@homebound/beam 3.102.0 → 3.104.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
@@ -8163,6 +8163,34 @@ function InlineLabel({
8163
8163
  ] });
8164
8164
  }
8165
8165
 
8166
+ // src/components/ProposedValue.tsx
8167
+ import { trussProps as trussProps20 } from "@homebound/truss/runtime";
8168
+ import { Fragment as Fragment7, jsx as jsx27, jsxs as jsxs13 } from "react/jsx-runtime";
8169
+ function ProposedValue(props) {
8170
+ const {
8171
+ original,
8172
+ proposed
8173
+ } = props;
8174
+ const tid = useTestIds(props, "proposedValue");
8175
+ return /* @__PURE__ */ jsxs13("span", { ...tid, children: [
8176
+ original && /* @__PURE__ */ jsxs13(Fragment7, { children: [
8177
+ /* @__PURE__ */ jsx27("span", { ...trussProps20({
8178
+ textDecoration: "tdlt",
8179
+ color: ["color_var", {
8180
+ "--color": "var(--b-on-surface-muted)"
8181
+ }]
8182
+ }), ...tid.original, children: original }),
8183
+ " "
8184
+ ] }),
8185
+ /* @__PURE__ */ jsx27("span", { ...trussProps20({
8186
+ fontWeight: "fw6",
8187
+ color: ["color_var", {
8188
+ "--color": "var(--b-ai-field-fg)"
8189
+ }]
8190
+ }), ...tid.proposed, children: proposed })
8191
+ ] });
8192
+ }
8193
+
8166
8194
  // src/components/Table/components/Row.tsx
8167
8195
  import { observer } from "mobx-react";
8168
8196
  import React7, { useCallback as useCallback8, useContext as useContext12, useRef as useRef11 } from "react";
@@ -8171,10 +8199,10 @@ import { mergeProps as mergeProps5 } from "react-aria";
8171
8199
  // src/components/Table/components/cell.tsx
8172
8200
  import { Link as Link2 } from "react-router-dom";
8173
8201
  import { mergeProps as mergeProps4 } from "@homebound/truss/runtime";
