@elevasis/ui 2.25.6 → 2.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (105) hide show
  1. package/dist/api/index.js +2 -2
  2. package/dist/app/index.css +15 -5
  3. package/dist/app/index.d.ts +61 -14
  4. package/dist/app/index.js +6 -6
  5. package/dist/charts/index.js +6 -5
  6. package/dist/chunk-3MEXPLWT.js +265 -0
  7. package/dist/{chunk-BDKM56TP.js → chunk-4KTLOK7K.js} +1 -1
  8. package/dist/{chunk-KMAXFJPH.js → chunk-CW3UNAF2.js} +5 -409
  9. package/dist/{chunk-HKBEURCV.js → chunk-G26INIF3.js} +1 -1
  10. package/dist/{chunk-7F3IQMLI.js → chunk-G66QFZXD.js} +11 -214
  11. package/dist/{chunk-QIW6OCEI.js → chunk-HLFFKKT3.js} +27 -373
  12. package/dist/chunk-JDNEWB5F.js +10 -0
  13. package/dist/{chunk-L7D6KNHV.js → chunk-JKBGDFX2.js} +890 -749
  14. package/dist/{chunk-YRKQNPK2.js → chunk-JPGX3533.js} +4 -3
  15. package/dist/chunk-KEFWANZY.js +155 -0
  16. package/dist/chunk-LH4GPYDX.js +448 -0
  17. package/dist/{chunk-JXSBOG2R.js → chunk-LWKZ3BCC.js} +5 -4
  18. package/dist/chunk-MYEOTM7D.js +92 -0
  19. package/dist/chunk-OGXKOMUT.js +412 -0
  20. package/dist/chunk-OHXU5WWK.js +3731 -0
  21. package/dist/chunk-ONFKASZI.js +2004 -0
  22. package/dist/{chunk-U36X6NZM.js → chunk-RIFTUOPE.js} +2 -14
  23. package/dist/{chunk-T6INEVX6.js → chunk-SGS4CQ2B.js} +1 -1
  24. package/dist/{chunk-C7IBFI5B.js → chunk-UPMX5GJI.js} +5 -5
  25. package/dist/{chunk-ARJPZ66V.js → chunk-UY5I2KOZ.js} +208 -3124
  26. package/dist/chunk-W2ZTLH7Y.js +662 -0
  27. package/dist/{chunk-KNISO652.js → chunk-WUVR4QY6.js} +9 -9
  28. package/dist/{chunk-Q5BEODAT.js → chunk-X2SUMO3P.js} +2 -1
  29. package/dist/{chunk-SNHGSCKH.js → chunk-XBMCDGHA.js} +1 -1
  30. package/dist/{chunk-N55DVMAG.js → chunk-XQQEKWTL.js} +2 -6
  31. package/dist/{chunk-SBQ4MYQV.js → chunk-XZSEPJZQ.js} +5 -6
  32. package/dist/{chunk-CPAJXBTL.js → chunk-YHBPR67D.js} +490 -676
  33. package/dist/{chunk-QARSVM7Q.js → chunk-YO2YORW4.js} +4 -4
  34. package/dist/{chunk-TAIX4NO3.js → chunk-ZFLM2YVW.js} +2 -2
  35. package/dist/components/index.css +15 -5
  36. package/dist/components/index.d.ts +202 -383
  37. package/dist/components/index.js +43 -429
  38. package/dist/components/navigation/index.css +25 -15
  39. package/dist/execution/index.d.ts +0 -73
  40. package/dist/features/auth/index.css +25 -15
  41. package/dist/features/crm/index.css +25 -15
  42. package/dist/features/crm/index.d.ts +49 -49
  43. package/dist/features/crm/index.js +14 -15
  44. package/dist/features/dashboard/index.css +25 -15
  45. package/dist/features/dashboard/index.js +18 -16
  46. package/dist/features/delivery/index.css +15 -5
  47. package/dist/features/delivery/index.js +14 -15
  48. package/dist/features/knowledge/index.css +611 -0
  49. package/dist/features/knowledge/index.js +375 -72
  50. package/dist/features/lead-gen/index.css +25 -15
  51. package/dist/features/lead-gen/index.d.ts +60 -21
  52. package/dist/features/lead-gen/index.js +16 -16
  53. package/dist/features/monitoring/index.css +15 -5
  54. package/dist/features/monitoring/index.js +17 -17
  55. package/dist/features/monitoring/requests/index.css +25 -15
  56. package/dist/features/monitoring/requests/index.js +13 -14
  57. package/dist/features/operations/index.css +25 -15
  58. package/dist/features/operations/index.d.ts +16 -98
  59. package/dist/features/operations/index.js +26 -22
  60. package/dist/features/settings/index.css +25 -15
  61. package/dist/features/settings/index.d.ts +1 -0
  62. package/dist/features/settings/index.js +15 -16
  63. package/dist/hooks/delivery/index.css +25 -15
  64. package/dist/hooks/delivery/index.js +2 -2
  65. package/dist/hooks/index.css +15 -5
  66. package/dist/hooks/index.d.ts +172 -380
  67. package/dist/hooks/index.js +13 -14
  68. package/dist/hooks/published.css +15 -5
  69. package/dist/hooks/published.d.ts +172 -380
  70. package/dist/hooks/published.js +13 -14
  71. package/dist/index.css +15 -5
  72. package/dist/index.d.ts +988 -403
  73. package/dist/index.js +15 -15
  74. package/dist/initialization/index.d.ts +1 -0
  75. package/dist/knowledge/index.d.ts +981 -41
  76. package/dist/knowledge/index.js +5449 -294
  77. package/dist/layout/index.d.ts +2 -0
  78. package/dist/layout/index.js +3 -2
  79. package/dist/organization/index.css +25 -15
  80. package/dist/organization/index.d.ts +1 -0
  81. package/dist/provider/index.css +25 -15
  82. package/dist/provider/index.d.ts +818 -26
  83. package/dist/provider/index.js +11 -11
  84. package/dist/provider/published.css +25 -15
  85. package/dist/provider/published.d.ts +817 -25
  86. package/dist/provider/published.js +8 -9
  87. package/dist/test-utils/index.js +2 -2
  88. package/dist/test-utils/setup.js +1 -1
  89. package/dist/theme/index.js +3 -2
  90. package/dist/theme/presets/index.d.ts +97 -0
  91. package/dist/theme/presets/index.js +3 -0
  92. package/dist/types/index.d.ts +71 -126
  93. package/dist/utils/index.js +1 -1
  94. package/dist/vite/index.d.ts +7 -0
  95. package/dist/vite/index.js +10 -0
  96. package/dist/vite-plugin-knowledge/index.d.ts +1 -33
  97. package/dist/vite-plugin-knowledge/index.js +1 -66
  98. package/package.json +16 -3
  99. package/src/knowledge/README.md +8 -8
  100. package/src/theme/presets/README.md +19 -0
  101. package/dist/chunk-5RLYII6P.js +0 -314
  102. package/dist/chunk-6U7AIIHF.js +0 -880
  103. package/dist/chunk-HAEJ4M54.js +0 -94
  104. package/dist/chunk-LPM7O6XM.js +0 -293
  105. /package/dist/{chunk-SGXXJE52.js → chunk-QD4X4H5A.js} +0 -0
