@keboola/design 2.1.0 → 3.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,12 +2,14 @@
2
2
 
3
3
  var clsx = require('clsx');
4
4
  var tailwindMerge = require('tailwind-merge');
5
+ var react = require('react');
6
+ var brandRegistry = require('@keboola/brand-registry');
5
7
  var reactTooltip = require('@radix-ui/react-tooltip');
6
8
  var classVarianceAuthority = require('class-variance-authority');
7
9
  var jsxRuntime = require('react/jsx-runtime');
8
- var react = require('react');
9
- var lucideReact = require('lucide-react');
10
+ var lucide_react_star = require('lucide-react');
10
11
  var reactSlot = require('@radix-ui/react-slot');
12
+ var DOMPurify = require('dompurify');
11
13
  var beautifulMermaid = require('beautiful-mermaid');
12
14
  var colors = require('@keboola/tailwind-config/colors');
13
15
  var code = require('@lexical/code');
@@ -32,7 +34,6 @@ var richText = require('@lexical/rich-text');
32
34
  var lexical = require('lexical');
33
35
  var LexicalComposerContext = require('@lexical/react/LexicalComposerContext');
34
36
  var sonner = require('sonner');
35
- var reactFontawesome = require('@fortawesome/react-fontawesome');
36
37
  var reactDom = require('react-dom');
37
38
  var utils = require('@lexical/utils');
38
39
  var DropdownMenuPrimitive3 = require('@radix-ui/react-dropdown-menu');
@@ -60,6 +61,8 @@ function _interopNamespace(e) {
60
61
  return Object.freeze(n);
61
62
  }
62
63
 
64
+ var lucide_react_star__namespace = /*#__PURE__*/_interopNamespace(lucide_react_star);
65
+ var DOMPurify__default = /*#__PURE__*/_interopDefault(DOMPurify);
63
66
  var colors__default = /*#__PURE__*/_interopDefault(colors);
64
67
  var DropdownMenuPrimitive3__namespace = /*#__PURE__*/_interopNamespace(DropdownMenuPrimitive3);
65
68
  var ScrollAreaPrimitive2__namespace = /*#__PURE__*/_interopNamespace(ScrollAreaPrimitive2);
@@ -67,7 +70,9 @@ var TextareaAutosize__default = /*#__PURE__*/_interopDefault(TextareaAutosize);
67
70
  var RLabel__namespace = /*#__PURE__*/_interopNamespace(RLabel);
68
71
 
69
72
  var __defProp = Object.defineProperty;
73
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
70
74
  var __getOwnPropNames = Object.getOwnPropertyNames;
75
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
71
76
  var __esm = (fn, res) => function __init() {
72
77
  return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
73
78
  };
@@ -75,6 +80,15 @@ var __export = (target, all) => {
75
80
  for (var name in all)
76
81
  __defProp(target, name, { get: all[name], enumerable: true });
77
82
  };
83
+ var __copyProps = (to, from, except, desc) => {
84
+ if (from && typeof from === "object" || typeof from === "function") {
85
+ for (let key of __getOwnPropNames(from))
86
+ if (!__hasOwnProp.call(to, key) && key !== except)
87
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
88
+ }
89
+ return to;
90
+ };
91
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget);
78
92
  var twMerge, cn;
