|
1 | 1 | <script lang="ts"> |
2 | 2 | import * as Sidebar from '$lib/components/ui/sidebar'; |
3 | | - import {Icon} from '$lib/components/ui/icon'; |
4 | 3 | import {ComposableInput} from '$lib/components/ui/input'; |
5 | 4 | import {t} from 'svelte-i18n-lingui'; |
6 | | - import {Toggle} from '$lib/components/ui/toggle'; |
7 | | - import {mergeProps} from 'bits-ui'; |
8 | 5 | import {useProjectStats, useWritingSystemService} from '$project/data'; |
9 | 6 | import {pt} from '$lib/views/view-text'; |
10 | 7 | import {useCurrentView} from '$lib/views/view-service'; |
|
22 | 19 | import {Switch} from '$lib/components/ui/switch'; |
23 | 20 | import ResponsivePopup from '$lib/components/responsive-popup/responsive-popup.svelte'; |
24 | 21 | import {IsMobile} from '$lib/hooks/is-mobile.svelte'; |
| 22 | + import {Button} from '$lib/components/ui/button'; |
25 | 23 |
|
26 | 24 | const stats = useProjectStats(); |
27 | 25 | const currentView = useCurrentView(); |
|
118 | 116 | }} |
119 | 117 | > |
120 | 118 | {#snippet trigger({ props })} |
121 | | - <Toggle |
122 | | - {...mergeProps(props, { class: 'aspect-square' })} |
123 | | - aria-label={$t`Toggle filters`} |
124 | | - size={IsMobile.value ? 'sm' : 'xs'} |
125 | | - bind:pressed={filtersExpanded} |
126 | | - > |
127 | | - <Icon icon={gridifyFilter ? 'i-mdi-filter' : 'i-mdi-filter-outline'} class="size-6 md:size-5" /> |
128 | | - </Toggle> |
| 119 | + <Button {...props} variant="ghost" |
| 120 | + size={IsMobile.value ? 'sm-icon' : 'xs-icon'} |
| 121 | + icon={gridifyFilter ? 'i-mdi-filter' : 'i-mdi-filter-outline'} |
| 122 | + aria-label={$t`Toggle filters`} /> |
129 | 123 | {/snippet} |
130 | 124 | <div class="space-y-4"> |
131 | 125 | <div class="flex flex-col"> |
|
0 commit comments