@arbidocs/blocks 0.3.137 → 0.3.139

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.cjs CHANGED
@@ -1,13 +1,13 @@
1
1
  'use strict';
2
2
 
3
- var chunkAHWIZJ4M_cjs = require('./chunk-AHWIZJ4M.cjs');
3
+ var chunk6MFI2HPX_cjs = require('./chunk-6MFI2HPX.cjs');
4
4
  var react$1 = require('react');
5
+ var lucideReact = require('lucide-react');
5
6
  var react = require('@arbidocs/react');
6
7
  var jsxRuntime = require('react/jsx-runtime');
7
8
  var reactQuery = require('@tanstack/react-query');
8
9
  var agGridReact = require('ag-grid-react');
9
10
  var agGridCommunity = require('ag-grid-community');
10
- var lucideReact = require('lucide-react');
11
11
  var reactRouterDom = require('react-router-dom');
12
12
  var puck = require('@measured/puck');
13
13
  var zustand = require('zustand');
@@ -194,6 +194,170 @@ Lead with why the firm is the right choice, reference relevant experience at a t
194
194
  ];
195
195
  return { prompts, WORKFLOW_ACTIONS };
196
196
  }
197
+ function CitationEditor({
198
+ value,
199
+ citations,
200
+ onChange,
201
+ activeCitationKey,
202
+ onCiteDocument,
203
+ citedDocs,
204
+ renderDocumentPicker,
205
+ autoFocus = false,
206
+ "data-testid": dataTestId,
207
+ placeholder = "Add a note...",
208
+ readOnly = false,
209
+ className,
210
+ defaultHeight,
211
+ onHeightChange
212
+ }) {
213
+ const [localValue, setLocalValue] = react$1.useState(value);
214
+ const [isEditing, setIsEditing] = react$1.useState(autoFocus);
215
+ const textareaRef = react$1.useRef(null);
216
+ const debounceRef = react$1.useRef(null);
217
+ react$1.useEffect(() => {
218
+ if (!isEditing) {
219
+ setLocalValue(value);
220
+ }
221
+ }, [value, isEditing]);
222
+ const passages = react$1.useMemo(() => citations?.passages ?? [], [citations]);
223
+ const hasCitations = passages.length > 0;
224
+ const byDoc = react$1.useMemo(() => {
225
+ const groups = /* @__PURE__ */ new Map();
226
+ for (const passage of passages) {
227
+ if (!passage.doc_ext_id) continue;
228
+ const group = groups.get(passage.doc_ext_id) ?? { pages: [], count: 0 };
229
+ group.count += 1;
230
+ if (passage.page != null && !group.pages.includes(passage.page))
231
+ group.pages.push(passage.page);
232
+ groups.set(passage.doc_ext_id, group);
233
+ }
234
+ return groups;
235
+ }, [passages]);
236
+ const docIds = Array.from(byDoc.keys());
237
+ const handleRemoveDocument = react$1.useCallback(
238
+ (docExtId) => {
239
+ const remaining = passages.filter((p) => p.doc_ext_id !== docExtId);
240
+ onChange(localValue, remaining.length ? { passages: remaining } : null);
241
+ },
242
+ [passages, localValue, onChange]
243
+ );
244
+ const handleToggleDocument = react$1.useCallback(
245
+ (docExtId) => {
246
+ if (!docExtId) return;
247
+ if (docIds.includes(docExtId)) {
248
+ handleRemoveDocument(docExtId);
249
+ return;
250
+ }
251
+ onCiteDocument?.(docExtId);
252
+ },
253
+ [docIds, onCiteDocument, handleRemoveDocument]
254
+ );
255
+ const renderedContent = react$1.useMemo(
256
+ () => localValue ? /* @__PURE__ */ jsxRuntime.jsx("span", { children: localValue }) : null,
257
+ [localValue]
258
+ );
259
+ const handleChange = react$1.useCallback(
260
+ (newValue) => {
261
+ setLocalValue(newValue);
262
+ if (debounceRef.current) clearTimeout(debounceRef.current);
263
+ debounceRef.current = setTimeout(() => onChange(newValue, citations ?? null), 400);
264
+ },
265
+ [citations, onChange]
266
+ );
267
+ const flushPendingChange = react$1.useCallback(() => {
268
+ if (!debounceRef.current) return;
269
+ clearTimeout(debounceRef.current);
270
+ debounceRef.current = null;
271
+ onChange(localValue, citations ?? null);
272
+ }, [localValue, citations, onChange]);
273
+ return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: react.cn("space-y-1", className), children: [
274
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative", children: isEditing ? /* @__PURE__ */ jsxRuntime.jsx(
275
+ "textarea",
276
+ {
277
+ ref: textareaRef,
278
+ value: localValue,
279
+ onChange: (e) => handleChange(e.target.value),
280
+ onBlur: () => {
281
+ flushPendingChange();
282
+ setIsEditing(false);
283
+ },
284
+ onMouseUp: () => {
285
+ if (textareaRef.current && onHeightChange) {
286
+ onHeightChange(textareaRef.current.offsetHeight);
287
+ }
288
+ },
289
+ placeholder,
290
+ readOnly,
291
+ rows: 2,
292
+ "data-testid": dataTestId,
293
+ autoFocus: true,
294
+ style: defaultHeight ? { height: defaultHeight } : void 0,
295
+ className: "w-full text-sm p-2 pr-14 border border-border rounded-md resize-y bg-background focus:outline-none focus:ring-2 focus:ring-ring"
296
+ }
297
+ ) : /* @__PURE__ */ jsxRuntime.jsx(
298
+ "div",
299
+ {
300
+ onClick: () => !readOnly && setIsEditing(true),
301
+ style: defaultHeight ? { minHeight: defaultHeight } : void 0,
302
+ "data-testid": dataTestId,
303
+ className: react.cn(
304
+ "w-full text-sm p-2 pr-14 border border-border rounded-md min-h-[4rem] whitespace-pre-wrap bg-background",
305
+ !readOnly && "cursor-text hover:border-ring",
306
+ !localValue && "text-muted-foreground"
307
+ ),
308
+ children: renderedContent || placeholder
309
+ }
310
+ ) }),
311
+ (hasCitations || !readOnly) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1", children: [
312
+ docIds.map((docId) => {
313
+ const doc = citedDocs?.[docId];
314
+ const group = byDoc.get(docId);
315
+ const pages = (group?.pages ?? []).slice().sort((a, b) => a - b);
316
+ return /* @__PURE__ */ jsxRuntime.jsxs(
317
+ "div",
318
+ {
319
+ className: "flex items-center gap-1.5 text-sm",
320
+ "data-testid": `citation-doc-${docId}`,
321
+ children: [
322
+ doc ? /* @__PURE__ */ jsxRuntime.jsx(
323
+ "button",
324
+ {
325
+ type: "button",
326
+ onClick: () => !readOnly && onCiteDocument?.(docId),
327
+ className: "flex-1 min-w-0 text-left",
328
+ title: "Open to tag more passages",
329
+ children: /* @__PURE__ */ jsxRuntime.jsx(react.DocumentEntity, { doc, fullWidth: true, labelMaxWidth: "max-w-full" })
330
+ }
331
+ ) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: docId }),
332
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground shrink-0", children: chunk6MFI2HPX_cjs.formatPageRefs(pages) }),
333
+ !readOnly && /* @__PURE__ */ jsxRuntime.jsx(
334
+ "button",
335
+ {
336
+ type: "button",
337
+ onClick: () => handleRemoveDocument(docId),
338
+ "aria-label": "Remove this document",
339
+ className: "p-0.5 hover:bg-destructive/20 hover:text-destructive rounded shrink-0",
340
+ children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { size: 12 })
341
+ }
342
+ )
343
+ ]
344
+ },
345
+ docId
346
+ );
347
+ }),
348
+ passages.some((p) => !p.doc_ext_id) && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm text-muted-foreground", children: [
349
+ passages.filter((p) => !p.doc_ext_id).length,
350
+ " passage(s) without a recorded document"
351
+ ] }),
352
+ !readOnly && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-1", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-w-0", "data-testid": "citation-document-picker", children: renderDocumentPicker?.(handleToggleDocument, docIds) }) })
353
+ ] }),
354
+ activeCitationKey && /* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-sm text-blue-text", children: [
355
+ "Click a passage in the document to add it \u2014 ",
356
+ /* @__PURE__ */ jsxRuntime.jsx("strong", { children: "shift-click" }),
357
+ " to take a whole range. Add as many as you like, from as many documents as you like."
358
+ ] })
359
+ ] });
360
+ }
197
361
  var ConnectionContext = react$1.createContext(null);
