@discuss-ds/ui 0.24.1 → 0.26.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1046,13 +1046,14 @@ import { Tabs as TabsPrimitive2 } from "radix-ui";
1046
1046
  import * as React19 from "react";
1047
1047
  import { Tabs as TabsPrimitive } from "radix-ui";
1048
1048
  import { cva as cva3 } from "class-variance-authority";
1049
- import { jsx as jsx20 } from "react/jsx-runtime";
1049
+ import { jsx as jsx20, jsxs as jsxs14 } from "react/jsx-runtime";
1050
1050
  var TabNavigationContext = React19.createContext("filter");
1051
1051
  var tabNavigationVariants = cva3("inline-flex items-start gap-1 p-0.5", {
1052
1052
  variants: {
1053
1053
  variant: {
1054
- filter: "rounded-full border border-border bg-surface",
1055
- toggle: "rounded-md bg-secondary bg-linear-to-r from-overlay-dark-5 to-overlay-dark-5",
1054
+ // `relative`: the sliding indicator is positioned against the list.
1055
+ filter: "relative rounded-full border border-border bg-surface",
1056
+ toggle: "relative rounded-md bg-secondary bg-linear-to-r from-overlay-dark-5 to-overlay-dark-5",
1056
1057
  underline: "items-stretch p-0"
1057
1058
  }
1058
1059
  },
@@ -1060,16 +1061,70 @@ var tabNavigationVariants = cva3("inline-flex items-start gap-1 p-0.5", {
1060
1061
  });
1061
1062
  var Tabs = TabsPrimitive.Root;
1062
1063
  var TabsContent = TabsPrimitive.Content;
1064
+ var indicatorClasses = {
1065
+ filter: "rounded-full bg-secondary bg-linear-to-r from-overlay-dark-5 to-overlay-dark-5",
1066
+ toggle: "rounded-sm bg-surface"
1067
+ };
1063
1068
  var TabNavigation = React19.forwardRef(
1064
- ({ className, variant = "filter", ...props }, ref) => /* @__PURE__ */ jsx20(TabNavigationContext.Provider, { value: variant ?? "filter", children: /* @__PURE__ */ jsx20(TabsPrimitive.List, { ref, className: cn(tabNavigationVariants({ variant }), className), ...props }) })
1069
+ ({ className, variant = "filter", children, ...props }, forwardedRef) => {
1070
+ const kind = variant ?? "filter";
1071
+ const slides = kind !== "underline";
1072
+ const listRef = React19.useRef(null);
1073
+ const [box, setBox] = React19.useState(null);
1074
+ const [animate, setAnimate] = React19.useState(false);
1075
+ const setRefs = React19.useCallback(
1076
+ (node) => {
1077
+ listRef.current = node;
1078
+ if (typeof forwardedRef === "function") forwardedRef(node);
1079
+ else if (forwardedRef) forwardedRef.current = node;
1080
+ },
1081
+ [forwardedRef]
1082
+ );
1083
+ React19.useLayoutEffect(() => {
1084
+ const list = listRef.current;
1085
+ if (!slides || !list) return;
1086
+ const measure = () => {
1087
+ const active = list.querySelector('[role="tab"][data-state="active"]');
1088
+ const next = active ? { left: active.offsetLeft, top: active.offsetTop, width: active.offsetWidth, height: active.offsetHeight } : null;
1089
+ setBox((prev) => prev && next && prev.left === next.left && prev.top === next.top && prev.width === next.width && prev.height === next.height ? prev : next);
1090
+ };
1091
+ measure();
1092
+ const mutations = new MutationObserver(measure);
1093
+ mutations.observe(list, { attributes: true, attributeFilter: ["data-state"], subtree: true, childList: true });
1094
+ const resizes = typeof ResizeObserver === "undefined" ? null : new ResizeObserver(measure);
1095
+ resizes?.observe(list);
1096
+ const frame = requestAnimationFrame(() => setAnimate(true));
1097
+ return () => {
1098
+ mutations.disconnect();
1099
+ resizes?.disconnect();
1100
+ cancelAnimationFrame(frame);
1101
+ };
1102
+ }, [slides]);
1103
+ return /* @__PURE__ */ jsx20(TabNavigationContext.Provider, { value: kind, children: /* @__PURE__ */ jsxs14(TabsPrimitive.List, { ref: setRefs, className: cn(tabNavigationVariants({ variant }), className), ...props, children: [
1104
+ slides && box && /* @__PURE__ */ jsx20(
1105
+ "span",
1106
+ {
1107
+ "aria-hidden": true,
1108
+ "data-slot": "tab-indicator",
1109
+ className: cn(
1110
+ "pointer-events-none absolute",
1111
+ indicatorClasses[kind],
1112
+ animate && "transition-[left,top,width,height] duration-200 ease-out motion-reduce:transition-none"
1113
+ ),
1114
+ style: { left: box.left, top: box.top, width: box.width, height: box.height }
1115
+ }
1116
+ ),
1117
+ children
1118
+ ] }) });
1119
+ }
1065
1120
  );
1066
1121
  TabNavigation.displayName = "TabNavigation";
1067
1122
 
1068
1123
  // src/components/Navigation/TabItem.tsx
1069
1124
  import { jsx as jsx21 } from "react/jsx-runtime";
1070
1125
  var base = "inline-flex h-7 items-center justify-center gap-1 whitespace-nowrap px-2.5 py-1 text-ui-label transition-colors disabled:pointer-events-none disabled:opacity-50";
1071
- var filter = "rounded-full text-surface-foreground hover:text-accent data-[state=active]:bg-secondary data-[state=active]:bg-linear-to-r data-[state=active]:from-overlay-dark-5 data-[state=active]:to-overlay-dark-5 data-[state=active]:hover:bg-accent-soft data-[state=active]:hover:bg-none data-[state=active]:hover:text-accent-soft-foreground disabled:text-muted-foreground";
1072
- var toggle = "rounded-sm text-secondary-muted-foreground hover:text-surface-foreground data-[state=active]:bg-surface data-[state=active]:text-surface-foreground";
1126
+ var filter = "relative rounded-full text-surface-foreground hover:text-accent data-[state=active]:hover:bg-accent-soft data-[state=active]:hover:text-accent-soft-foreground disabled:text-muted-foreground";
1127
+ var toggle = "relative rounded-sm text-secondary-muted-foreground hover:text-surface-foreground data-[state=active]:text-surface-foreground";
1073
1128
  var underline = "relative h-full rounded-none px-4 py-3 font-medium text-secondary-muted-foreground hover:text-surface-foreground data-[state=active]:font-semibold data-[state=active]:text-surface-foreground after:absolute after:inset-x-0 after:bottom-0 after:h-0.5 data-[state=active]:after:bg-accent";
1074
1129
  var TabItem = React20.forwardRef(
1075
1130
  ({ className, ...props }, ref) => {
@@ -1087,7 +1142,7 @@ var TabItem = React20.forwardRef(
1087
1142
  TabItem.displayName = "TabItem";
1088
1143
 
1089
1144
  // src/components/Forms & Data Entry/TimePicker.tsx
1090
- import { jsx as jsx22, jsxs as jsxs14 } from "react/jsx-runtime";
1145
+ import { jsx as jsx22, jsxs as jsxs15 } from "react/jsx-runtime";
1091
1146
  var TimeItem = React21.forwardRef(
1092
1147
  ({ className, recommended, ...props }, ref) => /* @__PURE__ */ jsx22(
1093
1148
  ToggleGroupPrimitive.Item,
@@ -1128,7 +1183,7 @@ function TimePicker({
1128
1183
  }, []);
1129
1184
  const hours = Array.from({ length: 12 }, (_, i) => i + 1);
1130
1185
  const minutes = Array.from({ length: Math.ceil(60 / minuteStep) }, (_, i) => i * minuteStep);
1131
- return /* @__PURE__ */ jsxs14("div", { ref: root, className: cn("flex w-45 flex-col gap-4 pt-2", className), children: [
1186
+ return /* @__PURE__ */ jsxs15("div", { ref: root, className: cn("flex w-45 flex-col gap-4 pt-2", className), children: [
1132
1187
  /* @__PURE__ */ jsx22("p", { className: "text-ui-label text-surface-foreground", children: "Select Time" }),
1133
1188
  /* @__PURE__ */ jsx22(
1134
1189
  Tabs,
@@ -1138,7 +1193,7 @@ function TimePicker({
1138
1193
  children: /* @__PURE__ */ jsx22(TabNavigation, { variant: "toggle", "aria-label": "AM or PM", className: "self-start", children: ["AM", "PM"].map((period) => /* @__PURE__ */ jsx22(TabItem, { value: period, children: period }, period)) })
1139
1194
  }
1140
1195
  ),
1141
- /* @__PURE__ */ jsxs14("div", { className: "flex h-47.5 w-full items-start gap-3", children: [
1196
+ /* @__PURE__ */ jsxs15("div", { className: "flex h-47.5 w-full items-start gap-3", children: [
1142
1197
  /* @__PURE__ */ jsx22(
1143
1198
  ToggleGroupPrimitive.Root,
1144
1199
  {
@@ -1185,7 +1240,7 @@ function TimePicker({
1185
1240
  }
1186
1241
 
1187
1242
  // src/components/Forms & Data Entry/DateTimePicker.tsx
1188
- import { Fragment as Fragment3, jsx as jsx23, jsxs as jsxs15 } from "react/jsx-runtime";
1243
+ import { Fragment as Fragment3, jsx as jsx23, jsxs as jsxs16 } from "react/jsx-runtime";
1189
1244
  function toTimeValue(date) {
1190
1245
  if (!date) return void 0;
1191
1246
  const hours = date.getHours();
@@ -1212,7 +1267,7 @@ function DateTimePicker({
1212
1267
  if (!date) return onApply?.(void 0);
1213
1268
  onApply?.(showTime ? combine(date, time ?? { hour: 12, minute: 0, period: "AM" }) : date);
1214
1269
  };
1215
- return /* @__PURE__ */ jsxs15(
1270
+ return /* @__PURE__ */ jsxs16(
1216
1271
  "div",
1217
1272
  {
1218
1273
  className: cn(
@@ -1220,14 +1275,14 @@ function DateTimePicker({
1220
1275
  className
1221
1276
  ),
1222
1277
  children: [
1223
- /* @__PURE__ */ jsxs15("div", { className: "flex items-center gap-6", children: [
1278
+ /* @__PURE__ */ jsxs16("div", { className: "flex items-center gap-6", children: [
1224
1279
  /* @__PURE__ */ jsx23(Calendar, { mode: "single", selected: date, onSelect: setDate, defaultMonth: date, ...calendarProps }),
1225
- showTime && /* @__PURE__ */ jsxs15(Fragment3, { children: [
1280
+ showTime && /* @__PURE__ */ jsxs16(Fragment3, { children: [
1226
1281
  /* @__PURE__ */ jsx23("div", { className: "h-70 w-px self-center bg-border", "aria-hidden": "true" }),
1227
1282
  /* @__PURE__ */ jsx23(TimePicker, { value: time, onValueChange: setTime, ...timePickerProps })
1228
1283
  ] })
1229
1284
  ] }),
1230
- /* @__PURE__ */ jsxs15("div", { className: "flex items-center justify-end gap-2", children: [
1285
+ /* @__PURE__ */ jsxs16("div", { className: "flex items-center justify-end gap-2", children: [
1231
1286
  /* @__PURE__ */ jsx23(
1232
1287
  Button,
1233
1288
  {
@@ -1253,8 +1308,8 @@ var DatePicker = React22.forwardRef(
1253
1308
  const [open, setOpen] = React22.useState(false);
1254
1309
  const [internal, setInternal] = React22.useState(defaultValue);
1255
1310
  const current = value ?? internal;
1256
- return /* @__PURE__ */ jsx23(Field, { label, className: cn("w-75", className), children: (control) => /* @__PURE__ */ jsxs15(PopoverPrimitive.Root, { open, onOpenChange: setOpen, children: [
1257
- /* @__PURE__ */ jsx23(PopoverPrimitive.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs15(
1311
+ return /* @__PURE__ */ jsx23(Field, { label, className: cn("w-75", className), children: (control) => /* @__PURE__ */ jsxs16(PopoverPrimitive.Root, { open, onOpenChange: setOpen, children: [
1312
+ /* @__PURE__ */ jsx23(PopoverPrimitive.Trigger, { asChild: true, children: /* @__PURE__ */ jsxs16(
1258
1313
  "button",
1259
1314
  {
1260
1315
  ref,
@@ -1387,7 +1442,7 @@ FormMessage.displayName = "FormMessage";
1387
1442
  // src/components/Forms & Data Entry/InlineEdit.tsx
1388
1443
  import * as React24 from "react";
1389
1444
  import { PencilSimple, WarningCircle as WarningCircle2 } from "@phosphor-icons/react";
1390
- import { Fragment as Fragment4, jsx as jsx25, jsxs as jsxs16 } from "react/jsx-runtime";
1445
+ import { Fragment as Fragment4, jsx as jsx25, jsxs as jsxs17 } from "react/jsx-runtime";
1391
1446
  function limitsText(min, max) {
1392
1447
  if (min !== void 0 && max !== void 0) return `${min}\u2013${max} characters`;
1393
1448
  if (min !== void 0) return `At least ${min} characters`;
@@ -1476,7 +1531,7 @@ var InlineEdit = React24.forwardRef(
1476
1531
  ref,
1477
1532
  className: cn(fill ? "flex w-full min-w-0" : "inline-flex min-w-0 max-w-full", editing && (error || showLimits) && "flex-col gap-1.5", className),
1478
1533
  ...props,
1479
- children: editing ? /* @__PURE__ */ jsxs16(Fragment4, { children: [
1534
+ children: editing ? /* @__PURE__ */ jsxs17(Fragment4, { children: [
1480
1535
  React24.createElement(multiline ? "textarea" : "input", {
1481
1536
  ref: fieldRef,
1482
1537
  value: draft,
@@ -1510,26 +1565,26 @@ var InlineEdit = React24.forwardRef(
1510
1565
  if (!cancelled.current) finish(true, false);
1511
1566
  }
1512
1567
  }),
1513
- (error || showLimits) && /* @__PURE__ */ jsxs16(
1568
+ (error || showLimits) && /* @__PURE__ */ jsxs17(
1514
1569
  "p",
1515
1570
  {
1516
1571
  id: errorId,
1517
1572
  role: error ? "alert" : void 0,
1518
1573
  className: cn("flex items-start justify-between gap-2 px-3 text-ui-caption", error ? "text-destructive" : "text-secondary-muted-foreground"),
1519
1574
  children: [
1520
- /* @__PURE__ */ jsxs16("span", { className: "flex items-start gap-2", children: [
1575
+ /* @__PURE__ */ jsxs17("span", { className: "flex items-start gap-2", children: [
1521
1576
  error && /* @__PURE__ */ jsx25(WarningCircle2, { size: 16, "aria-hidden": true, className: "shrink-0" }),
1522
1577
  showLimits ? limitsText(minLength, maxLength) : error,
1523
1578
  showLimits && error && /* @__PURE__ */ jsx25("span", { className: "sr-only", children: error })
1524
1579
  ] }),
1525
- showLimits && /* @__PURE__ */ jsxs16("span", { "aria-hidden": true, className: "shrink-0 tabular-nums", children: [
1580
+ showLimits && /* @__PURE__ */ jsxs17("span", { "aria-hidden": true, className: "shrink-0 tabular-nums", children: [
1526
1581
  draft.length,
1527
1582
  maxLength !== void 0 && `/${maxLength}`
1528
1583
  ] })
1529
1584
  ]
1530
1585
  }
1531
1586
  )
1532
- ] }) : /* @__PURE__ */ jsxs16(
1587
+ ] }) : /* @__PURE__ */ jsxs17(
1533
1588
  "button",
1534
1589
  {
1535
1590
  ref: readRef,
@@ -1597,9 +1652,9 @@ Input.displayName = "Input";
1597
1652
 
1598
1653
  // src/components/Forms & Data Entry/InputWithAction.tsx
1599
1654
  import * as React26 from "react";
1600
- import { jsx as jsx27, jsxs as jsxs17 } from "react/jsx-runtime";
1655
+ import { jsx as jsx27, jsxs as jsxs18 } from "react/jsx-runtime";
1601
1656
  var InputWithAction = React26.forwardRef(
1602
- ({ className, actionLabel, onAction, tags, status = "default", label, description, message, id, disabled, placeholder, ...props }, ref) => /* @__PURE__ */ jsx27(Field, { label, description, message, status, id, children: (control) => /* @__PURE__ */ jsxs17(
1657
+ ({ className, actionLabel, onAction, tags, status = "default", label, description, message, id, disabled, placeholder, ...props }, ref) => /* @__PURE__ */ jsx27(Field, { label, description, message, status, id, children: (control) => /* @__PURE__ */ jsxs18(
1603
1658
  "div",
1604
1659
  {
1605
1660
  className: cn(
@@ -1633,7 +1688,7 @@ InputWithAction.displayName = "InputWithAction";
1633
1688
  // src/components/Forms & Data Entry/NumberInput.tsx
1634
1689
  import * as React27 from "react";
1635
1690
  import { Minus as Minus2, Plus as Plus2 } from "@phosphor-icons/react";
1636
- import { jsx as jsx28, jsxs as jsxs18 } from "react/jsx-runtime";
1691
+ import { jsx as jsx28, jsxs as jsxs19 } from "react/jsx-runtime";
1637
1692
  var NumberInput = React27.forwardRef(
1638
1693
  ({
1639
1694
  className,
@@ -1660,7 +1715,7 @@ var NumberInput = React27.forwardRef(
1660
1715
  setInternal(clamped);
1661
1716
  onValueChange?.(clamped);
1662
1717
  };
1663
- return /* @__PURE__ */ jsx28(Field, { label, description, message, status, id, className: "w-50", children: (control) => /* @__PURE__ */ jsxs18(
1718
+ return /* @__PURE__ */ jsx28(Field, { label, description, message, status, id, className: "w-50", children: (control) => /* @__PURE__ */ jsxs19(
1664
1719
  "div",
1665
1720
  {
1666
1721
  className: cn(
@@ -1683,7 +1738,7 @@ var NumberInput = React27.forwardRef(
1683
1738
  children: /* @__PURE__ */ jsx28(Minus2, { size: 16, "aria-hidden": true })
1684
1739
  }
1685
1740
  ),
1686
- /* @__PURE__ */ jsxs18("div", { className: "flex items-center justify-center gap-1 text-center", children: [
1741
+ /* @__PURE__ */ jsxs19("div", { className: "flex items-center justify-center gap-1 text-center", children: [
1687
1742
  /* @__PURE__ */ jsx28(
1688
1743
  "input",
1689
1744
  {
@@ -1738,7 +1793,7 @@ NumberInput.displayName = "NumberInput";
1738
1793
  // src/components/Forms & Data Entry/SearchBar.tsx
1739
1794
  import * as React28 from "react";
1740
1795
  import { MagnifyingGlass, X as X2 } from "@phosphor-icons/react";
1741
- import { jsx as jsx29, jsxs as jsxs19 } from "react/jsx-runtime";
1796
+ import { jsx as jsx29, jsxs as jsxs20 } from "react/jsx-runtime";
1742
1797
  var SearchBar = React28.forwardRef(
1743
1798
  ({ className, value, defaultValue, onChange, onClear, clearLabel = "Clear search", disabled, ...props }, ref) => {
1744
1799
  const innerRef = React28.useRef(null);
@@ -1755,7 +1810,7 @@ var SearchBar = React28.forwardRef(
1755
1810
  }
1756
1811
  onClear?.();
1757
1812
  };
1758
- return /* @__PURE__ */ jsxs19(
1813
+ return /* @__PURE__ */ jsxs20(
1759
1814
  "div",
1760
1815
  {
1761
1816
  className: cn(
@@ -1805,13 +1860,13 @@ SearchBar.displayName = "SearchBar";
1805
1860
  import * as React29 from "react";
1806
1861
  import { CaretDown as CaretDown3 } from "@phosphor-icons/react";
1807
1862
  import { Select as SelectPrimitive } from "radix-ui";
1808
- import { jsx as jsx30, jsxs as jsxs20 } from "react/jsx-runtime";
1863
+ import { jsx as jsx30, jsxs as jsxs21 } from "react/jsx-runtime";
1809
1864
  var Select = SelectPrimitive.Root;
1810
1865
  var SelectValue = SelectPrimitive.Value;
1811
1866
  var SelectGroup = SelectPrimitive.Group;
1812
1867
  var CheckIcon = () => /* @__PURE__ */ jsx30("svg", { width: "10", height: "8", viewBox: "0 0 10 8", fill: "none", "aria-hidden": "true", children: /* @__PURE__ */ jsx30("path", { d: "M1 4L3.5 6.5L9 1", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
1813
1868
  var SelectTrigger = React29.forwardRef(
1814
- ({ className, children, icon, ...props }, ref) => /* @__PURE__ */ jsxs20(
1869
+ ({ className, children, icon, ...props }, ref) => /* @__PURE__ */ jsxs21(
1815
1870
  SelectPrimitive.Trigger,
1816
1871
  {
1817
1872
  ref,
@@ -1853,7 +1908,7 @@ var SelectContent = React29.forwardRef(
1853
1908
  );
1854
1909
  SelectContent.displayName = "SelectContent";
1855
1910
  var SelectItem = React29.forwardRef(
1856
- ({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs20(
1911
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ jsxs21(
1857
1912
  SelectPrimitive.Item,
1858
1913
  {
1859
1914
  ref,
@@ -1875,7 +1930,7 @@ SelectItem.displayName = "SelectItem";
1875
1930
  // src/components/Forms & Data Entry/Slider.tsx
1876
1931
  import * as React30 from "react";
1877
1932
  import { Slider as SliderPrimitive } from "radix-ui";
1878
- import { jsx as jsx31, jsxs as jsxs21 } from "react/jsx-runtime";
1933
+ import { jsx as jsx31, jsxs as jsxs22 } from "react/jsx-runtime";
1879
1934
  var Slider = React30.forwardRef(
1880
1935
  ({
1881
1936
  className,
@@ -1894,12 +1949,12 @@ var Slider = React30.forwardRef(
1894
1949
  const [internal, setInternal] = React30.useState(defaultValue ?? [min]);
1895
1950
  const thumbValues = value ?? internal;
1896
1951
  const hasHeader = label != null || showRange;
1897
- return /* @__PURE__ */ jsxs21("div", { className: cn("flex w-full flex-col gap-2", className), children: [
1898
- hasHeader && /* @__PURE__ */ jsxs21("div", { className: "flex items-center justify-between text-secondary-muted-foreground", children: [
1952
+ return /* @__PURE__ */ jsxs22("div", { className: cn("flex w-full flex-col gap-2", className), children: [
1953
+ hasHeader && /* @__PURE__ */ jsxs22("div", { className: "flex items-center justify-between text-secondary-muted-foreground", children: [
1899
1954
  label != null ? /* @__PURE__ */ jsx31("span", { className: "text-ui-label text-surface-foreground", children: label }) : /* @__PURE__ */ jsx31("span", { className: "text-ui-caption", children: min }),
1900
1955
  /* @__PURE__ */ jsx31("span", { className: "text-body-small", children: max })
1901
1956
  ] }),
1902
- /* @__PURE__ */ jsxs21(
1957
+ /* @__PURE__ */ jsxs22(
1903
1958
  SliderPrimitive.Root,
1904
1959
  {
1905
1960
  ref,
@@ -1980,12 +2035,12 @@ Textarea.displayName = "Textarea";
1980
2035
  import * as React32 from "react";
1981
2036
  import { X as X3 } from "@phosphor-icons/react";
1982
2037
  import { Dialog as DialogPrimitive } from "radix-ui";
1983
- import { jsx as jsx33, jsxs as jsxs22 } from "react/jsx-runtime";
2038
+ import { jsx as jsx33, jsxs as jsxs23 } from "react/jsx-runtime";
1984
2039
  var Dialog = DialogPrimitive.Root;
1985
2040
  var DialogTrigger = DialogPrimitive.Trigger;
1986
2041
  var DialogClose = DialogPrimitive.Close;
1987
2042
  var DialogContent = React32.forwardRef(
1988
- ({ className, children, closeLabel = "Close", hideClose, ...props }, ref) => /* @__PURE__ */ jsxs22(DialogPrimitive.Portal, { children: [
2043
+ ({ className, children, closeLabel = "Close", hideClose, ...props }, ref) => /* @__PURE__ */ jsxs23(DialogPrimitive.Portal, { children: [
1989
2044
  /* @__PURE__ */ jsx33(
1990
2045
  DialogPrimitive.Overlay,
1991
2046
  {
@@ -1993,7 +2048,7 @@ var DialogContent = React32.forwardRef(
1993
2048
  className: "fixed inset-0 bg-primary/30"
1994
2049
  }
1995
2050
  ),
1996
- /* @__PURE__ */ jsxs22(
2051
+ /* @__PURE__ */ jsxs23(
1997
2052
  DialogPrimitive.Content,
1998
2053
  {
1999
2054
  ref,
@@ -2039,7 +2094,7 @@ import * as React33 from "react";
2039
2094
  import { CheckCircle as CheckCircle2, Info, Warning, WarningCircle as WarningCircle3, X as X4 } from "@phosphor-icons/react";
2040
2095
  import { cva as cva4 } from "class-variance-authority";
2041
2096
  import { Toast as ToastPrimitive } from "radix-ui";
2042
- import { jsx as jsx34, jsxs as jsxs23 } from "react/jsx-runtime";
2097
+ import { jsx as jsx34, jsxs as jsxs24 } from "react/jsx-runtime";
2043
2098
  var toastVariants = cva4("border", {
2044
2099
  variants: {
2045
2100
  variant: {
@@ -2051,6 +2106,18 @@ var toastVariants = cva4("border", {
2051
2106
  },
2052
2107
  defaultVariants: { variant: "info" }
2053
2108
  });
2109
+ var inlineVariants = cva4("border", {
2110
+ variants: {
2111
+ variant: {
2112
+ neutral: "border-border bg-secondary",
2113
+ info: "border-info-border bg-surface",
2114
+ success: "border-success-soft-border bg-success-soft",
2115
+ warning: "border-warning-soft-border bg-warning-soft",
2116
+ destructive: "border-destructive-soft-border bg-destructive-soft"
2117
+ }
2118
+ },
2119
+ defaultVariants: { variant: "info" }
2120
+ });
2054
2121
  var iconColour = {
2055
2122
  info: "text-surface-foreground",
2056
2123
  success: "text-success-soft-foreground",
@@ -2084,7 +2151,7 @@ ToastViewport.displayName = "ToastViewport";
2084
2151
  var Toast = React33.forwardRef(
2085
2152
  ({ className, variant = "info", title, description, action, closeLabel = "Close", children, ...props }, ref) => {
2086
2153
  const v = variant ?? "info";
2087
- return /* @__PURE__ */ jsxs23(
2154
+ return /* @__PURE__ */ jsxs24(
2088
2155
  ToastPrimitive.Root,
2089
2156
  {
2090
2157
  ref,
@@ -2093,7 +2160,7 @@ var Toast = React33.forwardRef(
2093
2160
  ...props,
2094
2161
  children: [
2095
2162
  /* @__PURE__ */ jsx34(VariantIcon, { variant: v, size: 20 }),
2096
- /* @__PURE__ */ jsxs23("div", { className: "flex min-w-0 flex-1 flex-col gap-1 text-body-small", children: [
2163
+ /* @__PURE__ */ jsxs24("div", { className: "flex min-w-0 flex-1 flex-col gap-1 text-body-small", children: [
2097
2164
  title != null && /* @__PURE__ */ jsx34(ToastPrimitive.Title, { className: cn("font-semibold", titleColour[v]), children: title }),
2098
2165
  description != null && /* @__PURE__ */ jsx34(ToastPrimitive.Description, { className: "text-secondary-muted-foreground", children: description }),
2099
2166
  children,
@@ -2115,18 +2182,19 @@ var Toast = React33.forwardRef(
2115
2182
  Toast.displayName = "Toast";
2116
2183
  var ToastAction = ToastPrimitive.Action;
2117
2184
  var ToastInline = React33.forwardRef(
2118
- ({ className, variant = "info", onClose, closeLabel = "Close", children, ...props }, ref) => {
2185
+ ({ className, variant = "info", actions, onClose, closeLabel = "Close", children, ...props }, ref) => {
2119
2186
  const v = variant ?? "info";
2120
- return /* @__PURE__ */ jsxs23(
2187
+ return /* @__PURE__ */ jsxs24(
2121
2188
  "div",
2122
2189
  {
2123
2190
  ref,
2124
2191
  role: v === "destructive" ? "alert" : "status",
2125
- className: cn("flex items-center gap-2 rounded-sm px-2 py-1.5", toastVariants({ variant: v }), className),
2192
+ className: cn("flex items-center gap-2 rounded-sm px-2 py-1.5", inlineVariants({ variant: v }), className),
2126
2193
  ...props,
2127
2194
  children: [
2128
- /* @__PURE__ */ jsx34(VariantIcon, { variant: v, size: 16 }),
2195
+ /* @__PURE__ */ jsx34(VariantIcon, { variant: v === "neutral" ? "info" : v, size: 16 }),
2129
2196
  /* @__PURE__ */ jsx34("p", { className: "min-w-0 flex-1 text-body-small text-secondary-muted-foreground", children }),
2197
+ actions && /* @__PURE__ */ jsx34("div", { className: "flex shrink-0 items-center gap-2", children: actions }),
2130
2198
  onClose && /* @__PURE__ */ jsx34(Button, { type: "button", variant: "ghost", size: "icon-sm", "aria-label": closeLabel, onClick: onClose, children: /* @__PURE__ */ jsx34(X4, { size: 16, "aria-hidden": true }) })
2131
2199
  ]
2132
2200
  }
@@ -2138,14 +2206,14 @@ ToastInline.displayName = "ToastInline";
2138
2206
  // src/components/Overlays & Feedback/Tooltip.tsx
2139
2207
  import * as React34 from "react";
2140
2208
  import { Tooltip as TooltipPrimitive } from "radix-ui";
2141
- import { Fragment as Fragment5, jsx as jsx35, jsxs as jsxs24 } from "react/jsx-runtime";
2209
+ import { Fragment as Fragment5, jsx as jsx35, jsxs as jsxs25 } from "react/jsx-runtime";
2142
2210
  var TooltipProvider = TooltipPrimitive.Provider;
2143
2211
  var Tooltip = TooltipPrimitive.Root;
2144
2212
  var TooltipTrigger = TooltipPrimitive.Trigger;
2145
2213
  var TooltipContent = React34.forwardRef(
2146
2214
  ({ className, sideOffset = 4, title, description, action, arrow = true, children, ...props }, ref) => {
2147
2215
  const detailed = title != null || description != null;
2148
- return /* @__PURE__ */ jsx35(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsxs24(
2216
+ return /* @__PURE__ */ jsx35(TooltipPrimitive.Portal, { children: /* @__PURE__ */ jsxs25(
2149
2217
  TooltipPrimitive.Content,
2150
2218
  {
2151
2219
  ref,
@@ -2159,7 +2227,7 @@ var TooltipContent = React34.forwardRef(
2159
2227
  ),
2160
2228
  ...props,
2161
2229
  children: [
2162
- detailed ? /* @__PURE__ */ jsxs24(Fragment5, { children: [
2230
+ detailed ? /* @__PURE__ */ jsxs25(Fragment5, { children: [
2163
2231
  title != null && /* @__PURE__ */ jsx35("p", { className: "text-xs leading-4 font-semibold text-label", children: title }),
2164
2232
  description != null && /* @__PURE__ */ jsx35("p", { className: "text-xs leading-4.5 text-plum-200", children: description }),
2165
2233
  action != null && /* @__PURE__ */ jsx35("div", { className: "mt-1 text-ui-caption text-plum-300 underline *:underline", children: action })
@@ -2180,7 +2248,7 @@ import { Progress as ProgressPrimitive } from "radix-ui";
2180
2248
  // src/components/Tags & Badges/Tag.tsx
2181
2249
  import * as React35 from "react";
2182
2250
  import { cva as cva5 } from "class-variance-authority";
2183
- import { jsx as jsx36, jsxs as jsxs25 } from "react/jsx-runtime";
2251
+ import { jsx as jsx36, jsxs as jsxs26 } from "react/jsx-runtime";
2184
2252
  var tagVariants = cva5(
2185
2253
  "inline-flex items-center gap-1.5 whitespace-nowrap rounded-sm border px-2.5 py-1 text-ui-caption",
2186
2254
  {
@@ -2210,7 +2278,7 @@ var statusDotVariants = cva5("size-1.5 shrink-0 rounded-full", {
2210
2278
  defaultVariants: { status: "active" }
2211
2279
  });
2212
2280
  var StatusTag = React35.forwardRef(
2213
- ({ className, status, children, ...props }, ref) => /* @__PURE__ */ jsxs25("span", { ref, className: cn(tagVariants({ variant: "default" }), className), ...props, children: [
2281
+ ({ className, status, children, ...props }, ref) => /* @__PURE__ */ jsxs26("span", { ref, className: cn(tagVariants({ variant: "default" }), className), ...props, children: [
2214
2282
  /* @__PURE__ */ jsx36("span", { className: statusDotVariants({ status }), "aria-hidden": "true" }),
2215
2283
  children
2216
2284
  ] })
@@ -2218,11 +2286,11 @@ var StatusTag = React35.forwardRef(
2218
2286
  StatusTag.displayName = "StatusTag";
2219
2287
 
2220
2288
  // src/components/Question Types/FileUpload.tsx
2221
- import { Fragment as Fragment6, jsx as jsx37, jsxs as jsxs26 } from "react/jsx-runtime";
2289
+ import { Fragment as Fragment6, jsx as jsx37, jsxs as jsxs27 } from "react/jsx-runtime";
2222
2290
  var FileUploadZone = React36.forwardRef(
2223
2291
  ({ className, title = "Upload document", hint, icon, onFiles, ...props }, ref) => {
2224
2292
  const [over, setOver] = React36.useState(false);
2225
- return /* @__PURE__ */ jsxs26(
2293
+ return /* @__PURE__ */ jsxs27(
2226
2294
  "label",
2227
2295
  {
2228
2296
  className: cn(
@@ -2243,7 +2311,7 @@ var FileUploadZone = React36.forwardRef(
2243
2311
  },
2244
2312
  children: [
2245
2313
  /* @__PURE__ */ jsx37("span", { className: "flex size-10 items-center justify-center rounded-full bg-background bg-linear-to-r from-overlay-dark-5 to-overlay-dark-5 text-surface-foreground", children: icon ?? /* @__PURE__ */ jsx37(FileText, { size: 24, "aria-hidden": true }) }),
2246
- /* @__PURE__ */ jsxs26("span", { className: "flex flex-col gap-1", children: [
2314
+ /* @__PURE__ */ jsxs27("span", { className: "flex flex-col gap-1", children: [
2247
2315
  /* @__PURE__ */ jsx37("span", { className: "text-body-small text-surface-foreground", children: title }),
2248
2316
  hint && /* @__PURE__ */ jsx37("span", { className: "text-ui-caption text-secondary-muted-foreground", children: hint })
2249
2317
  ] }),
@@ -2266,31 +2334,31 @@ FileUploadZone.displayName = "FileUploadZone";
2266
2334
  var FileUploadItem = React36.forwardRef(
2267
2335
  ({ className, name, size, status = "uploading", progress = 0, timeLeft, icon, onRemove, removeLabel, ...props }, ref) => {
2268
2336
  const uploading = status === "uploading";
2269
- return /* @__PURE__ */ jsxs26(
2337
+ return /* @__PURE__ */ jsxs27(
2270
2338
  "div",
2271
2339
  {
2272
2340
  ref,
2273
2341
  className: cn("flex w-full flex-col justify-center gap-2 overflow-hidden rounded-sm border border-border p-2", className),
2274
2342
  ...props,
2275
2343
  children: [
2276
- /* @__PURE__ */ jsxs26("div", { className: "flex items-center gap-2", children: [
2344
+ /* @__PURE__ */ jsxs27("div", { className: "flex items-center gap-2", children: [
2277
2345
  /* @__PURE__ */ jsx37("span", { className: "flex size-10 shrink-0 items-center justify-center rounded-full bg-background bg-linear-to-r from-overlay-dark-5 to-overlay-dark-5 text-surface-foreground", children: icon ?? /* @__PURE__ */ jsx37(FileText, { size: 24, "aria-hidden": true }) }),
2278
- /* @__PURE__ */ jsxs26("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
2279
- /* @__PURE__ */ jsxs26("div", { className: "flex items-center justify-between gap-2", children: [
2346
+ /* @__PURE__ */ jsxs27("div", { className: "flex min-w-0 flex-1 flex-col gap-1", children: [
2347
+ /* @__PURE__ */ jsxs27("div", { className: "flex items-center justify-between gap-2", children: [
2280
2348
  /* @__PURE__ */ jsx37("p", { className: "min-w-0 truncate text-ui-label text-surface-foreground", children: name }),
2281
2349
  onRemove && /* @__PURE__ */ jsx37(Button, { type: "button", variant: "ghost", size: "icon-sm", "aria-label": removeLabel ?? `Remove ${name}`, onClick: onRemove, children: /* @__PURE__ */ jsx37(X5, { size: 16, "aria-hidden": true }) })
2282
2350
  ] }),
2283
- /* @__PURE__ */ jsxs26("div", { className: "flex items-center justify-between text-ui-caption text-secondary-muted-foreground", children: [
2284
- /* @__PURE__ */ jsxs26("span", { className: "flex items-center gap-2", children: [
2351
+ /* @__PURE__ */ jsxs27("div", { className: "flex items-center justify-between text-ui-caption text-secondary-muted-foreground", children: [
2352
+ /* @__PURE__ */ jsxs27("span", { className: "flex items-center gap-2", children: [
2285
2353
  size,
2286
2354
  status === "complete" && /* @__PURE__ */ jsx37(Tag, { variant: "success", children: "Complete" }),
2287
2355
  status === "error" && /* @__PURE__ */ jsx37(Tag, { variant: "destructive", children: "Error" }),
2288
- uploading && timeLeft && /* @__PURE__ */ jsxs26(Fragment6, { children: [
2356
+ uploading && timeLeft && /* @__PURE__ */ jsxs27(Fragment6, { children: [
2289
2357
  /* @__PURE__ */ jsx37("span", { "aria-hidden": "true", className: "size-0.5 rounded-full bg-secondary-muted-foreground" }),
2290
2358
  timeLeft
2291
2359
  ] })
2292
2360
  ] }),
2293
- uploading && /* @__PURE__ */ jsxs26("span", { className: "text-body-xxs font-normal", children: [
2361
+ uploading && /* @__PURE__ */ jsxs27("span", { className: "text-body-xxs font-normal", children: [
2294
2362
  Math.round(progress),
2295
2363
  "%"
2296
2364
  ] })
@@ -2317,12 +2385,12 @@ FileUploadItem.displayName = "FileUploadItem";
2317
2385
  import * as React37 from "react";
2318
2386
  import { CornersOut, DotsThree, Image as ImageIcon, Pause, Play, SpeakerSimpleHigh, SpeakerSimpleX, Trash as Trash2 } from "@phosphor-icons/react";
2319
2387
  import { Slider as SliderPrimitive2, ToggleGroup as ToggleGroupPrimitive2 } from "radix-ui";
2320
- import { jsx as jsx38, jsxs as jsxs27 } from "react/jsx-runtime";
2388
+ import { jsx as jsx38, jsxs as jsxs28 } from "react/jsx-runtime";
2321
2389
  function MediaInfo({ name, details, onRemove, removeLabel, large, className, ...props }) {
2322
- return /* @__PURE__ */ jsxs27("div", { className: cn("flex items-center justify-between border-t border-border bg-surface px-6 py-4", className), ...props, children: [
2323
- /* @__PURE__ */ jsxs27("div", { className: "flex min-w-0 flex-1 flex-col gap-2", children: [
2390
+ return /* @__PURE__ */ jsxs28("div", { className: cn("flex items-center justify-between border-t border-border bg-surface px-6 py-4", className), ...props, children: [
2391
+ /* @__PURE__ */ jsxs28("div", { className: "flex min-w-0 flex-1 flex-col gap-2", children: [
2324
2392
  /* @__PURE__ */ jsx38("p", { className: cn("truncate text-surface-foreground", large ? "text-body-section" : "text-ui-label"), children: name }),
2325
- details && /* @__PURE__ */ jsx38("p", { className: cn("flex items-center gap-2 text-secondary-muted-foreground", large ? "text-body-small" : "text-ui-caption"), children: details.map((part, index) => /* @__PURE__ */ jsxs27(React37.Fragment, { children: [
2393
+ details && /* @__PURE__ */ jsx38("p", { className: cn("flex items-center gap-2 text-secondary-muted-foreground", large ? "text-body-small" : "text-ui-caption"), children: details.map((part, index) => /* @__PURE__ */ jsxs28(React37.Fragment, { children: [
2326
2394
  index > 0 && /* @__PURE__ */ jsx38("span", { "aria-hidden": "true", className: "size-0.5 rounded-full bg-secondary-muted-foreground" }),
2327
2395
  part
2328
2396
  ] }, part)) })
@@ -2331,7 +2399,7 @@ function MediaInfo({ name, details, onRemove, removeLabel, large, className, ...
2331
2399
  ] });
2332
2400
  }
2333
2401
  var ImagePreview = React37.forwardRef(
2334
- ({ className, children, name, details, onRemove, ...props }, ref) => /* @__PURE__ */ jsxs27("div", { ref, className: cn("flex w-full flex-col overflow-hidden rounded-lg border border-border", className), ...props, children: [
2402
+ ({ className, children, name, details, onRemove, ...props }, ref) => /* @__PURE__ */ jsxs28("div", { ref, className: cn("flex w-full flex-col overflow-hidden rounded-lg border border-border", className), ...props, children: [
2335
2403
  /* @__PURE__ */ jsx38(
2336
2404
  "div",
2337
2405
  {
@@ -2407,8 +2475,8 @@ var VideoPlayer = React37.forwardRef(
2407
2475
  if (el.paused) void el.play();
2408
2476
  else el.pause();
2409
2477
  };
2410
- return /* @__PURE__ */ jsxs27("div", { ref, className: cn("flex w-full flex-col overflow-hidden rounded-lg border border-border bg-surface", className), ...props, children: [
2411
- /* @__PURE__ */ jsxs27("div", { className: "relative flex h-60.5 w-full items-end bg-accent-soft", children: [
2478
+ return /* @__PURE__ */ jsxs28("div", { ref, className: cn("flex w-full flex-col overflow-hidden rounded-lg border border-border bg-surface", className), ...props, children: [
2479
+ /* @__PURE__ */ jsxs28("div", { className: "relative flex h-60.5 w-full items-end bg-accent-soft", children: [
2412
2480
  src && /* @__PURE__ */ jsx38(
2413
2481
  "video",
2414
2482
  {
@@ -2422,8 +2490,8 @@ var VideoPlayer = React37.forwardRef(
2422
2490
  onVolumeChange: (event) => setVolume(event.currentTarget.muted ? 0 : event.currentTarget.volume)
2423
2491
  }
2424
2492
  ),
2425
- /* @__PURE__ */ jsxs27("div", { className: "relative flex w-full flex-col gap-2 bg-surface-foreground bg-linear-to-r from-primary/30 to-primary/30 px-4 pt-3 pb-4 text-surface", children: [
2426
- /* @__PURE__ */ jsxs27(
2493
+ /* @__PURE__ */ jsxs28("div", { className: "relative flex w-full flex-col gap-2 bg-surface-foreground bg-linear-to-r from-primary/30 to-primary/30 px-4 pt-3 pb-4 text-surface", children: [
2494
+ /* @__PURE__ */ jsxs28(
2427
2495
  SliderPrimitive2.Root,
2428
2496
  {
2429
2497
  min: 0,
@@ -2442,8 +2510,8 @@ var VideoPlayer = React37.forwardRef(
2442
2510
  ]
2443
2511
  }
2444
2512
  ),
2445
- /* @__PURE__ */ jsxs27("div", { className: "flex items-center justify-between", children: [
2446
- /* @__PURE__ */ jsxs27("div", { className: "flex items-center gap-4", children: [
2513
+ /* @__PURE__ */ jsxs28("div", { className: "flex items-center justify-between", children: [
2514
+ /* @__PURE__ */ jsxs28("div", { className: "flex items-center gap-4", children: [
2447
2515
  /* @__PURE__ */ jsx38(
2448
2516
  "button",
2449
2517
  {
@@ -2454,13 +2522,13 @@ var VideoPlayer = React37.forwardRef(
2454
2522
  children: playing ? /* @__PURE__ */ jsx38(Pause, { size: 16, weight: "fill", "aria-hidden": true }) : /* @__PURE__ */ jsx38(Play, { size: 16, weight: "fill", "aria-hidden": true })
2455
2523
  }
2456
2524
  ),
2457
- /* @__PURE__ */ jsxs27("span", { className: "text-ui-label whitespace-nowrap text-surface/80", children: [
2525
+ /* @__PURE__ */ jsxs28("span", { className: "text-ui-label whitespace-nowrap text-surface/80", children: [
2458
2526
  formatTime(time),
2459
2527
  " / ",
2460
2528
  formatTime(duration)
2461
2529
  ] })
2462
2530
  ] }),
2463
- /* @__PURE__ */ jsxs27("div", { className: "flex items-center gap-2", children: [
2531
+ /* @__PURE__ */ jsxs28("div", { className: "flex items-center gap-2", children: [
2464
2532
  /* @__PURE__ */ jsx38(
2465
2533
  VolumeControl,
2466
2534
  {
@@ -2507,8 +2575,8 @@ VideoPlayer.displayName = "VideoPlayer";
2507
2575
  function VolumeControl({ volume, onVolumeChange, className }) {
2508
2576
  const last = React37.useRef(volume || 1);
2509
2577
  if (volume > 0) last.current = volume;
2510
- return /* @__PURE__ */ jsxs27("div", { className: cn("group/volume flex items-center", className), children: [
2511
- /* @__PURE__ */ jsx38("div", { className: "w-0 overflow-hidden opacity-0 transition-all group-focus-within/volume:w-16 group-focus-within/volume:opacity-100 group-hover/volume:w-16 group-hover/volume:opacity-100", children: /* @__PURE__ */ jsxs27(
2578
+ return /* @__PURE__ */ jsxs28("div", { className: cn("group/volume flex items-center", className), children: [
2579
+ /* @__PURE__ */ jsx38("div", { className: "w-0 overflow-hidden opacity-0 transition-all group-focus-within/volume:w-16 group-focus-within/volume:opacity-100 group-hover/volume:w-16 group-hover/volume:opacity-100", children: /* @__PURE__ */ jsxs28(
2512
2580
  SliderPrimitive2.Root,
2513
2581
  {
2514
2582
  min: 0,
@@ -2592,7 +2660,7 @@ import {
2592
2660
  // src/components/Question Types/QuestionHeader.tsx
2593
2661
  import * as React40 from "react";
2594
2662
  import { DotsSixVertical } from "@phosphor-icons/react";
2595
- import { jsx as jsx41, jsxs as jsxs28 } from "react/jsx-runtime";
2663
+ import { jsx as jsx41, jsxs as jsxs29 } from "react/jsx-runtime";
2596
2664
  var eyebrow = "text-ui-caption uppercase text-secondary-muted-foreground";
2597
2665
  var QuestionHeader = React40.forwardRef(
2598
2666
  ({ className, number, title, required, error, onDismissError, editor, onTitleChange, actions, meta, maxLength = 2e3, active, showCounter = true, dragHandleProps, showDragHandle = true, ...props }, ref) => {
@@ -2602,10 +2670,10 @@ var QuestionHeader = React40.forwardRef(
2602
2670
  if (editor) {
2603
2671
  const text = typeof title === "string" ? title : "";
2604
2672
  const count = (draft ?? text).length;
2605
- return /* @__PURE__ */ jsxs28("div", { ref, className: cn("group/header flex w-full flex-col gap-2", className), ...props, children: [
2606
- /* @__PURE__ */ jsxs28("div", { className: "flex items-center justify-between", children: [
2607
- /* @__PURE__ */ jsxs28("div", { className: "flex items-center gap-2", children: [
2608
- /* @__PURE__ */ jsxs28(
2673
+ return /* @__PURE__ */ jsxs29("div", { ref, className: cn("group/header flex w-full flex-col gap-2", className), ...props, children: [
2674
+ /* @__PURE__ */ jsxs29("div", { className: "flex items-center justify-between", children: [
2675
+ /* @__PURE__ */ jsxs29("div", { className: "flex items-center gap-2", children: [
2676
+ /* @__PURE__ */ jsxs29(
2609
2677
  "span",
2610
2678
  {
2611
2679
  "aria-label": dragHandleProps ? `Reorder question ${number}` : void 0,
@@ -2660,7 +2728,7 @@ var QuestionHeader = React40.forwardRef(
2660
2728
  textClassName: "text-heading-h4"
2661
2729
  }
2662
2730
  ),
2663
- showCounter && /* @__PURE__ */ jsxs28("p", { className: "text-ui-caption text-secondary-muted-foreground", children: [
2731
+ showCounter && /* @__PURE__ */ jsxs29("p", { className: "text-ui-caption text-secondary-muted-foreground", children: [
2664
2732
  count,
2665
2733
  "/",
2666
2734
  maxLength,
@@ -2668,13 +2736,13 @@ var QuestionHeader = React40.forwardRef(
2668
2736
  ] })
2669
2737
  ] });
2670
2738
  }
2671
- return /* @__PURE__ */ jsxs28("div", { ref, className: cn("flex w-full flex-col gap-2", className), ...props, children: [
2739
+ return /* @__PURE__ */ jsxs29("div", { ref, className: cn("flex w-full flex-col gap-2", className), ...props, children: [
2672
2740
  showError && /* @__PURE__ */ jsx41(ToastInline, { variant: "destructive", onClose: onDismissError, className: "min-h-10", children: /* @__PURE__ */ jsx41("span", { className: "text-ui-label text-destructive", children: error === true ? "This question is mandatory." : error }) }),
2673
- /* @__PURE__ */ jsxs28("p", { className: eyebrow, children: [
2741
+ /* @__PURE__ */ jsxs29("p", { className: eyebrow, children: [
2674
2742
  "Question ",
2675
2743
  label
2676
2744
  ] }),
2677
- /* @__PURE__ */ jsxs28("h3", { className: "text-heading-h4 text-surface-foreground", children: [
2745
+ /* @__PURE__ */ jsxs29("h3", { className: "text-heading-h4 text-surface-foreground", children: [
2678
2746
  title,
2679
2747
  required && /* @__PURE__ */ jsx41("span", { "aria-hidden": "true", className: "text-destructive", children: "*" }),
2680
2748
  required && /* @__PURE__ */ jsx41("span", { className: "sr-only", children: " (required)" })
@@ -2685,7 +2753,7 @@ var QuestionHeader = React40.forwardRef(
2685
2753
  QuestionHeader.displayName = "QuestionHeader";
2686
2754
 
2687
2755
  // src/components/Question Types/QuestionEditorCard.tsx
2688
- import { Fragment as Fragment8, jsx as jsx42, jsxs as jsxs29 } from "react/jsx-runtime";
2756
+ import { Fragment as Fragment8, jsx as jsx42, jsxs as jsxs30 } from "react/jsx-runtime";
2689
2757
  var QuestionEditorCard = React41.forwardRef(
2690
2758
  ({
2691
2759
  className,
@@ -2712,7 +2780,7 @@ var QuestionEditorCard = React41.forwardRef(
2712
2780
  ...props
2713
2781
  }, ref) => {
2714
2782
  const footer = active && (countLabel != null || onAdd || onPaste);
2715
- return /* @__PURE__ */ jsxs29(
2783
+ return /* @__PURE__ */ jsxs30(
2716
2784
  "div",
2717
2785
  {
2718
2786
  ref,
@@ -2720,7 +2788,7 @@ var QuestionEditorCard = React41.forwardRef(
2720
2788
  "data-hovered": hovered ? "" : void 0,
2721
2789
  ...props,
2722
2790
  children: [
2723
- /* @__PURE__ */ jsxs29(
2791
+ /* @__PURE__ */ jsxs30(
2724
2792
  "div",
2725
2793
  {
2726
2794
  className: cn(
@@ -2728,8 +2796,8 @@ var QuestionEditorCard = React41.forwardRef(
2728
2796
  active ? "border-accent" : "border-border"
2729
2797
  ),
2730
2798
  children: [
2731
- /* @__PURE__ */ jsxs29("div", { className: cn("flex flex-col p-6", footer ? "gap-5" : "gap-4"), children: [
2732
- /* @__PURE__ */ jsxs29("div", { className: "flex flex-col gap-4", children: [
2799
+ /* @__PURE__ */ jsxs30("div", { className: cn("flex flex-col p-6", footer ? "gap-5" : "gap-4"), children: [
2800
+ /* @__PURE__ */ jsxs30("div", { className: "flex flex-col gap-4", children: [
2733
2801
  /* @__PURE__ */ jsx42(
2734
2802
  QuestionHeader,
2735
2803
  {
@@ -2743,7 +2811,7 @@ var QuestionEditorCard = React41.forwardRef(
2743
2811
  showDragHandle,
2744
2812
  meta,
2745
2813
  maxLength,
2746
- actions: actions ?? /* @__PURE__ */ jsxs29(Fragment8, { children: [
2814
+ actions: actions ?? /* @__PURE__ */ jsxs30(Fragment8, { children: [
2747
2815
  /* @__PURE__ */ jsx42(
2748
2816
  Button,
2749
2817
  {
@@ -2782,14 +2850,14 @@ var QuestionEditorCard = React41.forwardRef(
2782
2850
  ),
2783
2851
  children
2784
2852
  ] }),
2785
- error && /* @__PURE__ */ jsxs29("p", { className: "flex items-center gap-1 text-ui-caption text-destructive-foreground", children: [
2853
+ error && /* @__PURE__ */ jsxs30("p", { className: "flex items-center gap-1 text-ui-caption text-destructive-foreground", children: [
2786
2854
  /* @__PURE__ */ jsx42(Warning2, { size: 16, "aria-hidden": true, className: "shrink-0" }),
2787
2855
  error
2788
2856
  ] }),
2789
- footer && /* @__PURE__ */ jsxs29("div", { className: "flex items-center justify-between", children: [
2857
+ footer && /* @__PURE__ */ jsxs30("div", { className: "flex items-center justify-between", children: [
2790
2858
  /* @__PURE__ */ jsx42("p", { className: "text-ui-caption text-secondary-muted-foreground", children: countLabel }),
2791
- /* @__PURE__ */ jsxs29("div", { className: "flex items-center gap-2", children: [
2792
- onAdd && /* @__PURE__ */ jsxs29(Button, { type: "button", variant: "outline", onClick: onAdd, children: [
2859
+ /* @__PURE__ */ jsxs30("div", { className: "flex items-center gap-2", children: [
2860
+ onAdd && /* @__PURE__ */ jsxs30(Button, { type: "button", variant: "outline", onClick: onAdd, children: [
2793
2861
  /* @__PURE__ */ jsx42(Plus3, { size: 16, "aria-hidden": true }),
2794
2862
  "Add choice"
2795
2863
  ] }),
@@ -2854,11 +2922,11 @@ function QuestionTypeIcon({ type, size = 22.5, className, ...props }) {
2854
2922
  }
2855
2923
 
2856
2924
  // src/components/Question Types/QuestionNavItem.tsx
2857
- import { jsx as jsx44, jsxs as jsxs30 } from "react/jsx-runtime";
2925
+ import { jsx as jsx44, jsxs as jsxs31 } from "react/jsx-runtime";
2858
2926
  var QuestionNavItem = React43.forwardRef(
2859
2927
  ({ className, questionType = "select-one", selected, error, asChild, showDragHandle = true, hovered, children, ...props }, ref) => {
2860
2928
  const Comp = asChild ? Slot3.Root : "button";
2861
- return /* @__PURE__ */ jsxs30(
2929
+ return /* @__PURE__ */ jsxs31(
2862
2930
  Comp,
2863
2931
  {
2864
2932
  ref,
@@ -2877,7 +2945,7 @@ var QuestionNavItem = React43.forwardRef(
2877
2945
  ),
2878
2946
  ...props,
2879
2947
  children: [
2880
- /* @__PURE__ */ jsxs30("span", { "aria-hidden": "true", className: "relative flex size-4 shrink-0 items-center justify-center", children: [
2948
+ /* @__PURE__ */ jsxs31("span", { "aria-hidden": "true", className: "relative flex size-4 shrink-0 items-center justify-center", children: [
2881
2949
  showDragHandle && /* @__PURE__ */ jsx44(DotsSixVertical2, { size: 16, className: "hidden group-hover/nav:block group-data-[hovered]/nav:block" }),
2882
2950
  /* @__PURE__ */ jsx44("span", { className: showDragHandle ? "group-hover/nav:hidden group-data-[hovered]/nav:hidden" : void 0, children: error ? /* @__PURE__ */ jsx44(Warning3, { size: 16, className: "text-destructive-foreground" }) : /* @__PURE__ */ jsx44(
2883
2951
  QuestionTypeIcon,
@@ -2900,11 +2968,11 @@ QuestionNavItem.displayName = "QuestionNavItem";
2900
2968
  // src/components/Question Types/QuestionOption.tsx
2901
2969
  import * as React44 from "react";
2902
2970
  import { Check as Check4, DotsSixVertical as DotsSixVertical3, Plus as Plus4, Trash as Trash4 } from "@phosphor-icons/react";
2903
- import { Fragment as Fragment9, jsx as jsx45, jsxs as jsxs31 } from "react/jsx-runtime";
2971
+ import { Fragment as Fragment9, jsx as jsx45, jsxs as jsxs32 } from "react/jsx-runtime";
2904
2972
  var optionClasses = "flex w-full max-w-150 cursor-pointer items-center gap-2 rounded-md border border-border bg-surface px-4 py-2 text-body-base text-surface-foreground transition-colors hover:bg-accent-soft hover:shadow-md has-[[data-state=checked]]:border-accent-foreground has-[:disabled]:cursor-not-allowed has-[:disabled]:opacity-50";
2905
2973
  function QuestionOption(props) {
2906
2974
  const id = React44.useId();
2907
- return /* @__PURE__ */ jsxs31("label", { htmlFor: id, className: cn(optionClasses, props.className), children: [
2975
+ return /* @__PURE__ */ jsxs32("label", { htmlFor: id, className: cn(optionClasses, props.className), children: [
2908
2976
  props.kind === "checkbox" ? /* @__PURE__ */ jsx45(
2909
2977
  Checkbox,
2910
2978
  {
@@ -2923,7 +2991,7 @@ var QuestionOtherOption = React44.forwardRef(
2923
2991
  const inner = React44.useRef(null);
2924
2992
  React44.useImperativeHandle(ref, () => inner.current);
2925
2993
  const submit = () => onSubmit?.(inner.current?.value ?? "");
2926
- return /* @__PURE__ */ jsxs31(
2994
+ return /* @__PURE__ */ jsxs32(
2927
2995
  "div",
2928
2996
  {
2929
2997
  className: cn(
@@ -2962,8 +3030,8 @@ function QuestionOptionEditor({ label, onLabelChange, onRemove, onAdd, className
2962
3030
  className: cn("cursor-grab touch-none select-none", dragHandleProps.className)
2963
3031
  } : { "aria-hidden": true };
2964
3032
  const grip = dragHandleProps ? /* @__PURE__ */ jsx45("span", { ...gripProps, className: cn("shrink-0", gripProps.className), children: /* @__PURE__ */ jsx45(DotsSixVertical3, { size: 20, "aria-hidden": true, className: "text-surface-foreground" }) }) : /* @__PURE__ */ jsx45(DotsSixVertical3, { size: 20, "aria-hidden": true, className: "shrink-0 text-surface-foreground" });
2965
- return /* @__PURE__ */ jsxs31("div", { className: cn("group/option flex w-full items-center gap-2", className), children: [
2966
- /* @__PURE__ */ jsxs31(
3033
+ return /* @__PURE__ */ jsxs32("div", { className: cn("group/option flex w-full items-center gap-2", className), children: [
3034
+ /* @__PURE__ */ jsxs32(
2967
3035
  "div",
2968
3036
  {
2969
3037
  className: cn(
@@ -2974,7 +3042,7 @@ function QuestionOptionEditor({ label, onLabelChange, onRemove, onAdd, className
2974
3042
  ) : "border-border hover:border-input-muted hover:shadow-md"
2975
3043
  ),
2976
3044
  children: [
2977
- kind === "rank" ? /* @__PURE__ */ jsxs31(Fragment9, { children: [
3045
+ kind === "rank" ? /* @__PURE__ */ jsxs32(Fragment9, { children: [
2978
3046
  !locked && grip,
2979
3047
  /* @__PURE__ */ jsx45(
2980
3048
  "span",
@@ -2984,7 +3052,7 @@ function QuestionOptionEditor({ label, onLabelChange, onRemove, onAdd, className
2984
3052
  children: rank
2985
3053
  }
2986
3054
  )
2987
- ] }) : reveal && locked ? /* @__PURE__ */ jsx45("span", { "aria-hidden": "true", className: "relative flex size-5 shrink-0 items-center justify-center", children: /* @__PURE__ */ jsx45("span", { className: cn("inline-flex size-4 border-2 border-input bg-surface", kind === "radio" ? "rounded-full" : "rounded-xxs") }) }) : reveal ? /* @__PURE__ */ jsxs31("span", { ...gripProps, className: cn("relative flex size-5 shrink-0 items-center justify-center", gripProps.className), children: [
3055
+ ] }) : reveal && locked ? /* @__PURE__ */ jsx45("span", { "aria-hidden": "true", className: "relative flex size-5 shrink-0 items-center justify-center", children: /* @__PURE__ */ jsx45("span", { className: cn("inline-flex size-4 border-2 border-input bg-surface", kind === "radio" ? "rounded-full" : "rounded-xxs") }) }) : reveal ? /* @__PURE__ */ jsxs32("span", { ...gripProps, className: cn("relative flex size-5 shrink-0 items-center justify-center", gripProps.className), children: [
2988
3056
  /* @__PURE__ */ jsx45(
2989
3057
  "span",
2990
3058
  {
@@ -3020,7 +3088,7 @@ function QuestionOptionEditor({ label, onLabelChange, onRemove, onAdd, className
3020
3088
  ]
3021
3089
  }
3022
3090
  ),
3023
- !locked && /* @__PURE__ */ jsxs31(
3091
+ !locked && /* @__PURE__ */ jsxs32(
3024
3092
  "div",
3025
3093
  {
3026
3094
  className: cn(
@@ -3039,7 +3107,7 @@ function QuestionOptionEditor({ label, onLabelChange, onRemove, onAdd, className
3039
3107
  // src/components/Question Types/RankList.tsx
3040
3108
  import * as React45 from "react";
3041
3109
  import { DotsSixVertical as DotsSixVertical4 } from "@phosphor-icons/react";
3042
- import { Fragment as Fragment10, jsx as jsx46, jsxs as jsxs32 } from "react/jsx-runtime";
3110
+ import { Fragment as Fragment10, jsx as jsx46, jsxs as jsxs33 } from "react/jsx-runtime";
3043
3111
  function move(list, from, to) {
3044
3112
  if (from === to || to < 0 || to >= list.length) return list;
3045
3113
  const next = list.slice();
@@ -3066,8 +3134,8 @@ var RankList = React45.forwardRef(
3066
3134
  setAnnouncement(`Moved to position ${to + 1} of ${items.length}`);
3067
3135
  onItemsChange(next);
3068
3136
  };
3069
- return /* @__PURE__ */ jsxs32(Fragment10, { children: [
3070
- /* @__PURE__ */ jsx46("ol", { ref, className: cn("flex w-full max-w-150 flex-col gap-4", className), ...props, children: items.map((item, index) => /* @__PURE__ */ jsxs32(
3137
+ return /* @__PURE__ */ jsxs33(Fragment10, { children: [
3138
+ /* @__PURE__ */ jsx46("ol", { ref, className: cn("flex w-full max-w-150 flex-col gap-4", className), ...props, children: items.map((item, index) => /* @__PURE__ */ jsxs33(
3071
3139
  "li",
3072
3140
  {
3073
3141
  draggable: true,
@@ -3128,12 +3196,12 @@ RankList.displayName = "RankList";
3128
3196
  // src/components/Question Types/RatingScale.tsx
3129
3197
  import * as React46 from "react";
3130
3198
  import { ToggleGroup as ToggleGroupPrimitive3 } from "radix-ui";
3131
- import { jsx as jsx47, jsxs as jsxs33 } from "react/jsx-runtime";
3199
+ import { jsx as jsx47, jsxs as jsxs34 } from "react/jsx-runtime";
3132
3200
  var RatingScale = React46.forwardRef(
3133
3201
  ({ className, max = 5, value, defaultValue, onValueChange, lowLabel, highLabel, ...props }, ref) => {
3134
3202
  const [internal, setInternal] = React46.useState(defaultValue);
3135
3203
  const current = value !== void 0 ? value : internal;
3136
- return /* @__PURE__ */ jsxs33("div", { className: cn("flex w-full max-w-150 flex-col gap-2", className), children: [
3204
+ return /* @__PURE__ */ jsxs34("div", { className: cn("flex w-full max-w-150 flex-col gap-2", className), children: [
3137
3205
  /* @__PURE__ */ jsx47(
3138
3206
  ToggleGroupPrimitive3.Root,
3139
3207
  {
@@ -3163,7 +3231,7 @@ var RatingScale = React46.forwardRef(
3163
3231
  ))
3164
3232
  }
3165
3233
  ),
3166
- (lowLabel != null || highLabel != null) && /* @__PURE__ */ jsxs33("div", { className: "flex justify-between text-ui-caption text-secondary-muted-foreground", "aria-hidden": "true", children: [
3234
+ (lowLabel != null || highLabel != null) && /* @__PURE__ */ jsxs34("div", { className: "flex justify-between text-ui-caption text-secondary-muted-foreground", "aria-hidden": "true", children: [
3167
3235
  /* @__PURE__ */ jsx47("span", { children: lowLabel }),
3168
3236
  /* @__PURE__ */ jsx47("span", { children: highLabel })
3169
3237
  ] })
@@ -3175,7 +3243,7 @@ RatingScale.displayName = "RatingScale";
3175
3243
  // src/components/Question Types/StimulusCard.tsx
3176
3244
  import * as React47 from "react";
3177
3245
  import { Image as ImageIcon2, ImageBroken, Trash as Trash5 } from "@phosphor-icons/react";
3178
- import { jsx as jsx48, jsxs as jsxs34 } from "react/jsx-runtime";
3246
+ import { jsx as jsx48, jsxs as jsxs35 } from "react/jsx-runtime";
3179
3247
  var MIN_THUMBNAIL = 92;
3180
3248
  var MAX_THUMBNAIL = 240;
3181
3249
  var StimulusCard = React47.forwardRef(
@@ -3211,7 +3279,7 @@ var StimulusCard = React47.forwardRef(
3211
3279
  observer.observe(el);
3212
3280
  return () => observer.disconnect();
3213
3281
  }, []);
3214
- return /* @__PURE__ */ jsxs34(
3282
+ return /* @__PURE__ */ jsxs35(
3215
3283
  "div",
3216
3284
  {
3217
3285
  ref,
@@ -3219,7 +3287,7 @@ var StimulusCard = React47.forwardRef(
3219
3287
  className: cn("flex min-h-24.5 w-full items-center gap-4 rounded-md border border-border p-0.5 pr-4", className),
3220
3288
  ...props,
3221
3289
  children: [
3222
- /* @__PURE__ */ jsxs34("div", { className: "flex min-w-0 flex-1 items-center gap-4", children: [
3290
+ /* @__PURE__ */ jsxs35("div", { className: "flex min-w-0 flex-1 items-center gap-4", children: [
3223
3291
  /* @__PURE__ */ jsx48(
3224
3292
  "span",
3225
3293
  {
@@ -3235,7 +3303,7 @@ var StimulusCard = React47.forwardRef(
3235
3303
  ) : error ? /* @__PURE__ */ jsx48(ImageBroken, { size: 24, "aria-hidden": true }) : icon ?? /* @__PURE__ */ jsx48(ImageIcon2, { size: 24, "aria-hidden": true })
3236
3304
  }
3237
3305
  ),
3238
- /* @__PURE__ */ jsxs34("div", { ref: textRef, className: "flex min-w-0 flex-1 flex-col justify-center gap-2 py-2 text-surface-foreground", children: [
3306
+ /* @__PURE__ */ jsxs35("div", { ref: textRef, className: "flex min-w-0 flex-1 flex-col justify-center gap-2 py-2 text-surface-foreground", children: [
3239
3307
  /* @__PURE__ */ jsx48("p", { className: "w-full text-ui-label", children: label }),
3240
3308
  onCaptionChange ? /* @__PURE__ */ jsx48(
3241
3309
  InlineEdit,
@@ -3255,7 +3323,7 @@ var StimulusCard = React47.forwardRef(
3255
3323
  textClassName: "text-body-base"
3256
3324
  }
3257
3325
  ) : /* @__PURE__ */ jsx48("p", { className: "w-full text-body-base [word-break:break-word]", children: caption }),
3258
- onCaptionChange && showCounter && maxLength !== void 0 && /* @__PURE__ */ jsxs34("p", { className: "text-ui-caption text-secondary-muted-foreground", children: [
3326
+ onCaptionChange && showCounter && maxLength !== void 0 && /* @__PURE__ */ jsxs35("p", { className: "text-ui-caption text-secondary-muted-foreground", children: [
3259
3327
  count,
3260
3328
  "/",
3261
3329
  maxLength,
@@ -3274,14 +3342,14 @@ StimulusCard.displayName = "StimulusCard";
3274
3342
  // src/components/Data Display/Progress.tsx
3275
3343
  import * as React48 from "react";
3276
3344
  import { Progress as ProgressPrimitive2 } from "radix-ui";
3277
- import { jsx as jsx49, jsxs as jsxs35 } from "react/jsx-runtime";
3345
+ import { jsx as jsx49, jsxs as jsxs36 } from "react/jsx-runtime";
3278
3346
  var Progress = React48.forwardRef(
3279
3347
  ({ className, value = 0, label, valueLabel, detailsStart, detailsEnd, ...props }, ref) => {
3280
3348
  const hasHeader = label != null || valueLabel != null;
3281
3349
  const hasDetails = detailsStart != null || detailsEnd != null;
3282
3350
  const clamped = Math.min(100, Math.max(0, value ?? 0));
3283
- return /* @__PURE__ */ jsxs35("div", { className: cn("flex w-full flex-col gap-2", className), children: [
3284
- hasHeader && /* @__PURE__ */ jsxs35("div", { className: "flex items-center justify-between text-ui-label text-surface-foreground", children: [
3351
+ return /* @__PURE__ */ jsxs36("div", { className: cn("flex w-full flex-col gap-2", className), children: [
3352
+ hasHeader && /* @__PURE__ */ jsxs36("div", { className: "flex items-center justify-between text-ui-label text-surface-foreground", children: [
3285
3353
  /* @__PURE__ */ jsx49("span", { children: label }),
3286
3354
  /* @__PURE__ */ jsx49("span", { children: valueLabel === true ? `${Math.round(clamped)}%` : valueLabel })
3287
3355
  ] }),
@@ -3301,7 +3369,7 @@ var Progress = React48.forwardRef(
3301
3369
  )
3302
3370
  }
3303
3371
  ),
3304
- hasDetails && /* @__PURE__ */ jsxs35("div", { className: "flex items-start justify-between text-ui-label leading-5 text-secondary-muted-foreground", children: [
3372
+ hasDetails && /* @__PURE__ */ jsxs36("div", { className: "flex items-start justify-between text-ui-label leading-5 text-secondary-muted-foreground", children: [
3305
3373
  /* @__PURE__ */ jsx49("span", { children: detailsStart }),
3306
3374
  /* @__PURE__ */ jsx49("span", { children: detailsEnd })
3307
3375
  ] })
@@ -3313,7 +3381,7 @@ Progress.displayName = "Progress";
3313
3381
  // src/components/Data Display/Table.tsx
3314
3382
  import * as React49 from "react";
3315
3383
  import { CaretDown as CaretDown4, CaretUp } from "@phosphor-icons/react";
3316
- import { jsx as jsx50, jsxs as jsxs36 } from "react/jsx-runtime";
3384
+ import { jsx as jsx50, jsxs as jsxs37 } from "react/jsx-runtime";
3317
3385
  var Table = React49.forwardRef(
3318
3386
  ({ className, containerClassName, striped, ...props }, ref) => /* @__PURE__ */ jsx50("div", { className: cn("relative w-full overflow-auto rounded-lg border border-border bg-surface", containerClassName), children: /* @__PURE__ */ jsx50(
3319
3387
  "table",
@@ -3368,7 +3436,7 @@ var TableHead = React49.forwardRef(
3368
3436
  className
3369
3437
  ),
3370
3438
  ...props,
3371
- children: sortable ? /* @__PURE__ */ jsxs36(
3439
+ children: sortable ? /* @__PURE__ */ jsxs37(
3372
3440
  "button",
3373
3441
  {
3374
3442
  type: "button",
@@ -3405,9 +3473,9 @@ var TableCell = React49.forwardRef(
3405
3473
  );
3406
3474
  TableCell.displayName = "TableCell";
3407
3475
  function TableCellTwoLines({ primary, secondary, avatar, className, ...props }) {
3408
- return /* @__PURE__ */ jsxs36("div", { className: cn("flex items-center gap-2", className), ...props, children: [
3476
+ return /* @__PURE__ */ jsxs37("div", { className: cn("flex items-center gap-2", className), ...props, children: [
3409
3477
  avatar,
3410
- /* @__PURE__ */ jsxs36("div", { className: "flex flex-col gap-0.5 whitespace-nowrap", children: [
3478
+ /* @__PURE__ */ jsxs37("div", { className: "flex flex-col gap-0.5 whitespace-nowrap", children: [
3411
3479
  /* @__PURE__ */ jsx50("span", { className: "text-ui-label text-surface-foreground", children: primary }),
3412
3480
  secondary && /* @__PURE__ */ jsx50("span", { className: "text-ui-caption text-secondary-muted-foreground", children: secondary })
3413
3481
  ] })
@@ -3417,7 +3485,7 @@ function TableCellTwoLines({ primary, secondary, avatar, className, ...props })
3417
3485
  // src/components/Data Display/StatCard.tsx
3418
3486
  import * as React50 from "react";
3419
3487
  import { cva as cva6 } from "class-variance-authority";
3420
- import { jsx as jsx51, jsxs as jsxs37 } from "react/jsx-runtime";
3488
+ import { jsx as jsx51, jsxs as jsxs38 } from "react/jsx-runtime";
3421
3489
  var statCardVariants = cva6("flex min-w-0 flex-col gap-2 rounded-md border p-3", {
3422
3490
  variants: {
3423
3491
  variant: {
@@ -3432,9 +3500,9 @@ var statCardVariants = cva6("flex min-w-0 flex-col gap-2 rounded-md border p-3",
3432
3500
  defaultVariants: { variant: "default" }
3433
3501
  });
3434
3502
  var StatCard = React50.forwardRef(
3435
- ({ className, variant, label, value, icon, ...props }, ref) => /* @__PURE__ */ jsxs37("div", { ref, className: cn(statCardVariants({ variant }), className), ...props, children: [
3503
+ ({ className, variant, label, value, icon, ...props }, ref) => /* @__PURE__ */ jsxs38("div", { ref, className: cn(statCardVariants({ variant }), className), ...props, children: [
3436
3504
  /* @__PURE__ */ jsx51("p", { className: "truncate text-ui-caption text-secondary-muted-foreground", children: label }),
3437
- /* @__PURE__ */ jsxs37("p", { className: "flex items-center gap-2 text-body-base text-surface-foreground", children: [
3505
+ /* @__PURE__ */ jsxs38("p", { className: "flex items-center gap-2 text-body-base text-surface-foreground", children: [
3438
3506
  icon && /* @__PURE__ */ jsx51("span", { "aria-hidden": "true", className: "inline-flex size-6 shrink-0 items-center justify-center", children: icon }),
3439
3507
  value
3440
3508
  ] })
@@ -3449,7 +3517,7 @@ import * as React52 from "react";
3449
3517
  import * as React51 from "react";
3450
3518
  import { Crown, Plus as Plus5, X as X6 } from "@phosphor-icons/react";
3451
3519
  import { cva as cva7 } from "class-variance-authority";
3452
- import { jsx as jsx52, jsxs as jsxs38 } from "react/jsx-runtime";
3520
+ import { jsx as jsx52, jsxs as jsxs39 } from "react/jsx-runtime";
3453
3521
  var editableTagVariants = cva7(
3454
3522
  "inline-flex h-6.5 items-center whitespace-nowrap rounded-sm py-1 text-ui-caption transition-colors",
3455
3523
  {
@@ -3469,12 +3537,12 @@ var EditableTag = React51.forwardRef(
3469
3537
  const classes = cn(editableTagVariants({ type }), className);
3470
3538
  const leading = type === "add" ? /* @__PURE__ */ jsx52(Plus5, { size: 12, "aria-hidden": true }) : icon !== void 0 ? icon : type === "default" ? /* @__PURE__ */ jsx52(Crown, { size: 12, weight: "fill", "aria-hidden": true }) : null;
3471
3539
  if (type === "add" || type === "multiple" && onClick) {
3472
- return /* @__PURE__ */ jsxs38("button", { ref, type: "button", className: classes, onClick, ...props, children: [
3540
+ return /* @__PURE__ */ jsxs39("button", { ref, type: "button", className: classes, onClick, ...props, children: [
3473
3541
  leading,
3474
3542
  children
3475
3543
  ] });
3476
3544
  }
3477
- return /* @__PURE__ */ jsxs38("span", { ref, className: classes, ...props, children: [
3545
+ return /* @__PURE__ */ jsxs39("span", { ref, className: classes, ...props, children: [
3478
3546
  leading,
3479
3547
  children,
3480
3548
  onRemove && /* @__PURE__ */ jsx52(
@@ -3493,24 +3561,24 @@ var EditableTag = React51.forwardRef(
3493
3561
  EditableTag.displayName = "EditableTag";
3494
3562
 
3495
3563
  // src/components/Research-Specific/ActivityStructure.tsx
3496
- import { jsx as jsx53, jsxs as jsxs39 } from "react/jsx-runtime";
3564
+ import { jsx as jsx53, jsxs as jsxs40 } from "react/jsx-runtime";
3497
3565
  var ActivityStructure = React52.forwardRef(
3498
- ({ className, title = "Activity Structure", stats, sections, onRemoveTag, onAddTag, addTagLabel = "Add tag", action, children, ...props }, ref) => /* @__PURE__ */ jsxs39(
3566
+ ({ className, title = "Activity Structure", stats, sections, onRemoveTag, onAddTag, addTagLabel = "Add tag", action, children, ...props }, ref) => /* @__PURE__ */ jsxs40(
3499
3567
  "section",
3500
3568
  {
3501
3569
  ref,
3502
3570
  className: cn("flex w-full max-w-96.5 flex-col gap-4 rounded-xl bg-surface p-4", className),
3503
3571
  ...props,
3504
3572
  children: [
3505
- /* @__PURE__ */ jsxs39("div", { className: "flex items-center justify-between gap-2", children: [
3573
+ /* @__PURE__ */ jsxs40("div", { className: "flex items-center justify-between gap-2", children: [
3506
3574
  /* @__PURE__ */ jsx53("h3", { className: "text-body-section text-surface-foreground", children: title }),
3507
3575
  action
3508
3576
  ] }),
3509
3577
  stats.length > 0 && /* @__PURE__ */ jsx53("div", { className: "grid grid-cols-2 gap-3", children: stats.map(({ id, ...stat }) => /* @__PURE__ */ jsx53(StatCard, { ...stat }, id)) }),
3510
- sections?.map(({ id, heading, body, tags }) => /* @__PURE__ */ jsxs39("div", { className: "flex flex-col gap-2", children: [
3578
+ sections?.map(({ id, heading, body, tags }) => /* @__PURE__ */ jsxs40("div", { className: "flex flex-col gap-2", children: [
3511
3579
  /* @__PURE__ */ jsx53("h4", { className: "text-heading-h4 text-surface-foreground", children: heading }),
3512
3580
  /* @__PURE__ */ jsx53("div", { className: "text-body-base text-surface-foreground", children: body }),
3513
- (tags?.length || onAddTag) && /* @__PURE__ */ jsxs39("div", { className: "flex flex-wrap items-center gap-2", children: [
3581
+ (tags?.length || onAddTag) && /* @__PURE__ */ jsxs40("div", { className: "flex flex-wrap items-center gap-2", children: [
3514
3582
  tags?.map((tag) => /* @__PURE__ */ jsx53(EditableTag, { type: "editable", onRemove: onRemoveTag && (() => onRemoveTag(id, tag)), children: tag }, tag)),
3515
3583
  onAddTag && /* @__PURE__ */ jsx53(EditableTag, { type: "add", onClick: () => onAddTag(id), children: addTagLabel })
3516
3584
  ] })
@@ -3526,7 +3594,7 @@ ActivityStructure.displayName = "ActivityStructure";
3526
3594
  import * as React53 from "react";
3527
3595
  import { DotsSixVertical as DotsSixVertical5, RadioButton as RadioButton2 } from "@phosphor-icons/react";
3528
3596
  import { cva as cva8 } from "class-variance-authority";
3529
- import { jsx as jsx54, jsxs as jsxs40 } from "react/jsx-runtime";
3597
+ import { jsx as jsx54, jsxs as jsxs41 } from "react/jsx-runtime";
3530
3598
  var roleTagVariants = cva8(
3531
3599
  "group inline-flex h-6 items-center whitespace-nowrap rounded-sm py-1 text-ui-caption transition-colors",
3532
3600
  {
@@ -3556,7 +3624,7 @@ var Badge = React53.forwardRef(
3556
3624
  ({ className, type = "primary", selected = false, onClick, children, ...props }, ref) => {
3557
3625
  const classes = cn(roleTagVariants({ type, selected: type === "interactable" ? selected : false }), className);
3558
3626
  if (type === "interactable") {
3559
- return /* @__PURE__ */ jsxs40(
3627
+ return /* @__PURE__ */ jsxs41(
3560
3628
  "button",
3561
3629
  {
3562
3630
  ref,
@@ -3572,7 +3640,7 @@ var Badge = React53.forwardRef(
3572
3640
  }
3573
3641
  );
3574
3642
  }
3575
- return /* @__PURE__ */ jsxs40("span", { ref, className: classes, ...props, children: [
3643
+ return /* @__PURE__ */ jsxs41("span", { ref, className: classes, ...props, children: [
3576
3644
  type === "question" && /* @__PURE__ */ jsx54(RadioButton2, { size: 16, weight: "fill", "aria-hidden": true }),
3577
3645
  type === "id" && /* @__PURE__ */ jsx54("span", { className: "text-secondary-muted-foreground", children: "ID" }),
3578
3646
  children
@@ -3584,7 +3652,7 @@ Badge.displayName = "Badge";
3584
3652
  // src/components/Utility/Pagination.tsx
3585
3653
  import * as React54 from "react";
3586
3654
  import { ArrowLeft, ArrowRight, DotsThree as DotsThree2 } from "@phosphor-icons/react";
3587
- import { jsx as jsx55, jsxs as jsxs41 } from "react/jsx-runtime";
3655
+ import { jsx as jsx55, jsxs as jsxs42 } from "react/jsx-runtime";
3588
3656
  function getPaginationItems(page, pageCount, siblings = 1) {
3589
3657
  const keep = /* @__PURE__ */ new Set([1, pageCount]);
3590
3658
  for (let p = page - siblings; p <= page + siblings; p++) if (p >= 1 && p <= pageCount) keep.add(p);
@@ -3625,7 +3693,7 @@ var Pagination = React54.forwardRef(
3625
3693
  children: /* @__PURE__ */ jsx55(ArrowRight, { size: 16, "aria-hidden": true })
3626
3694
  }
3627
3695
  );
3628
- return /* @__PURE__ */ jsxs41(
3696
+ return /* @__PURE__ */ jsxs42(
3629
3697
  "nav",
3630
3698
  {
3631
3699
  ref,
@@ -3634,11 +3702,11 @@ var Pagination = React54.forwardRef(
3634
3702
  ...props,
3635
3703
  children: [
3636
3704
  previous,
3637
- variant === "compact" ? /* @__PURE__ */ jsxs41("span", { className: "text-body-small text-surface-foreground", "aria-live": "polite", children: [
3705
+ variant === "compact" ? /* @__PURE__ */ jsxs42("span", { className: "text-body-small text-surface-foreground", "aria-live": "polite", children: [
3638
3706
  page,
3639
3707
  "/",
3640
3708
  pageCount
3641
- ] }) : /* @__PURE__ */ jsx55("ul", { className: "flex items-center gap-2", children: getPaginationItems(page, pageCount, siblings).map((item, index) => /* @__PURE__ */ jsx55("li", { children: item === "ellipsis" ? /* @__PURE__ */ jsxs41("span", { className: "inline-flex size-8 items-center justify-center rounded-sm border border-border bg-surface text-surface-foreground", children: [
3709
+ ] }) : /* @__PURE__ */ jsx55("ul", { className: "flex items-center gap-2", children: getPaginationItems(page, pageCount, siblings).map((item, index) => /* @__PURE__ */ jsx55("li", { children: item === "ellipsis" ? /* @__PURE__ */ jsxs42("span", { className: "inline-flex size-8 items-center justify-center rounded-sm border border-border bg-surface text-surface-foreground", children: [
3642
3710
  /* @__PURE__ */ jsx55(DotsThree2, { size: 16, "aria-hidden": true }),
3643
3711
  /* @__PURE__ */ jsx55("span", { className: "sr-only", children: "More pages" })
3644
3712
  ] }) : /* @__PURE__ */ jsx55(