@@ -1,23 +1,24 @@
1
+ import { ZodFormRenderer } from './chunk-3MEXPLWT.js';
1
2
  import { ResourceHealthChart } from './chunk-LGKLC5MG.js';
2
- import { useCyberColors, HeroStatsRow } from './chunk-KMAXFJPH.js';
3
+ import { HeroStatsRow } from './chunk-OGXKOMUT.js';
4
+ import { useCyberColors } from './chunk-CW3UNAF2.js';
3
5
  import { AppShellCenteredContainer, AppShellLoader } from './chunk-RYTEQBAO.js';
4
- import { STATUS_COLORS, getStatusIcon, formatDuration, getStatusColors, AGENT_CONSTANTS, shouldAnimateEdge, TIMELINE_CONSTANTS, calculateBarPosition, CONTAINER_CONSTANTS, useExecutionPath, useUnifiedWorkflowLayout, WORKFLOW_CONSTANTS, useReactFlowAgent } from './chunk-E4WQGJNS.js';
5
- import { useExecuteResource, useDashboardMetrics, useResources, useTimeRangeDates, useUnresolvedErrors, useRecentExecutionsByResource, useCommandQueue, useScheduledTasks, useResourcesHealth } from './chunk-CPAJXBTL.js';
6
6
  import { Graph_module_css_default, useDirectedChainHighlighting, useNodeSelection, useFitViewTrigger } from './chunk-22UVE3RA.js';
7
- import { glassBase } from './chunk-QIW6OCEI.js';
8
- import { GlowDot, CardHeader, EmptyState, PageTitleCaption, TabCountBadge } from './chunk-U36X6NZM.js';
9
- import { formatTimeAgo, getTimeRangeDates, formatRelativeTime } from './chunk-SGXXJE52.js';
7
+ import { STATUS_COLORS, getStatusIcon, formatDuration, getStatusColors, AGENT_CONSTANTS, shouldAnimateEdge, TIMELINE_CONSTANTS, calculateBarPosition, CONTAINER_CONSTANTS, useExecutionPath, useUnifiedWorkflowLayout, WORKFLOW_CONSTANTS, useReactFlowAgent } from './chunk-E4WQGJNS.js';
8
+ import { useExecuteResource, useDashboardMetrics, useResources, useTimeRangeDates, useUnresolvedErrors, useRecentExecutionsByResource, useCommandQueue, useScheduledTasks, useResourcesHealth } from './chunk-YHBPR67D.js';
9
+ import { glassBase } from './chunk-LH4GPYDX.js';
10
+ import { GlowDot, CardHeader, EmptyState, PageTitleCaption, TabCountBadge } from './chunk-RIFTUOPE.js';
11
+ import { formatTimeAgo, getTimeRangeDates, formatRelativeTime } from './chunk-QD4X4H5A.js';
10
12
  import { ResourceStatusColors } from './chunk-KRWALB24.js';
