@almadar/ui 5.123.0 → 5.125.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.
Files changed (63) hide show
  1. package/dist/{TraitProvider-YkK6tXDw.d.cts → TraitProvider-Ch79cUcb.d.cts} +6 -1
  2. package/dist/{TraitProvider-YkK6tXDw.d.ts → TraitProvider-Ch79cUcb.d.ts} +6 -1
  3. package/dist/{UserContext-bziZwgFL.d.cts → UserContext-BKckAUv7.d.cts} +5 -5
  4. package/dist/{UserContext-bziZwgFL.d.ts → UserContext-BKckAUv7.d.ts} +5 -5
  5. package/dist/avl/index.cjs +332 -275
  6. package/dist/avl/index.js +334 -277
  7. package/dist/components/index.cjs +284 -248
  8. package/dist/components/index.d.cts +4 -3
  9. package/dist/components/index.d.ts +4 -3
  10. package/dist/components/index.js +284 -248
  11. package/dist/context/index.cjs +25 -66
  12. package/dist/context/index.d.cts +1 -1
  13. package/dist/context/index.d.ts +1 -1
  14. package/dist/context/index.js +25 -66
  15. package/dist/{offline-executor-aRuNznZx.d.cts → offline-executor-Qz4b6GpF.d.cts} +19 -1
  16. package/dist/{offline-executor-aRuNznZx.d.ts → offline-executor-Qz4b6GpF.d.ts} +19 -1
  17. package/dist/providers/index.cjs +395 -275
  18. package/dist/providers/index.d.cts +6 -6
  19. package/dist/providers/index.d.ts +6 -6
  20. package/dist/providers/index.js +394 -276
  21. package/dist/renderer/index.cjs +8 -0
  22. package/dist/renderer/index.d.cts +2 -2
  23. package/dist/renderer/index.d.ts +2 -2
  24. package/dist/renderer/index.js +1 -1
  25. package/dist/runtime/index.cjs +325 -268
  26. package/dist/runtime/index.d.cts +4 -2
  27. package/dist/runtime/index.d.ts +4 -2
  28. package/dist/runtime/index.js +327 -270
  29. package/package.json +13 -11
  30. package/themes/_contract.md +2 -0
  31. package/themes/almadar-website.css +3 -3
  32. package/themes/almadar.css +4 -4
  33. package/themes/bloomberg-dense.css +2 -2
  34. package/themes/clay.css +417 -0
  35. package/themes/corporate.css +411 -0
  36. package/themes/game-adventure.css +3 -3
  37. package/themes/game-rpg.css +2 -2
  38. package/themes/game-sci-fi.css +1 -1
  39. package/themes/game-ui-pack.css +2 -2
  40. package/themes/gazette.css +2 -2
  41. package/themes/glass.css +428 -0
  42. package/themes/index.css +9 -13
  43. package/themes/kiosk.css +5 -5
  44. package/themes/linear-clean.css +1 -1
  45. package/themes/minimalist.css +2 -2
  46. package/themes/neon.css +3 -3
  47. package/themes/notion-editorial.css +1 -1
  48. package/themes/prism.css +3 -3
  49. package/themes/retro.css +410 -0
  50. package/themes/terminal.css +1 -1
  51. package/themes/trait-wars.css +8 -8
  52. package/themes/wireframe.css +2 -2
  53. package/themes/arctic.css +0 -235
  54. package/themes/copper.css +0 -235
  55. package/themes/ember.css +0 -238
  56. package/themes/forest.css +0 -238
  57. package/themes/lavender.css +0 -233
  58. package/themes/midnight.css +0 -234
  59. package/themes/ocean.css +0 -238
  60. package/themes/rose.css +0 -233
  61. package/themes/sand.css +0 -234
  62. package/themes/slate.css +0 -233
  63. package/themes/sunset.css +0 -238