79
93
  var init_classNames = __esm({
80
94
  "src/utils/classNames.ts"() {
@@ -143,20 +157,62 @@ var init_keyCodes = __esm({
143
157
  };
144
158
  }
145
159
  });
160
+ var ThemeContext;
161
+ var init_themeContext = __esm({
162
+ "src/components/ThemeProvider/themeContext.ts"() {
163
+ ThemeContext = react.createContext(null);
164
+ }
165
+ });
166
+ var useIsLegacyBrand;
167
+ var init_useIsLegacyBrand = __esm({
168
+ "src/components/internal/useIsLegacyBrand.ts"() {
169
+ init_themeContext();
170
+ useIsLegacyBrand = () => {
171
+ const context = react.use(ThemeContext);
172
+ return context === null || context.brand.id === brandRegistry.keboolaLegacy.id;
173
+ };
174
+ }
175
+ });
146
176
  var tooltipVariants, TooltipContent;
147
177
  var init_TooltipContent = __esm({
148
178
  "src/components/Tooltip/TooltipContent.tsx"() {
179
+ init_useIsLegacyBrand();
149
180
  tooltipVariants = classVarianceAuthority.cva(
150
181
  [
151
182
  "tailwindcss-preflight",
152
183
  "tw-inline-block",
153
- "tw-rounded",
154
- "tw-bg-neutral-800",
155
- "tw-text-white",
156
184
  "tw-break-anywhere",
157
185
  "tw-max-h-96",
158
186
  "tw-overflow-y-auto",
159
- "tw-z-[1060]"
187
+ "tw-z-[1060]",
188
+ // legacy (dark) chrome — default
189
+ "tw-rounded",
190
+ "tw-bg-neutral-800",
191
+ "tw-text-white",
192
+ // argo chrome overrides — semantic floating-panel tokens
193
+ "data-[argo=true]:tw-rounded-2xl",
194
+ "data-[argo=true]:tw-border",
195
+ "data-[argo=true]:tw-border-solid",
196
+ "data-[argo=true]:tw-border-border",
197
+ "data-[argo=true]:tw-bg-popover",
198
+ "data-[argo=true]:tw-text-popover-foreground",
199
+ "data-[argo=true]:tw-shadow-md",
200
+ // argo open animation
201
+ "data-[argo=true]:data-[state=delayed-open]:tw-animate-in",
202
+ "data-[argo=true]:data-[state=instant-open]:tw-animate-in",
203
+ "data-[argo=true]:data-[state=delayed-open]:tw-fade-in-0",
204
+ "data-[argo=true]:data-[state=instant-open]:tw-fade-in-0",
205
+ "data-[argo=true]:data-[state=delayed-open]:tw-zoom-in-95",
206
+ "data-[argo=true]:data-[state=instant-open]:tw-zoom-in-95",
207
+ // argo closed animation
208
+ "data-[argo=true]:data-[state=closed]:tw-animate-out",
209
+ "data-[argo=true]:data-[state=closed]:tw-fade-out-0",
210
+ "data-[argo=true]:data-[state=closed]:tw-zoom-out-95",
211
+ // argo position animation
212
+ "data-[argo=true]:data-[side=bottom]:tw-slide-in-from-top-2",
213
+ "data-[argo=true]:data-[side=left]:tw-slide-in-from-right-2",
214
+ "data-[argo=true]:data-[side=right]:tw-slide-in-from-left-2",
215
+ "data-[argo=true]:data-[side=top]:tw-slide-in-from-bottom-2"
160
216
  ],
161
217
  {
162
218
  defaultVariants: {
@@ -189,6 +245,7 @@ var init_TooltipContent = __esm({
189
245
  TooltipContent = ({
190
246
  className,
191
247
  variant,
248
+ argo,
192
249
  keepOpenOnPointerDownOutside = false,
193
250
  children,
194
251
  onPointerDownOutside,
@@ -198,6 +255,8 @@ var init_TooltipContent = __esm({
198
255
  placement = "right",
199
256
  ...rest
200
257
  }) => {
258
+ const isLegacy = useIsLegacyBrand();
259
+ const renderArgo = !isLegacy || argo === true;
201
260
  const handlePointerDownOutside = (event) => {
202
261
  if (keepOpenOnPointerDownOutside) event.preventDefault();
203
262
  onPointerDownOutside?.(event);
@@ -206,7 +265,8 @@ var init_TooltipContent = __esm({
206
265
  reactTooltip.Content,
207
266
  {
208
267
  ...rest,
209
- "data-tooltip-content": true,
268
+ "data-tooltip-content": renderArgo ? void 0 : true,
269
+ "data-argo": renderArgo,
210
270
  sideOffset,
211
271
  collisionPadding,
212
272
  onPointerDownOutside: handlePointerDownOutside,
@@ -285,6 +345,7 @@ var init_Tooltip = __esm({
285
345
  className,
286
346
  keepOpenOnTriggerClick = false,
287
347
  variant,
348
+ argo,
288
349
  placement = "right",
289
350
  forceHide = false,
290
351
  forceShow = false,
@@ -323,6 +384,7 @@ var init_Tooltip = __esm({
323
384
  {
324
385
  className,
325
386
  variant: resolvedVariant,
387
+ argo,
326
388
  placement,
327
389
  keepOpenOnPointerDownOutside: keepOpenOnTriggerClick,
328
390
  children: tooltip
@@ -450,7 +512,7 @@ var init_Skeleton = __esm({
450
512
  "tw-relative",
451
513
  "tw-overflow-hidden",
452
514
  "tw-pointer-events-none",
453
- "tw-bg-neutral-150",
515
+ "tw-bg-muted",
454
516
  // before
455
517
  'before:tw-content-[""]',
456
518
  "before:tw-opacity-100",
@@ -477,8 +539,42 @@ var init_Skeleton = __esm({
477
539
  };
478
540
  }
479
541
  });
542
+ var Keboola;
543
+ var init_Keboola = __esm({
544
+ "src/icons/Keboola.tsx"() {
545
+ init_utils();
546
+ Keboola = react.forwardRef(
547
+ ({ size = 24, color = "currentColor", className, children, ...rest }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
548
+ "svg",
549
+ {
550
+ ref,
551
+ xmlns: "http://www.w3.org/2000/svg",
552
+ width: size,
553
+ height: size,
554
+ viewBox: "0 0 300 512",
555
+ fill: color,
556
+ className: cn("lucide", className),
557
+ ...rest,
558
+ children: [
559
+ /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M152 320C79.7 320 24.5 233.9 24.5 124.7C24.5 15.6 70.5 0 152 0s123.6 15.6 123.6 124.7C275.5 233.9 217.7 320 152 320zm-8.7-50.5c0-11.2-9.5-20.3-21.2-20.3s-21.2 9.1-21.2 20.3c0 11.2 9.5 20.3 21.2 20.3s21.2-9.1 21.2-20.3zm55.7 0c0-11.2-9.5-20.3-21.2-20.3s-21.2 9.1-21.2 20.3c0 11.2 9.5 20.3 21.2 20.3s21.2-9.1 21.2-20.3zm68.9 115.1c10.2 9.3 20.2 20.5 29 35c5.9 9.7 2.6 22.1-7.5 27.8c-3.4 1.9-7.1 2.8-10.7 2.8c-7.2 0-14.3-3.6-18.3-10c-6.8-11.1-13.8-18.9-21.7-26.1c-7.3-6.7-15.6-12.7-24.9-19.5c-.7-.5-1.4-1-2.1-1.5c-5-3.6-10-6.8-14.9-9.4c.6 1 1.2 2.1 1.8 3.2c14.4 26.4 29.2 63.1 29.2 104.9c0 11.2-9.5 20.3-21.2 20.3c-11.7 0-21.2-9.1-21.2-20.3c.1-31.8-11.6-62.3-23.8-84.9c-4-7.4-8-13.9-11.6-19.3c-3.4 5.2-7.2 11.3-11 18.3c-12.5 22.7-24.5 53.8-24.4 86c0 11.2-9.5 20.3-21.2 20.3s-21.2-9.1-21.2-20.3c.1-41.8 14.9-78.4 29.2-104.9c.6-1.1 1.2-2.1 1.8-3.2c-5 2.7-9.9 5.8-14.9 9.4c-.6 .5-1.3 .9-1.9 1.4c-9.5 6.9-17.8 12.9-25.1 19.7c-7.9 7.2-14.9 15.1-21.7 26.1c-5.9 9.7-18.9 12.9-29 7.2C.5 441.8-2.9 429.3 3.1 419.7c8.9-14.4 18.8-25.7 29-35c9.2-8.4 18.5-15.1 27.6-21.7c1-.7 2-1.4 3-2.2c4.7-3.5 9.6-6.7 14.6-9.6c-5-2.9-9.8-6.1-14.6-9.6C39.8 325 19.9 302.5 3.1 275.1c-5.9-9.7-2.6-22.1 7.5-27.8c10.1-5.7 23.1-2.5 29 7.2c14.6 23.7 31.1 42 48.7 54.9c18.9 13.7 37.4 20.5 56.5 21.5c1.7-.1 3.5-.1 5.2-.1c1.8 0 3.5 .1 5.2 .1c0 0 0 0 0 0c19.1-1.1 37.6-7.9 56.5-21.5c17.6-12.8 34.2-31.2 48.7-54.9c6-9.7 18.9-12.9 29-7.2c10.1 5.7 13.4 18.1 7.5 27.8c-16.8 27.4-36.7 49.9-59.6 66.6c-4.7 3.5-9.6 6.7-14.5 9.6c4.9 2.9 9.8 6.1 14.5 9.6c.9 .7 1.8 1.3 2.7 2c9.2 6.7 18.5 13.5 27.9 22z" }),
560
+ children
561
+ ]
562
+ }
563
+ )
564
+ );
565
+ Keboola.displayName = "Keboola";
566
+ }
567
+ });
568
+
569
+ // src/icons/index.ts
570
+ var icons_exports = {};
571
+ __export(icons_exports, {
572
+ Keboola: () => Keboola
573
+ });
480
574
  var init_icons = __esm({
481
575
  "src/icons/index.ts"() {
576
+ __reExport(icons_exports, lucide_react_star__namespace);
577
+ init_Keboola();
482
578
  }
483
579
  });
484
580
  var variants, argoVariants;
@@ -671,6 +767,8 @@ var init_styles = __esm({
671
767
  "tw-bg-clip-padding",
672
768
  // anchor support
673
769
  "!tw-no-underline",
770
+ "aria-disabled:tw-cursor-not-allowed",
771
+ "aria-disabled:tw-opacity-50",
674
772
  // icon
675
773
  "tw-shrink-0",
676
774
  "[&_svg]:tw-pointer-events-none",
@@ -765,6 +863,7 @@ var init_Button = __esm({
765
863
  "src/components/Button/Button.tsx"() {
766
864
  init_icons();
767
865
  init_utils();
866
+ init_useIsLegacyBrand();
768
867
  init_styles();
769
868
  Button = ({
770
869
  ref,
@@ -781,14 +880,11 @@ var init_Button = __esm({
781
880
  block = false,
782
881
  ...buttonProps
783
882
  }) => {
883
+ const isLegacy = useIsLegacyBrand();
884
+ const renderArgo = !isLegacy || argo;
784
885
  const Comp = asChild ? reactSlot.Root : "button";
785
886
  const isIconOnly = String(size).startsWith("icon");
786
- const classNames = argo ? argoVariants({ variant, size, block, className }) : variants({
787
- size,
788
- variant,
789
- block,
790
- className
791
- });
887
+ const classNames = renderArgo ? argoVariants({ variant, size, block, className }) : variants({ size, variant, block, className });
792
888
  const handleClick = (event) => {
793
889
  const isAnchor = event.currentTarget.tagName === "A";
794
890
  if (isAnchor && disabled) {
@@ -810,7 +906,7 @@ var init_Button = __esm({
810
906
  onClick: handleClick,
811
907
  className: cn(classNames),
812
908
  children: [
813
- isLoading && /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "tw-size-4 tw-shrink-0 tw-animate-spin" }),
909
+ isLoading && /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Loader2, { className: "tw-size-4 tw-shrink-0 tw-animate-spin" }),
814
910
  /* @__PURE__ */ jsxRuntime.jsx(reactSlot.Slottable, { children: isLoading && isIconOnly ? null : children })
815
911
  ]
816
912
  }
@@ -833,7 +929,7 @@ var init_ButtonInline = __esm({
833
929
  "disabled:tw-no-underline",
834
930
  "[&_svg]:disabled:tw-text-neutral-400",
835
931
  // Default size for nested Lucide icons; callers can override on the icon.
836
- "[&_svg:not([class*='tw-size-'])]:tw-size-4",
932
+ "[&_svg.lucide:not([class*='tw-size-'])]:tw-size-4",
837
933
  "[&_svg]:tw-shrink-0"
838
934
  ],
839
935
  {
@@ -843,11 +939,7 @@ var init_ButtonInline = __esm({
843
939
  },
844
940
  variants: {
845
941
  color: {
846
- link: [
847
- "tw-text-secondary-500",
848
- "hover:tw-text-secondary-600",
849
- "[&_svg]:tw-text-secondary-500"
850
- ],
942
+ link: ["tw-text-primary", "hover:tw-text-primary/90", "[&_svg]:tw-text-primary"],
851
943
  dark: ["tw-text-neutral-800 [&_svg]:tw-text-neutral-400"],
852
944
  danger: ["tw-text-error-500 [&_svg]:tw-text-error-500"],
853
945
  muted: ["tw-text-muted-foreground [&_svg]:tw-text-muted-foreground"],
@@ -954,7 +1046,7 @@ var init_ClipboardButton = __esm({
954
1046
  init_Button2();
955
1047
  init_Clipboard2();
956
1048
  init_icons();
957
- DEFAULT_ICON = /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Copy, {});
1049
+ DEFAULT_ICON = /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Copy, {});
958
1050
  ClipboardButton = ({
959
1051
  // clipboard props
960
1052
  text,
@@ -1001,6 +1093,10 @@ var init_ZoomableSvg = __esm({
1001
1093
  MAX_SCALE = 3;
1002
1094
  ZOOM_STEP = 0.1;
1003
1095
  ZoomableSvg = ({ html, copyText, className }) => {
1096
+ const safeHtml = react.useMemo(
1097
+ () => DOMPurify__default.default.sanitize(html, { USE_PROFILES: { svg: true, svgFilters: true } }),
1098
+ [html]
1099
+ );
1004
1100
  const containerRef = react.useRef(null);
1005
1101
  const [scale, setScale] = react.useState(1);
1006
1102
  const [translate, setTranslate] = react.useState({ x: 0, y: 0 });
@@ -1096,7 +1192,7 @@ var init_ZoomableSvg = __esm({
1096
1192
  isFullscreen && "tw-h-full [&>svg]:tw-h-full"
1097
1193
  ),
1098
1194
  style: { transform: `translate(${translate.x}px, ${translate.y}px) scale(${scale})` },
1099
- dangerouslySetInnerHTML: { __html: html }
1195
+ dangerouslySetInnerHTML: { __html: safeHtml }
1100
1196
  }
1101
1197
  )
1102
1198
  }
@@ -1133,7 +1229,7 @@ var init_ZoomableSvg = __esm({
1133
1229
  "aria-label": isFullscreen ? "Exit fullscreen" : "Fullscreen",
1134
1230
  onClick: () => setIsFullscreen((f) => !f),
1135
1231
  argo: true,
1136
- children: isFullscreen ? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Minimize2, { className: "tw-size-4" }) : /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Maximize2, { className: "tw-size-4" })
1232
+ children: isFullscreen ? /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Minimize2, { className: "tw-size-4" }) : /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Maximize2, { className: "tw-size-4" })
1137
1233
  }
1138
1234
  )
1139
1235
  }
@@ -1149,7 +1245,7 @@ var init_ZoomableSvg = __esm({
1149
1245
  "div",
1150
1246
  {
1151
1247
  role: "presentation",
1152
- className: "tw-fixed tw-inset-0 tw-z-[1060] tw-bg-neutral-50 tw-p-4",
1248
+ className: "tw-fixed tw-inset-0 tw-z-[1060] tw-bg-muted tw-p-4",
1153
1249
  onClick: stopPropagation,
1154
1250
  children: diagramContent
1155
1251
  }
@@ -1159,7 +1255,7 @@ var init_ZoomableSvg = __esm({
1159
1255
  "div",
1160
1256
  {
1161
1257
  className: cn(
1162
- "tw-overflow-hidden tw-rounded-md tw-border tw-border-neutral-150 tw-bg-neutral-50",
1258
+ "tw-overflow-hidden tw-rounded-md tw-border tw-border-border tw-bg-muted",
1163
1259
  className
1164
1260
  ),
1165
1261
  children: diagramContent
@@ -1181,12 +1277,17 @@ var MermaidDiagram_exports = {};
1181
1277
  __export(MermaidDiagram_exports, {
1182
1278
  MermaidDiagram: () => MermaidDiagram
1183
1279
  });
1184
- var mermaidPromise, getMermaid, stripFontImports, tryFastRender, makeResponsive, RENDER_DEBOUNCE_MS, svgCache, MermaidDiagram;
1280
+ var PRIMARY_FALLBACK_CHANNELS, resolvePrimary, mermaidPromise, getMermaid, stripFontImports, tryFastRender, makeResponsive, RENDER_DEBOUNCE_MS, svgCache, resolveSyncSvg, MermaidDiagram;
1185
1281
  var init_MermaidDiagram = __esm({
1186
1282
  "src/blocks/MermaidDiagram/MermaidDiagram.tsx"() {
1187
1283
  init_Skeleton();
1188
1284
  init_ZoomableSvg2();
1189
1285
  init_utils();
1286
+ PRIMARY_FALLBACK_CHANNELS = "31 143 255";
1287
+ resolvePrimary = () => {
1288
+ const channels = typeof document === "undefined" ? PRIMARY_FALLBACK_CHANNELS : getComputedStyle(document.documentElement).getPropertyValue("--color-primary").trim() || PRIMARY_FALLBACK_CHANNELS;
1289
+ return `rgb(${channels})`;
1290
+ };
1190
1291
  mermaidPromise = null;
1191
1292
  getMermaid = () => {
1192
1293
  if (!mermaidPromise) {
@@ -1235,7 +1336,7 @@ var init_MermaidDiagram = __esm({
1235
1336
  taskTextColor: colors__default.default.neutral[800],
1236
1337
  taskTextDarkColor: colors__default.default.neutral[800],
1237
1338
  taskTextLightColor: colors__default.default.neutral[800],
1238
- activeTaskBorderColor: colors__default.default.primary.DEFAULT,
1339
+ activeTaskBorderColor: resolvePrimary(),
1239
1340
  activeTaskBkgColor: colors__default.default.secondary[200],
1240
1341
  doneTaskBorderColor: colors__default.default.primary[600],
1241
1342
  doneTaskBkgColor: colors__default.default.primary[100],
@@ -1287,46 +1388,28 @@ var init_MermaidDiagram = __esm({
1287
1388
  };
1288
1389
  RENDER_DEBOUNCE_MS = 300;
1289
1390
  svgCache = /* @__PURE__ */ new Map();
1391
+ resolveSyncSvg = (code) => {
1392
+ const cached = svgCache.get(code);
1393
+ if (cached) return cached;
1394
+ const fast = tryFastRender(code);
1395
+ if (fast) svgCache.set(code, fast);
1396
+ return fast;
1397
+ };
1290
1398
  MermaidDiagram = ({ code }) => {
1291
1399
  const id = react.useId();
1292
- const [svg, setSvg] = react.useState(() => {
1293
- const cached = svgCache.get(code);
1294
- if (cached) return cached;
1295
- const fast = tryFastRender(code);
1296
- if (fast) {
1297
- svgCache.set(code, fast);
1298
- return fast;
1299
- }
1300
- return null;
1301
- });
1400
+ const [svg, setSvg] = react.useState(() => resolveSyncSvg(code));
1302
1401
  const [renderFailed, setRenderFailed] = react.useState(false);
1303
1402
  const debounceRef = react.useRef(null);
1304
1403
  const renderIdRef = react.useRef(0);
1305
1404
  const [prevCode, setPrevCode] = react.useState(code);
1306
1405
  if (code !== prevCode) {
1307
1406
  setPrevCode(code);
1308
- const cached = svgCache.get(code);
1309
- const fast = cached ?? tryFastRender(code);
1310
- if (fast && !cached) svgCache.set(code, fast);
1311
- setSvg(fast);
1407
+ setSvg(resolveSyncSvg(code));
1312
1408
  setRenderFailed(false);
1313
1409
  }
1314
1410
  react.useEffect(() => {
1315
- if (svgCache.has(code)) {
1316
- setSvg(svgCache.get(code));
1317
- setRenderFailed(false);
1318
- return;
1319
- }
1320
- const fastResult = tryFastRender(code);
1321
- if (fastResult) {
1322
- svgCache.set(code, fastResult);
1323
- setSvg(fastResult);
1324
- setRenderFailed(false);
1325
- return;
1326
- }
1327
- setSvg(null);
1411
+ if (svgCache.has(code)) return;
1328
1412
  const currentRenderId = ++renderIdRef.current;
1329
- setRenderFailed(false);
1330
1413
  if (debounceRef.current) {
1331
1414
  clearTimeout(debounceRef.current);
1332
1415
  }
@@ -1576,9 +1659,7 @@ init_utils();
1576
1659
  // src/components/Toast/ToastRoot.tsx
1577
1660
  init_icons();
1578
1661
  init_utils();
1579
- var Icon = ({ ref, icon, ...rest }) => /* @__PURE__ */ jsxRuntime.jsx(reactFontawesome.FontAwesomeIcon, { ...rest, ref, icon });
1580
- var isFAIconValue = (value) => typeof value === "string" || Array.isArray(value) && value.length === 2 && typeof value[0] === "string" && typeof value[1] === "string";
1581
- var renderLegacyIcon = (value) => isFAIconValue(value) ? /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: value }) : value;
1662
+ init_useIsLegacyBrand();
1582
1663
 
1583
1664
  // src/components/Toast/ToastAction.tsx
1584
1665
  init_utils();
@@ -1663,12 +1744,13 @@ var ToastDismiss = ({
1663
1744
  "[&_svg]:tw-m-1",
1664
1745
  "tw-text-white",
1665
1746
  "group-data-[variant=default]/toast:[&_svg]:tw-text-popover-foreground",
1747
+ "group-data-[variant=default]/toast:group-data-[argo=true]/toast:[&_svg]:tw-text-foreground",
1666
1748
  className
1667
1749
  ),
1668
1750
  type: "button",
1669
1751
  ...rest,
1670
1752
  children: [
1671
- /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, {}),
1753
+ /* @__PURE__ */ jsxRuntime.jsx(icons_exports.X, {}),
1672
1754
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-sr-only", children: "Dismiss" })
1673
1755
  ]
1674
1756
  }
@@ -1690,6 +1772,7 @@ var ToastDuration = ({
1690
1772
  className: cn(
1691
1773
  "tw-bg-white/30",
1692
1774
  "group-data-[variant=default]/toast:tw-bg-popover-foreground/20",
1775
+ "group-data-[variant=default]/toast:group-data-[argo=true]/toast:tw-bg-foreground/20",
1693
1776
  "tw-rounded-bl-lg",
1694
1777
  "tw-mx-px",
1695
1778
  // positioning
@@ -1730,6 +1813,7 @@ var ToastTitle = ({
1730
1813
  "tw-self-center",
1731
1814
  "tw-text-white",
1732
1815
  "group-data-[variant=default]/toast:tw-text-popover-foreground",
1816
+ "group-data-[variant=default]/toast:group-data-[argo=true]/toast:tw-text-foreground",
1733
1817
  "tw-break-words",
1734
1818
  "tw-font-medium",
1735
1819
  className
@@ -1776,10 +1860,10 @@ var variants2 = classVarianceAuthority.cva(
1776
1860
  }
1777
1861
  );
1778
1862
  var DEFAULT_VARIANT_ICON = {
1779
- error: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.AlertTriangle, {}),
1780
- info: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Info, {}),
1781
- success: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CircleCheck, {}),
1782
- warning: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.AlertCircle, {})
1863
+ error: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.AlertTriangle, {}),
1864
+ info: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Info, {}),
1865
+ success: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.CircleCheck, {}),
1866
+ warning: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.AlertCircle, {})
1783
1867
  };
1784
1868
  var ToastRoot = ({
1785
1869
  id,
@@ -1789,11 +1873,14 @@ var ToastRoot = ({
1789
1873
  duration = Infinity,
1790
1874
  variant = "info",
1791
1875
  loading = false,
1792
- icon: iconProp
1876
+ icon: iconProp,
1877
+ argo
1793
1878
  }) => {
1879
+ const isLegacy = useIsLegacyBrand();
1880
+ const renderArgo = !isLegacy || argo;
1794
1881
  const icon = (() => {
1795
- if (loading) return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "tw-animate-spin" });
1796
- if (iconProp) return renderLegacyIcon(iconProp);
1882
+ if (loading) return /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Loader2, { className: "tw-animate-spin" });
1883
+ if (iconProp) return iconProp;
1797
1884
  if (variant === "default" || variant === null) return null;
1798
1885
  return DEFAULT_VARIANT_ICON[variant];
1799
1886
  })();
@@ -1801,35 +1888,44 @@ var ToastRoot = ({
1801
1888
  sonner.toast.dismiss(id);
1802
1889
  action?.onClick(event);
1803
1890
  };
1804
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-variant": variant, className: cn(variants2({ variant })), children: [
1805
- icon && /* @__PURE__ */ jsxRuntime.jsx(
1806
- "span",
1807
- {
1808
- "data-slot": "toast-icon",
1809
- className: cn(
1810
- "tw-inline-flex",
1811
- "tw-items-center",
1812
- "tw-justify-center",
1813
- "tw-self-center",
1814
- // styles — container at 20px with no padding so the 20px Lucide
1815
- // glyph fills the slot (previous tw-size-4 + tw-p-1 clipped a
1816
- // 16px child into 8px of visible space)
1817
- "tw-aspect-square",
1818
- "tw-size-5",
1819
- "tw-shrink-0",
1820
- '[&_svg:not([class*="tw-size-"])]:tw-size-5',
1821
- "tw-text-white",
1822
- "group-data-[variant=default]/toast:tw-text-popover-foreground"
1891
+ return /* @__PURE__ */ jsxRuntime.jsxs(
1892
+ "div",
1893
+ {
1894
+ "data-variant": variant,
1895
+ "data-argo": renderArgo,
1896
+ className: cn(
1897
+ variants2({ variant }),
1898
+ "data-[variant=default]:data-[argo=true]:tw-bg-background"
1899
+ ),
1900
+ children: [
1901
+ icon && /* @__PURE__ */ jsxRuntime.jsx(
1902
+ "span",
1903
+ {
1904
+ "data-slot": "toast-icon",
1905
+ className: cn(
1906
+ "tw-inline-flex",
1907
+ "tw-items-center",
1908
+ "tw-justify-center",
1909
+ "tw-self-center",
1910
+ "tw-aspect-square",
1911
+ "tw-size-5",
1912
+ "tw-shrink-0",
1913
+ '[&_svg:not([class*="tw-size-"])]:tw-size-5',
1914
+ "tw-text-white",
1915
+ "group-data-[variant=default]/toast:tw-text-popover-foreground",
1916
+ "group-data-[variant=default]/toast:group-data-[argo=true]/toast:tw-text-foreground"
1917
+ ),
1918
+ children: icon
1919
+ }
1823
1920
  ),
1824
- children: icon
1825
- }
1826
- ),
1827
- /* @__PURE__ */ jsxRuntime.jsx(ToastTitle, { children: title }),
1828
- description && /* @__PURE__ */ jsxRuntime.jsx(ToastDescription, { children: description }),
1829
- action && /* @__PURE__ */ jsxRuntime.jsx(ToastAction, { style: action?.actionButtonStyle, onClick: handleActionClick, children: action.label }),
1830
- /* @__PURE__ */ jsxRuntime.jsx(ToastDismiss, { onClick: () => sonner.toast.dismiss(id) }),
1831
- duration !== Infinity && /* @__PURE__ */ jsxRuntime.jsx(ToastDuration, { duration })
1832
- ] });
1921
+ /* @__PURE__ */ jsxRuntime.jsx(ToastTitle, { children: title }),
1922
+ description && /* @__PURE__ */ jsxRuntime.jsx(ToastDescription, { children: description }),
1923
+ action && /* @__PURE__ */ jsxRuntime.jsx(ToastAction, { style: action?.actionButtonStyle, onClick: handleActionClick, children: action.label }),
1924
+ /* @__PURE__ */ jsxRuntime.jsx(ToastDismiss, { onClick: () => sonner.toast.dismiss(id) }),
1925
+ duration !== Infinity && /* @__PURE__ */ jsxRuntime.jsx(ToastDuration, { duration })
1926
+ ]
1927
+ }
1928
+ );
1833
1929
  };
1834
1930
  var toast = ({
1835
1931
  onAutoClose,
@@ -2220,6 +2316,9 @@ init_icons();
2220
2316
  init_icons();
2221
2317
  init_utils();
2222
2318
 
2319
+ // src/components/DropdownMenu/DropdownMenu.tsx
2320
+ init_useIsLegacyBrand();
2321
+
2223
2322
  // src/components/DropdownMenu/DropdownMenuCheckboxItem.tsx
2224
2323
  init_icons();
2225
2324
  init_utils();
@@ -2292,9 +2391,9 @@ var DropdownMenuItemIndicator = ({
2292
2391
  ...rest
2293
2392
  }) => {
2294
2393
  const IconComp = (() => {
2295
- if (variant === "switch") return lucideReact.ToggleRight;
2296
- if (variant === "radio") return lucideReact.Circle;
2297
- return lucideReact.Check;
2394
+ if (variant === "switch") return icons_exports.ToggleRight;
2395
+ if (variant === "radio") return icons_exports.Circle;
2396
+ return icons_exports.Check;
2298
2397
  })();
2299
2398
  const forceMount = (() => {
2300
2399
  if (forceMountProp) return true;
@@ -2368,17 +2467,16 @@ var itemVariants = cn(
2368
2467
  "group-data-[variant=default]/dropdown-menu-content:hover:tw-bg-neutral-100",
2369
2468
  "group-data-[variant=default]/dropdown-menu-content:hover:tw-text-neutral-900",
2370
2469
  "group-data-[variant=argo]/dropdown-menu-content:tw-rounded-md",
2371
- "group-data-[variant=argo]/dropdown-menu-content:tw-text-slate-800",
2372
- "group-data-[variant=argo]/dropdown-menu-content:focus:tw-text-slate-800",
2373
- "group-data-[variant=argo]/dropdown-menu-content:focus:tw-bg-sky-100",
2374
- "group-data-[variant=argo]/dropdown-menu-content:hover:tw-text-slate-800",
2375
- "group-data-[variant=argo]/dropdown-menu-content:hover:tw-bg-sky-100"
2470
+ "group-data-[variant=argo]/dropdown-menu-content:tw-text-popover-foreground",
2471
+ "group-data-[variant=argo]/dropdown-menu-content:focus:tw-text-accent-foreground",
2472
+ "group-data-[variant=argo]/dropdown-menu-content:focus:tw-bg-accent",
2473
+ "group-data-[variant=argo]/dropdown-menu-content:hover:tw-text-accent-foreground",
2474
+ "group-data-[variant=argo]/dropdown-menu-content:hover:tw-bg-accent"
2376
2475
  );
2377
2476
  var contentVariants = cn(
2378
2477
  "tailwindcss-preflight",
2379
2478
  "tw-group/dropdown-menu-content",
2380
2479
  "tw-z-[1040]",
2381
- "tw-bg-white",
2382
2480
  // positioning
2383
2481
  "tw-flex",
2384
2482
  "tw-flex-col",
@@ -2389,8 +2487,16 @@ var contentVariants = cn(
2389
2487
  // border
2390
2488
  "tw-border",
2391
2489
  "tw-shadow-md",
2490
+ // Legacy surface — fixed white panel.
2392
2491
  "data-[variant=default]:tw-rounded-md",
2492
+ "data-[variant=default]:tw-bg-white",
2493
+ "data-[variant=default]:tw-border-neutral-100",
2494
+ "data-[variant=default]:tw-text-neutral-800",
2495
+ // Argo surface — semantic popover tokens (brand + dark aware).
2393
2496
  "data-[variant=argo]:tw-rounded-2xl",
2497
+ "data-[variant=argo]:tw-bg-popover",
2498
+ "data-[variant=argo]:tw-text-popover-foreground",
2499
+ "data-[variant=argo]:tw-border-border",
2394
2500
  // animations
2395
2501
  "data-[state=open]:tw-animate-in",
2396
2502
  "data-[state=open]:tw-fade-in-0",
@@ -2415,7 +2521,7 @@ var DropdownMenuCheckboxItem = ({
2415
2521
  ...props
2416
2522
  }) => {
2417
2523
  const isAtStart = indicatorAlign === "start";
2418
- const indicatorEle = isLoading ? /* @__PURE__ */ jsxRuntime.jsx(ItemIcon, { className: isAtStart ? "" : "tw-ml-auto", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "tw-animate-spin" }) }) : /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuItemIndicator, { variant: indicator, className: isAtStart ? "" : "tw-ml-auto" });
2524
+ const indicatorEle = isLoading ? /* @__PURE__ */ jsxRuntime.jsx(ItemIcon, { className: isAtStart ? "" : "tw-ml-auto", children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Loader2, { className: "tw-animate-spin" }) }) : /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuItemIndicator, { variant: indicator, className: isAtStart ? "" : "tw-ml-auto" });
2419
2525
  const handleSelect = (event) => {
2420
2526
  if (!closeOnSelect) event.preventDefault();
2421
2527
  onSelect?.(event);
@@ -2450,7 +2556,6 @@ var ScrollBar = ({ className, orientation = "vertical", ...props }) => /* @__PUR
2450
2556
  orientation,
2451
2557
  className: cn(
2452
2558
  "tw-flex tw-touch-none tw-select-none tw-transition-color",
2453
- '[data-state="hidden"]:tw-bg-pink-500',
2454
2559
  {
2455
2560
  "tw-h-full tw-w-2.5 tw-p-px": orientation === "vertical",
2456
2561
  "tw-h-2.5 tw-flex-col tw-p-px": orientation === "horizontal"
@@ -2465,8 +2570,8 @@ var ScrollBar = ({ className, orientation = "vertical", ...props }) => /* @__PUR
2465
2570
  "tw-relative",
2466
2571
  "tw-flex-1",
2467
2572
  "tw-rounded-full",
2468
- "tw-bg-neutral-200",
2469
- "hover:tw-bg-neutral-400"
2573
+ "tw-bg-border",
2574
+ "hover:tw-bg-muted-foreground"
2470
2575
  )
2471
2576
  }
2472
2577
  )
@@ -2565,7 +2670,7 @@ var DropdownMenuItem = ({
2565
2670
  ...props
2566
2671
  }) => {
2567
2672
  const Comp = asChild ? reactSlot.Root : "div";
2568
- const adornment = isLoading ? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "tw-animate-spin" }) : renderLegacyIcon(icon);
2673
+ const adornment = isLoading ? /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Loader2, { className: "tw-animate-spin" }) : icon;
2569
2674
  const handleOnSelect = (event) => {
2570
2675
  if (asModalTrigger) event.preventDefault();
2571
2676
  onSelect?.(event);
@@ -2680,7 +2785,7 @@ var DropdownMenuRadioItem = ({
2680
2785
  ...props
2681
2786
  }) => {
2682
2787
  const isAtStart = indicatorAlign === "start";
2683
- const indicatorEle = isLoading ? /* @__PURE__ */ jsxRuntime.jsx(ItemIcon, { className: iconClassName, children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "tw-animate-spin" }) }) : /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuItemIndicator, { variant: indicator });
2788
+ const indicatorEle = isLoading ? /* @__PURE__ */ jsxRuntime.jsx(ItemIcon, { className: iconClassName, children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Loader2, { className: "tw-animate-spin" }) }) : /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuItemIndicator, { variant: indicator });
2684
2789
  const handleSelect = (event) => {
2685
2790
  if (!closeOnSelect) event.preventDefault();
2686
2791
  onSelect?.(event);
@@ -2701,7 +2806,7 @@ var DropdownMenuRadioItem = ({
2701
2806
  ...props,
2702
2807
  children: [
2703
2808
  isAtStart && indicatorEle,
2704
- icon && /* @__PURE__ */ jsxRuntime.jsx(ItemIcon, { className: iconClassName, children: renderLegacyIcon(icon) }),
2809
+ icon && /* @__PURE__ */ jsxRuntime.jsx(ItemIcon, { className: iconClassName, children: icon }),
2705
2810
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "tw-flex tw-min-w-0 tw-flex-1 tw-items-center tw-gap-2", children }),
2706
2811
  !isAtStart && indicatorEle
2707
2812
  ]
@@ -2757,7 +2862,7 @@ init_utils();
2757
2862
  var DropdownMenuSubTrigger = ({ className, children, ...props }) => {
2758
2863
  return /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenuPrimitive3__namespace.SubTrigger, { className: cn(itemVariants, className), ...props, children: [
2759
2864
  children,
2760
- /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "tw-ml-auto tw-size-5" })
2865
+ /* @__PURE__ */ jsxRuntime.jsx(icons_exports.ChevronRight, { className: "tw-ml-auto tw-size-5" })
2761
2866
  ] });
2762
2867
  };
2763
2868
 
@@ -2779,10 +2884,12 @@ var DropdownMenuTrigger = ({
2779
2884
  var DropdownMenu = ({
2780
2885
  // change a default value to false, for modal property, as it is not used in most cases
2781
2886
  modal = false,
2782
- variant = "default",
2887
+ variant,
2783
2888
  ...props
2784
2889
  }) => {
2785
- const contextValue = react.useMemo(() => ({ variant }), [variant]);
2890
+ const isLegacy = useIsLegacyBrand();
2891
+ const effectiveVariant = !isLegacy || variant === "argo" ? "argo" : "default";
2892
+ const contextValue = react.useMemo(() => ({ variant: effectiveVariant }), [effectiveVariant]);
2786
2893
  return /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuContext, { value: contextValue, children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenuPrimitive3.Root, { ...props, modal }) });
2787
2894
  };
2788
2895
  DropdownMenu.Trigger = DropdownMenuTrigger;
@@ -2802,10 +2909,10 @@ DropdownMenu.ItemDescription = DropdownMenuItemDescription;
2802
2909
  // src/components/MarkdownEditor/plugins/toolbar/AlignmentDropdown.tsx
2803
2910
  init_Tooltip2();
2804
2911
  var ALIGNMENT_OPTIONS = [
2805
- { value: "left", label: "Left", icon: lucideReact.AlignLeft },
2806
- { value: "center", label: "Center", icon: lucideReact.AlignCenter },
2807
- { value: "right", label: "Right", icon: lucideReact.AlignRight },
2808
- { value: "justify", label: "Justify", icon: lucideReact.AlignJustify }
2912
+ { value: "left", label: "Left", icon: icons_exports.AlignLeft },
2913
+ { value: "center", label: "Center", icon: icons_exports.AlignCenter },
2914
+ { value: "right", label: "Right", icon: icons_exports.AlignRight },
2915
+ { value: "justify", label: "Justify", icon: icons_exports.AlignJustify }
2809
2916
  ];
2810
2917
  var ALIGNMENT_ICONS = Object.fromEntries(
2811
2918
  ALIGNMENT_OPTIONS.map(({ value, icon }) => [value, icon])
@@ -2831,7 +2938,7 @@ var AlignmentDropdown = ({
2831
2938
  editor.dispatchCommand(lexical.FORMAT_ELEMENT_COMMAND, align);
2832
2939
  });
2833
2940
  };
2834
- const CurrentAlignmentIcon = ALIGNMENT_ICONS[alignment] ?? lucideReact.AlignLeft;
2941
+ const CurrentAlignmentIcon = ALIGNMENT_ICONS[alignment] ?? icons_exports.AlignLeft;
2835
2942
  return /* @__PURE__ */ jsxRuntime.jsxs(DropdownMenu, { onOpenChange: handleOpenChange, children: [
2836
2943
  /* @__PURE__ */ jsxRuntime.jsx(Tooltip, { tooltip: "Text alignment", placement: "top", triggerAsChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(DropdownMenu.Trigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(
2837
2944
  "button",
@@ -2843,7 +2950,7 @@ var AlignmentDropdown = ({
2843
2950
  ),
2844
2951
  children: [
2845
2952
  /* @__PURE__ */ jsxRuntime.jsx(CurrentAlignmentIcon, { className: "tw-size-4" }),
2846
- /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDown, { className: "tw-size-3" })
2953
+ /* @__PURE__ */ jsxRuntime.jsx(icons_exports.ChevronDown, { className: "tw-size-3" })
2847
2954
  ]
2848
2955
  }
2849
2956
  ) }) }),
@@ -2870,14 +2977,14 @@ init_icons();
2870
2977
  init_utils();
2871
2978
  init_Tooltip2();
2872
2979
  var BLOCK_TYPE_META = {
2873
- paragraph: { label: "Normal", icon: lucideReact.Type, selectable: true },
2874
- h1: { label: "Heading 1", icon: lucideReact.Heading1, selectable: true },
2875
- h2: { label: "Heading 2", icon: lucideReact.Heading2, selectable: true },
2876
- h3: { label: "Heading 3", icon: lucideReact.Heading3, selectable: true },
2877
- bullet: { label: "Bullet List", icon: lucideReact.List, selectable: false },
2878
- number: { label: "Numbered List", icon: lucideReact.ListOrdered, selectable: false },
2879
- quote: { label: "Quote", icon: lucideReact.Quote, selectable: false },
2880
- code: { label: "Code Block", icon: lucideReact.SquareCode, selectable: false }
2980
+ paragraph: { label: "Normal", icon: icons_exports.Type, selectable: true },
2981
+ h1: { label: "Heading 1", icon: icons_exports.Heading1, selectable: true },
2982
+ h2: { label: "Heading 2", icon: icons_exports.Heading2, selectable: true },
2983
+ h3: { label: "Heading 3", icon: icons_exports.Heading3, selectable: true },
2984
+ bullet: { label: "Bullet List", icon: icons_exports.List, selectable: false },
2985
+ number: { label: "Numbered List", icon: icons_exports.ListOrdered, selectable: false },
2986
+ quote: { label: "Quote", icon: icons_exports.Quote, selectable: false },
2987
+ code: { label: "Code Block", icon: icons_exports.SquareCode, selectable: false }
2881
2988
  };
2882
2989
  var BLOCK_TYPE_OPTIONS = Object.entries(BLOCK_TYPE_META).filter(([, meta]) => meta.selectable).map(([value, { label, icon }]) => ({ value, label, icon }));
2883
2990
  var isBlockType = (value) => Object.prototype.hasOwnProperty.call(BLOCK_TYPE_META, value);
@@ -2887,7 +2994,7 @@ var BlockTypeDropdown = ({
2887
2994
  }) => {
2888
2995
  const savedSelectionRef = react.useRef(null);
2889
2996
  const currentMeta = isBlockType(blockType) ? BLOCK_TYPE_META[blockType] : null;
2890
- const CurrentBlockIcon = currentMeta?.icon ?? lucideReact.Type;
2997
+ const CurrentBlockIcon = currentMeta?.icon ?? icons_exports.Type;
2891
2998
  const handleOpenChange = (open) => {
2892
2999
  if (open) {
2893
3000
  editor.getEditorState().read(() => {
@@ -2930,7 +3037,7 @@ var BlockTypeDropdown = ({
2930
3037
  children: [
2931
3038
  /* @__PURE__ */ jsxRuntime.jsx(CurrentBlockIcon, { className: "tw-size-4" }),
2932
3039
  currentMeta?.label ?? "Normal",
2933
- /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDown, { className: "tw-size-3" })
3040
+ /* @__PURE__ */ jsxRuntime.jsx(icons_exports.ChevronDown, { className: "tw-size-3" })
2934
3041
  ]
2935
3042
  }
2936
3043
  ) }) }),
@@ -3031,6 +3138,7 @@ var useFormGroupContext = () => react.use(FormGroupContext);
3031
3138
 
3032
3139
  // src/components/InputGroup/InputGroup.tsx
3033
3140
  init_utils();
3141
+ init_useIsLegacyBrand();
3034
3142
 
3035
3143
  // src/components/InputGroup/InputGroupAddon.tsx
3036
3144
  init_utils();
@@ -3040,7 +3148,7 @@ var addonVariants = classVarianceAuthority.cva(
3040
3148
  "tw-items-center",
3041
3149
  "tw-gap-1",
3042
3150
  // Default size for nested Lucide icons in prefix/suffix slots; callers can override on the icon.
3043
- "[&_svg:not([class*='tw-size-'])]:tw-size-4",
3151
+ "[&_svg.lucide:not([class*='tw-size-'])]:tw-size-4",
3044
3152
  "[&_svg]:tw-shrink-0"
3045
3153
  ],
3046
3154
  {
@@ -3329,7 +3437,8 @@ var inputGroupVariants = classVarianceAuthority.cva(
3329
3437
  "has-[:is(input,textarea):disabled]:tw-opacity-40"
3330
3438
  ],
3331
3439
  argo: [
3332
- "tw-bg-background",
3440
+ // muted filled input surface — gray, distinct from white containers; not the app-background token
3441
+ "tw-bg-muted",
3333
3442
  "tw-border-input",
3334
3443
  "tw-rounded-lg",
3335
3444
  "tw-text-foreground",
@@ -3383,15 +3492,28 @@ var InputGroupRoot = ({
3383
3492
  focusVariant,
3384
3493
  className,
3385
3494
  ...props
3386
- }) => /* @__PURE__ */ jsxRuntime.jsx(
3387
- "div",
3388
- {
3389
- ...props,
3390
- ref,
3391
- className: cn(inputGroupVariants({ state, variant, sizing, focusVariant, className })),
3392
- children
3393
- }
3394
- );
3495
+ }) => {
3496
+ const isLegacy = useIsLegacyBrand();
3497
+ const effectiveVariant = !isLegacy || variant === "argo" ? "argo" : variant;
3498
+ const effectiveSizing = effectiveVariant === "argo" ? "medium" : sizing;
3499
+ return /* @__PURE__ */ jsxRuntime.jsx(
3500
+ "div",
3501
+ {
3502
+ ...props,
3503
+ ref,
3504
+ className: cn(
3505
+ inputGroupVariants({
3506
+ state,
3507
+ variant: effectiveVariant,
3508
+ sizing: effectiveSizing,
3509
+ focusVariant,
3510
+ className
3511
+ })
3512
+ ),
3513
+ children
3514
+ }
3515
+ );
3516
+ };
3395
3517
  var InputGroup = InputGroupRoot;
3396
3518
  InputGroup.Input = InputGroupInput;
3397
3519
  InputGroup.Addon = InputGroupAddon;
@@ -3467,7 +3589,7 @@ var ColorPicker = ({ value, disabled, readOnly, ...props }) => {
3467
3589
  disabled: disabled || readOnly,
3468
3590
  onClick: handleOpenPicker,
3469
3591
  "aria-label": "Pick color",
3470
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Pipette, { className: "tw-size-4" })
3592
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Pipette, { className: "tw-size-4" })
3471
3593
  }
3472
3594
  )
3473
3595
  ] });
@@ -3586,7 +3708,7 @@ var ColorInput = ({
3586
3708
  onMouseDown: (event) => event.preventDefault(),
3587
3709
  onClick: handleClear,
3588
3710
  "aria-label": "Clear color",
3589
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "tw-size-4" })
3711
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.X, { className: "tw-size-4" })
3590
3712
  }
3591
3713
  ),
3592
3714
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -3616,8 +3738,8 @@ var helpVariants = classVarianceAuthority.cva(["tw-m-0", "tw-text-xs"], {
3616
3738
  },
3617
3739
  variants: {
3618
3740
  state: {
3619
- default: ["tw-text-neutral-500"],
3620
- error: ["tw-text-error-500"],
3741
+ default: ["tw-text-muted-foreground"],
3742
+ error: ["tw-text-destructive"],
3621
3743
  warning: ["tw-text-warning-500"]
3622
3744
  }
3623
3745
  }
@@ -3696,7 +3818,7 @@ var Textarea = ({
3696
3818
  containerClassName,
3697
3819
  // group props
3698
3820
  state = "default",
3699
- variant = "primary",
3821
+ variant,
3700
3822
  sizing,
3701
3823
  focusVariant,
3702
3824
  ...rest
@@ -3821,14 +3943,14 @@ var Input = ({
3821
3943
  onMouseDown: (e) => e.preventDefault(),
3822
3944
  onClick: handleClear,
3823
3945
  "data-testid": testId.clearButton,
3824
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "tw-size-4" })
3946
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.X, { className: "tw-size-4" })
3825
3947
  }
3826
3948
  ),
3827
3949
  rightSuffix && /* @__PURE__ */ jsxRuntime.jsx(
3828
3950
  "div",
3829
3951
  {
3830
3952
  className: cn({
3831
- "tw-whitespace-nowrap tw-bg-neutral-200 tw-px-4 -tw-mr-4 tw-py-2.5": rightSuffixVariant === "addon"
3953
+ "tw-whitespace-nowrap tw-bg-muted tw-px-4 -tw-mr-4 tw-py-2.5": rightSuffixVariant === "addon"
3832
3954
  }),
3833
3955
  children: rightSuffix
3834
3956
  }
@@ -3847,6 +3969,7 @@ var TextInput = ({
3847
3969
  value,
3848
3970
  defaultValue,
3849
3971
  type = "text",
3972
+ variant,
3850
3973
  onValueChange,
3851
3974
  onChange,
3852
3975
  onValueBlur,
@@ -3869,6 +3992,7 @@ var TextInput = ({
3869
3992
  onChange: handleChange,
3870
3993
  onBlur: handleBlur,
3871
3994
  type,
3995
+ variant,
3872
3996
  value: sanitizeTextInputValue(value),
3873
3997
  defaultValue: sanitizeTextInputValue(defaultValue)
3874
3998
  }
@@ -3892,7 +4016,7 @@ FormGroup.Textarea = FormGroupTextarea;
3892
4016
 
3893
4017
  // src/components/Label/Label.tsx
3894
4018
  init_utils();
3895
- var Optional = ({ className }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("tw-text-neutral-400", className), children: "(optional)" });
4019
+ var Optional = ({ className }) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn("tw-text-muted-foreground", className), children: "(optional)" });
3896
4020
  var Label2 = ({ className, children, id, htmlFor, ...rest }) => {
3897
4021
  return /* @__PURE__ */ jsxRuntime.jsx(
3898
4022
  RLabel__namespace.Root,
@@ -3901,7 +4025,7 @@ var Label2 = ({ className, children, id, htmlFor, ...rest }) => {
3901
4025
  id: id?.toString(),
3902
4026
  htmlFor: htmlFor?.toString(),
3903
4027
  className: cn(
3904
- "tw-m-0 tw-text-neutral-800 tw-font-normal peer-disabled:tw-opacity-50",
4028
+ "tw-m-0 tw-text-foreground tw-font-normal peer-disabled:tw-opacity-50",
3905
4029
  className
3906
4030
  ),
3907
4031
  children
@@ -4001,12 +4125,12 @@ var LinkPanel = ({ editor, isLink }) => {
4001
4125
  active: true,
4002
4126
  onClick: () => editor.dispatchCommand(link.TOGGLE_LINK_COMMAND, null),
4003
4127
  tooltip: "Remove Link",
4004
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Link, { className: "tw-size-4" })
4128
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Link, { className: "tw-size-4" })
4005
4129
  }
4006
4130
  );
4007
4131
  }
4008
4132
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "tw-relative", children: [
4009
- /* @__PURE__ */ jsxRuntime.jsx(ToolbarButton, { active: open, onClick: handleOpen, tooltip: "Insert Link", children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Link, { className: "tw-size-4" }) }),
4133
+ /* @__PURE__ */ jsxRuntime.jsx(ToolbarButton, { active: open, onClick: handleOpen, tooltip: "Insert Link", children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Link, { className: "tw-size-4" }) }),
4010
4134
  open && /* @__PURE__ */ jsxRuntime.jsx(
4011
4135
  "div",
4012
4136
  {
@@ -4170,7 +4294,7 @@ var ToolbarPlugin = () => {
4170
4294
  active: isBold,
4171
4295
  onClick: () => editor.dispatchCommand(lexical.FORMAT_TEXT_COMMAND, "bold"),
4172
4296
  tooltip: "Bold (Ctrl+B)",
4173
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Bold, { className: "tw-size-4" })
4297
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Bold, { className: "tw-size-4" })
4174
4298
  }
4175
4299
  ),
4176
4300
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4179,7 +4303,7 @@ var ToolbarPlugin = () => {
4179
4303
  active: isItalic,
4180
4304
  onClick: () => editor.dispatchCommand(lexical.FORMAT_TEXT_COMMAND, "italic"),
4181
4305
  tooltip: "Italic (Ctrl+I)",
4182
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Italic, { className: "tw-size-4" })
4306
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Italic, { className: "tw-size-4" })
4183
4307
  }
4184
4308
  ),
4185
4309
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4188,7 +4312,7 @@ var ToolbarPlugin = () => {
4188
4312
  active: isUnderline,
4189
4313
  onClick: () => editor.dispatchCommand(lexical.FORMAT_TEXT_COMMAND, "underline"),
4190
4314
  tooltip: "Underline (Ctrl+U)",
4191
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Underline, { className: "tw-size-4" })
4315
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Underline, { className: "tw-size-4" })
4192
4316
  }
4193
4317
  ),
4194
4318
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4197,7 +4321,7 @@ var ToolbarPlugin = () => {
4197
4321
  active: isStrikethrough,
4198
4322
  onClick: () => editor.dispatchCommand(lexical.FORMAT_TEXT_COMMAND, "strikethrough"),
4199
4323
  tooltip: "Strikethrough",
4200
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Strikethrough, { className: "tw-size-4" })
4324
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Strikethrough, { className: "tw-size-4" })
4201
4325
  }
4202
4326
  ),
4203
4327
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4206,7 +4330,7 @@ var ToolbarPlugin = () => {
4206
4330
  active: isCode,
4207
4331
  onClick: () => editor.dispatchCommand(lexical.FORMAT_TEXT_COMMAND, "code"),
4208
4332
  tooltip: "Inline Code",
4209
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Code, { className: "tw-size-4" })
4333
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Code, { className: "tw-size-4" })
4210
4334
  }
4211
4335
  ),
4212
4336
  /* @__PURE__ */ jsxRuntime.jsx(ToolbarDivider, {}),
@@ -4224,7 +4348,7 @@ var ToolbarPlugin = () => {
4224
4348
  }
4225
4349
  },
4226
4350
  tooltip: "Bullet List",
4227
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.List, { className: "tw-size-4" })
4351
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.List, { className: "tw-size-4" })
4228
4352
  }
4229
4353
  ),
4230
4354
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4239,7 +4363,7 @@ var ToolbarPlugin = () => {
4239
4363
  }
4240
4364
  },
4241
4365
  tooltip: "Numbered List",
4242
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ListOrdered, { className: "tw-size-4" })
4366
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.ListOrdered, { className: "tw-size-4" })
4243
4367
  }
4244
4368
  ),
4245
4369
  /* @__PURE__ */ jsxRuntime.jsx(ToolbarDivider, {}),
@@ -4261,7 +4385,7 @@ var ToolbarPlugin = () => {
4261
4385
  });
4262
4386
  },
4263
4387
  tooltip: "Quote",
4264
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Quote, { className: "tw-size-4" })
4388
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.Quote, { className: "tw-size-4" })
4265
4389
  }