11
13
  import { useInitialization } from './chunk-WKJ47GIW.js';
12
14
  import { memo, useMemo, useEffect, useState, useCallback, Fragment } from 'react';
13
- import { Paper, Stack, Text, Group, Badge, Box, useComputedColorScheme, Card, ActionIcon, Loader, SegmentedControl, TextInput, Textarea, Radio, Checkbox, Select, NumberInput, Button, Modal, Center, SimpleGrid, Title, Tabs, Grid, ThemeIcon } from '@mantine/core';
15
+ import { Paper, Stack, Text, Group, Badge, Box, useComputedColorScheme, Card, ActionIcon, Loader, SegmentedControl, Button, Modal, Center, SimpleGrid, Title, Tabs, Grid, ThemeIcon } from '@mantine/core';
14
16
  import { jsxs, jsx, Fragment as Fragment$1 } from 'react/jsx-runtime';
15
17
  import { Position, Handle, getSmoothStepPath, BaseEdge as BaseEdge$1, EdgeLabelRenderer, Panel, useReactFlow, Controls, ReactFlowProvider, ReactFlow } from '@xyflow/react';
16
18
  import { IconPlayerPlay, IconPlayerStop, IconArrowsSplit, IconSquare, IconFocus2, IconArrowUpRight, IconLayoutDashboard, IconActivity, IconAlertTriangle, IconHandStop, IconCalendarEvent, IconCircleCheck, IconBrain, IconGitBranch } from '@tabler/icons-react';
17
19
  import '@xyflow/react/dist/style.css';
18
20
  import { z } from 'zod';
19
21
  import { notifications } from '@mantine/notifications';
20
- import { useForm } from '@mantine/form';
21
22
  import '@mantine/charts/styles.css';
22
23
 
23
24
  var DOMAIN_COLORS = {
@@ -1194,210 +1195,6 @@ function AgentExecutionTimeline({ iterationData, selectedIterationId }) {
1194
1195
  )
1195
1196
  ] });
1196
1197
  }