@@ -5176,15 +5176,15 @@ var init_TextHighlight = __esm({
5176
5176
  const typeStyles = {
5177
5177
  question: cn(
5178
5178
  // Blue border for questions
5179
- "bg-card border-b-2 border-primary-600",
5179
+ "bg-card border-b-2 border-primary",
5180
5180
  "hover:bg-muted",
5181
- isActive && "bg-primary-100 ring-2 ring-primary-600"
5181
+ isActive && "bg-primary/10 ring-2 ring-primary"
5182
5182
  ),
5183
5183
  note: cn(
5184
5184
  // Yellow border for notes
5185
- "bg-card border-b-2 border-amber-500",
5185
+ "bg-card border-b-2 border-warning",
5186
5186
  "hover:bg-muted",
5187
- isActive && "bg-amber-100 ring-2 ring-amber-500"
5187
+ isActive && "bg-warning/10 ring-2 ring-warning"
5188
5188
  )
5189
5189
  };
5190
5190
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -5530,7 +5530,7 @@ function DayCell({
5530
5530
  {
5531
5531
  className: cn(
5532
5532
  "p-2 text-center cursor-pointer hover:bg-muted transition-colors",
5533
- isToday && "bg-blue-500/10",
5533
+ isToday && "bg-primary/10",
5534
5534
  className
5535
5535
  ),
5536
5536
  onClick: handleClick,
@@ -5541,7 +5541,7 @@ function DayCell({
5541
5541
  variant: "small",
5542
5542
  className: cn(
5543
5543
  "font-medium",
5544
- isToday ? "text-blue-600" : "text-muted-foreground"
5544
+ isToday ? "text-primary" : "text-muted-foreground"
5545
5545
  ),
5546
5546
  children: dayAbbr
5547
5547
  }
@@ -5553,7 +5553,7 @@ function DayCell({
5553
5553
  rounded: "full",
5554
5554
  className: cn(
5555
5555
  "h-8 w-8 mx-auto items-center justify-center",
5556
- isToday && "bg-blue-600 text-white"
5556
+ isToday && "bg-primary text-primary-foreground"
5557
5557
  ),
5558
5558
  children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", className: "font-semibold", children: safeDate.getDate() })
5559
5559
  }
@@ -12265,19 +12265,19 @@ var init_ActivationBlock = __esm({
12265
12265
  "div",
12266
12266
  {
12267
12267
  className: cn(
12268
- "bg-indigo-50 dark:bg-indigo-900/20 border-2 border-indigo-200 dark:border-indigo-800 rounded-lg p-5 mb-6",
12268
+ "bg-primary/10 border-2 border-primary rounded-lg p-5 mb-6",
12269
12269
  className
12270
12270
  ),
12271
12271
  children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-3", children: [
12272
- /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Lightbulb, { className: "text-indigo-600 dark:text-indigo-400 flex-shrink-0 mt-1", size: 24 }),
12272
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Lightbulb, { className: "text-primary flex-shrink-0 mt-1", size: 24 }),
12273
12273
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1", children: [
12274
- /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-indigo-900 dark:text-indigo-100 mb-2", children: "Before You Begin..." }),
12275
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-gray-700 dark:text-gray-300 mb-3 text-sm md:text-base", children: question }),
12274
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-primary mb-2", children: "Before You Begin..." }),
12275
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground mb-3 text-sm md:text-base", children: question }),
12276
12276
  isExpanded ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
12277
12277
  /* @__PURE__ */ jsxRuntime.jsx(
12278
12278
  "textarea",
12279
12279
  {
12280
- className: "w-full p-3 border border-indigo-300 dark:border-indigo-700 rounded-md bg-white dark:bg-gray-800 text-gray-900 dark:text-gray-100 focus:ring-2 focus:ring-indigo-500 focus:border-transparent text-sm",
12280
+ className: "w-full p-3 border border-input rounded-md bg-card text-foreground focus:ring-2 focus:ring-ring focus:border-transparent text-sm",
12281
12281
  placeholder: "Jot down your thoughts...",
12282
12282
  value: response,
12283
12283
  onChange: (e) => setResponse(e.target.value),
@@ -12289,7 +12289,7 @@ var init_ActivationBlock = __esm({
12289
12289
  "button",
12290
12290
  {
12291
12291
  onClick: handleSubmit,
12292
- className: "px-4 py-2 bg-indigo-600 text-white rounded-md hover:bg-indigo-700 text-sm font-medium transition-colors",
12292
+ className: "px-4 py-2 bg-primary text-primary-foreground rounded-md hover:bg-primary-hover text-sm font-medium transition-colors",
12293
12293
  children: "Continue to Lesson \u2192"
12294
12294
  }
12295
12295
  ),
@@ -12300,7 +12300,7 @@ var init_ActivationBlock = __esm({
12300
12300
  emit(`UI:${saveEvent}`, { response: "" });
12301
12301
  setIsExpanded(false);
12302
12302
  },
12303
- className: "px-4 py-2 text-indigo-600 dark:text-indigo-400 hover:underline text-sm",
12303
+ className: "px-4 py-2 text-primary hover:underline text-sm",
12304
12304
  children: "Skip for now"
12305
12305
  }
12306
12306
  )
@@ -12309,7 +12309,7 @@ var init_ActivationBlock = __esm({
12309
12309
  "button",
12310
12310
  {
12311
12311
  onClick: () => setIsExpanded(true),
12312
- className: "text-sm text-indigo-600 dark:text-indigo-400 hover:underline font-medium",
12312
+ className: "text-sm text-primary hover:underline font-medium",
12313
12313
  children: "\u2713 Answered \xB7 Edit response"
12314
12314
  }
12315
12315
  )
@@ -12813,7 +12813,7 @@ var init_AuthLayout = __esm({
12813
12813
  VStack,
12814
12814
  {
12815
12815
  className: cn(
12816
- "hidden lg:flex lg:w-1/2 bg-primary-600 relative overflow-hidden",
12816
+ "hidden lg:flex lg:w-1/2 bg-primary relative overflow-hidden",
12817
12817
  "justify-between p-12"
12818
12818
  ),
12819
12819
  style: backgroundImage ? {
@@ -12822,7 +12822,7 @@ var init_AuthLayout = __esm({
12822
12822
  } : void 0,
12823
12823
  gap: "none",
12824
12824
  children: [
12825
- /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "absolute inset-0 bg-gradient-to-br from-primary-600/90 to-primary-800/90" }),
12825
+ /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "absolute inset-0 bg-gradient-to-br from-primary/90 to-primary-hover/90" }),
12826
12826
  /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "relative z-10", children: /* @__PURE__ */ jsxRuntime.jsxs(reactRouterDom.Link, { to: "/", className: "flex items-center gap-3", children: [
12827
12827
  logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-10 h-10 bg-[var(--color-card)]/20 rounded-xl flex items-center justify-center backdrop-blur", children: /* @__PURE__ */ jsxRuntime.jsx(
12828
12828
  Typography,
@@ -12907,7 +12907,7 @@ var init_AuthLayout = __esm({
12907
12907
  ),
12908
12908
  children: /* @__PURE__ */ jsxRuntime.jsxs(Box, { className: "w-full max-w-md", children: [
12909
12909
  /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "lg:hidden mb-8 text-center", children: /* @__PURE__ */ jsxRuntime.jsxs(reactRouterDom.Link, { to: "/", className: "inline-flex items-center gap-3", children: [
12910
- logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-12 h-12 bg-primary-600 rounded-xl flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
12910
+ logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-12 h-12 bg-primary rounded-xl flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
12911
12911
  Typography,
12912
12912
  {
12913
12913
  variant: "body1",
@@ -14898,7 +14898,7 @@ var init_CodeBlock = __esm({
14898
14898
  {
14899
14899
  justify: "between",
14900
14900
  align: "center",
14901
- className: "px-3 py-2 bg-[var(--color-card)] rounded-t-lg border-b border-gray-700",
14901
+ className: "px-3 py-2 bg-[var(--color-card)] rounded-t-lg border-b border-border",
14902
14902
  children: [
14903
14903
  showLanguageBadge && /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "default", size: "sm", children: language }),
14904
14904
  effectiveCopy && /* @__PURE__ */ jsxRuntime.jsx(
@@ -14907,9 +14907,9 @@ var init_CodeBlock = __esm({
14907
14907
  variant: "ghost",
14908
14908
  size: "sm",
14909
14909
  onClick: handleCopy,
14910
- className: "opacity-0 group-hover:opacity-100 focus:opacity-100 transition-opacity text-muted-foreground hover:text-white",
14910
+ className: "opacity-0 group-hover:opacity-100 focus:opacity-100 transition-opacity text-muted-foreground hover:text-foreground",
14911
14911
  "aria-label": t("common.copy"),
14912
- children: copied ? /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "check", className: "w-4 h-4 text-green-400" }) : /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "copy", className: "w-4 h-4" })
14912
+ children: copied ? /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "check", className: "w-4 h-4 text-success" }) : /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "copy", className: "w-4 h-4" })
14913
14913
  }
14914
14914
  )
14915
14915
  ]
@@ -15277,12 +15277,12 @@ var init_BloomQuizBlock = __esm({
15277
15277
  init_useEventBus();
15278
15278
  init_cn();
15279
15279
  BLOOM_CONFIG = {
15280
- remember: { color: "bg-gray-500", bgColor: "bg-gray-50 dark:bg-gray-900/30", label: "Remember" },
15281
- understand: { color: "bg-blue-500", bgColor: "bg-blue-50 dark:bg-blue-900/30", label: "Understand" },
15282
- apply: { color: "bg-green-500", bgColor: "bg-green-50 dark:bg-green-900/30", label: "Apply" },
15283
- analyze: { color: "bg-yellow-500", bgColor: "bg-yellow-50 dark:bg-yellow-900/30", label: "Analyze" },
15284
- evaluate: { color: "bg-orange-500", bgColor: "bg-orange-50 dark:bg-orange-900/30", label: "Evaluate" },
15285
- create: { color: "bg-purple-500", bgColor: "bg-purple-50 dark:bg-purple-900/30", label: "Create" }
15280
+ remember: { color: "bg-secondary text-secondary-foreground", bgColor: "bg-muted", label: "Remember" },
15281
+ understand: { color: "bg-info text-info-foreground", bgColor: "bg-info/10", label: "Understand" },
15282
+ apply: { color: "bg-success text-success-foreground", bgColor: "bg-success/10", label: "Apply" },
15283
+ analyze: { color: "bg-warning text-warning-foreground", bgColor: "bg-warning/10", label: "Analyze" },
15284
+ evaluate: { color: "bg-accent text-accent-foreground", bgColor: "bg-accent/10", label: "Evaluate" },
15285
+ create: { color: "bg-primary text-primary-foreground", bgColor: "bg-primary/10", label: "Create" }
15286
15286
  };
15287
15287
  BloomQuizBlock = ({
15288
15288
  level,
@@ -15308,22 +15308,22 @@ var init_BloomQuizBlock = __esm({
15308
15308
  "div",
15309
15309
  {
15310
15310
  className: cn(
15311
- "rounded-lg border border-indigo-100 dark:border-indigo-800 p-4 my-4 transition-all",
15311
+ "rounded-lg border border-primary p-4 my-4 transition-all",
15312
15312
  config.bgColor,
15313
15313
  className
15314
15314
  ),
15315
15315
  children: [
15316
15316
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mb-3", children: [
15317
15317
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 flex-wrap", children: [
15318
- index !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-gray-500 dark:text-gray-400 font-medium text-sm", children: [
15318
+ index !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-muted-foreground font-medium text-sm", children: [
15319
15319
  "Question ",
15320
15320
  index + 1
15321
15321
  ] }),
15322
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn(config.color, "text-white text-xs px-2 py-1 rounded-full font-medium"), children: config.label })
15322
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn(config.color, "text-xs px-2 py-1 rounded-full font-medium"), children: config.label })
15323
15323
  ] }),
15324
- isAnswered && /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.CheckCircle, { className: "text-green-600 dark:text-green-400 flex-shrink-0", size: 20 })
15324
+ isAnswered && /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.CheckCircle, { className: "text-success flex-shrink-0", size: 20 })
15325
15325
  ] }),
15326
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "font-semibold text-indigo-900 dark:text-indigo-200 mb-3 space-y-2", children: questionSegments.map(
15326
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "font-semibold text-primary mb-3 space-y-2", children: questionSegments.map(
15327
15327
  (segment, idx) => segment.type === "markdown" ? /* @__PURE__ */ jsxRuntime.jsx(MarkdownContent, { content: segment.content }, `q-md-${idx}`) : /* @__PURE__ */ jsxRuntime.jsx(
15328
15328
  CodeBlock,
15329
15329
  {
@@ -15337,13 +15337,13 @@ var init_BloomQuizBlock = __esm({
15337
15337
  "button",
15338
15338
  {
15339
15339
  type: "button",
15340
- className: "inline-flex items-center rounded-md bg-indigo-600 dark:bg-indigo-500 px-3 py-1.5 text-sm font-medium text-white hover:bg-indigo-700 dark:hover:bg-indigo-600 transition-colors",
15340
+ className: "inline-flex items-center rounded-md bg-primary px-3 py-1.5 text-sm font-medium text-primary-foreground hover:bg-primary-hover transition-colors",
15341
15341
  onClick: handleReveal,
15342
15342
  children: revealed ? "Hide Answer" : "Reveal Answer"
15343
15343
  }
15344
15344
  ),
15345
- revealed && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-lg bg-white/80 dark:bg-gray-800/80 p-3 text-sm text-slate-800 dark:text-gray-200 shadow-sm border border-indigo-100 dark:border-indigo-800 mt-3 space-y-2", children: [
15346
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs text-gray-600 dark:text-gray-400 mb-1 font-medium uppercase tracking-wide", children: "Answer:" }),
15345
+ revealed && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rounded-lg bg-card/80 p-3 text-sm text-foreground shadow-sm border border-primary mt-3 space-y-2", children: [
15346
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs text-muted-foreground mb-1 font-medium uppercase tracking-wide", children: "Answer:" }),
15347
15347
  answerSegments.map(
15348
15348
  (segment, idx) => segment.type === "markdown" ? /* @__PURE__ */ jsxRuntime.jsx(MarkdownContent, { content: segment.content }, `a-md-${idx}`) : /* @__PURE__ */ jsxRuntime.jsx(
15349
15349
  CodeBlock,
@@ -15567,12 +15567,12 @@ var init_QuizBlock = __esm({
15567
15567
  }) => {
15568
15568
  const { t } = hooks.useTranslate();
15569
15569
  const [revealed, setRevealed] = React82.useState(false);
15570
- return /* @__PURE__ */ jsxRuntime.jsx(Card2, { className: cn("my-4 border-blue-200 dark:border-blue-800", className), children: /* @__PURE__ */ jsxRuntime.jsxs(VStack, { gap: "sm", className: "p-4", children: [
15570
+ return /* @__PURE__ */ jsxRuntime.jsx(Card2, { className: cn("my-4 border-primary", className), children: /* @__PURE__ */ jsxRuntime.jsxs(VStack, { gap: "sm", className: "p-4", children: [
15571
15571
  /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", align: "start", children: [
15572
- /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: LucideIcons2.HelpCircle, size: "sm", className: "text-blue-500 mt-0.5 shrink-0" }),
15572
+ /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: LucideIcons2.HelpCircle, size: "sm", className: "text-primary mt-0.5 shrink-0" }),
15573
15573
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", className: "font-medium", children: question })
15574
15574
  ] }),
15575
- revealed ? /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "pl-7 pt-2 border-t border-gray-200 dark:border-gray-700", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", className: "text-foreground", children: answer }) }) : null,
15575
+ revealed ? /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "pl-7 pt-2 border-t border-border", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", className: "text-foreground", children: answer }) }) : null,
15576
15576
  /* @__PURE__ */ jsxRuntime.jsx(
15577
15577
  Button,
15578
15578
  {
@@ -17484,7 +17484,7 @@ var init_BookTableOfContents = __esm({
17484
17484
  className: cn(
17485
17485
  "justify-start text-left w-full",
17486
17486
  direction === "rtl" && "text-right",
17487
- isCurrent && "bg-blue-50 dark:bg-blue-950 text-blue-600 dark:text-blue-400"
17487
+ isCurrent && "bg-primary/10 text-primary"
17488
17488
  ),
17489
17489
  children: /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "truncate", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", children: String(chapter.title ?? "") }) })
17490
17490
  },
@@ -18665,7 +18665,7 @@ function CalendarGrid({
18665
18665
  border: true,
18666
18666
  className: cn(
18667
18667
  "cursor-pointer hover:shadow-sm transition-shadow text-xs truncate",
18668
- color ? color : "bg-blue-500/15 border-blue-500/30 text-blue-600"
18668
+ color ? color : "bg-primary/10 border-primary/30 text-primary"
18669
18669
  ),
18670
18670
  onClick: (e) => handleEventClick(event, e),
18671
18671
  children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "truncate font-medium", children: event.title })
@@ -18763,7 +18763,7 @@ function CalendarGrid({
18763
18763
  onClick: () => handleSlotClick(day, time),
18764
18764
  className: cn(
18765
18765
  "border-l border-border",
18766
- isToday && "bg-blue-50/30"
18766
+ isToday && "bg-primary/10"
18767
18767
  ),
18768
18768
  ...longPressEvent ? {
18769
18769
  onPointerDown: () => startLongPress(day, time),
@@ -20779,31 +20779,31 @@ var init_CodeRunnerPanel = __esm({
20779
20779
  }
20780
20780
  )
20781
20781
  ] }),
20782
- hasOutput && /* @__PURE__ */ jsxRuntime.jsxs(Box, { className: "rounded-lg border border-gray-700 bg-[#0d0d0d] overflow-hidden", children: [
20782
+ hasOutput && /* @__PURE__ */ jsxRuntime.jsxs(Box, { className: "rounded-lg border border-border bg-foreground overflow-hidden", children: [
20783
20783
  /* @__PURE__ */ jsxRuntime.jsxs(
20784
20784
  HStack,
20785
20785
  {
20786
20786
  gap: "sm",
20787
20787
  align: "center",
20788
- className: "px-3 py-2 bg-gray-800 border-b border-gray-700",
20788
+ className: "px-3 py-2 bg-card border-b border-border",
20789
20789
  children: [
20790
- /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Terminal, { size: 16, className: "text-gray-400" }),
20791
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-300 font-medium", children: "Output" })
20790
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Terminal, { size: 16, className: "text-muted-foreground" }),
20791
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-foreground font-medium", children: "Output" })
20792
20792
  ]
20793
20793
  }
20794
20794
  ),
20795
- /* @__PURE__ */ jsxRuntime.jsx(VStack, { gap: "none", className: "p-3 font-mono text-sm", children: error ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-red-400 whitespace-pre-wrap", children: error }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
20796
- output?.stdout ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-200 whitespace-pre-wrap", children: output.stdout }) : null,
20797
- output?.stderr ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-red-400 whitespace-pre-wrap", children: output.stderr }) : null,
20798
- !output?.stdout && !output?.stderr ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500 italic", children: "No output" }) : null,
20799
- output && output.testResults.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "mt-3 pt-3 border-t border-gray-700 space-y-2", children: output.testResults.map((test, index) => /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", align: "start", className: "text-xs", children: [
20800
- test.passed ? /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.CheckCircle, { size: 14, className: "text-green-400 mt-0.5" }) : /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.XCircle, { size: 14, className: "text-red-400 mt-0.5" }),
20795
+ /* @__PURE__ */ jsxRuntime.jsx(VStack, { gap: "none", className: "p-3 font-mono text-sm", children: error ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-error whitespace-pre-wrap", children: error }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
20796
+ output?.stdout ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-background whitespace-pre-wrap", children: output.stdout }) : null,
20797
+ output?.stderr ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-error whitespace-pre-wrap", children: output.stderr }) : null,
20798
+ !output?.stdout && !output?.stderr ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-background italic", children: "No output" }) : null,
20799
+ output && output.testResults.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "mt-3 pt-3 border-t border-border space-y-2", children: output.testResults.map((test, index) => /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", align: "start", className: "text-xs", children: [
20800
+ test.passed ? /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.CheckCircle, { size: 14, className: "text-success mt-0.5" }) : /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.XCircle, { size: 14, className: "text-error mt-0.5" }),
20801
20801
  /* @__PURE__ */ jsxRuntime.jsxs(VStack, { gap: "xs", className: "flex-1", children: [
20802
20802
  /* @__PURE__ */ jsxRuntime.jsxs(
20803
20803
  Typography,
20804
20804
  {
20805
20805
  variant: "small",
20806
- className: test.passed ? "text-green-400" : "text-red-400",
20806
+ className: test.passed ? "text-success" : "text-error",
20807
20807
  children: [
20808
20808
  "Test ",
20809
20809
  index + 1,
@@ -20812,15 +20812,15 @@ var init_CodeRunnerPanel = __esm({
20812
20812
  ]
20813
20813
  }
20814
20814
  ),
20815
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-gray-400", children: [
20815
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-background", children: [
20816
20816
  "Input: ",
20817
20817
  test.input
20818
20818
  ] }),
20819
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-gray-400", children: [
20819
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-background", children: [
20820
20820
  "Expected: ",
20821
20821
  test.expectedOutput
20822
20822
  ] }),
20823
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-gray-400", children: [
20823
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-background", children: [
20824
20824
  "Actual: ",
20825
20825
  test.actualOutput
20826
20826
  ] })
@@ -21005,14 +21005,14 @@ var init_ConnectionBlock = __esm({
21005
21005
  "div",
21006
21006
  {
21007
21007
  className: cn(
21008
- "bg-emerald-50 dark:bg-emerald-900/20 border-l-4 border-emerald-500 rounded-r-lg p-5 mb-6",
21008
+ "bg-success/10 border-l-4 border-success rounded-r-lg p-5 mb-6",
21009
21009
  className
21010
21010
  ),
21011
21011
  children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-3", children: [
21012
- /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Link2, { className: "text-emerald-600 dark:text-emerald-400 flex-shrink-0 mt-1", size: 20 }),
21012
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Link2, { className: "text-success flex-shrink-0 mt-1", size: 20 }),
21013
21013
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1", children: [
21014
- /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-emerald-900 dark:text-emerald-100 mb-2", children: "Building On What You Know" }),
21015
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "prose dark:prose-invert prose-sm max-w-none text-gray-700 dark:text-gray-300", children: /* @__PURE__ */ jsxRuntime.jsx(MarkdownContent, { content }) })
21014
+ /* @__PURE__ */ jsxRuntime.jsx("h4", { className: "font-semibold text-success mb-2", children: "Building On What You Know" }),
21015
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "prose dark:prose-invert prose-sm max-w-none text-foreground", children: /* @__PURE__ */ jsxRuntime.jsx(MarkdownContent, { content }) })
21016
21016
  ] })
21017
21017
  ] })
21018
21018
  }
@@ -21099,7 +21099,7 @@ function CounterStandard({
21099
21099
  variant: "h1",
21100
21100
  className: cn(
21101
21101
  sizeStyles8[size].display,
21102
- "font-bold tabular-nums text-primary-600"
21102
+ "font-bold tabular-nums text-primary"
21103
21103
  ),
21104
21104
  children: resolved.count
21105
21105
  }
@@ -21172,7 +21172,7 @@ function CounterFull({
21172
21172
  variant: "h1",
21173
21173
  className: cn(
21174
21174
  sizeStyles8[size].display,
21175
- "font-bold tabular-nums text-primary-600"
21175
+ "font-bold tabular-nums text-primary"
21176
21176
  ),
21177
21177
  children: resolved.count
21178
21178
  }
@@ -21419,11 +21419,11 @@ var init_DashboardLayout = __esm({
21419
21419
  className: "h-16 px-4 border-b border-border dark:border-border",
21420
21420
  children: [
21421
21421
  /* @__PURE__ */ jsxRuntime.jsxs(reactRouterDom.Link, { to: "/", className: "flex items-center gap-2", children: [
21422
- logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-8 h-8 bg-primary-600 rounded-lg flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
21422
+ logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-8 h-8 bg-primary rounded-lg flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
21423
21423
  Typography,
21424
21424
  {
21425
21425
  variant: "small",
21426
- className: "text-white font-bold text-sm",
21426
+ className: "text-primary-foreground font-bold text-sm",
21427
21427
  as: "span",
21428
21428
  children: appName.charAt(0).toUpperCase()
21429
21429
  }
@@ -21502,11 +21502,11 @@ var init_DashboardLayout = __esm({
21502
21502
  className: "hidden @md/dashboard:flex items-center gap-1 overflow-x-auto",
21503
21503
  children: [
21504
21504
  /* @__PURE__ */ jsxRuntime.jsxs(reactRouterDom.Link, { to: "/", className: "flex items-center gap-2 mr-3 shrink-0", children: [
21505
- logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-7 h-7 bg-primary-600 rounded-lg flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
21505
+ logo || /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-7 h-7 bg-primary rounded-lg flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
21506
21506
  Typography,
21507
21507
  {
21508
21508
  variant: "small",
21509
- className: "text-white font-bold text-xs",
21509
+ className: "text-primary-foreground font-bold text-xs",
21510
21510
  as: "span",
21511
21511
  children: appName.charAt(0).toUpperCase()
21512
21512
  }
@@ -21566,8 +21566,8 @@ var init_DashboardLayout = __esm({
21566
21566
  {
21567
21567
  as: "span",
21568
21568
  className: cn(
21569
- "absolute -top-0.5 -right-0.5 min-w-[18px] h-[18px] px-1 rounded-full text-xs font-semibold text-white flex items-center justify-center",
21570
- action.variant === "danger" ? "bg-error" : action.variant === "primary" ? "bg-primary" : "bg-foreground"
21569
+ "absolute -top-0.5 -right-0.5 min-w-[18px] h-[18px] px-1 rounded-full text-xs font-semibold flex items-center justify-center",
21570
+ action.variant === "danger" ? "bg-error text-error-foreground" : action.variant === "primary" ? "bg-primary text-primary-foreground" : "bg-foreground text-background"
21571
21571
  ),
21572
21572
  children: action.badge
21573
21573
  }
@@ -21589,7 +21589,7 @@ var init_DashboardLayout = __esm({
21589
21589
  Box,
21590
21590
  {
21591
21591
  as: "span",
21592
- className: "absolute -top-0.5 -right-0.5 min-w-[18px] h-[18px] px-1 bg-error rounded-full text-xs font-semibold text-white flex items-center justify-center",
21592
+ className: "absolute -top-0.5 -right-0.5 min-w-[18px] h-[18px] px-1 bg-error rounded-full text-xs font-semibold text-error-foreground flex items-center justify-center",
21593
21593
  children: unreadCount > 99 ? "99+" : unreadCount
21594
21594
  }
21595
21595
  )
@@ -21872,7 +21872,7 @@ function SubMenu({
21872
21872
  ),
21873
21873
  children: [
21874
21874
  item.icon && (typeof item.icon === "string" ? /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: item.icon, size: "sm", className: "flex-shrink-0" }) : /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: item.icon, size: "sm", className: "flex-shrink-0" })),
21875
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: cn("flex-1", isDanger && "text-red-600"), children: item.label }),
21875
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: cn("flex-1", isDanger && "text-error"), children: item.label }),
21876
21876
  item.badge !== void 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-auto text-xs font-medium", children: item.badge })
21877
21877
  ]
21878
21878
  },
@@ -21929,7 +21929,7 @@ function MenuItemRow({
21929
21929
  Typography,
21930
21930
  {
21931
21931
  variant: "small",
21932
- className: cn("flex-1", isDanger && "text-red-600"),
21932
+ className: cn("flex-1", isDanger && "text-error"),
21933
21933
  children: item.label
21934
21934
  }
21935
21935
  ),
@@ -22697,20 +22697,24 @@ function DataGrid({
22697
22697
  const bodyFields = fieldDefs.filter((f3) => f3 !== titleField && !badgeFields.includes(f3));
22698
22698
  const primaryActions = actionDefs.filter((a) => a.variant !== "danger");
22699
22699
  const dangerActions = actionDefs.filter((a) => a.variant === "danger");
22700
- const handleActionClick = (action, itemData) => (e) => {
22701
- e.stopPropagation();
22702
- const payload = {
22703
- id: itemData.id,
22704
- row: itemData
22705
- };
22706
- eventBus.emit(`UI:${action.event}`, payload);
22700
+ const fireAction = (action, itemData) => {
22707
22701
  if (action.navigatesTo) {
22708
22702
  const url = action.navigatesTo.replace(
22709
22703
  /\{\{row\.(\w+(?:\.\w+)*)\}\}/g,
22710
22704
  (_, field) => String(itemData[field] ?? "")
22711
22705
  );
22712
- eventBus.emit("UI:NAVIGATE", { url });
22706
+ eventBus.emit("UI:NAVIGATE", { url, row: itemData });
22707
+ return;
22713
22708
  }
22709
+ const payload = {
22710
+ id: itemData.id,
22711
+ row: itemData
22712
+ };
22713
+ eventBus.emit(`UI:${action.event}`, payload);
22714
+ };
22715
+ const handleActionClick = (action, itemData) => (e) => {
22716
+ e.stopPropagation();
22717
+ fireAction(action, itemData);
22714
22718
  };
22715
22719
  const hasRenderProp = typeof children === "function";
22716
22720
  React82.useEffect(() => {
@@ -22812,10 +22816,7 @@ function DataGrid({
22812
22816
  label: action.label,
22813
22817
  icon: action.icon,
22814
22818
  event: action.event,
22815
- onClick: () => eventBus.emit(`UI:${action.event}`, {
22816
- id: itemData.id,
22817
- row: itemData
22818
- })
22819
+ onClick: () => fireAction(action, itemData)
22819
22820
  }))
22820
22821
  }
22821
22822
  )
@@ -22868,13 +22869,13 @@ function DataGrid({
22868
22869
  }
22869
22870
  ),
22870
22871
  /* @__PURE__ */ jsxRuntime.jsxs(VStack, { gap: "xs", className: "flex-1 min-w-0", children: [
22871
- titleValue !== void 0 && titleValue !== null && /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "xs", className: "items-center", children: [
22872
+ titleValue !== void 0 && titleValue !== null && /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "xs", className: "items-center min-w-0", children: [
22872
22873
  titleField?.icon && renderIconInput(titleField.icon, { size: "sm", className: "text-primary flex-shrink-0" }),
22873
22874
  /* @__PURE__ */ jsxRuntime.jsx(
22874
22875
  Typography,
22875
22876
  {
22876
22877
  variant: titleField?.variant === "h3" ? "h3" : "h4",
22877
- className: "font-semibold truncate",
22878
+ className: "font-semibold truncate min-w-0",
22878
22879
  children: String(titleValue)
22879
22880
  }
22880
22881
  )
@@ -22932,7 +22933,7 @@ function DataGrid({
22932
22933
  )
22933
22934
  ] }, field.name);
22934
22935
  }) }) }),
22935
- primaryActions.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "px-4 py-3 mt-auto border-t border-border", children: /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", className: "justify-end", children: [
22936
+ primaryActions.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "px-4 py-3 mt-auto border-t border-border", children: /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", className: "justify-end flex-wrap", children: [
22936
22937
  (maxInlineActions != null ? primaryActions.slice(0, maxInlineActions) : primaryActions).map((action, idx) => /* @__PURE__ */ jsxRuntime.jsxs(
22937
22938
  Button,
22938
22939
  {
@@ -22957,10 +22958,7 @@ function DataGrid({
22957
22958
  label: action.label,
22958
22959
  icon: action.icon,
22959
22960
  event: action.event,
22960
- onClick: () => eventBus.emit(`UI:${action.event}`, {
22961
- id: itemData.id,
22962
- row: itemData
22963
- })
22961
+ onClick: () => fireAction(action, itemData)
22964
22962
  }))
22965
22963
  }
22966
22964
  )
@@ -24823,8 +24821,8 @@ var init_RelationSelect = __esm({
24823
24821
  disabled,
24824
24822
  className: cn(
24825
24823
  "w-full justify-between font-normal",
24826
- error && "border-red-300 focus:border-red-500 focus:ring-red-500",
24827
- isOpen && "ring-2 ring-primary-500 border-primary-500"
24824
+ error && "border-error/50 focus:border-error focus:ring-error",
24825
+ isOpen && "ring-2 ring-primary border-primary"
24828
24826
  ),
24829
24827
  children: [
24830
24828
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -24904,7 +24902,7 @@ var init_RelationSelect = __esm({
24904
24902
  paddingY: "sm",
24905
24903
  className: cn(
24906
24904
  "text-left text-sm hover:bg-muted focus:outline-none focus:bg-muted",
24907
- option.value === value && "bg-primary-50 text-primary-700",
24905
+ option.value === value && "bg-primary/10 text-primary",
24908
24906
  option.disabled && "opacity-50 cursor-not-allowed"
24909
24907
  ),
24910
24908
  onClick: () => handleSelect(option),
@@ -25061,7 +25059,7 @@ var init_SidePanel = __esm({
25061
25059
  showOverlay && /* @__PURE__ */ jsxRuntime.jsx(Presence, { show: isOpen, animation: "overlay", children: /* @__PURE__ */ jsxRuntime.jsx(
25062
25060
  Box,
25063
25061
  {
25064
- className: "fixed inset-0 bg-white/80 backdrop-blur-sm z-40 lg:hidden",
25062
+ className: "fixed inset-0 bg-background/80 backdrop-blur-sm z-40 lg:hidden",
25065
25063
  onClick: handleClose
25066
25064
  }
25067
25065
  ) }),
@@ -25428,7 +25426,7 @@ var init_WizardNavigation = __esm({
25428
25426
  /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "chevron-left", size: "sm" }),
25429
25427
  resolvedBackLabel
25430
25428
  ] }) : /* @__PURE__ */ jsxRuntime.jsx(Box, {}),
25431
- /* @__PURE__ */ jsxRuntime.jsx(HStack, { align: "center", gap: "sm", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "caption", className: "text-neutral-500", children: t("wizard.stepOf", { current: String(currentStep + 1), total: String(totalSteps) }) }) }),
25429
+ /* @__PURE__ */ jsxRuntime.jsx(HStack, { align: "center", gap: "sm", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "caption", className: "text-muted-foreground", children: t("wizard.stepOf", { current: String(currentStep + 1), total: String(totalSteps) }) }) }),
25432
25430
  isLastStep && showComplete ? /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "primary", onClick: handleComplete, disabled: !isValid, children: resolvedCompleteLabel }) : showNext ? /* @__PURE__ */ jsxRuntime.jsxs(Button, { variant: "primary", onClick: handleNext, disabled: !isValid, children: [
25433
25431
  resolvedNextLabel,
25434
25432
  /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "chevron-right", size: "sm" })
@@ -27585,6 +27583,7 @@ var init_Lightbox = __esm({
27585
27583
  {
27586
27584
  className: cn(
27587
27585
  "fixed inset-0 z-50 flex items-center justify-center",
27586
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: lightbox scrim behind images
27588
27587
  "bg-black bg-opacity-90",
27589
27588
  className
27590
27589
  ),
@@ -27607,7 +27606,7 @@ var init_Lightbox = __esm({
27607
27606
  "p-2 rounded-full",
27608
27607
  "text-[var(--color-foreground)] bg-[var(--color-card)]",
27609
27608
  "hover:bg-opacity-70 transition-opacity",
27610
- "focus:outline-none focus:ring-2 focus:ring-white"
27609
+ "focus:outline-none focus:ring-2 focus:ring-ring"
27611
27610
  ),
27612
27611
  "aria-label": t("aria.closeModal"),
27613
27612
  children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "x", className: "w-6 h-6" })
@@ -27626,7 +27625,7 @@ var init_Lightbox = __esm({
27626
27625
  "p-2 rounded-full",
27627
27626
  "text-[var(--color-foreground)] bg-[var(--color-card)]",
27628
27627
  "hover:bg-opacity-70 transition-opacity",
27629
- "focus:outline-none focus:ring-2 focus:ring-white"
27628
+ "focus:outline-none focus:ring-2 focus:ring-ring"
27630
27629
  ),
27631
27630
  "aria-label": t("aria.previousImage"),
27632
27631
  children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "chevron-left", className: "w-8 h-8" })
@@ -27663,7 +27662,7 @@ var init_Lightbox = __esm({
27663
27662
  "p-2 rounded-full",
27664
27663
  "text-[var(--color-foreground)] bg-[var(--color-card)]",
27665
27664
  "hover:bg-opacity-70 transition-opacity",
27666
- "focus:outline-none focus:ring-2 focus:ring-white"
27665
+ "focus:outline-none focus:ring-2 focus:ring-ring"
27667
27666
  ),
27668
27667
  "aria-label": t("aria.nextImage"),
27669
27668
  children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "chevron-right", className: "w-8 h-8" })
@@ -27883,7 +27882,7 @@ function TableView({
27883
27882
  col.key
27884
27883
  );
27885
27884
  }),
27886
- hasActions && /* @__PURE__ */ jsxRuntime.jsx(Box, { "aria-hidden": true })
27885
+ hasActions && /* @__PURE__ */ jsxRuntime.jsx(Box, { "aria-hidden": true, className: "sticky right-0 bg-[var(--color-surface-subtle)]" })
27887
27886
  ]
27888
27887
  }
27889
27888
  );
@@ -27927,41 +27926,54 @@ function TableView({
27927
27926
  }
27928
27927
  return /* @__PURE__ */ jsxRuntime.jsx(Box, { role: "cell", className: cellBase, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate", children: formatCell(raw, col.format) }) }, col.key);
27929
27928
  }),
27930
- itemActions && itemActions.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "xs", className: "justify-end flex-shrink-0 opacity-60 group-hover:opacity-100 transition-opacity", children: [
27931
- (maxInlineActions != null ? itemActions.slice(0, maxInlineActions) : itemActions).map((action, i) => /* @__PURE__ */ jsxRuntime.jsxs(
27932
- Button,
27933
- {
27934
- variant: action.variant ?? "ghost",
27935
- size: "sm",
27936
- onClick: handleActionClick(action, row),
27937
- "data-testid": `action-${action.event}`,
27938
- "data-row-id": String(row.id),
27939
- className: cn(action.variant === "danger" && "text-error hover:bg-error/10"),
27940
- children: [
27941
- action.icon && renderIconInput3(action.icon, { size: "xs", className: "mr-1" }),
27942
- action.label
27943
- ]
27944
- },
27945
- i
27946
- )),
27947
- maxInlineActions != null && itemActions.length > maxInlineActions && /* @__PURE__ */ jsxRuntime.jsx(
27948
- Menu,
27949
- {
27950
- position: "bottom-end",
27951
- trigger: /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", size: "sm", "aria-label": t("common.actions"), "data-testid": "action-overflow", children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "more-horizontal", size: "xs" }) }),
27952
- items: itemActions.slice(maxInlineActions).map((action) => ({
27953
- label: action.label,
27954
- icon: action.icon,
27955
- event: action.event,
27956
- variant: action.variant === "danger" ? "danger" : "default",
27957
- onClick: () => eventBus.emit(`UI:${action.event}`, {
27958
- id: row.id,
27959
- row
27960
- })
27961
- }))
27962
- }
27963
- )
27964
- ] })
27929
+ itemActions && itemActions.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(
27930
+ HStack,
27931
+ {
27932
+ gap: "xs",
27933
+ className: cn(
27934
+ // Pinned: the fixed column tracks routinely overflow the caller's
27935
+ // scroll container, which used to leave the actions off-screen.
27936
+ // Opaque so scrolled cells pass underneath it.
27937
+ "justify-end flex-shrink-0 sticky right-0 z-[1] transition-colors",
27938
+ lk.striped && index % 2 === 1 ? "bg-[var(--color-surface-subtle)]" : "bg-[var(--color-card)] group-hover:bg-[var(--color-surface-subtle)]"
27939
+ ),
27940
+ children: [
27941
+ (maxInlineActions != null ? itemActions.slice(0, maxInlineActions) : itemActions).map((action, i) => /* @__PURE__ */ jsxRuntime.jsxs(
27942
+ Button,
27943
+ {
27944
+ variant: action.variant ?? "ghost",
27945
+ size: "sm",
27946
+ onClick: handleActionClick(action, row),
27947
+ "data-testid": `action-${action.event}`,
27948
+ "data-row-id": String(row.id),
27949
+ className: cn(action.variant === "danger" && "text-error hover:bg-error/10"),
27950
+ children: [
27951
+ action.icon && renderIconInput3(action.icon, { size: "xs", className: "mr-1" }),
27952
+ action.label
27953
+ ]
27954
+ },
27955
+ i
27956
+ )),
27957
+ maxInlineActions != null && itemActions.length > maxInlineActions && /* @__PURE__ */ jsxRuntime.jsx(
27958
+ Menu,
27959
+ {
27960
+ position: "bottom-end",
27961
+ trigger: /* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "ghost", size: "sm", "aria-label": t("common.actions"), "data-testid": "action-overflow", children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { name: "more-horizontal", size: "xs" }) }),
27962
+ items: itemActions.slice(maxInlineActions).map((action) => ({
27963
+ label: action.label,
27964
+ icon: action.icon,
27965
+ event: action.event,
27966
+ variant: action.variant === "danger" ? "danger" : "default",
27967
+ onClick: () => eventBus.emit(`UI:${action.event}`, {
27968
+ id: row.id,
27969
+ row
27970
+ })
27971
+ }))
27972
+ }
27973
+ )
27974
+ ]
27975
+ }
27976
+ )
27965
27977
  ]
27966
27978
  }
27967
27979
  );
@@ -30598,6 +30610,7 @@ var init_QrScanner = __esm({
30598
30610
  overflow: "hidden",
30599
30611
  rounded: "sm",
30600
30612
  className: cn(
30613
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30601
30614
  "bg-black",
30602
30615
  "aspect-square w-full max-w-md",
30603
30616
  className
@@ -30662,7 +30675,9 @@ var init_QrScanner = __esm({
30662
30675
  type: "button",
30663
30676
  onClick: togglePause,
30664
30677
  className: cn(
30678
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30665
30679
  "rounded-full bg-black bg-opacity-60 p-2 text-white",
30680
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30666
30681
  "hover:bg-opacity-80 focus:outline-none focus:ring-2 focus:ring-white"
30667
30682
  ),
30668
30683
  "aria-label": isPaused ? t("qrScanner.resumeScanning") : t("qrScanner.pauseScanning"),
@@ -30675,7 +30690,9 @@ var init_QrScanner = __esm({
30675
30690
  type: "button",
30676
30691
  onClick: toggleFacing,
30677
30692
  className: cn(
30693
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30678
30694
  "rounded-full bg-black bg-opacity-60 p-2 text-white",
30695
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30679
30696
  "hover:bg-opacity-80 focus:outline-none focus:ring-2 focus:ring-white"
30680
30697
  ),
30681
30698
  "aria-label": currentFacing === "environment" ? t("qrScanner.switchToFrontCamera") : t("qrScanner.switchToRearCamera"),
@@ -30688,7 +30705,9 @@ var init_QrScanner = __esm({
30688
30705
  type: "button",
30689
30706
  onClick: handleMockScan,
30690
30707
  className: cn(
30708
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30691
30709
  "rounded-full bg-black bg-opacity-60 px-3 py-2 text-xs text-white",
30710
+ // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: always over a dark scrim
30692
30711
  "hover:bg-opacity-80 focus:outline-none focus:ring-2 focus:ring-white"
30693
30712
  ),
30694
30713
  "aria-label": t("aria.mockScanDev"),
@@ -33424,10 +33443,10 @@ var init_ModuleCard = __esm({
33424
33443
  init_avl_atom_types();
33425
33444
  init_MiniStateMachine();
33426
33445
  PERSISTENCE_BORDER = {
33427
- persistent: "border-l-[3px] border-l-blue-500 border-solid",
33428
- runtime: "border-l-[3px] border-l-blue-500 border-dashed",
33429
- singleton: "border-l-[3px] border-l-blue-500 border-double",
33430
- instance: "border-l-[3px] border-l-blue-500 border-dotted"
33446
+ persistent: "border-l-[3px] border-l-primary border-solid",
33447
+ runtime: "border-l-[3px] border-l-primary border-dashed",
33448
+ singleton: "border-l-[3px] border-l-primary border-double",
33449
+ instance: "border-l-[3px] border-l-primary border-dotted"
33431
33450
  };
33432
33451
  PERSISTENCE_ICON = {
33433
33452
  persistent: "\u26C1",
@@ -33457,8 +33476,8 @@ var init_ModuleCard = __esm({
33457
33476
  className: "rounded-lg border border-[var(--color-border)] bg-[var(--color-card)] shadow-sm overflow-hidden",
33458
33477
  style: { minWidth: 280, maxWidth: 400 },
33459
33478
  children: [
33460
- /* @__PURE__ */ jsxRuntime.jsx(react.Handle, { type: "target", position: react.Position.Left, className: "!w-2.5 !h-2.5 !bg-orange-400" }),
33461
- /* @__PURE__ */ jsxRuntime.jsx(react.Handle, { type: "source", position: react.Position.Right, className: "!w-2.5 !h-2.5 !bg-orange-400" }),
33479
+ /* @__PURE__ */ jsxRuntime.jsx(react.Handle, { type: "target", position: react.Position.Left, className: "!w-2.5 !h-2.5 !bg-warning" }),
33480
+ /* @__PURE__ */ jsxRuntime.jsx(react.Handle, { type: "source", position: react.Position.Right, className: "!w-2.5 !h-2.5 !bg-warning" }),
33462
33481
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 py-2 border-b border-[var(--color-border)]", children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-base font-bold text-[var(--color-foreground)]", children: orbitalName }) }),
33463
33482
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `px-3 py-2 border-b border-[var(--color-border)] ${PERSISTENCE_BORDER[persistence] ?? ""}`, children: [
33464
33483
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1.5 mb-1.5", children: [
@@ -35914,19 +35933,19 @@ var init_ReflectionBlock = __esm({
35914
35933
  "div",
35915
35934
  {
35916
35935
  className: cn(
35917
- "my-6 border-l-4 border-amber-400 bg-amber-50 dark:bg-amber-900/20 rounded-r-lg p-4",
35936
+ "my-6 border-l-4 border-warning bg-warning/10 rounded-r-lg p-4",
35918
35937
  className
35919
35938
  ),
35920
35939
  children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-3", children: [
35921
- /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.PauseCircle, { className: "text-amber-600 dark:text-amber-400 flex-shrink-0 mt-1", size: 20 }),
35940
+ /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.PauseCircle, { className: "text-warning flex-shrink-0 mt-1", size: 20 }),
35922
35941
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1", children: [
35923
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "font-medium text-amber-900 dark:text-amber-100 mb-2", children: "Pause & Reflect" }),
35924
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-gray-700 dark:text-gray-300 text-sm mb-3", children: prompt }),
35942
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "font-medium text-warning mb-2", children: "Pause & Reflect" }),
35943
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-foreground text-sm mb-3", children: prompt }),
35925
35944
  isExpanded ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
35926
35945
  /* @__PURE__ */ jsxRuntime.jsx(
35927
35946
  "textarea",
35928
35947
  {
35929
- className: "w-full p-2 border border-amber-300 dark:border-amber-700 rounded text-sm bg-white dark:bg-gray-800 text-gray-900 dark:text-gray-100 focus:ring-2 focus:ring-amber-500 focus:border-transparent",
35948
+ className: "w-full p-2 border border-input rounded text-sm bg-card text-foreground focus:ring-2 focus:ring-ring focus:border-transparent",
35930
35949
  placeholder: "Your thoughts...",
35931
35950
  value: note,
35932
35951
  onChange: (e) => setNote(e.target.value),
@@ -35937,7 +35956,7 @@ var init_ReflectionBlock = __esm({
35937
35956
  "button",
35938
35957
  {
35939
35958
  onClick: handleSave,
35940
- className: "mt-2 text-sm px-3 py-1 bg-amber-600 text-white rounded hover:bg-amber-700 transition-colors",
35959
+ className: "mt-2 text-sm px-3 py-1 bg-warning text-warning-foreground rounded hover:opacity-90 transition-colors",
35941
35960
  children: "Save & Continue"
35942
35961
  }
35943
35962
  )
@@ -35945,7 +35964,7 @@ var init_ReflectionBlock = __esm({
35945
35964
  "button",
35946
35965
  {
35947
35966
  onClick: () => setIsExpanded(true),
35948
- className: "text-sm text-amber-600 dark:text-amber-400 hover:underline",
35967
+ className: "text-sm text-warning hover:underline",
35949
35968
  children: savedNote ? "\u2713 Answered \xB7 Edit" : "Answer this question"
35950
35969
  }
35951
35970
  )
@@ -36231,7 +36250,7 @@ function DataTable({
36231
36250
  )),
36232
36251
  rowActions && /* @__PURE__ */ jsxRuntime.jsx("th", { className: "w-12 px-4 py-3" })
36233
36252
  ] }) }),
36234
- /* @__PURE__ */ jsxRuntime.jsx("tbody", { className: "divide-y divide-gray-200 dark:divide-gray-700", children: isLoading ? /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx(
36253
+ /* @__PURE__ */ jsxRuntime.jsx("tbody", { className: "divide-y divide-border", children: isLoading ? /* @__PURE__ */ jsxRuntime.jsx("tr", { children: /* @__PURE__ */ jsxRuntime.jsx(
36235
36254
  "td",
36236
36255
  {
36237
36256
  colSpan: normalizedColumns.length + (selectable ? 1 : 0) + (rowActions ? 1 : 0),
@@ -36551,6 +36570,16 @@ function normalizeFieldDefs(fields) {
36551
36570
  return String(f3);
36552
36571
  });
36553
36572
  }
36573
+ function buildFieldLabelMap(fields) {
36574
+ const map = {};
36575
+ if (!fields) return map;
36576
+ for (const f3 of fields) {
36577
+ if (typeof f3 === "object" && "key" in f3 && f3.header !== void 0 && f3.header !== "") {
36578
+ map[f3.key] = f3.header;
36579
+ }
36580
+ }
36581
+ return map;
36582
+ }
36554
36583
  function buildFieldTypeMap(fields) {
36555
36584
  const map = {};
36556
36585
  if (!fields) return map;
@@ -36602,7 +36631,9 @@ var init_DetailPanel = __esm({
36602
36631
  };
36603
36632
  const effectiveFieldNames = isFieldDefArray(propFields) ? normalizeFieldDefs(propFields) : fieldNames;
36604
36633
  const fieldTypeMap = isFieldDefArray(propFields) ? buildFieldTypeMap(propFields) : {};
36605
- React82.useCallback(
36634
+ const fieldLabelMap = isFieldDefArray(propFields) ? buildFieldLabelMap(propFields) : {};
36635
+ const labelFor = (field) => fieldLabelMap[field] ?? formatFieldLabel(field);
36636
+ const handleActionClick = React82.useCallback(
36606
36637
  (action, data2) => {
36607
36638
  if (action.navigatesTo) {
36608
36639
  const url = action.navigatesTo.replace(
@@ -36637,7 +36668,7 @@ var init_DetailPanel = __esm({
36637
36668
  if (typeof field === "string") {
36638
36669
  const value = getNestedValue(normalizedData, field);
36639
36670
  return {
36640
- label: formatFieldLabel(field),
36671
+ label: labelFor(field),
36641
36672
  value: formatFieldValue(value, field),
36642
36673
  icon: getFieldIcon(field)
36643
36674
  };
@@ -36648,7 +36679,10 @@ var init_DetailPanel = __esm({
36648
36679
  }
36649
36680
  if (normalizedData && effectiveFieldNames) {
36650
36681
  const primaryField = effectiveFieldNames[0];
36651
- if (!title && primaryField && normalizedData[primaryField]) {
36682
+ const titleDerivedFromPrimary = Boolean(
36683
+ !title && primaryField && normalizedData[primaryField]
36684
+ );
36685
+ if (titleDerivedFromPrimary) {
36652
36686
  title = String(normalizedData[primaryField]);
36653
36687
  }
36654
36688
  const statusFields = effectiveFieldNames.filter(
@@ -36667,16 +36701,16 @@ var init_DetailPanel = __esm({
36667
36701
  (f3) => f3.toLowerCase().includes("description") || f3.toLowerCase().includes("note")
36668
36702
  );
36669
36703
  const otherFields = effectiveFieldNames.filter(
36670
- (f3) => f3 !== primaryField && !statusFields.includes(f3) && !progressFields.includes(f3) && !metricFields.includes(f3) && !dateFields.includes(f3) && !descriptionFields.includes(f3)
36704
+ (f3) => (!titleDerivedFromPrimary || f3 !== primaryField) && !statusFields.includes(f3) && !progressFields.includes(f3) && !metricFields.includes(f3) && !dateFields.includes(f3) && !descriptionFields.includes(f3)
36671
36705
  );
36672
36706
  sections = [];
36673
36707
  if (statusFields.length > 0 || otherFields.length > 0) {
36674
36708
  const overviewFields = [];
36675
- [...statusFields, ...otherFields.slice(0, 3)].forEach((field) => {
36709
+ [...statusFields, ...otherFields].forEach((field) => {
36676
36710
  const value = getNestedValue(normalizedData, field);
36677
36711
  if (value !== void 0 && value !== null) {
36678
36712
  overviewFields.push({
36679
- label: formatFieldLabel(field),
36713
+ label: labelFor(field),
36680
36714
  value: renderRichFieldValue(value, field, fieldTypeMap[field]),
36681
36715
  icon: getFieldIcon(field)
36682
36716
  });
@@ -36692,7 +36726,7 @@ var init_DetailPanel = __esm({
36692
36726
  const value = getNestedValue(normalizedData, field);
36693
36727
  if (value !== void 0 && value !== null) {
36694
36728
  metricsFields.push({
36695
- label: formatFieldLabel(field),
36729
+ label: labelFor(field),
36696
36730
  value: renderRichFieldValue(value, field, fieldTypeMap[field]),
36697
36731
  icon: getFieldIcon(field)
36698
36732
  });
@@ -36708,7 +36742,7 @@ var init_DetailPanel = __esm({
36708
36742
  const value = getNestedValue(normalizedData, field);
36709
36743
  if (value !== void 0 && value !== null) {
36710
36744
  timelineFields.push({
36711
- label: formatFieldLabel(field),
36745
+ label: labelFor(field),
36712
36746
  value: renderRichFieldValue(value, field, fieldTypeMap[field]),
36713
36747
  icon: getFieldIcon(field)
36714
36748
  });
@@ -36724,7 +36758,7 @@ var init_DetailPanel = __esm({
36724
36758
  const value = getNestedValue(normalizedData, field);
36725
36759
  if (value !== void 0 && value !== null) {
36726
36760
  descFields.push({
36727
- label: formatFieldLabel(field),
36761
+ label: labelFor(field),
36728
36762
  value: renderRichFieldValue(value, field, fieldTypeMap[field]),
36729
36763
  icon: getFieldIcon(field)
36730
36764
  });
@@ -36772,7 +36806,7 @@ var init_DetailPanel = __esm({
36772
36806
  if (typeof field === "string") {
36773
36807
  const value = normalizedData ? getNestedValue(normalizedData, field) : void 0;
36774
36808
  allFields.push({
36775
- label: formatFieldLabel(field),
36809
+ label: labelFor(field),
36776
36810
  value: renderRichFieldValue(value, field, fieldTypeMap[field]),
36777
36811
  icon: getFieldIcon(field)
36778
36812
  });
@@ -36794,8 +36828,9 @@ var init_DetailPanel = __esm({
36794
36828
  {
36795
36829
  variant: action.variant || "secondary",
36796
36830
  size: "sm",
36797
- action: action.event,
36831
+ action: action.navigatesTo ? void 0 : action.event,
36798
36832
  actionPayload: { row: normalizedData },
36833
+ onClick: action.navigatesTo ? () => handleActionClick(action, normalizedData) : void 0,
36799
36834
  icon: action.icon,
36800
36835
  "data-testid": action.event ? `action-${action.event}` : void 0,
36801
36836
  "data-row-id": normalizedData?.id !== void 0 ? String(normalizedData.id) : void 0,
@@ -38838,8 +38873,9 @@ var init_MediaGallery = __esm({
38838
38873
  )
38839
38874
  }
38840
38875
  ),
38841
- item.caption && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "absolute bottom-0 left-0 right-0 p-2 bg-gradient-to-t from-black/60 to-transparent", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "caption", className: "text-white truncate", children: item.caption }) }),
38842
- selectable && isSelected && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "absolute top-2 right-2 w-5 h-5 rounded-full bg-primary flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "caption", className: "text-white text-xs", children: "\u2713" }) })
38876
+ item.caption && // eslint-disable-next-line almadar/no-hardcoded-colors -- media overlay: caption scrim over image
38877
+ /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "absolute bottom-0 left-0 right-0 p-2 bg-gradient-to-t from-black/60 to-transparent", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "caption", className: "text-white truncate", children: item.caption }) }),
38878
+ selectable && isSelected && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "absolute top-2 right-2 w-5 h-5 rounded-full bg-primary flex items-center justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "caption", className: "text-primary-foreground text-xs", children: "\u2713" }) })
38843
38879
  ]
38844
38880
  },
38845
38881
  item.id
@@ -38868,7 +38904,7 @@ var init_MediaGallery = __esm({
38868
38904
  size: "sm",
38869
38905
  icon: LucideIcons2.X,
38870
38906
  action: "LIGHTBOX_CLOSE",
38871
- className: "text-white hover:bg-white/20"
38907
+ className: "text-foreground hover:bg-muted/50"
38872
38908
  }
38873
38909
  ) }),
38874
38910
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -38879,7 +38915,7 @@ var init_MediaGallery = __esm({
38879
38915
  className: "max-w-full max-h-[80vh] object-contain rounded-md"
38880
38916
  }
38881
38917
  ),
38882
- lightboxItem.caption && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", className: "text-white mt-3 text-center", children: lightboxItem.caption })
38918
+ lightboxItem.caption && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", className: "text-foreground mt-3 text-center", children: lightboxItem.caption })
38883
38919
  ]
38884
38920
  }
38885
38921
  )
@@ -39340,7 +39376,7 @@ function WalkMinimap() {
39340
39376
  {
39341
39377
  variant,
39342
39378
  size: "sm",
39343
- className: `flex-shrink-0 text-[9px] ${isActive ? "ring-1 ring-cyan-400" : ""}`,
39379
+ className: `flex-shrink-0 text-[9px] ${isActive ? "ring-1 ring-info" : ""}`,
39344
39380
  children: [
39345
39381
  isDone ? "\u2713" : isActive ? "\u25CF" : "\u25CB",
39346
39382
  " ",
@@ -39481,13 +39517,13 @@ function WalkMinimap() {
39481
39517
  })
39482
39518
  ] }) }),
39483
39519
  /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "px-2 py-1 border-t border-border", children: /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "sm", className: "items-center justify-between", children: [
39484
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "caption", className: "text-xs font-mono text-green-500", children: [
39520
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "caption", className: "text-xs font-mono text-success", children: [
39485
39521
  "Engine: ",
39486
39522
  engineCount,
39487
39523
  "/",
39488
39524
  totalTransitions
39489
39525
  ] }),
39490
- domCount > 0 && /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "caption", className: "text-xs font-mono text-cyan-500", children: [
39526
+ domCount > 0 && /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "caption", className: "text-xs font-mono text-info", children: [
39491
39527
  "DOM: ",
39492
39528
  domCount
39493
39529
  ] }),
@@ -39520,13 +39556,13 @@ function TraitsTab({ traits: traits2 }) {
39520
39556
  const accordionItems = traits2.map((trait) => ({
39521
39557
  id: trait.id,
39522
39558
  header: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 w-full", children: [
39523
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-purple-600 dark:text-purple-400", children: trait.name }),
39559
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-primary", children: trait.name }),
39524
39560
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "success", size: "sm", children: trait.currentState }),
39525
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500 ml-auto", children: t("debug.transitionsCount", { count: trait.transitionCount }) })
39561
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground ml-auto", children: t("debug.transitionsCount", { count: trait.transitionCount }) })
39526
39562
  ] }),
39527
39563
  content: /* @__PURE__ */ jsxRuntime.jsxs(Stack, { gap: "sm", children: [
39528
39564
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39529
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: t("debug.states") }),
39565
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: t("debug.states") }),
39530
39566
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-1", children: trait.states.map((state) => /* @__PURE__ */ jsxRuntime.jsx(
39531
39567
  Badge,
39532
39568
  {
@@ -39538,18 +39574,18 @@ function TraitsTab({ traits: traits2 }) {
39538
39574
  )) })
39539
39575
  ] }),
39540
39576
  trait.transitions.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39541
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: t("debug.transitions") }),
39577
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: t("debug.transitions") }),
39542
39578
  /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "xs", children: trait.transitions.map((t2, i) => /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "font-mono", children: [
39543
39579
  t2.from,
39544
39580
  " \u2192 ",
39545
39581
  t2.to,
39546
39582
  " ",
39547
- /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-gray-500", children: [
39583
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-muted-foreground", children: [
39548
39584
  "(",
39549
39585
  t2.event,
39550
39586
  ")"
39551
39587
  ] }),
39552
- t2.guard && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-amber-500", children: [
39588
+ t2.guard && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-warning", children: [
39553
39589
  " [",
39554
39590
  t2.guard,
39555
39591
  "]"
@@ -39557,7 +39593,7 @@ function TraitsTab({ traits: traits2 }) {
39557
39593
  ] }, i)) })
39558
39594
  ] }),
39559
39595
  trait.guards.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39560
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: t("debug.guards") }),
39596
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: t("debug.guards") }),
39561
39597
  /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "xs", children: trait.guards.map((g, i) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
39562
39598
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", children: g.name }),
39563
39599
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: g.lastResult === true ? "success" : g.lastResult === false ? "danger" : "default", size: "sm", children: g.lastResult === void 0 ? "?" : g.lastResult ? "\u2713" : "\u2717" })
@@ -39600,11 +39636,11 @@ function TicksTab({ ticks: ticks2 }) {
39600
39636
  };
39601
39637
  const TickCard = ({ tick, active }) => /* @__PURE__ */ jsxRuntime.jsxs(Card, { className: `p-3 ${!active ? "opacity-50" : ""}`, children: [
39602
39638
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 mb-2", children: [
39603
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: `w-2 h-2 rounded-full ${active ? "bg-green-500" : "bg-gray-400"}` }),
39604
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-amber-600 dark:text-amber-400", children: tick.name }),
39605
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500", children: tick.traitName })
39639
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: `w-2 h-2 rounded-full ${active ? "bg-success" : "bg-muted-foreground"}` }),
39640
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-warning", children: tick.name }),
39641
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: tick.traitName })
39606
39642
  ] }),
39607
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-3 text-xs text-gray-500", children: [
39643
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-3 text-xs text-muted-foreground", children: [
39608
39644
  /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
39609
39645
  tick.interval,
39610
39646
  "ms"
@@ -39627,7 +39663,7 @@ function TicksTab({ ticks: ticks2 }) {
39627
39663
  ] });
39628
39664
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "debug-tab debug-tab--ticks", children: [
39629
39665
  activeTicks.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4", children: [
39630
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: [
39666
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: [
39631
39667
  "Active (",
39632
39668
  activeTicks.length,
39633
39669
  ")"
@@ -39635,7 +39671,7 @@ function TicksTab({ ticks: ticks2 }) {
39635
39671
  /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "sm", children: activeTicks.map((tick) => /* @__PURE__ */ jsxRuntime.jsx(TickCard, { tick, active: true }, tick.id)) })
39636
39672
  ] }),
39637
39673
  inactiveTicks.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39638
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", weight: "medium", className: "text-gray-400 mb-2", children: [
39674
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: [
39639
39675
  "Inactive (",
39640
39676
  inactiveTicks.length,
39641
39677
  ")"
@@ -39683,33 +39719,33 @@ function EntitiesTab({ snapshot }) {
39683
39719
  id: `singleton-${name}`,
39684
39720
  header: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
39685
39721
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "primary", size: "sm", children: t("debug.singleton") }),
39686
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-sky-600 dark:text-sky-400", children: name })
39722
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-info", children: name })
39687
39723
  ] }),
39688
- content: /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "text-xs text-gray-600 dark:text-gray-400 bg-gray-50 dark:bg-gray-800 p-2 rounded overflow-auto max-h-40", children: JSON.stringify(data, null, 2) })
39724
+ content: /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "text-xs text-muted-foreground bg-muted p-2 rounded overflow-auto max-h-40", children: JSON.stringify(data, null, 2) })
39689
39725
  }));
