negodesign 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/dist/components/core/breadcrumb/breadcrumb-list.svelte +31 -31
  2. package/dist/components/core/button/ButtonBack.svelte +18 -18
  3. package/dist/components/core/button/ButtonLogin.svelte +15 -15
  4. package/dist/components/core/button/ButtonLoginWith.svelte +57 -57
  5. package/dist/components/core/carousel/data/CarouselModel.d.ts +2 -1
  6. package/dist/components/core/datatable/ui/DataTableActions.svelte +28 -28
  7. package/dist/components/core/datatable/ui/DataTableCheckbox.svelte +22 -22
  8. package/dist/components/core/datatable/ui/DataTableContent.svelte +59 -59
  9. package/dist/components/core/datatable/ui/DataTableCore.svelte +144 -144
  10. package/dist/components/core/datatable/ui/DataTableDragHandle.svelte +8 -8
  11. package/dist/components/core/datatable/ui/DataTableListFilter.svelte +59 -59
  12. package/dist/components/core/datatable/ui/DataTableListPagination.svelte +35 -35
  13. package/dist/components/core/form/ui/input-base.svelte +81 -81
  14. package/dist/components/core/form/ui/input-email.svelte +22 -22
  15. package/dist/components/core/form/ui/input-password-confirm.svelte +22 -22
  16. package/dist/components/core/form/ui/input-password.svelte +22 -22
  17. package/dist/components/core/form/ui/input-phone.svelte +22 -0
  18. package/dist/components/core/form/ui/input-phone.svelte.d.ts +4 -0
  19. package/dist/components/core/form/ui/input-username.svelte +21 -21
  20. package/dist/components/core/label/LabelOr.svelte +25 -25
  21. package/dist/components/core/link/link-forget-password.svelte +12 -12
  22. package/dist/components/core/link/link-privacy-polity.svelte +12 -12
  23. package/dist/components/core/link/link-terms-of-service.svelte +12 -12
  24. package/dist/components/core/nav/ui/nav-menu-bar.svelte +97 -97
  25. package/dist/components/core/nav/ui/nav-menu-bottom-bar.svelte +33 -33
  26. package/dist/components/core/nav/ui/nav-menu-top-bar.svelte +103 -103
  27. package/dist/components/core/sidebar/menu-bar-sidebar.svelte +62 -62
  28. package/dist/components/core/tabs/ui/tab-underline.svelte +41 -41
  29. package/dist/components/pages/admin/ui/admin-content.svelte +13 -13
  30. package/dist/components/pages/admin/ui/admin-panel.svelte +40 -40
  31. package/dist/components/pages/login/admin/01/data/page-props.d.ts +10 -0
  32. package/dist/components/pages/login/admin/01/data/page-props.js +1 -0
  33. package/dist/components/pages/login/admin/01/ui/AuthCard.svelte +84 -58
  34. package/dist/components/pages/login/admin/01/ui/AuthCard.svelte.d.ts +11 -17
  35. package/dist/components/pages/login/admin/01/ui/FormLogin.svelte +25 -5
  36. package/dist/components/pages/login/admin/01/ui/FormLogin.svelte.d.ts +6 -1
  37. package/dist/components/pages/login/admin/01/ui/FormLoginEmailPassword.svelte +12 -0
  38. package/dist/components/pages/login/admin/01/ui/FormLoginEmailPassword.svelte.d.ts +7 -0
  39. package/dist/components/pages/login/admin/01/ui/FormLoginPhonePassword.svelte +12 -0
  40. package/dist/components/pages/login/admin/01/ui/FormLoginPhonePassword.svelte.d.ts +7 -0
  41. package/dist/components/pages/login/admin/01/ui/FormLoginUsernamePassword.svelte +12 -0
  42. package/dist/components/pages/login/admin/01/ui/FormLoginUsernamePassword.svelte.d.ts +7 -0
  43. package/dist/components/pages/login/admin/01/ui/FormRegister.svelte +28 -28
  44. package/dist/components/pages/login/admin/01/ui/LeftHero.svelte +105 -105
  45. package/dist/components/pages/login/admin/01/ui/PageLogin.svelte +47 -49
  46. package/dist/components/pages/login/admin/01/ui/PageLogin.svelte.d.ts +14 -17
  47. package/dist/components/ui/badge/badge.svelte +49 -49
  48. package/dist/components/ui/chart/chart-container.svelte +80 -80
  49. package/dist/components/ui/chart/chart-style.svelte +37 -37
  50. package/dist/components/ui/chart/chart-tooltip.svelte +184 -184
  51. package/dist/components/ui/checkbox/checkbox.svelte +40 -40
  52. package/dist/components/ui/data-table/flex-render.svelte +40 -40
  53. package/dist/components/ui/drawer/drawer-close.svelte +7 -7
  54. package/dist/components/ui/drawer/drawer-content.svelte +33 -33
  55. package/dist/components/ui/drawer/drawer-description.svelte +17 -17
  56. package/dist/components/ui/drawer/drawer-footer.svelte +20 -20
  57. package/dist/components/ui/drawer/drawer-header.svelte +20 -20
  58. package/dist/components/ui/drawer/drawer-nested.svelte +12 -12
  59. package/dist/components/ui/drawer/drawer-overlay.svelte +17 -17
  60. package/dist/components/ui/drawer/drawer-portal.svelte +7 -7
  61. package/dist/components/ui/drawer/drawer-title.svelte +17 -17
  62. package/dist/components/ui/drawer/drawer-trigger.svelte +7 -7
  63. package/dist/components/ui/drawer/drawer.svelte +12 -12
  64. package/dist/components/ui/select/select-content.svelte +45 -45
  65. package/dist/components/ui/select/select-group-heading.svelte +21 -21
  66. package/dist/components/ui/select/select-group.svelte +17 -17
  67. package/dist/components/ui/select/select-item.svelte +41 -41
  68. package/dist/components/ui/select/select-label.svelte +20 -20
  69. package/dist/components/ui/select/select-portal.svelte +7 -7
  70. package/dist/components/ui/select/select-scroll-down-button.svelte +21 -21
  71. package/dist/components/ui/select/select-scroll-up-button.svelte +21 -21
  72. package/dist/components/ui/select/select-separator.svelte +18 -18
  73. package/dist/components/ui/select/select-trigger.svelte +30 -30
  74. package/dist/components/ui/select/select.svelte +11 -11
  75. package/dist/components/ui/sidebar/sidebar-menu-sub-button.svelte +39 -39
  76. package/dist/components/ui/table/table-body.svelte +15 -15
  77. package/dist/components/ui/table/table-caption.svelte +20 -20
  78. package/dist/components/ui/table/table-cell.svelte +15 -15
  79. package/dist/components/ui/table/table-footer.svelte +20 -20
  80. package/dist/components/ui/table/table-head.svelte +15 -15
  81. package/dist/components/ui/table/table-header.svelte +20 -20
  82. package/dist/components/ui/table/table-row.svelte +15 -15
  83. package/dist/components/ui/table/table.svelte +17 -17
  84. package/dist/components/ui/tabs/tabs-content.svelte +17 -17
  85. package/dist/components/ui/tabs/tabs-list.svelte +40 -40
  86. package/dist/components/ui/tabs/tabs-trigger.svelte +23 -23
  87. package/dist/components/ui/tabs/tabs.svelte +19 -19
  88. package/dist/index.js +0 -1
  89. package/package.json +94 -88
