@homebound/beam 3.53.0 → 3.54.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.cjs CHANGED
@@ -136,7 +136,6 @@ __export(index_exports, {
136
136
  NavbarLayout: () => NavbarLayout,
137
137
  NumberField: () => NumberField,
138
138
  OpenModal: () => OpenModal,
139
- PageHeader: () => PageHeader2,
140
139
  PageHeaderLayout: () => PageHeaderLayout,
141
140
  Pagination: () => Pagination,
142
141
  Palette: () => Palette,
@@ -24092,326 +24091,8 @@ function NavbarUserMenu({
24092
24091
  }, placement: "right", ...tid }) });
24093
24092
  }
24094
24093
 
24095
- // src/components/Tabs.tsx
24096
- var import_change_case9 = require("change-case");
24097
- var import_react138 = require("react");
24098
- var import_react_aria62 = require("react-aria");
24099
- var import_react_router = require("react-router");
24100
- var import_react_router_dom8 = require("react-router-dom");
24101
- var import_runtime110 = require("@homebound/truss/runtime");
24102
- var import_jsx_runtime190 = require("react/jsx-runtime");
24103
- function TabsWithContent(props) {
24104
- const styles = hideTabs(props) ? {} : {
24105
- paddingTop: "pt3"
24106
- };
24107
- return /* @__PURE__ */ (0, import_jsx_runtime190.jsxs)(import_jsx_runtime190.Fragment, { children: [
24108
- /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(Tabs, { ...props }),
24109
- /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(TabContent, { ...props, contentXss: {
24110
- ...styles,
24111
- ...props.contentXss
24112
- } })
24113
- ] });
24114
- }
24115
- function TabContent(props) {
24116
- const tid = useTestIds(props, "tab");
24117
- const {
24118
- tabs,
24119
- contentXss = {},
24120
- omitFullBleedPadding = false
24121
- } = props;
24122
- const location = (0, import_react_router_dom8.useLocation)();
24123
- const selectedTab = isRouteTabs(props) ? props.tabs.find((t) => {
24124
- const paths = Array.isArray(t.path) ? t.path : [t.path];
24125
- return paths.some((p) => !!(0, import_react_router.matchPath)({
24126
- path: p,
24127
- end: true
24128
- }, location.pathname));
24129
- }) || tabs[0] : props.tabs.find((tab) => tab.value === props.selected) || tabs[0];
24130
- const uniqueValue = uniqueTabValue(selectedTab);
24131
- return (
24132
- // Using FullBleed to allow the tab's bgColor to extend to the edges of the <ScrollableContent /> element.
24133
- // Omit the padding from `FullBleed` if the caller passes in the `paddingLeft/Right` styles.
24134
- /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(FullBleed, { omitPadding: omitFullBleedPadding, children: /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("div", { "aria-labelledby": `${uniqueValue}-tab`, id: `${uniqueValue}-tabPanel`, role: "tabpanel", tabIndex: 0, ...tid.panel, ...(0, import_runtime110.trussProps)(contentXss), children: selectedTab.render() }) })
24135
- );
24136
- }
24137
- function Tabs(props) {
24138
- const {
24139
- ariaLabel,
24140
- tabs,
24141
- includeBottomBorder,
24142
- right,
24143
- ...others
24144
- } = props;
24145
- const location = (0, import_react_router_dom8.useLocation)();
24146
- const selected = isRouteTabs(props) ? uniqueTabValue(props.tabs.find((t) => {
24147
- const paths = Array.isArray(t.path) ? t.path : [t.path];
24148
- return paths.some((p) => !!(0, import_react_router.matchPath)({
24149
- path: p,
24150
- end: true
24151
- }, location.pathname));
24152
- }) || props.tabs[0]) : props.selected;
24153
- const {
24154
- isFocusVisible,
24155
- focusProps
24156
- } = (0, import_react_aria62.useFocusRing)();
24157
- const tid = useTestIds(others, "tabs");
24158
- const [active, setActive] = (0, import_react138.useState)(selected);
24159
- const ref = (0, import_react138.useRef)(null);
24160
- (0, import_react138.useEffect)(() => setActive(selected), [selected]);
24161
- function onKeyUp(e) {
24162
- if (e.key === "ArrowLeft" || e.key === "ArrowRight") {
24163
- const nextTabValue = getNextTabValue(active, e.key, tabs);
24164
- setActive(nextTabValue);
24165
- document.getElementById(`${nextTabValue}-tab`)?.focus();
24166
- }
24167
- }
24168
- function onClick(value) {
24169
- !isRouteTabs(props) && props.onChange(value);
24170
- }
24171
- function onBlur(e) {
24172
- if (!(ref.current && ref.current.contains(e.relatedTarget))) {
24173
- setActive(selected);
24174
- }
24175
- }
24176
- return /* @__PURE__ */ (0, import_jsx_runtime190.jsxs)("div", { ...(0, import_runtime110.trussProps)({
24177
- ...{
24178
- display: "df",
24179
- alignItems: "aic",
24180
- overflow: "oa",
24181
- whiteSpace: "wsnw",
24182
- gap: "gap1"
24183
- },
24184
- ...includeBottomBorder ? {
24185
- ...{
24186
- borderBottomStyle: "bbs_solid",
24187
- borderBottomWidth: "bbw_1px",
24188
- borderColor: "bcGray200"
24189
- }
24190
- } : {}
24191
- }), children: [
24192
- !hideTabs(props) && /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("div", { ref, className: "dif gap1 asfe", "aria-label": ariaLabel, role: "tablist", ...tid, children: tabs.map((tab) => {
24193
- const uniqueValue = uniqueTabValue(tab);
24194
- return /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(TabImpl, { active: active === uniqueValue, focusProps, isFocusVisible, onClick, onKeyUp, onBlur, tab, ...tid[defaultTestId(uniqueValue)] }, uniqueValue);
24195
- }) }),
24196
- right && /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("div", { className: "mla df aic gap1 pb1", children: right })
24197
- ] });
24198
- }
24199
- function TabImpl(props) {
24200
- const {
24201
- tab,
24202
- onClick,
24203
- active,
24204
- onKeyUp,
24205
- onBlur,
24206
- focusProps,
24207
- isFocusVisible = false,
24208
- ...others
24209
- } = props;
24210
- const {
24211
- disabled = false,
24212
- name: label,
24213
- icon,
24214
- endAdornment
24215
- } = tab;
24216
- const isDisabled = !!disabled;
24217
- const {
24218
- hoverProps,
24219
- isHovered
24220
- } = (0, import_react_aria62.useHover)({
24221
- isDisabled
24222
- });
24223
- const {
24224
- baseStyles: baseStyles4,
24225
- activeStyles: activeStyles3,
24226
- focusRingStyles: focusRingStyles2,
24227
- hoverStyles: hoverStyles4,
24228
- disabledStyles: disabledStyles3,
24229
- activeHoverStyles
24230
- } = (0, import_react138.useMemo)(() => getTabStyles(), []);
24231
- const uniqueValue = uniqueTabValue(tab);
24232
- const tabProps = {
24233
- "aria-controls": `${uniqueValue}-tabPanel`,
24234
- "aria-selected": active,
24235
- "aria-disabled": isDisabled || void 0,
24236
- id: `${uniqueValue}-tab`,
24237
- role: "tab",
24238
- tabIndex: active ? 0 : -1,
24239
- ...others,
24240
- ...(0, import_runtime110.trussProps)({
24241
- ...baseStyles4,
24242
- ...active && activeStyles3,
24243
- ...isDisabled && disabledStyles3,
24244
- ...isHovered && hoverStyles4,
24245
- ...isHovered && active && activeHoverStyles,
24246
- ...isFocusVisible && active && focusRingStyles2
24247
- })
24248
- };
24249
- const interactiveProps = (0, import_react_aria62.mergeProps)(focusProps, hoverProps, {
24250
- onKeyUp,
24251
- onBlur,
24252
- ...isRouteTab(tab) ? {} : {
24253
- onClick: () => onClick(tab.value)
24254
- }
24255
- });
24256
- const tabLabel = /* @__PURE__ */ (0, import_jsx_runtime190.jsxs)(import_jsx_runtime190.Fragment, { children: [
24257
- label,
24258
- (icon || endAdornment) && /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("span", { className: "ml1", children: icon ? /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(Icon, { icon }) : endAdornment })
24259
- ] });
24260
- return isDisabled ? maybeTooltip({
24261
- title: resolveTooltip(disabled),
24262
- placement: "top",
24263
- children: /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("div", { ...tabProps, children: tabLabel })
24264
- }) : isRouteTab(tab) ? /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(import_react_router_dom8.Link, { ...(0, import_react_aria62.mergeProps)(tabProps, interactiveProps, {
24265
- className: "navLink"
24266
- }), to: tab.href, children: tabLabel }) : /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("button", { ...{
24267
- ...tabProps,
24268
- ...interactiveProps
24269
- }, children: tabLabel });
24270
- }
24271
- function getTabStyles() {
24272
- const borderBottomWidthPx = 4;
24273
- const verticalPaddingPx = 6;
24274
- const borderBottomStyles = {
24275
- borderBottomStyle: "bbs_solid",
24276
- borderBottomWidth: ["borderBottomWidth_var", {
24277
- "--borderBottomWidth": (0, import_runtime110.maybeCssVar)(`${borderBottomWidthPx}px`)
24278
- }],
24279
- paddingBottom: ["pb_var", {
24280
- "--paddingBottom": `${verticalPaddingPx - borderBottomWidthPx}px`
24281
- }]
24282
- };
24283
- return {
24284
- baseStyles: {
24285
- display: "df",
24286
- alignItems: "aic",
24287
- height: "h_32px",
24288
- paddingTop: ["py_var", {
24289
- "--paddingTop": `${verticalPaddingPx}px`
24290
- }],
24291
- paddingBottom: ["py_var", {
24292
- "--paddingBottom": `${verticalPaddingPx}px`
24293
- }],
24294
- paddingLeft: "pl1",
24295
- paddingRight: "pr1",
24296
- outline: "outline0",
24297
- color: "gray700",
24298
- width: "width_fit_content",
24299
- cursor: "cursorPointer",
24300
- fontWeight: "fw4",
24301
- fontSize: "fz_14px",
24302
- lineHeight: "lh_20px"
24303
- },
24304
- activeStyles: {
24305
- ...{
24306
- borderColor: "bcBlue700",
24307
- fontWeight: "fw6",
24308
- fontSize: "fz_14px",
24309
- lineHeight: "lh_20px",
24310
- color: "gray900"
24311
- },
24312
- ...borderBottomStyles
24313
- },
24314
- disabledStyles: {
24315
- color: "gray400",
24316
- cursor: "cursorNotAllowed"
24317
- },
24318
- focusRingStyles: {
24319
- backgroundColor: "bgBlue50",
24320
- boxShadow: "bshFocus"
24321
- },
24322
- hoverStyles: {
24323
- ...{
24324
- borderColor: "bcGray400"
24325
- },
24326
- ...borderBottomStyles
24327
- },
24328
- activeHoverStyles: {
24329
- ...{
24330
- backgroundColor: "bgBlue50",
24331
- borderColor: "bcBlue700"
24332
- },
24333
- ...borderBottomStyles
24334
- }
24335
- };
24336
- }
24337
- function getNextTabValue(selected, key, tabs) {
24338
- const enabledTabs = tabs.filter((tab) => tab.disabled !== true);
24339
- const tabsToScan = key === "ArrowRight" ? enabledTabs : enabledTabs.reverse();
24340
- const currentIndex = tabsToScan.findIndex((tab) => uniqueTabValue(tab) === selected);
24341
- const nextIndex = currentIndex === tabsToScan.length - 1 ? 0 : currentIndex + 1;
24342
- return uniqueTabValue(tabsToScan[nextIndex]);
24343
- }
24344
- function isRouteTabs(props) {
24345
- const {
24346
- tabs
24347
- } = props;
24348
- return tabs.length > 0 && isRouteTab(tabs[0]);
24349
- }
24350
- function isRouteTab(tab) {
24351
- return "path" in tab;
24352
- }
24353
- function uniqueTabValue(tab) {
24354
- return isRouteTab(tab) ? (0, import_change_case9.camelCase)(tab.name) : tab.value;
24355
- }
24356
- function hideTabs(props) {
24357
- return props.alwaysShowAllTabs ? false : props.tabs.filter((t) => !t.disabled).length === 1;
24358
- }
24359
-
24360
- // src/components/PageHeader.tsx
24361
- var import_runtime111 = require("@homebound/truss/runtime");
24362
- var import_jsx_runtime191 = require("react/jsx-runtime");
24363
- function PageHeader2(props) {
24364
- const {
24365
- title,
24366
- documentTitleSuffix,
24367
- rightSlot,
24368
- tabs,
24369
- breadcrumbs,
24370
- ...otherProps
24371
- } = props;
24372
- const tid = useTestIds(otherProps, "pageHeader");
24373
- useDocumentTitle(title, documentTitleSuffix);
24374
- return /* @__PURE__ */ (0, import_jsx_runtime191.jsxs)("header", { ...tid, ...(0, import_runtime111.trussProps)({
24375
- display: "df",
24376
- flexDirection: "fdc",
24377
- paddingTop: "pt3",
24378
- paddingLeft: "pl3",
24379
- paddingRight: "pr3",
24380
- borderBottomStyle: "bbs_solid",
24381
- borderBottomWidth: "bbw_1px",
24382
- gap: "gap2",
24383
- borderColor: ["bc_var", {
24384
- "--borderColor": "var(--b-surface-separator)"
24385
- }],
24386
- backgroundColor: ["bgColor_var", {
24387
- "--backgroundColor": "var(--b-surface)"
24388
- }]
24389
- }), children: [
24390
- /* @__PURE__ */ (0, import_jsx_runtime191.jsxs)("div", { ...(0, import_runtime111.trussProps)({
24391
- ...{
24392
- display: "df",
24393
- justifyContent: "jcsb",
24394
- width: "w100",
24395
- gap: "gap1"
24396
- },
24397
- ...{
24398
- ...!tabs ? {
24399
- marginBottom: "mb2"
24400
- } : {}
24401
- }
24402
- }), children: [
24403
- /* @__PURE__ */ (0, import_jsx_runtime191.jsxs)("div", { className: "mw0", children: [
24404
- breadcrumbs && /* @__PURE__ */ (0, import_jsx_runtime191.jsx)(Breadcrumbs, { ...breadcrumbs }),
24405
- /* @__PURE__ */ (0, import_jsx_runtime191.jsx)("h1", { ...tid.title, className: "fw6 fz_20px lh_28px", children: title })
24406
- ] }),
24407
- /* @__PURE__ */ (0, import_jsx_runtime191.jsx)("div", { className: "fs0", children: rightSlot })
24408
- ] }),
24409
- tabs && /* @__PURE__ */ (0, import_jsx_runtime191.jsx)(Tabs, { ...tabs })
24410
- ] });
24411
- }
24412
-
24413
24094
  // src/components/Pagination.tsx
