@devalok/shilp-sutra 0.17.2 → 0.18.1
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/_chunks/framer.js +1376 -0
- package/dist/_chunks/link-context.js +19 -0
- package/dist/_chunks/motion-provider.js +24 -0
- package/dist/_chunks/primitives.js +3499 -3920
- package/dist/_chunks/tiptap.js +1 -1
- package/dist/_chunks/tree-view.js +183 -181
- package/dist/_chunks/use-calendar.js +531 -515
- package/dist/_chunks/vendor-client.js +1792 -1049
- package/dist/_chunks/vendor-utils.js +5123 -1169
- package/dist/composed/activity-feed.d.ts.map +1 -1
- package/dist/composed/activity-feed.js +75 -78
- package/dist/composed/avatar-group.js +33 -33
- package/dist/composed/command-palette.d.ts +1 -1
- package/dist/composed/command-palette.d.ts.map +1 -1
- package/dist/composed/command-palette.js +207 -158
- package/dist/composed/confirm-dialog.d.ts +3 -5
- package/dist/composed/confirm-dialog.d.ts.map +1 -1
- package/dist/composed/confirm-dialog.js +47 -42
- package/dist/composed/content-card.d.ts +1 -1
- package/dist/composed/content-card.js +30 -30
- package/dist/composed/date-picker/calendar-grid.d.ts +1 -1
- package/dist/composed/date-picker/calendar-grid.d.ts.map +1 -1
- package/dist/composed/date-picker/date-picker.d.ts +1 -1
- package/dist/composed/date-picker/date-picker.d.ts.map +1 -1
- package/dist/composed/date-picker/date-range-picker.d.ts +1 -1
- package/dist/composed/date-picker/date-range-picker.d.ts.map +1 -1
- package/dist/composed/date-picker/date-time-picker.d.ts +1 -1
- package/dist/composed/date-picker/date-time-picker.d.ts.map +1 -1
- package/dist/composed/date-picker/month-picker.d.ts +1 -1
- package/dist/composed/date-picker/month-picker.d.ts.map +1 -1
- package/dist/composed/date-picker/presets.d.ts +1 -1
- package/dist/composed/date-picker/presets.d.ts.map +1 -1
- package/dist/composed/date-picker/time-picker.d.ts +1 -1
- package/dist/composed/date-picker/time-picker.d.ts.map +1 -1
- package/dist/composed/date-picker/year-picker.d.ts +1 -1
- package/dist/composed/date-picker/year-picker.d.ts.map +1 -1
- package/dist/composed/empty-state.d.ts +1 -0
- package/dist/composed/empty-state.d.ts.map +1 -1
- package/dist/composed/empty-state.js +51 -47
- package/dist/composed/error-boundary.d.ts +1 -1
- package/dist/composed/error-boundary.d.ts.map +1 -1
- package/dist/composed/error-boundary.js +48 -48
- package/dist/composed/extensions/mention-suggestion.d.ts +1 -1
- package/dist/composed/extensions/mention-suggestion.d.ts.map +1 -1
- package/dist/composed/global-loading.d.ts +1 -1
- package/dist/composed/global-loading.d.ts.map +1 -1
- package/dist/composed/global-loading.js +22 -19
- package/dist/composed/index.d.ts +2 -4
- package/dist/composed/index.d.ts.map +1 -1
- package/dist/composed/index.js +26 -29
- package/dist/composed/lib/string-utils.d.ts +0 -1
- package/dist/composed/lib/string-utils.js +0 -1
- package/dist/composed/loading-skeleton.d.ts +1 -1
- package/dist/composed/loading-skeleton.d.ts.map +1 -1
- package/dist/composed/loading-skeleton.js +92 -87
- package/dist/composed/member-picker.d.ts +1 -1
- package/dist/composed/member-picker.d.ts.map +1 -1
- package/dist/composed/member-picker.js +47 -43
- package/dist/composed/page-header.js +36 -36
- package/dist/composed/page-skeletons.d.ts +9 -3
- package/dist/composed/page-skeletons.d.ts.map +1 -1
- package/dist/composed/page-skeletons.js +58 -58
- package/dist/composed/priority-indicator.js +24 -24
- package/dist/composed/rich-text-editor.d.ts +3 -3
- package/dist/composed/rich-text-editor.d.ts.map +1 -1
- package/dist/composed/rich-text-editor.js +317 -310
- package/dist/composed/schedule-view.js +84 -84
- package/dist/composed/simple-tooltip.d.ts +2 -5
- package/dist/composed/simple-tooltip.d.ts.map +1 -1
- package/dist/composed/simple-tooltip.js +19 -14
- package/dist/composed/status-badge.d.ts +2 -1
- package/dist/composed/status-badge.d.ts.map +1 -1
- package/dist/composed/status-badge.js +81 -68
- package/dist/hooks/index.d.ts +2 -1
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/index.js +3 -4
- package/dist/hooks/use-toast.d.ts +15 -45
- package/dist/hooks/use-toast.d.ts.map +1 -1
- package/dist/hooks/use-toast.js +2 -95
- package/dist/motion/index.d.ts +4 -0
- package/dist/motion/index.d.ts.map +1 -0
- package/dist/motion/index.js +12 -0
- package/dist/motion/motion-provider.d.ts +18 -0
- package/dist/motion/motion-provider.d.ts.map +1 -0
- package/dist/motion/primitives-index.d.ts +3 -0
- package/dist/motion/primitives-index.d.ts.map +1 -0
- package/dist/motion/primitives-index.js +187 -0
- package/dist/motion/primitives.d.ts +38 -0
- package/dist/motion/primitives.d.ts.map +1 -0
- package/dist/shell/app-command-palette.d.ts +14 -5
- package/dist/shell/app-command-palette.d.ts.map +1 -1
- package/dist/shell/app-command-palette.js +152 -130
- package/dist/shell/bottom-navbar.d.ts.map +1 -1
- package/dist/shell/bottom-navbar.js +90 -92
- package/dist/shell/command-registry.d.ts +23 -0
- package/dist/shell/command-registry.d.ts.map +1 -0
- package/dist/shell/command-registry.js +18 -0
- package/dist/shell/index.d.ts +2 -1
- package/dist/shell/index.d.ts.map +1 -1
- package/dist/shell/index.js +14 -11
- package/dist/shell/link-context.d.ts +6 -10
- package/dist/shell/link-context.d.ts.map +1 -1
- package/dist/shell/link-context.js +3 -16
- package/dist/shell/notification-center.d.ts.map +1 -1
- package/dist/shell/notification-center.js +129 -124
- package/dist/shell/notification-preferences.d.ts +10 -5
- package/dist/shell/notification-preferences.d.ts.map +1 -1
- package/dist/shell/notification-preferences.js +169 -165
- package/dist/shell/sidebar.js +104 -104
- package/dist/shell/top-bar.js +67 -67
- package/dist/tailwind/index.cjs +118 -297
- package/dist/tailwind/preset.d.ts.map +1 -1
- package/dist/tailwind/preset.js +118 -297
- package/dist/tokens/generate-scale.d.ts +86 -0
- package/dist/tokens/generate-scale.d.ts.map +1 -0
- package/dist/tokens/primitives.css +415 -187
- package/dist/tokens/semantic.css +244 -270
- package/dist/tokens/typography.css +6 -6
- package/dist/ui/accordion.d.ts.map +1 -1
- package/dist/ui/accordion.js +34 -24
- package/dist/ui/alert-dialog.d.ts +4 -1
- package/dist/ui/alert-dialog.d.ts.map +1 -1
- package/dist/ui/alert-dialog.js +115 -74
- package/dist/ui/alert.d.ts +6 -1
- package/dist/ui/alert.d.ts.map +1 -1
- package/dist/ui/alert.js +65 -50
- package/dist/ui/aspect-ratio.d.ts +2 -1
- package/dist/ui/aspect-ratio.d.ts.map +1 -1
- package/dist/ui/aspect-ratio.js +14 -4
- package/dist/ui/autocomplete.d.ts +11 -2
- package/dist/ui/autocomplete.d.ts.map +1 -1
- package/dist/ui/autocomplete.js +85 -60
- package/dist/ui/avatar.d.ts.map +1 -1
- package/dist/ui/avatar.js +46 -35
- package/dist/ui/badge.d.ts +1 -1
- package/dist/ui/badge.d.ts.map +1 -1
- package/dist/ui/badge.js +72 -67
- package/dist/ui/banner.d.ts.map +1 -1
- package/dist/ui/banner.js +54 -40
- package/dist/ui/breadcrumb.d.ts +2 -0
- package/dist/ui/breadcrumb.d.ts.map +1 -1
- package/dist/ui/breadcrumb.js +19 -19
- package/dist/ui/button-group.js +4 -4
- package/dist/ui/button.d.ts +10 -1
- package/dist/ui/button.d.ts.map +1 -1
- package/dist/ui/button.js +102 -66
- package/dist/ui/card.d.ts +2 -2
- package/dist/ui/card.d.ts.map +1 -1
- package/dist/ui/card.js +61 -53
- package/dist/ui/charts/_internal/animation.d.ts +1 -1
- package/dist/ui/charts/_internal/animation.d.ts.map +1 -1
- package/dist/ui/charts/area-chart.d.ts +3 -5
- package/dist/ui/charts/area-chart.d.ts.map +1 -1
- package/dist/ui/charts/bar-chart.d.ts +3 -5
- package/dist/ui/charts/bar-chart.d.ts.map +1 -1
- package/dist/ui/charts/chart-container.d.ts +2 -5
- package/dist/ui/charts/chart-container.d.ts.map +1 -1
- package/dist/ui/charts/gauge-chart.d.ts +3 -5
- package/dist/ui/charts/gauge-chart.d.ts.map +1 -1
- package/dist/ui/charts/index.js +1204 -1095
- package/dist/ui/charts/line-chart.d.ts +3 -5
- package/dist/ui/charts/line-chart.d.ts.map +1 -1
- package/dist/ui/charts/pie-chart.d.ts +2 -5
- package/dist/ui/charts/pie-chart.d.ts.map +1 -1
- package/dist/ui/charts/radar-chart.d.ts +3 -5
- package/dist/ui/charts/radar-chart.d.ts.map +1 -1
- package/dist/ui/charts/sparkline.d.ts +5 -5
- package/dist/ui/charts/sparkline.d.ts.map +1 -1
- package/dist/ui/checkbox.d.ts.map +1 -1
- package/dist/ui/checkbox.js +31 -19
- package/dist/ui/chip.d.ts +3 -2
- package/dist/ui/chip.d.ts.map +1 -1
- package/dist/ui/chip.js +58 -50
- package/dist/ui/code.js +16 -16
- package/dist/ui/collapsible.d.ts.map +1 -1
- package/dist/ui/collapsible.js +23 -15
- package/dist/ui/color-input.d.ts +1 -1
- package/dist/ui/color-input.d.ts.map +1 -1
- package/dist/ui/color-input.js +27 -27
- package/dist/ui/combobox.d.ts +2 -0
- package/dist/ui/combobox.d.ts.map +1 -1
- package/dist/ui/combobox.js +177 -166
- package/dist/ui/container.js +4 -4
- package/dist/ui/context-menu.d.ts +4 -2
- package/dist/ui/context-menu.d.ts.map +1 -1
- package/dist/ui/context-menu.js +147 -87
- package/dist/ui/data-table-toolbar.d.ts +3 -2
- package/dist/ui/data-table-toolbar.d.ts.map +1 -1
- package/dist/ui/data-table-toolbar.js +65 -63
- package/dist/ui/data-table.d.ts.map +1 -1
- package/dist/ui/data-table.js +275 -240
- package/dist/ui/dialog.d.ts +3 -1
- package/dist/ui/dialog.d.ts.map +1 -1
- package/dist/ui/dialog.js +114 -74
- package/dist/ui/dropdown-menu.d.ts +5 -3
- package/dist/ui/dropdown-menu.d.ts.map +1 -1
- package/dist/ui/dropdown-menu.js +151 -90
- package/dist/ui/file-upload.d.ts.map +1 -1
- package/dist/ui/file-upload.js +170 -128
- package/dist/ui/form.d.ts.map +1 -1
- package/dist/ui/form.js +30 -27
- package/dist/ui/hover-card.d.ts +1 -1
- package/dist/ui/hover-card.d.ts.map +1 -1
- package/dist/ui/hover-card.js +53 -21
- package/dist/ui/icon-button.js +9 -9
- package/dist/ui/index.d.ts +18 -18
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/index.js +322 -533
- package/dist/ui/input-otp.d.ts +2 -0
- package/dist/ui/input-otp.d.ts.map +1 -1
- package/dist/ui/input-otp.js +8 -8
- package/dist/ui/input.d.ts.map +1 -1
- package/dist/ui/input.js +35 -33
- package/dist/ui/label.js +12 -12
- package/dist/ui/lib/date-utils.d.ts +5 -0
- package/dist/ui/lib/date-utils.d.ts.map +1 -0
- package/dist/ui/lib/date-utils.js +12 -0
- package/dist/ui/lib/index.d.ts +7 -0
- package/dist/ui/lib/index.d.ts.map +1 -0
- package/dist/ui/lib/link-context.d.ts +13 -0
- package/dist/ui/lib/link-context.d.ts.map +1 -0
- package/dist/ui/lib/motion.d.ts +44 -9
- package/dist/ui/lib/motion.d.ts.map +1 -1
- package/dist/ui/lib/motion.js +34 -0
- package/dist/ui/lib/use-ripple.d.ts.map +1 -1
- package/dist/ui/lib/utils.js +1 -1
- package/dist/ui/link.js +11 -11
- package/dist/ui/menubar.d.ts +4 -2
- package/dist/ui/menubar.d.ts.map +1 -1
- package/dist/ui/menubar.js +142 -98
- package/dist/ui/navigation-menu.d.ts +2 -0
- package/dist/ui/navigation-menu.d.ts.map +1 -1
- package/dist/ui/navigation-menu.js +176 -73
- package/dist/ui/number-input.d.ts.map +1 -1
- package/dist/ui/number-input.js +58 -51
- package/dist/ui/pagination.js +23 -23
- package/dist/ui/popover.d.ts +2 -1
- package/dist/ui/popover.d.ts.map +1 -1
- package/dist/ui/popover.js +54 -22
- package/dist/ui/progress.d.ts.map +1 -1
- package/dist/ui/progress.js +58 -42
- package/dist/ui/radio.js +15 -15
- package/dist/ui/search-input.d.ts.map +1 -1
- package/dist/ui/search-input.js +28 -33
- package/dist/ui/segmented-control.d.ts +4 -2
- package/dist/ui/segmented-control.d.ts.map +1 -1
- package/dist/ui/segmented-control.js +146 -123
- package/dist/ui/select.d.ts.map +1 -1
- package/dist/ui/select.js +75 -64
- package/dist/ui/separator.js +12 -12
- package/dist/ui/sheet.d.ts +1 -1
- package/dist/ui/sheet.d.ts.map +1 -1
- package/dist/ui/sheet.js +111 -75
- package/dist/ui/sidebar.d.ts +6 -1
- package/dist/ui/sidebar.d.ts.map +1 -1
- package/dist/ui/sidebar.js +574 -36
- package/dist/ui/skeleton.js +2 -2
- package/dist/ui/slider.d.ts +9 -0
- package/dist/ui/slider.d.ts.map +1 -1
- package/dist/ui/slider.js +33 -27
- package/dist/ui/spinner.d.ts +32 -25
- package/dist/ui/spinner.d.ts.map +1 -1
- package/dist/ui/spinner.js +199 -40
- package/dist/ui/stack.js +1 -1
- package/dist/ui/stat-card.d.ts.map +1 -1
- package/dist/ui/stat-card.js +181 -114
- package/dist/ui/stepper.d.ts +23 -4
- package/dist/ui/stepper.d.ts.map +1 -1
- package/dist/ui/stepper.js +126 -48
- package/dist/ui/switch.d.ts.map +1 -1
- package/dist/ui/switch.js +39 -26
- package/dist/ui/table.d.ts +3 -0
- package/dist/ui/table.d.ts.map +1 -1
- package/dist/ui/table.js +29 -29
- package/dist/ui/tabs.d.ts +4 -1
- package/dist/ui/tabs.d.ts.map +1 -1
- package/dist/ui/tabs.js +94 -44
- package/dist/ui/text.d.ts +3 -3
- package/dist/ui/text.js +2 -2
- package/dist/ui/textarea.d.ts.map +1 -1
- package/dist/ui/textarea.js +27 -25
- package/dist/ui/toast-types.d.ts +43 -0
- package/dist/ui/toast-types.d.ts.map +1 -0
- package/dist/ui/toast-types.js +2 -0
- package/dist/ui/toast.d.ts +60 -26
- package/dist/ui/toast.d.ts.map +1 -1
- package/dist/ui/toast.js +535 -89
- package/dist/ui/toaster.d.ts +19 -23
- package/dist/ui/toaster.d.ts.map +1 -1
- package/dist/ui/toaster.js +31 -21
- package/dist/ui/toggle-group.d.ts +2 -2
- package/dist/ui/toggle-group.d.ts.map +1 -1
- package/dist/ui/toggle-group.js +29 -26
- package/dist/ui/toggle.d.ts +2 -2
- package/dist/ui/toggle.d.ts.map +1 -1
- package/dist/ui/toggle.js +21 -17
- package/dist/ui/tooltip.d.ts +2 -1
- package/dist/ui/tooltip.d.ts.map +1 -1
- package/dist/ui/tooltip.js +58 -21
- package/dist/ui/tree-view/tree-view.d.ts +1 -1
- package/dist/ui/tree-view/tree-view.d.ts.map +1 -1
- package/dist/ui/visually-hidden.js +3 -3
- package/llms-full.txt +3440 -1528
- package/llms.txt +67 -14
- package/package.json +50 -9
- package/dist/_chunks/avatar.js +0 -50
- package/dist/_chunks/button.js +0 -95
- package/dist/_chunks/checkbox.js +0 -14
- package/dist/_chunks/form.js +0 -27
- package/dist/_chunks/sidebar.js +0 -592
- package/dist/_chunks/spinner.js +0 -34
- package/dist/_chunks/switch.js +0 -10
- package/dist/_chunks/tooltip.js +0 -13
- package/dist/_chunks/utils.js +0 -17
- package/dist/composed/upload-progress.d.ts +0 -33
- package/dist/composed/upload-progress.d.ts.map +0 -1
- package/dist/composed/upload-progress.js +0 -386
- package/dist/ui/lib/use-reduced-motion.d.ts +0 -4
- package/dist/ui/lib/use-reduced-motion.d.ts.map +0 -1
- package/dist/ui/transitions.d.ts +0 -17
- package/dist/ui/transitions.d.ts.map +0 -1
- package/dist/ui/transitions.js +0 -111
package/dist/ui/sidebar.js
CHANGED
|
@@ -1,39 +1,577 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import "react/jsx-runtime";
|
|
3
|
-
import "../_chunks/primitives.js";
|
|
4
|
-
import "../_chunks/vendor-utils.js";
|
|
5
|
-
import "@tabler/icons-react";
|
|
6
|
-
import "../hooks/use-mobile.js";
|
|
7
|
-
import "
|
|
8
|
-
import "
|
|
9
|
-
import {
|
|
10
|
-
import "./
|
|
11
|
-
import "./
|
|
12
|
-
import "
|
|
13
|
-
import "
|
|
2
|
+
import { jsx as s, jsxs as h, Fragment as E } from "react/jsx-runtime";
|
|
3
|
+
import { S as v } from "../_chunks/primitives.js";
|
|
4
|
+
import { ag as T } from "../_chunks/vendor-utils.js";
|
|
5
|
+
import { IconLayoutSidebarLeftCollapse as A } from "@tabler/icons-react";
|
|
6
|
+
import { useIsMobile as D } from "../hooks/use-mobile.js";
|
|
7
|
+
import { springs as O } from "./lib/motion.js";
|
|
8
|
+
import { cn as r } from "./lib/utils.js";
|
|
9
|
+
import { Button as R } from "./button.js";
|
|
10
|
+
import { Input as G } from "./input.js";
|
|
11
|
+
import { Separator as L } from "./separator.js";
|
|
12
|
+
import { Sheet as H, SheetContent as K } from "./sheet.js";
|
|
13
|
+
import { Skeleton as _ } from "./skeleton.js";
|
|
14
|
+
import { TooltipProvider as j, Tooltip as $, TooltipTrigger as F, TooltipContent as P } from "./tooltip.js";
|
|
15
|
+
import { createContext as V, forwardRef as i, useState as I, useCallback as C, useEffect as W, useMemo as k, useContext as q } from "react";
|
|
16
|
+
import { m as U } from "../_chunks/framer.js";
|
|
17
|
+
const X = "sidebar:state", Y = 60 * 60 * 24 * 7, J = "16rem", Q = "18rem", Z = "3rem", ee = "b", z = V(null);
|
|
18
|
+
function N() {
|
|
19
|
+
const a = q(z);
|
|
20
|
+
if (!a)
|
|
21
|
+
throw new Error("useSidebar must be used within a SidebarProvider.");
|
|
22
|
+
return a;
|
|
23
|
+
}
|
|
24
|
+
const ae = i(
|
|
25
|
+
({
|
|
26
|
+
defaultOpen: a = !0,
|
|
27
|
+
open: e,
|
|
28
|
+
onOpenChange: t,
|
|
29
|
+
className: d,
|
|
30
|
+
style: o,
|
|
31
|
+
children: n,
|
|
32
|
+
...u
|
|
33
|
+
}, f) => {
|
|
34
|
+
const c = D(), [b, m] = I(!1), [y, x] = I(a), g = e ?? y, S = C(
|
|
35
|
+
(l) => {
|
|
36
|
+
const p = typeof l == "function" ? l(g) : l;
|
|
37
|
+
t ? t(p) : x(p), document.cookie = `${X}=${p}; path=/; max-age=${Y}`;
|
|
38
|
+
},
|
|
39
|
+
[t, g]
|
|
40
|
+
), w = C(() => c ? m((l) => !l) : S((l) => !l), [c, S, m]);
|
|
41
|
+
W(() => {
|
|
42
|
+
const l = (p) => {
|
|
43
|
+
p.key === ee && (p.metaKey || p.ctrlKey) && (p.preventDefault(), w());
|
|
44
|
+
};
|
|
45
|
+
return window.addEventListener("keydown", l), () => window.removeEventListener("keydown", l);
|
|
46
|
+
}, [w]);
|
|
47
|
+
const M = g ? "expanded" : "collapsed", B = k(
|
|
48
|
+
() => ({
|
|
49
|
+
state: M,
|
|
50
|
+
open: g,
|
|
51
|
+
setOpen: S,
|
|
52
|
+
isMobile: c,
|
|
53
|
+
openMobile: b,
|
|
54
|
+
setOpenMobile: m,
|
|
55
|
+
toggleSidebar: w
|
|
56
|
+
}),
|
|
57
|
+
[
|
|
58
|
+
M,
|
|
59
|
+
g,
|
|
60
|
+
S,
|
|
61
|
+
c,
|
|
62
|
+
b,
|
|
63
|
+
m,
|
|
64
|
+
w
|
|
65
|
+
]
|
|
66
|
+
);
|
|
67
|
+
return /* @__PURE__ */ s(z.Provider, { value: B, children: /* @__PURE__ */ s(j, { delayDuration: 0, children: /* @__PURE__ */ s(
|
|
68
|
+
"div",
|
|
69
|
+
{
|
|
70
|
+
style: {
|
|
71
|
+
"--sidebar-width": J,
|
|
72
|
+
"--sidebar-width-icon": Z,
|
|
73
|
+
...o
|
|
74
|
+
},
|
|
75
|
+
className: r(
|
|
76
|
+
"group/sidebar-wrapper flex min-h-svh has-[[data-variant=inset]]:bg-surface-1",
|
|
77
|
+
d
|
|
78
|
+
),
|
|
79
|
+
ref: f,
|
|
80
|
+
...u,
|
|
81
|
+
children: n
|
|
82
|
+
}
|
|
83
|
+
) }) });
|
|
84
|
+
}
|
|
85
|
+
);
|
|
86
|
+
ae.displayName = "SidebarProvider";
|
|
87
|
+
const te = i(
|
|
88
|
+
({
|
|
89
|
+
side: a = "left",
|
|
90
|
+
variant: e = "sidebar",
|
|
91
|
+
collapsible: t = "offcanvas",
|
|
92
|
+
className: d,
|
|
93
|
+
children: o,
|
|
94
|
+
...n
|
|
95
|
+
}, u) => {
|
|
96
|
+
const { isMobile: f, state: c, openMobile: b, setOpenMobile: m } = N();
|
|
97
|
+
return t === "none" ? /* @__PURE__ */ s(
|
|
98
|
+
"div",
|
|
99
|
+
{
|
|
100
|
+
className: r(
|
|
101
|
+
"flex h-full w-[--sidebar-width] flex-col bg-surface-1 text-surface-fg",
|
|
102
|
+
d
|
|
103
|
+
),
|
|
104
|
+
ref: u,
|
|
105
|
+
...n,
|
|
106
|
+
children: o
|
|
107
|
+
}
|
|
108
|
+
) : f ? /* @__PURE__ */ s(H, { open: b, onOpenChange: m, ...n, children: /* @__PURE__ */ s(
|
|
109
|
+
K,
|
|
110
|
+
{
|
|
111
|
+
"data-sidebar": "sidebar",
|
|
112
|
+
"data-mobile": "true",
|
|
113
|
+
className: "w-[--sidebar-width] bg-surface-1 p-0 text-surface-fg [&>button]:hidden",
|
|
114
|
+
style: {
|
|
115
|
+
"--sidebar-width": Q
|
|
116
|
+
},
|
|
117
|
+
side: a,
|
|
118
|
+
children: /* @__PURE__ */ s("div", { className: "flex h-full w-full flex-col", children: o })
|
|
119
|
+
}
|
|
120
|
+
) }) : /* @__PURE__ */ h(
|
|
121
|
+
"div",
|
|
122
|
+
{
|
|
123
|
+
ref: u,
|
|
124
|
+
className: "group peer hidden text-surface-fg md:block",
|
|
125
|
+
"data-state": c,
|
|
126
|
+
"data-collapsible": c === "collapsed" ? t : "",
|
|
127
|
+
"data-variant": e,
|
|
128
|
+
"data-side": a,
|
|
129
|
+
children: [
|
|
130
|
+
/* @__PURE__ */ s(
|
|
131
|
+
"div",
|
|
132
|
+
{
|
|
133
|
+
className: r(
|
|
134
|
+
"relative h-svh w-[--sidebar-width] bg-transparent transition-[width] duration-moderate-02 ease-linear",
|
|
135
|
+
"group-data-[collapsible=offcanvas]:w-0",
|
|
136
|
+
"group-data-[side=right]:rotate-180",
|
|
137
|
+
e === "floating" || e === "inset" ? "group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))]" : "group-data-[collapsible=icon]:w-[--sidebar-width-icon]"
|
|
138
|
+
)
|
|
139
|
+
}
|
|
140
|
+
),
|
|
141
|
+
/* @__PURE__ */ s(
|
|
142
|
+
"div",
|
|
143
|
+
{
|
|
144
|
+
className: r(
|
|
145
|
+
"fixed inset-y-0 z-raised hidden h-svh w-[--sidebar-width] transition-[left,right,width] duration-moderate-02 ease-linear md:flex",
|
|
146
|
+
a === "left" ? "left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]" : "right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",
|
|
147
|
+
e === "floating" || e === "inset" ? "p-ds-03 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)]" : "group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l",
|
|
148
|
+
d
|
|
149
|
+
),
|
|
150
|
+
...n,
|
|
151
|
+
children: /* @__PURE__ */ s(
|
|
152
|
+
"div",
|
|
153
|
+
{
|
|
154
|
+
"data-sidebar": "sidebar",
|
|
155
|
+
className: "flex h-full w-full flex-col bg-surface-1 group-data-[variant=floating]:rounded-ds-lg group-data-[variant=floating]:border group-data-[variant=floating]:border-surface-border group-data-[variant=floating]:shadow",
|
|
156
|
+
children: o
|
|
157
|
+
}
|
|
158
|
+
)
|
|
159
|
+
}
|
|
160
|
+
)
|
|
161
|
+
]
|
|
162
|
+
}
|
|
163
|
+
);
|
|
164
|
+
}
|
|
165
|
+
);
|
|
166
|
+
te.displayName = "Sidebar";
|
|
167
|
+
const se = i(({ className: a, onClick: e, ...t }, d) => {
|
|
168
|
+
const { toggleSidebar: o } = N();
|
|
169
|
+
return /* @__PURE__ */ h(
|
|
170
|
+
R,
|
|
171
|
+
{
|
|
172
|
+
ref: d,
|
|
173
|
+
"data-sidebar": "trigger",
|
|
174
|
+
variant: "ghost",
|
|
175
|
+
size: "icon-md",
|
|
176
|
+
className: r("h-ds-xs-plus w-ds-xs-plus", a),
|
|
177
|
+
onClick: (n) => {
|
|
178
|
+
e == null || e(n), o();
|
|
179
|
+
},
|
|
180
|
+
...t,
|
|
181
|
+
children: [
|
|
182
|
+
/* @__PURE__ */ s(A, {}),
|
|
183
|
+
/* @__PURE__ */ s("span", { className: "sr-only", children: "Toggle Sidebar" })
|
|
184
|
+
]
|
|
185
|
+
}
|
|
186
|
+
);
|
|
187
|
+
});
|
|
188
|
+
se.displayName = "SidebarTrigger";
|
|
189
|
+
const re = i(
|
|
190
|
+
({ className: a, ...e }, t) => {
|
|
191
|
+
const { toggleSidebar: d } = N();
|
|
192
|
+
return /* @__PURE__ */ s(
|
|
193
|
+
"button",
|
|
194
|
+
{
|
|
195
|
+
ref: t,
|
|
196
|
+
"data-sidebar": "rail",
|
|
197
|
+
"aria-label": "Toggle Sidebar",
|
|
198
|
+
tabIndex: -1,
|
|
199
|
+
onClick: d,
|
|
200
|
+
title: "Toggle Sidebar",
|
|
201
|
+
className: r(
|
|
202
|
+
"hover:after:bg-surface-border-strong absolute inset-y-0 z-raised hidden w-4 -translate-x-1/2 transition-colors ease-linear after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] group-data-[side=left]:-right-4 group-data-[side=right]:left-0 sm:flex",
|
|
203
|
+
"[[data-side=left]_&]:cursor-w-resize [[data-side=right]_&]:cursor-e-resize",
|
|
204
|
+
"[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize",
|
|
205
|
+
"group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full group-data-[collapsible=offcanvas]:hover:bg-surface-2",
|
|
206
|
+
"[[data-side=left][data-collapsible=offcanvas]_&]:-right-2",
|
|
207
|
+
"[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",
|
|
208
|
+
a
|
|
209
|
+
),
|
|
210
|
+
...e
|
|
211
|
+
}
|
|
212
|
+
);
|
|
213
|
+
}
|
|
214
|
+
);
|
|
215
|
+
re.displayName = "SidebarRail";
|
|
216
|
+
const ie = i(
|
|
217
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
218
|
+
"main",
|
|
219
|
+
{
|
|
220
|
+
ref: t,
|
|
221
|
+
className: r(
|
|
222
|
+
"relative flex min-h-svh flex-1 flex-col bg-surface-1",
|
|
223
|
+
"peer-data-[variant=inset]:min-h-[calc(100svh-theme(spacing.4))] md:peer-data-[variant=inset]:m-ds-03 md:peer-data-[state=collapsed]:peer-data-[variant=inset]:ml-ds-03 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-ds-xl md:peer-data-[variant=inset]:shadow",
|
|
224
|
+
a
|
|
225
|
+
),
|
|
226
|
+
...e
|
|
227
|
+
}
|
|
228
|
+
)
|
|
229
|
+
);
|
|
230
|
+
ie.displayName = "SidebarInset";
|
|
231
|
+
const de = i(({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
232
|
+
G,
|
|
233
|
+
{
|
|
234
|
+
ref: t,
|
|
235
|
+
"data-sidebar": "input",
|
|
236
|
+
className: r(
|
|
237
|
+
"h-ds-sm w-full bg-surface-1 shadow-none focus-visible:ring-2 focus-visible:ring-accent-9",
|
|
238
|
+
a
|
|
239
|
+
),
|
|
240
|
+
...e
|
|
241
|
+
}
|
|
242
|
+
));
|
|
243
|
+
de.displayName = "SidebarInput";
|
|
244
|
+
const oe = i(
|
|
245
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
246
|
+
"div",
|
|
247
|
+
{
|
|
248
|
+
ref: t,
|
|
249
|
+
"data-sidebar": "header",
|
|
250
|
+
className: r("flex flex-col gap-ds-03 p-ds-03", a),
|
|
251
|
+
...e
|
|
252
|
+
}
|
|
253
|
+
)
|
|
254
|
+
);
|
|
255
|
+
oe.displayName = "SidebarHeader";
|
|
256
|
+
const ne = i(
|
|
257
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
258
|
+
"div",
|
|
259
|
+
{
|
|
260
|
+
ref: t,
|
|
261
|
+
"data-sidebar": "footer",
|
|
262
|
+
className: r("flex flex-col gap-ds-03 p-ds-03", a),
|
|
263
|
+
...e
|
|
264
|
+
}
|
|
265
|
+
)
|
|
266
|
+
);
|
|
267
|
+
ne.displayName = "SidebarFooter";
|
|
268
|
+
const le = i(({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
269
|
+
L,
|
|
270
|
+
{
|
|
271
|
+
ref: t,
|
|
272
|
+
"data-sidebar": "separator",
|
|
273
|
+
className: r(
|
|
274
|
+
"bg-surface-border mx-ds-03 w-auto",
|
|
275
|
+
a
|
|
276
|
+
),
|
|
277
|
+
...e
|
|
278
|
+
}
|
|
279
|
+
));
|
|
280
|
+
le.displayName = "SidebarSeparator";
|
|
281
|
+
const ce = i(
|
|
282
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
283
|
+
"div",
|
|
284
|
+
{
|
|
285
|
+
ref: t,
|
|
286
|
+
"data-sidebar": "content",
|
|
287
|
+
className: r(
|
|
288
|
+
"flex min-h-0 flex-1 flex-col gap-ds-03 overflow-auto group-data-[collapsible=icon]:overflow-hidden",
|
|
289
|
+
a
|
|
290
|
+
),
|
|
291
|
+
...e
|
|
292
|
+
}
|
|
293
|
+
)
|
|
294
|
+
);
|
|
295
|
+
ce.displayName = "SidebarContent";
|
|
296
|
+
const ue = i(
|
|
297
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
298
|
+
"div",
|
|
299
|
+
{
|
|
300
|
+
ref: t,
|
|
301
|
+
"data-sidebar": "group",
|
|
302
|
+
className: r("relative flex w-full min-w-0 flex-col p-ds-03", a),
|
|
303
|
+
...e
|
|
304
|
+
}
|
|
305
|
+
)
|
|
306
|
+
);
|
|
307
|
+
ue.displayName = "SidebarGroup";
|
|
308
|
+
const me = i(({ className: a, asChild: e = !1, ...t }, d) => /* @__PURE__ */ s(
|
|
309
|
+
e ? v : "div",
|
|
310
|
+
{
|
|
311
|
+
ref: d,
|
|
312
|
+
"data-sidebar": "group-label",
|
|
313
|
+
className: r(
|
|
314
|
+
"flex h-ds-sm shrink-0 items-center rounded-ds-md px-ds-03 text-ds-sm font-medium text-surface-fg-muted outline-none ring-accent-9 transition-[margin,opa] duration-moderate-02 ease-linear focus-visible:ring-2 [&>svg]:h-ico-sm [&>svg]:w-ico-sm [&>svg]:shrink-0",
|
|
315
|
+
"group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",
|
|
316
|
+
a
|
|
317
|
+
),
|
|
318
|
+
...t
|
|
319
|
+
}
|
|
320
|
+
));
|
|
321
|
+
me.displayName = "SidebarGroupLabel";
|
|
322
|
+
const pe = i(({ className: a, asChild: e = !1, ...t }, d) => /* @__PURE__ */ s(
|
|
323
|
+
e ? v : "button",
|
|
324
|
+
{
|
|
325
|
+
ref: d,
|
|
326
|
+
"data-sidebar": "group-action",
|
|
327
|
+
className: r(
|
|
328
|
+
"hover:bg-surface-2 absolute right-ds-04 top-ds-04 flex aspect-square w-5 items-center justify-center rounded-ds-md p-0 text-surface-fg outline-none ring-accent-9 transition-transform hover:text-surface-fg focus-visible:ring-2 [&>svg]:h-ico-sm [&>svg]:w-ico-sm [&>svg]:shrink-0",
|
|
329
|
+
"after:absolute after:-inset-2 after:md:hidden",
|
|
330
|
+
"group-data-[collapsible=icon]:hidden",
|
|
331
|
+
a
|
|
332
|
+
),
|
|
333
|
+
...t
|
|
334
|
+
}
|
|
335
|
+
));
|
|
336
|
+
pe.displayName = "SidebarGroupAction";
|
|
337
|
+
const be = i(
|
|
338
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
339
|
+
"div",
|
|
340
|
+
{
|
|
341
|
+
ref: t,
|
|
342
|
+
"data-sidebar": "group-content",
|
|
343
|
+
className: r("w-full text-ds-md", a),
|
|
344
|
+
...e
|
|
345
|
+
}
|
|
346
|
+
)
|
|
347
|
+
);
|
|
348
|
+
be.displayName = "SidebarGroupContent";
|
|
349
|
+
const fe = i(
|
|
350
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
351
|
+
"ul",
|
|
352
|
+
{
|
|
353
|
+
ref: t,
|
|
354
|
+
"data-sidebar": "menu",
|
|
355
|
+
className: r("flex w-full min-w-0 flex-col gap-ds-02", a),
|
|
356
|
+
...e
|
|
357
|
+
}
|
|
358
|
+
)
|
|
359
|
+
);
|
|
360
|
+
fe.displayName = "SidebarMenu";
|
|
361
|
+
const ge = i(
|
|
362
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
363
|
+
"li",
|
|
364
|
+
{
|
|
365
|
+
ref: t,
|
|
366
|
+
"data-sidebar": "menu-item",
|
|
367
|
+
className: r("group/menu-item relative", a),
|
|
368
|
+
...e
|
|
369
|
+
}
|
|
370
|
+
)
|
|
371
|
+
);
|
|
372
|
+
ge.displayName = "SidebarMenuItem";
|
|
373
|
+
const he = T(
|
|
374
|
+
"peer/menu-button hover:bg-surface-2 active:bg-accent-2 data-[active=true]:bg-accent-2 data-[state=open]:hover:bg-surface-2 flex w-full items-center gap-ds-03 overflow-hidden rounded-ds-md p-ds-03 text-left outline-none ring-accent-9 transition-[width,height,padding] hover:text-surface-fg focus-visible:ring-2 active:text-surface-fg disabled:pointer-events-none disabled:opacity-action-disabled group-has-[[data-sidebar=menu-action]]/menu-item:pr-ds-07 aria-disabled:pointer-events-none aria-disabled:opacity-action-disabled data-[active=true]:font-medium data-[active=true]:text-surface-fg data-[state=open]:hover:text-surface-fg group-data-[collapsible=icon]:!size-8 group-data-[collapsible=icon]:!p-ds-03 [&>span:last-child]:truncate [&>svg]:h-ico-sm [&>svg]:w-ico-sm [&>svg]:shrink-0",
|
|
375
|
+
{
|
|
376
|
+
variants: {
|
|
377
|
+
variant: {
|
|
378
|
+
default: "hover:bg-surface-2 hover:text-surface-fg",
|
|
379
|
+
outline: "hover:bg-surface-2 bg-surface-1 shadow-[0_0_0_1px_var(--color-surface-border)] hover:text-surface-fg hover:shadow-[0_0_0_1px_var(--color-surface-border-strong)]"
|
|
380
|
+
},
|
|
381
|
+
size: {
|
|
382
|
+
md: "h-ds-sm text-ds-md",
|
|
383
|
+
sm: "h-ds-xs-plus text-ds-sm",
|
|
384
|
+
lg: "h-ds-lg text-ds-md group-data-[collapsible=icon]:!p-0"
|
|
385
|
+
}
|
|
386
|
+
},
|
|
387
|
+
defaultVariants: {
|
|
388
|
+
variant: "default",
|
|
389
|
+
size: "md"
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
), ve = i(
|
|
393
|
+
({
|
|
394
|
+
asChild: a = !1,
|
|
395
|
+
isActive: e = !1,
|
|
396
|
+
variant: t = "default",
|
|
397
|
+
size: d = "md",
|
|
398
|
+
tooltip: o,
|
|
399
|
+
className: n,
|
|
400
|
+
children: u,
|
|
401
|
+
...f
|
|
402
|
+
}, c) => {
|
|
403
|
+
const b = a ? v : "button", { isMobile: m, state: y } = N(), x = /* @__PURE__ */ s(
|
|
404
|
+
b,
|
|
405
|
+
{
|
|
406
|
+
ref: c,
|
|
407
|
+
"data-sidebar": "menu-button",
|
|
408
|
+
"data-size": d,
|
|
409
|
+
"data-active": e,
|
|
410
|
+
className: r(he({ variant: t, size: d }), !a && "relative", n),
|
|
411
|
+
...f,
|
|
412
|
+
children: a ? u : /* @__PURE__ */ h(E, { children: [
|
|
413
|
+
e && /* @__PURE__ */ s(
|
|
414
|
+
U.span,
|
|
415
|
+
{
|
|
416
|
+
layoutId: "sidebar-active-indicator",
|
|
417
|
+
className: "absolute inset-0 rounded-ds-md bg-accent-2",
|
|
418
|
+
transition: O.smooth
|
|
419
|
+
}
|
|
420
|
+
),
|
|
421
|
+
/* @__PURE__ */ s("span", { className: "relative z-[1] flex w-full items-center gap-[inherit]", children: u })
|
|
422
|
+
] })
|
|
423
|
+
}
|
|
424
|
+
);
|
|
425
|
+
return o ? (typeof o == "string" && (o = {
|
|
426
|
+
children: o
|
|
427
|
+
}), /* @__PURE__ */ h($, { children: [
|
|
428
|
+
/* @__PURE__ */ s(F, { asChild: !0, children: x }),
|
|
429
|
+
/* @__PURE__ */ s(
|
|
430
|
+
P,
|
|
431
|
+
{
|
|
432
|
+
side: "right",
|
|
433
|
+
align: "center",
|
|
434
|
+
hidden: y !== "collapsed" || m,
|
|
435
|
+
...o
|
|
436
|
+
}
|
|
437
|
+
)
|
|
438
|
+
] })) : x;
|
|
439
|
+
}
|
|
440
|
+
);
|
|
441
|
+
ve.displayName = "SidebarMenuButton";
|
|
442
|
+
const xe = i(({ className: a, asChild: e = !1, showOnHover: t = !1, ...d }, o) => /* @__PURE__ */ s(
|
|
443
|
+
e ? v : "button",
|
|
444
|
+
{
|
|
445
|
+
ref: o,
|
|
446
|
+
"data-sidebar": "menu-action",
|
|
447
|
+
className: r(
|
|
448
|
+
"hover:bg-surface-2 absolute right-ds-02 top-ds-02b flex aspect-square w-5 items-center justify-center rounded-ds-md p-0 text-surface-fg outline-none ring-accent-9 transition-transform hover:text-surface-fg focus-visible:ring-2 peer-hover/menu-button:text-surface-fg [&>svg]:h-ico-sm [&>svg]:w-ico-sm [&>svg]:shrink-0",
|
|
449
|
+
"after:absolute after:-inset-2 after:md:hidden",
|
|
450
|
+
"peer-data-[size=sm]/menu-button:top-1",
|
|
451
|
+
"peer-data-[size=md]/menu-button:top-ds-02b",
|
|
452
|
+
"peer-data-[size=lg]/menu-button:top-ds-03",
|
|
453
|
+
"group-data-[collapsible=icon]:hidden",
|
|
454
|
+
t && "group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 peer-data-[active=true]/menu-button:text-surface-fg md:opacity-0",
|
|
455
|
+
a
|
|
456
|
+
),
|
|
457
|
+
...d
|
|
458
|
+
}
|
|
459
|
+
));
|
|
460
|
+
xe.displayName = "SidebarMenuAction";
|
|
461
|
+
const Se = i(
|
|
462
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
463
|
+
"div",
|
|
464
|
+
{
|
|
465
|
+
ref: t,
|
|
466
|
+
"data-sidebar": "menu-badge",
|
|
467
|
+
className: r(
|
|
468
|
+
"pointer-events-none absolute right-ds-02 flex h-5 min-w-5 select-none items-center justify-center rounded-ds-md px-ds-02 text-ds-sm font-medium tabular-nums text-surface-fg",
|
|
469
|
+
"peer-hover/menu-button:text-surface-fg peer-data-[active=true]/menu-button:text-surface-fg",
|
|
470
|
+
"peer-data-[size=sm]/menu-button:top-1",
|
|
471
|
+
"peer-data-[size=md]/menu-button:top-ds-02b",
|
|
472
|
+
"peer-data-[size=lg]/menu-button:top-ds-03",
|
|
473
|
+
"group-data-[collapsible=icon]:hidden",
|
|
474
|
+
a
|
|
475
|
+
),
|
|
476
|
+
...e
|
|
477
|
+
}
|
|
478
|
+
)
|
|
479
|
+
);
|
|
480
|
+
Se.displayName = "SidebarMenuBadge";
|
|
481
|
+
const we = i(({ className: a, showIcon: e = !1, ...t }, d) => {
|
|
482
|
+
const o = k(() => `${Math.floor(Math.random() * 40) + 50}%`, []);
|
|
483
|
+
return /* @__PURE__ */ h(
|
|
484
|
+
"div",
|
|
485
|
+
{
|
|
486
|
+
ref: d,
|
|
487
|
+
"data-sidebar": "menu-skeleton",
|
|
488
|
+
className: r("flex h-ds-sm items-center gap-ds-03 rounded-ds-md px-ds-03", a),
|
|
489
|
+
...t,
|
|
490
|
+
children: [
|
|
491
|
+
e && /* @__PURE__ */ s(
|
|
492
|
+
_,
|
|
493
|
+
{
|
|
494
|
+
className: "h-ico-sm w-ico-sm rounded-ds-md",
|
|
495
|
+
"data-sidebar": "menu-skeleton-icon"
|
|
496
|
+
}
|
|
497
|
+
),
|
|
498
|
+
/* @__PURE__ */ s(
|
|
499
|
+
_,
|
|
500
|
+
{
|
|
501
|
+
className: "h-4 max-w-[--skeleton-width] flex-1",
|
|
502
|
+
"data-sidebar": "menu-skeleton-text",
|
|
503
|
+
style: {
|
|
504
|
+
"--skeleton-width": o
|
|
505
|
+
}
|
|
506
|
+
}
|
|
507
|
+
)
|
|
508
|
+
]
|
|
509
|
+
}
|
|
510
|
+
);
|
|
511
|
+
});
|
|
512
|
+
we.displayName = "SidebarMenuSkeleton";
|
|
513
|
+
const Ne = i(
|
|
514
|
+
({ className: a, ...e }, t) => /* @__PURE__ */ s(
|
|
515
|
+
"ul",
|
|
516
|
+
{
|
|
517
|
+
ref: t,
|
|
518
|
+
"data-sidebar": "menu-sub",
|
|
519
|
+
className: r(
|
|
520
|
+
"mx-ds-04 flex min-w-0 translate-x-px flex-col gap-ds-02 border-l border-surface-border px-ds-03 py-ds-01",
|
|
521
|
+
"group-data-[collapsible=icon]:hidden",
|
|
522
|
+
a
|
|
523
|
+
),
|
|
524
|
+
...e
|
|
525
|
+
}
|
|
526
|
+
)
|
|
527
|
+
);
|
|
528
|
+
Ne.displayName = "SidebarMenuSub";
|
|
529
|
+
const ye = i(
|
|
530
|
+
({ ...a }, e) => /* @__PURE__ */ s("li", { ref: e, ...a })
|
|
531
|
+
);
|
|
532
|
+
ye.displayName = "SidebarMenuSubItem";
|
|
533
|
+
const Me = i(({ asChild: a = !1, size: e = "md", isActive: t, className: d, ...o }, n) => /* @__PURE__ */ s(
|
|
534
|
+
a ? v : "a",
|
|
535
|
+
{
|
|
536
|
+
ref: n,
|
|
537
|
+
"data-sidebar": "menu-sub-button",
|
|
538
|
+
"data-size": e,
|
|
539
|
+
"data-active": t,
|
|
540
|
+
className: r(
|
|
541
|
+
"hover:bg-surface-2 active:bg-accent-2 flex h-ds-xs-plus min-w-0 -translate-x-px items-center gap-ds-03 overflow-hidden rounded-ds-md px-ds-03 text-surface-fg outline-none ring-accent-9 hover:text-surface-fg focus-visible:ring-2 active:text-surface-fg disabled:pointer-events-none disabled:opacity-action-disabled aria-disabled:pointer-events-none aria-disabled:opacity-action-disabled [&>span:last-child]:truncate [&>svg]:h-ico-sm [&>svg]:w-ico-sm [&>svg]:shrink-0 [&>svg]:text-surface-fg",
|
|
542
|
+
"data-[active=true]:bg-accent-2 data-[active=true]:text-surface-fg",
|
|
543
|
+
e === "sm" && "text-ds-sm",
|
|
544
|
+
e === "md" && "text-ds-md",
|
|
545
|
+
"group-data-[collapsible=icon]:hidden",
|
|
546
|
+
d
|
|
547
|
+
),
|
|
548
|
+
...o
|
|
549
|
+
}
|
|
550
|
+
));
|
|
551
|
+
Me.displayName = "SidebarMenuSubButton";
|
|
14
552
|
export {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
553
|
+
te as Sidebar,
|
|
554
|
+
ce as SidebarContent,
|
|
555
|
+
ne as SidebarFooter,
|
|
556
|
+
ue as SidebarGroup,
|
|
557
|
+
pe as SidebarGroupAction,
|
|
558
|
+
be as SidebarGroupContent,
|
|
559
|
+
me as SidebarGroupLabel,
|
|
560
|
+
oe as SidebarHeader,
|
|
561
|
+
de as SidebarInput,
|
|
562
|
+
ie as SidebarInset,
|
|
563
|
+
fe as SidebarMenu,
|
|
564
|
+
xe as SidebarMenuAction,
|
|
565
|
+
Se as SidebarMenuBadge,
|
|
566
|
+
ve as SidebarMenuButton,
|
|
567
|
+
ge as SidebarMenuItem,
|
|
568
|
+
we as SidebarMenuSkeleton,
|
|
569
|
+
Ne as SidebarMenuSub,
|
|
570
|
+
Me as SidebarMenuSubButton,
|
|
571
|
+
ye as SidebarMenuSubItem,
|
|
572
|
+
ae as SidebarProvider,
|
|
573
|
+
re as SidebarRail,
|
|
574
|
+
le as SidebarSeparator,
|
|
575
|
+
se as SidebarTrigger,
|
|
576
|
+
N as useSidebar
|
|
39
577
|
};
|
package/dist/ui/skeleton.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as l, jsxs as f } from "react/jsx-runtime";
|
|
2
2
|
import * as o from "react";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { ag as g } from "../_chunks/vendor-utils.js";
|
|
4
|
+
import { cn as r } from "./lib/utils.js";
|
|
5
5
|
const k = g("bg-skeleton-base", {
|
|
6
6
|
variants: {
|
|
7
7
|
variant: {
|
package/dist/ui/slider.d.ts
CHANGED
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import * as SliderPrimitive from '../primitives/react-slider';
|
|
4
|
+
/**
|
|
5
|
+
* A Radix-powered slider supporting single or multiple thumbs.
|
|
6
|
+
*
|
|
7
|
+
* Pass `defaultValue={[50]}` for a single thumb, or `defaultValue={[25, 75]}`
|
|
8
|
+
* for a range slider with two thumbs. One `<Thumb>` is rendered per value entry.
|
|
9
|
+
*
|
|
10
|
+
* When using multiple thumbs, provide per-thumb labels via the `aria-label` array
|
|
11
|
+
* on the `value`/`defaultValue` entries, or wrap each in a labelled form field.
|
|
12
|
+
*/
|
|
4
13
|
declare const Slider: React.ForwardRefExoticComponent<Omit<SliderPrimitive.SliderProps & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
5
14
|
export type SliderProps = React.ComponentPropsWithoutRef<typeof SliderPrimitive.Root>;
|
|
6
15
|
export { Slider };
|
package/dist/ui/slider.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"slider.d.ts","sourceRoot":"","sources":["../../src/ui/slider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,eAAe,MAAM,0BAA0B,CAAA;AAI3D,QAAA,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"slider.d.ts","sourceRoot":"","sources":["../../src/ui/slider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,eAAe,MAAM,0BAA0B,CAAA;AAI3D;;;;;;;;GAQG;AACH,QAAA,MAAM,MAAM,yJA8BV,CAAA;AAGF,MAAM,MAAM,WAAW,GAAG,KAAK,CAAC,wBAAwB,CAAC,OAAO,eAAe,CAAC,IAAI,CAAC,CAAA;AAErF,OAAO,EAAE,MAAM,EAAE,CAAA"}
|