@arc-ui/components 13.3.0 → 13.4.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/lib/Alert/styles.css +1 -1
- package/lib/Align/styles.css +1 -1
- package/lib/AppButton/styles.css +1 -1
- package/lib/Avatar/styles.css +1 -1
- package/lib/AvatarGroup/styles.css +1 -1
- package/lib/Badge/styles.css +1 -1
- package/lib/Banner/Banner.cjs +3 -3
- package/lib/Banner/Banner.mjs +3 -3
- package/lib/Box/styles.css +1 -1
- package/lib/BrandLogo/styles.css +1 -1
- package/lib/Breadcrumbs/styles.css +1 -1
- package/lib/Button/styles.css +1 -1
- package/lib/ButtonGroup/styles.css +1 -1
- package/lib/ButtonV2/styles.css +1 -1
- package/lib/Calendar/Calendar.cjs +2 -2
- package/lib/Calendar/Calendar.mjs +2 -2
- package/lib/Calendar/styles.css +1 -1
- package/lib/CardFooter/styles.css +1 -1
- package/lib/CardHeading/styles.css +1 -1
- package/lib/Carousel/Carousel.cjs +1 -1
- package/lib/Carousel/Carousel.mjs +1 -1
- package/lib/Carousel/styles.css +1 -1
- package/lib/Checkbox/Checkbox.cjs +2 -2
- package/lib/Checkbox/Checkbox.mjs +2 -2
- package/lib/Checkbox/styles.css +1 -1
- package/lib/CheckboxIcon/CheckboxIcon.cjs +2 -2
- package/lib/CheckboxIcon/CheckboxIcon.mjs +2 -2
- package/lib/CheckboxIcon/styles.css +1 -1
- package/lib/Columns/styles.css +1 -1
- package/lib/ComboBox/ComboBox.cjs +1 -1
- package/lib/ComboBox/ComboBox.mjs +1 -1
- package/lib/ComboBox/styles.css +1 -1
- package/lib/ContentSwitcher/styles.css +1 -1
- package/lib/ContentSwitcherDropdown/styles.css +1 -1
- package/lib/DatePicker/DatePicker.cjs +4 -4
- package/lib/DatePicker/DatePicker.mjs +4 -4
- package/lib/DatePicker/styles.css +1 -1
- package/lib/Disclosure/styles.css +1 -1
- package/lib/DisclosureMini/styles.css +1 -1
- package/lib/Download/styles.css +1 -1
- package/lib/Drawer/styles.css +1 -1
- package/lib/Elevation/styles.css +1 -1
- package/lib/Filter/styles.css +1 -1
- package/lib/FormControl/FormControl.cjs +1 -1
- package/lib/FormControl/FormControl.mjs +1 -1
- package/lib/FormControl/styles.css +1 -1
- package/lib/GhostedHeroBanner/styles.css +1 -1
- package/lib/GradientPageBackground/GradientPageBackground.cjs +2 -2
- package/lib/GradientPageBackground/GradientPageBackground.mjs +2 -2
- package/lib/GradientPageBackground/styles.css +1 -1
- package/lib/Grid/styles.css +1 -1
- package/lib/Group/styles.css +1 -1
- package/lib/Heading/styles.css +1 -1
- package/lib/HeroBanner/HeroBanner.cjs +3 -3
- package/lib/HeroBanner/HeroBanner.mjs +3 -3
- package/lib/HeroBanner/styles.css +1 -1
- package/lib/HeroButton/styles.css +1 -1
- package/lib/Hidden/styles.css +1 -1
- package/lib/HorizontalCard/styles.css +1 -1
- package/lib/Icon/styles.css +1 -1
- package/lib/Image/styles.css +1 -1
- package/lib/ImpactCard/ImpactCard.cjs +4 -1
- package/lib/ImpactCard/ImpactCard.mjs +4 -1
- package/lib/ImpactCard/styles.css +1 -1
- package/lib/InformationCard/InformationCard.cjs +6 -5
- package/lib/InformationCard/InformationCard.mjs +6 -5
- package/lib/InformationCard/styles.css +1 -1
- package/lib/Link/styles.css +1 -1
- package/lib/Markup/styles.css +1 -1
- package/lib/MediaCard/MediaCard.cjs +4 -1
- package/lib/MediaCard/MediaCard.mjs +4 -1
- package/lib/MediaCard/styles.css +1 -1
- package/lib/Menu/Menu.cjs +17 -2
- package/lib/Menu/Menu.mjs +17 -3
- package/lib/Menu/styles.css +1 -1
- package/lib/Modal/styles.css +1 -1
- package/lib/NavigationHeader/NavigationHeader.cjs +39 -79
- package/lib/NavigationHeader/NavigationHeader.mjs +40 -80
- package/lib/NavigationHeader/styles.css +1 -1
- package/lib/Pagination/styles.css +1 -1
- package/lib/PaginationSimple/styles.css +1 -1
- package/lib/Popover/styles.css +1 -1
- package/lib/Poster/styles.css +1 -1
- package/lib/ProgressBar/styles.css +1 -1
- package/lib/ProgressStepper/styles.css +1 -1
- package/lib/ProgressStepperOverflow/styles.css +1 -1
- package/lib/RadioCardGroup/RadioCardGroup.cjs +1 -1
- package/lib/RadioCardGroup/RadioCardGroup.mjs +1 -1
- package/lib/RadioCardGroup/styles.css +1 -1
- package/lib/RadioGroup/RadioGroup.cjs +1 -1
- package/lib/RadioGroup/RadioGroup.mjs +1 -1
- package/lib/RadioGroup/styles.css +1 -1
- package/lib/Rule/styles.css +1 -1
- package/lib/ScrollToTop/styles.css +1 -1
- package/lib/Section/styles.css +1 -1
- package/lib/Select/Select.cjs +1 -1
- package/lib/Select/Select.mjs +1 -1
- package/lib/Select/styles.css +1 -1
- package/lib/SemanticButton/styles.css +1 -1
- package/lib/SemanticHeading/styles.css +1 -1
- package/lib/SemanticLink/styles.css +1 -1
- package/lib/SiteFooter/styles.css +1 -1
- package/lib/SiteFooterV2/styles.css +1 -1
- package/lib/SiteHeaderV2/SiteHeaderV2.cjs +1 -1
- package/lib/SiteHeaderV2/SiteHeaderV2.mjs +1 -1
- package/lib/SiteHeaderV2/styles.css +1 -1
- package/lib/Skeleton/Skeleton.cjs +7 -17
- package/lib/Skeleton/Skeleton.mjs +5 -19
- package/lib/Skeleton/styles.css +1 -1
- package/lib/SkipLink/styles.css +1 -1
- package/lib/Spacing/styles.css +1 -1
- package/lib/Spinner/styles.css +1 -1
- package/lib/Surface/styles.css +1 -1
- package/lib/Switch/Switch.cjs +1 -1
- package/lib/Switch/Switch.mjs +1 -1
- package/lib/Switch/styles.css +1 -1
- package/lib/TabbedBanner/TabbedBanner.cjs +3 -3
- package/lib/TabbedBanner/TabbedBanner.mjs +3 -3
- package/lib/TabbedBanner/styles.css +1 -1
- package/lib/Tabs/styles.css +1 -1
- package/lib/Tag/Tag.cjs +3 -3
- package/lib/Tag/Tag.mjs +3 -3
- package/lib/Tag/styles.css +1 -1
- package/lib/TemplateBanner/TemplateBanner.cjs +3 -3
- package/lib/TemplateBanner/TemplateBanner.mjs +3 -3
- package/lib/TemplateBanner/styles.css +1 -1
- package/lib/Text/styles.css +1 -1
- package/lib/TextArea/TextArea.cjs +2 -2
- package/lib/TextArea/TextArea.mjs +2 -2
- package/lib/TextArea/styles.css +1 -1
- package/lib/TextInput/TextInput.cjs +2 -2
- package/lib/TextInput/TextInput.mjs +2 -2
- package/lib/TextInput/styles.css +1 -1
- package/lib/Theme/Theme.cjs +1 -1
- package/lib/Theme/Theme.mjs +1 -1
- package/lib/Theme/styles.css +1 -1
- package/lib/ThemeIcon/styles.css +1 -1
- package/lib/ThumbnailSignpost/styles.css +1 -1
- package/lib/Toast/styles.css +1 -1
- package/lib/Tooltip/styles.css +1 -1
- package/lib/Truncate/styles.css +1 -1
- package/lib/TypographyCard/TypographyCard.cjs +4 -1
- package/lib/TypographyCard/TypographyCard.mjs +4 -1
- package/lib/TypographyCard/styles.css +1 -1
- package/lib/UniversalHeader/styles.css +1 -1
- package/lib/VerticalSpace/styles.css +1 -1
- package/lib/VideoPlayer/styles.css +1 -1
- package/lib/Visible/styles.css +1 -1
- package/lib/VisuallyHidden/styles.css +1 -1
- package/lib/_shared/cjs/{Calendar-DzrCblS7.cjs → Calendar-D7DzTyqu.cjs} +1 -1
- package/lib/_shared/cjs/{CheckboxIcon-BzY1S_ud.cjs → CheckboxIcon-LesSiNub.cjs} +1 -1
- package/lib/_shared/cjs/{FormControl-TtboqHRx.cjs → FormControl-BtFbIuB3.cjs} +8 -12
- package/lib/_shared/cjs/Skeleton-C1R-zgcO.cjs +21 -0
- package/lib/_shared/cjs/{TemplateBanner-BYuDjH9w.cjs → TemplateBanner-d8uKhQxu.cjs} +1 -1
- package/lib/_shared/cjs/{TextInput-CLkhL2KT.cjs → TextInput-BTdXg_G5.cjs} +1 -1
- package/lib/_shared/cjs/{arc-breakpoints-BuvObBnW.cjs → arc-breakpoints-DX5WrUyh.cjs} +1 -1
- package/lib/_shared/cjs/{index.es-C4DHJlS_.cjs → index.es-pYEm4MOk.cjs} +1 -1
- package/lib/_shared/esm/{Calendar-D1dKY2q1.mjs → Calendar-CGHTC6D9.mjs} +1 -1
- package/lib/_shared/esm/{CheckboxIcon-CzRn1j8X.mjs → CheckboxIcon-DLXZVpoo.mjs} +1 -1
- package/lib/_shared/esm/{FormControl-DopDD_nC.mjs → FormControl-BCZe7nrI.mjs} +8 -12
- package/lib/_shared/esm/Skeleton-BuuY1t5b.mjs +19 -0
- package/lib/_shared/esm/{TemplateBanner-D9LAh6EQ.mjs → TemplateBanner-CShZMwaX.mjs} +1 -1
- package/lib/_shared/esm/{TextInput-WczTCUvp.mjs → TextInput-BWzMPQSC.mjs} +1 -1
- package/lib/_shared/esm/{arc-breakpoints-DEwTuwn3.mjs → arc-breakpoints-Beeczz-E.mjs} +1 -1
- package/lib/_shared/esm/{index.es-mlUVFLmd.mjs → index.es-BAiyN-06.mjs} +1 -1
- package/lib/index.cjs +116 -136
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +33 -12
- package/lib/index.d.mts +33 -12
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +116 -137
- package/lib/index.mjs.map +1 -1
- package/lib/styles.css +3 -3
- package/package.json +7 -7
package/lib/index.cjs
CHANGED
|
@@ -1423,7 +1423,7 @@ var debounce = /*@__PURE__*/getDefaultExportFromCjs(debounceExports);
|
|
|
1423
1423
|
|
|
1424
1424
|
/**
|
|
1425
1425
|
* Do not edit directly
|
|
1426
|
-
* Generated on Wed,
|
|
1426
|
+
* Generated on Wed, 25 Feb 2026 15:47:05 GMT
|
|
1427
1427
|
*/
|
|
1428
1428
|
var ArcSizeBreakpointsXs = "320px";
|
|
1429
1429
|
var ArcSizeBreakpointsS = "636px";
|
|
@@ -3028,7 +3028,7 @@ function subYears(dirtyDate, dirtyAmount) {
|
|
|
3028
3028
|
return addYears(dirtyDate, -amount);
|
|
3029
3029
|
}
|
|
3030
3030
|
|
|
3031
|
-
var KeyNames$
|
|
3031
|
+
var KeyNames$2;
|
|
3032
3032
|
(function (KeyNames) {
|
|
3033
3033
|
KeyNames["ArrowUp"] = "ArrowUp";
|
|
3034
3034
|
KeyNames["ArrowDown"] = "ArrowDown";
|
|
@@ -3041,26 +3041,26 @@ var KeyNames$3;
|
|
|
3041
3041
|
KeyNames["Tab"] = "Tab";
|
|
3042
3042
|
KeyNames["Enter"] = "Enter";
|
|
3043
3043
|
KeyNames["Space"] = " ";
|
|
3044
|
-
})(KeyNames$
|
|
3044
|
+
})(KeyNames$2 || (KeyNames$2 = {}));
|
|
3045
3045
|
|
|
3046
3046
|
var getKeyDownDate = function (_a) {
|
|
3047
3047
|
var key = _a.key, shiftKey = _a.shiftKey, focusDate = _a.focusDate;
|
|
3048
3048
|
switch (key) {
|
|
3049
|
-
case KeyNames$
|
|
3049
|
+
case KeyNames$2.ArrowDown:
|
|
3050
3050
|
return addWeeks(focusDate, 1);
|
|
3051
|
-
case KeyNames$
|
|
3051
|
+
case KeyNames$2.ArrowLeft:
|
|
3052
3052
|
return subDays(focusDate, 1);
|
|
3053
|
-
case KeyNames$
|
|
3053
|
+
case KeyNames$2.ArrowRight:
|
|
3054
3054
|
return addDays(focusDate, 1);
|
|
3055
|
-
case KeyNames$
|
|
3055
|
+
case KeyNames$2.ArrowUp:
|
|
3056
3056
|
return subWeeks(focusDate, 1);
|
|
3057
|
-
case KeyNames$
|
|
3057
|
+
case KeyNames$2.Home:
|
|
3058
3058
|
return dateWithoutTime(startOfWeek(focusDate, { weekStartsOn: 1 }));
|
|
3059
|
-
case KeyNames$
|
|
3059
|
+
case KeyNames$2.End:
|
|
3060
3060
|
return dateWithoutTime(endOfWeek(focusDate, { weekStartsOn: 1 }));
|
|
3061
|
-
case KeyNames$
|
|
3061
|
+
case KeyNames$2.PageUp:
|
|
3062
3062
|
return shiftKey ? subYears(focusDate, 1) : subMonths(focusDate, 1);
|
|
3063
|
-
case KeyNames$
|
|
3063
|
+
case KeyNames$2.PageDown:
|
|
3064
3064
|
return shiftKey ? addYears(focusDate, 1) : addMonths(focusDate, 1);
|
|
3065
3065
|
default:
|
|
3066
3066
|
return focusDate;
|
|
@@ -5558,13 +5558,13 @@ var CalendarDayGrid = function (_a) {
|
|
|
5558
5558
|
var handleKeyDown = function (e) {
|
|
5559
5559
|
var key = e.key;
|
|
5560
5560
|
var newDate = e.target.getAttribute("data-date");
|
|
5561
|
-
if (key === KeyNames$
|
|
5561
|
+
if (key === KeyNames$2.Tab) {
|
|
5562
5562
|
return;
|
|
5563
5563
|
}
|
|
5564
|
-
if (Object.values(KeyNames$
|
|
5564
|
+
if (Object.values(KeyNames$2).includes(key)) {
|
|
5565
5565
|
e.preventDefault();
|
|
5566
5566
|
}
|
|
5567
|
-
if ([KeyNames$
|
|
5567
|
+
if ([KeyNames$2.Space, KeyNames$2.Enter].includes(key) && newDate) {
|
|
5568
5568
|
onDayNumberClick(dateWithoutTime(new Date(parseInt(newDate))))();
|
|
5569
5569
|
}
|
|
5570
5570
|
else {
|
|
@@ -5870,7 +5870,7 @@ function setYear(dirtyDate, dirtyYear) {
|
|
|
5870
5870
|
var calendarKeydownHandler = function (payload, state) {
|
|
5871
5871
|
var displayDate = state.displayDate, focusDate = state.focusDate, highlightedRange = state.highlightedRange;
|
|
5872
5872
|
var minDate = payload.minDate, maxDate = payload.maxDate, calendarType = payload.calendarType, key = payload.key, shiftKey = payload.shiftKey, range = payload.range, selectionType = payload.selectionType;
|
|
5873
|
-
var isNavigatingByYear = shiftKey && [KeyNames$
|
|
5873
|
+
var isNavigatingByYear = shiftKey && [KeyNames$2.PageUp, KeyNames$2.PageDown].includes(key);
|
|
5874
5874
|
var keyDownDate = getKeyDownDate({
|
|
5875
5875
|
focusDate: focusDate,
|
|
5876
5876
|
key: key,
|
|
@@ -8259,12 +8259,12 @@ var CarouselDotButton = function (_a) {
|
|
|
8259
8259
|
}), onKeyDown: onKeyDown(scrollSnapIndex), onClick: function () { return onClick(scrollSnapIndex); }, "aria-selected": isSelected, role: "tab", "aria-label": "Show slide ".concat(scrollSnapIndex + 1) }));
|
|
8260
8260
|
};
|
|
8261
8261
|
|
|
8262
|
-
var KeyNames$
|
|
8262
|
+
var KeyNames$1;
|
|
8263
8263
|
(function (KeyNames) {
|
|
8264
8264
|
KeyNames["ArrowLeft"] = "ArrowLeft";
|
|
8265
8265
|
KeyNames["ArrowRight"] = "ArrowRight";
|
|
8266
8266
|
KeyNames["Escape"] = "Escape";
|
|
8267
|
-
})(KeyNames$
|
|
8267
|
+
})(KeyNames$1 || (KeyNames$1 = {}));
|
|
8268
8268
|
|
|
8269
8269
|
var Carousel = function (_a) {
|
|
8270
8270
|
var children = _a.children, responsive = _a.responsive, _b = _a.itemsToScroll, itemsToScroll = _b === void 0 ? 1 : _b, _c = _a.itemsPerSlide, itemsPerSlide = _c === void 0 ? 1 : _c, _d = _a.controlsPosition, controlsPosition = _d === void 0 ? "bottom" : _d, _e = _a.behavior, behavior = _e === void 0 ? "default" : _e, _f = _a.overflow, overflow = _f === void 0 ? "hidden" : _f, _g = _a.withGutter, withGutter = _g === void 0 ? true : _g, _h = _a.loop, loop = _h === void 0 ? false : _h, _j = _a.isPartialVisible, isPartialVisible = _j === void 0 ? false : _j, autoplay = _a.autoplay, isPlaying = _a.isPlaying, fade = _a.fade;
|
|
@@ -8330,17 +8330,17 @@ var Carousel = function (_a) {
|
|
|
8330
8330
|
}, [emblaApi]);
|
|
8331
8331
|
var onSlideKeyDown = function (e) {
|
|
8332
8332
|
var _a;
|
|
8333
|
-
if (e.key === KeyNames$
|
|
8333
|
+
if (e.key === KeyNames$1.Escape) {
|
|
8334
8334
|
prevButtonEnabled
|
|
8335
8335
|
? (_a = prevButtonRef.current) === null || _a === void 0 ? void 0 : _a.focus()
|
|
8336
8336
|
: setCarouselDotButtonFocusIndex(0);
|
|
8337
8337
|
}
|
|
8338
8338
|
};
|
|
8339
8339
|
var onCarouselDotButtonKeyDown = function (index) { return function (e) {
|
|
8340
|
-
if (e.key === KeyNames$
|
|
8340
|
+
if (e.key === KeyNames$1.ArrowLeft) {
|
|
8341
8341
|
setCarouselDotButtonFocusIndex(index === 0 ? scrollSnaps.length - 1 : index - 1);
|
|
8342
8342
|
}
|
|
8343
|
-
if (e.key === KeyNames$
|
|
8343
|
+
if (e.key === KeyNames$1.ArrowRight) {
|
|
8344
8344
|
setCarouselDotButtonFocusIndex(index + 1 === scrollSnaps.length ? 0 : index + 1);
|
|
8345
8345
|
}
|
|
8346
8346
|
}; };
|
|
@@ -8432,15 +8432,14 @@ var Provider$4 = Context$2.Provider;
|
|
|
8432
8432
|
* Use `FormControl` to provide inputs with labels, helper text and error messages
|
|
8433
8433
|
*/
|
|
8434
8434
|
var FormControl = function (_a) {
|
|
8435
|
-
var _b;
|
|
8436
|
-
var children = _a.children, _c = _a.elementType, ElementType = _c === void 0 ? "div" : _c, errorMessage = _a.errorMessage, helper = _a.helper, htmlFor = _a.htmlFor, supplementaryInfo = _a.supplementaryInfo, id = _a.id, label = _a.label, _d = _a.labelSize, labelSize = _d === void 0 ? "l" : _d, _e = _a.labelPosition, labelPosition = _e === void 0 ? "top" : _e, _f = _a.requirementStatus, requirementStatus = _f === void 0 ? "optional" : _f, _g = _a.helperUnderLabel, helperUnderLabel = _g === void 0 ? false : _g, isDisabled = _a.isDisabled, _h = _a.hideLabel, hideLabel = _h === void 0 ? false : _h, disclosureTitle = _a.disclosureTitle, disclosureText = _a.disclosureText, onClickDisclosure = _a.onClickDisclosure, _j = _a.isErrorAlert, isErrorAlert = _j === void 0 ? false : _j, props = __rest(_a, ["children", "elementType", "errorMessage", "helper", "htmlFor", "supplementaryInfo", "id", "label", "labelSize", "labelPosition", "requirementStatus", "helperUnderLabel", "isDisabled", "hideLabel", "disclosureTitle", "disclosureText", "onClickDisclosure", "isErrorAlert"]);
|
|
8435
|
+
var children = _a.children, _b = _a.elementType, ElementType = _b === void 0 ? "div" : _b, errorMessage = _a.errorMessage, helper = _a.helper, htmlFor = _a.htmlFor, supplementaryInfo = _a.supplementaryInfo, id = _a.id, label = _a.label, _c = _a.labelSize, labelSize = _c === void 0 ? "l" : _c, _d = _a.labelPosition, labelPosition = _d === void 0 ? "top" : _d, _e = _a.requirementStatus, requirementStatus = _e === void 0 ? "optional" : _e, _f = _a.helperUnderLabel, helperUnderLabel = _f === void 0 ? false : _f, isDisabled = _a.isDisabled, _g = _a.hideLabel, hideLabel = _g === void 0 ? false : _g, disclosureTitle = _a.disclosureTitle, disclosureText = _a.disclosureText, onClickDisclosure = _a.onClickDisclosure, _h = _a.isErrorAlert, isErrorAlert = _h === void 0 ? false : _h, props = __rest(_a, ["children", "elementType", "errorMessage", "helper", "htmlFor", "supplementaryInfo", "id", "label", "labelSize", "labelPosition", "requirementStatus", "helperUnderLabel", "isDisabled", "hideLabel", "disclosureTitle", "disclosureText", "onClickDisclosure", "isErrorAlert"]);
|
|
8437
8436
|
var surface = React.useContext(Context$3).surface;
|
|
8438
|
-
var
|
|
8437
|
+
var _j = useAriaDescribedby({
|
|
8439
8438
|
disclosureText: disclosureText,
|
|
8440
8439
|
errorMessage: errorMessage,
|
|
8441
8440
|
helper: helper,
|
|
8442
8441
|
id: htmlFor || id, // `htmlFor` is preference to keep this deterministic with TextInput
|
|
8443
|
-
}), ariaDescribedby =
|
|
8442
|
+
}), ariaDescribedby = _j.ariaDescribedby, idError = _j.idError, idHelper = _j.idHelper, idDisclosure = _j.idDisclosure;
|
|
8444
8443
|
var LabelType = ElementType === "div" ? "label" : "legend";
|
|
8445
8444
|
var elementProps = {};
|
|
8446
8445
|
var labelProps = {};
|
|
@@ -8460,14 +8459,11 @@ var FormControl = function (_a) {
|
|
|
8460
8459
|
? Boolean(errorMessage || disclosureTitle || supplementaryInfo)
|
|
8461
8460
|
: Boolean(errorMessage || disclosureTitle || helper || supplementaryInfo);
|
|
8462
8461
|
return (React.createElement(Provider$4, { value: { requirementStatus: requirementStatus } },
|
|
8463
|
-
React.createElement(ElementType, __assign({ className: classNames((
|
|
8464
|
-
|
|
8465
|
-
|
|
8466
|
-
|
|
8467
|
-
|
|
8468
|
-
},
|
|
8469
|
-
_b["arc-FormControl--".concat(labelSize)] = labelSize !== "l",
|
|
8470
|
-
_b)), id: id }, elementProps, filterAttrs(props)),
|
|
8462
|
+
React.createElement(ElementType, __assign({ className: classNames("arc-FormControl", "arc-FormControl--".concat(labelSize), {
|
|
8463
|
+
"arc-FormControl--isDisabled": isDisabled,
|
|
8464
|
+
"arc-FormControl--onDarkSurface": surface === "dark",
|
|
8465
|
+
"arc-FormControl--sideLabel": labelPosition === "left",
|
|
8466
|
+
}), id: id }, elementProps, filterAttrs(props)),
|
|
8471
8467
|
hideLabel === true ? (React.createElement(VisuallyHidden$2, null,
|
|
8472
8468
|
React.createElement(LabelType, __assign({ className: classNames("arc-FormControl-label", {
|
|
8473
8469
|
"arc-FormControl-label--withHelperUnderLabel": helperUnderLabel && helper,
|
|
@@ -14728,7 +14724,7 @@ var ComboBoxOptions = function (_a) {
|
|
|
14728
14724
|
}) }, option.isCustom ? (React.createElement(ComboBoxCustomOption, { option: option, optionsLength: options.length, customOptionSupportingCopy: customOptionSupportingCopy, selectedOptions: selectedOptions, isHighlighted: isHighlighted(i, highlightedOptionIndex), isSelected: isSingleSelected(option, singleSelectedOption) })) : (React.createElement(ComboBoxRegularOption, { option: option, isDisabled: isOptionDisabled(option, selectedOptions), isMultiSelectable: isMultiSelectable, isHighlighted: isHighlighted(i, highlightedOptionIndex), isMultiSelected: isMultiSelected(option, selectedOptions), isSingleSelected: isSingleSelected(option, singleSelectedOption) })))); })) : (React.createElement(ComboBoxNoResults, { noResultsSupportingCopy: noResultsSupportingCopy, value: value }))));
|
|
14729
14725
|
};
|
|
14730
14726
|
|
|
14731
|
-
var KeyNames
|
|
14727
|
+
var KeyNames;
|
|
14732
14728
|
(function (KeyNames) {
|
|
14733
14729
|
KeyNames["ArrowUp"] = "ArrowUp";
|
|
14734
14730
|
KeyNames["ArrowDown"] = "ArrowDown";
|
|
@@ -14736,10 +14732,10 @@ var KeyNames$1;
|
|
|
14736
14732
|
KeyNames["Enter"] = "Enter";
|
|
14737
14733
|
KeyNames["Escape"] = "Escape";
|
|
14738
14734
|
KeyNames["Space"] = " ";
|
|
14739
|
-
})(KeyNames
|
|
14735
|
+
})(KeyNames || (KeyNames = {}));
|
|
14740
14736
|
|
|
14741
14737
|
var isSelectionKey = function (key) {
|
|
14742
|
-
return key === KeyNames
|
|
14738
|
+
return key === KeyNames.Space || key === KeyNames.Enter;
|
|
14743
14739
|
};
|
|
14744
14740
|
|
|
14745
14741
|
var ComboBoxClearButton = function (_a) {
|
|
@@ -19113,8 +19109,11 @@ var ImpactCard = function (_a) {
|
|
|
19113
19109
|
return "arc-ImpactCard--preserveAspectRatio-".concat(breakpoint, "-").concat(ratio);
|
|
19114
19110
|
})
|
|
19115
19111
|
: [];
|
|
19112
|
+
var minHeightStyle = !preserveAspectRatios && {
|
|
19113
|
+
minHeight: minHeight,
|
|
19114
|
+
};
|
|
19116
19115
|
return (React.createElement(ConditionalWrapper, { condition: Boolean(preserveAspectRatios), wrapper: function (children) { return (React.createElement("div", { className: "arc-ImpactCard--preserveAspectRatioWrapper" }, children)); } },
|
|
19117
|
-
React.createElement("div", __assign({ style: {
|
|
19116
|
+
React.createElement("div", __assign({ style: __assign({}, minHeightStyle), className: classNames.apply(void 0, __spreadArray(__spreadArray(["arc-ImpactCard"], aspectRatioClassNames, false), [{
|
|
19118
19117
|
"arc-ImpactCard--darkPathway": isDarkPathway,
|
|
19119
19118
|
"arc-ImpactCard--outlined": url && showHoverState,
|
|
19120
19119
|
"arc-ImpactCard--isHovered": showHoverState,
|
|
@@ -19190,10 +19189,11 @@ var InformationCard = function (_a) {
|
|
|
19190
19189
|
index > 0 && React.createElement(VerticalSpace, { size: "8" }),
|
|
19191
19190
|
React.createElement(Text, null, paragraph))); });
|
|
19192
19191
|
};
|
|
19192
|
+
var minHeightStyle = !preserveAspectRatios && {
|
|
19193
|
+
minHeight: minHeight ? minHeight : minimumHeight,
|
|
19194
|
+
};
|
|
19193
19195
|
return (React.createElement(ConditionalWrapper, { condition: Boolean(preserveAspectRatios), wrapper: function (children) { return (React.createElement("div", { className: "arc-InformationCard--preserveAspectRatioWrapper" }, children)); } },
|
|
19194
|
-
React.createElement("div", __assign({ ref: cardRef, style: {
|
|
19195
|
-
minHeight: minHeight ? minHeight : minimumHeight,
|
|
19196
|
-
}, className: classNames.apply(void 0, __spreadArray(__spreadArray(["arc-InformationCard"], aspectRatioClassNames, false), [{
|
|
19196
|
+
React.createElement("div", __assign({ ref: cardRef, style: __assign({}, minHeightStyle), className: classNames.apply(void 0, __spreadArray(__spreadArray(["arc-InformationCard"], aspectRatioClassNames, false), [{
|
|
19197
19197
|
"arc-InformationCard--isALink": cardUrl,
|
|
19198
19198
|
"arc-InformationCard--outlined": cardUrl && showHoverState,
|
|
19199
19199
|
"arc-InformationCard--onDarkSurface": surface === "dark",
|
|
@@ -19276,8 +19276,11 @@ var MediaCard = function (_a) {
|
|
|
19276
19276
|
return "arc-MediaCard--preserveAspectRatio-".concat(breakpoint, "-").concat(ratio);
|
|
19277
19277
|
})
|
|
19278
19278
|
: [];
|
|
19279
|
+
var minHeightStyle = !preserveAspectRatios && {
|
|
19280
|
+
minHeight: minHeight,
|
|
19281
|
+
};
|
|
19279
19282
|
return (React.createElement(ConditionalWrapper, { condition: Boolean(preserveAspectRatios), wrapper: function (children) { return (React.createElement("div", { className: "arc-MediaCard--preserveAspectRatioWrapper" }, children)); } },
|
|
19280
|
-
React.createElement("div", __assign({ style: {
|
|
19283
|
+
React.createElement("div", __assign({ style: __assign({}, minHeightStyle), className: classNames.apply(void 0, __spreadArray(__spreadArray(["arc-MediaCard"], aspectRatioClassNames, false), [{
|
|
19281
19284
|
"arc-MediaCard--outlined": url && isContained && showHoverState,
|
|
19282
19285
|
"arc-MediaCard--contained": isContained,
|
|
19283
19286
|
"arc-MediaCard--onDarkSurface": surface === "dark",
|
|
@@ -20963,6 +20966,32 @@ var MenuTrigger = function (_a) {
|
|
|
20963
20966
|
}), asChild: asChild }, filterAttrs(props)), children));
|
|
20964
20967
|
};
|
|
20965
20968
|
|
|
20969
|
+
/**
|
|
20970
|
+
* Use `Skeleton` to display a placeholder preview of your page before the data gets loaded to reduce load-time frustration.
|
|
20971
|
+
*/
|
|
20972
|
+
var Skeleton = function (_a) {
|
|
20973
|
+
var _b;
|
|
20974
|
+
var width = _a.width, height = _a.height, isCircle = _a.isCircle, _c = _a.animation, animation = _c === void 0 ? "pulse" : _c, props = __rest(_a, ["width", "height", "isCircle", "animation"]);
|
|
20975
|
+
return (React.createElement("span", __assign({ className: classNames("arc-Skeleton", (_b = {
|
|
20976
|
+
"arc-Skeleton--circle": isCircle
|
|
20977
|
+
},
|
|
20978
|
+
_b["arc-Skeleton--".concat(animation)] = animation !== "none",
|
|
20979
|
+
_b)), style: { width: width, height: height } }, filterAttrs(props))));
|
|
20980
|
+
};
|
|
20981
|
+
|
|
20982
|
+
var MenuSkeletonItem = function (_a) {
|
|
20983
|
+
var _b = _a.hasLeadingIcon, hasLeadingIcon = _b === void 0 ? false : _b, _c = _a.hasTrailingIcon, hasTrailingIcon = _c === void 0 ? false : _c, _d = _a.hasSupportingText, hasSupportingText = _d === void 0 ? false : _d;
|
|
20984
|
+
return (React.createElement("div", { className: "arc-MenuSkeletonItem" },
|
|
20985
|
+
hasLeadingIcon && (React.createElement("div", { className: "arc-MenuSkeletonItem-leadingIcon" },
|
|
20986
|
+
React.createElement(Skeleton, { isCircle: true, width: 24, height: 24 }))),
|
|
20987
|
+
React.createElement("div", { className: "arc-MenuSkeletonItem-textWrapper" },
|
|
20988
|
+
React.createElement(Skeleton, { height: 24 }),
|
|
20989
|
+
hasSupportingText && (React.createElement("div", { className: "arc-MenuSkeletonItem-supportingText" },
|
|
20990
|
+
React.createElement(Skeleton, { height: 16 })))),
|
|
20991
|
+
hasTrailingIcon && (React.createElement("div", { className: "arc-MenuSkeletonItem-trailingIcon" },
|
|
20992
|
+
React.createElement(Skeleton, { isCircle: true, width: 24, height: 24 })))));
|
|
20993
|
+
};
|
|
20994
|
+
|
|
20966
20995
|
/** Use `Modal` to display information that needs immediate action from a user. */
|
|
20967
20996
|
var Modal = function (_a) {
|
|
20968
20997
|
var _b;
|
|
@@ -22451,19 +22480,6 @@ var SiteHeaderV2VerticalDivider = function () {
|
|
|
22451
22480
|
return React.createElement("li", { className: "arc-SiteHeaderV2VerticalDivider-line" });
|
|
22452
22481
|
};
|
|
22453
22482
|
|
|
22454
|
-
/**
|
|
22455
|
-
* Use `Skeleton` to display a placeholder preview of your page before the data gets loaded to reduce load-time frustration.
|
|
22456
|
-
*/
|
|
22457
|
-
var Skeleton = function (_a) {
|
|
22458
|
-
var _b;
|
|
22459
|
-
var width = _a.width, height = _a.height, isCircle = _a.isCircle, _c = _a.animation, animation = _c === void 0 ? "pulse" : _c, props = __rest(_a, ["width", "height", "isCircle", "animation"]);
|
|
22460
|
-
return (React.createElement("span", __assign({ className: classNames("arc-Skeleton", (_b = {
|
|
22461
|
-
"arc-Skeleton--circle": isCircle
|
|
22462
|
-
},
|
|
22463
|
-
_b["arc-Skeleton--".concat(animation)] = animation !== "none",
|
|
22464
|
-
_b)), style: { width: width, height: height } }, filterAttrs(props))));
|
|
22465
|
-
};
|
|
22466
|
-
|
|
22467
22483
|
/** Use `SkipLink` to help keyboard-only users skip to the main content on a page. */
|
|
22468
22484
|
var SkipLink = function (_a) {
|
|
22469
22485
|
var children = _a.children, props = __rest(_a, ["children"]);
|
|
@@ -22854,7 +22870,7 @@ var TabsList = function (_a) {
|
|
|
22854
22870
|
* Use `Tag` to promote features and manage filtering.
|
|
22855
22871
|
*/
|
|
22856
22872
|
var Tag = function (_a) {
|
|
22857
|
-
var children = _a.children, isRemovable = _a.isRemovable, link = _a.link, icon = _a.icon, onClick = _a.onClick, onRemove = _a.onRemove, title = _a.title, props = __rest(_a, ["children", "isRemovable", "link", "icon", "onClick", "onRemove", "title"]);
|
|
22873
|
+
var children = _a.children, isRemovable = _a.isRemovable, link = _a.link, ariaLabel = _a.ariaLabel, icon = _a.icon, onClick = _a.onClick, onRemove = _a.onRemove, title = _a.title, props = __rest(_a, ["children", "isRemovable", "link", "ariaLabel", "icon", "onClick", "onRemove", "title"]);
|
|
22858
22874
|
var _b = React.useState(false), isRemoved = _b[0], setIsRemoved = _b[1];
|
|
22859
22875
|
var surface = React.useContext(Context$3).surface;
|
|
22860
22876
|
var onRemoveHandler = function () {
|
|
@@ -22868,10 +22884,10 @@ var Tag = function (_a) {
|
|
|
22868
22884
|
"arc-Tag--removed": isRemoved,
|
|
22869
22885
|
"arc-Tag--onDarkSurface": surface === "dark",
|
|
22870
22886
|
}) }, (isRemoved && { "aria-hidden": true }), filterAttrs(props)),
|
|
22871
|
-
link ? (React.createElement("a", { className: "arc-Tag-content", href: link, tabIndex: 0 },
|
|
22887
|
+
link ? (React.createElement("a", { className: "arc-Tag-content", href: link, tabIndex: 0, "aria-label": ariaLabel },
|
|
22872
22888
|
icon && (React.createElement("span", { className: "arc-Tag-icon" },
|
|
22873
22889
|
React.createElement(Icon$1, { "data-testid": "arc-Tag-icon", icon: icon }))),
|
|
22874
|
-
React.createElement("div", { className: "arc-Tag-label", title: title }, children))) : (React.createElement(React.Fragment, null, onClick ? (React.createElement("button", { className: "arc-Tag-content", onClick: onClick, "data-testid": "arc-Tag-content" },
|
|
22890
|
+
React.createElement("div", { className: "arc-Tag-label", title: title }, children))) : (React.createElement(React.Fragment, null, onClick ? (React.createElement("button", { "aria-label": ariaLabel, className: "arc-Tag-content", onClick: onClick, "data-testid": "arc-Tag-content" },
|
|
22875
22891
|
icon && (React.createElement("span", { className: "arc-Tag-icon" },
|
|
22876
22892
|
React.createElement(Icon$1, { "data-testid": "arc-Tag-icon", icon: icon }))),
|
|
22877
22893
|
React.createElement("div", { className: "arc-Tag-label", title: title }, children))) : (React.createElement("div", { className: "arc-Tag-content", "data-testid": "arc-Tag-content" },
|
|
@@ -22885,7 +22901,7 @@ var Tag = function (_a) {
|
|
|
22885
22901
|
|
|
22886
22902
|
/** Use `TextArea` to allow custom user text entry via keyboard, for long-form and multi-line descriptions */
|
|
22887
22903
|
var TextArea = function (_a) {
|
|
22888
|
-
var ref = _a.ref, _b = _a.defaultValue, defaultValue = _b === void 0 ? "" : _b, errorMessage = _a.errorMessage, helper = _a.helper, hideLabel = _a.hideLabel, id = _a.id, _c = _a.resize, resize = _c === void 0 ? "manual" : _c, _d = _a.isDisabled, isDisabled = _d === void 0 ? false : _d, _e = _a.isReadOnly, isReadOnly = _e === void 0 ? false : _e, _f = _a.isRequired, isRequired = _f === void 0 ? false : _f, _g = _a.showCharacterCount, showCharacterCount = _g === void 0 ? true : _g, label = _a.label, _h = _a.labelSize, labelSize = _h === void 0 ? "
|
|
22904
|
+
var ref = _a.ref, _b = _a.defaultValue, defaultValue = _b === void 0 ? "" : _b, errorMessage = _a.errorMessage, helper = _a.helper, hideLabel = _a.hideLabel, id = _a.id, _c = _a.resize, resize = _c === void 0 ? "manual" : _c, _d = _a.isDisabled, isDisabled = _d === void 0 ? false : _d, _e = _a.isReadOnly, isReadOnly = _e === void 0 ? false : _e, _f = _a.isRequired, isRequired = _f === void 0 ? false : _f, _g = _a.showCharacterCount, showCharacterCount = _g === void 0 ? true : _g, label = _a.label, _h = _a.labelSize, labelSize = _h === void 0 ? "m" : _h, maxLength = _a.maxLength, name = _a.name, onBlur = _a.onBlur, onFocus = _a.onFocus, onChange = _a.onChange, onClickDisclosure = _a.onClickDisclosure, value = _a.value, disclosureTitle = _a.disclosureTitle, disclosureText = _a.disclosureText, width = _a.width, autoComplete = _a.autoComplete, _j = _a.minHeight, minHeight = _j === void 0 ? "116px" : _j, maxHeight = _a.maxHeight, isErrorAlert = _a.isErrorAlert, props = __rest(_a, ["ref", "defaultValue", "errorMessage", "helper", "hideLabel", "id", "resize", "isDisabled", "isReadOnly", "isRequired", "showCharacterCount", "label", "labelSize", "maxLength", "name", "onBlur", "onFocus", "onChange", "onClickDisclosure", "value", "disclosureTitle", "disclosureText", "width", "autoComplete", "minHeight", "maxHeight", "isErrorAlert"]);
|
|
22889
22905
|
var surface = React.useContext(Context$3).surface;
|
|
22890
22906
|
var ourRef = React.useRef(null);
|
|
22891
22907
|
var _k = React.useState((value && value.length) || (defaultValue && defaultValue.length) || 0), characterCount = _k[0], setCharacterCount = _k[1];
|
|
@@ -22940,7 +22956,7 @@ var TextArea = function (_a) {
|
|
|
22940
22956
|
var package_default = {
|
|
22941
22957
|
name: "@arc-ui/helpers",
|
|
22942
22958
|
private: true,
|
|
22943
|
-
version: "13.
|
|
22959
|
+
version: "13.4.0",
|
|
22944
22960
|
type: "module",
|
|
22945
22961
|
homepage: "https://ui.digital-ent-int.bt.com",
|
|
22946
22962
|
author: "BT Enterprise Digital UI Team <ui-digital-ent-int@bt.com>",
|
|
@@ -24033,8 +24049,11 @@ var TypographyCard = function (_a) {
|
|
|
24033
24049
|
return "arc-TypographyCard--preserveAspectRatio-".concat(breakpoint, "-").concat(ratio);
|
|
24034
24050
|
})
|
|
24035
24051
|
: [];
|
|
24052
|
+
var minHeightStyle = !preserveAspectRatios && {
|
|
24053
|
+
minHeight: minHeight,
|
|
24054
|
+
};
|
|
24036
24055
|
return (React.createElement(ConditionalWrapper, { condition: Boolean(preserveAspectRatios), wrapper: function (children) { return (React.createElement("div", { className: "arc-TypographyCard--preserveAspectRatioWrapper" }, children)); } },
|
|
24037
|
-
React.createElement("div", __assign({ style: {
|
|
24056
|
+
React.createElement("div", __assign({ style: __assign({}, minHeightStyle), className: classNames.apply(void 0, __spreadArray(__spreadArray(["arc-TypographyCard"], aspectRatioClassNames, false), [{
|
|
24038
24057
|
"arc-TypographyCard--outlined": showHoverState,
|
|
24039
24058
|
"arc-TypographyCard--darkPathway": isDarkPathway,
|
|
24040
24059
|
"arc-TypographyCard--lightPathway": !isDarkPathway,
|
|
@@ -27571,10 +27590,10 @@ var NavigationHeaderCta = function (_a) {
|
|
|
27571
27590
|
};
|
|
27572
27591
|
|
|
27573
27592
|
var NavigationHeaderCollapsingNavList = function (_a) {
|
|
27574
|
-
var mainLink = _a.mainLink, description = _a.description, category = _a.category, links = _a.links, revealLinkIconOnHover = _a.revealLinkIconOnHover, _b = _a.
|
|
27593
|
+
var mainLink = _a.mainLink, description = _a.description, category = _a.category, links = _a.links, revealLinkIconOnHover = _a.revealLinkIconOnHover, _b = _a.isBottomSpacing, isBottomSpacing = _b === void 0 ? false : _b, _c = _a.autoFocusOnExpand, autoFocusOnExpand = _c === void 0 ? true : _c, _d = _a.background, background = _d === void 0 ? "dark" : _d, _e = _a.defaultOpen, defaultOpen = _e === void 0 ? false : _e;
|
|
27575
27594
|
var id = React.useId();
|
|
27576
27595
|
var surface = React.useContext(Context$3).surface;
|
|
27577
|
-
var
|
|
27596
|
+
var _f = React.useState(defaultOpen), isOpen = _f[0], setIsOpen = _f[1];
|
|
27578
27597
|
var containerRef = React.useRef(null);
|
|
27579
27598
|
var onClick = function (e) {
|
|
27580
27599
|
setIsOpen(e.currentTarget.open);
|
|
@@ -27596,20 +27615,21 @@ var NavigationHeaderCollapsingNavList = function (_a) {
|
|
|
27596
27615
|
React.createElement("span", { className: "arc-NavigationHeaderCollapsingNavList-disclosureSummaryIcon" },
|
|
27597
27616
|
React.createElement(ThemeIcon, { size: 16, icon: "disclosureExpand" }))),
|
|
27598
27617
|
React.createElement("div", { className: "arc-NavigationHeaderCollapsingNavList-content" },
|
|
27599
|
-
React.createElement(VerticalSpace, { size: "8" }),
|
|
27600
27618
|
description && (React.createElement("div", { className: "arc-NavigationHeaderCollapsingNavList-description" },
|
|
27619
|
+
React.createElement(VerticalSpace, { size: "8" }),
|
|
27601
27620
|
React.createElement(Text, { size: "s", tone: "muted" }, description))),
|
|
27602
27621
|
React.createElement("div", { ref: containerRef },
|
|
27603
|
-
|
|
27604
|
-
|
|
27605
|
-
React.createElement(
|
|
27606
|
-
|
|
27607
|
-
|
|
27608
|
-
|
|
27609
|
-
|
|
27610
|
-
|
|
27611
|
-
|
|
27612
|
-
|
|
27622
|
+
React.createElement(VerticalSpace, { size: "16" }),
|
|
27623
|
+
React.createElement("ul", { className: "arc-NavigationHeaderCollapsingNavList-list" },
|
|
27624
|
+
mainLink && (React.createElement("li", null,
|
|
27625
|
+
React.createElement(NavigationHeaderCta, __assign({}, mainLink, { revealLinkIconOnHover: revealLinkIconOnHover })),
|
|
27626
|
+
React.createElement("div", { "aria-hidden": true },
|
|
27627
|
+
React.createElement(VerticalSpace, { size: "16" }),
|
|
27628
|
+
React.createElement(Rule, null),
|
|
27629
|
+
Boolean(links === null || links === void 0 ? void 0 : links.length) && React.createElement(VerticalSpace, { size: "16" })))), links === null || links === void 0 ? void 0 :
|
|
27630
|
+
links.map(function (link, i) { return (React.createElement("li", { key: "".concat(id, "-NavigationHeader-megamenu-link-").concat(i) },
|
|
27631
|
+
React.createElement(NavigationHeaderCta, __assign({}, link, { revealLinkIconOnHover: revealLinkIconOnHover })))); }))),
|
|
27632
|
+
isBottomSpacing && React.createElement(VerticalSpace, null))));
|
|
27613
27633
|
};
|
|
27614
27634
|
|
|
27615
27635
|
var SideMenuCategoryLinksItem = function (_a) {
|
|
@@ -27630,7 +27650,7 @@ var SideMenuCategoryLinksItem = function (_a) {
|
|
|
27630
27650
|
return (React.createElement(React.Fragment, null,
|
|
27631
27651
|
React.createElement(SideMenuLink, { "aria-haspopup": "dialog", "aria-expanded": isDrawerOpen, ref: triggerRef, onClick: onItemClick, text: text }),
|
|
27632
27652
|
React.createElement(SideMenuSubMenu, { isOpen: isDrawerOpen, heading: panelHeading.heading, supportingText: panelHeading.supportingText, onBackClick: onBackClick, onCloseAutoFocus: onCloseAutoFocus, backButtonLabel: backButtonLabel, backButtonAriaLabel: backButtonAriaLabel },
|
|
27633
|
-
React.createElement("div", { className: "arc-SideMenuCategoryLinksItem-navItems" }, items.map(function (navItem, navItemIndex) { return (React.createElement(NavigationHeaderCollapsingNavList, __assign({}, navItem, { key: "".concat(id, "-side-menu-category-link-item-").concat(navItemIndex) }))); })))));
|
|
27653
|
+
React.createElement("div", { className: "arc-SideMenuCategoryLinksItem-navItems" }, items.map(function (navItem, navItemIndex) { return (React.createElement(NavigationHeaderCollapsingNavList, __assign({}, navItem, { isBottomSpacing: true, key: "".concat(id, "-side-menu-category-link-item-").concat(navItemIndex) }))); })))));
|
|
27634
27654
|
};
|
|
27635
27655
|
|
|
27636
27656
|
var NavigationHeaderFeatureCard = function (_a) {
|
|
@@ -27656,7 +27676,7 @@ var NavigationHeaderFeatureCard = function (_a) {
|
|
|
27656
27676
|
};
|
|
27657
27677
|
|
|
27658
27678
|
var NavigationHeaderPanelLink = function (_a) {
|
|
27659
|
-
var icon = _a.icon, href = _a.href, onClick = _a.onClick, heading = _a.heading, description = _a.description;
|
|
27679
|
+
var icon = _a.icon, href = _a.href, ariaLabel = _a.ariaLabel, onClick = _a.onClick, heading = _a.heading, description = _a.description;
|
|
27660
27680
|
var surface = React.useContext(Context$3).surface;
|
|
27661
27681
|
return (React.createElement("div", { className: classNames("arc-NavigationHeaderPanelLink", suffixModifier("arc-NavigationHeaderPanelLink--on", surface)) },
|
|
27662
27682
|
React.createElement("div", { className: "arc-NavigationHeaderPanelLink-icon" },
|
|
@@ -27664,7 +27684,7 @@ var NavigationHeaderPanelLink = function (_a) {
|
|
|
27664
27684
|
React.createElement("div", { className: "arc-NavigationHeaderPanelLink-textCol" },
|
|
27665
27685
|
React.createElement("div", { className: "arc-NavigationHeaderPanelLink-heading" },
|
|
27666
27686
|
React.createElement(Heading, { size: "s" },
|
|
27667
|
-
React.createElement(SemanticLink, { className: "arc-NavigationHeaderPanelLink-link", href: href, onClick: onClick }, heading))),
|
|
27687
|
+
React.createElement(SemanticLink, { "aria-label": ariaLabel, className: "arc-NavigationHeaderPanelLink-link", href: href, onClick: onClick }, heading))),
|
|
27668
27688
|
React.createElement(VerticalSpace, { size: "12" }),
|
|
27669
27689
|
React.createElement("div", { className: "arc-NavigationHeaderPanelLink-description" },
|
|
27670
27690
|
React.createElement(Text, { size: "s" }, description))),
|
|
@@ -27698,7 +27718,7 @@ var MegaMenuSubMenu = function (_a) {
|
|
|
27698
27718
|
React.createElement(SideMenuSubMenu, { isOpen: isDrawerOpen, heading: heading, headingSize: "s", onBackClick: onBackClick, onCloseAutoFocus: onCloseAutoFocus, backButtonLabel: backButtonLabel, backButtonAriaLabel: backButtonAriaLabel },
|
|
27699
27719
|
React.createElement(NavigationHeaderPanelLink, __assign({}, item.panelLink, { icon: item.icon })),
|
|
27700
27720
|
React.createElement(VerticalSpace, { size: "16" }),
|
|
27701
|
-
React.createElement("div", { className: "arc-SideMenuMegaMenuItem-navItems" }, item.items.map(function (navItem, navItemIndex) { return (React.createElement(NavigationHeaderCollapsingNavList, __assign({}, navItem, { key: "".concat(id, "-side-mega-menu-drawer-navItem-").concat(navItemIndex) }))); })))));
|
|
27721
|
+
React.createElement("div", { className: "arc-SideMenuMegaMenuItem-navItems" }, item.items.map(function (navItem, navItemIndex) { return (React.createElement(NavigationHeaderCollapsingNavList, __assign({}, navItem, { isBottomSpacing: true, key: "".concat(id, "-side-mega-menu-drawer-navItem-").concat(navItemIndex) }))); })))));
|
|
27702
27722
|
};
|
|
27703
27723
|
var SideMenuMegaMenuItem = function (_a) {
|
|
27704
27724
|
var featureCards = _a.featureCards, text = _a.text, panelHeading = _a.panelHeading, tabs = _a.tabs, backButtonLabel = _a.backButtonLabel, backButtonAriaLabel = _a.backButtonAriaLabel;
|
|
@@ -27842,7 +27862,7 @@ var NavigationHeaderPanelHeading = function (_a) {
|
|
|
27842
27862
|
return (React.createElement("div", __assign({ className: "arc-NavigationHeaderPanelHeading" }, filterAttrs(props)),
|
|
27843
27863
|
React.createElement("div", { className: "arc-NavigationHeaderPanelHeading-grid" },
|
|
27844
27864
|
React.createElement("div", { className: "arc-NavigationHeaderPanelHeading-text" },
|
|
27845
|
-
React.createElement(Heading, { level: "2", size: "m" }, heading)),
|
|
27865
|
+
React.createElement(Heading, { color: "brand", level: "2", size: "m" }, heading)),
|
|
27846
27866
|
React.createElement("div", { className: "arc-NavigationHeaderPanelHeading-cta" }, link && (React.createElement(ButtonV2, { buttonStyle: "secondary", ariaLabel: link.ariaLabel, href: link.href, onClick: link.onClick, label: link.text })))),
|
|
27847
27867
|
React.createElement(VerticalSpace, { size: "4" }),
|
|
27848
27868
|
React.createElement(Text, { size: "s", tone: "muted" }, supportingText)));
|
|
@@ -29733,7 +29753,7 @@ function useFloating(options) {
|
|
|
29733
29753
|
var _a = createNavigationHeaderContext("NavigationHeader sub components must be used within NavigationHeader"), NavigationHeaderContext = _a[0], useNavigationHeaderContext = _a[1];
|
|
29734
29754
|
|
|
29735
29755
|
var NavigationHeaderSubnavContent = function (_a) {
|
|
29736
|
-
var children = _a.children, background = _a.background, menuTitle = _a.menuTitle;
|
|
29756
|
+
var children = _a.children, background = _a.background, menuTitle = _a.menuTitle, description = _a.description;
|
|
29737
29757
|
var navigationHeaderContext = useNavigationHeaderContext();
|
|
29738
29758
|
var subNavContext = useSubNavContext();
|
|
29739
29759
|
var dialogRef = React.useRef(null);
|
|
@@ -29820,9 +29840,12 @@ var NavigationHeaderSubnavContent = function (_a) {
|
|
|
29820
29840
|
React.createElement(Portal$1, { container: themeElement },
|
|
29821
29841
|
React.createElement("div", { className: "arc-NavigationHeaderSubnavContent", ref: subNavRefs.setFloating, style: subNavFloatStyles },
|
|
29822
29842
|
React.createElement(NavigationHeaderContainer, { isExtended: navigationHeaderContext === null || navigationHeaderContext === void 0 ? void 0 : navigationHeaderContext.isExtended, isFluid: navigationHeaderContext === null || navigationHeaderContext === void 0 ? void 0 : navigationHeaderContext.isFluid, isPill: navigationHeaderContext === null || navigationHeaderContext === void 0 ? void 0 : navigationHeaderContext.isPill, backgroundColor: background },
|
|
29823
|
-
React.createElement(Content, { className: "arc-NavigationHeaderSubnavContent-dialog", ref: dialogRef,
|
|
29843
|
+
React.createElement(Content, { className: "arc-NavigationHeaderSubnavContent-dialog", ref: dialogRef, onInteractOutside: onInteractOutside, onEscapeKeyDown: onEscapeKeyDown, onCloseAutoFocus: onCloseAutoFocus, onOpenAutoFocus: onOpenAutoFocus },
|
|
29824
29844
|
React.createElement(VisuallyHidden$2, null,
|
|
29825
|
-
React.createElement(Title, null,
|
|
29845
|
+
React.createElement(Title, null,
|
|
29846
|
+
menuTitle,
|
|
29847
|
+
" submenu"),
|
|
29848
|
+
React.createElement(Description, null, description)),
|
|
29826
29849
|
React.createElement("div", { ref: childContainerRef }, children))),
|
|
29827
29850
|
React.createElement(VerticalSpace, null))))));
|
|
29828
29851
|
};
|
|
@@ -29836,15 +29859,14 @@ var NavigationHeaderMegaMenu = function (_a) {
|
|
|
29836
29859
|
]; };
|
|
29837
29860
|
return (React.createElement(NavigationHeaderSubnav, { onOpenChange: onOpenChange },
|
|
29838
29861
|
React.createElement(NavigationHeaderSubnavTrigger, { ariaLabel: ariaLabel, onClick: onClick }, text),
|
|
29839
|
-
React.createElement(NavigationHeaderSubnavContent, { background: "lightElevated",
|
|
29862
|
+
React.createElement(NavigationHeaderSubnavContent, { background: "lightElevated", description: "Use tab and arrow keys to navigate. Press Escape to close.", menuTitle: text },
|
|
29840
29863
|
React.createElement("div", { className: "arc-NavigationHeaderMegaMenu" },
|
|
29841
29864
|
React.createElement("div", { className: "arc-NavigationHeaderMegaMenu-navCol" },
|
|
29842
29865
|
React.createElement(NavigationHeaderPanelHeading, __assign({}, panelHeading)),
|
|
29843
29866
|
React.createElement($69cb30bb0017df05$export$be92b6f5f03c0fe9, { orientation: "vertical", className: "arc-NavigationHeaderMegaMenu-nav", defaultValue: "".concat(tabs[0].triggerText, "-").concat(0) },
|
|
29844
29867
|
React.createElement("div", { className: "arc-NavigationHeaderMegaMenu-tabs" },
|
|
29845
|
-
React.createElement($69cb30bb0017df05$export$54c2e3dc7acea9f5, { className: "arc-NavigationHeaderMegaMenu-tabList" }, tabs.map(function (item, i) { return (React.createElement(
|
|
29846
|
-
React.createElement(
|
|
29847
|
-
React.createElement(Heading, { level: "3", size: "xs" }, item.triggerText)))); }))),
|
|
29868
|
+
React.createElement($69cb30bb0017df05$export$54c2e3dc7acea9f5, { className: "arc-NavigationHeaderMegaMenu-tabList" }, tabs.map(function (item, i) { return (React.createElement($69cb30bb0017df05$export$41fb9f06171c75f4, { key: "".concat(id, "-NavigationHeader-megamenu-trigger-").concat(i), className: "arc-NavigationHeaderMegaMenu-tab", "aria-label": item.triggerText, value: "".concat(item.triggerText, "-").concat(i), onClick: item.onClick },
|
|
29869
|
+
React.createElement(Heading, { level: "3", size: "xs" }, item.triggerText))); }))),
|
|
29848
29870
|
React.createElement("div", { className: "arc-NavigationHeaderMegaMenu-mainContent" },
|
|
29849
29871
|
React.createElement("div", { className: "arc-NavigationHeaderMegaMenu-linksPanel" }, tabs.map(function (tab, i) { return (React.createElement($69cb30bb0017df05$export$7c6e2c02157bb7d2, { tabIndex: -1, className: "arc-NavigationHeaderMegaMenu-content", key: "".concat(id, "-NavigationHeader-megamenu-content-").concat(i), value: "".concat(tab.triggerText, "-").concat(i) },
|
|
29850
29872
|
React.createElement(NavigationHeaderPanelLink, __assign({}, tab.panelLink, { icon: tab.icon })),
|
|
@@ -29861,7 +29883,7 @@ var NavigationHeaderCategoryLinks = function (_a) {
|
|
|
29861
29883
|
var id = React.useId();
|
|
29862
29884
|
return (React.createElement(NavigationHeaderSubnav, { onOpenChange: onOpenChange },
|
|
29863
29885
|
React.createElement(NavigationHeaderSubnavTrigger, { ariaLabel: ariaLabel, onClick: onClick }, text),
|
|
29864
|
-
React.createElement(NavigationHeaderSubnavContent, { background: "lightElevated", menuTitle:
|
|
29886
|
+
React.createElement(NavigationHeaderSubnavContent, { background: "lightElevated", menuTitle: text, description: "Use tab keys to navigate. Press Escape to close." },
|
|
29865
29887
|
React.createElement("div", { className: "arc-NavigationHeaderCategoryLinks" },
|
|
29866
29888
|
React.createElement(NavigationHeaderPanelHeading, __assign({}, panelHeading)),
|
|
29867
29889
|
React.createElement("div", { className: "arc-NavigationHeaderCategoryLinks-container" }, items.map(function (item, i) { return (React.createElement("div", { key: "".concat(id, "-NavigationHeader-category-link-item-").concat(i) },
|
|
@@ -30778,16 +30800,11 @@ var NavigationHeaderAction = function (_a) {
|
|
|
30778
30800
|
var NavigationHeaderSearchMenu = function (_a) {
|
|
30779
30801
|
var onSubmit = _a.onSubmit, quickLinks = _a.quickLinks, onInputChange = _a.onInputChange, _b = _a.submitButtonAriaLabel, submitButtonAriaLabel = _b === void 0 ? "Submit search" : _b, _c = _a.panelTitle, panelTitle = _c === void 0 ? "Quick links" : _c, _d = _a.description, description = _d === void 0 ? "Discover our products and how we can help your business grow" : _d, _e = _a.accessibleMenuTitle, accessibleMenuTitle = _e === void 0 ? "Search menu" : _e, _f = _a.label, label = _f === void 0 ? "Search" : _f, _g = _a.triggerTooltip, triggerTooltip = _g === void 0 ? "Search" : _g, _h = _a.triggerAriaLabel, triggerAriaLabel = _h === void 0 ? "Open search menu" : _h;
|
|
30780
30802
|
var id = React.useId();
|
|
30781
|
-
var
|
|
30782
|
-
var inputId = React.useId();
|
|
30783
|
-
var _j = React.useState(undefined), highlightedOptionIndex = _j[0], setHighlightedOptionIndex = _j[1];
|
|
30784
|
-
var _k = React.useState(""), searchTerm = _k[0], setSearchTerm = _k[1];
|
|
30803
|
+
var _j = React.useState(""), searchTerm = _j[0], setSearchTerm = _j[1];
|
|
30785
30804
|
var inputRef = React.useRef(null);
|
|
30786
|
-
var hasHighlightedOption = typeof highlightedOptionIndex === "number";
|
|
30787
30805
|
var onChange = function (e) {
|
|
30788
30806
|
onInputChange === null || onInputChange === void 0 ? void 0 : onInputChange(e.target.value);
|
|
30789
30807
|
setSearchTerm(e.target.value);
|
|
30790
|
-
setHighlightedOptionIndex(undefined);
|
|
30791
30808
|
};
|
|
30792
30809
|
var onFormSubmit = function (e) {
|
|
30793
30810
|
e.preventDefault();
|
|
@@ -30796,71 +30813,33 @@ var NavigationHeaderSearchMenu = function (_a) {
|
|
|
30796
30813
|
var onOpenChange = function (isOpen) {
|
|
30797
30814
|
if (!isOpen) {
|
|
30798
30815
|
setSearchTerm("");
|
|
30799
|
-
setHighlightedOptionIndex(undefined);
|
|
30800
|
-
}
|
|
30801
|
-
};
|
|
30802
|
-
var onInputKeyDown = function (e) {
|
|
30803
|
-
var key = e.key;
|
|
30804
|
-
if (key === KeyNames.Enter || key === KeyNames.Space) {
|
|
30805
|
-
!searchTerm && e.preventDefault();
|
|
30806
|
-
}
|
|
30807
|
-
if (key === KeyNames.ArrowDown) {
|
|
30808
|
-
e.preventDefault();
|
|
30809
|
-
var newIndex = !hasHighlightedOption ||
|
|
30810
|
-
highlightedOptionIndex === quickLinks.length - 1
|
|
30811
|
-
? 0
|
|
30812
|
-
: highlightedOptionIndex + 1;
|
|
30813
|
-
setHighlightedOptionIndex(newIndex);
|
|
30814
|
-
setSearchTerm(quickLinks[newIndex].text);
|
|
30815
|
-
}
|
|
30816
|
-
if (key === KeyNames.ArrowUp) {
|
|
30817
|
-
e.preventDefault();
|
|
30818
|
-
var newIndex = (!hasHighlightedOption || highlightedOptionIndex === 0
|
|
30819
|
-
? quickLinks.length
|
|
30820
|
-
: highlightedOptionIndex) - 1;
|
|
30821
|
-
setHighlightedOptionIndex(newIndex);
|
|
30822
|
-
setSearchTerm(quickLinks[newIndex].text);
|
|
30823
30816
|
}
|
|
30824
30817
|
};
|
|
30825
30818
|
return (React.createElement(NavigationHeaderSubnav, { onOpenChange: onOpenChange },
|
|
30826
30819
|
React.createElement(NavigationHeaderSubnavTrigger, { asChild: true },
|
|
30827
30820
|
React.createElement(NavigationHeaderAction, { title: triggerTooltip, ariaLabel: triggerAriaLabel, icon: React.createElement(ThemeIcon, { icon: "navigationHeaderSearch", size: 24 }) })),
|
|
30828
|
-
React.createElement(NavigationHeaderSubnavContent, { background: "lightElevated", menuTitle: accessibleMenuTitle },
|
|
30821
|
+
React.createElement(NavigationHeaderSubnavContent, { background: "lightElevated", menuTitle: accessibleMenuTitle, description: "Use tab keys to navigate. Press Escape to close." },
|
|
30829
30822
|
React.createElement("div", { className: "arc-NavigationHeaderSearchMenu" },
|
|
30830
30823
|
React.createElement("div", { className: "arc-NavigationHeaderSearchMenu-labelContainer" },
|
|
30831
|
-
React.createElement("label", { htmlFor:
|
|
30832
|
-
React.createElement(Heading, { size: "m" }, label)),
|
|
30824
|
+
React.createElement("label", { htmlFor: id },
|
|
30825
|
+
React.createElement(Heading, { color: "brand", size: "m" }, label)),
|
|
30833
30826
|
React.createElement(Text, null, description)),
|
|
30834
30827
|
React.createElement("form", { onSubmit: onFormSubmit, className: "arc-NavigationHeaderSearchMenu-form" },
|
|
30835
|
-
React.createElement("input", { id:
|
|
30836
|
-
? "".concat(listBoxId, "-").concat(highlightedOptionIndex)
|
|
30837
|
-
: undefined, ref: inputRef, value: searchTerm, onChange: onChange, onKeyDown: onInputKeyDown, className: "arc-NavigationHeaderSearchMenu-input", type: "text" }),
|
|
30828
|
+
React.createElement("input", { id: id, role: "searchbox", autoComplete: "off", "aria-autocomplete": "none", ref: inputRef, value: searchTerm, onChange: onChange, className: "arc-NavigationHeaderSearchMenu-input", type: "text" }),
|
|
30838
30829
|
React.createElement("div", { className: "arc-NavigationHeaderSearchMenu-actions" },
|
|
30839
30830
|
React.createElement(SemanticButton, { "aria-label": submitButtonAriaLabel, className: "arc-NavigationHeaderSearchMenu-submitButton", type: "submit" },
|
|
30840
30831
|
React.createElement(ThemeIcon, { icon: "navigationHeaderSearch" })))),
|
|
30841
30832
|
React.createElement("div", { className: "arc-NavigationHeaderSearchMenu-results" },
|
|
30842
30833
|
React.createElement(Heading, { level: "3", size: "xxxs" }, panelTitle),
|
|
30843
|
-
React.createElement("ul", {
|
|
30834
|
+
React.createElement("ul", { className: "arc-NavigationHeaderSearchMenu-resultsList" }, quickLinks.map(function (_a, i) {
|
|
30844
30835
|
var text = _a.text, href = _a.href, onClick = _a.onClick;
|
|
30845
|
-
return (React.createElement("li", {
|
|
30846
|
-
"arc-NavigationHeaderSearchMenu-listItem--highlighted": highlightedOptionIndex === i,
|
|
30847
|
-
}), role: "option", "aria-label": text, onMouseMove: function () { return setHighlightedOptionIndex(i); }, "aria-selected": highlightedOptionIndex === i, id: "".concat(listBoxId, "-").concat(i), key: "".concat(id, "-search-link-").concat(text, "-").concat(i) },
|
|
30836
|
+
return (React.createElement("li", { key: "".concat(id, "-search-link-").concat(text, "-").concat(i), className: "arc-NavigationHeaderSearchMenu-listItem" },
|
|
30848
30837
|
React.createElement("div", { className: "arc-NavigationHeaderSearchMenu-linkContainer" },
|
|
30849
|
-
React.createElement(
|
|
30850
|
-
React.createElement(SemanticLink, { className: "arc-NavigationHeaderSearchMenu-link", href: href, onClick: onClick, tabIndex: -1 }, text))),
|
|
30838
|
+
React.createElement(NavigationHeaderCta, { revealLinkIconOnHover: true, href: href, onClick: onClick, text: text })),
|
|
30851
30839
|
React.createElement("div", { className: "arc-NavigationHeaderSearchMenu-iconContainer" },
|
|
30852
30840
|
React.createElement(ArrowRightIcon, null))));
|
|
30853
30841
|
})))))));
|
|
30854
30842
|
};
|
|
30855
|
-
var KeyNames;
|
|
30856
|
-
(function (KeyNames) {
|
|
30857
|
-
KeyNames["ArrowUp"] = "ArrowUp";
|
|
30858
|
-
KeyNames["ArrowDown"] = "ArrowDown";
|
|
30859
|
-
KeyNames["Home"] = "Home";
|
|
30860
|
-
KeyNames["Enter"] = "Enter";
|
|
30861
|
-
KeyNames["Escape"] = "Escape";
|
|
30862
|
-
KeyNames["Space"] = " ";
|
|
30863
|
-
})(KeyNames || (KeyNames = {}));
|
|
30864
30843
|
|
|
30865
30844
|
var NavigationHeaderBasket = function (_a) {
|
|
30866
30845
|
var supportingCopy = _a.supportingCopy, onClick = _a.onClick, href = _a.href, _b = _a.popoverText, popoverText = _b === void 0 ? "No items in basket" : _b, _c = _a.title, title = _c === void 0 ? "Basket" : _c, _d = _a.ariaLabel, ariaLabel = _d === void 0 ? "Basket, empty" : _d, _e = _a.isAttention, isAttention = _e === void 0 ? false : _e;
|
|
@@ -31131,6 +31110,7 @@ exports.MenuLabel = MenuLabel;
|
|
|
31131
31110
|
exports.MenuPortal = MenuPortal;
|
|
31132
31111
|
exports.MenuScrollable = MenuScrollable;
|
|
31133
31112
|
exports.MenuSeparator = MenuSeparator;
|
|
31113
|
+
exports.MenuSkeletonItem = MenuSkeletonItem;
|
|
31134
31114
|
exports.MenuTrigger = MenuTrigger;
|
|
31135
31115
|
exports.Modal = Modal;
|
|
31136
31116
|
exports.NavigationHeader = NavigationHeader;
|