{#if !disabled} { if (buttonRef) { buttonRef.click() } } }} onclick={href ? undefined : (e) => { if (stopPropagationOnClick) e.preventDefault() dispatch('click') }} {href} data-light-mode={lightMode} class={twMerge( 'group flex items-center px-2 py-2 font-light rounded-md gap-2', compact ? 'w-auto' : 'w-full', sidebarClasses.hoverBg, 'transition-all relative', sublabel ? 'h-10' : 'h-8', classNames, buttonClass )} use:conditionalMelt={trigger} aria-label={ariaLabel ?? label} title={isCollapsed || disableTitle ? undefined : label} {...$trigger} > {#if icon} {@const SvelteComponent = icon} {#if color} {@const disc = compact ? 20 : 26} {@const glyph = compact ? 12 : 16} {:else} {/if} {/if}
{#if !isCollapsed && label}
{label} {shortcut}
{/if} {#if sublabel}
{sublabel}
{/if}
{#if showChevron && !isCollapsed} {/if} {#if isCollapsed && notificationsCount > 0}
{:else if notificationsCount > 0}
{/if} {#snippet text()} {#if label} {label} {/if} {/snippet} {/if}