39690
39726
  const runtimeItems = runtimeEntities.slice(0, 20).map((entity) => ({
39691
39727
  id: entity.id,
39692
39728
  header: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
39693
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-sky-600 dark:text-sky-400", children: entity.type }),
39694
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-gray-500", children: [
39729
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-info", children: entity.type }),
39730
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-muted-foreground", children: [
39695
39731
  "#",
39696
39732
  entity.id.slice(0, 8)
39697
39733
  ] })
39698
39734
  ] }),
39699
- content: /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "text-xs text-gray-600 dark:text-gray-400 bg-gray-50 dark:bg-gray-800 p-2 rounded overflow-auto max-h-40", children: JSON.stringify(entity.data, null, 2) })
39735
+ content: /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "text-xs text-muted-foreground bg-muted p-2 rounded overflow-auto max-h-40", children: JSON.stringify(entity.data, null, 2) })
39700
39736
  }));
39701
39737
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "debug-tab debug-tab--entities", children: [
39702
39738
  singletonItems.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4", children: [
39703
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: t("debug.singletonsCount", { count: singletonItems.length }) }),
39739
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: t("debug.singletonsCount", { count: singletonItems.length }) }),
39704
39740
  /* @__PURE__ */ jsxRuntime.jsx(Accordion, { items: singletonItems, multiple: true })
