@timbal-ai/timbal-react 1.6.0 → 1.7.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/CHANGELOG.md +39 -0
- package/README.md +8 -0
- package/dist/app.cjs +167 -75
- package/dist/app.d.cts +3 -3
- package/dist/app.d.ts +3 -3
- package/dist/app.esm.js +5 -5
- package/dist/{chart-artifact-VAqgH-My.d.cts → chart-artifact-CuTiCITz.d.cts} +230 -15
- package/dist/{chart-artifact-C2pZQsaP.d.ts → chart-artifact-U-x0UNJm.d.ts} +230 -15
- package/dist/chat.esm.js +3 -3
- package/dist/{chunk-YYEI6XME.esm.js → chunk-22KWC2LS.esm.js} +5 -5
- package/dist/{chunk-MBS7XHV2.esm.js → chunk-45NXD3IG.esm.js} +3 -3
- package/dist/{chunk-24B4I4XC.esm.js → chunk-64RHAJVG.esm.js} +1 -1
- package/dist/{chunk-WQIQW7EM.esm.js → chunk-7AGIAQE6.esm.js} +1 -1
- package/dist/{chunk-NO5AWNWT.esm.js → chunk-7WU3IKAN.esm.js} +1 -1
- package/dist/{chunk-6SQMTBPL.esm.js → chunk-M5IBJBEY.esm.js} +109 -23
- package/dist/{chunk-HSL36SJ4.esm.js → chunk-PMMI7LBV.esm.js} +20 -8
- package/dist/{chunk-TMP7RIA7.esm.js → chunk-VKXOHVDE.esm.js} +2 -2
- package/dist/{chunk-ELEY66OH.esm.js → chunk-XOCOZU7J.esm.js} +11 -1
- package/dist/cli/timbal-ui-lint.mjs +534 -0
- package/dist/index.cjs +303 -200
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.esm.js +9 -9
- package/dist/{kanban-FFBeaZPS.d.cts → kanban-BQxWliCS.d.cts} +17 -0
- package/dist/{kanban-FFBeaZPS.d.ts → kanban-BQxWliCS.d.ts} +17 -0
- package/dist/studio.cjs +104 -85
- package/dist/studio.esm.js +6 -6
- package/dist/ui.cjs +6 -6
- package/dist/ui.d.cts +1 -1
- package/dist/ui.d.ts +1 -1
- package/dist/ui.esm.js +4 -4
- package/package.json +13 -3
package/dist/index.cjs
CHANGED
|
@@ -1643,14 +1643,14 @@ function DialogDescription({
|
|
|
1643
1643
|
className,
|
|
1644
1644
|
...props
|
|
1645
1645
|
}) {
|
|
1646
|
-
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
1647
|
-
|
|
1646
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_radix_ui2.Dialog.Description, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
1647
|
+
"div",
|
|
1648
1648
|
{
|
|
1649
1649
|
"data-slot": "dialog-description",
|
|
1650
1650
|
className: cn("text-sm text-muted-foreground", className),
|
|
1651
1651
|
...props
|
|
1652
1652
|
}
|
|
1653
|
-
);
|
|
1653
|
+
) });
|
|
1654
1654
|
}
|
|
1655
1655
|
function DialogHeader({ className, ...props }) {
|
|
1656
1656
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
@@ -6070,9 +6070,9 @@ var TimbalChatShell = ({
|
|
|
6070
6070
|
};
|
|
6071
6071
|
|
|
6072
6072
|
// src/studio/shell/studio-shell.tsx
|
|
6073
|
-
var
|
|
6073
|
+
var import_react50 = require("react");
|
|
6074
6074
|
var import_lucide_react14 = require("lucide-react");
|
|
6075
|
-
var
|
|
6075
|
+
var import_react51 = require("motion/react");
|
|
6076
6076
|
|
|
6077
6077
|
// src/design/sidebar-motion.ts
|
|
6078
6078
|
var STUDIO_SIDEBAR_EASE_ENTER = [0, 0, 0.2, 1];
|
|
@@ -6255,11 +6255,19 @@ function useStudioSidebarLayout() {
|
|
|
6255
6255
|
}
|
|
6256
6256
|
|
|
6257
6257
|
// src/studio/sidebar/sidebar.tsx
|
|
6258
|
-
var
|
|
6259
|
-
var
|
|
6258
|
+
var import_react44 = require("react");
|
|
6259
|
+
var import_react45 = require("motion/react");
|
|
6260
|
+
|
|
6261
|
+
// src/layout/shell-nav-context.tsx
|
|
6262
|
+
var import_react37 = require("react");
|
|
6263
|
+
var ShellNavContext = (0, import_react37.createContext)(null);
|
|
6264
|
+
var ShellNavProvider = ShellNavContext.Provider;
|
|
6265
|
+
function useOptionalShellNav() {
|
|
6266
|
+
return (0, import_react37.useContext)(ShellNavContext);
|
|
6267
|
+
}
|
|
6260
6268
|
|
|
6261
6269
|
// src/studio/sidebar/sidebar-entries.tsx
|
|
6262
|
-
var
|
|
6270
|
+
var import_react38 = require("motion/react");
|
|
6263
6271
|
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
6264
6272
|
var StudioSidebarEntries = ({
|
|
6265
6273
|
visible,
|
|
@@ -6267,12 +6275,12 @@ var StudioSidebarEntries = ({
|
|
|
6267
6275
|
children,
|
|
6268
6276
|
className
|
|
6269
6277
|
}) => {
|
|
6270
|
-
const reducedMotion = (0,
|
|
6278
|
+
const reducedMotion = (0, import_react38.useReducedMotion)();
|
|
6271
6279
|
if (reducedMotion) {
|
|
6272
6280
|
return visible ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: cn("flex min-h-0 flex-1 flex-col", className), children }) : null;
|
|
6273
6281
|
}
|
|
6274
6282
|
return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
|
|
6275
|
-
|
|
6283
|
+
import_react38.motion.div,
|
|
6276
6284
|
{
|
|
6277
6285
|
className: cn("flex min-h-0 flex-1 flex-col", className),
|
|
6278
6286
|
initial: false,
|
|
@@ -6292,11 +6300,11 @@ var StudioSidebarEntries = ({
|
|
|
6292
6300
|
};
|
|
6293
6301
|
|
|
6294
6302
|
// src/studio/sidebar/sidebar-footer.tsx
|
|
6295
|
-
var
|
|
6303
|
+
var import_react41 = require("react");
|
|
6296
6304
|
var import_lucide_react11 = require("lucide-react");
|
|
6297
6305
|
|
|
6298
6306
|
// src/auth/provider.tsx
|
|
6299
|
-
var
|
|
6307
|
+
var import_react39 = require("react");
|
|
6300
6308
|
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
6301
6309
|
function isInsideIframe() {
|
|
6302
6310
|
try {
|
|
@@ -6305,26 +6313,26 @@ function isInsideIframe() {
|
|
|
6305
6313
|
return true;
|
|
6306
6314
|
}
|
|
6307
6315
|
}
|
|
6308
|
-
var SessionContext = (0,
|
|
6316
|
+
var SessionContext = (0, import_react39.createContext)(void 0);
|
|
6309
6317
|
var useSession = () => {
|
|
6310
|
-
const context = (0,
|
|
6318
|
+
const context = (0, import_react39.useContext)(SessionContext);
|
|
6311
6319
|
if (context === void 0) {
|
|
6312
6320
|
throw new Error("useSession must be used within a SessionProvider");
|
|
6313
6321
|
}
|
|
6314
6322
|
return context;
|
|
6315
6323
|
};
|
|
6316
6324
|
var useOptionalSession = () => {
|
|
6317
|
-
const context = (0,
|
|
6325
|
+
const context = (0, import_react39.useContext)(SessionContext);
|
|
6318
6326
|
return context ?? null;
|
|
6319
6327
|
};
|
|
6320
6328
|
var SessionProvider = ({
|
|
6321
6329
|
children,
|
|
6322
6330
|
enabled = true
|
|
6323
6331
|
}) => {
|
|
6324
|
-
const [user, setUser] = (0,
|
|
6325
|
-
const [loading, setLoading] = (0,
|
|
6326
|
-
const [embedded] = (0,
|
|
6327
|
-
(0,
|
|
6332
|
+
const [user, setUser] = (0, import_react39.useState)(null);
|
|
6333
|
+
const [loading, setLoading] = (0, import_react39.useState)(enabled);
|
|
6334
|
+
const [embedded] = (0, import_react39.useState)(isInsideIframe);
|
|
6335
|
+
(0, import_react39.useEffect)(() => {
|
|
6328
6336
|
if (!enabled) {
|
|
6329
6337
|
setLoading(false);
|
|
6330
6338
|
return;
|
|
@@ -6385,7 +6393,7 @@ var SessionProvider = ({
|
|
|
6385
6393
|
messageCleanup?.();
|
|
6386
6394
|
};
|
|
6387
6395
|
}, [enabled, embedded]);
|
|
6388
|
-
const logout = (0,
|
|
6396
|
+
const logout = (0, import_react39.useCallback)(() => {
|
|
6389
6397
|
clearTokens();
|
|
6390
6398
|
setUser(null);
|
|
6391
6399
|
const returnTo = encodeURIComponent(
|
|
@@ -6433,17 +6441,17 @@ function studioSidebarNavItemClasses(iconOnly, isActive) {
|
|
|
6433
6441
|
}
|
|
6434
6442
|
|
|
6435
6443
|
// src/studio/sidebar/sidebar-entry-motion.tsx
|
|
6436
|
-
var
|
|
6444
|
+
var import_react40 = require("motion/react");
|
|
6437
6445
|
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
6438
6446
|
var StudioSidebarEntryMotion = ({
|
|
6439
6447
|
children,
|
|
6440
6448
|
className
|
|
6441
6449
|
}) => {
|
|
6442
|
-
const reducedMotion = (0,
|
|
6450
|
+
const reducedMotion = (0, import_react40.useReducedMotion)();
|
|
6443
6451
|
if (reducedMotion) {
|
|
6444
6452
|
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("div", { className, children });
|
|
6445
6453
|
}
|
|
6446
|
-
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
|
|
6454
|
+
return /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_react40.motion.div, { variants: studioSidebarEntryItemVariants, className: cn(className), children });
|
|
6447
6455
|
};
|
|
6448
6456
|
|
|
6449
6457
|
// src/studio/sidebar/sidebar-tooltip.tsx
|
|
@@ -6683,8 +6691,8 @@ var StudioSidebarFooter = ({
|
|
|
6683
6691
|
}) => {
|
|
6684
6692
|
const session = useOptionalSession();
|
|
6685
6693
|
const user = session?.user ?? null;
|
|
6686
|
-
const [isDark, setIsDark] = (0,
|
|
6687
|
-
(0,
|
|
6694
|
+
const [isDark, setIsDark] = (0, import_react41.useState)(false);
|
|
6695
|
+
(0, import_react41.useEffect)(() => {
|
|
6688
6696
|
if (typeof window === "undefined" || typeof document === "undefined") return;
|
|
6689
6697
|
const stored = window.localStorage.getItem(STORAGE_KEYS.theme);
|
|
6690
6698
|
if (stored) {
|
|
@@ -7036,14 +7044,14 @@ function TimbalMark({
|
|
|
7036
7044
|
}
|
|
7037
7045
|
|
|
7038
7046
|
// src/studio/sidebar/shell-inset-bridge-context.tsx
|
|
7039
|
-
var
|
|
7047
|
+
var import_react43 = require("react");
|
|
7040
7048
|
|
|
7041
7049
|
// src/layout/shell-inset-context.tsx
|
|
7042
|
-
var
|
|
7043
|
-
var ShellInsetContext = (0,
|
|
7050
|
+
var import_react42 = require("react");
|
|
7051
|
+
var ShellInsetContext = (0, import_react42.createContext)(null);
|
|
7044
7052
|
var ShellInsetProvider = ShellInsetContext.Provider;
|
|
7045
7053
|
function useShellInsetReporter() {
|
|
7046
|
-
return (0,
|
|
7054
|
+
return (0, import_react42.useContext)(ShellInsetContext);
|
|
7047
7055
|
}
|
|
7048
7056
|
|
|
7049
7057
|
// src/studio/sidebar/shell-inset-bridge-context.tsx
|
|
@@ -7052,7 +7060,7 @@ var StudioSidebarShellInsetBridge = ({
|
|
|
7052
7060
|
}) => {
|
|
7053
7061
|
const reportInset = useShellInsetReporter();
|
|
7054
7062
|
const { isMobile, isCollapsedRail } = useStudioSidebarLayout();
|
|
7055
|
-
(0,
|
|
7063
|
+
(0, import_react43.useLayoutEffect)(() => {
|
|
7056
7064
|
const insetPx = isMobile ? 0 : isCollapsedRail ? SIDEBAR_INSET_PX_COLLAPSED : SIDEBAR_INSET_PX_EXPANDED;
|
|
7057
7065
|
reportInset?.(insetPx);
|
|
7058
7066
|
onInsetChange?.(insetPx);
|
|
@@ -7095,7 +7103,7 @@ var StudioSidebarPanel = ({
|
|
|
7095
7103
|
logo,
|
|
7096
7104
|
emptyCaption = null
|
|
7097
7105
|
}) => {
|
|
7098
|
-
const reducedMotion = (0,
|
|
7106
|
+
const reducedMotion = (0, import_react45.useReducedMotion)();
|
|
7099
7107
|
const isCollapsedRail = widthCollapsed && !isMobile;
|
|
7100
7108
|
const iconOnlyLayout = studioSidebarIconOnlyLayout(isMobile, isCollapsedRail);
|
|
7101
7109
|
const isDrawerOpen = isMobile && mobileOpen;
|
|
@@ -7117,7 +7125,7 @@ var StudioSidebarPanel = ({
|
|
|
7117
7125
|
const brandNode = brand ?? /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(TimbalMark, { size: 32 });
|
|
7118
7126
|
const logoNode = logo ?? (isCustomBrand ? null : brandNode);
|
|
7119
7127
|
const panel = /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
|
|
7120
|
-
|
|
7128
|
+
import_react45.motion.div,
|
|
7121
7129
|
{
|
|
7122
7130
|
"data-sidebar-collapsed": isCollapsedRail ? "" : void 0,
|
|
7123
7131
|
className: cn(
|
|
@@ -7187,7 +7195,7 @@ var StudioSidebarPanel = ({
|
|
|
7187
7195
|
);
|
|
7188
7196
|
if (isMobile) {
|
|
7189
7197
|
return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
|
|
7190
|
-
|
|
7198
|
+
import_react45.motion.aside,
|
|
7191
7199
|
{
|
|
7192
7200
|
className: "fixed inset-y-0 left-0 z-[60] flex",
|
|
7193
7201
|
"aria-label": "Studio navigation",
|
|
@@ -7225,51 +7233,62 @@ var StudioSidebar = ({
|
|
|
7225
7233
|
onMobileOpenChange: onMobileOpenChangeProp,
|
|
7226
7234
|
onInsetChange
|
|
7227
7235
|
}) => {
|
|
7228
|
-
const reducedMotion = (0,
|
|
7236
|
+
const reducedMotion = (0, import_react45.useReducedMotion)();
|
|
7229
7237
|
const fetched = useWorkforces({ enabled: workforcesProp === void 0 });
|
|
7230
7238
|
const workforces = workforcesProp ?? fetched.workforces;
|
|
7231
|
-
const [internalSelected, setInternalSelected] = (0,
|
|
7239
|
+
const [internalSelected, setInternalSelected] = (0, import_react44.useState)(
|
|
7232
7240
|
selectedIdProp ?? ""
|
|
7233
7241
|
);
|
|
7234
|
-
(0,
|
|
7242
|
+
(0, import_react44.useEffect)(() => {
|
|
7235
7243
|
if (selectedIdProp !== void 0) return;
|
|
7236
7244
|
if (internalSelected) return;
|
|
7237
7245
|
const first = workforces[0]?.id ?? workforces[0]?.uid ?? workforces[0]?.name;
|
|
7238
7246
|
if (first) setInternalSelected(first);
|
|
7239
7247
|
}, [workforces, selectedIdProp, internalSelected]);
|
|
7240
7248
|
const selectedId = selectedIdProp ?? internalSelected ?? workforces[0]?.id ?? workforces[0]?.uid ?? workforces[0]?.name ?? "";
|
|
7241
|
-
const [collapsed, setCollapsed] = (0,
|
|
7249
|
+
const [collapsed, setCollapsed] = (0, import_react44.useState)(() => {
|
|
7242
7250
|
const persisted = readPersistedCollapsed(persistKey);
|
|
7243
7251
|
return persisted || defaultCollapsed;
|
|
7244
7252
|
});
|
|
7245
|
-
const handleCollapsedChange = (0,
|
|
7253
|
+
const handleCollapsedChange = (0, import_react44.useCallback)(
|
|
7246
7254
|
(next) => {
|
|
7247
7255
|
setCollapsed(next);
|
|
7248
7256
|
writePersistedCollapsed(persistKey, next);
|
|
7249
7257
|
},
|
|
7250
7258
|
[persistKey]
|
|
7251
7259
|
);
|
|
7252
|
-
const [isMobile, setIsMobile] = (0,
|
|
7260
|
+
const [isMobile, setIsMobile] = (0, import_react44.useState)(() => {
|
|
7253
7261
|
if (typeof window === "undefined") return false;
|
|
7254
7262
|
return window.innerWidth < mobileBreakpointPx;
|
|
7255
7263
|
});
|
|
7256
|
-
(0,
|
|
7264
|
+
(0, import_react44.useEffect)(() => {
|
|
7257
7265
|
if (typeof window === "undefined") return;
|
|
7258
7266
|
const onResize = () => setIsMobile(window.innerWidth < mobileBreakpointPx);
|
|
7259
7267
|
onResize();
|
|
7260
7268
|
window.addEventListener("resize", onResize);
|
|
7261
7269
|
return () => window.removeEventListener("resize", onResize);
|
|
7262
7270
|
}, [mobileBreakpointPx]);
|
|
7263
|
-
const
|
|
7264
|
-
const
|
|
7265
|
-
const
|
|
7271
|
+
const shellNav = useOptionalShellNav();
|
|
7272
|
+
const isControlled = mobileOpenProp !== void 0;
|
|
7273
|
+
const usingShellNav = !isControlled && shellNav !== null;
|
|
7274
|
+
const [internalMobileOpen, setInternalMobileOpen] = (0, import_react44.useState)(false);
|
|
7275
|
+
const mobileOpen = isControlled ? mobileOpenProp : usingShellNav ? shellNav.open : internalMobileOpen;
|
|
7276
|
+
const setMobileOpen = (0, import_react44.useCallback)(
|
|
7266
7277
|
(next) => {
|
|
7267
|
-
if (
|
|
7278
|
+
if (isControlled) {
|
|
7279
|
+
onMobileOpenChangeProp?.(next);
|
|
7280
|
+
return;
|
|
7281
|
+
}
|
|
7282
|
+
if (usingShellNav) {
|
|
7283
|
+
shellNav.setOpen(next);
|
|
7284
|
+
} else {
|
|
7285
|
+
setInternalMobileOpen(next);
|
|
7286
|
+
}
|
|
7268
7287
|
onMobileOpenChangeProp?.(next);
|
|
7269
7288
|
},
|
|
7270
|
-
[
|
|
7289
|
+
[isControlled, usingShellNav, shellNav, onMobileOpenChangeProp]
|
|
7271
7290
|
);
|
|
7272
|
-
const handleSelect = (0,
|
|
7291
|
+
const handleSelect = (0, import_react44.useCallback)(
|
|
7273
7292
|
(id) => {
|
|
7274
7293
|
if (selectedIdProp === void 0) setInternalSelected(id);
|
|
7275
7294
|
onSelect?.(id);
|
|
@@ -7277,10 +7296,10 @@ var StudioSidebar = ({
|
|
|
7277
7296
|
},
|
|
7278
7297
|
[selectedIdProp, onSelect, isMobile, setMobileOpen]
|
|
7279
7298
|
);
|
|
7280
|
-
(0,
|
|
7299
|
+
(0, import_react44.useEffect)(() => {
|
|
7281
7300
|
if (!isMobile && mobileOpen) setMobileOpen(false);
|
|
7282
7301
|
}, [isMobile, mobileOpen, setMobileOpen]);
|
|
7283
|
-
(0,
|
|
7302
|
+
(0, import_react44.useEffect)(() => {
|
|
7284
7303
|
if (!isMobile || !mobileOpen) return;
|
|
7285
7304
|
const onKeyDown = (e) => {
|
|
7286
7305
|
if (e.key === "Escape") setMobileOpen(false);
|
|
@@ -7298,7 +7317,7 @@ var StudioSidebar = ({
|
|
|
7298
7317
|
const entriesVisible = isMobile || phaseEntriesVisible;
|
|
7299
7318
|
const isCollapsedRail = widthCollapsed && !isMobile;
|
|
7300
7319
|
const iconOnlyLayout = studioSidebarIconOnlyLayout(isMobile, isCollapsedRail);
|
|
7301
|
-
const contextValue = (0,
|
|
7320
|
+
const contextValue = (0, import_react44.useMemo)(
|
|
7302
7321
|
() => ({
|
|
7303
7322
|
collapsed: effectiveCollapsed,
|
|
7304
7323
|
isMobile,
|
|
@@ -7334,23 +7353,23 @@ var StudioSidebar = ({
|
|
|
7334
7353
|
};
|
|
7335
7354
|
|
|
7336
7355
|
// src/studio/sidebar/sidebar-runtime-portal.tsx
|
|
7337
|
-
var
|
|
7356
|
+
var import_react46 = require("react");
|
|
7338
7357
|
var import_react_dom = require("react-dom");
|
|
7339
7358
|
var import_lucide_react13 = require("lucide-react");
|
|
7340
|
-
var
|
|
7359
|
+
var import_react47 = require("@assistant-ui/react");
|
|
7341
7360
|
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
7342
7361
|
var StudioSidebarRuntimePortal = ({
|
|
7343
7362
|
label = "New chat"
|
|
7344
7363
|
}) => {
|
|
7345
7364
|
const { iconOnlyLayout, isMobile, closeMobile } = useStudioSidebarLayout();
|
|
7346
|
-
const hasMessages = (0,
|
|
7365
|
+
const hasMessages = (0, import_react47.useThread)((s) => s.messages.length > 0);
|
|
7347
7366
|
const { clear } = useTimbalRuntime();
|
|
7348
|
-
const [anchor, setAnchor] = (0,
|
|
7349
|
-
const startNewChat = (0,
|
|
7367
|
+
const [anchor, setAnchor] = (0, import_react46.useState)(null);
|
|
7368
|
+
const startNewChat = (0, import_react46.useCallback)(() => {
|
|
7350
7369
|
clear();
|
|
7351
7370
|
if (isMobile) closeMobile?.();
|
|
7352
7371
|
}, [clear, isMobile, closeMobile]);
|
|
7353
|
-
(0,
|
|
7372
|
+
(0, import_react46.useLayoutEffect)(() => {
|
|
7354
7373
|
setAnchor(document.getElementById(DOM_IDS.sidebarRuntimeAnchor));
|
|
7355
7374
|
}, []);
|
|
7356
7375
|
if (!anchor || !hasMessages) return null;
|
|
@@ -7377,8 +7396,8 @@ var StudioSidebarRuntimePortal = ({
|
|
|
7377
7396
|
};
|
|
7378
7397
|
|
|
7379
7398
|
// src/studio/sidebar/welcome.tsx
|
|
7380
|
-
var
|
|
7381
|
-
var
|
|
7399
|
+
var import_react48 = require("motion/react");
|
|
7400
|
+
var import_react49 = require("@assistant-ui/react");
|
|
7382
7401
|
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
7383
7402
|
var welcomeStagger2 = {
|
|
7384
7403
|
initial: {},
|
|
@@ -7404,7 +7423,7 @@ var welcomeIcon2 = {
|
|
|
7404
7423
|
}
|
|
7405
7424
|
};
|
|
7406
7425
|
var StudioWelcome = ({ config, icon }) => {
|
|
7407
|
-
const isEmpty = (0,
|
|
7426
|
+
const isEmpty = (0, import_react49.useThread)((s) => s.messages.length === 0);
|
|
7408
7427
|
if (!isEmpty) return null;
|
|
7409
7428
|
const iconNode = icon ?? /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
7410
7429
|
TimbalMark,
|
|
@@ -7414,16 +7433,16 @@ var StudioWelcome = ({ config, icon }) => {
|
|
|
7414
7433
|
}
|
|
7415
7434
|
);
|
|
7416
7435
|
return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "aui-thread-welcome-root mx-auto my-auto flex w-full max-w-(--thread-max-width) grow flex-col", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "aui-thread-welcome-center flex w-full grow flex-col items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
|
|
7417
|
-
|
|
7436
|
+
import_react48.motion.div,
|
|
7418
7437
|
{
|
|
7419
7438
|
className: "aui-thread-welcome-message flex flex-col items-center justify-center px-2 text-center sm:px-4",
|
|
7420
7439
|
variants: welcomeStagger2,
|
|
7421
7440
|
initial: "initial",
|
|
7422
7441
|
animate: "animate",
|
|
7423
7442
|
children: [
|
|
7424
|
-
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
7443
|
+
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_react48.motion.div, { variants: welcomeIcon2, className: "mb-4 md:mb-5", children: iconNode }),
|
|
7425
7444
|
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
7426
|
-
|
|
7445
|
+
import_react48.motion.h1,
|
|
7427
7446
|
{
|
|
7428
7447
|
variants: welcomeItem2,
|
|
7429
7448
|
className: "aui-thread-welcome-message-inner text-xl font-semibold sm:text-2xl",
|
|
@@ -7431,7 +7450,7 @@ var StudioWelcome = ({ config, icon }) => {
|
|
|
7431
7450
|
}
|
|
7432
7451
|
),
|
|
7433
7452
|
/* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
|
|
7434
|
-
|
|
7453
|
+
import_react48.motion.p,
|
|
7435
7454
|
{
|
|
7436
7455
|
variants: welcomeItem2,
|
|
7437
7456
|
className: "aui-thread-welcome-message-inner mt-2 text-muted-foreground",
|
|
@@ -7445,7 +7464,7 @@ var StudioWelcome = ({ config, icon }) => {
|
|
|
7445
7464
|
|
|
7446
7465
|
// src/studio/shell/studio-shell.tsx
|
|
7447
7466
|
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
7448
|
-
var
|
|
7467
|
+
var import_react52 = require("react");
|
|
7449
7468
|
var DEFAULT_BREAKPOINT_PX2 = 768;
|
|
7450
7469
|
function readPersistedCollapsed2(key) {
|
|
7451
7470
|
if (!key || typeof window === "undefined") return false;
|
|
@@ -7488,7 +7507,7 @@ var TimbalStudioShell = ({
|
|
|
7488
7507
|
components,
|
|
7489
7508
|
...chatProps
|
|
7490
7509
|
}) => {
|
|
7491
|
-
const reducedMotion = (0,
|
|
7510
|
+
const reducedMotion = (0, import_react51.useReducedMotion)();
|
|
7492
7511
|
const shouldFetchWorkforces = !workforceId && workforcesProp === void 0;
|
|
7493
7512
|
const fetched = useWorkforces({
|
|
7494
7513
|
enabled: shouldFetchWorkforces,
|
|
@@ -7496,36 +7515,36 @@ var TimbalStudioShell = ({
|
|
|
7496
7515
|
baseUrl: workforcesBaseUrl
|
|
7497
7516
|
});
|
|
7498
7517
|
const workforces = workforcesProp ?? fetched.workforces;
|
|
7499
|
-
const [internalSelected, setInternalSelected] = (0,
|
|
7518
|
+
const [internalSelected, setInternalSelected] = (0, import_react50.useState)(
|
|
7500
7519
|
workforceId ?? ""
|
|
7501
7520
|
);
|
|
7502
|
-
(0,
|
|
7521
|
+
(0, import_react50.useEffect)(() => {
|
|
7503
7522
|
if (workforceId) return;
|
|
7504
7523
|
if (internalSelected) return;
|
|
7505
7524
|
const first = workforces[0]?.id ?? workforces[0]?.uid ?? workforces[0]?.name;
|
|
7506
7525
|
if (first) setInternalSelected(first);
|
|
7507
7526
|
}, [workforces, workforceId, internalSelected]);
|
|
7508
7527
|
const activeWorkforceId = workforceId ?? internalSelected ?? fetched.selectedId ?? "";
|
|
7509
|
-
const [collapsed, setCollapsed] = (0,
|
|
7528
|
+
const [collapsed, setCollapsed] = (0, import_react50.useState)(() => {
|
|
7510
7529
|
const persisted = readPersistedCollapsed2(persistKey);
|
|
7511
7530
|
return persisted || defaultCollapsed;
|
|
7512
7531
|
});
|
|
7513
|
-
const [isMobile, setIsMobile] = (0,
|
|
7532
|
+
const [isMobile, setIsMobile] = (0, import_react50.useState)(() => {
|
|
7514
7533
|
if (typeof window === "undefined") return false;
|
|
7515
7534
|
return window.innerWidth < mobileBreakpointPx;
|
|
7516
7535
|
});
|
|
7517
|
-
const [mobileSidebarOpen, setMobileSidebarOpen] = (0,
|
|
7518
|
-
(0,
|
|
7536
|
+
const [mobileSidebarOpen, setMobileSidebarOpen] = (0, import_react50.useState)(false);
|
|
7537
|
+
(0, import_react50.useEffect)(() => {
|
|
7519
7538
|
if (typeof window === "undefined") return;
|
|
7520
7539
|
const onResize = () => setIsMobile(window.innerWidth < mobileBreakpointPx);
|
|
7521
7540
|
onResize();
|
|
7522
7541
|
window.addEventListener("resize", onResize);
|
|
7523
7542
|
return () => window.removeEventListener("resize", onResize);
|
|
7524
7543
|
}, [mobileBreakpointPx]);
|
|
7525
|
-
(0,
|
|
7544
|
+
(0, import_react50.useEffect)(() => {
|
|
7526
7545
|
if (!isMobile) setMobileSidebarOpen(false);
|
|
7527
7546
|
}, [isMobile]);
|
|
7528
|
-
(0,
|
|
7547
|
+
(0, import_react50.useEffect)(() => {
|
|
7529
7548
|
if (!mobileSidebarOpen) return;
|
|
7530
7549
|
const onKeyDown = (e) => {
|
|
7531
7550
|
if (e.key === "Escape") setMobileSidebarOpen(false);
|
|
@@ -7549,21 +7568,21 @@ var TimbalStudioShell = ({
|
|
|
7549
7568
|
layoutDirection
|
|
7550
7569
|
);
|
|
7551
7570
|
const desktopInsetPx = widthCollapsed ? SIDEBAR_INSET_PX_COLLAPSED : SIDEBAR_INSET_PX_EXPANDED;
|
|
7552
|
-
const onCollapsedChange = (0,
|
|
7571
|
+
const onCollapsedChange = (0, import_react50.useCallback)(
|
|
7553
7572
|
(next) => {
|
|
7554
7573
|
setCollapsed(next);
|
|
7555
7574
|
writePersistedCollapsed2(persistKey, next);
|
|
7556
7575
|
},
|
|
7557
7576
|
[persistKey]
|
|
7558
7577
|
);
|
|
7559
|
-
const handleSelectWorkforce = (0,
|
|
7578
|
+
const handleSelectWorkforce = (0, import_react50.useCallback)(
|
|
7560
7579
|
(id) => {
|
|
7561
7580
|
if (!workforceId) setInternalSelected(id);
|
|
7562
7581
|
if (isMobile) setMobileSidebarOpen(false);
|
|
7563
7582
|
},
|
|
7564
7583
|
[workforceId, isMobile]
|
|
7565
7584
|
);
|
|
7566
|
-
const sidebarContext = (0,
|
|
7585
|
+
const sidebarContext = (0, import_react50.useMemo)(
|
|
7567
7586
|
() => ({
|
|
7568
7587
|
collapsed: effectiveCollapsed,
|
|
7569
7588
|
isMobile,
|
|
@@ -7573,7 +7592,7 @@ var TimbalStudioShell = ({
|
|
|
7573
7592
|
}),
|
|
7574
7593
|
[effectiveCollapsed, isMobile, isCollapsedRail, iconOnlyLayout]
|
|
7575
7594
|
);
|
|
7576
|
-
const resolvedComponents = (0,
|
|
7595
|
+
const resolvedComponents = (0, import_react50.useMemo)(() => {
|
|
7577
7596
|
const next = { Welcome: StudioWelcome, ...components };
|
|
7578
7597
|
next.Composer = makeComposerWithPortal(components?.Composer);
|
|
7579
7598
|
return next;
|
|
@@ -7632,7 +7651,7 @@ var TimbalStudioShell = ({
|
|
|
7632
7651
|
}
|
|
7633
7652
|
),
|
|
7634
7653
|
/* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
|
|
7635
|
-
|
|
7654
|
+
import_react51.motion.header,
|
|
7636
7655
|
{
|
|
7637
7656
|
className: cn(
|
|
7638
7657
|
"absolute top-0 right-0 z-40 flex items-start justify-between gap-2",
|
|
@@ -7673,7 +7692,7 @@ var TimbalStudioShell = ({
|
|
|
7673
7692
|
}
|
|
7674
7693
|
),
|
|
7675
7694
|
/* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
|
|
7676
|
-
|
|
7695
|
+
import_react51.motion.main,
|
|
7677
7696
|
{
|
|
7678
7697
|
className: cn(
|
|
7679
7698
|
"relative z-10 flex h-full min-w-0 flex-col",
|
|
@@ -7683,7 +7702,7 @@ var TimbalStudioShell = ({
|
|
|
7683
7702
|
initial: false,
|
|
7684
7703
|
animate: { paddingLeft: isMobile ? 12 : desktopInsetPx },
|
|
7685
7704
|
transition: layoutTransition,
|
|
7686
|
-
children: activeWorkforceId ? /* @__PURE__ */ (0,
|
|
7705
|
+
children: activeWorkforceId ? /* @__PURE__ */ (0, import_react52.createElement)(
|
|
7687
7706
|
TimbalChat,
|
|
7688
7707
|
{
|
|
7689
7708
|
...chatProps,
|
|
@@ -7717,7 +7736,7 @@ var userMessageRootClass = [
|
|
|
7717
7736
|
].join(" ");
|
|
7718
7737
|
|
|
7719
7738
|
// src/studio/sidebar/mode-toggle.tsx
|
|
7720
|
-
var
|
|
7739
|
+
var import_react53 = require("react");
|
|
7721
7740
|
var import_lucide_react15 = require("lucide-react");
|
|
7722
7741
|
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
7723
7742
|
function readStoredTheme() {
|
|
@@ -7747,8 +7766,8 @@ var ModeToggle = ({
|
|
|
7747
7766
|
label = "Toggle theme"
|
|
7748
7767
|
}) => {
|
|
7749
7768
|
const isControlled = theme !== void 0;
|
|
7750
|
-
const [internalIsDark, setInternalIsDark] = (0,
|
|
7751
|
-
(0,
|
|
7769
|
+
const [internalIsDark, setInternalIsDark] = (0, import_react53.useState)(false);
|
|
7770
|
+
(0, import_react53.useLayoutEffect)(() => {
|
|
7752
7771
|
if (isControlled) return;
|
|
7753
7772
|
const stored = readStoredTheme();
|
|
7754
7773
|
if (stored) {
|
|
@@ -7760,7 +7779,7 @@ var ModeToggle = ({
|
|
|
7760
7779
|
setInternalIsDark(document.documentElement.classList.contains("dark"));
|
|
7761
7780
|
}, [isControlled]);
|
|
7762
7781
|
const isDark = isControlled ? theme === "dark" : internalIsDark;
|
|
7763
|
-
const onClick = (0,
|
|
7782
|
+
const onClick = (0, import_react53.useCallback)(() => {
|
|
7764
7783
|
const next = isDark ? "light" : "dark";
|
|
7765
7784
|
if (setTheme) {
|
|
7766
7785
|
setTheme(next);
|
|
@@ -7796,11 +7815,11 @@ var ModeToggle = ({
|
|
|
7796
7815
|
};
|
|
7797
7816
|
|
|
7798
7817
|
// src/studio/mode-switch.tsx
|
|
7799
|
-
var
|
|
7818
|
+
var import_react56 = require("react");
|
|
7800
7819
|
|
|
7801
7820
|
// src/ui/pill-segmented-tabs.tsx
|
|
7802
|
-
var
|
|
7803
|
-
var
|
|
7821
|
+
var import_react54 = require("react");
|
|
7822
|
+
var import_react55 = require("motion/react");
|
|
7804
7823
|
|
|
7805
7824
|
// src/design/pill-segmented-classes.ts
|
|
7806
7825
|
var pillSegmentedTrackBase = "inline-flex w-fit max-w-max shrink-0 self-start items-center rounded-full";
|
|
@@ -7844,7 +7863,7 @@ var PillTab = ({
|
|
|
7844
7863
|
segmentClassName,
|
|
7845
7864
|
animateIndicator
|
|
7846
7865
|
}) => {
|
|
7847
|
-
const handlePress = (0,
|
|
7866
|
+
const handlePress = (0, import_react54.useCallback)(() => {
|
|
7848
7867
|
if (!disabled) onSelect(tabKey);
|
|
7849
7868
|
}, [disabled, onSelect, tabKey]);
|
|
7850
7869
|
return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
|
|
@@ -7861,7 +7880,7 @@ var PillTab = ({
|
|
|
7861
7880
|
),
|
|
7862
7881
|
children: [
|
|
7863
7882
|
isActive && animateIndicator ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
|
|
7864
|
-
|
|
7883
|
+
import_react55.motion.div,
|
|
7865
7884
|
{
|
|
7866
7885
|
layoutId,
|
|
7867
7886
|
className: pillSegmentedActiveIndicatorClass,
|
|
@@ -7882,9 +7901,9 @@ var PillSegmentedTabs = ({
|
|
|
7882
7901
|
layoutId: layoutIdProp,
|
|
7883
7902
|
"aria-label": ariaLabel
|
|
7884
7903
|
}) => {
|
|
7885
|
-
const reactId = (0,
|
|
7904
|
+
const reactId = (0, import_react54.useId)();
|
|
7886
7905
|
const layoutId = layoutIdProp ?? `pill-segmented-${reactId.replace(/:/g, "")}`;
|
|
7887
|
-
const reducedMotion = (0,
|
|
7906
|
+
const reducedMotion = (0, import_react55.useReducedMotion)();
|
|
7888
7907
|
const isFlush = trackVariant === "flush";
|
|
7889
7908
|
const trackClass2 = isFlush ? pillSegmentedTrackFlushClass : pillSegmentedTrackClass;
|
|
7890
7909
|
const segmentClassName = isFlush ? pillSegmentedFlushSegmentClass : pillSegmentedSegmentClass;
|
|
@@ -7903,7 +7922,7 @@ var PillSegmentedTabs = ({
|
|
|
7903
7922
|
tab.key
|
|
7904
7923
|
)) });
|
|
7905
7924
|
};
|
|
7906
|
-
var MemoPillSegmentedTabs = (0,
|
|
7925
|
+
var MemoPillSegmentedTabs = (0, import_react54.memo)(PillSegmentedTabs);
|
|
7907
7926
|
|
|
7908
7927
|
// src/studio/mode-switch.tsx
|
|
7909
7928
|
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
@@ -7911,7 +7930,7 @@ var STUDIO_NAV_MODE = {
|
|
|
7911
7930
|
BUILD: "build",
|
|
7912
7931
|
OPERATE: "operate"
|
|
7913
7932
|
};
|
|
7914
|
-
var StudioModeSwitch = (0,
|
|
7933
|
+
var StudioModeSwitch = (0, import_react56.memo)(
|
|
7915
7934
|
function StudioModeSwitch2({
|
|
7916
7935
|
value,
|
|
7917
7936
|
onChange,
|
|
@@ -7920,14 +7939,14 @@ var StudioModeSwitch = (0, import_react55.memo)(
|
|
|
7920
7939
|
manageLabel = "Manage",
|
|
7921
7940
|
"aria-label": ariaLabel = "Studio mode"
|
|
7922
7941
|
}) {
|
|
7923
|
-
const tabs = (0,
|
|
7942
|
+
const tabs = (0, import_react56.useMemo)(
|
|
7924
7943
|
() => [
|
|
7925
7944
|
{ key: STUDIO_NAV_MODE.BUILD, label: buildLabel },
|
|
7926
7945
|
{ key: STUDIO_NAV_MODE.OPERATE, label: manageLabel }
|
|
7927
7946
|
],
|
|
7928
7947
|
[buildLabel, manageLabel]
|
|
7929
7948
|
);
|
|
7930
|
-
const handleChange = (0,
|
|
7949
|
+
const handleChange = (0, import_react56.useCallback)(
|
|
7931
7950
|
(key) => {
|
|
7932
7951
|
if (key === STUDIO_NAV_MODE.BUILD || key === STUDIO_NAV_MODE.OPERATE) {
|
|
7933
7952
|
onChange(key);
|
|
@@ -8086,6 +8105,13 @@ var HOUSE_RULES = [
|
|
|
8086
8105
|
slop: `<span className="text-blue-600 bg-green-50">`,
|
|
8087
8106
|
good: `<span className="text-primary bg-muted">`
|
|
8088
8107
|
},
|
|
8108
|
+
{
|
|
8109
|
+
id: "chart-token-color",
|
|
8110
|
+
rule: "Pass chart and theme color tokens directly (var(--chart-1)) \u2014 never wrap them in hsl(), rgb(), or oklch().",
|
|
8111
|
+
why: "The --chart-N and theme tokens are already full OKLCH colors. Wrapping them in hsl()/rgb() is invalid CSS, so the chart renders empty/uncolored \u2014 and the build still passes, so it's a silent runtime bug.",
|
|
8112
|
+
slop: `<Cell fill="hsl(var(--chart-1))" />`,
|
|
8113
|
+
good: `<Cell fill="var(--chart-1)" />`
|
|
8114
|
+
},
|
|
8089
8115
|
{
|
|
8090
8116
|
id: "no-decorative-icons",
|
|
8091
8117
|
rule: "Icons must earn their place (action, nav, or status). Never add an icon beside a label that already says the thing.",
|
|
@@ -8132,7 +8158,11 @@ var HOUSE_RULES = [
|
|
|
8132
8158
|
{
|
|
8133
8159
|
id: "compose-from-blocks",
|
|
8134
8160
|
rule: "Build from premade blocks (MetricRow, MetricChartCard, DataTable, IntegrationCard). Drop to raw primitives only when no block fits.",
|
|
8135
|
-
why: "Slop appears the moment generation falls below the curated block layer."
|
|
8161
|
+
why: "Slop appears the moment generation falls below the curated block layer.",
|
|
8162
|
+
// "Should have used a block" is a judgement about absence, not a textual
|
|
8163
|
+
// pattern — no high-precision deterministic check exists, so this stays
|
|
8164
|
+
// prompt-only rather than risk false-positives blocking valid UIs.
|
|
8165
|
+
enforcement: "prompt-only"
|
|
8136
8166
|
},
|
|
8137
8167
|
{
|
|
8138
8168
|
id: "use-kit-controls",
|
|
@@ -8213,7 +8243,7 @@ The content region is a **padded scroll area** by default \u2014 great for stack
|
|
|
8213
8243
|
- Give the filling child **\`min-h-0 flex-1\`** (or \`h-full\`) so its own scroll/footer resolves \u2014 e.g. \`<TimbalChat className="min-h-0 flex-1" />\`, or a two-pane row where each pane is \`min-h-0 overflow-y-auto\`.
|
|
8214
8244
|
|
|
8215
8245
|
\`\`\`tsx
|
|
8216
|
-
<AppShell contentFill topbar
|
|
8246
|
+
<AppShell contentFill> {/* no global topbar / theme switch */}
|
|
8217
8247
|
<Page fill> {/* headerless: omit title */}
|
|
8218
8248
|
<TimbalChat workforceId="\u2026" className="min-h-0 flex-1" />
|
|
8219
8249
|
</Page>
|
|
@@ -8317,6 +8347,8 @@ The cause of slop is dropping **below** the curated block layer into raw primiti
|
|
|
8317
8347
|
|
|
8318
8348
|
Charts run on **recharts** with shadcn \`ChartContainer\` / \`ChartTooltipContent\` chrome (see \`src/ui/chart.tsx\`). Series colors default to \`--chart-1..6\`; override those CSS tokens to rebrand every chart.
|
|
8319
8349
|
|
|
8350
|
+
> **React 19 requirement \u2014 do not hand-roll SVG charts to work around this.** recharts under React 19 crashes (\`Cannot assign to read only property 'lanes'\`, blank route) when \`immer\` resolves to **11.0.0**. The fix is a dependency override in the app's \`package.json\` \u2014 \`"overrides": { "immer": ">=11.0.1" }\` (Yarn: \`"resolutions"\`) \u2014 **not** a code change. Always keep using \`LineAreaChart\` / \`PieChart\` / \`ChartPanel\`; never replace them with raw SVG/CSS charts.
|
|
8351
|
+
|
|
8320
8352
|
| Component | Use for |
|
|
8321
8353
|
|-----------|---------|
|
|
8322
8354
|
| \`LineAreaChart\` | Cartesian engine (shadcn-style chrome). Bar fills use theme gradients automatically. Props: \`data\`, \`xKey\`, \`series: [{ dataKey, label?, color? }]\`, \`variant\` (\`area\`\\|\`line\`\\|\`bar\`), \`orientation\` (\`horizontal\` for horizontal bars), \`stacked\`, \`curve\`, \`dots\`, \`gridLines\`, \`tooltipIndicator\`, \`layout\` (\`flush\` \u2014 hides axes by default; category + values on hover tooltip), \`showXAxis\` / \`showYAxis\` to opt back in, \`clipTicks\` (truncates long axis labels when axes are on), \`height\`, \`showLegend\`, \`formatX\`, \`formatValue\`, \`ariaLabel\`. |
|
|
@@ -8481,6 +8513,7 @@ var RAW_COLOR_RE = new RegExp(
|
|
|
8481
8513
|
"g"
|
|
8482
8514
|
);
|
|
8483
8515
|
var COLOR_LITERAL_RE = /#[0-9a-fA-F]{3,8}\b|\b(?:oklch|rgba?|hsla?)\s*\(/g;
|
|
8516
|
+
var COLOR_FN_WRAPPING_VAR_RE = /\b(?:hsl|hsla|rgb|rgba|oklch|oklab|lab|lch|hwb|color)\s*\(\s*var\(\s*--/i;
|
|
8484
8517
|
var INLINE_STYLE_COLOR_RE = /style=\{\{[^}]*\b(?:color|background|backgroundColor|borderColor|fill|stroke)\b/;
|
|
8485
8518
|
var BOLD_VALUE_RE = /text-(?:xl|2xl|3xl|4xl|5xl|6xl)[^"'`]*\bfont-(?:bold|extrabold|black|semibold)|font-(?:bold|extrabold|black|semibold)[^"'`]*text-(?:xl|2xl|3xl|4xl|5xl|6xl)/;
|
|
8486
8519
|
var GRADIENT_RE = /\bbg-(?:gradient|linear|radial|conic)-/;
|
|
@@ -8497,15 +8530,32 @@ var GRADIENT_DIRECTIONS = /* @__PURE__ */ new Set([
|
|
|
8497
8530
|
var ICON_IMPORT_RE = /from\s+["']lucide-react["']/;
|
|
8498
8531
|
var RAW_CONTROL_SURFACE_RE = /\bborder-input\b/;
|
|
8499
8532
|
var COLORED_HOVER_RE = /\bhover:(?:bg|from|to|via)-(?:primary|destructive|success|warn|danger|blue|emerald|green|amber|red|indigo|violet|purple|pink|rose|sky|cyan|teal|lime|yellow|orange|fuchsia)\b/;
|
|
8533
|
+
var TREND_CONTEXT_RE = /\b(?:trend|delta|TrendingUp|TrendingDown|ArrowUp|ArrowDown|ArrowUpRight|ArrowDownRight|MoveUp|MoveDown)\b|[+\-]\d+(?:\.\d+)?\s*%/;
|
|
8534
|
+
var TREND_COLOR_RE = /\b(?:text|bg|border)-(?:success|destructive|emerald|green|lime|teal|red|rose|orange|amber)(?:-\d{2,3})?(?:\/\d{1,3})?\b/;
|
|
8500
8535
|
var RESERVED_GRADIENT_SET = new Set(RESERVED_GRADIENT_TOKENS);
|
|
8501
8536
|
function stripVariants(util) {
|
|
8502
8537
|
return util.replace(/^(?:[a-z-]+:)*/, "");
|
|
8503
8538
|
}
|
|
8539
|
+
function describeArg(value) {
|
|
8540
|
+
if (value === null) return "null";
|
|
8541
|
+
if (Array.isArray(value)) return "an array";
|
|
8542
|
+
const t = typeof value;
|
|
8543
|
+
if (t === "object") {
|
|
8544
|
+
const keys = Object.keys(value).slice(0, 4);
|
|
8545
|
+
return keys.length ? `an object with keys { ${keys.join(", ")} }` : "an object";
|
|
8546
|
+
}
|
|
8547
|
+
return `a ${t}`;
|
|
8548
|
+
}
|
|
8504
8549
|
function isCommentOrImport(line) {
|
|
8505
8550
|
const t = line.trim();
|
|
8506
8551
|
return t.startsWith("//") || t.startsWith("*") || t.startsWith("/*") || t.startsWith("import ") || t.startsWith("export ");
|
|
8507
8552
|
}
|
|
8508
8553
|
function lintGeneratedUi(source, options = {}) {
|
|
8554
|
+
if (typeof source !== "string") {
|
|
8555
|
+
throw new TypeError(
|
|
8556
|
+
`lintGeneratedUi(source, options?) expects the generated code as a string, but received ${describeArg(source)}. Pass the raw .tsx source \u2014 lintGeneratedUi(code) \u2014 not an object like { filename, source } and not a previous LintResult.`
|
|
8557
|
+
);
|
|
8558
|
+
}
|
|
8509
8559
|
const maxIcons = options.maxIconsPerView ?? SLOP_BUDGETS.maxIconsPerView;
|
|
8510
8560
|
const maxRowDividers = options.maxRowDividers ?? SLOP_BUDGETS.maxRowDividers;
|
|
8511
8561
|
const findings = [];
|
|
@@ -8540,6 +8590,16 @@ function lintGeneratedUi(source, options = {}) {
|
|
|
8540
8590
|
if (cardMatch) {
|
|
8541
8591
|
const isSelfClosing = /\/>/.test(line) && line.indexOf(cardMatch[0]) < line.indexOf("/>");
|
|
8542
8592
|
if (!isSelfClosing) {
|
|
8593
|
+
if (openCards.length > 0) {
|
|
8594
|
+
const parentCard = openCards[openCards.length - 1];
|
|
8595
|
+
findings.push({
|
|
8596
|
+
rule: "no-card-in-card",
|
|
8597
|
+
severity: "warn",
|
|
8598
|
+
line: lineNo,
|
|
8599
|
+
message: `Card inside card. A <${cardMatch[1]}> is nested inside the <${parentCard.type}> opened on L${parentCard.line}. Double borders/shadows add no information \u2014 group with spacing or a <Section> instead.`,
|
|
8600
|
+
snippet: line.trim().slice(0, 120)
|
|
8601
|
+
});
|
|
8602
|
+
}
|
|
8543
8603
|
openCards.push({ type: cardMatch[1], line: lineNo });
|
|
8544
8604
|
}
|
|
8545
8605
|
}
|
|
@@ -8575,7 +8635,17 @@ function lintGeneratedUi(source, options = {}) {
|
|
|
8575
8635
|
});
|
|
8576
8636
|
}
|
|
8577
8637
|
}
|
|
8578
|
-
const
|
|
8638
|
+
const wrapsTokenInColorFn = COLOR_FN_WRAPPING_VAR_RE.test(line);
|
|
8639
|
+
if (wrapsTokenInColorFn) {
|
|
8640
|
+
findings.push({
|
|
8641
|
+
rule: "chart-token-color-fn",
|
|
8642
|
+
severity: "error",
|
|
8643
|
+
line: lineNo,
|
|
8644
|
+
message: "Color function wrapping a token (e.g. hsl(var(--chart-1))). The --chart-N and theme tokens are already OKLCH colors \u2014 wrapping them in hsl()/rgb() is invalid CSS and renders an empty/uncolored chart (the build still passes). Pass the token directly: var(--chart-1), or let the app-kit charts use --chart-N automatically.",
|
|
8645
|
+
snippet: line.trim().slice(0, 120)
|
|
8646
|
+
});
|
|
8647
|
+
}
|
|
8648
|
+
const literals = wrapsTokenInColorFn ? null : line.match(COLOR_LITERAL_RE);
|
|
8579
8649
|
if (literals) {
|
|
8580
8650
|
findings.push({
|
|
8581
8651
|
rule: "color-literal",
|
|
@@ -8612,6 +8682,15 @@ function lintGeneratedUi(source, options = {}) {
|
|
|
8612
8682
|
snippet: line.trim().slice(0, 120)
|
|
8613
8683
|
});
|
|
8614
8684
|
}
|
|
8685
|
+
if (TREND_CONTEXT_RE.test(line) && TREND_COLOR_RE.test(line)) {
|
|
8686
|
+
findings.push({
|
|
8687
|
+
rule: "neutral-trend",
|
|
8688
|
+
severity: "warn",
|
|
8689
|
+
line: lineNo,
|
|
8690
|
+
message: "Colored trend indicator. House style: don't tint deltas green/red on every metric \u2014 show a trend only when the change is the point, and keep it muted (text-muted-foreground).",
|
|
8691
|
+
snippet: line.trim().slice(0, 120)
|
|
8692
|
+
});
|
|
8693
|
+
}
|
|
8615
8694
|
if (BOLD_VALUE_RE.test(line)) {
|
|
8616
8695
|
findings.push({
|
|
8617
8696
|
rule: "bold-metric",
|
|
@@ -8717,6 +8796,11 @@ function lintGeneratedUi(source, options = {}) {
|
|
|
8717
8796
|
};
|
|
8718
8797
|
}
|
|
8719
8798
|
function formatLintReport(findings) {
|
|
8799
|
+
if (!Array.isArray(findings)) {
|
|
8800
|
+
throw new TypeError(
|
|
8801
|
+
`formatLintReport(findings) expects the findings array, but received ${describeArg(findings)}. Pass result.findings \u2014 formatLintReport(lintGeneratedUi(code).findings) \u2014 not the whole LintResult.`
|
|
8802
|
+
);
|
|
8803
|
+
}
|
|
8720
8804
|
if (findings.length === 0) return "";
|
|
8721
8805
|
const lines = findings.slice().sort((a, b) => a.line - b.line).map((f) => {
|
|
8722
8806
|
const tag = f.severity === "error" ? "ERROR" : "warn ";
|
|
@@ -9427,7 +9511,7 @@ var TimbalThemeStyle = ({
|
|
|
9427
9511
|
};
|
|
9428
9512
|
|
|
9429
9513
|
// src/app/layout/app-density-context.tsx
|
|
9430
|
-
var
|
|
9514
|
+
var import_react57 = require("react");
|
|
9431
9515
|
|
|
9432
9516
|
// src/design/app-classes.ts
|
|
9433
9517
|
var appPageColumnClass = "mx-auto w-full max-w-[100rem] px-4 md:px-6 lg:px-8";
|
|
@@ -9563,7 +9647,7 @@ function appDensityClass(key, density = "default") {
|
|
|
9563
9647
|
|
|
9564
9648
|
// src/app/layout/app-density-context.tsx
|
|
9565
9649
|
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
9566
|
-
var AppDensityContext = (0,
|
|
9650
|
+
var AppDensityContext = (0, import_react57.createContext)("default");
|
|
9567
9651
|
var AppDensityProvider = ({
|
|
9568
9652
|
density = "default",
|
|
9569
9653
|
children
|
|
@@ -9571,7 +9655,7 @@ var AppDensityProvider = ({
|
|
|
9571
9655
|
return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(AppDensityContext.Provider, { value: density, children });
|
|
9572
9656
|
};
|
|
9573
9657
|
function useAppDensity() {
|
|
9574
|
-
return (0,
|
|
9658
|
+
return (0, import_react57.useContext)(AppDensityContext);
|
|
9575
9659
|
}
|
|
9576
9660
|
function useAppDensityClass(key, override) {
|
|
9577
9661
|
const inherited = useAppDensity();
|
|
@@ -9627,7 +9711,7 @@ function metricTilesGridColsClass(n) {
|
|
|
9627
9711
|
}
|
|
9628
9712
|
|
|
9629
9713
|
// src/charts/sparkline.tsx
|
|
9630
|
-
var
|
|
9714
|
+
var import_react58 = require("react");
|
|
9631
9715
|
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
9632
9716
|
var Sparkline = ({
|
|
9633
9717
|
data,
|
|
@@ -9643,9 +9727,9 @@ var Sparkline = ({
|
|
|
9643
9727
|
labels,
|
|
9644
9728
|
formatValue
|
|
9645
9729
|
}) => {
|
|
9646
|
-
const uid = (0,
|
|
9647
|
-
const containerRef = (0,
|
|
9648
|
-
const [activeIndex, setActiveIndex] = (0,
|
|
9730
|
+
const uid = (0, import_react58.useId)();
|
|
9731
|
+
const containerRef = (0, import_react58.useRef)(null);
|
|
9732
|
+
const [activeIndex, setActiveIndex] = (0, import_react58.useState)(null);
|
|
9649
9733
|
const values = data.map((d) => typeof d === "number" ? d : toNum(d[dataKey]));
|
|
9650
9734
|
if (values.length === 0) {
|
|
9651
9735
|
return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: cn("inline-block", className), style: { width, height } });
|
|
@@ -9902,29 +9986,29 @@ var MetricTile = ({
|
|
|
9902
9986
|
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
9903
9987
|
|
|
9904
9988
|
// src/app/layout/AppShell.tsx
|
|
9989
|
+
var import_lucide_react16 = require("lucide-react");
|
|
9905
9990
|
var import_react60 = require("motion/react");
|
|
9906
9991
|
var import_react61 = require("react");
|
|
9907
9992
|
|
|
9908
9993
|
// src/app/layout/app-shell-chat-context.tsx
|
|
9909
|
-
var
|
|
9910
|
-
var AppShellChatContext = (0,
|
|
9994
|
+
var import_react59 = require("react");
|
|
9995
|
+
var AppShellChatContext = (0, import_react59.createContext)(null);
|
|
9911
9996
|
var AppShellChatProvider = AppShellChatContext.Provider;
|
|
9912
9997
|
function useAppShellChat() {
|
|
9913
|
-
return (0,
|
|
9998
|
+
return (0, import_react59.useContext)(AppShellChatContext);
|
|
9914
9999
|
}
|
|
9915
10000
|
|
|
9916
10001
|
// src/app/layout/app-shell-nav-context.tsx
|
|
9917
|
-
var
|
|
9918
|
-
var
|
|
9919
|
-
|
|
10002
|
+
var AppShellNavProvider = ShellNavProvider;
|
|
10003
|
+
var NAV_NOOP = {
|
|
10004
|
+
open: false,
|
|
10005
|
+
setOpen: () => {
|
|
10006
|
+
},
|
|
10007
|
+
toggle: () => {
|
|
10008
|
+
}
|
|
10009
|
+
};
|
|
9920
10010
|
function useAppShellNav() {
|
|
9921
|
-
return (
|
|
9922
|
-
open: false,
|
|
9923
|
-
setOpen: () => {
|
|
9924
|
-
},
|
|
9925
|
-
toggle: () => {
|
|
9926
|
-
}
|
|
9927
|
-
};
|
|
10011
|
+
return useOptionalShellNav() ?? NAV_NOOP;
|
|
9928
10012
|
}
|
|
9929
10013
|
|
|
9930
10014
|
// src/app/layout/AppShell.tsx
|
|
@@ -9935,6 +10019,12 @@ var floatingTriggerClass = cn(
|
|
|
9935
10019
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
|
|
9936
10020
|
"bottom-6 right-6 max-sm:bottom-4 max-sm:right-4"
|
|
9937
10021
|
);
|
|
10022
|
+
var floatingNavTriggerClass = cn(
|
|
10023
|
+
"aui-app-shell-nav-trigger-fixed fixed left-4 top-4 z-30 inline-flex size-10 items-center justify-center rounded-xl md:hidden",
|
|
10024
|
+
"border border-border/60 bg-card/85 text-foreground shadow-card-elevated backdrop-blur-xl supports-backdrop-filter:bg-card/75",
|
|
10025
|
+
"transition-colors hover:bg-card",
|
|
10026
|
+
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background"
|
|
10027
|
+
);
|
|
9938
10028
|
var floatingPanelClass = cn(
|
|
9939
10029
|
"aui-app-shell-chat-float fixed z-50 flex flex-col overflow-hidden rounded-2xl border border-border/60 shadow-card-elevated",
|
|
9940
10030
|
"bg-card/85 backdrop-blur-xl supports-backdrop-filter:bg-card/75",
|
|
@@ -10025,12 +10115,14 @@ var AppShell = ({
|
|
|
10025
10115
|
navOpen: navOpenProp,
|
|
10026
10116
|
defaultNavOpen = false,
|
|
10027
10117
|
onNavOpenChange,
|
|
10118
|
+
mobileSidebarTrigger = "auto",
|
|
10028
10119
|
className,
|
|
10029
10120
|
mainClassName,
|
|
10030
10121
|
contentFill = false
|
|
10031
10122
|
}) => {
|
|
10032
10123
|
const topbarContent = topbar ?? header;
|
|
10033
10124
|
const hasChat = Boolean(chat);
|
|
10125
|
+
const showFloatingNavTrigger = Boolean(sidebar) && mobileSidebarTrigger !== "none" && !(mobileSidebarTrigger === "topbar") && !topbarContent;
|
|
10034
10126
|
const [uncontrolledNavOpen, setUncontrolledNavOpen] = (0, import_react61.useState)(defaultNavOpen);
|
|
10035
10127
|
const isNavControlled = navOpenProp !== void 0;
|
|
10036
10128
|
const navOpen = isNavControlled ? navOpenProp : uncontrolledNavOpen;
|
|
@@ -10090,6 +10182,17 @@ var AppShell = ({
|
|
|
10090
10182
|
style: studioChromeShellStyle,
|
|
10091
10183
|
children: [
|
|
10092
10184
|
sidebar,
|
|
10185
|
+
showFloatingNavTrigger && !navOpen ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
10186
|
+
"button",
|
|
10187
|
+
{
|
|
10188
|
+
type: "button",
|
|
10189
|
+
"aria-label": "Open navigation",
|
|
10190
|
+
"aria-expanded": false,
|
|
10191
|
+
onClick: () => setNavOpen(true),
|
|
10192
|
+
className: floatingNavTriggerClass,
|
|
10193
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_lucide_react16.MenuIcon, { className: "size-5", "aria-hidden": true })
|
|
10194
|
+
}
|
|
10195
|
+
) : null,
|
|
10093
10196
|
sidebar && navOpen ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
10094
10197
|
"button",
|
|
10095
10198
|
{
|
|
@@ -10174,7 +10277,7 @@ var AppShellChatTrigger = ({
|
|
|
10174
10277
|
};
|
|
10175
10278
|
|
|
10176
10279
|
// src/app/layout/AppShellSidebarTrigger.tsx
|
|
10177
|
-
var
|
|
10280
|
+
var import_lucide_react17 = require("lucide-react");
|
|
10178
10281
|
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
10179
10282
|
var AppShellSidebarTrigger = ({
|
|
10180
10283
|
label = "Open navigation",
|
|
@@ -10193,7 +10296,7 @@ var AppShellSidebarTrigger = ({
|
|
|
10193
10296
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-foreground/10",
|
|
10194
10297
|
className
|
|
10195
10298
|
),
|
|
10196
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(
|
|
10299
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime65.jsx)(import_lucide_react17.MenuIcon, { className: "size-5", "aria-hidden": true })
|
|
10197
10300
|
}
|
|
10198
10301
|
);
|
|
10199
10302
|
};
|
|
@@ -10345,7 +10448,7 @@ function useAppCopilotContext() {
|
|
|
10345
10448
|
}
|
|
10346
10449
|
|
|
10347
10450
|
// src/app/chat/AppChatPanel.tsx
|
|
10348
|
-
var
|
|
10451
|
+
var import_lucide_react18 = require("lucide-react");
|
|
10349
10452
|
var import_jsx_runtime71 = require("react/jsx-runtime");
|
|
10350
10453
|
var shellClass = "aui-app-chat-panel flex h-full min-h-0 flex-col overflow-hidden";
|
|
10351
10454
|
var chromeClass = cn(
|
|
@@ -10399,7 +10502,7 @@ var AppChatPanel = ({
|
|
|
10399
10502
|
className: closeButtonClass,
|
|
10400
10503
|
onClick: () => shellChat.setOpen(false),
|
|
10401
10504
|
"aria-label": "Close assistant",
|
|
10402
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
10505
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_lucide_react18.XIcon, { className: "size-4", "aria-hidden": true })
|
|
10403
10506
|
}
|
|
10404
10507
|
) }) : null,
|
|
10405
10508
|
/* @__PURE__ */ (0, import_jsx_runtime71.jsx)("div", { className: bodyClass, children: /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(
|
|
@@ -10928,7 +11031,7 @@ var ResourceCard = ({
|
|
|
10928
11031
|
};
|
|
10929
11032
|
|
|
10930
11033
|
// src/app/surfaces/AlertCard.tsx
|
|
10931
|
-
var
|
|
11034
|
+
var import_lucide_react19 = require("lucide-react");
|
|
10932
11035
|
var import_jsx_runtime82 = require("react/jsx-runtime");
|
|
10933
11036
|
var alertCardShellClass = cn(
|
|
10934
11037
|
"flex flex-col rounded-2xl p-4 text-left font-normal border border-border shadow-card",
|
|
@@ -10945,11 +11048,11 @@ var alertCardInteractiveClass = cn(
|
|
|
10945
11048
|
);
|
|
10946
11049
|
|
|
10947
11050
|
// src/app/surfaces/CatalogCard.tsx
|
|
10948
|
-
var
|
|
11051
|
+
var import_lucide_react21 = require("lucide-react");
|
|
10949
11052
|
|
|
10950
11053
|
// src/ui/copy-button.tsx
|
|
10951
11054
|
var React5 = __toESM(require("react"), 1);
|
|
10952
|
-
var
|
|
11055
|
+
var import_lucide_react20 = require("lucide-react");
|
|
10953
11056
|
var import_jsx_runtime83 = require("react/jsx-runtime");
|
|
10954
11057
|
function CopyButton({
|
|
10955
11058
|
value,
|
|
@@ -10975,7 +11078,7 @@ function CopyButton({
|
|
|
10975
11078
|
} catch {
|
|
10976
11079
|
}
|
|
10977
11080
|
};
|
|
10978
|
-
const Icon = copied ?
|
|
11081
|
+
const Icon = copied ? import_lucide_react20.CheckIcon : import_lucide_react20.CopyIcon;
|
|
10979
11082
|
return /* @__PURE__ */ (0, import_jsx_runtime83.jsxs)(
|
|
10980
11083
|
"button",
|
|
10981
11084
|
{
|
|
@@ -11536,7 +11639,7 @@ var FieldTextarea = ({
|
|
|
11536
11639
|
|
|
11537
11640
|
// src/app/forms/FieldSelect.tsx
|
|
11538
11641
|
var import_react71 = require("react");
|
|
11539
|
-
var
|
|
11642
|
+
var import_lucide_react22 = require("lucide-react");
|
|
11540
11643
|
var import_jsx_runtime98 = require("react/jsx-runtime");
|
|
11541
11644
|
var selectWrapClass = "relative";
|
|
11542
11645
|
var selectClass = cn(
|
|
@@ -11575,7 +11678,7 @@ var FieldSelect = ({
|
|
|
11575
11678
|
}
|
|
11576
11679
|
),
|
|
11577
11680
|
/* @__PURE__ */ (0, import_jsx_runtime98.jsx)(
|
|
11578
|
-
|
|
11681
|
+
import_lucide_react22.ChevronDownIcon,
|
|
11579
11682
|
{
|
|
11580
11683
|
className: "pointer-events-none absolute top-1/2 right-3 size-4 -translate-y-1/2 text-muted-foreground",
|
|
11581
11684
|
"aria-hidden": true
|
|
@@ -11642,7 +11745,7 @@ var FieldSwitch = ({
|
|
|
11642
11745
|
};
|
|
11643
11746
|
|
|
11644
11747
|
// src/app/forms/SearchInput.tsx
|
|
11645
|
-
var
|
|
11748
|
+
var import_lucide_react23 = require("lucide-react");
|
|
11646
11749
|
var import_jsx_runtime100 = require("react/jsx-runtime");
|
|
11647
11750
|
var SearchInput = ({
|
|
11648
11751
|
className,
|
|
@@ -11658,7 +11761,7 @@ var SearchInput = ({
|
|
|
11658
11761
|
className
|
|
11659
11762
|
),
|
|
11660
11763
|
children: [
|
|
11661
|
-
/* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
|
|
11764
|
+
/* @__PURE__ */ (0, import_jsx_runtime100.jsx)(import_lucide_react23.SearchIcon, { className: "size-4 shrink-0 text-muted-foreground", "aria-hidden": true }),
|
|
11662
11765
|
/* @__PURE__ */ (0, import_jsx_runtime100.jsx)(
|
|
11663
11766
|
"input",
|
|
11664
11767
|
{
|
|
@@ -11719,11 +11822,11 @@ var FilterField = ({
|
|
|
11719
11822
|
|
|
11720
11823
|
// src/app/data/FilterDropdown.tsx
|
|
11721
11824
|
var import_react73 = require("react");
|
|
11722
|
-
var
|
|
11825
|
+
var import_lucide_react26 = require("lucide-react");
|
|
11723
11826
|
|
|
11724
11827
|
// src/ui/checkbox.tsx
|
|
11725
11828
|
var import_radix_ui7 = require("radix-ui");
|
|
11726
|
-
var
|
|
11829
|
+
var import_lucide_react24 = require("lucide-react");
|
|
11727
11830
|
var import_jsx_runtime104 = require("react/jsx-runtime");
|
|
11728
11831
|
function Checkbox({
|
|
11729
11832
|
className,
|
|
@@ -11745,7 +11848,7 @@ function Checkbox({
|
|
|
11745
11848
|
{
|
|
11746
11849
|
"data-slot": "checkbox-indicator",
|
|
11747
11850
|
className: "flex items-center justify-center text-current animate-checkbox-pop",
|
|
11748
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(
|
|
11851
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime104.jsx)(import_lucide_react24.CheckIcon, { className: "size-2.5 stroke-[3.5px]" })
|
|
11749
11852
|
}
|
|
11750
11853
|
)
|
|
11751
11854
|
}
|
|
@@ -11754,7 +11857,7 @@ function Checkbox({
|
|
|
11754
11857
|
|
|
11755
11858
|
// src/ui/select.tsx
|
|
11756
11859
|
var import_radix_ui8 = require("radix-ui");
|
|
11757
|
-
var
|
|
11860
|
+
var import_lucide_react25 = require("lucide-react");
|
|
11758
11861
|
var import_jsx_runtime105 = require("react/jsx-runtime");
|
|
11759
11862
|
function Select({
|
|
11760
11863
|
...props
|
|
@@ -11790,7 +11893,7 @@ function SelectTrigger({
|
|
|
11790
11893
|
...props,
|
|
11791
11894
|
children: [
|
|
11792
11895
|
children,
|
|
11793
|
-
/* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_radix_ui8.Select.Icon, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(
|
|
11896
|
+
/* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_radix_ui8.Select.Icon, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_lucide_react25.ChevronDownIcon, { className: "size-4 opacity-50" }) })
|
|
11794
11897
|
]
|
|
11795
11898
|
}
|
|
11796
11899
|
);
|
|
@@ -11859,7 +11962,7 @@ function SelectItem({
|
|
|
11859
11962
|
),
|
|
11860
11963
|
...props,
|
|
11861
11964
|
children: [
|
|
11862
|
-
/* @__PURE__ */ (0, import_jsx_runtime105.jsx)("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_radix_ui8.Select.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(
|
|
11965
|
+
/* @__PURE__ */ (0, import_jsx_runtime105.jsx)("span", { className: "absolute right-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_radix_ui8.Select.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_lucide_react25.CheckIcon, { className: "size-4" }) }) }),
|
|
11863
11966
|
/* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_radix_ui8.Select.ItemText, { children })
|
|
11864
11967
|
]
|
|
11865
11968
|
}
|
|
@@ -11888,7 +11991,7 @@ function SelectScrollUpButton({
|
|
|
11888
11991
|
"data-slot": "select-scroll-up-button",
|
|
11889
11992
|
className: cn("flex cursor-default items-center justify-center py-1", className),
|
|
11890
11993
|
...props,
|
|
11891
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(
|
|
11994
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_lucide_react25.ChevronUpIcon, { className: "size-4" })
|
|
11892
11995
|
}
|
|
11893
11996
|
);
|
|
11894
11997
|
}
|
|
@@ -11902,7 +12005,7 @@ function SelectScrollDownButton({
|
|
|
11902
12005
|
"data-slot": "select-scroll-down-button",
|
|
11903
12006
|
className: cn("flex cursor-default items-center justify-center py-1", className),
|
|
11904
12007
|
...props,
|
|
11905
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(
|
|
12008
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime105.jsx)(import_lucide_react25.ChevronDownIcon, { className: "size-4" })
|
|
11906
12009
|
}
|
|
11907
12010
|
);
|
|
11908
12011
|
}
|
|
@@ -12075,7 +12178,7 @@ function FilterDropdown({
|
|
|
12075
12178
|
variant: "outline",
|
|
12076
12179
|
size: "sm",
|
|
12077
12180
|
className: "border-dashed font-medium text-muted-foreground hover:text-foreground",
|
|
12078
|
-
iconLeading: /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(
|
|
12181
|
+
iconLeading: /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_lucide_react26.ListFilterIcon, { className: "size-4" }),
|
|
12079
12182
|
children: label
|
|
12080
12183
|
}
|
|
12081
12184
|
) }),
|
|
@@ -12103,7 +12206,7 @@ function FilterDropdown({
|
|
|
12103
12206
|
field.icon,
|
|
12104
12207
|
/* @__PURE__ */ (0, import_jsx_runtime107.jsx)("span", { children: field.label })
|
|
12105
12208
|
] }),
|
|
12106
|
-
/* @__PURE__ */ (0, import_jsx_runtime107.jsx)(
|
|
12209
|
+
/* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_lucide_react26.ChevronRightIcon, { className: "size-4 text-muted-foreground/50" })
|
|
12107
12210
|
]
|
|
12108
12211
|
},
|
|
12109
12212
|
field.id
|
|
@@ -12151,7 +12254,7 @@ function FilterChip({ label, onRemove }) {
|
|
|
12151
12254
|
onClick: onRemove,
|
|
12152
12255
|
"aria-label": `Remove ${label}`,
|
|
12153
12256
|
className: "flex size-5 items-center justify-center rounded-full text-muted-foreground outline-none transition-colors hover:bg-muted hover:text-foreground",
|
|
12154
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(
|
|
12257
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime107.jsx)(import_lucide_react26.XIcon, { className: "size-3.5" })
|
|
12155
12258
|
}
|
|
12156
12259
|
)
|
|
12157
12260
|
] });
|
|
@@ -12414,7 +12517,7 @@ function ApplyClear({ onClear, onApply }) {
|
|
|
12414
12517
|
|
|
12415
12518
|
// src/app/data/DataTable.tsx
|
|
12416
12519
|
var import_react74 = require("react");
|
|
12417
|
-
var
|
|
12520
|
+
var import_lucide_react27 = require("lucide-react");
|
|
12418
12521
|
|
|
12419
12522
|
// src/ui/skeleton.tsx
|
|
12420
12523
|
var import_jsx_runtime108 = require("react/jsx-runtime");
|
|
@@ -12473,12 +12576,12 @@ function SortIndicator({
|
|
|
12473
12576
|
}) {
|
|
12474
12577
|
const iconClass = "size-3.5 shrink-0 opacity-60 group-hover:opacity-100";
|
|
12475
12578
|
if (!active) {
|
|
12476
|
-
return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
|
|
12579
|
+
return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_lucide_react27.ArrowUpDownIcon, { className: iconClass, "aria-hidden": true });
|
|
12477
12580
|
}
|
|
12478
12581
|
if (direction === "desc") {
|
|
12479
|
-
return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
|
|
12582
|
+
return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_lucide_react27.ArrowDownIcon, { className: iconClass, "aria-hidden": true });
|
|
12480
12583
|
}
|
|
12481
|
-
return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
|
|
12584
|
+
return /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_lucide_react27.ArrowUpIcon, { className: iconClass, "aria-hidden": true });
|
|
12482
12585
|
}
|
|
12483
12586
|
function DataTable({
|
|
12484
12587
|
columns,
|
|
@@ -12755,7 +12858,7 @@ function DataTable({
|
|
|
12755
12858
|
onClick: () => setPage(pageIndex - 1),
|
|
12756
12859
|
disabled: pageIndex <= 0,
|
|
12757
12860
|
"aria-label": "Previous page",
|
|
12758
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
|
|
12861
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_lucide_react27.ChevronLeftIcon, { className: "size-4", "aria-hidden": true })
|
|
12759
12862
|
}
|
|
12760
12863
|
),
|
|
12761
12864
|
/* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
|
|
@@ -12766,7 +12869,7 @@ function DataTable({
|
|
|
12766
12869
|
onClick: () => setPage(pageIndex + 1),
|
|
12767
12870
|
disabled: pageIndex >= pageCount - 1,
|
|
12768
12871
|
"aria-label": "Next page",
|
|
12769
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(
|
|
12872
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime109.jsx)(import_lucide_react27.ChevronRightIcon, { className: "size-4", "aria-hidden": true })
|
|
12770
12873
|
}
|
|
12771
12874
|
)
|
|
12772
12875
|
] })
|
|
@@ -13305,7 +13408,7 @@ function UntitledButton({
|
|
|
13305
13408
|
}
|
|
13306
13409
|
|
|
13307
13410
|
// src/ui/banner.tsx
|
|
13308
|
-
var
|
|
13411
|
+
var import_lucide_react28 = require("lucide-react");
|
|
13309
13412
|
var import_jsx_runtime114 = require("react/jsx-runtime");
|
|
13310
13413
|
var bannerSoftClass = {
|
|
13311
13414
|
default: "border-border/50 bg-muted/30 text-foreground/90 dark:bg-muted/15",
|
|
@@ -13402,7 +13505,7 @@ function Banner({
|
|
|
13402
13505
|
isSingleLine ? "self-center" : "-mt-0.5",
|
|
13403
13506
|
isSolid ? "opacity-80 hover:bg-background/15 hover:opacity-100" : "text-muted-foreground hover:bg-foreground/10 hover:text-foreground"
|
|
13404
13507
|
),
|
|
13405
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(
|
|
13508
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime114.jsx)(import_lucide_react28.XIcon, { className: "size-4", "aria-hidden": true })
|
|
13406
13509
|
}
|
|
13407
13510
|
) : null
|
|
13408
13511
|
]
|
|
@@ -13501,7 +13604,7 @@ var React6 = __toESM(require("react"), 1);
|
|
|
13501
13604
|
var import_core2 = require("@dnd-kit/core");
|
|
13502
13605
|
var import_sortable = require("@dnd-kit/sortable");
|
|
13503
13606
|
var import_utilities = require("@dnd-kit/utilities");
|
|
13504
|
-
var
|
|
13607
|
+
var import_lucide_react29 = require("lucide-react");
|
|
13505
13608
|
var import_jsx_runtime116 = require("react/jsx-runtime");
|
|
13506
13609
|
var columnTitleToneClass = {
|
|
13507
13610
|
default: "text-foreground",
|
|
@@ -13587,7 +13690,7 @@ function SortableCard({
|
|
|
13587
13690
|
className: "absolute right-1.5 top-1.5 z-10 grid size-6 cursor-grab touch-none place-items-center rounded-md text-muted-foreground/40 opacity-0 transition hover:bg-foreground/5 hover:text-foreground focus-visible:opacity-100 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-foreground/15 group-hover/kanban-card:opacity-100 active:cursor-grabbing",
|
|
13588
13691
|
...attributes,
|
|
13589
13692
|
...listeners2,
|
|
13590
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(
|
|
13693
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime116.jsx)(import_lucide_react29.GripVerticalIcon, { className: "size-4", "aria-hidden": true })
|
|
13591
13694
|
}
|
|
13592
13695
|
) : null,
|
|
13593
13696
|
renderCard(card, { column, isDragging, isOverlay: false, dragHandleProps })
|
|
@@ -14001,7 +14104,7 @@ When you call a tool that returns an artifact (\`make_chart\`, \`ask_question\`,
|
|
|
14001
14104
|
`.trim();
|
|
14002
14105
|
|
|
14003
14106
|
// src/auth/guard.tsx
|
|
14004
|
-
var
|
|
14107
|
+
var import_lucide_react30 = require("lucide-react");
|
|
14005
14108
|
var import_jsx_runtime117 = require("react/jsx-runtime");
|
|
14006
14109
|
var AuthGuard = ({
|
|
14007
14110
|
children,
|
|
@@ -14013,7 +14116,7 @@ var AuthGuard = ({
|
|
|
14013
14116
|
return children;
|
|
14014
14117
|
}
|
|
14015
14118
|
if (loading) {
|
|
14016
|
-
return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)("div", { className: "flex items-center justify-center h-screen", children: /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
|
|
14119
|
+
return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)("div", { className: "flex items-center justify-center h-screen", children: /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(import_lucide_react30.Loader2, { className: "w-8 h-8 animate-spin" }) });
|
|
14017
14120
|
}
|
|
14018
14121
|
if (requireAuth && !isAuthenticated && !isEmbedded) {
|
|
14019
14122
|
const returnTo = encodeURIComponent(
|
|
@@ -14124,7 +14227,7 @@ function Switch({
|
|
|
14124
14227
|
|
|
14125
14228
|
// src/ui/radio-group.tsx
|
|
14126
14229
|
var import_radix_ui13 = require("radix-ui");
|
|
14127
|
-
var
|
|
14230
|
+
var import_lucide_react31 = require("lucide-react");
|
|
14128
14231
|
var import_jsx_runtime122 = require("react/jsx-runtime");
|
|
14129
14232
|
function RadioGroup({
|
|
14130
14233
|
className,
|
|
@@ -14159,7 +14262,7 @@ function RadioGroupItem({
|
|
|
14159
14262
|
{
|
|
14160
14263
|
"data-slot": "radio-group-indicator",
|
|
14161
14264
|
className: "flex items-center justify-center",
|
|
14162
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(
|
|
14265
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(import_lucide_react31.CircleIcon, { className: "size-2 fill-foreground text-foreground" })
|
|
14163
14266
|
}
|
|
14164
14267
|
)
|
|
14165
14268
|
}
|
|
@@ -14235,7 +14338,7 @@ function AspectRatio({
|
|
|
14235
14338
|
}
|
|
14236
14339
|
|
|
14237
14340
|
// src/ui/breadcrumb.tsx
|
|
14238
|
-
var
|
|
14341
|
+
var import_lucide_react32 = require("lucide-react");
|
|
14239
14342
|
var import_radix_ui16 = require("radix-ui");
|
|
14240
14343
|
var import_jsx_runtime125 = require("react/jsx-runtime");
|
|
14241
14344
|
function Breadcrumb({ ...props }) {
|
|
@@ -14305,7 +14408,7 @@ function BreadcrumbSeparator({
|
|
|
14305
14408
|
"aria-hidden": "true",
|
|
14306
14409
|
className: cn("[&>svg]:size-3.5", className),
|
|
14307
14410
|
...props,
|
|
14308
|
-
children: children ?? /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
14411
|
+
children: children ?? /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(import_lucide_react32.ChevronRightIcon, {})
|
|
14309
14412
|
}
|
|
14310
14413
|
);
|
|
14311
14414
|
}
|
|
@@ -14322,7 +14425,7 @@ function BreadcrumbEllipsis({
|
|
|
14322
14425
|
className: cn("flex size-8 items-center justify-center", className),
|
|
14323
14426
|
...props,
|
|
14324
14427
|
children: [
|
|
14325
|
-
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)(
|
|
14428
|
+
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)(import_lucide_react32.MoreHorizontalIcon, { className: "size-4" }),
|
|
14326
14429
|
/* @__PURE__ */ (0, import_jsx_runtime125.jsx)("span", { className: "sr-only", children: "More" })
|
|
14327
14430
|
]
|
|
14328
14431
|
}
|
|
@@ -14330,7 +14433,7 @@ function BreadcrumbEllipsis({
|
|
|
14330
14433
|
}
|
|
14331
14434
|
|
|
14332
14435
|
// src/ui/pagination.tsx
|
|
14333
|
-
var
|
|
14436
|
+
var import_lucide_react33 = require("lucide-react");
|
|
14334
14437
|
var import_jsx_runtime126 = require("react/jsx-runtime");
|
|
14335
14438
|
function Pagination({ className, ...props }) {
|
|
14336
14439
|
return /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
@@ -14384,7 +14487,7 @@ function PaginationPrevious({
|
|
|
14384
14487
|
className: cn("gap-1 px-2.5 sm:pl-2.5", className),
|
|
14385
14488
|
...props,
|
|
14386
14489
|
children: [
|
|
14387
|
-
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
14490
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(import_lucide_react33.ChevronLeftIcon, { className: "size-4" }),
|
|
14388
14491
|
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)("span", { className: "hidden sm:block", children: "Previous" })
|
|
14389
14492
|
]
|
|
14390
14493
|
}
|
|
@@ -14403,7 +14506,7 @@ function PaginationNext({
|
|
|
14403
14506
|
...props,
|
|
14404
14507
|
children: [
|
|
14405
14508
|
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)("span", { className: "hidden sm:block", children: "Next" }),
|
|
14406
|
-
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
14509
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(import_lucide_react33.ChevronRightIcon, { className: "size-4" })
|
|
14407
14510
|
]
|
|
14408
14511
|
}
|
|
14409
14512
|
);
|
|
@@ -14420,7 +14523,7 @@ function PaginationEllipsis({
|
|
|
14420
14523
|
className: cn("flex size-9 items-center justify-center", className),
|
|
14421
14524
|
...props,
|
|
14422
14525
|
children: [
|
|
14423
|
-
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
|
|
14526
|
+
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)(import_lucide_react33.MoreHorizontalIcon, { className: "size-4" }),
|
|
14424
14527
|
/* @__PURE__ */ (0, import_jsx_runtime126.jsx)("span", { className: "sr-only", children: "More pages" })
|
|
14425
14528
|
]
|
|
14426
14529
|
}
|
|
@@ -14526,7 +14629,7 @@ function ToolbarLink({
|
|
|
14526
14629
|
|
|
14527
14630
|
// src/ui/menubar.tsx
|
|
14528
14631
|
var import_radix_ui18 = require("radix-ui");
|
|
14529
|
-
var
|
|
14632
|
+
var import_lucide_react34 = require("lucide-react");
|
|
14530
14633
|
var import_jsx_runtime128 = require("react/jsx-runtime");
|
|
14531
14634
|
function Menubar({
|
|
14532
14635
|
className,
|
|
@@ -14624,7 +14727,7 @@ function MenubarCheckboxItem({
|
|
|
14624
14727
|
checked,
|
|
14625
14728
|
...props,
|
|
14626
14729
|
children: [
|
|
14627
|
-
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_radix_ui18.Menubar.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
14730
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_radix_ui18.Menubar.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_lucide_react34.CheckIcon, { className: "size-4" }) }) }),
|
|
14628
14731
|
children
|
|
14629
14732
|
]
|
|
14630
14733
|
}
|
|
@@ -14647,7 +14750,7 @@ function MenubarRadioItem({
|
|
|
14647
14750
|
className: cn(overlayItemClass, "py-1 pr-2 pl-8", className),
|
|
14648
14751
|
...props,
|
|
14649
14752
|
children: [
|
|
14650
|
-
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_radix_ui18.Menubar.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
14753
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_radix_ui18.Menubar.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_lucide_react34.CircleIcon, { className: "size-2 fill-current" }) }) }),
|
|
14651
14754
|
children
|
|
14652
14755
|
]
|
|
14653
14756
|
}
|
|
@@ -14724,7 +14827,7 @@ function MenubarSubTrigger({
|
|
|
14724
14827
|
...props,
|
|
14725
14828
|
children: [
|
|
14726
14829
|
children,
|
|
14727
|
-
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
|
|
14830
|
+
/* @__PURE__ */ (0, import_jsx_runtime128.jsx)(import_lucide_react34.ChevronRightIcon, { className: "ml-auto size-4" })
|
|
14728
14831
|
]
|
|
14729
14832
|
}
|
|
14730
14833
|
);
|
|
@@ -14749,7 +14852,7 @@ function MenubarSubContent({
|
|
|
14749
14852
|
|
|
14750
14853
|
// src/ui/navigation-menu.tsx
|
|
14751
14854
|
var import_radix_ui19 = require("radix-ui");
|
|
14752
|
-
var
|
|
14855
|
+
var import_lucide_react35 = require("lucide-react");
|
|
14753
14856
|
var import_class_variance_authority3 = require("class-variance-authority");
|
|
14754
14857
|
var import_jsx_runtime129 = require("react/jsx-runtime");
|
|
14755
14858
|
function NavigationMenu({
|
|
@@ -14814,7 +14917,7 @@ function NavigationMenuTrigger({
|
|
|
14814
14917
|
children,
|
|
14815
14918
|
" ",
|
|
14816
14919
|
/* @__PURE__ */ (0, import_jsx_runtime129.jsx)(
|
|
14817
|
-
|
|
14920
|
+
import_lucide_react35.ChevronDownIcon,
|
|
14818
14921
|
{
|
|
14819
14922
|
className: "relative top-px ml-1 size-3 transition duration-300 group-data-[state=open]:rotate-180",
|
|
14820
14923
|
"aria-hidden": "true"
|
|
@@ -14894,7 +14997,7 @@ function NavigationMenuIndicator({
|
|
|
14894
14997
|
|
|
14895
14998
|
// src/ui/command.tsx
|
|
14896
14999
|
var import_cmdk = require("cmdk");
|
|
14897
|
-
var
|
|
15000
|
+
var import_lucide_react36 = require("lucide-react");
|
|
14898
15001
|
var import_jsx_runtime130 = require("react/jsx-runtime");
|
|
14899
15002
|
function Command({
|
|
14900
15003
|
className,
|
|
@@ -14945,7 +15048,7 @@ function CommandInput({
|
|
|
14945
15048
|
"data-slot": "command-input-wrapper",
|
|
14946
15049
|
className: "flex h-9 items-center gap-2 border-b border-border px-2.5",
|
|
14947
15050
|
children: [
|
|
14948
|
-
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
15051
|
+
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(import_lucide_react36.SearchIcon, { className: "size-4 shrink-0 text-muted-foreground" }),
|
|
14949
15052
|
/* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
|
|
14950
15053
|
import_cmdk.Command.Input,
|
|
14951
15054
|
{
|
|
@@ -15051,7 +15154,7 @@ function CommandShortcut({
|
|
|
15051
15154
|
|
|
15052
15155
|
// src/ui/calendar.tsx
|
|
15053
15156
|
var React7 = __toESM(require("react"), 1);
|
|
15054
|
-
var
|
|
15157
|
+
var import_lucide_react37 = require("lucide-react");
|
|
15055
15158
|
var import_react_day_picker = require("react-day-picker");
|
|
15056
15159
|
var import_jsx_runtime131 = require("react/jsx-runtime");
|
|
15057
15160
|
function Calendar({
|
|
@@ -15123,7 +15226,7 @@ function Calendar({
|
|
|
15123
15226
|
},
|
|
15124
15227
|
components: {
|
|
15125
15228
|
Chevron: ({ orientation, className: chevronClass, ...chevronProps }) => {
|
|
15126
|
-
const Icon = orientation === "left" ?
|
|
15229
|
+
const Icon = orientation === "left" ? import_lucide_react37.ChevronLeftIcon : orientation === "right" ? import_lucide_react37.ChevronRightIcon : import_lucide_react37.ChevronDownIcon;
|
|
15127
15230
|
return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(Icon, { className: cn("size-4", chevronClass), ...chevronProps });
|
|
15128
15231
|
},
|
|
15129
15232
|
DayButton: CalendarDayButton
|
|
@@ -15176,7 +15279,7 @@ function CalendarDayButton({
|
|
|
15176
15279
|
}
|
|
15177
15280
|
|
|
15178
15281
|
// src/ui/combobox.tsx
|
|
15179
|
-
var
|
|
15282
|
+
var import_lucide_react38 = require("lucide-react");
|
|
15180
15283
|
var import_jsx_runtime132 = require("react/jsx-runtime");
|
|
15181
15284
|
function Combobox({
|
|
15182
15285
|
...props
|
|
@@ -15202,7 +15305,7 @@ function ComboboxTrigger({
|
|
|
15202
15305
|
...props,
|
|
15203
15306
|
children: [
|
|
15204
15307
|
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)("span", { className: "truncate", children }),
|
|
15205
|
-
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
|
|
15308
|
+
/* @__PURE__ */ (0, import_jsx_runtime132.jsx)(import_lucide_react38.ChevronDownIcon, { className: "size-4 shrink-0 opacity-50" })
|
|
15206
15309
|
]
|
|
15207
15310
|
}
|
|
15208
15311
|
);
|
|
@@ -15281,7 +15384,7 @@ function ComboboxShortcut({
|
|
|
15281
15384
|
}
|
|
15282
15385
|
|
|
15283
15386
|
// src/ui/date-picker.tsx
|
|
15284
|
-
var
|
|
15387
|
+
var import_lucide_react39 = require("lucide-react");
|
|
15285
15388
|
var import_jsx_runtime133 = require("react/jsx-runtime");
|
|
15286
15389
|
function DatePicker({
|
|
15287
15390
|
...props
|
|
@@ -15347,7 +15450,7 @@ function DatePickerButton({
|
|
|
15347
15450
|
),
|
|
15348
15451
|
...props,
|
|
15349
15452
|
children: [
|
|
15350
|
-
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)(
|
|
15453
|
+
/* @__PURE__ */ (0, import_jsx_runtime133.jsx)(import_lucide_react39.CalendarIcon, { className: "size-4 shrink-0 opacity-70" }),
|
|
15351
15454
|
date ? formatPickerDate(date) : placeholder
|
|
15352
15455
|
]
|
|
15353
15456
|
}
|
|
@@ -15355,7 +15458,7 @@ function DatePickerButton({
|
|
|
15355
15458
|
}
|
|
15356
15459
|
|
|
15357
15460
|
// src/ui/input-otp.tsx
|
|
15358
|
-
var
|
|
15461
|
+
var import_lucide_react40 = require("lucide-react");
|
|
15359
15462
|
var import_radix_ui20 = require("radix-ui");
|
|
15360
15463
|
var import_jsx_runtime134 = require("react/jsx-runtime");
|
|
15361
15464
|
function InputOTP({
|
|
@@ -15427,7 +15530,7 @@ function InputOTPSeparator({
|
|
|
15427
15530
|
"aria-hidden": true,
|
|
15428
15531
|
className: cn("text-muted-foreground", className),
|
|
15429
15532
|
...props,
|
|
15430
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(
|
|
15533
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(import_lucide_react40.MinusIcon, { className: "size-4" })
|
|
15431
15534
|
}
|
|
15432
15535
|
);
|
|
15433
15536
|
}
|
|
@@ -15572,7 +15675,7 @@ function InputGroupText({
|
|
|
15572
15675
|
|
|
15573
15676
|
// src/ui/accordion.tsx
|
|
15574
15677
|
var import_radix_ui21 = require("radix-ui");
|
|
15575
|
-
var
|
|
15678
|
+
var import_lucide_react41 = require("lucide-react");
|
|
15576
15679
|
var import_jsx_runtime138 = require("react/jsx-runtime");
|
|
15577
15680
|
function Accordion({
|
|
15578
15681
|
...props
|
|
@@ -15610,7 +15713,7 @@ function AccordionTrigger({
|
|
|
15610
15713
|
...props,
|
|
15611
15714
|
children: [
|
|
15612
15715
|
children,
|
|
15613
|
-
/* @__PURE__ */ (0, import_jsx_runtime138.jsx)(
|
|
15716
|
+
/* @__PURE__ */ (0, import_jsx_runtime138.jsx)(import_lucide_react41.ChevronDownIcon, { className: "pointer-events-none size-4 shrink-0 text-muted-foreground transition-transform duration-200" })
|
|
15614
15717
|
]
|
|
15615
15718
|
}
|
|
15616
15719
|
) });
|
|
@@ -15781,7 +15884,7 @@ function Badge({
|
|
|
15781
15884
|
}
|
|
15782
15885
|
|
|
15783
15886
|
// src/ui/sheet.tsx
|
|
15784
|
-
var
|
|
15887
|
+
var import_lucide_react42 = require("lucide-react");
|
|
15785
15888
|
var import_radix_ui26 = require("radix-ui");
|
|
15786
15889
|
var import_class_variance_authority5 = require("class-variance-authority");
|
|
15787
15890
|
var import_jsx_runtime143 = require("react/jsx-runtime");
|
|
@@ -15883,7 +15986,7 @@ function SheetContent({
|
|
|
15883
15986
|
children: [
|
|
15884
15987
|
children,
|
|
15885
15988
|
showCloseButton ? /* @__PURE__ */ (0, import_jsx_runtime143.jsxs)(import_radix_ui26.Dialog.Close, { className: "absolute top-4 right-4 rounded-xs opacity-70 transition-[opacity,background-color] hover:bg-ghost-fill-hover hover:opacity-100 focus:ring-2 focus:ring-foreground/10 focus:outline-hidden disabled:pointer-events-none", children: [
|
|
15886
|
-
/* @__PURE__ */ (0, import_jsx_runtime143.jsx)(
|
|
15989
|
+
/* @__PURE__ */ (0, import_jsx_runtime143.jsx)(import_lucide_react42.XIcon, { className: "size-4" }),
|
|
15887
15990
|
/* @__PURE__ */ (0, import_jsx_runtime143.jsx)("span", { className: "sr-only", children: "Close" })
|
|
15888
15991
|
] }) : null
|
|
15889
15992
|
]
|
|
@@ -15928,14 +16031,14 @@ function SheetDescription({
|
|
|
15928
16031
|
className,
|
|
15929
16032
|
...props
|
|
15930
16033
|
}) {
|
|
15931
|
-
return /* @__PURE__ */ (0, import_jsx_runtime143.jsx)(
|
|
15932
|
-
|
|
16034
|
+
return /* @__PURE__ */ (0, import_jsx_runtime143.jsx)(import_radix_ui26.Dialog.Description, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime143.jsx)(
|
|
16035
|
+
"div",
|
|
15933
16036
|
{
|
|
15934
16037
|
"data-slot": "sheet-description",
|
|
15935
16038
|
className: cn("text-sm text-muted-foreground", className),
|
|
15936
16039
|
...props
|
|
15937
16040
|
}
|
|
15938
|
-
);
|
|
16041
|
+
) });
|
|
15939
16042
|
}
|
|
15940
16043
|
|
|
15941
16044
|
// src/ui/alert-dialog.tsx
|
|
@@ -16272,7 +16375,7 @@ function HoverCardContent({
|
|
|
16272
16375
|
|
|
16273
16376
|
// src/ui/context-menu.tsx
|
|
16274
16377
|
var import_radix_ui33 = require("radix-ui");
|
|
16275
|
-
var
|
|
16378
|
+
var import_lucide_react43 = require("lucide-react");
|
|
16276
16379
|
var import_jsx_runtime150 = require("react/jsx-runtime");
|
|
16277
16380
|
function ContextMenu({
|
|
16278
16381
|
...props
|
|
@@ -16341,7 +16444,7 @@ function ContextMenuCheckboxItem({
|
|
|
16341
16444
|
checked,
|
|
16342
16445
|
...props,
|
|
16343
16446
|
children: [
|
|
16344
|
-
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_radix_ui33.ContextMenu.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
16447
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_radix_ui33.ContextMenu.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_lucide_react43.CheckIcon, { className: "size-4" }) }) }),
|
|
16345
16448
|
children
|
|
16346
16449
|
]
|
|
16347
16450
|
}
|
|
@@ -16370,7 +16473,7 @@ function ContextMenuRadioItem({
|
|
|
16370
16473
|
className: cn(overlayItemClass, "py-1.5 pr-2 pl-8", className),
|
|
16371
16474
|
...props,
|
|
16372
16475
|
children: [
|
|
16373
|
-
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_radix_ui33.ContextMenu.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
16476
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_radix_ui33.ContextMenu.ItemIndicator, { children: /* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_lucide_react43.CircleIcon, { className: "size-2 fill-current" }) }) }),
|
|
16374
16477
|
children
|
|
16375
16478
|
]
|
|
16376
16479
|
}
|
|
@@ -16447,7 +16550,7 @@ function ContextMenuSubTrigger({
|
|
|
16447
16550
|
...props,
|
|
16448
16551
|
children: [
|
|
16449
16552
|
children,
|
|
16450
|
-
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(
|
|
16553
|
+
/* @__PURE__ */ (0, import_jsx_runtime150.jsx)(import_lucide_react43.ChevronRightIcon, { className: "ml-auto size-4" })
|
|
16451
16554
|
]
|
|
16452
16555
|
}
|
|
16453
16556
|
);
|
|
@@ -16680,7 +16783,7 @@ function TableCaption({ className, ...props }) {
|
|
|
16680
16783
|
|
|
16681
16784
|
// src/ui/toast.tsx
|
|
16682
16785
|
var import_radix_ui34 = require("radix-ui");
|
|
16683
|
-
var
|
|
16786
|
+
var import_lucide_react44 = require("lucide-react");
|
|
16684
16787
|
var import_jsx_runtime154 = require("react/jsx-runtime");
|
|
16685
16788
|
function ToastProvider({
|
|
16686
16789
|
...props
|
|
@@ -16753,7 +16856,7 @@ function ToastClose({
|
|
|
16753
16856
|
),
|
|
16754
16857
|
"toast-close": "",
|
|
16755
16858
|
...props,
|
|
16756
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime154.jsx)(
|
|
16859
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime154.jsx)(import_lucide_react44.XIcon, { className: "size-4" })
|
|
16757
16860
|
}
|
|
16758
16861
|
);
|
|
16759
16862
|
}
|
|
@@ -16923,7 +17026,7 @@ function AvatarGroup({
|
|
|
16923
17026
|
}
|
|
16924
17027
|
|
|
16925
17028
|
// src/ui/stepper.tsx
|
|
16926
|
-
var
|
|
17029
|
+
var import_lucide_react45 = require("lucide-react");
|
|
16927
17030
|
var import_jsx_runtime157 = require("react/jsx-runtime");
|
|
16928
17031
|
function Stepper({
|
|
16929
17032
|
steps,
|
|
@@ -16968,7 +17071,7 @@ function Stepper({
|
|
|
16968
17071
|
active && "border-primary text-primary",
|
|
16969
17072
|
!complete && !active && "border-border text-muted-foreground"
|
|
16970
17073
|
),
|
|
16971
|
-
children: complete ? /* @__PURE__ */ (0, import_jsx_runtime157.jsx)(
|
|
17074
|
+
children: complete ? /* @__PURE__ */ (0, import_jsx_runtime157.jsx)(import_lucide_react45.CheckIcon, { className: "size-3.5", "aria-hidden": true }) : index + 1
|
|
16972
17075
|
}
|
|
16973
17076
|
),
|
|
16974
17077
|
!last ? /* @__PURE__ */ (0, import_jsx_runtime157.jsx)(
|
|
@@ -17007,7 +17110,7 @@ function Stepper({
|
|
|
17007
17110
|
|
|
17008
17111
|
// src/ui/rating.tsx
|
|
17009
17112
|
var React11 = __toESM(require("react"), 1);
|
|
17010
|
-
var
|
|
17113
|
+
var import_lucide_react46 = require("lucide-react");
|
|
17011
17114
|
var import_jsx_runtime158 = require("react/jsx-runtime");
|
|
17012
17115
|
var sizeClass = { sm: "size-4", md: "size-5", lg: "size-6" };
|
|
17013
17116
|
var ratingFillClass = {
|
|
@@ -17050,7 +17153,7 @@ function Rating({
|
|
|
17050
17153
|
"aria-label": `${label}: ${value} of ${max}`,
|
|
17051
17154
|
className: cn("inline-flex items-center gap-0.5", disabled && "opacity-50", className),
|
|
17052
17155
|
children: Array.from({ length: max }, (_, i) => /* @__PURE__ */ (0, import_jsx_runtime158.jsx)(
|
|
17053
|
-
|
|
17156
|
+
import_lucide_react46.StarIcon,
|
|
17054
17157
|
{
|
|
17055
17158
|
"aria-hidden": true,
|
|
17056
17159
|
className: cn(
|
|
@@ -17087,7 +17190,7 @@ function Rating({
|
|
|
17087
17190
|
onBlur: () => setHover(null),
|
|
17088
17191
|
className: "rounded-sm p-0.5 transition-transform hover:scale-110 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-foreground/15",
|
|
17089
17192
|
children: /* @__PURE__ */ (0, import_jsx_runtime158.jsx)(
|
|
17090
|
-
|
|
17193
|
+
import_lucide_react46.StarIcon,
|
|
17091
17194
|
{
|
|
17092
17195
|
className: cn(
|
|
17093
17196
|
sizeClass[size],
|
|
@@ -17106,7 +17209,7 @@ function Rating({
|
|
|
17106
17209
|
|
|
17107
17210
|
// src/ui/number-field.tsx
|
|
17108
17211
|
var React12 = __toESM(require("react"), 1);
|
|
17109
|
-
var
|
|
17212
|
+
var import_lucide_react47 = require("lucide-react");
|
|
17110
17213
|
var import_jsx_runtime159 = require("react/jsx-runtime");
|
|
17111
17214
|
var heightClass = { sm: "h-9", default: "h-10" };
|
|
17112
17215
|
var stepButtonClass = "inline-flex aspect-square h-full items-center justify-center text-muted-foreground transition-colors hover:bg-accent hover:text-foreground disabled:pointer-events-none disabled:opacity-40 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-foreground/15";
|
|
@@ -17157,7 +17260,7 @@ function NumberField({
|
|
|
17157
17260
|
disabled: disabled || typeof min === "number" && value <= min,
|
|
17158
17261
|
onClick: () => commit(value - step),
|
|
17159
17262
|
className: cn(stepButtonClass, "border-r border-border"),
|
|
17160
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime159.jsx)(
|
|
17263
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime159.jsx)(import_lucide_react47.MinusIcon, { className: "size-4" })
|
|
17161
17264
|
}
|
|
17162
17265
|
),
|
|
17163
17266
|
/* @__PURE__ */ (0, import_jsx_runtime159.jsx)(
|
|
@@ -17193,7 +17296,7 @@ function NumberField({
|
|
|
17193
17296
|
disabled: disabled || typeof max === "number" && value >= max,
|
|
17194
17297
|
onClick: () => commit(value + step),
|
|
17195
17298
|
className: cn(stepButtonClass, "border-l border-border"),
|
|
17196
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime159.jsx)(
|
|
17299
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime159.jsx)(import_lucide_react47.PlusIcon, { className: "size-4" })
|
|
17197
17300
|
}
|
|
17198
17301
|
)
|
|
17199
17302
|
]
|
|
@@ -17203,7 +17306,7 @@ function NumberField({
|
|
|
17203
17306
|
|
|
17204
17307
|
// src/ui/tag-input.tsx
|
|
17205
17308
|
var React13 = __toESM(require("react"), 1);
|
|
17206
|
-
var
|
|
17309
|
+
var import_lucide_react48 = require("lucide-react");
|
|
17207
17310
|
var import_jsx_runtime160 = require("react/jsx-runtime");
|
|
17208
17311
|
var tagInputSizeClass = {
|
|
17209
17312
|
sm: "min-h-8 gap-1 px-1.5 py-0.5",
|
|
@@ -17278,7 +17381,7 @@ function TagInput({
|
|
|
17278
17381
|
"aria-label": `Remove ${tag}`,
|
|
17279
17382
|
onClick: () => removeAt(index),
|
|
17280
17383
|
className: "inline-flex size-4 items-center justify-center rounded-sm text-muted-foreground transition-colors hover:bg-foreground/10 hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-foreground/20",
|
|
17281
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime160.jsx)(
|
|
17384
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime160.jsx)(import_lucide_react48.XIcon, { className: "size-3", "aria-hidden": true })
|
|
17282
17385
|
}
|
|
17283
17386
|
)
|
|
17284
17387
|
]
|