@@ -1,20 +1,20 @@
1
- <script lang="ts">
2
- import { cn, type WithElementRef } from "../../../utils.js";
3
- import type { HTMLAttributes } from "svelte/elements";
4
-
5
- let {
6
- ref = $bindable(null),
7
- class: className,
8
- children,
9
- ...restProps
10
- }: WithElementRef<HTMLAttributes<HTMLDivElement>> = $props();
11
- </script>
12
-
13
- <div
14
- bind:this={ref}
15
- data-slot="drawer-footer"
16
- class={cn("gap-2 p-4 mt-auto flex flex-col", className)}
17
- {...restProps}
18
- >
19
- {@render children?.()}
20
- </div>
1
+ <script lang="ts">
2
+ import { cn, type WithElementRef } from "../../../utils.js";
3
+ import type { HTMLAttributes } from "svelte/elements";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ children,
9
+ ...restProps
10
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> = $props();
11
+ </script>
12
+
13
+ <div
14
+ bind:this={ref}
15
+ data-slot="drawer-footer"
16
+ class={cn("gap-2 p-4 mt-auto flex flex-col", className)}
17
+ {...restProps}
18
+ >
19
+ {@render children?.()}
20
+ </div>
@@ -1,20 +1,20 @@
1
- <script lang="ts">
2
- import type { HTMLAttributes } from "svelte/elements";
3
- import { cn, type WithElementRef } from "../../../utils.js";
4
-
5
- let {
6
- ref = $bindable(null),
7
- class: className,
8
- children,
9
- ...restProps
10
- }: WithElementRef<HTMLAttributes<HTMLDivElement>> = $props();
11
- </script>
12
-
13
- <div
14
- bind:this={ref}
15
- data-slot="drawer-header"
16
- class={cn("gap-0.5 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:gap-1.5 md:text-left flex flex-col", className)}
17
- {...restProps}
18
- >
19
- {@render children?.()}
20
- </div>
1
+ <script lang="ts">
2
+ import type { HTMLAttributes } from "svelte/elements";
3
+ import { cn, type WithElementRef } from "../../../utils.js";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ children,
9
+ ...restProps
10
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> = $props();
11
+ </script>
12
+
13
+ <div
14
+ bind:this={ref}
15
+ data-slot="drawer-header"
16
+ class={cn("gap-0.5 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:gap-1.5 md:text-left flex flex-col", className)}
17
+ {...restProps}
18
+ >
19
+ {@render children?.()}
20
+ </div>
@@ -1,12 +1,12 @@
1
- <script lang="ts">
2
- import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
-
4
- let {
5
- shouldScaleBackground = true,
6
- open = $bindable(false),
7
- activeSnapPoint = $bindable(null),
8
- ...restProps
9
- }: DrawerPrimitive.RootProps = $props();
10
- </script>
11
-
12
- <DrawerPrimitive.NestedRoot {shouldScaleBackground} bind:open bind:activeSnapPoint {...restProps} />
1
+ <script lang="ts">
2
+ import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
+
4
+ let {
5
+ shouldScaleBackground = true,
6
+ open = $bindable(false),
7
+ activeSnapPoint = $bindable(null),
8
+ ...restProps
9
+ }: DrawerPrimitive.RootProps = $props();
10
+ </script>
11
+
12
+ <DrawerPrimitive.NestedRoot {shouldScaleBackground} bind:open bind:activeSnapPoint {...restProps} />
@@ -1,17 +1,17 @@
1
- <script lang="ts">
2
- import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
- import { cn } from "../../../utils.js";
4
-
5
- let {
6
- ref = $bindable(null),
7
- class: className,
8
- ...restProps
9
- }: DrawerPrimitive.OverlayProps = $props();
10
- </script>
11
-
12
- <DrawerPrimitive.Overlay
13
- bind:ref
14
- data-slot="drawer-overlay"
15
- class={cn("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/80 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50", className)}
16
- {...restProps}
17
- />
1
+ <script lang="ts">
2
+ import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
+ import { cn } from "../../../utils.js";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: DrawerPrimitive.OverlayProps = $props();
10
+ </script>
11
+
12
+ <DrawerPrimitive.Overlay
13
+ bind:ref
14
+ data-slot="drawer-overlay"
15
+ class={cn("data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 bg-black/80 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50", className)}
16
+ {...restProps}
17
+ />
@@ -1,7 +1,7 @@
1
- <script lang="ts">
2
- import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
-
4
- let { ...restProps }: DrawerPrimitive.PortalProps = $props();
5
- </script>
6
-
7
- <DrawerPrimitive.Portal {...restProps} />
1
+ <script lang="ts">
2
+ import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
+
4
+ let { ...restProps }: DrawerPrimitive.PortalProps = $props();
5
+ </script>
6
+
7
+ <DrawerPrimitive.Portal {...restProps} />
@@ -1,17 +1,17 @@
1
- <script lang="ts">
2
- import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
- import { cn } from "../../../utils.js";
4
-
5
- let {
6
- ref = $bindable(null),
7
- class: className,
8
- ...restProps
9
- }: DrawerPrimitive.TitleProps = $props();
10
- </script>
11
-
12
- <DrawerPrimitive.Title
13
- bind:ref
14
- data-slot="drawer-title"
15
- class={cn("text-foreground text-base font-medium", className)}
16
- {...restProps}
17
- />
1
+ <script lang="ts">
2
+ import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
+ import { cn } from "../../../utils.js";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: DrawerPrimitive.TitleProps = $props();
10
+ </script>
11
+
12
+ <DrawerPrimitive.Title
13
+ bind:ref
14
+ data-slot="drawer-title"
15
+ class={cn("text-foreground text-base font-medium", className)}
16
+ {...restProps}
17
+ />
@@ -1,7 +1,7 @@
1
- <script lang="ts">
2
- import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
-
4
- let { ref = $bindable(null), ...restProps }: DrawerPrimitive.TriggerProps = $props();
5
- </script>
6
-
7
- <DrawerPrimitive.Trigger bind:ref data-slot="drawer-trigger" {...restProps} />
1
+ <script lang="ts">
2
+ import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
+
4
+ let { ref = $bindable(null), ...restProps }: DrawerPrimitive.TriggerProps = $props();
5
+ </script>
6
+
7
+ <DrawerPrimitive.Trigger bind:ref data-slot="drawer-trigger" {...restProps} />
@@ -1,12 +1,12 @@
1
- <script lang="ts">
2
- import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
-
4
- let {
5
- shouldScaleBackground = true,
6
- open = $bindable(false),
7
- activeSnapPoint = $bindable(null),
8
- ...restProps
9
- }: DrawerPrimitive.RootProps = $props();
10
- </script>
11
-
12
- <DrawerPrimitive.Root {shouldScaleBackground} bind:open bind:activeSnapPoint {...restProps} />
1
+ <script lang="ts">
2
+ import { Drawer as DrawerPrimitive } from "vaul-svelte";
3
+
4
+ let {
5
+ shouldScaleBackground = true,
6
+ open = $bindable(false),
7
+ activeSnapPoint = $bindable(null),
8
+ ...restProps
9
+ }: DrawerPrimitive.RootProps = $props();
10
+ </script>
11
+
12
+ <DrawerPrimitive.Root {shouldScaleBackground} bind:open bind:activeSnapPoint {...restProps} />
@@ -1,45 +1,45 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
- import SelectPortal from "./select-portal.svelte";
4
- import SelectScrollUpButton from "./select-scroll-up-button.svelte";
5
- import SelectScrollDownButton from "./select-scroll-down-button.svelte";
6
- import { cn, type WithoutChild } from "../../../utils.js";
7
- import type { ComponentProps } from "svelte";
8
- import type { WithoutChildrenOrChild } from "../../../utils.js";
9
-
10
- let {
11
- ref = $bindable(null),
12
- class: className,
13
- sideOffset = 4,
14
- portalProps,
15
- children,
16
- preventScroll = true,
17
- ...restProps
18
- }: WithoutChild<SelectPrimitive.ContentProps> & {
19
- portalProps?: WithoutChildrenOrChild<ComponentProps<typeof SelectPortal>>;
20
- } = $props();
21
- </script>
22
-
23
- <SelectPortal {...portalProps}>
24
- <SelectPrimitive.Content
25
- bind:ref
26
- {sideOffset}
27
- {preventScroll}
28
- data-slot="select-content"
29
- class={cn(
30
- "bg-popover text-popover-foreground data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/5 min-w-36 rounded-2xl shadow-2xl ring-1 duration-100 data-[side=inline-start]:slide-in-from-right-2 data-[side=inline-end]:slide-in-from-left-2 relative isolate z-50 overflow-x-hidden overflow-y-auto",
31
- className
32
- )}
33
- {...restProps}
34
- >
35
- <SelectScrollUpButton />
36
- <SelectPrimitive.Viewport
37
- class={cn(
38
- "h-(--bits-select-anchor-height) w-full min-w-(--bits-select-anchor-width) scroll-my-1"
39
- )}
40
- >
41
- {@render children?.()}
42
- </SelectPrimitive.Viewport>
43
- <SelectScrollDownButton />
44
- </SelectPrimitive.Content>
45
- </SelectPortal>
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+ import SelectPortal from "./select-portal.svelte";
4
+ import SelectScrollUpButton from "./select-scroll-up-button.svelte";
5
+ import SelectScrollDownButton from "./select-scroll-down-button.svelte";
6
+ import { cn, type WithoutChild } from "../../../utils.js";
7
+ import type { ComponentProps } from "svelte";
8
+ import type { WithoutChildrenOrChild } from "../../../utils.js";
9
+
10
+ let {
11
+ ref = $bindable(null),
12
+ class: className,
13
+ sideOffset = 4,
14
+ portalProps,
15
+ children,
16
+ preventScroll = true,
17
+ ...restProps
18
+ }: WithoutChild<SelectPrimitive.ContentProps> & {
19
+ portalProps?: WithoutChildrenOrChild<ComponentProps<typeof SelectPortal>>;
20
+ } = $props();
21
+ </script>
22
+
23
+ <SelectPortal {...portalProps}>
24
+ <SelectPrimitive.Content
25
+ bind:ref
26
+ {sideOffset}
27
+ {preventScroll}
28
+ data-slot="select-content"
29
+ class={cn(
30
+ "bg-popover text-popover-foreground data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 ring-foreground/5 min-w-36 rounded-2xl shadow-2xl ring-1 duration-100 data-[side=inline-start]:slide-in-from-right-2 data-[side=inline-end]:slide-in-from-left-2 relative isolate z-50 overflow-x-hidden overflow-y-auto",
31
+ className
32
+ )}
33
+ {...restProps}
34
+ >
35
+ <SelectScrollUpButton />
36
+ <SelectPrimitive.Viewport
37
+ class={cn(
38
+ "h-(--bits-select-anchor-height) w-full min-w-(--bits-select-anchor-width) scroll-my-1"
39
+ )}
40
+ >
41
+ {@render children?.()}
42
+ </SelectPrimitive.Viewport>
43
+ <SelectScrollDownButton />
44
+ </SelectPrimitive.Content>
45
+ </SelectPortal>
@@ -1,21 +1,21 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
- import { cn } from "../../../utils.js";
4
- import type { ComponentProps } from "svelte";
5
-
6
- let {
7
- ref = $bindable(null),
8
- class: className,
9
- children,
10
- ...restProps
11
- }: ComponentProps<typeof SelectPrimitive.GroupHeading> = $props();
12
- </script>
13
-
14
- <SelectPrimitive.GroupHeading
15
- bind:ref
16
- data-slot="select-group-heading"
17
- class={cn("text-muted-foreground px-2 py-1.5 text-xs", className)}
18
- {...restProps}
19
- >
20
- {@render children?.()}
21
- </SelectPrimitive.GroupHeading>
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+ import { cn } from "../../../utils.js";
4
+ import type { ComponentProps } from "svelte";
5
+
6
+ let {
7
+ ref = $bindable(null),
8
+ class: className,
9
+ children,
10
+ ...restProps
11
+ }: ComponentProps<typeof SelectPrimitive.GroupHeading> = $props();
12
+ </script>
13
+
14
+ <SelectPrimitive.GroupHeading
15
+ bind:ref
16
+ data-slot="select-group-heading"
17
+ class={cn("text-muted-foreground px-2 py-1.5 text-xs", className)}
18
+ {...restProps}
19
+ >
20
+ {@render children?.()}
21
+ </SelectPrimitive.GroupHeading>
@@ -1,17 +1,17 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
- import { cn } from "../../../utils.js";
4
-
5
- let {
6
- ref = $bindable(null),
7
- class: className,
8
- ...restProps
9
- }: SelectPrimitive.GroupProps = $props();
10
- </script>
11
-
12
- <SelectPrimitive.Group
13
- bind:ref
14
- data-slot="select-group"
15
- class={cn("scroll-my-1 p-1", className)}
16
- {...restProps}
17
- />
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+ import { cn } from "../../../utils.js";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: SelectPrimitive.GroupProps = $props();
10
+ </script>
11
+
12
+ <SelectPrimitive.Group
13
+ bind:ref
14
+ data-slot="select-group"
15
+ class={cn("scroll-my-1 p-1", className)}
16
+ {...restProps}
17
+ />
@@ -1,41 +1,41 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
- import { cn, type WithoutChild } from "../../../utils.js";
4
- import { HugeiconsIcon } from "@hugeicons/svelte"
5
- import { Tick02Icon } from '@hugeicons/core-free-icons';
6
-
7
- let {
8
- ref = $bindable(null),
9
- class: className,
10
- value,
11
- label,
12
- children: childrenProp,
13
- ...restProps
14
- }: WithoutChild<SelectPrimitive.ItemProps> = $props();
15
- </script>
16
-
17
- <SelectPrimitive.Item
18
- bind:ref
19
- {value}
20
- data-slot="select-item"
21
- class={cn(
22
- "focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground gap-2.5 rounded-xl py-2 pr-8 pl-3 text-sm [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2 focus:bg-accent data-highlighted:bg-accent data-highlighted:text-accent-foreground focus:text-accent-foreground relative flex w-full cursor-default items-center outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0",
23
- className
24
- )}
25
- {...restProps}
26
- >
27
- {#snippet children({ selected, highlighted })}
28
- <span class="absolute end-2 flex size-3.5 items-center justify-center">
29
- {#if selected}
30
- <HugeiconsIcon icon={Tick02Icon} strokeWidth={2} class="cn-select-item-indicator-icon" />
31
- {/if}
32
- </span>
33
- <span class="flex flex-1 gap-2 shrink-0 whitespace-nowrap">
34
- {#if childrenProp}
35
- {@render childrenProp({ selected, highlighted })}
36
- {:else}
37
- {label || value}
38
- {/if}
39
- </span>
40
- {/snippet}
41
- </SelectPrimitive.Item>
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+ import { cn, type WithoutChild } from "../../../utils.js";
4
+ import { HugeiconsIcon } from "@hugeicons/svelte"
5
+ import { Tick02Icon } from '@hugeicons/core-free-icons';
6
+
7
+ let {
8
+ ref = $bindable(null),
9
+ class: className,
10
+ value,
11
+ label,
12
+ children: childrenProp,
13
+ ...restProps
14
+ }: WithoutChild<SelectPrimitive.ItemProps> = $props();
15
+ </script>
16
+
17
+ <SelectPrimitive.Item
18
+ bind:ref
19
+ {value}
20
+ data-slot="select-item"
21
+ class={cn(
22
+ "focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground gap-2.5 rounded-xl py-2 pr-8 pl-3 text-sm [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2 focus:bg-accent data-highlighted:bg-accent data-highlighted:text-accent-foreground focus:text-accent-foreground relative flex w-full cursor-default items-center outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0",
23
+ className
24
+ )}
25
+ {...restProps}
26
+ >
27
+ {#snippet children({ selected, highlighted })}
28
+ <span class="absolute end-2 flex size-3.5 items-center justify-center">
29
+ {#if selected}
30
+ <HugeiconsIcon icon={Tick02Icon} strokeWidth={2} class="cn-select-item-indicator-icon" />
31
+ {/if}
32
+ </span>
33
+ <span class="flex flex-1 gap-2 shrink-0 whitespace-nowrap">
34
+ {#if childrenProp}
35
+ {@render childrenProp({ selected, highlighted })}
36
+ {:else}
37
+ {label || value}
38
+ {/if}
39
+ </span>
40
+ {/snippet}
41
+ </SelectPrimitive.Item>
@@ -1,20 +1,20 @@
1
- <script lang="ts">
2
- import { cn, type WithElementRef } from "../../../utils.js";
3
- import type { HTMLAttributes } from "svelte/elements";
4
-
5
- let {
6
- ref = $bindable(null),
7
- class: className,
8
- children,
9
- ...restProps
10
- }: WithElementRef<HTMLAttributes<HTMLDivElement>> & {} = $props();
11
- </script>
12
-
13
- <div
14
- bind:this={ref}
15
- data-slot="select-label"
16
- class={cn("text-muted-foreground px-3 py-2.5 text-xs", className)}
17
- {...restProps}
18
- >
19
- {@render children?.()}
20
- </div>
1
+ <script lang="ts">
2
+ import { cn, type WithElementRef } from "../../../utils.js";
3
+ import type { HTMLAttributes } from "svelte/elements";
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ children,
9
+ ...restProps
10
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> & {} = $props();
11
+ </script>
12
+
13
+ <div
14
+ bind:this={ref}
15
+ data-slot="select-label"
16
+ class={cn("text-muted-foreground px-3 py-2.5 text-xs", className)}
17
+ {...restProps}
18
+ >
19
+ {@render children?.()}
20
+ </div>
@@ -1,7 +1,7 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
-
4
- let { ...restProps }: SelectPrimitive.PortalProps = $props();
5
- </script>
6
-
7
- <SelectPrimitive.Portal {...restProps} />
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+
4
+ let { ...restProps }: SelectPrimitive.PortalProps = $props();
5
+ </script>
6
+
7
+ <SelectPrimitive.Portal {...restProps} />
@@ -1,21 +1,21 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
- import { cn, type WithoutChildrenOrChild } from "../../../utils.js";
4
- import { HugeiconsIcon } from "@hugeicons/svelte"
5
- import { ArrowDown01Icon } from '@hugeicons/core-free-icons';
6
-
7
- let {
8
- ref = $bindable(null),
9
- class: className,
10
- ...restProps
11
- }: WithoutChildrenOrChild<SelectPrimitive.ScrollDownButtonProps> = $props();
12
- </script>
13
-
14
- <SelectPrimitive.ScrollDownButton
15
- bind:ref
16
- data-slot="select-scroll-down-button"
17
- class={cn("bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-4 bottom-0 w-full", className)}
18
- {...restProps}
19
- >
20
- <HugeiconsIcon icon={ArrowDown01Icon} strokeWidth={2} />
21
- </SelectPrimitive.ScrollDownButton>
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+ import { cn, type WithoutChildrenOrChild } from "../../../utils.js";
4
+ import { HugeiconsIcon } from "@hugeicons/svelte"
5
+ import { ArrowDown01Icon } from '@hugeicons/core-free-icons';
6
+
7
+ let {
8
+ ref = $bindable(null),
9
+ class: className,
10
+ ...restProps
11
+ }: WithoutChildrenOrChild<SelectPrimitive.ScrollDownButtonProps> = $props();
12
+ </script>
13
+
14
+ <SelectPrimitive.ScrollDownButton
15
+ bind:ref
16
+ data-slot="select-scroll-down-button"
17
+ class={cn("bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-4 bottom-0 w-full", className)}
18
+ {...restProps}
19
+ >
20
+ <HugeiconsIcon icon={ArrowDown01Icon} strokeWidth={2} />
21
+ </SelectPrimitive.ScrollDownButton>
@@ -1,21 +1,21 @@
1
- <script lang="ts">
2
- import { Select as SelectPrimitive } from "bits-ui";
3
- import { cn, type WithoutChildrenOrChild } from "../../../utils.js";
4
- import { HugeiconsIcon } from "@hugeicons/svelte"
5
- import { ArrowUp01Icon } from '@hugeicons/core-free-icons';
6
-
7
- let {
8
- ref = $bindable(null),
9
- class: className,
10
- ...restProps
11
- }: WithoutChildrenOrChild<SelectPrimitive.ScrollUpButtonProps> = $props();
12
- </script>
13
-
14
- <SelectPrimitive.ScrollUpButton
15
- bind:ref
16
- data-slot="select-scroll-up-button"
17
- class={cn("bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-4 top-0 w-full", className)}
18
- {...restProps}
19
- >
20
- <HugeiconsIcon icon={ArrowUp01Icon} strokeWidth={2} />
21
- </SelectPrimitive.ScrollUpButton>
1
+ <script lang="ts">
2
+ import { Select as SelectPrimitive } from "bits-ui";
3
+ import { cn, type WithoutChildrenOrChild } from "../../../utils.js";
4
+ import { HugeiconsIcon } from "@hugeicons/svelte"
5
+ import { ArrowUp01Icon } from '@hugeicons/core-free-icons';
6
+
7
+ let {
8
+ ref = $bindable(null),
9
+ class: className,
10
+ ...restProps
11
+ }: WithoutChildrenOrChild<SelectPrimitive.ScrollUpButtonProps> = $props();
12
+ </script>
13
+
14
+ <SelectPrimitive.ScrollUpButton
15
+ bind:ref
16
+ data-slot="select-scroll-up-button"
17
+ class={cn("bg-popover z-10 flex cursor-default items-center justify-center py-1 [&_svg:not([class*='size-'])]:size-4 top-0 w-full", className)}
18
+ {...restProps}
19
+ >
20
+ <HugeiconsIcon icon={ArrowUp01Icon} strokeWidth={2} />
21
+ </SelectPrimitive.ScrollUpButton>