@vantageos/mosaic-blocks 0.5.19-alpha → 0.5.21-alpha

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/index.cjs CHANGED
@@ -4,7 +4,7 @@
4
4
  var jsxRuntime = require('react/jsx-runtime');
5
5
  var button = require('@base-ui/react/button');
6
6
  var classVarianceAuthority = require('class-variance-authority');
7
- var React28 = require('react');
7
+ var React29 = require('react');
8
8
  var accordion = require('@base-ui/react/accordion');
9
9
  var checkbox = require('@base-ui/react/checkbox');
10
10
  var collapsible = require('@base-ui/react/collapsible');
@@ -24,6 +24,7 @@ var select = require('@base-ui/react/select');
24
24
  var combobox = require('@base-ui/react/combobox');
25
25
  var menu = require('@base-ui/react/menu');
26
26
  var alertDialog = require('@base-ui/react/alert-dialog');
27
+ var dialog = require('@base-ui/react/dialog');
27
28
 
28
29
  function _interopNamespace(e) {
29
30
  if (e && e.__esModule) return e;
@@ -43,10 +44,10 @@ function _interopNamespace(e) {
43
44
  return Object.freeze(n);
44
45
  }
45
46
 
46
- var React28__namespace = /*#__PURE__*/_interopNamespace(React28);
47
+ var React29__namespace = /*#__PURE__*/_interopNamespace(React29);
47
48
 
48
49
  // src/version.ts
49
- var version = "0.5.19-alpha";
50
+ var version = "0.5.21-alpha";
50
51
  function Placeholder({ label = "mosaic-blocks placeholder" }) {
51
52
  return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-mosaic-block": "placeholder", children: label });
52
53
  }
@@ -177,11 +178,11 @@ function MosaicNavbar({
177
178
  className,
178
179
  ref
179
180
  }) {
180
- const [isScrolled, setIsScrolled] = React28__namespace.useState(false);
181
- const [isHidden, setIsHidden] = React28__namespace.useState(false);
182
- const [isOpen, setIsOpen] = React28__namespace.useState(false);
183
- const lastScrollY = React28__namespace.useRef(0);
184
- React28__namespace.useEffect(() => {
181
+ const [isScrolled, setIsScrolled] = React29__namespace.useState(false);
182
+ const [isHidden, setIsHidden] = React29__namespace.useState(false);
183
+ const [isOpen, setIsOpen] = React29__namespace.useState(false);
184
+ const lastScrollY = React29__namespace.useRef(0);
185
+ React29__namespace.useEffect(() => {
185
186
  const handleScroll = () => {
186
187
  const current = window.scrollY;
187
188
  setIsScrolled(current > 50);
@@ -196,7 +197,7 @@ function MosaicNavbar({
196
197
  window.addEventListener("scroll", handleScroll, { passive: true });
197
198
  return () => window.removeEventListener("scroll", handleScroll);
198
199
  }, []);
199
- React28__namespace.useEffect(() => {
200
+ React29__namespace.useEffect(() => {
200
201
  document.body.style.overflow = isOpen ? "hidden" : "";
201
202
  return () => {
202
203
  document.body.style.overflow = "";
@@ -724,10 +725,10 @@ function MosaicCounter({
724
725
  className,
725
726
  ref
726
727
  }) {
727
- const [current, setCurrent] = React28__namespace.useState(0);
728
- const rafRef = React28__namespace.useRef(0);
729
- const startTimeRef = React28__namespace.useRef(null);
730
- React28__namespace.useEffect(() => {
728
+ const [current, setCurrent] = React29__namespace.useState(0);
729
+ const rafRef = React29__namespace.useRef(0);
730
+ const startTimeRef = React29__namespace.useRef(null);
731
+ React29__namespace.useEffect(() => {
731
732
  const prefersReduced = typeof window !== "undefined" && typeof window.matchMedia === "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
732
733
  if (prefersReduced) {
733
734
  setCurrent(value);
@@ -783,12 +784,12 @@ function MosaicThemeToggle({
783
784
  switchToDarkLabel,
784
785
  ref
785
786
  }) {
786
- const [theme, setTheme] = React28__namespace.useState(() => {
787
+ const [theme, setTheme] = React29__namespace.useState(() => {
787
788
  if (typeof document === "undefined") return themes[0];
788
789
  const current = document.documentElement.getAttribute("data-theme");
789
790
  return current && themes.includes(current) ? current : themes[0];
790
791
  });
791
- const applyTheme = React28__namespace.useCallback(
792
+ const applyTheme = React29__namespace.useCallback(
792
793
  (next) => {
793
794
  const resolved = next === "system" ? getSystemTheme() : next;
794
795
  document.documentElement.setAttribute("data-theme", resolved);
@@ -916,10 +917,10 @@ function MosaicAnimatedList({
916
917
  as: Tag = "ul",
917
918
  ref
918
919
  }) {
919
- React28__namespace.useEffect(() => {
920
+ React29__namespace.useEffect(() => {
920
921
  injectKeyframes();
921
922
  }, []);
922
- const items = React28__namespace.Children.toArray(children);
923
+ const items = React29__namespace.Children.toArray(children);
923
924
  return /* @__PURE__ */ jsxRuntime.jsx(
924
925
  Tag,
925
926
  {
@@ -927,7 +928,7 @@ function MosaicAnimatedList({
927
928
  className,
928
929
  children: items.map((child, i) => {
929
930
  const stableKey = child.key ?? `item-${i}`;
930
- return /* @__PURE__ */ jsxRuntime.jsx(React28__namespace.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsx(
931
+ return /* @__PURE__ */ jsxRuntime.jsx(React29__namespace.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsx(
931
932
  "div",
932
933
  {
933
934
  className: "mosaic-list-item",
@@ -1000,8 +1001,8 @@ function MosaicFallingPattern({
1000
1001
  className,
1001
1002
  ref
1002
1003
  }) {
1003
- const uniqueId = React28__namespace.useId();
1004
- React28__namespace.useEffect(() => {
1004
+ const uniqueId = React29__namespace.useId();
1005
+ React29__namespace.useEffect(() => {
1005
1006
  injectPatternKeyframes();
1006
1007
  }, []);
1007
1008
  const cols = density;
@@ -1075,8 +1076,8 @@ function MosaicFallingPattern({
1075
1076
  }
1076
1077
  MosaicFallingPattern.displayName = "MosaicFallingPattern";
1077
1078
  function useMediaQuery(query) {
1078
- const [matches, setMatches] = React28.useState(false);
1079
- React28.useEffect(() => {
1079
+ const [matches, setMatches] = React29.useState(false);
1080
+ React29.useEffect(() => {
1080
1081
  const mql = window.matchMedia(query);
1081
1082
  setMatches(mql.matches);
1082
1083
  const handler = (e) => {
@@ -2097,7 +2098,7 @@ function MosaicSelect({
2097
2098
  name,
2098
2099
  className
2099
2100
  }) {
2100
- const labelMap = React28__namespace.useMemo(
2101
+ const labelMap = React29__namespace.useMemo(
2101
2102
  () => Object.fromEntries(items.map((item) => [item.value, item.label])),
2102
2103
  [items]
2103
2104
  );
@@ -2217,9 +2218,9 @@ function MosaicCombobox({
2217
2218
  emptyMessage,
2218
2219
  className
2219
2220
  }) {
2220
- const [inputValue, setInputValue] = React28__namespace.useState("");
2221
+ const [inputValue, setInputValue] = React29__namespace.useState("");
2221
2222
  const filter = combobox.Combobox.useFilter({ sensitivity: "base" });
2222
- const filteredItems = React28__namespace.useMemo(() => {
2223
+ const filteredItems = React29__namespace.useMemo(() => {
2223
2224
  if (!inputValue) return items;
2224
2225
  return items.filter((item) => filter.contains(item.label, inputValue));
2225
2226
  }, [items, inputValue, filter]);
@@ -2284,9 +2285,123 @@ function MosaicCombobox({
2284
2285
  }
2285
2286
  );
2286
2287
  }
2288
+ var modelSelectorTriggerVariants = classVarianceAuthority.cva(
2289
+ [
2290
+ "flex w-full min-h-[44px] items-center justify-between gap-2 rounded-md border",
2291
+ "border-border bg-background px-3 py-2 text-left text-sm text-foreground shadow-xs",
2292
+ "outline-none transition-colors hover:bg-muted",
2293
+ "focus-visible:ring-ring focus-visible:ring-[3px]",
2294
+ "data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50",
2295
+ "data-[popup-open]:ring-ring data-[popup-open]:ring-[3px]"
2296
+ ],
2297
+ {
2298
+ variants: {}
2299
+ }
2300
+ );
2301
+ var modelSelectorItemVariants = classVarianceAuthority.cva(
2302
+ [
2303
+ "relative flex cursor-pointer select-none flex-col gap-0.5 rounded-sm px-2 py-1.5",
2304
+ "text-sm text-popover-foreground outline-none transition-colors",
2305
+ "data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground",
2306
+ "data-[disabled]:cursor-not-allowed data-[disabled]:opacity-50",
2307
+ "data-[selected]:font-medium"
2308
+ ],
2309
+ {
2310
+ variants: {}
2311
+ }
2312
+ );
2287
2313
  function cn36(...classes) {
2288
2314
  return classes.filter(Boolean).join(" ");
2289
2315
  }
2316
+ function MosaicModelSelector({
2317
+ models,
2318
+ value,
2319
+ onValueChange,
2320
+ placeholder,
2321
+ emptyMessage,
2322
+ disabled,
2323
+ name,
2324
+ className
2325
+ }) {
2326
+ const [inputValue, setInputValue] = React29__namespace.useState("");
2327
+ const filter = combobox.Combobox.useFilter({ sensitivity: "base" });
2328
+ const filteredModels = React29__namespace.useMemo(() => {
2329
+ if (!inputValue) return models;
2330
+ return models.filter((model) => filter.contains(model.label, inputValue));
2331
+ }, [models, inputValue, filter]);
2332
+ const labelMap = React29__namespace.useMemo(
2333
+ () => Object.fromEntries(models.map((model) => [model.value, model.label])),
2334
+ [models]
2335
+ );
2336
+ const handleValueChange = React29__namespace.useCallback(
2337
+ (nextValue, eventDetails) => {
2338
+ if (typeof nextValue !== "string") return;
2339
+ const selected = models.find((model) => model.value === nextValue);
2340
+ if (!selected || selected.disabled) return;
2341
+ onValueChange?.(nextValue);
2342
+ },
2343
+ [models, onValueChange]
2344
+ );
2345
+ return /* @__PURE__ */ jsxRuntime.jsx(
2346
+ combobox.Combobox.Root,
2347
+ {
2348
+ value,
2349
+ onValueChange: handleValueChange,
2350
+ disabled,
2351
+ name,
2352
+ onInputValueChange: setInputValue,
2353
+ autoHighlight: true,
2354
+ children: /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "model-selector", className: cn36("relative w-full", className), children: [
2355
+ /* @__PURE__ */ jsxRuntime.jsx(
2356
+ combobox.Combobox.Input,
2357
+ {
2358
+ placeholder,
2359
+ className: modelSelectorTriggerVariants({ className })
2360
+ }
2361
+ ),
2362
+ value != null && value in labelMap && inputValue === "" && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "pointer-events-none absolute inset-y-0 left-3 flex items-center text-sm text-foreground", children: labelMap[value] }),
2363
+ /* @__PURE__ */ jsxRuntime.jsx(combobox.Combobox.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(combobox.Combobox.Positioner, { sideOffset: 4, children: /* @__PURE__ */ jsxRuntime.jsx(
2364
+ combobox.Combobox.Popup,
2365
+ {
2366
+ className: cn36(
2367
+ "z-50 min-w-[16rem] overflow-hidden rounded-md border border-border",
2368
+ "bg-popover p-1 text-popover-foreground shadow-md",
2369
+ "origin-[var(--transform-origin)]",
2370
+ "transition-[transform,scale,opacity]",
2371
+ "data-[open]:scale-100 data-[open]:opacity-100",
2372
+ "data-[ending-style]:scale-95 data-[ending-style]:opacity-0",
2373
+ "data-[starting-style]:scale-95 data-[starting-style]:opacity-0"
2374
+ ),
2375
+ children: /* @__PURE__ */ jsxRuntime.jsxs(combobox.Combobox.List, { children: [
2376
+ filteredModels.map((model) => /* @__PURE__ */ jsxRuntime.jsxs(
2377
+ combobox.Combobox.Item,
2378
+ {
2379
+ value: model.value,
2380
+ disabled: model.disabled,
2381
+ className: modelSelectorItemVariants({ className: void 0 }),
2382
+ children: [
2383
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-2", children: [
2384
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "font-medium", children: model.label }),
2385
+ model.badge && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "rounded-full bg-secondary px-2 py-0.5 text-xs text-secondary-foreground", children: model.badge })
2386
+ ] }),
2387
+ model.description && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-muted-foreground", children: model.description }),
2388
+ model.meta && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-muted-foreground", children: model.meta })
2389
+ ]
2390
+ },
2391
+ model.value
2392
+ )),
2393
+ /* @__PURE__ */ jsxRuntime.jsx(combobox.Combobox.Empty, { className: "py-2 text-center text-sm text-muted-foreground", children: emptyMessage })
2394
+ ] })
2395
+ }
2396
+ ) }) })
2397
+ ] })
2398
+ }
2399
+ );
2400
+ }
2401
+ MosaicModelSelector.displayName = "MosaicModelSelector";
2402
+ function cn37(...classes) {
2403
+ return classes.filter(Boolean).join(" ");
2404
+ }
2290
2405
  function MosaicDropdownMenu({
2291
2406
  trigger,
2292
2407
  items,
@@ -2301,7 +2416,7 @@ function MosaicDropdownMenu({
2301
2416
  menu.Menu.Popup,
2302
2417
  {
2303
2418
  "data-slot": "dropdown-menu",
2304
- className: cn36(
2419
+ className: cn37(
2305
2420
  "z-50 min-w-[8rem] overflow-hidden rounded-md border border-border",
2306
2421
  "bg-popover p-1 text-popover-foreground shadow-md",
2307
2422
  "origin-[var(--transform-origin)]",
@@ -2311,14 +2426,14 @@ function MosaicDropdownMenu({
2311
2426
  "data-[starting-style]:scale-95 data-[starting-style]:opacity-0",
2312
2427
  className
2313
2428
  ),
2314
- children: items.map((item) => /* @__PURE__ */ jsxRuntime.jsxs(React28__namespace.Fragment, { children: [
2429
+ children: items.map((item) => /* @__PURE__ */ jsxRuntime.jsxs(React29__namespace.Fragment, { children: [
2315
2430
  item.separator && /* @__PURE__ */ jsxRuntime.jsx(menu.Menu.Separator, { className: "my-1 h-px bg-border" }),
2316
2431
  /* @__PURE__ */ jsxRuntime.jsx(
2317
2432
  menu.Menu.Item,
2318
2433
  {
2319
2434
  disabled: item.disabled,
2320
2435
  onClick: () => onItemSelect?.(item.id),
2321
- className: cn36(
2436
+ className: cn37(
2322
2437
  "relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5",
2323
2438
  "text-sm text-popover-foreground outline-none",
2324
2439
  "data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground",
@@ -2339,8 +2454,8 @@ var BREAKPOINTS = {
2339
2454
  xl: 1280
2340
2455
  };
2341
2456
  function useBreakpoint(breakpoint) {
2342
- const [matches, setMatches] = React28__namespace.useState(false);
2343
- React28__namespace.useEffect(() => {
2457
+ const [matches, setMatches] = React29__namespace.useState(false);
2458
+ React29__namespace.useEffect(() => {
2344
2459
  if (typeof window === "undefined") return;
2345
2460
  const mq = window.matchMedia(`(min-width: ${BREAKPOINTS[breakpoint]}px)`);
2346
2461
  setMatches(mq.matches);
@@ -2363,8 +2478,8 @@ function useIsDesktop() {
2363
2478
  return useBreakpoint("lg");
2364
2479
  }
2365
2480
  function useViewport() {
2366
- const [size, setSize] = React28__namespace.useState({ width: 0, height: 0 });
2367
- React28__namespace.useEffect(() => {
2481
+ const [size, setSize] = React29__namespace.useState({ width: 0, height: 0 });
2482
+ React29__namespace.useEffect(() => {
2368
2483
  if (typeof window === "undefined") return;
2369
2484
  const update = () => setSize({ width: window.innerWidth, height: window.innerHeight });
2370
2485
  update();
@@ -2382,8 +2497,8 @@ function useViewport() {
2382
2497
  return size;
2383
2498
  }
2384
2499
  function useOrientation() {
2385
- const [orientation, setOrientation] = React28__namespace.useState("portrait");
2386
- React28__namespace.useEffect(() => {
2500
+ const [orientation, setOrientation] = React29__namespace.useState("portrait");
2501
+ React29__namespace.useEffect(() => {
2387
2502
  if (typeof window === "undefined") return;
2388
2503
  const update = () => {
2389
2504
  setOrientation(window.innerHeight > window.innerWidth ? "portrait" : "landscape");
@@ -2398,7 +2513,7 @@ function useOrientation() {
2398
2513
  }, []);
2399
2514
  return orientation;
2400
2515
  }
2401
- var DeviceContext = React28__namespace.createContext(void 0);
2516
+ var DeviceContext = React29__namespace.createContext(void 0);
2402
2517
  function MosaicDeviceProvider({ children }) {
2403
2518
  const isMobile = useIsMobile();
2404
2519
  const isTablet = useIsTablet();
@@ -2409,7 +2524,7 @@ function MosaicDeviceProvider({ children }) {
2409
2524
  const isXlUp = useBreakpoint("xl");
2410
2525
  const orientation = useOrientation();
2411
2526
  const viewport = useViewport();
2412
- const isBreakpoint = React28__namespace.useCallback(
2527
+ const isBreakpoint = React29__namespace.useCallback(
2413
2528
  (bp) => {
2414
2529
  switch (bp) {
2415
2530
  case "sm":
@@ -2424,7 +2539,7 @@ function MosaicDeviceProvider({ children }) {
2424
2539
  },
2425
2540
  [isSmUp, isMdUp, isLgUp, isXlUp]
2426
2541
  );
2427
- const value = React28__namespace.useMemo(
2542
+ const value = React29__namespace.useMemo(
2428
2543
  () => ({
2429
2544
  isMobile,
2430
2545
  isTablet,
@@ -2454,13 +2569,13 @@ function MosaicDeviceProvider({ children }) {
2454
2569
  }
2455
2570
  MosaicDeviceProvider.displayName = "MosaicDeviceProvider";
2456
2571
  function useDevice() {
2457
- const ctx = React28__namespace.useContext(DeviceContext);
2572
+ const ctx = React29__namespace.useContext(DeviceContext);
2458
2573
  if (!ctx) {
2459
2574
  throw new Error("useDevice must be used within a MosaicDeviceProvider");
2460
2575
  }
2461
2576
  return ctx;
2462
2577
  }
2463
- function cn37(...classes) {
2578
+ function cn38(...classes) {
2464
2579
  return classes.filter(Boolean).join(" ");
2465
2580
  }
2466
2581
  function MosaicAdaptiveGrid({
@@ -2479,14 +2594,14 @@ function MosaicAdaptiveGrid({
2479
2594
  {
2480
2595
  ref,
2481
2596
  "data-slot": "adaptive-grid",
2482
- className: cn37("grid", gap, className),
2597
+ className: cn38("grid", gap, className),
2483
2598
  style: { gridTemplateColumns: `repeat(${cols}, minmax(0, 1fr))` },
2484
2599
  children
2485
2600
  }
2486
2601
  );
2487
2602
  }
2488
2603
  MosaicAdaptiveGrid.displayName = "MosaicAdaptiveGrid";
2489
- function cn38(...classes) {
2604
+ function cn39(...classes) {
2490
2605
  return classes.filter(Boolean).join(" ");
2491
2606
  }
2492
2607
  var ANIM_ID = "mosaic-adaptive-modal-kf";
@@ -2540,13 +2655,13 @@ function MosaicAdaptiveModal({
2540
2655
  closeAriaLabel
2541
2656
  }) {
2542
2657
  const { isMobile } = useDevice();
2543
- const dialogRef = React28__namespace.useRef(null);
2544
- const titleId = React28__namespace.useId();
2545
- const descId = React28__namespace.useId();
2546
- React28__namespace.useEffect(() => {
2658
+ const dialogRef = React29__namespace.useRef(null);
2659
+ const titleId = React29__namespace.useId();
2660
+ const descId = React29__namespace.useId();
2661
+ React29__namespace.useEffect(() => {
2547
2662
  injectStyles();
2548
2663
  }, []);
2549
- React28__namespace.useEffect(() => {
2664
+ React29__namespace.useEffect(() => {
2550
2665
  const el = dialogRef.current;
2551
2666
  if (!el) return;
2552
2667
  if (isOpen) {
@@ -2555,7 +2670,7 @@ function MosaicAdaptiveModal({
2555
2670
  if (el.open) el.close();
2556
2671
  }
2557
2672
  }, [isOpen]);
2558
- React28__namespace.useEffect(() => {
2673
+ React29__namespace.useEffect(() => {
2559
2674
  const el = dialogRef.current;
2560
2675
  if (!el) return;
2561
2676
  const handler = (e) => {
@@ -2565,7 +2680,7 @@ function MosaicAdaptiveModal({
2565
2680
  el.addEventListener("cancel", handler);
2566
2681
  return () => el.removeEventListener("cancel", handler);
2567
2682
  }, [onClose]);
2568
- React28__namespace.useEffect(() => {
2683
+ React29__namespace.useEffect(() => {
2569
2684
  if (!isOpen) return;
2570
2685
  const prev = document.body.style.overflow;
2571
2686
  document.body.style.overflow = "hidden";
@@ -2592,7 +2707,7 @@ function MosaicAdaptiveModal({
2592
2707
  children: /* @__PURE__ */ jsxRuntime.jsxs(
2593
2708
  "div",
2594
2709
  {
2595
- className: cn38(
2710
+ className: cn39(
2596
2711
  "mosaic-sheet-panel relative w-full rounded-t-2xl border-t border-border bg-background",
2597
2712
  "max-h-[90dvh] flex flex-col",
2598
2713
  className
@@ -2625,7 +2740,7 @@ function MosaicAdaptiveModal({
2625
2740
  children: /* @__PURE__ */ jsxRuntime.jsxs(
2626
2741
  "div",
2627
2742
  {
2628
- className: cn38(
2743
+ className: cn39(
2629
2744
  "mosaic-modal-panel relative w-[min(90vw,42rem)] rounded-xl border border-border bg-background shadow-xl",
2630
2745
  "max-h-[90vh] flex flex-col",
2631
2746
  className
@@ -2673,7 +2788,7 @@ function MosaicAdaptiveModal({
2673
2788
  );
2674
2789
  }
2675
2790
  MosaicAdaptiveModal.displayName = "MosaicAdaptiveModal";
2676
- function cn39(...classes) {
2791
+ function cn40(...classes) {
2677
2792
  return classes.filter(Boolean).join(" ");
2678
2793
  }
2679
2794
  function CheckIcon2() {
@@ -2734,7 +2849,7 @@ function MosaicAdaptiveNavigation({
2734
2849
  {
2735
2850
  ref,
2736
2851
  "data-slot": "adaptive-navigation",
2737
- className: cn39("space-y-3", className),
2852
+ className: cn40("space-y-3", className),
2738
2853
  "aria-label": stepNavAriaLabel,
2739
2854
  children: items.map((item, idx) => {
2740
2855
  const isExpanded = expandedItems?.has(item.id) ?? false;
@@ -2752,7 +2867,7 @@ function MosaicAdaptiveNavigation({
2752
2867
  /* @__PURE__ */ jsxRuntime.jsx(
2753
2868
  "div",
2754
2869
  {
2755
- className: cn39(
2870
+ className: cn40(
2756
2871
  "flex h-8 w-8 shrink-0 items-center justify-center rounded-full text-xs font-bold",
2757
2872
  item.isComplete ? "bg-green-500 text-white" : "bg-muted text-muted-foreground"
2758
2873
  ),
@@ -2786,7 +2901,7 @@ function MosaicAdaptiveNavigation({
2786
2901
  {
2787
2902
  ref,
2788
2903
  "data-slot": "adaptive-navigation",
2789
- className: cn39("w-full", className),
2904
+ className: cn40("w-full", className),
2790
2905
  "aria-label": tabNavAriaLabel,
2791
2906
  children: /* @__PURE__ */ jsxRuntime.jsx(
2792
2907
  "div",
@@ -2803,7 +2918,7 @@ function MosaicAdaptiveNavigation({
2803
2918
  role: "tab",
2804
2919
  "aria-selected": isActive,
2805
2920
  onClick: () => onItemChange(item.id),
2806
- className: cn39(
2921
+ className: cn40(
2807
2922
  "flex items-center justify-center gap-2 rounded-md px-3 py-2 text-sm font-medium transition-colors",
2808
2923
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-1",
2809
2924
  isActive ? "bg-primary text-primary-foreground shadow-sm" : "text-muted-foreground hover:text-foreground"
@@ -2812,7 +2927,7 @@ function MosaicAdaptiveNavigation({
2812
2927
  /* @__PURE__ */ jsxRuntime.jsx(
2813
2928
  "div",
2814
2929
  {
2815
- className: cn39(
2930
+ className: cn40(
2816
2931
  "flex h-6 w-6 shrink-0 items-center justify-center rounded-full text-xs font-bold",
2817
2932
  item.isComplete ? "bg-green-500 text-white" : isActive ? "bg-primary-foreground/20 text-primary-foreground" : "bg-background text-muted-foreground"
2818
2933
  ),
@@ -2824,7 +2939,7 @@ function MosaicAdaptiveNavigation({
2824
2939
  item.duration !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs(
2825
2940
  "span",
2826
2941
  {
2827
- className: cn39(
2942
+ className: cn40(
2828
2943
  "rounded px-1 py-0.5 text-xs",
2829
2944
  isActive ? "bg-primary-foreground/20" : "bg-muted"
2830
2945
  ),
@@ -2845,7 +2960,7 @@ function MosaicAdaptiveNavigation({
2845
2960
  );
2846
2961
  }
2847
2962
  MosaicAdaptiveNavigation.displayName = "MosaicAdaptiveNavigation";
2848
- function cn40(...classes) {
2963
+ function cn41(...classes) {
2849
2964
  return classes.filter(Boolean).join(" ");
2850
2965
  }
2851
2966
  var ANIM_ID2 = "mosaic-sidebar-kf";
@@ -2997,8 +3112,8 @@ function MosaicAppSidebar({
2997
3112
  ref
2998
3113
  }) {
2999
3114
  const { isMobile } = useDevice();
3000
- const [expandedItems, setExpandedItems] = React28__namespace.useState(/* @__PURE__ */ new Set());
3001
- React28__namespace.useEffect(() => {
3115
+ const [expandedItems, setExpandedItems] = React29__namespace.useState(/* @__PURE__ */ new Set());
3116
+ React29__namespace.useEffect(() => {
3002
3117
  injectStyles2();
3003
3118
  }, []);
3004
3119
  const sidebarWidth = isMobile ? "100%" : isCollapsed ? "64px" : "280px";
@@ -3021,7 +3136,7 @@ function MosaicAppSidebar({
3021
3136
  {
3022
3137
  ref,
3023
3138
  "data-slot": "app-sidebar",
3024
- className: cn40(
3139
+ className: cn41(
3025
3140
  "flex h-full flex-col bg-sidebar border-r border-sidebar-border",
3026
3141
  isMobile && "border-r-0",
3027
3142
  className
@@ -3041,7 +3156,7 @@ function MosaicAppSidebar({
3041
3156
  type: "button",
3042
3157
  onClick: onToggleCollapse,
3043
3158
  "aria-label": isCollapsed ? expandSidebarAriaLabel : collapseSidebarAriaLabel,
3044
- className: cn40(
3159
+ className: cn41(
3045
3160
  "flex h-9 w-9 items-center justify-center rounded-lg transition-colors",
3046
3161
  "hover:bg-sidebar-accent text-sidebar-foreground",
3047
3162
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -3071,7 +3186,7 @@ function MosaicAppSidebar({
3071
3186
  },
3072
3187
  "aria-current": isActive ? "page" : void 0,
3073
3188
  "aria-expanded": hasSubmenu && !isCollapsed ? isExpanded : void 0,
3074
- className: cn40(
3189
+ className: cn41(
3075
3190
  "group flex w-full min-h-[44px] items-center rounded-lg p-3 transition-colors",
3076
3191
  "hover:bg-sidebar-accent",
3077
3192
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -3098,7 +3213,7 @@ function MosaicAppSidebar({
3098
3213
  type: "button",
3099
3214
  onClick: () => handleNavClick(sub.href),
3100
3215
  "aria-current": isSubActive ? "page" : void 0,
3101
- className: cn40(
3216
+ className: cn41(
3102
3217
  "flex w-full min-h-[40px] items-center gap-3 rounded-lg px-3 py-2 text-sm transition-colors",
3103
3218
  "hover:bg-sidebar-accent/50 text-sidebar-foreground",
3104
3219
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -3121,7 +3236,7 @@ function MosaicAppSidebar({
3121
3236
  {
3122
3237
  type: "button",
3123
3238
  onClick: action.onClick,
3124
- className: cn40(
3239
+ className: cn41(
3125
3240
  "flex w-full min-h-[44px] items-center gap-3 rounded-lg px-3 py-2 text-sm font-medium",
3126
3241
  "text-sidebar-foreground transition-colors hover:bg-sidebar-accent",
3127
3242
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -3168,7 +3283,7 @@ function MosaicAppSidebar({
3168
3283
  );
3169
3284
  }
3170
3285
  MosaicAppSidebar.displayName = "MosaicAppSidebar";
3171
- function cn41(...classes) {
3286
+ function cn42(...classes) {
3172
3287
  return classes.filter(Boolean).join(" ");
3173
3288
  }
3174
3289
  var ANIM_ID3 = "mosaic-dashboard-kf";
@@ -3250,9 +3365,9 @@ function MosaicDashboardLayout({
3250
3365
  ref
3251
3366
  }) {
3252
3367
  const { isMobile } = useDevice();
3253
- const [isSidebarCollapsed, setIsSidebarCollapsed] = React28__namespace.useState(defaultSidebarCollapsed);
3254
- const [isMobileSidebarOpen, setIsMobileSidebarOpen] = React28__namespace.useState(false);
3255
- React28__namespace.useEffect(() => {
3368
+ const [isSidebarCollapsed, setIsSidebarCollapsed] = React29__namespace.useState(defaultSidebarCollapsed);
3369
+ const [isMobileSidebarOpen, setIsMobileSidebarOpen] = React29__namespace.useState(false);
3370
+ React29__namespace.useEffect(() => {
3256
3371
  injectStyles3();
3257
3372
  }, []);
3258
3373
  const defaultRenderLink2 = (href, children2) => /* @__PURE__ */ jsxRuntime.jsx("a", { href, className: "transition-colors hover:text-foreground", children: children2 });
@@ -3262,7 +3377,7 @@ function MosaicDashboardLayout({
3262
3377
  {
3263
3378
  ref,
3264
3379
  "data-slot": "dashboard-layout",
3265
- className: cn41("flex h-screen w-full bg-background", className),
3380
+ className: cn42("flex h-screen w-full bg-background", className),
3266
3381
  children: [
3267
3382
  !isMobile && /* @__PURE__ */ jsxRuntime.jsx(
3268
3383
  MosaicAppSidebar,
@@ -3286,7 +3401,7 @@ function MosaicDashboardLayout({
3286
3401
  type: "button",
3287
3402
  "aria-label": openNavigationAriaLabel,
3288
3403
  onClick: () => setIsMobileSidebarOpen(true),
3289
- className: cn41(
3404
+ className: cn42(
3290
3405
  "flex h-11 w-11 shrink-0 items-center justify-center rounded-lg",
3291
3406
  "text-foreground transition-colors hover:bg-muted",
3292
3407
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -3339,7 +3454,7 @@ function MosaicDashboardLayout({
3339
3454
  );
3340
3455
  }
3341
3456
  MosaicDashboardLayout.displayName = "MosaicDashboardLayout";
3342
- function cn42(...classes) {
3457
+ function cn43(...classes) {
3343
3458
  return classes.filter(Boolean).join(" ");
3344
3459
  }
3345
3460
  var ANIM_ID4 = "mosaic-quick-action-kf";
@@ -3384,7 +3499,7 @@ function MosaicQuickActionCard({
3384
3499
  ref
3385
3500
  }) {
3386
3501
  const { mobile = 2, desktop = 3 } = columns;
3387
- React28__namespace.useEffect(() => {
3502
+ React29__namespace.useEffect(() => {
3388
3503
  injectStyles4();
3389
3504
  }, []);
3390
3505
  const defaultRenderLink2 = (href, children) => /* @__PURE__ */ jsxRuntime.jsx("a", { href, className: "block h-full", children });
@@ -3394,7 +3509,7 @@ function MosaicQuickActionCard({
3394
3509
  {
3395
3510
  ref,
3396
3511
  "data-slot": "quick-action-card",
3397
- className: cn42("rounded-xl border border-border bg-card", className),
3512
+ className: cn43("rounded-xl border border-border bg-card", className),
3398
3513
  children: [
3399
3514
  heading && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-b border-border px-6 py-4", children: /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-lg font-semibold text-foreground", children: heading }) }),
3400
3515
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -3419,7 +3534,7 @@ function MosaicQuickActionCard({
3419
3534
  /* @__PURE__ */ jsxRuntime.jsxs(
3420
3535
  "div",
3421
3536
  {
3422
- className: cn42(
3537
+ className: cn43(
3423
3538
  "flex min-h-[100px] cursor-pointer flex-col items-center justify-center gap-2 rounded-xl border p-4",
3424
3539
  "transition-transform duration-150 hover:scale-105 active:scale-[0.98]",
3425
3540
  accentClass
@@ -3452,7 +3567,7 @@ function MosaicQuickActionCard({
3452
3567
  );
3453
3568
  }
3454
3569
  MosaicQuickActionCard.displayName = "MosaicQuickActionCard";
3455
- function cn43(...classes) {
3570
+ function cn44(...classes) {
3456
3571
  return classes.filter(Boolean).join(" ");
3457
3572
  }
3458
3573
  var ANIM_ID5 = "mosaic-activity-feed-kf";
@@ -3541,7 +3656,7 @@ function MosaicActivityItem({ activity, icon, className }) {
3541
3656
  "div",
3542
3657
  {
3543
3658
  "data-slot": "activity-item",
3544
- className: cn43(
3659
+ className: cn44(
3545
3660
  "flex cursor-pointer items-start gap-4 rounded-lg p-3 transition-colors hover:bg-muted/50",
3546
3661
  className
3547
3662
  ),
@@ -3575,7 +3690,7 @@ function MosaicActivityItem({ activity, icon, className }) {
3575
3690
  /* @__PURE__ */ jsxRuntime.jsx(
3576
3691
  "span",
3577
3692
  {
3578
- className: cn43(
3693
+ className: cn44(
3579
3694
  "rounded-full px-2 py-0.5 text-xs font-medium",
3580
3695
  getStatusClass(activity.status)
3581
3696
  ),
@@ -3601,7 +3716,7 @@ function MosaicActivityFeed({
3601
3716
  className,
3602
3717
  ref
3603
3718
  }) {
3604
- React28__namespace.useEffect(() => {
3719
+ React29__namespace.useEffect(() => {
3605
3720
  injectStyles5();
3606
3721
  }, []);
3607
3722
  const defaultRenderLink2 = (href, children) => /* @__PURE__ */ jsxRuntime.jsx(
@@ -3618,7 +3733,7 @@ function MosaicActivityFeed({
3618
3733
  {
3619
3734
  ref,
3620
3735
  "data-slot": "activity-feed",
3621
- className: cn43("rounded-xl border border-border bg-card", className),
3736
+ className: cn44("rounded-xl border border-border bg-card", className),
3622
3737
  children: [
3623
3738
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between border-b border-border px-6 py-4", children: [
3624
3739
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-lg font-semibold text-foreground", children: heading }),
@@ -3644,7 +3759,7 @@ function MosaicActivityFeed({
3644
3759
  );
3645
3760
  }
3646
3761
  MosaicActivityFeed.displayName = "MosaicActivityFeed";
3647
- function cn44(...classes) {
3762
+ function cn45(...classes) {
3648
3763
  return classes.filter(Boolean).join(" ");
3649
3764
  }
3650
3765
  function SparklesIcon() {
@@ -3852,7 +3967,7 @@ function MosaicAgentComposerDesktop({
3852
3967
  value: agentName,
3853
3968
  onChange: (e) => onAgentNameChange(e.target.value),
3854
3969
  placeholder: agentNamePlaceholder,
3855
- className: cn44(
3970
+ className: cn45(
3856
3971
  "flex min-h-[48px] w-full rounded-lg border border-input bg-transparent px-3 py-2 text-sm",
3857
3972
  "placeholder:text-muted-foreground",
3858
3973
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -3953,7 +4068,7 @@ function MosaicAgentComposerDesktop({
3953
4068
  onChange: (e) => onCustomInstructionsChange(e.target.value),
3954
4069
  placeholder: instructionsPlaceholder,
3955
4070
  rows: 5,
3956
- className: cn44(
4071
+ className: cn45(
3957
4072
  "flex w-full resize-y rounded-lg border border-input bg-transparent px-3 py-2 text-sm",
3958
4073
  "placeholder:text-muted-foreground",
3959
4074
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -4021,7 +4136,7 @@ function MosaicAgentComposerDesktop({
4021
4136
  /* @__PURE__ */ jsxRuntime.jsx(SparklesIcon, {}),
4022
4137
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground", children: selectAllModulesLabel })
4023
4138
  ] }) }),
4024
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn44("flex gap-2", isEditMode && onCancel ? "flex-row" : "flex-col"), children: [
4139
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn45("flex gap-2", isEditMode && onCancel ? "flex-row" : "flex-col"), children: [
4025
4140
  isEditMode && onCancel && /* @__PURE__ */ jsxRuntime.jsx(
4026
4141
  "button",
4027
4142
  {
@@ -4037,7 +4152,7 @@ function MosaicAgentComposerDesktop({
4037
4152
  type: "button",
4038
4153
  onClick: onSave,
4039
4154
  disabled: !canSave,
4040
- className: cn44(
4155
+ className: cn45(
4041
4156
  "flex min-h-[48px] items-center justify-center gap-2 rounded-lg text-sm font-medium transition-colors",
4042
4157
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
4043
4158
  "bg-primary text-primary-foreground hover:bg-primary/90",
@@ -4058,7 +4173,7 @@ function MosaicAgentComposerDesktop({
4058
4173
  ] });
4059
4174
  }
4060
4175
  MosaicAgentComposerDesktop.displayName = "MosaicAgentComposerDesktop";
4061
- function cn45(...classes) {
4176
+ function cn46(...classes) {
4062
4177
  return classes.filter(Boolean).join(" ");
4063
4178
  }
4064
4179
  function SparklesIcon2() {
@@ -4271,7 +4386,7 @@ function MosaicAgentComposerMobile({
4271
4386
  optionalInstructionsHelp
4272
4387
  }) {
4273
4388
  const L = labels;
4274
- const instructionsId = React28__namespace.useId();
4389
+ const instructionsId = React29__namespace.useId();
4275
4390
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "agent-composer-mobile", className: "flex h-full flex-col", children: [
4276
4391
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "shrink-0 sticky top-0 z-10 border-b border-border bg-background px-4 pt-4 pb-3", children: [
4277
4392
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
@@ -4312,7 +4427,7 @@ function MosaicAgentComposerMobile({
4312
4427
  disabled: isLoading,
4313
4428
  "aria-required": "true",
4314
4429
  "aria-invalid": canSave && !agentName ? "true" : "false",
4315
- className: cn45(
4430
+ className: cn46(
4316
4431
  "flex min-h-[48px] w-full rounded-lg border border-input bg-transparent px-3 py-2 text-sm",
4317
4432
  "placeholder:text-muted-foreground",
4318
4433
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -4419,7 +4534,7 @@ function MosaicAgentComposerMobile({
4419
4534
  disabled: isLoading,
4420
4535
  "aria-describedby": `${instructionsId}-help`,
4421
4536
  rows: 4,
4422
- className: cn45(
4537
+ className: cn46(
4423
4538
  "flex w-full resize-y rounded-lg border border-input bg-transparent px-3 py-2 text-sm",
4424
4539
  "placeholder:text-muted-foreground",
4425
4540
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -4475,7 +4590,7 @@ function MosaicAgentComposer(props) {
4475
4590
  return isMobile ? /* @__PURE__ */ jsxRuntime.jsx(MosaicAgentComposerMobile, { ...props }) : /* @__PURE__ */ jsxRuntime.jsx(MosaicAgentComposerDesktop, { ...props });
4476
4591
  }
4477
4592
  MosaicAgentComposer.displayName = "MosaicAgentComposer";
4478
- function cn46(...classes) {
4593
+ function cn47(...classes) {
4479
4594
  return classes.filter(Boolean).join(" ");
4480
4595
  }
4481
4596
  function EditIcon() {
@@ -4536,7 +4651,7 @@ function MosaicModuleCard({
4536
4651
  {
4537
4652
  ref,
4538
4653
  "data-slot": "module-card",
4539
- className: cn46(
4654
+ className: cn47(
4540
4655
  "min-h-[80px] rounded-xl border border-border bg-card p-4 transition-all",
4541
4656
  "flex items-start gap-3",
4542
4657
  isSelected && "ring-2 ring-primary bg-primary/5",
@@ -4598,7 +4713,7 @@ function MosaicThemeProvider({
4598
4713
  return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-slot": "theme-provider", children });
4599
4714
  }
4600
4715
  MosaicThemeProvider.displayName = "MosaicThemeProvider";
4601
- function cn47(...classes) {
4716
+ function cn48(...classes) {
4602
4717
  return classes.filter(Boolean).join(" ");
4603
4718
  }
4604
4719
  var ANIM_ID6 = "mosaic-delete-dialog-kf";
@@ -4640,21 +4755,21 @@ function MosaicDeleteConfirmationDialog({
4640
4755
  cancelLabel,
4641
4756
  confirmLabel
4642
4757
  }) {
4643
- React28__namespace.useEffect(() => {
4758
+ React29__namespace.useEffect(() => {
4644
4759
  injectStyles6();
4645
4760
  }, []);
4646
4761
  return /* @__PURE__ */ jsxRuntime.jsx(alertDialog.AlertDialog.Root, { open, onOpenChange, children: /* @__PURE__ */ jsxRuntime.jsxs(alertDialog.AlertDialog.Portal, { children: [
4647
4762
  /* @__PURE__ */ jsxRuntime.jsx(
4648
4763
  alertDialog.AlertDialog.Backdrop,
4649
4764
  {
4650
- className: cn47("mosaic-delete-overlay", "fixed inset-0 z-50 bg-black/50")
4765
+ className: cn48("mosaic-delete-overlay", "fixed inset-0 z-50 bg-black/50")
4651
4766
  }
4652
4767
  ),
4653
4768
  /* @__PURE__ */ jsxRuntime.jsxs(
4654
4769
  alertDialog.AlertDialog.Popup,
4655
4770
  {
4656
4771
  "data-slot": "delete-confirmation-dialog",
4657
- className: cn47(
4772
+ className: cn48(
4658
4773
  "mosaic-delete-content",
4659
4774
  "fixed left-1/2 top-1/2 z-50",
4660
4775
  "w-full max-w-[92vw] sm:max-w-md",
@@ -4667,7 +4782,7 @@ function MosaicDeleteConfirmationDialog({
4667
4782
  /* @__PURE__ */ jsxRuntime.jsx(
4668
4783
  alertDialog.AlertDialog.Close,
4669
4784
  {
4670
- className: cn47(
4785
+ className: cn48(
4671
4786
  "inline-flex min-h-[44px] w-full items-center justify-center rounded-md border border-border",
4672
4787
  "bg-background px-4 py-2 text-sm font-medium text-foreground",
4673
4788
  "hover:bg-accent hover:text-accent-foreground",
@@ -4681,7 +4796,7 @@ function MosaicDeleteConfirmationDialog({
4681
4796
  alertDialog.AlertDialog.Close,
4682
4797
  {
4683
4798
  onClick: onConfirm,
4684
- className: cn47(
4799
+ className: cn48(
4685
4800
  "inline-flex min-h-[44px] w-full items-center justify-center rounded-md",
4686
4801
  "bg-destructive px-4 py-2 text-sm font-medium text-destructive-foreground",
4687
4802
  "hover:bg-destructive/90",
@@ -4698,7 +4813,7 @@ function MosaicDeleteConfirmationDialog({
4698
4813
  ] }) });
4699
4814
  }
4700
4815
  MosaicDeleteConfirmationDialog.displayName = "MosaicDeleteConfirmationDialog";
4701
- function cn48(...classes) {
4816
+ function cn49(...classes) {
4702
4817
  return classes.filter(Boolean).join(" ");
4703
4818
  }
4704
4819
  function Toggle({
@@ -4714,7 +4829,7 @@ function Toggle({
4714
4829
  id,
4715
4830
  "aria-checked": checked,
4716
4831
  onClick: () => onChange(!checked),
4717
- className: cn48(
4832
+ className: cn49(
4718
4833
  "relative inline-flex h-6 w-11 shrink-0 cursor-pointer rounded-full border-2 border-transparent",
4719
4834
  "transition-colors duration-200 ease-in-out",
4720
4835
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
@@ -4723,7 +4838,7 @@ function Toggle({
4723
4838
  children: /* @__PURE__ */ jsxRuntime.jsx(
4724
4839
  "span",
4725
4840
  {
4726
- className: cn48(
4841
+ className: cn49(
4727
4842
  "pointer-events-none inline-block h-5 w-5 rounded-full bg-background shadow-lg",
4728
4843
  "transform transition duration-200 ease-in-out",
4729
4844
  checked ? "translate-x-5" : "translate-x-0"
@@ -4745,7 +4860,7 @@ function NativeSelect({
4745
4860
  id,
4746
4861
  value,
4747
4862
  onChange: (e) => onChange(e.target.value),
4748
- className: cn48(
4863
+ className: cn49(
4749
4864
  "flex min-h-[48px] w-full rounded-md border border-input bg-background px-3 py-2",
4750
4865
  "text-sm text-foreground",
4751
4866
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -4765,7 +4880,7 @@ function MosaicPreferencesPanel({
4765
4880
  className
4766
4881
  }) {
4767
4882
  const { isMobile } = useDevice();
4768
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "preferences-panel", className: cn48("space-y-4 md:space-y-6", className), children: [
4883
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "preferences-panel", className: cn49("space-y-4 md:space-y-6", className), children: [
4769
4884
  groups.map((group) => /* @__PURE__ */ jsxRuntime.jsxs(
4770
4885
  "div",
4771
4886
  {
@@ -4808,13 +4923,13 @@ function MosaicPreferencesPanel({
4808
4923
  },
4809
4924
  group.id
4810
4925
  )),
4811
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn48("flex", isMobile ? "flex-col" : "justify-end"), children: /* @__PURE__ */ jsxRuntime.jsxs(
4926
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn49("flex", isMobile ? "flex-col" : "justify-end"), children: /* @__PURE__ */ jsxRuntime.jsxs(
4812
4927
  "button",
4813
4928
  {
4814
4929
  type: "button",
4815
4930
  onClick: onSave,
4816
4931
  disabled: isSaving,
4817
- className: cn48(
4932
+ className: cn49(
4818
4933
  "inline-flex min-h-[44px] items-center justify-center gap-2 rounded-md",
4819
4934
  "bg-primary px-4 py-2 text-sm font-medium text-primary-foreground",
4820
4935
  "hover:bg-primary/90",
@@ -4850,7 +4965,7 @@ function MosaicPreferencesPanel({
4850
4965
  ] });
4851
4966
  }
4852
4967
  MosaicPreferencesPanel.displayName = "MosaicPreferencesPanel";
4853
- function cn49(...classes) {
4968
+ function cn50(...classes) {
4854
4969
  return classes.filter(Boolean).join(" ");
4855
4970
  }
4856
4971
  function AvatarDisplay({
@@ -4863,7 +4978,7 @@ function AvatarDisplay({
4863
4978
  return /* @__PURE__ */ jsxRuntime.jsx(
4864
4979
  "span",
4865
4980
  {
4866
- className: cn49(
4981
+ className: cn50(
4867
4982
  "inline-flex shrink-0 items-center justify-center rounded-full bg-muted text-muted-foreground font-semibold overflow-hidden",
4868
4983
  sizeClass
4869
4984
  ),
@@ -4895,7 +5010,7 @@ function MosaicProfilePanel({
4895
5010
  className
4896
5011
  }) {
4897
5012
  const { isMobile } = useDevice();
4898
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "profile-panel", className: cn49("space-y-4 md:space-y-6", className), children: [
5013
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "profile-panel", className: cn50("space-y-4 md:space-y-6", className), children: [
4899
5014
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-lg border border-border bg-card text-card-foreground shadow-sm", children: [
4900
5015
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col space-y-1.5 p-6", children: [
4901
5016
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "text-lg font-semibold leading-none tracking-tight md:text-xl", children: avatarHeading }),
@@ -4915,7 +5030,7 @@ function MosaicProfilePanel({
4915
5030
  {
4916
5031
  type: "button",
4917
5032
  onClick: onAvatarUpload,
4918
- className: cn49(
5033
+ className: cn50(
4919
5034
  "inline-flex min-h-[44px] items-center justify-center gap-2 rounded-md border border-border",
4920
5035
  "bg-background px-4 py-2 text-sm font-medium text-foreground",
4921
5036
  "hover:bg-accent hover:text-accent-foreground",
@@ -4965,7 +5080,7 @@ function MosaicProfilePanel({
4965
5080
  placeholder: field.placeholder,
4966
5081
  onChange: (e) => onFieldChange?.(field.id, e.target.value),
4967
5082
  rows: 4,
4968
- className: cn49(
5083
+ className: cn50(
4969
5084
  "flex min-h-[120px] w-full rounded-md border border-input bg-background px-3 py-2",
4970
5085
  "text-sm text-foreground placeholder:text-muted-foreground",
4971
5086
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -4981,7 +5096,7 @@ function MosaicProfilePanel({
4981
5096
  readOnly: field.readOnly,
4982
5097
  placeholder: field.placeholder,
4983
5098
  onChange: (e) => onFieldChange?.(field.id, e.target.value),
4984
- className: cn49(
5099
+ className: cn50(
4985
5100
  "flex min-h-[48px] w-full rounded-md border border-input bg-background px-3 py-2",
4986
5101
  "text-sm text-foreground placeholder:text-muted-foreground",
4987
5102
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -5001,7 +5116,7 @@ function MosaicProfilePanel({
5001
5116
  {
5002
5117
  type: "button",
5003
5118
  onClick: onChangePassword,
5004
- className: cn49(
5119
+ className: cn50(
5005
5120
  "inline-flex min-h-[44px] items-center justify-center rounded-md border border-border",
5006
5121
  "bg-background px-4 py-2 text-sm font-medium text-foreground",
5007
5122
  "hover:bg-accent hover:text-accent-foreground",
@@ -5013,13 +5128,13 @@ function MosaicProfilePanel({
5013
5128
  ) })
5014
5129
  ] }),
5015
5130
  extraSections,
5016
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn49("flex", isMobile ? "flex-col" : "justify-end"), children: /* @__PURE__ */ jsxRuntime.jsxs(
5131
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn50("flex", isMobile ? "flex-col" : "justify-end"), children: /* @__PURE__ */ jsxRuntime.jsxs(
5017
5132
  "button",
5018
5133
  {
5019
5134
  type: "button",
5020
5135
  onClick: onSave,
5021
5136
  disabled: isSaving,
5022
- className: cn49(
5137
+ className: cn50(
5023
5138
  "inline-flex min-h-[44px] items-center justify-center gap-2 rounded-md",
5024
5139
  "bg-primary px-4 py-2 text-sm font-medium text-primary-foreground",
5025
5140
  "hover:bg-primary/90",
@@ -5055,7 +5170,7 @@ function MosaicProfilePanel({
5055
5170
  ] });
5056
5171
  }
5057
5172
  MosaicProfilePanel.displayName = "MosaicProfilePanel";
5058
- function cn50(...classes) {
5173
+ function cn51(...classes) {
5059
5174
  return classes.filter(Boolean).join(" ");
5060
5175
  }
5061
5176
  var ANIM_ID7 = "mosaic-main-nav-kf";
@@ -5146,12 +5261,12 @@ function MosaicMainNav({
5146
5261
  className
5147
5262
  }) {
5148
5263
  const { isMobile } = useDevice();
5149
- const [isOpen, setIsOpen] = React28__namespace.useState(false);
5264
+ const [isOpen, setIsOpen] = React29__namespace.useState(false);
5150
5265
  const linkRenderer = renderLink ?? defaultRenderLink;
5151
- React28__namespace.useEffect(() => {
5266
+ React29__namespace.useEffect(() => {
5152
5267
  injectStyles7();
5153
5268
  }, []);
5154
- React28__namespace.useEffect(() => {
5269
+ React29__namespace.useEffect(() => {
5155
5270
  if (!isOpen) return;
5156
5271
  const handler = (e) => {
5157
5272
  if (e.key === "Escape") setIsOpen(false);
@@ -5168,7 +5283,7 @@ function MosaicMainNav({
5168
5283
  {
5169
5284
  type: "button",
5170
5285
  onClick: () => setIsOpen(!isOpen),
5171
- className: cn50(
5286
+ className: cn51(
5172
5287
  "inline-flex min-h-[44px] min-w-[44px] items-center justify-center rounded-md p-0",
5173
5288
  "text-foreground hover:bg-accent hover:text-accent-foreground",
5174
5289
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -5194,7 +5309,7 @@ function MosaicMainNav({
5194
5309
  "aria-label": drawerNavAriaLabel,
5195
5310
  open: isOpen,
5196
5311
  "data-open": isOpen ? "true" : "false",
5197
- className: cn50(
5312
+ className: cn51(
5198
5313
  "mosaic-nav-drawer",
5199
5314
  "fixed inset-y-0 left-0 z-50 m-0 w-[280px] max-h-none h-full p-0",
5200
5315
  "border-r border-border bg-background shadow-xl",
@@ -5211,7 +5326,7 @@ function MosaicMainNav({
5211
5326
  {
5212
5327
  type: "button",
5213
5328
  onClick: () => setIsOpen(false),
5214
- className: cn50(
5329
+ className: cn51(
5215
5330
  "inline-flex h-8 w-8 items-center justify-center rounded-md",
5216
5331
  "text-muted-foreground hover:bg-accent hover:text-accent-foreground",
5217
5332
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -5224,13 +5339,13 @@ function MosaicMainNav({
5224
5339
  /* @__PURE__ */ jsxRuntime.jsx("nav", { className: "flex flex-col gap-1 p-4", "aria-label": mainNavAriaLabel, children: filteredItems.map((item) => {
5225
5340
  const Icon = item.icon;
5226
5341
  const active = isItemActive(item);
5227
- const itemClass = cn50(
5342
+ const itemClass = cn51(
5228
5343
  "flex items-center gap-3 rounded-lg px-3 py-3 text-sm font-medium transition-colors",
5229
5344
  "hover:bg-accent hover:text-accent-foreground",
5230
5345
  "min-h-[44px]",
5231
5346
  active && "bg-accent text-accent-foreground"
5232
5347
  );
5233
- return /* @__PURE__ */ jsxRuntime.jsx(React28__namespace.Fragment, { children: linkRenderer(
5348
+ return /* @__PURE__ */ jsxRuntime.jsx(React29__namespace.Fragment, { children: linkRenderer(
5234
5349
  item,
5235
5350
  /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
5236
5351
  Icon && /* @__PURE__ */ jsxRuntime.jsx(Icon, { className: "h-5 w-5 shrink-0", "aria-hidden": "true" }),
@@ -5250,18 +5365,18 @@ function MosaicMainNav({
5250
5365
  "nav",
5251
5366
  {
5252
5367
  "data-slot": "main-nav",
5253
- className: cn50("flex items-center gap-1", className),
5368
+ className: cn51("flex items-center gap-1", className),
5254
5369
  "aria-label": mainNavAriaLabel,
5255
5370
  children: filteredItems.map((item) => {
5256
5371
  const Icon = item.icon;
5257
5372
  const active = isItemActive(item);
5258
- const itemClass = cn50(
5373
+ const itemClass = cn51(
5259
5374
  "flex items-center gap-2 rounded-lg px-3 py-2 text-sm font-medium transition-colors",
5260
5375
  "hover:bg-accent hover:text-accent-foreground",
5261
5376
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
5262
5377
  active && "bg-accent text-accent-foreground"
5263
5378
  );
5264
- return /* @__PURE__ */ jsxRuntime.jsx(React28__namespace.Fragment, { children: linkRenderer(
5379
+ return /* @__PURE__ */ jsxRuntime.jsx(React29__namespace.Fragment, { children: linkRenderer(
5265
5380
  item,
5266
5381
  /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
5267
5382
  Icon && /* @__PURE__ */ jsxRuntime.jsx(Icon, { className: "h-4 w-4", "aria-hidden": "true" }),
@@ -5275,7 +5390,7 @@ function MosaicMainNav({
5275
5390
  );
5276
5391
  }
5277
5392
  MosaicMainNav.displayName = "MosaicMainNav";
5278
- function cn51(...classes) {
5393
+ function cn52(...classes) {
5279
5394
  return classes.filter(Boolean).join(" ");
5280
5395
  }
5281
5396
  function MoreVertIcon() {
@@ -5398,10 +5513,10 @@ function MosaicAgentCard({
5398
5513
  createdLabel,
5399
5514
  className
5400
5515
  }) {
5401
- const [menuOpen, setMenuOpen] = React28__namespace.useState(false);
5402
- const menuRef = React28__namespace.useRef(null);
5516
+ const [menuOpen, setMenuOpen] = React29__namespace.useState(false);
5517
+ const menuRef = React29__namespace.useRef(null);
5403
5518
  const formattedDate = agent.createdAt ? new Date(agent.createdAt).toLocaleDateString() : void 0;
5404
- React28__namespace.useEffect(() => {
5519
+ React29__namespace.useEffect(() => {
5405
5520
  if (!menuOpen) return;
5406
5521
  const handler = (e) => {
5407
5522
  if (menuRef.current && !menuRef.current.contains(e.target)) {
@@ -5415,7 +5530,7 @@ function MosaicAgentCard({
5415
5530
  "div",
5416
5531
  {
5417
5532
  "data-slot": "agent-card",
5418
- className: cn51(
5533
+ className: cn52(
5419
5534
  "relative overflow-hidden rounded-lg border border-border bg-card text-card-foreground shadow-sm",
5420
5535
  "transition-shadow hover:shadow-md",
5421
5536
  agent.isActive && "ring-2 ring-primary",
@@ -5425,7 +5540,7 @@ function MosaicAgentCard({
5425
5540
  /* @__PURE__ */ jsxRuntime.jsx(
5426
5541
  "div",
5427
5542
  {
5428
- className: cn51(
5543
+ className: cn52(
5429
5544
  "absolute left-0 top-0 h-1 w-full",
5430
5545
  agent.isActive ? "bg-primary" : "bg-muted"
5431
5546
  )
@@ -5437,7 +5552,7 @@ function MosaicAgentCard({
5437
5552
  agent.accentColor && /* @__PURE__ */ jsxRuntime.jsx(
5438
5553
  "span",
5439
5554
  {
5440
- className: cn51("h-3 w-3 shrink-0 rounded-full", agent.accentColor),
5555
+ className: cn52("h-3 w-3 shrink-0 rounded-full", agent.accentColor),
5441
5556
  "aria-hidden": "true"
5442
5557
  }
5443
5558
  ),
@@ -5455,7 +5570,7 @@ function MosaicAgentCard({
5455
5570
  {
5456
5571
  type: "button",
5457
5572
  onClick: () => setMenuOpen((v) => !v),
5458
- className: cn51(
5573
+ className: cn52(
5459
5574
  "inline-flex h-8 w-8 items-center justify-center rounded-md",
5460
5575
  "text-muted-foreground hover:bg-accent hover:text-accent-foreground",
5461
5576
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -5470,7 +5585,7 @@ function MosaicAgentCard({
5470
5585
  "div",
5471
5586
  {
5472
5587
  role: "menu",
5473
- className: cn51(
5588
+ className: cn52(
5474
5589
  "absolute right-0 top-full z-50 mt-1 min-w-[140px] rounded-md border border-border",
5475
5590
  "bg-popover py-1 shadow-md"
5476
5591
  ),
@@ -5485,7 +5600,7 @@ function MosaicAgentCard({
5485
5600
  onToggleStatus(agent.id);
5486
5601
  setMenuOpen(false);
5487
5602
  },
5488
- className: cn51(
5603
+ className: cn52(
5489
5604
  "flex w-full items-center gap-2 px-3 py-2 text-sm text-foreground",
5490
5605
  "hover:bg-accent hover:text-accent-foreground",
5491
5606
  "disabled:pointer-events-none disabled:opacity-50"
@@ -5544,7 +5659,7 @@ function MosaicAgentCard({
5544
5659
  type: "button",
5545
5660
  disabled: isLoading,
5546
5661
  onClick: () => onToggleStatus(agent.id),
5547
- className: cn51(
5662
+ className: cn52(
5548
5663
  "inline-flex h-7 items-center justify-center rounded-md px-3 text-xs font-medium",
5549
5664
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
5550
5665
  "disabled:pointer-events-none disabled:opacity-50",
@@ -5560,7 +5675,7 @@ function MosaicAgentCard({
5560
5675
  );
5561
5676
  }
5562
5677
  MosaicAgentCard.displayName = "MosaicAgentCard";
5563
- function cn52(...classes) {
5678
+ function cn53(...classes) {
5564
5679
  return classes.filter(Boolean).join(" ");
5565
5680
  }
5566
5681
  function PlusIcon3() {
@@ -5643,7 +5758,7 @@ function PickerContent({
5643
5758
  {
5644
5759
  type: "button",
5645
5760
  onClick: () => onAdd(agent.id),
5646
- className: cn52(
5761
+ className: cn53(
5647
5762
  "flex w-full items-center gap-3 rounded-lg px-3 py-2.5 text-sm",
5648
5763
  "hover:bg-accent hover:text-accent-foreground",
5649
5764
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -5652,7 +5767,7 @@ function PickerContent({
5652
5767
  agent.accentColor && /* @__PURE__ */ jsxRuntime.jsx(
5653
5768
  "span",
5654
5769
  {
5655
- className: cn52("h-3 w-3 shrink-0 rounded-full", agent.accentColor),
5770
+ className: cn53("h-3 w-3 shrink-0 rounded-full", agent.accentColor),
5656
5771
  "aria-hidden": "true"
5657
5772
  }
5658
5773
  ),
@@ -5669,7 +5784,7 @@ function PickerContent({
5669
5784
  {
5670
5785
  type: "button",
5671
5786
  onClick: onOpenBuilder,
5672
- className: cn52(
5787
+ className: cn53(
5673
5788
  "flex w-full items-center gap-3 rounded-lg px-3 py-2.5 text-sm",
5674
5789
  "hover:bg-accent hover:text-accent-foreground",
5675
5790
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -5704,9 +5819,9 @@ function MosaicQuickAgentSelector({
5704
5819
  className
5705
5820
  }) {
5706
5821
  const { isMobile } = useDevice();
5707
- const [pickerOpen, setPickerOpen] = React28__namespace.useState(false);
5708
- const dropdownRef = React28__namespace.useRef(null);
5709
- React28__namespace.useEffect(() => {
5822
+ const [pickerOpen, setPickerOpen] = React29__namespace.useState(false);
5823
+ const dropdownRef = React29__namespace.useRef(null);
5824
+ React29__namespace.useEffect(() => {
5710
5825
  if (!pickerOpen || isMobile) return;
5711
5826
  const handler = (e) => {
5712
5827
  if (dropdownRef.current && !dropdownRef.current.contains(e.target)) {
@@ -5724,11 +5839,11 @@ function MosaicQuickAgentSelector({
5724
5839
  setPickerOpen(false);
5725
5840
  };
5726
5841
  const canAdd = selectedAgents.length < maxAgents;
5727
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "quick-agent-selector", className: cn52("flex items-center gap-2", className), children: [
5842
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "quick-agent-selector", className: cn53("flex items-center gap-2", className), children: [
5728
5843
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-2 overflow-x-auto", children: selectedAgents.map((agent) => /* @__PURE__ */ jsxRuntime.jsxs(
5729
5844
  "div",
5730
5845
  {
5731
- className: cn52(
5846
+ className: cn53(
5732
5847
  "group flex shrink-0 items-center gap-2 rounded-md border border-border bg-card",
5733
5848
  isMobile ? "px-2 py-1" : "px-3 py-1.5"
5734
5849
  ),
@@ -5736,17 +5851,17 @@ function MosaicQuickAgentSelector({
5736
5851
  agent.accentColor && /* @__PURE__ */ jsxRuntime.jsx(
5737
5852
  "span",
5738
5853
  {
5739
- className: cn52("h-2 w-2 shrink-0 rounded-full", agent.accentColor),
5854
+ className: cn53("h-2 w-2 shrink-0 rounded-full", agent.accentColor),
5740
5855
  "aria-hidden": "true"
5741
5856
  }
5742
5857
  ),
5743
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn52("whitespace-nowrap font-medium", isMobile ? "text-xs" : "text-sm"), children: isMobile ? agent.type.split("-")[0] : agent.name }),
5858
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn53("whitespace-nowrap font-medium", isMobile ? "text-xs" : "text-sm"), children: isMobile ? agent.type.split("-")[0] : agent.name }),
5744
5859
  /* @__PURE__ */ jsxRuntime.jsx(
5745
5860
  "button",
5746
5861
  {
5747
5862
  type: "button",
5748
5863
  onClick: () => onRemoveAgent(agent.id),
5749
- className: cn52(
5864
+ className: cn53(
5750
5865
  "inline-flex h-4 w-4 items-center justify-center rounded",
5751
5866
  "text-muted-foreground hover:text-foreground",
5752
5867
  "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",
@@ -5766,7 +5881,7 @@ function MosaicQuickAgentSelector({
5766
5881
  {
5767
5882
  type: "button",
5768
5883
  onClick: () => setPickerOpen((v) => !v),
5769
- className: cn52(
5884
+ className: cn53(
5770
5885
  "inline-flex items-center justify-center gap-2 rounded-md border border-border bg-background",
5771
5886
  "px-3 py-1.5 text-sm font-medium text-foreground",
5772
5887
  "hover:bg-accent hover:text-accent-foreground",
@@ -5781,7 +5896,7 @@ function MosaicQuickAgentSelector({
5781
5896
  !isMobile && pickerOpen && /* @__PURE__ */ jsxRuntime.jsx(
5782
5897
  "div",
5783
5898
  {
5784
- className: cn52(
5899
+ className: cn53(
5785
5900
  "absolute left-0 top-full z-50 mt-2 w-72 rounded-lg border border-border",
5786
5901
  "bg-popover shadow-lg"
5787
5902
  ),
@@ -5830,7 +5945,7 @@ function MosaicQuickAgentSelector({
5830
5945
  /* @__PURE__ */ jsxRuntime.jsxs(
5831
5946
  "span",
5832
5947
  {
5833
- className: cn52(
5948
+ className: cn53(
5834
5949
  "shrink-0 rounded-md bg-secondary px-2 py-0.5 text-xs font-medium text-secondary-foreground"
5835
5950
  ),
5836
5951
  children: [
@@ -5908,7 +6023,7 @@ var memoryActionsMenuTriggerVariants = classVarianceAuthority.cva(
5908
6023
  }
5909
6024
  }
5910
6025
  );
5911
- function cn53(...classes) {
6026
+ function cn54(...classes) {
5912
6027
  return classes.filter(Boolean).join(" ");
5913
6028
  }
5914
6029
  var MAX_VISIBLE_TAGS = 3;
@@ -6062,10 +6177,10 @@ function MosaicMemoryCard(props) {
6062
6177
  ref
6063
6178
  } = props;
6064
6179
  const variant = props.variant ?? "detailed";
6065
- const [menuOpen, setMenuOpen] = React28__namespace.useState(false);
6066
- const menuRef = React28__namespace.useRef(null);
6180
+ const [menuOpen, setMenuOpen] = React29__namespace.useState(false);
6181
+ const menuRef = React29__namespace.useRef(null);
6067
6182
  const SourceIcon = SOURCE_ICONS[memory.source];
6068
- React28__namespace.useEffect(() => {
6183
+ React29__namespace.useEffect(() => {
6069
6184
  if (!menuOpen) return;
6070
6185
  const handler = (event) => {
6071
6186
  if (menuRef.current && !menuRef.current.contains(event.target)) {
@@ -6086,7 +6201,7 @@ function MosaicMemoryCard(props) {
6086
6201
  "aria-label": moreActionsLabel,
6087
6202
  "aria-haspopup": "menu",
6088
6203
  "aria-expanded": menuOpen,
6089
- className: cn53(memoryActionsMenuTriggerVariants({ variant })),
6204
+ className: cn54(memoryActionsMenuTriggerVariants({ variant })),
6090
6205
  children: /* @__PURE__ */ jsxRuntime.jsx(MoreVertIcon2, {})
6091
6206
  }
6092
6207
  ),
@@ -6094,7 +6209,7 @@ function MosaicMemoryCard(props) {
6094
6209
  "div",
6095
6210
  {
6096
6211
  role: "menu",
6097
- className: cn53(
6212
+ className: cn54(
6098
6213
  "absolute right-0 top-full z-50 mt-1 min-w-[140px] rounded-md border border-border",
6099
6214
  "bg-popover py-1 shadow-md"
6100
6215
  ),
@@ -6135,7 +6250,7 @@ function MosaicMemoryCard(props) {
6135
6250
  ref,
6136
6251
  "data-slot": "memory-card",
6137
6252
  "data-variant": variant,
6138
- className: cn53(memoryCardVariants({ variant }), className),
6253
+ className: cn54(memoryCardVariants({ variant }), className),
6139
6254
  children: props.variant !== "compact" ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
6140
6255
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-3", children: [
6141
6256
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex min-w-0 flex-1 items-start gap-3", children: [
@@ -6145,7 +6260,7 @@ function MosaicMemoryCard(props) {
6145
6260
  /* @__PURE__ */ jsxRuntime.jsx(
6146
6261
  "span",
6147
6262
  {
6148
- className: cn53(
6263
+ className: cn54(
6149
6264
  memoryScopeBadgeVariants({ scope: memory.scope, bordered: true }),
6150
6265
  "mt-1"
6151
6266
  ),
@@ -6158,8 +6273,8 @@ function MosaicMemoryCard(props) {
6158
6273
  ] }),
6159
6274
  /* @__PURE__ */ jsxRuntime.jsx("p", { className: "line-clamp-3 text-sm text-muted-foreground", children: memory.content }),
6160
6275
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "memory-tags", className: "flex flex-wrap gap-1", children: [
6161
- visibleTags.map((tag) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn53(memoryTagBadgeVariants()), children: tag }, tag)),
6162
- hiddenTagCount > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn53(memoryTagBadgeVariants()), children: props.formatMoreTags(hiddenTagCount) })
6276
+ visibleTags.map((tag) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn54(memoryTagBadgeVariants()), children: tag }, tag)),
6277
+ hiddenTagCount > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn54(memoryTagBadgeVariants()), children: props.formatMoreTags(hiddenTagCount) })
6163
6278
  ] }),
6164
6279
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between border-t pt-2 text-xs text-muted-foreground", children: [
6165
6280
  /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "flex items-center gap-1", children: [
@@ -6187,7 +6302,7 @@ function MosaicMemoryCard(props) {
6187
6302
  /* @__PURE__ */ jsxRuntime.jsx(
6188
6303
  "span",
6189
6304
  {
6190
- className: cn53(memoryScopeBadgeVariants({ scope: memory.scope, bordered: false })),
6305
+ className: cn54(memoryScopeBadgeVariants({ scope: memory.scope, bordered: false })),
6191
6306
  children: formatScope(memory.scope)
6192
6307
  }
6193
6308
  ),
@@ -6206,7 +6321,169 @@ function MosaicMemoryCard(props) {
6206
6321
  );
6207
6322
  }
6208
6323
  MosaicMemoryCard.displayName = "MosaicMemoryCard";
6209
- function cn54(...classes) {
6324
+ var templateAgentCardVariants = classVarianceAuthority.cva(
6325
+ [
6326
+ "rounded-lg border border-border bg-card text-card-foreground shadow-sm",
6327
+ "transition-all hover:border-primary/50"
6328
+ ],
6329
+ {
6330
+ variants: {
6331
+ selected: {
6332
+ true: "ring-2 ring-primary border-primary bg-primary/5",
6333
+ false: ""
6334
+ }
6335
+ },
6336
+ defaultVariants: {
6337
+ selected: false
6338
+ }
6339
+ }
6340
+ );
6341
+ var templateAgentCardBadgeVariants = classVarianceAuthority.cva([
6342
+ "inline-flex items-center rounded-md border border-border px-2 py-0.5 text-xs font-medium"
6343
+ ]);
6344
+ var templateAgentCardTagVariants = classVarianceAuthority.cva([
6345
+ "inline-flex items-center rounded-full border border-border bg-muted px-2 py-0.5 text-xs text-muted-foreground"
6346
+ ]);
6347
+ function cn55(...classes) {
6348
+ return classes.filter(Boolean).join(" ");
6349
+ }
6350
+ var MAX_VISIBLE_TAGS2 = 3;
6351
+ function EyeIcon() {
6352
+ return /* @__PURE__ */ jsxRuntime.jsxs(
6353
+ "svg",
6354
+ {
6355
+ xmlns: "http://www.w3.org/2000/svg",
6356
+ width: "14",
6357
+ height: "14",
6358
+ viewBox: "0 0 24 24",
6359
+ fill: "none",
6360
+ stroke: "currentColor",
6361
+ strokeWidth: "2",
6362
+ strokeLinecap: "round",
6363
+ strokeLinejoin: "round",
6364
+ "aria-hidden": "true",
6365
+ children: [
6366
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z" }),
6367
+ /* @__PURE__ */ jsxRuntime.jsx("circle", { cx: "12", cy: "12", r: "3" })
6368
+ ]
6369
+ }
6370
+ );
6371
+ }
6372
+ function CopyIcon() {
6373
+ return /* @__PURE__ */ jsxRuntime.jsxs(
6374
+ "svg",
6375
+ {
6376
+ xmlns: "http://www.w3.org/2000/svg",
6377
+ width: "14",
6378
+ height: "14",
6379
+ viewBox: "0 0 24 24",
6380
+ fill: "none",
6381
+ stroke: "currentColor",
6382
+ strokeWidth: "2",
6383
+ strokeLinecap: "round",
6384
+ strokeLinejoin: "round",
6385
+ "aria-hidden": "true",
6386
+ children: [
6387
+ /* @__PURE__ */ jsxRuntime.jsx("rect", { x: "9", y: "9", width: "13", height: "13", rx: "2", ry: "2" }),
6388
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1" })
6389
+ ]
6390
+ }
6391
+ );
6392
+ }
6393
+ function MosaicTemplateAgentCard({
6394
+ template,
6395
+ isSelected = false,
6396
+ onSelect,
6397
+ onPreview,
6398
+ onDuplicate,
6399
+ icon,
6400
+ selectAriaLabel,
6401
+ agentCountLabel,
6402
+ formatUsageCount,
6403
+ formatMoreTags,
6404
+ previewAriaLabel,
6405
+ duplicateAriaLabel,
6406
+ className,
6407
+ ref
6408
+ }) {
6409
+ const visibleTags = template.tags?.slice(0, MAX_VISIBLE_TAGS2) ?? [];
6410
+ const hiddenTagCount = (template.tags?.length ?? 0) - visibleTags.length;
6411
+ return /* @__PURE__ */ jsxRuntime.jsxs(
6412
+ "div",
6413
+ {
6414
+ ref,
6415
+ "data-slot": "template-agent-card",
6416
+ className: cn55(templateAgentCardVariants({ selected: isSelected }), "p-4", className),
6417
+ children: [
6418
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-start justify-between gap-2", children: /* @__PURE__ */ jsxRuntime.jsxs(
6419
+ "button",
6420
+ {
6421
+ type: "button",
6422
+ onClick: () => onSelect(template),
6423
+ "aria-label": selectAriaLabel,
6424
+ "aria-pressed": isSelected,
6425
+ className: cn55(
6426
+ "flex min-w-0 flex-1 items-start gap-2 rounded-md text-left",
6427
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
6428
+ ),
6429
+ children: [
6430
+ icon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-0.5 shrink-0 text-primary", "aria-hidden": "true", children: icon }),
6431
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "min-w-0", children: [
6432
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "block truncate text-sm font-semibold leading-tight", children: template.name }),
6433
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-1 block line-clamp-2 text-xs text-muted-foreground", children: template.description })
6434
+ ] })
6435
+ ]
6436
+ }
6437
+ ) }),
6438
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-3 flex flex-wrap items-center gap-2", children: [
6439
+ template.category && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn55(templateAgentCardBadgeVariants()), children: template.category }),
6440
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn55(templateAgentCardBadgeVariants()), children: agentCountLabel }),
6441
+ formatUsageCount(template.usageCount) != null && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn55(templateAgentCardBadgeVariants()), children: formatUsageCount(template.usageCount) }),
6442
+ visibleTags.map((tag) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn55(templateAgentCardTagVariants()), children: tag }, tag)),
6443
+ hiddenTagCount > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn55(templateAgentCardTagVariants()), children: formatMoreTags(hiddenTagCount) })
6444
+ ] }),
6445
+ (onPreview || onDuplicate) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-3 flex items-center gap-2 border-t border-border pt-2", children: [
6446
+ onPreview && /* @__PURE__ */ jsxRuntime.jsxs(
6447
+ "button",
6448
+ {
6449
+ type: "button",
6450
+ onClick: () => onPreview(template),
6451
+ "aria-label": previewAriaLabel,
6452
+ className: cn55(
6453
+ "inline-flex h-8 flex-1 items-center justify-center gap-1.5 rounded-md text-xs font-medium",
6454
+ "text-muted-foreground hover:bg-accent hover:text-accent-foreground",
6455
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
6456
+ ),
6457
+ children: [
6458
+ /* @__PURE__ */ jsxRuntime.jsx(EyeIcon, {}),
6459
+ previewAriaLabel
6460
+ ]
6461
+ }
6462
+ ),
6463
+ onDuplicate && /* @__PURE__ */ jsxRuntime.jsxs(
6464
+ "button",
6465
+ {
6466
+ type: "button",
6467
+ onClick: () => onDuplicate(template),
6468
+ "aria-label": duplicateAriaLabel,
6469
+ className: cn55(
6470
+ "inline-flex h-8 flex-1 items-center justify-center gap-1.5 rounded-md text-xs font-medium",
6471
+ "text-muted-foreground hover:bg-accent hover:text-accent-foreground",
6472
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
6473
+ ),
6474
+ children: [
6475
+ /* @__PURE__ */ jsxRuntime.jsx(CopyIcon, {}),
6476
+ duplicateAriaLabel
6477
+ ]
6478
+ }
6479
+ )
6480
+ ] })
6481
+ ]
6482
+ }
6483
+ );
6484
+ }
6485
+ MosaicTemplateAgentCard.displayName = "MosaicTemplateAgentCard";
6486
+ function cn56(...classes) {
6210
6487
  return classes.filter(Boolean).join(" ");
6211
6488
  }
6212
6489
  function SearchIcon() {
@@ -6266,10 +6543,10 @@ function MosaicSelectorModal({
6266
6543
  emptyMessage,
6267
6544
  closeAriaLabel
6268
6545
  }) {
6269
- const [query, setQuery] = React28__namespace.useState("");
6270
- const [activeCategory, setActiveCategory] = React28__namespace.useState("all");
6271
- const [pendingId, setPendingId] = React28__namespace.useState(selectedId);
6272
- React28__namespace.useEffect(() => {
6546
+ const [query, setQuery] = React29__namespace.useState("");
6547
+ const [activeCategory, setActiveCategory] = React29__namespace.useState("all");
6548
+ const [pendingId, setPendingId] = React29__namespace.useState(selectedId);
6549
+ React29__namespace.useEffect(() => {
6273
6550
  if (isOpen) {
6274
6551
  setPendingId(selectedId);
6275
6552
  setQuery("");
@@ -6307,7 +6584,7 @@ function MosaicSelectorModal({
6307
6584
  value: query,
6308
6585
  onChange: (e) => setQuery(e.target.value),
6309
6586
  placeholder: searchPlaceholder,
6310
- className: cn54(
6587
+ className: cn56(
6311
6588
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
6312
6589
  "text-sm text-foreground placeholder:text-muted-foreground",
6313
6590
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -6321,7 +6598,7 @@ function MosaicSelectorModal({
6321
6598
  {
6322
6599
  type: "button",
6323
6600
  onClick: () => setActiveCategory("all"),
6324
- className: cn54(
6601
+ className: cn56(
6325
6602
  "shrink-0 rounded-md px-3 py-1.5 text-sm font-medium transition-colors",
6326
6603
  activeCategory === "all" ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground hover:bg-accent hover:text-accent-foreground"
6327
6604
  ),
@@ -6333,7 +6610,7 @@ function MosaicSelectorModal({
6333
6610
  {
6334
6611
  type: "button",
6335
6612
  onClick: () => setActiveCategory(cat.id),
6336
- className: cn54(
6613
+ className: cn56(
6337
6614
  "shrink-0 rounded-md px-3 py-1.5 text-sm font-medium transition-colors",
6338
6615
  activeCategory === cat.id ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground hover:bg-accent hover:text-accent-foreground"
6339
6616
  ),
@@ -6345,7 +6622,7 @@ function MosaicSelectorModal({
6345
6622
  /* @__PURE__ */ jsxRuntime.jsxs(
6346
6623
  "div",
6347
6624
  {
6348
- className: cn54(
6625
+ className: cn56(
6349
6626
  "max-h-[50vh] overflow-y-auto",
6350
6627
  columns === 2 ? "grid grid-cols-1 gap-3 sm:grid-cols-2" : "flex flex-col gap-3"
6351
6628
  ),
@@ -6357,7 +6634,7 @@ function MosaicSelectorModal({
6357
6634
  {
6358
6635
  type: "button",
6359
6636
  onClick: () => setPendingId(item.id),
6360
- className: cn54(
6637
+ className: cn56(
6361
6638
  "group relative rounded-lg border p-4 text-left transition-all duration-150",
6362
6639
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
6363
6640
  isSelected ? "border-primary bg-primary/5 ring-2 ring-primary" : "border-border bg-card hover:border-primary/50"
@@ -6395,7 +6672,7 @@ function MosaicSelectorModal({
6395
6672
  {
6396
6673
  type: "button",
6397
6674
  onClick: onClose,
6398
- className: cn54(
6675
+ className: cn56(
6399
6676
  "inline-flex min-h-[44px] items-center justify-center rounded-md border border-border",
6400
6677
  "bg-background px-4 py-2 text-sm font-medium text-foreground",
6401
6678
  "hover:bg-accent hover:text-accent-foreground",
@@ -6410,7 +6687,7 @@ function MosaicSelectorModal({
6410
6687
  type: "button",
6411
6688
  onClick: handleConfirm,
6412
6689
  disabled: !pendingItem,
6413
- className: cn54(
6690
+ className: cn56(
6414
6691
  "inline-flex min-h-[44px] items-center justify-center rounded-md",
6415
6692
  "bg-primary px-4 py-2 text-sm font-medium text-primary-foreground",
6416
6693
  "hover:bg-primary/90",
@@ -6426,7 +6703,7 @@ function MosaicSelectorModal({
6426
6703
  );
6427
6704
  }
6428
6705
  MosaicSelectorModal.displayName = "MosaicSelectorModal";
6429
- function cn55(...classes) {
6706
+ function cn57(...classes) {
6430
6707
  return classes.filter(Boolean).join(" ");
6431
6708
  }
6432
6709
  function relativeTime(ts) {
@@ -6626,13 +6903,13 @@ function MosaicMessageCard({
6626
6903
  copyMessageLabel,
6627
6904
  className
6628
6905
  }) {
6629
- const [bookmarked, setBookmarked] = React28__namespace.useState(message.bookmarked ?? false);
6630
- const [likes, setLikes] = React28__namespace.useState(message.reactions?.likes ?? 0);
6631
- const [dislikes, setDislikes] = React28__namespace.useState(message.reactions?.dislikes ?? 0);
6632
- const [hasLiked, setHasLiked] = React28__namespace.useState(false);
6633
- const [hasDisliked, setHasDisliked] = React28__namespace.useState(false);
6634
- const [menuOpen, setMenuOpen] = React28__namespace.useState(false);
6635
- const menuRef = React28__namespace.useRef(null);
6906
+ const [bookmarked, setBookmarked] = React29__namespace.useState(message.bookmarked ?? false);
6907
+ const [likes, setLikes] = React29__namespace.useState(message.reactions?.likes ?? 0);
6908
+ const [dislikes, setDislikes] = React29__namespace.useState(message.reactions?.dislikes ?? 0);
6909
+ const [hasLiked, setHasLiked] = React29__namespace.useState(false);
6910
+ const [hasDisliked, setHasDisliked] = React29__namespace.useState(false);
6911
+ const [menuOpen, setMenuOpen] = React29__namespace.useState(false);
6912
+ const menuRef = React29__namespace.useRef(null);
6636
6913
  const initials = message.sender.name.split(" ").map((n) => n[0]).filter(Boolean).slice(0, 2).join("").toUpperCase();
6637
6914
  const handleLike = () => {
6638
6915
  if (hasLiked) {
@@ -6670,7 +6947,7 @@ function MosaicMessageCard({
6670
6947
  navigator.clipboard.writeText(message.content).catch(() => null);
6671
6948
  onCopy?.(message.id, message.content);
6672
6949
  };
6673
- React28__namespace.useEffect(() => {
6950
+ React29__namespace.useEffect(() => {
6674
6951
  if (!menuOpen) return;
6675
6952
  const h = (e) => {
6676
6953
  if (menuRef.current && !menuRef.current.contains(e.target)) setMenuOpen(false);
@@ -6682,7 +6959,7 @@ function MosaicMessageCard({
6682
6959
  "div",
6683
6960
  {
6684
6961
  "data-slot": "message-card",
6685
- className: cn55(
6962
+ className: cn57(
6686
6963
  "rounded-lg border border-border bg-card p-4 shadow-sm transition-shadow hover:shadow-md",
6687
6964
  compact && "p-3",
6688
6965
  message.sender.type === "user" && "bg-primary/5",
@@ -6692,7 +6969,7 @@ function MosaicMessageCard({
6692
6969
  /* @__PURE__ */ jsxRuntime.jsx(
6693
6970
  "span",
6694
6971
  {
6695
- className: cn55(
6972
+ className: cn57(
6696
6973
  "inline-flex shrink-0 items-center justify-center rounded-full text-white font-semibold",
6697
6974
  compact ? "h-8 w-8 text-xs" : "h-10 w-10 text-sm",
6698
6975
  message.sender.accentColor ?? "bg-muted text-muted-foreground"
@@ -6710,7 +6987,7 @@ function MosaicMessageCard({
6710
6987
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
6711
6988
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-2 flex items-center justify-between gap-2", children: [
6712
6989
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
6713
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn55("font-medium", compact ? "text-sm" : "text-base"), children: message.sender.name }),
6990
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn57("font-medium", compact ? "text-sm" : "text-base"), children: message.sender.name }),
6714
6991
  message.sender.type === "ai" && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "rounded-full bg-secondary px-2 py-0.5 text-xs font-medium text-secondary-foreground", children: "AI" })
6715
6992
  ] }),
6716
6993
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0 text-xs text-muted-foreground", children: relativeTime(message.timestamp) })
@@ -6718,7 +6995,7 @@ function MosaicMessageCard({
6718
6995
  /* @__PURE__ */ jsxRuntime.jsx(
6719
6996
  "p",
6720
6997
  {
6721
- className: cn55(
6998
+ className: cn57(
6722
6999
  "leading-relaxed text-foreground mb-3",
6723
7000
  compact ? "text-sm" : "text-base"
6724
7001
  ),
@@ -6733,7 +7010,7 @@ function MosaicMessageCard({
6733
7010
  {
6734
7011
  type: "button",
6735
7012
  onClick: handleLike,
6736
- className: cn55(
7013
+ className: cn57(
6737
7014
  "inline-flex h-8 items-center gap-1 rounded-md px-2 text-xs",
6738
7015
  "hover:bg-accent hover:text-accent-foreground",
6739
7016
  "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",
@@ -6751,7 +7028,7 @@ function MosaicMessageCard({
6751
7028
  {
6752
7029
  type: "button",
6753
7030
  onClick: handleDislike,
6754
- className: cn55(
7031
+ className: cn57(
6755
7032
  "inline-flex h-8 items-center gap-1 rounded-md px-2 text-xs",
6756
7033
  "hover:bg-accent hover:text-accent-foreground",
6757
7034
  "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",
@@ -6796,7 +7073,7 @@ function MosaicMessageCard({
6796
7073
  {
6797
7074
  type: "button",
6798
7075
  onClick: handleBookmark,
6799
- className: cn55(
7076
+ className: cn57(
6800
7077
  "inline-flex h-8 w-8 items-center justify-center rounded-md",
6801
7078
  "hover:bg-accent hover:text-accent-foreground",
6802
7079
  "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",
@@ -6897,7 +7174,7 @@ function MosaicMessageCard({
6897
7174
  );
6898
7175
  }
6899
7176
  MosaicMessageCard.displayName = "MosaicMessageCard";
6900
- function cn56(...classes) {
7177
+ function cn58(...classes) {
6901
7178
  return classes.filter(Boolean).join(" ");
6902
7179
  }
6903
7180
  function SearchIcon2() {
@@ -6943,11 +7220,11 @@ function MessageListDesktop({
6943
7220
  copyMessageLabel,
6944
7221
  className
6945
7222
  }) {
6946
- const [query, setQuery] = React28__namespace.useState("");
7223
+ const [query, setQuery] = React29__namespace.useState("");
6947
7224
  const filtered = query ? messages.filter(
6948
7225
  (m) => m.content.toLowerCase().includes(query.toLowerCase()) || m.sender.name.toLowerCase().includes(query.toLowerCase())
6949
7226
  ) : messages;
6950
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "message-list-desktop", className: cn56("flex h-full flex-col", className), children: [
7227
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "message-list-desktop", className: cn58("flex h-full flex-col", className), children: [
6951
7228
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between border-b border-border px-6 py-4", children: [
6952
7229
  title && /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-lg font-semibold", children: title }),
6953
7230
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative ml-auto max-w-xs flex-1", children: [
@@ -6959,7 +7236,7 @@ function MessageListDesktop({
6959
7236
  value: query,
6960
7237
  onChange: (e) => setQuery(e.target.value),
6961
7238
  placeholder: searchPlaceholder,
6962
- className: cn56(
7239
+ className: cn58(
6963
7240
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
6964
7241
  "text-sm placeholder:text-muted-foreground",
6965
7242
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -6995,7 +7272,7 @@ function MessageListDesktop({
6995
7272
  {
6996
7273
  type: "button",
6997
7274
  onClick: onLoadMore,
6998
- className: cn56(
7275
+ className: cn58(
6999
7276
  "w-full rounded-md border border-border bg-background px-4 py-2 text-sm font-medium",
7000
7277
  "hover:bg-accent hover:text-accent-foreground",
7001
7278
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -7026,7 +7303,7 @@ function MessageListMobile({
7026
7303
  copyMessageLabel,
7027
7304
  className
7028
7305
  }) {
7029
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "message-list-mobile", className: cn56("flex flex-col", className), children: [
7306
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "message-list-mobile", className: cn58("flex flex-col", className), children: [
7030
7307
  title && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "sticky top-0 z-10 border-b border-border bg-background px-4 py-3", children: /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-base font-semibold", children: title }) }),
7031
7308
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3 p-4", children: [
7032
7309
  isLoading && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-3", children: [0, 1, 2].map((i) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "h-20 animate-pulse rounded-lg bg-muted" }, i)) }),
@@ -7056,7 +7333,7 @@ function MessageListMobile({
7056
7333
  {
7057
7334
  type: "button",
7058
7335
  onClick: onLoadMore,
7059
- className: cn56(
7336
+ className: cn58(
7060
7337
  "w-full min-h-[44px] rounded-md border border-border bg-background px-4 py-2 text-sm font-medium",
7061
7338
  "hover:bg-accent hover:text-accent-foreground",
7062
7339
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -7071,7 +7348,7 @@ function MosaicMessageList(props) {
7071
7348
  return isMobile ? /* @__PURE__ */ jsxRuntime.jsx(MessageListMobile, { ...props }) : /* @__PURE__ */ jsxRuntime.jsx(MessageListDesktop, { ...props });
7072
7349
  }
7073
7350
  MosaicMessageList.displayName = "MosaicMessageList";
7074
- function cn57(...classes) {
7351
+ function cn59(...classes) {
7075
7352
  return classes.filter(Boolean).join(" ");
7076
7353
  }
7077
7354
  function ChevronLeftIcon2() {
@@ -7151,7 +7428,7 @@ function MosaicFilterSidebar({
7151
7428
  {
7152
7429
  "data-slot": "filter-sidebar",
7153
7430
  style: { width, minWidth: isCollapsed && !isMobile ? "64px" : void 0 },
7154
- className: cn57(
7431
+ className: cn59(
7155
7432
  "relative flex flex-col border-r border-border bg-card",
7156
7433
  "transition-[width] duration-200 ease-in-out",
7157
7434
  "overflow-hidden",
@@ -7163,7 +7440,7 @@ function MosaicFilterSidebar({
7163
7440
  {
7164
7441
  type: "button",
7165
7442
  onClick: onToggleCollapse,
7166
- className: cn57(
7443
+ className: cn59(
7167
7444
  "absolute -right-3 top-6 z-10 flex h-6 w-6 items-center justify-center rounded-full",
7168
7445
  "border border-border bg-background shadow-sm",
7169
7446
  "hover:bg-accent hover:text-accent-foreground",
@@ -7193,7 +7470,7 @@ function MosaicFilterSidebar({
7193
7470
  {
7194
7471
  type: "button",
7195
7472
  onClick: () => onFilterChange(f.id),
7196
- className: cn57(
7473
+ className: cn59(
7197
7474
  "flex min-h-[40px] items-center justify-between rounded-md px-3 py-2 text-sm font-medium",
7198
7475
  "transition-colors hover:bg-accent hover:text-accent-foreground",
7199
7476
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -7213,7 +7490,7 @@ function MosaicFilterSidebar({
7213
7490
  {
7214
7491
  type: "button",
7215
7492
  onClick: () => onCategoryChange(cat.id),
7216
- className: cn57(
7493
+ className: cn59(
7217
7494
  "flex min-h-[36px] items-center justify-between rounded-md px-3 py-1.5 text-sm",
7218
7495
  "transition-colors hover:bg-accent hover:text-accent-foreground",
7219
7496
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -7233,7 +7510,7 @@ function MosaicFilterSidebar({
7233
7510
  );
7234
7511
  }
7235
7512
  MosaicFilterSidebar.displayName = "MosaicFilterSidebar";
7236
- function cn58(...classes) {
7513
+ function cn60(...classes) {
7237
7514
  return classes.filter(Boolean).join(" ");
7238
7515
  }
7239
7516
  function SearchIcon3() {
@@ -7319,8 +7596,8 @@ function AgentListDesktop({
7319
7596
  collapseSidebarAriaLabel,
7320
7597
  expandSidebarAriaLabel
7321
7598
  }) {
7322
- const [query, setQuery] = React28__namespace.useState("");
7323
- const [sidebarCollapsed, setSidebarCollapsed] = React28__namespace.useState(false);
7599
+ const [query, setQuery] = React29__namespace.useState("");
7600
+ const [sidebarCollapsed, setSidebarCollapsed] = React29__namespace.useState(false);
7324
7601
  const filtered = agents.filter(
7325
7602
  (a) => !query || a.name.toLowerCase().includes(query.toLowerCase()) || a.description?.toLowerCase().includes(query.toLowerCase())
7326
7603
  );
@@ -7358,7 +7635,7 @@ function AgentListDesktop({
7358
7635
  value: query,
7359
7636
  onChange: (e) => setQuery(e.target.value),
7360
7637
  placeholder: searchPlaceholder,
7361
- className: cn58(
7638
+ className: cn60(
7362
7639
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
7363
7640
  "text-sm placeholder:text-muted-foreground",
7364
7641
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -7371,7 +7648,7 @@ function AgentListDesktop({
7371
7648
  {
7372
7649
  type: "button",
7373
7650
  onClick: onCreateAgent,
7374
- className: cn58(
7651
+ className: cn60(
7375
7652
  "inline-flex items-center gap-2 rounded-md bg-primary px-4 py-2 text-sm font-medium text-primary-foreground",
7376
7653
  "hover:bg-primary/90 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
7377
7654
  ),
@@ -7425,8 +7702,8 @@ function AgentListMobile({
7425
7702
  collapseSidebarAriaLabel,
7426
7703
  expandSidebarAriaLabel
7427
7704
  }) {
7428
- const [filterOpen, setFilterOpen] = React28__namespace.useState(false);
7429
- const [query, setQuery] = React28__namespace.useState("");
7705
+ const [filterOpen, setFilterOpen] = React29__namespace.useState(false);
7706
+ const [query, setQuery] = React29__namespace.useState("");
7430
7707
  const filtered = agents.filter(
7431
7708
  (a) => !query || a.name.toLowerCase().includes(query.toLowerCase()) || a.description?.toLowerCase().includes(query.toLowerCase())
7432
7709
  );
@@ -7440,7 +7717,7 @@ function AgentListMobile({
7440
7717
  {
7441
7718
  type: "button",
7442
7719
  onClick: () => setFilterOpen(true),
7443
- className: cn58(
7720
+ className: cn60(
7444
7721
  "inline-flex h-9 w-9 items-center justify-center rounded-md",
7445
7722
  "border border-border bg-background text-foreground",
7446
7723
  "hover:bg-accent hover:text-accent-foreground",
@@ -7455,7 +7732,7 @@ function AgentListMobile({
7455
7732
  {
7456
7733
  type: "button",
7457
7734
  onClick: onCreateAgent,
7458
- className: cn58(
7735
+ className: cn60(
7459
7736
  "inline-flex h-9 items-center gap-1.5 rounded-md bg-primary px-3 text-sm font-medium text-primary-foreground",
7460
7737
  "hover:bg-primary/90 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
7461
7738
  ),
@@ -7476,7 +7753,7 @@ function AgentListMobile({
7476
7753
  value: query,
7477
7754
  onChange: (e) => setQuery(e.target.value),
7478
7755
  placeholder: searchPlaceholder,
7479
- className: cn58(
7756
+ className: cn60(
7480
7757
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
7481
7758
  "text-sm placeholder:text-muted-foreground",
7482
7759
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -7538,7 +7815,7 @@ function MosaicAgentList(props) {
7538
7815
  return isMobile ? /* @__PURE__ */ jsxRuntime.jsx(AgentListMobile, { ...props }) : /* @__PURE__ */ jsxRuntime.jsx(AgentListDesktop, { ...props });
7539
7816
  }
7540
7817
  MosaicAgentList.displayName = "MosaicAgentList";
7541
- function cn59(...classes) {
7818
+ function cn61(...classes) {
7542
7819
  return classes.filter(Boolean).join(" ");
7543
7820
  }
7544
7821
  function StarIcon({ filled }) {
@@ -7635,7 +7912,7 @@ function MarketplaceCard({
7635
7912
  "div",
7636
7913
  {
7637
7914
  "data-slot": "marketplace-card",
7638
- className: cn59(
7915
+ className: cn61(
7639
7916
  "rounded-lg border border-border bg-card p-4 transition-shadow hover:shadow-md",
7640
7917
  compact ? "flex items-center gap-3" : "flex flex-col gap-3"
7641
7918
  ),
@@ -7643,7 +7920,7 @@ function MarketplaceCard({
7643
7920
  item.icon && /* @__PURE__ */ jsxRuntime.jsx(
7644
7921
  "div",
7645
7922
  {
7646
- className: cn59(
7923
+ className: cn61(
7647
7924
  "flex shrink-0 items-center justify-center rounded-lg",
7648
7925
  compact ? "h-10 w-10" : "h-12 w-12",
7649
7926
  item.accentClass ?? "bg-muted text-muted-foreground"
@@ -7654,7 +7931,7 @@ function MarketplaceCard({
7654
7931
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 min-w-0", children: [
7655
7932
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-2", children: [
7656
7933
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0", children: [
7657
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn59("font-semibold leading-tight", compact ? "text-sm" : "text-base"), children: item.title }),
7934
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: cn61("font-semibold leading-tight", compact ? "text-sm" : "text-base"), children: item.title }),
7658
7935
  item.description && !compact && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "mt-1 text-sm text-muted-foreground line-clamp-2", children: item.description })
7659
7936
  ] }),
7660
7937
  item.price && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "shrink-0 rounded-full bg-muted px-2 py-0.5 text-xs font-medium text-muted-foreground", children: item.price })
@@ -7671,13 +7948,13 @@ function MarketplaceCard({
7671
7948
  ] })
7672
7949
  ] })
7673
7950
  ] }),
7674
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn59("flex gap-2", compact ? "shrink-0" : "mt-1"), children: [
7951
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn61("flex gap-2", compact ? "shrink-0" : "mt-1"), children: [
7675
7952
  onPreview && /* @__PURE__ */ jsxRuntime.jsx(
7676
7953
  "button",
7677
7954
  {
7678
7955
  type: "button",
7679
7956
  onClick: () => onPreview(item.id),
7680
- className: cn59(
7957
+ className: cn61(
7681
7958
  "inline-flex min-h-[36px] items-center justify-center rounded-md border border-border",
7682
7959
  "bg-background px-3 text-xs font-medium text-foreground",
7683
7960
  "hover:bg-accent hover:text-accent-foreground",
@@ -7691,7 +7968,7 @@ function MarketplaceCard({
7691
7968
  {
7692
7969
  type: "button",
7693
7970
  onClick: () => onUninstall(item.id),
7694
- className: cn59(
7971
+ className: cn61(
7695
7972
  "inline-flex min-h-[36px] items-center justify-center rounded-md",
7696
7973
  "bg-secondary px-3 text-xs font-medium text-secondary-foreground",
7697
7974
  "hover:bg-secondary/80",
@@ -7704,7 +7981,7 @@ function MarketplaceCard({
7704
7981
  {
7705
7982
  type: "button",
7706
7983
  onClick: () => onInstall(item.id),
7707
- className: cn59(
7984
+ className: cn61(
7708
7985
  "inline-flex min-h-[36px] items-center justify-center rounded-md",
7709
7986
  "bg-primary px-3 text-xs font-medium text-primary-foreground",
7710
7987
  "hover:bg-primary/90",
@@ -7741,8 +8018,8 @@ function MarketplaceListDesktop(props) {
7741
8018
  collapseSidebarAriaLabel,
7742
8019
  expandSidebarAriaLabel
7743
8020
  } = props;
7744
- const [query, setQuery] = React28__namespace.useState("");
7745
- const [sidebarCollapsed, setSidebarCollapsed] = React28__namespace.useState(false);
8021
+ const [query, setQuery] = React29__namespace.useState("");
8022
+ const [sidebarCollapsed, setSidebarCollapsed] = React29__namespace.useState(false);
7746
8023
  const filtered = items.filter(
7747
8024
  (i) => !query || i.title.toLowerCase().includes(query.toLowerCase()) || (i.description ?? "").toLowerCase().includes(query.toLowerCase())
7748
8025
  );
@@ -7776,7 +8053,7 @@ function MarketplaceListDesktop(props) {
7776
8053
  value: query,
7777
8054
  onChange: (e) => setQuery(e.target.value),
7778
8055
  placeholder: searchPlaceholder,
7779
- className: cn59(
8056
+ className: cn61(
7780
8057
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
7781
8058
  "text-sm placeholder:text-muted-foreground",
7782
8059
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -7830,8 +8107,8 @@ function MarketplaceListMobile(props) {
7830
8107
  collapseSidebarAriaLabel,
7831
8108
  expandSidebarAriaLabel
7832
8109
  } = props;
7833
- const [filterOpen, setFilterOpen] = React28__namespace.useState(false);
7834
- const [query, setQuery] = React28__namespace.useState("");
8110
+ const [filterOpen, setFilterOpen] = React29__namespace.useState(false);
8111
+ const [query, setQuery] = React29__namespace.useState("");
7835
8112
  const filtered = items.filter(
7836
8113
  (i) => !query || i.title.toLowerCase().includes(query.toLowerCase()) || (i.description ?? "").toLowerCase().includes(query.toLowerCase())
7837
8114
  );
@@ -7859,7 +8136,7 @@ function MarketplaceListMobile(props) {
7859
8136
  value: query,
7860
8137
  onChange: (e) => setQuery(e.target.value),
7861
8138
  placeholder: searchPlaceholder,
7862
- className: cn59(
8139
+ className: cn61(
7863
8140
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
7864
8141
  "text-sm placeholder:text-muted-foreground",
7865
8142
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -7924,7 +8201,7 @@ function MosaicMarketplaceList(props) {
7924
8201
  return isMobile ? /* @__PURE__ */ jsxRuntime.jsx(MarketplaceListMobile, { ...props }) : /* @__PURE__ */ jsxRuntime.jsx(MarketplaceListDesktop, { ...props });
7925
8202
  }
7926
8203
  MosaicMarketplaceList.displayName = "MosaicMarketplaceList";
7927
- function cn60(...classes) {
8204
+ function cn62(...classes) {
7928
8205
  return classes.filter(Boolean).join(" ");
7929
8206
  }
7930
8207
  function StarIcon2() {
@@ -8045,7 +8322,7 @@ function MosaicTemplateCard({
8045
8322
  type: "button",
8046
8323
  onClick: () => onSelect(template),
8047
8324
  "data-slot": "template-card",
8048
- className: cn60(
8325
+ className: cn62(
8049
8326
  "w-full text-left rounded-lg border transition-all duration-200",
8050
8327
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
8051
8328
  isSelected ? "border-primary bg-primary/5 ring-2 ring-primary" : "border-border bg-card hover:border-primary/50",
@@ -8146,7 +8423,7 @@ function MosaicTemplatePreview({
8146
8423
  agent.accentColor && /* @__PURE__ */ jsxRuntime.jsx(
8147
8424
  "span",
8148
8425
  {
8149
- className: cn60("h-2 w-2 rounded-full", agent.accentColor),
8426
+ className: cn62("h-2 w-2 rounded-full", agent.accentColor),
8150
8427
  "aria-hidden": "true"
8151
8428
  }
8152
8429
  ),
@@ -8206,7 +8483,7 @@ function MosaicAgentTeamPreview({ agents, label }) {
8206
8483
  agent.accentColor && /* @__PURE__ */ jsxRuntime.jsx(
8207
8484
  "span",
8208
8485
  {
8209
- className: cn60("h-2.5 w-2.5 rounded-full", agent.accentColor),
8486
+ className: cn62("h-2.5 w-2.5 rounded-full", agent.accentColor),
8210
8487
  "aria-hidden": "true"
8211
8488
  }
8212
8489
  ),
@@ -8230,7 +8507,7 @@ function MosaicQuickStartPanel({
8230
8507
  scratchLabel,
8231
8508
  className
8232
8509
  }) {
8233
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "quick-start-panel", className: cn60("flex flex-col gap-6", className), children: [
8510
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "quick-start-panel", className: cn62("flex flex-col gap-6", className), children: [
8234
8511
  scenarios.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
8235
8512
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: "mb-3 text-sm font-semibold text-foreground", children: scenariosTitle }),
8236
8513
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid gap-3 sm:grid-cols-2", children: scenarios.map((scenario) => /* @__PURE__ */ jsxRuntime.jsxs(
@@ -8238,7 +8515,7 @@ function MosaicQuickStartPanel({
8238
8515
  {
8239
8516
  type: "button",
8240
8517
  onClick: () => onSelectScenario(scenario),
8241
- className: cn60(
8518
+ className: cn62(
8242
8519
  "flex items-start gap-3 rounded-lg border border-border bg-card p-4 text-left",
8243
8520
  "hover:border-primary/50 hover:bg-primary/5",
8244
8521
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -8270,7 +8547,7 @@ function MosaicQuickStartPanel({
8270
8547
  {
8271
8548
  type: "button",
8272
8549
  onClick: () => onSelectPreset(preset),
8273
- className: cn60(
8550
+ className: cn62(
8274
8551
  "flex items-center justify-between gap-3 rounded-lg border border-border bg-card px-4 py-3 text-left",
8275
8552
  "hover:border-primary/50",
8276
8553
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
@@ -8284,7 +8561,7 @@ function MosaicQuickStartPanel({
8284
8561
  a.accentColor && /* @__PURE__ */ jsxRuntime.jsx(
8285
8562
  "span",
8286
8563
  {
8287
- className: cn60("h-2 w-2 rounded-full", a.accentColor),
8564
+ className: cn62("h-2 w-2 rounded-full", a.accentColor),
8288
8565
  "aria-hidden": "true"
8289
8566
  }
8290
8567
  ),
@@ -8302,7 +8579,7 @@ function MosaicQuickStartPanel({
8302
8579
  {
8303
8580
  type: "button",
8304
8581
  onClick: onStartFromScratch,
8305
- className: cn60(
8582
+ className: cn62(
8306
8583
  "inline-flex min-h-[44px] w-full items-center justify-center rounded-md border border-border",
8307
8584
  "bg-background px-4 text-sm font-medium text-foreground",
8308
8585
  "hover:bg-accent hover:text-accent-foreground",
@@ -8341,9 +8618,9 @@ function TemplateGalleryContent({
8341
8618
  duplicateLabel,
8342
8619
  isMobile
8343
8620
  }) {
8344
- const [query, setQuery] = React28__namespace.useState("");
8345
- const [filterOpen, setFilterOpen] = React28__namespace.useState(false);
8346
- const [sidebarCollapsed, setSidebarCollapsed] = React28__namespace.useState(false);
8621
+ const [query, setQuery] = React29__namespace.useState("");
8622
+ const [filterOpen, setFilterOpen] = React29__namespace.useState(false);
8623
+ const [sidebarCollapsed, setSidebarCollapsed] = React29__namespace.useState(false);
8347
8624
  const filtered = templates.filter(
8348
8625
  (t) => !query || t.name.toLowerCase().includes(query.toLowerCase()) || (t.description ?? "").toLowerCase().includes(query.toLowerCase())
8349
8626
  );
@@ -8396,7 +8673,7 @@ function TemplateGalleryContent({
8396
8673
  value: query,
8397
8674
  onChange: (e) => setQuery(e.target.value),
8398
8675
  placeholder: searchPlaceholder,
8399
- className: cn60(
8676
+ className: cn62(
8400
8677
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3 text-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
8401
8678
  )
8402
8679
  }
@@ -8447,7 +8724,7 @@ function TemplateGalleryContent({
8447
8724
  value: query,
8448
8725
  onChange: (e) => setQuery(e.target.value),
8449
8726
  placeholder: searchPlaceholder,
8450
- className: cn60(
8727
+ className: cn62(
8451
8728
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3 text-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
8452
8729
  )
8453
8730
  }
@@ -8479,7 +8756,7 @@ function MosaicTemplateGallery(props) {
8479
8756
  return /* @__PURE__ */ jsxRuntime.jsx(TemplateGalleryContent, { ...props, isMobile });
8480
8757
  }
8481
8758
  MosaicTemplateGallery.displayName = "MosaicTemplateGallery";
8482
- function cn61(...classes) {
8759
+ function cn63(...classes) {
8483
8760
  return classes.filter(Boolean).join(" ");
8484
8761
  }
8485
8762
  function PlusIcon5() {
@@ -8581,7 +8858,7 @@ function MosaicModuleForm(props) {
8581
8858
  cancelLabel,
8582
8859
  tagListAddPlaceholder
8583
8860
  } = props;
8584
- const [formData, setFormData] = React28__namespace.useState({
8861
+ const [formData, setFormData] = React29__namespace.useState({
8585
8862
  name: item?.name ?? "",
8586
8863
  description: item?.description ?? "",
8587
8864
  icon: item?.icon ?? "",
@@ -8592,7 +8869,7 @@ function MosaicModuleForm(props) {
8592
8869
  formFields.map((f) => [f.id, item?.[f.id] ?? (f.type === "tag-list" ? [] : "")])
8593
8870
  )
8594
8871
  });
8595
- const [tagInputs, setTagInputs] = React28__namespace.useState({});
8872
+ const [tagInputs, setTagInputs] = React29__namespace.useState({});
8596
8873
  const update = (key, value) => {
8597
8874
  setFormData((prev) => ({ ...prev, [key]: value }));
8598
8875
  };
@@ -8630,7 +8907,7 @@ function MosaicModuleForm(props) {
8630
8907
  onChange: (e) => update("name", e.target.value),
8631
8908
  placeholder: namePlaceholder,
8632
8909
  required: true,
8633
- className: cn61(
8910
+ className: cn63(
8634
8911
  "w-full rounded-md border border-input bg-background px-3 py-2 min-h-[40px]",
8635
8912
  "text-sm placeholder:text-muted-foreground",
8636
8913
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -8648,7 +8925,7 @@ function MosaicModuleForm(props) {
8648
8925
  onChange: (e) => update("description", e.target.value),
8649
8926
  placeholder: descriptionPlaceholder,
8650
8927
  rows: 3,
8651
- className: cn61(
8928
+ className: cn63(
8652
8929
  "w-full rounded-md border border-input bg-background px-3 py-2",
8653
8930
  "text-sm placeholder:text-muted-foreground resize-none",
8654
8931
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -8670,7 +8947,7 @@ function MosaicModuleForm(props) {
8670
8947
  value: formData[field.id] ?? "",
8671
8948
  onChange: (e) => update(field.id, e.target.value),
8672
8949
  placeholder: field.placeholder,
8673
- className: cn61(
8950
+ className: cn63(
8674
8951
  "w-full rounded-md border border-input bg-background px-3 py-2 min-h-[40px]",
8675
8952
  "text-sm placeholder:text-muted-foreground",
8676
8953
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -8685,7 +8962,7 @@ function MosaicModuleForm(props) {
8685
8962
  onChange: (e) => update(field.id, e.target.value),
8686
8963
  placeholder: field.placeholder,
8687
8964
  rows: 3,
8688
- className: cn61(
8965
+ className: cn63(
8689
8966
  "w-full rounded-md border border-input bg-background px-3 py-2",
8690
8967
  "text-sm placeholder:text-muted-foreground resize-none",
8691
8968
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -8701,7 +8978,7 @@ function MosaicModuleForm(props) {
8701
8978
  onChange: (e) => update(field.id, e.target.value),
8702
8979
  placeholder: field.placeholder ?? "\u{1F9E0}",
8703
8980
  maxLength: 4,
8704
- className: cn61(
8981
+ className: cn63(
8705
8982
  "w-20 rounded-md border border-input bg-background px-3 py-2 text-2xl",
8706
8983
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
8707
8984
  )
@@ -8722,7 +8999,7 @@ function MosaicModuleForm(props) {
8722
8999
  }
8723
9000
  },
8724
9001
  placeholder: field.placeholder ?? tagListAddPlaceholder,
8725
- className: cn61(
9002
+ className: cn63(
8726
9003
  "flex-1 rounded-md border border-input bg-background px-3 py-2 min-h-[36px]",
8727
9004
  "text-sm placeholder:text-muted-foreground",
8728
9005
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -8793,9 +9070,9 @@ function ModuleItemCard({
8793
9070
  editItemLabel,
8794
9071
  deleteItemLabel
8795
9072
  }) {
8796
- const [menuOpen, setMenuOpen] = React28__namespace.useState(false);
8797
- const menuRef = React28__namespace.useRef(null);
8798
- React28__namespace.useEffect(() => {
9073
+ const [menuOpen, setMenuOpen] = React29__namespace.useState(false);
9074
+ const menuRef = React29__namespace.useRef(null);
9075
+ React29__namespace.useEffect(() => {
8799
9076
  if (!menuOpen) return;
8800
9077
  const h = (e) => {
8801
9078
  if (menuRef.current && !menuRef.current.contains(e.target)) setMenuOpen(false);
@@ -8896,11 +9173,11 @@ function LibraryContent({
8896
9173
  editModalTitle,
8897
9174
  tagListAddPlaceholder
8898
9175
  }) {
8899
- const [query, setQuery] = React28__namespace.useState("");
8900
- const [activeTab, setActiveTab] = React28__namespace.useState(tabs?.[0]?.id ?? "all");
8901
- const [editorOpen, setEditorOpen] = React28__namespace.useState(false);
8902
- const [editingItem, setEditingItem] = React28__namespace.useState();
8903
- const [editorMode, setEditorMode] = React28__namespace.useState("create");
9176
+ const [query, setQuery] = React29__namespace.useState("");
9177
+ const [activeTab, setActiveTab] = React29__namespace.useState(tabs?.[0]?.id ?? "all");
9178
+ const [editorOpen, setEditorOpen] = React29__namespace.useState(false);
9179
+ const [editingItem, setEditingItem] = React29__namespace.useState();
9180
+ const [editorMode, setEditorMode] = React29__namespace.useState("create");
8904
9181
  const openCreate = () => {
8905
9182
  setEditingItem(void 0);
8906
9183
  setEditorMode("create");
@@ -8934,7 +9211,7 @@ function LibraryContent({
8934
9211
  {
8935
9212
  type: "button",
8936
9213
  onClick: openCreate,
8937
- className: cn61(
9214
+ className: cn63(
8938
9215
  "inline-flex items-center gap-2 rounded-md bg-primary px-3 py-2 text-sm font-medium text-primary-foreground",
8939
9216
  "hover:bg-primary/90 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
8940
9217
  ),
@@ -8954,7 +9231,7 @@ function LibraryContent({
8954
9231
  value: query,
8955
9232
  onChange: (e) => setQuery(e.target.value),
8956
9233
  placeholder: searchPlaceholder,
8957
- className: cn61(
9234
+ className: cn63(
8958
9235
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
8959
9236
  "text-sm placeholder:text-muted-foreground",
8960
9237
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -8967,7 +9244,7 @@ function LibraryContent({
8967
9244
  {
8968
9245
  type: "button",
8969
9246
  onClick: () => setActiveTab(tab.id),
8970
- className: cn61(
9247
+ className: cn63(
8971
9248
  "rounded-md px-3 py-1.5 text-sm font-medium transition-colors",
8972
9249
  activeTab === tab.id ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground hover:bg-accent hover:text-accent-foreground"
8973
9250
  ),
@@ -9019,7 +9296,7 @@ function MosaicModuleLibrary(props) {
9019
9296
  return /* @__PURE__ */ jsxRuntime.jsx(LibraryContent, { ...props });
9020
9297
  }
9021
9298
  MosaicModuleLibrary.displayName = "MosaicModuleLibrary";
9022
- function cn62(...classes) {
9299
+ function cn64(...classes) {
9023
9300
  return classes.filter(Boolean).join(" ");
9024
9301
  }
9025
9302
  var roleConfig = {
@@ -9046,7 +9323,7 @@ function MosaicOrgRoleBadge({ role, className }) {
9046
9323
  {
9047
9324
  "data-slot": "org-role-badge",
9048
9325
  title: config.description,
9049
- className: cn62(
9326
+ className: cn64(
9050
9327
  "inline-flex items-center rounded-full px-2 py-0.5 text-xs font-medium",
9051
9328
  config.className,
9052
9329
  className
@@ -9063,13 +9340,13 @@ function MosaicMultiOrgIndicator({
9063
9340
  className
9064
9341
  }) {
9065
9342
  if (orgCount <= 1) return null;
9066
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "multi-org-indicator", className: cn62("flex items-center gap-2", className), children: [
9343
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "multi-org-indicator", className: cn64("flex items-center gap-2", className), children: [
9067
9344
  onSwitchOrg ? /* @__PURE__ */ jsxRuntime.jsxs(
9068
9345
  "button",
9069
9346
  {
9070
9347
  type: "button",
9071
9348
  onClick: onSwitchOrg,
9072
- className: cn62(
9349
+ className: cn64(
9073
9350
  "inline-flex items-center gap-1.5 rounded-full bg-secondary px-2.5 py-1 text-xs font-medium text-secondary-foreground",
9074
9351
  "hover:bg-secondary/80",
9075
9352
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -9122,10 +9399,10 @@ function MosaicCreateOrgDialog({
9122
9399
  creatingLabel,
9123
9400
  createLabel
9124
9401
  }) {
9125
- const [name, setName] = React28__namespace.useState("");
9126
- const [slug, setSlug] = React28__namespace.useState("");
9127
- const [description, setDescription] = React28__namespace.useState("");
9128
- const [errors, setErrors] = React28__namespace.useState({});
9402
+ const [name, setName] = React29__namespace.useState("");
9403
+ const [slug, setSlug] = React29__namespace.useState("");
9404
+ const [description, setDescription] = React29__namespace.useState("");
9405
+ const [errors, setErrors] = React29__namespace.useState({});
9129
9406
  const validate = () => {
9130
9407
  const errs = {};
9131
9408
  if (!name.trim()) errs.name = "Name is required";
@@ -9149,7 +9426,7 @@ function MosaicCreateOrgDialog({
9149
9426
  setErrors({});
9150
9427
  onOpenChange(false);
9151
9428
  };
9152
- React28__namespace.useEffect(() => {
9429
+ React29__namespace.useEffect(() => {
9153
9430
  if (!name) {
9154
9431
  setSlug("");
9155
9432
  return;
@@ -9183,7 +9460,7 @@ function MosaicCreateOrgDialog({
9183
9460
  onChange: (e) => setName(e.target.value),
9184
9461
  placeholder: orgNamePlaceholder,
9185
9462
  required: true,
9186
- className: cn62(
9463
+ className: cn64(
9187
9464
  "w-full rounded-md border bg-background px-3 py-2 min-h-[40px] text-sm placeholder:text-muted-foreground",
9188
9465
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
9189
9466
  errors.name ? "border-destructive" : "border-input"
@@ -9203,7 +9480,7 @@ function MosaicCreateOrgDialog({
9203
9480
  onChange: (e) => setSlug(e.target.value),
9204
9481
  placeholder: "acme-inc",
9205
9482
  required: true,
9206
- className: cn62(
9483
+ className: cn64(
9207
9484
  "w-full rounded-md border bg-background px-3 py-2 min-h-[40px] text-sm placeholder:text-muted-foreground",
9208
9485
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
9209
9486
  errors.slug ? "border-destructive" : "border-input"
@@ -9272,9 +9549,9 @@ function MosaicInviteMemberDialog({
9272
9549
  sendingLabel,
9273
9550
  sendInvitationLabel
9274
9551
  }) {
9275
- const [email, setEmail] = React28__namespace.useState("");
9276
- const [role, setRole] = React28__namespace.useState("member");
9277
- const [errors, setErrors] = React28__namespace.useState({});
9552
+ const [email, setEmail] = React29__namespace.useState("");
9553
+ const [role, setRole] = React29__namespace.useState("member");
9554
+ const [errors, setErrors] = React29__namespace.useState({});
9278
9555
  const validate = () => {
9279
9556
  const errs = {};
9280
9557
  if (!email.trim()) errs.email = "Email is required";
@@ -9316,7 +9593,7 @@ function MosaicInviteMemberDialog({
9316
9593
  onChange: (e) => setEmail(e.target.value),
9317
9594
  placeholder: emailPlaceholder,
9318
9595
  required: true,
9319
- className: cn62(
9596
+ className: cn64(
9320
9597
  "w-full rounded-md border bg-background px-3 py-2 min-h-[40px] text-sm placeholder:text-muted-foreground",
9321
9598
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
9322
9599
  errors.email ? "border-destructive" : "border-input"
@@ -9375,10 +9652,10 @@ function MemberRow({
9375
9652
  memberActionsAriaLabel,
9376
9653
  removeMemberLabel
9377
9654
  }) {
9378
- const [menuOpen, setMenuOpen] = React28__namespace.useState(false);
9379
- const menuRef = React28__namespace.useRef(null);
9655
+ const [menuOpen, setMenuOpen] = React29__namespace.useState(false);
9656
+ const menuRef = React29__namespace.useRef(null);
9380
9657
  const isSelf = member.id === currentUserId;
9381
- React28__namespace.useEffect(() => {
9658
+ React29__namespace.useEffect(() => {
9382
9659
  if (!menuOpen) return;
9383
9660
  const h = (e) => {
9384
9661
  if (menuRef.current && !menuRef.current.contains(e.target)) setMenuOpen(false);
@@ -9499,11 +9776,11 @@ function MosaicMemberList({
9499
9776
  inviteLabel,
9500
9777
  className
9501
9778
  }) {
9502
- const [query, setQuery] = React28__namespace.useState("");
9779
+ const [query, setQuery] = React29__namespace.useState("");
9503
9780
  const filtered = members.filter(
9504
9781
  (m) => !query || m.name.toLowerCase().includes(query.toLowerCase()) || m.email.toLowerCase().includes(query.toLowerCase())
9505
9782
  );
9506
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "member-list", className: cn62("flex flex-col gap-4", className), children: [
9783
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "member-list", className: cn64("flex flex-col gap-4", className), children: [
9507
9784
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
9508
9785
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative flex-1", children: [
9509
9786
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground", children: /* @__PURE__ */ jsxRuntime.jsxs(
@@ -9597,9 +9874,9 @@ function MosaicOrgPanel({
9597
9874
  className
9598
9875
  }) {
9599
9876
  const { isMobile } = useDevice();
9600
- const [activeTab, setActiveTab] = React28__namespace.useState(defaultTab ?? tabs[0]?.id ?? "");
9877
+ const [activeTab, setActiveTab] = React29__namespace.useState(defaultTab ?? tabs[0]?.id ?? "");
9601
9878
  const activeContent = tabs.find((t) => t.id === activeTab)?.content;
9602
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "org-panel", className: cn62("flex h-full flex-col", className), children: [
9879
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "org-panel", className: cn64("flex h-full flex-col", className), children: [
9603
9880
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-b border-border px-4 py-4 md:px-6", children: [
9604
9881
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start justify-between gap-4", children: [
9605
9882
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
@@ -9621,12 +9898,12 @@ function MosaicOrgPanel({
9621
9898
  ] }),
9622
9899
  headerActions
9623
9900
  ] }),
9624
- tabs.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn62("mt-4 flex gap-1", isMobile && "overflow-x-auto"), children: tabs.map((tab) => /* @__PURE__ */ jsxRuntime.jsx(
9901
+ tabs.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn64("mt-4 flex gap-1", isMobile && "overflow-x-auto"), children: tabs.map((tab) => /* @__PURE__ */ jsxRuntime.jsx(
9625
9902
  "button",
9626
9903
  {
9627
9904
  type: "button",
9628
9905
  onClick: () => setActiveTab(tab.id),
9629
- className: cn62(
9906
+ className: cn64(
9630
9907
  "shrink-0 rounded-md px-3 py-1.5 text-sm font-medium transition-colors",
9631
9908
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
9632
9909
  activeTab === tab.id ? "bg-primary text-primary-foreground" : "bg-muted text-muted-foreground hover:bg-accent hover:text-accent-foreground"
@@ -9640,7 +9917,7 @@ function MosaicOrgPanel({
9640
9917
  ] });
9641
9918
  }
9642
9919
  MosaicOrgPanel.displayName = "MosaicOrgPanel";
9643
- function cn63(...classes) {
9920
+ function cn65(...classes) {
9644
9921
  return classes.filter(Boolean).join(" ");
9645
9922
  }
9646
9923
  var ANIM_ID8 = "mosaic-dashboard-content-kf";
@@ -9669,7 +9946,7 @@ function MosaicDashboardContent({
9669
9946
  className
9670
9947
  }) {
9671
9948
  const { isMobile } = useDevice();
9672
- React28__namespace.useEffect(() => {
9949
+ React29__namespace.useEffect(() => {
9673
9950
  injectStyles8();
9674
9951
  }, []);
9675
9952
  const activeView = views.find((v) => v.id === currentView);
@@ -9677,7 +9954,7 @@ function MosaicDashboardContent({
9677
9954
  "div",
9678
9955
  {
9679
9956
  "data-slot": "dashboard-content",
9680
- className: cn63("h-full overflow-auto", isMobile ? "p-4" : "p-6", className),
9957
+ className: cn65("h-full overflow-auto", isMobile ? "p-4" : "p-6", className),
9681
9958
  children: activeView ? /* @__PURE__ */ jsxRuntime.jsx("div", { className: "mosaic-content-view space-y-6", children: activeView.content }, currentView) : /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "py-12 text-center text-sm text-muted-foreground", children: [
9682
9959
  "View not found: ",
9683
9960
  currentView
@@ -9686,7 +9963,7 @@ function MosaicDashboardContent({
9686
9963
  );
9687
9964
  }
9688
9965
  MosaicDashboardContent.displayName = "MosaicDashboardContent";
9689
- function cn64(...classes) {
9966
+ function cn66(...classes) {
9690
9967
  return classes.filter(Boolean).join(" ");
9691
9968
  }
9692
9969
  var ANIM_ID9 = "mosaic-dashboard-header2-kf";
@@ -9786,8 +10063,8 @@ function MosaicDashboardHeader({
9786
10063
  className
9787
10064
  }) {
9788
10065
  const { isMobile } = useDevice();
9789
- const [searchQuery, setSearchQuery] = React28__namespace.useState("");
9790
- React28__namespace.useEffect(() => {
10066
+ const [searchQuery, setSearchQuery] = React29__namespace.useState("");
10067
+ React29__namespace.useEffect(() => {
9791
10068
  injectStyles9();
9792
10069
  }, []);
9793
10070
  const handleSearch = (e) => {
@@ -9798,16 +10075,16 @@ function MosaicDashboardHeader({
9798
10075
  "header",
9799
10076
  {
9800
10077
  "data-slot": "dashboard-header",
9801
- className: cn64(
10078
+ className: cn66(
9802
10079
  "mosaic-dashboard-header2",
9803
10080
  "sticky top-0 z-40 border-b border-border/50 bg-background/80 backdrop-blur-sm",
9804
10081
  className
9805
10082
  ),
9806
- children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn64(isMobile ? "px-4 py-3" : "container mx-auto px-4 py-4"), children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
10083
+ children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn66(isMobile ? "px-4 py-3" : "container mx-auto px-4 py-4"), children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
9807
10084
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex min-w-0 flex-1 items-center gap-2 md:gap-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
9808
10085
  logoSlot ?? /* @__PURE__ */ jsxRuntime.jsx(SparklesIcon4, {}),
9809
10086
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0", children: [
9810
- /* @__PURE__ */ jsxRuntime.jsx("h1", { className: cn64("font-semibold truncate", isMobile ? "text-lg" : "text-xl"), children: title }),
10087
+ /* @__PURE__ */ jsxRuntime.jsx("h1", { className: cn66("font-semibold truncate", isMobile ? "text-lg" : "text-xl"), children: title }),
9811
10088
  subtitle && !isMobile && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground truncate", children: subtitle })
9812
10089
  ] })
9813
10090
  ] }) }),
@@ -9820,7 +10097,7 @@ function MosaicDashboardHeader({
9820
10097
  value: searchQuery,
9821
10098
  onChange: handleSearch,
9822
10099
  placeholder: searchPlaceholder,
9823
- className: cn64(
10100
+ className: cn66(
9824
10101
  "w-full rounded-md border border-input bg-background py-2 pl-9 pr-3",
9825
10102
  "text-sm placeholder:text-muted-foreground",
9826
10103
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
@@ -9860,7 +10137,7 @@ function MosaicDashboardHeader({
9860
10137
  );
9861
10138
  }
9862
10139
  MosaicDashboardHeader.displayName = "MosaicDashboardHeader";
9863
- function cn65(...classes) {
10140
+ function cn67(...classes) {
9864
10141
  return classes.filter(Boolean).join(" ");
9865
10142
  }
9866
10143
  function ChevronDownIcon4() {
@@ -9930,10 +10207,10 @@ function MosaicOrgSwitcher({
9930
10207
  noOrgSelectedLabel,
9931
10208
  className
9932
10209
  }) {
9933
- const [open, setOpen] = React28__namespace.useState(false);
9934
- const ref = React28__namespace.useRef(null);
10210
+ const [open, setOpen] = React29__namespace.useState(false);
10211
+ const ref = React29__namespace.useRef(null);
9935
10212
  const currentOrg = organizations.find((o) => o.id === currentOrgId) ?? organizations[0];
9936
- React28__namespace.useEffect(() => {
10213
+ React29__namespace.useEffect(() => {
9937
10214
  if (!open) return;
9938
10215
  const h = (e) => {
9939
10216
  if (ref.current && !ref.current.contains(e.target)) setOpen(false);
@@ -9943,13 +10220,13 @@ function MosaicOrgSwitcher({
9943
10220
  }, [open]);
9944
10221
  if (!currentOrg && organizations.length === 0 && !onCreateOrg) return null;
9945
10222
  const initials = currentOrg?.name.split(" ").map((n) => n[0]).filter(Boolean).slice(0, 2).join("").toUpperCase() ?? "?";
9946
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "org-switcher", className: cn65("relative", className), children: [
10223
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "org-switcher", className: cn67("relative", className), children: [
9947
10224
  /* @__PURE__ */ jsxRuntime.jsxs(
9948
10225
  "button",
9949
10226
  {
9950
10227
  type: "button",
9951
10228
  onClick: () => setOpen((v) => !v),
9952
- className: cn65(
10229
+ className: cn67(
9953
10230
  "inline-flex items-center gap-2 rounded-md border border-border bg-background px-3 py-1.5",
9954
10231
  "text-sm font-medium text-foreground",
9955
10232
  "hover:bg-accent hover:text-accent-foreground",
@@ -9976,7 +10253,7 @@ function MosaicOrgSwitcher({
9976
10253
  {
9977
10254
  role: "menu",
9978
10255
  "aria-label": triggerAriaLabel,
9979
- className: cn65(
10256
+ className: cn67(
9980
10257
  "absolute left-0 top-full z-50 mt-1 min-w-[200px] rounded-md border border-border",
9981
10258
  "bg-popover py-1 shadow-md"
9982
10259
  ),
@@ -9991,7 +10268,7 @@ function MosaicOrgSwitcher({
9991
10268
  onSelectOrg?.(org.id);
9992
10269
  setOpen(false);
9993
10270
  },
9994
- className: cn65(
10271
+ className: cn67(
9995
10272
  "flex w-full items-center gap-2.5 px-3 py-2 text-sm text-foreground",
9996
10273
  "hover:bg-accent hover:text-accent-foreground",
9997
10274
  org.id === currentOrgId && "bg-primary/10 text-primary"
@@ -10028,7 +10305,7 @@ function MosaicOrgSwitcher({
10028
10305
  ] });
10029
10306
  }
10030
10307
  MosaicOrgSwitcher.displayName = "MosaicOrgSwitcher";
10031
- function cn66(...classes) {
10308
+ function cn68(...classes) {
10032
10309
  return classes.filter(Boolean).join(" ");
10033
10310
  }
10034
10311
  function PlusIcon7() {
@@ -10063,9 +10340,9 @@ function MosaicQuickActionsMenu({
10063
10340
  className
10064
10341
  }) {
10065
10342
  const { isMobile } = useDevice();
10066
- const [open, setOpen] = React28__namespace.useState(false);
10067
- const ref = React28__namespace.useRef(null);
10068
- React28__namespace.useEffect(() => {
10343
+ const [open, setOpen] = React29__namespace.useState(false);
10344
+ const ref = React29__namespace.useRef(null);
10345
+ React29__namespace.useEffect(() => {
10069
10346
  if (!open) return;
10070
10347
  const h = (e) => {
10071
10348
  if (ref.current && !ref.current.contains(e.target)) setOpen(false);
@@ -10073,19 +10350,19 @@ function MosaicQuickActionsMenu({
10073
10350
  document.addEventListener("mousedown", h);
10074
10351
  return () => document.removeEventListener("mousedown", h);
10075
10352
  }, [open]);
10076
- const itemClass = cn66(
10353
+ const itemClass = cn68(
10077
10354
  "flex w-full items-center gap-2 px-3 py-2 text-sm text-foreground",
10078
10355
  "hover:bg-accent hover:text-accent-foreground",
10079
10356
  "focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring",
10080
10357
  "min-h-[44px]"
10081
10358
  );
10082
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "quick-actions-menu", className: cn66("relative", className), children: [
10359
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "quick-actions-menu", className: cn68("relative", className), children: [
10083
10360
  /* @__PURE__ */ jsxRuntime.jsxs(
10084
10361
  "button",
10085
10362
  {
10086
10363
  type: "button",
10087
10364
  onClick: () => setOpen((v) => !v),
10088
- className: cn66(
10365
+ className: cn68(
10089
10366
  "inline-flex items-center justify-center gap-2 rounded-md border border-border bg-background",
10090
10367
  "min-h-[44px] min-w-[44px] px-3 py-2 text-sm font-medium text-foreground",
10091
10368
  "hover:bg-accent hover:text-accent-foreground",
@@ -10096,7 +10373,7 @@ function MosaicQuickActionsMenu({
10096
10373
  "aria-label": label,
10097
10374
  children: [
10098
10375
  triggerIcon ?? /* @__PURE__ */ jsxRuntime.jsx(PlusIcon7, {}),
10099
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn66("hidden md:inline"), children: label })
10376
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn68("hidden md:inline"), children: label })
10100
10377
  ]
10101
10378
  }
10102
10379
  ),
@@ -10105,14 +10382,14 @@ function MosaicQuickActionsMenu({
10105
10382
  {
10106
10383
  role: "menu",
10107
10384
  "aria-label": menuTitle,
10108
- className: cn66(
10385
+ className: cn68(
10109
10386
  "absolute right-0 top-full z-50 mt-1 rounded-md border border-border bg-popover py-1 shadow-md",
10110
10387
  isMobile ? "w-[min(90vw,280px)]" : "w-56"
10111
10388
  ),
10112
10389
  children: [
10113
10390
  menuTitle && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-1.5", children: /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs font-semibold text-muted-foreground uppercase tracking-wide", children: menuTitle }) }),
10114
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn66(menuTitle && "border-t border-border") }),
10115
- actions.map((action) => /* @__PURE__ */ jsxRuntime.jsxs(React28__namespace.Fragment, { children: [
10391
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn68(menuTitle && "border-t border-border") }),
10392
+ actions.map((action) => /* @__PURE__ */ jsxRuntime.jsxs(React29__namespace.Fragment, { children: [
10116
10393
  action.separator && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "my-1 border-t border-border" }),
10117
10394
  action.href && renderLink ? renderLink(
10118
10395
  action,
@@ -10416,7 +10693,7 @@ function MosaicOrgProfilePage({
10416
10693
  );
10417
10694
  }
10418
10695
  MosaicOrgProfilePage.displayName = "MosaicOrgProfilePage";
10419
- function cn67(...classes) {
10696
+ function cn69(...classes) {
10420
10697
  return classes.filter(Boolean).join(" ");
10421
10698
  }
10422
10699
  function defaultCompare(a, b) {
@@ -10435,7 +10712,7 @@ function MosaicDataTable({
10435
10712
  footerSlot,
10436
10713
  pagination
10437
10714
  }) {
10438
- const [sort, setSort] = React28.useState(null);
10715
+ const [sort, setSort] = React29.useState(null);
10439
10716
  function handleHeaderClick(col) {
10440
10717
  if (!masterSortable || !col.sortable) return;
10441
10718
  setSort((prev) => {
@@ -10479,7 +10756,7 @@ function MosaicDataTable({
10479
10756
  {
10480
10757
  ref,
10481
10758
  "data-slot": "data-table",
10482
- className: cn67("w-full border-collapse text-sm", className),
10759
+ className: cn69("w-full border-collapse text-sm", className),
10483
10760
  children: [
10484
10761
  /* @__PURE__ */ jsxRuntime.jsx("thead", { "data-slot": "data-table-header", children: /* @__PURE__ */ jsxRuntime.jsx("tr", { "data-slot": "data-table-header-row", className: "border-b border-border bg-muted", children: columns.map((col, colIndex) => {
10485
10762
  const isSortable = masterSortable && col.sortable;
@@ -10497,7 +10774,7 @@ function MosaicDataTable({
10497
10774
  handleHeaderClick(col);
10498
10775
  }
10499
10776
  } : void 0,
10500
- className: cn67(
10777
+ className: cn69(
10501
10778
  "px-4 py-3 font-medium text-muted-foreground",
10502
10779
  alignClass(col.align),
10503
10780
  col.className,
@@ -10533,7 +10810,7 @@ function MosaicDataTable({
10533
10810
  "td",
10534
10811
  {
10535
10812
  "data-slot": "data-table-td",
10536
- className: cn67(
10813
+ className: cn69(
10537
10814
  "px-4 py-3 text-foreground",
10538
10815
  alignClass(col.align),
10539
10816
  col.className
@@ -10672,7 +10949,7 @@ var stepSegmentVariants = classVarianceAuthority.cva(["h-1.5 flex-1 min-w-2 roun
10672
10949
  filled: false
10673
10950
  }
10674
10951
  });
10675
- function cn68(...classes) {
10952
+ function cn70(...classes) {
10676
10953
  return classes.filter(Boolean).join(" ");
10677
10954
  }
10678
10955
  function resolveStatus(step, index, currentIndex) {
@@ -10713,7 +10990,7 @@ function MosaicStepPipelineSegments({
10713
10990
  "aria-valuemax": total,
10714
10991
  "aria-valuenow": current,
10715
10992
  "aria-valuetext": progressLabel ? progressLabel(current, total) : void 0,
10716
- className: cn68(stepSegmentBarVariants(), className),
10993
+ className: cn70(stepSegmentBarVariants(), className),
10717
10994
  children: steps.map((step, index) => {
10718
10995
  const status = resolveStatus(step, index, currentIndex);
10719
10996
  const filled = status !== "upcoming";
@@ -10725,7 +11002,7 @@ function MosaicStepPipelineSegments({
10725
11002
  "data-status": status,
10726
11003
  "data-filled": filled,
10727
11004
  "aria-hidden": "true",
10728
- className: cn68(stepSegmentVariants({ filled }))
11005
+ className: cn70(stepSegmentVariants({ filled }))
10729
11006
  },
10730
11007
  key
10731
11008
  );
@@ -10746,7 +11023,7 @@ function MosaicStepPipelineDots({
10746
11023
  {
10747
11024
  ref,
10748
11025
  "data-slot": "step-pipeline",
10749
- className: cn68(stepPipelineVariants({ orientation }), className),
11026
+ className: cn70(stepPipelineVariants({ orientation }), className),
10750
11027
  children: steps.map((step, index) => {
10751
11028
  const status = resolveStatus(step, index, currentIndex);
10752
11029
  const isCurrent = status === "current";
@@ -10758,7 +11035,7 @@ function MosaicStepPipelineDots({
10758
11035
  "data-slot": "step",
10759
11036
  "data-status": status,
10760
11037
  "aria-current": isCurrent ? "step" : void 0,
10761
- className: cn68(
11038
+ className: cn70(
10762
11039
  "flex shrink-0",
10763
11040
  orientation === "horizontal" ? "flex-col items-center gap-2" : "flex-row items-start gap-3",
10764
11041
  orientation === "horizontal" && !isLast && "flex-1"
@@ -10769,14 +11046,14 @@ function MosaicStepPipelineDots({
10769
11046
  "div",
10770
11047
  {
10771
11048
  "data-slot": "step-connector",
10772
- className: cn68(stepConnectorVariants({ status, orientation }))
11049
+ className: cn70(stepConnectorVariants({ status, orientation }))
10773
11050
  }
10774
11051
  ),
10775
11052
  /* @__PURE__ */ jsxRuntime.jsx(
10776
11053
  "div",
10777
11054
  {
10778
11055
  "data-slot": "step-indicator",
10779
- className: cn68(stepIndicatorVariants({ status, orientation })),
11056
+ className: cn70(stepIndicatorVariants({ status, orientation })),
10780
11057
  "aria-hidden": "true",
10781
11058
  children: status === "done" ? "\u2713" : /* @__PURE__ */ jsxRuntime.jsx("span", { children: index + 1 })
10782
11059
  }
@@ -10785,7 +11062,7 @@ function MosaicStepPipelineDots({
10785
11062
  "div",
10786
11063
  {
10787
11064
  "data-slot": "step-connector",
10788
- className: cn68(
11065
+ className: cn70(
10789
11066
  stepConnectorVariants({
10790
11067
  // connector after current step is still upcoming
10791
11068
  status: status === "done" ? "done" : "upcoming",
@@ -10796,12 +11073,12 @@ function MosaicStepPipelineDots({
10796
11073
  )
10797
11074
  ] }),
10798
11075
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-0.5 text-center px-1", children: [
10799
- /* @__PURE__ */ jsxRuntime.jsx("span", { "data-slot": "step-label", className: cn68(stepLabelVariants({ status })), children: step.label }),
11076
+ /* @__PURE__ */ jsxRuntime.jsx("span", { "data-slot": "step-label", className: cn70(stepLabelVariants({ status })), children: step.label }),
10800
11077
  step.description !== void 0 && /* @__PURE__ */ jsxRuntime.jsx(
10801
11078
  "span",
10802
11079
  {
10803
11080
  "data-slot": "step-description",
10804
- className: cn68(stepDescriptionVariants({ status })),
11081
+ className: cn70(stepDescriptionVariants({ status })),
10805
11082
  children: step.description
10806
11083
  }
10807
11084
  )
@@ -10812,7 +11089,7 @@ function MosaicStepPipelineDots({
10812
11089
  "div",
10813
11090
  {
10814
11091
  "data-slot": "step-indicator",
10815
- className: cn68(stepIndicatorVariants({ status, orientation })),
11092
+ className: cn70(stepIndicatorVariants({ status, orientation })),
10816
11093
  "aria-hidden": "true",
10817
11094
  children: status === "done" ? "\u2713" : /* @__PURE__ */ jsxRuntime.jsx("span", { children: index + 1 })
10818
11095
  }
@@ -10821,7 +11098,7 @@ function MosaicStepPipelineDots({
10821
11098
  "div",
10822
11099
  {
10823
11100
  "data-slot": "step-connector",
10824
- className: cn68(
11101
+ className: cn70(
10825
11102
  stepConnectorVariants({
10826
11103
  status: status === "done" ? "done" : "upcoming",
10827
11104
  orientation
@@ -10831,12 +11108,12 @@ function MosaicStepPipelineDots({
10831
11108
  )
10832
11109
  ] }),
10833
11110
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-0.5 pt-1 pb-4", children: [
10834
- /* @__PURE__ */ jsxRuntime.jsx("span", { "data-slot": "step-label", className: cn68(stepLabelVariants({ status })), children: step.label }),
11111
+ /* @__PURE__ */ jsxRuntime.jsx("span", { "data-slot": "step-label", className: cn70(stepLabelVariants({ status })), children: step.label }),
10835
11112
  step.description !== void 0 && /* @__PURE__ */ jsxRuntime.jsx(
10836
11113
  "span",
10837
11114
  {
10838
11115
  "data-slot": "step-description",
10839
- className: cn68(stepDescriptionVariants({ status })),
11116
+ className: cn70(stepDescriptionVariants({ status })),
10840
11117
  children: step.description
10841
11118
  }
10842
11119
  )
@@ -10850,7 +11127,7 @@ function MosaicStepPipelineDots({
10850
11127
  );
10851
11128
  }
10852
11129
  MosaicStepPipelineDots.displayName = "MosaicStepPipelineDots";
10853
- function cn69(...classes) {
11130
+ function cn71(...classes) {
10854
11131
  return classes.filter(Boolean).join(" ");
10855
11132
  }
10856
11133
  function MosaicKanbanBoard({ children, className, ref, ...props }) {
@@ -10859,7 +11136,7 @@ function MosaicKanbanBoard({ children, className, ref, ...props }) {
10859
11136
  {
10860
11137
  ref,
10861
11138
  "data-slot": "kanban-board",
10862
- className: cn69(
11139
+ className: cn71(
10863
11140
  "flex gap-4 overflow-x-auto pb-4",
10864
11141
  "min-h-0",
10865
11142
  // Smooth momentum scrolling on iOS
@@ -10872,7 +11149,7 @@ function MosaicKanbanBoard({ children, className, ref, ...props }) {
10872
11149
  );
10873
11150
  }
10874
11151
  MosaicKanbanBoard.displayName = "MosaicKanbanBoard";
10875
- function cn70(...classes) {
11152
+ function cn72(...classes) {
10876
11153
  return classes.filter(Boolean).join(" ");
10877
11154
  }
10878
11155
  function MosaicKanbanColumn({
@@ -10890,7 +11167,7 @@ function MosaicKanbanColumn({
10890
11167
  {
10891
11168
  ref,
10892
11169
  "data-slot": "kanban-column",
10893
- className: cn70(
11170
+ className: cn72(
10894
11171
  // Fixed column width, never shrink so board stays scrollable
10895
11172
  "flex flex-col w-72 shrink-0",
10896
11173
  // Surface
@@ -10911,7 +11188,7 @@ function MosaicKanbanColumn({
10911
11188
  {
10912
11189
  "data-slot": "kanban-column-count",
10913
11190
  "aria-label": countLabel(count),
10914
- className: cn70(
11191
+ className: cn72(
10915
11192
  "inline-flex items-center justify-center",
10916
11193
  "min-w-[1.25rem] h-5 px-1.5 rounded-full",
10917
11194
  "bg-muted text-muted-foreground",
@@ -10954,12 +11231,12 @@ function MosaicKanbanColumn({
10954
11231
  );
10955
11232
  }
10956
11233
  MosaicKanbanColumn.displayName = "MosaicKanbanColumn";
10957
- var WorkspaceCtx = React28__namespace.createContext({
11234
+ var WorkspaceCtx = React29__namespace.createContext({
10958
11235
  workspaceId: null,
10959
11236
  isLoading: false
10960
11237
  });
10961
11238
  function useMosaicWorkspace() {
10962
- return React28__namespace.useContext(WorkspaceCtx);
11239
+ return React29__namespace.useContext(WorkspaceCtx);
10963
11240
  }
10964
11241
  var defaultClerkAppearance = {
10965
11242
  variables: {
@@ -10972,9 +11249,9 @@ var defaultClerkAppearance = {
10972
11249
  }
10973
11250
  };
10974
11251
  function WorkspaceResolver({ resolveWorkspaceId, initialOrgId, children }) {
10975
- const [workspaceId, setWorkspaceId] = React28__namespace.useState(null);
10976
- const [isLoading, setIsLoading] = React28__namespace.useState(false);
10977
- React28__namespace.useEffect(() => {
11252
+ const [workspaceId, setWorkspaceId] = React29__namespace.useState(null);
11253
+ const [isLoading, setIsLoading] = React29__namespace.useState(false);
11254
+ React29__namespace.useEffect(() => {
10978
11255
  if (!resolveWorkspaceId) {
10979
11256
  setWorkspaceId(initialOrgId ?? null);
10980
11257
  return;
@@ -11133,7 +11410,7 @@ var documentUploadProgressFillVariants = classVarianceAuthority.cva(
11133
11410
  defaultVariants: {}
11134
11411
  }
11135
11412
  );
11136
- function cn71(...classes) {
11413
+ function cn73(...classes) {
11137
11414
  return classes.filter(Boolean).join(" ");
11138
11415
  }
11139
11416
  function MosaicDocumentUpload({
@@ -11153,9 +11430,9 @@ function MosaicDocumentUpload({
11153
11430
  className,
11154
11431
  ref
11155
11432
  }) {
11156
- const [isDragActive, setIsDragActive] = React28.useState(false);
11157
- const inputRef = React28.useRef(null);
11158
- const inputId = React28.useId();
11433
+ const [isDragActive, setIsDragActive] = React29.useState(false);
11434
+ const inputRef = React29.useRef(null);
11435
+ const inputId = React29.useId();
11159
11436
  function handleDragOver(event) {
11160
11437
  event.preventDefault();
11161
11438
  setIsDragActive(true);
@@ -11174,7 +11451,7 @@ function MosaicDocumentUpload({
11174
11451
  if (selected.length > 0) onFilesSelected(selected);
11175
11452
  event.target.value = "";
11176
11453
  }
11177
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "document-upload", className: cn71("flex flex-col gap-4", className), children: [
11454
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "document-upload", className: cn73("flex flex-col gap-4", className), children: [
11178
11455
  /* @__PURE__ */ jsxRuntime.jsxs(
11179
11456
  "div",
11180
11457
  {
@@ -11239,7 +11516,7 @@ function MosaicDocumentUpload({
11239
11516
  "aria-valuemin": 0,
11240
11517
  "aria-valuemax": 100,
11241
11518
  "aria-valuenow": file.progress ?? 0,
11242
- className: cn71(documentUploadProgressTrackVariants(), "mt-2"),
11519
+ className: cn73(documentUploadProgressTrackVariants(), "mt-2"),
11243
11520
  children: /* @__PURE__ */ jsxRuntime.jsx(
11244
11521
  "div",
11245
11522
  {
@@ -11316,7 +11593,7 @@ var urlScraperCardVariants = classVarianceAuthority.cva(["flex flex-col gap-2 ro
11316
11593
  tone: "neutral"
11317
11594
  }
11318
11595
  });
11319
- function cn72(...classes) {
11596
+ function cn74(...classes) {
11320
11597
  return classes.filter(Boolean).join(" ");
11321
11598
  }
11322
11599
  function isSyntacticallyValidUrl(candidate) {
@@ -11339,7 +11616,7 @@ function MosaicUrlScraper(props) {
11339
11616
  className,
11340
11617
  ref
11341
11618
  } = props;
11342
- const [isLocallyInvalid, setIsLocallyInvalid] = React28.useState(false);
11619
+ const [isLocallyInvalid, setIsLocallyInvalid] = React29.useState(false);
11343
11620
  const isBusy = props.status === "loading" || props.status === "success";
11344
11621
  function handleSubmit(event) {
11345
11622
  event.preventDefault();
@@ -11355,7 +11632,7 @@ function MosaicUrlScraper(props) {
11355
11632
  setIsLocallyInvalid(false);
11356
11633
  onUrlChange(event.target.value);
11357
11634
  }
11358
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "url-scraper", className: cn72("flex flex-col gap-4", className), children: [
11635
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "url-scraper", className: cn74("flex flex-col gap-4", className), children: [
11359
11636
  /* @__PURE__ */ jsxRuntime.jsxs(
11360
11637
  "form",
11361
11638
  {
@@ -11491,7 +11768,7 @@ var chatThreadScrollButtonVariants = classVarianceAuthority.cva([
11491
11768
  "items-center justify-center rounded-full border border-border bg-card text-foreground shadow-sm",
11492
11769
  "transition-colors hover:bg-accent/50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
11493
11770
  ]);
11494
- function cn73(...classes) {
11771
+ function cn75(...classes) {
11495
11772
  return classes.filter(Boolean).join(" ");
11496
11773
  }
11497
11774
  var BOTTOM_THRESHOLD_PX = 24;
@@ -11505,9 +11782,9 @@ function MosaicChatThread({
11505
11782
  className,
11506
11783
  ref
11507
11784
  }) {
11508
- const containerRef = React28.useRef(null);
11509
- const isAtBottomRef = React28.useRef(true);
11510
- const [isAtBottom, setIsAtBottom] = React28.useState(true);
11785
+ const containerRef = React29.useRef(null);
11786
+ const isAtBottomRef = React29.useRef(true);
11787
+ const [isAtBottom, setIsAtBottom] = React29.useState(true);
11511
11788
  function setRefs(node) {
11512
11789
  containerRef.current = node;
11513
11790
  if (typeof ref === "function") {
@@ -11539,7 +11816,7 @@ function MosaicChatThread({
11539
11816
  disengageBottomAnchor();
11540
11817
  }
11541
11818
  }
11542
- React28.useEffect(() => {
11819
+ React29.useEffect(() => {
11543
11820
  function handleSelectionChange() {
11544
11821
  const container = containerRef.current;
11545
11822
  if (!container) {
@@ -11561,7 +11838,7 @@ function MosaicChatThread({
11561
11838
  document.removeEventListener("selectionchange", handleSelectionChange);
11562
11839
  };
11563
11840
  }, []);
11564
- React28.useLayoutEffect(() => {
11841
+ React29.useLayoutEffect(() => {
11565
11842
  const element = containerRef.current;
11566
11843
  if (element && isAtBottomRef.current) {
11567
11844
  element.scrollTop = element.scrollHeight;
@@ -11575,7 +11852,7 @@ function MosaicChatThread({
11575
11852
  role: "log",
11576
11853
  onScroll: handleScroll,
11577
11854
  onKeyDown: handleKeyDown,
11578
- className: cn73(chatThreadRootVariants(), className),
11855
+ className: cn75(chatThreadRootVariants(), className),
11579
11856
  children: [
11580
11857
  /* @__PURE__ */ jsxRuntime.jsx("div", { "data-slot": "chat-thread-content", className: chatThreadContentVariants(), children }),
11581
11858
  !isAtBottom && /* @__PURE__ */ jsxRuntime.jsx(
@@ -11616,7 +11893,7 @@ var chatComposerActionButtonVariants = classVarianceAuthority.cva(
11616
11893
  }
11617
11894
  }
11618
11895
  );
11619
- function cn74(...classes) {
11896
+ function cn76(...classes) {
11620
11897
  return classes.filter(Boolean).join(" ");
11621
11898
  }
11622
11899
  function MosaicChatComposer(props) {
@@ -11629,9 +11906,9 @@ function MosaicChatComposer(props) {
11629
11906
  className,
11630
11907
  ref
11631
11908
  } = props;
11632
- const textareaRef = React28.useRef(null);
11909
+ const textareaRef = React29.useRef(null);
11633
11910
  const trimmedValue = value.trim();
11634
- React28.useEffect(() => {
11911
+ React29.useEffect(() => {
11635
11912
  const textarea = textareaRef.current;
11636
11913
  if (!textarea) {
11637
11914
  return;
@@ -11639,7 +11916,7 @@ function MosaicChatComposer(props) {
11639
11916
  textarea.style.height = "auto";
11640
11917
  textarea.style.height = `${textarea.scrollHeight}px`;
11641
11918
  }, [value]);
11642
- const submitValue = React28.useCallback(() => {
11919
+ const submitValue = React29.useCallback(() => {
11643
11920
  if (props.status !== "idle") {
11644
11921
  return;
11645
11922
  }
@@ -11649,14 +11926,14 @@ function MosaicChatComposer(props) {
11649
11926
  }
11650
11927
  props.onSubmit(text);
11651
11928
  }, [disabled, props, value]);
11652
- const handleSubmit = React28.useCallback(
11929
+ const handleSubmit = React29.useCallback(
11653
11930
  (event) => {
11654
11931
  event.preventDefault();
11655
11932
  submitValue();
11656
11933
  },
11657
11934
  [submitValue]
11658
11935
  );
11659
- const handleKeyDown = React28.useCallback(
11936
+ const handleKeyDown = React29.useCallback(
11660
11937
  (event) => {
11661
11938
  if (event.key === "Enter" && !event.shiftKey) {
11662
11939
  event.preventDefault();
@@ -11671,7 +11948,7 @@ function MosaicChatComposer(props) {
11671
11948
  {
11672
11949
  ref,
11673
11950
  "data-slot": "chat-composer",
11674
- className: cn74(chatComposerRootVariants(), className),
11951
+ className: cn76(chatComposerRootVariants(), className),
11675
11952
  onSubmit: handleSubmit,
11676
11953
  children: [
11677
11954
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -11787,7 +12064,7 @@ var markdownTableCellVariants = classVarianceAuthority.cva(["border border-borde
11787
12064
  align: "left"
11788
12065
  }
11789
12066
  });
11790
- function cn75(...classes) {
12067
+ function cn77(...classes) {
11791
12068
  return classes.filter(Boolean).join(" ");
11792
12069
  }
11793
12070
  function sanitizeHref(rawHref) {
@@ -11982,7 +12259,7 @@ function parseBlocks(content) {
11982
12259
  function MosaicMarkdown({ content, renderCodeBlock, className, ref }) {
11983
12260
  const blocks = parseBlocks(content);
11984
12261
  const ids = makeIdSource();
11985
- return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, "data-slot": "markdown", className: cn75(markdownRootVariants(), className), children: blocks.map((block) => {
12262
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, "data-slot": "markdown", className: cn77(markdownRootVariants(), className), children: blocks.map((block) => {
11986
12263
  if (block.kind === "heading") {
11987
12264
  const HeadingTag = `h${block.level}`;
11988
12265
  return /* @__PURE__ */ jsxRuntime.jsx(HeadingTag, { className: markdownHeadingVariants({ level: block.level }), children: parseInline(block.text, ids) }, block.id);
@@ -12060,11 +12337,13 @@ var chatMessageToolStatusVariants = classVarianceAuthority.cva(["text-xs font-me
12060
12337
  status: "running"
12061
12338
  }
12062
12339
  });
12063
- function cn76(...classes) {
12340
+ function cn78(...classes) {
12064
12341
  return classes.filter(Boolean).join(" ");
12065
12342
  }
12066
12343
  function partKey(part, index) {
12067
- return part.type === "tool" ? part.toolCallId : `${part.type}:${index}`;
12344
+ if (part.type === "tool") return part.toolCallId;
12345
+ if (part.type === "attachment") return part.attachmentId;
12346
+ return `${part.type}:${index}`;
12068
12347
  }
12069
12348
  function toolStatusOf(part) {
12070
12349
  switch (part.state) {
@@ -12166,6 +12445,21 @@ function ChatMessageToolPartView({
12166
12445
  )
12167
12446
  ] });
12168
12447
  }
12448
+ function ChatMessageAttachmentPartView({ part }) {
12449
+ return /* @__PURE__ */ jsxRuntime.jsx(
12450
+ "div",
12451
+ {
12452
+ "data-slot": "chat-message-attachment",
12453
+ "data-attachment-id": part.attachmentId,
12454
+ "data-attachment-filename": part.fileName,
12455
+ "data-attachment-mimetype": part.mimeType,
12456
+ "data-attachment-size": part.sizeBytes,
12457
+ "data-attachment-url": part.url,
12458
+ className: "my-2",
12459
+ children: part.renderAttachment(part)
12460
+ }
12461
+ );
12462
+ }
12169
12463
  function ChatMessagePartView({
12170
12464
  part,
12171
12465
  renderText,
@@ -12188,6 +12482,8 @@ function ChatMessagePartView({
12188
12482
  );
12189
12483
  case "tool":
12190
12484
  return /* @__PURE__ */ jsxRuntime.jsx(ChatMessageToolPartView, { part, toolStatusLabels });
12485
+ case "attachment":
12486
+ return /* @__PURE__ */ jsxRuntime.jsx(ChatMessageAttachmentPartView, { part });
12191
12487
  }
12192
12488
  }
12193
12489
  function MosaicChatMessage({
@@ -12207,7 +12503,7 @@ function MosaicChatMessage({
12207
12503
  ref,
12208
12504
  "data-slot": "chat-message",
12209
12505
  "data-role": messageRole,
12210
- className: cn76(chatMessageContainerVariants({ align: isUser ? "end" : "start" }), className),
12506
+ className: cn78(chatMessageContainerVariants({ align: isUser ? "end" : "start" }), className),
12211
12507
  children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: chatMessageBubbleVariants({ role: messageRole }), children: parts.map((part, index) => /* @__PURE__ */ jsxRuntime.jsx(
12212
12508
  ChatMessagePartView,
12213
12509
  {
@@ -12262,7 +12558,7 @@ var approvalPromptButtonVariants = classVarianceAuthority.cva(
12262
12558
  }
12263
12559
  }
12264
12560
  );
12265
- function cn77(...classes) {
12561
+ function cn79(...classes) {
12266
12562
  return classes.filter(Boolean).join(" ");
12267
12563
  }
12268
12564
  function MosaicApprovalPrompt(props) {
@@ -12274,7 +12570,7 @@ function MosaicApprovalPrompt(props) {
12274
12570
  ref,
12275
12571
  "data-slot": "approval-prompt",
12276
12572
  "aria-label": promptTitle,
12277
- className: cn77("border-0 p-0 m-0", approvalPromptCardVariants({ tone }), className),
12573
+ className: cn79("border-0 p-0 m-0", approvalPromptCardVariants({ tone }), className),
12278
12574
  children: [
12279
12575
  /* @__PURE__ */ jsxRuntime.jsx("legend", { "data-slot": "approval-prompt-title", className: "text-base font-semibold md:text-lg", children: promptTitle }),
12280
12576
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "approval-prompt-tool", className: "flex flex-col gap-1", children: [
@@ -12351,7 +12647,7 @@ var toolToggleListRowVariants = classVarianceAuthority.cva(
12351
12647
  }
12352
12648
  }
12353
12649
  );
12354
- function cn78(...classes) {
12650
+ function cn80(...classes) {
12355
12651
  return classes.filter(Boolean).join(" ");
12356
12652
  }
12357
12653
  function MosaicToolToggleList({
@@ -12367,7 +12663,7 @@ function MosaicToolToggleList({
12367
12663
  }) {
12368
12664
  const toolsById = new Map(tools.map((tool) => [tool.id, tool]));
12369
12665
  const approvalLabelById = new Map(approvalLevels.map((level) => [level.id, level.label]));
12370
- return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, "data-slot": "tool-toggle-list", className: cn78("flex flex-col gap-6", className), children: sections.map((section) => /* @__PURE__ */ jsxRuntime.jsxs(
12666
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { ref, "data-slot": "tool-toggle-list", className: cn80("flex flex-col gap-6", className), children: sections.map((section) => /* @__PURE__ */ jsxRuntime.jsxs(
12371
12667
  "div",
12372
12668
  {
12373
12669
  "data-slot": "tool-toggle-list-section",
@@ -12398,7 +12694,7 @@ function MosaicToolToggleList({
12398
12694
  onCheckedChange: (checked) => onToggleTool(tool.id, checked),
12399
12695
  "aria-label": toggleAriaLabel(tool.name),
12400
12696
  "data-slot": "tool-toggle-list-switch",
12401
- className: cn78(
12697
+ className: cn80(
12402
12698
  "relative inline-flex h-6 w-10 shrink-0 cursor-pointer items-center",
12403
12699
  "rounded-full border-2 border-transparent outline-none",
12404
12700
  "bg-muted transition-colors",
@@ -12409,7 +12705,7 @@ function MosaicToolToggleList({
12409
12705
  _switch.Switch.Thumb,
12410
12706
  {
12411
12707
  "data-slot": "tool-toggle-list-switch-thumb",
12412
- className: cn78(
12708
+ className: cn80(
12413
12709
  "pointer-events-none block h-4 w-4 rounded-full",
12414
12710
  "bg-background shadow-sm",
12415
12711
  "translate-x-0 transition-transform",
@@ -12451,7 +12747,7 @@ function MosaicToolToggleList({
12451
12747
  {
12452
12748
  "aria-label": approvalSelectAriaLabel(tool.name),
12453
12749
  "data-slot": "tool-toggle-list-approval-trigger",
12454
- className: cn78(
12750
+ className: cn80(
12455
12751
  "inline-flex h-9 min-w-[10rem] items-center justify-between gap-2",
12456
12752
  "rounded-md border border-border bg-background px-3 py-2",
12457
12753
  "text-sm text-foreground shadow-xs outline-none",
@@ -12469,7 +12765,7 @@ function MosaicToolToggleList({
12469
12765
  select.Select.Popup,
12470
12766
  {
12471
12767
  "data-slot": "tool-toggle-list-approval-popup",
12472
- className: cn78(
12768
+ className: cn80(
12473
12769
  "z-50 min-w-[10rem] overflow-hidden rounded-md border border-border",
12474
12770
  "bg-popover p-1 text-popover-foreground shadow-md",
12475
12771
  "origin-[var(--transform-origin)]",
@@ -12482,7 +12778,7 @@ function MosaicToolToggleList({
12482
12778
  select.Select.Item,
12483
12779
  {
12484
12780
  value: level.id,
12485
- className: cn78(
12781
+ className: cn80(
12486
12782
  "relative flex cursor-pointer select-none items-center rounded-sm px-2 py-1.5",
12487
12783
  "text-sm text-popover-foreground outline-none",
12488
12784
  "data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground",
@@ -12590,7 +12886,7 @@ var apiKeyPanelMessageVariants = classVarianceAuthority.cva(["text-sm"], {
12590
12886
  tone: "muted"
12591
12887
  }
12592
12888
  });
12593
- function cn79(...classes) {
12889
+ function cn81(...classes) {
12594
12890
  return classes.filter(Boolean).join(" ");
12595
12891
  }
12596
12892
  function MosaicApiKeyPanel(props) {
@@ -12618,7 +12914,7 @@ function MosaicApiKeyPanel(props) {
12618
12914
  function handleKeyChange(event) {
12619
12915
  onKeyChange(event.target.value);
12620
12916
  }
12621
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "api-key-panel", className: cn79("flex flex-col gap-3", className), children: [
12917
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "api-key-panel", className: cn81("flex flex-col gap-3", className), children: [
12622
12918
  /* @__PURE__ */ jsxRuntime.jsx(
12623
12919
  "div",
12624
12920
  {
@@ -12713,7 +13009,7 @@ MosaicApiKeyPanel.displayName = "MosaicApiKeyPanel";
12713
13009
  var agentChatRootVariants = classVarianceAuthority.cva([
12714
13010
  "flex min-h-0 w-full flex-1 flex-col gap-2 overflow-hidden rounded-lg border border-border bg-card"
12715
13011
  ]);
12716
- function cn80(...classes) {
13012
+ function cn82(...classes) {
12717
13013
  return classes.filter(Boolean).join(" ");
12718
13014
  }
12719
13015
  function formatPayload2(value) {
@@ -12833,9 +13129,9 @@ function MosaicAgentChat(props) {
12833
13129
  className,
12834
13130
  ref
12835
13131
  } = props;
12836
- const [decisions, setDecisions] = React28.useState({});
12837
- const resumedSessionIdRef = React28.useRef(void 0);
12838
- React28.useEffect(() => {
13132
+ const [decisions, setDecisions] = React29.useState({});
13133
+ const resumedSessionIdRef = React29.useRef(void 0);
13134
+ React29.useEffect(() => {
12839
13135
  if (!sessionId || !onResumeSession) {
12840
13136
  return;
12841
13137
  }
@@ -12849,7 +13145,7 @@ function MosaicAgentChat(props) {
12849
13145
  setDecisions((previous) => ({ ...previous, [payload.requestId]: decision }));
12850
13146
  onApprovalResponse(payload);
12851
13147
  }
12852
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "agent-chat", className: cn80(agentChatRootVariants(), className), children: [
13148
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "agent-chat", className: cn82(agentChatRootVariants(), className), children: [
12853
13149
  /* @__PURE__ */ jsxRuntime.jsx(MosaicChatThread, { scrollToBottomLabel, children: messages.map((message) => /* @__PURE__ */ jsxRuntime.jsx(
12854
13150
  MosaicChatMessage,
12855
13151
  {
@@ -12938,7 +13234,7 @@ var toastProviderPositionVariants = classVarianceAuthority.cva(
12938
13234
  }
12939
13235
  }
12940
13236
  );
12941
- function cn81(...classes) {
13237
+ function cn83(...classes) {
12942
13238
  return classes.filter(Boolean).join(" ");
12943
13239
  }
12944
13240
  function MosaicToast({
@@ -12952,7 +13248,7 @@ function MosaicToast({
12952
13248
  className,
12953
13249
  ref
12954
13250
  }) {
12955
- React28.useEffect(() => {
13251
+ React29.useEffect(() => {
12956
13252
  if (durationMs === void 0) return;
12957
13253
  const timer = setTimeout(onDismiss, durationMs);
12958
13254
  return () => clearTimeout(timer);
@@ -12964,7 +13260,7 @@ function MosaicToast({
12964
13260
  ref,
12965
13261
  "data-slot": "toast",
12966
13262
  role,
12967
- className: cn81(toastCardVariants({ variant }), className),
13263
+ className: cn83(toastCardVariants({ variant }), className),
12968
13264
  children: [
12969
13265
  /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "toast-body", className: "flex min-w-0 flex-1 flex-col gap-1", children: [
12970
13266
  /* @__PURE__ */ jsxRuntime.jsx("p", { "data-slot": "toast-title", className: toastTitleVariants({ variant }), children: title }),
@@ -13004,7 +13300,7 @@ function MosaicToast({
13004
13300
  );
13005
13301
  }
13006
13302
  MosaicToast.displayName = "MosaicToast";
13007
- function cn82(...classes) {
13303
+ function cn84(...classes) {
13008
13304
  return classes.filter(Boolean).join(" ");
13009
13305
  }
13010
13306
  function MosaicToastProvider({
@@ -13018,7 +13314,7 @@ function MosaicToastProvider({
13018
13314
  {
13019
13315
  ref,
13020
13316
  "data-slot": "toast-provider",
13021
- className: cn82(toastProviderPositionVariants({ position }), className),
13317
+ className: cn84(toastProviderPositionVariants({ position }), className),
13022
13318
  children
13023
13319
  }
13024
13320
  );
@@ -13045,7 +13341,7 @@ var pdfViewerToolbarButtonVariants = classVarianceAuthority.cva([
13045
13341
  "inline-flex min-h-8 min-w-8 items-center justify-center rounded-md border border-border text-sm",
13046
13342
  "transition-colors hover:bg-accent/50 disabled:opacity-50 disabled:hover:bg-transparent"
13047
13343
  ]);
13048
- function cn83(...classes) {
13344
+ function cn85(...classes) {
13049
13345
  return classes.filter(Boolean).join(" ");
13050
13346
  }
13051
13347
  function buildFrameSrc(fileUrl, currentPage, zoom) {
@@ -13068,14 +13364,14 @@ function MosaicPdfViewer({
13068
13364
  className,
13069
13365
  ref
13070
13366
  }) {
13071
- const [status, setStatus] = React28.useState("loading");
13072
- const [trackedFileUrl, setTrackedFileUrl] = React28.useState(fileUrl);
13073
- const frameRef = React28.useRef(null);
13367
+ const [status, setStatus] = React29.useState("loading");
13368
+ const [trackedFileUrl, setTrackedFileUrl] = React29.useState(fileUrl);
13369
+ const frameRef = React29.useRef(null);
13074
13370
  if (fileUrl !== trackedFileUrl) {
13075
13371
  setTrackedFileUrl(fileUrl);
13076
13372
  setStatus("loading");
13077
13373
  }
13078
- React28.useEffect(() => {
13374
+ React29.useEffect(() => {
13079
13375
  const node = frameRef.current;
13080
13376
  if (!node) return;
13081
13377
  function handleLoad() {
@@ -13110,7 +13406,7 @@ function MosaicPdfViewer({
13110
13406
  if (zoom === void 0 || onZoomChange === void 0) return;
13111
13407
  onZoomChange(Math.round((zoom + 0.1) * 100) / 100);
13112
13408
  }
13113
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "pdf-viewer", className: cn83("flex flex-col gap-2", className), children: [
13409
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref, "data-slot": "pdf-viewer", className: cn85("flex flex-col gap-2", className), children: [
13114
13410
  (showPageControls || showZoomControls) && /* @__PURE__ */ jsxRuntime.jsxs(
13115
13411
  "div",
13116
13412
  {
@@ -13199,7 +13495,7 @@ function MosaicPdfViewer({
13199
13495
  "data-slot": "pdf-viewer-frame",
13200
13496
  src: buildFrameSrc(fileUrl, currentPage, zoom),
13201
13497
  title: fileUrl,
13202
- className: cn83(
13498
+ className: cn85(
13203
13499
  "h-full min-h-64 w-full border-0",
13204
13500
  status !== "loaded" && "pointer-events-none absolute inset-0 opacity-0"
13205
13501
  )
@@ -13218,7 +13514,7 @@ var splitPaneCollapseButtonVariants = classVarianceAuthority.cva([
13218
13514
  "inline-flex h-11 w-6 shrink-0 items-center justify-center self-center rounded-md border border-border text-sm",
13219
13515
  "transition-colors hover:bg-accent/50"
13220
13516
  ]);
13221
- function cn84(...classes) {
13517
+ function cn86(...classes) {
13222
13518
  return classes.filter(Boolean).join(" ");
13223
13519
  }
13224
13520
  function mergeRefs(externalRef, node) {
@@ -13247,9 +13543,9 @@ function MosaicResizableSplitPane({
13247
13543
  className,
13248
13544
  ref
13249
13545
  }) {
13250
- const rootRef = React28.useRef(null);
13251
- const isDraggingRef = React28.useRef(false);
13252
- React28.useEffect(() => {
13546
+ const rootRef = React29.useRef(null);
13547
+ const isDraggingRef = React29.useRef(false);
13548
+ React29.useEffect(() => {
13253
13549
  function handlePointerMove(event) {
13254
13550
  if (!isDraggingRef.current) return;
13255
13551
  const rootNode = rootRef.current;
@@ -13291,7 +13587,7 @@ function MosaicResizableSplitPane({
13291
13587
  mergeRefs(ref, node);
13292
13588
  },
13293
13589
  "data-slot": "resizable-split-pane",
13294
- className: cn84(splitPaneRootVariants(), className),
13590
+ className: cn86(splitPaneRootVariants(), className),
13295
13591
  children: [
13296
13592
  /* @__PURE__ */ jsxRuntime.jsx("div", { "data-slot": "resizable-split-pane-main", className: "min-h-0 min-w-0 flex-1 overflow-auto", children: main }),
13297
13593
  !isSideCollapsed && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
@@ -13358,7 +13654,7 @@ var tagInputFieldVariants = classVarianceAuthority.cva([
13358
13654
  "min-w-[6ch] flex-1 border-none bg-transparent px-1 py-0.5 text-sm text-foreground outline-none",
13359
13655
  "placeholder:text-muted-foreground"
13360
13656
  ]);
13361
- function cn85(...classes) {
13657
+ function cn87(...classes) {
13362
13658
  return classes.filter(Boolean).join(" ");
13363
13659
  }
13364
13660
  function mergeRefs2(externalRef, node) {
@@ -13379,12 +13675,12 @@ function MosaicTagInput({
13379
13675
  className,
13380
13676
  ref
13381
13677
  }) {
13382
- const [inputValue, setInputValue] = React28.useState("");
13383
- const inputRef = React28.useRef(null);
13678
+ const [inputValue, setInputValue] = React29.useState("");
13679
+ const inputRef = React29.useRef(null);
13384
13680
  const filter = combobox.Combobox.useFilter({ sensitivity: "base" });
13385
13681
  const isMaxReached = maxTags !== void 0 && tags.length >= maxTags;
13386
13682
  const trimmedValue = inputValue.trim();
13387
- const filteredSuggestions = React28.useMemo(() => {
13683
+ const filteredSuggestions = React29.useMemo(() => {
13388
13684
  if (!suggestions || trimmedValue.length === 0) return [];
13389
13685
  return suggestions.filter(
13390
13686
  (suggestion) => !tags.includes(suggestion) && filter.contains(suggestion, trimmedValue)
@@ -13409,7 +13705,7 @@ function MosaicTagInput({
13409
13705
  if (lastTag !== void 0) onRemoveTag(lastTag);
13410
13706
  }
13411
13707
  }
13412
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "tag-input", className: cn85(tagInputRootVariants(), className), children: [
13708
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-slot": "tag-input", className: cn87(tagInputRootVariants(), className), children: [
13413
13709
  tags.map((tag) => /* @__PURE__ */ jsxRuntime.jsxs("span", { "data-slot": "tag-input-tag", className: tagInputTagVariants(), children: [
13414
13710
  tag,
13415
13711
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -13446,7 +13742,7 @@ function MosaicTagInput({
13446
13742
  "ul",
13447
13743
  {
13448
13744
  "data-slot": "tag-input-suggestions",
13449
- className: cn85(
13745
+ className: cn87(
13450
13746
  "z-50 mt-1 w-full min-w-[8rem] overflow-hidden rounded-md border border-border",
13451
13747
  "bg-popover p-1 text-sm text-popover-foreground shadow-md"
13452
13748
  ),
@@ -13465,6 +13761,96 @@ function MosaicTagInput({
13465
13761
  ] });
13466
13762
  }
13467
13763
  MosaicTagInput.displayName = "MosaicTagInput";
13764
+ var drawerPopupVariants = classVarianceAuthority.cva(
13765
+ [
13766
+ "fixed z-50 flex flex-col bg-background shadow-xl outline-none",
13767
+ "transition-transform duration-200 ease-out",
13768
+ "data-[ending-style]:transition-none"
13769
+ ],
13770
+ {
13771
+ variants: {
13772
+ side: {
13773
+ right: "inset-y-0 right-0 h-full w-3/4 border-l border-border sm:max-w-sm",
13774
+ left: "inset-y-0 left-0 h-full w-3/4 border-r border-border sm:max-w-sm",
13775
+ top: "inset-x-0 top-0 max-h-[80vh] w-full border-b border-border",
13776
+ bottom: "inset-x-0 bottom-0 max-h-[80vh] w-full border-t border-border"
13777
+ }
13778
+ },
13779
+ defaultVariants: {
13780
+ side: "right"
13781
+ }
13782
+ }
13783
+ );
13784
+ var drawerBackdropVariants = classVarianceAuthority.cva(["fixed inset-0 z-50 bg-black/50"]);
13785
+ function cn88(...classes) {
13786
+ return classes.filter(Boolean).join(" ");
13787
+ }
13788
+ function MosaicDrawer({
13789
+ open,
13790
+ onOpenChange,
13791
+ title,
13792
+ closeAriaLabel,
13793
+ children,
13794
+ side = "right",
13795
+ className
13796
+ }) {
13797
+ const titleId = React29__namespace.useId();
13798
+ return /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog.Root, { open, onOpenChange: (nextOpen) => onOpenChange(nextOpen), modal: true, children: /* @__PURE__ */ jsxRuntime.jsxs(dialog.Dialog.Portal, { children: [
13799
+ /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog.Backdrop, { "data-slot": "drawer-backdrop", className: drawerBackdropVariants() }),
13800
+ /* @__PURE__ */ jsxRuntime.jsxs(
13801
+ dialog.Dialog.Popup,
13802
+ {
13803
+ "data-slot": "drawer",
13804
+ "aria-labelledby": titleId,
13805
+ "aria-modal": "true",
13806
+ className: cn88(drawerPopupVariants({ side }), className),
13807
+ children: [
13808
+ /* @__PURE__ */ jsxRuntime.jsxs(
13809
+ "div",
13810
+ {
13811
+ "data-slot": "drawer-header",
13812
+ className: "flex items-center justify-between gap-4 border-b border-border p-4",
13813
+ children: [
13814
+ /* @__PURE__ */ jsxRuntime.jsx(dialog.Dialog.Title, { id: titleId, className: "text-base font-semibold text-foreground", children: title }),
13815
+ /* @__PURE__ */ jsxRuntime.jsx(
13816
+ dialog.Dialog.Close,
13817
+ {
13818
+ "aria-label": closeAriaLabel,
13819
+ className: cn88(
13820
+ "flex h-8 w-8 shrink-0 items-center justify-center rounded-md text-muted-foreground transition-colors",
13821
+ "hover:bg-muted hover:text-foreground",
13822
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
13823
+ ),
13824
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
13825
+ "svg",
13826
+ {
13827
+ width: "16",
13828
+ height: "16",
13829
+ viewBox: "0 0 24 24",
13830
+ fill: "none",
13831
+ stroke: "currentColor",
13832
+ strokeWidth: "2",
13833
+ strokeLinecap: "round",
13834
+ strokeLinejoin: "round",
13835
+ "aria-hidden": "true",
13836
+ children: [
13837
+ /* @__PURE__ */ jsxRuntime.jsx("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
13838
+ /* @__PURE__ */ jsxRuntime.jsx("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
13839
+ ]
13840
+ }
13841
+ )
13842
+ }
13843
+ )
13844
+ ]
13845
+ }
13846
+ ),
13847
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "min-h-0 flex-1 overflow-y-auto p-4", children })
13848
+ ]
13849
+ }
13850
+ )
13851
+ ] }) });
13852
+ }
13853
+ MosaicDrawer.displayName = "MosaicDrawer";
13468
13854
 
13469
13855
  Object.defineProperty(exports, "Accordion", {
13470
13856
  enumerable: true,
@@ -13525,6 +13911,7 @@ exports.MosaicDataTable = MosaicDataTable;
13525
13911
  exports.MosaicDeleteConfirmationDialog = MosaicDeleteConfirmationDialog;
13526
13912
  exports.MosaicDeviceProvider = MosaicDeviceProvider;
13527
13913
  exports.MosaicDocumentUpload = MosaicDocumentUpload;
13914
+ exports.MosaicDrawer = MosaicDrawer;
13528
13915
  exports.MosaicDropdownMenu = MosaicDropdownMenu;
13529
13916
  exports.MosaicEmptyState = MosaicEmptyState;
13530
13917
  exports.MosaicFallingPattern = MosaicFallingPattern;
@@ -13557,6 +13944,7 @@ exports.MosaicMessageCard = MosaicMessageCard;
13557
13944
  exports.MosaicMessageList = MosaicMessageList;
13558
13945
  exports.MosaicMessageListDesktop = MessageListDesktop;
13559
13946
  exports.MosaicMessageListMobile = MessageListMobile;
13947
+ exports.MosaicModelSelector = MosaicModelSelector;
13560
13948
  exports.MosaicModuleCard = MosaicModuleCard;
13561
13949
  exports.MosaicModuleForm = MosaicModuleForm;
13562
13950
  exports.MosaicModuleLibrary = MosaicModuleLibrary;
@@ -13595,6 +13983,7 @@ exports.MosaicTabsList = MosaicTabsList;
13595
13983
  exports.MosaicTabsPanel = MosaicTabsPanel;
13596
13984
  exports.MosaicTabsTrigger = MosaicTabsTrigger;
13597
13985
  exports.MosaicTagInput = MosaicTagInput;
13986
+ exports.MosaicTemplateAgentCard = MosaicTemplateAgentCard;
13598
13987
  exports.MosaicTemplateCard = MosaicTemplateCard;
13599
13988
  exports.MosaicTemplateGallery = MosaicTemplateGallery;
13600
13989
  exports.MosaicTemplatePreview = MosaicTemplatePreview;
@@ -13619,6 +14008,8 @@ exports.buttonVariants = buttonVariants;
13619
14008
  exports.chatMessageBubbleVariants = chatMessageBubbleVariants;
13620
14009
  exports.chatMessageContainerVariants = chatMessageContainerVariants;
13621
14010
  exports.chatMessageToolStatusVariants = chatMessageToolStatusVariants;
14011
+ exports.drawerBackdropVariants = drawerBackdropVariants;
14012
+ exports.drawerPopupVariants = drawerPopupVariants;
13622
14013
  exports.pdfViewerFrameVariants = pdfViewerFrameVariants;
13623
14014
  exports.pdfViewerStatusVariants = pdfViewerStatusVariants;
13624
14015
  exports.pdfViewerToolbarButtonVariants = pdfViewerToolbarButtonVariants;
@@ -13630,6 +14021,9 @@ exports.tagInputFieldVariants = tagInputFieldVariants;
13630
14021
  exports.tagInputRemoveButtonVariants = tagInputRemoveButtonVariants;
13631
14022
  exports.tagInputRootVariants = tagInputRootVariants;
13632
14023
  exports.tagInputTagVariants = tagInputTagVariants;
14024
+ exports.templateAgentCardBadgeVariants = templateAgentCardBadgeVariants;
14025
+ exports.templateAgentCardTagVariants = templateAgentCardTagVariants;
14026
+ exports.templateAgentCardVariants = templateAgentCardVariants;
13633
14027
  exports.toastCardVariants = toastCardVariants;
13634
14028
  exports.toastDismissButtonVariants = toastDismissButtonVariants;
13635
14029
  exports.toastProviderPositionVariants = toastProviderPositionVariants;