8174
- import { jsx as jsx27 } from "react/jsx-runtime";
8202
+ import { jsx as jsx28 } from "react/jsx-runtime";
8175
8203
  var defaultRenderFn = (as, colSpan) => (key, css2, content, row, rowStyle, classNames, onClick, tooltip) => {
8176
8204
  const Cell = as === "table" ? "td" : "div";
8177
- return /* @__PURE__ */ jsx27(Cell, { ...mergeProps4(classNames, void 0, {
8205
+ return /* @__PURE__ */ jsx28(Cell, { ...mergeProps4(classNames, void 0, {
8178
8206
  ...css2,
8179
8207
  ...{
8180
8208
  cursor: "cursor_default"
@@ -8185,7 +8213,7 @@ var defaultRenderFn = (as, colSpan) => (key, css2, content, row, rowStyle, class
8185
8213
  };
8186
8214
  var headerRenderFn = (column2, as, colSpan) => (key, css2, content, row, rowStyle, classNames, onClick, tooltip) => {
8187
8215
  const Cell = as === "table" ? "th" : "div";
8188
- return /* @__PURE__ */ jsx27(Cell, { ...mergeProps4(classNames, void 0, {
8216
+ return /* @__PURE__ */ jsx28(Cell, { ...mergeProps4(classNames, void 0, {
8189
8217
  ...css2
8190
8218
  }), ...as === "table" && {
8191
8219
  colSpan
@@ -8194,15 +8222,15 @@ var headerRenderFn = (column2, as, colSpan) => (key, css2, content, row, rowStyl
8194
8222
  var rowLinkRenderFn = (as, colSpan) => (key, css2, content, row, rowStyle, classNames, onClick, tooltip) => {
8195
8223
  const to = rowStyle.rowLink(row);
8196
8224
  if (as === "table") {
8197
- return /* @__PURE__ */ jsx27("td", { ...mergeProps4(classNames, void 0, {
8225
+ return /* @__PURE__ */ jsx28("td", { ...mergeProps4(classNames, void 0, {
8198
8226
  ...css2
8199
- }), colSpan, children: /* @__PURE__ */ jsx27(Link2, { to, ...mergeProps4(navLink, void 0, {
8227
+ }), colSpan, children: /* @__PURE__ */ jsx28(Link2, { to, ...mergeProps4(navLink, void 0, {
8200
8228
  textDecoration: "tdn",
8201
8229
  color: "color_unset",
8202
8230
  display: "db"
8203
8231
  }), children: content }) }, key);
8204
8232
  }
8205
- return /* @__PURE__ */ jsx27(Link2, { to, ...mergeProps4(`${navLink} ${classNames}`, void 0, {
8233
+ return /* @__PURE__ */ jsx28(Link2, { to, ...mergeProps4(`${navLink} ${classNames}`, void 0, {
8206
8234
  ...{
8207
8235
  textDecoration: "tdn",
8208
8236
  color: "color_unset"
@@ -8212,7 +8240,7 @@ var rowLinkRenderFn = (as, colSpan) => (key, css2, content, row, rowStyle, class
8212
8240
  };
8213
8241
  var rowClickRenderFn = (as, api, colSpan) => (key, css2, content, row, rowStyle, classNames, onClick, tooltip) => {
8214
8242
  const Cell = as === "table" ? "td" : "div";
8215
- return /* @__PURE__ */ jsx27(Cell, { ...mergeProps4(classNames, void 0, {
8243
+ return /* @__PURE__ */ jsx28(Cell, { ...mergeProps4(classNames, void 0, {
8216
8244
  ...css2
8217
8245
  }), onClick: (e) => {
8218
8246
  rowStyle.onClick(row, api);
@@ -8224,8 +8252,8 @@ var rowClickRenderFn = (as, api, colSpan) => (key, css2, content, row, rowStyle,
8224
8252
 
8225
8253
  // src/components/Table/components/ColumnResizeHandle.tsx
8226
8254
  import { useCallback as useCallback7, useContext as useContext10, useEffect as useEffect7, useRef as useRef10, useState as useState11 } from "react";
8227
- import { trussProps as trussProps20, maybeCssVar as maybeCssVar10 } from "@homebound/truss/runtime";
8228
- import { Fragment as Fragment7, jsx as jsx28, jsxs as jsxs13 } from "react/jsx-runtime";
8255
+ import { trussProps as trussProps21, maybeCssVar as maybeCssVar10 } from "@homebound/truss/runtime";
8256
+ import { Fragment as Fragment8, jsx as jsx29, jsxs as jsxs14 } from "react/jsx-runtime";
8229
8257
  function findScrollableParent(element) {
8230
8258
  if (!element) return null;
8231
8259
  let parent = element.parentElement;
@@ -8388,8 +8416,8 @@ function ColumnResizeHandle({
8388
8416
  document.body.style.userSelect = "";
8389
8417
  };
8390
8418
  }, []);
8391
- return /* @__PURE__ */ jsxs13(Fragment7, { children: [
8392
- /* @__PURE__ */ jsx28("div", { ref: handleRef, onMouseDown: handleMouseDown, onMouseEnter: () => setIsHovering(true), onMouseLeave: () => !isDragging && setIsHovering(false), ...trussProps20({
8419
+ return /* @__PURE__ */ jsxs14(Fragment8, { children: [
8420
+ /* @__PURE__ */ jsx29("div", { ref: handleRef, onMouseDown: handleMouseDown, onMouseEnter: () => setIsHovering(true), onMouseLeave: () => !isDragging && setIsHovering(false), ...trussProps21({
8393
8421
  position: "absolute",
8394
8422
  top: "top0",
8395
8423
  bottom: "bottom0",
@@ -8406,7 +8434,7 @@ function ColumnResizeHandle({
8406
8434
  }]
8407
8435
  } : {}
8408
8436
  }), ...tid.handle, "data-column-id": columnId, "data-column-index": columnIndex }),
8409
- isDragging && guideLineX !== null && /* @__PURE__ */ jsx28("div", { ...trussProps20({
8437
+ isDragging && guideLineX !== null && /* @__PURE__ */ jsx29("div", { ...trussProps21({
8410
8438
  position: "fixed",
8411
8439
  top: ["top_var", {
8412
8440
  "--top": `${guideLineTop}px`
@@ -8432,8 +8460,8 @@ function ColumnResizeHandle({
8432
8460
 
8433
8461
  // src/components/Table/components/KeptGroupRow.tsx
8434
8462
  import { useContext as useContext11 } from "react";
8435
- import { trussProps as trussProps21, maybeCssVar as maybeCssVar11 } from "@homebound/truss/runtime";
8436
- import { jsx as jsx29, jsxs as jsxs14 } from "react/jsx-runtime";
8463
+ import { trussProps as trussProps22, maybeCssVar as maybeCssVar11 } from "@homebound/truss/runtime";
8464
+ import { jsx as jsx30, jsxs as jsxs15 } from "react/jsx-runtime";
8437
8465
  var __maybeInc5 = (inc) => {
8438
8466
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
8439
8467
  };
@@ -8451,7 +8479,7 @@ function KeptGroupRow(props) {
8451
8479
  tableState
8452
8480
  } = useContext11(TableStateContext);
8453
8481
  const numHiddenSelectedRows = useComputed(() => tableState.keptRows.length, [tableState]);
8454
- return /* @__PURE__ */ jsx29(CellTag, { ...trussProps21({
8482
+ return /* @__PURE__ */ jsx30(CellTag, { ...trussProps22({
8455
8483
  ...style.cellCss,
8456
8484
  ...style.betweenRowsCss,
8457
8485
  ...isLastBodyRow && style.lastRowCellCss,
@@ -8466,10 +8494,10 @@ function KeptGroupRow(props) {
8466
8494
  }
8467
8495
  }), ...as === "table" ? {
8468
8496
  colSpan
8469
- } : {}, children: /* @__PURE__ */ jsxs14("div", { className: "df aic gap_12px", children: [
8470
- /* @__PURE__ */ jsx29("div", { className: "w_38px df jcc", children: /* @__PURE__ */ jsx29(CollapseToggle, { row, compact: true }) }),
8471
- /* @__PURE__ */ jsxs14("div", { className: "df aic gap1", children: [
8472
- /* @__PURE__ */ jsx29(Icon, { icon: "infoCircle", inc: 2 }),
8497
+ } : {}, children: /* @__PURE__ */ jsxs15("div", { className: "df aic gap_12px", children: [
8498
+ /* @__PURE__ */ jsx30("div", { className: "w_38px df jcc", children: /* @__PURE__ */ jsx30(CollapseToggle, { row, compact: true }) }),
8499
+ /* @__PURE__ */ jsxs15("div", { className: "df aic gap1", children: [
8500
+ /* @__PURE__ */ jsx30(Icon, { icon: "infoCircle", inc: 2 }),
8473
8501
  `${numHiddenSelectedRows} selected ${pluralize(numHiddenSelectedRows, "row")} hidden due to filters`
8474
8502
  ] })
8475
8503
  ] }) });
@@ -8950,8 +8978,8 @@ function resolveStyles(style) {
8950
8978
 
8951
8979
  // src/components/Table/components/Row.tsx
8952
8980
  import { useDebouncedCallback as useDebouncedCallback2 } from "use-debounce";
8953
- import { trussProps as trussProps22, mergeProps as mergeProps_12, maybeCssVar as maybeCssVar_12 } from "@homebound/truss/runtime";
8954
- import { Fragment as Fragment8, jsx as jsx30, jsxs as jsxs15 } from "react/jsx-runtime";
8981
+ import { trussProps as trussProps23, mergeProps as mergeProps_12, maybeCssVar as maybeCssVar_12 } from "@homebound/truss/runtime";
8982
+ import { Fragment as Fragment9, jsx as jsx31, jsxs as jsxs16 } from "react/jsx-runtime";
8955
8983
  var __maybeInc6 = (inc) => {
8956
8984
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
8957
8985
  };
@@ -9123,12 +9151,12 @@ function RowImpl(props) {
9123
9151
  const ref = useRef11(null);
9124
9152
  const dragOverCallback = useCallback8((row2, evt) => onDragOver?.(row2, evt), [onDragOver]);
9125
9153
  const onDragOverDebounced = useDebouncedCallback2(dragOverCallback, 100);
9126
- const RowContent = () => /* @__PURE__ */ jsx30(RowTag, { ...mergeProps_12(`${BorderHoverParent}${showRowHoverColor ? ` ${RowHoverClass}` : ""}`, void 0, rowCss), ...others, "data-gridrow": true, ...getCount(row.id), ref, children: isKeptGroupRow ? /* @__PURE__ */ jsx30(KeptGroupRow, { as, style, columnSizes, row, colSpan: columns.length, isLastBodyRow }) : columns.map((column2, columnIndex) => {
9154
+ const RowContent = () => /* @__PURE__ */ jsx31(RowTag, { ...mergeProps_12(`${BorderHoverParent}${showRowHoverColor ? ` ${RowHoverClass}` : ""}`, void 0, rowCss), ...others, "data-gridrow": true, ...getCount(row.id), ref, children: isKeptGroupRow ? /* @__PURE__ */ jsx31(KeptGroupRow, { as, style, columnSizes, row, colSpan: columns.length, isLastBodyRow }) : columns.map((column2, columnIndex) => {
9127
9155
  const maybeExpandedColumn = expandColumnHidden ? columns[columnIndex - 1] : column2;
9128
9156
  const isExpanded = tableState.isExpandedColumn(maybeExpandedColumn.id);
9129
9157
  if (column2.hideOnExpand && isExpanded) {
9130
9158
  expandColumnHidden = true;
9131
- return /* @__PURE__ */ jsx30(Fragment8, {});
9159
+ return /* @__PURE__ */ jsx31(Fragment9, {});
9132
9160
  }
9133
9161
  const numExpandedColumns = isExpanded ? tableState.numberOfExpandedChildren(maybeExpandedColumn.id) ? (
9134
9162
  // Subtract 1 if the column is hidden on expand, since we're not rendering it.
@@ -9309,24 +9337,24 @@ function RowImpl(props) {
9309
9337
  const currentSizeStr = columnSizes[columnIndex];
9310
9338
  const minWidthPx = column2.mw ? parseInt(column2.mw.replace("px", ""), 10) : 100;
9311
9339
  const currentWidthPx = parseWidthToPx(currentSizeStr, void 0) ?? resizedWidths?.[column2.id] ?? minWidthPx;
9312
- const cellElementWithHandle = React7.cloneElement(cellElement, mergeProps5(cellElement.props, trussProps22({
9340
+ const cellElementWithHandle = React7.cloneElement(cellElement, mergeProps5(cellElement.props, trussProps23({
9313
9341
  ...!maybeSticky && {
9314
9342
  position: "relative"
9315
9343
  }
9316
9344
  }), {
9317
- children: /* @__PURE__ */ jsxs15(Fragment8, { children: [
9345
+ children: /* @__PURE__ */ jsxs16(Fragment9, { children: [
9318
9346
  cellElement.props.children,
9319
- /* @__PURE__ */ jsx30(ColumnResizeHandle, { columnId: column2.id, columnIndex, currentWidth: currentWidthPx, minWidth: minWidthPx, onResize: (colId, width2) => setResizedWidth?.(colId, width2, columnIndex), calculatePreviewWidth })
9347
+ /* @__PURE__ */ jsx31(ColumnResizeHandle, { columnId: column2.id, columnIndex, currentWidth: currentWidthPx, minWidth: minWidthPx, onResize: (colId, width2) => setResizedWidth?.(colId, width2, columnIndex), calculatePreviewWidth })
9320
9348
  ] })
9321
9349
  }));
9322
9350
  return cellElementWithHandle;
9323
9351
  }
9324
9352
  return cellElement;
9325
9353
  }) });
9326
- return row.draggable ? /* @__PURE__ */ jsx30(
9354
+ return row.draggable ? /* @__PURE__ */ jsx31(
9327
9355
  "div",
9328
9356
  {
9329
- ...trussProps22(containerCss),
9357
+ ...trussProps23(containerCss),
9330
9358
  onDrop: (evt) => onDrop?.(row, evt),
9331
9359
  onDragEnter: (evt) => onDragEnter?.(row, evt),
9332
9360
  onDragOver: (evt) => {
@@ -9335,7 +9363,7 @@ function RowImpl(props) {
9335
9363
  },
9336
9364
  children: RowContent()
9337
9365
  }
9338
- ) : /* @__PURE__ */ jsx30(Fragment8, { children: RowContent() });
9366
+ ) : /* @__PURE__ */ jsx31(Fragment9, { children: RowContent() });
9339
9367
  }
9340
9368
  var Row = observer(RowImpl);
9341
9369
  var BorderHoverParent = "beam-bhp";
@@ -9365,8 +9393,8 @@ function useLabelSuffix(required, readOnly) {
9365
9393
 
9366
9394
  // src/inputs/ErrorMessage.tsx
9367
9395
  import { VisuallyHidden as VisuallyHidden2 } from "react-aria";
9368
- import { trussProps as trussProps23 } from "@homebound/truss/runtime";
9369
- import { Fragment as Fragment9, jsx as jsx31, jsxs as jsxs16 } from "react/jsx-runtime";
9396
+ import { trussProps as trussProps24 } from "@homebound/truss/runtime";
9397
+ import { Fragment as Fragment10, jsx as jsx32, jsxs as jsxs17 } from "react/jsx-runtime";
9370
9398
  function ErrorMessage(props) {
9371
9399
  const {
9372
9400
  id,
@@ -9374,7 +9402,7 @@ function ErrorMessage(props) {
9374
9402
  hidden = false,
9375
9403
  ...others
9376
9404
  } = props;
9377
- const errorEl = errorMsg ? /* @__PURE__ */ jsxs16("div", { ...trussProps23({
9405
+ const errorEl = errorMsg ? /* @__PURE__ */ jsxs17("div", { ...trussProps24({
9378
9406
  color: ["color_var", {
9379
9407
  "--color": "var(--b-danger)"
9380
9408
  }],
@@ -9384,38 +9412,10 @@ function ErrorMessage(props) {
9384
9412
  display: "df",
9385
9413
  marginTop: "mt_4px"
9386
9414
  }), children: [
9387
- /* @__PURE__ */ jsx31("span", { className: "fs0", children: /* @__PURE__ */ jsx31(Icon, { icon: "error" }) }),
9388
- /* @__PURE__ */ jsx31("span", { id, className: "ml1 mt_2px", ...others, children: errorMsg })
9389
- ] }) : /* @__PURE__ */ jsx31(Fragment9, {});
9390
- return hidden ? /* @__PURE__ */ jsx31(VisuallyHidden2, { children: errorEl }) : errorEl;
9391
- }
9392
-
9393
- // src/inputs/internal/ProposedValue.tsx
9394
- import { trussProps as trussProps24 } from "@homebound/truss/runtime";
9395
- import { Fragment as Fragment10, jsx as jsx32, jsxs as jsxs17 } from "react/jsx-runtime";
9396
- function ProposedValue(props) {
9397
- const {
9398
- original,
9399
- proposed
9400
- } = props;
9401
- const tid = useTestIds(props, "proposedValue");
9402
- return /* @__PURE__ */ jsxs17("span", { ...tid, children: [
9403
- original && /* @__PURE__ */ jsxs17(Fragment10, { children: [
9404
- /* @__PURE__ */ jsx32("span", { ...trussProps24({
9405
- textDecoration: "tdlt",
9406
- color: ["color_var", {
9407
- "--color": "var(--b-on-surface-muted)"
9408
- }]
9409
- }), ...tid.original, children: original }),
9410
- " "
9411
- ] }),
9412
- /* @__PURE__ */ jsx32("span", { ...trussProps24({
9413
- fontWeight: "fw6",
9414
- color: ["color_var", {
9415
- "--color": "var(--b-ai-field-fg)"
9416
- }]
9417
- }), ...tid.proposed, children: proposed })
9418
- ] });
9415
+ /* @__PURE__ */ jsx32("span", { className: "fs0", children: /* @__PURE__ */ jsx32(Icon, { icon: "error" }) }),
9416
+ /* @__PURE__ */ jsx32("span", { id, className: "ml1 mt_2px", ...others, children: errorMsg })
9417
+ ] }) : /* @__PURE__ */ jsx32(Fragment10, {});
9418
+ return hidden ? /* @__PURE__ */ jsx32(VisuallyHidden2, { children: errorEl }) : errorEl;
9419
9419
  }
9420
9420
 
9421
9421
  // src/inputs/utils.ts
@@ -17601,6 +17601,7 @@ function TableCardView(props) {
17601
17601
  aiMode = false
17602
17602
  } = props;
17603
17603
  const tid = useTestIds(props, "tableCardView");
17604
+ const titleText = typeof title === "string" ? title : title.proposed;
17604
17605
  const action = to || onClick;
17605
17606
  const progressValue = useMemo27(() => progress !== void 0 ? clampProgress(progress) : 0, [progress]);
17606
17607
  const shownFooter = shownInteractiveFooter(interactiveFooter);
@@ -17613,7 +17614,7 @@ function TableCardView(props) {
17613
17614
  } = useFocusRing11();
17614
17615
  const actionAttrs = {
17615
17616
  ...tid.action,
17616
- "aria-label": title,
17617
+ "aria-label": titleText,
17617
17618
  // `getButtonOrLink` renders its `<button>` without a type, which would default to submit inside a form.
17618
17619
  type: typeof action === "string" ? void 0 : "button",
17619
17620
  ...trussProps63(contentStyles),
@@ -17627,7 +17628,7 @@ function TableCardView(props) {
17627
17628
  borderBottomStyle: "bbs_solid",
17628
17629
  borderBottomWidth: "bbw_1px",
17629
17630
  borderColor: ["bc_var", {
17630
- "--borderColor": "var(--b-field-border-default)"
17631
+ "--borderColor": maybeCssVar31(aiMode ? "--b-ai-field-bg" /* AiFieldBg */ : "--b-field-border-default" /* FieldBorderDefault */)
17631
17632
  }],
17632
17633
  overflow: "oh",
17633
17634
  borderRadius: "borderRadius_12px_12px_0_0"
@@ -17638,7 +17639,7 @@ function TableCardView(props) {
17638
17639
  objectFit: ["objectFit_var", {
17639
17640
  "--objectFit": maybeCssVar31(imageFit)
17640
17641
  }]
17641
- }), src: imgSrc, alt: title, loading: "lazy", ...tid.image }),
17642
+ }), src: imgSrc, alt: titleText, loading: "lazy", ...tid.image }),
17642
17643
  status && /* @__PURE__ */ jsx97("div", { className: "absolute top1 left1 df", ...tid.status, children: /* @__PURE__ */ jsx97(Tag, { ...status }) })
17643
17644
  ] }),
17644
17645
  /* @__PURE__ */ jsxs51("div", { ...trussProps63({
@@ -17662,8 +17663,8 @@ function TableCardView(props) {
17662
17663
  "--color": "var(--b-on-surface)"
17663
17664
  }]
17664
17665
  }), ...tid.eyebrow, children: [
17665
- /* @__PURE__ */ jsx97("span", { className: "wsnw oh to_ellipsis", ...tid.leftEyebrow, children: leftEyebrow }),
17666
- rightEyebrow && /* @__PURE__ */ jsx97("span", { className: "fs0", ...tid.rightEyebrow, children: rightEyebrow })
17666
+ /* @__PURE__ */ jsx97("span", { className: "wsnw oh to_ellipsis", ...tid.leftEyebrow, children: renderMaybeProposed(leftEyebrow, tid.leftEyebrowProposal) }),
17667
+ rightEyebrow && /* @__PURE__ */ jsx97("span", { className: "fs0", ...tid.rightEyebrow, children: renderMaybeProposed(rightEyebrow, tid.rightEyebrowProposal) })
17667
17668
  ] }),
17668
17669
  /* @__PURE__ */ jsxs51("div", { className: "dif w100 jcsb aic", children: [
17669
17670
  /* @__PURE__ */ jsx97("h4", { ...trussProps63({
@@ -17678,7 +17679,7 @@ function TableCardView(props) {
17678
17679
  color: ["color_var", {
17679
17680
  "--color": "var(--b-on-surface)"
17680
17681
  }]
17681
- }), ...tid.title, children: title }),
17682
+ }), ...tid.title, children: renderMaybeProposed(title, tid.titleProposal) }),
17682
17683
  (badge || badgeTags?.length) && /* @__PURE__ */ jsxs51("div", { className: "dif aic gap1 fs0", ...tid.badge, children: [
17683
17684
  badge && /* @__PURE__ */ jsx97("span", { className: "fw4 fz_14px lh_20px wsnw", children: badge }),
17684
17685
  badgeTags?.map((tag) => /* @__PURE__ */ jsx97(Tag, { ...tag }, tag.text))
@@ -17697,19 +17698,19 @@ function TableCardView(props) {
17697
17698
  } : {}
17698
17699
  }), children: [
17699
17700
  data.length > 0 && /* @__PURE__ */ jsxs51("dl", { className: "df gap2 fw4 fz_14px lh_20px", children: [
17700
- /* @__PURE__ */ jsx97("div", { className: "df fdc fg1", children: col1.map((d) => /* @__PURE__ */ jsxs51("div", { className: "df gap_4px", ...tid[defaultTestId(d.label)], children: [
17701
- /* @__PURE__ */ jsxs51("dt", { children: [
17701
+ /* @__PURE__ */ jsx97("div", { className: "df fdc fg1 fb2 mw0", children: col1.map((d) => /* @__PURE__ */ jsxs51("div", { className: "df gap_4px", ...tid[defaultTestId(d.label)], children: [
17702
+ /* @__PURE__ */ jsxs51("dt", { className: "fs0", children: [
17702
17703
  d.label,
17703
17704
  ":"
17704
17705
  ] }),
17705
- /* @__PURE__ */ jsx97("dd", { children: d.value })
17706
+ /* @__PURE__ */ jsx97("dd", { className: "mw0", children: d.value })
17706
17707
  ] }, d.label)) }),
17707
- /* @__PURE__ */ jsx97("div", { className: "df fdc fg1", children: col2.map((d) => /* @__PURE__ */ jsxs51("div", { className: "df gap_4px", ...tid[defaultTestId(d.label)], children: [
17708
- /* @__PURE__ */ jsxs51("dt", { children: [
17708
+ /* @__PURE__ */ jsx97("div", { className: "df fdc fg1 fb2 mw0", children: col2.map((d) => /* @__PURE__ */ jsxs51("div", { className: "df gap_4px", ...tid[defaultTestId(d.label)], children: [
17709
+ /* @__PURE__ */ jsxs51("dt", { className: "fs0", children: [
17709
17710
  d.label,
17710
17711
  ":"
17711
17712
  ] }),
17712
- /* @__PURE__ */ jsx97("dd", { children: d.value })
17713
+ /* @__PURE__ */ jsx97("dd", { className: "mw0", children: d.value })
17713
17714
  ] }, d.label)) })
17714
17715
  ] }),
17715
17716
  progress !== void 0 && /* @__PURE__ */ jsxs51("div", { className: "df aic gap1 fs_10px lh_14px", children: [
@@ -17718,16 +17719,16 @@ function TableCardView(props) {
17718
17719
  height: "h_8px",
17719
17720
  borderRadius: "br4",
17720
17721
  backgroundColor: ["bgColor_var", {
17721
- "--backgroundColor": "var(--b-surface-subtle)"
17722
+ "--backgroundColor": maybeCssVar31(aiMode ? "rgba(221, 214, 254, 1)" /* Purple200 */ : "--b-surface-subtle" /* SurfaceSubtle */)
17722
17723
  }]
17723
- }), children: /* @__PURE__ */ jsx97("div", { ...trussProps63({
17724
+ }), ...tid.progressTrack, children: /* @__PURE__ */ jsx97("div", { ...trussProps63({
17724
17725
  height: "h100",
17725
17726
  borderRadius: "br4",
17726
17727
  backgroundColor: "bgBlue500",
17727
17728
  width: ["w_var", {
17728
17729
  "--width": maybeCssVar31(__maybeInc13(`${progressValue}%`))
17729
17730
  }]
17730
- }) }) }),
17731
+ }), ...tid.progressFill }) }),
17731
17732
  /* @__PURE__ */ jsxs51("span", { ...tid.progressValue, children: [
17732
17733
  progressValue,
17733
17734
  "%"
@@ -17760,6 +17761,13 @@ function TableCardView(props) {
17760
17761
  boxShadow: "bshFocus",
17761
17762
  borderStyle: "bss",
17762
17763
  borderWidth: "bw1"
17764
+ } : {},
17765
+ // Must follow the focus ring, whose `ba` would reset the AI border back to 1px.
17766
+ ...aiMode ? {
17767
+ borderWidth: "bw2",
17768
+ borderColor: ["bc_var", {
17769
+ "--borderColor": "var(--b-ai-field-fg)"
17770
+ }]
17763
17771
  } : {}
17764
17772
  }), ...tid, children: [
17765
17773
  action ? getButtonOrLink(content, action, actionAttrs) : (
@@ -17821,6 +17829,9 @@ function Thumbnail(props) {
17821
17829
  pointerEvents: "after_a_pointerEvents_none"
17822
17830
  }), children: /* @__PURE__ */ jsx97("span", { className: "db w100 h100 oh br8", children: /* @__PURE__ */ jsx97("img", { className: "w100 h100 objectFit_cover db", src: item.imgUrl, alt: "", loading: "lazy" }) }) }) });
17823
17831
  }
17832
+ function renderMaybeProposed(value, tid) {
17833
+ return typeof value === "string" || value === void 0 ? value : /* @__PURE__ */ jsx97(ProposedValue, { ...value, ...tid });
17834
+ }
17824
17835
  function clampProgress(value) {
17825
17836
  if (process.env.NODE_ENV !== "production" && (value < 0 || value > 100)) {
17826
17837
  console.warn(`[TableCard] progress value ${value} is outside the expected range [0, 100] and will be clamped.`);
@@ -27923,8 +27934,72 @@ function EnvironmentBannerLayout(props) {
27923
27934
  }
27924
27935
 
27925
27936
  // src/layouts/FormSectionLayout/FormSectionLayout.tsx
27926
- import { trussProps as trussProps133 } from "@homebound/truss/runtime";
27927
- import { jsx as jsx229, jsxs as jsxs120 } from "react/jsx-runtime";
27937
+ import { trussProps as trussProps134, maybeCssVar as maybeCssVar67 } from "@homebound/truss/runtime";
27938
+
27939
+ // src/layouts/FormSectionLayout/JumpLinksRail.tsx
27940
+ import { trussProps as trussProps133, maybeCssVar as maybeCssVar66 } from "@homebound/truss/runtime";
27941
+ import { jsx as jsx229 } from "react/jsx-runtime";
27942
+ var __maybeInc31 = (inc) => {
27943
+ return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
27944
+ };
27945
+ function JumpLinksRail(props) {
27946
+ const {
27947
+ links,
27948
+ activeId
27949
+ } = props;
27950
+ const tid = useTestIds(props, "jumpLinks");
27951
+ return /* @__PURE__ */ jsx229("nav", { ...trussProps133({
27952
+ display: "df",
27953
+ flexDirection: "fdc",
27954
+ flexShrink: "fs0",
27955
+ width: ["w_var", {
27956
+ "--width": `${jumpLinksRailWidthPx}px`
27957
+ }],
27958
+ position: "sticky",
27959
+ alignSelf: "asfs",
27960
+ top: ["top_var", {
27961
+ "--top": maybeCssVar66(__maybeInc31(stickyNavAndHeaderOffset()))
27962
+ }]
27963
+ }), ...tid, children: links.map((link) => /* @__PURE__ */ jsx229(JumpLink, { label: link.label, href: `#${link.id}`, active: link.id === activeId, ...tid.link }, link.id)) });
27964
+ }
27965
+ var jumpLinksRailWidthPx = 192;
27966
+ var railAndShellPx = centeredShellMaxPx.sm + jumpLinksRailWidthPx;
27967
+ var jumpLinksRailReservation = `clamp(0px, 100% - ${railAndShellPx}px, ${jumpLinksRailWidthPx}px)`;
27968
+
27969
+ // src/layouts/FormSectionLayout/useActiveJumpLink.ts
27970
+ import { useLayoutEffect as useLayoutEffect12, useState as useState61 } from "react";
27971
+ var activationLeadPx = 120;
27972
+ function useActiveJumpLink(sectionIds) {
27973
+ const idsKey = sectionIds.join("\0");
27974
+ const [activeId, setActiveId] = useState61(sectionIds[0]);
27975
+ useLayoutEffect12(() => {
27976
+ const ids = idsKey.length === 0 ? [] : idsKey.split("\0");
27977
+ if (ids.length === 0) return;
27978
+ const update = () => {
27979
+ const first = ids.map((id) => document.getElementById(id)).find((el) => el !== null);
27980
+ if (!first) return;
27981
+ const headerOffset = stickyNavAndHeaderOffsetPx(first);
27982
+ let current = ids[0];
27983
+ for (const id of ids) {
27984
+ const el = document.getElementById(id);
27985
+ if (el && el.getBoundingClientRect().top - headerOffset <= activationLeadPx) {
27986
+ current = id;
27987
+ }
27988
+ }
27989
+ setActiveId(current);
27990
+ };
27991
+ update();
27992
+ window.addEventListener("scroll", update, { passive: true });
27993
+ return () => window.removeEventListener("scroll", update);
27994
+ }, [idsKey]);
27995
+ return sectionIds.includes(activeId ?? "") ? activeId : sectionIds[0];
27996
+ }
27997
+
27998
+ // src/layouts/FormSectionLayout/FormSectionLayout.tsx
27999
+ import { jsx as jsx230, jsxs as jsxs120 } from "react/jsx-runtime";
28000
+ var __maybeInc32 = (inc) => {
28001
+ return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
28002
+ };
27928
28003
  function FormSectionLayout(props) {
27929
28004
  const {
27930
28005
  title,
@@ -27933,10 +28008,23 @@ function FormSectionLayout(props) {
27933
28008
  withAutoSave,
27934
28009
  initialFields,
27935
28010
  sections,
27936
- aiMode = false
28011
+ aiMode = false,
28012
+ withJumpLinks = false
27937
28013
  } = props;
27938
28014
  const tid = useTestIds(props, "formSectionLayout");
27939
- const content = /* @__PURE__ */ jsxs120("div", { ...trussProps133({
28015
+ const {
28016
+ sm: isMobile
28017
+ } = useBreakpoint();
28018
+ const jumpLinks = (sections ?? []).filter((section) => !section.excludeJumpLink).map((section) => {
28019
+ const id = defaultTestId(section.title);
28020
+ return {
28021
+ id,
28022
+ label: section.title
28023
+ };
28024
+ });
28025
+ const showRail = withJumpLinks && jumpLinks.length >= 2 && !isMobile;
28026
+ const activeId = useActiveJumpLink(showRail ? jumpLinks.map((link) => link.id) : []);
28027
+ const content = /* @__PURE__ */ jsxs120("div", { ...trussProps134({
27940
28028
  display: "df",
27941
28029
  flexDirection: "fdc",
27942
28030
  gap: "gap8",
@@ -27948,20 +28036,33 @@ function FormSectionLayout(props) {
27948
28036
  } : {}
27949
28037
  }), children: [
27950
28038
  /* @__PURE__ */ jsxs120("div", { className: "df fdc gap3", children: [
27951
- /* @__PURE__ */ jsx229(ContentHeader, { ...tid, title, description, actions, withAutoSave, level: 2, aiMode }),
28039
+ /* @__PURE__ */ jsx230(ContentHeader, { ...tid, title, description, actions, withAutoSave, level: 2, aiMode }),
27952
28040
  initialFields
27953
28041
  ] }),
27954
- sections && /* @__PURE__ */ jsx229("div", { className: "df fdc gap8", children: sections.map((section, i) => /* @__PURE__ */ jsx229(FormSection, { ...section }, defaultTestId(section.title) || i)) })
28042
+ sections && /* @__PURE__ */ jsx230("div", { className: "df fdc gap8", children: sections.map((section, i) => /* @__PURE__ */ jsx230(FormSection, { ...section }, defaultTestId(section.title) || i)) })
28043
+ ] });
28044
+ const form = /* @__PURE__ */ jsx230(CenteredLayout, { size: "sm", children: aiMode ? /* @__PURE__ */ jsx230(AiCard, { size: "lg", ...tid, children: content }) : content });
28045
+ if (!showRail) {
28046
+ return /* @__PURE__ */ jsx230("div", { className: "mb4", children: form });
28047
+ }
28048
+ return /* @__PURE__ */ jsxs120("div", { className: "df w100 mb4", children: [
28049
+ /* @__PURE__ */ jsx230(JumpLinksRail, { links: jumpLinks, activeId, ...tid.jumpLinks }),
28050
+ /* @__PURE__ */ jsx230("div", { ...trussProps134({
28051
+ flexGrow: "fg1",
28052
+ minWidth: "mw0",
28053
+ marginRight: ["mr_var", {
28054
+ "--marginRight": maybeCssVar67(__maybeInc32(jumpLinksRailReservation))
28055
+ }]
28056
+ }), ...tid.column, children: form })
27955
28057
  ] });
27956
- return /* @__PURE__ */ jsx229(CenteredLayout, { size: "sm", children: aiMode ? /* @__PURE__ */ jsx229(AiCard, { size: "lg", ...tid, children: content }) : content });
27957
28058
  }
27958
28059
 
27959
28060
  // src/layouts/NavbarLayout/NavbarLayout.tsx
27960
28061
  import { useMemo as useMemo57, useRef as useRef69 } from "react";
27961
- import { mergeProps as mergeProps39, maybeCssVar as maybeCssVar66 } from "@homebound/truss/runtime";
28062
+ import { mergeProps as mergeProps39, maybeCssVar as maybeCssVar68 } from "@homebound/truss/runtime";
27962
28063
 
27963
28064
  // src/layouts/useAutoHideOnScroll.ts
27964
- import { useLayoutEffect as useLayoutEffect12, useRef as useRef68, useState as useState61 } from "react";
28065
+ import { useLayoutEffect as useLayoutEffect13, useRef as useRef68, useState as useState62 } from "react";
27965
28066
  var THRESHOLD = 80;
27966
28067
  function getInitialAutoHideState() {
27967
28068
  if (typeof window === "undefined" || window.scrollY <= 0) {
@@ -27971,15 +28072,15 @@ function getInitialAutoHideState() {
27971
28072
  }
27972
28073
  function useAutoHideOnScroll(spacerRef, enabled, getTopOffset) {
27973
28074
  const initial = getInitialAutoHideState();
27974
- const [state, setState] = useState61(initial.state);
28075
+ const [state, setState] = useState62(initial.state);
27975
28076
  const stateRef = useRef68(initial.state);
27976
- const [atTop, setAtTop] = useState61(initial.atTop);
28077
+ const [atTop, setAtTop] = useState62(initial.atTop);
27977
28078
  const atTopRef = useRef68(initial.atTop);
27978
28079
  const getTopOffsetRef = useRef68(getTopOffset);
27979
28080
  getTopOffsetRef.current = getTopOffset;
27980
28081
  const lastScrollY = useRef68(Number.POSITIVE_INFINITY);
27981
28082
  const lastScrollHeight = useRef68(0);
27982
- useLayoutEffect12(() => {
28083
+ useLayoutEffect13(() => {
27983
28084
  if (!enabled) {
27984
28085
  stateRef.current = "static";
27985
28086
  atTopRef.current = true;
@@ -28052,16 +28153,16 @@ function useAutoHideOnScroll(spacerRef, enabled, getTopOffset) {
28052
28153
 
28053
28154
  // src/layouts/useMeasuredHeight.ts
28054
28155
  import { useResizeObserver as useResizeObserver12 } from "@react-aria/utils";
28055
- import { useCallback as useCallback41, useLayoutEffect as useLayoutEffect13, useState as useState62 } from "react";
28156
+ import { useCallback as useCallback41, useLayoutEffect as useLayoutEffect14, useState as useState63 } from "react";
28056
28157
  function useMeasuredHeight(ref, enabled) {
28057
- const [height, setHeight] = useState62(0);
28158
+ const [height, setHeight] = useState63(0);
28058
28159
  const syncElementHeight = useCallback41(() => {
28059
28160
  const el = ref.current;
28060
28161
  const next = el ? Math.round(el.getBoundingClientRect().height) : 0;
28061
28162
  setHeight((prev) => prev === next ? prev : next);
28062
28163
  }, [ref]);
28063
28164
  useResizeObserver12({ ref, onResize: syncElementHeight });
28064
- useLayoutEffect13(() => {
28165
+ useLayoutEffect14(() => {
28065
28166
  syncElementHeight();
28066
28167
  }, [enabled, syncElementHeight]);
28067
28168
  return height;
@@ -28069,18 +28170,18 @@ function useMeasuredHeight(ref, enabled) {
28069
28170
 
28070
28171
  // src/layouts/NavbarLayout/NavbarLayoutHeightContext.tsx
28071
28172
  import { createContext as createContext16, useContext as useContext28 } from "react";
28072
- import { jsx as jsx230 } from "react/jsx-runtime";
28173
+ import { jsx as jsx231 } from "react/jsx-runtime";
28073
28174
  var NavbarLayoutHeightContext = createContext16(0);
28074
28175
  function NavbarLayoutHeightProvider({ value, children }) {
28075
- return /* @__PURE__ */ jsx230(NavbarLayoutHeightContext.Provider, { value, children });
28176
+ return /* @__PURE__ */ jsx231(NavbarLayoutHeightContext.Provider, { value, children });
28076
28177
  }
28077
28178
  function useNavbarLayoutHeight() {
28078
28179
  return useContext28(NavbarLayoutHeightContext);
28079
28180
  }
28080
28181
 
28081
28182
  // src/layouts/NavbarLayout/NavbarLayout.tsx
28082
- import { jsx as jsx231, jsxs as jsxs121 } from "react/jsx-runtime";
28083
- var __maybeInc31 = (inc) => {
28183
+ import { jsx as jsx232, jsxs as jsxs121 } from "react/jsx-runtime";
28184
+ var __maybeInc33 = (inc) => {
28084
28185
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
28085
28186
  };
28086
28187
  function NavbarLayout(props) {
@@ -28108,10 +28209,10 @@ function NavbarLayout(props) {
28108
28209
  position: "sticky",
28109
28210
  left: "left0",
28110
28211
  zIndex: ["z_var", {
28111
- "--zIndex": maybeCssVar66(zIndices.navbar)
28212
+ "--zIndex": maybeCssVar68(zIndices.navbar)
28112
28213
  }],
28113
28214
  width: ["w_var", {
28114
- "--width": maybeCssVar66(__maybeInc31(innerWidth))
28215
+ "--width": maybeCssVar68(__maybeInc33(innerWidth))
28115
28216
  }]
28116
28217
  }
28117
28218
  ) : (
@@ -28120,10 +28221,10 @@ function NavbarLayout(props) {
28120
28221
  position: "fixed",
28121
28222
  left: "left0",
28122
28223
  zIndex: ["z_var", {
28123
- "--zIndex": maybeCssVar66(zIndices.navbar)
28224
+ "--zIndex": maybeCssVar68(zIndices.navbar)
28124
28225
  }],
28125
28226
  width: ["w_var", {
28126
- "--width": maybeCssVar66(__maybeInc31(innerWidth))
28227
+ "--width": maybeCssVar68(__maybeInc33(innerWidth))
28127
28228
  }],
28128
28229
  transition: "transitionTop"
28129
28230
  }
@@ -28132,20 +28233,20 @@ function NavbarLayout(props) {
28132
28233
  const innerStyle = autoHideState !== "static" ? {
28133
28234
  top: autoHideState === "revealed" ? bannerTop : `calc(${bannerTop} - ${navHeight}px)`
28134
28235
  } : void 0;
28135
- const navbarEl = useMemo57(() => /* @__PURE__ */ jsx231(Navbar, { ...navbar }), [navbar]);
28136
- return /* @__PURE__ */ jsx231(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ jsx231(NavbarLayoutHeightProvider, { value: navbarOffsetPx, children: /* @__PURE__ */ jsx231(MobileSubNavProvider, { children: /* @__PURE__ */ jsxs121("div", { ...mergeProps39(void 0, cssVars, {
28236
+ const navbarEl = useMemo57(() => /* @__PURE__ */ jsx232(Navbar, { ...navbar }), [navbar]);
28237
+ return /* @__PURE__ */ jsx232(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ jsx232(NavbarLayoutHeightProvider, { value: navbarOffsetPx, children: /* @__PURE__ */ jsx232(MobileSubNavProvider, { children: /* @__PURE__ */ jsxs121("div", { ...mergeProps39(void 0, cssVars, {
28137
28238
  display: "df",
28138
28239
  flexDirection: "fdc",
28139
28240
  width: "wfc",
28140
28241
  minWidth: "mw100"
28141
28242
  }), ...tid, children: [
28142
- /* @__PURE__ */ jsx231("div", { ref: spacerRef, ...mergeProps39(void 0, {
28243
+ /* @__PURE__ */ jsx232("div", { ref: spacerRef, ...mergeProps39(void 0, {
28143
28244
  height: navHeight
28144
28245
  }, {
28145
28246
  flexShrink: "fs0",
28146
28247
  width: "w100"
28147
- }), children: /* @__PURE__ */ jsx231("div", { ref: navMetricsRef, ...mergeProps39(void 0, innerStyle, innerCss), ...tid.navbar, children: navbarEl }) }),
28148
- /* @__PURE__ */ jsx231("div", { className: "df fdc mh0 mw100 w100", ...tid.body, children })
28248
+ }), children: /* @__PURE__ */ jsx232("div", { ref: navMetricsRef, ...mergeProps39(void 0, innerStyle, innerCss), ...tid.navbar, children: navbarEl }) }),
28249
+ /* @__PURE__ */ jsx232("div", { className: "df fdc mh0 mw100 w100", ...tid.body, children })
28149
28250
  ] }) }) }) });
28150
28251
  }
28151
28252
 
@@ -28153,8 +28254,8 @@ function NavbarLayout(props) {
28153
28254
  import { useCallback as useCallback42, useMemo as useMemo58, useRef as useRef70 } from "react";
28154
28255
 
28155
28256
  // src/components/Headers/BaseHeader.tsx
28156
- import { trussProps as trussProps134 } from "@homebound/truss/runtime";
28157
- import { jsx as jsx232, jsxs as jsxs122 } from "react/jsx-runtime";
28257
+ import { trussProps as trussProps135 } from "@homebound/truss/runtime";
28258
+ import { jsx as jsx233, jsxs as jsxs122 } from "react/jsx-runtime";
28158
28259
  function BaseHeader(props) {
28159
28260
  const {
28160
28261
  title,
@@ -28166,7 +28267,7 @@ function BaseHeader(props) {
28166
28267
  } = props;
28167
28268
  const tid = useTestIds(otherProps, "header");
28168
28269
  useDocumentTitle(title, documentTitleSuffix);
28169
- return /* @__PURE__ */ jsxs122("header", { ...tid, ...trussProps134({
28270
+ return /* @__PURE__ */ jsxs122("header", { ...tid, ...trussProps135({
28170
28271
  display: "df",
28171
28272
  flexDirection: "fdc",
28172
28273
  paddingTop: "pt3",
@@ -28180,7 +28281,7 @@ function BaseHeader(props) {
28180
28281
  "--backgroundColor": "var(--b-surface)"
28181
28282
  }]
28182
28283
  }), children: [
28183
- /* @__PURE__ */ jsxs122("div", { ...trussProps134({
28284
+ /* @__PURE__ */ jsxs122("div", { ...trussProps135({
28184
28285
  ...{
28185
28286
  display: "df",
28186
28287
  justifyContent: "jcsb",
@@ -28195,8 +28296,8 @@ function BaseHeader(props) {
28195
28296
  }
28196
28297
  }), children: [
28197
28298
  /* @__PURE__ */ jsxs122("div", { className: "mw0", children: [
28198
- breadcrumbs && /* @__PURE__ */ jsx232(Breadcrumbs, { ...breadcrumbs }),
28199
- /* @__PURE__ */ jsx232("h1", { ...tid.title, ...trussProps134({
28299
+ breadcrumbs && /* @__PURE__ */ jsx233(Breadcrumbs, { ...breadcrumbs }),
28300
+ /* @__PURE__ */ jsx233("h1", { ...tid.title, ...trussProps135({
28200
28301
  fontWeight: "fw6",
28201
28302
  fontSize: "fz_20px",
28202
28303
  lineHeight: "lh_28px",
@@ -28205,15 +28306,15 @@ function BaseHeader(props) {
28205
28306
  }]
28206
28307
  }), children: title })
28207
28308
  ] }),
28208
- /* @__PURE__ */ jsx232("div", { className: "fs0", children: rightSlot })
28309
+ /* @__PURE__ */ jsx233("div", { className: "fs0", children: rightSlot })
28209
28310
  ] }),
28210
28311
  bottomSlot
28211
28312
  ] });
28212
28313
  }
28213
28314
 
28214
28315
  // src/components/Headers/PageHeader.tsx
28215
- import { trussProps as trussProps135 } from "@homebound/truss/runtime";
28216
- import { Fragment as Fragment51, jsx as jsx233, jsxs as jsxs123 } from "react/jsx-runtime";
28316
+ import { trussProps as trussProps136 } from "@homebound/truss/runtime";
28317
+ import { Fragment as Fragment51, jsx as jsx234, jsxs as jsxs123 } from "react/jsx-runtime";
28217
28318
  function PageHeader2(props) {
28218
28319
  const {
28219
28320
  tabs,
@@ -28222,10 +28323,10 @@ function PageHeader2(props) {
28222
28323
  ...otherProps
28223
28324
  } = props;
28224
28325
  const tid = useTestIds(otherProps, "header");
28225
- return /* @__PURE__ */ jsx233(BaseHeader, { ...otherProps, rightSlot: /* @__PURE__ */ jsxs123(Fragment51, { children: [
28326
+ return /* @__PURE__ */ jsx234(BaseHeader, { ...otherProps, rightSlot: /* @__PURE__ */ jsxs123(Fragment51, { children: [
28226
28327
  rightSlot,
28227
- actions && actions.length > 0 && /* @__PURE__ */ jsx233(HeaderActions, { actions, collapseOnSm: true })
28228
- ] }), bottomSlot: tabs && /* @__PURE__ */ jsx233("div", { ...trussProps135(pageContentPaddingX), children: /* @__PURE__ */ jsx233(Tabs, { ...tabs, ...tid.tabs }) }) });
28328
+ actions && actions.length > 0 && /* @__PURE__ */ jsx234(HeaderActions, { actions, collapseOnSm: true })
28329
+ ] }), bottomSlot: tabs && /* @__PURE__ */ jsx234("div", { ...trussProps136(pageContentPaddingX), children: /* @__PURE__ */ jsx234(Tabs, { ...tabs, ...tid.tabs }) }) });
28229
28330
  }
28230
28331
 
28231
28332
  // src/layouts/useBannerAndNavbarHeight.ts
@@ -28234,9 +28335,9 @@ function useBannerAndNavbarHeight() {
28234
28335
  }
28235
28336
 
28236
28337
  // src/layouts/PageHeaderLayout/PageHeaderLayout.tsx
28237
- import { mergeProps as mergeProps40, maybeCssVar as maybeCssVar67 } from "@homebound/truss/runtime";
28238
- import { jsx as jsx234, jsxs as jsxs124 } from "react/jsx-runtime";
28239
- var __maybeInc32 = (inc) => {
28338
+ import { mergeProps as mergeProps40, maybeCssVar as maybeCssVar69 } from "@homebound/truss/runtime";
28339
+ import { jsx as jsx235, jsxs as jsxs124 } from "react/jsx-runtime";
28340
+ var __maybeInc34 = (inc) => {
28240
28341
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
28241
28342
  };
28242
28343
  function PageHeaderLayout(props) {
@@ -28266,103 +28367,46 @@ function PageHeaderLayout(props) {
28266
28367
  const innerCss = autoHideState === "static" ? {
28267
28368
  position: "sticky",
28268
28369
  left: ["left_var", {
28269
- "--left": maybeCssVar67(__maybeInc32(headerLeft))
28370
+ "--left": maybeCssVar69(__maybeInc34(headerLeft))
28270
28371
  }],
28271
28372
  width: ["w_var", {
28272
- "--width": maybeCssVar67(__maybeInc32(headerWidth))
28373
+ "--width": maybeCssVar69(__maybeInc34(headerWidth))
28273
28374
  }],
28274
28375
  zIndex: ["z_var", {
28275
- "--zIndex": maybeCssVar67(zIndices.pageStickyHeader)
28376
+ "--zIndex": maybeCssVar69(zIndices.pageStickyHeader)
28276
28377
  }]
28277
28378
  } : {
28278
28379
  position: "fixed",
28279
28380
  left: ["left_var", {
28280
- "--left": maybeCssVar67(__maybeInc32(headerLeft))
28381
+ "--left": maybeCssVar69(__maybeInc34(headerLeft))
28281
28382
  }],
28282
28383
  width: ["w_var", {
28283
- "--width": maybeCssVar67(__maybeInc32(headerWidth))
28384
+ "--width": maybeCssVar69(__maybeInc34(headerWidth))
28284
28385
  }],
28285
28386
  zIndex: ["z_var", {
28286
- "--zIndex": maybeCssVar67(zIndices.pageStickyHeader)
28387
+ "--zIndex": maybeCssVar69(zIndices.pageStickyHeader)
28287
28388
  }],
28288
28389
  transition: "transitionTop"
28289
28390
  };
28290
28391
  const innerStyle = autoHideState !== "static" ? {
28291
28392
  top: autoHideState === "revealed" ? outerTop : `calc(${outerTop} - ${headerHeight}px)`
28292
28393
  } : void 0;
28293
- const pageHeaderEl = useMemo58(() => /* @__PURE__ */ jsx234(PageHeader2, { ...pageHeader }), [pageHeader]);
28294
- return /* @__PURE__ */ jsx234(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ jsxs124("div", { ...mergeProps40(void 0, cssVars, {
28394
+ const pageHeaderEl = useMemo58(() => /* @__PURE__ */ jsx235(PageHeader2, { ...pageHeader }), [pageHeader]);
28395
+ return /* @__PURE__ */ jsx235(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ jsxs124("div", { ...mergeProps40(void 0, cssVars, {
28295
28396
  display: "df",
28296
28397
  flexDirection: "fdc",
28297
28398
  width: "w100"
28298
28399
  }), ...tid, children: [
28299
- /* @__PURE__ */ jsx234("div", { ref: spacerRef, ...mergeProps40(void 0, {
28400
+ /* @__PURE__ */ jsx235("div", { ref: spacerRef, ...mergeProps40(void 0, {
28300
28401
  height: headerHeight
28301
28402
  }, {
28302
28403
  flexShrink: "fs0",
28303
28404
  width: "w100"
28304
- }), children: /* @__PURE__ */ jsx234("div", { ref: headerMetricsRef, ...mergeProps40(void 0, innerStyle, innerCss), ...tid.pageHeader, children: pageHeaderEl }) }),
28305
- /* @__PURE__ */ jsx234("div", { className: "df fdc fg1 mh0 w100", ...tid.body, children })
28405
+ }), children: /* @__PURE__ */ jsx235("div", { ref: headerMetricsRef, ...mergeProps40(void 0, innerStyle, innerCss), ...tid.pageHeader, children: pageHeaderEl }) }),
28406
+ /* @__PURE__ */ jsx235("div", { className: "df fdc fg1 mh0 w100", ...tid.body, children })
28306
28407
  ] }) });
28307
28408
  }
28308
28409
 
28309
- // src/layouts/Workflow/JumpLinksRail.tsx
28310
- import { trussProps as trussProps136, maybeCssVar as maybeCssVar68 } from "@homebound/truss/runtime";
28311
- import { jsx as jsx235 } from "react/jsx-runtime";
28312
- var __maybeInc33 = (inc) => {
28313
- return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
28314
- };
28315
- var jumpLinksRailWidthPx = 180;
28316
- function JumpLinksRail(props) {
28317
- const {
28318
- links,
28319
- activeId
28320
- } = props;
28321
- const tid = useTestIds(props, "jumpLinks");
28322
- return /* @__PURE__ */ jsx235("nav", { ...trussProps136({
28323
- display: "df",
28324
- flexDirection: "fdc",
28325
- flexShrink: "fs0",
28326
- width: ["w_var", {
28327
- "--width": `${jumpLinksRailWidthPx}px`
28328
- }],
28329
- position: "sticky",
28330
- alignSelf: "asfs",
28331
- top: ["top_var", {
28332
- "--top": maybeCssVar68(__maybeInc33(stickyNavAndHeaderOffset()))
28333
- }]
28334
- }), ...tid, children: links.map((link) => /* @__PURE__ */ jsx235(JumpLink, { label: link.label, href: `#${link.id}`, active: link.id === activeId, ...tid.link }, link.id)) });
28335
- }
28336
-
28337
- // src/layouts/Workflow/useActiveJumpLink.ts
28338
- import { useLayoutEffect as useLayoutEffect14, useState as useState63 } from "react";
28339
- var activationLeadPx = 120;
28340
- function useActiveJumpLink(sectionIds) {
28341
- const idsKey = sectionIds.join("\0");
28342
- const [activeId, setActiveId] = useState63(sectionIds[0]);
28343
- useLayoutEffect14(() => {
28344
- const ids = idsKey.length === 0 ? [] : idsKey.split("\0");
28345
- if (ids.length === 0) return;
28346
- const update = () => {
28347
- const first = ids.map((id) => document.getElementById(id)).find((el) => el !== null);
28348
- if (!first) return;
28349
- const headerOffset = stickyNavAndHeaderOffsetPx(first);
28350
- let current = ids[0];
28351
- for (const id of ids) {
28352
- const el = document.getElementById(id);
28353
- if (el && el.getBoundingClientRect().top - headerOffset <= activationLeadPx) {
28354
- current = id;
28355
- }
28356
- }
28357
- setActiveId(current);
28358
- };
28359
- update();
28360
- window.addEventListener("scroll", update, { passive: true });
28361
- return () => window.removeEventListener("scroll", update);
28362
- }, [idsKey]);
28363
- return sectionIds.includes(activeId ?? "") ? activeId : sectionIds[0];
28364
- }
28365
-
28366
28410
  // src/layouts/Workflow/WorkflowPageLayout.tsx
28367
28411
  import { useLayoutEffect as useLayoutEffect15, useRef as useRef72 } from "react";
28368
28412
 
@@ -28457,9 +28501,9 @@ function WorkflowActions(props) {
28457
28501
  }
28458
28502
 
28459
28503
  // src/layouts/Workflow/WorkflowPageLayout.tsx
28460
- import { trussProps as trussProps137, mergeProps as mergeProps41, maybeCssVar as maybeCssVar69 } from "@homebound/truss/runtime";
28504
+ import { trussProps as trussProps137, mergeProps as mergeProps41, maybeCssVar as maybeCssVar70 } from "@homebound/truss/runtime";
28461
28505
  import { jsx as jsx239, jsxs as jsxs126 } from "react/jsx-runtime";
28462
- var __maybeInc34 = (inc) => {
28506
+ var __maybeInc35 = (inc) => {
28463
28507
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
28464
28508
  };
28465
28509
  var mobileFooterHeightPx = 80;
@@ -28517,13 +28561,13 @@ function WorkflowPageLayout(props) {
28517
28561
  position: "sticky",
28518
28562
  left: "left0",
28519
28563
  width: ["w_var", {
28520
- "--width": maybeCssVar69(__maybeInc34(headerWidth))
28564
+ "--width": maybeCssVar70(__maybeInc35(headerWidth))
28521
28565
  }],
28522
28566
  zIndex: ["z_var", {
28523
- "--zIndex": maybeCssVar69(zIndices.pageStickyHeader)
28567
+ "--zIndex": maybeCssVar70(zIndices.pageStickyHeader)
28524
28568
  }],
28525
28569
  top: ["top_var", {
28526
- "--top": maybeCssVar69(__maybeInc34(outerTop))
28570
+ "--top": maybeCssVar70(__maybeInc35(outerTop))
28527
28571
  }]
28528
28572
  }), ...tid.header, children: /* @__PURE__ */ jsx239(WorkflowHeader, { title, documentTitleSuffix, breadcrumbs, rightSlot: isMobile ? void 0 : actions, stepperTabs }) }),
28529
28573
  /* @__PURE__ */ jsx239("div", { ...trussProps137({
@@ -28538,7 +28582,7 @@ function WorkflowPageLayout(props) {
28538
28582
  ...aiMode && {
28539
28583
  backgroundImage: "aiBackground",
28540
28584
  minHeight: ["mh_var", {
28541
- "--minHeight": maybeCssVar69(documentScrollBodyMinHeight())
28585
+ "--minHeight": maybeCssVar70(documentScrollBodyMinHeight())
28542
28586
  }]
28543
28587
  }
28544
28588
  }), ...tid.body, children }),
@@ -28553,13 +28597,13 @@ function WorkflowPageLayout(props) {
28553
28597
  position: "fixed",
28554
28598
  bottom: "bottom0",
28555
28599
  width: ["w_var", {
28556
- "--width": maybeCssVar69(__maybeInc34(headerWidth))
28600
+ "--width": maybeCssVar70(__maybeInc35(headerWidth))
28557
28601
  }],
28558
28602
  height: ["h_var", {
28559
28603
  "--height": `${mobileFooterHeightPx}px`
28560
28604
  }],
28561
28605
  zIndex: ["z_var", {
28562
- "--zIndex": maybeCssVar69(zIndices.pageStickyFooter)
28606
+ "--zIndex": maybeCssVar70(zIndices.pageStickyFooter)
28563
28607
  }],
28564
28608
  display: "df",
28565
28609
  alignItems: "aic",
@@ -28582,37 +28626,25 @@ function WorkflowPageLayout(props) {
28582
28626
  }
28583
28627
 
28584
28628
  // src/layouts/Workflow/FocusedFormLayout.tsx
28585
- import { jsx as jsx240, jsxs as jsxs127 } from "react/jsx-runtime";
28629
+ import { jsx as jsx240 } from "react/jsx-runtime";
28586
28630
  function FocusedFormLayout(props) {
28587
- const {
28588
- onCancel,
28589
- completeLabel,
28590
- onComplete,
28591
- onSaveAndExit,
28592
- isValid,
28593
- isDirty,
28594
- withJumpLinks = true,
28595
- aiMode,
28596
- form,
28597
- ...headerProps
28598
- } = props;
28631
+ const { onCancel, completeLabel, onComplete, onSaveAndExit, isValid, isDirty, aiMode, children, ...headerProps } = props;
28599
28632
  const tid = useTestIds(props, "focusedFormLayout");
28600
- const {
28601
- sm: isMobile
28602
- } = useBreakpoint();
28603
- const jumpLinks = (form.sections ?? []).filter((section) => !section.excludeJumpLink).map((section) => {
28604
- const id = defaultTestId(section.title);
28605
- return {
28606
- id,
28607
- label: section.title
28608
- };
28609
- });
28610
- const activeId = useActiveJumpLink(jumpLinks.map((link) => link.id));
28611
- const showRail = withJumpLinks && jumpLinks.length >= 2 && !isMobile;
28612
- return /* @__PURE__ */ jsx240(WorkflowPageLayout, { ...tid, ...headerProps, aiMode, isDirty, onCancel, onSaveAndExit, completeLabel, onComplete, primaryDisabled: !isValid, children: /* @__PURE__ */ jsxs127("div", { className: "df w100", children: [
28613
- showRail && /* @__PURE__ */ jsx240(JumpLinksRail, { links: jumpLinks, activeId, ...tid.jumpLinks }),
28614
- /* @__PURE__ */ jsx240("div", { className: "fg1 mw0 mb4", children: /* @__PURE__ */ jsx240(FormSectionLayout, { ...form, aiMode }) })
28615
- ] }) });
28633
+ return /* @__PURE__ */ jsx240(
28634
+ WorkflowPageLayout,
28635
+ {
28636
+ ...tid,
28637
+ ...headerProps,
28638
+ aiMode,
28639
+ isDirty,
28640
+ onCancel,
28641
+ onSaveAndExit,
28642
+ completeLabel,
28643
+ onComplete,
28644
+ primaryDisabled: !isValid,
28645
+ children
28646
+ }
28647
+ );
28616
28648
  }
28617
28649
 
28618
28650
  // src/layouts/Workflow/StepperLayout.tsx
@@ -28798,6 +28830,7 @@ export {
28798
28830
  PinToggle,
28799
28831
  PresentationProvider,
28800
28832
  PreventBrowserScroll,
28833
+ ProposedValue,
28801
28834
  RIGHT_SIDEBAR_MIN_WIDTH,
28802
28835
  RadioGroupField,
28803
28836
  ResponsiveGrid,