39705
39741
  ] }),
39706
39742
  runtimeItems.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-4", children: [
39707
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: t("debug.runtimeCount", { count: runtimeEntities.length }) }),
39743
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: t("debug.runtimeCount", { count: runtimeEntities.length }) }),
39708
39744
  /* @__PURE__ */ jsxRuntime.jsx(Accordion, { items: runtimeItems, multiple: true }),
39709
- runtimeEntities.length > 20 && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400 text-center mt-2", children: t("debug.moreEntities", { count: runtimeEntities.length - 20 }) })
39745
+ runtimeEntities.length > 20 && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground text-center mt-2", children: t("debug.moreEntities", { count: runtimeEntities.length - 20 }) })
39710
39746
  ] }),
39711
39747
  persistentEntries.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39712
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-2", children: t("debug.persistent") }),
39748
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-2", children: t("debug.persistent") }),
39713
39749
  /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "xs", children: persistentEntries.map(([type, info]) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between py-1", children: [
39714
39750
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", children: type }),
39715
39751
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: info.loaded ? "success" : "default", size: "sm", children: info.loaded ? t("debug.loadedCount", { count: info.count }) : t("debug.notLoaded") })
@@ -39794,7 +39830,7 @@ function EventFlowTab({ events: events2 }) {
39794
39830
  );
