@sofya-ds/react 1.13.1 → 1.14.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -107,26 +107,42 @@ import * as React2 from "react";
107
107
  // src/components/icon-data.ts
108
108
  import {
109
109
  IconAdjustmentsHorizontalFilled,
110
+ IconActivity,
111
+ IconActivityHeartbeat,
110
112
  IconAlignCenter,
111
113
  IconAlignJustified,
112
114
  IconAlignLeft,
113
115
  IconAlignRight,
116
+ IconAlertCircle,
114
117
  IconArrowUp,
115
118
  IconArchive,
116
119
  IconBold,
120
+ IconBrain,
117
121
  IconBuildingHospital,
118
122
  IconBooks,
119
123
  IconBulb,
120
124
  IconChartBar,
121
125
  IconCheck,
122
126
  IconChecklist,
127
+ IconClipboardList,
128
+ IconClipboardText,
123
129
  IconCode,
130
+ IconFileText,
131
+ IconFlask,
132
+ IconHeartbeat,
124
133
  IconItalic,
125
134
  IconLink,
126
135
  IconList,
136
+ IconListCheck,
127
137
  IconListNumbers,
138
+ IconNotes,
139
+ IconPill,
128
140
  IconQuote,
141
+ IconReportMedical,
129
142
  IconStrikethrough,
143
+ IconStethoscope,
144
+ IconTable,
145
+ IconTemperature,
130
146
  IconUnderline,
131
147
  IconChevronLeft,
132
148
  IconChevronDown,
@@ -166,26 +182,42 @@ import {
166
182
  } from "@tabler/icons-react";
167
183
  var tablerIconRegistry = {
168
184
  IconAdjustmentsHorizontalFilled,
185
+ IconActivity,
186
+ IconActivityHeartbeat,
169
187
  IconAlignCenter,
170
188
  IconAlignJustified,
171
189
  IconAlignLeft,
172
190
  IconAlignRight,
191
+ IconAlertCircle,
173
192
  IconArrowUp,
174
193
  IconArchive,
175
194
  IconBold,
195
+ IconBrain,
176
196
  IconBuildingHospital,
177
197
  IconBooks,
178
198
  IconBulb,
179
199
  IconChartBar,
180
200
  IconCheck,
181
201
  IconChecklist,
202
+ IconClipboardList,
203
+ IconClipboardText,
182
204
  IconCode,
205
+ IconFileText,
206
+ IconFlask,
207
+ IconHeartbeat,
183
208
  IconItalic,
184
209
  IconLink,
185
210
  IconList,
211
+ IconListCheck,
186
212
  IconListNumbers,
213
+ IconNotes,
214
+ IconPill,
187
215
  IconQuote,
216
+ IconReportMedical,
188
217
  IconStrikethrough,
218
+ IconStethoscope,
219
+ IconTable,
220
+ IconTemperature,
189
221
  IconUnderline,
190
222
  IconChevronLeft,
191
223
  IconChevronDown,
@@ -253,6 +285,7 @@ var legacyIconToTablerNameMap = {
253
285
  "lightbulb": "IconBulb",
254
286
  "chats": "IconMessages",
255
287
  "file": "IconFile",
288
+ "file-text": "IconFileText",
256
289
  "folders": "IconFolders",
257
290
  "sparkle": "IconSparkles",
258
291
  "x": "IconX",
@@ -260,6 +293,21 @@ var legacyIconToTablerNameMap = {
260
293
  "search": "IconSearch",
261
294
  "arrow-up": "IconArrowUp",
262
295
  "question": "IconHelpCircle",
296
+ "activity": "IconActivity",
297
+ "activity-heartbeat": "IconActivityHeartbeat",
298
+ "alert-circle": "IconAlertCircle",
299
+ "brain": "IconBrain",
300
+ "clipboard-list": "IconClipboardList",
301
+ "clipboard-text": "IconClipboardText",
302
+ "flask": "IconFlask",
303
+ "heartbeat": "IconHeartbeat",
304
+ "list-check": "IconListCheck",
305
+ "notes": "IconNotes",
306
+ "pill": "IconPill",
307
+ "report-medical": "IconReportMedical",
308
+ "stethoscope": "IconStethoscope",
309
+ "table": "IconTable",
310
+ "temperature": "IconTemperature",
263
311
  "user-filled": "IconUserFilled",
264
312
  "caret-up": "IconChevronUp",
265
313
  "caret-left": "IconChevronLeft",
@@ -475,8 +523,10 @@ var defaultElements = {
475
523
  "body-md": "p",
476
524
  "body-sm": "p",
477
525
  body: "p",
526
+ "clinical-body": "p",
478
527
  "label-md": "span",
479
528
  "settings-section-title": "span",
529
+ "clinical-section-title": "span",
480
530
  "section-label": "span",
481
531
  "eyebrow-md": "span",
482
532
  "overline-md": "span",
@@ -504,7 +554,7 @@ var textSizeStyles = Object.fromEntries(
504
554
  fontWeight: `var(--sofya-text-${size}-font-weight)`,
505
555
  lineHeight: `var(--sofya-text-${size}-line-height)`,
506
556
  letterSpacing: `var(--sofya-text-${size}-letter-spacing)`,
507
- ...size === "settings-section-title" ? { textTransform: "uppercase" } : {}
557
+ ...size === "settings-section-title" || size === "clinical-section-title" ? { textTransform: "uppercase" } : {}
508
558
  }
509
559
  ])
510
560
  );
@@ -1986,7 +2036,8 @@ var dropdownVariantOptions = [
1986
2036
  "card",
1987
2037
  "language",
1988
2038
  "selected",
1989
- "action"
2039
+ "action",
2040
+ "inline"
1990
2041
  ];
1991
2042
  var dropdownAppearanceOptions = ["card"];
1992
2043
  var dropdownTriggerSizeOptions = ["default", "sm", "lg"];
@@ -1999,7 +2050,8 @@ var dropdownTriggerToneClasses = {
1999
2050
  card: "text-primary",
2000
2051
  language: "",
2001
2052
  selected: "w-full border-[color:var(--sofya-border-strong)] [font-family:var(--sofya-text-tiny-font-family)] text-[length:var(--sofya-text-tiny-font-size)] [font-weight:var(--sofya-text-tiny-font-weight)] leading-[var(--sofya-text-tiny-line-height)] tracking-[var(--sofya-text-tiny-letter-spacing)]",
2002
- action: ""
2053
+ action: "",
2054
+ inline: "border-0 bg-transparent p-0 [font-family:var(--sofya-text-tiny-font-family)] text-[length:var(--sofya-text-tiny-font-size)] font-semibold leading-[var(--sofya-text-tiny-line-height)] tracking-[0.001em] text-primary shadow-none hover:bg-transparent hover:text-primary active:bg-transparent"
2003
2055
  };
2004
2056
  var dropdownTriggerSizeClasses = {
2005
2057
  regular: {
@@ -2021,6 +2073,11 @@ var dropdownTriggerSizeClasses = {
2021
2073
  default: "h-10 w-10 p-0",
2022
2074
  sm: "h-8 w-8 p-0",
2023
2075
  lg: "h-12 w-12 p-0"
2076
+ },
2077
+ inline: {
2078
+ default: "h-[18px] px-0 py-0",
2079
+ sm: "h-[18px] px-0 py-0",
2080
+ lg: "h-[18px] px-0 py-0"
2024
2081
  }
2025
2082
  };
2026
2083
  var dropdownAppearanceClasses = {
@@ -2033,13 +2090,15 @@ var dropdownContentBaseClasses = {
2033
2090
  card: "border-[color:var(--sofya-border-strong)] text-foreground shadow-[var(--sofya-shadow-soft)]",
2034
2091
  language: "w-[224px] min-w-[224px] border-[color:var(--sofya-border-strong)] text-foreground shadow-[var(--sofya-shadow-soft)]",
2035
2092
  selected: "w-[var(--radix-dropdown-menu-trigger-width)] min-w-[var(--radix-dropdown-menu-trigger-width)] border-[color:var(--sofya-border-strong)] text-foreground shadow-[var(--sofya-shadow-soft)]",
2036
- action: "w-[224px] min-w-[224px] border-[color:var(--sofya-border-strong)] text-foreground shadow-[var(--sofya-shadow-soft)]"
2093
+ action: "w-[224px] min-w-[224px] border-[color:var(--sofya-border-strong)] text-foreground shadow-[var(--sofya-shadow-soft)]",
2094
+ inline: "w-[178px] min-w-[178px] border-0 text-[color:hsl(var(--sofya-muted-foreground))] shadow-[0_2px_4px_hsl(var(--sofya-foreground)/0.10)]"
2037
2095
  };
2038
2096
  var dropdownItemClasses = {
2039
2097
  card: "text-foreground",
2040
2098
  language: "text-foreground",
2041
2099
  selected: "text-foreground",
2042
- action: "text-foreground"
2100
+ action: "text-foreground",
2101
+ inline: "text-[color:hsl(var(--sofya-muted-foreground))]"
2043
2102
  };
2044
2103
  function isButtonLanguageLocale(value) {
2045
2104
  return buttonLanguageLocaleOptions.includes(value);
@@ -2068,6 +2127,9 @@ function resolveDropdownTriggerSizeFamily(variant) {
2068
2127
  if (variant === "action") {
2069
2128
  return "action";
2070
2129
  }
2130
+ if (variant === "inline") {
2131
+ return "inline";
2132
+ }
2071
2133
  return "regular";
2072
2134
  }
2073
2135
  function resolveAccessibleText(node) {
@@ -2087,6 +2149,9 @@ function resolveAccessibleText(node) {
2087
2149
  return result.length > 0 ? result : void 0;
2088
2150
  }
2089
2151
  function DefaultDropdownTriggerIcon({ variant }) {
2152
+ if (variant === "inline") {
2153
+ return /* @__PURE__ */ jsx13("span", { className: "flex h-4 w-4 shrink-0 items-center justify-center rounded-full bg-[color:var(--sofya-surface-selected)] text-[color:var(--sofya-link-hover)]", children: /* @__PURE__ */ jsx13(Icon, { name: "caret-down", className: "h-3 w-3" }) });
2154
+ }
2090
2155
  if (variant === "selected") {
2091
2156
  return /* @__PURE__ */ jsx13(
2092
2157
  Icon,
@@ -2141,6 +2206,7 @@ function Dropdown({
2141
2206
  const isLanguageVariant = variant === "language";
2142
2207
  const isSelectedVariant = variant === "selected";
2143
2208
  const isActionVariant = variant === "action";
2209
+ const isInlineVariant = variant === "inline";
2144
2210
  const isIconOnlyTrigger = iconTrigger !== void 0 && !isActionVariant;
2145
2211
  const resolvedAppearance = resolveDropdownAppearance({ appearance, variant });
2146
2212
  const triggerSizeFamily = isIconOnlyTrigger ? "action" : resolveDropdownTriggerSizeFamily(variant);
@@ -2193,7 +2259,7 @@ function Dropdown({
2193
2259
  Button,
2194
2260
  {
2195
2261
  type: "button",
2196
- variant: isLanguageVariant ? "language" : isActionVariant || isIconOnlyTrigger ? "ghost" : "dropdown",
2262
+ variant: isLanguageVariant ? "language" : isActionVariant || isIconOnlyTrigger ? "ghost" : isInlineVariant ? "ghost" : "dropdown",
2197
2263
  languageLocale: selectedLanguageLocale,
2198
2264
  "data-appearance": resolvedAppearance,
2199
2265
  "data-trigger-size": triggerSize,
@@ -2204,6 +2270,7 @@ function Dropdown({
2204
2270
  dropdownTriggerSizeClasses[triggerSizeFamily][triggerSize],
2205
2271
  !isIconOnlyTrigger && dropdownAppearanceClasses[resolvedAppearance].trigger,
2206
2272
  selectedTriggerToneClassName,
2273
+ isInlineVariant && "justify-end gap-2",
2207
2274
  isIconOnlyTrigger && "flex items-center justify-center",
2208
2275
  triggerClassName
2209
2276
  ),
@@ -2211,7 +2278,10 @@ function Dropdown({
2211
2278
  rightIcon: resolvedTriggerIcon,
2212
2279
  children: isLanguageVariant || isActionVariant || isIconOnlyTrigger ? null : /* @__PURE__ */ jsx13("span", { className: "min-w-0 truncate", children: renderTextContent(triggerLabel, {
2213
2280
  as: "span",
2214
- className: "block min-w-0 truncate text-inherit",
2281
+ className: cn(
2282
+ "block min-w-0 truncate text-inherit",
2283
+ isInlineVariant && "text-right"
2284
+ ),
2215
2285
  size: "tiny"
2216
2286
  }) })
2217
2287
  }
@@ -2226,6 +2296,7 @@ function Dropdown({
2226
2296
  "sofya-dropdown-content z-50 w-auto min-w-[var(--radix-dropdown-menu-trigger-width)] border bg-card p-2 outline-none",
2227
2297
  dropdownContentBaseClasses[variant],
2228
2298
  dropdownAppearanceClasses[resolvedAppearance].content,
2299
+ isInlineVariant && "rounded-2xl",
2229
2300
  contentClassName
2230
2301
  ),
2231
2302
  children: /* @__PURE__ */ jsx13(
@@ -2463,7 +2534,8 @@ function Dropdown({
2463
2534
  disabled: item.disabled,
2464
2535
  className: cn(
2465
2536
  "flex w-full cursor-pointer items-center rounded-[4px] [font-family:var(--sofya-text-tiny-font-family)] text-[length:var(--sofya-text-tiny-font-size)] [font-weight:var(--sofya-text-tiny-font-weight)] leading-[22px] tracking-[var(--sofya-text-tiny-letter-spacing)] outline-none transition-colors duration-sofya ease-sofya data-[disabled]:pointer-events-none data-[disabled]:opacity-40",
2466
- "px-0 py-0 data-[highlighted]:bg-transparent [&[data-highlighted]_span[data-dropdown-item-body]]:bg-[color:var(--sofya-surface-selected)]",
2537
+ "px-0 py-0 data-[highlighted]:bg-transparent",
2538
+ isInlineVariant ? "[&[data-highlighted]_span[data-dropdown-item-body]]:bg-[color:var(--sofya-surface-hover)]" : "[&[data-highlighted]_span[data-dropdown-item-body]]:bg-[color:var(--sofya-surface-selected)]",
2467
2539
  dropdownItemClasses[variant],
2468
2540
  itemClassName
2469
2541
  ),
@@ -2473,7 +2545,7 @@ function Dropdown({
2473
2545
  "data-dropdown-item-body": true,
2474
2546
  className: cn(
2475
2547
  "inline-flex min-w-0 items-center gap-2 rounded-full px-4 py-2 transition-colors duration-sofya ease-sofya",
2476
- isSelected ? "bg-[color:var(--sofya-surface-selected)]" : "bg-transparent"
2548
+ isSelected ? isInlineVariant ? "bg-[color:var(--sofya-surface-hover)]" : "bg-[color:var(--sofya-surface-selected)]" : "bg-transparent"
2477
2549
  ),
2478
2550
  children: [
2479
2551
  itemIcon ? /* @__PURE__ */ jsx13("span", { className: "flex shrink-0 items-center justify-center", children: itemIcon }) : null,
@@ -2575,7 +2647,7 @@ function FieldShell({
2575
2647
  // src/components/input-upload.tsx
2576
2648
  import * as React14 from "react";
2577
2649
  import {
2578
- IconFileText,
2650
+ IconFileText as IconFileText2,
2579
2651
  IconPhoto,
2580
2652
  IconUpload,
2581
2653
  IconVideo
@@ -2706,7 +2778,7 @@ function UploadFileTypeGlyph({
2706
2778
  );
2707
2779
  }
2708
2780
  return /* @__PURE__ */ jsx15(
2709
- IconFileText,
2781
+ IconFileText2,
2710
2782
  {
2711
2783
  "aria-hidden": "true",
2712
2784
  className: cn("inline-block shrink-0 align-middle", className)
@@ -4994,11 +5066,1424 @@ var RichTextToolbarButton = React31.forwardRef(function RichTextToolbarButton2({
4994
5066
  });
4995
5067
  RichTextToolbarButton.displayName = "RichTextToolbarButton";
4996
5068
 
4997
- // src/components/right-rail-action.tsx
5069
+ // src/components/reasoning-widget.tsx
4998
5070
  import * as React32 from "react";
4999
- import { jsx as jsx34 } from "react/jsx-runtime";
5000
- var RightRailAction = React32.forwardRef(
5001
- ({ active = false, className, icon, ...props }, ref) => /* @__PURE__ */ jsx34(
5071
+ import { jsx as jsx34, jsxs as jsxs17 } from "react/jsx-runtime";
5072
+ var reasoningWidgetToneOptions = [
5073
+ "default",
5074
+ "info",
5075
+ "success",
5076
+ "warning",
5077
+ "critical",
5078
+ "muted"
5079
+ ];
5080
+ var reasoningWidgetDensityOptions = ["default", "compact"];
5081
+ var reasoningWidgetVariantOptions = [
5082
+ "flat",
5083
+ "outline",
5084
+ "muted",
5085
+ "suggestion"
5086
+ ];
5087
+ var reasoningWidgetActionScopeOptions = ["item", "widget"];
5088
+ var reasoningWidgetActionToneOptions = [
5089
+ "primary",
5090
+ "neutral",
5091
+ "danger"
5092
+ ];
5093
+ var reasoningWidgetTableAlignOptions = [
5094
+ "left",
5095
+ "center",
5096
+ "right"
5097
+ ];
5098
+ var reasoningWidgetTableColumnVariantOptions = [
5099
+ "default",
5100
+ "value"
5101
+ ];
5102
+ var reasoningWidgetFrameOptions = ["bordered", "minimal"];
5103
+ var ReasoningWidgetDensityContext = React32.createContext("default");
5104
+ var actionIconNames = {
5105
+ accept: "check",
5106
+ add: "plus",
5107
+ edit: "edit",
5108
+ reject: "x",
5109
+ remove: "trash"
5110
+ };
5111
+ var actionToneById = {
5112
+ accept: "primary",
5113
+ add: "primary",
5114
+ edit: "neutral",
5115
+ reject: "danger",
5116
+ remove: "danger"
5117
+ };
5118
+ var actionVariantByTone = {
5119
+ danger: "destructive",
5120
+ neutral: "ghost",
5121
+ primary: "subtle"
5122
+ };
5123
+ var toneSurfaceClassName = {
5124
+ default: "border-[color:var(--sofya-neutral-600)] bg-card",
5125
+ info: "border-[color:var(--sofya-tone-info-border)] bg-[color:var(--sofya-tone-info-background)]",
5126
+ success: "border-[color:var(--sofya-tone-success-border)] bg-[color:var(--sofya-tone-success-background)]",
5127
+ warning: "border-[color:var(--sofya-tone-warning-border)] bg-[color:var(--sofya-tone-warning-background)]",
5128
+ critical: "border-[color:var(--sofya-tone-destructive-border)] bg-[color:var(--sofya-tone-destructive-background)]",
5129
+ muted: "border-[color:var(--sofya-neutral-600)] bg-card"
5130
+ };
5131
+ var clinicalToneMarkerClassName = {
5132
+ default: "bg-[color:var(--sofya-neutral-600)]",
5133
+ info: "bg-secondary",
5134
+ success: "bg-[color:var(--sofya-tag-green)]",
5135
+ warning: "bg-[color:var(--sofya-tag-red)]",
5136
+ critical: "bg-[color:var(--sofya-tag-red)]",
5137
+ muted: "bg-[color:var(--sofya-neutral-600)]"
5138
+ };
5139
+ var clinicalToneSurfaceClassName = {
5140
+ default: "bg-transparent",
5141
+ info: "bg-[color:var(--sofya-neutral-50)]",
5142
+ success: "bg-transparent",
5143
+ warning: "bg-transparent",
5144
+ critical: "bg-transparent",
5145
+ muted: "bg-transparent"
5146
+ };
5147
+ var clinicalToneStatusClassName = {
5148
+ default: "text-[color:var(--sofya-text-subtle)]",
5149
+ info: "text-secondary",
5150
+ success: "text-[color:var(--sofya-tag-green)]",
5151
+ warning: "text-[color:var(--sofya-tag-red)]",
5152
+ critical: "text-[color:var(--sofya-tag-red)]",
5153
+ muted: "text-[color:var(--sofya-text-subtle)]"
5154
+ };
5155
+ var clinicalToneValueClassName = {
5156
+ default: "text-[color:var(--sofya-neutral-900)]",
5157
+ info: "text-[color:var(--sofya-neutral-900)]",
5158
+ success: "text-[color:var(--sofya-neutral-900)]",
5159
+ warning: "text-[color:var(--sofya-tag-red)]",
5160
+ critical: "text-[color:var(--sofya-tag-red)]",
5161
+ muted: "text-[color:var(--sofya-neutral-900)]"
5162
+ };
5163
+ var clinicalToneBadgeClassName = {
5164
+ default: "bg-[color:var(--sofya-neutral-50)] text-[color:var(--sofya-text-subtle)]",
5165
+ info: "bg-[color:var(--sofya-neutral-50)] text-secondary",
5166
+ success: "bg-[color:var(--sofya-agent-mint)] text-[color:var(--sofya-tag-green)]",
5167
+ warning: "bg-[color:var(--sofya-tag-sand)] text-[color:var(--sofya-tag-red)]",
5168
+ critical: "bg-[color:var(--sofya-tag-sand)] text-[color:var(--sofya-tag-red)]",
5169
+ muted: "bg-[color:var(--sofya-neutral-50)] text-[color:var(--sofya-text-subtle)]"
5170
+ };
5171
+ var clinicalDataFrameClassName = {
5172
+ bordered: "w-full overflow-hidden rounded-[var(--sofya-radius-lg)] border border-[color:var(--sofya-neutral-600)] bg-card",
5173
+ minimal: "w-full overflow-hidden rounded-[var(--sofya-radius-md)] border-0 bg-[color:var(--sofya-neutral-50)]"
5174
+ };
5175
+ var clinicalDataHeaderClassName = {
5176
+ bordered: "border-b border-[color:var(--sofya-neutral-600)] bg-[color:var(--sofya-neutral-50)]",
5177
+ minimal: "border-b border-[color:var(--sofya-neutral-600)] bg-transparent"
5178
+ };
5179
+ var clinicalLabsFrameClassName = {
5180
+ bordered: "w-full overflow-x-auto overflow-y-hidden rounded-[var(--sofya-radius-lg)] border border-[color:var(--sofya-neutral-600)] bg-card",
5181
+ minimal: "w-fit max-w-full overflow-x-auto overflow-y-hidden rounded-[var(--sofya-radius-md)] border-0 bg-[color:var(--sofya-neutral-50)]"
5182
+ };
5183
+ var tableAlignClassName = {
5184
+ center: "text-center",
5185
+ left: "text-left",
5186
+ right: "text-right"
5187
+ };
5188
+ function isWidgetAction(action) {
5189
+ return action.scope === "widget";
5190
+ }
5191
+ function isItemAction(action) {
5192
+ return action.scope !== "widget";
5193
+ }
5194
+ function getActionIcon(action) {
5195
+ if (action.icon) {
5196
+ return action.icon;
5197
+ }
5198
+ return actionIconNames[action.id] ?? "square-toggle";
5199
+ }
5200
+ function getActionTone(action) {
5201
+ if (action.tone) {
5202
+ return action.tone;
5203
+ }
5204
+ return actionToneById[action.id] ?? "neutral";
5205
+ }
5206
+ function getTargetLabel(target) {
5207
+ if (!target) {
5208
+ return void 0;
5209
+ }
5210
+ if ("label" in target) {
5211
+ return typeof target.label === "string" || typeof target.label === "number" ? String(target.label) : target.id;
5212
+ }
5213
+ return target.id;
5214
+ }
5215
+ function getActionLabel(action, target) {
5216
+ if (action.ariaLabel) {
5217
+ return action.ariaLabel;
5218
+ }
5219
+ const targetLabel = getTargetLabel(target);
5220
+ return targetLabel ? `${action.label} ${targetLabel}` : action.label;
5221
+ }
5222
+ function getItemsFromDescriptor(widget) {
5223
+ return widget.items ?? widget.data?.items ?? [];
5224
+ }
5225
+ function getDescriptionFromDescriptor(widget) {
5226
+ return widget.description ?? widget.data?.description;
5227
+ }
5228
+ function getEmptyLabelFromDescriptor(widget) {
5229
+ return widget.emptyLabel ?? widget.data?.emptyLabel;
5230
+ }
5231
+ function getFrameFromDescriptor(widget) {
5232
+ return widget.frame ?? widget.data?.frame;
5233
+ }
5234
+ function getDescriptorKind(widget) {
5235
+ return `${widget.component ?? ""} ${widget.type ?? ""}`.toLowerCase();
5236
+ }
5237
+ function getIconFromDescriptor(widget) {
5238
+ if (widget.icon) {
5239
+ return widget.icon;
5240
+ }
5241
+ const descriptorKind = getDescriptorKind(widget);
5242
+ if (descriptorKind.includes("summary") || descriptorKind.includes("impression") || hasRenderableNode(widget.data?.impression)) {
5243
+ return "stethoscope";
5244
+ }
5245
+ if (descriptorKind.includes("vitals")) {
5246
+ return "activity-heartbeat";
5247
+ }
5248
+ if (descriptorKind.includes("question")) {
5249
+ return "question";
5250
+ }
5251
+ if (descriptorKind.includes("prescription") || descriptorKind.includes("medication")) {
5252
+ return "pill";
5253
+ }
5254
+ if (descriptorKind.includes("lab")) {
5255
+ return "flask";
5256
+ }
5257
+ if (descriptorKind.includes("alert")) {
5258
+ return "alert-circle";
5259
+ }
5260
+ if (widget.data?.tableColumns && widget.data.rows) {
5261
+ return "table";
5262
+ }
5263
+ return "clipboard-list";
5264
+ }
5265
+ function hasRenderableNode(value) {
5266
+ return value !== null && value !== void 0 && value !== false;
5267
+ }
5268
+ function isEditableTextValue(value) {
5269
+ return typeof value === "string" || typeof value === "number";
5270
+ }
5271
+ function ReasoningEditableText({
5272
+ as = "span",
5273
+ ariaLabel,
5274
+ className,
5275
+ editable = false,
5276
+ multiline = false,
5277
+ onCommit,
5278
+ size,
5279
+ value,
5280
+ weight
5281
+ }) {
5282
+ if (!editable || !isEditableTextValue(value)) {
5283
+ return renderTextContent(value, {
5284
+ as,
5285
+ className,
5286
+ size,
5287
+ weight
5288
+ });
5289
+ }
5290
+ const initialValue = String(value);
5291
+ return /* @__PURE__ */ jsx34(
5292
+ Text,
5293
+ {
5294
+ as,
5295
+ "aria-label": ariaLabel,
5296
+ className: cn(
5297
+ "rounded-[4px] text-inherit outline-none transition-[background-color,box-shadow] duration-sofya ease-sofya",
5298
+ "-mx-1 px-1 hover:bg-[color:var(--sofya-surface-hover)] focus-visible:bg-card focus-visible:ring-2 focus-visible:ring-[color:var(--sofya-focus-ring-strong)]",
5299
+ multiline ? "whitespace-pre-wrap" : "truncate",
5300
+ className
5301
+ ),
5302
+ contentEditable: true,
5303
+ "data-editable": "true",
5304
+ role: "textbox",
5305
+ size,
5306
+ spellCheck: true,
5307
+ suppressContentEditableWarning: true,
5308
+ tabIndex: 0,
5309
+ weight,
5310
+ onBlur: (event) => {
5311
+ const nextValue = event.currentTarget.textContent ?? "";
5312
+ if (nextValue !== initialValue) {
5313
+ onCommit?.(nextValue);
5314
+ }
5315
+ },
5316
+ onKeyDown: (event) => {
5317
+ if (event.key === "Enter" && !multiline) {
5318
+ event.preventDefault();
5319
+ event.currentTarget.blur();
5320
+ }
5321
+ },
5322
+ children: initialValue
5323
+ }
5324
+ );
5325
+ }
5326
+ var ReasoningWidgetActionButton = React32.forwardRef(function ReasoningWidgetActionButton2({ action, className, disabled, onAction, target, widgetId, ...props }, ref) {
5327
+ const tone = getActionTone(action);
5328
+ return /* @__PURE__ */ jsx34(
5329
+ IconButton,
5330
+ {
5331
+ ref,
5332
+ "aria-label": getActionLabel(
5333
+ action,
5334
+ target
5335
+ ),
5336
+ "data-action-id": action.id,
5337
+ "data-action-scope": action.scope,
5338
+ disabled: disabled ?? action.disabled,
5339
+ icon: /* @__PURE__ */ jsx34(Icon, { name: getActionIcon(action), size: "sm" }),
5340
+ size: "sm",
5341
+ variant: actionVariantByTone[tone],
5342
+ className: cn(
5343
+ "rounded-[var(--sofya-radius-sm)] text-[color:var(--sofya-text-soft)]",
5344
+ tone === "primary" && "text-primary",
5345
+ className
5346
+ ),
5347
+ onClick: () => {
5348
+ onAction?.({
5349
+ action,
5350
+ target,
5351
+ widgetId
5352
+ });
5353
+ },
5354
+ ...props
5355
+ }
5356
+ );
5357
+ });
5358
+ var ReasoningWidgetActions = React32.forwardRef(function ReasoningWidgetActions2({
5359
+ actions = [],
5360
+ className,
5361
+ onAction,
5362
+ reveal = "widget-hover",
5363
+ target,
5364
+ widgetId,
5365
+ ...props
5366
+ }, ref) {
5367
+ if (actions.length === 0) {
5368
+ return null;
5369
+ }
5370
+ return /* @__PURE__ */ jsx34(
5371
+ "div",
5372
+ {
5373
+ ref,
5374
+ "data-slot": "reasoning-widget-actions",
5375
+ "data-reveal": reveal,
5376
+ className: cn(
5377
+ "z-10 flex shrink-0 items-center gap-1 transition-opacity duration-sofya ease-sofya",
5378
+ reveal === "widget-hover" && "pointer-events-none opacity-0 group-hover/reasoning:pointer-events-auto group-hover/reasoning:opacity-100 group-focus-within/reasoning:pointer-events-auto group-focus-within/reasoning:opacity-100",
5379
+ reveal === "item-hover" && "pointer-events-none opacity-0 group-hover/item:pointer-events-auto group-hover/item:opacity-100 group-focus-within/item:pointer-events-auto group-focus-within/item:opacity-100",
5380
+ className
5381
+ ),
5382
+ ...props,
5383
+ children: actions.map((action) => /* @__PURE__ */ jsx34(
5384
+ ReasoningWidgetActionButton,
5385
+ {
5386
+ action,
5387
+ onAction,
5388
+ target,
5389
+ widgetId
5390
+ },
5391
+ action.id
5392
+ ))
5393
+ }
5394
+ );
5395
+ });
5396
+ var ReasoningWidget = React32.forwardRef(
5397
+ function ReasoningWidget2({
5398
+ actions = [],
5399
+ children,
5400
+ className,
5401
+ density = "default",
5402
+ description,
5403
+ empty = false,
5404
+ emptyLabel = "No extracted information yet.",
5405
+ eyebrow,
5406
+ icon,
5407
+ onAction,
5408
+ sectionDivider = false,
5409
+ title,
5410
+ variant = "flat",
5411
+ widgetId,
5412
+ ...props
5413
+ }, ref) {
5414
+ const widgetActions = actions.filter(isWidgetAction);
5415
+ return /* @__PURE__ */ jsx34(ReasoningWidgetDensityContext.Provider, { value: density, children: /* @__PURE__ */ jsxs17(
5416
+ "article",
5417
+ {
5418
+ ref,
5419
+ "data-density": density,
5420
+ "data-slot": "reasoning-widget",
5421
+ "data-variant": variant,
5422
+ className: cn(
5423
+ "group/reasoning w-full shadow-none",
5424
+ "transition-[border-color,box-shadow] duration-sofya ease-sofya",
5425
+ variant === "flat" && "rounded-none border-0 bg-transparent p-0",
5426
+ variant === "outline" && "rounded-[var(--sofya-radius-md)] border border-[color:var(--sofya-border-strong)] bg-card",
5427
+ variant === "muted" && "rounded-[var(--sofya-radius-md)] border-0 bg-[color:var(--sofya-surface-muted)]",
5428
+ variant === "suggestion" && "rounded-[var(--sofya-radius-md)] border border-[color:var(--sofya-border-hover)] bg-card",
5429
+ variant !== "flat" && (density === "compact" ? "p-4" : "p-5"),
5430
+ className
5431
+ ),
5432
+ ...props,
5433
+ children: [
5434
+ /* @__PURE__ */ jsxs17(
5435
+ "div",
5436
+ {
5437
+ "data-slot": "reasoning-widget-header",
5438
+ className: "relative flex items-start gap-4",
5439
+ children: [
5440
+ /* @__PURE__ */ jsxs17("div", { className: "flex min-w-0 flex-1 items-start gap-3", children: [
5441
+ /* @__PURE__ */ jsxs17("div", { className: "flex min-w-0 items-start gap-2.5", children: [
5442
+ icon ? /* @__PURE__ */ jsx34(
5443
+ "span",
5444
+ {
5445
+ "aria-hidden": "true",
5446
+ "data-icon": icon,
5447
+ "data-slot": "reasoning-widget-icon",
5448
+ className: "mt-0.5 inline-flex size-4 shrink-0 items-center justify-center text-secondary",
5449
+ children: /* @__PURE__ */ jsx34(Icon, { name: icon, size: 14, strokeWidth: 1.8 })
5450
+ }
5451
+ ) : null,
5452
+ /* @__PURE__ */ jsxs17("div", { className: "min-w-0", children: [
5453
+ eyebrow ? renderTextContent(eyebrow, {
5454
+ as: "span",
5455
+ className: "mb-1 block uppercase text-secondary [font-weight:var(--sofya-text-section-label-font-weight)]",
5456
+ size: "section-label"
5457
+ }) : null,
5458
+ /* @__PURE__ */ jsx34(
5459
+ "h3",
5460
+ {
5461
+ className: cn(
5462
+ "m-0",
5463
+ eyebrow ? "text-[color:var(--sofya-neutral-800)]" : "text-secondary"
5464
+ ),
5465
+ children: renderTextContent(title, {
5466
+ as: "span",
5467
+ className: cn(
5468
+ "block text-inherit",
5469
+ !eyebrow && "uppercase"
5470
+ ),
5471
+ size: eyebrow ? density === "compact" ? "label-md" : "title-sm" : density === "compact" ? "section-label" : "clinical-section-title"
5472
+ })
5473
+ }
5474
+ ),
5475
+ description ? renderTextContent(description, {
5476
+ as: "p",
5477
+ className: "mt-2 text-[color:var(--sofya-text-subtle)]",
5478
+ size: "body-md"
5479
+ }) : null
5480
+ ] })
5481
+ ] }),
5482
+ sectionDivider ? /* @__PURE__ */ jsx34(
5483
+ "span",
5484
+ {
5485
+ "aria-hidden": "true",
5486
+ "data-slot": "reasoning-widget-section-divider",
5487
+ className: cn(
5488
+ "mt-2 h-px min-w-8 flex-1 bg-[color:var(--sofya-neutral-600)]",
5489
+ widgetActions.length > 0 && "mr-12"
5490
+ )
5491
+ }
5492
+ ) : null
5493
+ ] }),
5494
+ /* @__PURE__ */ jsx34(
5495
+ ReasoningWidgetActions,
5496
+ {
5497
+ actions: widgetActions,
5498
+ className: "absolute right-0 top-1/2 -translate-y-1/2",
5499
+ onAction,
5500
+ reveal: "widget-hover",
5501
+ widgetId
5502
+ }
5503
+ )
5504
+ ]
5505
+ }
5506
+ ),
5507
+ /* @__PURE__ */ jsx34(
5508
+ "div",
5509
+ {
5510
+ "data-slot": "reasoning-widget-content",
5511
+ className: cn(density === "compact" ? "mt-3" : "mt-4"),
5512
+ children: empty ? renderTextContent(emptyLabel, {
5513
+ as: "p",
5514
+ className: "m-0 text-[color:var(--sofya-text-subtle)]",
5515
+ size: "body-md"
5516
+ }) : children
5517
+ }
5518
+ )
5519
+ ]
5520
+ }
5521
+ ) });
5522
+ }
5523
+ );
5524
+ var ReasoningWidgetList = React32.forwardRef(function ReasoningWidgetList2({
5525
+ actions = [],
5526
+ className,
5527
+ editable = false,
5528
+ emptyLabel,
5529
+ items,
5530
+ onAction,
5531
+ onItemEdit,
5532
+ widgetId,
5533
+ ...props
5534
+ }, ref) {
5535
+ const itemActions = actions.filter(isItemAction);
5536
+ const density = React32.useContext(ReasoningWidgetDensityContext);
5537
+ const primaryTextSize = density === "compact" ? "body-md" : "clinical-body";
5538
+ const supportingTextSize = density === "compact" ? "body-sm" : "clinical-body";
5539
+ if (items.length === 0) {
5540
+ return /* @__PURE__ */ jsx34("p", { className: "m-0 text-[color:var(--sofya-text-subtle)]", children: renderTextContent(emptyLabel ?? "No extracted items.", {
5541
+ as: "span",
5542
+ className: "block text-inherit",
5543
+ size: "body-md"
5544
+ }) });
5545
+ }
5546
+ return /* @__PURE__ */ jsx34(
5547
+ "ul",
5548
+ {
5549
+ ref,
5550
+ "data-slot": "reasoning-widget-list",
5551
+ className: cn("m-0 list-none space-y-0 p-0", className),
5552
+ ...props,
5553
+ children: items.map((item, index) => /* @__PURE__ */ jsxs17(
5554
+ "li",
5555
+ {
5556
+ "data-slot": "reasoning-widget-list-item",
5557
+ "data-tone": item.tone,
5558
+ className: "group/item relative grid grid-cols-[auto_minmax(0,1fr)] items-start gap-3 rounded-[var(--sofya-radius-sm)] pr-2 transition-colors duration-sofya ease-sofya hover:bg-[color:var(--sofya-surface-hover)] focus-within:bg-[color:var(--sofya-surface-hover)]",
5559
+ children: [
5560
+ /* @__PURE__ */ jsx34(
5561
+ "span",
5562
+ {
5563
+ "aria-hidden": "true",
5564
+ "data-slot": "reasoning-widget-list-marker",
5565
+ className: "mt-2 size-2 rounded-full bg-[color:var(--sofya-text-soft)]"
5566
+ }
5567
+ ),
5568
+ /* @__PURE__ */ jsxs17("div", { className: "min-w-0", children: [
5569
+ /* @__PURE__ */ jsxs17("div", { className: "flex min-w-0 flex-wrap items-baseline gap-x-2 gap-y-1", children: [
5570
+ /* @__PURE__ */ jsx34("span", { className: "min-w-0 text-[color:var(--sofya-neutral-800)]", children: /* @__PURE__ */ jsx34(
5571
+ ReasoningEditableText,
5572
+ {
5573
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "item"} label`,
5574
+ className: "block text-inherit",
5575
+ editable,
5576
+ size: primaryTextSize,
5577
+ value: item.label,
5578
+ onCommit: (value) => {
5579
+ onItemEdit?.({
5580
+ field: "label",
5581
+ item,
5582
+ value,
5583
+ widgetId
5584
+ });
5585
+ }
5586
+ }
5587
+ ) }),
5588
+ hasRenderableNode(item.value) ? /* @__PURE__ */ jsx34(
5589
+ ReasoningEditableText,
5590
+ {
5591
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "item"} value`,
5592
+ className: "text-[color:var(--sofya-text-soft)]",
5593
+ editable,
5594
+ size: primaryTextSize,
5595
+ value: item.value,
5596
+ onCommit: (value) => {
5597
+ onItemEdit?.({
5598
+ field: "value",
5599
+ item,
5600
+ value,
5601
+ widgetId
5602
+ });
5603
+ }
5604
+ }
5605
+ ) : null,
5606
+ hasRenderableNode(item.status) ? /* @__PURE__ */ jsx34(
5607
+ ReasoningEditableText,
5608
+ {
5609
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "item"} status`,
5610
+ className: "text-[color:var(--sofya-text-subtle)]",
5611
+ editable,
5612
+ size: "caption",
5613
+ value: item.status,
5614
+ onCommit: (value) => {
5615
+ onItemEdit?.({
5616
+ field: "status",
5617
+ item,
5618
+ value,
5619
+ widgetId
5620
+ });
5621
+ }
5622
+ }
5623
+ ) : null
5624
+ ] }),
5625
+ hasRenderableNode(item.evidence) ? /* @__PURE__ */ jsx34(
5626
+ ReasoningEditableText,
5627
+ {
5628
+ as: "p",
5629
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "item"} evidence`,
5630
+ className: "mt-1 text-[color:var(--sofya-text-subtle)]",
5631
+ editable,
5632
+ multiline: true,
5633
+ size: supportingTextSize,
5634
+ value: item.evidence,
5635
+ onCommit: (value) => {
5636
+ onItemEdit?.({
5637
+ field: "evidence",
5638
+ item,
5639
+ value,
5640
+ widgetId
5641
+ });
5642
+ }
5643
+ }
5644
+ ) : null
5645
+ ] }),
5646
+ /* @__PURE__ */ jsx34(
5647
+ ReasoningWidgetActions,
5648
+ {
5649
+ actions: itemActions,
5650
+ className: "absolute right-1 top-1",
5651
+ onAction,
5652
+ reveal: "item-hover",
5653
+ target: item,
5654
+ widgetId
5655
+ }
5656
+ )
5657
+ ]
5658
+ },
5659
+ item.id ?? `reasoning-widget-item-${index}`
5660
+ ))
5661
+ }
5662
+ );
5663
+ });
5664
+ var ReasoningWidgetTable = React32.forwardRef(function ReasoningWidgetTable2({
5665
+ actions = [],
5666
+ className,
5667
+ columns,
5668
+ editable = false,
5669
+ emptyLabel = "No rows available.",
5670
+ onAction,
5671
+ onCellEdit,
5672
+ rows,
5673
+ showHeader = true,
5674
+ widgetId,
5675
+ ...props
5676
+ }, ref) {
5677
+ const itemActions = actions.filter(isItemAction);
5678
+ const hasActions = itemActions.length > 0;
5679
+ const density = React32.useContext(ReasoningWidgetDensityContext);
5680
+ const headerTextSize = density === "compact" ? "label-md" : "body-sm";
5681
+ const cellTextSize = density === "compact" ? "body-sm" : "body-sm";
5682
+ if (rows.length === 0) {
5683
+ return /* @__PURE__ */ jsx34("p", { className: "m-0 text-[color:var(--sofya-text-subtle)]", children: renderTextContent(emptyLabel, {
5684
+ as: "span",
5685
+ className: "block text-inherit",
5686
+ size: "body-md"
5687
+ }) });
5688
+ }
5689
+ return /* @__PURE__ */ jsx34(
5690
+ "div",
5691
+ {
5692
+ ref,
5693
+ "data-slot": "reasoning-widget-table",
5694
+ className: cn(
5695
+ "overflow-hidden rounded-[10px] border border-[color:var(--sofya-neutral-600)] bg-[color:var(--sofya-neutral-50)]",
5696
+ className
5697
+ ),
5698
+ ...props,
5699
+ children: /* @__PURE__ */ jsxs17("table", { className: "w-full border-collapse table-fixed", children: [
5700
+ showHeader ? /* @__PURE__ */ jsx34("thead", { children: /* @__PURE__ */ jsx34("tr", { className: "border-b border-[color:var(--sofya-neutral-600)]", children: columns.map((column, columnIndex) => /* @__PURE__ */ jsx34(
5701
+ "th",
5702
+ {
5703
+ className: cn(
5704
+ "align-middle text-[color:var(--sofya-text-subtle)]",
5705
+ density === "compact" ? "px-3 py-2" : "px-4 py-2",
5706
+ columnIndex > 0 && "border-l border-[color:var(--sofya-neutral-600)]",
5707
+ tableAlignClassName[column.align ?? "left"]
5708
+ ),
5709
+ style: column.width ? { width: column.width } : void 0,
5710
+ scope: "col",
5711
+ children: renderTextContent(column.header, {
5712
+ as: "span",
5713
+ className: "block truncate text-inherit",
5714
+ size: headerTextSize
5715
+ })
5716
+ },
5717
+ column.key
5718
+ )) }) }) : null,
5719
+ /* @__PURE__ */ jsx34("tbody", { children: rows.map((row, rowIndex) => /* @__PURE__ */ jsx34(
5720
+ "tr",
5721
+ {
5722
+ "data-tone": row.tone,
5723
+ className: cn(
5724
+ "group/item border-t border-[color:var(--sofya-neutral-600)] transition-colors duration-sofya ease-sofya first:border-t-0 hover:bg-[color:var(--sofya-surface-hover)] focus-within:bg-[color:var(--sofya-surface-hover)]",
5725
+ row.tone && toneSurfaceClassName[row.tone]
5726
+ ),
5727
+ children: columns.map((column, columnIndex) => {
5728
+ const isLastColumn = columnIndex === columns.length - 1;
5729
+ return /* @__PURE__ */ jsxs17(
5730
+ "td",
5731
+ {
5732
+ className: cn(
5733
+ "relative min-w-0 align-top",
5734
+ density === "compact" ? "px-3 py-2" : "px-4 py-2",
5735
+ column.variant === "value" ? "text-[color:var(--sofya-neutral-800)]" : "text-[color:var(--sofya-neutral-800)]",
5736
+ columnIndex > 0 && "border-l border-[color:var(--sofya-neutral-600)]",
5737
+ hasActions && isLastColumn && "pr-24",
5738
+ tableAlignClassName[column.align ?? "left"]
5739
+ ),
5740
+ children: [
5741
+ /* @__PURE__ */ jsx34(
5742
+ ReasoningEditableText,
5743
+ {
5744
+ ariaLabel: `Edit ${row.id ?? "row"} ${column.key}`,
5745
+ className: "block truncate text-inherit",
5746
+ editable,
5747
+ size: cellTextSize,
5748
+ value: row.cells[column.key] ?? null,
5749
+ weight: column.variant === "value" ? 600 : void 0,
5750
+ onCommit: (value) => {
5751
+ onCellEdit?.({
5752
+ columnKey: column.key,
5753
+ row,
5754
+ value,
5755
+ widgetId
5756
+ });
5757
+ }
5758
+ }
5759
+ ),
5760
+ hasActions && isLastColumn ? /* @__PURE__ */ jsx34(
5761
+ ReasoningWidgetActions,
5762
+ {
5763
+ actions: itemActions,
5764
+ className: "absolute right-2 top-1/2 -translate-y-1/2",
5765
+ onAction,
5766
+ reveal: "item-hover",
5767
+ target: row,
5768
+ widgetId
5769
+ }
5770
+ ) : null
5771
+ ]
5772
+ },
5773
+ column.key
5774
+ );
5775
+ })
5776
+ },
5777
+ row.id ?? `reasoning-widget-row-${rowIndex}`
5778
+ )) })
5779
+ ] })
5780
+ }
5781
+ );
5782
+ });
5783
+ var ReasoningVitalsWidget = React32.forwardRef(function ReasoningVitalsWidget2({
5784
+ actions = [],
5785
+ editable = false,
5786
+ emptyLabel = "No vitals extracted.",
5787
+ frame = "bordered",
5788
+ icon = "activity-heartbeat",
5789
+ items,
5790
+ onAction,
5791
+ onItemEdit,
5792
+ title = "Vitals",
5793
+ widgetId,
5794
+ ...props
5795
+ }, ref) {
5796
+ const itemActions = actions.filter(isItemAction);
5797
+ const hasActions = itemActions.length > 0;
5798
+ return /* @__PURE__ */ jsx34(
5799
+ ReasoningWidget,
5800
+ {
5801
+ ref,
5802
+ actions,
5803
+ empty: items.length === 0,
5804
+ emptyLabel,
5805
+ icon,
5806
+ onAction,
5807
+ title,
5808
+ widgetId,
5809
+ ...props,
5810
+ children: /* @__PURE__ */ jsx34(
5811
+ "div",
5812
+ {
5813
+ "data-slot": "reasoning-vitals-list",
5814
+ "data-frame": frame,
5815
+ className: clinicalDataFrameClassName[frame],
5816
+ children: items.map((item, index) => {
5817
+ const tone = item.tone ?? "muted";
5818
+ const unit = item.unit ?? (typeof item.metadata?.unit === "string" ? item.metadata.unit : void 0);
5819
+ const hasValue = hasRenderableNode(item.value);
5820
+ const value = hasValue ? item.value : item.label;
5821
+ const label = hasValue ? item.label : void 0;
5822
+ return /* @__PURE__ */ jsxs17(
5823
+ "div",
5824
+ {
5825
+ "data-slot": "reasoning-vital",
5826
+ "data-tone": tone,
5827
+ className: cn(
5828
+ "group/item relative grid min-w-0 grid-cols-[auto_minmax(0,1fr)_auto] items-stretch gap-0 border-t border-[color:var(--sofya-neutral-600)] transition-colors duration-sofya ease-sofya first:border-t-0 hover:bg-[color:var(--sofya-surface-hover)] focus-within:bg-[color:var(--sofya-surface-hover)]",
5829
+ clinicalToneSurfaceClassName[tone]
5830
+ ),
5831
+ children: [
5832
+ /* @__PURE__ */ jsx34(
5833
+ "span",
5834
+ {
5835
+ "aria-hidden": "true",
5836
+ "data-slot": "reasoning-vital-marker",
5837
+ className: cn(
5838
+ "my-5 ml-0 mr-5 w-1 rounded-r-full",
5839
+ clinicalToneMarkerClassName[tone]
5840
+ )
5841
+ }
5842
+ ),
5843
+ /* @__PURE__ */ jsxs17("div", { className: "min-w-0 py-5", children: [
5844
+ hasRenderableNode(label) ? /* @__PURE__ */ jsx34(
5845
+ ReasoningEditableText,
5846
+ {
5847
+ as: "p",
5848
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} label`,
5849
+ className: "text-[color:var(--sofya-neutral-900)]",
5850
+ editable,
5851
+ size: "title-sm",
5852
+ weight: 500,
5853
+ value: label,
5854
+ onCommit: (nextValue) => {
5855
+ onItemEdit?.({
5856
+ field: "label",
5857
+ item,
5858
+ value: nextValue,
5859
+ widgetId
5860
+ });
5861
+ }
5862
+ }
5863
+ ) : null,
5864
+ hasRenderableNode(item.referenceRange) ? /* @__PURE__ */ jsx34(
5865
+ ReasoningEditableText,
5866
+ {
5867
+ as: "p",
5868
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} reference range`,
5869
+ className: "mt-1 text-[color:var(--sofya-text-subtle)]",
5870
+ editable,
5871
+ size: "body-sm",
5872
+ value: item.referenceRange,
5873
+ onCommit: (nextValue) => {
5874
+ onItemEdit?.({
5875
+ field: "referenceRange",
5876
+ item,
5877
+ value: nextValue,
5878
+ widgetId
5879
+ });
5880
+ }
5881
+ }
5882
+ ) : null,
5883
+ hasRenderableNode(item.evidence) ? /* @__PURE__ */ jsx34(
5884
+ ReasoningEditableText,
5885
+ {
5886
+ as: "p",
5887
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} evidence`,
5888
+ className: "mt-1 text-[color:var(--sofya-text-subtle)]",
5889
+ editable,
5890
+ multiline: true,
5891
+ size: "body-sm",
5892
+ value: item.evidence,
5893
+ onCommit: (nextValue) => {
5894
+ onItemEdit?.({
5895
+ field: "evidence",
5896
+ item,
5897
+ value: nextValue,
5898
+ widgetId
5899
+ });
5900
+ }
5901
+ }
5902
+ ) : null,
5903
+ hasRenderableNode(item.observedAt) ? /* @__PURE__ */ jsx34(
5904
+ ReasoningEditableText,
5905
+ {
5906
+ as: "p",
5907
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} observed time`,
5908
+ className: "mt-1 text-[color:var(--sofya-text-subtle)]",
5909
+ editable,
5910
+ size: "body-sm",
5911
+ value: item.observedAt,
5912
+ onCommit: (nextValue) => {
5913
+ onItemEdit?.({
5914
+ field: "observedAt",
5915
+ item,
5916
+ value: nextValue,
5917
+ widgetId
5918
+ });
5919
+ }
5920
+ }
5921
+ ) : null
5922
+ ] }),
5923
+ /* @__PURE__ */ jsxs17(
5924
+ "div",
5925
+ {
5926
+ className: cn(
5927
+ "min-w-[7.5rem] py-4 pr-6 text-right",
5928
+ hasActions && "pr-24"
5929
+ ),
5930
+ children: [
5931
+ /* @__PURE__ */ jsxs17("div", { className: "flex min-w-0 items-baseline justify-end gap-1", children: [
5932
+ /* @__PURE__ */ jsx34(
5933
+ "span",
5934
+ {
5935
+ className: cn("min-w-0", clinicalToneValueClassName[tone]),
5936
+ children: /* @__PURE__ */ jsx34(
5937
+ ReasoningEditableText,
5938
+ {
5939
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} value`,
5940
+ className: "block text-inherit",
5941
+ editable,
5942
+ size: "title-md",
5943
+ value,
5944
+ weight: 600,
5945
+ onCommit: (nextValue) => {
5946
+ onItemEdit?.({
5947
+ field: hasValue ? "value" : "label",
5948
+ item,
5949
+ value: nextValue,
5950
+ widgetId
5951
+ });
5952
+ }
5953
+ }
5954
+ )
5955
+ }
5956
+ ),
5957
+ hasRenderableNode(unit) && hasValue ? /* @__PURE__ */ jsx34(
5958
+ ReasoningEditableText,
5959
+ {
5960
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} unit`,
5961
+ className: "text-[color:var(--sofya-text-subtle)]",
5962
+ editable,
5963
+ size: "body-sm",
5964
+ value: unit,
5965
+ onCommit: (nextValue) => {
5966
+ onItemEdit?.({
5967
+ field: "unit",
5968
+ item,
5969
+ value: nextValue,
5970
+ widgetId
5971
+ });
5972
+ }
5973
+ }
5974
+ ) : null
5975
+ ] }),
5976
+ hasRenderableNode(item.status) ? /* @__PURE__ */ jsx34(
5977
+ ReasoningEditableText,
5978
+ {
5979
+ as: "p",
5980
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "vital"} status`,
5981
+ className: cn(
5982
+ "mt-1 text-right",
5983
+ clinicalToneStatusClassName[tone]
5984
+ ),
5985
+ editable,
5986
+ size: "label-md",
5987
+ value: item.status,
5988
+ weight: 600,
5989
+ onCommit: (nextValue) => {
5990
+ onItemEdit?.({
5991
+ field: "status",
5992
+ item,
5993
+ value: nextValue,
5994
+ widgetId
5995
+ });
5996
+ }
5997
+ }
5998
+ ) : null
5999
+ ]
6000
+ }
6001
+ ),
6002
+ /* @__PURE__ */ jsx34(
6003
+ ReasoningWidgetActions,
6004
+ {
6005
+ actions: itemActions,
6006
+ className: "absolute right-2 top-1/2 -translate-y-1/2",
6007
+ onAction,
6008
+ reveal: "item-hover",
6009
+ target: item,
6010
+ widgetId
6011
+ }
6012
+ )
6013
+ ]
6014
+ },
6015
+ item.id ?? `reasoning-vital-${index}`
6016
+ );
6017
+ })
6018
+ }
6019
+ )
6020
+ }
6021
+ );
6022
+ });
6023
+ var ReasoningLabsWidget = React32.forwardRef(function ReasoningLabsWidget2({
6024
+ actions = [],
6025
+ columnLabels,
6026
+ editable = false,
6027
+ emptyLabel = "No labs extracted.",
6028
+ frame = "bordered",
6029
+ icon = "flask",
6030
+ items,
6031
+ onAction,
6032
+ onItemEdit,
6033
+ title = "Labs",
6034
+ widgetId,
6035
+ ...props
6036
+ }, ref) {
6037
+ const itemActions = actions.filter(isItemAction);
6038
+ const labColumns = [
6039
+ {
6040
+ key: "test",
6041
+ label: columnLabels?.test ?? "Test",
6042
+ width: "260px"
6043
+ },
6044
+ {
6045
+ key: "result",
6046
+ label: columnLabels?.result ?? "Result",
6047
+ width: "150px"
6048
+ },
6049
+ {
6050
+ key: "reference",
6051
+ label: columnLabels?.reference ?? "Reference",
6052
+ width: "150px"
6053
+ },
6054
+ {
6055
+ key: "flag",
6056
+ label: columnLabels?.flag ?? "Flag",
6057
+ width: "160px"
6058
+ }
6059
+ ];
6060
+ return /* @__PURE__ */ jsx34(
6061
+ ReasoningWidget,
6062
+ {
6063
+ ref,
6064
+ actions,
6065
+ empty: items.length === 0,
6066
+ emptyLabel,
6067
+ icon,
6068
+ onAction,
6069
+ title,
6070
+ widgetId,
6071
+ ...props,
6072
+ children: /* @__PURE__ */ jsx34(
6073
+ "div",
6074
+ {
6075
+ "data-slot": "reasoning-labs-table",
6076
+ "data-frame": frame,
6077
+ className: clinicalLabsFrameClassName[frame],
6078
+ children: /* @__PURE__ */ jsxs17("table", { className: "w-auto min-w-[720px] border-collapse table-fixed", children: [
6079
+ /* @__PURE__ */ jsx34("thead", { children: /* @__PURE__ */ jsxs17("tr", { className: clinicalDataHeaderClassName[frame], children: [
6080
+ /* @__PURE__ */ jsx34("th", { className: "w-7 px-4 py-3", scope: "col", children: /* @__PURE__ */ jsx34("span", { className: "sr-only", children: columnLabels?.tone ?? "Tone" }) }),
6081
+ labColumns.map((column) => /* @__PURE__ */ jsx34(
6082
+ "th",
6083
+ {
6084
+ className: "px-4 py-3 text-left align-middle text-[color:var(--sofya-text-subtle)]",
6085
+ scope: "col",
6086
+ style: { width: column.width },
6087
+ children: renderTextContent(column.label, {
6088
+ as: "span",
6089
+ className: "block truncate text-inherit",
6090
+ size: "clinical-section-title"
6091
+ })
6092
+ },
6093
+ column.key
6094
+ ))
6095
+ ] }) }),
6096
+ /* @__PURE__ */ jsx34("tbody", { children: items.map((item, index) => {
6097
+ const tone = item.tone ?? "muted";
6098
+ const unit = item.unit ?? (typeof item.metadata?.unit === "string" ? item.metadata.unit : void 0);
6099
+ const interpretation = item.interpretation ?? item.status;
6100
+ return /* @__PURE__ */ jsxs17(
6101
+ "tr",
6102
+ {
6103
+ "data-slot": "reasoning-lab",
6104
+ "data-tone": tone,
6105
+ className: cn(
6106
+ "group/item border-t border-[color:var(--sofya-neutral-600)] transition-colors duration-sofya ease-sofya first:border-t-0 hover:bg-[color:var(--sofya-surface-hover)] focus-within:bg-[color:var(--sofya-surface-hover)]",
6107
+ clinicalToneSurfaceClassName[tone]
6108
+ ),
6109
+ children: [
6110
+ /* @__PURE__ */ jsx34("td", { className: "px-0 py-4 align-top", children: /* @__PURE__ */ jsx34(
6111
+ "span",
6112
+ {
6113
+ "aria-hidden": "true",
6114
+ "data-slot": "reasoning-lab-marker",
6115
+ className: cn(
6116
+ "mt-1 block h-12 w-1 rounded-r-full",
6117
+ clinicalToneMarkerClassName[tone]
6118
+ )
6119
+ }
6120
+ ) }),
6121
+ /* @__PURE__ */ jsxs17("td", { className: "min-w-0 px-4 py-4 align-top text-[color:var(--sofya-neutral-900)]", children: [
6122
+ /* @__PURE__ */ jsx34(
6123
+ ReasoningEditableText,
6124
+ {
6125
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "lab"} label`,
6126
+ className: "block text-inherit",
6127
+ editable,
6128
+ size: "title-sm",
6129
+ value: item.label,
6130
+ weight: 500,
6131
+ onCommit: (nextValue) => {
6132
+ onItemEdit?.({
6133
+ field: "label",
6134
+ item,
6135
+ value: nextValue,
6136
+ widgetId
6137
+ });
6138
+ }
6139
+ }
6140
+ ),
6141
+ hasRenderableNode(item.evidence) ? /* @__PURE__ */ jsx34(
6142
+ ReasoningEditableText,
6143
+ {
6144
+ as: "p",
6145
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "lab"} evidence`,
6146
+ className: "mt-1 text-[color:var(--sofya-text-subtle)]",
6147
+ editable,
6148
+ multiline: true,
6149
+ size: "body-sm",
6150
+ value: item.evidence,
6151
+ onCommit: (nextValue) => {
6152
+ onItemEdit?.({
6153
+ field: "evidence",
6154
+ item,
6155
+ value: nextValue,
6156
+ widgetId
6157
+ });
6158
+ }
6159
+ }
6160
+ ) : null
6161
+ ] }),
6162
+ /* @__PURE__ */ jsx34("td", { className: "min-w-0 px-4 py-4 align-top", children: /* @__PURE__ */ jsxs17("div", { className: "flex min-w-0 flex-col items-start", children: [
6163
+ /* @__PURE__ */ jsx34(
6164
+ "span",
6165
+ {
6166
+ className: cn(
6167
+ "min-w-0",
6168
+ clinicalToneValueClassName[tone]
6169
+ ),
6170
+ children: /* @__PURE__ */ jsx34(
6171
+ ReasoningEditableText,
6172
+ {
6173
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "lab"} value`,
6174
+ className: "block text-inherit",
6175
+ editable,
6176
+ size: "title-sm",
6177
+ value: item.value ?? null,
6178
+ weight: 600,
6179
+ onCommit: (nextValue) => {
6180
+ onItemEdit?.({
6181
+ field: "value",
6182
+ item,
6183
+ value: nextValue,
6184
+ widgetId
6185
+ });
6186
+ }
6187
+ }
6188
+ )
6189
+ }
6190
+ ),
6191
+ hasRenderableNode(unit) ? /* @__PURE__ */ jsx34(
6192
+ ReasoningEditableText,
6193
+ {
6194
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "lab"} unit`,
6195
+ className: "text-[color:var(--sofya-text-subtle)]",
6196
+ editable,
6197
+ size: "body-sm",
6198
+ value: unit,
6199
+ onCommit: (nextValue) => {
6200
+ onItemEdit?.({
6201
+ field: "unit",
6202
+ item,
6203
+ value: nextValue,
6204
+ widgetId
6205
+ });
6206
+ }
6207
+ }
6208
+ ) : null
6209
+ ] }) }),
6210
+ /* @__PURE__ */ jsx34("td", { className: "min-w-0 px-4 py-4 align-top text-[color:var(--sofya-text-soft)]", children: hasRenderableNode(item.referenceRange) ? /* @__PURE__ */ jsx34(
6211
+ ReasoningEditableText,
6212
+ {
6213
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "lab"} reference range`,
6214
+ className: "block truncate text-inherit",
6215
+ editable,
6216
+ size: "body-sm",
6217
+ value: item.referenceRange,
6218
+ onCommit: (nextValue) => {
6219
+ onItemEdit?.({
6220
+ field: "referenceRange",
6221
+ item,
6222
+ value: nextValue,
6223
+ widgetId
6224
+ });
6225
+ }
6226
+ }
6227
+ ) : null }),
6228
+ /* @__PURE__ */ jsxs17("td", { className: "relative min-w-0 px-4 py-4 align-top", children: [
6229
+ hasRenderableNode(interpretation) ? /* @__PURE__ */ jsx34(
6230
+ ReasoningEditableText,
6231
+ {
6232
+ ariaLabel: `Edit ${getTargetLabel(item) ?? "lab"} interpretation`,
6233
+ className: cn(
6234
+ "inline-flex rounded-full px-3 py-1",
6235
+ clinicalToneBadgeClassName[tone]
6236
+ ),
6237
+ editable,
6238
+ multiline: true,
6239
+ size: "label-md",
6240
+ value: interpretation,
6241
+ weight: tone === "muted" ? void 0 : 600,
6242
+ onCommit: (nextValue) => {
6243
+ onItemEdit?.({
6244
+ field: "status",
6245
+ item,
6246
+ value: nextValue,
6247
+ widgetId
6248
+ });
6249
+ }
6250
+ }
6251
+ ) : null,
6252
+ /* @__PURE__ */ jsx34(
6253
+ ReasoningWidgetActions,
6254
+ {
6255
+ actions: itemActions,
6256
+ className: "absolute right-2 top-1/2 -translate-y-1/2",
6257
+ onAction,
6258
+ reveal: "item-hover",
6259
+ target: item,
6260
+ widgetId
6261
+ }
6262
+ )
6263
+ ] })
6264
+ ]
6265
+ },
6266
+ item.id ?? `reasoning-lab-${index}`
6267
+ );
6268
+ }) })
6269
+ ] })
6270
+ }
6271
+ )
6272
+ }
6273
+ );
6274
+ });
6275
+ var ReasoningSummaryWidget = React32.forwardRef(function ReasoningSummaryWidget2({
6276
+ actions,
6277
+ clinicalImpression,
6278
+ description,
6279
+ editable = false,
6280
+ findings = [],
6281
+ eyebrow = "Summary",
6282
+ icon = "stethoscope",
6283
+ onAction,
6284
+ onItemEdit,
6285
+ onSummaryEdit,
6286
+ title,
6287
+ widgetId,
6288
+ ...props
6289
+ }, ref) {
6290
+ return /* @__PURE__ */ jsxs17(
6291
+ ReasoningWidget,
6292
+ {
6293
+ ref,
6294
+ actions,
6295
+ description,
6296
+ eyebrow,
6297
+ icon,
6298
+ onAction,
6299
+ title,
6300
+ widgetId,
6301
+ ...props,
6302
+ children: [
6303
+ hasRenderableNode(clinicalImpression) ? /* @__PURE__ */ jsx34(
6304
+ ReasoningEditableText,
6305
+ {
6306
+ as: "p",
6307
+ ariaLabel: "Edit clinical impression",
6308
+ className: "m-0 text-[color:var(--sofya-neutral-800)]",
6309
+ editable,
6310
+ multiline: true,
6311
+ size: "clinical-body",
6312
+ value: clinicalImpression,
6313
+ onCommit: (value) => {
6314
+ onSummaryEdit?.({
6315
+ field: "clinicalImpression",
6316
+ value,
6317
+ widgetId
6318
+ });
6319
+ }
6320
+ }
6321
+ ) : null,
6322
+ findings.length > 0 ? /* @__PURE__ */ jsx34(
6323
+ ReasoningWidgetList,
6324
+ {
6325
+ actions,
6326
+ className: hasRenderableNode(clinicalImpression) ? "mt-3" : void 0,
6327
+ editable,
6328
+ items: findings,
6329
+ onAction,
6330
+ onItemEdit,
6331
+ widgetId
6332
+ }
6333
+ ) : null
6334
+ ]
6335
+ }
6336
+ );
6337
+ });
6338
+ function ReasoningWidgetRenderer({
6339
+ editable = false,
6340
+ onAction,
6341
+ onCellEdit,
6342
+ onItemEdit,
6343
+ onSummaryEdit,
6344
+ widget,
6345
+ ...props
6346
+ }) {
6347
+ const descriptorKind = getDescriptorKind(widget);
6348
+ const description = getDescriptionFromDescriptor(widget);
6349
+ const emptyLabel = getEmptyLabelFromDescriptor(widget);
6350
+ const frame = getFrameFromDescriptor(widget);
6351
+ const items = getItemsFromDescriptor(widget);
6352
+ const actions = widget.actions ?? [];
6353
+ const icon = getIconFromDescriptor(widget);
6354
+ if (descriptorKind.includes("summary") || hasRenderableNode(widget.data?.impression)) {
6355
+ return /* @__PURE__ */ jsx34(
6356
+ ReasoningSummaryWidget,
6357
+ {
6358
+ actions,
6359
+ clinicalImpression: widget.data?.impression,
6360
+ description,
6361
+ editable,
6362
+ findings: items,
6363
+ icon,
6364
+ onAction,
6365
+ onItemEdit,
6366
+ onSummaryEdit,
6367
+ sectionDivider: widget.sectionDivider,
6368
+ title: widget.title,
6369
+ widgetId: widget.id,
6370
+ ...props
6371
+ }
6372
+ );
6373
+ }
6374
+ if (descriptorKind.includes("vitals")) {
6375
+ return /* @__PURE__ */ jsx34(
6376
+ ReasoningVitalsWidget,
6377
+ {
6378
+ actions,
6379
+ description,
6380
+ editable,
6381
+ emptyLabel,
6382
+ frame,
6383
+ icon,
6384
+ items,
6385
+ onAction,
6386
+ onItemEdit,
6387
+ sectionDivider: widget.sectionDivider,
6388
+ title: widget.title,
6389
+ widgetId: widget.id,
6390
+ ...props
6391
+ }
6392
+ );
6393
+ }
6394
+ if (descriptorKind.includes("lab") && items.length > 0) {
6395
+ return /* @__PURE__ */ jsx34(
6396
+ ReasoningLabsWidget,
6397
+ {
6398
+ actions,
6399
+ columnLabels: widget.data?.labColumnLabels,
6400
+ description,
6401
+ editable,
6402
+ emptyLabel,
6403
+ frame,
6404
+ icon,
6405
+ items,
6406
+ onAction,
6407
+ onItemEdit,
6408
+ sectionDivider: widget.sectionDivider,
6409
+ title: widget.title,
6410
+ widgetId: widget.id,
6411
+ ...props
6412
+ }
6413
+ );
6414
+ }
6415
+ if (widget.data?.tableColumns && widget.data.rows) {
6416
+ return /* @__PURE__ */ jsx34(
6417
+ ReasoningWidget,
6418
+ {
6419
+ actions,
6420
+ description,
6421
+ empty: widget.data.rows.length === 0,
6422
+ emptyLabel,
6423
+ icon,
6424
+ onAction,
6425
+ sectionDivider: widget.sectionDivider,
6426
+ title: widget.title,
6427
+ widgetId: widget.id,
6428
+ ...props,
6429
+ children: /* @__PURE__ */ jsx34(
6430
+ ReasoningWidgetTable,
6431
+ {
6432
+ actions,
6433
+ columns: widget.data.tableColumns,
6434
+ editable,
6435
+ emptyLabel,
6436
+ onAction,
6437
+ onCellEdit,
6438
+ rows: widget.data.rows,
6439
+ widgetId: widget.id
6440
+ }
6441
+ )
6442
+ }
6443
+ );
6444
+ }
6445
+ return /* @__PURE__ */ jsx34(
6446
+ ReasoningWidget,
6447
+ {
6448
+ actions,
6449
+ description,
6450
+ empty: items.length === 0,
6451
+ emptyLabel,
6452
+ icon,
6453
+ onAction,
6454
+ sectionDivider: widget.sectionDivider,
6455
+ title: widget.title,
6456
+ widgetId: widget.id,
6457
+ ...props,
6458
+ children: /* @__PURE__ */ jsx34(
6459
+ ReasoningWidgetList,
6460
+ {
6461
+ actions,
6462
+ editable,
6463
+ emptyLabel,
6464
+ items,
6465
+ onAction,
6466
+ onItemEdit,
6467
+ widgetId: widget.id
6468
+ }
6469
+ )
6470
+ }
6471
+ );
6472
+ }
6473
+ ReasoningWidgetActionButton.displayName = "ReasoningWidgetActionButton";
6474
+ ReasoningWidgetActions.displayName = "ReasoningWidgetActions";
6475
+ ReasoningWidget.displayName = "ReasoningWidget";
6476
+ ReasoningWidgetList.displayName = "ReasoningWidgetList";
6477
+ ReasoningWidgetTable.displayName = "ReasoningWidgetTable";
6478
+ ReasoningVitalsWidget.displayName = "ReasoningVitalsWidget";
6479
+ ReasoningLabsWidget.displayName = "ReasoningLabsWidget";
6480
+ ReasoningSummaryWidget.displayName = "ReasoningSummaryWidget";
6481
+
6482
+ // src/components/right-rail-action.tsx
6483
+ import * as React33 from "react";
6484
+ import { jsx as jsx35 } from "react/jsx-runtime";
6485
+ var RightRailAction = React33.forwardRef(
6486
+ ({ active = false, className, icon, ...props }, ref) => /* @__PURE__ */ jsx35(
5002
6487
  IconButton,
5003
6488
  {
5004
6489
  ref,
@@ -5017,12 +6502,12 @@ var RightRailAction = React32.forwardRef(
5017
6502
  RightRailAction.displayName = "RightRailAction";
5018
6503
 
5019
6504
  // src/components/scroll-area.tsx
5020
- import * as React33 from "react";
6505
+ import * as React34 from "react";
5021
6506
  import * as ScrollAreaPrimitive from "@radix-ui/react-scroll-area";
5022
- import { jsx as jsx35 } from "react/jsx-runtime";
6507
+ import { jsx as jsx36 } from "react/jsx-runtime";
5023
6508
  var scrollAreaOrientationOptions = ["horizontal", "vertical"];
5024
- var ScrollArea = React33.forwardRef(function ScrollArea2({ className, ...props }, ref) {
5025
- return /* @__PURE__ */ jsx35(
6509
+ var ScrollArea = React34.forwardRef(function ScrollArea2({ className, ...props }, ref) {
6510
+ return /* @__PURE__ */ jsx36(
5026
6511
  ScrollAreaPrimitive.Root,
5027
6512
  {
5028
6513
  ref,
@@ -5033,8 +6518,8 @@ var ScrollArea = React33.forwardRef(function ScrollArea2({ className, ...props }
5033
6518
  );
5034
6519
  });
5035
6520
  ScrollArea.displayName = ScrollAreaPrimitive.Root.displayName;
5036
- var ScrollAreaViewport = React33.forwardRef(function ScrollAreaViewport2({ className, ...props }, ref) {
5037
- return /* @__PURE__ */ jsx35(
6521
+ var ScrollAreaViewport = React34.forwardRef(function ScrollAreaViewport2({ className, ...props }, ref) {
6522
+ return /* @__PURE__ */ jsx36(
5038
6523
  ScrollAreaPrimitive.Viewport,
5039
6524
  {
5040
6525
  ref,
@@ -5048,8 +6533,8 @@ var ScrollAreaViewport = React33.forwardRef(function ScrollAreaViewport2({ class
5048
6533
  );
5049
6534
  });
5050
6535
  ScrollAreaViewport.displayName = ScrollAreaPrimitive.Viewport.displayName;
5051
- var ScrollAreaScrollbar = React33.forwardRef(function ScrollAreaScrollbar2({ className, orientation = "vertical", thumbClassName, ...props }, ref) {
5052
- return /* @__PURE__ */ jsx35(
6536
+ var ScrollAreaScrollbar = React34.forwardRef(function ScrollAreaScrollbar2({ className, orientation = "vertical", thumbClassName, ...props }, ref) {
6537
+ return /* @__PURE__ */ jsx36(
5053
6538
  ScrollAreaPrimitive.Scrollbar,
5054
6539
  {
5055
6540
  ref,
@@ -5060,7 +6545,7 @@ var ScrollAreaScrollbar = React33.forwardRef(function ScrollAreaScrollbar2({ cla
5060
6545
  className
5061
6546
  ),
5062
6547
  ...props,
5063
- children: /* @__PURE__ */ jsx35(
6548
+ children: /* @__PURE__ */ jsx36(
5064
6549
  ScrollAreaPrimitive.Thumb,
5065
6550
  {
5066
6551
  "data-slot": "scroll-area-thumb",
@@ -5074,8 +6559,8 @@ var ScrollAreaScrollbar = React33.forwardRef(function ScrollAreaScrollbar2({ cla
5074
6559
  );
5075
6560
  });
5076
6561
  ScrollAreaScrollbar.displayName = ScrollAreaPrimitive.Scrollbar.displayName;
5077
- var ScrollAreaCorner = React33.forwardRef(function ScrollAreaCorner2({ className, ...props }, ref) {
5078
- return /* @__PURE__ */ jsx35(
6562
+ var ScrollAreaCorner = React34.forwardRef(function ScrollAreaCorner2({ className, ...props }, ref) {
6563
+ return /* @__PURE__ */ jsx36(
5079
6564
  ScrollAreaPrimitive.Corner,
5080
6565
  {
5081
6566
  ref,
@@ -5088,19 +6573,19 @@ var ScrollAreaCorner = React33.forwardRef(function ScrollAreaCorner2({ className
5088
6573
  ScrollAreaCorner.displayName = ScrollAreaPrimitive.Corner.displayName;
5089
6574
 
5090
6575
  // src/components/select.tsx
5091
- import * as React34 from "react";
6576
+ import * as React35 from "react";
5092
6577
  import * as SelectPrimitive from "@radix-ui/react-select";
5093
6578
 
5094
6579
  // src/lib/form-control-classes.ts
5095
6580
  var formControlBaseClasses = "flex w-full items-center justify-between gap-4 rounded-[10px] border border-[color:var(--sofya-border-strong)] bg-card px-4 text-left [font-family:var(--sofya-text-body-font-family)] text-[length:var(--sofya-text-body-font-size)] [font-weight:var(--sofya-text-body-font-weight)] leading-[var(--sofya-text-body-line-height)] tracking-[var(--sofya-text-body-letter-spacing)] text-[color:var(--sofya-text-default)] shadow-none transition-[border-color,box-shadow,background-color,color] duration-sofya ease-sofya hover:border-[color:var(--sofya-border-hover)] focus:outline-none focus:ring-2 focus:ring-[color:var(--sofya-focus-ring-soft)] focus:ring-offset-0 active:border-transparent active:ring-2 active:ring-[color:var(--sofya-focus-ring-soft)] disabled:cursor-not-allowed disabled:bg-muted disabled:opacity-50 aria-invalid:border-destructive aria-invalid:focus:ring-destructive/20 data-[placeholder]:text-[color:var(--sofya-text-placeholder)]";
5096
6581
 
5097
6582
  // src/components/select.tsx
5098
- import { jsx as jsx36, jsxs as jsxs17 } from "react/jsx-runtime";
6583
+ import { jsx as jsx37, jsxs as jsxs18 } from "react/jsx-runtime";
5099
6584
  var selectSizeOptions = ["default", "sm"];
5100
6585
  var Select = SelectPrimitive.Root;
5101
6586
  var SelectGroup = SelectPrimitive.Group;
5102
- var SelectValue = React34.forwardRef(function SelectValue2({ className, ...props }, ref) {
5103
- return /* @__PURE__ */ jsx36(
6587
+ var SelectValue = React35.forwardRef(function SelectValue2({ className, ...props }, ref) {
6588
+ return /* @__PURE__ */ jsx37(
5104
6589
  Text,
5105
6590
  {
5106
6591
  ref,
@@ -5109,13 +6594,13 @@ var SelectValue = React34.forwardRef(function SelectValue2({ className, ...props
5109
6594
  className: cn("block truncate text-inherit", className),
5110
6595
  size: "tiny",
5111
6596
  style: inheritedTypographyStyle,
5112
- children: /* @__PURE__ */ jsx36(SelectPrimitive.Value, { className: "block truncate", ...props })
6597
+ children: /* @__PURE__ */ jsx37(SelectPrimitive.Value, { className: "block truncate", ...props })
5113
6598
  }
5114
6599
  );
5115
6600
  });
5116
6601
  SelectValue.displayName = SelectPrimitive.Value.displayName;
5117
- var SelectTrigger = React34.forwardRef(function SelectTrigger2({ className, children, size = "default", ...props }, ref) {
5118
- return /* @__PURE__ */ jsxs17(
6602
+ var SelectTrigger = React35.forwardRef(function SelectTrigger2({ className, children, size = "default", ...props }, ref) {
6603
+ return /* @__PURE__ */ jsxs18(
5119
6604
  SelectPrimitive.Trigger,
5120
6605
  {
5121
6606
  ref,
@@ -5129,7 +6614,7 @@ var SelectTrigger = React34.forwardRef(function SelectTrigger2({ className, chil
5129
6614
  ...props,
5130
6615
  children: [
5131
6616
  children,
5132
- /* @__PURE__ */ jsx36(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx36(
6617
+ /* @__PURE__ */ jsx37(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx37(
5133
6618
  Icon,
5134
6619
  {
5135
6620
  name: "caret-down",
@@ -5142,8 +6627,8 @@ var SelectTrigger = React34.forwardRef(function SelectTrigger2({ className, chil
5142
6627
  );
5143
6628
  });
5144
6629
  SelectTrigger.displayName = SelectPrimitive.Trigger.displayName;
5145
- var SelectScrollUpButton = React34.forwardRef(function SelectScrollUpButton2({ className, ...props }, ref) {
5146
- return /* @__PURE__ */ jsx36(
6630
+ var SelectScrollUpButton = React35.forwardRef(function SelectScrollUpButton2({ className, ...props }, ref) {
6631
+ return /* @__PURE__ */ jsx37(
5147
6632
  SelectPrimitive.ScrollUpButton,
5148
6633
  {
5149
6634
  ref,
@@ -5153,13 +6638,13 @@ var SelectScrollUpButton = React34.forwardRef(function SelectScrollUpButton2({ c
5153
6638
  className
5154
6639
  ),
5155
6640
  ...props,
5156
- children: /* @__PURE__ */ jsx36(Icon, { name: "caret-up", size: 12 })
6641
+ children: /* @__PURE__ */ jsx37(Icon, { name: "caret-up", size: 12 })
5157
6642
  }
5158
6643
  );
5159
6644
  });
5160
6645
  SelectScrollUpButton.displayName = SelectPrimitive.ScrollUpButton.displayName;
5161
- var SelectScrollDownButton = React34.forwardRef(function SelectScrollDownButton2({ className, ...props }, ref) {
5162
- return /* @__PURE__ */ jsx36(
6646
+ var SelectScrollDownButton = React35.forwardRef(function SelectScrollDownButton2({ className, ...props }, ref) {
6647
+ return /* @__PURE__ */ jsx37(
5163
6648
  SelectPrimitive.ScrollDownButton,
5164
6649
  {
5165
6650
  ref,
@@ -5169,13 +6654,13 @@ var SelectScrollDownButton = React34.forwardRef(function SelectScrollDownButton2
5169
6654
  className
5170
6655
  ),
5171
6656
  ...props,
5172
- children: /* @__PURE__ */ jsx36(Icon, { name: "caret-down", size: 12 })
6657
+ children: /* @__PURE__ */ jsx37(Icon, { name: "caret-down", size: 12 })
5173
6658
  }
5174
6659
  );
5175
6660
  });
5176
6661
  SelectScrollDownButton.displayName = SelectPrimitive.ScrollDownButton.displayName;
5177
- var SelectContent = React34.forwardRef(function SelectContent2({ className, children, position = "popper", ...props }, ref) {
5178
- return /* @__PURE__ */ jsx36(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs17(
6662
+ var SelectContent = React35.forwardRef(function SelectContent2({ className, children, position = "popper", ...props }, ref) {
6663
+ return /* @__PURE__ */ jsx37(SelectPrimitive.Portal, { children: /* @__PURE__ */ jsxs18(
5179
6664
  SelectPrimitive.Content,
5180
6665
  {
5181
6666
  ref,
@@ -5188,8 +6673,8 @@ var SelectContent = React34.forwardRef(function SelectContent2({ className, chil
5188
6673
  ),
5189
6674
  ...props,
5190
6675
  children: [
5191
- /* @__PURE__ */ jsx36(SelectScrollUpButton, {}),
5192
- /* @__PURE__ */ jsx36(
6676
+ /* @__PURE__ */ jsx37(SelectScrollUpButton, {}),
6677
+ /* @__PURE__ */ jsx37(
5193
6678
  SelectPrimitive.Viewport,
5194
6679
  {
5195
6680
  "data-slot": "select-viewport",
@@ -5197,14 +6682,14 @@ var SelectContent = React34.forwardRef(function SelectContent2({ className, chil
5197
6682
  children
5198
6683
  }
5199
6684
  ),
5200
- /* @__PURE__ */ jsx36(SelectScrollDownButton, {})
6685
+ /* @__PURE__ */ jsx37(SelectScrollDownButton, {})
5201
6686
  ]
5202
6687
  }
5203
6688
  ) });
5204
6689
  });
5205
6690
  SelectContent.displayName = SelectPrimitive.Content.displayName;
5206
- var SelectLabel = React34.forwardRef(function SelectLabel2({ className, ...props }, ref) {
5207
- return /* @__PURE__ */ jsx36(
6691
+ var SelectLabel = React35.forwardRef(function SelectLabel2({ className, ...props }, ref) {
6692
+ return /* @__PURE__ */ jsx37(
5208
6693
  SelectPrimitive.Label,
5209
6694
  {
5210
6695
  ref,
@@ -5226,8 +6711,8 @@ var SelectLabel = React34.forwardRef(function SelectLabel2({ className, ...props
5226
6711
  );
5227
6712
  });
5228
6713
  SelectLabel.displayName = SelectPrimitive.Label.displayName;
5229
- var SelectItem = React34.forwardRef(function SelectItem2({ className, children, ...props }, ref) {
5230
- return /* @__PURE__ */ jsxs17(
6714
+ var SelectItem = React35.forwardRef(function SelectItem2({ className, children, ...props }, ref) {
6715
+ return /* @__PURE__ */ jsxs18(
5231
6716
  SelectPrimitive.Item,
5232
6717
  {
5233
6718
  ref,
@@ -5238,20 +6723,20 @@ var SelectItem = React34.forwardRef(function SelectItem2({ className, children,
5238
6723
  ),
5239
6724
  ...props,
5240
6725
  children: [
5241
- /* @__PURE__ */ jsx36(SelectPrimitive.ItemText, { className: "truncate", children: renderTextContent(children, {
6726
+ /* @__PURE__ */ jsx37(SelectPrimitive.ItemText, { className: "truncate", children: renderTextContent(children, {
5242
6727
  as: "span",
5243
6728
  className: "block truncate text-[color:var(--sofya-text-default)]",
5244
6729
  size: "tiny",
5245
6730
  style: inheritedTypographyStyle
5246
6731
  }) }),
5247
- /* @__PURE__ */ jsx36(SelectPrimitive.ItemIndicator, { asChild: true, children: /* @__PURE__ */ jsx36("span", { className: "absolute right-4 inline-flex h-4 w-4 items-center justify-center text-primary", children: /* @__PURE__ */ jsx36(Icon, { name: "check", size: 14 }) }) })
6732
+ /* @__PURE__ */ jsx37(SelectPrimitive.ItemIndicator, { asChild: true, children: /* @__PURE__ */ jsx37("span", { className: "absolute right-4 inline-flex h-4 w-4 items-center justify-center text-primary", children: /* @__PURE__ */ jsx37(Icon, { name: "check", size: 14 }) }) })
5248
6733
  ]
5249
6734
  }
5250
6735
  );
5251
6736
  });
5252
6737
  SelectItem.displayName = SelectPrimitive.Item.displayName;
5253
- var SelectSeparator = React34.forwardRef(function SelectSeparator2({ className, ...props }, ref) {
5254
- return /* @__PURE__ */ jsx36(
6738
+ var SelectSeparator = React35.forwardRef(function SelectSeparator2({ className, ...props }, ref) {
6739
+ return /* @__PURE__ */ jsx37(
5255
6740
  SelectPrimitive.Separator,
5256
6741
  {
5257
6742
  ref,
@@ -5264,11 +6749,11 @@ var SelectSeparator = React34.forwardRef(function SelectSeparator2({ className,
5264
6749
  SelectSeparator.displayName = SelectPrimitive.Separator.displayName;
5265
6750
 
5266
6751
  // src/components/separator.tsx
5267
- import * as React35 from "react";
6752
+ import * as React36 from "react";
5268
6753
  import * as SeparatorPrimitive from "@radix-ui/react-separator";
5269
- import { jsx as jsx37 } from "react/jsx-runtime";
5270
- var Separator2 = React35.forwardRef(function Separator3({ className, decorative = true, orientation = "horizontal", ...props }, ref) {
5271
- return /* @__PURE__ */ jsx37(
6754
+ import { jsx as jsx38 } from "react/jsx-runtime";
6755
+ var Separator2 = React36.forwardRef(function Separator3({ className, decorative = true, orientation = "horizontal", ...props }, ref) {
6756
+ return /* @__PURE__ */ jsx38(
5272
6757
  SeparatorPrimitive.Root,
5273
6758
  {
5274
6759
  ref,
@@ -5287,8 +6772,8 @@ var Separator2 = React35.forwardRef(function Separator3({ className, decorative
5287
6772
  Separator2.displayName = SeparatorPrimitive.Root.displayName;
5288
6773
 
5289
6774
  // src/components/sidebar-nav-item.tsx
5290
- import * as React36 from "react";
5291
- import { jsx as jsx38, jsxs as jsxs18 } from "react/jsx-runtime";
6775
+ import * as React37 from "react";
6776
+ import { jsx as jsx39, jsxs as jsxs19 } from "react/jsx-runtime";
5292
6777
  var sidebarNavItemAppearanceClassNames = {
5293
6778
  settings: "rounded-[var(--sofya-radius-md)] py-[var(--sofya-space-2)] pl-[var(--sofya-space-3)] pr-[var(--sofya-space-3)] text-[color:var(--sofya-text-soft)] hover:bg-[color:var(--sofya-surface-hover)] hover:text-[color:var(--sofya-text-default)] data-[active=true]:bg-[color:var(--sofya-surface-selected)] data-[active=true]:text-[color:var(--sofya-text-default)] data-[active=true]:hover:bg-[color:var(--sofya-surface-selected-strong)] data-[disabled=true]:text-[color:var(--sofya-text-subtle)] data-[disabled=true]:hover:bg-transparent",
5294
6779
  workspace: "rounded-[var(--sofya-radius-sm)] bg-transparent px-0 py-0 text-[color:var(--sofya-text-subtle)] hover:bg-transparent hover:text-[color:var(--sofya-text-default)] data-[active=true]:bg-transparent data-[active=true]:text-primary data-[active=true]:hover:bg-transparent data-[active=true]:hover:text-primary data-[disabled=true]:text-[color:var(--sofya-text-subtle)] data-[disabled=true]:hover:bg-transparent"
@@ -5301,10 +6786,10 @@ var sidebarNavItemTextSize = {
5301
6786
  settings: "sidebar-title",
5302
6787
  workspace: "sidebar-title-regular"
5303
6788
  };
5304
- var SidebarNav = React36.forwardRef(
6789
+ var SidebarNav = React37.forwardRef(
5305
6790
  ({ as, className, ...props }, ref) => {
5306
6791
  const Comp = as ?? "nav";
5307
- return /* @__PURE__ */ jsx38(
6792
+ return /* @__PURE__ */ jsx39(
5308
6793
  Comp,
5309
6794
  {
5310
6795
  ref,
@@ -5316,8 +6801,8 @@ var SidebarNav = React36.forwardRef(
5316
6801
  }
5317
6802
  );
5318
6803
  SidebarNav.displayName = "SidebarNav";
5319
- var SidebarNavSection = React36.forwardRef(
5320
- ({ className, ...props }, ref) => /* @__PURE__ */ jsx38(
6804
+ var SidebarNavSection = React37.forwardRef(
6805
+ ({ className, ...props }, ref) => /* @__PURE__ */ jsx39(
5321
6806
  "div",
5322
6807
  {
5323
6808
  ref,
@@ -5328,10 +6813,10 @@ var SidebarNavSection = React36.forwardRef(
5328
6813
  )
5329
6814
  );
5330
6815
  SidebarNavSection.displayName = "SidebarNavSection";
5331
- var SidebarNavSectionLabel = React36.forwardRef(
6816
+ var SidebarNavSectionLabel = React37.forwardRef(
5332
6817
  ({ as, className, children, ...props }, ref) => {
5333
6818
  const Comp = as ?? "h5";
5334
- return /* @__PURE__ */ jsx38(
6819
+ return /* @__PURE__ */ jsx39(
5335
6820
  Comp,
5336
6821
  {
5337
6822
  ref,
@@ -5348,8 +6833,8 @@ var SidebarNavSectionLabel = React36.forwardRef(
5348
6833
  }
5349
6834
  );
5350
6835
  SidebarNavSectionLabel.displayName = "SidebarNavSectionLabel";
5351
- var SidebarNavSectionItems = React36.forwardRef(
5352
- ({ className, ...props }, ref) => /* @__PURE__ */ jsx38(
6836
+ var SidebarNavSectionItems = React37.forwardRef(
6837
+ ({ className, ...props }, ref) => /* @__PURE__ */ jsx39(
5353
6838
  "div",
5354
6839
  {
5355
6840
  ref,
@@ -5360,7 +6845,7 @@ var SidebarNavSectionItems = React36.forwardRef(
5360
6845
  )
5361
6846
  );
5362
6847
  SidebarNavSectionItems.displayName = "SidebarNavSectionItems";
5363
- var SidebarNavItem = React36.forwardRef(
6848
+ var SidebarNavItem = React37.forwardRef(
5364
6849
  function SidebarNavItem2({
5365
6850
  as,
5366
6851
  active = false,
@@ -5373,7 +6858,7 @@ var SidebarNavItem = React36.forwardRef(
5373
6858
  }, ref) {
5374
6859
  const Comp = as ?? (props.href ? "a" : "button");
5375
6860
  const isNativeButton = Comp === "button";
5376
- return /* @__PURE__ */ jsxs18(
6861
+ return /* @__PURE__ */ jsxs19(
5377
6862
  Comp,
5378
6863
  {
5379
6864
  ref,
@@ -5394,7 +6879,7 @@ var SidebarNavItem = React36.forwardRef(
5394
6879
  ),
5395
6880
  ...props,
5396
6881
  children: [
5397
- appearance === "settings" ? /* @__PURE__ */ jsx38(
6882
+ appearance === "settings" ? /* @__PURE__ */ jsx39(
5398
6883
  "span",
5399
6884
  {
5400
6885
  "aria-hidden": "true",
@@ -5405,7 +6890,7 @@ var SidebarNavItem = React36.forwardRef(
5405
6890
  )
5406
6891
  }
5407
6892
  ) : null,
5408
- icon ? /* @__PURE__ */ jsx38(
6893
+ icon ? /* @__PURE__ */ jsx39(
5409
6894
  "span",
5410
6895
  {
5411
6896
  "data-slot": "sidebar-nav-item-icon",
@@ -5413,7 +6898,7 @@ var SidebarNavItem = React36.forwardRef(
5413
6898
  children: icon
5414
6899
  }
5415
6900
  ) : null,
5416
- /* @__PURE__ */ jsx38("span", { className: "min-w-0 flex-1 truncate", children: renderTextContent(children, {
6901
+ /* @__PURE__ */ jsx39("span", { className: "min-w-0 flex-1 truncate", children: renderTextContent(children, {
5417
6902
  as: "span",
5418
6903
  className: "block min-w-0 truncate text-inherit",
5419
6904
  size: sidebarNavItemTextSize[appearance]
@@ -5427,8 +6912,8 @@ SidebarNavItem.displayName = "SidebarNavItem";
5427
6912
  var SettingsNavItem = SidebarNavItem;
5428
6913
 
5429
6914
  // src/components/slider.tsx
5430
- import * as React37 from "react";
5431
- import { jsx as jsx39, jsxs as jsxs19 } from "react/jsx-runtime";
6915
+ import * as React38 from "react";
6916
+ import { jsx as jsx40, jsxs as jsxs20 } from "react/jsx-runtime";
5432
6917
  function clampSliderValue(value, min, max) {
5433
6918
  if (Number.isNaN(value)) {
5434
6919
  return min;
@@ -5453,7 +6938,7 @@ function resolveSliderMeasurement(value, fallback) {
5453
6938
  function isTextValue(value) {
5454
6939
  return typeof value === "string" || typeof value === "number";
5455
6940
  }
5456
- var Slider = React37.forwardRef(function Slider2({
6941
+ var Slider = React38.forwardRef(function Slider2({
5457
6942
  className,
5458
6943
  defaultValue,
5459
6944
  formatValue,
@@ -5476,7 +6961,7 @@ var Slider = React37.forwardRef(function Slider2({
5476
6961
  valueClassName,
5477
6962
  ...props
5478
6963
  }, ref) {
5479
- const resolvedId = React37.useId();
6964
+ const resolvedId = React38.useId();
5480
6965
  const inputId = id ?? resolvedId;
5481
6966
  const safeMin = min;
5482
6967
  const safeMax = resolveSliderMax(safeMin, max);
@@ -5485,7 +6970,7 @@ var Slider = React37.forwardRef(function Slider2({
5485
6970
  onChange: onValueChange,
5486
6971
  value
5487
6972
  });
5488
- React37.useEffect(() => {
6973
+ React38.useEffect(() => {
5489
6974
  if (value !== void 0) {
5490
6975
  return;
5491
6976
  }
@@ -5532,14 +7017,14 @@ var Slider = React37.forwardRef(function Slider2({
5532
7017
  setControllableValue(nextValue);
5533
7018
  onChange?.(event);
5534
7019
  };
5535
- return /* @__PURE__ */ jsxs19(
7020
+ return /* @__PURE__ */ jsxs20(
5536
7021
  "div",
5537
7022
  {
5538
7023
  "data-slot": "slider",
5539
7024
  className: cn("grid w-full gap-2", className),
5540
7025
  children: [
5541
- label || showValue ? /* @__PURE__ */ jsxs19("div", { className: "flex items-center justify-between gap-4", children: [
5542
- label ? /* @__PURE__ */ jsx39(
7026
+ label || showValue ? /* @__PURE__ */ jsxs20("div", { className: "flex items-center justify-between gap-4", children: [
7027
+ label ? /* @__PURE__ */ jsx40(
5543
7028
  FieldLabel,
5544
7029
  {
5545
7030
  htmlFor: inputId,
@@ -5550,8 +7035,8 @@ var Slider = React37.forwardRef(function Slider2({
5550
7035
  textClassName: "block min-w-0 text-[color:var(--sofya-text-default)]",
5551
7036
  children: label
5552
7037
  }
5553
- ) : /* @__PURE__ */ jsx39("span", {}),
5554
- showValue ? /* @__PURE__ */ jsx39(
7038
+ ) : /* @__PURE__ */ jsx40("span", {}),
7039
+ showValue ? /* @__PURE__ */ jsx40(
5555
7040
  "div",
5556
7041
  {
5557
7042
  className: cn(
@@ -5569,7 +7054,7 @@ var Slider = React37.forwardRef(function Slider2({
5569
7054
  }
5570
7055
  ) : null
5571
7056
  ] }) : null,
5572
- /* @__PURE__ */ jsxs19(
7057
+ /* @__PURE__ */ jsxs20(
5573
7058
  "div",
5574
7059
  {
5575
7060
  "data-slot": "slider-control",
@@ -5579,7 +7064,7 @@ var Slider = React37.forwardRef(function Slider2({
5579
7064
  ),
5580
7065
  style: controlStyle,
5581
7066
  children: [
5582
- /* @__PURE__ */ jsx39(
7067
+ /* @__PURE__ */ jsx40(
5583
7068
  "input",
5584
7069
  {
5585
7070
  ...props,
@@ -5596,7 +7081,7 @@ var Slider = React37.forwardRef(function Slider2({
5596
7081
  style: inputBoundsStyle
5597
7082
  }
5598
7083
  ),
5599
- /* @__PURE__ */ jsx39(
7084
+ /* @__PURE__ */ jsx40(
5600
7085
  "div",
5601
7086
  {
5602
7087
  "data-slot": "slider-track",
@@ -5607,7 +7092,7 @@ var Slider = React37.forwardRef(function Slider2({
5607
7092
  style: trackBoundsStyle
5608
7093
  }
5609
7094
  ),
5610
- /* @__PURE__ */ jsx39(
7095
+ /* @__PURE__ */ jsx40(
5611
7096
  "div",
5612
7097
  {
5613
7098
  "data-slot": "slider-range",
@@ -5618,7 +7103,7 @@ var Slider = React37.forwardRef(function Slider2({
5618
7103
  style: rangeStyle
5619
7104
  }
5620
7105
  ),
5621
- /* @__PURE__ */ jsx39(
7106
+ /* @__PURE__ */ jsx40(
5622
7107
  "div",
5623
7108
  {
5624
7109
  "data-slot": "slider-thumb",
@@ -5639,10 +7124,10 @@ var Slider = React37.forwardRef(function Slider2({
5639
7124
  Slider.displayName = "Slider";
5640
7125
 
5641
7126
  // src/components/skeleton.tsx
5642
- import * as React38 from "react";
5643
- import { jsx as jsx40 } from "react/jsx-runtime";
5644
- var Skeleton = React38.forwardRef(function Skeleton2({ className, ...props }, ref) {
5645
- return /* @__PURE__ */ jsx40(
7127
+ import * as React39 from "react";
7128
+ import { jsx as jsx41 } from "react/jsx-runtime";
7129
+ var Skeleton = React39.forwardRef(function Skeleton2({ className, ...props }, ref) {
7130
+ return /* @__PURE__ */ jsx41(
5646
7131
  "div",
5647
7132
  {
5648
7133
  ref,
@@ -5657,18 +7142,18 @@ var Skeleton = React38.forwardRef(function Skeleton2({ className, ...props }, re
5657
7142
  Skeleton.displayName = "Skeleton";
5658
7143
 
5659
7144
  // src/components/sonner.tsx
5660
- import * as React39 from "react";
7145
+ import * as React40 from "react";
5661
7146
  import {
5662
7147
  Toaster as SonnerToaster,
5663
7148
  toast
5664
7149
  } from "sonner";
5665
- import { jsx as jsx41 } from "react/jsx-runtime";
7150
+ import { jsx as jsx42 } from "react/jsx-runtime";
5666
7151
  var notificationVariantOptions = ["default", "success", "error", "warning"];
5667
7152
  function ToastStatusIcon({
5668
7153
  iconName,
5669
7154
  className
5670
7155
  }) {
5671
- return /* @__PURE__ */ jsx41(
7156
+ return /* @__PURE__ */ jsx42(
5672
7157
  "span",
5673
7158
  {
5674
7159
  "aria-hidden": "true",
@@ -5676,7 +7161,7 @@ function ToastStatusIcon({
5676
7161
  "inline-flex h-9 w-9 shrink-0 items-center justify-center rounded-full border shadow-none",
5677
7162
  className
5678
7163
  ),
5679
- children: /* @__PURE__ */ jsx41(Icon, { name: iconName, size: 16 })
7164
+ children: /* @__PURE__ */ jsx42(Icon, { name: iconName, size: 16 })
5680
7165
  }
5681
7166
  );
5682
7167
  }
@@ -5700,35 +7185,35 @@ var defaultToastClassNames = {
5700
7185
  loading: "border-border bg-card text-foreground"
5701
7186
  };
5702
7187
  var defaultToastIcons = {
5703
- success: /* @__PURE__ */ jsx41(
7188
+ success: /* @__PURE__ */ jsx42(
5704
7189
  ToastStatusIcon,
5705
7190
  {
5706
7191
  iconName: "check",
5707
7192
  className: "border-success/15 bg-success/12 text-success"
5708
7193
  }
5709
7194
  ),
5710
- error: /* @__PURE__ */ jsx41(
7195
+ error: /* @__PURE__ */ jsx42(
5711
7196
  ToastStatusIcon,
5712
7197
  {
5713
7198
  iconName: "x",
5714
7199
  className: "border-destructive/15 bg-destructive/12 text-destructive"
5715
7200
  }
5716
7201
  ),
5717
- warning: /* @__PURE__ */ jsx41(
7202
+ warning: /* @__PURE__ */ jsx42(
5718
7203
  ToastStatusIcon,
5719
7204
  {
5720
7205
  iconName: "question",
5721
7206
  className: "border-warning/20 bg-warning/15 text-foreground"
5722
7207
  }
5723
7208
  ),
5724
- info: /* @__PURE__ */ jsx41(
7209
+ info: /* @__PURE__ */ jsx42(
5725
7210
  ToastStatusIcon,
5726
7211
  {
5727
7212
  iconName: "question",
5728
7213
  className: "border-primary/15 bg-primary/10 text-primary"
5729
7214
  }
5730
7215
  ),
5731
- close: /* @__PURE__ */ jsx41(Icon, { name: "x", size: 12 })
7216
+ close: /* @__PURE__ */ jsx42(Icon, { name: "x", size: 12 })
5732
7217
  };
5733
7218
  function mergeToastClassNames(overrides) {
5734
7219
  return {
@@ -5736,7 +7221,7 @@ function mergeToastClassNames(overrides) {
5736
7221
  ...overrides
5737
7222
  };
5738
7223
  }
5739
- var Toaster = React39.forwardRef(
7224
+ var Toaster = React40.forwardRef(
5740
7225
  function Toaster2({
5741
7226
  className,
5742
7227
  closeButton = true,
@@ -5748,7 +7233,7 @@ var Toaster = React39.forwardRef(
5748
7233
  visibleToasts = 5,
5749
7234
  ...props
5750
7235
  }, ref) {
5751
- return /* @__PURE__ */ jsx41(
7236
+ return /* @__PURE__ */ jsx42(
5752
7237
  SonnerToaster,
5753
7238
  {
5754
7239
  ref,
@@ -5803,12 +7288,12 @@ notify.dismiss = toast.dismiss;
5803
7288
  notify.promise = toast.promise;
5804
7289
 
5805
7290
  // src/components/status-indicator.tsx
5806
- import * as React41 from "react";
7291
+ import * as React42 from "react";
5807
7292
 
5808
7293
  // src/components/tooltip.tsx
5809
- import * as React40 from "react";
7294
+ import * as React41 from "react";
5810
7295
  import * as TooltipPrimitive from "@radix-ui/react-tooltip";
5811
- import { Fragment as Fragment4, jsx as jsx42, jsxs as jsxs20 } from "react/jsx-runtime";
7296
+ import { Fragment as Fragment4, jsx as jsx43, jsxs as jsxs21 } from "react/jsx-runtime";
5812
7297
  var TooltipProvider = TooltipPrimitive.Provider;
5813
7298
  var Tooltip = TooltipPrimitive.Root;
5814
7299
  var TooltipTrigger = TooltipPrimitive.Trigger;
@@ -5826,8 +7311,8 @@ var tooltipToneClassNames = {
5826
7311
  warning: "border-[color:var(--sofya-tone-warning-border)] bg-[color:var(--sofya-tone-warning-background)] text-[color:var(--sofya-tone-warning-foreground)]",
5827
7312
  destructive: "border-[color:var(--sofya-tone-destructive-border)] bg-[color:var(--sofya-tone-destructive-background)] text-[color:var(--sofya-tone-destructive-foreground)]"
5828
7313
  };
5829
- var TooltipContent = React40.forwardRef(function TooltipContent2({ className, sideOffset = 8, align = "center", tone = "default", ...props }, ref) {
5830
- return /* @__PURE__ */ jsx42(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsx42(
7314
+ var TooltipContent = React41.forwardRef(function TooltipContent2({ className, sideOffset = 8, align = "center", tone = "default", ...props }, ref) {
7315
+ return /* @__PURE__ */ jsx43(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsx43(
5831
7316
  TooltipPrimitive.Content,
5832
7317
  {
5833
7318
  ref,
@@ -5853,7 +7338,7 @@ var TooltipContent = React40.forwardRef(function TooltipContent2({ className, si
5853
7338
  ) });
5854
7339
  });
5855
7340
  TooltipContent.displayName = TooltipPrimitive.Content.displayName;
5856
- var StatusTooltip = React40.forwardRef(function StatusTooltip2({
7341
+ var StatusTooltip = React41.forwardRef(function StatusTooltip2({
5857
7342
  children,
5858
7343
  label,
5859
7344
  status = "default",
@@ -5868,11 +7353,11 @@ var StatusTooltip = React40.forwardRef(function StatusTooltip2({
5868
7353
  className
5869
7354
  }, ref) {
5870
7355
  if (disabled) {
5871
- return /* @__PURE__ */ jsx42(Fragment4, { children });
7356
+ return /* @__PURE__ */ jsx43(Fragment4, { children });
5872
7357
  }
5873
- return /* @__PURE__ */ jsx42(TooltipProvider, { delayDuration, children: /* @__PURE__ */ jsxs20(Tooltip, { open, defaultOpen, onOpenChange, children: [
5874
- /* @__PURE__ */ jsx42(TooltipTrigger, { asChild: true, children }),
5875
- /* @__PURE__ */ jsx42(
7358
+ return /* @__PURE__ */ jsx43(TooltipProvider, { delayDuration, children: /* @__PURE__ */ jsxs21(Tooltip, { open, defaultOpen, onOpenChange, children: [
7359
+ /* @__PURE__ */ jsx43(TooltipTrigger, { asChild: true, children }),
7360
+ /* @__PURE__ */ jsx43(
5876
7361
  TooltipContent,
5877
7362
  {
5878
7363
  ref,
@@ -5890,7 +7375,7 @@ var StatusTooltip = React40.forwardRef(function StatusTooltip2({
5890
7375
  StatusTooltip.displayName = "StatusTooltip";
5891
7376
 
5892
7377
  // src/components/status-indicator.tsx
5893
- import { jsx as jsx43, jsxs as jsxs21 } from "react/jsx-runtime";
7378
+ import { jsx as jsx44, jsxs as jsxs22 } from "react/jsx-runtime";
5894
7379
  var workflowStatusOptions = [
5895
7380
  "draft",
5896
7381
  "in_progress",
@@ -5971,7 +7456,7 @@ var toneTextClassName = {
5971
7456
  warning: "text-[color:var(--sofya-tone-warning-foreground)]",
5972
7457
  destructive: "text-[color:var(--sofya-tone-destructive-foreground)]"
5973
7458
  };
5974
- var StatusIndicator = React41.forwardRef(
7459
+ var StatusIndicator = React42.forwardRef(
5975
7460
  function StatusIndicator2({
5976
7461
  className,
5977
7462
  label,
@@ -5982,7 +7467,7 @@ var StatusIndicator = React41.forwardRef(
5982
7467
  ...props
5983
7468
  }, ref) {
5984
7469
  const resolved = resolveWorkflowStatus(status, { label });
5985
- const indicator = /* @__PURE__ */ jsxs21(
7470
+ const indicator = /* @__PURE__ */ jsxs22(
5986
7471
  "span",
5987
7472
  {
5988
7473
  ref,
@@ -5997,7 +7482,7 @@ var StatusIndicator = React41.forwardRef(
5997
7482
  ),
5998
7483
  ...props,
5999
7484
  children: [
6000
- /* @__PURE__ */ jsx43(
7485
+ /* @__PURE__ */ jsx44(
6001
7486
  "span",
6002
7487
  {
6003
7488
  "aria-hidden": "true",
@@ -6018,15 +7503,15 @@ var StatusIndicator = React41.forwardRef(
6018
7503
  if (!tooltip) {
6019
7504
  return indicator;
6020
7505
  }
6021
- return /* @__PURE__ */ jsx43(StatusTooltip, { status: resolved.tone, label: resolved.label, side, children: indicator });
7506
+ return /* @__PURE__ */ jsx44(StatusTooltip, { status: resolved.tone, label: resolved.label, side, children: indicator });
6022
7507
  }
6023
7508
  );
6024
7509
  StatusIndicator.displayName = "StatusIndicator";
6025
7510
 
6026
7511
  // src/components/switch.tsx
6027
- import * as React42 from "react";
7512
+ import * as React43 from "react";
6028
7513
  import * as SwitchPrimitives from "@radix-ui/react-switch";
6029
- import { jsx as jsx44, jsxs as jsxs22 } from "react/jsx-runtime";
7514
+ import { jsx as jsx45, jsxs as jsxs23 } from "react/jsx-runtime";
6030
7515
  var switchSizeOptions = ["default", "sm"];
6031
7516
  var switchRootSizeClasses = {
6032
7517
  default: "h-6 w-11",
@@ -6036,7 +7521,7 @@ var switchThumbSizeClasses = {
6036
7521
  default: "h-5 w-5 data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0",
6037
7522
  sm: "h-4 w-4 data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0"
6038
7523
  };
6039
- var Switch = React42.forwardRef(
7524
+ var Switch = React43.forwardRef(
6040
7525
  ({
6041
7526
  "aria-describedby": ariaDescribedBy,
6042
7527
  "aria-labelledby": ariaLabelledBy,
@@ -6051,7 +7536,7 @@ var Switch = React42.forwardRef(
6051
7536
  size,
6052
7537
  ...props
6053
7538
  }, ref) => {
6054
- const generatedId = React42.useId();
7539
+ const generatedId = React43.useId();
6055
7540
  const resolvedId = id ?? generatedId;
6056
7541
  const labelId = label ? `${resolvedId}-label` : void 0;
6057
7542
  const descriptionId = description ? `${resolvedId}-description` : void 0;
@@ -6060,7 +7545,7 @@ var Switch = React42.forwardRef(
6060
7545
  const alignClassName2 = description ? "items-start" : "items-center";
6061
7546
  const resolvedAriaDescribedBy = [ariaDescribedBy, descriptionId].filter(Boolean).join(" ") || void 0;
6062
7547
  const resolvedAriaLabelledBy = ariaLabelledBy ?? labelId;
6063
- const switchControl = /* @__PURE__ */ jsx44(
7548
+ const switchControl = /* @__PURE__ */ jsx45(
6064
7549
  SwitchPrimitives.Root,
6065
7550
  {
6066
7551
  id: resolvedId,
@@ -6075,7 +7560,7 @@ var Switch = React42.forwardRef(
6075
7560
  "data-size": resolvedSize,
6076
7561
  ...props,
6077
7562
  ref,
6078
- children: /* @__PURE__ */ jsx44(
7563
+ children: /* @__PURE__ */ jsx45(
6079
7564
  SwitchPrimitives.Thumb,
6080
7565
  {
6081
7566
  className: cn(
@@ -6089,7 +7574,7 @@ var Switch = React42.forwardRef(
6089
7574
  if (!hasTextContent) {
6090
7575
  return switchControl;
6091
7576
  }
6092
- return /* @__PURE__ */ jsxs22(
7577
+ return /* @__PURE__ */ jsxs23(
6093
7578
  "div",
6094
7579
  {
6095
7580
  "data-slot": "switch-container",
@@ -6100,8 +7585,8 @@ var Switch = React42.forwardRef(
6100
7585
  }),
6101
7586
  children: [
6102
7587
  switchControl,
6103
- /* @__PURE__ */ jsxs22("span", { className: selectionControlContentBaseClasses, children: [
6104
- label ? /* @__PURE__ */ jsx44("label", { htmlFor: resolvedId, className: selectionControlLabelTextBaseClasses, children: /* @__PURE__ */ jsx44(
7588
+ /* @__PURE__ */ jsxs23("span", { className: selectionControlContentBaseClasses, children: [
7589
+ label ? /* @__PURE__ */ jsx45("label", { htmlFor: resolvedId, className: selectionControlLabelTextBaseClasses, children: /* @__PURE__ */ jsx45(
6105
7590
  "span",
6106
7591
  {
6107
7592
  id: labelId,
@@ -6116,7 +7601,7 @@ var Switch = React42.forwardRef(
6116
7601
  })
6117
7602
  }
6118
7603
  ) }) : null,
6119
- description ? /* @__PURE__ */ jsx44(
7604
+ description ? /* @__PURE__ */ jsx45(
6120
7605
  "span",
6121
7606
  {
6122
7607
  id: descriptionId,
@@ -6141,8 +7626,8 @@ Switch.displayName = SwitchPrimitives.Root.displayName;
6141
7626
 
6142
7627
  // src/components/table.tsx
6143
7628
  import { cva as cva8 } from "class-variance-authority";
6144
- import * as React43 from "react";
6145
- import { jsx as jsx45 } from "react/jsx-runtime";
7629
+ import * as React44 from "react";
7630
+ import { jsx as jsx46 } from "react/jsx-runtime";
6146
7631
  var tableDensityOptions = ["default", "compact"];
6147
7632
  var tableCellVariantOptions = ["default", "primary", "muted"];
6148
7633
  var tableStatusToneOptions = [
@@ -6152,10 +7637,10 @@ var tableStatusToneOptions = [
6152
7637
  "warning"
6153
7638
  ];
6154
7639
  var tableActionToneOptions = ["primary", "neutral", "danger"];
6155
- var TableDensityContext = React43.createContext("default");
6156
- var TableHeaderDensityContext = React43.createContext("default");
7640
+ var TableDensityContext = React44.createContext("default");
7641
+ var TableHeaderDensityContext = React44.createContext("default");
6157
7642
  function useTableDensity(density) {
6158
- const inheritedDensity = React43.useContext(TableDensityContext);
7643
+ const inheritedDensity = React44.useContext(TableDensityContext);
6159
7644
  return density ?? inheritedDensity;
6160
7645
  }
6161
7646
  var tableCellVariants = cva8(
@@ -6211,13 +7696,13 @@ var tableActionButtonVariants = cva8(
6211
7696
  }
6212
7697
  }
6213
7698
  );
6214
- var Table = React43.forwardRef(function Table2({ className, density = "default", ...props }, ref) {
6215
- return /* @__PURE__ */ jsx45(TableDensityContext.Provider, { value: density, children: /* @__PURE__ */ jsx45(
7699
+ var Table = React44.forwardRef(function Table2({ className, density = "default", ...props }, ref) {
7700
+ return /* @__PURE__ */ jsx46(TableDensityContext.Provider, { value: density, children: /* @__PURE__ */ jsx46(
6216
7701
  "div",
6217
7702
  {
6218
7703
  "data-slot": "table-container",
6219
7704
  className: "relative w-full overflow-x-auto",
6220
- children: /* @__PURE__ */ jsx45(
7705
+ children: /* @__PURE__ */ jsx46(
6221
7706
  "table",
6222
7707
  {
6223
7708
  "data-density": density,
@@ -6234,10 +7719,10 @@ var Table = React43.forwardRef(function Table2({ className, density = "default",
6234
7719
  }
6235
7720
  ) });
6236
7721
  });
6237
- var TableHeader = React43.forwardRef(function TableHeader2({ className, density, ...props }, ref) {
7722
+ var TableHeader = React44.forwardRef(function TableHeader2({ className, density, ...props }, ref) {
6238
7723
  const tableDensity = useTableDensity();
6239
7724
  const headerDensity = density ?? tableDensity;
6240
- return /* @__PURE__ */ jsx45(TableHeaderDensityContext.Provider, { value: headerDensity, children: /* @__PURE__ */ jsx45(TableDensityContext.Provider, { value: "default", children: /* @__PURE__ */ jsx45(
7725
+ return /* @__PURE__ */ jsx46(TableHeaderDensityContext.Provider, { value: headerDensity, children: /* @__PURE__ */ jsx46(TableDensityContext.Provider, { value: "default", children: /* @__PURE__ */ jsx46(
6241
7726
  "thead",
6242
7727
  {
6243
7728
  "data-slot": "table-header",
@@ -6251,8 +7736,8 @@ var TableHeader = React43.forwardRef(function TableHeader2({ className, density,
6251
7736
  }
6252
7737
  ) }) });
6253
7738
  });
6254
- var TableBody = React43.forwardRef(function TableBody2({ className, ...props }, ref) {
6255
- return /* @__PURE__ */ jsx45(
7739
+ var TableBody = React44.forwardRef(function TableBody2({ className, ...props }, ref) {
7740
+ return /* @__PURE__ */ jsx46(
6256
7741
  "tbody",
6257
7742
  {
6258
7743
  "data-slot": "table-body",
@@ -6262,8 +7747,8 @@ var TableBody = React43.forwardRef(function TableBody2({ className, ...props },
6262
7747
  }
6263
7748
  );
6264
7749
  });
6265
- var TableFooter = React43.forwardRef(function TableFooter2({ className, ...props }, ref) {
6266
- return /* @__PURE__ */ jsx45(
7750
+ var TableFooter = React44.forwardRef(function TableFooter2({ className, ...props }, ref) {
7751
+ return /* @__PURE__ */ jsx46(
6267
7752
  "tfoot",
6268
7753
  {
6269
7754
  "data-slot": "table-footer",
@@ -6276,10 +7761,10 @@ var TableFooter = React43.forwardRef(function TableFooter2({ className, ...props
6276
7761
  }
6277
7762
  );
6278
7763
  });
6279
- var TableRow = React43.forwardRef(
7764
+ var TableRow = React44.forwardRef(
6280
7765
  function TableRow2({ className, density, ...props }, ref) {
6281
7766
  const resolvedDensity = useTableDensity(density);
6282
- return /* @__PURE__ */ jsx45(TableDensityContext.Provider, { value: resolvedDensity, children: /* @__PURE__ */ jsx45(
7767
+ return /* @__PURE__ */ jsx46(TableDensityContext.Provider, { value: resolvedDensity, children: /* @__PURE__ */ jsx46(
6283
7768
  "tr",
6284
7769
  {
6285
7770
  "data-density": resolvedDensity,
@@ -6295,9 +7780,9 @@ var TableRow = React43.forwardRef(
6295
7780
  ) });
6296
7781
  }
6297
7782
  );
6298
- var TableHead = React43.forwardRef(function TableHead2({ className, children, ...props }, ref) {
6299
- const headerDensity = React43.useContext(TableHeaderDensityContext);
6300
- return /* @__PURE__ */ jsx45(
7783
+ var TableHead = React44.forwardRef(function TableHead2({ className, children, ...props }, ref) {
7784
+ const headerDensity = React44.useContext(TableHeaderDensityContext);
7785
+ return /* @__PURE__ */ jsx46(
6301
7786
  "th",
6302
7787
  {
6303
7788
  "data-slot": "table-head",
@@ -6318,10 +7803,10 @@ var TableHead = React43.forwardRef(function TableHead2({ className, children, ..
6318
7803
  }
6319
7804
  );
6320
7805
  });
6321
- var TableCell = React43.forwardRef(
7806
+ var TableCell = React44.forwardRef(
6322
7807
  function TableCell2({ className, density, variant, truncate, children, ...props }, ref) {
6323
7808
  const resolvedDensity = useTableDensity(density);
6324
- return /* @__PURE__ */ jsx45(
7809
+ return /* @__PURE__ */ jsx46(
6325
7810
  "td",
6326
7811
  {
6327
7812
  "data-density": resolvedDensity,
@@ -6346,8 +7831,8 @@ var TableCell = React43.forwardRef(
6346
7831
  );
6347
7832
  }
6348
7833
  );
6349
- var TableCaption = React43.forwardRef(function TableCaption2({ className, children, ...props }, ref) {
6350
- return /* @__PURE__ */ jsx45(
7834
+ var TableCaption = React44.forwardRef(function TableCaption2({ className, children, ...props }, ref) {
7835
+ return /* @__PURE__ */ jsx46(
6351
7836
  "caption",
6352
7837
  {
6353
7838
  "data-slot": "table-caption",
@@ -6366,12 +7851,12 @@ var TableCaption = React43.forwardRef(function TableCaption2({ className, childr
6366
7851
  }
6367
7852
  );
6368
7853
  });
6369
- var TableCellTitle = React43.forwardRef(
7854
+ var TableCellTitle = React44.forwardRef(
6370
7855
  function TableCellTitle2({ className, children, size, ...props }, ref) {
6371
7856
  const density = useTableDensity();
6372
7857
  const resolvedSize = size ?? (density === "compact" ? "compact" : "default");
6373
7858
  const textSize = resolvedSize === "compact" ? "label-md" : "body";
6374
- return /* @__PURE__ */ jsx45(
7859
+ return /* @__PURE__ */ jsx46(
6375
7860
  "span",
6376
7861
  {
6377
7862
  "data-slot": "table-cell-title",
@@ -6391,11 +7876,11 @@ var TableCellTitle = React43.forwardRef(
6391
7876
  );
6392
7877
  }
6393
7878
  );
6394
- var TableCellDescription = React43.forwardRef(function TableCellDescription2({ className, children, size, ...props }, ref) {
7879
+ var TableCellDescription = React44.forwardRef(function TableCellDescription2({ className, children, size, ...props }, ref) {
6395
7880
  const density = useTableDensity();
6396
7881
  const resolvedSize = size ?? (density === "compact" ? "compact" : "default");
6397
7882
  const textSize = resolvedSize === "compact" ? "body-sm" : "tiny";
6398
- return /* @__PURE__ */ jsx45(
7883
+ return /* @__PURE__ */ jsx46(
6399
7884
  "span",
6400
7885
  {
6401
7886
  "data-slot": "table-cell-description",
@@ -6423,7 +7908,7 @@ function TableStatusBadge({
6423
7908
  ...props
6424
7909
  }) {
6425
7910
  const resolvedDensity = useTableDensity(density);
6426
- return /* @__PURE__ */ jsx45(
7911
+ return /* @__PURE__ */ jsx46(
6427
7912
  Badge,
6428
7913
  {
6429
7914
  "data-density": resolvedDensity,
@@ -6442,8 +7927,8 @@ function TableStatusBadge({
6442
7927
  }
6443
7928
  );
6444
7929
  }
6445
- var TableActionButton = React43.forwardRef(function TableActionButton2({ className, tone, type = "button", children, ...props }, ref) {
6446
- return /* @__PURE__ */ jsx45(
7930
+ var TableActionButton = React44.forwardRef(function TableActionButton2({ className, tone, type = "button", children, ...props }, ref) {
7931
+ return /* @__PURE__ */ jsx46(
6447
7932
  Button,
6448
7933
  {
6449
7934
  ref,
@@ -6461,8 +7946,8 @@ var TableActionButton = React43.forwardRef(function TableActionButton2({ classNa
6461
7946
  }
6462
7947
  );
6463
7948
  });
6464
- var TableActions = React43.forwardRef(function TableActions2({ className, ...props }, ref) {
6465
- return /* @__PURE__ */ jsx45(
7949
+ var TableActions = React44.forwardRef(function TableActions2({ className, ...props }, ref) {
7950
+ return /* @__PURE__ */ jsx46(
6466
7951
  "div",
6467
7952
  {
6468
7953
  ref,
@@ -6489,8 +7974,8 @@ TableActions.displayName = "TableActions";
6489
7974
 
6490
7975
  // src/components/tag.tsx
6491
7976
  import { cva as cva9 } from "class-variance-authority";
6492
- import * as React44 from "react";
6493
- import { jsx as jsx46, jsxs as jsxs23 } from "react/jsx-runtime";
7977
+ import * as React45 from "react";
7978
+ import { jsx as jsx47, jsxs as jsxs24 } from "react/jsx-runtime";
6494
7979
  var tagVariantOptions = [
6495
7980
  "neutral",
6496
7981
  "organization",
@@ -6531,9 +8016,9 @@ var tagStatusToneClasses = {
6531
8016
  warning: "border-[color:var(--sofya-tone-warning-border)] bg-[color:var(--sofya-tone-warning-background)] text-[color:var(--sofya-tone-warning-foreground)]",
6532
8017
  destructive: "border-[color:var(--sofya-tone-destructive-border)] bg-[color:var(--sofya-tone-destructive-background)] text-[color:var(--sofya-tone-destructive-foreground)]"
6533
8018
  };
6534
- var Tag = React44.forwardRef(function Tag2({ children, className, icon, tone = "info", truncate = false, variant, ...props }, ref) {
8019
+ var Tag = React45.forwardRef(function Tag2({ children, className, icon, tone = "info", truncate = false, variant, ...props }, ref) {
6535
8020
  const resolvedVariant = variant ?? "neutral";
6536
- return /* @__PURE__ */ jsxs23(
8021
+ return /* @__PURE__ */ jsxs24(
6537
8022
  "span",
6538
8023
  {
6539
8024
  ref,
@@ -6547,7 +8032,7 @@ var Tag = React44.forwardRef(function Tag2({ children, className, icon, tone = "
6547
8032
  ),
6548
8033
  ...props,
6549
8034
  children: [
6550
- icon ? /* @__PURE__ */ jsx46("span", { className: "inline-flex shrink-0 items-center justify-center", children: icon }) : null,
8035
+ icon ? /* @__PURE__ */ jsx47("span", { className: "inline-flex shrink-0 items-center justify-center", children: icon }) : null,
6551
8036
  renderTextContent(children, {
6552
8037
  as: "span",
6553
8038
  className: cn("text-inherit", truncate && "min-w-0 truncate"),
@@ -6568,11 +8053,11 @@ var privacyDefaultLabels = {
6568
8053
  organization: "Minha organiza\xE7\xE3o",
6569
8054
  public: "P\xFAblico"
6570
8055
  };
6571
- var PrivacyLabel = React44.forwardRef(
8056
+ var PrivacyLabel = React45.forwardRef(
6572
8057
  function PrivacyLabel2({ appearance = "text", className, icon, label, privacy, ...props }, ref) {
6573
8058
  const content = label ?? privacyDefaultLabels[privacy];
6574
8059
  if (appearance === "tag") {
6575
- return /* @__PURE__ */ jsx46(
8060
+ return /* @__PURE__ */ jsx47(
6576
8061
  Tag,
6577
8062
  {
6578
8063
  ref,
@@ -6585,7 +8070,7 @@ var PrivacyLabel = React44.forwardRef(
6585
8070
  }
6586
8071
  );
6587
8072
  }
6588
- return /* @__PURE__ */ jsxs23(
8073
+ return /* @__PURE__ */ jsxs24(
6589
8074
  "span",
6590
8075
  {
6591
8076
  ref,
@@ -6597,7 +8082,7 @@ var PrivacyLabel = React44.forwardRef(
6597
8082
  ),
6598
8083
  ...props,
6599
8084
  children: [
6600
- icon ? /* @__PURE__ */ jsx46("span", { className: "inline-flex shrink-0 items-center justify-center", children: icon }) : null,
8085
+ icon ? /* @__PURE__ */ jsx47("span", { className: "inline-flex shrink-0 items-center justify-center", children: icon }) : null,
6601
8086
  renderTextContent(content, {
6602
8087
  as: "span",
6603
8088
  className: "text-inherit",
@@ -6611,12 +8096,12 @@ var PrivacyLabel = React44.forwardRef(
6611
8096
  PrivacyLabel.displayName = "PrivacyLabel";
6612
8097
 
6613
8098
  // src/components/template-card.tsx
6614
- import * as React45 from "react";
6615
- import { Fragment as Fragment5, jsx as jsx47, jsxs as jsxs24 } from "react/jsx-runtime";
8099
+ import * as React46 from "react";
8100
+ import { Fragment as Fragment5, jsx as jsx48, jsxs as jsxs25 } from "react/jsx-runtime";
6616
8101
  var templateCardLayoutOptions = ["card", "list"];
6617
8102
  var templateCardFavoriteDisplayOptions = ["action", "inline"];
6618
8103
  var templateCardMetaPlacementOptions = ["block", "inline"];
6619
- var TemplateCard = React45.forwardRef(
8104
+ var TemplateCard = React46.forwardRef(
6620
8105
  function TemplateCard2({
6621
8106
  className,
6622
8107
  description,
@@ -6643,14 +8128,14 @@ var TemplateCard = React45.forwardRef(
6643
8128
  const showInlineMeta = metaPlacement === "inline" && Boolean(meta);
6644
8129
  const showBlockMeta = metaPlacement !== "inline" && Boolean(meta);
6645
8130
  const showFavoriteAction = favoriteDisplay !== "inline" && (onToggleFavorite !== void 0 || favorited !== void 0);
6646
- const actions = showFavoriteAction || overflow ? /* @__PURE__ */ jsxs24("div", { className: "flex shrink-0 items-center gap-[var(--sofya-gap-tight)]", children: [
6647
- showFavoriteAction ? /* @__PURE__ */ jsx47(
8131
+ const actions = showFavoriteAction || overflow ? /* @__PURE__ */ jsxs25("div", { className: "flex shrink-0 items-center gap-[var(--sofya-gap-tight)]", children: [
8132
+ showFavoriteAction ? /* @__PURE__ */ jsx48(
6648
8133
  IconButton,
6649
8134
  {
6650
8135
  "aria-label": favoriteLabel,
6651
8136
  selected: Boolean(favorited),
6652
8137
  onClick: onToggleFavorite,
6653
- icon: /* @__PURE__ */ jsx47(Icon, { name: "star", size: 18 })
8138
+ icon: /* @__PURE__ */ jsx48(Icon, { name: "star", size: 18 })
6654
8139
  }
6655
8140
  ) : null,
6656
8141
  overflow
@@ -6665,10 +8150,10 @@ var TemplateCard = React45.forwardRef(
6665
8150
  style: selectable ? { fontSize: "15px", lineHeight: "26px", fontWeight: 600 } : void 0
6666
8151
  });
6667
8152
  const hasInlineTitleExtras = showInlineStar || showInlineMeta;
6668
- const titleRow = hasInlineTitleExtras ? /* @__PURE__ */ jsxs24("div", { className: "flex min-w-0 items-center gap-[var(--sofya-gap-tight)]", children: [
6669
- showInlineStar ? /* @__PURE__ */ jsx47(Icon, { name: "star-filled", size: 18, color: "primary" }) : null,
8153
+ const titleRow = hasInlineTitleExtras ? /* @__PURE__ */ jsxs25("div", { className: "flex min-w-0 items-center gap-[var(--sofya-gap-tight)]", children: [
8154
+ showInlineStar ? /* @__PURE__ */ jsx48(Icon, { name: "star-filled", size: 18, color: "primary" }) : null,
6670
8155
  titleNode,
6671
- showInlineMeta ? /* @__PURE__ */ jsx47(
8156
+ showInlineMeta ? /* @__PURE__ */ jsx48(
6672
8157
  "span",
6673
8158
  {
6674
8159
  "data-slot": "template-card-meta-inline",
@@ -6677,7 +8162,7 @@ var TemplateCard = React45.forwardRef(
6677
8162
  }
6678
8163
  ) : null
6679
8164
  ] }) : titleNode;
6680
- const heading = /* @__PURE__ */ jsxs24("div", { className: "flex min-w-0 flex-col gap-[var(--sofya-space-1)]", children: [
8165
+ const heading = /* @__PURE__ */ jsxs25("div", { className: "flex min-w-0 flex-col gap-[var(--sofya-space-1)]", children: [
6681
8166
  titleRow,
6682
8167
  description ? renderTextContent(description, {
6683
8168
  as: "span",
@@ -6695,7 +8180,7 @@ var TemplateCard = React45.forwardRef(
6695
8180
  style: selectable ? { fontSize: "14px", lineHeight: "18px", fontWeight: 400 } : void 0
6696
8181
  }) : null
6697
8182
  ] });
6698
- const blockMeta = showBlockMeta ? /* @__PURE__ */ jsx47(
8183
+ const blockMeta = showBlockMeta ? /* @__PURE__ */ jsx48(
6699
8184
  "div",
6700
8185
  {
6701
8186
  "data-slot": "template-card-meta",
@@ -6719,7 +8204,7 @@ var TemplateCard = React45.forwardRef(
6719
8204
  }
6720
8205
  onKeyDown?.(event);
6721
8206
  };
6722
- return /* @__PURE__ */ jsx47(
8207
+ return /* @__PURE__ */ jsx48(
6723
8208
  "div",
6724
8209
  {
6725
8210
  ref,
@@ -6745,13 +8230,13 @@ var TemplateCard = React45.forwardRef(
6745
8230
  className
6746
8231
  ),
6747
8232
  ...props,
6748
- children: selectable ? /* @__PURE__ */ jsxs24(Fragment5, { children: [
6749
- /* @__PURE__ */ jsx47(
8233
+ children: selectable ? /* @__PURE__ */ jsxs25(Fragment5, { children: [
8234
+ /* @__PURE__ */ jsx48(
6750
8235
  "span",
6751
8236
  {
6752
8237
  className: "shrink-0",
6753
8238
  onClick: (event) => event.stopPropagation(),
6754
- children: /* @__PURE__ */ jsx47(
8239
+ children: /* @__PURE__ */ jsx48(
6755
8240
  Checkbox,
6756
8241
  {
6757
8242
  checked: selected,
@@ -6761,15 +8246,15 @@ var TemplateCard = React45.forwardRef(
6761
8246
  )
6762
8247
  }
6763
8248
  ),
6764
- /* @__PURE__ */ jsx47("div", { className: "min-w-0 flex-1", children: heading }),
8249
+ /* @__PURE__ */ jsx48("div", { className: "min-w-0 flex-1", children: heading }),
6765
8250
  blockMeta,
6766
8251
  actions
6767
- ] }) : isList ? /* @__PURE__ */ jsxs24(Fragment5, { children: [
6768
- /* @__PURE__ */ jsx47("div", { className: "min-w-0 flex-1", children: heading }),
8252
+ ] }) : isList ? /* @__PURE__ */ jsxs25(Fragment5, { children: [
8253
+ /* @__PURE__ */ jsx48("div", { className: "min-w-0 flex-1", children: heading }),
6769
8254
  blockMeta,
6770
8255
  actions
6771
- ] }) : /* @__PURE__ */ jsxs24(Fragment5, { children: [
6772
- /* @__PURE__ */ jsxs24("div", { className: "flex items-start justify-between gap-[var(--sofya-gap-compact)]", children: [
8256
+ ] }) : /* @__PURE__ */ jsxs25(Fragment5, { children: [
8257
+ /* @__PURE__ */ jsxs25("div", { className: "flex items-start justify-between gap-[var(--sofya-gap-compact)]", children: [
6773
8258
  heading,
6774
8259
  actions
6775
8260
  ] }),
@@ -6780,16 +8265,16 @@ var TemplateCard = React45.forwardRef(
6780
8265
  }
6781
8266
  );
6782
8267
  TemplateCard.displayName = "TemplateCard";
6783
- var TemplateListItem = React45.forwardRef(function TemplateListItem2(props, ref) {
6784
- return /* @__PURE__ */ jsx47(TemplateCard, { ref, layout: "list", ...props });
8268
+ var TemplateListItem = React46.forwardRef(function TemplateListItem2(props, ref) {
8269
+ return /* @__PURE__ */ jsx48(TemplateCard, { ref, layout: "list", ...props });
6785
8270
  });
6786
8271
  TemplateListItem.displayName = "TemplateListItem";
6787
8272
 
6788
8273
  // src/components/tabs.tsx
6789
- import * as React46 from "react";
8274
+ import * as React47 from "react";
6790
8275
  import * as TabsPrimitive from "@radix-ui/react-tabs";
6791
8276
  import { motion as motion3 } from "motion/react";
6792
- import { jsx as jsx48, jsxs as jsxs25 } from "react/jsx-runtime";
8277
+ import { jsx as jsx49, jsxs as jsxs26 } from "react/jsx-runtime";
6793
8278
  function resolveDefaultValue(items, defaultValue) {
6794
8279
  if (defaultValue) {
6795
8280
  return defaultValue;
@@ -6813,13 +8298,13 @@ function Tabs({
6813
8298
  onChange: onValueChange,
6814
8299
  value
6815
8300
  });
6816
- const indicatorLayoutId = React46.useId();
6817
- React46.useEffect(() => {
8301
+ const indicatorLayoutId = React47.useId();
8302
+ React47.useEffect(() => {
6818
8303
  if (value === void 0) {
6819
8304
  setUncontrolledCurrentValue(resolvedDefaultValue);
6820
8305
  }
6821
8306
  }, [resolvedDefaultValue, setUncontrolledCurrentValue, value]);
6822
- return /* @__PURE__ */ jsxs25(
8307
+ return /* @__PURE__ */ jsxs26(
6823
8308
  TabsPrimitive.Root,
6824
8309
  {
6825
8310
  className: cn("w-full", className),
@@ -6827,7 +8312,7 @@ function Tabs({
6827
8312
  value: currentValue,
6828
8313
  ...props,
6829
8314
  children: [
6830
- /* @__PURE__ */ jsx48(
8315
+ /* @__PURE__ */ jsx49(
6831
8316
  TabsPrimitive.List,
6832
8317
  {
6833
8318
  "aria-label": "Subtelas navegaveis",
@@ -6838,7 +8323,7 @@ function Tabs({
6838
8323
  children: items.map((item) => {
6839
8324
  const isUnavailable = item.disabled || item.loading;
6840
8325
  const isActive = item.value === currentValue;
6841
- return /* @__PURE__ */ jsxs25(
8326
+ return /* @__PURE__ */ jsxs26(
6842
8327
  TabsPrimitive.Trigger,
6843
8328
  {
6844
8329
  value: item.value,
@@ -6850,7 +8335,7 @@ function Tabs({
6850
8335
  item.triggerClassName
6851
8336
  ),
6852
8337
  children: [
6853
- isActive ? /* @__PURE__ */ jsx48(
8338
+ isActive ? /* @__PURE__ */ jsx49(
6854
8339
  motion3.span,
6855
8340
  {
6856
8341
  "aria-hidden": "true",
@@ -6860,15 +8345,15 @@ function Tabs({
6860
8345
  transition: { duration: 0.25, ease: "easeInOut" }
6861
8346
  }
6862
8347
  ) : null,
6863
- /* @__PURE__ */ jsxs25("span", { className: "relative z-10 inline-flex items-center gap-2", children: [
6864
- item.loading ? /* @__PURE__ */ jsx48(
8348
+ /* @__PURE__ */ jsxs26("span", { className: "relative z-10 inline-flex items-center gap-2", children: [
8349
+ item.loading ? /* @__PURE__ */ jsx49(
6865
8350
  "span",
6866
8351
  {
6867
8352
  "aria-hidden": "true",
6868
8353
  className: "h-4 w-4 animate-spin rounded-full border-2 border-current border-r-transparent"
6869
8354
  }
6870
8355
  ) : null,
6871
- /* @__PURE__ */ jsx48("span", { children: renderTextContent(item.label, {
8356
+ /* @__PURE__ */ jsx49("span", { children: renderTextContent(item.label, {
6872
8357
  as: "span",
6873
8358
  className: "block text-inherit",
6874
8359
  size: "body"
@@ -6882,7 +8367,7 @@ function Tabs({
6882
8367
  }
6883
8368
  ),
6884
8369
  items.map(
6885
- (item) => item.content !== void 0 ? /* @__PURE__ */ jsx48(
8370
+ (item) => item.content !== void 0 ? /* @__PURE__ */ jsx49(
6886
8371
  TabsPrimitive.Content,
6887
8372
  {
6888
8373
  value: item.value,
@@ -6905,9 +8390,9 @@ function Tabs({
6905
8390
  Tabs.displayName = "Tabs";
6906
8391
 
6907
8392
  // src/components/textarea.tsx
6908
- import * as React47 from "react";
6909
- import { jsx as jsx49 } from "react/jsx-runtime";
6910
- var Textarea = React47.forwardRef(
8393
+ import * as React48 from "react";
8394
+ import { jsx as jsx50 } from "react/jsx-runtime";
8395
+ var Textarea = React48.forwardRef(
6911
8396
  ({
6912
8397
  className,
6913
8398
  containerClassName,
@@ -6917,10 +8402,10 @@ var Textarea = React47.forwardRef(
6917
8402
  rows = 5,
6918
8403
  ...props
6919
8404
  }, ref) => {
6920
- const generatedId = React47.useId();
8405
+ const generatedId = React48.useId();
6921
8406
  const resolvedId = id ?? generatedId;
6922
8407
  const ariaLabel = props["aria-label"] ?? (typeof label === "string" ? label : void 0);
6923
- const control = /* @__PURE__ */ jsx49(
8408
+ const control = /* @__PURE__ */ jsx50(
6924
8409
  "textarea",
6925
8410
  {
6926
8411
  className: cn(
@@ -6934,7 +8419,7 @@ var Textarea = React47.forwardRef(
6934
8419
  "aria-label": ariaLabel
6935
8420
  }
6936
8421
  );
6937
- return /* @__PURE__ */ jsx49(
8422
+ return /* @__PURE__ */ jsx50(
6938
8423
  FieldShell,
6939
8424
  {
6940
8425
  control,
@@ -6949,10 +8434,10 @@ var Textarea = React47.forwardRef(
6949
8434
  Textarea.displayName = "Textarea";
6950
8435
 
6951
8436
  // src/components/toggle.tsx
6952
- import * as React48 from "react";
8437
+ import * as React49 from "react";
6953
8438
  import * as SwitchPrimitives2 from "@radix-ui/react-switch";
6954
- import { jsx as jsx50, jsxs as jsxs26 } from "react/jsx-runtime";
6955
- var Toggle = React48.forwardRef(function Toggle2({
8439
+ import { jsx as jsx51, jsxs as jsxs27 } from "react/jsx-runtime";
8440
+ var Toggle = React49.forwardRef(function Toggle2({
6956
8441
  "aria-describedby": ariaDescribedBy,
6957
8442
  "aria-labelledby": ariaLabelledBy,
6958
8443
  className,
@@ -6965,7 +8450,7 @@ var Toggle = React48.forwardRef(function Toggle2({
6965
8450
  labelClassName,
6966
8451
  ...props
6967
8452
  }, ref) {
6968
- const generatedId = React48.useId();
8453
+ const generatedId = React49.useId();
6969
8454
  const resolvedId = id ?? generatedId;
6970
8455
  const labelId = label ? `${resolvedId}-label` : void 0;
6971
8456
  const descriptionId = description ? `${resolvedId}-description` : void 0;
@@ -6973,7 +8458,7 @@ var Toggle = React48.forwardRef(function Toggle2({
6973
8458
  const alignClassName2 = description ? "items-start" : "items-center";
6974
8459
  const resolvedAriaDescribedBy = [ariaDescribedBy, descriptionId].filter(Boolean).join(" ") || void 0;
6975
8460
  const resolvedAriaLabelledBy = ariaLabelledBy ?? labelId;
6976
- const toggleControl = /* @__PURE__ */ jsx50(
8461
+ const toggleControl = /* @__PURE__ */ jsx51(
6977
8462
  SwitchPrimitives2.Root,
6978
8463
  {
6979
8464
  id: resolvedId,
@@ -6987,7 +8472,7 @@ var Toggle = React48.forwardRef(function Toggle2({
6987
8472
  className
6988
8473
  ),
6989
8474
  ...props,
6990
- children: /* @__PURE__ */ jsx50(
8475
+ children: /* @__PURE__ */ jsx51(
6991
8476
  SwitchPrimitives2.Thumb,
6992
8477
  {
6993
8478
  "data-slot": "toggle-thumb",
@@ -6999,7 +8484,7 @@ var Toggle = React48.forwardRef(function Toggle2({
6999
8484
  if (!hasTextContent) {
7000
8485
  return toggleControl;
7001
8486
  }
7002
- return /* @__PURE__ */ jsxs26(
8487
+ return /* @__PURE__ */ jsxs27(
7003
8488
  "div",
7004
8489
  {
7005
8490
  "data-slot": "toggle-container",
@@ -7010,8 +8495,8 @@ var Toggle = React48.forwardRef(function Toggle2({
7010
8495
  }),
7011
8496
  children: [
7012
8497
  toggleControl,
7013
- /* @__PURE__ */ jsxs26("span", { className: selectionControlContentBaseClasses, children: [
7014
- label ? /* @__PURE__ */ jsx50("label", { htmlFor: resolvedId, className: selectionControlLabelTextBaseClasses, children: /* @__PURE__ */ jsx50(
8498
+ /* @__PURE__ */ jsxs27("span", { className: selectionControlContentBaseClasses, children: [
8499
+ label ? /* @__PURE__ */ jsx51("label", { htmlFor: resolvedId, className: selectionControlLabelTextBaseClasses, children: /* @__PURE__ */ jsx51(
7015
8500
  "span",
7016
8501
  {
7017
8502
  id: labelId,
@@ -7023,7 +8508,7 @@ var Toggle = React48.forwardRef(function Toggle2({
7023
8508
  })
7024
8509
  }
7025
8510
  ) }) : null,
7026
- description ? /* @__PURE__ */ jsx50(
8511
+ description ? /* @__PURE__ */ jsx51(
7027
8512
  "span",
7028
8513
  {
7029
8514
  id: descriptionId,
@@ -7046,13 +8531,13 @@ var Toggle = React48.forwardRef(function Toggle2({
7046
8531
  Toggle.displayName = "Toggle";
7047
8532
 
7048
8533
  // src/theme/provider.tsx
7049
- import * as React49 from "react";
8534
+ import * as React50 from "react";
7050
8535
  import {
7051
8536
  createWhitelabelTheme,
7052
8537
  defaultTheme,
7053
8538
  themeToCssVariables
7054
8539
  } from "@sofya-ds/tokens";
7055
- import { jsx as jsx51 } from "react/jsx-runtime";
8540
+ import { jsx as jsx52 } from "react/jsx-runtime";
7056
8541
  var SOFYA_FONT_LINKS = [
7057
8542
  {
7058
8543
  id: "preconnect-googleapis",
@@ -7072,7 +8557,7 @@ var SOFYA_FONT_LINKS = [
7072
8557
  }
7073
8558
  ];
7074
8559
  function useSofyaFontLinks() {
7075
- React49.useEffect(() => {
8560
+ React50.useEffect(() => {
7076
8561
  if (typeof document === "undefined") {
7077
8562
  return;
7078
8563
  }
@@ -7105,7 +8590,7 @@ function SofyaProvider({
7105
8590
  useSofyaFontLinks();
7106
8591
  const theme = createWhitelabelTheme(overrides ?? {}, preset);
7107
8592
  const cssVariables = themeToCssVariables(theme);
7108
- return /* @__PURE__ */ jsx51(
8593
+ return /* @__PURE__ */ jsx52(
7109
8594
  "div",
7110
8595
  {
7111
8596
  "data-sofya-theme": theme.name,
@@ -7225,6 +8710,15 @@ export {
7225
8710
  RadioGroupOptionDescription,
7226
8711
  RadioGroupOptionIndicator,
7227
8712
  RadioGroupOptionLabel,
8713
+ ReasoningLabsWidget,
8714
+ ReasoningSummaryWidget,
8715
+ ReasoningVitalsWidget,
8716
+ ReasoningWidget,
8717
+ ReasoningWidgetActionButton,
8718
+ ReasoningWidgetActions,
8719
+ ReasoningWidgetList,
8720
+ ReasoningWidgetRenderer,
8721
+ ReasoningWidgetTable,
7228
8722
  RichTextToolbar,
7229
8723
  RichTextToolbarButton,
7230
8724
  RichTextToolbarGroup,
@@ -7329,6 +8823,14 @@ export {
7329
8823
  progressSizeOptions,
7330
8824
  radioGroupOrientationOptions,
7331
8825
  radioGroupVariantOptions,
8826
+ reasoningWidgetActionScopeOptions,
8827
+ reasoningWidgetActionToneOptions,
8828
+ reasoningWidgetDensityOptions,
8829
+ reasoningWidgetFrameOptions,
8830
+ reasoningWidgetTableAlignOptions,
8831
+ reasoningWidgetTableColumnVariantOptions,
8832
+ reasoningWidgetToneOptions,
8833
+ reasoningWidgetVariantOptions,
7332
8834
  renderTextContent,
7333
8835
  resolveSurfaceToken,
7334
8836
  resolveTextStyle,