negodesign 0.0.26 → 0.0.27
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.
- package/dist/components/core/breadcrumb/breadcrumb-list.svelte +31 -31
- package/dist/components/core/button/ButtonBack.svelte +18 -18
- package/dist/components/core/button/ButtonLogin.svelte +15 -15
- package/dist/components/core/button/ButtonLoginWith.svelte +57 -57
- package/dist/components/core/button/ButtonSend.svelte +15 -15
- package/dist/components/core/card/highlight/01/CardHighlight01.svelte +91 -91
- package/dist/components/core/card/highlight/02/CardHighlight02.svelte +93 -93
- package/dist/components/core/card/highlight/CardHighlight.svelte +22 -22
- package/dist/components/core/card/media/01/CardMedia01.svelte +111 -111
- package/dist/components/core/card/media/02/CardMedia02.svelte +110 -110
- package/dist/components/core/card/media/CardMedia.svelte +17 -17
- package/dist/components/core/card/profile/01/CardProfile01.svelte +98 -98
- package/dist/components/core/card/profile/02/CardProfile02.svelte +98 -98
- package/dist/components/core/card/profile/CardProfile.svelte +17 -17
- package/dist/components/core/card/promotion/CardPromotion.svelte +112 -112
- package/dist/components/core/card/shared/CardButton.svelte +30 -30
- package/dist/components/core/card/shared/CardCart.svelte +36 -36
- package/dist/components/core/card/shared/CardDescription.svelte +38 -38
- package/dist/components/core/card/shared/CardFavorite.svelte +33 -33
- package/dist/components/core/card/shared/CardStarRating.svelte +20 -20
- package/dist/components/core/card/shared/CardStartPrice.svelte +34 -34
- package/dist/components/core/card/shared/CardTags.svelte +73 -73
- package/dist/components/core/card/shared/CardThumbnailVideo.svelte +169 -169
- package/dist/components/core/card/shared/TruncatableText.svelte +55 -55
- package/dist/components/core/carousel/badge/ui/CarouselBadge.svelte +82 -83
- package/dist/components/core/carousel/hero/CarouselHero.svelte +158 -158
- package/dist/components/core/carousel/highlights/ui/CarouselHighlights.svelte +63 -63
- package/dist/components/core/carousel/promotion/ui/CarouselPromotion.svelte +64 -64
- package/dist/components/core/carousel/shared/ui/CarouselHeader.svelte +55 -55
- package/dist/components/core/datatable/ui/DataTableActions.svelte +28 -28
- package/dist/components/core/datatable/ui/DataTableCheckbox.svelte +22 -22
- package/dist/components/core/datatable/ui/DataTableContent.svelte +59 -59
- package/dist/components/core/datatable/ui/DataTableCore.svelte +151 -151
- package/dist/components/core/datatable/ui/DataTableDragHandle.svelte +8 -8
- package/dist/components/core/datatable/ui/DataTableListFilter.svelte +59 -59
- package/dist/components/core/datatable/ui/DataTableListPagination.svelte +35 -35
- package/dist/components/core/form/ui/input-base.svelte +81 -81
- package/dist/components/core/form/ui/input-email-or-phone.svelte +23 -23
- package/dist/components/core/form/ui/input-email.svelte +23 -23
- package/dist/components/core/form/ui/input-password-confirm.svelte +23 -23
- package/dist/components/core/form/ui/input-password.svelte +23 -23
- package/dist/components/core/form/ui/input-phone.svelte +33 -33
- package/dist/components/core/form/ui/input-username.svelte +22 -22
- package/dist/components/core/hero/SimpleHero.svelte +65 -65
- package/dist/components/core/label/LabelOr.svelte +25 -25
- package/dist/components/core/link/link-forget-password.svelte +12 -12
- package/dist/components/core/link/link-privacy-polity.svelte +12 -12
- package/dist/components/core/link/link-terms-of-service.svelte +12 -12
- package/dist/components/core/nav/ui/menu-links.svelte +27 -27
- package/dist/components/core/nav/ui/mobile/nav-menu-drawer.svelte +85 -85
- package/dist/components/core/nav/ui/nav-menu-bottom-sidebar.svelte +33 -33
- package/dist/components/core/nav/ui/nav-menu-sidebar.svelte +97 -97
- package/dist/components/core/nav/ui/nav-menu-top-bar-sidebar.svelte +103 -103
- package/dist/components/core/nav/ui/nav-menu.svelte +106 -106
- package/dist/components/core/panel/CarouselSlot.svelte +63 -63
- package/dist/components/core/panel/LeftHero.svelte +116 -116
- package/dist/components/core/search/SearchInput.svelte +32 -32
- package/dist/components/core/search/shared/SearchInputCore.svelte +66 -66
- package/dist/components/core/sidebar/MenuBarSidebar.svelte +70 -70
- package/dist/components/core/tabs/ui/tab-underline.svelte +43 -43
- package/dist/components/pages/admin/01/ui/AdminContent.svelte +14 -14
- package/dist/components/pages/admin/01/ui/AdminPanel.svelte +46 -46
- package/dist/components/pages/security/login/01/ui/FormRegister.svelte +28 -28
- package/dist/components/pages/security/login/01/ui/LoginCard.svelte +107 -107
- package/dist/components/pages/security/login/PageLogin.svelte +22 -22
- package/dist/components/ui/badge/badge.svelte +49 -49
- package/dist/components/ui/button/button.svelte +82 -82
- package/dist/components/ui/chart/chart-container.svelte +80 -80
- package/dist/components/ui/chart/chart-style.svelte +37 -37
- package/dist/components/ui/chart/chart-tooltip.svelte +184 -184
- package/dist/components/ui/checkbox/checkbox.svelte +40 -40
- package/dist/components/ui/data-table/flex-render.svelte +40 -40
- package/dist/components/ui/drawer/drawer-close.svelte +7 -7
- package/dist/components/ui/drawer/drawer-content.svelte +33 -33
- package/dist/components/ui/drawer/drawer-description.svelte +17 -17
- package/dist/components/ui/drawer/drawer-footer.svelte +20 -20
- package/dist/components/ui/drawer/drawer-header.svelte +20 -20
- package/dist/components/ui/drawer/drawer-nested.svelte +12 -12
- package/dist/components/ui/drawer/drawer-overlay.svelte +17 -17
- package/dist/components/ui/drawer/drawer-portal.svelte +7 -7
- package/dist/components/ui/drawer/drawer-title.svelte +17 -17
- package/dist/components/ui/drawer/drawer-trigger.svelte +7 -7
- package/dist/components/ui/drawer/drawer.svelte +12 -12
- package/dist/components/ui/select/select-content.svelte +45 -45
- package/dist/components/ui/select/select-group-heading.svelte +21 -21
- package/dist/components/ui/select/select-group.svelte +17 -17
- package/dist/components/ui/select/select-item.svelte +41 -41
- package/dist/components/ui/select/select-label.svelte +20 -20
- package/dist/components/ui/select/select-portal.svelte +7 -7
- package/dist/components/ui/select/select-scroll-down-button.svelte +21 -21
- package/dist/components/ui/select/select-scroll-up-button.svelte +21 -21
- package/dist/components/ui/select/select-separator.svelte +18 -18
- package/dist/components/ui/select/select-trigger.svelte +30 -30
- package/dist/components/ui/select/select.svelte +11 -11
- package/dist/components/ui/sidebar/sidebar-menu-sub-button.svelte +39 -39
- package/dist/components/ui/star-rating/star-rating-star.svelte +41 -41
- package/dist/components/ui/star-rating/star-rating.svelte +20 -20
- package/dist/components/ui/table/table-body.svelte +15 -15
- package/dist/components/ui/table/table-caption.svelte +20 -20
- package/dist/components/ui/table/table-cell.svelte +15 -15
- package/dist/components/ui/table/table-footer.svelte +20 -20
- package/dist/components/ui/table/table-head.svelte +15 -15
- package/dist/components/ui/table/table-header.svelte +20 -20
- package/dist/components/ui/table/table-row.svelte +15 -15
- package/dist/components/ui/table/table.svelte +17 -17
- package/dist/components/ui/tabs/tabs-content.svelte +17 -17
- package/dist/components/ui/tabs/tabs-list.svelte +40 -40
- package/dist/components/ui/tabs/tabs-trigger.svelte +23 -23
- package/dist/components/ui/tabs/tabs.svelte +19 -19
- package/dist/globals.css +3 -0
- package/dist/styles/globals.css +149 -149
- package/package.json +113 -113
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import type { Separator as SeparatorPrimitive } from "bits-ui";
|
|
3
|
-
import { Separator } from "../separator/index.js";
|
|
4
|
-
import { cn } from "../../../utils.js";
|
|
5
|
-
|
|
6
|
-
let {
|
|
7
|
-
ref = $bindable(null),
|
|
8
|
-
class: className,
|
|
9
|
-
...restProps
|
|
10
|
-
}: SeparatorPrimitive.RootProps = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<Separator
|
|
14
|
-
bind:ref
|
|
15
|
-
data-slot="select-separator"
|
|
16
|
-
class={cn("bg-border/50 -mx-1 my-1 h-px pointer-events-none", className)}
|
|
17
|
-
{...restProps}
|
|
18
|
-
/>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { Separator as SeparatorPrimitive } from "bits-ui";
|
|
3
|
+
import { Separator } from "../separator/index.js";
|
|
4
|
+
import { cn } from "../../../utils.js";
|
|
5
|
+
|
|
6
|
+
let {
|
|
7
|
+
ref = $bindable(null),
|
|
8
|
+
class: className,
|
|
9
|
+
...restProps
|
|
10
|
+
}: SeparatorPrimitive.RootProps = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<Separator
|
|
14
|
+
bind:ref
|
|
15
|
+
data-slot="select-separator"
|
|
16
|
+
class={cn("bg-border/50 -mx-1 my-1 h-px pointer-events-none", className)}
|
|
17
|
+
{...restProps}
|
|
18
|
+
/>
|
|
@@ -1,30 +1,30 @@
|
|
|
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 { UnfoldMoreIcon } from '@hugeicons/core-free-icons';
|
|
6
|
-
|
|
7
|
-
let {
|
|
8
|
-
ref = $bindable(null),
|
|
9
|
-
class: className,
|
|
10
|
-
children,
|
|
11
|
-
size = "default",
|
|
12
|
-
...restProps
|
|
13
|
-
}: WithoutChild<SelectPrimitive.TriggerProps> & {
|
|
14
|
-
size?: "sm" | "default";
|
|
15
|
-
} = $props();
|
|
16
|
-
</script>
|
|
17
|
-
|
|
18
|
-
<SelectPrimitive.Trigger
|
|
19
|
-
bind:ref
|
|
20
|
-
data-slot="select-trigger"
|
|
21
|
-
data-size={size}
|
|
22
|
-
class={cn(
|
|
23
|
-
"border-input data-placeholder:text-muted-foreground bg-input/30 dark:hover:bg-input/50 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 gap-1.5 rounded-4xl border px-3 py-2 text-sm transition-colors focus-visible:ring-[3px] aria-invalid:ring-[3px] data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:flex *:data-[slot=select-value]:gap-1.5 [&_svg:not([class*='size-'])]:size-4 flex w-fit items-center justify-between whitespace-nowrap outline-none disabled:cursor-not-allowed disabled:opacity-50 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
24
|
-
className
|
|
25
|
-
)}
|
|
26
|
-
{...restProps}
|
|
27
|
-
>
|
|
28
|
-
{@render children?.()}
|
|
29
|
-
<HugeiconsIcon icon={UnfoldMoreIcon} strokeWidth={2} class="text-muted-foreground size-4 pointer-events-none" />
|
|
30
|
-
</SelectPrimitive.Trigger>
|
|
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 { UnfoldMoreIcon } from '@hugeicons/core-free-icons';
|
|
6
|
+
|
|
7
|
+
let {
|
|
8
|
+
ref = $bindable(null),
|
|
9
|
+
class: className,
|
|
10
|
+
children,
|
|
11
|
+
size = "default",
|
|
12
|
+
...restProps
|
|
13
|
+
}: WithoutChild<SelectPrimitive.TriggerProps> & {
|
|
14
|
+
size?: "sm" | "default";
|
|
15
|
+
} = $props();
|
|
16
|
+
</script>
|
|
17
|
+
|
|
18
|
+
<SelectPrimitive.Trigger
|
|
19
|
+
bind:ref
|
|
20
|
+
data-slot="select-trigger"
|
|
21
|
+
data-size={size}
|
|
22
|
+
class={cn(
|
|
23
|
+
"border-input data-placeholder:text-muted-foreground bg-input/30 dark:hover:bg-input/50 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 gap-1.5 rounded-4xl border px-3 py-2 text-sm transition-colors focus-visible:ring-[3px] aria-invalid:ring-[3px] data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:flex *:data-[slot=select-value]:gap-1.5 [&_svg:not([class*='size-'])]:size-4 flex w-fit items-center justify-between whitespace-nowrap outline-none disabled:cursor-not-allowed disabled:opacity-50 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
24
|
+
className
|
|
25
|
+
)}
|
|
26
|
+
{...restProps}
|
|
27
|
+
>
|
|
28
|
+
{@render children?.()}
|
|
29
|
+
<HugeiconsIcon icon={UnfoldMoreIcon} strokeWidth={2} class="text-muted-foreground size-4 pointer-events-none" />
|
|
30
|
+
</SelectPrimitive.Trigger>
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { Select as SelectPrimitive } from "bits-ui";
|
|
3
|
-
|
|
4
|
-
let {
|
|
5
|
-
open = $bindable(false),
|
|
6
|
-
value = $bindable(),
|
|
7
|
-
...restProps
|
|
8
|
-
}: SelectPrimitive.RootProps = $props();
|
|
9
|
-
</script>
|
|
10
|
-
|
|
11
|
-
<SelectPrimitive.Root bind:open bind:value={value as never} {...restProps} />
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { Select as SelectPrimitive } from "bits-ui";
|
|
3
|
+
|
|
4
|
+
let {
|
|
5
|
+
open = $bindable(false),
|
|
6
|
+
value = $bindable(),
|
|
7
|
+
...restProps
|
|
8
|
+
}: SelectPrimitive.RootProps = $props();
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
<SelectPrimitive.Root bind:open bind:value={value as never} {...restProps} />
|
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { cn, type WithElementRef } from "../../../utils.js";
|
|
3
|
-
import type { Snippet } from "svelte";
|
|
4
|
-
import type { HTMLAnchorAttributes } from "svelte/elements";
|
|
5
|
-
|
|
6
|
-
let {
|
|
7
|
-
ref = $bindable(null),
|
|
8
|
-
children,
|
|
9
|
-
child,
|
|
10
|
-
class: className,
|
|
11
|
-
size = "md",
|
|
12
|
-
isActive = false,
|
|
13
|
-
...restProps
|
|
14
|
-
}: WithElementRef<HTMLAnchorAttributes> & {
|
|
15
|
-
child?: Snippet<[{ props: Record<string, unknown> }]>;
|
|
16
|
-
size?: "sm" | "md";
|
|
17
|
-
isActive?: boolean;
|
|
18
|
-
} = $props();
|
|
19
|
-
|
|
20
|
-
const mergedProps = $derived({
|
|
21
|
-
class: cn(
|
|
22
|
-
"text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground [&>svg]:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground h-7 gap-2 rounded-md px-2 focus-visible:ring-2 data-[size=md]:text-sm data-[size=sm]:text-xs [&>svg]:size-4 flex min-w-0 -translate-x-px items-center overflow-hidden outline-hidden group-data-[collapsible=icon]:hidden disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:shrink-0",
|
|
23
|
-
className,
|
|
24
|
-
),
|
|
25
|
-
"data-slot": "sidebar-menu-sub-button",
|
|
26
|
-
"data-sidebar": "menu-sub-button",
|
|
27
|
-
"data-size": size,
|
|
28
|
-
"data-active": isActive,
|
|
29
|
-
...restProps,
|
|
30
|
-
});
|
|
31
|
-
</script>
|
|
32
|
-
|
|
33
|
-
{#if child}
|
|
34
|
-
{@render child({ props: mergedProps })}
|
|
35
|
-
{:else}
|
|
36
|
-
<a bind:this={ref} {...mergedProps}>
|
|
37
|
-
{@render children?.()}
|
|
38
|
-
</a>
|
|
39
|
-
{/if}
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { cn, type WithElementRef } from "../../../utils.js";
|
|
3
|
+
import type { Snippet } from "svelte";
|
|
4
|
+
import type { HTMLAnchorAttributes } from "svelte/elements";
|
|
5
|
+
|
|
6
|
+
let {
|
|
7
|
+
ref = $bindable(null),
|
|
8
|
+
children,
|
|
9
|
+
child,
|
|
10
|
+
class: className,
|
|
11
|
+
size = "md",
|
|
12
|
+
isActive = false,
|
|
13
|
+
...restProps
|
|
14
|
+
}: WithElementRef<HTMLAnchorAttributes> & {
|
|
15
|
+
child?: Snippet<[{ props: Record<string, unknown> }]>;
|
|
16
|
+
size?: "sm" | "md";
|
|
17
|
+
isActive?: boolean;
|
|
18
|
+
} = $props();
|
|
19
|
+
|
|
20
|
+
const mergedProps = $derived({
|
|
21
|
+
class: cn(
|
|
22
|
+
"text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground [&>svg]:text-sidebar-accent-foreground data-active:bg-sidebar-accent data-active:text-sidebar-accent-foreground h-7 gap-2 rounded-md px-2 focus-visible:ring-2 data-[size=md]:text-sm data-[size=sm]:text-xs [&>svg]:size-4 flex min-w-0 -translate-x-px items-center overflow-hidden outline-hidden group-data-[collapsible=icon]:hidden disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:shrink-0",
|
|
23
|
+
className,
|
|
24
|
+
),
|
|
25
|
+
"data-slot": "sidebar-menu-sub-button",
|
|
26
|
+
"data-sidebar": "menu-sub-button",
|
|
27
|
+
"data-size": size,
|
|
28
|
+
"data-active": isActive,
|
|
29
|
+
...restProps,
|
|
30
|
+
});
|
|
31
|
+
</script>
|
|
32
|
+
|
|
33
|
+
{#if child}
|
|
34
|
+
{@render child({ props: mergedProps })}
|
|
35
|
+
{:else}
|
|
36
|
+
<a bind:this={ref} {...mergedProps}>
|
|
37
|
+
{@render children?.()}
|
|
38
|
+
</a>
|
|
39
|
+
{/if}
|
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { cn } from '../../../utils.js';
|
|
3
|
-
import StarHalfIcon from '@lucide/svelte/icons/star-half';
|
|
4
|
-
import StarIcon from '@lucide/svelte/icons/star';
|
|
5
|
-
import { RatingGroup } from 'bits-ui';
|
|
6
|
-
import type { StarRatingStarProps } from './types';
|
|
7
|
-
|
|
8
|
-
let { index, state, class: className }: StarRatingStarProps = $props();
|
|
9
|
-
</script>
|
|
10
|
-
|
|
11
|
-
<RatingGroup.Item
|
|
12
|
-
{index}
|
|
13
|
-
class={cn(
|
|
14
|
-
'ring-ring text-primary ring-offset-background group/item size-5 rounded-md ring-offset-2 outline-hidden group-aria-disabled:opacity-50 focus-visible:ring-2',
|
|
15
|
-
className
|
|
16
|
-
)}
|
|
17
|
-
>
|
|
18
|
-
<div class="relative size-full">
|
|
19
|
-
<StarIcon
|
|
20
|
-
class={cn('size-full fill-transparent transition-all', {
|
|
21
|
-
'fill-current': state === 'active'
|
|
22
|
-
})}
|
|
23
|
-
/>
|
|
24
|
-
<StarHalfIcon
|
|
25
|
-
class={cn(
|
|
26
|
-
'absolute top-0 left-0 size-full fill-transparent transition-all group-data-[state=active]/item:fill-current',
|
|
27
|
-
{
|
|
28
|
-
'ltr:fill-current': state === 'partial'
|
|
29
|
-
}
|
|
30
|
-
)}
|
|
31
|
-
/>
|
|
32
|
-
<StarHalfIcon
|
|
33
|
-
class={cn(
|
|
34
|
-
'absolute top-0 right-0 size-full scale-x-[-1] fill-transparent transition-all group-data-[state=active]/item:fill-current',
|
|
35
|
-
{
|
|
36
|
-
'rtl:fill-current': state === 'partial'
|
|
37
|
-
}
|
|
38
|
-
)}
|
|
39
|
-
/>
|
|
40
|
-
</div>
|
|
41
|
-
</RatingGroup.Item>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { cn } from '../../../utils.js';
|
|
3
|
+
import StarHalfIcon from '@lucide/svelte/icons/star-half';
|
|
4
|
+
import StarIcon from '@lucide/svelte/icons/star';
|
|
5
|
+
import { RatingGroup } from 'bits-ui';
|
|
6
|
+
import type { StarRatingStarProps } from './types';
|
|
7
|
+
|
|
8
|
+
let { index, state, class: className }: StarRatingStarProps = $props();
|
|
9
|
+
</script>
|
|
10
|
+
|
|
11
|
+
<RatingGroup.Item
|
|
12
|
+
{index}
|
|
13
|
+
class={cn(
|
|
14
|
+
'ring-ring text-primary ring-offset-background group/item size-5 rounded-md ring-offset-2 outline-hidden group-aria-disabled:opacity-50 focus-visible:ring-2',
|
|
15
|
+
className
|
|
16
|
+
)}
|
|
17
|
+
>
|
|
18
|
+
<div class="relative size-full">
|
|
19
|
+
<StarIcon
|
|
20
|
+
class={cn('size-full fill-transparent transition-all', {
|
|
21
|
+
'fill-current': state === 'active'
|
|
22
|
+
})}
|
|
23
|
+
/>
|
|
24
|
+
<StarHalfIcon
|
|
25
|
+
class={cn(
|
|
26
|
+
'absolute top-0 left-0 size-full fill-transparent transition-all group-data-[state=active]/item:fill-current',
|
|
27
|
+
{
|
|
28
|
+
'ltr:fill-current': state === 'partial'
|
|
29
|
+
}
|
|
30
|
+
)}
|
|
31
|
+
/>
|
|
32
|
+
<StarHalfIcon
|
|
33
|
+
class={cn(
|
|
34
|
+
'absolute top-0 right-0 size-full scale-x-[-1] fill-transparent transition-all group-data-[state=active]/item:fill-current',
|
|
35
|
+
{
|
|
36
|
+
'rtl:fill-current': state === 'partial'
|
|
37
|
+
}
|
|
38
|
+
)}
|
|
39
|
+
/>
|
|
40
|
+
</div>
|
|
41
|
+
</RatingGroup.Item>
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { cn } from '../../../utils.js';
|
|
3
|
-
import { RatingGroup, type RatingGroupRootProps } from 'bits-ui';
|
|
4
|
-
|
|
5
|
-
let {
|
|
6
|
-
value = $bindable(0),
|
|
7
|
-
max = 5,
|
|
8
|
-
orientation = 'horizontal',
|
|
9
|
-
class: className,
|
|
10
|
-
...rest
|
|
11
|
-
}: RatingGroupRootProps = $props();
|
|
12
|
-
</script>
|
|
13
|
-
|
|
14
|
-
<RatingGroup.Root
|
|
15
|
-
class={cn('group flex w-fit place-items-center gap-1 rounded-md outline-hidden', className)}
|
|
16
|
-
bind:value
|
|
17
|
-
{max}
|
|
18
|
-
{orientation}
|
|
19
|
-
{...rest}
|
|
20
|
-
/>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { cn } from '../../../utils.js';
|
|
3
|
+
import { RatingGroup, type RatingGroupRootProps } from 'bits-ui';
|
|
4
|
+
|
|
5
|
+
let {
|
|
6
|
+
value = $bindable(0),
|
|
7
|
+
max = 5,
|
|
8
|
+
orientation = 'horizontal',
|
|
9
|
+
class: className,
|
|
10
|
+
...rest
|
|
11
|
+
}: RatingGroupRootProps = $props();
|
|
12
|
+
</script>
|
|
13
|
+
|
|
14
|
+
<RatingGroup.Root
|
|
15
|
+
class={cn('group flex w-fit place-items-center gap-1 rounded-md outline-hidden', className)}
|
|
16
|
+
bind:value
|
|
17
|
+
{max}
|
|
18
|
+
{orientation}
|
|
19
|
+
{...rest}
|
|
20
|
+
/>
|
|
@@ -1,15 +1,15 @@
|
|
|
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<HTMLTableSectionElement>> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<tbody bind:this={ref} data-slot="table-body" class={cn("[&_tr:last-child]:border-0", className)} {...restProps}>
|
|
14
|
-
{@render children?.()}
|
|
15
|
-
</tbody>
|
|
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<HTMLTableSectionElement>> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<tbody bind:this={ref} data-slot="table-body" class={cn("[&_tr:last-child]:border-0", className)} {...restProps}>
|
|
14
|
+
{@render children?.()}
|
|
15
|
+
</tbody>
|
|
@@ -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<HTMLElement>> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<caption
|
|
14
|
-
bind:this={ref}
|
|
15
|
-
data-slot="table-caption"
|
|
16
|
-
class={cn("text-muted-foreground mt-4 text-sm", className)}
|
|
17
|
-
{...restProps}
|
|
18
|
-
>
|
|
19
|
-
{@render children?.()}
|
|
20
|
-
</caption>
|
|
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<HTMLElement>> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<caption
|
|
14
|
+
bind:this={ref}
|
|
15
|
+
data-slot="table-caption"
|
|
16
|
+
class={cn("text-muted-foreground mt-4 text-sm", className)}
|
|
17
|
+
{...restProps}
|
|
18
|
+
>
|
|
19
|
+
{@render children?.()}
|
|
20
|
+
</caption>
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { cn, type WithElementRef } from "../../../utils.js";
|
|
3
|
-
import type { HTMLTdAttributes } from "svelte/elements";
|
|
4
|
-
|
|
5
|
-
let {
|
|
6
|
-
ref = $bindable(null),
|
|
7
|
-
class: className,
|
|
8
|
-
children,
|
|
9
|
-
...restProps
|
|
10
|
-
}: WithElementRef<HTMLTdAttributes> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<td bind:this={ref} data-slot="table-cell" class={cn("p-3 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0", className)} {...restProps}>
|
|
14
|
-
{@render children?.()}
|
|
15
|
-
</td>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { cn, type WithElementRef } from "../../../utils.js";
|
|
3
|
+
import type { HTMLTdAttributes } from "svelte/elements";
|
|
4
|
+
|
|
5
|
+
let {
|
|
6
|
+
ref = $bindable(null),
|
|
7
|
+
class: className,
|
|
8
|
+
children,
|
|
9
|
+
...restProps
|
|
10
|
+
}: WithElementRef<HTMLTdAttributes> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<td bind:this={ref} data-slot="table-cell" class={cn("p-3 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0", className)} {...restProps}>
|
|
14
|
+
{@render children?.()}
|
|
15
|
+
</td>
|
|
@@ -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<HTMLTableSectionElement>> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<tfoot
|
|
14
|
-
bind:this={ref}
|
|
15
|
-
data-slot="table-footer"
|
|
16
|
-
class={cn("bg-muted/50 border-t font-medium [&>tr]:last:border-b-0", className)}
|
|
17
|
-
{...restProps}
|
|
18
|
-
>
|
|
19
|
-
{@render children?.()}
|
|
20
|
-
</tfoot>
|
|
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<HTMLTableSectionElement>> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<tfoot
|
|
14
|
+
bind:this={ref}
|
|
15
|
+
data-slot="table-footer"
|
|
16
|
+
class={cn("bg-muted/50 border-t font-medium [&>tr]:last:border-b-0", className)}
|
|
17
|
+
{...restProps}
|
|
18
|
+
>
|
|
19
|
+
{@render children?.()}
|
|
20
|
+
</tfoot>
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { cn, type WithElementRef } from "../../../utils.js";
|
|
3
|
-
import type { HTMLThAttributes } from "svelte/elements";
|
|
4
|
-
|
|
5
|
-
let {
|
|
6
|
-
ref = $bindable(null),
|
|
7
|
-
class: className,
|
|
8
|
-
children,
|
|
9
|
-
...restProps
|
|
10
|
-
}: WithElementRef<HTMLThAttributes> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<th bind:this={ref} data-slot="table-head" class={cn("text-foreground h-12 px-3 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0", className)} {...restProps}>
|
|
14
|
-
{@render children?.()}
|
|
15
|
-
</th>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { cn, type WithElementRef } from "../../../utils.js";
|
|
3
|
+
import type { HTMLThAttributes } from "svelte/elements";
|
|
4
|
+
|
|
5
|
+
let {
|
|
6
|
+
ref = $bindable(null),
|
|
7
|
+
class: className,
|
|
8
|
+
children,
|
|
9
|
+
...restProps
|
|
10
|
+
}: WithElementRef<HTMLThAttributes> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<th bind:this={ref} data-slot="table-head" class={cn("text-foreground h-12 px-3 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0", className)} {...restProps}>
|
|
14
|
+
{@render children?.()}
|
|
15
|
+
</th>
|
|
@@ -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<HTMLTableSectionElement>> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<thead
|
|
14
|
-
bind:this={ref}
|
|
15
|
-
data-slot="table-header"
|
|
16
|
-
class={cn("[&_tr]:border-b", className)}
|
|
17
|
-
{...restProps}
|
|
18
|
-
>
|
|
19
|
-
{@render children?.()}
|
|
20
|
-
</thead>
|
|
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<HTMLTableSectionElement>> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<thead
|
|
14
|
+
bind:this={ref}
|
|
15
|
+
data-slot="table-header"
|
|
16
|
+
class={cn("[&_tr]:border-b", className)}
|
|
17
|
+
{...restProps}
|
|
18
|
+
>
|
|
19
|
+
{@render children?.()}
|
|
20
|
+
</thead>
|
|
@@ -1,15 +1,15 @@
|
|
|
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<HTMLTableRowElement>> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<tr bind:this={ref} data-slot="table-row" class={cn("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors", className)} {...restProps}>
|
|
14
|
-
{@render children?.()}
|
|
15
|
-
</tr>
|
|
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<HTMLTableRowElement>> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<tr bind:this={ref} data-slot="table-row" class={cn("hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors", className)} {...restProps}>
|
|
14
|
+
{@render children?.()}
|
|
15
|
+
</tr>
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import type { HTMLTableAttributes } 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<HTMLTableAttributes> = $props();
|
|
11
|
-
</script>
|
|
12
|
-
|
|
13
|
-
<div data-slot="table-container" class="relative w-full overflow-x-auto">
|
|
14
|
-
<table bind:this={ref} data-slot="table" class={cn("w-full caption-bottom text-sm", className)} {...restProps}>
|
|
15
|
-
{@render children?.()}
|
|
16
|
-
</table>
|
|
17
|
-
</div>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import type { HTMLTableAttributes } 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<HTMLTableAttributes> = $props();
|
|
11
|
+
</script>
|
|
12
|
+
|
|
13
|
+
<div data-slot="table-container" class="relative w-full overflow-x-auto">
|
|
14
|
+
<table bind:this={ref} data-slot="table" class={cn("w-full caption-bottom text-sm", className)} {...restProps}>
|
|
15
|
+
{@render children?.()}
|
|
16
|
+
</table>
|
|
17
|
+
</div>
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import { Tabs as TabsPrimitive } from "bits-ui";
|
|
3
|
-
import { cn } from "../../../utils.js";
|
|
4
|
-
|
|
5
|
-
let {
|
|
6
|
-
ref = $bindable(null),
|
|
7
|
-
class: className,
|
|
8
|
-
...restProps
|
|
9
|
-
}: TabsPrimitive.ContentProps = $props();
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<TabsPrimitive.Content
|
|
13
|
-
bind:ref
|
|
14
|
-
data-slot="tabs-content"
|
|
15
|
-
class={cn("text-sm flex-1 outline-none", className)}
|
|
16
|
-
{...restProps}
|
|
17
|
-
/>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { Tabs as TabsPrimitive } from "bits-ui";
|
|
3
|
+
import { cn } from "../../../utils.js";
|
|
4
|
+
|
|
5
|
+
let {
|
|
6
|
+
ref = $bindable(null),
|
|
7
|
+
class: className,
|
|
8
|
+
...restProps
|
|
9
|
+
}: TabsPrimitive.ContentProps = $props();
|
|
10
|
+
</script>
|
|
11
|
+
|
|
12
|
+
<TabsPrimitive.Content
|
|
13
|
+
bind:ref
|
|
14
|
+
data-slot="tabs-content"
|
|
15
|
+
class={cn("text-sm flex-1 outline-none", className)}
|
|
16
|
+
{...restProps}
|
|
17
|
+
/>
|