39795
39831
  })
39796
39832
  ] }),
39797
- /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-1 text-xs text-gray-500 ml-auto cursor-pointer", children: [
39833
+ /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-1 text-xs text-muted-foreground ml-auto cursor-pointer", children: [
39798
39834
  /* @__PURE__ */ jsxRuntime.jsx(
39799
39835
  Checkbox,
39800
39836
  {
@@ -39809,18 +39845,18 @@ function EventFlowTab({ events: events2 }) {
39809
39845
  "div",
39810
39846
  {
39811
39847
  ref: containerRef,
39812
- className: "max-h-64 overflow-y-auto space-y-1 bg-gray-50 dark:bg-gray-800 rounded p-2",
39848
+ className: "max-h-64 overflow-y-auto space-y-1 bg-muted rounded p-2",
39813
39849
  children: filteredEvents.slice(-100).map((event) => {
39814
39850
  const { variant, icon } = TYPE_BADGES[event.type] || { variant: "default", icon: "\u2022" };
39815
39851
  return /* @__PURE__ */ jsxRuntime.jsxs(
39816
39852
  "div",
39817
39853
  {
39818
- className: "flex items-start gap-2 text-xs py-1 hover:bg-gray-100 dark:hover:bg-gray-700 rounded px-1",
39854
+ className: "flex items-start gap-2 text-xs py-1 hover:bg-muted/50 rounded px-1",
39819
39855
  children: [
39820
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400 font-mono min-w-[65px]", children: formatTime2(event.timestamp) }),
39856
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground font-mono min-w-[65px]", children: formatTime2(event.timestamp) }),
39821
39857
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: icon }),
39822
39858
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant, size: "sm", className: "min-w-[60px] justify-center", children: event.source }),
39823
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-600 dark:text-gray-400", children: event.message })
39859
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: event.message })
39824
39860
  ]
39825
39861
  },
39826
39862
  event.id
@@ -39884,21 +39920,21 @@ function GuardsPanel({ guards }) {
39884
39920
  id: guard.id,
39885
39921
  header: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 w-full", children: [
39886
39922
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: guard.result ? "success" : "danger", size: "sm", children: guard.result ? "\u2713" : "\u2717" }),
39887
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-amber-600 dark:text-amber-400", children: guard.guardName }),
39888
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500", children: guard.context.type === "transition" ? `${guard.context.transitionFrom} \u2192 ${guard.context.transitionTo}` : guard.context.tickName }),
39889
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400 ml-auto", children: formatTime2(guard.timestamp) })
39923
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "body", weight: "semibold", className: "text-warning", children: guard.guardName }),
39924
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: guard.context.type === "transition" ? `${guard.context.transitionFrom} \u2192 ${guard.context.transitionTo}` : guard.context.tickName }),
39925
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground ml-auto", children: formatTime2(guard.timestamp) })
39890
39926
  ] }),
