@ukic/web-components 2.15.0 → 2.16.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/helpers-3d0705ed.js.map +1 -1
- package/dist/cjs/ic-link.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-group.cjs.entry.js +15 -12
- package/dist/cjs/ic-navigation-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-item.cjs.entry.js +27 -31
- package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-side-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-text-field.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-top-navigation.cjs.entry.js +45 -59
- package/dist/cjs/ic-top-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/types-dc22e301.js.map +1 -1
- package/dist/collection/components/ic-link/ic-link.js.map +1 -1
- package/dist/collection/components/ic-navigation-button/ic-navigation-button.js.map +1 -1
- package/dist/collection/components/ic-navigation-group/ic-navigation-group.css +1 -0
- package/dist/collection/components/ic-navigation-group/ic-navigation-group.js +14 -11
- package/dist/collection/components/ic-navigation-group/ic-navigation-group.js.map +1 -1
- package/dist/collection/components/ic-navigation-item/ic-navigation-item.js +28 -32
- package/dist/collection/components/ic-navigation-item/ic-navigation-item.js.map +1 -1
- package/dist/collection/components/ic-side-navigation/ic-side-navigation.js.map +1 -1
- package/dist/collection/components/ic-text-field/ic-text-field.js.map +1 -1
- package/dist/collection/components/ic-top-navigation/ic-top-navigation.css +21 -24
- package/dist/collection/components/ic-top-navigation/ic-top-navigation.js +68 -59
- package/dist/collection/components/ic-top-navigation/ic-top-navigation.js.map +1 -1
- package/dist/collection/utils/helpers.js.map +1 -1
- package/dist/collection/utils/types.js.map +1 -1
- package/dist/components/helpers.js.map +1 -1
- package/dist/components/ic-link2.js.map +1 -1
- package/dist/components/ic-navigation-button.js.map +1 -1
- package/dist/components/ic-navigation-group.js +15 -12
- package/dist/components/ic-navigation-group.js.map +1 -1
- package/dist/components/ic-navigation-item.js +28 -32
- package/dist/components/ic-navigation-item.js.map +1 -1
- package/dist/components/ic-side-navigation.js.map +1 -1
- package/dist/components/ic-text-field2.js.map +1 -1
- package/dist/components/ic-top-navigation.js +47 -61
- package/dist/components/ic-top-navigation.js.map +1 -1
- package/dist/components/types.js.map +1 -1
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/p-2436d4bd.entry.js +2 -0
- package/dist/core/p-2436d4bd.entry.js.map +1 -0
- package/dist/core/p-268355c1.js.map +1 -1
- package/dist/core/p-26b7b18f.js.map +1 -1
- package/dist/core/p-2ed0232c.entry.js +2 -0
- package/dist/core/p-2ed0232c.entry.js.map +1 -0
- package/dist/core/p-8eb0e85f.entry.js +2 -0
- package/dist/core/p-8eb0e85f.entry.js.map +1 -0
- package/dist/core/p-a222554a.entry.js.map +1 -1
- package/dist/core/p-c2173562.entry.js.map +1 -1
- package/dist/core/p-f24084fa.entry.js.map +1 -1
- package/dist/core/p-fc91292d.entry.js.map +1 -1
- package/dist/esm/core.js +1 -1
- package/dist/esm/helpers-4262def4.js.map +1 -1
- package/dist/esm/ic-link.entry.js.map +1 -1
- package/dist/esm/ic-navigation-button.entry.js.map +1 -1
- package/dist/esm/ic-navigation-group.entry.js +15 -12
- package/dist/esm/ic-navigation-group.entry.js.map +1 -1
- package/dist/esm/ic-navigation-item.entry.js +28 -32
- package/dist/esm/ic-navigation-item.entry.js.map +1 -1
- package/dist/esm/ic-side-navigation.entry.js.map +1 -1
- package/dist/esm/ic-text-field.entry.js.map +1 -1
- package/dist/esm/ic-top-navigation.entry.js +46 -60
- package/dist/esm/ic-top-navigation.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/types-6f6b41a5.js.map +1 -1
- package/dist/types/components/ic-navigation-item/ic-navigation-item.d.ts +2 -2
- package/dist/types/components/ic-top-navigation/ic-top-navigation.d.ts +10 -5
- package/dist/types/components.d.ts +10 -2
- package/dist/types/utils/helpers.d.ts +6 -6
- package/dist/types/utils/types.d.ts +1 -0
- package/hydrate/index.js +88 -103
- package/package.json +2 -2
- package/vscode-data.json +4 -0
- package/dist/collection/components/ic-page-header/test/a11y/ic-page-header.test.a11y.js +0 -13
- package/dist/collection/components/ic-page-header/test/a11y/ic-page-header.test.a11y.js.map +0 -1
- package/dist/collection/components/ic-page-header/test/basic/ic-page-header.e2e.js +0 -177
- package/dist/collection/components/ic-page-header/test/basic/ic-page-header.e2e.js.map +0 -1
- package/dist/collection/components/ic-pagination/test/a11y/ic-pagination.test.a11y.js +0 -18
- package/dist/collection/components/ic-pagination/test/a11y/ic-pagination.test.a11y.js.map +0 -1
- package/dist/collection/components/ic-pagination/test/basic/ic-pagination.e2e.js +0 -128
- package/dist/collection/components/ic-pagination/test/basic/ic-pagination.e2e.js.map +0 -1
- package/dist/core/p-7cdea5bf.entry.js +0 -2
- package/dist/core/p-7cdea5bf.entry.js.map +0 -1
- package/dist/core/p-f58da6ae.entry.js +0 -2
- package/dist/core/p-f58da6ae.entry.js.map +0 -1
- package/dist/core/p-f7019830.entry.js +0 -2
- package/dist/core/p-f7019830.entry.js.map +0 -1
- package/dist/types/components/ic-page-header/test/a11y/ic-page-header.test.a11y.d.ts +0 -1
- package/dist/types/components/ic-pagination/test/a11y/ic-pagination.test.a11y.d.ts +0 -1
@@ -1 +1 @@
|
|
1
|
-
{"file":"types.js","mappings":"
|
1
|
+
{"file":"types.js","mappings":"IAyBY;AAAZ,WAAY,mBAAmB;IAC7B,0CAAmB,CAAA;IACnB,sCAAe,CAAA;IACf,0CAAmB,CAAA;AACrB,CAAC,EAJW,mBAAmB,KAAnB,mBAAmB,QAI9B;IAsEW;AAAZ,WAAY,qBAAqB;IAC/B,4CAAmB,CAAA;IACnB,sCAAa,CAAA;IACb,wCAAe,CAAA;AACjB,CAAC,EAJW,qBAAqB,KAArB,qBAAqB;;;;","names":[],"sources":["src/utils/types.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nexport type IcFocusableComponents =\n | HTMLIcBreadcrumbElement\n | HTMLIcButtonElement\n | HTMLIcCardElement\n | HTMLIcCheckboxElement\n | HTMLIcChipElement\n | HTMLIcLinkElement\n | HTMLIcNavigationButtonElement\n | HTMLIcNavigationGroupElement\n | HTMLIcNavigationItemElement\n | HTMLIcRadioOptionElement\n | HTMLIcSearchBarElement\n | HTMLIcSelectElement\n | HTMLIcSwitchElement\n | HTMLIcTabElement\n | HTMLIcTextFieldElement;\n\nexport type IcStatusVariants =\n | \"neutral\"\n | \"info\"\n | \"warning\"\n | \"error\"\n | \"success\";\n\nexport enum IcInformationStatus {\n Warning = \"warning\",\n Error = \"error\",\n Success = \"success\",\n}\n\nexport type IcSizes = \"default\" | \"large\" | \"small\";\n\nexport type IcSizesNoLarge = \"default\" | \"small\";\n\nexport type IcInformationStatusOrEmpty = \"warning\" | \"error\" | \"success\" | \"\";\n\nexport type IcNavType = \"side\" | \"top\" | \"page-header\";\n\n// From: https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete\nexport type IcAutocompleteTypes =\n | \"on\"\n | \"off\"\n | \"name\"\n | \"honorific-prefix\"\n | \"given-name\"\n | \"additional-name\"\n | \"family-name\"\n | \"honorific-suffix\"\n | \"nickname\"\n | \"email\"\n | \"username\"\n | \"new-password\"\n | \"current-password\"\n | \"one-time-code\"\n | \"organization-title\"\n | \"organization\"\n | \"street-address\"\n | \"address-line1\"\n | \"address-line2\"\n | \"address-line3\"\n | \"address-level4\"\n | \"address-level3\"\n | \"address-level2\"\n | \"address-level1\"\n | \"country\"\n | \"country-name\"\n | \"postal-code\"\n | \"cc-name\"\n | \"cc-given-name\"\n | \"cc-additional-name\"\n | \"cc-family-name\"\n | \"cc-family-name\"\n | \"cc-number\"\n | \"cc-exp\"\n | \"cc-exp-month\"\n | \"cc-exp-year\"\n | \"cc-csc\"\n | \"cc-type\"\n | \"transaction-currency\"\n | \"transaction-amount\"\n | \"language\"\n | \"bday\"\n | \"bday-day\"\n | \"bday-month\"\n | \"bday-year\"\n | \"sex\"\n | \"tel\"\n | \"tel-country-code\"\n | \"tel-national\"\n | \"tel-area-code\"\n | \"tel-local\"\n | \"tel-extension\"\n | \"impp\"\n | \"url\"\n | \"photo\";\n\nexport type IcAlignment = \"left\" | \"center\" | \"full-width\";\n\nexport enum IcThemeForegroundEnum {\n Default = \"default\",\n Dark = \"dark\",\n Light = \"light\",\n}\n\nexport type IcThemeForeground = \"default\" | \"dark\" | \"light\";\n\nexport type IcThemeForegroundNoDefault = \"dark\" | \"light\";\n\nexport type IcTheme = {\n mode: IcThemeForeground;\n color: IcColorRGB;\n};\n\nexport type IcAdditionalFieldTypes = \"static\" | \"dynamic\";\n\nexport type IcColorRGB = {\n r: number;\n g: number;\n b: number;\n};\n\nexport type IcColorRGBA = IcColorRGB & {\n a: number;\n};\n\nexport type IcActivationTypes = \"automatic\" | \"manual\";\n\nexport type IcAutocorrectStates = \"on\" | \"off\";\n\nexport type IcNavParentDetails = {\n navType: IcNavType | \"\";\n parent: HTMLElement;\n};\n\nexport type IcTypographyVariants =\n | \"h1\"\n | \"h2\"\n | \"h3\"\n | \"h4\"\n | \"subtitle-large\"\n | \"subtitle-small\"\n | \"body\"\n | \"label\"\n | \"label-uppercase\"\n | \"caption\"\n | \"caption-uppercase\"\n | \"code-large\"\n | \"code-small\"\n | \"code-extra-small\"\n | \"badge\"\n | \"badge-small\";\n\n/**\n * @interface IcMenuOption\n * @field {string} A label field to options. Defaults to \"label\", but can have any custom name.\n * @field {string} A value field to options. Defaults to \"value\", but can have any custom name.\n */\nexport interface IcMenuOption {\n description?: string;\n disabled?: boolean;\n recommended?: boolean;\n children?: IcMenuOption[];\n loading?: boolean;\n timedOut?: boolean;\n [key: string]: any;\n element?: {\n component: any;\n ariaLabel: string;\n };\n icon?: any;\n}\n\nexport type IcSearchMatchPositions = \"start\" | \"anywhere\";\n\nexport type IcCallbackFunctionNoReturn = (...args: unknown[]) => void;\n\nexport type IcRequiredPropsTypes =\n | string\n | boolean\n | number\n | HTMLElement\n | IcMenuOption[];\n\nexport type IcPropObject = { prop: IcRequiredPropsTypes; propName: string };\n\nexport type IcRelatedTarget = EventTarget | undefined;\n\nexport type IcOrientation = \"horizontal\" | \"vertical\";\n\nexport type IcEmphasisType = \"filled\" | \"outlined\";\n\nexport interface IcValueEventDetail {\n value: string;\n keyPressed?: string;\n}\nexport interface IcBlurEventDetail {\n relatedTarget: IcRelatedTarget;\n}\n\nexport type IcSelectTypes = \"single\" | \"multi\";\n\nexport type IcSelectMethodTypes = \"auto\" | \"manual\";\n\nexport type IcDeviceSizes = 0 | 576 | 768 | 992 | 1200;\n"],"version":3}
|
package/dist/core/core.esm.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
import{p as e,b as a}from"./p-6b5e91e2.js";export{s as setNonce}from"./p-6b5e91e2.js";const i=()=>{const a=import.meta.url;const i={};if(a!==""){i.resourcesUrl=new URL(".",a).href}return e(i)};i().then((e=>a(JSON.parse('[["p-77a00075",[[1,"ic-typography",{"applyVerticalMargins":[4,"apply-vertical-margins"],"bold":[4],"italic":[4],"maxLines":[2,"max-lines"],"strikethrough":[4],"underline":[4],"variant":[1],"truncated":[32],"truncButtonFocussed":[32],"expanded":[32]},null,{"expanded":["watchExpandedHandler"]}]]],["p-04d2f198",[[17,"ic-search-bar",{"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autofocus":[4],"charactersUntilSuggestion":[2,"characters-until-suggestion"],"disabled":[4],"disableFilter":[4,"disable-filter"],"debounce":[2],"emptyOptionListText":[1,"empty-option-list-text"],"focusOnLoad":[4,"focus-on-load"],"fullWidth":[4,"full-width"],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"hintText":[1,"hint-text"],"label":[1],"labelField":[1,"label-field"],"loading":[1028],"loadingErrorLabel":[1,"loading-error-label"],"loadingLabel":[1,"loading-label"],"name":[1],"placeholder":[1],"readonly":[4],"required":[4],"searchMode":[1,"search-mode"],"size":[1],"small":[4],"spellcheck":[4],"timeout":[2],"valueField":[1,"value-field"],"options":[16],"value":[1537],"ariaActiveDescendant":[32],"clearButtonFocused":[32],"highlightedValue":[32],"open":[32],"searchSubmitFocused":[32],"showClearButton":[32],"filteredOptions":[32],"setFocus":[64]},[[0,"icKeydown","handleKeyDown"],[0,"keyup","handleKeyUp"]],{"loading":["loadingHandler"],"filteredOptions":["filteredOptionsHandler"],"options":["watchOptionsHandler"],"value":["watchValueHandler"]}]]],["p-c43946b0",[[17,"ic-select",{"charactersUntilSuggestions":[2,"characters-until-suggestions"],"disabled":[516],"disableFilter":[4,"disable-filter"],"emptyOptionListText":[1,"empty-option-list-text"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"fullWidth":[4,"full-width"],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"includeDescriptionsInSearch":[4,"include-descriptions-in-search"],"includeGroupTitlesInSearch":[4,"include-group-titles-in-search"],"label":[1],"loadingErrorLabel":[1,"loading-error-label"],"loadingLabel":[1,"loading-label"],"name":[1],"placeholder":[1],"readonly":[4],"required":[4],"searchable":[4],"searchMatchPosition":[1,"search-match-position"],"selectOnEnter":[4,"select-on-enter"],"showClearButton":[4,"show-clear-button"],"size":[1],"small":[4],"timeout":[2],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"],"loading":[1028],"options":[16],"debounce":[2],"value":[1025],"ariaActiveDescendant":[32],"clearButtonFocused":[32],"debounceIcChange":[32],"hiddenInputValue":[32],"noOptions":[32],"open":[32],"pressedCharacters":[32],"searchableSelectInputValue":[32],"filteredOptions":[32],"uniqueOptions":[32],"currDebounce":[32],"initialValue":[32],"inputValueToFilter":[32],"currValue":[32],"setFocus":[64]},null,{"loading":["loadingHandler"],"options":["watchOptionsHandler"],"debounce":["debounceChangedHandler"],"value":["valueChangedHandler"],"open":["openChangedHandler"]}]]],["p-7cdea5bf",[[1,"ic-top-navigation",{"contentAligned":[1,"content-aligned"],"href":[1],"inline":[4],"shortAppTitle":[1,"short-app-title"],"status":[1],"version":[1],"appTitle":[1,"app-title"],"deviceSize":[32],"foregroundColor":[32],"hasFullWidthSearchBar":[32],"menuOpen":[32],"mobileSearchBarVisible":[32],"mobileSearchHiddenOnBlur":[32],"navMenuVisible":[32],"searchButtonClick":[32],"searchValue":[32]},[[0,"icNavigationMenuClose","navBarMenuCloseHandler"],[0,"icSearchBarBlur","searchInputBlurHandler"],[0,"icChange","searchValueChangeHandler"],[4,"themeChange","themeChangeHandler"]],{"appTitle":["watchPropHandler"]}]]],["p-b7bf772b",[[1,"ic-page-header",{"aligned":[1],"border":[4],"heading":[1],"reverseOrder":[4,"reverse-order"],"size":[1],"small":[4],"sticky":[4],"stickyDesktopOnly":[4,"sticky-desktop-only"],"subheading":[1],"actionContent":[32],"areButtonsReversed":[32],"deviceSize":[32]}]]],["p-b1e74a89",[[1,"ic-dialog",{"alertHeading":[1,"alert-heading"],"alertMessage":[1,"alert-message"],"buttons":[4],"closeOnBackdropClick":[4,"close-on-backdrop-click"],"destructive":[4],"dismissLabel":[1,"dismiss-label"],"disableHeightConstraint":[4,"disable-height-constraint"],"disableWidthConstraint":[4,"disable-width-constraint"],"hideCloseButton":[4,"hide-close-button"],"heading":[1],"label":[1],"open":[1540],"size":[1],"status":[1],"buttonProps":[16],"dialogRendered":[32],"fadeIn":[32],"showDialog":[64],"hideDialog":[64],"cancelDialog":[64],"confirmDialog":[64]},[[4,"keydown","handleKeyboard"],[0,"click","handleClick"]],{"open":["watchOpenHandler"],"buttonProps":["watchPropHandler"]}]]],["p-77503f4f",[[1,"ic-pagination",{"adjacentCount":[1026,"adjacent-count"],"appearance":[1],"boundaryCount":[1026,"boundary-count"],"defaultPage":[2,"default-page"],"disabled":[4],"hideCurrentPage":[4,"hide-current-page"],"hideFirstAndLastPageButton":[4,"hide-first-and-last-page-button"],"label":[1],"pages":[2],"type":[1],"currentPage":[1026,"current-page"],"endEllipsis":[32],"endItems":[32],"midItems":[32],"startEllipsis":[32],"startItems":[32],"setCurrentPage":[64]},[[0,"paginationItemClick","paginationItemClickHandler"]],{"pages":["watchNumberPagesHandler"],"currentPage":["watchPageChangeHandler"]}]]],["p-880bcf91",[[17,"ic-popover-menu",{"anchor":[1],"parentLabel":[1,"parent-label"],"parentPopover":[16],"submenuId":[1,"submenu-id"],"submenuLevel":[2,"submenu-level"],"open":[1540],"openingFromChild":[32],"openingFromParent":[32],"openFromChild":[64],"openFromParent":[64]},[[0,"handleMenuItemClick","handleMenuItemClick"],[2,"triggerPopoverMenuInstance","handleSubmenuChange"],[4,"click","handleClick"],[0,"keydown","handleKeyDown"]],{"open":["watchOpenHandler"]}]]],["p-fc91292d",[[1,"ic-side-navigation",{"appTitle":[1,"app-title"],"collapsedIconLabels":[4,"collapsed-icon-labels"],"disableAutoParentStyling":[4,"disable-auto-parent-styling"],"disableTopBarBehaviour":[4,"disable-top-bar-behaviour"],"expanded":[4],"href":[1],"inline":[4],"shortAppTitle":[1,"short-app-title"],"static":[4],"status":[1],"version":[1],"deviceSize":[32],"deviceSizeAppTitle":[32],"foregroundColor":[32],"hasSecondaryNavigation":[32],"menuExpanded":[32],"menuOpen":[32]},[[4,"themeChange","themeChangeHandler"]],{"expanded":["watchExpandedHandler"]}]]],["p-04dd9fe8",[[17,"ic-tab-group",{"appearance":[1],"contextId":[513,"context-id"],"inline":[516],"label":[1]}]]],["p-166861e8",[[17,"ic-accordion-group",{"accessibleButtonLabel":[1,"accessible-button-label"],"appearance":[1],"expanded":[1028],"groupTitle":[1,"group-title"],"singleExpansion":[4,"single-expansion"],"size":[1],"accordions":[32],"areAllAccordionsOpen":[32]},[[0,"accordionClicked","handleAccordionClicked"]]]]],["p-f24084fa",[[17,"ic-navigation-button",{"download":[8],"href":[1],"hreflang":[1],"label":[1],"referrerpolicy":[1],"rel":[1],"target":[1],"initialAppearance":[32],"mode":[32],"setFocus":[64]},[[4,"icNavigationMenuOpened","navBarMenuOpenHandler"],[4,"icNavigationMenuClosed","navBarMenuCloseHandler"],[4,"themeChange","themeChangeHandler"]]]]],["p-1e84a765",[[1,"ic-toast",{"autoDismissTimeout":[1026,"auto-dismiss-timeout"],"dismissButtonAriaLabel":[1,"dismiss-button-aria-label"],"dismissMode":[1025,"dismiss-mode"],"heading":[1],"message":[1],"neutralIconAriaLabel":[1,"neutral-icon-aria-label"],"variant":[1025],"timerProgress":[32],"visible":[32],"setVisible":[64]},[[2,"icDismiss","handleDismiss"],[4,"keydown","handleKeyboard"],[1,"mouseenter","handleTimer"],[1,"mouseleave","handleTimer"]]]]],["p-8841668b",[[17,"ic-toggle-button",{"accessibleLabel":[1,"accessible-label"],"appearance":[1],"disabled":[4],"fullWidth":[4,"full-width"],"iconPlacement":[1,"icon-placement"],"label":[1],"loading":[4],"size":[1],"toggleChecked":[1540,"toggle-checked"],"variant":[513]},[[2,"click","handleHostClick"]]]]],["p-cd2d2141",[[1,"ic-checkbox-group",{"disabled":[4],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"label":[1],"name":[1],"required":[4],"size":[1],"small":[4],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"]},[[0,"icChange","handleChange"],[0,"icCheck","selectHandler"]]]]],["p-aac0195e",[[1,"ic-radio-group",{"disabled":[4],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"label":[1],"name":[1],"orientation":[1],"required":[4],"size":[1],"small":[4],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"],"checkedValue":[32],"currentOrientation":[32],"initialOrientation":[32],"selectedChild":[32]},[[0,"icCheck","selectHandler"],[0,"icSelectedChange","changeHandler"]],{"orientation":["orientationChangeHandler"]}]]],["p-cdb51adf",[[1,"ic-breadcrumb-group",{"appearance":[1],"backBreadcrumbOnly":[4,"back-breadcrumb-only"],"collapsed":[4],"deviceSize":[32],"expandedBreadcrumbs":[32]}]]],["p-2edbdbaf",[[1,"ic-card",{"clickable":[1028],"disabled":[4],"expandable":[4],"fullWidth":[4,"full-width"],"heading":[1],"href":[1],"hreflang":[1],"message":[1],"referrerpolicy":[1],"rel":[1],"subheading":[1],"target":[1],"appearance":[32],"areaExpanded":[32],"isFocussed":[32],"parentEl":[32],"parentIsAnchorTag":[32],"setFocus":[64]},[[2,"click","handleHostClick"],[4,"themeChange","themeChangeHandler"]]]]],["p-ab14339d",[[17,"ic-chip",{"appearance":[1],"disabled":[4],"dismissible":[4],"label":[1],"size":[1],"transparentBackground":[4,"transparent-background"],"variant":[1],"isHovered":[32],"visible":[32],"setFocus":[64]},[[2,"icDismiss","handleClick"]]]]],["p-18137908",[[1,"ic-footer",{"aligned":[1],"breakpoint":[1],"caption":[1],"copyright":[4],"description":[1],"groupLinks":[4,"group-links"],"deviceSize":[32],"foregroundColor":[32]},[[4,"themeChange","themeChangeHandler"]]]]],["p-5479d3e5",[[17,"ic-footer-link-group",{"groupTitle":[1,"group-title"],"expanded":[32],"deviceSize":[32],"dropdownIconStyle":[32],"small":[32]},[[4,"footerResized","footerResizeHandler"],[4,"themeChange","footerThemeChangeHandler"]]]]],["p-9b4fd843",[[1,"ic-hero",{"aligned":[1],"backgroundImage":[1,"background-image"],"contentAligned":[1,"content-aligned"],"disableBackgroundParallax":[4,"disable-background-parallax"],"heading":[1],"secondaryHeading":[1,"secondary-heading"],"secondarySubheading":[1,"secondary-subheading"],"size":[1],"small":[4],"subheading":[1],"foregroundColor":[32],"rightContent":[32],"leftContentFullWidth":[32],"scrollFactor":[32]},[[4,"themeChange","themeChangeHandler"],[5,"scroll","doScroll"]]]]],["p-f58da6ae",[[17,"ic-navigation-item",{"collapsedIconLabel":[4,"collapsed-icon-label"],"displayNavigationTooltip":[4,"display-navigation-tooltip"],"download":[8],"expandable":[4],"href":[1],"hreflang":[1],"label":[1],"rel":[1],"referrerpolicy":[1],"selected":[4],"target":[1],"deviceSize":[32],"focusStyle":[32],"inTopNavSideMenu":[32],"isSideNavMobile":[32],"isTopNavChild":[32],"navigationType":[32],"parentEl":[32],"sideNavExpanded":[32],"setFocus":[64]},[[4,"themeChange","themeChangeHandler"]]]]],["p-ba8d968c",[[1,"ic-step",{"compactStepStyling":[1,"compact-step-styling"],"current":[1028],"lastStep":[4,"last-step"],"lastStepNum":[2,"last-step-num"],"nextStepTitle":[1,"next-step-title"],"progress":[2],"stepNum":[2,"step-num"],"stepStatus":[1,"step-status"],"stepSubtitle":[1,"step-subtitle"],"stepTitle":[1,"step-title"],"variant":[1],"stepType":[1,"step-type"]},null,{"stepType":["stepTypeChangeHandler"]}]]],["p-14ea9cc7",[[17,"ic-switch",{"checked":[4],"disabled":[4],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"label":[1],"name":[1],"showState":[4,"show-state"],"size":[1],"small":[4],"value":[1],"checkedState":[32],"initiallyChecked":[32],"setFocus":[64]},null,{"checked":["checkedChangeHandler"]}]]],["p-d5cadfa1",[[1,"ic-accordion",{"appearance":[1],"disabled":[4],"expanded":[1028],"heading":[1],"message":[1],"size":[1],"setFocus":[64]},null,{"expanded":["handleExpandedWatch"]}]]],["p-8a77a417",[[17,"ic-back-to-top",{"target":[1],"bannerOffset":[32],"footerVisible":[32],"targetElVisible":[32]},null,{"target":["watchPropHandler"]}]]],["p-22cbe39b",[[17,"ic-badge",{"accessibleLabel":[1,"accessible-label"],"customColor":[1,"custom-color"],"maxNumber":[2,"max-number"],"position":[1],"size":[1],"textLabel":[1,"text-label"],"type":[1],"variant":[1],"visible":[1028],"showBadge":[64],"hideBadge":[64]}]]],["p-cc0ab439",[[17,"ic-checkbox",{"additionalFieldDisplay":[513,"additional-field-display"],"checked":[1540],"disabled":[4],"dynamicText":[1,"dynamic-text"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"groupLabel":[1,"group-label"],"indeterminate":[4],"label":[1],"name":[1],"size":[1],"small":[4],"value":[1],"initiallyChecked":[32],"setFocus":[64]}]]],["p-3cc52cbc",[[1,"ic-classification-banner",{"additionalSelectors":[1,"additional-selectors"],"classification":[1],"country":[1],"inline":[4],"upTo":[4,"up-to"]}]]],["p-7438ab1f",[[1,"ic-data-entity",{"heading":[1],"size":[1],"small":[4]}]]],["p-f026466e",[[1,"ic-data-row",{"label":[1],"size":[1],"small":[4],"value":[1],"deviceSize":[32],"entitySize":[32]}]]],["p-5421ceb4",[[1,"ic-empty-state",{"aligned":[1],"body":[1],"bodyMaxLines":[2,"body-max-lines"],"heading":[1],"imageSize":[1,"image-size"],"subheading":[1]}]]],["p-dfef57d3",[[1,"ic-menu-group",{"label":[1]}]]],["p-f7019830",[[17,"ic-navigation-group",{"expandable":[4],"label":[1],"deviceSize":[32],"dropdownOpen":[32],"expanded":[32],"focusStyle":[32],"inTopNavSideMenu":[32],"navigationType":[32],"parentEl":[32],"setFocus":[64]},[[0,"childBlur","childBlurHandler"],[0,"navItemClicked","navItemClickHandler"],[4,"themeChange","themeChangeHandler"]]]]],["p-c1bb5018",[[17,"ic-radio-option",{"additionalFieldDisplay":[513,"additional-field-display"],"disabled":[4],"dynamicText":[1,"dynamic-text"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"groupLabel":[1,"group-label"],"label":[1],"name":[1],"value":[1025],"selected":[1540],"initiallySelected":[32],"setFocus":[64]},[[0,"icChange","textfieldValueHandler"]],{"selected":["watchSelectedHandler"]}]]],["p-8352d752",[[1,"ic-status-tag",{"announced":[4],"appearance":[1],"label":[1],"size":[1],"small":[4],"status":[1],"variant":[1]}]]],["p-ba31ee69",[[1,"ic-tab",{"appearance":[1],"contextId":[513,"context-id"],"disabled":[4],"selected":[516],"tabId":[513,"tab-id"],"tabPosition":[2,"tab-position"],"setFocus":[64]},null,{"disabled":["disabledWatchHandler"]}]]],["p-8cbbe579",[[17,"ic-footer-link",{"download":[8],"href":[1],"hreflang":[1],"referrerpolicy":[1],"rel":[1],"target":[1],"deviceSize":[32],"footerConfig":[32],"foregroundColor":[32]},[[4,"footerResized","footerResizeHandler"],[4,"themeChange","footerThemeChangeHandler"]]]]],["p-7b720034",[[1,"ic-skeleton",{"appearance":[1],"light":[4],"variant":[1],"default":[32],"hasChild":[32],"heightOnly":[32],"widthOnly":[32]}]]],["p-4e3d46f2",[[1,"ic-stepper",{"aligned":[1],"connectorWidth":[2,"connector-width"],"hideStepInfo":[4,"hide-step-info"],"variant":[1025],"alignedFullWidth":[32],"autoSetStepTitles":[32],"lastStepWidth":[32],"noOfResizes":[32],"stepperWidth":[32],"stepTypes":[32],"variantOverride":[32]}]]],["p-cf798ea7",[[4,"ic-tab-context",{"activationType":[1,"activation-type"],"appearance":[1],"contextId":[513,"context-id"],"selectedTabIndex":[2,"selected-tab-index"],"selectedTab":[32],"tabRemovedHandler":[64]},[[0,"tabClick","tabClickHandler"],[0,"tabCreated","tabCreatedHandler"],[0,"tabPanelCreated","tabCreatedHandler"],[0,"tabEnabled","tabEnabledHandler"]],{"selectedTabIndex":["updateSelectedTab"]}]]],["p-fc83d8d7",[[1,"ic-tab-panel",{"appearance":[1],"contextId":[513,"context-id"],"panelId":[513,"panel-id"],"selectedTab":[1,"selected-tab"],"tabPosition":[514,"tab-position"]}]]],["p-917b15da",[[1,"ic-theme",{"color":[1]},null,{"color":["watchColorPropHandler"]}]]],["p-1145e33c",[[4,"ic-toast-region",{"openToast":[1040],"setVisible":[64]},[[2,"icDismiss","handleDismissedToast"]],{"openToast":["watchOpenToastHandler"]}]]],["p-6fae929c",[[1,"ic-toggle-button-group",{"accessibleLabel":[1,"accessible-label"],"appearance":[1],"disabled":[4],"fullWidth":[4,"full-width"],"iconPlacement":[1,"icon-placement"],"loading":[4],"selectMethod":[1025,"select-method"],"selectType":[1,"select-type"],"size":[1],"variant":[513],"lastKeyPressed":[32]},[[0,"icToggleChecked","selectHandler"]]]]],["p-a222554a",[[1,"ic-text-field",{"ariaActiveDescendant":[1,"aria-active-descendant"],"ariaAutocomplete":[1,"aria-autocomplete"],"ariaExpanded":[1,"aria-expanded"],"ariaOwns":[1,"aria-owns"],"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autoFocus":[4,"auto-focus"],"disabled":[4],"fullWidth":[4,"full-width"],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"hiddenInput":[4,"hidden-input"],"inputId":[1,"input-id"],"inputmode":[1],"label":[1],"max":[8],"maxCharacters":[2,"max-characters"],"maxLength":[2,"max-length"],"min":[8],"minCharacters":[2,"min-characters"],"name":[1],"placeholder":[1],"readonly":[516],"required":[4],"resize":[4],"role":[1],"rows":[2],"size":[1],"small":[4],"spellcheck":[4],"truncateValue":[4,"truncate-value"],"type":[1],"validationInline":[4,"validation-inline"],"validationInlineInternal":[4,"validation-inline-internal"],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"],"debounce":[2],"value":[1537],"numChars":[32],"maxCharactersReached":[32],"maxCharactersError":[32],"minCharactersUnattained":[32],"maxLengthExceeded":[32],"maxValueExceeded":[32],"minValueUnattained":[32],"initialValue":[32],"setFocus":[64]},[[0,"keydown","handleKeyDown"]],{"debounce":["debounceChanged"],"value":["watchValueHandler"]}]]],["p-e7483ee5",[[1,"ic-alert",{"announced":[4],"dismissible":[4],"heading":[1],"message":[1],"titleAbove":[4,"title-above"],"variant":[1],"alertTitleWrap":[32],"visible":[32]},[[2,"icDismiss","handleClick"]]]]],["p-f926174d",[[17,"ic-menu-item",{"description":[1],"disabled":[4],"href":[1],"hreflang":[1],"keyboardShortcut":[1,"keyboard-shortcut"],"label":[1],"referrerpolicy":[1],"rel":[1],"submenuTriggerFor":[1,"submenu-trigger-for"],"target":[1],"variant":[1537],"toggleChecked":[32]},[[2,"click","handleHostClick"]]]]],["p-65d3c0f1",[[1,"ic-navigation-menu",{"status":[1],"version":[1]},[[0,"navItemClicked","navItemClickHandler"],[4,"keydown","handleKeyDown"]]]]],["p-c2173562",[[17,"ic-link",{"appearance":[1025],"download":[8],"href":[1],"hreflang":[1],"referrerpolicy":[1],"rel":[1],"showIcon":[4,"show-icon"],"target":[1],"setFocus":[64]},[[4,"themeChange","themeChangeHandler"]]]]],["p-e7b676fc",[[17,"ic-breadcrumb",{"appearance":[1],"current":[4],"href":[1],"pageTitle":[1,"page-title"],"showBackIcon":[516,"show-back-icon"],"setFocus":[64]}]]],["p-934c2a94",[[1,"ic-pagination-item",{"appearance":[1],"ariaOverride":[4,"aria-override"],"disabled":[4],"label":[1],"page":[2],"pages":[2],"selected":[4],"type":[1]}]]],["p-c0525936",[[2,"ic-divider",{"foregroundColor":[32]},[[4,"themeChange","themeChangeHandler"]]]]],["p-e47f887a",[[1,"ic-horizontal-scroll",{"appearance":[1],"focusTrigger":[1,"focus-trigger"],"firstItemVisible":[32],"itemOverflow":[32],"lastItemVisible":[32],"scrollItemIntoView":[64]}]]],["p-e9723eaa",[[1,"ic-section-container",{"aligned":[1],"fullHeight":[4,"full-height"]}]]],["p-563c2522",[[2,"ic-menu",{"activationType":[1,"activation-type"],"anchorEl":[16],"autoFocusOnSelected":[4,"auto-focus-on-selected"],"fullWidth":[4,"full-width"],"inputEl":[16],"inputLabel":[1,"input-label"],"labelField":[1,"label-field"],"menuId":[1,"menu-id"],"open":[516],"parentEl":[16],"searchMode":[1,"search-mode"],"selectOnEnter":[4,"select-on-enter"],"size":[1],"small":[4],"options":[16],"value":[1025],"valueField":[1,"value-field"],"focusFromSearchKeypress":[32],"initialOptionsListRender":[32],"keyboardNav":[32],"optionHighlighted":[32],"preventIncorrectTabOrder":[32],"handleClickOpen":[64],"handleKeyboardOpen":[64],"handleSetFirstOption":[64],"initPopperJs":[64]},null,{"open":["watchOpenHandler"],"options":["watchOptionsHandler"],"value":["watchValueHandler"]}],[4,"ic-input-component-container",{"appearance":[1],"dark":[4],"disabled":[4],"fullWidth":[4,"full-width"],"multiLine":[4,"multi-line"],"readonly":[4],"size":[1],"small":[4],"validationInline":[4,"validation-inline"],"validationStatus":[1,"validation-status"]}],[4,"ic-input-container",{"disabled":[4],"readonly":[4]}]]],["p-9c157974",[[4,"ic-input-validation",{"ariaLiveMode":[1,"aria-live-mode"],"for":[1],"fullWidth":[4,"full-width"],"message":[1],"status":[1]}],[0,"ic-input-label",{"appearance":[1],"dark":[4],"disabled":[4],"error":[4],"for":[1],"helperText":[1,"helper-text"],"label":[1],"readonly":[4],"required":[4]}]]],["p-2e3845be",[[17,"ic-button",{"accept":[1],"appearance":[1025],"ariaControlsId":[8,"aria-controls-id"],"ariaOwnsId":[8,"aria-owns-id"],"disabled":[4],"disableTooltip":[4,"disable-tooltip"],"download":[8],"dropdown":[4],"dropdownExpanded":[1540,"dropdown-expanded"],"fileUpload":[4,"file-upload"],"fileInputName":[1,"file-input-name"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"fullWidth":[4,"full-width"],"href":[1],"hreflang":[1],"loading":[4],"multiple":[4],"referrerpolicy":[1],"rel":[1],"selectedFiles":[16],"size":[1],"target":[1],"tooltipPlacement":[1,"tooltip-placement"],"transparentBackground":[4,"transparent-background"],"type":[1],"variant":[1],"ariaLabel":[32],"describedByContent":[32],"title":[32],"setFocus":[64]},[[2,"click","handleHostClick"],[4,"themeChange","themeChangeHandler"]],{"disabled":["watchDisabledHandler"]}],[1,"ic-loading-indicator",{"appearance":[1],"description":[1],"fullWidth":[516,"full-width"],"innerLabel":[2,"inner-label"],"labelDuration":[2,"label-duration"],"max":[2],"min":[2],"size":[513],"type":[513],"label":[1],"progress":[2],"circularDiameter":[32],"circularLineWidth":[32],"indeterminate":[32],"indicatorLabel":[32],"showSecond":[32]},null,{"label":["watchPropHandler"],"progress":["watchProgressHandler"]}],[1,"ic-tooltip",{"disableClick":[4,"disable-click"],"disableHover":[4,"disable-hover"],"maxLines":[2,"max-lines"],"placement":[1025],"silent":[4],"target":[513],"label":[1],"displayTooltip":[64]}]]]]'),e)));
|
1
|
+
import{p as e,b as a}from"./p-6b5e91e2.js";export{s as setNonce}from"./p-6b5e91e2.js";const i=()=>{const a=import.meta.url;const i={};if(a!==""){i.resourcesUrl=new URL(".",a).href}return e(i)};i().then((e=>a(JSON.parse('[["p-77a00075",[[1,"ic-typography",{"applyVerticalMargins":[4,"apply-vertical-margins"],"bold":[4],"italic":[4],"maxLines":[2,"max-lines"],"strikethrough":[4],"underline":[4],"variant":[1],"truncated":[32],"truncButtonFocussed":[32],"expanded":[32]},null,{"expanded":["watchExpandedHandler"]}]]],["p-04d2f198",[[17,"ic-search-bar",{"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autofocus":[4],"charactersUntilSuggestion":[2,"characters-until-suggestion"],"disabled":[4],"disableFilter":[4,"disable-filter"],"debounce":[2],"emptyOptionListText":[1,"empty-option-list-text"],"focusOnLoad":[4,"focus-on-load"],"fullWidth":[4,"full-width"],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"hintText":[1,"hint-text"],"label":[1],"labelField":[1,"label-field"],"loading":[1028],"loadingErrorLabel":[1,"loading-error-label"],"loadingLabel":[1,"loading-label"],"name":[1],"placeholder":[1],"readonly":[4],"required":[4],"searchMode":[1,"search-mode"],"size":[1],"small":[4],"spellcheck":[4],"timeout":[2],"valueField":[1,"value-field"],"options":[16],"value":[1537],"ariaActiveDescendant":[32],"clearButtonFocused":[32],"highlightedValue":[32],"open":[32],"searchSubmitFocused":[32],"showClearButton":[32],"filteredOptions":[32],"setFocus":[64]},[[0,"icKeydown","handleKeyDown"],[0,"keyup","handleKeyUp"]],{"loading":["loadingHandler"],"filteredOptions":["filteredOptionsHandler"],"options":["watchOptionsHandler"],"value":["watchValueHandler"]}]]],["p-c43946b0",[[17,"ic-select",{"charactersUntilSuggestions":[2,"characters-until-suggestions"],"disabled":[516],"disableFilter":[4,"disable-filter"],"emptyOptionListText":[1,"empty-option-list-text"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"fullWidth":[4,"full-width"],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"includeDescriptionsInSearch":[4,"include-descriptions-in-search"],"includeGroupTitlesInSearch":[4,"include-group-titles-in-search"],"label":[1],"loadingErrorLabel":[1,"loading-error-label"],"loadingLabel":[1,"loading-label"],"name":[1],"placeholder":[1],"readonly":[4],"required":[4],"searchable":[4],"searchMatchPosition":[1,"search-match-position"],"selectOnEnter":[4,"select-on-enter"],"showClearButton":[4,"show-clear-button"],"size":[1],"small":[4],"timeout":[2],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"],"loading":[1028],"options":[16],"debounce":[2],"value":[1025],"ariaActiveDescendant":[32],"clearButtonFocused":[32],"debounceIcChange":[32],"hiddenInputValue":[32],"noOptions":[32],"open":[32],"pressedCharacters":[32],"searchableSelectInputValue":[32],"filteredOptions":[32],"uniqueOptions":[32],"currDebounce":[32],"initialValue":[32],"inputValueToFilter":[32],"currValue":[32],"setFocus":[64]},null,{"loading":["loadingHandler"],"options":["watchOptionsHandler"],"debounce":["debounceChangedHandler"],"value":["valueChangedHandler"],"open":["openChangedHandler"]}]]],["p-2436d4bd",[[1,"ic-top-navigation",{"contentAligned":[1,"content-aligned"],"customMobileBreakpoint":[2,"custom-mobile-breakpoint"],"href":[1],"inline":[4],"shortAppTitle":[1,"short-app-title"],"status":[1],"version":[1],"appTitle":[1,"app-title"],"deviceSize":[32],"foregroundColor":[32],"hasFullWidthSearchBar":[32],"mobileSearchBarVisible":[32],"mobileSearchHiddenOnBlur":[32],"navMenuVisible":[32],"searchButtonClick":[32],"searchValue":[32]},[[0,"icNavigationMenuClose","navBarMenuCloseHandler"],[0,"icSearchBarBlur","searchInputBlurHandler"],[0,"icChange","searchValueChangeHandler"],[4,"themeChange","themeChangeHandler"]],{"appTitle":["watchPropHandler"]}]]],["p-b7bf772b",[[1,"ic-page-header",{"aligned":[1],"border":[4],"heading":[1],"reverseOrder":[4,"reverse-order"],"size":[1],"small":[4],"sticky":[4],"stickyDesktopOnly":[4,"sticky-desktop-only"],"subheading":[1],"actionContent":[32],"areButtonsReversed":[32],"deviceSize":[32]}]]],["p-b1e74a89",[[1,"ic-dialog",{"alertHeading":[1,"alert-heading"],"alertMessage":[1,"alert-message"],"buttons":[4],"closeOnBackdropClick":[4,"close-on-backdrop-click"],"destructive":[4],"dismissLabel":[1,"dismiss-label"],"disableHeightConstraint":[4,"disable-height-constraint"],"disableWidthConstraint":[4,"disable-width-constraint"],"hideCloseButton":[4,"hide-close-button"],"heading":[1],"label":[1],"open":[1540],"size":[1],"status":[1],"buttonProps":[16],"dialogRendered":[32],"fadeIn":[32],"showDialog":[64],"hideDialog":[64],"cancelDialog":[64],"confirmDialog":[64]},[[4,"keydown","handleKeyboard"],[0,"click","handleClick"]],{"open":["watchOpenHandler"],"buttonProps":["watchPropHandler"]}]]],["p-77503f4f",[[1,"ic-pagination",{"adjacentCount":[1026,"adjacent-count"],"appearance":[1],"boundaryCount":[1026,"boundary-count"],"defaultPage":[2,"default-page"],"disabled":[4],"hideCurrentPage":[4,"hide-current-page"],"hideFirstAndLastPageButton":[4,"hide-first-and-last-page-button"],"label":[1],"pages":[2],"type":[1],"currentPage":[1026,"current-page"],"endEllipsis":[32],"endItems":[32],"midItems":[32],"startEllipsis":[32],"startItems":[32],"setCurrentPage":[64]},[[0,"paginationItemClick","paginationItemClickHandler"]],{"pages":["watchNumberPagesHandler"],"currentPage":["watchPageChangeHandler"]}]]],["p-880bcf91",[[17,"ic-popover-menu",{"anchor":[1],"parentLabel":[1,"parent-label"],"parentPopover":[16],"submenuId":[1,"submenu-id"],"submenuLevel":[2,"submenu-level"],"open":[1540],"openingFromChild":[32],"openingFromParent":[32],"openFromChild":[64],"openFromParent":[64]},[[0,"handleMenuItemClick","handleMenuItemClick"],[2,"triggerPopoverMenuInstance","handleSubmenuChange"],[4,"click","handleClick"],[0,"keydown","handleKeyDown"]],{"open":["watchOpenHandler"]}]]],["p-fc91292d",[[1,"ic-side-navigation",{"appTitle":[1,"app-title"],"collapsedIconLabels":[4,"collapsed-icon-labels"],"disableAutoParentStyling":[4,"disable-auto-parent-styling"],"disableTopBarBehaviour":[4,"disable-top-bar-behaviour"],"expanded":[4],"href":[1],"inline":[4],"shortAppTitle":[1,"short-app-title"],"static":[4],"status":[1],"version":[1],"deviceSize":[32],"deviceSizeAppTitle":[32],"foregroundColor":[32],"hasSecondaryNavigation":[32],"menuExpanded":[32],"menuOpen":[32]},[[4,"themeChange","themeChangeHandler"]],{"expanded":["watchExpandedHandler"]}]]],["p-04dd9fe8",[[17,"ic-tab-group",{"appearance":[1],"contextId":[513,"context-id"],"inline":[516],"label":[1]}]]],["p-166861e8",[[17,"ic-accordion-group",{"accessibleButtonLabel":[1,"accessible-button-label"],"appearance":[1],"expanded":[1028],"groupTitle":[1,"group-title"],"singleExpansion":[4,"single-expansion"],"size":[1],"accordions":[32],"areAllAccordionsOpen":[32]},[[0,"accordionClicked","handleAccordionClicked"]]]]],["p-f24084fa",[[17,"ic-navigation-button",{"download":[8],"href":[1],"hreflang":[1],"label":[1],"referrerpolicy":[1],"rel":[1],"target":[1],"initialAppearance":[32],"mode":[32],"setFocus":[64]},[[4,"icNavigationMenuOpened","navBarMenuOpenHandler"],[4,"icNavigationMenuClosed","navBarMenuCloseHandler"],[4,"themeChange","themeChangeHandler"]]]]],["p-1e84a765",[[1,"ic-toast",{"autoDismissTimeout":[1026,"auto-dismiss-timeout"],"dismissButtonAriaLabel":[1,"dismiss-button-aria-label"],"dismissMode":[1025,"dismiss-mode"],"heading":[1],"message":[1],"neutralIconAriaLabel":[1,"neutral-icon-aria-label"],"variant":[1025],"timerProgress":[32],"visible":[32],"setVisible":[64]},[[2,"icDismiss","handleDismiss"],[4,"keydown","handleKeyboard"],[1,"mouseenter","handleTimer"],[1,"mouseleave","handleTimer"]]]]],["p-8841668b",[[17,"ic-toggle-button",{"accessibleLabel":[1,"accessible-label"],"appearance":[1],"disabled":[4],"fullWidth":[4,"full-width"],"iconPlacement":[1,"icon-placement"],"label":[1],"loading":[4],"size":[1],"toggleChecked":[1540,"toggle-checked"],"variant":[513]},[[2,"click","handleHostClick"]]]]],["p-cd2d2141",[[1,"ic-checkbox-group",{"disabled":[4],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"label":[1],"name":[1],"required":[4],"size":[1],"small":[4],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"]},[[0,"icChange","handleChange"],[0,"icCheck","selectHandler"]]]]],["p-aac0195e",[[1,"ic-radio-group",{"disabled":[4],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"label":[1],"name":[1],"orientation":[1],"required":[4],"size":[1],"small":[4],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"],"checkedValue":[32],"currentOrientation":[32],"initialOrientation":[32],"selectedChild":[32]},[[0,"icCheck","selectHandler"],[0,"icSelectedChange","changeHandler"]],{"orientation":["orientationChangeHandler"]}]]],["p-cdb51adf",[[1,"ic-breadcrumb-group",{"appearance":[1],"backBreadcrumbOnly":[4,"back-breadcrumb-only"],"collapsed":[4],"deviceSize":[32],"expandedBreadcrumbs":[32]}]]],["p-2edbdbaf",[[1,"ic-card",{"clickable":[1028],"disabled":[4],"expandable":[4],"fullWidth":[4,"full-width"],"heading":[1],"href":[1],"hreflang":[1],"message":[1],"referrerpolicy":[1],"rel":[1],"subheading":[1],"target":[1],"appearance":[32],"areaExpanded":[32],"isFocussed":[32],"parentEl":[32],"parentIsAnchorTag":[32],"setFocus":[64]},[[2,"click","handleHostClick"],[4,"themeChange","themeChangeHandler"]]]]],["p-ab14339d",[[17,"ic-chip",{"appearance":[1],"disabled":[4],"dismissible":[4],"label":[1],"size":[1],"transparentBackground":[4,"transparent-background"],"variant":[1],"isHovered":[32],"visible":[32],"setFocus":[64]},[[2,"icDismiss","handleClick"]]]]],["p-18137908",[[1,"ic-footer",{"aligned":[1],"breakpoint":[1],"caption":[1],"copyright":[4],"description":[1],"groupLinks":[4,"group-links"],"deviceSize":[32],"foregroundColor":[32]},[[4,"themeChange","themeChangeHandler"]]]]],["p-5479d3e5",[[17,"ic-footer-link-group",{"groupTitle":[1,"group-title"],"expanded":[32],"deviceSize":[32],"dropdownIconStyle":[32],"small":[32]},[[4,"footerResized","footerResizeHandler"],[4,"themeChange","footerThemeChangeHandler"]]]]],["p-9b4fd843",[[1,"ic-hero",{"aligned":[1],"backgroundImage":[1,"background-image"],"contentAligned":[1,"content-aligned"],"disableBackgroundParallax":[4,"disable-background-parallax"],"heading":[1],"secondaryHeading":[1,"secondary-heading"],"secondarySubheading":[1,"secondary-subheading"],"size":[1],"small":[4],"subheading":[1],"foregroundColor":[32],"rightContent":[32],"leftContentFullWidth":[32],"scrollFactor":[32]},[[4,"themeChange","themeChangeHandler"],[5,"scroll","doScroll"]]]]],["p-8eb0e85f",[[17,"ic-navigation-item",{"collapsedIconLabel":[4,"collapsed-icon-label"],"displayNavigationTooltip":[4,"display-navigation-tooltip"],"download":[8],"expandable":[4],"href":[1],"hreflang":[1],"label":[1],"rel":[1],"referrerpolicy":[1],"selected":[4],"target":[1],"deviceSize":[32],"focusStyle":[32],"inTopNavSideMenu":[32],"isSideNavMobile":[32],"isTopNavChild":[32],"navigationType":[32],"parentEl":[32],"sideNavExpanded":[32],"setFocus":[64]},[[4,"themeChange","themeChangeHandler"]]]]],["p-ba8d968c",[[1,"ic-step",{"compactStepStyling":[1,"compact-step-styling"],"current":[1028],"lastStep":[4,"last-step"],"lastStepNum":[2,"last-step-num"],"nextStepTitle":[1,"next-step-title"],"progress":[2],"stepNum":[2,"step-num"],"stepStatus":[1,"step-status"],"stepSubtitle":[1,"step-subtitle"],"stepTitle":[1,"step-title"],"variant":[1],"stepType":[1,"step-type"]},null,{"stepType":["stepTypeChangeHandler"]}]]],["p-14ea9cc7",[[17,"ic-switch",{"checked":[4],"disabled":[4],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"label":[1],"name":[1],"showState":[4,"show-state"],"size":[1],"small":[4],"value":[1],"checkedState":[32],"initiallyChecked":[32],"setFocus":[64]},null,{"checked":["checkedChangeHandler"]}]]],["p-d5cadfa1",[[1,"ic-accordion",{"appearance":[1],"disabled":[4],"expanded":[1028],"heading":[1],"message":[1],"size":[1],"setFocus":[64]},null,{"expanded":["handleExpandedWatch"]}]]],["p-8a77a417",[[17,"ic-back-to-top",{"target":[1],"bannerOffset":[32],"footerVisible":[32],"targetElVisible":[32]},null,{"target":["watchPropHandler"]}]]],["p-22cbe39b",[[17,"ic-badge",{"accessibleLabel":[1,"accessible-label"],"customColor":[1,"custom-color"],"maxNumber":[2,"max-number"],"position":[1],"size":[1],"textLabel":[1,"text-label"],"type":[1],"variant":[1],"visible":[1028],"showBadge":[64],"hideBadge":[64]}]]],["p-cc0ab439",[[17,"ic-checkbox",{"additionalFieldDisplay":[513,"additional-field-display"],"checked":[1540],"disabled":[4],"dynamicText":[1,"dynamic-text"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"groupLabel":[1,"group-label"],"indeterminate":[4],"label":[1],"name":[1],"size":[1],"small":[4],"value":[1],"initiallyChecked":[32],"setFocus":[64]}]]],["p-3cc52cbc",[[1,"ic-classification-banner",{"additionalSelectors":[1,"additional-selectors"],"classification":[1],"country":[1],"inline":[4],"upTo":[4,"up-to"]}]]],["p-7438ab1f",[[1,"ic-data-entity",{"heading":[1],"size":[1],"small":[4]}]]],["p-f026466e",[[1,"ic-data-row",{"label":[1],"size":[1],"small":[4],"value":[1],"deviceSize":[32],"entitySize":[32]}]]],["p-5421ceb4",[[1,"ic-empty-state",{"aligned":[1],"body":[1],"bodyMaxLines":[2,"body-max-lines"],"heading":[1],"imageSize":[1,"image-size"],"subheading":[1]}]]],["p-dfef57d3",[[1,"ic-menu-group",{"label":[1]}]]],["p-2ed0232c",[[17,"ic-navigation-group",{"expandable":[4],"label":[1],"deviceSize":[32],"dropdownOpen":[32],"expanded":[32],"focusStyle":[32],"inTopNavSideMenu":[32],"navigationType":[32],"parentEl":[32],"setFocus":[64]},[[0,"childBlur","childBlurHandler"],[0,"navItemClicked","navItemClickHandler"],[4,"themeChange","themeChangeHandler"]]]]],["p-c1bb5018",[[17,"ic-radio-option",{"additionalFieldDisplay":[513,"additional-field-display"],"disabled":[4],"dynamicText":[1,"dynamic-text"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"groupLabel":[1,"group-label"],"label":[1],"name":[1],"value":[1025],"selected":[1540],"initiallySelected":[32],"setFocus":[64]},[[0,"icChange","textfieldValueHandler"]],{"selected":["watchSelectedHandler"]}]]],["p-8352d752",[[1,"ic-status-tag",{"announced":[4],"appearance":[1],"label":[1],"size":[1],"small":[4],"status":[1],"variant":[1]}]]],["p-ba31ee69",[[1,"ic-tab",{"appearance":[1],"contextId":[513,"context-id"],"disabled":[4],"selected":[516],"tabId":[513,"tab-id"],"tabPosition":[2,"tab-position"],"setFocus":[64]},null,{"disabled":["disabledWatchHandler"]}]]],["p-8cbbe579",[[17,"ic-footer-link",{"download":[8],"href":[1],"hreflang":[1],"referrerpolicy":[1],"rel":[1],"target":[1],"deviceSize":[32],"footerConfig":[32],"foregroundColor":[32]},[[4,"footerResized","footerResizeHandler"],[4,"themeChange","footerThemeChangeHandler"]]]]],["p-7b720034",[[1,"ic-skeleton",{"appearance":[1],"light":[4],"variant":[1],"default":[32],"hasChild":[32],"heightOnly":[32],"widthOnly":[32]}]]],["p-4e3d46f2",[[1,"ic-stepper",{"aligned":[1],"connectorWidth":[2,"connector-width"],"hideStepInfo":[4,"hide-step-info"],"variant":[1025],"alignedFullWidth":[32],"autoSetStepTitles":[32],"lastStepWidth":[32],"noOfResizes":[32],"stepperWidth":[32],"stepTypes":[32],"variantOverride":[32]}]]],["p-cf798ea7",[[4,"ic-tab-context",{"activationType":[1,"activation-type"],"appearance":[1],"contextId":[513,"context-id"],"selectedTabIndex":[2,"selected-tab-index"],"selectedTab":[32],"tabRemovedHandler":[64]},[[0,"tabClick","tabClickHandler"],[0,"tabCreated","tabCreatedHandler"],[0,"tabPanelCreated","tabCreatedHandler"],[0,"tabEnabled","tabEnabledHandler"]],{"selectedTabIndex":["updateSelectedTab"]}]]],["p-fc83d8d7",[[1,"ic-tab-panel",{"appearance":[1],"contextId":[513,"context-id"],"panelId":[513,"panel-id"],"selectedTab":[1,"selected-tab"],"tabPosition":[514,"tab-position"]}]]],["p-917b15da",[[1,"ic-theme",{"color":[1]},null,{"color":["watchColorPropHandler"]}]]],["p-1145e33c",[[4,"ic-toast-region",{"openToast":[1040],"setVisible":[64]},[[2,"icDismiss","handleDismissedToast"]],{"openToast":["watchOpenToastHandler"]}]]],["p-6fae929c",[[1,"ic-toggle-button-group",{"accessibleLabel":[1,"accessible-label"],"appearance":[1],"disabled":[4],"fullWidth":[4,"full-width"],"iconPlacement":[1,"icon-placement"],"loading":[4],"selectMethod":[1025,"select-method"],"selectType":[1,"select-type"],"size":[1],"variant":[513],"lastKeyPressed":[32]},[[0,"icToggleChecked","selectHandler"]]]]],["p-a222554a",[[1,"ic-text-field",{"ariaActiveDescendant":[1,"aria-active-descendant"],"ariaAutocomplete":[1,"aria-autocomplete"],"ariaExpanded":[1,"aria-expanded"],"ariaOwns":[1,"aria-owns"],"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autoFocus":[4,"auto-focus"],"disabled":[4],"fullWidth":[4,"full-width"],"helperText":[1,"helper-text"],"hideLabel":[4,"hide-label"],"hiddenInput":[4,"hidden-input"],"inputId":[1,"input-id"],"inputmode":[1],"label":[1],"max":[8],"maxCharacters":[2,"max-characters"],"maxLength":[2,"max-length"],"min":[8],"minCharacters":[2,"min-characters"],"name":[1],"placeholder":[1],"readonly":[516],"required":[4],"resize":[4],"role":[1],"rows":[2],"size":[1],"small":[4],"spellcheck":[4],"truncateValue":[4,"truncate-value"],"type":[1],"validationInline":[4,"validation-inline"],"validationInlineInternal":[4,"validation-inline-internal"],"validationStatus":[1,"validation-status"],"validationText":[1,"validation-text"],"debounce":[2],"value":[1537],"numChars":[32],"maxCharactersReached":[32],"maxCharactersError":[32],"minCharactersUnattained":[32],"maxLengthExceeded":[32],"maxValueExceeded":[32],"minValueUnattained":[32],"initialValue":[32],"setFocus":[64]},[[0,"keydown","handleKeyDown"]],{"debounce":["debounceChanged"],"value":["watchValueHandler"]}]]],["p-e7483ee5",[[1,"ic-alert",{"announced":[4],"dismissible":[4],"heading":[1],"message":[1],"titleAbove":[4,"title-above"],"variant":[1],"alertTitleWrap":[32],"visible":[32]},[[2,"icDismiss","handleClick"]]]]],["p-f926174d",[[17,"ic-menu-item",{"description":[1],"disabled":[4],"href":[1],"hreflang":[1],"keyboardShortcut":[1,"keyboard-shortcut"],"label":[1],"referrerpolicy":[1],"rel":[1],"submenuTriggerFor":[1,"submenu-trigger-for"],"target":[1],"variant":[1537],"toggleChecked":[32]},[[2,"click","handleHostClick"]]]]],["p-65d3c0f1",[[1,"ic-navigation-menu",{"status":[1],"version":[1]},[[0,"navItemClicked","navItemClickHandler"],[4,"keydown","handleKeyDown"]]]]],["p-c2173562",[[17,"ic-link",{"appearance":[1025],"download":[8],"href":[1],"hreflang":[1],"referrerpolicy":[1],"rel":[1],"showIcon":[4,"show-icon"],"target":[1],"setFocus":[64]},[[4,"themeChange","themeChangeHandler"]]]]],["p-e7b676fc",[[17,"ic-breadcrumb",{"appearance":[1],"current":[4],"href":[1],"pageTitle":[1,"page-title"],"showBackIcon":[516,"show-back-icon"],"setFocus":[64]}]]],["p-934c2a94",[[1,"ic-pagination-item",{"appearance":[1],"ariaOverride":[4,"aria-override"],"disabled":[4],"label":[1],"page":[2],"pages":[2],"selected":[4],"type":[1]}]]],["p-c0525936",[[2,"ic-divider",{"foregroundColor":[32]},[[4,"themeChange","themeChangeHandler"]]]]],["p-e47f887a",[[1,"ic-horizontal-scroll",{"appearance":[1],"focusTrigger":[1,"focus-trigger"],"firstItemVisible":[32],"itemOverflow":[32],"lastItemVisible":[32],"scrollItemIntoView":[64]}]]],["p-e9723eaa",[[1,"ic-section-container",{"aligned":[1],"fullHeight":[4,"full-height"]}]]],["p-563c2522",[[2,"ic-menu",{"activationType":[1,"activation-type"],"anchorEl":[16],"autoFocusOnSelected":[4,"auto-focus-on-selected"],"fullWidth":[4,"full-width"],"inputEl":[16],"inputLabel":[1,"input-label"],"labelField":[1,"label-field"],"menuId":[1,"menu-id"],"open":[516],"parentEl":[16],"searchMode":[1,"search-mode"],"selectOnEnter":[4,"select-on-enter"],"size":[1],"small":[4],"options":[16],"value":[1025],"valueField":[1,"value-field"],"focusFromSearchKeypress":[32],"initialOptionsListRender":[32],"keyboardNav":[32],"optionHighlighted":[32],"preventIncorrectTabOrder":[32],"handleClickOpen":[64],"handleKeyboardOpen":[64],"handleSetFirstOption":[64],"initPopperJs":[64]},null,{"open":["watchOpenHandler"],"options":["watchOptionsHandler"],"value":["watchValueHandler"]}],[4,"ic-input-component-container",{"appearance":[1],"dark":[4],"disabled":[4],"fullWidth":[4,"full-width"],"multiLine":[4,"multi-line"],"readonly":[4],"size":[1],"small":[4],"validationInline":[4,"validation-inline"],"validationStatus":[1,"validation-status"]}],[4,"ic-input-container",{"disabled":[4],"readonly":[4]}]]],["p-9c157974",[[4,"ic-input-validation",{"ariaLiveMode":[1,"aria-live-mode"],"for":[1],"fullWidth":[4,"full-width"],"message":[1],"status":[1]}],[0,"ic-input-label",{"appearance":[1],"dark":[4],"disabled":[4],"error":[4],"for":[1],"helperText":[1,"helper-text"],"label":[1],"readonly":[4],"required":[4]}]]],["p-2e3845be",[[17,"ic-button",{"accept":[1],"appearance":[1025],"ariaControlsId":[8,"aria-controls-id"],"ariaOwnsId":[8,"aria-owns-id"],"disabled":[4],"disableTooltip":[4,"disable-tooltip"],"download":[8],"dropdown":[4],"dropdownExpanded":[1540,"dropdown-expanded"],"fileUpload":[4,"file-upload"],"fileInputName":[1,"file-input-name"],"form":[1],"formaction":[1],"formenctype":[1],"formmethod":[1],"formnovalidate":[4],"formtarget":[1],"fullWidth":[4,"full-width"],"href":[1],"hreflang":[1],"loading":[4],"multiple":[4],"referrerpolicy":[1],"rel":[1],"selectedFiles":[16],"size":[1],"target":[1],"tooltipPlacement":[1,"tooltip-placement"],"transparentBackground":[4,"transparent-background"],"type":[1],"variant":[1],"ariaLabel":[32],"describedByContent":[32],"title":[32],"setFocus":[64]},[[2,"click","handleHostClick"],[4,"themeChange","themeChangeHandler"]],{"disabled":["watchDisabledHandler"]}],[1,"ic-loading-indicator",{"appearance":[1],"description":[1],"fullWidth":[516,"full-width"],"innerLabel":[2,"inner-label"],"labelDuration":[2,"label-duration"],"max":[2],"min":[2],"size":[513],"type":[513],"label":[1],"progress":[2],"circularDiameter":[32],"circularLineWidth":[32],"indeterminate":[32],"indicatorLabel":[32],"showSecond":[32]},null,{"label":["watchPropHandler"],"progress":["watchProgressHandler"]}],[1,"ic-tooltip",{"disableClick":[4,"disable-click"],"disableHover":[4,"disable-hover"],"maxLines":[2,"max-lines"],"placement":[1025],"silent":[4],"target":[513],"label":[1],"displayTooltip":[64]}]]]]'),e)));
|
2
2
|
//# sourceMappingURL=core.esm.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","options","bootstrapLazy","JSON","parse"],"sources":["node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.10.0 | MIT Licensed | https://stenciljs.com\n */\nimport { BUILD, NAMESPACE } from '@stencil/core/internal/app-data';\nimport { consoleDevInfo, doc, promiseResolve, H } from '@stencil/core';\nconst patchBrowser = () => {\n // NOTE!! This fn cannot use async/await!\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo('Running in development mode.');\n }\n if (BUILD.cloneNodeFix) {\n // opted-in to polyfill cloneNode() for slot polyfilled components\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts\n ? Array.from(doc.querySelectorAll('script')).find((s) => new RegExp(`\\/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) ||\n s.getAttribute('data-stencil-namespace') === NAMESPACE)\n : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})['data-opts'] || {} : {};\n if (importMeta !== '') {\n opts.resourcesUrl = new URL('.', importMeta).href;\n }\n return promiseResolve(opts);\n};\nconst patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function (deep) {\n if (this.nodeName === 'TEMPLATE') {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n // Node.ATTRIBUTE_NODE === 2, and checking because IE11\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport { patchBrowser };\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(options => {\n globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"sFAKA,MAAMA,EAAe,KAajB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAC3E,GAAIF,IAAe,GAAI,CACnBE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IACrD,CACI,OAAOC,EAAeJ,EAAK,ECnB/BH,IAAeQ,MAAKC,GAEXC,EAAcC,KAAAC,MAAA,
|
1
|
+
{"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","options","bootstrapLazy","JSON","parse"],"sources":["node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.10.0 | MIT Licensed | https://stenciljs.com\n */\nimport { BUILD, NAMESPACE } from '@stencil/core/internal/app-data';\nimport { consoleDevInfo, doc, promiseResolve, H } from '@stencil/core';\nconst patchBrowser = () => {\n // NOTE!! This fn cannot use async/await!\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo('Running in development mode.');\n }\n if (BUILD.cloneNodeFix) {\n // opted-in to polyfill cloneNode() for slot polyfilled components\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts\n ? Array.from(doc.querySelectorAll('script')).find((s) => new RegExp(`\\/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) ||\n s.getAttribute('data-stencil-namespace') === NAMESPACE)\n : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})['data-opts'] || {} : {};\n if (importMeta !== '') {\n opts.resourcesUrl = new URL('.', importMeta).href;\n }\n return promiseResolve(opts);\n};\nconst patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function (deep) {\n if (this.nodeName === 'TEMPLATE') {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n // Node.ATTRIBUTE_NODE === 2, and checking because IE11\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport { patchBrowser };\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(options => {\n globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"sFAKA,MAAMA,EAAe,KAajB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAC3E,GAAIF,IAAe,GAAI,CACnBE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IACrD,CACI,OAAOC,EAAeJ,EAAK,ECnB/BH,IAAeQ,MAAKC,GAEXC,EAAcC,KAAAC,MAAA,gprBAAuCH"}
|
@@ -0,0 +1,2 @@
|
|
1
|
+
import{r as t,c as i,h as e,H as a,g as n}from"./p-6b5e91e2.js";import{I as o}from"./p-26b7b18f.js";import{L as s,e as r,D as l,u as c,o as h,i as d,f as p,a as m,G as u,d as b}from"./p-268355c1.js";const g='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;color:var(--ic-theme-text);width:100%;position:relative}:host .top-navigation{background-color:var(--ic-theme-primary);height:-moz-max-content;height:max-content}:host(.fullwidth-searchbar) slot[name="search"]::slotted(form){width:100%}:host .title-link{display:inline-flex;align-items:center;text-decoration:none;padding:var(--ic-space-xxs);transition:var(--ic-easing-transition-fast)}:host .title-link,:host .title-link:visited,:host .title-link:active,:host .title-link ::slotted(a),:host .title-link:visited ::slotted(a),:host .title-link:active ::slotted(a){color:var(--ic-theme-text);text-decoration:none;outline:none}:host .title-link:hover:not(:focus){background-color:var(--ic-theme-hover)}:host .title-link:active:not(:focus){background-color:var(--ic-theme-active)}:host .title-link:hover{border-radius:var(--ic-border-radius)}:host .title-link:focus,:host .title-link:focus-within{border-radius:var(--ic-border-radius);box-shadow:var(--ic-border-focus);outline:var(--ic-hc-focus-outline)}:host .title-link ic-typography{font-weight:600}:host .nav-panel-container{border-top:var(--ic-keyline-lighten);padding:0 var(--ic-space-lg);margin-left:calc(-1 * var(--section-container-margin));margin-right:calc(-1 * var(--section-container-margin));display:flex}:host(.dark) .nav-panel-container{border-top:var(--ic-keyline-darken)}.top-panel-container{display:flex;padding-top:0.5rem;padding-bottom:0.5rem}.navigation-tabs{margin-top:calc(-1 * var(--ic-space-1px))}.app-details-container{display:flex;align-items:center;flex:1 1 auto;margin-right:var(--ic-space-md)}.app-icon-container{display:flex;padding-right:var(--ic-space-xs)}.icon-buttons-container{display:flex;margin-left:var(--ic-space-md)}.icon-buttons-container ::slotted(nav){display:flex}.title-wrap{overflow-wrap:break-word;word-wrap:break-word;-ms-word-break:break-all;word-break:break-word;-webkit-hyphens:auto;hyphens:auto}:host .app-status{border-radius:var(--ic-space-md);background-color:var(--ic-architectural-white);color:var(--ic-color-primary-text);padding:var(--ic-space-xxs) var(--ic-space-lg);margin-left:var(--ic-space-md);flex:1 1 0;max-width:-moz-fit-content;max-width:fit-content}:host(.dark) .app-status{background-color:var(--ic-theme-text);color:var(--ic-color-white-text)}:host .app-version{border-radius:var(--ic-space-md);background-color:var(--ic-theme-active);padding:var(--ic-space-xxs) var(--ic-space-sm);margin-left:var(--ic-space-xs);flex:1 1 0;max-width:-moz-fit-content;max-width:fit-content}slot[name="app-icon"]::slotted(*){fill:var(--ic-theme-text);width:2em;height:2em}slot[name="toggle-icon"] svg{fill:var(--ic-theme-text)}.search-menu-container{justify-content:right;display:flex;align-items:center}.menu-button-container{margin-left:var(--ic-space-md)}.menu-button-container .navigation-landmark-button-text{position:absolute;left:-10000px;top:auto;width:1px;height:1px;overflow:hidden}.search-actions-container{display:flex}.menu-buttons-slot{display:flex;flex-direction:column}.navigation-landmark-text{position:absolute;width:var(--ic-space-1px);height:var(--ic-space-1px);padding:0;margin:calc(-1 * var(--ic-space-1px));overflow:hidden}.navigation-item-list{display:flex;list-style:none;height:2.75rem}.navigation-item-list::-webkit-scrollbar{display:none}:host ic-section-container{padding-bottom:0 !important;padding-top:0 !important}@media screen and (min-width: 993px){.app-details-container{margin-right:var(--ic-space-lg)}}@media screen and (max-width: 1200px){:host .nav-panel-container{padding:0 var(--ic-space-md)}}:host(.mobile-mode) .app-status,:host(.mobile-mode) .app-version{display:none}:host(.mobile-mode) .title-link{margin-right:var(--ic-space-xs)}:host(.mobile-mode) .search-menu-container{max-width:10rem}:host(.mobile-mode) .search-bar-container{display:flex;justify-content:center;align-items:center;border-top:var(--ic-keyline-darken);height:4rem;padding-left:var(--ic-space-md);padding-right:var(--ic-space-md);margin-left:calc(-1 * var(--section-container-margin));margin-right:calc(-1 * var(--section-container-margin))}@media screen and (max-width: 576px){:host .title-link{margin-right:var(--ic-space-xxxs);word-break:break-word;-webkit-hyphens:none;hyphens:none}.top-panel-container{min-height:2.5rem}.search-bar-container{margin-top:0;height:3.5rem;padding-left:var(--ic-space-xs);padding-right:var(--ic-space-xs)}.menu-button-container{margin-left:var(--ic-space-sm)}slot[name="app-icon"]::slotted(*){width:1.5em;height:1.5em}slot[name="toggle-icon"] svg{width:1.5em;height:1.5em}}@media (forced-colors: active){:host .top-navigation{border-bottom:var(--ic-hc-border)}.app-status,.app-version{border:var(--ic-hc-border)}slot[name="app-icon"]::slotted(*){fill:currentcolor}}';const v=class{constructor(e){t(this,e);this.icNavigationMenuClosed=i(this,"icNavigationMenuClosed",7);this.icNavigationMenuOpened=i(this,"icNavigationMenuOpened",7);this.topNavResized=i(this,"topNavResized",7);this.hasAppIcon=false;this.hasIconButtons=false;this.hasNavigation=false;this.hasSearchSlotContent=false;this.resizeObserver=null;this.searchBar=null;this.initialiseSearchBar=()=>{if(this.hasSearchSlotContent){const t=s(this.el,"search");if((t===null||t===void 0?void 0:t.tagName)==="IC-SEARCH-BAR"){this.searchBar=t}else if((t===null||t===void 0?void 0:t.tagName)==="FORM"){this.searchBar=t.querySelector("ic-search-bar")}if(this.searchBar!==null){this.searchBar.hideLabel=true}}};this.menuButtonClick=()=>{this.showNavMenu(true)};this.searchButtonMouseDownHandler=()=>{this.searchButtonClick=true};this.searchButtonClickHandler=()=>{this.toggleSearchBar();this.searchButtonClick=false};this.resizeObserverCallback=t=>{var i;if(t!==this.deviceSize){this.deviceSize=t;if(t>this.customMobileBreakpoint){this.showNavMenu(false);if(this.mobileSearchBarVisible){this.toggleSearchBar()}}this.topNavResized.emit({size:t});if(((i=document.activeElement)===null||i===void 0?void 0:i.tagName)==="IC-SEARCH-BAR"){this.searchBar.setAttribute("hidden","true");this.searchBar.removeAttribute("hidden");setTimeout((()=>{this.searchBar.focus()}),100)}}};this.runResizeObserver=()=>{this.resizeObserver=new ResizeObserver((()=>{this.resizeObserverCallback(r())}));this.resizeObserver.observe(this.el)};this.deviceSize=l.XL;this.foregroundColor=c();this.hasFullWidthSearchBar=false;this.mobileSearchBarVisible=false;this.mobileSearchHiddenOnBlur=false;this.navMenuVisible=false;this.searchButtonClick=false;this.searchValue="";this.contentAligned="full-width";this.customMobileBreakpoint=l.L;this.href="/";this.inline=false;this.shortAppTitle="";this.status="";this.version="";this.appTitle=undefined}watchPropHandler(t,i){h(i,t,this.initialiseSearchBar)}disconnectedCallback(){if(this.resizeObserver!==null){this.resizeObserver.disconnect()}}componentWillLoad(){this.hasAppIcon=d(this.el,"app-icon");this.hasNavigation=d(this.el,"navigation");this.hasIconButtons=d(this.el,"buttons");this.hasSearchSlotContent=d(this.el,"search");this.deviceSize=r();this.initialiseSearchBar()}componentDidLoad(){p(this.runResizeObserver);!d(this.el,"app-title")&&m([{prop:this.appTitle,propName:"app-title"}],"Top Navigation")}componentWillRender(){this.hasNavigation=d(this.el,"navigation");this.hasSearchSlotContent=d(this.el,"search");this.hasIconButtons=d(this.el,"buttons");this.hasAppIcon=d(this.el,"app-icon")}navBarMenuCloseHandler(){this.showNavMenu(false);this.el.shadowRoot.querySelector("#menu-button").focus()}searchInputBlurHandler({detail:t}){if(t!==null){if(this.mobileSearchBarVisible&&!this.searchButtonClick){this.toggleSearchBar()}this.searchValue=t.value}}searchValueChangeHandler({detail:t}){this.searchValue=t.value}themeChangeHandler({detail:t}){this.foregroundColor=t.mode}toggleSearchBar(){this.mobileSearchBarVisible=!this.mobileSearchBarVisible;if(this.searchBar!==null){this.mobileSearchButtonEl.setAttribute("aria-label",`${this.mobileSearchBarVisible?"Hide":"Show"} search`);this.hasFullWidthSearchBar=this.mobileSearchBarVisible;this.searchBar.fullWidth=this.mobileSearchBarVisible;if(this.mobileSearchBarVisible){setTimeout((()=>{this.searchBar.focus()}),100)}}}showNavMenu(t){this.navMenuVisible=t;if(t){this.icNavigationMenuOpened.emit();document.body.style.height="100%";document.body.style.overflow="hidden"}else{this.icNavigationMenuClosed.emit();document.body.style.height="auto";document.body.style.overflow="auto"}}render(){const{appTitle:t,contentAligned:i,customMobileBreakpoint:n,deviceSize:s,el:r,foregroundColor:c,hasAppIcon:h,hasFullWidthSearchBar:p,hasIconButtons:m,hasNavigation:g,hasSearchSlotContent:v,href:f,inline:x,menuButtonClick:w,mobileSearchBarVisible:k,navMenuVisible:y,searchButtonClickHandler:z,searchButtonMouseDownHandler:H,shortAppTitle:C,status:M,version:B}=this;const S=M!=="";const j=B!=="";const R=g||m||S||j;const T=s<=l.S?"default":"large";const A=t!==""&&b(t);const I=s<=n;const N=I?s<=l.S?"subtitle-small":"h4":"h3";const V=`${k?"Hide":"Show"} search`;const $=s<=l.S?"small":"default";const L=d(r,"short-app-title");const O=d(r,"app-title");const D=O?"div":"a";const W=D=="a"&&{href:f};return e(a,{class:{"fullwidth-searchbar":p,"mobile-mode":I,[o.Dark]:c===o.Dark}},e("div",{class:"top-navigation"},e("ic-section-container",{aligned:i,"full-height":true},e("header",{role:"banner"},e("div",{class:"top-panel-container"},e("div",{class:"app-details-container"},(A||O)&&e(D,Object.assign({class:"title-link"},W),h&&e("div",{class:"app-icon-container"},e("slot",{name:"app-icon"})),s<=l.S&&(!u(C)||L)?e("ic-typography",{variant:"subtitle-small","aria-label":(!O||!L)&&`${t} (${C})`},e("h1",null,L?e("slot",{name:"short-app-title"}):C)):e("ic-typography",{variant:N},e("h1",{class:"title-wrap"},O?e("slot",{name:"app-title"}):t))),S&&e("div",{class:"app-status"},e("ic-typography",{"aria-label":"app tag",variant:"label-uppercase",class:"app-status-text"},M)),j&&e("div",{class:"app-version"},e("ic-typography",{variant:"label",class:"app-version-text","aria-label":"app version"},B))),(v||R)&&e("div",{class:"search-menu-container"},e("div",{class:"search-actions-container"},!I&&e("slot",{name:"search"}),v&&I&&e("ic-button",{id:"search-toggle-button",ref:t=>this.mobileSearchButtonEl=t,onMouseDown:H,variant:"icon",size:T,"aria-label":V,appearance:c,onClick:z},e("slot",{name:"toggle-icon"},e("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"#ffffff"},e("path",{d:"M0 0h24v24H0V0z",fill:"none"}),e("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"})))),m&&!I&&e("div",{class:"icon-buttons-container"},e("slot",{name:"buttons"})),R&&I&&e("div",{class:"menu-button-container"},e("span",{id:"navigation-landmark-button-text",class:"navigation-landmark-button-text","aria-hidden":"true"},"Main navigation button"),e("nav",{"aria-labelledby":"navigation-landmark-button-text","aria-hidden":`${y}`},e("ic-button",{id:"menu-button",appearance:c,variant:"secondary","aria-expanded":"false","aria-haspopup":"true","aria-label":`Open ${g?"navigation":"app"} menu`,size:$,onClick:w},"Menu",e("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24px",viewBox:"0 0 24 24",width:"24px",fill:"#ffffff",slot:"icon"},e("path",{d:"M0 0h24v24H0V0z",fill:"none"}),e("path",{d:"M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"})))))))),k&&e("div",{class:"search-bar-container"},e("slot",{name:"search"})),g&&!I&&e("div",{class:"navigation-tabs"},e("span",{id:"navigation-landmark-text",class:"navigation-landmark-text","aria-hidden":"true"},"Main pages"),e("nav",{"aria-labelledby":"navigation-landmark-text",class:"nav-panel-container"},e("ic-horizontal-scroll",{appearance:c},e("ul",{class:"navigation-item-list",tabindex:"-1"},e("slot",{name:"navigation"})))))))),y&&e("ic-navigation-menu",{version:B,status:M,class:{["inline"]:x}},m&&e("div",{class:"menu-buttons-slot",slot:"buttons"},e("slot",{name:"buttons"})),e("ul",{slot:"navigation"},e("slot",{name:"navigation"}))))}get el(){return n(this)}static get watchers(){return{appTitle:["watchPropHandler"]}}};v.style=g;export{v as ic_top_navigation};
|
2
|
+
//# sourceMappingURL=p-2436d4bd.entry.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["icTopNavigationCss","TopNavigation","this","hasAppIcon","hasIconButtons","hasNavigation","hasSearchSlotContent","resizeObserver","searchBar","initialiseSearchBar","slot","getSlot","el","tagName","querySelector","hideLabel","menuButtonClick","showNavMenu","searchButtonMouseDownHandler","searchButtonClick","searchButtonClickHandler","toggleSearchBar","resizeObserverCallback","currSize","deviceSize","customMobileBreakpoint","mobileSearchBarVisible","topNavResized","emit","size","_a","document","activeElement","setAttribute","removeAttribute","setTimeout","focus","runResizeObserver","ResizeObserver","getCurrentDeviceSize","observe","DEVICE_SIZES","XL","getThemeForegroundColor","L","watchPropHandler","newValue","oldValue","onComponentPropUndefinedChange","disconnectedCallback","disconnect","componentWillLoad","isSlotUsed","componentDidLoad","checkResizeObserver","onComponentRequiredPropUndefined","prop","appTitle","propName","componentWillRender","navBarMenuCloseHandler","shadowRoot","searchInputBlurHandler","detail","searchValue","value","searchValueChangeHandler","themeChangeHandler","foregroundColor","mode","mobileSearchButtonEl","hasFullWidthSearchBar","fullWidth","show","navMenuVisible","icNavigationMenuOpened","body","style","height","overflow","icNavigationMenuClosed","render","contentAligned","href","inline","shortAppTitle","status","version","hasStatus","hasVersion","hasMenuContent","searchButtonSize","S","hasTitle","isPropDefined","overMobileBreakpoint","appTitleVariant","mobileSearchButtonTitle","menuSize","shortAppTitleSlot","hasAppTitleSlot","Component","attrs","h","Host","class","IcThemeForegroundEnum","Dark","aligned","role","Object","assign","name","isEmptyString","variant","id","ref","onMouseDown","appearance","onClick","xmlns","viewBox","fill","d","width","tabindex"],"sources":["src/components/ic-top-navigation/ic-top-navigation.css?tag=ic-top-navigation&encapsulation=shadow","src/components/ic-top-navigation/ic-top-navigation.tsx"],"sourcesContent":["@import \"../../global/normalize.css\";\n\n:host {\n display: block;\n color: var(--ic-theme-text);\n width: 100%;\n position: relative;\n}\n\n:host .top-navigation {\n background-color: var(--ic-theme-primary);\n height: max-content;\n}\n\n:host(.fullwidth-searchbar) slot[name=\"search\"]::slotted(form) {\n width: 100%;\n}\n\n:host .title-link {\n display: inline-flex;\n align-items: center;\n text-decoration: none;\n padding: var(--ic-space-xxs);\n transition: var(--ic-easing-transition-fast);\n}\n\n:host .title-link,\n:host .title-link:visited,\n:host .title-link:active,\n:host .title-link ::slotted(a),\n:host .title-link:visited ::slotted(a),\n:host .title-link:active ::slotted(a) {\n color: var(--ic-theme-text);\n text-decoration: none;\n outline: none;\n}\n\n:host .title-link:hover:not(:focus) {\n background-color: var(--ic-theme-hover);\n}\n\n:host .title-link:active:not(:focus) {\n background-color: var(--ic-theme-active);\n}\n\n:host .title-link:hover {\n border-radius: var(--ic-border-radius);\n}\n\n:host .title-link:focus,\n:host .title-link:focus-within {\n border-radius: var(--ic-border-radius);\n box-shadow: var(--ic-border-focus);\n outline: var(--ic-hc-focus-outline);\n}\n\n:host .title-link ic-typography {\n font-weight: 600;\n}\n\n:host .nav-panel-container {\n border-top: var(--ic-keyline-lighten);\n padding: 0 var(--ic-space-lg);\n margin-left: calc(-1 * var(--section-container-margin));\n margin-right: calc(-1 * var(--section-container-margin));\n display: flex;\n}\n\n:host(.dark) .nav-panel-container {\n border-top: var(--ic-keyline-darken);\n}\n\n.top-panel-container {\n display: flex;\n padding-top: 0.5rem;\n padding-bottom: 0.5rem;\n}\n\n.navigation-tabs {\n margin-top: calc(-1 * var(--ic-space-1px));\n}\n\n.app-details-container {\n display: flex;\n align-items: center;\n flex: 1 1 auto;\n margin-right: var(--ic-space-md);\n}\n\n.app-icon-container {\n display: flex;\n padding-right: var(--ic-space-xs);\n}\n\n.icon-buttons-container {\n display: flex;\n margin-left: var(--ic-space-md);\n}\n\n.icon-buttons-container ::slotted(nav) {\n display: flex;\n}\n\n.title-wrap {\n overflow-wrap: break-word;\n word-wrap: break-word;\n -ms-word-break: break-all;\n word-break: break-word;\n hyphens: auto;\n}\n\n:host .app-status {\n border-radius: var(--ic-space-md);\n background-color: var(--ic-architectural-white);\n color: var(--ic-color-primary-text);\n padding: var(--ic-space-xxs) var(--ic-space-lg);\n margin-left: var(--ic-space-md);\n flex: 1 1 0;\n max-width: fit-content;\n}\n\n:host(.dark) .app-status {\n background-color: var(--ic-theme-text);\n color: var(--ic-color-white-text);\n}\n\n:host .app-version {\n border-radius: var(--ic-space-md);\n background-color: var(--ic-theme-active);\n padding: var(--ic-space-xxs) var(--ic-space-sm);\n margin-left: var(--ic-space-xs);\n flex: 1 1 0;\n max-width: fit-content;\n}\n\nslot[name=\"app-icon\"]::slotted(*) {\n fill: var(--ic-theme-text);\n width: 2em;\n height: 2em;\n}\n\nslot[name=\"toggle-icon\"] svg {\n fill: var(--ic-theme-text);\n}\n\n.search-menu-container {\n justify-content: right;\n display: flex;\n align-items: center;\n}\n\n.menu-button-container {\n margin-left: var(--ic-space-md);\n}\n\n.menu-button-container .navigation-landmark-button-text {\n position: absolute;\n left: -10000px;\n top: auto;\n width: 1px;\n height: 1px;\n overflow: hidden;\n}\n\n.search-actions-container {\n display: flex;\n}\n\n.menu-buttons-slot {\n display: flex;\n flex-direction: column;\n}\n\n.navigation-landmark-text {\n position: absolute;\n width: var(--ic-space-1px);\n height: var(--ic-space-1px);\n padding: 0;\n margin: calc(-1 * var(--ic-space-1px));\n overflow: hidden;\n}\n\n.navigation-item-list {\n display: flex;\n list-style: none;\n height: 2.75rem;\n}\n\n.navigation-item-list::-webkit-scrollbar {\n display: none;\n}\n\n:host ic-section-container {\n padding-bottom: 0 !important;\n padding-top: 0 !important;\n}\n\n@media screen and (min-width: 993px) {\n .app-details-container {\n margin-right: var(--ic-space-lg);\n }\n}\n\n/* large */\n@media screen and (max-width: 1200px) {\n :host .nav-panel-container {\n padding: 0 var(--ic-space-md);\n }\n}\n\n/** Mobile styling **/\n:host(.mobile-mode) .app-status,\n:host(.mobile-mode) .app-version {\n display: none;\n}\n\n:host(.mobile-mode) .title-link {\n margin-right: var(--ic-space-xs);\n}\n\n:host(.mobile-mode) .search-menu-container {\n max-width: 10rem;\n}\n\n:host(.mobile-mode) .search-bar-container {\n display: flex;\n justify-content: center;\n align-items: center;\n border-top: var(--ic-keyline-darken);\n height: 4rem;\n padding-left: var(--ic-space-md);\n padding-right: var(--ic-space-md);\n margin-left: calc(-1 * var(--section-container-margin));\n margin-right: calc(-1 * var(--section-container-margin));\n}\n\n/* x small */\n@media screen and (max-width: 576px) {\n :host .title-link {\n margin-right: var(--ic-space-xxxs);\n word-break: break-word;\n hyphens: none;\n }\n\n .top-panel-container {\n min-height: 2.5rem;\n }\n\n .search-bar-container {\n margin-top: 0;\n height: 3.5rem;\n padding-left: var(--ic-space-xs);\n padding-right: var(--ic-space-xs);\n }\n\n .menu-button-container {\n margin-left: var(--ic-space-sm);\n }\n\n slot[name=\"app-icon\"]::slotted(*) {\n width: 1.5em;\n height: 1.5em;\n }\n\n slot[name=\"toggle-icon\"] svg {\n width: 1.5em;\n height: 1.5em;\n }\n}\n\n@media (forced-colors: active) {\n :host .top-navigation {\n border-bottom: var(--ic-hc-border);\n }\n\n .app-status,\n .app-version {\n border: var(--ic-hc-border);\n }\n\n slot[name=\"app-icon\"]::slotted(*) {\n fill: currentcolor;\n }\n}\n","import {\n Component,\n Element,\n Host,\n Prop,\n h,\n State,\n Listen,\n Event,\n EventEmitter,\n Watch,\n} from \"@stencil/core\";\n\nimport {\n IcTypographyVariants,\n IcAlignment,\n IcThemeForeground,\n IcThemeForegroundEnum,\n IcTheme,\n IcDeviceSizes,\n IcValueEventDetail,\n} from \"../../utils/types\";\nimport {\n checkResizeObserver,\n DEVICE_SIZES,\n getCurrentDeviceSize,\n getThemeForegroundColor,\n getSlot,\n onComponentPropUndefinedChange,\n onComponentRequiredPropUndefined,\n isSlotUsed,\n isEmptyString,\n isPropDefined,\n} from \"../../utils/helpers\";\nimport { IcSearchBarBlurEventDetail } from \"../ic-search-bar/ic-search-bar.types\";\n\n/**\n * @slot app-icon - Content will be rendered to left of app title.\n * @slot app-title - Handle routing by nesting a route in the app title.\n * @slot short-app-title - Handle routing by nesting a route in the short app title (to be displayed in place of app title on small screen sizes).\n * @slot search - Content will be rendered in search area to left of buttons.\n * @slot toggle-icon - Icon to be displayed on the button to toggle search slot content on smaller devices\n * @slot navigation - Content will be rendered in navigation panel.\n * @slot buttons - Content will be rendered to right of search bar.\n */\n@Component({\n tag: \"ic-top-navigation\",\n styleUrl: \"ic-top-navigation.css\",\n shadow: true,\n})\nexport class TopNavigation {\n private hasAppIcon: boolean = false;\n private hasIconButtons: boolean = false;\n private hasNavigation: boolean = false;\n private hasSearchSlotContent: boolean = false;\n private mobileSearchButtonEl: HTMLIcButtonElement;\n private resizeObserver: ResizeObserver = null;\n private searchBar: HTMLIcSearchBarElement = null;\n\n @Element() el: HTMLIcTopNavigationElement;\n\n @State() deviceSize: number = DEVICE_SIZES.XL;\n @State() foregroundColor: IcThemeForeground = getThemeForegroundColor();\n @State() hasFullWidthSearchBar: boolean = false;\n @State() mobileSearchBarVisible: boolean = false;\n @State() mobileSearchHiddenOnBlur: boolean = false;\n @State() navMenuVisible: boolean = false;\n @State() searchButtonClick: boolean = false;\n @State() searchValue: string = \"\";\n\n /**\n * The alignment of the top navigation content.\n */\n @Prop() contentAligned: IcAlignment = \"full-width\";\n /**\n * Can set a custom breakpoint for the top navigation to switch to mobile mode.\n * Must be one of our specified breakpoints in px: `0`, `576`, `768`, `992`, `1200`.\n */\n @Prop() customMobileBreakpoint: IcDeviceSizes = DEVICE_SIZES.L;\n /**\n * The URL to navigate to when the app title is clicked.\n */\n @Prop() href: string = \"/\";\n\n /**\n * If `true`, the flyout navigation menu on small devices will be contained by the parent element.\n */\n @Prop() inline: boolean = false;\n\n /**\n * The short title of the app to be displayed at small screen sizes in place of the app title.\n */\n @Prop() shortAppTitle: string = \"\";\n\n /**\n * The status info to be displayed.\n */\n @Prop() status: string = \"\";\n\n /**\n * The version info to be displayed.\n */\n @Prop() version: string = \"\";\n\n /**\n * The app title to be displayed. This is required, unless a slotted app title link is used.\n */\n @Prop() appTitle: string;\n\n @Watch(\"appTitle\")\n watchPropHandler(newValue: string, oldValue: string): void {\n //added for gatsby rehydration issue where prop is initially undefined but then changes to actual value\n //this watch can be removed once gatbsy hydration issue is resolved\n onComponentPropUndefinedChange(\n oldValue,\n newValue,\n this.initialiseSearchBar\n );\n }\n\n /**\n * @internal - Emitted when the menu is closed.\n */\n @Event() icNavigationMenuClosed: EventEmitter<void>;\n\n /**\n * @internal - Emitted when the menu is opened.\n */\n @Event() icNavigationMenuOpened: EventEmitter<void>;\n\n /**\n * Emitted when the top navigation is resized.\n */\n @Event() topNavResized: EventEmitter<{ size: number }>;\n\n disconnectedCallback(): void {\n if (this.resizeObserver !== null) {\n this.resizeObserver.disconnect();\n }\n }\n\n componentWillLoad(): void {\n this.hasAppIcon = isSlotUsed(this.el, \"app-icon\");\n this.hasNavigation = isSlotUsed(this.el, \"navigation\");\n this.hasIconButtons = isSlotUsed(this.el, \"buttons\");\n this.hasSearchSlotContent = isSlotUsed(this.el, \"search\");\n this.deviceSize = getCurrentDeviceSize();\n this.initialiseSearchBar();\n }\n\n componentDidLoad(): void {\n checkResizeObserver(this.runResizeObserver);\n !isSlotUsed(this.el, \"app-title\") &&\n onComponentRequiredPropUndefined(\n [{ prop: this.appTitle, propName: \"app-title\" }],\n \"Top Navigation\"\n );\n }\n\n componentWillRender(): void {\n this.hasNavigation = isSlotUsed(this.el, \"navigation\");\n this.hasSearchSlotContent = isSlotUsed(this.el, \"search\");\n this.hasIconButtons = isSlotUsed(this.el, \"buttons\");\n this.hasAppIcon = isSlotUsed(this.el, \"app-icon\");\n }\n\n @Listen(\"icNavigationMenuClose\", {})\n navBarMenuCloseHandler(): void {\n this.showNavMenu(false);\n this.el.shadowRoot.querySelector<HTMLElement>(\"#menu-button\").focus();\n }\n\n @Listen(\"icSearchBarBlur\", {})\n searchInputBlurHandler({\n detail,\n }: CustomEvent<IcSearchBarBlurEventDetail>): void {\n if (detail !== null) {\n if (this.mobileSearchBarVisible && !this.searchButtonClick) {\n //don't hide if blur was triggered by click on search button - let the click handler toggle the state\n this.toggleSearchBar();\n }\n this.searchValue = detail.value;\n }\n }\n\n @Listen(\"icChange\", {})\n searchValueChangeHandler({ detail }: CustomEvent<IcValueEventDetail>): void {\n this.searchValue = detail.value;\n }\n\n @Listen(\"themeChange\", { target: \"document\" })\n themeChangeHandler({ detail }: CustomEvent<IcTheme>): void {\n this.foregroundColor = detail.mode;\n }\n\n private initialiseSearchBar = () => {\n if (this.hasSearchSlotContent) {\n const slot = getSlot(this.el, \"search\");\n if (slot?.tagName === \"IC-SEARCH-BAR\") {\n this.searchBar = slot as HTMLIcSearchBarElement;\n } else if (slot?.tagName === \"FORM\") {\n this.searchBar = slot.querySelector(\"ic-search-bar\");\n }\n\n if (this.searchBar !== null) {\n this.searchBar.hideLabel = true;\n }\n }\n };\n\n private toggleSearchBar(): void {\n this.mobileSearchBarVisible = !this.mobileSearchBarVisible;\n\n if (this.searchBar !== null) {\n this.mobileSearchButtonEl.setAttribute(\n \"aria-label\",\n `${this.mobileSearchBarVisible ? \"Hide\" : \"Show\"} search`\n );\n this.hasFullWidthSearchBar = this.mobileSearchBarVisible;\n this.searchBar.fullWidth = this.mobileSearchBarVisible;\n if (this.mobileSearchBarVisible) {\n setTimeout(() => {\n this.searchBar.focus();\n }, 100);\n }\n }\n }\n\n private menuButtonClick = () => {\n this.showNavMenu(true);\n };\n\n private showNavMenu(show: boolean): void {\n this.navMenuVisible = show;\n if (show) {\n this.icNavigationMenuOpened.emit();\n document.body.style.height = \"100%\";\n document.body.style.overflow = \"hidden\";\n } else {\n this.icNavigationMenuClosed.emit();\n document.body.style.height = \"auto\";\n document.body.style.overflow = \"auto\";\n }\n }\n\n private searchButtonMouseDownHandler = () => {\n this.searchButtonClick = true;\n };\n\n private searchButtonClickHandler = () => {\n this.toggleSearchBar();\n this.searchButtonClick = false;\n };\n\n private resizeObserverCallback = (currSize: number) => {\n if (currSize !== this.deviceSize) {\n this.deviceSize = currSize;\n if (currSize > this.customMobileBreakpoint) {\n this.showNavMenu(false);\n if (this.mobileSearchBarVisible) {\n this.toggleSearchBar();\n }\n }\n this.topNavResized.emit({\n size: currSize,\n });\n if (document.activeElement?.tagName === \"IC-SEARCH-BAR\") {\n this.searchBar.setAttribute(\"hidden\", \"true\");\n //remove attribute again as this trigger a redraw & applies css\n this.searchBar.removeAttribute(\"hidden\");\n setTimeout(() => {\n this.searchBar.focus();\n }, 100);\n }\n }\n };\n\n private runResizeObserver = () => {\n this.resizeObserver = new ResizeObserver(() => {\n this.resizeObserverCallback(getCurrentDeviceSize());\n });\n\n this.resizeObserver.observe(this.el);\n };\n\n render() {\n const {\n appTitle,\n contentAligned,\n customMobileBreakpoint,\n deviceSize,\n el,\n foregroundColor,\n hasAppIcon,\n hasFullWidthSearchBar,\n hasIconButtons,\n hasNavigation,\n hasSearchSlotContent,\n href,\n inline,\n menuButtonClick,\n mobileSearchBarVisible,\n navMenuVisible,\n searchButtonClickHandler,\n searchButtonMouseDownHandler,\n shortAppTitle,\n status,\n version,\n } = this;\n\n const hasStatus = status !== \"\";\n const hasVersion = version !== \"\";\n const hasMenuContent =\n hasNavigation || hasIconButtons || hasStatus || hasVersion;\n\n const searchButtonSize = deviceSize <= DEVICE_SIZES.S ? \"default\" : \"large\";\n const hasTitle = appTitle !== \"\" && isPropDefined(appTitle);\n const overMobileBreakpoint = deviceSize <= customMobileBreakpoint;\n\n const appTitleVariant: IcTypographyVariants = overMobileBreakpoint\n ? deviceSize <= DEVICE_SIZES.S\n ? \"subtitle-small\"\n : \"h4\"\n : \"h3\";\n\n const mobileSearchButtonTitle = `${\n mobileSearchBarVisible ? \"Hide\" : \"Show\"\n } search`;\n const menuSize = deviceSize <= DEVICE_SIZES.S ? \"small\" : \"default\";\n\n const shortAppTitleSlot = isSlotUsed(el, \"short-app-title\");\n const hasAppTitleSlot = isSlotUsed(el, \"app-title\");\n const Component = hasAppTitleSlot ? \"div\" : \"a\";\n const attrs = Component == \"a\" && {\n href: href,\n };\n\n return (\n <Host\n class={{\n \"fullwidth-searchbar\": hasFullWidthSearchBar,\n \"mobile-mode\": overMobileBreakpoint,\n [IcThemeForegroundEnum.Dark]:\n foregroundColor === IcThemeForegroundEnum.Dark,\n }}\n >\n <div class=\"top-navigation\">\n <ic-section-container aligned={contentAligned} full-height>\n <header role=\"banner\">\n <div class=\"top-panel-container\">\n <div class=\"app-details-container\">\n {(hasTitle || hasAppTitleSlot) && (\n <Component class=\"title-link\" {...attrs}>\n {hasAppIcon && (\n <div class=\"app-icon-container\">\n <slot name=\"app-icon\" />\n </div>\n )}\n {deviceSize <= DEVICE_SIZES.S &&\n (!isEmptyString(shortAppTitle) || shortAppTitleSlot) ? (\n <ic-typography\n variant=\"subtitle-small\"\n aria-label={\n (!hasAppTitleSlot || !shortAppTitleSlot) &&\n `${appTitle} (${shortAppTitle})`\n }\n >\n <h1>\n {shortAppTitleSlot ? (\n <slot name=\"short-app-title\"></slot>\n ) : (\n shortAppTitle\n )}\n </h1>\n </ic-typography>\n ) : (\n <ic-typography variant={appTitleVariant}>\n <h1 class=\"title-wrap\">\n {hasAppTitleSlot ? (\n <slot name=\"app-title\"></slot>\n ) : (\n appTitle\n )}\n </h1>\n </ic-typography>\n )}\n </Component>\n )}\n {hasStatus && (\n <div class=\"app-status\">\n <ic-typography\n aria-label=\"app tag\"\n variant=\"label-uppercase\"\n class=\"app-status-text\"\n >\n {status}\n </ic-typography>\n </div>\n )}\n {hasVersion && (\n <div class=\"app-version\">\n <ic-typography\n variant=\"label\"\n class=\"app-version-text\"\n aria-label=\"app version\"\n >\n {version}\n </ic-typography>\n </div>\n )}\n </div>\n\n {(hasSearchSlotContent || hasMenuContent) && (\n <div class=\"search-menu-container\">\n <div class=\"search-actions-container\">\n {!overMobileBreakpoint && <slot name=\"search\"></slot>}\n\n {hasSearchSlotContent && overMobileBreakpoint && (\n <ic-button\n id=\"search-toggle-button\"\n ref={(el) => (this.mobileSearchButtonEl = el)}\n onMouseDown={searchButtonMouseDownHandler}\n variant=\"icon\"\n size={searchButtonSize}\n aria-label={mobileSearchButtonTitle}\n appearance={foregroundColor}\n onClick={searchButtonClickHandler}\n >\n <slot name=\"toggle-icon\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 24 24\"\n fill=\"#ffffff\"\n >\n <path d=\"M0 0h24v24H0V0z\" fill=\"none\" />\n <path d=\"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z\" />\n </svg>\n </slot>\n </ic-button>\n )}\n\n {hasIconButtons && !overMobileBreakpoint && (\n <div class=\"icon-buttons-container\">\n <slot name=\"buttons\"></slot>\n </div>\n )}\n {hasMenuContent && overMobileBreakpoint && (\n <div class=\"menu-button-container\">\n <span\n id=\"navigation-landmark-button-text\"\n class=\"navigation-landmark-button-text\"\n aria-hidden=\"true\"\n >\n Main navigation button\n </span>\n <nav\n aria-labelledby=\"navigation-landmark-button-text\"\n aria-hidden={`${navMenuVisible}`}\n >\n <ic-button\n id=\"menu-button\"\n appearance={foregroundColor}\n variant=\"secondary\"\n aria-expanded=\"false\"\n aria-haspopup=\"true\"\n aria-label={`Open ${\n hasNavigation ? \"navigation\" : \"app\"\n } menu`}\n size={menuSize}\n onClick={menuButtonClick}\n >\n Menu\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n height=\"24px\"\n viewBox=\"0 0 24 24\"\n width=\"24px\"\n fill=\"#ffffff\"\n slot=\"icon\"\n >\n <path d=\"M0 0h24v24H0V0z\" fill=\"none\" />\n <path d=\"M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z\" />\n </svg>\n </ic-button>\n </nav>\n </div>\n )}\n </div>\n </div>\n )}\n </div>\n\n {mobileSearchBarVisible && (\n <div class=\"search-bar-container\">\n <slot name=\"search\"></slot>\n </div>\n )}\n\n {hasNavigation && !overMobileBreakpoint && (\n <div class=\"navigation-tabs\">\n <span\n id=\"navigation-landmark-text\"\n class=\"navigation-landmark-text\"\n aria-hidden=\"true\"\n >\n Main pages\n </span>\n <nav\n aria-labelledby=\"navigation-landmark-text\"\n class=\"nav-panel-container\"\n >\n <ic-horizontal-scroll appearance={foregroundColor}>\n <ul class=\"navigation-item-list\" tabindex=\"-1\">\n <slot name=\"navigation\"></slot>\n </ul>\n </ic-horizontal-scroll>\n </nav>\n </div>\n )}\n </header>\n </ic-section-container>\n </div>\n {navMenuVisible && (\n <ic-navigation-menu\n version={version}\n status={status}\n class={{\n [\"inline\"]: inline,\n }}\n >\n {hasIconButtons && (\n <div class=\"menu-buttons-slot\" slot=\"buttons\">\n <slot name=\"buttons\"></slot>\n </div>\n )}\n <ul slot=\"navigation\">\n <slot name=\"navigation\"></slot>\n </ul>\n </ic-navigation-menu>\n )}\n </Host>\n );\n }\n}\n"],"mappings":"uMAAA,MAAMA,EAAqB,m+N,MCkDdC,EAAa,M,oMAChBC,KAAAC,WAAsB,MACtBD,KAAAE,eAA0B,MAC1BF,KAAAG,cAAyB,MACzBH,KAAAI,qBAAgC,MAEhCJ,KAAAK,eAAiC,KACjCL,KAAAM,UAAoC,KA0IpCN,KAAAO,oBAAsB,KAC5B,GAAIP,KAAKI,qBAAsB,CAC7B,MAAMI,EAAOC,EAAQT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 -1 +1 @@
|
|
1
|
-
{"version":3,"names":["VARIANT_ICONS","neutral","icon","neutralIcon","ariaLabel","info","infoIcon","warning","warningIcon","error","errorIcon","success","successIcon","IC_INHERITED_ARIA","IC_DEVICE_SIZES","XS","S","M","L","XL","IC_BLOCK_COLOR_COMPONENTS","IC_FIXED_COLOR_COMPONENTS","IC_BLOCK_COLOR_EXCEPTIONS","BLACK_MIN_COLOR_BRIGHTNESS","WHITE_MAX_COLOR_BRIGHTNESS","DARK_MODE_THRESHOLD","icInput","linkIcInput","inheritAttributes","element","attributes","attributeObject","forEach","attr","hasAttribute","value","getAttribute","removeAttribute","debounceEvent","event","wait","original","_original","emit","debounce","bind","func","timer","args","clearTimeout","setTimeout","renderHiddenInput","always","container","name","disabled","undefined","hasShadowDom","inputs","querySelectorAll","inputEls","Array","from","filtered","filter","el","parentElement","input","ownerDocument","createElement","type","classList","add","appendChild","Date","toISOString","renderFileHiddenInput","multiple","accept","hidden","files","onchange","click","removeHiddenInput","remove","shadowRoot","attachShadow","getInputHelperTextID","id","getInputValidationTextID","getInputDescribedByText","inputId","helperText","validationText","trim","getThemeFromContext","themeFromEvent","getRootNode","host","blockColorParent","closest","join","parentTag","tagName","toLowerCase","currentTag","_a","includes","IcThemeForegroundEnum","Default","contains","Dark","Light","isMobileOrTablet","navigator","maxTouchPoints","handleHiddenFormButtonClick","form","button","hiddenFormButton","document","setAttribute","style","display","isEmptyString","length","isPropDefined","prop","getLabelFromValue","options","valueField","labelField","ungroupedOptions","map","option","children","push","matchingValue","find","getFilteredMenuOptions","includeDescriptions","searchString","position","label","description","lowerSearchString","startsWith","deviceSizeMatches","size","window","matchMedia","matches","getCurrentDeviceSize","DEVICE_SIZES","UNDEFINED","getCssProperty","cssVar","getComputedStyle","documentElement","getPropertyValue","getThemeColorBrightness","themeRed","themeGreen","themeBlue","parseInt","getThemeForegroundColor","getSlot","querySelector","slotHasContent","getSlotContent","slot","getSlotElements","slotContent","firstElementChild","elements","assignedElements","childNodes","getNavItemParentDetails","navType","parent","getParentElementType","getParentElement","Number","replace","hasValidationStatus","status","isSlotUsed","slotName","some","child","onComponentPropUndefinedChange","oldValue","newValue","callback","onComponentRequiredPropUndefined","props","component","i","propName","console","kebabToCamelCase","kebabCase","individualWords","split","camelCase","substring","toUpperCase","checkResizeObserver","callbackFn","ResizeObserver","hex2dec","v","hexToRgba","hex","c","r","g","b","a","slice","rgbaStrToObj","rgbaStr","fourthChar","colorRGBA","rgba","rgb","elementOverflowsX","scrollWidth","clientWidth","hasClassificationBanner","getForm","addFormResetListener","addEventListener","removeFormResetListener","removeEventListener","pxToRem","px","base","removeDisabledFalse"],"sources":["src/utils/constants.ts","src/utils/helpers.ts"],"sourcesContent":["import errorIcon from \"../assets/error-icon.svg\";\nimport infoIcon from \"../assets/info-icon.svg\";\nimport neutralIcon from \"../assets/neutral-icon.svg\";\nimport successIcon from \"../assets/success-icon.svg\";\nimport warningIcon from \"../assets/warning-icon.svg\";\n\n// Global status icons\nexport const VARIANT_ICONS = {\n neutral: {\n icon: neutralIcon,\n ariaLabel: \"Neutral\",\n },\n info: {\n icon: infoIcon,\n ariaLabel: \"For your information\",\n },\n warning: {\n icon: warningIcon,\n ariaLabel: \"Warning\",\n },\n error: {\n icon: errorIcon,\n ariaLabel: \"Error\",\n },\n success: {\n icon: successIcon,\n ariaLabel: \"Success\",\n },\n};\n\n// Global ARIA attributes\nexport const IC_INHERITED_ARIA = [\n \"aria-atomic\",\n \"aria-autocomplete\",\n \"aria-busy\",\n \"aria-controls\",\n \"aria-current\",\n \"aria-describedby\",\n \"aria-description\",\n \"aria-details\",\n \"aria-disabled\",\n \"aria-dropeffect\",\n \"aria-errormessage\",\n \"aria-expanded\",\n \"aria-flowto\",\n \"aria-grabbed\",\n \"aria-haspopup\",\n \"aria-hidden\",\n \"aria-invalid\",\n \"aria-keyshortcuts\",\n \"aria-label\",\n \"aria-labelledby\",\n \"aria-live\",\n \"aria-owns\",\n \"aria-relevant\",\n \"aria-roledescription\",\n];\n\nexport const IC_DEVICE_SIZES = {\n XS: 576,\n S: 768,\n M: 992,\n L: 1200,\n XL: 99999,\n};\n\nexport const IC_BLOCK_COLOR_COMPONENTS = [\n \"ic-hero\",\n \"ic-top-navigation\",\n \"ic-footer\",\n \"ic-side-navigation\",\n \"ic-alert\",\n];\n\nexport const IC_FIXED_COLOR_COMPONENTS = [\"ic-alert\"];\n\nexport interface IcColorExceptions {\n [details: string]: string[];\n}\n\nexport const IC_BLOCK_COLOR_EXCEPTIONS: IcColorExceptions = {\n \"ic-alert\": [\"ic-link\"],\n};\n\n/* Range within which the chosen theme colour would not have a sufficient brightness difference with either of the black or white foreground colours\n * The brightness difference must be greater than 125 to provide good colour visibility\n * Calculated by:\n * - Using the brightness formula for both colours: https://www.w3.org/TR/AERT/#color-contrast\n * - Adding 125 to the brightness of the black foreground colour - RGB(11, 12, 12)\n * - Subtracting 125 from the brightness of the white foreground colour - RGB(255, 255, 255)\n */\nexport const BLACK_MIN_COLOR_BRIGHTNESS = 136.701;\nexport const WHITE_MAX_COLOR_BRIGHTNESS = 130;\n","import { EventEmitter } from \"@stencil/core\";\nimport {\n IcCallbackFunctionNoReturn,\n IcInformationStatusOrEmpty,\n IcNavParentDetails,\n IcPropObject,\n IcSearchMatchPositions,\n IcColorRGBA,\n} from \"./types\";\n\nimport {\n IcMenuOption,\n IcThemeForeground,\n IcThemeForegroundEnum,\n} from \"../utils/types\";\nimport {\n IC_BLOCK_COLOR_COMPONENTS,\n IC_BLOCK_COLOR_EXCEPTIONS,\n IC_FIXED_COLOR_COMPONENTS,\n} from \"./constants\";\n\nconst DARK_MODE_THRESHOLD = 133.3505;\nconst icInput = \"ic-input\";\nconst linkIcInput = \"input.ic-input\";\n\n/**\n * converts an enum of strings into an array of strings\n */\nexport const stringEnumToArray = (\n theEnum: Record<string, string | number>\n): string[] => {\n const arr: string[] = [];\n Object.values(theEnum).forEach((val) => {\n if (isNaN(Number(val))) {\n const str = val as string;\n arr.push(str);\n }\n });\n return arr;\n};\n\n/**\n * Used to inherit global attributes set on the host. Called in componentWillLoad and assigned\n * to a variable that is later used in the render function.\n *\n * This does not need to be reactive as changing attributes on the host element\n * does not trigger a re-render.\n */\nexport const inheritAttributes = (\n element: HTMLElement,\n attributes: string[] = []\n): { [key: string]: string } => {\n const attributeObject: { [key: string]: string } = {};\n\n attributes.forEach((attr) => {\n if (element.hasAttribute(attr)) {\n const value = element.getAttribute(attr);\n if (value !== null) {\n attributeObject[attr] = value;\n }\n element.removeAttribute(attr);\n }\n });\n\n return attributeObject;\n};\n\nexport const debounceEvent = (\n event: EventEmitter,\n wait: number\n): EventEmitter => {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const original = (event as any)._original || event;\n return {\n _original: event,\n emit: debounce(original.emit.bind(original), wait),\n } as EventEmitter;\n};\n\nexport const debounce = (\n func: (...args: unknown[]) => void,\n wait = 0\n): unknown => {\n let timer: ReturnType<typeof setTimeout>;\n return (...args: unknown[]) => {\n clearTimeout(timer);\n timer = setTimeout(func, wait, ...args);\n };\n};\n\n/**\n * This method is used to add a hidden input to a host element that contains\n * a Shadow DOM. It does not add the input inside of the Shadow root which\n * allows it to be picked up inside of forms. It should contain the same\n * values as the host element.\n *\n * @param always Add a hidden input even if the container does not use Shadow\n * @param container The element where the input will be added\n * @param name The name of the input\n * @param value The value of the input\n * @param disabled If true, the input is disabled\n */\nexport const renderHiddenInput = (\n always: boolean,\n container: HTMLElement,\n name: string,\n value: string | Date | undefined | null,\n disabled: boolean\n): void => {\n if (name !== undefined && (always || hasShadowDom(container))) {\n const inputs = container.querySelectorAll(linkIcInput);\n const inputEls = Array.from(inputs);\n const filtered = inputEls.filter((el) => container === el.parentElement);\n\n let input = filtered[0] as HTMLInputElement;\n if (input === null || input === undefined) {\n input = container.ownerDocument.createElement(\"input\");\n input.type = \"hidden\";\n input.classList.add(icInput);\n container.appendChild(input);\n }\n input.disabled = disabled;\n input.name = name;\n\n if (value instanceof Date) {\n input.value = value ? value.toISOString() : null;\n } else {\n input.value = value || \"\";\n }\n }\n};\n\n/**\n * This method is used to add a hidden file input to a host element that contains\n * a Shadow DOM. It does not add the input inside of the Shadow root which\n * allows it to be picked up inside of forms. It should contain the same\n * values as the host element.\n *\n * @param event: The event that is emitted once a file is selected.\n * @param container The element where the input will be added\n * @param multiple If true, multiple files can be selected\n * @param name The name of the input\n * @param value The value of the input\n * @param disabled If true, the input is disabled\n * @param accept A string of the accepted files\n */\nexport const renderFileHiddenInput = (\n event: EventEmitter,\n container: HTMLElement,\n multiple: boolean,\n name: string,\n value: FileList | undefined | null,\n disabled: boolean,\n accept: string\n): void => {\n if (name !== undefined && hasShadowDom(container)) {\n const inputs = container.querySelectorAll(linkIcInput);\n const inputEls = Array.from(inputs);\n const filtered = inputEls.filter((el) => container === el.parentElement);\n\n let input = filtered[0] as HTMLInputElement;\n if (input === null || input === undefined) {\n input = container.ownerDocument.createElement(\"input\");\n input.classList.add(icInput);\n container.appendChild(input);\n }\n input.type = \"file\";\n input.hidden = true;\n input.multiple = multiple;\n input.name = name;\n input.files = value;\n input.disabled = disabled;\n input.accept = accept;\n input.onchange = () => {\n event.emit(input.files);\n };\n input.click();\n }\n};\n\nexport const removeHiddenInput = (container: HTMLElement): void => {\n const inputs = container.querySelectorAll(\"input.ic-input\");\n const inputEls = Array.from(inputs);\n const filtered = inputEls.filter((el) => container === el.parentElement);\n const input = filtered[0] as HTMLInputElement;\n input?.remove();\n};\n\nexport const hasShadowDom = (el: HTMLElement): boolean =>\n !!el.shadowRoot && !!el.attachShadow;\n\nexport const getInputHelperTextID = (id: string): string => id + \"-helper-text\";\n\nexport const getInputValidationTextID = (id: string): string =>\n id + \"-validation-text\";\n\nexport const getInputDescribedByText = (\n inputId: string,\n helperText: boolean,\n validationText: boolean\n): string =>\n `${helperText ? getInputHelperTextID(inputId) : \"\"} ${\n validationText ? getInputValidationTextID(inputId) : \"\"\n }`.trim();\n\n/**\n * This method helps to understand the context in which a component exists,\n * to assist with choosing appropriate foreground colours to use. For example,\n * this method will help you use the 'white' version of a button if it's within\n * a block colour element using white foreground text.\n *\n * This only works for components/elements passed via <slot> and not if they\n * are part of an IC component.\n *\n * \"\"\n * @returns IcThemeForeground depending on the context\n */\nexport const getThemeFromContext = (\n el: Element,\n themeFromEvent: IcThemeForeground = null\n): IcThemeForeground => {\n const parentElement =\n el.parentElement || (<ShadowRoot>el.getRootNode()).host.parentElement;\n const blockColorParent = parentElement.closest(\n IC_BLOCK_COLOR_COMPONENTS.join(\",\")\n );\n\n // If within a block color component\n if (blockColorParent !== null) {\n const parentTag = blockColorParent.tagName.toLowerCase();\n const currentTag = el.tagName.toLowerCase();\n\n if (IC_BLOCK_COLOR_EXCEPTIONS[parentTag]?.includes(currentTag)) {\n return IcThemeForegroundEnum.Default;\n } else if (\n themeFromEvent !== null &&\n !IC_FIXED_COLOR_COMPONENTS.includes(parentTag)\n ) {\n return themeFromEvent;\n } else if (\n blockColorParent.classList.contains(IcThemeForegroundEnum.Dark)\n ) {\n return IcThemeForegroundEnum.Dark;\n }\n\n return IcThemeForegroundEnum.Light;\n }\n\n return IcThemeForegroundEnum.Default;\n};\n\nexport const isMobileOrTablet = (): boolean =>\n \"maxTouchPoints\" in navigator ? navigator.maxTouchPoints > 0 : false;\n\n/**\n * Will create a button within the lightDOM which interacts with the parent form.\n * This is required as buttons within the shadowDOM will not invoke a submit or reset\n *\n * @param form - parent form element which contains shadowDom button\n * @param button - shadowDOM button\n */\nexport const handleHiddenFormButtonClick = (\n form: HTMLFormElement,\n button: HTMLIcButtonElement | HTMLButtonElement\n): void => {\n const hiddenFormButton = document.createElement(\"button\");\n\n hiddenFormButton.setAttribute(\"type\", button.type);\n hiddenFormButton.style.display = \"none\";\n\n form.appendChild(hiddenFormButton);\n\n hiddenFormButton.click();\n hiddenFormButton.remove();\n};\n\nexport const isEmptyString = (value: string): boolean =>\n value ? value.trim().length === 0 : true;\n\n// A helper function that checks if a prop has been defined\nexport const isPropDefined = (prop: string): string | null =>\n prop !== undefined ? prop : null;\n\n/**\n * Extracts the label using the value from an object. Requires the object to have a label and value property.\n * @param value - value from object\n * @param options - list of menu items\n * @returns - label corresponding to value\n */\nexport const getLabelFromValue = (\n value: string,\n options: IcMenuOption[],\n valueField = \"value\",\n labelField = \"label\"\n): string | undefined => {\n const ungroupedOptions: IcMenuOption[] = [];\n if (options.length > 0 && options.map) {\n options.map((option) => {\n if (option.children) {\n option.children.map((option: IcMenuOption) =>\n ungroupedOptions.push(option)\n );\n } else {\n ungroupedOptions.push(option);\n }\n });\n const matchingValue = ungroupedOptions.find(\n (option) => option[valueField] === value\n );\n if (matchingValue !== undefined) return matchingValue[labelField];\n }\n\n return undefined;\n};\n\n/**\n * Filters the options based on the search string.\n * @param options - array of options\n * @param includeDescriptions - determines whether option descriptions are included when filtering options\n * @param searchString - string used to filter the options\n * @param position - whether the search string matches the start of or anywhere in the options\n * @returns filtered array of options\n */\nexport const getFilteredMenuOptions = (\n options: IcMenuOption[],\n includeDescriptions: boolean,\n searchString: string,\n position: IcSearchMatchPositions,\n labelField = \"label\"\n): IcMenuOption[] =>\n options.filter((option) => {\n const label: string = option[labelField].toLowerCase();\n const description = option.description?.toLowerCase();\n const lowerSearchString = searchString.toLowerCase();\n\n return position === \"anywhere\"\n ? includeDescriptions\n ? label.includes(lowerSearchString) ||\n description?.includes(lowerSearchString)\n : label.includes(lowerSearchString)\n : includeDescriptions\n ? label.startsWith(lowerSearchString) ||\n description?.startsWith(lowerSearchString)\n : label.startsWith(lowerSearchString);\n });\n\nexport const deviceSizeMatches = (size: number): boolean =>\n window.matchMedia(`(max-width: ${size}px)`).matches;\n\nexport const getCurrentDeviceSize = (): number => {\n if (deviceSizeMatches(DEVICE_SIZES.S)) {\n return DEVICE_SIZES.S;\n }\n if (deviceSizeMatches(DEVICE_SIZES.M)) {\n return DEVICE_SIZES.M;\n }\n if (deviceSizeMatches(DEVICE_SIZES.L)) {\n return DEVICE_SIZES.L;\n }\n if (deviceSizeMatches(DEVICE_SIZES.XL)) {\n return DEVICE_SIZES.XL;\n }\n //fallback needed as all of above get initialised to 0 in jest tests\n return DEVICE_SIZES.UNDEFINED;\n};\n\nexport const getCssProperty = (cssVar: string): string =>\n getComputedStyle(document.documentElement).getPropertyValue(cssVar);\n\n/**\n * Returns the brightness of the theme colour, calculated by using the theme RGB CSS values by:\n * - Multiplying each RGB value by a set number: https://www.w3.org/TR/AERT/#color-contrast\n * - Adding them together and dividing by 1000\n * This is a similar calculation to its CSS counterpart: \"--ic-theme-text\"\n * @returns number representing the brightness of the theme colour\n */\nexport const getThemeColorBrightness = (): number => {\n const themeRed = getCssProperty(\"--ic-theme-primary-r\");\n const themeGreen = getCssProperty(\"--ic-theme-primary-g\");\n const themeBlue = getCssProperty(\"--ic-theme-primary-b\");\n return (\n (parseInt(themeRed) * 299 +\n parseInt(themeGreen) * 587 +\n parseInt(themeBlue) * 114) /\n 1000\n );\n};\n\n/**\n * Returns if dark or light foreground colors should be used for color contrast reasons\n * @returns \"dark\" or \"light\"\n */\nexport const getThemeForegroundColor = (): IcThemeForeground =>\n getThemeColorBrightness() > DARK_MODE_THRESHOLD\n ? IcThemeForegroundEnum.Dark\n : IcThemeForegroundEnum.Light;\n\nexport const getSlot = (element: HTMLElement, name: string): Element | null => {\n if (element && element.querySelector) {\n return element.querySelector(`[slot=\"${name}\"]`);\n }\n return null;\n};\n\nexport const slotHasContent = (element: HTMLElement, name: string): boolean =>\n getSlot(element, name) !== null;\n\nexport const getSlotContent = (\n element: HTMLElement,\n name: string\n): Element[] | NodeListOf<ChildNode> | null => {\n const slot = getSlot(element, name);\n if (slot) {\n return getSlotElements(slot);\n }\n\n return null;\n};\n\nexport const getSlotElements = (\n slot: Element\n): NodeListOf<ChildNode> | Element[] => {\n const slotContent = slot.firstElementChild as HTMLSlotElement;\n\n if (slotContent !== null) {\n const elements = slotContent.assignedElements\n ? slotContent.assignedElements()\n : slotContent.childNodes;\n return elements.length ? elements : null;\n } else {\n //check for single element\n return slot === null ? null : [slot];\n }\n};\n\nexport const getNavItemParentDetails = (\n el: HTMLElement\n): IcNavParentDetails => {\n let navType: IcNavParentDetails = { navType: \"\", parent: null };\n switch (getParentElementType(el)) {\n case \"IC-NAVIGATION-GROUP\":\n navType = getNavItemParentDetails(el.parentElement);\n break;\n case \"IC-TOP-NAVIGATION\":\n navType = { navType: \"top\", parent: getParentElement(el) };\n break;\n case \"IC-SIDE-NAVIGATION\":\n navType = { navType: \"side\", parent: getParentElement(el) };\n break;\n case \"IC-PAGE-HEADER\":\n navType = { navType: \"page-header\", parent: null };\n break;\n }\n return navType;\n};\n\nexport const DEVICE_SIZES = {\n XS: Number(getCssProperty(\"--ic-breakpoint-xs\").replace(\"px\", \"\")), // 0\n S: Number(getCssProperty(\"--ic-breakpoint-sm\").replace(\"px\", \"\")), // 576\n M: Number(getCssProperty(\"--ic-breakpoint-md\").replace(\"px\", \"\")), // 768\n L: Number(getCssProperty(\"--ic-breakpoint-lg\").replace(\"px\", \"\")), // 992\n XL: Number(getCssProperty(\"--ic-breakpoint-xl\").replace(\"px\", \"\")), // 1200\n UNDEFINED: 1200,\n};\n\nexport const hasValidationStatus = (\n status: IcInformationStatusOrEmpty,\n disabled: boolean\n): boolean => {\n return status !== \"\" && !disabled;\n};\n\nexport const isSlotUsed = (element: HTMLElement, slotName: string): boolean =>\n Array.from(element.children).some(\n (child) => child.getAttribute(\"slot\") === slotName\n );\n\n// added as a common method to allow detection of gatsby hydration issue, where (camelCase) props are initially undefined & then update\n// with a value. Allows a callback function to be executed when this is the case\nexport const onComponentPropUndefinedChange = (\n oldValue: string | undefined,\n newValue: string | undefined,\n callback: IcCallbackFunctionNoReturn\n): void => {\n if (oldValue === undefined && newValue !== oldValue) {\n callback();\n }\n};\n\nexport const onComponentRequiredPropUndefined = (\n props: IcPropObject[],\n component: string\n): void => {\n for (let i = 0; i < props.length; i++) {\n const { prop, propName } = props[i];\n if (prop === null || prop === undefined) {\n console.error(\n `No ${propName} specified for ${component} component - prop '${propName}' (web components) / '${kebabToCamelCase(\n propName\n )}' (react) required`\n );\n }\n }\n};\n\nexport const kebabToCamelCase = (kebabCase: string): string => {\n kebabCase = kebabCase.toLowerCase();\n const individualWords: string[] = kebabCase.split(\"-\");\n let camelCase = individualWords[0];\n for (let i = 1; i < individualWords.length; i++) {\n camelCase +=\n individualWords[i].substring(0, 1).toUpperCase() +\n individualWords[i].substring(1);\n }\n return camelCase;\n};\n\nexport const checkResizeObserver = (\n callbackFn: IcCallbackFunctionNoReturn\n): void => {\n if (\n typeof window !== \"undefined\" &&\n typeof window.ResizeObserver !== \"undefined\"\n ) {\n callbackFn();\n }\n};\n\nconst hex2dec = function (v: string) {\n return parseInt(v, 16);\n};\n\nexport const hexToRgba = (hex: string): IcColorRGBA => {\n let c;\n if (hex.length === 4) {\n c = hex.replace(\"#\", \"\").split(\"\");\n return {\n r: hex2dec(c[0] + c[0]),\n g: hex2dec(c[1] + c[1]),\n b: hex2dec(c[2] + c[2]),\n a: 1,\n };\n } else {\n return {\n r: hex2dec(hex.slice(1, 3)),\n g: hex2dec(hex.slice(3, 5)),\n b: hex2dec(hex.slice(5)),\n a: 1,\n };\n }\n};\n\nexport const rgbaStrToObj = (rgbaStr: string): IcColorRGBA => {\n const fourthChar = rgbaStr.slice(3, 4);\n let colorRGBA: IcColorRGBA;\n if (fourthChar.toLowerCase() === \"a\") {\n colorRGBA = { r: null, g: null, b: null, a: null };\n const rgba = rgbaStr\n .substring(5, rgbaStr.length - 1)\n .replace(/ /g, \"\")\n .split(\",\");\n colorRGBA.r = Number(rgba[0]);\n colorRGBA.g = Number(rgba[1]);\n colorRGBA.b = Number(rgba[2]);\n colorRGBA.a = Number(rgba[3]);\n } else {\n colorRGBA = { r: null, g: null, b: null, a: 1 };\n const rgb = rgbaStr\n .substring(4, rgbaStr.length - 1)\n .replace(/ /g, \"\")\n .split(\",\");\n colorRGBA.r = Number(rgb[0]);\n colorRGBA.g = Number(rgb[1]);\n colorRGBA.b = Number(rgb[2]);\n }\n\n return colorRGBA;\n};\n\nexport const elementOverflowsX = (element: HTMLElement): boolean =>\n element.scrollWidth > element.clientWidth;\n\n/**\n *\n * @param child - The child element\n * @returns string\n */\nexport const getParentElementType = (child: HTMLElement): string =>\n child.parentElement.tagName;\n\nexport const getParentElement = (child: HTMLElement): HTMLElement =>\n child.parentElement;\n\nexport const hasClassificationBanner = (): boolean =>\n !!document.querySelector(\"ic-classification-banner:not([inline='true'])\");\n\nexport const getForm = (el: HTMLElement): HTMLFormElement => el.closest(\"FORM\");\n\nexport const addFormResetListener = (\n el: HTMLElement,\n callbackFn: IcCallbackFunctionNoReturn\n): void => {\n const form = getForm(el);\n if (form !== null) {\n form.addEventListener(\"reset\", callbackFn);\n }\n};\n\nexport const removeFormResetListener = (\n el: HTMLElement,\n callbackFn: IcCallbackFunctionNoReturn\n): void => {\n const form = getForm(el);\n if (form !== null) {\n form.removeEventListener(\"reset\", callbackFn);\n }\n};\n\nexport const pxToRem = (px: string, base = 16): string =>\n `${(1 / base) * parseInt(px)}rem`;\n\nexport const removeDisabledFalse = (\n disabled: boolean,\n element: HTMLElement\n): void => {\n if (!disabled) {\n element.removeAttribute(\"disabled\");\n }\n};\n\nexport const isMacDevice = (): boolean => {\n return window.navigator.userAgent.toUpperCase().indexOf(\"MAC\") >= 0;\n};\n\nexport const isNumeric = (value: string) => {\n return /^-?\\d+$/.test(value);\n};\n"],"mappings":"k+FAOaA,EAAgB,CAC3BC,QAAS,CACPC,KAAMC,EACNC,UAAW,WAEbC,KAAM,CACJH,KAAMI,EACNF,UAAW,wBAEbG,QAAS,CACPL,KAAMM,EACNJ,UAAW,WAEbK,MAAO,CACLP,KAAMQ,EACNN,UAAW,SAEbO,QAAS,CACPT,KAAMU,EACNR,UAAW,Y,MAKFS,EAAoB,CAC/B,cACA,oBACA,YACA,gBACA,eACA,mBACA,mBACA,eACA,gBACA,kBACA,oBACA,gBACA,cACA,eACA,gBACA,cACA,eACA,oBACA,aACA,kBACA,YACA,YACA,gBACA,wB,MAG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BA,EAAKqH,oBAAoB,QAAS1B,E,SAIzB2B,GAAU,CAACC,EAAYC,EAAO,KACzC,GAAI,EAAIA,EAAQzE,SAASwE,Q,MAEdE,GAAsB,CACjCvL,EACA1B,KAEA,IAAK0B,EAAU,CACb1B,EAAQQ,gBAAgB,W"}
|
1
|
+
{"version":3,"names":["VARIANT_ICONS","neutral","icon","neutralIcon","ariaLabel","info","infoIcon","warning","warningIcon","error","errorIcon","success","successIcon","IC_INHERITED_ARIA","IC_DEVICE_SIZES","XS","S","M","L","XL","IC_BLOCK_COLOR_COMPONENTS","IC_FIXED_COLOR_COMPONENTS","IC_BLOCK_COLOR_EXCEPTIONS","BLACK_MIN_COLOR_BRIGHTNESS","WHITE_MAX_COLOR_BRIGHTNESS","DARK_MODE_THRESHOLD","icInput","linkIcInput","inheritAttributes","element","attributes","attributeObject","forEach","attr","hasAttribute","value","getAttribute","removeAttribute","debounceEvent","event","wait","original","_original","emit","debounce","bind","func","timer","args","clearTimeout","setTimeout","renderHiddenInput","always","container","name","disabled","undefined","hasShadowDom","inputs","querySelectorAll","inputEls","Array","from","filtered","filter","el","parentElement","input","ownerDocument","createElement","type","classList","add","appendChild","Date","toISOString","renderFileHiddenInput","multiple","accept","hidden","files","onchange","click","removeHiddenInput","remove","shadowRoot","attachShadow","getInputHelperTextID","id","getInputValidationTextID","getInputDescribedByText","inputId","helperText","validationText","trim","getThemeFromContext","themeFromEvent","getRootNode","host","blockColorParent","closest","join","parentTag","tagName","toLowerCase","currentTag","_a","includes","IcThemeForegroundEnum","Default","contains","Dark","Light","isMobileOrTablet","navigator","maxTouchPoints","handleHiddenFormButtonClick","form","button","hiddenFormButton","document","setAttribute","style","display","isEmptyString","length","isPropDefined","prop","getLabelFromValue","options","valueField","labelField","ungroupedOptions","map","option","children","push","matchingValue","find","getFilteredMenuOptions","includeDescriptions","searchString","position","label","description","lowerSearchString","startsWith","deviceSizeMatches","size","window","matchMedia","matches","getCurrentDeviceSize","DEVICE_SIZES","UNDEFINED","getCssProperty","cssVar","getComputedStyle","documentElement","getPropertyValue","getThemeColorBrightness","themeRed","themeGreen","themeBlue","parseInt","getThemeForegroundColor","getSlot","querySelector","slotHasContent","getSlotContent","slot","getSlotElements","slotContent","firstElementChild","elements","assignedElements","childNodes","getNavItemParentDetails","navType","parent","getParentElementType","getParentElement","Number","replace","hasValidationStatus","status","isSlotUsed","slotName","some","child","onComponentPropUndefinedChange","oldValue","newValue","callback","onComponentRequiredPropUndefined","props","component","i","propName","console","kebabToCamelCase","kebabCase","individualWords","split","camelCase","substring","toUpperCase","checkResizeObserver","callbackFn","ResizeObserver","hex2dec","v","hexToRgba","hex","c","r","g","b","a","slice","rgbaStrToObj","rgbaStr","fourthChar","colorRGBA","rgba","rgb","elementOverflowsX","scrollWidth","clientWidth","hasClassificationBanner","getForm","addFormResetListener","addEventListener","removeFormResetListener","removeEventListener","pxToRem","px","base","removeDisabledFalse"],"sources":["src/utils/constants.ts","src/utils/helpers.ts"],"sourcesContent":["import errorIcon from \"../assets/error-icon.svg\";\nimport infoIcon from \"../assets/info-icon.svg\";\nimport neutralIcon from \"../assets/neutral-icon.svg\";\nimport successIcon from \"../assets/success-icon.svg\";\nimport warningIcon from \"../assets/warning-icon.svg\";\n\n// Global status icons\nexport const VARIANT_ICONS = {\n neutral: {\n icon: neutralIcon,\n ariaLabel: \"Neutral\",\n },\n info: {\n icon: infoIcon,\n ariaLabel: \"For your information\",\n },\n warning: {\n icon: warningIcon,\n ariaLabel: \"Warning\",\n },\n error: {\n icon: errorIcon,\n ariaLabel: \"Error\",\n },\n success: {\n icon: successIcon,\n ariaLabel: \"Success\",\n },\n};\n\n// Global ARIA attributes\nexport const IC_INHERITED_ARIA = [\n \"aria-atomic\",\n \"aria-autocomplete\",\n \"aria-busy\",\n \"aria-controls\",\n \"aria-current\",\n \"aria-describedby\",\n \"aria-description\",\n \"aria-details\",\n \"aria-disabled\",\n \"aria-dropeffect\",\n \"aria-errormessage\",\n \"aria-expanded\",\n \"aria-flowto\",\n \"aria-grabbed\",\n \"aria-haspopup\",\n \"aria-hidden\",\n \"aria-invalid\",\n \"aria-keyshortcuts\",\n \"aria-label\",\n \"aria-labelledby\",\n \"aria-live\",\n \"aria-owns\",\n \"aria-relevant\",\n \"aria-roledescription\",\n];\n\nexport const IC_DEVICE_SIZES = {\n XS: 576,\n S: 768,\n M: 992,\n L: 1200,\n XL: 99999,\n};\n\nexport const IC_BLOCK_COLOR_COMPONENTS = [\n \"ic-hero\",\n \"ic-top-navigation\",\n \"ic-footer\",\n \"ic-side-navigation\",\n \"ic-alert\",\n];\n\nexport const IC_FIXED_COLOR_COMPONENTS = [\"ic-alert\"];\n\nexport interface IcColorExceptions {\n [details: string]: string[];\n}\n\nexport const IC_BLOCK_COLOR_EXCEPTIONS: IcColorExceptions = {\n \"ic-alert\": [\"ic-link\"],\n};\n\n/* Range within which the chosen theme colour would not have a sufficient brightness difference with either of the black or white foreground colours\n * The brightness difference must be greater than 125 to provide good colour visibility\n * Calculated by:\n * - Using the brightness formula for both colours: https://www.w3.org/TR/AERT/#color-contrast\n * - Adding 125 to the brightness of the black foreground colour - RGB(11, 12, 12)\n * - Subtracting 125 from the brightness of the white foreground colour - RGB(255, 255, 255)\n */\nexport const BLACK_MIN_COLOR_BRIGHTNESS = 136.701;\nexport const WHITE_MAX_COLOR_BRIGHTNESS = 130;\n","import { EventEmitter } from \"@stencil/core\";\nimport {\n IcCallbackFunctionNoReturn,\n IcInformationStatusOrEmpty,\n IcNavParentDetails,\n IcPropObject,\n IcSearchMatchPositions,\n IcColorRGBA,\n IcDeviceSizes,\n} from \"./types\";\n\nimport {\n IcMenuOption,\n IcThemeForeground,\n IcThemeForegroundEnum,\n} from \"../utils/types\";\nimport {\n IC_BLOCK_COLOR_COMPONENTS,\n IC_BLOCK_COLOR_EXCEPTIONS,\n IC_FIXED_COLOR_COMPONENTS,\n} from \"./constants\";\n\nconst DARK_MODE_THRESHOLD = 133.3505;\nconst icInput = \"ic-input\";\nconst linkIcInput = \"input.ic-input\";\n\n/**\n * converts an enum of strings into an array of strings\n */\nexport const stringEnumToArray = (\n theEnum: Record<string, string | number>\n): string[] => {\n const arr: string[] = [];\n Object.values(theEnum).forEach((val) => {\n if (isNaN(Number(val))) {\n const str = val as string;\n arr.push(str);\n }\n });\n return arr;\n};\n\n/**\n * Used to inherit global attributes set on the host. Called in componentWillLoad and assigned\n * to a variable that is later used in the render function.\n *\n * This does not need to be reactive as changing attributes on the host element\n * does not trigger a re-render.\n */\nexport const inheritAttributes = (\n element: HTMLElement,\n attributes: string[] = []\n): { [key: string]: string } => {\n const attributeObject: { [key: string]: string } = {};\n\n attributes.forEach((attr) => {\n if (element.hasAttribute(attr)) {\n const value = element.getAttribute(attr);\n if (value !== null) {\n attributeObject[attr] = value;\n }\n element.removeAttribute(attr);\n }\n });\n\n return attributeObject;\n};\n\nexport const debounceEvent = (\n event: EventEmitter,\n wait: number\n): EventEmitter => {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const original = (event as any)._original || event;\n return {\n _original: event,\n emit: debounce(original.emit.bind(original), wait),\n } as EventEmitter;\n};\n\nexport const debounce = (\n func: (...args: unknown[]) => void,\n wait = 0\n): unknown => {\n let timer: ReturnType<typeof setTimeout>;\n return (...args: unknown[]) => {\n clearTimeout(timer);\n timer = setTimeout(func, wait, ...args);\n };\n};\n\n/**\n * This method is used to add a hidden input to a host element that contains\n * a Shadow DOM. It does not add the input inside of the Shadow root which\n * allows it to be picked up inside of forms. It should contain the same\n * values as the host element.\n *\n * @param always Add a hidden input even if the container does not use Shadow\n * @param container The element where the input will be added\n * @param name The name of the input\n * @param value The value of the input\n * @param disabled If true, the input is disabled\n */\nexport const renderHiddenInput = (\n always: boolean,\n container: HTMLElement,\n name: string,\n value: string | Date | undefined | null,\n disabled: boolean\n): void => {\n if (name !== undefined && (always || hasShadowDom(container))) {\n const inputs = container.querySelectorAll(linkIcInput);\n const inputEls = Array.from(inputs);\n const filtered = inputEls.filter((el) => container === el.parentElement);\n\n let input = filtered[0] as HTMLInputElement;\n if (input === null || input === undefined) {\n input = container.ownerDocument.createElement(\"input\");\n input.type = \"hidden\";\n input.classList.add(icInput);\n container.appendChild(input);\n }\n input.disabled = disabled;\n input.name = name;\n\n if (value instanceof Date) {\n input.value = value ? value.toISOString() : null;\n } else {\n input.value = value || \"\";\n }\n }\n};\n\n/**\n * This method is used to add a hidden file input to a host element that contains\n * a Shadow DOM. It does not add the input inside of the Shadow root which\n * allows it to be picked up inside of forms. It should contain the same\n * values as the host element.\n *\n * @param event: The event that is emitted once a file is selected.\n * @param container The element where the input will be added\n * @param multiple If true, multiple files can be selected\n * @param name The name of the input\n * @param value The value of the input\n * @param disabled If true, the input is disabled\n * @param accept A string of the accepted files\n */\nexport const renderFileHiddenInput = (\n event: EventEmitter,\n container: HTMLElement,\n multiple: boolean,\n name: string,\n value: FileList | undefined | null,\n disabled: boolean,\n accept: string\n): void => {\n if (name !== undefined && hasShadowDom(container)) {\n const inputs = container.querySelectorAll(linkIcInput);\n const inputEls = Array.from(inputs);\n const filtered = inputEls.filter((el) => container === el.parentElement);\n\n let input = filtered[0] as HTMLInputElement;\n if (input === null || input === undefined) {\n input = container.ownerDocument.createElement(\"input\");\n input.classList.add(icInput);\n container.appendChild(input);\n }\n input.type = \"file\";\n input.hidden = true;\n input.multiple = multiple;\n input.name = name;\n input.files = value;\n input.disabled = disabled;\n input.accept = accept;\n input.onchange = () => {\n event.emit(input.files);\n };\n input.click();\n }\n};\n\nexport const removeHiddenInput = (container: HTMLElement): void => {\n const inputs = container.querySelectorAll(\"input.ic-input\");\n const inputEls = Array.from(inputs);\n const filtered = inputEls.filter((el) => container === el.parentElement);\n const input = filtered[0] as HTMLInputElement;\n input?.remove();\n};\n\nexport const hasShadowDom = (el: HTMLElement): boolean =>\n !!el.shadowRoot && !!el.attachShadow;\n\nexport const getInputHelperTextID = (id: string): string => id + \"-helper-text\";\n\nexport const getInputValidationTextID = (id: string): string =>\n id + \"-validation-text\";\n\nexport const getInputDescribedByText = (\n inputId: string,\n helperText: boolean,\n validationText: boolean\n): string =>\n `${helperText ? getInputHelperTextID(inputId) : \"\"} ${\n validationText ? getInputValidationTextID(inputId) : \"\"\n }`.trim();\n\n/**\n * This method helps to understand the context in which a component exists,\n * to assist with choosing appropriate foreground colours to use. For example,\n * this method will help you use the 'white' version of a button if it's within\n * a block colour element using white foreground text.\n *\n * This only works for components/elements passed via <slot> and not if they\n * are part of an IC component.\n *\n * \"\"\n * @returns IcThemeForeground depending on the context\n */\nexport const getThemeFromContext = (\n el: Element,\n themeFromEvent: IcThemeForeground = null\n): IcThemeForeground => {\n const parentElement =\n el.parentElement || (<ShadowRoot>el.getRootNode()).host.parentElement;\n const blockColorParent = parentElement.closest(\n IC_BLOCK_COLOR_COMPONENTS.join(\",\")\n );\n\n // If within a block color component\n if (blockColorParent !== null) {\n const parentTag = blockColorParent.tagName.toLowerCase();\n const currentTag = el.tagName.toLowerCase();\n\n if (IC_BLOCK_COLOR_EXCEPTIONS[parentTag]?.includes(currentTag)) {\n return IcThemeForegroundEnum.Default;\n } else if (\n themeFromEvent !== null &&\n !IC_FIXED_COLOR_COMPONENTS.includes(parentTag)\n ) {\n return themeFromEvent;\n } else if (\n blockColorParent.classList.contains(IcThemeForegroundEnum.Dark)\n ) {\n return IcThemeForegroundEnum.Dark;\n }\n\n return IcThemeForegroundEnum.Light;\n }\n\n return IcThemeForegroundEnum.Default;\n};\n\nexport const isMobileOrTablet = (): boolean =>\n \"maxTouchPoints\" in navigator ? navigator.maxTouchPoints > 0 : false;\n\n/**\n * Will create a button within the lightDOM which interacts with the parent form.\n * This is required as buttons within the shadowDOM will not invoke a submit or reset\n *\n * @param form - parent form element which contains shadowDom button\n * @param button - shadowDOM button\n */\nexport const handleHiddenFormButtonClick = (\n form: HTMLFormElement,\n button: HTMLIcButtonElement | HTMLButtonElement\n): void => {\n const hiddenFormButton = document.createElement(\"button\");\n\n hiddenFormButton.setAttribute(\"type\", button.type);\n hiddenFormButton.style.display = \"none\";\n\n form.appendChild(hiddenFormButton);\n\n hiddenFormButton.click();\n hiddenFormButton.remove();\n};\n\nexport const isEmptyString = (value: string): boolean =>\n value ? value.trim().length === 0 : true;\n\n// A helper function that checks if a prop has been defined\nexport const isPropDefined = (prop: string): string | null =>\n prop !== undefined ? prop : null;\n\n/**\n * Extracts the label using the value from an object. Requires the object to have a label and value property.\n * @param value - value from object\n * @param options - list of menu items\n * @returns - label corresponding to value\n */\nexport const getLabelFromValue = (\n value: string,\n options: IcMenuOption[],\n valueField = \"value\",\n labelField = \"label\"\n): string | undefined => {\n const ungroupedOptions: IcMenuOption[] = [];\n if (options.length > 0 && options.map) {\n options.map((option) => {\n if (option.children) {\n option.children.map((option: IcMenuOption) =>\n ungroupedOptions.push(option)\n );\n } else {\n ungroupedOptions.push(option);\n }\n });\n const matchingValue = ungroupedOptions.find(\n (option) => option[valueField] === value\n );\n if (matchingValue !== undefined) return matchingValue[labelField];\n }\n\n return undefined;\n};\n\n/**\n * Filters the options based on the search string.\n * @param options - array of options\n * @param includeDescriptions - determines whether option descriptions are included when filtering options\n * @param searchString - string used to filter the options\n * @param position - whether the search string matches the start of or anywhere in the options\n * @returns filtered array of options\n */\nexport const getFilteredMenuOptions = (\n options: IcMenuOption[],\n includeDescriptions: boolean,\n searchString: string,\n position: IcSearchMatchPositions,\n labelField = \"label\"\n): IcMenuOption[] =>\n options.filter((option) => {\n const label: string = option[labelField].toLowerCase();\n const description = option.description?.toLowerCase();\n const lowerSearchString = searchString.toLowerCase();\n\n return position === \"anywhere\"\n ? includeDescriptions\n ? label.includes(lowerSearchString) ||\n description?.includes(lowerSearchString)\n : label.includes(lowerSearchString)\n : includeDescriptions\n ? label.startsWith(lowerSearchString) ||\n description?.startsWith(lowerSearchString)\n : label.startsWith(lowerSearchString);\n });\n\nexport const deviceSizeMatches = (size: number): boolean =>\n window.matchMedia(`(max-width: ${size}px)`).matches;\n\nexport const getCurrentDeviceSize = (): number => {\n if (deviceSizeMatches(DEVICE_SIZES.S)) {\n return DEVICE_SIZES.S;\n }\n if (deviceSizeMatches(DEVICE_SIZES.M)) {\n return DEVICE_SIZES.M;\n }\n if (deviceSizeMatches(DEVICE_SIZES.L)) {\n return DEVICE_SIZES.L;\n }\n if (deviceSizeMatches(DEVICE_SIZES.XL)) {\n return DEVICE_SIZES.XL;\n }\n //fallback needed as all of above get initialised to 0 in jest tests\n return DEVICE_SIZES.UNDEFINED;\n};\n\nexport const getCssProperty = (cssVar: string): string =>\n getComputedStyle(document.documentElement).getPropertyValue(cssVar);\n\n/**\n * Returns the brightness of the theme colour, calculated by using the theme RGB CSS values by:\n * - Multiplying each RGB value by a set number: https://www.w3.org/TR/AERT/#color-contrast\n * - Adding them together and dividing by 1000\n * This is a similar calculation to its CSS counterpart: \"--ic-theme-text\"\n * @returns number representing the brightness of the theme colour\n */\nexport const getThemeColorBrightness = (): number => {\n const themeRed = getCssProperty(\"--ic-theme-primary-r\");\n const themeGreen = getCssProperty(\"--ic-theme-primary-g\");\n const themeBlue = getCssProperty(\"--ic-theme-primary-b\");\n return (\n (parseInt(themeRed) * 299 +\n parseInt(themeGreen) * 587 +\n parseInt(themeBlue) * 114) /\n 1000\n );\n};\n\n/**\n * Returns if dark or light foreground colors should be used for color contrast reasons\n * @returns \"dark\" or \"light\"\n */\nexport const getThemeForegroundColor = (): IcThemeForeground =>\n getThemeColorBrightness() > DARK_MODE_THRESHOLD\n ? IcThemeForegroundEnum.Dark\n : IcThemeForegroundEnum.Light;\n\nexport const getSlot = (element: HTMLElement, name: string): Element | null => {\n if (element && element.querySelector) {\n return element.querySelector(`[slot=\"${name}\"]`);\n }\n return null;\n};\n\nexport const slotHasContent = (element: HTMLElement, name: string): boolean =>\n getSlot(element, name) !== null;\n\nexport const getSlotContent = (\n element: HTMLElement,\n name: string\n): Element[] | NodeListOf<ChildNode> | null => {\n const slot = getSlot(element, name);\n if (slot) {\n return getSlotElements(slot);\n }\n\n return null;\n};\n\nexport const getSlotElements = (\n slot: Element\n): NodeListOf<ChildNode> | Element[] => {\n const slotContent = slot.firstElementChild as HTMLSlotElement;\n\n if (slotContent !== null) {\n const elements = slotContent.assignedElements\n ? slotContent.assignedElements()\n : slotContent.childNodes;\n return elements.length ? elements : null;\n } else {\n //check for single element\n return slot === null ? null : [slot];\n }\n};\n\nexport const getNavItemParentDetails = (\n el: HTMLElement\n): IcNavParentDetails => {\n let navType: IcNavParentDetails = { navType: \"\", parent: null };\n switch (getParentElementType(el)) {\n case \"IC-NAVIGATION-GROUP\":\n navType = getNavItemParentDetails(el.parentElement);\n break;\n case \"IC-TOP-NAVIGATION\":\n navType = { navType: \"top\", parent: getParentElement(el) };\n break;\n case \"IC-SIDE-NAVIGATION\":\n navType = { navType: \"side\", parent: getParentElement(el) };\n break;\n case \"IC-PAGE-HEADER\":\n navType = { navType: \"page-header\", parent: null };\n break;\n }\n return navType;\n};\n\nexport const DEVICE_SIZES = {\n XS: Number(\n getCssProperty(\"--ic-breakpoint-xs\").replace(\"px\", \"\")\n ) as IcDeviceSizes, // 0\n S: Number(\n getCssProperty(\"--ic-breakpoint-sm\").replace(\"px\", \"\")\n ) as IcDeviceSizes, // 576\n M: Number(\n getCssProperty(\"--ic-breakpoint-md\").replace(\"px\", \"\")\n ) as IcDeviceSizes, // 768\n L: Number(\n getCssProperty(\"--ic-breakpoint-lg\").replace(\"px\", \"\")\n ) as IcDeviceSizes, // 992\n XL: Number(\n getCssProperty(\"--ic-breakpoint-xl\").replace(\"px\", \"\")\n ) as IcDeviceSizes, // 1200\n UNDEFINED: 1200,\n};\n\nexport const hasValidationStatus = (\n status: IcInformationStatusOrEmpty,\n disabled: boolean\n): boolean => {\n return status !== \"\" && !disabled;\n};\n\nexport const isSlotUsed = (element: HTMLElement, slotName: string): boolean =>\n Array.from(element.children).some(\n (child) => child.getAttribute(\"slot\") === slotName\n );\n\n// added as a common method to allow detection of gatsby hydration issue, where (camelCase) props are initially undefined & then update\n// with a value. Allows a callback function to be executed when this is the case\nexport const onComponentPropUndefinedChange = (\n oldValue: string | undefined,\n newValue: string | undefined,\n callback: IcCallbackFunctionNoReturn\n): void => {\n if (oldValue === undefined && newValue !== oldValue) {\n callback();\n }\n};\n\nexport const onComponentRequiredPropUndefined = (\n props: IcPropObject[],\n component: string\n): void => {\n for (let i = 0; i < props.length; i++) {\n const { prop, propName } = props[i];\n if (prop === null || prop === undefined) {\n console.error(\n `No ${propName} specified for ${component} component - prop '${propName}' (web components) / '${kebabToCamelCase(\n propName\n )}' (react) required`\n );\n }\n }\n};\n\nexport const kebabToCamelCase = (kebabCase: string): string => {\n kebabCase = kebabCase.toLowerCase();\n const individualWords: string[] = kebabCase.split(\"-\");\n let camelCase = individualWords[0];\n for (let i = 1; i < individualWords.length; i++) {\n camelCase +=\n individualWords[i].substring(0, 1).toUpperCase() +\n individualWords[i].substring(1);\n }\n return camelCase;\n};\n\nexport const checkResizeObserver = (\n callbackFn: IcCallbackFunctionNoReturn\n): void => {\n if (\n typeof window !== \"undefined\" &&\n typeof window.ResizeObserver !== \"undefined\"\n ) {\n callbackFn();\n }\n};\n\nconst hex2dec = function (v: string) {\n return parseInt(v, 16);\n};\n\nexport const hexToRgba = (hex: string): IcColorRGBA => {\n let c;\n if (hex.length === 4) {\n c = hex.replace(\"#\", \"\").split(\"\");\n return {\n r: hex2dec(c[0] + c[0]),\n g: hex2dec(c[1] + c[1]),\n b: hex2dec(c[2] + c[2]),\n a: 1,\n };\n } else {\n return {\n r: hex2dec(hex.slice(1, 3)),\n g: hex2dec(hex.slice(3, 5)),\n b: hex2dec(hex.slice(5)),\n a: 1,\n };\n }\n};\n\nexport const rgbaStrToObj = (rgbaStr: string): IcColorRGBA => {\n const fourthChar = rgbaStr.slice(3, 4);\n let colorRGBA: IcColorRGBA;\n if (fourthChar.toLowerCase() === \"a\") {\n colorRGBA = { r: null, g: null, b: null, a: null };\n const rgba = rgbaStr\n .substring(5, rgbaStr.length - 1)\n .replace(/ /g, \"\")\n .split(\",\");\n colorRGBA.r = Number(rgba[0]);\n colorRGBA.g = Number(rgba[1]);\n colorRGBA.b = Number(rgba[2]);\n colorRGBA.a = Number(rgba[3]);\n } else {\n colorRGBA = { r: null, g: null, b: null, a: 1 };\n const rgb = rgbaStr\n .substring(4, rgbaStr.length - 1)\n .replace(/ /g, \"\")\n .split(\",\");\n colorRGBA.r = Number(rgb[0]);\n colorRGBA.g = Number(rgb[1]);\n colorRGBA.b = Number(rgb[2]);\n }\n\n return colorRGBA;\n};\n\nexport const elementOverflowsX = (element: HTMLElement): boolean =>\n element.scrollWidth > element.clientWidth;\n\n/**\n *\n * @param child - The child element\n * @returns string\n */\nexport const getParentElementType = (child: HTMLElement): string =>\n child.parentElement.tagName;\n\nexport const getParentElement = (child: HTMLElement): HTMLElement =>\n child.parentElement;\n\nexport const hasClassificationBanner = (): boolean =>\n !!document.querySelector(\"ic-classification-banner:not([inline='true'])\");\n\nexport const getForm = (el: HTMLElement): HTMLFormElement => el.closest(\"FORM\");\n\nexport const addFormResetListener = (\n el: HTMLElement,\n callbackFn: IcCallbackFunctionNoReturn\n): void => {\n const form = getForm(el);\n if (form !== null) {\n form.addEventListener(\"reset\", callbackFn);\n }\n};\n\nexport const removeFormResetListener = (\n el: HTMLElement,\n callbackFn: IcCallbackFunctionNoReturn\n): void => {\n const form = getForm(el);\n if (form !== null) {\n form.removeEventListener(\"reset\", callbackFn);\n }\n};\n\nexport const pxToRem = (px: string, base = 16): string =>\n `${(1 / base) * parseInt(px)}rem`;\n\nexport const removeDisabledFalse = (\n disabled: boolean,\n element: HTMLElement\n): void => {\n if (!disabled) {\n element.removeAttribute(\"disabled\");\n }\n};\n\nexport const isMacDevice = (): boolean => {\n return window.navigator.userAgent.toUpperCase().indexOf(\"MAC\") >= 0;\n};\n\nexport const isNumeric = (value: string): boolean => {\n return /^-?\\d+$/.test(value);\n};\n"],"mappings":"k+FAOaA,EAAgB,CAC3BC,QAAS,CACPC,KAAMC,EACNC,UAAW,WAEbC,KAAM,CACJH,KAAMI,EACNF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Ac,iDAEpB,MAAM+D,GAAWrK,GAAqCA,EAAGmC,QAAQ,Q,MAE3DmI,GAAuB,CAClCtK,EACA+I,KAEA,MAAM3F,EAAOiH,GAAQrK,GACrB,GAAIoD,IAAS,KAAM,CACjBA,EAAKmH,iBAAiB,QAASxB,E,SAItByB,GAA0B,CACrCxK,EACA+I,KAEA,MAAM3F,EAAOiH,GAAQrK,GACrB,GAAIoD,IAAS,KAAM,CACjBA,EAAKqH,oBAAoB,QAAS1B,E,SAIzB2B,GAAU,CAACC,EAAYC,EAAO,KACzC,GAAI,EAAIA,EAAQzE,SAASwE,Q,MAEdE,GAAsB,CACjCvL,EACA1B,KAEA,IAAK0B,EAAU,CACb1B,EAAQQ,gBAAgB,W"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["IcInformationStatus","IcThemeForegroundEnum"],"sources":["src/utils/types.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"names":["IcInformationStatus","IcThemeForegroundEnum"],"sources":["src/utils/types.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nexport type IcFocusableComponents =\n | HTMLIcBreadcrumbElement\n | HTMLIcButtonElement\n | HTMLIcCardElement\n | HTMLIcCheckboxElement\n | HTMLIcChipElement\n | HTMLIcLinkElement\n | HTMLIcNavigationButtonElement\n | HTMLIcNavigationGroupElement\n | HTMLIcNavigationItemElement\n | HTMLIcRadioOptionElement\n | HTMLIcSearchBarElement\n | HTMLIcSelectElement\n | HTMLIcSwitchElement\n | HTMLIcTabElement\n | HTMLIcTextFieldElement;\n\nexport type IcStatusVariants =\n | \"neutral\"\n | \"info\"\n | \"warning\"\n | \"error\"\n | \"success\";\n\nexport enum IcInformationStatus {\n Warning = \"warning\",\n Error = \"error\",\n Success = \"success\",\n}\n\nexport type IcSizes = \"default\" | \"large\" | \"small\";\n\nexport type IcSizesNoLarge = \"default\" | \"small\";\n\nexport type IcInformationStatusOrEmpty = \"warning\" | \"error\" | \"success\" | \"\";\n\nexport type IcNavType = \"side\" | \"top\" | \"page-header\";\n\n// From: https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete\nexport type IcAutocompleteTypes =\n | \"on\"\n | \"off\"\n | \"name\"\n | \"honorific-prefix\"\n | \"given-name\"\n | \"additional-name\"\n | \"family-name\"\n | \"honorific-suffix\"\n | \"nickname\"\n | \"email\"\n | \"username\"\n | \"new-password\"\n | \"current-password\"\n | \"one-time-code\"\n | \"organization-title\"\n | \"organization\"\n | \"street-address\"\n | \"address-line1\"\n | \"address-line2\"\n | \"address-line3\"\n | \"address-level4\"\n | \"address-level3\"\n | \"address-level2\"\n | \"address-level1\"\n | \"country\"\n | \"country-name\"\n | \"postal-code\"\n | \"cc-name\"\n | \"cc-given-name\"\n | \"cc-additional-name\"\n | \"cc-family-name\"\n | \"cc-family-name\"\n | \"cc-number\"\n | \"cc-exp\"\n | \"cc-exp-month\"\n | \"cc-exp-year\"\n | \"cc-csc\"\n | \"cc-type\"\n | \"transaction-currency\"\n | \"transaction-amount\"\n | \"language\"\n | \"bday\"\n | \"bday-day\"\n | \"bday-month\"\n | \"bday-year\"\n | \"sex\"\n | \"tel\"\n | \"tel-country-code\"\n | \"tel-national\"\n | \"tel-area-code\"\n | \"tel-local\"\n | \"tel-extension\"\n | \"impp\"\n | \"url\"\n | \"photo\";\n\nexport type IcAlignment = \"left\" | \"center\" | \"full-width\";\n\nexport enum IcThemeForegroundEnum {\n Default = \"default\",\n Dark = \"dark\",\n Light = \"light\",\n}\n\nexport type IcThemeForeground = \"default\" | \"dark\" | \"light\";\n\nexport type IcThemeForegroundNoDefault = \"dark\" | \"light\";\n\nexport type IcTheme = {\n mode: IcThemeForeground;\n color: IcColorRGB;\n};\n\nexport type IcAdditionalFieldTypes = \"static\" | \"dynamic\";\n\nexport type IcColorRGB = {\n r: number;\n g: number;\n b: number;\n};\n\nexport type IcColorRGBA = IcColorRGB & {\n a: number;\n};\n\nexport type IcActivationTypes = \"automatic\" | \"manual\";\n\nexport type IcAutocorrectStates = \"on\" | \"off\";\n\nexport type IcNavParentDetails = {\n navType: IcNavType | \"\";\n parent: HTMLElement;\n};\n\nexport type IcTypographyVariants =\n | \"h1\"\n | \"h2\"\n | \"h3\"\n | \"h4\"\n | \"subtitle-large\"\n | \"subtitle-small\"\n | \"body\"\n | \"label\"\n | \"label-uppercase\"\n | \"caption\"\n | \"caption-uppercase\"\n | \"code-large\"\n | \"code-small\"\n | \"code-extra-small\"\n | \"badge\"\n | \"badge-small\";\n\n/**\n * @interface IcMenuOption\n * @field {string} A label field to options. Defaults to \"label\", but can have any custom name.\n * @field {string} A value field to options. Defaults to \"value\", but can have any custom name.\n */\nexport interface IcMenuOption {\n description?: string;\n disabled?: boolean;\n recommended?: boolean;\n children?: IcMenuOption[];\n loading?: boolean;\n timedOut?: boolean;\n [key: string]: any;\n element?: {\n component: any;\n ariaLabel: string;\n };\n icon?: any;\n}\n\nexport type IcSearchMatchPositions = \"start\" | \"anywhere\";\n\nexport type IcCallbackFunctionNoReturn = (...args: unknown[]) => void;\n\nexport type IcRequiredPropsTypes =\n | string\n | boolean\n | number\n | HTMLElement\n | IcMenuOption[];\n\nexport type IcPropObject = { prop: IcRequiredPropsTypes; propName: string };\n\nexport type IcRelatedTarget = EventTarget | undefined;\n\nexport type IcOrientation = \"horizontal\" | \"vertical\";\n\nexport type IcEmphasisType = \"filled\" | \"outlined\";\n\nexport interface IcValueEventDetail {\n value: string;\n keyPressed?: string;\n}\nexport interface IcBlurEventDetail {\n relatedTarget: IcRelatedTarget;\n}\n\nexport type IcSelectTypes = \"single\" | \"multi\";\n\nexport type IcSelectMethodTypes = \"auto\" | \"manual\";\n\nexport type IcDeviceSizes = 0 | 576 | 768 | 992 | 1200;\n"],"mappings":"IAyBYA,GAAZ,SAAYA,GACVA,EAAA,qBACAA,EAAA,iBACAA,EAAA,oBACD,EAJD,CAAYA,MAAmB,K,IA0EnBC,GAAZ,SAAYA,GACVA,EAAA,qBACAA,EAAA,eACAA,EAAA,gBACD,EAJD,CAAYA,MAAqB,Y"}
|