@arc-ui/components 5.0.0 → 6.2.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.es.js CHANGED
@@ -369,6 +369,10 @@ var BrandLogo = function (_a) {
369
369
  } }, filterDataAttrs(props)), label ? React.createElement("span", { className: "arc-BrandLogo-text" }, label) : null));
370
370
  };
371
371
 
372
+ /**
373
+ * Do not edit directly
374
+ * Generated file
375
+ */
372
376
  const ArcBreakpointM = 768;
373
377
  const ArcBreakpointL = 1024;
374
378
  const iconsSelected = [
@@ -686,8 +690,8 @@ var Button = forwardRef(function (_a, ref) {
686
690
  var ButtonIcon = function (_a) {
687
691
  var icon = _a.icon, isChevron = _a.isChevron, isBeforeText = _a.isBeforeText;
688
692
  return (React.createElement("span", { className: classNames({
689
- "arc-ButtonIcon": true,
690
- "arc-ButtonIcon--chevron": isChevron
693
+ "arc-Button-icon": true,
694
+ "arc-Button-icon--chevron": isChevron
691
695
  }) }, isChevron ? (React.createElement(Icon, { icon: "btChevron".concat(isBeforeText ? "Left" : "Right", "2px") })) : (React.createElement(Icon, { icon: icon }))));
692
696
  };
693
697
 
@@ -731,7 +735,7 @@ var Heading = function (_a) {
731
735
  };
732
736
  var HeadingProposition = function (_a) {
733
737
  var children = _a.children;
734
- return React.createElement("span", { className: "arc-HeadingProposition" }, children);
738
+ return React.createElement("span", { className: "arc-Heading-proposition" }, children);
735
739
  };
736
740
  HeadingProposition.displayName = "Heading.Proposition";
737
741
  Heading.Proposition = HeadingProposition;
@@ -889,13 +893,13 @@ var Card = function (_a) {
889
893
  var CardBlock = function (_a) {
890
894
  var _b = _a.align, align = _b === void 0 ? "left" : _b, children = _a.children, _c = _a.isFullWidth, isFullWidth = _c === void 0 ? false : _c, _d = _a.grow, grow = _d === void 0 ? false : _d;
891
895
  return (React.createElement("div", { className: classNames({
892
- "arc-CardBlock": true,
893
- "arc-CardBlock--alignCenter": align === "center",
894
- "arc-CardBlock--alignRight": align === "right",
895
- "arc-CardBlock--fullWidth": isFullWidth,
896
- "arc-CardBlock--grow": grow
896
+ "arc-Card-block": true,
897
+ "arc-Card-block--alignCenter": align === "center",
898
+ "arc-Card-block--alignRight": align === "right",
899
+ "arc-Card-block--fullWidth": isFullWidth,
900
+ "arc-Card-block--grow": grow
897
901
  }) },
898
- React.createElement("div", { className: "arc-CardBlock-inner" }, children)));
902
+ React.createElement("div", { className: "arc-Card-blockInner" }, children)));
899
903
  };
900
904
  CardBlock.displayName = "Card.Block";
901
905
  Card.Block = CardBlock;
@@ -905,7 +909,7 @@ Card.Block = CardBlock;
905
909
  var CardImage = function (_a) {
906
910
  var _b = _a.alt, alt = _b === void 0 ? "" : _b, _c = _a.height, height = _c === void 0 ? 176 : _c, src = _a.src, srcSet = _a.srcSet;
907
911
  return (React.createElement("div", { className: classNames({
908
- "arc-CardImage": true
912
+ "arc-Card-image": true
909
913
  }) },
910
914
  React.createElement(Image, { alt: alt, fit: "cover", src: src, srcSet: srcSet, height: height })));
911
915
  };
@@ -918,13 +922,13 @@ var CardLink = function (_a) {
918
922
  var actionId = _a.actionId, isButton = _a.isButton, children = _a.children, fill = _a.fill, href = _a.href, stretch = _a.stretch, target = _a.target;
919
923
  var surface = useContext(Context$3).surface;
920
924
  return (React.createElement("a", { "aria-describedby": actionId, className: classNames({
921
- "arc-CardLink": true,
922
- "arc-CardLink--button": isButton,
923
- "arc-CardLink--onDarkSurface": surface === "dark" && fill !== "neutral",
924
- "arc-CardLink--stretch": stretch
925
+ "arc-Card-link": true,
926
+ "arc-Card-link--button": isButton,
927
+ "arc-Card-link--onDarkSurface": surface === "dark" && fill !== "neutral",
928
+ "arc-Card-link--stretch": stretch
925
929
  }), href: href, rel: target === "_blank" ? "noopener noreferrer" : undefined, tabIndex: isButton ? -1 : undefined, target: target },
926
- React.createElement("span", { className: "arc-CardLink-text" }, children),
927
- isButton && (React.createElement("span", { className: "arc-CardLink-icon" },
930
+ React.createElement("span", { className: "arc-Card-linkText" }, children),
931
+ isButton && (React.createElement("span", { className: "arc-Card-linkIcon" },
928
932
  React.createElement(Icon, { icon: "btChevronRight2px", size: 8 })))));
929
933
  };
930
934
 
@@ -967,7 +971,6 @@ var FormControl = function (_a) {
967
971
  }), id: id }, elementProps, filterDataAttrs(props)),
968
972
  React.createElement(LabelType, __assign({ className: "arc-FormControl-label" }, labelProps),
969
973
  label,
970
- " ",
971
974
  requirementStatus === "optional" && (React.createElement("span", { className: "arc-FormControl-labelOptional" }, "(optional)"))),
972
975
  helper && (React.createElement("div", { className: "arc-FormControl-helper", id: idHelper }, helper)),
973
976
  children,
@@ -1008,7 +1011,6 @@ var Checkbox = forwardRef(function (_a, ref) {
1008
1011
  React.createElement("span", { className: "arc-Checkbox-box" }),
1009
1012
  React.createElement("span", null,
1010
1013
  label,
1011
- " ",
1012
1014
  !isRequired && requirementStatus !== "optional" ? (React.createElement("span", { className: "arc-Checkbox-labelOptional" }, "(optional)")) : null,
1013
1015
  helper && React.createElement("span", { className: "arc-Checkbox-helper" }, helper))),
1014
1016
  errorMessage && (React.createElement("div", { id: idError, className: "arc-Checkbox-error" }, errorMessage))));