39891
39927
  content: /* @__PURE__ */ jsxRuntime.jsxs(Stack, { gap: "sm", children: [
39892
39928
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39893
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500", children: t("debug.expression") }),
39894
- /* @__PURE__ */ jsxRuntime.jsx("code", { className: "block mt-1 text-xs text-amber-600 dark:text-amber-400 bg-amber-50 dark:bg-amber-900/20 px-2 py-1 rounded", children: guard.expression })
39929
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground", children: t("debug.expression") }),
39930
+ /* @__PURE__ */ jsxRuntime.jsx("code", { className: "block mt-1 text-xs text-warning bg-warning/10 px-2 py-1 rounded", children: guard.expression })
39895
39931
  ] }),
39896
39932
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39897
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500", children: t("debug.inputs") }),
39898
- /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "mt-1 text-xs text-gray-600 dark:text-gray-400 bg-gray-50 dark:bg-gray-800 p-2 rounded overflow-auto max-h-24", children: JSON.stringify(guard.inputs, null, 2) })
39933
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground", children: t("debug.inputs") }),
39934
+ /* @__PURE__ */ jsxRuntime.jsx("pre", { className: "mt-1 text-xs text-muted-foreground bg-muted p-2 rounded overflow-auto max-h-24", children: JSON.stringify(guard.inputs, null, 2) })
39899
39935
  ] }),
39900
39936
  /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
39901
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500", children: t("debug.trait") }),
39937
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground", children: t("debug.trait") }),
39902
39938
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", children: guard.context.traitName })
39903
39939
  ] })
39904
39940
  ] })
@@ -39954,7 +39990,7 @@ function VerificationTab({ checks, summary }) {
39954
39990
  (a, b) => (sortOrder[a.status] ?? 4) - (sortOrder[b.status] ?? 4)
39955
39991
  );
39956
39992
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "debug-tab debug-tab--verification", children: [
39957
- /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3 mb-3 p-2 bg-gray-50 dark:bg-gray-800 rounded", children: [
39993
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3 mb-3 p-2 bg-muted rounded", children: [
39958
39994
  /* @__PURE__ */ jsxRuntime.jsxs(Badge, { variant: "success", size: "sm", children: [
39959
39995
  summary.passed,
39960
39996
  " passed"
@@ -39971,7 +40007,7 @@ function VerificationTab({ checks, summary }) {
39971
40007
  summary.pending,
39972
40008
  " pending"
39973
40009
  ] }),
39974
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-gray-500 ml-auto", children: [
40010
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-muted-foreground ml-auto", children: [
39975
40011
  summary.totalChecks,
39976
40012
  " total checks"
39977
40013
  ] })
@@ -39981,12 +40017,12 @@ function VerificationTab({ checks, summary }) {
39981
40017
  return /* @__PURE__ */ jsxRuntime.jsxs(
39982
40018
  "div",
39983
40019
  {
39984
- className: "flex items-start gap-2 p-2 rounded hover:bg-gray-50 dark:hover:bg-gray-800",
40020
+ className: "flex items-start gap-2 p-2 rounded hover:bg-muted/50",
39985
40021
  children: [
39986
40022
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: config.variant, size: "sm", className: "min-w-[20px] justify-center mt-0.5", children: config.icon }),
39987
40023
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 min-w-0", children: [
39988
40024
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "break-words", children: check.label }),
39989
- check.details && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500 break-words", children: check.details })
40025
+ check.details && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground break-words", children: check.details })
39990
40026
  ] }),
39991
40027
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground font-mono text-xs shrink-0", children: new Date(check.updatedAt).toLocaleTimeString("en-US", {
39992
40028
  hour12: false,
@@ -40021,10 +40057,10 @@ var init_VerificationTab = __esm({
40021
40057
  function EffectBadge({ effect }) {
40022
40058
  const variant = EFFECT_STATUS_VARIANT[effect.status] || "default";
40023
40059
  const icon = effect.status === "executed" ? "\u2713" : effect.status === "failed" ? "\u2717" : "-";
40024
- return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1 text-xs font-mono bg-gray-100 dark:bg-gray-700 rounded px-1.5 py-0.5", children: [
40060
+ return /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "inline-flex items-center gap-1 text-xs font-mono bg-muted rounded px-1.5 py-0.5", children: [
40025
40061
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant, size: "sm", className: "!text-[9px] !px-1 !py-0", children: icon }),
40026
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-gray-600 dark:text-gray-400", children: effect.type }),
40027
- effect.error && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-red-500 truncate max-w-[120px]", title: effect.error, children: effect.error })
40062
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: effect.type }),
40063
+ effect.error && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-error truncate max-w-[120px]", title: effect.error, children: effect.error })
40028
40064
  ] });
40029
40065
  }
40030
40066
  function TransitionTimeline({ transitions }) {
@@ -40059,8 +40095,8 @@ function TransitionTimeline({ transitions }) {
40059
40095
  const sorted = [...transitions].reverse();
40060
40096
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "debug-tab debug-tab--timeline", children: [
40061
40097
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between mb-2", children: [
40062
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500", children: t("debug.transitionsRecorded", { count: transitions.length }) }),
40063
- /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-1 text-xs text-gray-500 cursor-pointer", children: [
40098
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: t("debug.transitionsRecorded", { count: transitions.length }) }),
40099
+ /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-1 text-xs text-muted-foreground cursor-pointer", children: [
40064
40100
  /* @__PURE__ */ jsxRuntime.jsx(
40065
40101
  Checkbox,
40066
40102
  {
@@ -40085,22 +40121,22 @@ function TransitionTimeline({ transitions }) {
40085
40121
  {
40086
40122
  className: `
40087
40123
  relative pl-6 pb-3 border-l-2 cursor-pointer
40088
- hover:bg-gray-50 dark:hover:bg-gray-800 rounded-r
40089
- ${hasFailedEffects ? "border-red-300 dark:border-red-700" : "border-gray-200 dark:border-gray-700"}
40124
+ hover:bg-muted/50 rounded-r
40125
+ ${hasFailedEffects ? "border-error" : "border-border"}
40090
40126
  `,
40091
40127
  onClick: () => setExpandedId(isExpanded ? null : trace.id),
40092
40128
  children: [
40093
40129
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: `
40094
40130
  absolute left-[-5px] top-1 w-2 h-2 rounded-full
40095
- ${hasFailedEffects ? "bg-red-500" : allPassed ? "bg-green-500" : "bg-gray-400"}
40131
+ ${hasFailedEffects ? "bg-error" : allPassed ? "bg-success" : "bg-muted-foreground"}
40096
40132
  ` }),
40097
40133
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 text-xs py-1 px-2", children: [
40098
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400 font-mono min-w-[65px]", children: formatTime2(trace.timestamp) }),
40134
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground font-mono min-w-[65px]", children: formatTime2(trace.timestamp) }),
40099
40135
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "primary", size: "sm", className: "min-w-[60px] justify-center", children: trace.traitName }),
40100
- /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "font-mono text-gray-600 dark:text-gray-400", children: [
40136
+ /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "font-mono text-muted-foreground", children: [
40101
40137
  trace.from,
40102
40138
  " ",
40103
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-gray-400", children: "\u2192" }),
40139
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground/50", children: "\u2192" }),
40104
40140
  " ",
40105
40141
  trace.to
40106
40142
  ] }),
@@ -40117,9 +40153,9 @@ function TransitionTimeline({ transitions }) {
40117
40153
  ]
40118
40154
  }