1197
- function FormFieldRenderer({ field, form, richTextRenderer }) {
1198
- const commonProps = {
1199
- label: field.label,
1200
- description: field.description,
1201
- placeholder: field.placeholder,
1202
- required: field.required,
1203
- ...form.getInputProps(field.name)
1204
- };
1205
- switch (field.type) {
1206
- case "text":
1207
- return /* @__PURE__ */ jsx(TextInput, { ...commonProps });
1208
- case "textarea":
1209
- return /* @__PURE__ */ jsx(Textarea, { ...commonProps, minRows: 3, autosize: true });
1210
- case "number":
1211
- return /* @__PURE__ */ jsx(NumberInput, { ...commonProps, min: field.min, max: field.max });
1212
- case "select":
1213
- return /* @__PURE__ */ jsx(
1214
- Select,
1215
- {
1216
- ...commonProps,
1217
- data: field.options?.map((opt) => ({
1218
- label: opt.label,
1219
- value: String(opt.value)
1220
- })) || []
1221
- }
1222
- );
1223
- case "checkbox":
1224
- return /* @__PURE__ */ jsx(Checkbox, { ...commonProps, ...form.getInputProps(field.name, { type: "checkbox" }) });
1225
- case "radio":
1226
- return /* @__PURE__ */ jsx(Radio.Group, { ...commonProps, children: /* @__PURE__ */ jsx(Stack, { gap: "xs", children: field.options?.map((opt) => /* @__PURE__ */ jsx(Radio, { value: String(opt.value), label: opt.label }, opt.value)) }) });
1227
- case "richtext": {
1228
- const inputProps = form.getInputProps(field.name);
1229
- if (richTextRenderer) {
1230
- return richTextRenderer({
1231
- content: inputProps.value || "",
1232
- onChange: (content) => form.setFieldValue(field.name, content),
1233
- placeholder: field.placeholder
1234
- });
1235
- }
1236
- return /* @__PURE__ */ jsx(Textarea, { ...commonProps, minRows: 5, autosize: true });
1237
- }
1238
- default:
1239
- return /* @__PURE__ */ jsx(TextInput, { ...commonProps });
1240
- }
1241
- }
1242
- function getTypeName(schema) {
1243
- return schema._def.typeName;
1244
- }
1245
- function unwrapOptionalOrNullable(schema) {
1246
- const name = getTypeName(schema);
1247
- if (name === "ZodOptional" || name === "ZodNullable") {
1248
- return unwrapOptionalOrNullable(schema._def.innerType);
1249
- }
1250
- if (name === "ZodDefault") {
1251
- return unwrapOptionalOrNullable(schema._def.innerType);
1252
- }
1253
- return schema;
1254
- }
1255
- function getDefaultValue(schema) {
1256
- const name = getTypeName(schema);
1257
- if (name === "ZodDefault") {
1258
- const def = schema._def;
1259
- return def.defaultValue();
1260
- }
1261
- if (name === "ZodOptional" || name === "ZodNullable") {
1262
- return getDefaultValue(schema._def.innerType);
1263
- }
1264
- return void 0;
1265
- }
1266
- function zodTypeToFormField(name, fieldSchema, required) {
1267
- const inner = unwrapOptionalOrNullable(fieldSchema);
1268
- const typeName = getTypeName(inner);
1269
- const label = name.replace(/([A-Z])/g, " $1").replace(/^./, (s) => s.toUpperCase());
1270
- switch (typeName) {
1271
- case "ZodString": {
1272
- const checks = inner._def.checks ?? [];
1273
- const maxCheck = checks.find((c) => c.kind === "max");
1274
- const isLong = maxCheck ? (maxCheck.value ?? 0) > 200 : false;
1275
- return {
1276
- name,
1277
- label,
1278
- type: isLong ? "textarea" : "text",
1279
- required,
1280
- placeholder: "",
1281
- description: "",
1282
- defaultValue: ""
1283
- };
1284
- }
1285
- case "ZodNumber":
1286
- return {
1287
- name,
1288
- label,
1289
- type: "number",
1290
- required,
1291
- placeholder: "",
1292
- description: "",
1293
- defaultValue: 0
1294
- };
1295
- case "ZodBoolean":
1296
- return {
1297
- name,
1298
- label,
1299
- type: "checkbox",
1300
- required,
1301
- placeholder: "",
1302
- description: "",
1303
- defaultValue: false
1304
- };
1305
- case "ZodEnum": {
1306
- const values = inner._def.values;
1307
- return {
1308
- name,
1309
- label,
1310
- type: "select",
1311
- required,
1312
- placeholder: "",
1313
- description: "",
1314
- options: values.map((v) => ({ label: v, value: v })),
1315
- defaultValue: values[0] ?? ""
1316
- };
1317
- }
1318
- default:
1319
- return null;
1320
- }
1321
- }
1322
- function ZodFormRenderer({
1323
- schema,
1324
- defaults,
1325
- onSubmit,
1326
- submitLabel = "Submit",
1327
- isPending = false
1328
- }) {
1329
- const typeName = getTypeName(schema);
1330
- const fields = [];
1331
- const initialValues = {};
1332
- if (typeName === "ZodObject") {
1333
- const shape = schema.shape;
1334
- for (const [fieldName, fieldSchema] of Object.entries(shape)) {
1335
- const isRequired = getTypeName(fieldSchema) !== "ZodOptional" && getTypeName(fieldSchema) !== "ZodNullable";
1336
- const formField = zodTypeToFormField(fieldName, fieldSchema, isRequired);
1337
- const defaultForField = defaults?.[fieldName];
1338
- const fieldDefault = defaultForField ?? getDefaultValue(fieldSchema);
1339
- if (formField) {
1340
- fields.push(formField);
1341
- initialValues[fieldName] = fieldDefault ?? formField.defaultValue;
1342
- } else {
1343
- const raw = fieldDefault !== void 0 ? JSON.stringify(fieldDefault, null, 2) : "";
1344
- fields.push({ name: fieldName, label: fieldName, fallback: true });
1345
- initialValues[fieldName] = raw;
1346
- }
1347
- }
1348
- } else {
1349
- const raw = defaults !== void 0 ? JSON.stringify(defaults, null, 2) : "";
1350
- fields.push({ name: "__input__", label: "Input (JSON)", fallback: true });
1351
- initialValues["__input__"] = raw;
1352
- }
1353
- const form = useForm({ initialValues });
1354
- const handleSubmit = (values) => {
1355
- const coerced = {};
1356
- for (const field of fields) {
1357
- const raw = values[field.name];
1358
- if ("fallback" in field) {
1359
- try {
1360
- coerced[field.name] = raw !== "" && raw !== void 0 ? JSON.parse(raw) : void 0;
1361
- } catch {
1362
- coerced[field.name] = raw;
1363
- }
1364
- } else {
1365
- coerced[field.name] = raw;
1366
- }
1367
- }
1368
- const payload = typeName === "ZodObject" ? coerced : coerced["__input__"] ?? coerced;
1369
- const parsed = schema.safeParse(payload);
1370
- if (!parsed.success) {
1371
- for (const issue of parsed.error.issues) {
1372
- const path = issue.path.join(".");
1373
- if (path) form.setFieldError(path, issue.message);
1374
- }
1375
- return;
1376
- }
1377
- void onSubmit(parsed.data);
1378
- };
1379
- return /* @__PURE__ */ jsx("form", { onSubmit: form.onSubmit(handleSubmit), children: /* @__PURE__ */ jsxs(Stack, { children: [
1380
- fields.map((field) => {
1381
- if ("fallback" in field) {
1382
- const label = field.label.replace(/([A-Z])/g, " $1").replace(/^./, (s) => s.toUpperCase());
1383
- return /* @__PURE__ */ jsx(
1384
- Textarea,
1385
- {
1386
- label,
1387
- placeholder: "Enter JSON value",
1388
- minRows: 3,
1389
- autosize: true,
1390
- ...form.getInputProps(field.name),
1391
- error: form.errors[field.name]
1392
- },
1393
- field.name
1394
- );
1395
- }
1396
- return /* @__PURE__ */ jsx(FormFieldRenderer, { field, form }, field.name);
1397
- }),
1398
- /* @__PURE__ */ jsx(Button, { type: "submit", loading: isPending, fullWidth: true, children: submitLabel })
1399
- ] }) });
1400
- }
1401
1198
  var isZodSchema = (value) => value instanceof z.ZodType;
