@devalok/shilp-sutra 0.17.2 → 0.18.0
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/avatar.js +21 -19
- package/dist/_chunks/button-group.js +27 -0
- package/dist/_chunks/button.js +53 -35
- package/dist/_chunks/card.js +50 -0
- package/dist/_chunks/checkbox.js +11 -9
- package/dist/_chunks/date-utils.js +13 -0
- package/dist/_chunks/form.js +20 -20
- package/dist/_chunks/link-context.js +19 -0
- package/dist/_chunks/motion.js +1376 -0
- package/dist/_chunks/motion2.js +35 -0
- package/dist/_chunks/primitives.js +3499 -3920
- package/dist/_chunks/sidebar.js +225 -211
- package/dist/_chunks/spinner.js +58 -28
- package/dist/_chunks/tiptap.js +1 -1
- package/dist/_chunks/tooltip.js +27 -10
- package/dist/_chunks/tree-view.js +180 -178
- package/dist/_chunks/use-calendar.js +531 -515
- package/dist/_chunks/utils.js +3 -3
- 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 +71 -74
- package/dist/composed/avatar-group.js +36 -36
- 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 +46 -41
- package/dist/composed/content-card.d.ts +1 -1
- package/dist/composed/content-card.js +29 -29
- 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 +23 -20
- 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/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 +19 -19
- 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 +316 -309
- package/dist/composed/schedule-view.js +88 -88
- 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 +76 -63
- 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 +10 -0
- package/dist/motion/motion-provider.d.ts +18 -0
- package/dist/motion/motion-provider.d.ts.map +1 -0
- package/dist/motion/motion-provider.js +24 -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 +11 -0
- package/dist/motion/primitives.d.ts +38 -0
- package/dist/motion/primitives.d.ts.map +1 -0
- package/dist/motion/primitives.js +187 -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 +137 -132
- 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 +168 -165
- package/dist/shell/sidebar.js +119 -119
- package/dist/shell/top-bar.js +65 -65
- 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 +32 -22
- 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 +114 -73
- package/dist/ui/alert.d.ts +6 -1
- package/dist/ui/alert.d.ts.map +1 -1
- package/dist/ui/alert.js +64 -49
- 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 +82 -57
- package/dist/ui/avatar.d.ts.map +1 -1
- package/dist/ui/avatar.js +45 -34
- package/dist/ui/badge.d.ts +1 -1
- package/dist/ui/badge.d.ts.map +1 -1
- package/dist/ui/badge.js +70 -65
- package/dist/ui/banner.d.ts.map +1 -1
- package/dist/ui/banner.js +53 -39
- package/dist/ui/breadcrumb.d.ts +2 -0
- package/dist/ui/breadcrumb.d.ts.map +1 -1
- package/dist/ui/breadcrumb.js +21 -21
- package/dist/ui/button.d.ts +10 -1
- package/dist/ui/button.d.ts.map +1 -1
- package/dist/ui/button.js +103 -67
- 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 +62 -54
- 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/context-menu.d.ts +4 -2
- package/dist/ui/context-menu.d.ts.map +1 -1
- package/dist/ui/context-menu.js +146 -86
- 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 +61 -59
- package/dist/ui/data-table.d.ts.map +1 -1
- package/dist/ui/data-table.js +289 -254
- 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 +150 -89
- package/dist/ui/file-upload.d.ts.map +1 -1
- package/dist/ui/file-upload.js +169 -127
- package/dist/ui/form.d.ts.map +1 -1
- package/dist/ui/form.js +29 -26
- 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/index.d.ts +18 -18
- package/dist/ui/index.d.ts.map +1 -1
- package/dist/ui/index.js +432 -449
- 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 +7 -7
- package/dist/ui/input.d.ts.map +1 -1
- package/dist/ui/input.js +36 -34
- package/dist/ui/label.js +12 -12
- package/dist/ui/lib/date-utils.d.ts +6 -0
- package/dist/ui/lib/date-utils.d.ts.map +1 -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/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 +141 -97
- 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 +56 -49
- package/dist/ui/pagination.js +22 -22
- 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 +19 -19
- 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 +2 -2
- package/dist/ui/segmented-control.d.ts.map +1 -1
- package/dist/ui/segmented-control.js +143 -124
- package/dist/ui/select.d.ts.map +1 -1
- package/dist/ui/select.js +72 -61
- package/dist/ui/separator.js +11 -11
- 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 +27 -25
- package/dist/ui/skeleton.js +1 -1
- 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/stat-card.d.ts.map +1 -1
- package/dist/ui/stat-card.js +183 -116
- package/dist/ui/stepper.d.ts +22 -1
- package/dist/ui/stepper.d.ts.map +1 -1
- package/dist/ui/stepper.js +121 -43
- 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 +47 -47
- 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 +1 -1
- package/dist/ui/textarea.d.ts.map +1 -1
- package/dist/ui/textarea.js +29 -27
- 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/llms-full.txt +221 -102
- package/llms.txt +65 -12
- package/package.json +26 -8
- package/dist/_chunks/switch.js +0 -10
- 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/shell/sidebar.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
2
|
+
import { jsxs as r, jsx as e, Fragment as A } from "react/jsx-runtime";
|
|
3
3
|
import * as m from "react";
|
|
4
|
-
import {
|
|
5
|
-
import { S as T, a as z, b, c as H, d as U, e as $, f as q, g as E, h as J, i as L, j as M, k as j, l as I, m as K, n as Q, o as V } from "../_chunks/sidebar.js";
|
|
4
|
+
import { u as R } from "../_chunks/link-context.js";
|
|
5
|
+
import { S as T, a as z, b as f, c as H, d as U, e as $, f as q, g as E, h as J, i as L, j as M, k as j, l as I, m as K, n as Q, o as V } from "../_chunks/sidebar.js";
|
|
6
6
|
import { Collapsible as X, CollapsibleTrigger as Y, CollapsibleContent as Z } from "../ui/collapsible.js";
|
|
7
7
|
import { A as _, a as P, b as ee } from "../_chunks/avatar.js";
|
|
8
|
-
import { c as
|
|
9
|
-
function ae({ className:
|
|
8
|
+
import { c as b } from "../_chunks/utils.js";
|
|
9
|
+
function ae({ className: s }) {
|
|
10
10
|
return /* @__PURE__ */ e(
|
|
11
11
|
"svg",
|
|
12
12
|
{
|
|
@@ -19,13 +19,13 @@ function ae({ className: r }) {
|
|
|
19
19
|
strokeWidth: "2",
|
|
20
20
|
strokeLinecap: "round",
|
|
21
21
|
strokeLinejoin: "round",
|
|
22
|
-
className:
|
|
22
|
+
className: s,
|
|
23
23
|
children: /* @__PURE__ */ e("path", { d: "m9 18 6-6-6-6" })
|
|
24
24
|
}
|
|
25
25
|
);
|
|
26
26
|
}
|
|
27
|
-
function
|
|
28
|
-
return /* @__PURE__ */
|
|
27
|
+
function se({ className: s }) {
|
|
28
|
+
return /* @__PURE__ */ r(
|
|
29
29
|
"svg",
|
|
30
30
|
{
|
|
31
31
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -37,7 +37,7 @@ function re({ className: r }) {
|
|
|
37
37
|
strokeWidth: "2",
|
|
38
38
|
strokeLinecap: "round",
|
|
39
39
|
strokeLinejoin: "round",
|
|
40
|
-
className:
|
|
40
|
+
className: s,
|
|
41
41
|
children: [
|
|
42
42
|
/* @__PURE__ */ e("path", { d: "M18 6 6 18" }),
|
|
43
43
|
/* @__PURE__ */ e("path", { d: "m6 6 12 12" })
|
|
@@ -45,38 +45,38 @@ function re({ className: r }) {
|
|
|
45
45
|
}
|
|
46
46
|
);
|
|
47
47
|
}
|
|
48
|
-
const B = "relative gap-ds-04 rounded-ds-lg px-ds-04 py-ds-03 transition-colors", F = "bg-
|
|
49
|
-
function
|
|
50
|
-
item:
|
|
51
|
-
isActive:
|
|
52
|
-
isPathActive:
|
|
48
|
+
const B = "relative gap-ds-04 rounded-ds-lg px-ds-04 py-ds-03 transition-colors", F = "bg-accent-2 text-accent-11 after:absolute after:right-0 after:top-0 after:h-full after:w-ds-01 after:rounded-l-ds-full after:bg-accent-9 after:content-['']", G = "text-surface-fg-subtle hover:bg-surface-2 hover:text-surface-fg";
|
|
49
|
+
function re({
|
|
50
|
+
item: s,
|
|
51
|
+
isActive: t,
|
|
52
|
+
isPathActive: u
|
|
53
53
|
}) {
|
|
54
|
-
const h = R(), i =
|
|
55
|
-
if (
|
|
56
|
-
const
|
|
57
|
-
(l) =>
|
|
58
|
-
),
|
|
59
|
-
return /* @__PURE__ */ e(X, { defaultOpen:
|
|
60
|
-
/* @__PURE__ */
|
|
54
|
+
const h = R(), i = s.badge != null ? typeof s.badge == "number" && s.badge > 99 ? "99+" : String(s.badge) : null;
|
|
55
|
+
if (s.children && s.children.length > 0) {
|
|
56
|
+
const d = s.children.some(
|
|
57
|
+
(l) => u(l.href, l.exact)
|
|
58
|
+
), g = d || t || (s.defaultOpen ?? !1);
|
|
59
|
+
return /* @__PURE__ */ e(X, { defaultOpen: g, className: "group/collapsible", children: /* @__PURE__ */ r(M, { children: [
|
|
60
|
+
/* @__PURE__ */ r("div", { className: "relative", children: [
|
|
61
61
|
/* @__PURE__ */ e(
|
|
62
62
|
j,
|
|
63
63
|
{
|
|
64
64
|
asChild: !0,
|
|
65
|
-
isActive:
|
|
66
|
-
tooltip:
|
|
67
|
-
className:
|
|
65
|
+
isActive: t || d,
|
|
66
|
+
tooltip: s.title,
|
|
67
|
+
className: b(
|
|
68
68
|
B,
|
|
69
|
-
|
|
69
|
+
t || d ? F : G
|
|
70
70
|
),
|
|
71
|
-
children: /* @__PURE__ */
|
|
71
|
+
children: /* @__PURE__ */ r(
|
|
72
72
|
h,
|
|
73
73
|
{
|
|
74
|
-
href:
|
|
75
|
-
"aria-label":
|
|
76
|
-
"aria-current":
|
|
74
|
+
href: s.href,
|
|
75
|
+
"aria-label": s.title,
|
|
76
|
+
"aria-current": t ? "page" : void 0,
|
|
77
77
|
children: [
|
|
78
|
-
/* @__PURE__ */ e("span", { className: "[&>svg]:h-ico-md [&>svg]:w-ico-md shrink-0", "aria-hidden": "true", children:
|
|
79
|
-
/* @__PURE__ */ e("span", { className: "text-ds-base", children:
|
|
78
|
+
/* @__PURE__ */ e("span", { className: "[&>svg]:h-ico-md [&>svg]:w-ico-md shrink-0", "aria-hidden": "true", children: s.icon }),
|
|
79
|
+
/* @__PURE__ */ e("span", { className: "text-ds-base", children: s.title })
|
|
80
80
|
]
|
|
81
81
|
}
|
|
82
82
|
)
|
|
@@ -86,20 +86,20 @@ function te({
|
|
|
86
86
|
/* @__PURE__ */ e(Y, { asChild: !0, children: /* @__PURE__ */ e(
|
|
87
87
|
"button",
|
|
88
88
|
{
|
|
89
|
-
className: "absolute right-ds-02 top-1/2 flex h-5 w-5 -translate-y-1/2 items-center justify-center rounded-ds-md text-
|
|
90
|
-
"aria-label": `Toggle ${
|
|
89
|
+
className: "absolute right-ds-02 top-1/2 flex h-5 w-5 -translate-y-1/2 items-center justify-center rounded-ds-md text-surface-fg-subtle transition-colors hover:bg-surface-2 hover:text-surface-fg group-data-[collapsible=icon]:hidden",
|
|
90
|
+
"aria-label": `Toggle ${s.title}`,
|
|
91
91
|
children: /* @__PURE__ */ e(ae, { className: "h-4 w-4 transition-transform duration-fast-02 ease-productive-standard group-data-[state=open]/collapsible:rotate-90" })
|
|
92
92
|
}
|
|
93
93
|
) })
|
|
94
94
|
] }),
|
|
95
|
-
/* @__PURE__ */ e(Z, {
|
|
96
|
-
const a =
|
|
95
|
+
/* @__PURE__ */ e(Z, { children: /* @__PURE__ */ e(K, { children: s.children.map((l) => {
|
|
96
|
+
const a = u(l.href, l.exact);
|
|
97
97
|
return /* @__PURE__ */ e(Q, { children: /* @__PURE__ */ e(
|
|
98
98
|
V,
|
|
99
99
|
{
|
|
100
100
|
asChild: !0,
|
|
101
101
|
isActive: a,
|
|
102
|
-
children: /* @__PURE__ */
|
|
102
|
+
children: /* @__PURE__ */ r(
|
|
103
103
|
h,
|
|
104
104
|
{
|
|
105
105
|
href: l.href,
|
|
@@ -115,26 +115,26 @@ function te({
|
|
|
115
115
|
}) }) })
|
|
116
116
|
] }) });
|
|
117
117
|
}
|
|
118
|
-
return /* @__PURE__ */
|
|
118
|
+
return /* @__PURE__ */ r(M, { children: [
|
|
119
119
|
/* @__PURE__ */ e(
|
|
120
120
|
j,
|
|
121
121
|
{
|
|
122
122
|
asChild: !0,
|
|
123
|
-
isActive:
|
|
124
|
-
tooltip:
|
|
125
|
-
className:
|
|
123
|
+
isActive: t,
|
|
124
|
+
tooltip: s.title,
|
|
125
|
+
className: b(
|
|
126
126
|
B,
|
|
127
|
-
|
|
127
|
+
t ? F : G
|
|
128
128
|
),
|
|
129
|
-
children: /* @__PURE__ */
|
|
129
|
+
children: /* @__PURE__ */ r(
|
|
130
130
|
h,
|
|
131
131
|
{
|
|
132
|
-
href:
|
|
133
|
-
"aria-label":
|
|
134
|
-
"aria-current":
|
|
132
|
+
href: s.href,
|
|
133
|
+
"aria-label": s.title,
|
|
134
|
+
"aria-current": t ? "page" : void 0,
|
|
135
135
|
children: [
|
|
136
|
-
/* @__PURE__ */ e("span", { className: "[&>svg]:h-ico-md [&>svg]:w-ico-md shrink-0", "aria-hidden": "true", children:
|
|
137
|
-
/* @__PURE__ */ e("span", { className: "text-ds-base", children:
|
|
136
|
+
/* @__PURE__ */ e("span", { className: "[&>svg]:h-ico-md [&>svg]:w-ico-md shrink-0", "aria-hidden": "true", children: s.icon }),
|
|
137
|
+
/* @__PURE__ */ e("span", { className: "text-ds-base", children: s.title })
|
|
138
138
|
]
|
|
139
139
|
}
|
|
140
140
|
)
|
|
@@ -143,144 +143,144 @@ function te({
|
|
|
143
143
|
i && /* @__PURE__ */ e(I, { children: i })
|
|
144
144
|
] });
|
|
145
145
|
}
|
|
146
|
-
const
|
|
146
|
+
const ne = m.forwardRef(
|
|
147
147
|
({
|
|
148
|
-
currentPath:
|
|
149
|
-
user:
|
|
150
|
-
navGroups:
|
|
148
|
+
currentPath: s = "/",
|
|
149
|
+
user: t,
|
|
150
|
+
navGroups: u = [],
|
|
151
151
|
logo: h,
|
|
152
152
|
headerSlot: i,
|
|
153
|
-
preFooterSlot:
|
|
154
|
-
preFooterClassName:
|
|
153
|
+
preFooterSlot: d,
|
|
154
|
+
preFooterClassName: g,
|
|
155
155
|
footerLinks: l = [],
|
|
156
156
|
footer: a,
|
|
157
|
-
renderItem:
|
|
157
|
+
renderItem: x,
|
|
158
158
|
className: D,
|
|
159
159
|
...O
|
|
160
160
|
}, W) => {
|
|
161
|
-
var N, w,
|
|
162
|
-
const
|
|
163
|
-
return /* @__PURE__ */
|
|
161
|
+
var N, w, C, S;
|
|
162
|
+
const p = R(), v = (n, c = !1) => c || n === "/" ? s === n : s.startsWith(n);
|
|
163
|
+
return /* @__PURE__ */ r(
|
|
164
164
|
T,
|
|
165
165
|
{
|
|
166
166
|
...O,
|
|
167
167
|
ref: W,
|
|
168
168
|
"aria-label": "Main navigation",
|
|
169
|
-
className:
|
|
170
|
-
"z-raised hidden h-full flex-col border-r border-border bg-
|
|
169
|
+
className: b(
|
|
170
|
+
"z-raised hidden h-full flex-col border-r border-surface-border-strong bg-surface-1 md:flex",
|
|
171
171
|
D
|
|
172
172
|
),
|
|
173
173
|
children: [
|
|
174
|
-
/* @__PURE__ */ e(z, { className: "px-ds-06 py-ds-06", children: h ?? /* @__PURE__ */ e("span", { className: "text-ds-lg font-semibold text-
|
|
175
|
-
|
|
176
|
-
/* @__PURE__ */
|
|
177
|
-
|
|
178
|
-
/* @__PURE__ */ e(ee, { className: "bg-
|
|
174
|
+
/* @__PURE__ */ e(z, { className: "px-ds-06 py-ds-06", children: h ?? /* @__PURE__ */ e("span", { className: "text-ds-lg font-semibold text-surface-fg", children: "Logo" }) }),
|
|
175
|
+
t && /* @__PURE__ */ r("div", { className: "flex items-center gap-ds-04 px-ds-06 pb-ds-05", children: [
|
|
176
|
+
/* @__PURE__ */ r(_, { className: "h-ds-sm-plus w-ds-sm-plus", children: [
|
|
177
|
+
t.image ? /* @__PURE__ */ e(P, { src: t.image, alt: t.name }) : null,
|
|
178
|
+
/* @__PURE__ */ e(ee, { className: "bg-surface-3 text-surface-fg", children: (N = t.name) == null ? void 0 : N.charAt(0).toUpperCase() })
|
|
179
179
|
] }),
|
|
180
|
-
/* @__PURE__ */
|
|
181
|
-
/* @__PURE__ */ e("span", { className: "truncate text-ds-md text-
|
|
182
|
-
/* @__PURE__ */ e("span", { className: "truncate text-ds-sm text-
|
|
180
|
+
/* @__PURE__ */ r("div", { className: "flex min-w-0 flex-col", children: [
|
|
181
|
+
/* @__PURE__ */ e("span", { className: "truncate text-ds-md text-surface-fg", children: t.name }),
|
|
182
|
+
/* @__PURE__ */ e("span", { className: "truncate text-ds-sm text-surface-fg-subtle", children: t.designation || t.role })
|
|
183
183
|
] })
|
|
184
184
|
] }),
|
|
185
|
-
/* @__PURE__ */ e(
|
|
186
|
-
i && /* @__PURE__ */
|
|
185
|
+
/* @__PURE__ */ e(f, {}),
|
|
186
|
+
i && /* @__PURE__ */ r(A, { children: [
|
|
187
187
|
i,
|
|
188
|
-
/* @__PURE__ */ e(
|
|
188
|
+
/* @__PURE__ */ e(f, {})
|
|
189
189
|
] }),
|
|
190
|
-
/* @__PURE__ */ e(H, { className: "no-scrollbar px-ds-04", children:
|
|
191
|
-
|
|
192
|
-
/* @__PURE__ */
|
|
193
|
-
/* @__PURE__ */ e($, { className: "px-ds-04 text-ds-sm text-
|
|
194
|
-
|
|
195
|
-
/* @__PURE__ */ e(E, { children: /* @__PURE__ */ e(J, { children:
|
|
196
|
-
const
|
|
197
|
-
|
|
190
|
+
/* @__PURE__ */ e(H, { className: "no-scrollbar px-ds-04", children: u.map((n, c) => /* @__PURE__ */ r("div", { children: [
|
|
191
|
+
c > 0 && /* @__PURE__ */ e(f, {}),
|
|
192
|
+
/* @__PURE__ */ r(U, { children: [
|
|
193
|
+
/* @__PURE__ */ e($, { className: "px-ds-04 text-ds-sm text-surface-fg-subtle", children: n.label }),
|
|
194
|
+
n.action && /* @__PURE__ */ e(q, { asChild: !0, children: n.action }),
|
|
195
|
+
/* @__PURE__ */ e(E, { children: /* @__PURE__ */ e(J, { children: n.items.map((o) => {
|
|
196
|
+
const k = () => /* @__PURE__ */ e(
|
|
197
|
+
re,
|
|
198
198
|
{
|
|
199
199
|
item: o,
|
|
200
|
-
isActive:
|
|
201
|
-
isPathActive:
|
|
200
|
+
isActive: v(o.href, o.exact),
|
|
201
|
+
isPathActive: v
|
|
202
202
|
}
|
|
203
203
|
);
|
|
204
|
-
if (
|
|
205
|
-
const
|
|
206
|
-
if (
|
|
207
|
-
return /* @__PURE__ */ e(m.Fragment, { children:
|
|
204
|
+
if (x) {
|
|
205
|
+
const y = x(o, k);
|
|
206
|
+
if (y !== null)
|
|
207
|
+
return /* @__PURE__ */ e(m.Fragment, { children: y }, o.href);
|
|
208
208
|
}
|
|
209
|
-
return /* @__PURE__ */ e(m.Fragment, { children:
|
|
209
|
+
return /* @__PURE__ */ e(m.Fragment, { children: k() }, o.href);
|
|
210
210
|
}) }) })
|
|
211
211
|
] })
|
|
212
|
-
] },
|
|
213
|
-
|
|
214
|
-
/* @__PURE__ */ e(
|
|
215
|
-
/* @__PURE__ */ e("div", { className:
|
|
212
|
+
] }, n.label)) }),
|
|
213
|
+
d && /* @__PURE__ */ r(A, { children: [
|
|
214
|
+
/* @__PURE__ */ e(f, {}),
|
|
215
|
+
/* @__PURE__ */ e("div", { className: g, children: d })
|
|
216
216
|
] }),
|
|
217
|
-
a ? /* @__PURE__ */
|
|
217
|
+
a ? /* @__PURE__ */ r(L, { className: "gap-ds-03 px-ds-06 py-ds-05", children: [
|
|
218
218
|
a.slot && /* @__PURE__ */ e("div", { children: a.slot }),
|
|
219
|
-
a.promo && /* @__PURE__ */
|
|
219
|
+
a.promo && /* @__PURE__ */ r("div", { className: "relative rounded-ds-lg border border-surface-border bg-surface-2 p-ds-04", children: [
|
|
220
220
|
a.promo.onDismiss && /* @__PURE__ */ e(
|
|
221
221
|
"button",
|
|
222
222
|
{
|
|
223
223
|
onClick: a.promo.onDismiss,
|
|
224
224
|
"aria-label": "Dismiss",
|
|
225
|
-
className: "absolute right-ds-02 top-ds-02 flex h-5 w-5 items-center justify-center rounded-ds-md text-
|
|
226
|
-
children: /* @__PURE__ */ e(
|
|
225
|
+
className: "absolute right-ds-02 top-ds-02 flex h-5 w-5 items-center justify-center rounded-ds-md text-surface-fg-subtle transition-colors hover:bg-surface-3 hover:text-surface-fg",
|
|
226
|
+
children: /* @__PURE__ */ e(se, { className: "h-3.5 w-3.5" })
|
|
227
227
|
}
|
|
228
228
|
),
|
|
229
|
-
/* @__PURE__ */
|
|
230
|
-
a.promo.icon && /* @__PURE__ */ e("span", { className: "text-
|
|
231
|
-
/* @__PURE__ */
|
|
232
|
-
/* @__PURE__ */ e("p", { className: "text-ds-sm text-
|
|
229
|
+
/* @__PURE__ */ r("div", { className: "flex flex-col gap-ds-03", children: [
|
|
230
|
+
a.promo.icon && /* @__PURE__ */ e("span", { className: "text-accent-11 [&>svg]:h-ico-md [&>svg]:w-ico-md", "aria-hidden": "true", children: a.promo.icon }),
|
|
231
|
+
/* @__PURE__ */ r("div", { className: "flex min-w-0 flex-col gap-ds-03", children: [
|
|
232
|
+
/* @__PURE__ */ e("p", { className: "text-ds-sm text-surface-fg", children: a.promo.text }),
|
|
233
233
|
a.promo.action && (a.promo.action.href ? /* @__PURE__ */ e(
|
|
234
|
-
|
|
234
|
+
p,
|
|
235
235
|
{
|
|
236
236
|
href: a.promo.action.href,
|
|
237
237
|
onClick: a.promo.action.onClick,
|
|
238
|
-
className: "inline-flex self-start rounded-ds-md bg-
|
|
238
|
+
className: "inline-flex self-start rounded-ds-md bg-accent-9 px-ds-04 py-ds-02 text-ds-sm font-medium text-accent-fg transition-colors hover:bg-accent-10",
|
|
239
239
|
children: a.promo.action.label
|
|
240
240
|
}
|
|
241
241
|
) : /* @__PURE__ */ e(
|
|
242
242
|
"button",
|
|
243
243
|
{
|
|
244
244
|
onClick: a.promo.action.onClick,
|
|
245
|
-
className: "inline-flex self-start rounded-ds-md bg-
|
|
245
|
+
className: "inline-flex self-start rounded-ds-md bg-accent-9 px-ds-04 py-ds-02 text-ds-sm font-medium text-accent-fg transition-colors hover:bg-accent-10",
|
|
246
246
|
children: a.promo.action.label
|
|
247
247
|
}
|
|
248
248
|
))
|
|
249
249
|
] })
|
|
250
250
|
] })
|
|
251
251
|
] }),
|
|
252
|
-
(((w = a.links) == null ? void 0 : w.length) || a.version) && /* @__PURE__ */
|
|
253
|
-
(
|
|
254
|
-
|
|
252
|
+
(((w = a.links) == null ? void 0 : w.length) || a.version) && /* @__PURE__ */ r("div", { className: "flex items-center gap-ds-03 text-ds-sm text-surface-fg-subtle", children: [
|
|
253
|
+
(C = a.links) == null ? void 0 : C.map((n, c) => /* @__PURE__ */ r(m.Fragment, { children: [
|
|
254
|
+
c > 0 && /* @__PURE__ */ e("span", { children: "·" }),
|
|
255
255
|
/* @__PURE__ */ e(
|
|
256
|
-
|
|
256
|
+
p,
|
|
257
257
|
{
|
|
258
|
-
className: "transition-colors hover:text-
|
|
259
|
-
href:
|
|
260
|
-
children:
|
|
258
|
+
className: "transition-colors hover:text-accent-11",
|
|
259
|
+
href: n.href,
|
|
260
|
+
children: n.label
|
|
261
261
|
}
|
|
262
262
|
)
|
|
263
|
-
] },
|
|
264
|
-
((
|
|
265
|
-
a.version && (typeof a.version == "string" ? /* @__PURE__ */ e("span", { children: a.version }) : /* @__PURE__ */ e(
|
|
263
|
+
] }, n.href)),
|
|
264
|
+
((S = a.links) == null ? void 0 : S.length) && a.version && /* @__PURE__ */ e("span", { children: "·" }),
|
|
265
|
+
a.version && (typeof a.version == "string" ? /* @__PURE__ */ e("span", { children: a.version }) : /* @__PURE__ */ e(p, { className: "transition-colors hover:text-accent-11", href: a.version.href, children: a.version.label }))
|
|
266
266
|
] })
|
|
267
|
-
] }) : l.length > 0 ? /* @__PURE__ */ e(L, { className: "px-ds-06 py-ds-05", children: /* @__PURE__ */ e("div", { className: "flex items-center gap-ds-03 text-ds-sm text-
|
|
268
|
-
|
|
267
|
+
] }) : l.length > 0 ? /* @__PURE__ */ e(L, { className: "px-ds-06 py-ds-05", children: /* @__PURE__ */ e("div", { className: "flex items-center gap-ds-03 text-ds-sm text-surface-fg-subtle", children: l.map((n, c) => /* @__PURE__ */ r(m.Fragment, { children: [
|
|
268
|
+
c > 0 && /* @__PURE__ */ e("span", { children: "·" }),
|
|
269
269
|
/* @__PURE__ */ e(
|
|
270
|
-
|
|
270
|
+
p,
|
|
271
271
|
{
|
|
272
|
-
className: "transition-colors hover:text-
|
|
273
|
-
href:
|
|
274
|
-
children:
|
|
272
|
+
className: "transition-colors hover:text-accent-11",
|
|
273
|
+
href: n.href,
|
|
274
|
+
children: n.label
|
|
275
275
|
}
|
|
276
276
|
)
|
|
277
|
-
] },
|
|
277
|
+
] }, n.href)) }) }) : null
|
|
278
278
|
]
|
|
279
279
|
}
|
|
280
280
|
);
|
|
281
281
|
}
|
|
282
282
|
);
|
|
283
|
-
|
|
283
|
+
ne.displayName = "AppSidebar";
|
|
284
284
|
export {
|
|
285
|
-
|
|
285
|
+
ne as AppSidebar
|
|
286
286
|
};
|
package/dist/shell/top-bar.js
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsxs as s, jsx as e, Fragment as D } from "react/jsx-runtime";
|
|
3
|
-
import * as
|
|
3
|
+
import * as w from "react";
|
|
4
4
|
import { useColorMode as I } from "../hooks/use-color-mode.js";
|
|
5
5
|
import { A as j, a as K, b as F } from "../_chunks/avatar.js";
|
|
6
|
-
import { DropdownMenu as U, DropdownMenuTrigger as B, DropdownMenuContent as E, DropdownMenuItem as
|
|
7
|
-
import { a as
|
|
6
|
+
import { DropdownMenu as U, DropdownMenuTrigger as B, DropdownMenuContent as E, DropdownMenuItem as d, DropdownMenuSeparator as N } from "../ui/dropdown-menu.js";
|
|
7
|
+
import { a as t, b as n, c as i } from "../_chunks/tooltip.js";
|
|
8
8
|
import { p as R } from "../_chunks/sidebar.js";
|
|
9
9
|
import { IconSearch as z, IconSparkles as L, IconUser as O, IconSun as P, IconMoon as q, IconLogout as G } from "@tabler/icons-react";
|
|
10
|
-
import { c as
|
|
11
|
-
const H =
|
|
10
|
+
import { c as l } from "../_chunks/utils.js";
|
|
11
|
+
const H = w.forwardRef(
|
|
12
12
|
({
|
|
13
13
|
pageTitle: m = "",
|
|
14
|
-
user:
|
|
15
|
-
onNavigate:
|
|
16
|
-
onLogout:
|
|
17
|
-
onSearchClick:
|
|
18
|
-
onAiChatClick:
|
|
19
|
-
mobileLogo:
|
|
20
|
-
notificationSlot:
|
|
14
|
+
user: a,
|
|
15
|
+
onNavigate: c,
|
|
16
|
+
onLogout: f,
|
|
17
|
+
onSearchClick: u,
|
|
18
|
+
onAiChatClick: p,
|
|
19
|
+
mobileLogo: h,
|
|
20
|
+
notificationSlot: y,
|
|
21
21
|
userMenuItems: o,
|
|
22
22
|
className: C,
|
|
23
23
|
...k
|
|
24
24
|
}, v) => {
|
|
25
|
-
var
|
|
26
|
-
const { colorMode:
|
|
27
|
-
|
|
25
|
+
var g;
|
|
26
|
+
const { colorMode: b, toggleColorMode: M } = I(), S = () => {
|
|
27
|
+
u ? u() : document.dispatchEvent(
|
|
28
28
|
new KeyboardEvent("keydown", {
|
|
29
29
|
key: "k",
|
|
30
30
|
ctrlKey: !0,
|
|
@@ -37,124 +37,124 @@ const H = g.forwardRef(
|
|
|
37
37
|
{
|
|
38
38
|
...k,
|
|
39
39
|
ref: v,
|
|
40
|
-
className:
|
|
41
|
-
"z-sticky flex w-full items-center border-b border-border bg-
|
|
40
|
+
className: l(
|
|
41
|
+
"z-sticky flex w-full items-center border-b border-surface-border-strong bg-surface-1 px-ds-05 py-ds-04 md:px-ds-06",
|
|
42
42
|
C
|
|
43
43
|
),
|
|
44
44
|
children: [
|
|
45
45
|
/* @__PURE__ */ s("div", { className: "flex items-center gap-ds-04", children: [
|
|
46
|
-
/* @__PURE__ */ e(R, { className: "hidden text-
|
|
47
|
-
|
|
48
|
-
m && /* @__PURE__ */ e("h2", { className: "hidden text-ds-lg text-
|
|
46
|
+
/* @__PURE__ */ e(R, { className: "hidden text-surface-fg-muted md:flex" }),
|
|
47
|
+
h && /* @__PURE__ */ e("div", { className: "md:hidden", children: h }),
|
|
48
|
+
m && /* @__PURE__ */ e("h2", { className: "hidden text-ds-lg text-surface-fg md:block", children: m })
|
|
49
49
|
] }),
|
|
50
50
|
/* @__PURE__ */ s("div", { className: "ml-auto flex items-center gap-ds-03 md:gap-ds-05", children: [
|
|
51
|
-
/* @__PURE__ */ s(
|
|
51
|
+
/* @__PURE__ */ s(t, { children: [
|
|
52
52
|
/* @__PURE__ */ e(n, { asChild: !0, children: /* @__PURE__ */ e(
|
|
53
53
|
"button",
|
|
54
54
|
{
|
|
55
55
|
type: "button",
|
|
56
56
|
onClick: S,
|
|
57
57
|
"aria-label": "Search (Ctrl+K)",
|
|
58
|
-
className: "flex h-ds-sm-plus w-ds-sm-plus items-center justify-center rounded-ds-full border border-border bg-
|
|
58
|
+
className: "flex h-ds-sm-plus w-ds-sm-plus items-center justify-center rounded-ds-full border border-surface-border-strong bg-surface-2 text-surface-fg-muted transition-colors hover:bg-surface-3",
|
|
59
59
|
children: /* @__PURE__ */ e(z, { className: "h-ico-sm w-ico-sm", "aria-hidden": "true" })
|
|
60
60
|
}
|
|
61
61
|
) }),
|
|
62
62
|
/* @__PURE__ */ e(i, { side: "bottom", align: "center", children: "Search (Ctrl+K)" })
|
|
63
63
|
] }),
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
y,
|
|
65
|
+
p && /* @__PURE__ */ s(t, { children: [
|
|
66
66
|
/* @__PURE__ */ e(n, { asChild: !0, children: /* @__PURE__ */ e(
|
|
67
67
|
"button",
|
|
68
68
|
{
|
|
69
69
|
type: "button",
|
|
70
|
-
onClick:
|
|
70
|
+
onClick: p,
|
|
71
71
|
"aria-label": "AI Chat",
|
|
72
|
-
className: "flex h-ds-sm-plus w-ds-sm-plus items-center justify-center rounded-ds-full border border-border bg-
|
|
72
|
+
className: "flex h-ds-sm-plus w-ds-sm-plus items-center justify-center rounded-ds-full border border-surface-border-strong bg-surface-2 text-surface-fg-muted transition-colors hover:bg-surface-3",
|
|
73
73
|
children: /* @__PURE__ */ e(L, { className: "h-ico-sm w-ico-sm", "aria-hidden": "true" })
|
|
74
74
|
}
|
|
75
75
|
) }),
|
|
76
76
|
/* @__PURE__ */ e(i, { side: "bottom", align: "center", children: "AI Chat" })
|
|
77
77
|
] }),
|
|
78
|
-
|
|
79
|
-
/* @__PURE__ */ s(
|
|
78
|
+
a && /* @__PURE__ */ s(U, { children: [
|
|
79
|
+
/* @__PURE__ */ s(t, { children: [
|
|
80
80
|
/* @__PURE__ */ e(n, { asChild: !0, children: /* @__PURE__ */ e(B, { asChild: !0, children: /* @__PURE__ */ e("button", { type: "button", className: "flex items-center gap-ds-03 outline-none", children: /* @__PURE__ */ s(j, { className: "h-ds-sm-plus w-ds-sm-plus cursor-pointer", children: [
|
|
81
|
-
|
|
82
|
-
/* @__PURE__ */ e(F, { className: "bg-
|
|
81
|
+
a.image ? /* @__PURE__ */ e(K, { src: a.image, alt: a.name }) : null,
|
|
82
|
+
/* @__PURE__ */ e(F, { className: "bg-surface-2 text-surface-fg", children: (g = a.name) == null ? void 0 : g.charAt(0).toUpperCase() })
|
|
83
83
|
] }) }) }) }),
|
|
84
84
|
/* @__PURE__ */ e(i, { side: "bottom", align: "center", children: "User Menu" })
|
|
85
85
|
] }),
|
|
86
86
|
/* @__PURE__ */ s(
|
|
87
87
|
E,
|
|
88
88
|
{
|
|
89
|
-
className: "w-[200px] rounded-ds-xl border border-border bg-
|
|
89
|
+
className: "w-[200px] rounded-ds-xl border border-surface-border-strong bg-surface-1 p-0 shadow-03",
|
|
90
90
|
sideOffset: 8,
|
|
91
91
|
align: "end",
|
|
92
92
|
children: [
|
|
93
|
-
/* @__PURE__ */ s("div", { className: "border-b border-border px-ds-05 py-ds-04", children: [
|
|
94
|
-
/* @__PURE__ */ e("p", { className: "text-ds-md text-
|
|
95
|
-
|
|
93
|
+
/* @__PURE__ */ s("div", { className: "border-b border-surface-border-strong px-ds-05 py-ds-04", children: [
|
|
94
|
+
/* @__PURE__ */ e("p", { className: "text-ds-md text-surface-fg", children: a.name }),
|
|
95
|
+
a.email && /* @__PURE__ */ e("p", { className: "text-ds-sm text-surface-fg-subtle", children: a.email })
|
|
96
96
|
] }),
|
|
97
97
|
/* @__PURE__ */ s(
|
|
98
|
-
|
|
98
|
+
d,
|
|
99
99
|
{
|
|
100
|
-
className: "flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-
|
|
101
|
-
onClick: () =>
|
|
100
|
+
className: "flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-surface-2",
|
|
101
|
+
onClick: () => c == null ? void 0 : c("/profile"),
|
|
102
102
|
children: [
|
|
103
|
-
/* @__PURE__ */ e(O, { className: "h-ico-sm w-ico-sm text-
|
|
104
|
-
/* @__PURE__ */ e("span", { className: "text-ds-md text-
|
|
103
|
+
/* @__PURE__ */ e(O, { className: "h-ico-sm w-ico-sm text-surface-fg-muted" }),
|
|
104
|
+
/* @__PURE__ */ e("span", { className: "text-ds-md text-surface-fg-muted", children: "Profile" })
|
|
105
105
|
]
|
|
106
106
|
}
|
|
107
107
|
),
|
|
108
108
|
o == null ? void 0 : o.map((r, T) => {
|
|
109
109
|
const A = {
|
|
110
|
-
error: "text-error",
|
|
111
|
-
success: "text-success",
|
|
112
|
-
warning: "text-warning",
|
|
113
|
-
info: "text-info"
|
|
114
|
-
},
|
|
115
|
-
return /* @__PURE__ */ s(
|
|
116
|
-
r.separator && /* @__PURE__ */ e(
|
|
110
|
+
error: "text-error-11",
|
|
111
|
+
success: "text-success-11",
|
|
112
|
+
warning: "text-warning-11",
|
|
113
|
+
info: "text-info-11"
|
|
114
|
+
}, x = r.color ? A[r.color] ?? "text-surface-fg-muted" : "text-surface-fg-muted";
|
|
115
|
+
return /* @__PURE__ */ s(w.Fragment, { children: [
|
|
116
|
+
r.separator && /* @__PURE__ */ e(N, { className: "bg-surface-border" }),
|
|
117
117
|
/* @__PURE__ */ s(
|
|
118
|
-
|
|
118
|
+
d,
|
|
119
119
|
{
|
|
120
|
-
className:
|
|
121
|
-
"flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-
|
|
122
|
-
r.disabled && "pointer-events-none opacity-
|
|
120
|
+
className: l(
|
|
121
|
+
"flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-surface-2",
|
|
122
|
+
r.disabled && "pointer-events-none opacity-action-disabled"
|
|
123
123
|
),
|
|
124
124
|
disabled: r.disabled,
|
|
125
125
|
onClick: () => {
|
|
126
|
-
r.disabled || (r.onClick ? r.onClick() : r.href && (
|
|
126
|
+
r.disabled || (r.onClick ? r.onClick() : r.href && (c == null || c(r.href)));
|
|
127
127
|
},
|
|
128
128
|
children: [
|
|
129
|
-
r.icon && /* @__PURE__ */ e("span", { className:
|
|
130
|
-
/* @__PURE__ */ e("span", { className:
|
|
131
|
-
r.badge != null && r.badge !== !1 && (typeof r.badge == "string" ? /* @__PURE__ */ e("span", { className: "ml-auto inline-flex h-[18px] min-w-[18px] items-center justify-center rounded-ds-full bg-error px-ds-02 text-[10px] font-semibold leading-none text-
|
|
129
|
+
r.icon && /* @__PURE__ */ e("span", { className: l("[&>svg]:h-ico-sm [&>svg]:w-ico-sm", x), children: r.icon }),
|
|
130
|
+
/* @__PURE__ */ e("span", { className: l("text-ds-md", x), children: r.label }),
|
|
131
|
+
r.badge != null && r.badge !== !1 && (typeof r.badge == "string" ? /* @__PURE__ */ e("span", { className: "ml-auto inline-flex h-[18px] min-w-[18px] items-center justify-center rounded-ds-full bg-error-9 px-ds-02 text-[10px] font-semibold leading-none text-accent-fg", children: r.badge }) : /* @__PURE__ */ e("span", { className: "ml-auto h-[8px] w-[8px] rounded-ds-full bg-error-9" }))
|
|
132
132
|
]
|
|
133
133
|
}
|
|
134
134
|
)
|
|
135
135
|
] }, r.label + T);
|
|
136
136
|
}),
|
|
137
137
|
/* @__PURE__ */ s(
|
|
138
|
-
|
|
138
|
+
d,
|
|
139
139
|
{
|
|
140
|
-
className: "flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-
|
|
140
|
+
className: "flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-surface-2",
|
|
141
141
|
onClick: M,
|
|
142
142
|
children: [
|
|
143
|
-
|
|
144
|
-
/* @__PURE__ */ e("span", { className: "text-ds-md text-
|
|
143
|
+
b === "dark" ? /* @__PURE__ */ e(P, { className: "h-ico-sm w-ico-sm text-surface-fg-muted" }) : /* @__PURE__ */ e(q, { className: "h-ico-sm w-ico-sm text-surface-fg-muted" }),
|
|
144
|
+
/* @__PURE__ */ e("span", { className: "text-ds-md text-surface-fg-muted", children: b === "dark" ? "Light Mode" : "Dark Mode" })
|
|
145
145
|
]
|
|
146
146
|
}
|
|
147
147
|
),
|
|
148
|
-
|
|
149
|
-
/* @__PURE__ */ e(
|
|
148
|
+
f && /* @__PURE__ */ s(D, { children: [
|
|
149
|
+
/* @__PURE__ */ e(N, { className: "bg-surface-border" }),
|
|
150
150
|
/* @__PURE__ */ s(
|
|
151
|
-
|
|
151
|
+
d,
|
|
152
152
|
{
|
|
153
|
-
className: "flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-
|
|
154
|
-
onClick:
|
|
153
|
+
className: "flex w-full cursor-pointer items-center gap-ds-03 px-ds-05 py-ds-04 hover:bg-surface-2",
|
|
154
|
+
onClick: f,
|
|
155
155
|
children: [
|
|
156
|
-
/* @__PURE__ */ e(G, { className: "h-ico-sm w-ico-sm text-error" }),
|
|
157
|
-
/* @__PURE__ */ e("span", { className: "text-ds-md text-error", children: "Logout" })
|
|
156
|
+
/* @__PURE__ */ e(G, { className: "h-ico-sm w-ico-sm text-error-11" }),
|
|
157
|
+
/* @__PURE__ */ e("span", { className: "text-ds-md text-error-11", children: "Logout" })
|
|
158
158
|
]
|
|
159
159
|
}
|
|
160
160
|
)
|