40119
40155
  ),
40120
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400 ml-auto", children: t("debug.effectsCount", { count: trace.effects.length }) })
40156
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground ml-auto", children: t("debug.effectsCount", { count: trace.effects.length }) })
40121
40157
  ] }),
40122
- isExpanded && trace.effects.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "ml-2 mt-1 mb-2 pl-2 border-l border-gray-200 dark:border-gray-700 space-y-1", children: trace.effects.map((effect, eIdx) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1", children: [
40158
+ isExpanded && trace.effects.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "ml-2 mt-1 mb-2 pl-2 border-l border-border space-y-1", children: trace.effects.map((effect, eIdx) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1", children: [
40123
40159
  /* @__PURE__ */ jsxRuntime.jsx(EffectBadge, { effect }),
40124
40160
  effect.args.length > 0 && /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground font-mono text-xs truncate max-w-[200px]", children: JSON.stringify(effect.args) }),
40125
40161
  effect.durationMs !== void 0 && /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "text-muted-foreground text-xs", children: [
@@ -40153,8 +40189,8 @@ var init_TransitionTimeline = __esm({
40153
40189
  }
40154
40190
  });
40155
40191
  function StatRow({ label, value, variant }) {
40156
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between py-1.5 border-b border-gray-100 dark:border-gray-800 last:border-b-0", children: [
40157
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500", children: label }),
40192
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between py-1.5 border-b border-border last:border-b-0", children: [
40193
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: label }),
40158
40194
  variant ? /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant, size: "sm", children: String(value) }) : /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "semibold", className: "font-mono", children: String(value) })
40159
40195
  ] });
40160
40196
  }
@@ -40183,7 +40219,7 @@ function ServerBridgeTab({ bridge }) {
40183
40219
  return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "debug-tab debug-tab--bridge", children: /* @__PURE__ */ jsxRuntime.jsxs(Stack, { gap: "sm", children: [
40184
40220
  /* @__PURE__ */ jsxRuntime.jsxs(Card, { className: "p-3", children: [
40185
40221
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3 mb-3", children: [
40186
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: `w-3 h-3 rounded-full ${bridge.connected ? "bg-green-500 animate-pulse" : "bg-red-500"}` }),
40222
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: `w-3 h-3 rounded-full ${bridge.connected ? "bg-success animate-pulse" : "bg-error"}` }),
40187
40223
  /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "h6", children: bridge.connected ? t("debug.connected") : t("debug.disconnected") })
40188
40224
  ] }),
40189
40225
  /* @__PURE__ */ jsxRuntime.jsxs(Stack, { gap: "xs", children: [
@@ -40218,11 +40254,11 @@ function ServerBridgeTab({ bridge }) {
40218
40254
  )
40219
40255
  ] })
40220
40256
  ] }),
40221
- bridge.lastError && /* @__PURE__ */ jsxRuntime.jsxs(Card, { className: "p-3 border-red-200 dark:border-red-800 bg-red-50 dark:bg-red-950", children: [
40222
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "semibold", className: "text-red-600 dark:text-red-400 mb-1", children: t("debug.lastError") }),
40223
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-red-500 font-mono break-all", children: bridge.lastError })
40257
+ bridge.lastError && /* @__PURE__ */ jsxRuntime.jsxs(Card, { className: "p-3 border-error/30 bg-error/10", children: [
40258
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "semibold", className: "text-error mb-1", children: t("debug.lastError") }),
40259
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-error font-mono break-all", children: bridge.lastError })
40224
40260
  ] }),
40225
- bridge.connected && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-center py-2", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400", children: t("debug.totalEventsProcessed", { count: bridge.eventsForwarded + bridge.eventsReceived }) }) })
40261
+ bridge.connected && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-center py-2", children: /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: t("debug.totalEventsProcessed", { count: bridge.eventsForwarded + bridge.eventsReceived }) }) })
40226
40262
  ] }) });
40227
40263
  }
40228
40264
  var init_ServerBridgeTab = __esm({
@@ -40348,7 +40384,7 @@ function EventDispatcherTab({ traits: traits2, schema }) {
40348
40384
  };
40349
40385
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "debug-tab debug-tab--dispatch", children: [
40350
40386
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-3", children: [
40351
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-1", children: t("debug.activeStates") }),
40387
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-1", children: t("debug.activeStates") }),
40352
40388
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-1", children: traits2.map((trait) => /* @__PURE__ */ jsxRuntime.jsxs(Badge, { variant: "success", size: "sm", children: [
40353
40389
  trait.name,
40354
40390
  ": ",
@@ -40356,8 +40392,8 @@ function EventDispatcherTab({ traits: traits2, schema }) {
40356
40392
  ] }, trait.id)) })
40357
40393
  ] }),
40358
40394
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-3", children: [
40359
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-1", children: t("debug.availableEvents") }),
40360
- availableEvents.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-400 italic", children: t("debug.noTransitionsFromState") }) : /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "xs", children: availableEvents.map(({ event, transitions }) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
40395
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-1", children: t("debug.availableEvents") }),
40396
+ availableEvents.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground italic", children: t("debug.noTransitionsFromState") }) : /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "xs", children: availableEvents.map(({ event, transitions }) => /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
40361
40397
  /* @__PURE__ */ jsxRuntime.jsx(
40362
40398
  Button,
40363
40399
  {
@@ -40368,22 +40404,22 @@ function EventDispatcherTab({ traits: traits2, schema }) {
40368
40404
  children: event
40369
40405
  }
40370
40406
  ),
40371
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-gray-500", children: transitions.map((t2) => `${t2.from} -> ${t2.to}`).join(", ") }),
40407
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", className: "text-muted-foreground", children: transitions.map((t2) => `${t2.from} -> ${t2.to}`).join(", ") }),
40372
40408
  transitions.some((tr) => tr.guard) && /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "warning", size: "sm", children: t("debug.guarded") })
40373
40409
  ] }, event)) })
40374
40410
  ] }),
40375
40411
  unavailableEvents.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-3", children: [
40376
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-1", children: t("debug.otherEvents") }),
40412
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-1", children: t("debug.otherEvents") }),
40377
40413
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-1", children: unavailableEvents.map((event) => /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "default", size: "sm", className: "opacity-50", children: event }, event)) })
40378
40414
  ] }),
40379
40415
  log9.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
40380
- /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-gray-500 mb-1", children: t("debug.recentTransitions") }),
40416
+ /* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "small", weight: "medium", className: "text-muted-foreground mb-1", children: t("debug.recentTransitions") }),
40381
40417
  /* @__PURE__ */ jsxRuntime.jsx(Stack, { gap: "xs", children: log9.map((entry, i) => /* @__PURE__ */ jsxRuntime.jsxs(Typography, { variant: "small", className: "font-mono text-xs", children: [
40382
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-purple-400", children: entry.traitName }),
40418
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-primary", children: entry.traitName }),
40383
40419
  " ",
40384
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-gray-500", children: entry.from }),
40420
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: entry.from }),
40385
40421
  " -> ",
40386
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-green-400", children: entry.to })
40422
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-success", children: entry.to })
40387
40423
  ] }, i)) })
40388
40424
  ] })
40389
40425
  ] });
@@ -40409,21 +40445,21 @@ var init_RuntimeDebugger = __esm({
40409
40445
  function ServerResponseRow({ sr }) {
40410
40446
  const { t } = hooks.useTranslate();
40411
40447
  const entityEntries = Object.entries(sr.dataEntities);
40412
- return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "ml-4 pl-2 border-l border-purple-500/30 py-0.5 text-xs font-mono", children: [
40448
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "ml-4 pl-2 border-l border-primary py-0.5 text-xs font-mono", children: [
40413
40449
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
40414
- /* @__PURE__ */ jsxRuntime.jsxs("span", { className: sr.success ? "text-green-600 dark:text-green-400" : "text-red-600 dark:text-red-400", children: [
40450
+ /* @__PURE__ */ jsxRuntime.jsxs("span", { className: sr.success ? "text-success" : "text-error", children: [
40415
40451
  sr.success ? "\u2713" : "\u2717",
40416
40452
  " ",
40417
40453
  t("debug.server")
40418
40454
  ] }),
40419
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-purple-600 dark:text-purple-300", children: sr.orbitalName }),
40420
- sr.clientEffects > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "px-1 rounded bg-purple-500/15 text-purple-600 dark:text-purple-300", children: t("debug.clientEffectsCount", { count: sr.clientEffects }) }),
40421
- sr.emittedEvents.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "px-1 rounded bg-blue-500/15 text-blue-300", children: [
40455
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-primary", children: sr.orbitalName }),
40456
+ sr.clientEffects > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "px-1 rounded bg-primary/10 text-primary", children: t("debug.clientEffectsCount", { count: sr.clientEffects }) }),
40457
+ sr.emittedEvents.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "px-1 rounded bg-primary/10 text-primary", children: [
40422
40458
  t("debug.emitLabel"),
40423
40459
  " ",
40424
40460
  sr.emittedEvents.join(", ")
40425
40461
  ] }),
40426
- sr.error && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "px-1 rounded bg-red-500/15 text-red-600 dark:text-red-400 truncate max-w-[300px]", children: sr.error })
40462
+ sr.error && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "px-1 rounded bg-error/10 text-error truncate max-w-[300px]", children: sr.error })
40427
40463
  ] }),
40428
40464
  entityEntries.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-1 mt-0.5", children: entityEntries.map(([name, count]) => /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "px-1 rounded bg-[var(--color-card)] text-foreground", children: [
40429
40465
  name,
@@ -40439,9 +40475,9 @@ function TransitionRow({ trace }) {
40439
40475
  if (isServerEntry && trace.serverResponse) {
40440
40476
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "py-0.5 border-b border-border last:border-0", children: [
40441
40477
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-2 text-xs font-mono", children: [
40442
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-1.5 w-1.5 h-1.5 rounded-full flex-shrink-0 bg-purple-500" }),
40478
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-1.5 w-1.5 h-1.5 rounded-full flex-shrink-0 bg-primary" }),
40443
40479
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "warning", size: "sm", className: "flex-shrink-0", children: trace.event }),
40444
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-purple-600 dark:text-purple-400 flex-shrink-0", children: t("debug.serverResponse") })
40480
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-primary flex-shrink-0", children: t("debug.serverResponse") })
40445
40481
  ] }),
40446
40482
  /* @__PURE__ */ jsxRuntime.jsx(ServerResponseRow, { sr: trace.serverResponse })
40447
40483
  ] });
@@ -40450,7 +40486,7 @@ function TransitionRow({ trace }) {
40450
40486
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-start gap-2 text-xs font-mono", children: [
40451
40487
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: cn(
40452
40488
  "mt-1.5 w-1.5 h-1.5 rounded-full flex-shrink-0",
40453
- hasFailedEffects ? "bg-red-500" : "bg-green-500"
40489
+ hasFailedEffects ? "bg-error" : "bg-success"
40454
40490
  ) }),
40455
40491
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: "info", size: "sm", className: "flex-shrink-0", children: trace.event }),
40456
40492
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground flex-shrink-0", children: trace.traitName }),
@@ -40464,7 +40500,7 @@ function TransitionRow({ trace }) {
40464
40500
  ] }),
40465
40501
  trace.effects.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-wrap gap-1 ml-6 mt-0.5", children: trace.effects.map((eff, i) => /* @__PURE__ */ jsxRuntime.jsxs("span", { className: cn(
40466
40502
  "px-1 rounded text-xs",
40467
- eff.status === "executed" ? "bg-green-500/15 text-green-600 dark:text-green-400" : eff.status === "failed" ? "bg-red-500/15 text-red-600 dark:text-red-400" : "bg-yellow-500/15 text-yellow-600 dark:text-yellow-400"
40503
+ eff.status === "executed" ? "bg-success/10 text-success" : eff.status === "failed" ? "bg-error/10 text-error" : "bg-warning/10 text-warning"
40468
40504
  ), children: [
40469
40505
  eff.status === "executed" ? "\u2713" : eff.status === "failed" ? "\u2717" : "-",
40470
40506
  " ",
@@ -40498,7 +40534,7 @@ function VerifyModePanel({
40498
40534
  {
40499
40535
  className: cn(
40500
40536
  "runtime-debugger runtime-debugger--verify",
40501
- "flex flex-col bg-[var(--color-card)] text-[var(--color-foreground)] border-t-2 border-cyan-500",
40537
+ "flex flex-col bg-[var(--color-card)] text-[var(--color-foreground)] border-t-2 border-accent",
40502
40538
  hudBottom ? "" : "fixed bottom-0 left-0 right-0",
40503
40539
  className
40504
40540
  ),
@@ -40519,8 +40555,8 @@ function VerifyModePanel({
40519
40555
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground/50 w-3", "aria-hidden": true, children: expanded ? "\u25BE" : "\u25B8" }),
40520
40556
  /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: failedChecks > 0 ? "danger" : "success", size: "sm", children: failedChecks > 0 ? t("debug.failCount", { count: failedChecks }) : t("debug.ok") }),
40521
40557
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground/70", children: t("debug.localCount", { count: localCount }) }),
40522
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-purple-600 dark:text-purple-400", children: t("debug.serverCount", { count: serverCount }) }),
40523
- traitStates && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-cyan-600 dark:text-cyan-400 truncate max-w-[400px]", children: traitStates }),
40558
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-primary", children: t("debug.serverCount", { count: serverCount }) }),
40559
+ traitStates && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-accent truncate max-w-[400px]", children: traitStates }),
40524
40560
  !expanded && transitions.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-auto text-foreground/50", children: t("debug.transitionsCount", { count: transitions.length }) })
40525
40561
  ]
40526
40562
  }
@@ -40715,7 +40751,7 @@ function RuntimeDebugger({
40715
40751
  title: t("debug.openDebugger"),
40716
40752
  children: failedChecks > 0 ? /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "relative", children: [
40717
40753
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: "V" }),
40718
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute -top-1 -right-2 w-2 h-2 bg-red-500 rounded-full" })
40754
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "absolute -top-1 -right-2 w-2 h-2 bg-error rounded-full" })
40719
40755
  ] }) : /* @__PURE__ */ jsxRuntime.jsx("span", { children: "V" })