@@ -1066,24 +1068,24 @@ var Col = function (_a) {
1066
1068
  var _b;
1067
1069
  var align = _a.align, children = _a.children, _c = _a.isDebugVisible, isDebugVisible = _c === void 0 ? false : _c, offset = _a.offset, offsetS = _a.offsetS, offsetM = _a.offsetM, offsetL = _a.offsetL, offsetXL = _a.offsetXL, span = _a.span, spanS = _a.spanS, spanM = _a.spanM, spanL = _a.spanL, spanXL = _a.spanXL, props = __rest(_a, ["align", "children", "isDebugVisible", "offset", "offsetS", "offsetM", "offsetL", "offsetXL", "span", "spanS", "spanM", "spanL", "spanXL"]);
1068
1070
  return (React.createElement("div", __assign({ className: classNames((_b = {},
1069
- _b["arc-Col"] = true,
1070
- _b[suffixModifier("arc-Col--align", align || "")] = align,
1071
- _b["arc-Col--".concat(span)] = typeof span !== "undefined",
1072
- _b["arc-Col--S".concat(spanS)] = typeof spanS !== "undefined",
1073
- _b["arc-Col--M".concat(spanM)] = typeof spanM !== "undefined",
1074
- _b["arc-Col--L".concat(spanL)] = typeof spanL !== "undefined",
1075
- _b["arc-Col--XL".concat(spanXL)] = typeof spanXL !== "undefined",
1076
- _b["arc-Col--offset"] = typeof offset !== "undefined" ||
1071
+ _b["arc-Columns-col"] = true,
1072
+ _b[suffixModifier("arc-Columns-col--align", align || "")] = align,
1073
+ _b["arc-Columns-col--".concat(span)] = typeof span !== "undefined",
1074
+ _b["arc-Columns-col--s".concat(spanS)] = typeof spanS !== "undefined",
1075
+ _b["arc-Columns-col--m".concat(spanM)] = typeof spanM !== "undefined",
1076
+ _b["arc-Columns-col--l".concat(spanL)] = typeof spanL !== "undefined",
1077
+ _b["arc-Columns-col--xL".concat(spanXL)] = typeof spanXL !== "undefined",
1078
+ _b["arc-Columns-col--offset"] = typeof offset !== "undefined" ||
1077
1079
  typeof offsetS !== "undefined" ||
1078
1080
  typeof offsetM !== "undefined" ||
1079
1081
  typeof offsetL !== "undefined" ||
1080
1082
  typeof offsetXL !== "undefined",
1081
- _b["arc-Col--offset".concat(offset)] = typeof offset !== "undefined",
1082
- _b["arc-Col--offsetS".concat(offsetS)] = typeof offsetS !== "undefined",
1083
- _b["arc-Col--offsetM".concat(offsetM)] = typeof offsetM !== "undefined",
1084
- _b["arc-Col--offsetL".concat(offsetL)] = typeof offsetL !== "undefined",
1085
- _b["arc-Col--offsetXL".concat(offsetXL)] = typeof offsetXL !== "undefined",
1086
- _b["arc-Col--debugVisible"] = isDebugVisible,
1083
+ _b["arc-Columns-col--offset".concat(offset)] = typeof offset !== "undefined",
1084
+ _b["arc-Columns-col--offsetS".concat(offsetS)] = typeof offsetS !== "undefined",
1085
+ _b["arc-Columns-col--offsetM".concat(offsetM)] = typeof offsetM !== "undefined",
1086
+ _b["arc-Columns-col--offsetL".concat(offsetL)] = typeof offsetL !== "undefined",
1087
+ _b["arc-Columns-col--offsetXL".concat(offsetXL)] = typeof offsetXL !== "undefined",
1088
+ _b["arc-Columns-col--debugVisible"] = isDebugVisible,
1087
1089
  _b)) }, filterDataAttrs(props)), children));
1088
1090
  };