4266
4390
  ),
4267
4391
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4280,7 +4404,7 @@ var ToolbarPlugin = () => {
4280
4404
  });
4281
4405
  },
4282
4406
  tooltip: "Code Block",
4283
- children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.SquareCode, { className: "tw-size-4" })
4407
+ children: /* @__PURE__ */ jsxRuntime.jsx(icons_exports.SquareCode, { className: "tw-size-4" })
4284
4408
  }
4285
4409
  )
4286
4410
  ]
@@ -4292,25 +4416,25 @@ var ToolbarPlugin = () => {
4292
4416
 
4293
4417
  // src/components/MarkdownEditor/theme.ts
4294
4418
  var editorTheme = {
4295
- link: "tw-cursor-pointer !tw-text-secondary-500 tw-underline",
4419
+ link: "tw-cursor-pointer !tw-text-primary tw-underline",
4296
4420
  text: {
4297
4421
  bold: "tw-font-bold",
4298
4422
  italic: "tw-italic",
4299
4423
  strikethrough: "tw-line-through",
4300
4424
  underline: "tw-underline",
4301
- code: "tw-rounded tw-bg-neutral-100 tw-px-1 tw-py-0.5 tw-font-mono tw-text-[0.85em]"
4425
+ code: "tw-rounded tw-bg-muted tw-px-1 tw-py-0.5 tw-font-mono tw-text-[0.85em]"
4302
4426
  },
4303
4427
  list: {
4304
4428
  ol: "!tw-list-decimal",
4305
4429
  ul: "!tw-list-disc",
4306
4430
  checklist: "!tw-list-none !tw-pl-0",
4307
4431
  listitemChecked: [
4308
- "tw-relative !tw-pl-6 tw-list-none tw-outline-none tw-line-through tw-text-neutral-400",
4432
+ "tw-relative !tw-pl-6 tw-list-none tw-outline-none tw-line-through tw-text-muted-foreground",
4309
4433
  'before:tw-content-[""] before:tw-absolute before:tw-left-0 before:tw-top-[3px]',
4310
4434
  "before:tw-size-4 before:tw-rounded before:tw-border before:tw-border-solid",
4311
- "before:tw-bg-secondary-500 before:tw-border-secondary-500 before:tw-cursor-pointer",
4435
+ "before:tw-bg-primary before:tw-border-primary before:tw-cursor-pointer",
4312
4436
  'after:tw-content-[""] after:tw-absolute after:tw-left-[5.5px] after:tw-top-[5.5px]',
4313
- "after:tw-w-1 after:tw-h-2 after:tw-border-white after:tw-border-solid",
4437
+ "after:tw-w-1 after:tw-h-2 after:tw-border-primary-foreground after:tw-border-solid",
4314
4438
  "after:tw-border-r-[1.5px] after:tw-border-b-[1.5px] after:tw-border-t-0 after:tw-border-l-0",
4315
4439
  "after:tw-rotate-45"
4316
4440
  ].join(" "),
@@ -4318,7 +4442,7 @@ var editorTheme = {
4318
4442
  "tw-relative !tw-pl-6 tw-list-none tw-outline-none",
4319
4443
  'before:tw-content-[""] before:tw-absolute before:tw-left-0 before:tw-top-[3px]',
4320
4444
  "before:tw-size-4 before:tw-rounded before:tw-border before:tw-border-solid",
4321
- "before:tw-border-neutral-200 before:tw-bg-white before:tw-cursor-pointer"
4445
+ "before:tw-border-input before:tw-bg-background before:tw-cursor-pointer"
4322
4446
  ].join(" ")
4323
4447
  }
4324
4448
  };
@@ -4406,7 +4530,7 @@ var MarkdownEditor = ({
4406
4530
  // but a matching negative margin shifts the wrapper outward so the text itself stays
4407
4531
  // aligned with the parent's content edge (i.e. with where static text would render).
4408
4532
  compact ? "tw-px-1.5 tw-py-0.5 -tw-mx-1.5 -tw-my-0.5" : "tw-p-2",
4409
- editable && "tw-cursor-text hover:tw-bg-neutral-50 focus-within:tw-ring-2 focus-within:tw-ring-secondary-500/40"
4533
+ editable && "tw-cursor-text hover:tw-bg-muted focus-within:tw-ring-2 focus-within:tw-ring-primary/40"
4410
4534
  ),
4411
4535
  children: /* @__PURE__ */ jsxRuntime.jsx(
4412
4536
  LexicalRichTextPlugin.RichTextPlugin,
@@ -4421,7 +4545,7 @@ var MarkdownEditor = ({
4421
4545
  "div",
4422
4546
  {
4423
4547
  className: cn(
4424
- "tw-pointer-events-none tw-absolute tw-select-none tw-text-neutral-400",
4548
+ "tw-pointer-events-none tw-absolute tw-select-none tw-text-muted-foreground",
4425
4549
  compact ? "tw-left-1.5 tw-top-0.5" : "tw-left-2 tw-top-[calc(0.5rem+0.35em)]"
4426
4550
  ),
4427
4551
  children: placeholder