1402
1199
  function RunResourceButton({
1403
1200
  resourceId,
@@ -1476,7 +1273,7 @@ function ResourceCard({ resource, onClick }) {
1476
1273
  style: {
1477
1274
  cursor: "pointer",
1478
1275
  transition: "all 150ms ease",
1479
- borderColor: hovered ? "color-mix(in srgb, var(--color-primary) 40%, var(--color-border))" : "var(--color-border)",
1276
+ borderColor: hovered ? "var(--border-primary-strong)" : "var(--color-border)",
1480
1277
  boxShadow: hovered ? "var(--card-shadow), 0 0 12px color-mix(in srgb, var(--color-primary) 25%, transparent)" : "var(--card-shadow)",
1481
1278
  transform: hovered ? "translateY(-1px)" : "none"
1482
1279
  },
@@ -2069,4 +1866,4 @@ function UnresolvedErrorsTeaser({ timeRange, onNavigateToAllErrors }) {
2069
1866
  );
2070
1867
  }
2071
1868
 
2072
- export { AgentExecutionTimeline, AgentExecutionVisualizer, AgentIterationEdge, AgentIterationNode, BaseEdge, BaseNode, Dashboard, EmptyVisualizer, ExecutionStats, ExecutionStatusBadge, FormFieldRenderer, GraphBackground, GraphContainer, GraphFitViewButton, GraphFitViewHandler, GraphLegend, OperationsOverview, RecentExecutionsByResource, ResourceOverview, RunResourceButton, TimelineAxis, TimelineBar, TimelineContainer, TimelineRow, UnifiedWorkflowEdge, UnifiedWorkflowGraph, UnifiedWorkflowNode, UnresolvedErrorsTeaser, VisualizerContainer, WorkflowExecutionTimeline, ZodFormRenderer, getGraphBackgroundStyles, useGraphBackgroundStyles, useGraphTheme };
1869
+ export { AgentExecutionTimeline, AgentExecutionVisualizer, AgentIterationEdge, AgentIterationNode, BaseEdge, BaseNode, Dashboard, EmptyVisualizer, ExecutionStats, ExecutionStatusBadge, GraphBackground, GraphContainer, GraphFitViewButton, GraphFitViewHandler, GraphLegend, OperationsOverview, RecentExecutionsByResource, ResourceOverview, RunResourceButton, TimelineAxis, TimelineBar, TimelineContainer, TimelineRow, UnifiedWorkflowEdge, UnifiedWorkflowGraph, UnifiedWorkflowNode, UnresolvedErrorsTeaser, VisualizerContainer, WorkflowExecutionTimeline, getGraphBackgroundStyles, useGraphBackgroundStyles, useGraphTheme };
@@ -1,7 +1,7 @@
1
- import { AppBackground, AmbientBloomGrid, CyberBackground, FloatingMotes, WaveBackground } from './chunk-WLOQ4IBG.js';
2
- import { createElement, Fragment, createContext, useRef, useEffect, useContext } from 'react';
1
+ import { AppBackground, AmbientBloomGrid, CyberBackground, WaveBackground, FloatingMotes } from './chunk-WLOQ4IBG.js';
2
+ import { z } from 'zod';
3
+ import { createElement, Fragment, useRef, useEffect } from 'react';
3
4
  import { jsxs, Fragment as Fragment$1, jsx } from 'react/jsx-runtime';
4
- import { Tooltip, Text, Tabs, Table, Stack, SimpleGrid, Select, Combobox, SegmentedControl, ScrollArea, Paper, Popover, Notification, Modal, Menu, Input, HoverCard, Group, Grid, Flex, Drawer, Code, Divider, Card, Button, Accordion, createTheme } from '@mantine/core';
5
5
 
6
6
  // src/theme/presets/utils.ts
7
7
  function hexToRgb(hex) {
@@ -64,6 +64,29 @@ function generateShades(hex) {
64
64
  ];
65
65
  return targets.map((tl) => hslToHex(h, s, tl));
66
66
  }
67
+ var THEME_PRESETS = [
68
+ "default",
69
+ "tactical",
70
+ "regal",
71
+ "cyber-volt",
72
+ "aurora",
73
+ "rose-gold",
74
+ "midnight",
75
+ "titanium",
76
+ "canopy",
77
+ "slate",
78
+ "cyber-strike",
79
+ "cyber-chrome",
80
+ "cyber-void",
81
+ "nirvana",
82
+ "wave",
83
+ "synapse",
84
+ "cortex",
85
+ "helios",
86
+ "graphite",
87
+ "quarry"
88
+ ];
89
+ var ThemePresetEnum = z.enum(THEME_PRESETS);
67
90
  var defaultPreset = {
68
91
  subtitleFontFamily: '"Inter", sans-serif',
69
92
  fontImports: ["https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap"],
@@ -2439,373 +2462,4 @@ function getPreset(name, presetsMap) {
2439
2462
  return PRESETS[name] ?? PRESETS.default;
2440
2463
  }
2441
2464
 
2442
- // src/theme/cssVariables.ts
2443
- var TOKEN_VAR_MAP = {
2444
- primary: "--color-primary",
2445
- primaryContrast: "--color-primary-contrast",
2446
- background: "--color-background",
2447
- surface: "--color-surface",
2448
- surfaceHover: "--color-surface-hover",
2449
- elevatedSurface: "--color-elevated",
2450
- text: "--color-text",
2451
- textDimmed: "--color-text-dimmed",
2452
- textSubtle: "--color-text-subtle",
2453
- border: "--color-border",
2454
- error: "--color-error",
2455
- warning: "--color-warning",
2456
- success: "--color-success",
2457
- glassBackground: "--glass-background",
2458
- glassBlur: "--glass-blur",
2459
- shadow: "--standard-box-shadow",
2460
- cardShadow: "--card-shadow",
2461
- durationFast: "--duration-fast",
2462
- durationNormal: "--duration-normal",
2463
- easing: "--easing",
2464
- destructiveFg: "--color-destructive-fg",
2465
- fontHeading: "--font-heading",
2466
- fontSans: "--font-sans"
2467
- };
2468
- var FRAMEWORK_BRIDGE = {
2469
- "--mantine-color-text": "var(--color-text)",
2470
- "--mantine-color-body": "var(--color-background)",
2471
- "--mantine-color-dimmed": "var(--color-text-dimmed)",
2472
- // Primary color functional variants — used by Tabs, SegmentedControl, Badge, Button, etc.
2473
- "--mantine-primary-color-filled": "var(--color-primary)",
2474
- "--mantine-primary-color-filled-hover": "color-mix(in srgb, var(--color-primary) 90%, black)",
2475
- "--mantine-primary-color-light": "color-mix(in srgb, var(--color-primary) 15%, transparent)",
2476
- "--mantine-primary-color-light-hover": "color-mix(in srgb, var(--color-primary) 20%, transparent)",
2477
- "--mantine-primary-color-light-color": "var(--color-primary)",
2478
- "--mantine-primary-color-contrast": "var(--color-primary-contrast)",
2479
- // Active/selected state — used by selectable cards, active filters, plan tiers, etc.
2480
- "--active-border": "1px solid color-mix(in srgb, var(--color-primary) 40%, var(--color-border))",
2481
- "--active-background": "color-mix(in srgb, var(--color-primary) 8%, var(--color-surface))"
2482
- };
2483
- function shadesToVars(shades) {
2484
- const vars = {};
2485
- for (let i = 0; i < shades.length; i++) {
2486
- vars[`--mantine-color-primary-${i}`] = shades[i];
2487
- }
2488
- return vars;
2489
- }
2490
- function presetToVars(tokens) {
2491
- const result = {};
2492
- for (const [key, varName] of Object.entries(TOKEN_VAR_MAP)) {
2493
- const value = tokens[key];
2494
- if (value) result[varName] = value;
2495
- }
2496
- return result;
2497
- }
2498
- function mapTokens(tokens) {
2499
- if (!tokens) return {};
2500
- const result = {};
2501
- for (const [key, varName] of Object.entries(TOKEN_VAR_MAP)) {
2502
- const value = tokens[key];
2503
- if (value) result[varName] = value;
2504
- }
2505
- return result;
2506
- }
2507
- function createCssVariablesResolver(tokens, preset, presetsMap) {
2508
- const resolved = getPreset(preset ?? "default", presetsMap);
2509
- const lightDefaults = presetToVars(resolved.light);
2510
- const darkDefaults = presetToVars(resolved.dark);
2511
- const flat = mapTokens(tokens);
2512
- const light = mapTokens(tokens?.light);
2513
- const dark = mapTokens(tokens?.dark);
2514
- const lightPrimary = tokens?.light?.primary ?? tokens?.primary ?? resolved.light.primary;
2515
- const darkPrimary = tokens?.dark?.primary ?? tokens?.primary ?? resolved.dark.primary;
2516
- const lightShades = shadesToVars(generateShades(lightPrimary));
2517
- const darkShades = shadesToVars(generateShades(darkPrimary));
2518
- return () => ({
2519
- variables: { ...FRAMEWORK_BRIDGE },
2520
- light: { ...lightShades, ...lightDefaults, ...flat, ...light },
2521
- dark: { ...darkShades, ...darkDefaults, ...flat, ...dark }
2522
- });
2523
- }
2524
- var DEFAULT_SIZE = "sm";
2525
- var glassBase = {
2526
- backdropFilter: "var(--glass-blur)",
2527
- WebkitBackdropFilter: "var(--glass-blur)",
2528
- border: "1px solid var(--color-border)"
2529
- };
2530
- var componentThemes = {
2531
- Accordion: Accordion.extend({
2532
- styles: {
2533
- item: {
2534
- borderColor: "var(--color-border)"
2535
- },
2536
- content: {
2537
- backgroundColor: "var(--color-surface)"
2538
- }
2539
- }
2540
- }),
2541
- // Button data-variant selector styles are in custom.css (attribute selectors unsupported in styles object)
2542
- Button: Button.extend({
2543
- styles: {
2544
- root: {
2545
- transition: `all var(--duration-fast) var(--easing)`
2546
- }
2547
- }
2548
- }),
2549
- Card: Card.extend({
2550
- defaultProps: {
2551
- p: DEFAULT_SIZE
2552
- },
2553
- styles: {
2554
- root: {
2555
- backgroundColor: "var(--color-surface)",
2556
- ...glassBase,
2557
- boxShadow: "var(--card-shadow)"
2558
- }
2559
- }
2560
- }),
2561
- // Checkbox styles are in custom.css to support :checked pseudo-selector
2562
- Divider: Divider.extend({
2563
- styles: {
2564
- root: {
2565
- borderColor: "var(--color-border)"
2566
- }
2567
- }
2568
- }),
2569
- Code: Code.extend({
2570
- styles: {
2571
- root: {
2572
- backgroundColor: "var(--color-surface)",
2573
- border: "1px solid var(--color-border)"
2574
- }
2575
- }
2576
- }),
2577
- Drawer: Drawer.extend({
2578
- styles: {
2579
- header: {
2580
- backgroundColor: "transparent"
2581
- },
2582
- title: {
2583
- fontFamily: "var(--font-sans, var(--mantine-font-family))",
2584
- fontSize: "var(--mantine-font-size-xl)",
2585
- fontWeight: 600,
2586
- color: "var(--color-text)"
2587
- },
2588
- content: {
2589
- backgroundColor: "var(--color-elevated, var(--color-background))",
2590
- ...glassBase
2591
- }
2592
- }
2593
- }),
2594
- Flex: Flex.extend({
2595
- defaultProps: {
2596
- gap: DEFAULT_SIZE
2597
- }
2598
- }),
2599
- Grid: Grid.extend({
2600
- defaultProps: {
2601
- gutter: DEFAULT_SIZE
2602
- }
2603
- }),
2604
- Group: Group.extend({
2605
- defaultProps: {
2606
- gap: DEFAULT_SIZE
2607
- }
2608
- }),
2609
- HoverCard: HoverCard.extend({
2610
- styles: {
2611
- dropdown: {
2612
- backgroundColor: "var(--glass-background)",
2613
- ...glassBase,
2614
- boxShadow: "var(--standard-box-shadow)"
2615
- }
2616
- }
2617
- }),
2618
- Input: Input.extend({
2619
- styles: {
2620
- input: {
2621
- backgroundColor: "var(--color-surface)",
2622
- border: "none",
2623
- borderBottom: "1px solid var(--color-border)",
2624
- borderRadius: "0"
2625
- }
2626
- }
2627
- }),
2628
- Menu: Menu.extend({
2629
- styles: {
2630
- dropdown: {
2631
- backgroundColor: "var(--glass-background)",
2632
- ...glassBase,
2633
- boxShadow: "var(--standard-box-shadow)"
2634
- }
2635
- }
2636
- }),
2637
- Modal: Modal.extend({
2638
- defaultProps: {
2639
- withCloseButton: false,
2640
- centered: true,
2641
- padding: "xs"
2642
- },
2643
- styles: {
2644
- header: {
2645
- backgroundColor: "transparent"
2646
- },
2647
- title: {
2648
- fontFamily: "var(--font-sans, var(--mantine-font-family))",
2649
- fontSize: "var(--mantine-font-size-xl)",
2650
- fontWeight: 600,
2651
- color: "var(--color-text)"
2652
- },
2653
- content: {
2654
- backgroundColor: "var(--color-elevated, var(--color-background))",
2655
- ...glassBase
2656
- }
2657
- }
2658
- }),
2659
- Notification: Notification.extend({
2660
- styles: {
2661
- root: {
2662
- backgroundColor: "color-mix(in srgb, var(--color-surface) 90%, transparent)",
2663
- ...glassBase
2664
- }
2665
- }
2666
- }),
2667
- Popover: Popover.extend({
2668
- styles: {
2669
- dropdown: {
2670
- backgroundColor: "var(--glass-background)",
2671
- ...glassBase,
2672
- boxShadow: "var(--standard-box-shadow)"
2673
- }
2674
- }
2675
- }),
2676
- Paper: Paper.extend({
2677
- styles: {
2678
- root: {
2679
- backgroundColor: "var(--glass-background)",
2680
- ...glassBase,
2681
- boxShadow: "var(--card-shadow)",
2682
- padding: `var(--mantine-spacing-${DEFAULT_SIZE})`
2683
- }
2684
- }
2685
- }),
2686
- ScrollArea: ScrollArea.extend({
2687
- defaultProps: {
2688
- scrollbarSize: 8
2689
- },
2690
- styles: {
2691
- scrollbar: {
2692
- background: "transparent",
2693
- '&[data-orientation="vertical"]': {
2694
- width: "8px"
2695
- },
2696
- '&[data-orientation="horizontal"]': {
2697
- height: "8px"
2698
- }
2699
- },
2700
- thumb: {
2701
- borderRadius: "var(--mantine-radius-default)",
2702
- background: "color-mix(in srgb, var(--color-text-subtle) 50%, var(--color-border))",
2703
- "&:hover": {
2704
- background: "var(--color-text-subtle)"
2705
- }
2706
- }
2707
- }
2708
- }),
2709
- SegmentedControl: SegmentedControl.extend({
2710
- styles: {
2711
- root: {
2712
- backgroundColor: "var(--color-surface)"
2713
- },
2714
- indicator: {
2715
- backgroundColor: "var(--color-surface-hover)",
2716
- boxShadow: "var(--standard-box-shadow)"
2717
- }
2718
- }
2719
- }),
2720
- Combobox: Combobox.extend({
2721
- styles: {
2722
- dropdown: {
2723
- backgroundColor: "var(--color-surface)"
2724
- }
2725
- }
2726
- }),
2727
- Select: Select.extend({
2728
- styles: {
2729
- dropdown: {
2730
- backgroundColor: "var(--color-surface)"
2731
- }
2732
- }
2733
- }),
2734
- // Switch styles are in custom.css to support [data-checked] attribute selector
2735
- SimpleGrid: SimpleGrid.extend({
2736
- defaultProps: {
2737
- spacing: DEFAULT_SIZE,
2738
- verticalSpacing: DEFAULT_SIZE
2739
- }
2740
- }),
2741
- Stack: Stack.extend({
2742
- defaultProps: {
2743
- gap: DEFAULT_SIZE
2744
- }
2745
- }),
2746
- Table: Table.extend({
2747
- defaultProps: {
2748
- highlightOnHover: true
2749
- },
2750
- styles: {
2751
- table: {
2752
- "--table-border-color": "var(--color-border)",
2753
- "--table-highlight-on-hover-color": "var(--color-surface-hover)"
2754
- }
2755
- }
2756
- }),
2757
- Tabs: Tabs.extend({}),
2758
- Text: Text.extend({
2759
- styles: {
2760
- root: {
2761
- fontFamily: 'Roboto, Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif'
2762
- }
2763
- }
2764
- }),
2765
- // Timeline styles are in custom.css to override color-scheme-specific selectors
2766
- Tooltip: Tooltip.extend({
2767
- styles: {
2768
- tooltip: {
2769
- backgroundColor: "var(--glass-background)",
2770
- ...glassBase,
2771
- color: "var(--color-text)",
2772
- boxShadow: "var(--standard-box-shadow)"
2773
- }
2774
- }
2775
- })
2776
- // Pagination styles are in custom.css to support :not([data-active]) selector
2777
- };
2778
- var mantineThemeOverride = createTheme({
2779
- defaultRadius: "xs",
2780
- fontFamily: 'Roboto, Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',
2781
- cursorType: "pointer",
2782
- spacing: {
2783
- xs: "0.5rem",
2784
- sm: "0.75rem",
2785
- md: "1rem",
2786
- lg: "1.5rem",
2787
- xl: "2rem"
2788
- },
2789
- radius: {
2790
- xs: "0.25rem",
2791
- sm: "0.5rem",
2792
- md: "0.75rem",
2793
- lg: "1rem",
2794
- xl: "1.5rem"
2795
- },
2796
- fontSizes: {
2797
- xs: "0.75rem",
2798
- sm: "0.875rem",
2799
- md: "1rem",
2800
- lg: "1.125rem",
2801
- xl: "1.25rem"
2802
- },
2803
- components: componentThemes
2804
- });
2805
- var PresetsContext = createContext(PRESETS);
2806
- var PresetsProvider = PresetsContext.Provider;
2807
- function usePresetsContext() {
2808
- return useContext(PresetsContext);
2809
- }
2810
-
2811
- export { PRESETS, PresetsProvider, TOKEN_VAR_MAP, componentThemes, createCssVariablesResolver, generateShades, getPreset, glassBase, mantineThemeOverride, usePresetsContext };
2465
+ export { PRESETS, THEME_PRESETS, ThemePresetEnum, generateShades, getPreset };
@@ -0,0 +1,10 @@
1
+ import { useAppearance } from './chunk-E565XMTQ.js';
2
+ import { Center } from '@mantine/core';
3
+ import { jsx } from 'react/jsx-runtime';
4
+
5
+ function SubshellLoader() {
6
+ const { loader } = useAppearance();
7
+ return /* @__PURE__ */ jsx(Center, { mih: "calc(100vh - 70px)", children: loader });
8
+ }
9
+
10
+ export { SubshellLoader };