1089
1091
  Col.displayName = "Columns.Col";
@@ -1164,9 +1166,9 @@ var GroupItem = function (_a) {
1164
1166
  var _b;
1165
1167
  var children = _a.children, _c = _a.grow, grow = _c === void 0 ? false : _c, _d = _a.isDebugVisible, isDebugVisible = _d === void 0 ? false : _d, props = __rest(_a, ["children", "grow", "isDebugVisible"]);
1166
1168
  return (React.createElement("div", __assign({ className: classNames((_b = {},
1167
- _b["arc-GroupItem"] = true,
1168
- _b["arc-GroupItem--grow"] = grow,
1169
- _b["arc-GroupItem--debugVisible"] = isDebugVisible,
1169
+ _b["arc-Group-item"] = true,
1170
+ _b["arc-Group-item--grow"] = grow,
1171
+ _b["arc-Group-item--debugVisible"] = isDebugVisible,
1170
1172
  _b)) }, filterDataAttrs(props)), children));
1171
1173
  };
1172
1174
  GroupItem.displayName = "Group.Item";
@@ -1249,9 +1251,6 @@ var RadioContext = createContext({});
1249
1251
  var Provider$2 = RadioContext.Provider;
1250
1252
  var useRadioContext = function () {
1251
1253
  var context = useContext(RadioContext);
1252
- if (!context) {
1253
- console.warn("Ensure to use <RadioGroup.RadioButton /> within the <RadioGroup /> or its branded version.");
1254
- }
1255
1254
  return context;
1256
1255
  };
1257
1256
 