24414
- var import_jsx_runtime192 = require("react/jsx-runtime");
24095
+ var import_jsx_runtime190 = require("react/jsx-runtime");
24415
24096
  var defaultPage = {
24416
24097
  offset: 0,
24417
24098
  limit: 100
@@ -24443,25 +24124,25 @@ function Pagination(props) {
24443
24124
  }
24444
24125
  }
24445
24126
  const tid = useTestIds(props, "pagination");
24446
- return /* @__PURE__ */ (0, import_jsx_runtime192.jsxs)("div", { className: "df bcGray200 bts_solid btw_1px fw4 fz_12px lh_16px gray500 pl2 pr2 pt2", ...tid, children: [
24447
- /* @__PURE__ */ (0, import_jsx_runtime192.jsx)("div", { className: "df mta mba mr2", ...tid.pageSizeLabel, children: "Page size:" }),
24448
- /* @__PURE__ */ (0, import_jsx_runtime192.jsx)("div", { className: "w_78px", children: /* @__PURE__ */ (0, import_jsx_runtime192.jsx)(SelectField, { compact: true, label: "Page Size", labelStyle: "hidden", options: pageOptions, value: pageSize, onSelect: (val) => set({
24127
+ return /* @__PURE__ */ (0, import_jsx_runtime190.jsxs)("div", { className: "df bcGray200 bts_solid btw_1px fw4 fz_12px lh_16px gray500 pl2 pr2 pt2", ...tid, children: [
24128
+ /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("div", { className: "df mta mba mr2", ...tid.pageSizeLabel, children: "Page size:" }),
24129
+ /* @__PURE__ */ (0, import_jsx_runtime190.jsx)("div", { className: "w_78px", children: /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(SelectField, { compact: true, label: "Page Size", labelStyle: "hidden", options: pageOptions, value: pageSize, onSelect: (val) => set({
24449
24130
  pageNumber: 1,
24450
24131
  pageSize: val
24451
24132
  }), autoSort: false, ...tid.pageSize }) }),
24452
- /* @__PURE__ */ (0, import_jsx_runtime192.jsxs)("div", { className: "mla mta mba df", children: [
24453
- /* @__PURE__ */ (0, import_jsx_runtime192.jsxs)("div", { className: "df mta mba mr2", ...tid.pageInfoLabel, children: [
24133
+ /* @__PURE__ */ (0, import_jsx_runtime190.jsxs)("div", { className: "mla mta mba df", children: [
24134
+ /* @__PURE__ */ (0, import_jsx_runtime190.jsxs)("div", { className: "df mta mba mr2", ...tid.pageInfoLabel, children: [
24454
24135
  first,
24455
24136
  " ",
24456
24137
  showLast ? `- ${last}` : "",
24457
24138
  " of ",
24458
24139
  totalCount
24459
24140
  ] }),
24460
- /* @__PURE__ */ (0, import_jsx_runtime192.jsx)(IconButton, { icon: "chevronLeft", color: hasPrevPage ? "rgba(29, 78, 216, 1)" /* Blue700 */ : "rgba(236, 235, 235, 1)" /* Gray200 */, onClick: () => set({
24141
+ /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(IconButton, { icon: "chevronLeft", color: hasPrevPage ? "rgba(29, 78, 216, 1)" /* Blue700 */ : "rgba(236, 235, 235, 1)" /* Gray200 */, onClick: () => set({
24461
24142
  pageNumber: pageNumber - 1,
24462
24143
  pageSize
24463
24144
  }), disabled: !hasPrevPage, ...tid.previousIcon }),
24464
- /* @__PURE__ */ (0, import_jsx_runtime192.jsx)(IconButton, { icon: "chevronRight", color: hasNextPage ? "rgba(29, 78, 216, 1)" /* Blue700 */ : "rgba(236, 235, 235, 1)" /* Gray200 */, onClick: () => set({
24145
+ /* @__PURE__ */ (0, import_jsx_runtime190.jsx)(IconButton, { icon: "chevronRight", color: hasNextPage ? "rgba(29, 78, 216, 1)" /* Blue700 */ : "rgba(236, 235, 235, 1)" /* Gray200 */, onClick: () => set({
24465
24146
  pageNumber: pageNumber + 1,
24466
24147
  pageSize
24467
24148
  }), disabled: !hasNextPage, ...tid.nextIcon })
@@ -24483,10 +24164,10 @@ function toPageNumberSize(page) {
24483
24164
  }
24484
24165
 
24485
24166
  // src/components/ScrollShadows.tsx
24486
- var import_utils160 = require("@react-aria/utils");
24487
- var import_react139 = require("react");
24488
- var import_runtime112 = require("@homebound/truss/runtime");
24489
- var import_jsx_runtime193 = require("react/jsx-runtime");
24167
+ var import_utils158 = require("@react-aria/utils");
24168
+ var import_react138 = require("react");
24169
+ var import_runtime110 = require("@homebound/truss/runtime");
24170
+ var import_jsx_runtime191 = require("react/jsx-runtime");
24490
24171
  function ScrollShadows(props) {
24491
24172
  const {
24492
24173
  children,
@@ -24502,15 +24183,15 @@ function ScrollShadows(props) {
24502
24183
  if (!bgColor.includes("rgba")) {
24503
24184
  throw new Error("ScrollShadows: bgColor prop must be in the format 'rgba(255, 255, 255, 1)'");
24504
24185
  }
24505
- const [showStartShadow, setShowStartShadow] = (0, import_react139.useState)(false);
24506
- const [showEndShadow, setShowEndShadow] = (0, import_react139.useState)(false);
24507
- const scrollRef = (0, import_react139.useRef)(null);
24508
- const [startShadowStyles, endShadowStyles] = (0, import_react139.useMemo)(() => {
24186
+ const [showStartShadow, setShowStartShadow] = (0, import_react138.useState)(false);
24187
+ const [showEndShadow, setShowEndShadow] = (0, import_react138.useState)(false);
24188
+ const scrollRef = (0, import_react138.useRef)(null);
24189
+ const [startShadowStyles, endShadowStyles] = (0, import_react138.useMemo)(() => {
24509
24190
  const transparentBgColor = bgColor.replace(/,1\)$/, ",0)");
24510
24191
  const commonStyles = {
24511
24192
  position: "absolute",
24512
24193
  zIndex: ["z_var", {
24513
- "--zIndex": (0, import_runtime112.maybeCssVar)(zIndices.scrollShadow)
24194
+ "--zIndex": (0, import_runtime110.maybeCssVar)(zIndices.scrollShadow)
24514
24195
  }],
24515
24196
  pointerEvents: "pointerEvents_none"
24516
24197
  };
@@ -24543,7 +24224,7 @@ function ScrollShadows(props) {
24543
24224
  ...startShadowStyles2,
24544
24225
  ...{
24545
24226
  background: ["background_var", {
24546
- "--background": (0, import_runtime112.maybeCssVar)(startGradient)
24227
+ "--background": (0, import_runtime110.maybeCssVar)(startGradient)
24547
24228
  }]
24548
24229
  }
24549
24230
  }, {
@@ -24551,12 +24232,12 @@ function ScrollShadows(props) {
24551
24232
  ...endShadowStyles2,
24552
24233
  ...{
24553
24234
  background: ["background_var", {
24554
- "--background": (0, import_runtime112.maybeCssVar)(endGradient)
24235
+ "--background": (0, import_runtime110.maybeCssVar)(endGradient)
24555
24236
  }]
24556
24237
  }
24557
24238
  }];
24558
24239
  }, [horizontal, bgColor]);
24559
- const updateScrollProps = (0, import_react139.useCallback)((el) => {
24240
+ const updateScrollProps = (0, import_react138.useCallback)((el) => {
24560
24241
  const {
24561
24242
  scrollTop,
24562
24243
  scrollHeight,
@@ -24571,15 +24252,15 @@ function ScrollShadows(props) {
24571
24252
  setShowStartShadow(start > 0);
24572
24253
  setShowEndShadow(start + boxSize < end);
24573
24254
  }, [horizontal]);
24574
- const onResize = (0, import_react139.useCallback)(() => scrollRef.current && updateScrollProps(scrollRef.current), [updateScrollProps]);
24575
- (0, import_utils160.useResizeObserver)({
24255
+ const onResize = (0, import_react138.useCallback)(() => scrollRef.current && updateScrollProps(scrollRef.current), [updateScrollProps]);
24256
+ (0, import_utils158.useResizeObserver)({
24576
24257
  ref: scrollRef,
24577
24258
  onResize
24578
24259
  });
24579
- return /* @__PURE__ */ (0, import_jsx_runtime193.jsxs)("div", { ...(0, import_runtime112.trussProps)({
24260
+ return /* @__PURE__ */ (0, import_jsx_runtime191.jsxs)("div", { ...(0, import_runtime110.trussProps)({
24580
24261
  display: "df",
24581
24262
  flexDirection: ["fd_var", {
24582
- "--flexDirection": (0, import_runtime112.maybeCssVar)(!horizontal ? "column" : "row")
24263
+ "--flexDirection": (0, import_runtime110.maybeCssVar)(!horizontal ? "column" : "row")
24583
24264
  }],
24584
24265
  position: "relative",
24585
24266
  overflow: "oh",
@@ -24592,23 +24273,23 @@ function ScrollShadows(props) {
24592
24273
  width: width2
24593
24274
  }
24594
24275
  }), ...tid, children: [
24595
- /* @__PURE__ */ (0, import_jsx_runtime193.jsx)("div", { ...(0, import_runtime112.trussProps)({
24276
+ /* @__PURE__ */ (0, import_jsx_runtime191.jsx)("div", { ...(0, import_runtime110.trussProps)({
24596
24277
  ...startShadowStyles,
24597
24278
  ...{
24598
24279
  opacity: ["o_var", {
24599
- "--opacity": (0, import_runtime112.maybeCssVar)(showStartShadow ? 1 : 0)
24280
+ "--opacity": (0, import_runtime110.maybeCssVar)(showStartShadow ? 1 : 0)
24600
24281
  }]
24601
24282
  }
24602
24283
  }), "data-chromatic": "ignore" }),
24603
- /* @__PURE__ */ (0, import_jsx_runtime193.jsx)("div", { ...(0, import_runtime112.trussProps)({
24284
+ /* @__PURE__ */ (0, import_jsx_runtime191.jsx)("div", { ...(0, import_runtime110.trussProps)({
24604
24285
  ...endShadowStyles,
24605
24286
  ...{
24606
24287
  opacity: ["o_var", {
24607
- "--opacity": (0, import_runtime112.maybeCssVar)(showEndShadow ? 1 : 0)
24288
+ "--opacity": (0, import_runtime110.maybeCssVar)(showEndShadow ? 1 : 0)
24608
24289
  }]
24609
24290
  }
24610
24291
  }), "data-chromatic": "ignore" }),
24611
- /* @__PURE__ */ (0, import_jsx_runtime193.jsx)("div", { ...(0, import_runtime112.trussProps)({
24292
+ /* @__PURE__ */ (0, import_jsx_runtime191.jsx)("div", { ...(0, import_runtime110.trussProps)({
24612
24293
  ...xss,
24613
24294
  ...{
24614
24295
  overflow: "oa",
@@ -24620,8 +24301,8 @@ function ScrollShadows(props) {
24620
24301
  }
24621
24302
 
24622
24303
  // src/layouts/SideNavLayout/SideNavLayoutContext.tsx
24623
- var import_react140 = require("react");
24624
- var import_jsx_runtime194 = require("react/jsx-runtime");
24304
+ var import_react139 = require("react");
24305
+ var import_jsx_runtime192 = require("react/jsx-runtime");
24625
24306
  var SIDE_NAV_LAYOUT_STATE_STORAGE_KEY = "beam.sideNavLayout.navState";
24626
24307
  function loadStoredNavState() {
24627
24308
  try {
@@ -24643,20 +24324,20 @@ function resolveInitialNavState(defaultNavState) {
24643
24324
  }
24644
24325
  return loadStoredNavState() ?? defaultNavState ?? "expanded";
24645
24326
  }
24646
- var SideNavLayoutContext = (0, import_react140.createContext)(void 0);
24327
+ var SideNavLayoutContext = (0, import_react139.createContext)(void 0);
24647
24328
  function SideNavLayoutProvider(props) {
24648
- const [navState, setNavStateInternal] = (0, import_react140.useState)(
24329
+ const [navState, setNavStateInternal] = (0, import_react139.useState)(
24649
24330
  () => resolveInitialNavState(props.defaultNavState)
24650
24331
  );
24651
24332
  const bp = useBreakpoint();
24652
- const prevMdAndUp = (0, import_react140.useRef)(bp.mdAndUp);
24653
- (0, import_react140.useEffect)(() => {
24333
+ const prevMdAndUp = (0, import_react139.useRef)(bp.mdAndUp);
24334
+ (0, import_react139.useEffect)(() => {
24654
24335
  if (prevMdAndUp.current && !bp.mdAndUp) {
24655
24336
  setNavStateInternal((prev) => prev === "expanded" ? "collapse" : prev);
24656
24337
  }
24657
24338
  prevMdAndUp.current = bp.mdAndUp;
24658
24339
  }, [bp.mdAndUp]);
24659
- const setNavState = (0, import_react140.useCallback)((value2) => {
24340
+ const setNavState = (0, import_react139.useCallback)((value2) => {
24660
24341
  setNavStateInternal((prev) => {
24661
24342
  const next = typeof value2 === "function" ? value2(prev) : value2;
24662
24343
  if (next === "expanded" || next === "collapse") {
@@ -24668,20 +24349,20 @@ function SideNavLayoutProvider(props) {
24668
24349
  return next;
24669
24350
  });
24670
24351
  }, []);
24671
- const value = (0, import_react140.useMemo)(() => ({ navState, setNavState }), [navState, setNavState]);
24672
- return /* @__PURE__ */ (0, import_jsx_runtime194.jsx)(SideNavLayoutContext.Provider, { value, children: props.children });
24352
+ const value = (0, import_react139.useMemo)(() => ({ navState, setNavState }), [navState, setNavState]);
24353
+ return /* @__PURE__ */ (0, import_jsx_runtime192.jsx)(SideNavLayoutContext.Provider, { value, children: props.children });
24673
24354
  }
24674
24355
  function useSideNavLayoutContext() {
24675
- return (0, import_react140.useContext)(SideNavLayoutContext) ?? { navState: "expanded", setNavState: () => {
24356
+ return (0, import_react139.useContext)(SideNavLayoutContext) ?? { navState: "expanded", setNavState: () => {
24676
24357
  } };
24677
24358
  }
24678
24359
  function useHasSideNavLayoutProvider() {
24679
- return (0, import_react140.useContext)(SideNavLayoutContext) !== void 0;
24360
+ return (0, import_react139.useContext)(SideNavLayoutContext) !== void 0;
24680
24361
  }
24681
24362
 
24682
24363
  // src/components/SideNav/SideNav.tsx
24683
- var import_runtime113 = require("@homebound/truss/runtime");
24684
- var import_jsx_runtime195 = require("react/jsx-runtime");
24364
+ var import_runtime111 = require("@homebound/truss/runtime");
24365
+ var import_jsx_runtime193 = require("react/jsx-runtime");
24685
24366
  function SideNav(props) {
24686
24367
  const {
24687
24368
  top,
@@ -24694,8 +24375,8 @@ function SideNav(props) {
24694
24375
  const tid = useTestIds(props, "sideNav");
24695
24376
  const panelCollapsed = navState === "collapse";
24696
24377
  const hideOnCollapse = panelCollapsed && !allItemsHaveIcons(items);
24697
- return /* @__PURE__ */ (0, import_jsx_runtime195.jsxs)("nav", { className: "df fdc h100 fs0", ...tid, children: [
24698
- top !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime195.jsx)("div", { ...(0, import_runtime113.trussProps)({
24378
+ return /* @__PURE__ */ (0, import_jsx_runtime193.jsxs)("nav", { className: "df fdc h100 fs0", ...tid, children: [
24379
+ top !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime193.jsx)("div", { ...(0, import_runtime111.trussProps)({
24699
24380
  flexShrink: "fs0",
24700
24381
  paddingLeft: "pl2",
24701
24382
  paddingRight: "pr2",
@@ -24706,7 +24387,7 @@ function SideNav(props) {
24706
24387
  paddingBottom: "pb4"
24707
24388
  } : {}
24708
24389
  }), ...tid.top, children: top }),
24709
- /* @__PURE__ */ (0, import_jsx_runtime195.jsx)("div", { ...(0, import_runtime113.trussProps)({
24390
+ /* @__PURE__ */ (0, import_jsx_runtime193.jsx)("div", { ...(0, import_runtime111.trussProps)({
24710
24391
  flexGrow: "fg1",
24711
24392
  overflowY: "oya",
24712
24393
  display: "df",
@@ -24718,8 +24399,8 @@ function SideNav(props) {
24718
24399
  ...top === void 0 ? {
24719
24400
  paddingTop: "pt5"
24720
24401
  } : {}
24721
- }), ...tid.items, children: !hideOnCollapse && /* @__PURE__ */ (0, import_jsx_runtime195.jsx)(AppNavItems, { items, panelCollapsed }) }),
24722
- footer !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime195.jsx)("div", { ...(0, import_runtime113.trussProps)({
24402
+ }), ...tid.items, children: !hideOnCollapse && /* @__PURE__ */ (0, import_jsx_runtime193.jsx)(AppNavItems, { items, panelCollapsed }) }),
24403
+ footer !== void 0 && /* @__PURE__ */ (0, import_jsx_runtime193.jsx)("div", { ...(0, import_runtime111.trussProps)({
24723
24404
  flexShrink: "fs0",
24724
24405
  paddingLeft: "pl2",
24725
24406
  paddingRight: "pr2",
@@ -24735,10 +24416,10 @@ function SideNav(props) {
24735
24416
  }
24736
24417
 
24737
24418
  // src/components/Snackbar/useSnackbar.tsx
24738
- var import_react141 = require("react");
24419
+ var import_react140 = require("react");
24739
24420
  function useSnackbar() {
24740
24421
  const { setNotices, setOffset } = useSnackbarContext();
24741
- const onClose = (0, import_react141.useCallback)(
24422
+ const onClose = (0, import_react140.useCallback)(
24742
24423
  (noticeId) => {
24743
24424
  setNotices((prev) => {
24744
24425
  let returnValue = prev;
@@ -24755,7 +24436,7 @@ function useSnackbar() {
24755
24436
  // eslint-disable-next-line react-hooks/exhaustive-deps
24756
24437
  []
24757
24438
  );
24758
- const triggerNotice = (0, import_react141.useCallback)(
24439
+ const triggerNotice = (0, import_react140.useCallback)(
24759
24440
  (props) => {
24760
24441
  const noticeId = props.id ?? `beamSnackbar:${snackbarId++}`;
24761
24442
  let maybeTimeout;
@@ -24784,8 +24465,8 @@ function useSnackbar() {
24784
24465
  },
24785
24466
  [onClose, setNotices]
24786
24467
  );
24787
- const closeNotice = (0, import_react141.useCallback)((id) => onClose(id), [onClose]);
24788
- const useSnackbarOffset = ({ bottom }) => (0, import_react141.useEffect)(() => {
24468
+ const closeNotice = (0, import_react140.useCallback)((id) => onClose(id), [onClose]);
24469
+ const useSnackbarOffset = ({ bottom }) => (0, import_react140.useEffect)(() => {
24789
24470
  setOffset({ bottom });
24790
24471
  return () => setOffset({});
24791
24472
  }, [bottom]);
@@ -24794,11 +24475,11 @@ function useSnackbar() {
24794
24475
  var snackbarId = 1;
24795
24476
 
24796
24477
  // src/components/Stepper.tsx
24478
+ var import_react141 = require("react");
24479
+ var import_react_aria62 = require("react-aria");
24480
+ var import_runtime112 = require("@homebound/truss/runtime");
24481
+ var import_jsx_runtime194 = require("react/jsx-runtime");
24797
24482
  var import_react142 = require("react");
24798
- var import_react_aria63 = require("react-aria");
24799
- var import_runtime114 = require("@homebound/truss/runtime");
24800
- var import_jsx_runtime196 = require("react/jsx-runtime");
24801
- var import_react143 = require("react");
24802
24483
  var __maybeInc20 = (inc) => {
24803
24484
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
24804
24485
  };
@@ -24816,8 +24497,8 @@ function Stepper(props) {
24816
24497
  const maxStepWidth = 200;
24817
24498
  const minStepWidth = 100;
24818
24499
  const gap = 8;
24819
- return /* @__PURE__ */ (0, import_jsx_runtime196.jsxs)("nav", { "aria-label": "steps", className: "df fdc w100", ...tid, children: [
24820
- /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("ol", { ...(0, import_runtime114.trussProps)({
24500
+ return /* @__PURE__ */ (0, import_jsx_runtime194.jsxs)("nav", { "aria-label": "steps", className: "df fdc w100", ...tid, children: [
24501
+ /* @__PURE__ */ (0, import_jsx_runtime194.jsx)("ol", { ...(0, import_runtime112.trussProps)({
24821
24502
  padding: "p_0",
24822
24503
  margin: "m_0",
24823
24504
  listStyle: "lis_none",
@@ -24827,7 +24508,7 @@ function Stepper(props) {
24827
24508
  }]
24828
24509
  }), children: steps.map((step) => {
24829
24510
  const isCurrent = currentStep === step.value;
24830
- return /* @__PURE__ */ (0, import_react143.createElement)("li", { ...(0, import_runtime114.trussProps)({
24511
+ return /* @__PURE__ */ (0, import_react142.createElement)("li", { ...(0, import_runtime112.trussProps)({
24831
24512
  display: "df",
24832
24513
  flexGrow: "fg1",
24833
24514
  flexDirection: "fdc",
@@ -24837,9 +24518,9 @@ function Stepper(props) {
24837
24518
  minWidth: ["mw_var", {
24838
24519
  "--minWidth": `${minStepWidth}px`
24839
24520
  }]
24840
- }), key: step.label, "aria-current": isCurrent, ...tid.step }, /* @__PURE__ */ (0, import_jsx_runtime196.jsx)(StepButton, { ...step, onClick: () => onChange(step.value), isCurrent, ...tid.stepButton }));
24521
+ }), key: step.label, "aria-current": isCurrent, ...tid.step }, /* @__PURE__ */ (0, import_jsx_runtime194.jsx)(StepButton, { ...step, onClick: () => onChange(step.value), isCurrent, ...tid.stepButton }));
24841
24522
  }) }),
24842
- /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("div", { ...(0, import_runtime114.trussProps)({
24523
+ /* @__PURE__ */ (0, import_jsx_runtime194.jsx)("div", { ...(0, import_runtime112.trussProps)({
24843
24524
  marginTop: "mt1",
24844
24525
  backgroundColor: "bgGray300",
24845
24526
  height: "h_4px",
@@ -24850,12 +24531,12 @@ function Stepper(props) {
24850
24531
  "--minWidth": `${steps.length * minStepWidth + (steps.length - 1) * gap}px`
24851
24532
  }],
24852
24533
  width: "w100"
24853
- }), children: /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("div", { ...(0, import_runtime114.trussProps)({
24534
+ }), children: /* @__PURE__ */ (0, import_jsx_runtime194.jsx)("div", { ...(0, import_runtime112.trussProps)({
24854
24535
  backgroundColor: "bgBlue600",
24855
24536
  transition: "transition_width_200ms",
24856
24537
  height: "h100",
24857
24538
  width: ["w_var", {
24858
- "--width": (0, import_runtime114.maybeCssVar)(__maybeInc20(`${(lastCompletedStep + 1) / steps.length * 100}%`))
24539
+ "--width": (0, import_runtime112.maybeCssVar)(__maybeInc20(`${(lastCompletedStep + 1) / steps.length * 100}%`))
24859
24540
  }]
24860
24541
  }) }) })
24861
24542
  ] });
@@ -24872,26 +24553,26 @@ function StepButton(props) {
24872
24553
  onPress: onClick,
24873
24554
  isDisabled: disabled
24874
24555
  };
24875
- const ref = (0, import_react142.useRef)(null);
24556
+ const ref = (0, import_react141.useRef)(null);
24876
24557
  const {
24877
24558
  buttonProps,
24878
24559
  isPressed
24879
- } = (0, import_react_aria63.useButton)(ariaProps, ref);
24560
+ } = (0, import_react_aria62.useButton)(ariaProps, ref);
24880
24561
  const {
24881
24562
  isFocusVisible,
24882
24563
  focusProps
24883
- } = (0, import_react_aria63.useFocusRing)();
24564
+ } = (0, import_react_aria62.useFocusRing)();
24884
24565
  const {
24885
24566
  hoverProps,
24886
24567
  isHovered
24887
- } = (0, import_react_aria63.useHover)(ariaProps);
24568
+ } = (0, import_react_aria62.useHover)(ariaProps);
24888
24569
  const focusRingStyles2 = state === "error" ? {
24889
24570
  boxShadow: "bshDanger"
24890
24571
  } : {
24891
24572
  boxShadow: "bshFocus"
24892
24573
  };
24893
24574
  const tid = useTestIds(props, "stepButton");
24894
- return /* @__PURE__ */ (0, import_jsx_runtime196.jsxs)("button", { ref, ...buttonProps, ...focusProps, ...hoverProps, ...(0, import_runtime114.trussProps)({
24575
+ return /* @__PURE__ */ (0, import_jsx_runtime194.jsxs)("button", { ref, ...buttonProps, ...focusProps, ...hoverProps, ...(0, import_runtime112.trussProps)({
24895
24576
  ...{
24896
24577
  fontWeight: "fw6",
24897
24578
  fontSize: "fz_14px",
@@ -24943,7 +24624,7 @@ function StepButton(props) {
24943
24624
  } : {},
24944
24625
  ...isFocusVisible ? focusRingStyles2 : {}
24945
24626
  }), ...tid[defaultTestId(label)], children: [
24946
- /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("span", { className: "fs0 mr_4px", children: /* @__PURE__ */ (0, import_jsx_runtime196.jsx)(StepIcon, { state, isHovered, isPressed, isCurrent }) }),
24627
+ /* @__PURE__ */ (0, import_jsx_runtime194.jsx)("span", { className: "fs0 mr_4px", children: /* @__PURE__ */ (0, import_jsx_runtime194.jsx)(StepIcon, { state, isHovered, isPressed, isCurrent }) }),
24947
24628
  label
24948
24629
  ] });
24949
24630
  }
@@ -24954,12 +24635,12 @@ function StepIcon({
24954
24635
  isCurrent = false
24955
24636
  }) {
24956
24637
  if (state === "error") {
24957
- return /* @__PURE__ */ (0, import_jsx_runtime196.jsx)(Icon, { icon: "errorCircle" });
24638
+ return /* @__PURE__ */ (0, import_jsx_runtime194.jsx)(Icon, { icon: "errorCircle" });
24958
24639
  }
24959
24640
  if (state === "complete") {
24960
- return /* @__PURE__ */ (0, import_jsx_runtime196.jsx)(Icon, { icon: "check" });
24641
+ return /* @__PURE__ */ (0, import_jsx_runtime194.jsx)(Icon, { icon: "check" });
24961
24642
  }
24962
- return /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("div", { className: "w_24px h_24px df aic jcc", children: /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("div", { ...(0, import_runtime114.trussProps)({
24643
+ return /* @__PURE__ */ (0, import_jsx_runtime194.jsx)("div", { className: "w_24px h_24px df aic jcc", children: /* @__PURE__ */ (0, import_jsx_runtime194.jsx)("div", { ...(0, import_runtime112.trussProps)({
24963
24644
  width: "w_10px",
24964
24645
  height: "h_10px",
24965
24646
  borderStyle: "bss",
@@ -24973,10 +24654,10 @@ function StepIcon({
24973
24654
  }
24974
24655
 
24975
24656
  // src/components/StepperTabs/StepperTab.tsx
24976
- var import_react144 = require("react");
24977
- var import_react_aria64 = require("react-aria");
24978
- var import_runtime115 = require("@homebound/truss/runtime");
24979
- var import_jsx_runtime197 = require("react/jsx-runtime");
24657
+ var import_react143 = require("react");
24658
+ var import_react_aria63 = require("react-aria");
24659
+ var import_runtime113 = require("@homebound/truss/runtime");
24660
+ var import_jsx_runtime195 = require("react/jsx-runtime");
24980
24661
  function StepperTab(props) {
24981
24662
  const {
24982
24663
  label,
@@ -24991,20 +24672,20 @@ function StepperTab(props) {
24991
24672
  onPress: () => onClick(value),
24992
24673
  isDisabled: disabled || collapsed
24993
24674
  };
24994
- const ref = (0, import_react144.useRef)(null);
24675
+ const ref = (0, import_react143.useRef)(null);
24995
24676
  const {
24996
24677
  buttonProps
24997
- } = (0, import_react_aria64.useButton)(ariaProps, ref);
24678
+ } = (0, import_react_aria63.useButton)(ariaProps, ref);
24998
24679
  const {
24999
24680
  isFocusVisible,
25000
24681
  focusProps
25001
- } = (0, import_react_aria64.useFocusRing)();
24682
+ } = (0, import_react_aria63.useFocusRing)();
25002
24683
  const {
25003
24684
  hoverProps,
25004
24685
  isHovered
25005
- } = (0, import_react_aria64.useHover)(ariaProps);
24686
+ } = (0, import_react_aria63.useHover)(ariaProps);
25006
24687
  const tid = useTestIds(props, "stepperTab");
25007
- return /* @__PURE__ */ (0, import_jsx_runtime197.jsxs)("button", { ref, ...(0, import_react_aria64.mergeProps)(buttonProps, focusProps, hoverProps), "aria-label": label, ...(0, import_runtime115.trussProps)({
24688
+ return /* @__PURE__ */ (0, import_jsx_runtime195.jsxs)("button", { ref, ...(0, import_react_aria63.mergeProps)(buttonProps, focusProps, hoverProps), "aria-label": label, ...(0, import_runtime113.trussProps)({
25008
24689
  ...stepperTabStyles.baseStyles,
25009
24690
  ...getStateStyles(active, completed),
25010
24691
  ...isHovered && !disabled ? stepperTabStyles.hoverStyles : {},
@@ -25012,9 +24693,9 @@ function StepperTab(props) {
25012
24693
  ...disabled ? stepperTabStyles.disabledStyles : {},
25013
24694
  ...isFocusVisible ? stepperTabStyles.focusRingStyles : {}
25014
24695
  }), ...tid[defaultTestId(value)], children: [
25015
- /* @__PURE__ */ (0, import_jsx_runtime197.jsx)("span", { className: "oh d_negwebkit_box wbo_vertical to_ellipsis wlc_1", children: label }),
25016
- completed && /* @__PURE__ */ (0, import_jsx_runtime197.jsx)("span", { className: "fs0 ml1", children: /* @__PURE__ */ (0, import_jsx_runtime197.jsx)(Icon, { icon: "check", inc: 2.5, ...tid.check }) }),
25017
- /* @__PURE__ */ (0, import_jsx_runtime197.jsx)(import_react_aria64.VisuallyHidden, { children: completed ? "Complete" : "Not Complete" })
24696
+ /* @__PURE__ */ (0, import_jsx_runtime195.jsx)("span", { className: "oh d_negwebkit_box wbo_vertical to_ellipsis wlc_1", children: label }),
24697
+ completed && /* @__PURE__ */ (0, import_jsx_runtime195.jsx)("span", { className: "fs0 ml1", children: /* @__PURE__ */ (0, import_jsx_runtime195.jsx)(Icon, { icon: "check", inc: 2.5, ...tid.check }) }),
24698
+ /* @__PURE__ */ (0, import_jsx_runtime195.jsx)(import_react_aria63.VisuallyHidden, { children: completed ? "Complete" : "Not Complete" })
25018
24699
  ] });
25019
24700
  }
25020
24701
  function withBorderBottom(color) {
@@ -25022,7 +24703,7 @@ function withBorderBottom(color) {
25022
24703
  ...{
25023
24704
  borderBottomStyle: "bbs_solid",
25024
24705
  borderBottomWidth: ["borderBottomWidth_var", {
25025
- "--borderBottomWidth": (0, import_runtime115.maybeCssVar)(`3px`)
24706
+ "--borderBottomWidth": (0, import_runtime113.maybeCssVar)(`3px`)
25026
24707
  }]
25027
24708
  },
25028
24709
  ...color
@@ -25094,9 +24775,9 @@ var stepperTabStyles = {
25094
24775
  };
25095
24776
 
25096
24777
  // src/components/StepperTabs/StepperTabs.tsx
25097
- var import_runtime116 = require("@homebound/truss/runtime");
25098
- var import_jsx_runtime198 = require("react/jsx-runtime");
25099
- var import_react145 = require("react");
24778
+ var import_runtime114 = require("@homebound/truss/runtime");
24779
+ var import_jsx_runtime196 = require("react/jsx-runtime");
24780
+ var import_react144 = require("react");
25100
24781
  function StepperTabs(props) {
25101
24782
  const {
25102
24783
  steps,
@@ -25108,7 +24789,7 @@ function StepperTabs(props) {
25108
24789
  sm: collapsed
25109
24790
  } = useBreakpoint();
25110
24791
  const capWidth = steps.length <= 3;
25111
- return /* @__PURE__ */ (0, import_jsx_runtime198.jsx)("nav", { "aria-label": "steps", className: "w100", ...tid, children: /* @__PURE__ */ (0, import_jsx_runtime198.jsx)("ol", { ...(0, import_runtime116.trussProps)({
24792
+ return /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("nav", { "aria-label": "steps", className: "w100", ...tid, children: /* @__PURE__ */ (0, import_jsx_runtime196.jsx)("ol", { ...(0, import_runtime114.trussProps)({
25112
24793
  padding: "p_0",
25113
24794
  margin: "m_0",
25114
24795
  listStyle: "lis_none",
@@ -25122,7 +24803,7 @@ function StepperTabs(props) {
25122
24803
  borderColor: "bcGray400"
25123
24804
  }), children: steps.map((step) => {
25124
24805
  const isCurrent = step.value === currentStep;
25125
- return /* @__PURE__ */ (0, import_react145.createElement)("li", { ...(0, import_runtime116.trussProps)({
24806
+ return /* @__PURE__ */ (0, import_react144.createElement)("li", { ...(0, import_runtime114.trussProps)({
25126
24807
  display: "df",
25127
24808
  flexGrow: "fg1",
25128
24809
  flexBasis: "fb_0",
@@ -25134,7 +24815,7 @@ function StepperTabs(props) {
25134
24815
  "--maxWidth": `${maxStepWidthPx}px`
25135
24816
  }]
25136
24817
  } : {}
25137
- }), key: step.value, "aria-current": isCurrent, ...tid.step }, /* @__PURE__ */ (0, import_jsx_runtime198.jsx)(StepperTab, { label: step.label, value: step.value, active: isCurrent, completed: step.completed, disabled: step.disabled, collapsed, onClick: onChange, ...tid.tab }));
24818
+ }), key: step.value, "aria-current": isCurrent, ...tid.step }, /* @__PURE__ */ (0, import_jsx_runtime196.jsx)(StepperTab, { label: step.label, value: step.value, active: isCurrent, completed: step.completed, disabled: step.disabled, collapsed, onClick: onChange, ...tid.tab }));
25138
24819
  }) }) });
25139
24820
  }
25140
24821
  var maxStepWidthPx = 280;
@@ -25142,8 +24823,8 @@ var gapPx = 6;
25142
24823
 
25143
24824
  // src/components/SuperDrawer/components/SuperDrawerHeader.tsx
25144
24825
  var import_react_dom7 = require("react-dom");
25145
- var import_runtime117 = require("@homebound/truss/runtime");
25146
- var import_jsx_runtime199 = require("react/jsx-runtime");
24826
+ var import_runtime115 = require("@homebound/truss/runtime");
24827
+ var import_jsx_runtime197 = require("react/jsx-runtime");
25147
24828
  function SuperDrawerHeader(props) {
25148
24829
  const {
25149
24830
  hideControls
@@ -25160,20 +24841,20 @@ function SuperDrawerHeader(props) {
25160
24841
  const currentContent = contentStack.current[contentStack.current.length - 1]?.opts;
25161
24842
  const isDetail = currentContent !== firstContent;
25162
24843
  const tid = useTestIds({}, "superDrawerHeader");
25163
- return (0, import_react_dom7.createPortal)(/* @__PURE__ */ (0, import_jsx_runtime199.jsxs)("div", { className: "df aic jcsb gap3", ...tid, children: [
25164
- isStructuredProps(props) ? /* @__PURE__ */ (0, import_jsx_runtime199.jsxs)("div", { className: "df jcsb aic gap2 fg1", children: [
25165
- /* @__PURE__ */ (0, import_jsx_runtime199.jsxs)("div", { className: "fg1 df aic gap2", children: [
25166
- /* @__PURE__ */ (0, import_jsx_runtime199.jsx)("h1", { className: "fw6 fz_30px lh_36px", children: props.title }),
24844
+ return (0, import_react_dom7.createPortal)(/* @__PURE__ */ (0, import_jsx_runtime197.jsxs)("div", { className: "df aic jcsb gap3", ...tid, children: [
24845
+ isStructuredProps(props) ? /* @__PURE__ */ (0, import_jsx_runtime197.jsxs)("div", { className: "df jcsb aic gap2 fg1", children: [
24846
+ /* @__PURE__ */ (0, import_jsx_runtime197.jsxs)("div", { className: "fg1 df aic gap2", children: [
24847
+ /* @__PURE__ */ (0, import_jsx_runtime197.jsx)("h1", { className: "fw6 fz_30px lh_36px", children: props.title }),
25167
24848
  props.left
25168
24849
  ] }),
25169
- props.right && /* @__PURE__ */ (0, import_jsx_runtime199.jsx)("div", { className: "fs0", children: props.right })
25170
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime199.jsx)("div", { className: "fg1", children: props.children }),
25171
- !hideControls && /* @__PURE__ */ (0, import_jsx_runtime199.jsx)("div", { ...(0, import_runtime117.trussProps)({
24850
+ props.right && /* @__PURE__ */ (0, import_jsx_runtime197.jsx)("div", { className: "fs0", children: props.right })
24851
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime197.jsx)("div", { className: "fg1", children: props.children }),
24852
+ !hideControls && /* @__PURE__ */ (0, import_jsx_runtime197.jsx)("div", { ...(0, import_runtime115.trussProps)({
25172
24853
  flexShrink: "fs0",
25173
24854
  ...isDetail ? {
25174
24855
  visibility: "vh"
25175
24856
  } : {}
25176
- }), children: /* @__PURE__ */ (0, import_jsx_runtime199.jsx)(ButtonGroup, { buttons: [{
24857
+ }), children: /* @__PURE__ */ (0, import_jsx_runtime197.jsx)(ButtonGroup, { buttons: [{
25177
24858
  icon: "chevronLeft",
25178
24859
  onClick: () => onPrevClick && onPrevClick(),
25179
24860
  disabled: !onPrevClick
@@ -25189,18 +24870,18 @@ function isStructuredProps(props) {
25189
24870
  }
25190
24871
 
25191
24872
  // src/components/SuperDrawer/ConfirmCloseModal.tsx
25192
- var import_jsx_runtime200 = require("react/jsx-runtime");
24873
+ var import_jsx_runtime198 = require("react/jsx-runtime");
25193
24874
  function ConfirmCloseModal(props) {
25194
24875
  const { onClose, discardText = "Discard Changes", continueText = "Continue Editing" } = props;
25195
24876
  const { modalState } = useBeamContext();
25196
24877
  function closeModal() {
25197
24878
  modalState.current = void 0;
25198
24879
  }
25199
- return /* @__PURE__ */ (0, import_jsx_runtime200.jsxs)(import_jsx_runtime200.Fragment, { children: [
25200
- /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(ModalHeader, { children: "Are you sure you want to cancel?" }),
25201
- /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(ModalBody, { children: /* @__PURE__ */ (0, import_jsx_runtime200.jsx)("p", { children: "Any changes you've made so far will be lost." }) }),
25202
- /* @__PURE__ */ (0, import_jsx_runtime200.jsxs)(ModalFooter, { children: [
25203
- /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(
24880
+ return /* @__PURE__ */ (0, import_jsx_runtime198.jsxs)(import_jsx_runtime198.Fragment, { children: [
24881
+ /* @__PURE__ */ (0, import_jsx_runtime198.jsx)(ModalHeader, { children: "Are you sure you want to cancel?" }),
24882
+ /* @__PURE__ */ (0, import_jsx_runtime198.jsx)(ModalBody, { children: /* @__PURE__ */ (0, import_jsx_runtime198.jsx)("p", { children: "Any changes you've made so far will be lost." }) }),
24883
+ /* @__PURE__ */ (0, import_jsx_runtime198.jsxs)(ModalFooter, { children: [
24884
+ /* @__PURE__ */ (0, import_jsx_runtime198.jsx)(
25204
24885
  Button,
25205
24886
  {
25206
24887
  variant: "quaternary",
@@ -25211,7 +24892,7 @@ function ConfirmCloseModal(props) {
25211
24892
  }
25212
24893
  }
25213
24894
  ),
25214
- /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(Button, { label: continueText, onClick: closeModal })
24895
+ /* @__PURE__ */ (0, import_jsx_runtime198.jsx)(Button, { label: continueText, onClick: closeModal })
25215
24896
  ] })
25216
24897
  ] });
25217
24898
  }
@@ -25220,8 +24901,8 @@ function ConfirmCloseModal(props) {
25220
24901
  var import_framer_motion6 = require("framer-motion");
25221
24902
 
25222
24903
  // src/components/SuperDrawer/useSuperDrawer.tsx
25223
- var import_react146 = require("react");
25224
- var import_jsx_runtime201 = require("react/jsx-runtime");
24904
+ var import_react145 = require("react");
24905
+ var import_jsx_runtime199 = require("react/jsx-runtime");
25225
24906
  function useSuperDrawer() {
25226
24907
  const {
25227
24908
  drawerContentStack: contentStack,
@@ -25233,7 +24914,7 @@ function useSuperDrawer() {
25233
24914
  function canCloseDrawerDetails(i, doChange) {
25234
24915
  for (const canCloseDrawerDetail of canCloseDetailsChecks.current[i] ?? []) {
25235
24916
  if (!canClose(canCloseDrawerDetail)) {
25236
- openModal({ content: /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(ConfirmCloseModal, { onClose: doChange, ...canCloseDrawerDetail }) });
24917
+ openModal({ content: /* @__PURE__ */ (0, import_jsx_runtime199.jsx)(ConfirmCloseModal, { onClose: doChange, ...canCloseDrawerDetail }) });
25237
24918
  return false;
25238
24919
  }
25239
24920
  }
@@ -25253,14 +24934,14 @@ function useSuperDrawer() {
25253
24934
  for (const canCloseDrawer of canCloseChecks.current) {
25254
24935
  if (!canClose(canCloseDrawer)) {
25255
24936
  openModal({
25256
- content: /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(ConfirmCloseModal, { onClose: doChange, ...canCloseDrawer })
24937
+ content: /* @__PURE__ */ (0, import_jsx_runtime199.jsx)(ConfirmCloseModal, { onClose: doChange, ...canCloseDrawer })
25257
24938
  });
25258
24939
  return;
25259
24940
  }
25260
24941
  }
25261
24942
  doChange();
25262
24943
  }
25263
- const closeActions = (0, import_react146.useMemo)(
24944
+ const closeActions = (0, import_react145.useMemo)(
25264
24945
  () => {
25265
24946
  return {
25266
24947
  /** Attempts to close the drawer. If any checks fail, a confirmation modal will appear */
@@ -25295,7 +24976,7 @@ function useSuperDrawer() {
25295
24976
  // eslint-disable-next-line react-hooks/exhaustive-deps
25296
24977
  [canCloseChecks, canCloseDetailsChecks, contentStack, modalState, openModal]
25297
24978
  );
25298
- const actions = (0, import_react146.useMemo)(
24979
+ const actions = (0, import_react145.useMemo)(
25299
24980
  () => {
25300
24981
  return {
25301
24982
  // TODO: Maybe we should rename to openDrawer as a breaking change (to match openDrawerDetail)
@@ -25348,8 +25029,8 @@ function canClose(canCloseCheck) {
25348
25029
  }
25349
25030
 
25350
25031
  // src/components/SuperDrawer/SuperDrawerContent.tsx
25351
- var import_runtime118 = require("@homebound/truss/runtime");
25352
- var import_jsx_runtime202 = require("react/jsx-runtime");
25032
+ var import_runtime116 = require("@homebound/truss/runtime");
25033
+ var import_jsx_runtime200 = require("react/jsx-runtime");
25353
25034
  var SuperDrawerContent = ({
25354
25035
  children,
25355
25036
  actions
@@ -25365,95 +25046,360 @@ var SuperDrawerContent = ({
25365
25046
  } = contentStack.current[contentStack.current.length - 1] ?? {};
25366
25047
  const firstContent = contentStack.current[0]?.opts;
25367
25048
  const {
25368
- width: width2 = 1040 /* Normal */
25369
- } = firstContent ?? {};
25370
- function wrapWithMotionAndMaybeBack(children2) {
25371
- if (kind === "open") {
25372
- return /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(import_framer_motion6.motion.div, { className: "pt3 pb3 pr3 pl3 fg1 oa", children: children2 }, "content");
25373
- } else if (kind === "detail") {
25374
- return /* @__PURE__ */ (0, import_jsx_runtime202.jsxs)(import_framer_motion6.motion.div, { className: "pl3 pr3 pt2 pb3 fg1", animate: {
25375
- overflow: "auto"
25376
- }, transition: {
25377
- overflow: {
25378
- delay: 0.3
25379
- }
25380
- }, children: [
25381
- /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(Button, { label: "Back", icon: "chevronLeft", variant: "tertiary", onClick: closeDrawerDetail }),
25382
- /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(import_framer_motion6.motion.div, { initial: {
25383
- x: width2,
25384
- opacity: 0
25385
- }, animate: {
25386
- x: 0,
25387
- opacity: 1
25388
- }, transition: {
25389
- ease: "linear",
25390
- duration: 0.3,
25391
- opacity: {
25392
- delay: 0.15
25393
- }
25394
- }, exit: {
25395
- x: width2,
25396
- opacity: 0
25397
- }, className: "pt2", children: children2 })
25398
- ] }, "content");
25399
- } else {
25400
- return /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(import_framer_motion6.motion.div, { ...(0, import_runtime118.mergeProps)(void 0, {
25401
- overflow: "auto"
25402
- }, {
25403
- paddingTop: "pt3",
25404
- paddingBottom: "pb3",
25405
- paddingRight: "pr3",
25406
- paddingLeft: "pl3",
25407
- flexGrow: "fg1"
25408
- }) }, "content");
25049
+ width: width2 = 1040 /* Normal */
25050
+ } = firstContent ?? {};
25051
+ function wrapWithMotionAndMaybeBack(children2) {
25052
+ if (kind === "open") {
25053
+ return /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(import_framer_motion6.motion.div, { className: "pt3 pb3 pr3 pl3 fg1 oa", children: children2 }, "content");
25054
+ } else if (kind === "detail") {
25055
+ return /* @__PURE__ */ (0, import_jsx_runtime200.jsxs)(import_framer_motion6.motion.div, { className: "pl3 pr3 pt2 pb3 fg1", animate: {
25056
+ overflow: "auto"
25057
+ }, transition: {
25058
+ overflow: {
25059
+ delay: 0.3
25060
+ }
25061
+ }, children: [
25062
+ /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(Button, { label: "Back", icon: "chevronLeft", variant: "tertiary", onClick: closeDrawerDetail }),
25063
+ /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(import_framer_motion6.motion.div, { initial: {
25064
+ x: width2,
25065
+ opacity: 0
25066
+ }, animate: {
25067
+ x: 0,
25068
+ opacity: 1
25069
+ }, transition: {
25070
+ ease: "linear",
25071
+ duration: 0.3,
25072
+ opacity: {
25073
+ delay: 0.15
25074
+ }
25075
+ }, exit: {
25076
+ x: width2,
25077
+ opacity: 0
25078
+ }, className: "pt2", children: children2 })
25079
+ ] }, "content");
25080
+ } else {
25081
+ return /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(import_framer_motion6.motion.div, { ...(0, import_runtime116.mergeProps)(void 0, {
25082
+ overflow: "auto"
25083
+ }, {
25084
+ paddingTop: "pt3",
25085
+ paddingBottom: "pb3",
25086
+ paddingRight: "pr3",
25087
+ paddingLeft: "pl3",
25088
+ flexGrow: "fg1"
25089
+ }) }, "content");
25090
+ }
25091
+ }
25092
+ return /* @__PURE__ */ (0, import_jsx_runtime200.jsxs)(import_jsx_runtime200.Fragment, { children: [
25093
+ wrapWithMotionAndMaybeBack(children),
25094
+ actions && /* @__PURE__ */ (0, import_jsx_runtime200.jsx)("footer", { className: "bts_solid btw_1px bcGray200 pt3 pb3 pr3 pl3 df aic jcfe", children: /* @__PURE__ */ (0, import_jsx_runtime200.jsx)("div", { className: "df gap1", children: actions.map((buttonProps, i) => /* @__PURE__ */ (0, import_jsx_runtime200.jsx)(Button, { ...buttonProps }, i)) }) })
25095
+ ] });
25096
+ };
25097
+
25098
+ // src/components/Table/cardSlots.ts
25099
+ function cardTitleSlot(text) {
25100
+ return { kind: "title", text };
25101
+ }
25102
+ function cardEyebrowSlot(text) {
25103
+ return { kind: "eyebrow", text };
25104
+ }
25105
+ function cardBadgeSlot(text, tags) {
25106
+ return { kind: "badge", text, tags };
25107
+ }
25108
+ function cardStatusSlot(tag) {
25109
+ return { kind: "status", tag };
25110
+ }
25111
+ function cardDataBlockSlot(props) {
25112
+ return { kind: "dataBlock", ...props };
25113
+ }
25114
+ function cardProgressSlot(value) {
25115
+ return { kind: "progress", value };
25116
+ }
25117
+
25118
+ // src/components/Table/utils/simpleHelpers.ts
25119
+ var simpleHeader = { kind: "header", id: "header", data: void 0 };
25120
+ function simpleDataRows(data = []) {
25121
+ return [simpleHeader, ...data.map((data2) => ({ kind: "data", data: data2, id: data2.id }))];
25122
+ }
25123
+
25124
+ // src/components/Table/utils/visitor.ts
25125
+ function visit(rows, fn) {
25126
+ const todo = [...rows];
25127
+ while (todo.length > 0) {
25128
+ const row = todo.pop();
25129
+ fn(row);
25130
+ if (row.children) {
25131
+ todo.push(...row.children);
25132
+ }
25133
+ }
25134
+ }
25135
+
25136
+ // src/components/Tabs.tsx
25137
+ var import_change_case9 = require("change-case");
25138
+ var import_react146 = require("react");
25139
+ var import_react_aria64 = require("react-aria");
25140
+ var import_react_router = require("react-router");
25141
+ var import_react_router_dom8 = require("react-router-dom");
25142
+ var import_runtime117 = require("@homebound/truss/runtime");
25143
+ var import_jsx_runtime201 = require("react/jsx-runtime");
25144
+ function TabsWithContent(props) {
25145
+ const styles = hideTabs(props) ? {} : {
25146
+ paddingTop: "pt3"
25147
+ };
25148
+ return /* @__PURE__ */ (0, import_jsx_runtime201.jsxs)(import_jsx_runtime201.Fragment, { children: [
25149
+ /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(Tabs, { ...props }),
25150
+ /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(TabContent, { ...props, contentXss: {
25151
+ ...styles,
25152
+ ...props.contentXss
25153
+ } })
25154
+ ] });
25155
+ }
25156
+ function TabContent(props) {
25157
+ const tid = useTestIds(props, "tab");
25158
+ const {
25159
+ tabs,
25160
+ contentXss = {},
25161
+ omitFullBleedPadding = false
25162
+ } = props;
25163
+ const location = (0, import_react_router_dom8.useLocation)();
25164
+ const selectedTab = isRouteTabs(props) ? props.tabs.find((t) => {
25165
+ const paths = Array.isArray(t.path) ? t.path : [t.path];
25166
+ return paths.some((p) => !!(0, import_react_router.matchPath)({
25167
+ path: p,
25168
+ end: true
25169
+ }, location.pathname));
25170
+ }) || tabs[0] : props.tabs.find((tab) => tab.value === props.selected) || tabs[0];
25171
+ const uniqueValue = uniqueTabValue(selectedTab);
25172
+ return (
25173
+ // Using FullBleed to allow the tab's bgColor to extend to the edges of the <ScrollableContent /> element.
25174
+ // Omit the padding from `FullBleed` if the caller passes in the `paddingLeft/Right` styles.
25175
+ /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(FullBleed, { omitPadding: omitFullBleedPadding, children: /* @__PURE__ */ (0, import_jsx_runtime201.jsx)("div", { "aria-labelledby": `${uniqueValue}-tab`, id: `${uniqueValue}-tabPanel`, role: "tabpanel", tabIndex: 0, ...tid.panel, ...(0, import_runtime117.trussProps)(contentXss), children: selectedTab.render() }) })
25176
+ );
25177
+ }
25178
+ function Tabs(props) {
25179
+ const {
25180
+ ariaLabel,
25181
+ tabs,
25182
+ includeBottomBorder,
25183
+ right,
25184
+ ...others
25185
+ } = props;
25186
+ const location = (0, import_react_router_dom8.useLocation)();
25187
+ const selected = isRouteTabs(props) ? uniqueTabValue(props.tabs.find((t) => {
25188
+ const paths = Array.isArray(t.path) ? t.path : [t.path];
25189
+ return paths.some((p) => !!(0, import_react_router.matchPath)({
25190
+ path: p,
25191
+ end: true
25192
+ }, location.pathname));
25193
+ }) || props.tabs[0]) : props.selected;
25194
+ const {
25195
+ isFocusVisible,
25196
+ focusProps
25197
+ } = (0, import_react_aria64.useFocusRing)();
25198
+ const tid = useTestIds(others, "tabs");
25199
+ const [active, setActive] = (0, import_react146.useState)(selected);
25200
+ const ref = (0, import_react146.useRef)(null);
25201
+ (0, import_react146.useEffect)(() => setActive(selected), [selected]);
25202
+ function onKeyUp(e) {
25203
+ if (e.key === "ArrowLeft" || e.key === "ArrowRight") {
25204
+ const nextTabValue = getNextTabValue(active, e.key, tabs);
25205
+ setActive(nextTabValue);
25206
+ document.getElementById(`${nextTabValue}-tab`)?.focus();
25207
+ }
25208
+ }
25209
+ function onClick(value) {
25210
+ !isRouteTabs(props) && props.onChange(value);
25211
+ }
25212
+ function onBlur(e) {
25213
+ if (!(ref.current && ref.current.contains(e.relatedTarget))) {
25214
+ setActive(selected);
25215
+ }
25216
+ }
25217
+ return /* @__PURE__ */ (0, import_jsx_runtime201.jsxs)("div", { ...(0, import_runtime117.trussProps)({
25218
+ ...{
25219
+ display: "df",
25220
+ alignItems: "aic",
25221
+ overflow: "oa",
25222
+ whiteSpace: "wsnw",
25223
+ gap: "gap1"
25224
+ },
25225
+ ...includeBottomBorder ? {
25226
+ ...{
25227
+ borderBottomStyle: "bbs_solid",
25228
+ borderBottomWidth: "bbw_1px",
25229
+ borderColor: "bcGray200"
25230
+ }
25231
+ } : {}
25232
+ }), children: [
25233
+ !hideTabs(props) && /* @__PURE__ */ (0, import_jsx_runtime201.jsx)("div", { ref, className: "dif gap1 asfe", "aria-label": ariaLabel, role: "tablist", ...tid, children: tabs.map((tab) => {
25234
+ const uniqueValue = uniqueTabValue(tab);
25235
+ return /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(TabImpl, { active: active === uniqueValue, focusProps, isFocusVisible, onClick, onKeyUp, onBlur, tab, ...tid[defaultTestId(uniqueValue)] }, uniqueValue);
25236
+ }) }),
25237
+ right && /* @__PURE__ */ (0, import_jsx_runtime201.jsx)("div", { className: "mla df aic gap1 pb1", children: right })
25238
+ ] });
25239
+ }
25240
+ function TabImpl(props) {
25241
+ const {
25242
+ tab,
25243
+ onClick,
25244
+ active,
25245
+ onKeyUp,
25246
+ onBlur,
25247
+ focusProps,
25248
+ isFocusVisible = false,
25249
+ ...others
25250
+ } = props;
25251
+ const {
25252
+ disabled = false,
25253
+ name: label,
25254
+ icon,
25255
+ endAdornment
25256
+ } = tab;
25257
+ const isDisabled = !!disabled;
25258
+ const {
25259
+ hoverProps,
25260
+ isHovered
25261
+ } = (0, import_react_aria64.useHover)({
25262
+ isDisabled
25263
+ });
25264
+ const {
25265
+ baseStyles: baseStyles4,
25266
+ activeStyles: activeStyles3,
25267
+ focusRingStyles: focusRingStyles2,
25268
+ hoverStyles: hoverStyles4,
25269
+ disabledStyles: disabledStyles3,
25270
+ activeHoverStyles
25271
+ } = (0, import_react146.useMemo)(() => getTabStyles(), []);
25272
+ const uniqueValue = uniqueTabValue(tab);
25273
+ const tabProps = {
25274
+ "aria-controls": `${uniqueValue}-tabPanel`,
25275
+ "aria-selected": active,
25276
+ "aria-disabled": isDisabled || void 0,
25277
+ id: `${uniqueValue}-tab`,
25278
+ role: "tab",
25279
+ tabIndex: active ? 0 : -1,
25280
+ ...others,
25281
+ ...(0, import_runtime117.trussProps)({
25282
+ ...baseStyles4,
25283
+ ...active && activeStyles3,
25284
+ ...isDisabled && disabledStyles3,
25285
+ ...isHovered && hoverStyles4,
25286
+ ...isHovered && active && activeHoverStyles,
25287
+ ...isFocusVisible && active && focusRingStyles2
25288
+ })
25289
+ };
25290
+ const interactiveProps = (0, import_react_aria64.mergeProps)(focusProps, hoverProps, {
25291
+ onKeyUp,
25292
+ onBlur,
25293
+ ...isRouteTab(tab) ? {} : {
25294
+ onClick: () => onClick(tab.value)
25409
25295
  }
25410
- }
25411
- return /* @__PURE__ */ (0, import_jsx_runtime202.jsxs)(import_jsx_runtime202.Fragment, { children: [
25412
- wrapWithMotionAndMaybeBack(children),
25413
- actions && /* @__PURE__ */ (0, import_jsx_runtime202.jsx)("footer", { className: "bts_solid btw_1px bcGray200 pt3 pb3 pr3 pl3 df aic jcfe", children: /* @__PURE__ */ (0, import_jsx_runtime202.jsx)("div", { className: "df gap1", children: actions.map((buttonProps, i) => /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(Button, { ...buttonProps }, i)) }) })
25296
+ });
25297
+ const tabLabel = /* @__PURE__ */ (0, import_jsx_runtime201.jsxs)(import_jsx_runtime201.Fragment, { children: [
25298
+ label,
25299
+ (icon || endAdornment) && /* @__PURE__ */ (0, import_jsx_runtime201.jsx)("span", { className: "ml1", children: icon ? /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(Icon, { icon }) : endAdornment })
25414
25300
  ] });
25415
- };
25416
-
25417
- // src/components/Table/cardSlots.ts
25418
- function cardTitleSlot(text) {
25419
- return { kind: "title", text };
25420
- }
25421
- function cardEyebrowSlot(text) {
25422
- return { kind: "eyebrow", text };
25301
+ return isDisabled ? maybeTooltip({
25302
+ title: resolveTooltip(disabled),
25303
+ placement: "top",
25304
+ children: /* @__PURE__ */ (0, import_jsx_runtime201.jsx)("div", { ...tabProps, children: tabLabel })
25305
+ }) : isRouteTab(tab) ? /* @__PURE__ */ (0, import_jsx_runtime201.jsx)(import_react_router_dom8.Link, { ...(0, import_react_aria64.mergeProps)(tabProps, interactiveProps, {
25306
+ className: "navLink"
25307
+ }), to: tab.href, children: tabLabel }) : /* @__PURE__ */ (0, import_jsx_runtime201.jsx)("button", { ...{
25308
+ ...tabProps,
25309
+ ...interactiveProps
25310
+ }, children: tabLabel });
25423
25311
  }
25424
- function cardBadgeSlot(text, tags) {
25425
- return { kind: "badge", text, tags };
25312
+ function getTabStyles() {
25313
+ const borderBottomWidthPx = 4;
25314
+ const verticalPaddingPx = 6;
25315
+ const borderBottomStyles = {
25316
+ borderBottomStyle: "bbs_solid",
25317
+ borderBottomWidth: ["borderBottomWidth_var", {
25318
+ "--borderBottomWidth": (0, import_runtime117.maybeCssVar)(`${borderBottomWidthPx}px`)
25319
+ }],
25320
+ paddingBottom: ["pb_var", {
25321
+ "--paddingBottom": `${verticalPaddingPx - borderBottomWidthPx}px`
25322
+ }]
25323
+ };
25324
+ return {
25325
+ baseStyles: {
25326
+ display: "df",
25327
+ alignItems: "aic",
25328
+ height: "h_32px",
25329
+ paddingTop: ["py_var", {
25330
+ "--paddingTop": `${verticalPaddingPx}px`
25331
+ }],
25332
+ paddingBottom: ["py_var", {
25333
+ "--paddingBottom": `${verticalPaddingPx}px`
25334
+ }],
25335
+ paddingLeft: "pl1",
25336
+ paddingRight: "pr1",
25337
+ outline: "outline0",
25338
+ color: "gray700",
25339
+ width: "width_fit_content",
25340
+ cursor: "cursorPointer",
25341
+ fontWeight: "fw4",
25342
+ fontSize: "fz_14px",
25343
+ lineHeight: "lh_20px"
25344
+ },
25345
+ activeStyles: {
25346
+ ...{
25347
+ borderColor: "bcBlue700",
25348
+ fontWeight: "fw6",
25349
+ fontSize: "fz_14px",
25350
+ lineHeight: "lh_20px",
25351
+ color: "gray900"
25352
+ },
25353
+ ...borderBottomStyles
25354
+ },
25355
+ disabledStyles: {
25356
+ color: "gray400",
25357
+ cursor: "cursorNotAllowed"
25358
+ },
25359
+ focusRingStyles: {
25360
+ backgroundColor: "bgBlue50",
25361
+ boxShadow: "bshFocus"
25362
+ },
25363
+ hoverStyles: {
25364
+ ...{
25365
+ borderColor: "bcGray400"
25366
+ },
25367
+ ...borderBottomStyles
25368
+ },
25369
+ activeHoverStyles: {
25370
+ ...{
25371
+ backgroundColor: "bgBlue50",
25372
+ borderColor: "bcBlue700"
25373
+ },
25374
+ ...borderBottomStyles
25375
+ }
25376
+ };
25426
25377
  }
25427
- function cardStatusSlot(tag) {
25428
- return { kind: "status", tag };
25378
+ function getNextTabValue(selected, key, tabs) {
25379
+ const enabledTabs = tabs.filter((tab) => tab.disabled !== true);
25380
+ const tabsToScan = key === "ArrowRight" ? enabledTabs : enabledTabs.reverse();
25381
+ const currentIndex = tabsToScan.findIndex((tab) => uniqueTabValue(tab) === selected);
25382
+ const nextIndex = currentIndex === tabsToScan.length - 1 ? 0 : currentIndex + 1;
25383
+ return uniqueTabValue(tabsToScan[nextIndex]);
25429
25384
  }
25430
- function cardDataBlockSlot(props) {
25431
- return { kind: "dataBlock", ...props };
25385
+ function isRouteTabs(props) {
25386
+ const {
25387
+ tabs
25388
+ } = props;
25389
+ return tabs.length > 0 && isRouteTab(tabs[0]);
25432
25390
  }
25433
- function cardProgressSlot(value) {
25434
- return { kind: "progress", value };
25391
+ function isRouteTab(tab) {
25392
+ return "path" in tab;
25435
25393
  }
25436
-
25437
- // src/components/Table/utils/simpleHelpers.ts
25438
- var simpleHeader = { kind: "header", id: "header", data: void 0 };
25439
- function simpleDataRows(data = []) {
25440
- return [simpleHeader, ...data.map((data2) => ({ kind: "data", data: data2, id: data2.id }))];
25394
+ function uniqueTabValue(tab) {
25395
+ return isRouteTab(tab) ? (0, import_change_case9.camelCase)(tab.name) : tab.value;
25441
25396
  }
25442
-
25443
- // src/components/Table/utils/visitor.ts
25444
- function visit(rows, fn) {
25445
- const todo = [...rows];
25446
- while (todo.length > 0) {
25447
- const row = todo.pop();
25448
- fn(row);
25449
- if (row.children) {
25450
- todo.push(...row.children);
25451
- }
25452
- }
25397
+ function hideTabs(props) {
25398
+ return props.alwaysShowAllTabs ? false : props.tabs.filter((t) => !t.disabled).length === 1;
25453
25399
  }
25454
25400
 
25455
25401
  // src/components/TagGroup.tsx
25456
- var import_jsx_runtime203 = require("react/jsx-runtime");
25402
+ var import_jsx_runtime202 = require("react/jsx-runtime");
25457
25403
  function TagGroup(props) {
25458
25404
  const {
25459
25405
  tags,
@@ -25461,9 +25407,9 @@ function TagGroup(props) {
25461
25407
  ...otherProps
25462
25408
  } = props;
25463
25409
  const tid = useTestIds(otherProps, "tagGroup");
25464
- return /* @__PURE__ */ (0, import_jsx_runtime203.jsxs)("div", { ...tid, className: "df aic fww gap1", children: [
25465
- tags.map((tag) => /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(Tag, { ...tag, variant: "secondary" }, tag.text)),
25466
- onEdit && /* @__PURE__ */ (0, import_jsx_runtime203.jsx)("span", { className: "ml1 fw4 fz_14px lh_20px", children: /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(Button, { label: "Edit", variant: "text", onClick: onEdit, ...tid.edit }) })
25410
+ return /* @__PURE__ */ (0, import_jsx_runtime202.jsxs)("div", { ...tid, className: "df aic fww gap1", children: [
25411
+ tags.map((tag) => /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(Tag, { ...tag, variant: "secondary" }, tag.text)),
25412
+ onEdit && /* @__PURE__ */ (0, import_jsx_runtime202.jsx)("span", { className: "ml1 fw4 fz_14px lh_20px", children: /* @__PURE__ */ (0, import_jsx_runtime202.jsx)(Button, { label: "Edit", variant: "text", onClick: onEdit, ...tid.edit }) })
25467
25413
  ] });
25468
25414
  }
25469
25415
 
@@ -25476,15 +25422,15 @@ function useToast() {
25476
25422
  }
25477
25423
 
25478
25424
  // src/layouts/SideNavLayout/SideNavLayout.tsx
25479
- var import_runtime119 = require("@homebound/truss/runtime");
25480
- var import_jsx_runtime204 = require("react/jsx-runtime");
25425
+ var import_runtime118 = require("@homebound/truss/runtime");
25426
+ var import_jsx_runtime203 = require("react/jsx-runtime");
25481
25427
  var __maybeInc21 = (inc) => {
25482
25428
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
25483
25429
  };
25484
25430
  function SideNavLayout(props) {
25485
25431
  const hasProvider = useHasSideNavLayoutProvider();
25486
- if (hasProvider) return /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(SideNavLayoutContent, { ...props });
25487
- return /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(SideNavLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(SideNavLayoutContent, { ...props }) });
25432
+ if (hasProvider) return /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(SideNavLayoutContent, { ...props });
25433
+ return /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(SideNavLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(SideNavLayoutContent, { ...props }) });
25488
25434
  }
25489
25435
  function SideNavLayoutContent(props) {
25490
25436
  const {
@@ -25506,7 +25452,7 @@ function SideNavLayoutContent(props) {
25506
25452
  const railOffsetPx = !showRail ? 0 : !bp.mdAndUp || collapsed ? railCollapsedWidthPx : railWidthPx;
25507
25453
  const navTop = bannerAndNavbarChromeTop();
25508
25454
  const railViewportHeight = `calc(var(${beamLayoutViewportHeightVar}, 100vh) - var(${beamEnvironmentBannerLayoutHeightVar}, 0px) - var(${beamNavbarLayoutHeightVar}, 0px))`;
25509
- const rail = showRail && /* @__PURE__ */ (0, import_jsx_runtime204.jsxs)("div", { ...(0, import_runtime119.trussProps)({
25455
+ const rail = showRail && /* @__PURE__ */ (0, import_jsx_runtime203.jsxs)("div", { ...(0, import_runtime118.trussProps)({
25510
25456
  ...{
25511
25457
  display: "df",
25512
25458
  flexDirection: "fdc",
@@ -25530,14 +25476,14 @@ function SideNavLayoutContent(props) {
25530
25476
  position: "sticky",
25531
25477
  left: "left0",
25532
25478
  zIndex: ["z_var", {
25533
- "--zIndex": (0, import_runtime119.maybeCssVar)(zIndices.sideNav)
25479
+ "--zIndex": (0, import_runtime118.maybeCssVar)(zIndices.sideNav)
25534
25480
  }],
25535
25481
  top: ["top_var", {
25536
- "--top": (0, import_runtime119.maybeCssVar)(__maybeInc21(navTop))
25482
+ "--top": (0, import_runtime118.maybeCssVar)(__maybeInc21(navTop))
25537
25483
  }],
25538
25484
  alignSelf: "asfs",
25539
25485
  height: ["h_var", {
25540
- "--height": (0, import_runtime119.maybeCssVar)(__maybeInc21(railViewportHeight))
25486
+ "--height": (0, import_runtime118.maybeCssVar)(__maybeInc21(railViewportHeight))
25541
25487
  }],
25542
25488
  width: ["w_var", {
25543
25489
  "--width": `${collapsed ? railCollapsedWidthPx : railWidthPx}px`
@@ -25547,11 +25493,11 @@ function SideNavLayoutContent(props) {
25547
25493
  position: "fixed",
25548
25494
  left: "left0",
25549
25495
  top: ["top_var", {
25550
- "--top": (0, import_runtime119.maybeCssVar)(__maybeInc21(navTop))
25496
+ "--top": (0, import_runtime118.maybeCssVar)(__maybeInc21(navTop))
25551
25497
  }],
25552
25498
  bottom: "bottom0",
25553
25499
  zIndex: ["z_var", {
25554
- "--zIndex": (0, import_runtime119.maybeCssVar)(zIndices.sideNav)
25500
+ "--zIndex": (0, import_runtime118.maybeCssVar)(zIndices.sideNav)
25555
25501
  }]
25556
25502
  },
25557
25503
  ...collapsed ? {
@@ -25563,18 +25509,18 @@ function SideNavLayoutContent(props) {
25563
25509
  }
25564
25510
  }
25565
25511
  }), ...tid.sideNav, children: [
25566
- showCollapseToggle && /* @__PURE__ */ (0, import_jsx_runtime204.jsx)("div", { className: "absolute right2 top2 z2", children: /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(IconButton, { icon: collapsed ? "menuOpen" : "menuClose", label: collapsed ? "Expand navigation" : "Collapse navigation", onClick: () => setNavState(collapsed ? "expanded" : "collapse"), ...tid.toggle }) }),
25567
- /* @__PURE__ */ (0, import_jsx_runtime204.jsx)("div", { className: "fg1 mh0 df fdc", ...tid.sideNavContent, children: /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(SideNav, { ...sideNav }) })
25512
+ showCollapseToggle && /* @__PURE__ */ (0, import_jsx_runtime203.jsx)("div", { className: "absolute right2 top2 z2", children: /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(IconButton, { icon: collapsed ? "menuOpen" : "menuClose", label: collapsed ? "Expand navigation" : "Collapse navigation", onClick: () => setNavState(collapsed ? "expanded" : "collapse"), ...tid.toggle }) }),
25513
+ /* @__PURE__ */ (0, import_jsx_runtime203.jsx)("div", { className: "fg1 mh0 df fdc", ...tid.sideNavContent, children: /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(SideNav, { ...sideNav }) })
25568
25514
  ] });
25569
- return /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime204.jsxs)("div", { ...(0, import_runtime119.mergeProps)(void 0, {
25515
+ return /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime203.jsxs)("div", { ...(0, import_runtime118.mergeProps)(void 0, {
25570
25516
  [beamSideNavLayoutWidthVar]: `${railOffsetPx}px`
25571
25517
  }, {
25572
25518
  display: "df",
25573
25519
  flexDirection: "fdr",
25574
25520
  width: "w100"
25575
25521
  }), ...tid, children: [
25576
- contrastRail ? /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(ContrastScope, { children: rail }) : rail,
25577
- /* @__PURE__ */ (0, import_jsx_runtime204.jsx)("div", { ...(0, import_runtime119.trussProps)({
25522
+ contrastRail ? /* @__PURE__ */ (0, import_jsx_runtime203.jsx)(ContrastScope, { children: rail }) : rail,
25523
+ /* @__PURE__ */ (0, import_jsx_runtime203.jsx)("div", { ...(0, import_runtime118.trussProps)({
25578
25524
  display: "df",
25579
25525
  flexDirection: "fdc",
25580
25526
  flexGrow: "fg1",
@@ -25590,8 +25536,8 @@ function SideNavLayoutContent(props) {
25590
25536
  }
25591
25537
 
25592
25538
  // src/layouts/EnvironmentBannerLayout/EnvironmentBannerLayout.tsx
25593
- var import_runtime120 = require("@homebound/truss/runtime");
25594
- var import_jsx_runtime205 = require("react/jsx-runtime");
25539
+ var import_runtime119 = require("@homebound/truss/runtime");
25540
+ var import_jsx_runtime204 = require("react/jsx-runtime");
25595
25541
  var __maybeInc22 = (inc) => {
25596
25542
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
25597
25543
  };
@@ -25607,35 +25553,35 @@ function EnvironmentBannerLayout(props) {
25607
25553
  [beamEnvironmentBannerLayoutHeightVar]: `${bannerHeightPx}px`
25608
25554
  };
25609
25555
  const innerWidth = `var(${beamLayoutViewportWidthVar}, 100vw)`;
25610
- return /* @__PURE__ */ (0, import_jsx_runtime205.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime205.jsx)(EnvironmentBannerLayoutHeightProvider, { value: bannerHeightPx, children: /* @__PURE__ */ (0, import_jsx_runtime205.jsxs)("div", { ...(0, import_runtime120.mergeProps)(void 0, style, {
25556
+ return /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(EnvironmentBannerLayoutHeightProvider, { value: bannerHeightPx, children: /* @__PURE__ */ (0, import_jsx_runtime204.jsxs)("div", { ...(0, import_runtime119.mergeProps)(void 0, style, {
25611
25557
  display: "df",
25612
25558
  flexDirection: "fdc",
25613
25559
  width: "wfc",
25614
25560
  minWidth: "mw100"
25615
25561
  }), ...tid, children: [
25616
- showBanner && environmentBanner && /* @__PURE__ */ (0, import_jsx_runtime205.jsx)("div", { ...(0, import_runtime120.mergeProps)(void 0, {
25562
+ showBanner && environmentBanner && /* @__PURE__ */ (0, import_jsx_runtime204.jsx)("div", { ...(0, import_runtime119.mergeProps)(void 0, {
25617
25563
  height: environmentBannerSizePx
25618
25564
  }, {
25619
25565
  flexShrink: "fs0",
25620
25566
  width: "w100"
25621
- }), children: /* @__PURE__ */ (0, import_jsx_runtime205.jsx)("div", { ...(0, import_runtime120.trussProps)({
25567
+ }), children: /* @__PURE__ */ (0, import_jsx_runtime204.jsx)("div", { ...(0, import_runtime119.trussProps)({
25622
25568
  position: "fixed",
25623
25569
  top: "top0",
25624
25570
  left: "left0",
25625
25571
  zIndex: ["z_var", {
25626
- "--zIndex": (0, import_runtime120.maybeCssVar)(zIndices.environmentBanner)
25572
+ "--zIndex": (0, import_runtime119.maybeCssVar)(zIndices.environmentBanner)
25627
25573
  }],
25628
25574
  width: ["w_var", {
25629
- "--width": (0, import_runtime120.maybeCssVar)(__maybeInc22(innerWidth))
25575
+ "--width": (0, import_runtime119.maybeCssVar)(__maybeInc22(innerWidth))
25630
25576
  }]
25631
- }), ...tid.bannerSticky, children: /* @__PURE__ */ (0, import_jsx_runtime205.jsx)(EnvironmentBanner, { ...environmentBanner, ...tid.environmentBanner }) }) }),
25577
+ }), ...tid.bannerSticky, children: /* @__PURE__ */ (0, import_jsx_runtime204.jsx)(EnvironmentBanner, { ...environmentBanner, ...tid.environmentBanner }) }) }),
25632
25578
  children
25633
25579
  ] }) }) });
25634
25580
  }
25635
25581
 
25636
25582
  // src/layouts/NavbarLayout/NavbarLayout.tsx
25637
25583
  var import_react151 = require("react");
25638
- var import_runtime121 = require("@homebound/truss/runtime");
25584
+ var import_runtime120 = require("@homebound/truss/runtime");
25639
25585
 
25640
25586
  // src/layouts/useAutoHideOnScroll.ts
25641
25587
  var import_react148 = require("react");
@@ -25728,7 +25674,7 @@ function useAutoHideOnScroll(spacerRef, enabled, getTopOffset) {
25728
25674
  }
25729
25675
 
25730
25676
  // src/layouts/useMeasuredHeight.ts
25731
- var import_utils171 = require("@react-aria/utils");
25677
+ var import_utils170 = require("@react-aria/utils");
25732
25678
  var import_react149 = require("react");
25733
25679
  function useMeasuredHeight(ref, enabled) {
25734
25680
  const [height, setHeight] = (0, import_react149.useState)(0);
@@ -25737,7 +25683,7 @@ function useMeasuredHeight(ref, enabled) {
25737
25683
  const next = el ? Math.round(el.getBoundingClientRect().height) : 0;
25738
25684
  setHeight((prev) => prev === next ? prev : next);
25739
25685
  }, [ref]);
25740
- (0, import_utils171.useResizeObserver)({ ref, onResize: syncElementHeight });
25686
+ (0, import_utils170.useResizeObserver)({ ref, onResize: syncElementHeight });
25741
25687
  (0, import_react149.useLayoutEffect)(() => {
25742
25688
  syncElementHeight();
25743
25689
  }, [enabled, syncElementHeight]);
@@ -25746,17 +25692,17 @@ function useMeasuredHeight(ref, enabled) {
25746
25692
 
25747
25693
  // src/layouts/NavbarLayout/NavbarLayoutHeightContext.tsx
25748
25694
  var import_react150 = require("react");
25749
- var import_jsx_runtime206 = require("react/jsx-runtime");
25695
+ var import_jsx_runtime205 = require("react/jsx-runtime");
25750
25696
  var NavbarLayoutHeightContext = (0, import_react150.createContext)(0);
25751
25697
  function NavbarLayoutHeightProvider({ value, children }) {
25752
- return /* @__PURE__ */ (0, import_jsx_runtime206.jsx)(NavbarLayoutHeightContext.Provider, { value, children });
25698
+ return /* @__PURE__ */ (0, import_jsx_runtime205.jsx)(NavbarLayoutHeightContext.Provider, { value, children });
25753
25699
  }
25754
25700
  function useNavbarLayoutHeight() {
25755
25701
  return (0, import_react150.useContext)(NavbarLayoutHeightContext);
25756
25702
  }
25757
25703
 
25758
25704
  // src/layouts/NavbarLayout/NavbarLayout.tsx
25759
- var import_jsx_runtime207 = require("react/jsx-runtime");
25705
+ var import_jsx_runtime206 = require("react/jsx-runtime");
25760
25706
  var __maybeInc23 = (inc) => {
25761
25707
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
25762
25708
  };
@@ -25785,10 +25731,10 @@ function NavbarLayout(props) {
25785
25731
  position: "sticky",
25786
25732
  left: "left0",
25787
25733
  zIndex: ["z_var", {
25788
- "--zIndex": (0, import_runtime121.maybeCssVar)(zIndices.navbar)
25734
+ "--zIndex": (0, import_runtime120.maybeCssVar)(zIndices.navbar)
25789
25735
  }],
25790
25736
  width: ["w_var", {
25791
- "--width": (0, import_runtime121.maybeCssVar)(__maybeInc23(innerWidth))
25737
+ "--width": (0, import_runtime120.maybeCssVar)(__maybeInc23(innerWidth))
25792
25738
  }]
25793
25739
  }
25794
25740
  ) : (
@@ -25797,10 +25743,10 @@ function NavbarLayout(props) {
25797
25743
  position: "fixed",
25798
25744
  left: "left0",
25799
25745
  zIndex: ["z_var", {
25800
- "--zIndex": (0, import_runtime121.maybeCssVar)(zIndices.navbar)
25746
+ "--zIndex": (0, import_runtime120.maybeCssVar)(zIndices.navbar)
25801
25747
  }],
25802
25748
  width: ["w_var", {
25803
- "--width": (0, import_runtime121.maybeCssVar)(__maybeInc23(innerWidth))
25749
+ "--width": (0, import_runtime120.maybeCssVar)(__maybeInc23(innerWidth))
25804
25750
  }],
25805
25751
  transition: "transitionTop"
25806
25752
  }
@@ -25809,26 +25755,90 @@ function NavbarLayout(props) {
25809
25755
  const innerStyle = autoHideState !== "static" ? {
25810
25756
  top: autoHideState === "revealed" ? bannerTop : `calc(${bannerTop} - ${navHeight}px)`
25811
25757
  } : void 0;
25812
- const navbarEl = (0, import_react151.useMemo)(() => /* @__PURE__ */ (0, import_jsx_runtime207.jsx)(Navbar, { ...navbar }), [navbar]);
25813
- return /* @__PURE__ */ (0, import_jsx_runtime207.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime207.jsx)(NavbarLayoutHeightProvider, { value: navbarOffsetPx, children: /* @__PURE__ */ (0, import_jsx_runtime207.jsxs)("div", { ...(0, import_runtime121.mergeProps)(void 0, cssVars, {
25758
+ const navbarEl = (0, import_react151.useMemo)(() => /* @__PURE__ */ (0, import_jsx_runtime206.jsx)(Navbar, { ...navbar }), [navbar]);
25759
+ return /* @__PURE__ */ (0, import_jsx_runtime206.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime206.jsx)(NavbarLayoutHeightProvider, { value: navbarOffsetPx, children: /* @__PURE__ */ (0, import_jsx_runtime206.jsxs)("div", { ...(0, import_runtime120.mergeProps)(void 0, cssVars, {
25814
25760
  display: "df",
25815
25761
  flexDirection: "fdc",
25816
25762
  width: "wfc",
25817
25763
  minWidth: "mw100"
25818
25764
  }), ...tid, children: [
25819
- /* @__PURE__ */ (0, import_jsx_runtime207.jsx)("div", { ref: spacerRef, ...(0, import_runtime121.mergeProps)(void 0, {
25765
+ /* @__PURE__ */ (0, import_jsx_runtime206.jsx)("div", { ref: spacerRef, ...(0, import_runtime120.mergeProps)(void 0, {
25820
25766
  height: navHeight
25821
25767
  }, {
25822
25768
  flexShrink: "fs0",
25823
25769
  width: "w100"
25824
- }), children: /* @__PURE__ */ (0, import_jsx_runtime207.jsx)("div", { ref: navMetricsRef, ...(0, import_runtime121.mergeProps)(void 0, innerStyle, innerCss), ...tid.navbar, children: navbarEl }) }),
25825
- /* @__PURE__ */ (0, import_jsx_runtime207.jsx)("div", { className: "df fdc mh0 mw100 w100", ...tid.body, children })
25770
+ }), children: /* @__PURE__ */ (0, import_jsx_runtime206.jsx)("div", { ref: navMetricsRef, ...(0, import_runtime120.mergeProps)(void 0, innerStyle, innerCss), ...tid.navbar, children: navbarEl }) }),
25771
+ /* @__PURE__ */ (0, import_jsx_runtime206.jsx)("div", { className: "df fdc mh0 mw100 w100", ...tid.body, children })
25826
25772
  ] }) }) });
25827
25773
  }
25828
25774
 
25829
25775
  // src/layouts/PageHeaderLayout/PageHeaderLayout.tsx
25830
25776
  var import_react152 = require("react");
25831
25777
 
25778
+ // src/components/Headers/BaseHeader.tsx
25779
+ var import_runtime121 = require("@homebound/truss/runtime");
25780
+ var import_jsx_runtime207 = require("react/jsx-runtime");
25781
+ function BaseHeader(props) {
25782
+ const {
25783
+ title,
25784
+ documentTitleSuffix,
25785
+ rightSlot,
25786
+ breadcrumbs,
25787
+ bottomSlot,
25788
+ ...otherProps
25789
+ } = props;
25790
+ const tid = useTestIds(otherProps, "header");
25791
+ useDocumentTitle(title, documentTitleSuffix);
25792
+ return /* @__PURE__ */ (0, import_jsx_runtime207.jsxs)("header", { ...tid, ...(0, import_runtime121.trussProps)({
25793
+ display: "df",
25794
+ flexDirection: "fdc",
25795
+ paddingTop: "pt3",
25796
+ borderBottomStyle: "bbs_solid",
25797
+ borderBottomWidth: "bbw_1px",
25798
+ gap: "gap2",
25799
+ borderColor: ["bc_var", {
25800
+ "--borderColor": "var(--b-surface-separator)"
25801
+ }],
25802
+ backgroundColor: ["bgColor_var", {
25803
+ "--backgroundColor": "var(--b-surface)"
25804
+ }]
25805
+ }), children: [
25806
+ /* @__PURE__ */ (0, import_jsx_runtime207.jsxs)("div", { ...(0, import_runtime121.trussProps)({
25807
+ ...{
25808
+ display: "df",
25809
+ justifyContent: "jcsb",
25810
+ width: "w100",
25811
+ gap: "gap1",
25812
+ paddingLeft: "pl3",
25813
+ paddingRight: "pr3"
25814
+ },
25815
+ ...{
25816
+ ...!bottomSlot ? {
25817
+ marginBottom: "mb2"
25818
+ } : {}
25819
+ }
25820
+ }), children: [
25821
+ /* @__PURE__ */ (0, import_jsx_runtime207.jsxs)("div", { className: "mw0", children: [
25822
+ breadcrumbs && /* @__PURE__ */ (0, import_jsx_runtime207.jsx)(Breadcrumbs, { ...breadcrumbs }),
25823
+ /* @__PURE__ */ (0, import_jsx_runtime207.jsx)("h1", { ...tid.title, className: "fw6 fz_20px lh_28px", children: title })
25824
+ ] }),
25825
+ /* @__PURE__ */ (0, import_jsx_runtime207.jsx)("div", { className: "fs0", children: rightSlot })
25826
+ ] }),
25827
+ bottomSlot
25828
+ ] });
25829
+ }
25830
+
25831
+ // src/components/Headers/PageHeader.tsx
25832
+ var import_jsx_runtime208 = require("react/jsx-runtime");
25833
+ function PageHeader2(props) {
25834
+ const {
25835
+ tabs,
25836
+ ...otherProps
25837
+ } = props;
25838
+ const tid = useTestIds(otherProps, "header");
25839
+ return /* @__PURE__ */ (0, import_jsx_runtime208.jsx)(BaseHeader, { ...otherProps, bottomSlot: tabs && /* @__PURE__ */ (0, import_jsx_runtime208.jsx)("div", { className: "pl3 pr3", children: /* @__PURE__ */ (0, import_jsx_runtime208.jsx)(Tabs, { ...tabs, ...tid.tabs }) }) });
25840
+ }
25841
+
25832
25842
  // src/layouts/useBannerAndNavbarHeight.ts
25833
25843
  function useBannerAndNavbarHeight() {
25834
25844
  return useEnvironmentBannerLayoutHeight() + useNavbarLayoutHeight();
@@ -25836,7 +25846,7 @@ function useBannerAndNavbarHeight() {
25836
25846
 
25837
25847
  // src/layouts/PageHeaderLayout/PageHeaderLayout.tsx
25838
25848
  var import_runtime122 = require("@homebound/truss/runtime");
25839
- var import_jsx_runtime208 = require("react/jsx-runtime");
25849
+ var import_jsx_runtime209 = require("react/jsx-runtime");
25840
25850
  var __maybeInc24 = (inc) => {
25841
25851
  return typeof inc === "string" ? inc : `calc(var(--t-spacing) * ${inc})`;
25842
25852
  };
@@ -25891,19 +25901,19 @@ function PageHeaderLayout(props) {
25891
25901
  const innerStyle = autoHideState !== "static" ? {
25892
25902
  top: autoHideState === "revealed" ? outerTop : `calc(${outerTop} - ${headerHeight}px)`
25893
25903
  } : void 0;
25894
- const pageHeaderEl = (0, import_react152.useMemo)(() => /* @__PURE__ */ (0, import_jsx_runtime208.jsx)(PageHeader2, { ...pageHeader }), [pageHeader]);
25895
- return /* @__PURE__ */ (0, import_jsx_runtime208.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime208.jsxs)("div", { ...(0, import_runtime122.mergeProps)(void 0, cssVars, {
25904
+ const pageHeaderEl = (0, import_react152.useMemo)(() => /* @__PURE__ */ (0, import_jsx_runtime209.jsx)(PageHeader2, { ...pageHeader }), [pageHeader]);
25905
+ return /* @__PURE__ */ (0, import_jsx_runtime209.jsx)(DocumentScrollLayoutProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime209.jsxs)("div", { ...(0, import_runtime122.mergeProps)(void 0, cssVars, {
25896
25906
  display: "df",
25897
25907
  flexDirection: "fdc",
25898
25908
  width: "w100"
25899
25909
  }), ...tid, children: [
25900
- /* @__PURE__ */ (0, import_jsx_runtime208.jsx)("div", { ref: spacerRef, ...(0, import_runtime122.mergeProps)(void 0, {
25910
+ /* @__PURE__ */ (0, import_jsx_runtime209.jsx)("div", { ref: spacerRef, ...(0, import_runtime122.mergeProps)(void 0, {
25901
25911
  height: headerHeight
25902
25912
  }, {
25903
25913
  flexShrink: "fs0",
25904
25914
  width: "w100"
25905
- }), children: /* @__PURE__ */ (0, import_jsx_runtime208.jsx)("div", { ref: headerMetricsRef, ...(0, import_runtime122.mergeProps)(void 0, innerStyle, innerCss), ...tid.pageHeader, children: pageHeaderEl }) }),
25906
- /* @__PURE__ */ (0, import_jsx_runtime208.jsx)("div", { className: "df fdc fg1 mh0 w100", ...tid.body, children })
25915
+ }), children: /* @__PURE__ */ (0, import_jsx_runtime209.jsx)("div", { ref: headerMetricsRef, ...(0, import_runtime122.mergeProps)(void 0, innerStyle, innerCss), ...tid.pageHeader, children: pageHeaderEl }) }),
25916
+ /* @__PURE__ */ (0, import_jsx_runtime209.jsx)("div", { className: "df fdc fg1 mh0 w100", ...tid.body, children })
25907
25917
  ] }) });
25908
25918
  }
25909
25919
  // Annotate the CommonJS export names for ESM import in node:
@@ -26014,7 +26024,6 @@ function PageHeaderLayout(props) {
26014
26024
  NavbarLayout,
26015
26025
  NumberField,
26016
26026
  OpenModal,
26017
- PageHeader,
26018
26027
  PageHeaderLayout,
26019
26028
  Pagination,
26020
26029
  Palette,