198
362
  var WORKSPACE_STORAGE_PREFIX = "arbi:selectedWorkspace";
199
363
  var workspaceStorageKey = (apiUrl) => `${WORKSPACE_STORAGE_PREFIX}:${apiUrl || "demo"}`;
@@ -415,9 +579,9 @@ function DataTable({
415
579
  className
416
580
  }) {
417
581
  if (rows.length === 0) {
418
- return /* @__PURE__ */ jsxRuntime.jsx(EmptyState, { title: emptyTitle, description: emptyDescription, testId: chunkAHWIZJ4M_cjs.tid(area, "empty") });
582
+ return /* @__PURE__ */ jsxRuntime.jsx(EmptyState, { title: emptyTitle, description: emptyDescription, testId: chunk6MFI2HPX_cjs.tid(area, "empty") });
419
583
  }
420
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: react.cn("rounded-xl border border-border bg-card", className), children: /* @__PURE__ */ jsxRuntime.jsxs(react.Table, { "data-testid": chunkAHWIZJ4M_cjs.tid(area, "table"), children: [
584
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: react.cn("rounded-xl border border-border bg-card", className), children: /* @__PURE__ */ jsxRuntime.jsxs(react.Table, { "data-testid": chunk6MFI2HPX_cjs.tid(area, "table"), children: [
421
585
  /* @__PURE__ */ jsxRuntime.jsx(react.TableHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(react.TableRow, { className: "hover:bg-transparent", children: columns.map((c) => /* @__PURE__ */ jsxRuntime.jsx(
422
586
  react.TableHead,
423
587
  {
@@ -431,7 +595,7 @@ function DataTable({
431
595
  return /* @__PURE__ */ jsxRuntime.jsx(
432
596
  react.TableRow,
433
597
  {
434
- "data-testid": chunkAHWIZJ4M_cjs.tid(area, "row", id),
598
+ "data-testid": chunk6MFI2HPX_cjs.tid(area, "row", id),
435
599
  onClick: onRowClick ? () => onRowClick(row) : void 0,
436
600
  className: react.cn(onRowClick && "cursor-pointer"),
437
601
  children: columns.map((c) => /* @__PURE__ */ jsxRuntime.jsx(
@@ -1243,7 +1407,7 @@ function WorkspaceCard({
1243
1407
  children: [
1244
1408
  shownMembers.map((m, i) => /* @__PURE__ */ jsxRuntime.jsxs(react.Avatar, { className: "size-6 border-2 border-card", title: m.name, children: [
1245
1409
  m.picture && /* @__PURE__ */ jsxRuntime.jsx(react.AvatarImage, { src: m.picture, alt: m.name }),
1246
- /* @__PURE__ */ jsxRuntime.jsx(react.AvatarFallback, { className: "bg-foreground text-[9px] font-medium text-background", children: chunkAHWIZJ4M_cjs.initials(m.name || "?") })
1410
+ /* @__PURE__ */ jsxRuntime.jsx(react.AvatarFallback, { className: "bg-foreground text-[9px] font-medium text-background", children: chunk6MFI2HPX_cjs.initials(m.name || "?") })
1247
1411
  ] }, i)),
1248
1412
  !membersHidden && extraMembers > 0 && /* @__PURE__ */ jsxRuntime.jsx(react.Avatar, { className: "size-6 border-2 border-card", children: /* @__PURE__ */ jsxRuntime.jsxs(react.AvatarFallback, { className: "bg-accent text-[9px] font-medium text-muted-foreground", children: [
1249
1413
  "+",
@@ -1257,10 +1421,10 @@ function WorkspaceCard({
1257
1421
  "span",
1258
1422
  {
1259
1423
  className: "min-w-0 max-w-full self-start truncate text-left text-xs text-muted-foreground",
1260
- title: chunkAHWIZJ4M_cjs.fmtDate(updatedAt),
1424
+ title: chunk6MFI2HPX_cjs.fmtDate(updatedAt),
1261
1425
  children: [
1262
1426
  "Updated ",
1263
- chunkAHWIZJ4M_cjs.fromNow(updatedAt)
1427
+ chunk6MFI2HPX_cjs.fromNow(updatedAt)
1264
1428
  ]
1265
1429
  }
1266
1430
  )
@@ -1292,7 +1456,7 @@ function NavItemLink({ item, onNavigate }) {
1292
1456
  to: item.to,
1293
1457
  end: item.end,
1294
1458
  onClick: onNavigate,
1295
- "data-testid": chunkAHWIZJ4M_cjs.tid("sidebar-nav", item.id),
1459
+ "data-testid": chunk6MFI2HPX_cjs.tid("sidebar-nav", item.id),
1296
1460
  className: ({ isActive }) => react.cn(
1297
1461
  "group flex items-center gap-3 rounded-md px-3 py-2 text-sm font-medium transition-colors",
1298
1462
  isActive ? "bg-sidebar-accent text-sidebar-accent-foreground" : "text-sidebar-foreground hover:bg-sidebar-accent/60 hover:text-sidebar-accent-foreground"
@@ -1465,7 +1629,7 @@ function AppHeader({
1465
1629
  type: "button",
1466
1630
  onClick: onSearch,
1467
1631
  className: classNames?.search ?? "relative hidden max-w-md flex-1 items-center rounded-md border border-input bg-background py-2 pl-9 pr-3 text-left text-sm text-muted-foreground transition-colors hover:bg-accent md:flex",
1468
- "data-testid": chunkAHWIZJ4M_cjs.tid(testIdPrefix, "global-search"),
1632
+ "data-testid": chunk6MFI2HPX_cjs.tid(testIdPrefix, "global-search"),
1469
1633
  children: [
1470
1634
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Search, { className: "pointer-events-none absolute left-3 top-1/2 size-4 -translate-y-1/2 text-muted-foreground" }),
1471
1635
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex-1", children: searchPlaceholder }),
@@ -1481,7 +1645,7 @@ function AppHeader({
1481
1645
  size: "sm",
1482
1646
  onClick: onAsk ?? onSearch,
1483
1647
  className: classNames?.askButton,
1484
- "data-testid": chunkAHWIZJ4M_cjs.tid(testIdPrefix, "ask-ai"),
1648
+ "data-testid": chunk6MFI2HPX_cjs.tid(testIdPrefix, "ask-ai"),
1485
1649
  children: [
1486
1650
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Sparkles, { className: "size-4" }),
1487
1651
  askLabel
@@ -1492,7 +1656,7 @@ function AppHeader({
1492
1656
  /* @__PURE__ */ jsxRuntime.jsx(
1493
1657
  react.NotificationBell,
1494
1658
  {
1495
- testId: chunkAHWIZJ4M_cjs.tid(testIdPrefix, "notifications"),
1659
+ testId: chunk6MFI2HPX_cjs.tid(testIdPrefix, "notifications"),
1496
1660
  onNavigate: onNotificationNavigate,
1497
1661
  toneClassNames: notificationTones
1498
1662
  }
@@ -1503,8 +1667,8 @@ function AppHeader({
1503
1667
  user,
1504
1668
  items: userItems,
1505
1669
  onLogout,
1506
- testId: chunkAHWIZJ4M_cjs.tid(testIdPrefix, "user-menu"),
1507
- logoutTestId: chunkAHWIZJ4M_cjs.tid(testIdPrefix, "logout")
1670
+ testId: chunk6MFI2HPX_cjs.tid(testIdPrefix, "user-menu"),
1671
+ logoutTestId: chunk6MFI2HPX_cjs.tid(testIdPrefix, "logout")
1508
1672
  }
1509
1673
  )
1510
1674
  ] })
@@ -1724,7 +1888,7 @@ function createArbiMaterializer(arbi, opts = {}) {
1724
1888
  }
1725
1889
  function collectAssetRefs(node, acc) {
1726
1890
  if (typeof node === "string") {
1727
- if (chunkAHWIZJ4M_cjs.isAssetRef(node)) acc.add(node);
1891
+ if (chunk6MFI2HPX_cjs.isAssetRef(node)) acc.add(node);
1728
1892
  return;
1729
1893
  }
1730
1894
  if (Array.isArray(node)) {
@@ -1758,7 +1922,7 @@ async function materializePageData(data, materialize) {
1758
1922
  const replacements = /* @__PURE__ */ new Map();
1759
1923
  await Promise.all(
1760
1924
  [...refs].map(async (ref) => {
1761
- const src = await materialize(chunkAHWIZJ4M_cjs.assetRefId(ref));
1925
+ const src = await materialize(chunk6MFI2HPX_cjs.assetRefId(ref));
1762
1926
  if (src) replacements.set(ref, src);
1763
1927
  })
1764
1928
  );
@@ -1843,7 +2007,7 @@ function StudioEditor({
1843
2007
  radius: stored.radius ?? defaultTheme.radius,
1844
2008
  activePresetId: null
1845
2009
  });
1846
- chunkAHWIZJ4M_cjs.applyStoredTheme(themeBundle);
2010
+ chunk6MFI2HPX_cjs.applyStoredTheme(themeBundle);
1847
2011
  })();
1848
2012
  return () => {
1849
2013
  cancelled = true;
@@ -1936,7 +2100,7 @@ function StudioEditor({
1936
2100
  "\u201D\u2026"
1937
2101
  ]
1938
2102
  }
1939
- ) : /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.AssetResolverProvider, { render: AssetThumb, children: /* @__PURE__ */ jsxRuntime.jsx(
2103
+ ) : /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.AssetResolverProvider, { render: AssetThumb, children: /* @__PURE__ */ jsxRuntime.jsx(
1940
2104
  puck.Puck,
1941
2105
  {
1942
2106
  config,
@@ -1954,7 +2118,7 @@ function StudioEditor({
1954
2118
  className: "w-80 shrink-0 border-l border-border",
1955
2119
  "data-testid": `${testIdPrefix}-theme-drawer`,
1956
2120
  children: /* @__PURE__ */ jsxRuntime.jsx(
1957
- chunkAHWIZJ4M_cjs.ThemeEditor,
2121
+ chunk6MFI2HPX_cjs.ThemeEditor,
1958
2122
  {
1959
2123
  bundle: themeBundle,
1960
2124
  variant: "drawer",
@@ -1993,7 +2157,7 @@ function PageRenderer({
1993
2157
  const page = initialData ?? (await persistence.loadPublished(arbi, live, slug)).data ?? (await persistence.loadPage(arbi, live, slug)).data;
1994
2158
  if (cancelled) return;
1995
2159
  if (applyTheme) {
1996
- chunkAHWIZJ4M_cjs.applyThemeVars(
2160
+ chunk6MFI2HPX_cjs.applyThemeVars(
1997
2161
  theme ? { ...defaultTheme, ...theme, colors: { ...defaultTheme.colors, ...theme.colors } } : defaultTheme
1998
2162
  );
1999
2163
  }
@@ -2195,7 +2359,7 @@ function AiTextField({
2195
2359
  setActive(true);
2196
2360
  await task.run(buildPrompt({ kind, label, current: value ?? "" }), docIds);
2197
2361
  };
2198
- const inputTid = chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-field`, name);
2362
+ const inputTid = chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-field`, name);
2199
2363
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "al-ai-field", children: [
2200
2364
  multiline ? /* @__PURE__ */ jsxRuntime.jsx(
2201
2365
  "textarea",
@@ -2224,7 +2388,7 @@ function AiTextField({
2224
2388
  className: "al-ai-field__btn",
2225
2389
  onClick: () => void write(),
2226
2390
  disabled: task.isRunning,
2227
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-ai-write`, name),
2391
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-ai-write`, name),
2228
2392
  title: "Draft this field with AI, grounded in the marketing workspace",
2229
2393
  children: [
2230
2394
  task.isRunning ? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Loader2, { className: "size-3 animate-spin" }) : /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Sparkles, { className: "size-3" }),
@@ -2327,8 +2491,8 @@ function ImageFieldControl({
2327
2491
  const arbi = react.useArbi();
2328
2492
  const gen = useImageGen();
2329
2493
  const queryClient = reactQuery.useQueryClient();
2330
- const currentAssetImage = useAssetImage(chunkAHWIZJ4M_cjs.isAssetRef(value) ? chunkAHWIZJ4M_cjs.assetRefId(value) : "");
2331
- const tp = (...q) => chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-image`, name, ...q);
2494
+ const currentAssetImage = useAssetImage(chunk6MFI2HPX_cjs.isAssetRef(value) ? chunk6MFI2HPX_cjs.assetRefId(value) : "");
2495
+ const tp = (...q) => chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-image`, name, ...q);
2332
2496
  const refreshAssets = () => queryClient.invalidateQueries({ queryKey: ["arbi", "documents", workspaceId] });
2333
2497
  const { data: docs } = react.useDocuments(workspaceId);
2334
2498
  const imageDocs = react$1.useMemo(
@@ -2362,7 +2526,7 @@ function ImageFieldControl({
2362
2526
  const res = await arbi.documents.uploadFile(file, name2, { folder });
2363
2527
  const id = res.doc_ext_ids?.[0];
2364
2528
  if (id) {
2365
- onChange(chunkAHWIZJ4M_cjs.asAssetRef(id));
2529
+ onChange(chunk6MFI2HPX_cjs.asAssetRef(id));
2366
2530
  void refreshAssets();
2367
2531
  }
2368
2532
  } finally {
@@ -2380,7 +2544,7 @@ function ImageFieldControl({
2380
2544
  if (!prompt.trim() || gen.isGenerating) return;
2381
2545
  const id = await gen.generate(prompt, refIds);
2382
2546
  if (id) {
2383
- onChange(chunkAHWIZJ4M_cjs.asAssetRef(id));
2547
+ onChange(chunk6MFI2HPX_cjs.asAssetRef(id));
2384
2548
  setRefIds([]);
2385
2549
  void refreshAssets();
2386
2550
  }
@@ -2395,7 +2559,7 @@ function ImageFieldControl({
2395
2559
  const tabClass = (on) => `inline-flex items-center gap-1 rounded-md px-2 py-1 text-xs font-medium ${on ? "bg-primary text-primary-foreground" : "text-muted-foreground hover:text-foreground"}`;
2396
2560
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-2", "data-testid": tp(), children: [
2397
2561
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative", children: [
2398
- /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.BlockImage, { src: value, aspect: "16:9", rounded: "md", testId: tp("preview") }),
2562
+ /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.BlockImage, { src: value, aspect: "16:9", rounded: "md", testId: tp("preview") }),
2399
2563
  currentAssetImage ? /* @__PURE__ */ jsxRuntime.jsxs(
2400
2564
  "button",
2401
2565
  {
@@ -2429,12 +2593,12 @@ function ImageFieldControl({
2429
2593
  imageDocs.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "col-span-3 py-3 text-center text-xs text-muted-foreground", children: "No image assets yet \u2014 upload or generate one." }),
2430
2594
  imageDocs.map((d) => {
2431
2595
  const thumb = thumbs?.[d.external_id];
2432
- const selected = value === chunkAHWIZJ4M_cjs.asAssetRef(d.external_id);
2596
+ const selected = value === chunk6MFI2HPX_cjs.asAssetRef(d.external_id);
2433
2597
  return /* @__PURE__ */ jsxRuntime.jsx(
2434
2598
  "button",
2435
2599
  {
2436
2600
  type: "button",
2437
- onClick: () => onChange(chunkAHWIZJ4M_cjs.asAssetRef(d.external_id)),
2601
+ onClick: () => onChange(chunk6MFI2HPX_cjs.asAssetRef(d.external_id)),
2438
2602
  className: `overflow-hidden rounded border ${selected ? "border-primary ring-1 ring-primary" : "border-border"}`,
2439
2603
  title: d.file_name ?? "",
2440
2604
  "data-testid": tp("asset", d.external_id),
@@ -2496,14 +2660,14 @@ function ImageFieldControl({
2496
2660
  "Reference images",
2497
2661
  refIds.length > 0 ? ` (${refIds.length})` : " (optional)"
2498
2662
  ] }),
2499
- chunkAHWIZJ4M_cjs.isAssetRef(value) && /* @__PURE__ */ jsxRuntime.jsx(
2663
+ chunk6MFI2HPX_cjs.isAssetRef(value) && /* @__PURE__ */ jsxRuntime.jsx(
2500
2664
  "button",
2501
2665
  {
2502
2666
  type: "button",
2503
2667
  className: "text-xs font-medium text-primary hover:underline",
2504
- onClick: () => toggleRef(chunkAHWIZJ4M_cjs.assetRefId(value)),
2668
+ onClick: () => toggleRef(chunk6MFI2HPX_cjs.assetRefId(value)),
2505
2669
  "data-testid": tp("vary-current"),
2506
- children: refIds.includes(chunkAHWIZJ4M_cjs.assetRefId(value)) ? "Varying current" : "Vary current image"
2670
+ children: refIds.includes(chunk6MFI2HPX_cjs.assetRefId(value)) ? "Varying current" : "Vary current image"
2507
2671
  }
2508
2672
  )
2509
2673
  ] }),
@@ -2717,7 +2881,7 @@ function createBlockKit(ai, image, eyebrowClassName) {
2717
2881
  }),
2718
2882
  iconField: (label = "Icon") => ({ type: "select", label, options: ICON_OPTIONS }),
2719
2883
  resolveIcon: (name) => name ? iconMap[name] : void 0,
2720
- blockTestId: (id) => chunkAHWIZJ4M_cjs.tid("arbi-block", id)
2884
+ blockTestId: (id) => chunk6MFI2HPX_cjs.tid("arbi-block", id)
2721
2885
  };
2722
2886
  }
2723
2887
  var emptySlot = [];
@@ -2782,7 +2946,7 @@ function createWebsiteBlocks(kit) {
2782
2946
  render: ({ id, count, gap, col1, col2, col3, col4 }) => {
2783
2947
  const n = Number(count) || 3;
2784
2948
  const columns = [col1, col2, col3, col4].slice(0, n).map(renderSlot);
2785
- return /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Columns, { count: n, gap, columns, testId: blockTestId(id) });
2949
+ return /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Columns, { count: n, gap, columns, testId: blockTestId(id) });
2786
2950
  }
2787
2951
  };
2788
2952
  const SpacerBlock = {
@@ -2800,7 +2964,7 @@ function createWebsiteBlocks(kit) {
2800
2964
  }
2801
2965
  },
2802
2966
  defaultProps: { size: "md" },
2803
- render: ({ id, size }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Spacer, { size, testId: blockTestId(id) })
2967
+ render: ({ id, size }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Spacer, { size, testId: blockTestId(id) })
2804
2968
  };
2805
2969
  const ContainerBlock = {
2806
2970
  label: "Container",
@@ -2828,7 +2992,7 @@ function createWebsiteBlocks(kit) {
2828
2992
  children: { type: "slot" }
2829
2993
  },
2830
2994
  defaultProps: { width: "default", padding: "md", children: emptySlot },
2831
- render: ({ id, width, padding, children }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Container, { width, padding, testId: blockTestId(id), children: renderSlot(children) })
2995
+ render: ({ id, width, padding, children }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Container, { width, padding, testId: blockTestId(id), children: renderSlot(children) })
2832
2996
  };
2833
2997
  const HeroBlock = {
2834
2998
  label: "Hero",
@@ -2879,7 +3043,7 @@ function createWebsiteBlocks(kit) {
2879
3043
  backgroundImage,
2880
3044
  overlay
2881
3045
  }) => /* @__PURE__ */ jsxRuntime.jsx(
2882
- chunkAHWIZJ4M_cjs.Hero,
3046
+ chunk6MFI2HPX_cjs.Hero,
2883
3047
  {
2884
3048
  eyebrow,
2885
3049
  title,
@@ -2951,7 +3115,7 @@ function createWebsiteBlocks(kit) {
2951
3115
  icon: resolveIcon(it.icon)
2952
3116
  })
2953
3117
  );
2954
- return /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.FeatureGrid, { columns, items: list, testId: blockTestId(id) });
3118
+ return /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.FeatureGrid, { columns, items: list, testId: blockTestId(id) });
2955
3119
  }
2956
3120
  };
2957
3121
  const StatGroupBlock = {
@@ -2993,7 +3157,7 @@ function createWebsiteBlocks(kit) {
2993
3157
  avatarUrl: ""
2994
3158
  },
2995
3159
  render: ({ id, quote, author, role, avatarUrl }) => /* @__PURE__ */ jsxRuntime.jsx(
2996
- chunkAHWIZJ4M_cjs.Testimonial,
3160
+ chunk6MFI2HPX_cjs.Testimonial,
2997
3161
  {
2998
3162
  quote,
2999
3163
  author,
@@ -3022,7 +3186,7 @@ function createWebsiteBlocks(kit) {
3022
3186
  overlay: true
3023
3187
  },
3024
3188
  render: ({ id, title, subtitle, cta, tone, backgroundImage, overlay }) => /* @__PURE__ */ jsxRuntime.jsx(
3025
- chunkAHWIZJ4M_cjs.CTABanner,
3189
+ chunk6MFI2HPX_cjs.CTABanner,
3026
3190
  {
3027
3191
  title,
3028
3192
  subtitle,
@@ -3054,7 +3218,7 @@ function createWebsiteBlocks(kit) {
3054
3218
  { label: "Umbrella" }
3055
3219
  ]
3056
3220
  },
3057
- render: ({ id, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.LogoCloud, { items, testId: blockTestId(id) })
3221
+ render: ({ id, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.LogoCloud, { items, testId: blockTestId(id) })
3058
3222
  };
3059
3223
  const FAQBlock = {
3060
3224
  label: "FAQ",
@@ -3086,7 +3250,7 @@ function createWebsiteBlocks(kit) {
3086
3250
  }
3087
3251
  ]
3088
3252
  },
3089
- render: ({ id, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.FAQ, { items, testId: blockTestId(id) })
3253
+ render: ({ id, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.FAQ, { items, testId: blockTestId(id) })
3090
3254
  };
3091
3255
  const RichTextBlockConfig = {
3092
3256
  label: "Rich text",
@@ -3096,7 +3260,7 @@ function createWebsiteBlocks(kit) {
3096
3260
  defaultProps: {
3097
3261
  content: "## About us\n\nWe build tools that help teams do their best work. Our platform combines **power** and _simplicity_ so you can focus on what matters.\n\n- Fast to learn\n- Easy to scale\n- Loved by teams"
3098
3262
  },
3099
- render: ({ id, content }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.RichTextBlock, { content, testId: blockTestId(id) })
3263
+ render: ({ id, content }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.RichTextBlock, { content, testId: blockTestId(id) })
3100
3264
  };
3101
3265
  const CalloutBlock = {
3102
3266
  label: "Callout",
@@ -3119,7 +3283,7 @@ function createWebsiteBlocks(kit) {
3119
3283
  title: "Good to know",
3120
3284
  body: "This is a helpful note that draws attention to important information."
3121
3285
  },
3122
- render: ({ id, variant, title, body }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Callout, { variant, title, body, testId: blockTestId(id) })
3286
+ render: ({ id, variant, title, body }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Callout, { variant, title, body, testId: blockTestId(id) })
3123
3287
  };
3124
3288
  const ImageBlock = {
3125
3289
  label: "Image",
@@ -3150,7 +3314,7 @@ function createWebsiteBlocks(kit) {
3150
3314
  },
3151
3315
  defaultProps: { src: "", alt: "Image", aspect: "16:9", rounded: "lg", framed: false },
3152
3316
  render: ({ id, src, alt, aspect, rounded, framed }) => /* @__PURE__ */ jsxRuntime.jsx(
3153
- chunkAHWIZJ4M_cjs.BlockImage,
3317
+ chunk6MFI2HPX_cjs.BlockImage,
3154
3318
  {
3155
3319
  src,
3156
3320
  alt,
@@ -3178,7 +3342,7 @@ function createWebsiteBlocks(kit) {
3178
3342
  }
3179
3343
  },
3180
3344
  defaultProps: { src: "", name: "Jane Doe", size: "md" },
3181
- render: ({ id, src, name, size }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.AvatarBlock, { src, name, size, testId: blockTestId(id) })
3345
+ render: ({ id, src, name, size }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.AvatarBlock, { src, name, size, testId: blockTestId(id) })
3182
3346
  };
3183
3347
  const NavbarBlock = {
3184
3348
  label: "Navbar",
@@ -3206,7 +3370,7 @@ function createWebsiteBlocks(kit) {
3206
3370
  ],
3207
3371
  cta: { label: "Sign up", href: "#" }
3208
3372
  },
3209
- render: ({ id, brand, links, cta }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Navbar, { brand, links, cta, testId: blockTestId(id) })
3373
+ render: ({ id, brand, links, cta }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Navbar, { brand, links, cta, testId: blockTestId(id) })
3210
3374
  };
3211
3375
  const FooterBlock = {
3212
3376
  label: "Footer",
@@ -3265,7 +3429,7 @@ function createWebsiteBlocks(kit) {
3265
3429
  ],
3266
3430
  copyright: "\xA9 2026 Acme, Inc. All rights reserved."
3267
3431
  },
3268
- render: ({ id, columns, copyright }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Footer, { columns, copyright, testId: blockTestId(id) })
3432
+ render: ({ id, columns, copyright }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Footer, { columns, copyright, testId: blockTestId(id) })
3269
3433
  };
3270
3434
  const ListBlockConfig = {
3271
3435
  label: "List",
@@ -3283,7 +3447,7 @@ function createWebsiteBlocks(kit) {
3283
3447
  ordered: false,
3284
3448
  items: [{ text: "First item" }, { text: "Second item" }, { text: "Third item" }]
3285
3449
  },
3286
- render: ({ id, ordered, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.ListBlock, { ordered, items, testId: blockTestId(id) })
3450
+ render: ({ id, ordered, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.ListBlock, { ordered, items, testId: blockTestId(id) })
3287
3451
  };
3288
3452
  return {
3289
3453
  Columns: ColumnsBlock,
@@ -3385,7 +3549,7 @@ function createSiteBlocks(kit) {
3385
3549
  ]
3386
3550
  },
3387
3551
  render: ({ id, plans }) => /* @__PURE__ */ jsxRuntime.jsx(
3388
- chunkAHWIZJ4M_cjs.PricingTable,
3552
+ chunk6MFI2HPX_cjs.PricingTable,
3389
3553
  {
3390
3554
  plans: (plans ?? []).map(
3391
3555
  (p) => ({
@@ -3423,7 +3587,7 @@ function createSiteBlocks(kit) {
3423
3587
  { label: "FAQ", content: "Answers to common questions." }
3424
3588
  ]
3425
3589
  },
3426
- render: ({ id, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Tabs, { items, testId: blockTestId(id) })
3590
+ render: ({ id, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Tabs, { items, testId: blockTestId(id) })
3427
3591
  };
3428
3592
  const AccordionBlock = {
3429
3593
  label: "Accordion",
@@ -3447,7 +3611,7 @@ function createSiteBlocks(kit) {
3447
3611
  { title: "How does billing work?", content: "Monthly or annually, cancel anytime." }
3448
3612
  ]
3449
3613
  },
3450
- render: ({ id, allowMultiple, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Accordion, { allowMultiple, items, testId: blockTestId(id) })
3614
+ render: ({ id, allowMultiple, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Accordion, { allowMultiple, items, testId: blockTestId(id) })
3451
3615
  };
3452
3616
  const GalleryBlock = {
3453
3617
  label: "Gallery",
@@ -3483,7 +3647,7 @@ function createSiteBlocks(kit) {
3483
3647
  { src: "", alt: "Image three", caption: "" }
3484
3648
  ]
3485
3649
  },
3486
- render: ({ id, columns, aspect, images }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Gallery, { columns, aspect, images, testId: blockTestId(id) })
3650
+ render: ({ id, columns, aspect, images }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Gallery, { columns, aspect, images, testId: blockTestId(id) })
3487
3651
  };
3488
3652
  const VideoBlock = {
3489
3653
  label: "Video",
@@ -3503,7 +3667,7 @@ function createSiteBlocks(kit) {
3503
3667
  },
3504
3668
  defaultProps: { url: "", title: "", aspect: "16:9", rounded: true },
3505
3669
  render: ({ id, url, title, aspect, rounded }) => /* @__PURE__ */ jsxRuntime.jsx(
3506
- chunkAHWIZJ4M_cjs.VideoEmbed,
3670
+ chunk6MFI2HPX_cjs.VideoEmbed,
3507
3671
  {
3508
3672
  url,
3509
3673
  title,
@@ -3552,7 +3716,7 @@ function createSiteBlocks(kit) {
3552
3716
  ]
3553
3717
  },
3554
3718
  render: ({ id, submitLabel, action, successMessage, fields }) => /* @__PURE__ */ jsxRuntime.jsx(
3555
- chunkAHWIZJ4M_cjs.ContactForm,
3719
+ chunk6MFI2HPX_cjs.ContactForm,
3556
3720
  {
3557
3721
  submitLabel,
3558
3722
  action: action || void 0,
@@ -3582,7 +3746,7 @@ function createSiteBlocks(kit) {
3582
3746
  cta: { label: "Read more", href: "#" },
3583
3747
  tone: "primary"
3584
3748
  },
3585
- render: ({ id, text, cta, tone }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Banner, { text, cta, tone, testId: blockTestId(id) })
3749
+ render: ({ id, text, cta, tone }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Banner, { text, cta, tone, testId: blockTestId(id) })
3586
3750
  };
3587
3751
  const MediaTextBlock = {
3588
3752
  label: "Media & text",
@@ -3610,7 +3774,7 @@ function createSiteBlocks(kit) {
3610
3774
  cta: { label: "Learn more", href: "#" }
3611
3775
  },
3612
3776
  render: ({ id, eyebrow, title, body, imageUrl, mediaSide, cta }) => /* @__PURE__ */ jsxRuntime.jsx(
3613
- chunkAHWIZJ4M_cjs.MediaText,
3777
+ chunk6MFI2HPX_cjs.MediaText,
3614
3778
  {
3615
3779
  eyebrow,
3616
3780
  title,
@@ -3647,7 +3811,7 @@ function createSiteBlocks(kit) {
3647
3811
  { name: "Jordan Lee", role: "Lead Engineer", bio: "", avatarUrl: "" }
3648
3812
  ]
3649
3813
  },
3650
- render: ({ id, columns, members }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.TeamGrid, { columns, members, testId: blockTestId(id) })
3814
+ render: ({ id, columns, members }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.TeamGrid, { columns, members, testId: blockTestId(id) })
3651
3815
  };
3652
3816
  const StepsBlock = {
3653
3817
  label: "Steps",
@@ -3679,7 +3843,7 @@ function createSiteBlocks(kit) {
3679
3843
  { title: "Launch", description: "Go live and start seeing results." }
3680
3844
  ]
3681
3845
  },
3682
- render: ({ id, variant, steps }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.Steps, { variant, steps, testId: blockTestId(id) })
3846
+ render: ({ id, variant, steps }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.Steps, { variant, steps, testId: blockTestId(id) })
3683
3847
  };
3684
3848
  const TestimonialGridBlock = {
3685
3849
  label: "Testimonial grid",
@@ -3721,7 +3885,7 @@ function createSiteBlocks(kit) {
3721
3885
  }
3722
3886
  ]
3723
3887
  },
3724
- render: ({ id, columns, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunkAHWIZJ4M_cjs.TestimonialGrid, { columns, items, testId: blockTestId(id) })
3888
+ render: ({ id, columns, items }) => /* @__PURE__ */ jsxRuntime.jsx(chunk6MFI2HPX_cjs.TestimonialGrid, { columns, items, testId: blockTestId(id) })
3725
3889
  };
3726
3890
  return {
3727
3891
  Pricing: PricingBlock,
@@ -3765,7 +3929,7 @@ function createArbiBlocksConfig(opts = {}) {
3765
3929
  },
3766
3930
  defaultProps: { title: "Section title", align: "left", invert: false },
3767
3931
  render: ({ id, title, eyebrow, lead, align, invert }) => /* @__PURE__ */ jsxRuntime.jsx("div", { "data-testid": blockTestId(id), children: /* @__PURE__ */ jsxRuntime.jsx(
3768
- chunkAHWIZJ4M_cjs.SectionHeading,
3932
+ chunk6MFI2HPX_cjs.SectionHeading,
3769
3933
  {
3770
3934
  title,
3771
3935
  eyebrow,
@@ -4359,7 +4523,7 @@ function ModuleManager({ store, testIdPrefix = "builder" }) {
4359
4523
  {
4360
4524
  variant: "elevated",
4361
4525
  className: "rounded-xl",
4362
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-modules-section`, group.section),
4526
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-modules-section`, group.section),
4363
4527
  children: [
4364
4528
  /* @__PURE__ */ jsxRuntime.jsx(react.CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(react.CardTitle, { className: "text-base", children: group.section }) }),
4365
4529
  /* @__PURE__ */ jsxRuntime.jsx(react.CardContent, { className: "space-y-1.5", children: group.modules.map((m, idx) => {
@@ -4368,7 +4532,7 @@ function ModuleManager({ store, testIdPrefix = "builder" }) {
4368
4532
  "div",
4369
4533
  {
4370
4534
  className: "flex items-center gap-3 rounded-md border border-border/60 bg-card px-3 py-2",
4371
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-module`, m.id),
4535
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-module`, m.id),
4372
4536
  children: [
4373
4537
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col", children: [
4374
4538
  /* @__PURE__ */ jsxRuntime.jsx(
@@ -4380,7 +4544,7 @@ function ModuleManager({ store, testIdPrefix = "builder" }) {
4380
4544
  disabled: idx === 0,
4381
4545
  onClick: () => move(m.id, "up"),
4382
4546
  "aria-label": `Move ${m.label} up`,
4383
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-module-up`, m.id),
4547
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-module-up`, m.id),
4384
4548
  children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronUp, { className: "size-3.5" })
4385
4549
  }
4386
4550
  ),
@@ -4393,7 +4557,7 @@ function ModuleManager({ store, testIdPrefix = "builder" }) {
4393
4557
  disabled: idx === group.modules.length - 1,
4394
4558
  onClick: () => move(m.id, "down"),
4395
4559
  "aria-label": `Move ${m.label} down`,
4396
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-module-down`, m.id),
4560
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-module-down`, m.id),
4397
4561
  children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronDown, { className: "size-3.5" })
4398
4562
  }
4399
4563
  )
@@ -4413,7 +4577,7 @@ function ModuleManager({ store, testIdPrefix = "builder" }) {
4413
4577
  checked: m.enabled,
4414
4578
  onCheckedChange: () => toggle2(m.id),
4415
4579
  "aria-label": `Enable ${m.label}`,
4416
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-module-toggle`, m.id)
4580
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-module-toggle`, m.id)
4417
4581
  }
4418
4582
  )
4419
4583
  ]
@@ -4445,7 +4609,7 @@ function ConfigModelBadge({ configId, testIdPrefix }) {
4445
4609
  react.Badge,
4446
4610
  {
4447
4611
  variant: TIER_VARIANT[tier] ?? "secondary",
4448
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-agents-config-tier`, configId),
4612
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-agents-config-tier`, configId),
4449
4613
  children: [
4450
4614
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Cpu, { className: "size-3" }),
4451
4615
  " ",
@@ -4482,14 +4646,14 @@ function AgentsPanel({ store, testIdPrefix = "builder" }) {
4482
4646
  "label",
4483
4647
  {
4484
4648
  className: "flex cursor-pointer items-center gap-3 rounded-md border border-border/60 bg-card px-3 py-2",
4485
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-agents-config`, v.external_id),
4649
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-agents-config`, v.external_id),
4486
4650
  children: [
4487
4651
  /* @__PURE__ */ jsxRuntime.jsx(
4488
4652
  react.Checkbox,
4489
4653
  {
4490
4654
  checked: configIds.includes(v.external_id),
4491
4655
  onCheckedChange: () => toggleConfig(v.external_id),
4492
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-agents-config-toggle`, v.external_id)
4656
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-agents-config-toggle`, v.external_id)
4493
4657
  }
4494
4658
  ),
4495
4659
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
@@ -4518,14 +4682,14 @@ function AgentsPanel({ store, testIdPrefix = "builder" }) {
4518
4682
  "label",
4519
4683
  {
4520
4684
  className: "flex cursor-pointer items-center gap-3 rounded-md border border-border/60 bg-card px-3 py-2",
4521
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-agents-agent`, a.external_id),
4685
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-agents-agent`, a.external_id),
4522
4686
  children: [
4523
4687
  /* @__PURE__ */ jsxRuntime.jsx(
4524
4688
  react.Checkbox,
4525
4689
  {
4526
4690
  checked: agentIds.includes(a.external_id),
4527
4691
  onCheckedChange: () => toggleAgent(a.external_id),
4528
- "data-testid": chunkAHWIZJ4M_cjs.tid(`${testIdPrefix}-agents-agent-toggle`, a.external_id)
4692
+ "data-testid": chunk6MFI2HPX_cjs.tid(`${testIdPrefix}-agents-agent-toggle`, a.external_id)
4529
4693
  }
4530
4694
  ),
4531
4695
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "min-w-0 flex-1", children: [
@@ -4612,7 +4776,7 @@ function VerticalBuilder({
4612
4776
  ] })
4613
4777
  ] }),
4614
4778
  /* @__PURE__ */ jsxRuntime.jsx(react.TabsContent, { value: "theme", children: /* @__PURE__ */ jsxRuntime.jsx(
4615
- chunkAHWIZJ4M_cjs.ThemeEditor,
4779
+ chunk6MFI2HPX_cjs.ThemeEditor,
4616
4780
  {
4617
4781
  bundle: themeBundle,
4618
4782
  variant: "panel",
@@ -4638,239 +4802,243 @@ function VerticalBuilder({
4638
4802
 
4639
4803
  Object.defineProperty(exports, "ASSET_REF_PREFIX", {
4640
4804
  enumerable: true,
4641
- get: function () { return chunkAHWIZJ4M_cjs.ASSET_REF_PREFIX; }
4805
+ get: function () { return chunk6MFI2HPX_cjs.ASSET_REF_PREFIX; }
4642
4806
  });
4643
4807
  Object.defineProperty(exports, "Accordion", {
4644
4808
  enumerable: true,
4645
- get: function () { return chunkAHWIZJ4M_cjs.Accordion; }
4809
+ get: function () { return chunk6MFI2HPX_cjs.Accordion; }
4646
4810
  });
4647
4811
  Object.defineProperty(exports, "AssetResolverProvider", {
4648
4812
  enumerable: true,
4649
- get: function () { return chunkAHWIZJ4M_cjs.AssetResolverProvider; }
4813
+ get: function () { return chunk6MFI2HPX_cjs.AssetResolverProvider; }
4650
4814
  });
4651
4815
  Object.defineProperty(exports, "AvatarBlock", {
4652
4816
  enumerable: true,
4653
- get: function () { return chunkAHWIZJ4M_cjs.AvatarBlock; }
4817
+ get: function () { return chunk6MFI2HPX_cjs.AvatarBlock; }
4654
4818
  });
4655
4819
  Object.defineProperty(exports, "Banner", {
4656
4820
  enumerable: true,
4657
- get: function () { return chunkAHWIZJ4M_cjs.Banner; }
4821
+ get: function () { return chunk6MFI2HPX_cjs.Banner; }
4658
4822
  });
4659
4823
  Object.defineProperty(exports, "BlockImage", {
4660
4824
  enumerable: true,
4661
- get: function () { return chunkAHWIZJ4M_cjs.BlockImage; }
4825
+ get: function () { return chunk6MFI2HPX_cjs.BlockImage; }
4662
4826
  });
4663
4827
  Object.defineProperty(exports, "BlockLink", {
4664
4828
  enumerable: true,
4665
- get: function () { return chunkAHWIZJ4M_cjs.BlockLink; }
4829
+ get: function () { return chunk6MFI2HPX_cjs.BlockLink; }
4666
4830
  });
4667
4831
  Object.defineProperty(exports, "CTABanner", {
4668
4832
  enumerable: true,
4669
- get: function () { return chunkAHWIZJ4M_cjs.CTABanner; }
4833
+ get: function () { return chunk6MFI2HPX_cjs.CTABanner; }
4670
4834
  });
4671
4835
  Object.defineProperty(exports, "Callout", {
4672
4836
  enumerable: true,
4673
- get: function () { return chunkAHWIZJ4M_cjs.Callout; }
4837
+ get: function () { return chunk6MFI2HPX_cjs.Callout; }
4674
4838
  });
4675
4839
  Object.defineProperty(exports, "Columns", {
4676
4840
  enumerable: true,
4677
- get: function () { return chunkAHWIZJ4M_cjs.Columns; }
4841
+ get: function () { return chunk6MFI2HPX_cjs.Columns; }
4678
4842
  });
4679
4843
  Object.defineProperty(exports, "ContactForm", {
4680
4844
  enumerable: true,
4681
- get: function () { return chunkAHWIZJ4M_cjs.ContactForm; }
4845
+ get: function () { return chunk6MFI2HPX_cjs.ContactForm; }
4682
4846
  });
4683
4847
  Object.defineProperty(exports, "Container", {
4684
4848
  enumerable: true,
4685
- get: function () { return chunkAHWIZJ4M_cjs.Container; }
4849
+ get: function () { return chunk6MFI2HPX_cjs.Container; }
4686
4850
  });
4687
4851
  Object.defineProperty(exports, "FAQ", {
4688
4852
  enumerable: true,
4689
- get: function () { return chunkAHWIZJ4M_cjs.FAQ; }
4853
+ get: function () { return chunk6MFI2HPX_cjs.FAQ; }
4690
4854
  });
4691
4855
  Object.defineProperty(exports, "FONT_PAIRINGS", {
4692
4856
  enumerable: true,
4693
- get: function () { return chunkAHWIZJ4M_cjs.FONT_PAIRINGS; }
4857
+ get: function () { return chunk6MFI2HPX_cjs.FONT_PAIRINGS; }
4694
4858
  });
4695
4859
  Object.defineProperty(exports, "FeatureGrid", {
4696
4860
  enumerable: true,
4697
- get: function () { return chunkAHWIZJ4M_cjs.FeatureGrid; }
4861
+ get: function () { return chunk6MFI2HPX_cjs.FeatureGrid; }
4698
4862
  });
4699
4863
  Object.defineProperty(exports, "Footer", {
4700
4864
  enumerable: true,
4701
- get: function () { return chunkAHWIZJ4M_cjs.Footer; }
4865
+ get: function () { return chunk6MFI2HPX_cjs.Footer; }
4702
4866
  });
4703
4867
  Object.defineProperty(exports, "Gallery", {
4704
4868
  enumerable: true,
4705
- get: function () { return chunkAHWIZJ4M_cjs.Gallery; }
4869
+ get: function () { return chunk6MFI2HPX_cjs.Gallery; }
4706
4870
  });
4707
4871
  Object.defineProperty(exports, "Hero", {
4708
4872
  enumerable: true,
4709
- get: function () { return chunkAHWIZJ4M_cjs.Hero; }
4873
+ get: function () { return chunk6MFI2HPX_cjs.Hero; }
4710
4874
  });
4711
4875
  Object.defineProperty(exports, "ListBlock", {
4712
4876
  enumerable: true,
4713
- get: function () { return chunkAHWIZJ4M_cjs.ListBlock; }
4877
+ get: function () { return chunk6MFI2HPX_cjs.ListBlock; }
4714
4878
  });
4715
4879
  Object.defineProperty(exports, "LogoCloud", {
4716
4880
  enumerable: true,
4717
- get: function () { return chunkAHWIZJ4M_cjs.LogoCloud; }
4881
+ get: function () { return chunk6MFI2HPX_cjs.LogoCloud; }
4718
4882
  });
4719
4883
  Object.defineProperty(exports, "MediaText", {
4720
4884
  enumerable: true,
4721
- get: function () { return chunkAHWIZJ4M_cjs.MediaText; }
4885
+ get: function () { return chunk6MFI2HPX_cjs.MediaText; }
4722
4886
  });
4723
4887
  Object.defineProperty(exports, "Navbar", {
4724
4888
  enumerable: true,
4725
- get: function () { return chunkAHWIZJ4M_cjs.Navbar; }
4889
+ get: function () { return chunk6MFI2HPX_cjs.Navbar; }
4726
4890
  });
4727
4891
  Object.defineProperty(exports, "PricingTable", {
4728
4892
  enumerable: true,
4729
- get: function () { return chunkAHWIZJ4M_cjs.PricingTable; }
4893
+ get: function () { return chunk6MFI2HPX_cjs.PricingTable; }
4730
4894
  });
4731
4895
  Object.defineProperty(exports, "RichTextBlock", {
4732
4896
  enumerable: true,
4733
- get: function () { return chunkAHWIZJ4M_cjs.RichTextBlock; }
4897
+ get: function () { return chunk6MFI2HPX_cjs.RichTextBlock; }
4734
4898
  });
4735
4899
  Object.defineProperty(exports, "SectionHeading", {
4736
4900
  enumerable: true,
4737
- get: function () { return chunkAHWIZJ4M_cjs.SectionHeading; }
4901
+ get: function () { return chunk6MFI2HPX_cjs.SectionHeading; }
4738
4902
  });
4739
4903
  Object.defineProperty(exports, "Spacer", {
4740
4904
  enumerable: true,
4741
- get: function () { return chunkAHWIZJ4M_cjs.Spacer; }
4905
+ get: function () { return chunk6MFI2HPX_cjs.Spacer; }
4742
4906
  });
4743
4907
  Object.defineProperty(exports, "Steps", {
4744
4908
  enumerable: true,
4745
- get: function () { return chunkAHWIZJ4M_cjs.Steps; }
4909
+ get: function () { return chunk6MFI2HPX_cjs.Steps; }
4746
4910
  });
4747
4911
  Object.defineProperty(exports, "THEME_STYLE_ID", {
4748
4912
  enumerable: true,
4749
- get: function () { return chunkAHWIZJ4M_cjs.THEME_STYLE_ID; }
4913
+ get: function () { return chunk6MFI2HPX_cjs.THEME_STYLE_ID; }
4750
4914
  });
4751
4915
  Object.defineProperty(exports, "Tabs", {
4752
4916
  enumerable: true,
4753
- get: function () { return chunkAHWIZJ4M_cjs.Tabs; }
4917
+ get: function () { return chunk6MFI2HPX_cjs.Tabs; }
4754
4918
  });
4755
4919
  Object.defineProperty(exports, "TeamGrid", {
4756
4920
  enumerable: true,
4757
- get: function () { return chunkAHWIZJ4M_cjs.TeamGrid; }
4921
+ get: function () { return chunk6MFI2HPX_cjs.TeamGrid; }
4758
4922
  });
4759
4923
  Object.defineProperty(exports, "Testimonial", {
4760
4924
  enumerable: true,
4761
- get: function () { return chunkAHWIZJ4M_cjs.Testimonial; }
4925
+ get: function () { return chunk6MFI2HPX_cjs.Testimonial; }
4762
4926
  });
4763
4927
  Object.defineProperty(exports, "TestimonialGrid", {
4764
4928
  enumerable: true,
4765
- get: function () { return chunkAHWIZJ4M_cjs.TestimonialGrid; }
4929
+ get: function () { return chunk6MFI2HPX_cjs.TestimonialGrid; }
4766
4930
  });
4767
4931
  Object.defineProperty(exports, "ThemeEditor", {
4768
4932
  enumerable: true,
4769
- get: function () { return chunkAHWIZJ4M_cjs.ThemeEditor; }
4933
+ get: function () { return chunk6MFI2HPX_cjs.ThemeEditor; }
4770
4934
  });
4771
4935
  Object.defineProperty(exports, "VideoEmbed", {
4772
4936
  enumerable: true,
4773
- get: function () { return chunkAHWIZJ4M_cjs.VideoEmbed; }
4937
+ get: function () { return chunk6MFI2HPX_cjs.VideoEmbed; }
4774
4938
  });
4775
4939
  Object.defineProperty(exports, "applyFontVars", {
4776
4940
  enumerable: true,
4777
- get: function () { return chunkAHWIZJ4M_cjs.applyFontVars; }
4941
+ get: function () { return chunk6MFI2HPX_cjs.applyFontVars; }
4778
4942
  });
4779
4943
  Object.defineProperty(exports, "applyStoredTheme", {
4780
4944
  enumerable: true,
4781
- get: function () { return chunkAHWIZJ4M_cjs.applyStoredTheme; }
4945
+ get: function () { return chunk6MFI2HPX_cjs.applyStoredTheme; }
4782
4946
  });
4783
4947
  Object.defineProperty(exports, "applyThemeVars", {
4784
4948
  enumerable: true,
4785
- get: function () { return chunkAHWIZJ4M_cjs.applyThemeVars; }
4949
+ get: function () { return chunk6MFI2HPX_cjs.applyThemeVars; }
4786
4950
  });
4787
4951
  Object.defineProperty(exports, "asAssetRef", {
4788
4952
  enumerable: true,
4789
- get: function () { return chunkAHWIZJ4M_cjs.asAssetRef; }
4953
+ get: function () { return chunk6MFI2HPX_cjs.asAssetRef; }
4790
4954
  });
4791
4955
  Object.defineProperty(exports, "assetRefId", {
4792
4956
  enumerable: true,
4793
- get: function () { return chunkAHWIZJ4M_cjs.assetRefId; }
4957
+ get: function () { return chunk6MFI2HPX_cjs.assetRefId; }
4794
4958
  });
4795
4959
  Object.defineProperty(exports, "clearFontVars", {
4796
4960
  enumerable: true,
4797
- get: function () { return chunkAHWIZJ4M_cjs.clearFontVars; }
4961
+ get: function () { return chunk6MFI2HPX_cjs.clearFontVars; }
4798
4962
  });
4799
4963
  Object.defineProperty(exports, "clearThemeVars", {
4800
4964
  enumerable: true,
4801
- get: function () { return chunkAHWIZJ4M_cjs.clearThemeVars; }
4965
+ get: function () { return chunk6MFI2HPX_cjs.clearThemeVars; }
4802
4966
  });
4803
4967
  Object.defineProperty(exports, "createThemeStore", {
4804
4968
  enumerable: true,
4805
- get: function () { return chunkAHWIZJ4M_cjs.createThemeStore; }
4969
+ get: function () { return chunk6MFI2HPX_cjs.createThemeStore; }
4806
4970
  });
4807
4971
  Object.defineProperty(exports, "daysUntil", {
4808
4972
  enumerable: true,
4809
- get: function () { return chunkAHWIZJ4M_cjs.daysUntil; }
4973
+ get: function () { return chunk6MFI2HPX_cjs.daysUntil; }
4810
4974
  });
4811
4975
  Object.defineProperty(exports, "fmtDate", {
4812
4976
  enumerable: true,
4813
- get: function () { return chunkAHWIZJ4M_cjs.fmtDate; }
4977
+ get: function () { return chunk6MFI2HPX_cjs.fmtDate; }
4814
4978
  });
4815
4979
  Object.defineProperty(exports, "fmtDateTime", {
4816
4980
  enumerable: true,
4817
- get: function () { return chunkAHWIZJ4M_cjs.fmtDateTime; }
4981
+ get: function () { return chunk6MFI2HPX_cjs.fmtDateTime; }
4818
4982
  });
4819
4983
  Object.defineProperty(exports, "fontPackages", {
4820
4984
  enumerable: true,
4821
- get: function () { return chunkAHWIZJ4M_cjs.fontPackages; }
4985
+ get: function () { return chunk6MFI2HPX_cjs.fontPackages; }
4986
+ });
4987
+ Object.defineProperty(exports, "formatPageRefs", {
4988
+ enumerable: true,
4989
+ get: function () { return chunk6MFI2HPX_cjs.formatPageRefs; }
4822
4990
  });
4823
4991
  Object.defineProperty(exports, "fromNow", {
4824
4992
  enumerable: true,
4825
- get: function () { return chunkAHWIZJ4M_cjs.fromNow; }
4993
+ get: function () { return chunk6MFI2HPX_cjs.fromNow; }
4826
4994
  });
4827
4995
  Object.defineProperty(exports, "gbp", {
4828
4996
  enumerable: true,
4829
- get: function () { return chunkAHWIZJ4M_cjs.gbp; }
4997
+ get: function () { return chunk6MFI2HPX_cjs.gbp; }
4830
4998
  });
4831
4999
  Object.defineProperty(exports, "getFontPairing", {
4832
5000
  enumerable: true,
4833
- get: function () { return chunkAHWIZJ4M_cjs.getFontPairing; }
5001
+ get: function () { return chunk6MFI2HPX_cjs.getFontPairing; }
4834
5002
  });
4835
5003
  Object.defineProperty(exports, "hrs", {
4836
5004
  enumerable: true,
4837
- get: function () { return chunkAHWIZJ4M_cjs.hrs; }
5005
+ get: function () { return chunk6MFI2HPX_cjs.hrs; }
4838
5006
  });
4839
5007
  Object.defineProperty(exports, "initials", {
4840
5008
  enumerable: true,
4841
- get: function () { return chunkAHWIZJ4M_cjs.initials; }
5009
+ get: function () { return chunk6MFI2HPX_cjs.initials; }
4842
5010
  });
4843
5011
  Object.defineProperty(exports, "isAssetRef", {
4844
5012
  enumerable: true,
4845
- get: function () { return chunkAHWIZJ4M_cjs.isAssetRef; }
5013
+ get: function () { return chunk6MFI2HPX_cjs.isAssetRef; }
4846
5014
  });
4847
5015
  Object.defineProperty(exports, "matchFontPairing", {
4848
5016
  enumerable: true,
4849
- get: function () { return chunkAHWIZJ4M_cjs.matchFontPairing; }
5017
+ get: function () { return chunk6MFI2HPX_cjs.matchFontPairing; }
4850
5018
  });
4851
5019
  Object.defineProperty(exports, "pct", {
4852
5020
  enumerable: true,
4853
- get: function () { return chunkAHWIZJ4M_cjs.pct; }
5021
+ get: function () { return chunk6MFI2HPX_cjs.pct; }
4854
5022
  });
4855
5023
  Object.defineProperty(exports, "tid", {
4856
5024
  enumerable: true,
4857
- get: function () { return chunkAHWIZJ4M_cjs.tid; }
5025
+ get: function () { return chunk6MFI2HPX_cjs.tid; }
4858
5026
  });
4859
5027
  Object.defineProperty(exports, "toEmbedUrl", {
4860
5028
  enumerable: true,
4861
- get: function () { return chunkAHWIZJ4M_cjs.toEmbedUrl; }
5029
+ get: function () { return chunk6MFI2HPX_cjs.toEmbedUrl; }
4862
5030
  });
4863
5031
  Object.defineProperty(exports, "toHslTriplet", {
4864
5032
  enumerable: true,
4865
- get: function () { return chunkAHWIZJ4M_cjs.toHslTriplet; }
5033
+ get: function () { return chunk6MFI2HPX_cjs.toHslTriplet; }
4866
5034
  });
4867
5035
  Object.defineProperty(exports, "useAssetRenderer", {
4868
5036
  enumerable: true,
4869
- get: function () { return chunkAHWIZJ4M_cjs.useAssetRenderer; }
5037
+ get: function () { return chunk6MFI2HPX_cjs.useAssetRenderer; }
4870
5038
  });
4871
5039
  Object.defineProperty(exports, "useAssetResolverActive", {
4872
5040
  enumerable: true,
4873
- get: function () { return chunkAHWIZJ4M_cjs.useAssetResolverActive; }
5041
+ get: function () { return chunk6MFI2HPX_cjs.useAssetResolverActive; }
4874
5042
  });
4875
5043
  Object.defineProperty(exports, "DocumentCard", {
4876
5044
  enumerable: true,
@@ -4932,6 +5100,7 @@ exports.AgentsPanel = AgentsPanel;
4932
5100
  exports.AppHeader = AppHeader;
4933
5101
  exports.AppShell = AppShell;
4934
5102
  exports.AssetThumb = AssetThumb;
5103
+ exports.CitationEditor = CitationEditor;
4935
5104
  exports.ConnectionProvider = ConnectionProvider;
4936
5105
  exports.DataTable = DataTable;
4937
5106
  exports.DataTableBlock = DataTableBlock;