@@ -1260,10 +1259,10 @@ var useRadioContext = function () {
1260
1259
  */
1261
1260
  var RadioButton = forwardRef(function (_a, ref) {
1262
1261
  var helper = _a.helper, id = _a.id, isDisabled = _a.isDisabled, label = _a.label, value = _a.value, props = __rest(_a, ["helper", "id", "isDisabled", "label", "value"]);
1263
- var _b = useRadioContext(), blurEvent = _b.blurEvent, changeEvent = _b.changeEvent, groupDisabled = _b.groupDisabled, isChecked = _b.isChecked, labelSize = _b.labelSize, name = _b.name, size = _b.size;
1262
+ var _b = useRadioContext(), blurEvent = _b.blurEvent, changeEvent = _b.changeEvent, groupDisabled = _b.groupDisabled, checkedValue = _b.checkedValue, labelSize = _b.labelSize, name = _b.name, size = _b.size;
1264
1263
  var surface = useContext(Context$3).surface;
1265
1264
  var idLabel = "".concat(id, "-label");
1266
- var checked = isChecked === value ? true : false;
1265
+ var checked = checkedValue === value ? true : false;
1267
1266
  return (React.createElement("div", __assign({ className: classNames({
1268
1267
  "arc-RadioButton": true,
1269
1268
  "arc-RadioButton--disabled": isDisabled || groupDisabled,
@@ -1282,12 +1281,19 @@ var RadioButton = forwardRef(function (_a, ref) {
1282
1281
  * Use `RadioGroup` to wrap and control radio buttons and apply default values
1283
1282
  */
1284
1283
  var RadioGroup = function (_a) {
1285
- var children = _a.children, defaultValue = _a.defaultValue, _b = _a.isDisabled, isDisabled = _b === void 0 ? false : _b, id = _a.id, helper = _a.helper, label = _a.label, _c = _a.labelSize, labelSize = _c === void 0 ? "l" : _c, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, _d = _a.size, size = _d === void 0 ? "l" : _d, props = __rest(_a, ["children", "defaultValue", "isDisabled", "id", "helper", "label", "labelSize", "name", "onBlur", "onChange", "size"]);
1284
+ var children = _a.children, checkedValue = _a.checkedValue, _b = _a.isDisabled, isDisabled = _b === void 0 ? false : _b, id = _a.id, helper = _a.helper, label = _a.label, _c = _a.labelSize, labelSize = _c === void 0 ? "l" : _c, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, _d = _a.size, size = _d === void 0 ? "l" : _d, props = __rest(_a, ["children", "checkedValue", "isDisabled", "id", "helper", "label", "labelSize", "name", "onBlur", "onChange", "size"]);
1285
+ useEffect(function () {
1286
+ React.Children.map(children, function (item) {
1287
+ if (item && item.type !== RadioButton) {
1288
+ throw new Error("Illegal child passed to <RadioGroup />. Ensure to only use <RadioGroup.RadioButton />.");
1289
+ }
1290
+ });
1291
+ }, [children]);
1286
1292
  return (React.createElement(Provider$2, { value: {
1287
1293
  blurEvent: onBlur,
1288
1294
  changeEvent: onChange,
1289
1295
  groupDisabled: isDisabled,
1290
- isChecked: defaultValue,
1296
+ checkedValue: checkedValue,
1291
1297
  labelSize: labelSize,
1292
1298
  name: name,
1293
1299
  size: size
@@ -1506,7 +1512,9 @@ var Panel = function (_a) {
1506
1512
  // and the click is not on a SubNavItem-link.
1507
1513
  // This ensures that one SubNavItem Panel per NavItem always remains open.
1508
1514
  (subNavItemRef &&
1509
- !e.target.classList.contains(subNavLink)) ||
1515
+ !e.target.classList.contains(subNavLink) &&
1516
+ !e.target.classList.contains("".concat(subNavLink, "Title")) &&
1517
+ !e.target.classList.contains("".concat(subNavLink, "SubTitle"))) ||
1510
1518
  // Panel is inside a SubNavItem
1511
1519
  // and the click is not inside the Panel's NavItem parent.
1512
1520
  // This prevents SubNavItem Panels in sibling NavItems from being closed.
@@ -1634,12 +1642,31 @@ var NavItemRehydrator = (function (el, hydrate) { return __awaiter(void 0, void
1634
1642
  });
1635
1643
  }); });
1636
1644
 
1645
+ /**
1646
+ * Use `Text` to display text.
1647
+ */
1648
+ var Text = function (_a) {
1649
+ var _b;
1650
+ var _c = _a.align, align = _c === void 0 ? "left" : _c, children = _a.children, _d = _a.isInline, isInline = _d === void 0 ? false : _d, _e = _a.isMeasured, isMeasured = _e === void 0 ? false : _e, _f = _a.size, size = _f === void 0 ? "m" : _f, _g = _a.tone, tone = _g === void 0 ? "default" : _g, props = __rest(_a, ["align", "children", "isInline", "isMeasured", "size", "tone"]);
1651
+ var surface = useContext(Context$3).surface;
1652
+ return (React.createElement("span", __assign({ className: classNames((_b = {
1653
+ "arc-Text": true
1654
+ },
1655
+ _b[suffixModifier("arc-Text--align", align)] = align !== "left",
1656
+ _b["arc-Text--inline"] = isInline,
1657
+ _b["arc-Text--measured"] = isMeasured,
1658
+ _b["arc-Text--size".concat(size && size.toUpperCase())] = size && size !== "m",
1659
+ _b["arc-Text--".concat(tone)] = tone !== "default",
1660
+ _b["arc-Text--onDarkSurface"] = surface === "dark",
1661
+ _b)) }, filterDataAttrs(props)), children));
1662
+ };
1663
+
1637
1664
  var SubNavItem = function (_a) {
1638
1665
  var _b, _c;
1639
- var children = _a.children, _d = _a.isDefaultItem, isDefaultItem = _d === void 0 ? false : _d, href = _a.href, promo = _a.promo, title = _a.title, props = __rest(_a, ["children", "isDefaultItem", "href", "promo", "title"]);
1640
- var _e = useContext(Context$1), navItem = _e.navItem, subTitle = _e.subTitle;
1666
+ var children = _a.children, _d = _a.isDefaultItem, isDefaultItem = _d === void 0 ? false : _d, href = _a.href, offsetXL = _a.offsetXL, promo = _a.promo, subTitle = _a.subTitle, title = _a.title, viewAllTitle = _a.viewAllTitle, props = __rest(_a, ["children", "isDefaultItem", "href", "offsetXL", "promo", "subTitle", "title", "viewAllTitle"]);
1667
+ var navItem = useContext(Context$1).navItem;
1641
1668
  var subNavItem = useRef();
1642
- var _f = useState(false), panelOpen = _f[0], setPanelOpen = _f[1];
1669
+ var _e = useState(false), panelOpen = _e[0], setPanelOpen = _e[1];
1643
1670
  var isMinWidthArcBreakpointL = useMediaQuery("(min-width: ".concat(ArcBreakpointL, "px)"));
1644
1671
  useEffect(function () {
1645
1672
  React.Children.map(children, function (item) {
@@ -1659,52 +1686,75 @@ var SubNavItem = function (_a) {
1659
1686
  setPanelOpen(false);
1660
1687
  }
1661
1688
  }, [isDefaultItem, isMinWidthArcBreakpointL]);
1689
+ var linkTitle = (React.createElement(React.Fragment, null,
1690
+ React.createElement("span", { className: "arc-SiteHeaderSubNavItem-linkTitle" }, title),
1691
+ subTitle ? (React.createElement("span", { className: "arc-SiteHeaderSubNavItem-linkSubTitle" }, subTitle)) : null));
1662
1692
  return (React.createElement("li", __assign({ className: classNames((_b = {},
1663
1693
  _b["arc-SiteHeaderSubNavItem"] = true,
1664
1694
  _b["arc-SiteHeaderSubNavItem--linkSelected"] = children && panelOpen,
1665
- _b)), ref: subNavItem }, filterDataAttrs(props), { "data-default-item": isDefaultItem || null }), !children ? (href ? (React.createElement("a", { className: "arc-SiteHeaderSubNavItem-link", href: href }, title)) : null) : (React.createElement(React.Fragment, null,
1695
+ _b[suffixModifier("arc-SiteHeaderSubNavItem--offsetXL", offsetXL || "")] = offsetXL,
1696
+ _b)), ref: subNavItem }, filterDataAttrs(props), { "data-default-item": isDefaultItem || null }), !children ? (href ? (React.createElement("a", { className: "arc-SiteHeaderSubNavItem-link", href: href }, linkTitle)) : null) : (React.createElement(React.Fragment, null,
1666
1697
  React.createElement("button", { "aria-expanded": panelOpen, className: classNames((_c = {},
1667
1698
  _c["arc-SiteHeaderSubNavItem-link"] = true,
1668
1699
  _c["arc-SiteHeaderSubNavItem-link--itemHasChildren"] = children,
1669
1700
  _c)), onClick: function () {
1670
1701
  setPanelOpen(true);
1671
- } }, title),
1672
- React.createElement(Panel, { navItemRef: navItem, open: panelOpen, setOpen: setPanelOpen, subNavItemRef: subNavItem, subNavLink: "arc-SiteHeaderSubNavItem-link", promo: promo, title: React.createElement(React.Fragment, null,
1673
- subTitle && "".concat(subTitle, " "),
1674
- React.createElement("b", null, title)) }, children)))));
1702
+ } }, linkTitle),
1703
+ React.createElement(Panel, { navItemRef: navItem, open: panelOpen, setOpen: setPanelOpen, subNavItemRef: subNavItem, subNavLink: "arc-SiteHeaderSubNavItem-link", promo: promo, title: React.createElement("span", null,
1704
+ title,
1705
+ subTitle && (React.createElement(Text, { size: "xs", tone: "supporting" }, subTitle))), viewAll: href ? (React.createElement(Panel.ViewAll, { href: href, title: viewAllTitle || "View all ".concat(title.toLowerCase()) })) : (undefined) }, children)))));
1675
1706
  };
1676
1707
 
1677
1708
  var SubNavItemRehydrator = (function (el, hydrate) { return __awaiter(void 0, void 0, void 0, function () {
1678
- var children, promo, link, href, title, props;
1679
- return __generator(this, function (_a) {
1680
- switch (_a.label) {
1709
+ var children, promo, link, linkTitle, viewAll, href, title, offsetXL, props;
1710
+ var _a;
1711
+ return __generator(this, function (_b) {
1712
+ switch (_b.label) {
1681
1713
  case 0:
1682
1714
  children = el.querySelector(".arc-SiteHeaderPanel-items");
1683
1715
  promo = el.querySelector(".arc-SiteHeaderPanel-promo");
1684
1716
  if (!children) return [3 /*break*/, 2];
1685
1717
  return [4 /*yield*/, hydrate(children)];
1686
1718
  case 1:
1687
- children = _a.sent();
1688
- _a.label = 2;
1719
+ children = _b.sent();
1720
+ _b.label = 2;
1689
1721
  case 2:
1690
1722
  if (!promo) return [3 /*break*/, 4];
1691
1723
  return [4 /*yield*/, hydrate(promo)];
1692
1724
  case 3:
1693
- promo = _a.sent();
1694
- _a.label = 4;
1725
+ promo = _b.sent();
1726
+ _b.label = 4;
1695
1727
  case 4:
1696
1728
  link = el.querySelector(".arc-SiteHeaderSubNavItem-link");
1729
+ linkTitle = el.querySelector(".arc-SiteHeaderSubNavItem-linkTitle");
1730
+ viewAll = el.querySelector(".arc-SiteHeaderPanel-viewAll");
1697
1731
  href = "";
1698
1732
  title = "";
1699
1733
  if (link) {
1700
1734
  href = link.getAttribute("href") || /* istanbul ignore next */ "";
1701
- title = link.textContent || /* istanbul ignore next */ "";
1735
+ }
1736
+ if (linkTitle) {
1737
+ title = linkTitle.textContent || /* istanbul ignore next */ "";
1738
+ }
1739
+ if (viewAll) {
1740
+ href = viewAll.getAttribute("href") || /* istanbul ignore next */ "";
1741
+ }
1742
+ offsetXL = undefined;
1743
+ if (el.classList.contains("arc-SiteHeaderSubNavItem--offsetXL24")) {
1744
+ offsetXL = "24";
1745
+ }
1746
+ if (el.classList.contains("arc-SiteHeaderSubNavItem--offsetXL48")) {
1747
+ offsetXL = "48";
1702
1748
  }
1703
1749
  props = {
1704
1750
  href: href,
1705
1751
  isDefaultItem: Boolean(el.dataset.defaultItem),
1752
+ offsetXL: offsetXL,
1706
1753
  promo: promo || undefined,
1707
- title: title
1754
+ subTitle: ((_a = el.querySelector(".arc-SiteHeaderSubNavItem-linkSubTitle")) === null || _a === void 0 ? void 0 : _a.textContent) ||
1755
+ undefined,
1756
+ title: title,
1757
+ viewAllTitle: (viewAll === null || viewAll === void 0 ? void 0 : viewAll.textContent) || undefined
1708
1758
  };
1709
1759
  return [2 /*return*/, React.createElement(SubNavItem, __assign({}, props), children)];
1710
1760
  }
@@ -1771,7 +1821,7 @@ function wrap(el, wrapper) {
1771
1821
  wrapper.appendChild(el);
1772
1822
  }
1773
1823
  var NavItemWithSubNavRehydrator = (function (el, hydrate) { return __awaiter(void 0, void 0, void 0, function () {
1774
- var subNavItem1, subNavItem2, subNavItem3, div1, div2, slot1, slot2, slot3, div3, link, subTitle, viewAll, title, props;
1824
+ var subNavItem1, subNavItem2, subNavItem3, div1, div2, slot1, slot2, slot3, div3, link, subTitle, viewAllNodes, viewAll, title, props;
1775
1825
  return __generator(this, function (_a) {
1776
1826
  switch (_a.label) {
1777
1827
  case 0:
@@ -1801,7 +1851,8 @@ var NavItemWithSubNavRehydrator = (function (el, hydrate) { return __awaiter(voi
1801
1851
  case 4:
1802
1852
  link = el.querySelector(".arc-SiteHeaderNavItem-link");
1803
1853
  subTitle = el.querySelector(".arc-SiteHeaderPanel-title");
1804
- viewAll = el.querySelector(".arc-SiteHeaderPanel-viewAll");
1854
+ viewAllNodes = el.querySelectorAll(".arc-SiteHeaderPanel-viewAll");
1855
+ viewAll = viewAllNodes[viewAllNodes.length - 1];
1805
1856
  title = "";
1806
1857
  if (link) {
1807
1858
  title = link.textContent || /* istanbul ignore next */ "";
@@ -1968,25 +2019,6 @@ SiteHeaderRehydrator.NavItemRehydrator = NavItemRehydrator;
1968
2019
  SiteHeaderRehydrator.NavItemWithSubNavRehydrator = NavItemWithSubNavRehydrator;
1969
2020
  SiteHeaderRehydrator.SubNavItemRehydrator = SubNavItemRehydrator;
1970
2021
 
1971
- /**
1972
- * Use `Text` to display text.
1973
- */
1974
- var Text = function (_a) {
1975
- var _b;
1976
- var _c = _a.align, align = _c === void 0 ? "left" : _c, children = _a.children, _d = _a.isInline, isInline = _d === void 0 ? false : _d, _e = _a.isMeasured, isMeasured = _e === void 0 ? false : _e, _f = _a.size, size = _f === void 0 ? "m" : _f, _g = _a.tone, tone = _g === void 0 ? "default" : _g, props = __rest(_a, ["align", "children", "isInline", "isMeasured", "size", "tone"]);
1977
- var surface = useContext(Context$3).surface;
1978
- return (React.createElement("span", __assign({ className: classNames((_b = {
1979
- "arc-Text": true
1980
- },
1981
- _b[suffixModifier("arc-Text--align", align)] = align !== "left",
1982
- _b["arc-Text--inline"] = isInline,
1983
- _b["arc-Text--measured"] = isMeasured,
1984
- _b["arc-Text--size".concat(size && size.toUpperCase())] = size && size !== "m",
1985
- _b["arc-Text--".concat(tone)] = tone !== "default",
1986
- _b["arc-Text--onDarkSurface"] = surface === "dark",
1987
- _b)) }, filterDataAttrs(props)), children));
1988
- };
1989
-
1990
2022
  /**
1991
2023
  * Use `TextInput` to allow custom user text entry with a keyboard.
1992
2024
  */