40720
40756
  }
40721
40757
  ) : /* @__PURE__ */ jsxRuntime.jsxs(Card, { className: "runtime-debugger__panel", children: [
@@ -40803,7 +40839,7 @@ var init_SegmentRenderer = __esm({
40803
40839
  "div",
40804
40840
  {
40805
40841
  className: cn(
40806
- "border border-gray-200 dark:border-gray-700 rounded-lg p-2 md:p-4 overflow-x-auto space-y-6",
40842
+ "border border-border rounded-lg p-2 md:p-4 overflow-x-auto space-y-6",
40807
40843
  containerClassName,
40808
40844
  className
40809
40845
  ),
@@ -45348,7 +45384,11 @@ function useTraitStateMachine(traitBindings, uiSlots, options) {
45348
45384
  crossTraitLog.debug("listen:subscribed", { busKey, targetTrait: binding.trait.name, sourceOrbital, sourceTrait, listenEvent: listen.event, triggers: listen.triggers });
45349
45385
  const unsub = eventBus.on(busKey, (event) => {
45350
45386
  crossTraitLog.debug("listen:fired", { busKey, targetTrait: binding.trait.name, triggers: listen.triggers });
45351
- enqueueAndDrain(listen.triggers, event.payload, binding.trait.name);
45387
+ enqueueAndDrain(
45388
+ listen.triggers,
45389
+ core.applyListenPayloadMapping(listen.payloadMapping, event.payload),
45390
+ binding.trait.name
45391
+ );
45352
45392
  });
45353
45393
  unsubscribes.push(() => {
45354
45394
  crossTraitLog.debug("listen:unsubscribe", { busKey, targetTrait: binding.trait.name, triggers: listen.triggers });
@@ -45378,7 +45418,7 @@ function useTraitStateMachine(traitBindings, uiSlots, options) {
45378
45418
  }
45379
45419
  for (const event of eventsToFire) {
45380
45420
  stateLog.debug("mount:fire-lifecycle", { event, traitCount: traitBindings.length });
45381
- enqueueAndDrain(event, {});
45421
+ enqueueAndDrain(event, { ...optionsRef.current?.initPayload ?? {} });
45382
45422
  }
45383
45423
  return () => {
45384
45424
  initedTraitsRef.current = /* @__PURE__ */ new Set();
@@ -45419,7 +45459,9 @@ function useResolvedSchema(schema, pageName) {
45419
45459
  trait.listens = callSiteListens.map((l) => ({
45420
45460
  event: l.event,
45421
45461
  triggers: l.triggers,
45422
- source: l.source
45462
+ source: l.source,
45463
+ guard: l.guard,
45464
+ payloadMapping: l.payloadMapping
45423
45465
  }));
45424
45466
  resolvedSchemaLog.info("listens:restored", {
45425
45467
  trait: traitName,
@@ -45578,7 +45620,7 @@ function collectServerActiveTraits(ir, allTraits, mountedTraitNames) {
45578
45620
  }
45579
45621
  return active;
45580
45622
  }
45581
- function TraitInitializer({ traits: traits2, orbitalNames, onNavigate, onLocalFallback, persistence, traitConfigsByName, orbitalsByTrait, embeddedTraits, serverActiveTraits }) {
45623
+ function TraitInitializer({ traits: traits2, routeParams, orbitalNames, onNavigate, onLocalFallback, persistence, traitConfigsByName, orbitalsByTrait, embeddedTraits, serverActiveTraits }) {
45582
45624
  const bridge = providers.useServerBridge();
45583
45625
  const activeTraitNames = React82.useMemo(
45584
45626
  () => new Set(traits2.map((b) => b.trait.name).filter((n) => !!n)),
@@ -45607,43 +45649,48 @@ function TraitInitializer({ traits: traits2, orbitalNames, onNavigate, onLocalFa
45607
45649
  applyServerEffects(effects, uiSlots, onNavigate, embeddedTraits, activeTraitNames);
45608
45650
  }
45609
45651
  }, [bridge.connected, bridge.sendEvent, orbitalNames, uiSlots, onNavigate, embeddedTraits, activeTraitNames, withActiveTraits]);
45610
- const opts = orbitalNames ? { onEventProcessed, navigate: onNavigate, traitConfigsByName, orbitalsByTrait, embeddedTraits } : { navigate: onNavigate, persistence, traitConfigsByName, orbitalsByTrait, embeddedTraits };
45652
+ const opts = orbitalNames ? { onEventProcessed, navigate: onNavigate, traitConfigsByName, orbitalsByTrait, embeddedTraits, initPayload: routeParams } : { navigate: onNavigate, persistence, traitConfigsByName, orbitalsByTrait, embeddedTraits, initPayload: routeParams };
45611
45653
  const { sendEvent } = useTraitStateMachine(traits2, uiSlots, opts);
45612
45654
  const initSentRef = React82.useRef(false);
45613
45655
  const prevTraitsRef = React82.useRef(void 0);
45656
+ const paramsKey = JSON.stringify(routeParams ?? {});
45657
+ const prevParamsKeyRef = React82.useRef(void 0);
45614
45658
  React82.useEffect(() => {
45615
45659
  const refChanged = prevTraitsRef.current !== void 0 && prevTraitsRef.current !== traits2;
45660
+ const paramsChanged = prevParamsKeyRef.current !== void 0 && prevParamsKeyRef.current !== paramsKey;
45616
45661
  navLog.debug("page:traits-effect", () => ({
45617
45662
  refChanged,
45663
+ paramsChanged,
45618
45664
  traitsCount: Array.isArray(traits2) ? traits2.length : -1,
45619
45665
  hadPrev: prevTraitsRef.current !== void 0
45620
45666
  }));
45621
- if (refChanged) {
45622
- navLog.info("page:traits-reset", { traitsCount: Array.isArray(traits2) ? traits2.length : -1 });
45667
+ if (refChanged || paramsChanged) {
45668
+ navLog.info("page:traits-reset", { traitsCount: Array.isArray(traits2) ? traits2.length : -1, paramsChanged });
45623
45669
  uiSlots.clearAll();
45624
45670
  initSentRef.current = false;
45625
45671
  }
45626
45672
  prevTraitsRef.current = traits2;
45627
- }, [traits2, uiSlots]);
45673
+ prevParamsKeyRef.current = paramsKey;
45674
+ }, [traits2, uiSlots, paramsKey]);
45628
45675
  React82.useEffect(() => {
45629
45676
  if (!orbitalNames?.length) {
45630
- const t = setTimeout(() => sendEvent("INIT"), 50);
45677
+ const t = setTimeout(() => sendEvent("INIT", routeParams), 50);
45631
45678
  return () => clearTimeout(t);
45632
45679
  }
45633
45680
  const fallback = setTimeout(() => {
45634
45681
  if (!initSentRef.current) {
45635
- sendEvent("INIT");
45682
+ sendEvent("INIT", routeParams);
45636
45683
  onLocalFallback?.();
45637
45684
  }
45638
45685
  }, 5e3);
45639
45686
  return () => clearTimeout(fallback);
45640
- }, [traits2, orbitalNames, sendEvent, onLocalFallback]);
45687
+ }, [traits2, orbitalNames, sendEvent, onLocalFallback, routeParams]);
45641
45688
  React82.useEffect(() => {
45642
45689
  if (!bridge.connected || !orbitalNames?.length || initSentRef.current) return;
45643
45690
  initSentRef.current = true;
45644
45691
  (async () => {
45645
45692
  for (const name of orbitalNames) {
45646
- const { effects, meta } = await bridge.sendEvent(name, "INIT", withActiveTraits({}));
45693
+ const { effects, meta } = await bridge.sendEvent(name, "INIT", withActiveTraits({ ...routeParams ?? {} }));
45647
45694
  recordServerResponse(name, "INIT", meta);
45648
45695
  const effectTraces = [
45649
45696
  { type: "fetch", args: [], status: "executed" },
@@ -45664,10 +45711,10 @@ function TraitInitializer({ traits: traits2, orbitalNames, onNavigate, onLocalFa
45664
45711
  applyServerEffects(effects, uiSlots, onNavigate, embeddedTraits, activeTraitNames);
45665
45712
  }
45666
45713
  })();
45667
- }, [bridge.connected, orbitalNames, bridge.sendEvent, uiSlots, onNavigate, embeddedTraits, activeTraitNames, withActiveTraits]);
45714
+ }, [bridge.connected, orbitalNames, bridge.sendEvent, uiSlots, onNavigate, embeddedTraits, activeTraitNames, withActiveTraits, routeParams]);
45668
45715
  return null;
45669
45716
  }
45670
- function SchemaRunner({ schema, serverUrl, transport, mockData, pageName, onNavigate, onLocalFallback, persistence }) {
45717
+ function SchemaRunner({ schema, serverUrl, transport, mockData, pageName, routeParams, onNavigate, onLocalFallback, persistence }) {
45671
45718
  const { traits: traits2, allEntities, allTraits, ir } = useResolvedSchema(schema, pageName);
45672
45719
  const allPageTraits = React82.useMemo(() => {
45673
45720
  let base;
@@ -45809,6 +45856,7 @@ function SchemaRunner({ schema, serverUrl, transport, mockData, pageName, onNavi
45809
45856
  TraitInitializer,
45810
45857
  {
45811
45858
  traits: allPageTraits,
45859
+ routeParams,
45812
45860
  orbitalNames: serverUrl || transport ? pageOrbitalNames : void 0,
45813
45861
  traitConfigsByName,
45814
45862
  orbitalsByTrait,
@@ -45886,27 +45934,35 @@ function OrbPreview({
45886
45934
  return [];
45887
45935
  }
45888
45936
  }, [parsedSchema]);
45889
- const initialPageName = React82.useMemo(() => {
45937
+ const initialPageMatch = React82.useMemo(() => {
45890
45938
  if (!initialPagePath) return void 0;
45891
- const match = pages.find(({ page }) => page.path === initialPagePath);
45892
- return match?.page.name;
45939
+ const hit = providers.matchPathAmong(pages, initialPagePath, (entry) => entry.page.path);
45940
+ if (!hit) return void 0;
45941
+ return { name: hit.candidate.page.name, params: hit.params };
45893
45942
  }, [pages, initialPagePath]);
45943
+ const initialPageName = initialPageMatch?.name;
45894
45944
  const [currentPage, setCurrentPage] = React82.useState(initialPageName);
45945
+ const [routeParams, setRouteParams] = React82.useState(initialPageMatch?.params ?? {});
45895
45946
  const prevInitialPagePathRef = React82.useRef(initialPagePath);
45896
45947
  React82.useEffect(() => {
45897
45948
  if (prevInitialPagePathRef.current !== initialPagePath) {
45898
45949
  prevInitialPagePathRef.current = initialPagePath;
45899
45950
  setCurrentPage(initialPageName);
45951
+ setRouteParams(initialPageMatch?.params ?? {});
45900
45952
  }
45901
- }, [initialPagePath, initialPageName]);
45953
+ }, [initialPagePath, initialPageName, initialPageMatch]);
45902
45954
  const handleNavigate = React82.useCallback((path) => {
45903
- const match = pages.find(({ page }) => page.path === path);
45955
+ const hit = providers.matchPathAmong(pages, path, (entry) => entry.page.path);
45956
+ const match = hit?.candidate;
45957
+ const params = hit?.params ?? {};
45904
45958
  navLog.debug("handleNavigate", () => ({
45905
45959
  path,
45906
45960
  matched: match?.page.name ?? null,
45961
+ params,
45907
45962
  availablePaths: pages.map((p) => p.page.path)
45908
45963
  }));
45909
- if (match) {
45964
+ if (match?.page.name) {
45965
+ setRouteParams(params);
45910
45966
  setCurrentPage(match.page.name);
45911
45967
  if (typeof window !== "undefined") {
45912
45968
  const url = new URL(window.location.href);
@@ -45976,6 +46032,7 @@ function OrbPreview({
45976
46032
  transport,
45977
46033
  mockData: effectiveMockData,
45978
46034
  pageName: currentPage,
46035
+ routeParams,
45979
46036
  onNavigate: handleNavigate,
45980
46037
  onLocalFallback: handleLocalFallback,
45981
46038
  persistence