@equisoft/design-elements-react 4.1.1-snapshot.20221025143557 → 4.1.1-snapshot.20221026185905
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.js +145 -111
- package/package.json +3 -3
package/dist/bundle.js
CHANGED
|
@@ -3,17 +3,21 @@
|
|
|
3
3
|
font-size: ${t?"0.75":"0.625"}rem;
|
|
4
4
|
height: ${t?"32":"24"}px;
|
|
5
5
|
letter-spacing: ${t?"0.013":"0.011"}rem;
|
|
6
|
-
width: ${t?"32":"24"}px
|
|
6
|
+
width: ${t?"32":"24"}px;
|
|
7
|
+
`;case"small":return u.css`
|
|
7
8
|
font-size: ${t?"0.875":"0.75"}rem;
|
|
8
9
|
height: ${t?"40":"32"}px;
|
|
9
10
|
letter-spacing: ${t?"0.014":"0.013"}rem;
|
|
10
|
-
width: ${t?"40":"32"}px
|
|
11
|
+
width: ${t?"40":"32"}px;
|
|
12
|
+
`;case"medium":return u.css`
|
|
11
13
|
font-size: 1rem;
|
|
12
14
|
height: 48px;
|
|
13
|
-
width: 48px
|
|
15
|
+
width: 48px;
|
|
16
|
+
`;case"large":return u.css`
|
|
14
17
|
font-size: 1.5rem;
|
|
15
18
|
height: ${t?"72":"80"}px;
|
|
16
|
-
width: ${t?"72":"80"}px
|
|
19
|
+
width: ${t?"72":"80"}px;
|
|
20
|
+
`}}const f=u.default.div`
|
|
17
21
|
align-items: center;
|
|
18
22
|
background: ${({bgColor:e,theme:t})=>null!=e?e:t.greys["light-grey"]};
|
|
19
23
|
border-radius: 50%;
|
|
@@ -49,14 +53,16 @@
|
|
|
49
53
|
position: absolute;
|
|
50
54
|
text-align: center;
|
|
51
55
|
${({$position:e,$offsetX:t,$offsetY:n})=>d(e,t,n)}
|
|
52
|
-
${({$animate:e,$position:t})=>e&&function(e){const t=d(e).transform||"",n=l.keyframes`
|
|
56
|
+
${({$animate:e,$position:t})=>e&&function(e){const t=d(e).transform||"",n=l.keyframes` /* stylelint-disable-line keyframes-name-pattern */
|
|
53
57
|
10% { transform: ${t} translateY(-4px); }
|
|
54
|
-
20% { transform: ${t}; }
|
|
58
|
+
20% { transform: ${t}; }
|
|
59
|
+
`;return l.css`
|
|
55
60
|
animation: ${n} 2s ease-in infinite;
|
|
56
61
|
|
|
57
62
|
@media (prefers-reduced-motion: reduce) {
|
|
58
63
|
animation: none;
|
|
59
|
-
}
|
|
64
|
+
}
|
|
65
|
+
`}(t)}
|
|
60
66
|
`,t.BadgeDot=(0,l.default)(t.BadgeCircle)`
|
|
61
67
|
height: 0.5rem;
|
|
62
68
|
min-width: 0.5rem;
|
|
@@ -90,7 +96,9 @@
|
|
|
90
96
|
right: 0;
|
|
91
97
|
width: initial;
|
|
92
98
|
|
|
93
|
-
|
|
99
|
+
/* stylelint-disable-next-line declaration-block-semicolon-newline-after,rule-empty-line-before */
|
|
100
|
+
${p.StyledNavItem},
|
|
101
|
+
${p.HtmlLink} {
|
|
94
102
|
height: 2.75rem;
|
|
95
103
|
padding: var(--spacing-1x) var(--spacing-4x);
|
|
96
104
|
}
|
|
@@ -101,8 +109,7 @@
|
|
|
101
109
|
}
|
|
102
110
|
|
|
103
111
|
${m.StyledHeading} {
|
|
104
|
-
margin: 0;
|
|
105
|
-
margin-bottom: var(--spacing-1x);
|
|
112
|
+
margin: 0 0 var(--spacing-1x);
|
|
106
113
|
padding: 0 var(--spacing-4x);
|
|
107
114
|
}
|
|
108
115
|
|
|
@@ -290,7 +297,7 @@
|
|
|
290
297
|
`,d=(0,o.default)(i.Link)`
|
|
291
298
|
background-color: ${({theme:e})=>e.greys.white};
|
|
292
299
|
border-radius: var(--border-radius-2x);
|
|
293
|
-
box-shadow: inset 0 0 0 1px ${({theme:e})=>e.greys.grey}, 0 1px 4px 0
|
|
300
|
+
box-shadow: inset 0 0 0 1px ${({theme:e})=>e.greys.grey}, 0 1px 4px 0 rgb(0 0 0 / 20%);
|
|
294
301
|
box-sizing: border-box;
|
|
295
302
|
color: ${({theme:e})=>e.greys.black};
|
|
296
303
|
display: block;
|
|
@@ -307,7 +314,7 @@
|
|
|
307
314
|
|
|
308
315
|
&:hover {
|
|
309
316
|
background-color: ${({theme:e})=>e.greys.grey};
|
|
310
|
-
box-shadow: inset 0 0 0 1px ${({theme:e})=>e.greys["dark-grey"]}, 0 1px 4px 0
|
|
317
|
+
box-shadow: inset 0 0 0 1px ${({theme:e})=>e.greys["dark-grey"]}, 0 1px 4px 0 rgb(0 0 0 / 20%);
|
|
311
318
|
|
|
312
319
|
${s} {
|
|
313
320
|
color: ${({theme:e})=>e.greys.black};
|
|
@@ -319,7 +326,7 @@
|
|
|
319
326
|
background: ${e=>e.theme.greys.white};
|
|
320
327
|
border: 1px solid ${e=>e.theme.greys["light-grey"]};
|
|
321
328
|
border-radius: var(--border-radius-2x);
|
|
322
|
-
box-shadow: 0 1px 4px 0
|
|
329
|
+
box-shadow: 0 1px 4px 0 rgb(0 0 0 / 20%);
|
|
323
330
|
box-sizing: border-box;
|
|
324
331
|
margin-bottom: var(--spacing-3x);
|
|
325
332
|
padding: ${({$noPadding:e})=>e?"0":"var(--spacing-3x) var(--spacing-4x) var(--spacing-4x)"};
|
|
@@ -497,6 +504,7 @@
|
|
|
497
504
|
border-color: ${({theme:e})=>e.greys["dark-grey"]};
|
|
498
505
|
cursor: pointer;
|
|
499
506
|
|
|
507
|
+
/* stylelint-disable-next-line declaration-block-semicolon-newline-after,rule-empty-line-before */
|
|
500
508
|
${t.Description},
|
|
501
509
|
${t.InputContainer} {
|
|
502
510
|
color: ${({theme:e})=>e.greys.black};
|
|
@@ -575,7 +583,7 @@
|
|
|
575
583
|
|
|
576
584
|
.react-datepicker {
|
|
577
585
|
border: 1px solid ${({theme:e})=>e.greys.grey};
|
|
578
|
-
box-shadow: 0 10px 20px 0
|
|
586
|
+
box-shadow: 0 10px 20px 0 rgb(0 0 0 / 19%);
|
|
579
587
|
font-family: var(--font-family);
|
|
580
588
|
padding: var(--spacing-3x) var(--spacing-2x);
|
|
581
589
|
}
|
|
@@ -612,7 +620,11 @@
|
|
|
612
620
|
box-sizing: border-box;
|
|
613
621
|
color: ${({theme:e})=>e.greys.black};
|
|
614
622
|
|
|
615
|
-
|
|
623
|
+
/* stylelint-disable-next-line declaration-colon-newline-after */
|
|
624
|
+
${({isMobile:e,theme:t})=>e&&p.css`
|
|
625
|
+
border: 1px solid ${t.main["primary-1.1"]};
|
|
626
|
+
box-shadow: ${t.tokens["focus-box-shadow"]};
|
|
627
|
+
`};
|
|
616
628
|
|
|
617
629
|
&:focus {
|
|
618
630
|
border: 1px solid ${({theme:e})=>e.main["primary-1.1"]};
|
|
@@ -645,6 +657,7 @@
|
|
|
645
657
|
background-color: ${({theme:e})=>e.main["primary-1.1"]};
|
|
646
658
|
border-radius: 50%;
|
|
647
659
|
|
|
660
|
+
/* stylelint-disable-next-line declaration-colon-newline-after */
|
|
648
661
|
${({isMobile:e,theme:t})=>e?`\n &[tabindex="0"] {\n box-shadow: ${t.tokens["focus-box-shadow"]};\n }\n `:`\n &:focus {\n box-shadow: ${t.tokens["focus-box-shadow"]};\n }\n `};
|
|
649
662
|
|
|
650
663
|
&:hover {
|
|
@@ -674,7 +687,7 @@
|
|
|
674
687
|
}
|
|
675
688
|
|
|
676
689
|
.react-datepicker__portal {
|
|
677
|
-
background-color:
|
|
690
|
+
background-color: rgb(0 0 0 / 50%);
|
|
678
691
|
|
|
679
692
|
.react-datepicker__day-name {
|
|
680
693
|
font-size: 1rem;
|
|
@@ -745,7 +758,7 @@
|
|
|
745
758
|
}
|
|
746
759
|
`,_=p.createGlobalStyle`
|
|
747
760
|
${m.default.toString()}
|
|
748
|
-
`;(0,c.registerLocale)("en-CA",s.enCA),(0,c.registerLocale)("en-US",s.enUS),(0,c.registerLocale)("fr-CA",s.frCA);const S=[s.enUS,s.enCA,s.frCA];t.Datepicker=(0,d.forwardRef)(((e,t)=>{var n,{className:a,dateFormat:r,disabled:i,firstDayOfWeek:l,hasTodayButton:s,hint:c,id:m,label:p,locale:T="en-CA",maxDate:P,minDate:H,noMargin:O,onBlur:V,onCalendarClose:q,onCalendarOpen:j,onChange:L,onFocus:A,open:D,placeholder:R,startDate:I,startOpen:W,tooltip:N,valid:z=!0,validationErrorMessage:Z}=e,B=o(e,["className","dateFormat","disabled","firstDayOfWeek","hasTodayButton","hint","id","label","locale","maxDate","minDate","noMargin","onBlur","onCalendarClose","onCalendarOpen","onChange","onFocus","open","placeholder","startDate","startOpen","tooltip","valid","validationErrorMessage"]);const{t:F}=(0,f.useTranslation)("datepicker"),{isMobile:$}=(0,v.useDeviceContext)(),[U,Y]=(0,d.useState)(I),K=(0,d.useMemo)((()=>(0,M.getLocale)(S,T)),[T]),X=(0,d.useMemo)((()=>(0,M.getLocaleMonthsShort)(K)),[K]),G=(0,d.useMemo)((()=>(0,M.getLocaleMonthsOptions)(K)),[K]),J=(0,d.useMemo)((()=>(0,M.getYearsOptions)(H,P)),[H,P]),Q=(0,d.useRef)(null),ee=(0,d.useMemo)((()=>m||(0,h.v4)()),[m]),te=(0,d.useRef)(null),ne=(0,d.useRef)(null);function ae(){setTimeout((()=>{var e;const t=null===(e=Q.current)||void 0===e?void 0:e.querySelector('.react-datepicker__day[tabindex="0"]');t&&t.focus()}),0)}(0,d.useImperativeHandle)(t,(()=>({reset:()=>{Y(I)},setDate:e=>{Y(e)}}))),(0,d.useEffect)((()=>{l&&(0,M.setLocaleFirstDayOfWeek)(K,l)}),[K,l]);const re=(0,d.useCallback)((e=>{Y(e),L&&L(e)}),[L]),ie=(0,d.useCallback)((()=>{var e;re(new Date),null===(e=te.current)||void 0===e||e.setOpen(!1)}),[re]),oe=(0,d.useMemo)((()=>R||(r?r.toUpperCase():(0,M.getLocaleDatePlaceholder)(K))),[K,R,r]),le=(0,d.useMemo)((()=>({children:e})=>(0,u.jsxs)("div",Object.assign({"aria-label":(null==U?void 0:U.toLocaleDateString(T))||F("calendarContainerLabel"),"aria-live":"polite","aria-modal":!0,className:"react-datepicker",role:"dialog",ref:Q},{children:[e,s&&(0,u.jsx)(C,{children:(0,u.jsx)(g.Button,{"aria-label":F("todayButtonAriaLabel"),buttonType:"secondary","data-testid":"today-button",label:F("todayButtonLabel"),type:"button",onClick:ie})})]}))),[ie,s,T,U,F]);return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(_,{}),(0,u.jsx)(y.FieldContainer,Object.assign({className:a,noMargin:O,fieldId:ee,label:p,tooltip:N,hint:c,valid:z,validationErrorMessage:Z||F("validationErrorMessage")},{children:(0,u.jsxs)(E,Object.assign({isMobile:$},{children:[(0,u.jsx)(k,Object.assign({customInput:(0,u.jsx)("input",{type:"text","data-testid":null!==(n=B["data-testid"])&&void 0!==n?n:"text-input"}),isMobile:$,id:ee,ref:te,renderCustomHeader:e=>(0,u.jsx)(w.CalendarHeader,Object.assign({months:X,monthsOptions:G,yearsOptions:J},e)),calendarContainer:le,className:"datePickerInput",dateFormat:r||(0,M.getLocaleDateFormat)(K),disabled:i,locale:T,maxDate:P||void 0,minDate:H||void 0,onChange:re,onSelect:function(){var e;null===(e=ne.current)||void 0===e||e.focus()},onBlur:function(e){var t,n;const a=null===(t=te.current)||void 0===t?void 0:t.isCalendarOpen();void 0!==a&&(null===(n=te.current)||void 0===n||n.setOpen(a,!1)),V&&V(e)},onCalendarClose:q,onCalendarOpen:j,onFocus:A,onInputClick:function(){var e;null===(e=te.current)||void 0===e||e.setOpen(!1,!0)},onKeyDown:function(e){var t,n;switch(e.key){case"ArrowUp":case"ArrowDown":case"ArrowLeft":case"ArrowRight":ae();break;case"Escape":e.stopPropagation(),null===(t=te.current)||void 0===t||t.setOpen(!1),null===(n=ne.current)||void 0===n||n.focus()}},open:D,placeholderText:oe,popperClassName:"popper",preventOpenOnFocus:!0,selected:U,showPopperArrow:!1,startOpen:W,valid:z,withPortal:$},B)),(0,u.jsx)(x,Object.assign({"aria-label":U?`${F("calendarButtonSelectedLabel")} ${U.toLocaleDateString(T)}`:F("calendarButtonLabel"),"data-testid":"calendar-button",type:"button",disabled:i,isMobile:$,onKeyDown:function(e){var t;"Enter"!==e.key&&" "!==e.key||(null===(t=te.current)||void 0===t||t.setOpen(!0),ae())},onMouseDown:function(e){var t,n,a;e.stopPropagation(),(null===(t=te.current)||void 0===t?void 0:t.isCalendarOpen())?null===(n=te.current)||void 0===n||n.setOpen(!1):(null===(a=te.current)||void 0===a||a.setOpen(!0),ae())},ref:ne,tabIndex:0},{children:(0,u.jsx)(b.Icon,{name:"calendar",size:$?"24":"16"})}))]}))}))]})})),t.Datepicker.displayName="Datepicker";try{Datepicker.displayName="Datepicker",Datepicker.__docgenInfo={description:"",displayName:"Datepicker",props:{className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},dateFormat:{defaultValue:null,description:"Sets date format (e.g.: dd/MM/yyyy).",name:"dateFormat",required:!1,type:{name:"string"}},"data-testid":{defaultValue:null,description:"",name:"data-testid",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},noMargin:{defaultValue:null,description:"Disables default margin",name:"noMargin",required:!1,type:{name:"boolean"}},firstDayOfWeek:{defaultValue:null,description:"",name:"firstDayOfWeek",required:!1,type:{name:"enum",value:[{value:"0"},{value:"1"},{value:"2"},{value:"3"},{value:"4"},{value:"5"},{value:"6"}]}},hasTodayButton:{defaultValue:null,description:"",name:"hasTodayButton",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"Sets input label",name:"label",required:!1,type:{name:"string"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},locale:{defaultValue:{value:"en-CA"},description:"Sets localization",name:"locale",required:!1,type:{name:"enum",value:[{value:'"fr-CA"'},{value:'"en-CA"'},{value:'"en-US"'}]}},maxDate:{defaultValue:null,description:"",name:"maxDate",required:!1,type:{name:"Date | null"}},minDate:{defaultValue:null,description:"",name:"minDate",required:!1,type:{name:"Date | null"}},name:{defaultValue:null,description:"Sets input name",name:"name",required:!1,type:{name:"string"}},open:{defaultValue:null,description:"Toggles calendar (controlled)",name:"open",required:!1,type:{name:"boolean"}},placeholder:{defaultValue:null,description:"",name:"placeholder",required:!1,type:{name:"string"}},readOnly:{defaultValue:null,description:"",name:"readOnly",required:!1,type:{name:"boolean"}},required:{defaultValue:null,description:"",name:"required",required:!1,type:{name:"boolean"}},startDate:{defaultValue:null,description:"Sets default selected date",name:"startDate",required:!1,type:{name:"Date | null"}},startOpen:{defaultValue:null,description:"Sets calendar initially open (uncontrolled)",name:"startOpen",required:!1,type:{name:"boolean"}},tabIndex:{defaultValue:null,description:"",name:"tabIndex",required:!1,type:{name:"number"}},valid:{defaultValue:{value:!0},description:"Sets input validity",name:"valid",required:!1,type:{name:"boolean"}},validationErrorMessage:{defaultValue:null,description:"Sets error message",name:"validationErrorMessage",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"Sets input value (controlled)",name:"value",required:!1,type:{name:"string"}},hint:{defaultValue:null,description:"",name:"hint",required:!1,type:{name:"string"}},onBlur:{defaultValue:null,description:"",name:"onBlur",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},onCalendarClose:{defaultValue:null,description:"",name:"onCalendarClose",required:!1,type:{name:"(() => void)"}},onCalendarOpen:{defaultValue:null,description:"",name:"onCalendarOpen",required:!1,type:{name:"(() => void)"}},onChange:{defaultValue:null,description:"",name:"onChange",required:!1,type:{name:"((date: Date) => void)"}},onFocus:{defaultValue:null,description:"",name:"onFocus",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},ref:{defaultValue:null,description:"",name:"ref",required:!1,type:{name:"Ref<DatepickerHandles>"}},key:{defaultValue:null,description:"",name:"key",required:!1,type:{name:"Key | null"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/datepicker/datepicker.tsx#Datepicker"]={docgenInfo:Datepicker.__docgenInfo,name:"Datepicker",path:"src/components/datepicker/datepicker.tsx#Datepicker"})}catch(e){}},1213:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setLocaleFirstDayOfWeek=t.getYearsOptions=t.getLocaleMonthsOptions=t.getLocaleDatePlaceholder=t.getLocaleDateFormat=t.getLocaleMonthsShort=t.getLocale=void 0;const a=n(5545),r=n(3225);function i(e=a.enCA){return new Intl.DateTimeFormat(e.code).formatToParts(new Date).map((e=>{switch(e.type){case"day":return"dd";case"month":return"MM";case"year":return"yyyy";default:return e.value}})).join("")}t.getLocale=function(e,t){return e.find((e=>e.code===t))||a.enCA},t.getLocaleMonthsShort=function(e){var t;const n=[];for(let a=0;a<12;a++)n.push(null===(t=e.localize)||void 0===t?void 0:t.month(a,{width:"abbreviated"}));return n},t.getLocaleDateFormat=i,t.getLocaleDatePlaceholder=function(e){return i(e).toUpperCase()},t.getLocaleMonthsOptions=function(e){var t,n;const a=[];for(let r=0;r<12;r++)a.push({value:null===(t=e.localize)||void 0===t?void 0:t.month(r).toLowerCase(),label:null===(n=e.localize)||void 0===n?void 0:n.month(r,{width:"abbreviated"})});return a},t.getYearsOptions=function(e,t){return e&&t&&e>t?[]:(0,r.range)(e?e.getUTCFullYear():1920,t?t.getUTCFullYear():(new Date).getUTCFullYear()).map((e=>({value:e.toString(),label:e.toString()})))},t.setLocaleFirstDayOfWeek=function(e,t){Object.assign(e.options||{},{weekStartsOn:t})}},8393:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DesignSystem=void 0;const a=n(348),r=n(7217),i=n(7510),o=n(8230),l=n(3216),u=e=>(0,a.jsx)(r.DeviceContextProvider,Object.assign({staticDevice:e.staticDevice},{children:(0,a.jsx)(o.ThemeWrapper,Object.assign({theme:e.theme,isolateStyles:e.isolateStyles},{children:(0,a.jsx)(i.IntlProvider,Object.assign({language:e.language},{children:(0,a.jsx)(l.ToastProvider,{children:e.children})}))}))}));t.DesignSystem=u;try{u.displayName="DesignSystem",u.__docgenInfo={description:"",displayName:"DesignSystem",props:{isolateStyles:{defaultValue:{value:"false"},description:"When true, components are mounted in the Shadow DOM",name:"isolateStyles",required:!1,type:{name:"boolean"}},theme:{defaultValue:null,description:"",name:"theme",required:!1,type:{name:"Theme"}},staticDevice:{defaultValue:null,description:"",name:"staticDevice",required:!1,type:{name:"enum",value:[{value:'"desktop"'},{value:'"tablet"'},{value:'"mobile"'}]}},language:{defaultValue:{value:"en"},description:"",name:"language",required:!1,type:{name:"string"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/design-system.tsx#DesignSystem"]={docgenInfo:u.__docgenInfo,name:"DesignSystem",path:"src/components/design-system.tsx#DesignSystem"})}catch(e){}},7217:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useDeviceContext=t.DeviceContextProvider=void 0;const a=n(348),r=n(8156),i=n(7480),o=e=>{let t=!1,n=!1,a=!1;const r={device:"desktop",isDesktop:!0,isTablet:!1,isMobile:!1,breakpoints:i.breakpoints};return e?("desktop"===e?t=!0:"tablet"===e?n=!0:"mobile"===e&&(a=!0),{device:e,isDesktop:t,isTablet:n,isMobile:a,breakpoints:i.breakpoints}):r},l=(0,r.createContext)(o()),u=({children:e,staticDevice:t})=>{const[n,u]=(0,r.useState)(o(t));function s(){const e=(e=>{let t="desktop";return e>=i.breakpoints.desktop?t="desktop":e<i.breakpoints.desktop&&e>i.breakpoints.mobile?t="tablet":e<=i.breakpoints.mobile&&(t="mobile"),t})(window.innerWidth||document.documentElement.clientWidth);u(o(e))}return(0,r.useEffect)((()=>{if(!t)return s(),window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}}),[t]),(0,a.jsx)(l.Provider,Object.assign({value:n},{children:e}))};t.DeviceContextProvider=u,t.useDeviceContext=function(){return(0,r.useContext)(l)};try{u.displayName="DeviceContextProvider",u.__docgenInfo={description:"",displayName:"DeviceContextProvider",props:{staticDevice:{defaultValue:null,description:"",name:"staticDevice",required:!1,type:{name:"enum",value:[{value:'"desktop"'},{value:'"tablet"'},{value:'"mobile"'}]}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/device-context-provider/device-context-provider.tsx#DeviceContextProvider"]={docgenInfo:u.__docgenInfo,name:"DeviceContextProvider",path:"src/components/device-context-provider/device-context-provider.tsx#DeviceContextProvider"})}catch(e){}},6284:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.DropdownMenuButton=t.StyledDropdownMenu=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(210),d=n(6443),c=n(2868),m=n(1785),p=n(1829),f=n(3859),h=n(7217),g=n(2805),v=n(2082),y=l.default.div`
|
|
761
|
+
`;(0,c.registerLocale)("en-CA",s.enCA),(0,c.registerLocale)("en-US",s.enUS),(0,c.registerLocale)("fr-CA",s.frCA);const S=[s.enUS,s.enCA,s.frCA];t.Datepicker=(0,d.forwardRef)(((e,t)=>{var n,{className:a,dateFormat:r,disabled:i,firstDayOfWeek:l,hasTodayButton:s,hint:c,id:m,label:p,locale:T="en-CA",maxDate:P,minDate:H,noMargin:O,onBlur:V,onCalendarClose:q,onCalendarOpen:j,onChange:L,onFocus:A,open:D,placeholder:R,startDate:I,startOpen:W,tooltip:N,valid:z=!0,validationErrorMessage:Z}=e,B=o(e,["className","dateFormat","disabled","firstDayOfWeek","hasTodayButton","hint","id","label","locale","maxDate","minDate","noMargin","onBlur","onCalendarClose","onCalendarOpen","onChange","onFocus","open","placeholder","startDate","startOpen","tooltip","valid","validationErrorMessage"]);const{t:F}=(0,f.useTranslation)("datepicker"),{isMobile:$}=(0,v.useDeviceContext)(),[U,Y]=(0,d.useState)(I),K=(0,d.useMemo)((()=>(0,M.getLocale)(S,T)),[T]),X=(0,d.useMemo)((()=>(0,M.getLocaleMonthsShort)(K)),[K]),G=(0,d.useMemo)((()=>(0,M.getLocaleMonthsOptions)(K)),[K]),J=(0,d.useMemo)((()=>(0,M.getYearsOptions)(H,P)),[H,P]),Q=(0,d.useRef)(null),ee=(0,d.useMemo)((()=>m||(0,h.v4)()),[m]),te=(0,d.useRef)(null),ne=(0,d.useRef)(null);function ae(){setTimeout((()=>{var e;const t=null===(e=Q.current)||void 0===e?void 0:e.querySelector('.react-datepicker__day[tabindex="0"]');t&&t.focus()}),0)}(0,d.useImperativeHandle)(t,(()=>({reset:()=>{Y(I)},setDate:e=>{Y(e)}}))),(0,d.useEffect)((()=>{l&&(0,M.setLocaleFirstDayOfWeek)(K,l)}),[K,l]);const re=(0,d.useCallback)((e=>{Y(e),L&&L(e)}),[L]),ie=(0,d.useCallback)((()=>{var e;re(new Date),null===(e=te.current)||void 0===e||e.setOpen(!1)}),[re]),oe=(0,d.useMemo)((()=>R||(r?r.toUpperCase():(0,M.getLocaleDatePlaceholder)(K))),[K,R,r]),le=(0,d.useMemo)((()=>({children:e})=>(0,u.jsxs)("div",Object.assign({"aria-label":(null==U?void 0:U.toLocaleDateString(T))||F("calendarContainerLabel"),"aria-live":"polite","aria-modal":!0,className:"react-datepicker",role:"dialog",ref:Q},{children:[e,s&&(0,u.jsx)(C,{children:(0,u.jsx)(g.Button,{"aria-label":F("todayButtonAriaLabel"),buttonType:"secondary","data-testid":"today-button",label:F("todayButtonLabel"),type:"button",onClick:ie})})]}))),[ie,s,T,U,F]);return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(_,{}),(0,u.jsx)(y.FieldContainer,Object.assign({className:a,noMargin:O,fieldId:ee,label:p,tooltip:N,hint:c,valid:z,validationErrorMessage:Z||F("validationErrorMessage")},{children:(0,u.jsxs)(E,Object.assign({isMobile:$},{children:[(0,u.jsx)(k,Object.assign({customInput:(0,u.jsx)("input",{type:"text","data-testid":null!==(n=B["data-testid"])&&void 0!==n?n:"text-input"}),isMobile:$,id:ee,ref:te,renderCustomHeader:e=>(0,u.jsx)(w.CalendarHeader,Object.assign({months:X,monthsOptions:G,yearsOptions:J},e)),calendarContainer:le,className:"datePickerInput",dateFormat:r||(0,M.getLocaleDateFormat)(K),disabled:i,locale:T,maxDate:P||void 0,minDate:H||void 0,onChange:re,onSelect:function(){var e;null===(e=ne.current)||void 0===e||e.focus()},onBlur:function(e){var t,n;const a=null===(t=te.current)||void 0===t?void 0:t.isCalendarOpen();void 0!==a&&(null===(n=te.current)||void 0===n||n.setOpen(a,!1)),V&&V(e)},onCalendarClose:q,onCalendarOpen:j,onFocus:A,onInputClick:function(){var e;null===(e=te.current)||void 0===e||e.setOpen(!1,!0)},onKeyDown:function(e){var t,n;switch(e.key){case"ArrowUp":case"ArrowDown":case"ArrowLeft":case"ArrowRight":ae();break;case"Escape":e.stopPropagation(),null===(t=te.current)||void 0===t||t.setOpen(!1),null===(n=ne.current)||void 0===n||n.focus()}},open:D,placeholderText:oe,popperClassName:"popper",preventOpenOnFocus:!0,selected:U,showPopperArrow:!1,startOpen:W,valid:z,withPortal:$},B)),(0,u.jsx)(x,Object.assign({"aria-label":U?`${F("calendarButtonSelectedLabel")} ${U.toLocaleDateString(T)}`:F("calendarButtonLabel"),"data-testid":"calendar-button",type:"button",disabled:i,isMobile:$,onKeyDown:function(e){var t;"Enter"!==e.key&&" "!==e.key||(null===(t=te.current)||void 0===t||t.setOpen(!0),ae())},onMouseDown:function(e){var t,n,a;e.stopPropagation(),(null===(t=te.current)||void 0===t?void 0:t.isCalendarOpen())?null===(n=te.current)||void 0===n||n.setOpen(!1):(null===(a=te.current)||void 0===a||a.setOpen(!0),ae())},ref:ne,tabIndex:0},{children:(0,u.jsx)(b.Icon,{name:"calendar",size:$?"24":"16"})}))]}))}))]})})),t.Datepicker.displayName="Datepicker";try{Datepicker.displayName="Datepicker",Datepicker.__docgenInfo={description:"",displayName:"Datepicker",props:{className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},dateFormat:{defaultValue:null,description:"Sets date format (e.g.: dd/MM/yyyy).",name:"dateFormat",required:!1,type:{name:"string"}},"data-testid":{defaultValue:null,description:"",name:"data-testid",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},noMargin:{defaultValue:null,description:"Disables default margin",name:"noMargin",required:!1,type:{name:"boolean"}},firstDayOfWeek:{defaultValue:null,description:"",name:"firstDayOfWeek",required:!1,type:{name:"enum",value:[{value:"0"},{value:"1"},{value:"2"},{value:"3"},{value:"4"},{value:"5"},{value:"6"}]}},hasTodayButton:{defaultValue:null,description:"",name:"hasTodayButton",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"Sets input label",name:"label",required:!1,type:{name:"string"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},locale:{defaultValue:{value:"en-CA"},description:"Sets localization",name:"locale",required:!1,type:{name:"enum",value:[{value:'"fr-CA"'},{value:'"en-CA"'},{value:'"en-US"'}]}},maxDate:{defaultValue:null,description:"",name:"maxDate",required:!1,type:{name:"Date | null"}},minDate:{defaultValue:null,description:"",name:"minDate",required:!1,type:{name:"Date | null"}},name:{defaultValue:null,description:"Sets input name",name:"name",required:!1,type:{name:"string"}},open:{defaultValue:null,description:"Toggles calendar (controlled)",name:"open",required:!1,type:{name:"boolean"}},placeholder:{defaultValue:null,description:"",name:"placeholder",required:!1,type:{name:"string"}},readOnly:{defaultValue:null,description:"",name:"readOnly",required:!1,type:{name:"boolean"}},required:{defaultValue:null,description:"",name:"required",required:!1,type:{name:"boolean"}},startDate:{defaultValue:null,description:"Sets default selected date",name:"startDate",required:!1,type:{name:"Date | null"}},startOpen:{defaultValue:null,description:"Sets calendar initially open (uncontrolled)",name:"startOpen",required:!1,type:{name:"boolean"}},tabIndex:{defaultValue:null,description:"",name:"tabIndex",required:!1,type:{name:"number"}},valid:{defaultValue:{value:!0},description:"Sets input validity",name:"valid",required:!1,type:{name:"boolean"}},validationErrorMessage:{defaultValue:null,description:"Sets error message",name:"validationErrorMessage",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"Sets input value (controlled)",name:"value",required:!1,type:{name:"string"}},hint:{defaultValue:null,description:"",name:"hint",required:!1,type:{name:"string"}},onBlur:{defaultValue:null,description:"",name:"onBlur",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},onCalendarClose:{defaultValue:null,description:"",name:"onCalendarClose",required:!1,type:{name:"(() => void)"}},onCalendarOpen:{defaultValue:null,description:"",name:"onCalendarOpen",required:!1,type:{name:"(() => void)"}},onChange:{defaultValue:null,description:"",name:"onChange",required:!1,type:{name:"((date: Date) => void)"}},onFocus:{defaultValue:null,description:"",name:"onFocus",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},ref:{defaultValue:null,description:"",name:"ref",required:!1,type:{name:"Ref<DatepickerHandles>"}},key:{defaultValue:null,description:"",name:"key",required:!1,type:{name:"Key | null"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/datepicker/datepicker.tsx#Datepicker"]={docgenInfo:Datepicker.__docgenInfo,name:"Datepicker",path:"src/components/datepicker/datepicker.tsx#Datepicker"})}catch(e){}},1213:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setLocaleFirstDayOfWeek=t.getYearsOptions=t.getLocaleMonthsOptions=t.getLocaleDatePlaceholder=t.getLocaleDateFormat=t.getLocaleMonthsShort=t.getLocale=void 0;const a=n(5545),r=n(3225);function i(e=a.enCA){return new Intl.DateTimeFormat(e.code).formatToParts(new Date).map((e=>{switch(e.type){case"day":return"dd";case"month":return"MM";case"year":return"yyyy";default:return e.value}})).join("")}t.getLocale=function(e,t){return e.find((e=>e.code===t))||a.enCA},t.getLocaleMonthsShort=function(e){var t;const n=[];for(let a=0;a<12;a++)n.push(null===(t=e.localize)||void 0===t?void 0:t.month(a,{width:"abbreviated"}));return n},t.getLocaleDateFormat=i,t.getLocaleDatePlaceholder=function(e){return i(e).toUpperCase()},t.getLocaleMonthsOptions=function(e){var t,n;const a=[];for(let r=0;r<12;r++)a.push({value:null===(t=e.localize)||void 0===t?void 0:t.month(r).toLowerCase(),label:null===(n=e.localize)||void 0===n?void 0:n.month(r,{width:"abbreviated"})});return a},t.getYearsOptions=function(e,t){return e&&t&&e>t?[]:(0,r.range)(e?e.getUTCFullYear():1920,t?t.getUTCFullYear():(new Date).getUTCFullYear()).map((e=>({value:e.toString(),label:e.toString()})))},t.setLocaleFirstDayOfWeek=function(e,t){const n={weekStartsOn:t};Object.assign(e.options||{},n)}},8393:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DesignSystem=void 0;const a=n(348),r=n(7217),i=n(7510),o=n(8230),l=n(3216),u=e=>(0,a.jsx)(r.DeviceContextProvider,Object.assign({staticDevice:e.staticDevice},{children:(0,a.jsx)(o.ThemeWrapper,Object.assign({theme:e.theme,isolateStyles:e.isolateStyles},{children:(0,a.jsx)(i.IntlProvider,Object.assign({language:e.language},{children:(0,a.jsx)(l.ToastProvider,{children:e.children})}))}))}));t.DesignSystem=u;try{u.displayName="DesignSystem",u.__docgenInfo={description:"",displayName:"DesignSystem",props:{isolateStyles:{defaultValue:{value:"false"},description:"When true, components are mounted in the Shadow DOM",name:"isolateStyles",required:!1,type:{name:"boolean"}},theme:{defaultValue:null,description:"",name:"theme",required:!1,type:{name:"Theme"}},staticDevice:{defaultValue:null,description:"",name:"staticDevice",required:!1,type:{name:"enum",value:[{value:'"desktop"'},{value:'"tablet"'},{value:'"mobile"'}]}},language:{defaultValue:{value:"en"},description:"",name:"language",required:!1,type:{name:"string"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/design-system.tsx#DesignSystem"]={docgenInfo:u.__docgenInfo,name:"DesignSystem",path:"src/components/design-system.tsx#DesignSystem"})}catch(e){}},7217:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useDeviceContext=t.DeviceContextProvider=void 0;const a=n(348),r=n(8156),i=n(7480),o=e=>{let t=!1,n=!1,a=!1;const r={device:"desktop",isDesktop:!0,isTablet:!1,isMobile:!1,breakpoints:i.breakpoints};return e?("desktop"===e?t=!0:"tablet"===e?n=!0:"mobile"===e&&(a=!0),{device:e,isDesktop:t,isTablet:n,isMobile:a,breakpoints:i.breakpoints}):r},l=(0,r.createContext)(o()),u=({children:e,staticDevice:t})=>{const[n,u]=(0,r.useState)(o(t));function s(){const e=(e=>{let t="desktop";return e>=i.breakpoints.desktop?t="desktop":e<i.breakpoints.desktop&&e>i.breakpoints.mobile?t="tablet":e<=i.breakpoints.mobile&&(t="mobile"),t})(window.innerWidth||document.documentElement.clientWidth);u(o(e))}return(0,r.useEffect)((()=>{if(!t)return s(),window.addEventListener("resize",s),()=>{window.removeEventListener("resize",s)}}),[t]),(0,a.jsx)(l.Provider,Object.assign({value:n},{children:e}))};t.DeviceContextProvider=u,t.useDeviceContext=function(){return(0,r.useContext)(l)};try{u.displayName="DeviceContextProvider",u.__docgenInfo={description:"",displayName:"DeviceContextProvider",props:{staticDevice:{defaultValue:null,description:"",name:"staticDevice",required:!1,type:{name:"enum",value:[{value:'"desktop"'},{value:'"tablet"'},{value:'"mobile"'}]}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/device-context-provider/device-context-provider.tsx#DeviceContextProvider"]={docgenInfo:u.__docgenInfo,name:"DeviceContextProvider",path:"src/components/device-context-provider/device-context-provider.tsx#DeviceContextProvider"})}catch(e){}},6284:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.DropdownMenuButton=t.StyledDropdownMenu=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(210),d=n(6443),c=n(2868),m=n(1785),p=n(1829),f=n(3859),h=n(7217),g=n(2805),v=n(2082),y=l.default.div`
|
|
749
762
|
position: relative;
|
|
750
763
|
`,b=(0,l.default)(p.Button)`
|
|
751
764
|
font-size: 0.875rem;
|
|
@@ -819,8 +832,7 @@
|
|
|
819
832
|
border: 1px solid ${({theme:e})=>e.greys.grey};
|
|
820
833
|
border-radius: var(--border-radius);
|
|
821
834
|
flex-shrink: 0;
|
|
822
|
-
margin: 2px 0;
|
|
823
|
-
margin-right: var(--spacing-1x);
|
|
835
|
+
margin: 2px var(--spacing-1x) 2px 0;
|
|
824
836
|
padding: var(--spacing-1x);
|
|
825
837
|
`,s=i.default.div`
|
|
826
838
|
align-items: center;
|
|
@@ -828,8 +840,7 @@
|
|
|
828
840
|
max-width: 100%;
|
|
829
841
|
`,d=i.default.span`
|
|
830
842
|
line-height: 1.25rem;
|
|
831
|
-
margin: auto 0;
|
|
832
|
-
margin-right: var(--spacing-1x);
|
|
843
|
+
margin: auto var(--spacing-1x) auto 0;
|
|
833
844
|
overflow: hidden;
|
|
834
845
|
text-overflow: ellipsis;
|
|
835
846
|
white-space: nowrap;
|
|
@@ -844,14 +855,12 @@
|
|
|
844
855
|
`,p=i.default.span`
|
|
845
856
|
align-items: center;
|
|
846
857
|
display: flex;
|
|
847
|
-
flex-
|
|
848
|
-
flex-wrap: wrap;
|
|
858
|
+
flex-flow: row wrap;
|
|
849
859
|
font-size: ${({$smallLabel:e,$device:{isTablet:t,isMobile:n}})=>e?t||n?"0.875rem":"0.75rem":t||n?"1rem":"0.875rem"};
|
|
850
860
|
height: 100%;
|
|
851
861
|
margin: 0;
|
|
852
862
|
overflow: hidden;
|
|
853
|
-
padding: 0;
|
|
854
|
-
padding-left: var(--spacing-half);
|
|
863
|
+
padding: 0 0 0 var(--spacing-half);
|
|
855
864
|
`,f=({device:e,description:t,iconName:n,label:a,lozenge:i,smallLabel:o=!1})=>(0,r.jsxs)(r.Fragment,{children:[n&&(0,r.jsx)(u,{"aria-hidden":"true",size:"22",name:n}),(0,r.jsxs)(p,Object.assign({$device:e,$smallLabel:o},{children:[(0,r.jsxs)(s,{children:[(0,r.jsx)(d,{children:a}),i&&(0,r.jsx)(m,{children:i})]}),t&&(0,r.jsx)(c,Object.assign({$device:e},{children:t}))]}))]});t.ItemContent=f;try{f.displayName="ItemContent",f.__docgenInfo={description:"",displayName:"ItemContent",props:{device:{defaultValue:null,description:"",name:"device",required:!0,type:{name:"DeviceContextProps"}},smallLabel:{defaultValue:{value:!1},description:"",name:"smallLabel",required:!1,type:{name:"boolean"}},description:{defaultValue:null,description:"",name:"description",required:!1,type:{name:"string"}},iconName:{defaultValue:null,description:"",name:"iconName",required:!1,type:{name:"enum",value:[{value:'"alertCircle"'},{value:'"alertFilled"'},{value:'"alertTriangle"'},{value:'"alertOctagon"'},{value:'"arrowDown"'},{value:'"arrowLeft"'},{value:'"arrowRight"'},{value:'"arrowUp"'},{value:'"bell"'},{value:'"bento"'},{value:'"calendar"'},{value:'"check"'},{value:'"chevronDown"'},{value:'"chevronLeft"'},{value:'"chevronRight"'},{value:'"chevronUp"'},{value:'"chevronsLeft"'},{value:'"chevronsRight"'},{value:'"circle"'},{value:'"contracts"'},{value:'"copy"'},{value:'"edit"'},{value:'"equisoft"'},{value:'"externalLink"'},{value:'"eye"'},{value:'"eyeOff"'},{value:'"files"'},{value:'"helpCircle"'},{value:'"history"'},{value:'"home"'},{value:'"info"'},{value:'"mail"'},{value:'"mapPin"'},{value:'"megaphone"'},{value:'"menu"'},{value:'"minus"'},{value:'"moreHorizontal"'},{value:'"moreVertical"'},{value:'"organization"'},{value:'"open"'},{value:'"phone"'},{value:'"plusSign"'},{value:'"reorder"'},{value:'"search"'},{value:'"settings"'},{value:'"star"'},{value:'"transfer"'},{value:'"trash"'},{value:'"user"'},{value:'"users"'},{value:'"warningFilled"'},{value:'"x"'}]}},label:{defaultValue:null,description:"",name:"label",required:!0,type:{name:"string"}},lozenge:{defaultValue:null,description:"",name:"lozenge",required:!1,type:{name:"string"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/dropdown-menu/list-items/item-content.tsx#ItemContent"]={docgenInfo:f.__docgenInfo,name:"ItemContent",path:"src/components/dropdown-menu/list-items/item-content.tsx#ItemContent"})}catch(e){}},7864:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.LabelItem=t.StyledListItem=void 0;const r=n(348),i=a(n(1608)),o=n(7217),l=n(9041);t.StyledListItem=i.default.li`
|
|
856
865
|
color: ${({theme:e})=>e.greys.black};
|
|
857
866
|
display: block;
|
|
@@ -978,8 +987,7 @@
|
|
|
978
987
|
background-color: ${p};
|
|
979
988
|
color: ${function({bannerType:e,theme:t}){switch(e){case"alert":case"info":case"default":return t.greys.white;case"warning":return t.greys.black}}};
|
|
980
989
|
display: flex;
|
|
981
|
-
flex-
|
|
982
|
-
flex-wrap: ${({isMobile:e})=>e?"nowrap":"wrap"};
|
|
990
|
+
flex-flow: ${({isMobile:e})=>e?"column nowrap":"row rap"};
|
|
983
991
|
font-size: ${({isMobile:e})=>e?1:.875}rem;
|
|
984
992
|
justify-content: space-between;
|
|
985
993
|
letter-spacing: ${({isMobile:e})=>e?.02875:.0125}rem;
|
|
@@ -988,25 +996,27 @@
|
|
|
988
996
|
position: relative;
|
|
989
997
|
`,v=u.default.div`
|
|
990
998
|
align-items: center;
|
|
999
|
+
align-self: ${({isMobile:e})=>e?"flex-start":null};
|
|
991
1000
|
display: flex;
|
|
992
1001
|
justify-content: ${({isMobile:e})=>e?"unset":"center"};
|
|
993
1002
|
margin-top: ${({isMobile:e})=>e?"0":"var(--spacing-1x)"};
|
|
994
1003
|
position: relative;
|
|
995
|
-
|
|
996
|
-
${({isMobile:e})=>e&&u.css`align-self: flex-start;`};
|
|
997
1004
|
`,y=(0,u.default)(m.Icon)`
|
|
998
1005
|
flex-shrink: 0;
|
|
999
1006
|
margin-right: var(--spacing-1x);
|
|
1000
1007
|
|
|
1001
|
-
${(
|
|
1008
|
+
${function(e){return e.$isMobile?u.css`
|
|
1009
|
+
align-self: flex-start;
|
|
1010
|
+
`:u.css`
|
|
1002
1011
|
left: calc(var(--spacing-3x) * -1);
|
|
1003
1012
|
position: absolute;
|
|
1004
1013
|
top: var(--spacing-half);
|
|
1005
|
-
`};
|
|
1014
|
+
`}};
|
|
1006
1015
|
`,b=u.default.span`
|
|
1007
1016
|
letter-spacing: 0.015rem;
|
|
1008
1017
|
margin: 0;
|
|
1009
1018
|
`;function w({bannerType:e,theme:t}){switch(e){case"alert":return"#f99d99";case"warning":return"#9e6900";case"info":return"#cfc1e3";case"default":return t.greys["mid-grey"]}}const M=(0,u.default)(d.Button).attrs({buttonType:"secondary",inverted:!0})`
|
|
1019
|
+
/* stylelint-disable-next-line declaration-colon-newline-after */
|
|
1010
1020
|
${({bannerType:e,theme:t})=>"warning"===e&&u.css`
|
|
1011
1021
|
border-color: ${t.greys.black};
|
|
1012
1022
|
color: ${t.greys.black};
|
|
@@ -1019,19 +1029,21 @@
|
|
|
1019
1029
|
|
|
1020
1030
|
&:focus {
|
|
1021
1031
|
background-color: ${p};
|
|
1022
|
-
${({bannerType:e,theme:t})=>"warning"===e&&u.css`
|
|
1032
|
+
${({bannerType:e,theme:t})=>"warning"===e&&u.css`
|
|
1033
|
+
color: ${t.greys.black};
|
|
1034
|
+
`}
|
|
1023
1035
|
}
|
|
1024
1036
|
`,E=(0,u.default)(d.Button).attrs({buttonType:"tertiary",inverted:!0})`
|
|
1025
|
-
${({bannerType:e,theme:t})=>"warning"===e&&
|
|
1037
|
+
color: ${({bannerType:e,theme:t})=>"warning"===e&&t.greys.black};
|
|
1026
1038
|
|
|
1027
1039
|
&:focus {
|
|
1028
1040
|
background-color: ${p};
|
|
1029
|
-
${({bannerType:e,theme:t})=>"warning"===e&&
|
|
1041
|
+
color: ${({bannerType:e,theme:t})=>"warning"===e&&t.greys.black};
|
|
1030
1042
|
}
|
|
1031
1043
|
|
|
1032
1044
|
&:hover {
|
|
1033
1045
|
background-color: ${function({bannerType:e}){switch(e){case"alert":return"#7b1a15";case"warning":return"#9e6900";case"info":return"#3a1c60";case"default":return"#878f9a"}}};
|
|
1034
|
-
${({bannerType:e,theme:t})=>"warning"===e&&
|
|
1046
|
+
color: ${({bannerType:e,theme:t})=>"warning"===e&&t.greys.white};
|
|
1035
1047
|
}
|
|
1036
1048
|
`,k=u.default.div`
|
|
1037
1049
|
display: flex;
|
|
@@ -1084,6 +1096,7 @@
|
|
|
1084
1096
|
text-decoration: none;
|
|
1085
1097
|
|
|
1086
1098
|
${s.focus}
|
|
1099
|
+
|
|
1087
1100
|
> * {
|
|
1088
1101
|
height: 100%;
|
|
1089
1102
|
}
|
|
@@ -1118,7 +1131,7 @@
|
|
|
1118
1131
|
}
|
|
1119
1132
|
`,w=({appName:e="default",appTitleDesktop:t,children:n,className:a,customLogo:r,logoHref:i="/",mobileDrawerContent:l,skipLink:u,usesReactRouter:s=!0})=>{const{device:c,isMobile:h}=(0,d.useDeviceContext)(),w=null!=r?r:(0,o.jsx)(p.Logo,{name:e,mobile:h});function M(){return(0,o.jsxs)(o.Fragment,{children:[w,!h&&t&&(0,o.jsx)(y,Object.assign({"data-testid":"app-title"},{children:t}))]})}return(0,o.jsxs)(f,Object.assign({className:a,device:c},{children:[u&&(0,o.jsx)(b,Object.assign({"data-testid":"skip-link"},u)),s?(0,o.jsx)(g,Object.assign({"data-testid":"logo-react-router-link",to:i},{children:M()})):(0,o.jsx)(v,Object.assign({"data-testid":"logo-html-link",href:i},{children:M()})),(0,o.jsx)(m.Content,Object.assign({mobileDrawerContent:l},{children:n}))]}))};t.GlobalHeader=w;try{w.displayName="GlobalHeader",w.__docgenInfo={description:"",displayName:"GlobalHeader",props:{appName:{defaultValue:{value:"default"},description:"Set the app name to get the proper logos",name:"appName",required:!1,type:{name:"enum",value:[{value:'"default"'},{value:'"analyze"'},{value:'"apply"'},{value:'"centralize"'},{value:'"connect"'},{value:'"design"'},{value:'"illustrate"'},{value:'"manage"'},{value:'"plan"'}]}},appTitleDesktop:{defaultValue:null,description:"Sets app title which appears next to logo on desktop",name:"appTitleDesktop",required:!1,type:{name:"string"}},children:{defaultValue:null,description:"Right-side content",name:"children",required:!1,type:{name:"ReactNode"}},className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},customLogo:{defaultValue:null,description:"",name:"customLogo",required:!1,type:{name:"ReactNode"}},logoHref:{defaultValue:{value:"/"},description:"Sets logo href",name:"logoHref",required:!1,type:{name:"string"}},mobileDrawerContent:{defaultValue:null,description:"What will be displayed inside the mobile drawer",name:"mobileDrawerContent",required:!1,type:{name:"ReactNode"}},skipLink:{defaultValue:null,description:"",name:"skipLink",required:!1,type:{name:"SkipLinkProps"}},usesReactRouter:{defaultValue:{value:!0},description:"",name:"usesReactRouter",required:!1,type:{name:"boolean"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/global-header/global-header.tsx#GlobalHeader"]={docgenInfo:w.__docgenInfo,name:"GlobalHeader",path:"src/components/global-header/global-header.tsx#GlobalHeader"})}catch(e){}},4521:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Logo=void 0;const r=n(348),i=a(n(6459)),o=a(n(2985)),l=a(n(2347)),u=a(n(7916)),s=a(n(3235)),d=a(n(4059)),c=a(n(2904)),m=a(n(6808)),p=a(n(6066)),f=a(n(5279)),h=a(n(3642)),g=a(n(4657)),v=a(n(6164)),y=a(n(9778)),b=a(n(5148)),w=a(n(989)),M=a(n(9e3)),E={default:{desktop:v.default,mobile:v.default},analyze:{desktop:o.default,mobile:i.default},apply:{desktop:u.default,mobile:l.default},centralize:{desktop:d.default,mobile:s.default},connect:{desktop:m.default,mobile:c.default},design:{desktop:f.default,mobile:p.default},illustrate:{desktop:g.default,mobile:h.default},manage:{desktop:b.default,mobile:y.default},plan:{desktop:M.default,mobile:w.default}},k=({name:e="default",mobile:t=!1})=>{const n=E[e][t?"mobile":"desktop"];return(0,r.jsx)(n,{style:{height:"100%"},focusable:"false","aria-hidden":"true"})};t.Logo=k;try{k.displayName="Logo",k.__docgenInfo={description:"",displayName:"Logo",props:{name:{defaultValue:{value:"default"},description:"",name:"name",required:!1,type:{name:"enum",value:[{value:'"default"'},{value:'"analyze"'},{value:'"apply"'},{value:'"centralize"'},{value:'"connect"'},{value:'"design"'},{value:'"illustrate"'},{value:'"manage"'},{value:'"plan"'}]}},mobile:{defaultValue:{value:!1},description:"",name:"mobile",required:!1,type:{name:"boolean"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/global-header/logo.tsx#Logo"]={docgenInfo:k.__docgenInfo,name:"Logo",path:"src/components/global-header/logo.tsx#Logo"})}catch(e){}},9682:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.GlobalNavigation=void 0;const r=n(348),i=n(8156),o=n(6128),l=a(n(1608)),u=n(6784),s=n(2868),d=n(3859),c=n(2082),m=l.default.div`
|
|
1120
1133
|
background-color: ${({theme:e})=>e.greys.white};
|
|
1121
|
-
box-shadow: 0 6px 10px 0
|
|
1134
|
+
box-shadow: 0 6px 10px 0 rgb(0 0 0 / 10%);
|
|
1122
1135
|
box-sizing: border-box;
|
|
1123
1136
|
display: flex;
|
|
1124
1137
|
flex-direction: column;
|
|
@@ -1154,7 +1167,7 @@
|
|
|
1154
1167
|
`,h=l.default.ul`
|
|
1155
1168
|
background-color: ${e=>e.theme.greys.white};
|
|
1156
1169
|
border-radius: var(--border-radius);
|
|
1157
|
-
box-shadow: 0 6px 10px 0
|
|
1170
|
+
box-shadow: 0 6px 10px 0 rgb(0 0 0 / 10%);
|
|
1158
1171
|
display: ${({open:e})=>e?"flex":"none"};
|
|
1159
1172
|
flex-wrap: wrap;
|
|
1160
1173
|
left: 72px;
|
|
@@ -1194,11 +1207,10 @@
|
|
|
1194
1207
|
background-color: ${e=>e.theme.greys.grey};
|
|
1195
1208
|
color: ${e=>e.theme.greys.black};
|
|
1196
1209
|
}
|
|
1197
|
-
|
|
1198
1210
|
`,v=l.default.li`
|
|
1199
1211
|
position: relative;
|
|
1200
1212
|
|
|
1201
|
-
|
|
1213
|
+
&:hover {
|
|
1202
1214
|
${h} {
|
|
1203
1215
|
display: flex;
|
|
1204
1216
|
}
|
|
@@ -1228,7 +1240,7 @@
|
|
|
1228
1240
|
height: ${40}px;
|
|
1229
1241
|
margin: var(--spacing-2x);
|
|
1230
1242
|
width: 40px;
|
|
1231
|
-
`,E=({className:e,mainItems:t,footerItems:n,coreActionButton:a})=>{const o=(0,i.useRef)(null),[l,u]=(0,i.useState)(t),[d,E]=(0,i.useState)(),[k,C]=(0,i.useState)(!1),[x,_]=(0,i.useState)(!1);function S(e){const t=null===o.current,n=(0,s.eventIsInside)(e,o.current);(t||!n)&&_(!1)}function T(e){null==e||e(),_(!1)}(0,i.useEffect)((()=>{if(k){if(null===o.current)return;return document.addEventListener("mouseup",S),()=>document.removeEventListener("mouseup",S)}}),[k]),(0,i.useEffect)((()=>{if(null===o.current)return;const e=e=>Array.from(e).reduce(((e,t)=>e+t.clientHeight),0),n=o.current.getElementsByTagName("nav"),r=n[0].getElementsByTagName("li"),i=e(r),l=e(n[1].getElementsByTagName("li")),s=i+l,d=o.current.clientHeight-17-(a?72:0);if(s>=d){let e=0,n=0;for(;e<d-l&&n<t.length;)e+=r[n].clientHeight,n+=1;const a=n-(e>d?1:0);u(t.filter(((e,t)=>t<a-1))),E(t.filter(((e,t)=>t>=a-1))),C(!0)}else u(t),C(!1)}),[n.length,t,o,a]);const P=e=>(0,r.jsx)(v,{children:(0,r.jsxs)(y,Object.assign({"data-testid":`${e.name}-${e.iconName}-link`,end:e.end,to:e.href,onClick:()=>T(e.onClick),onFocus:()=>_(!1)},{children:[(0,r.jsx)(c.Icon,{"aria-hidden":"true",name:e.iconName,size:"20"}),(0,r.jsx)(b,{children:e.name})]}))},`${e.name}-${e.iconName}`);return(0,r.jsxs)(m,Object.assign({className:e,ref:o},{children:[(0,r.jsxs)("div",{children:[a&&(0,r.jsx)(M,Object.assign({},a,{"data-testid":"core-action-button"})),(0,r.jsx)("nav",Object.assign({"aria-label":"App Navigation"},{children:(0,r.jsxs)(p,{children:[l.map(P),k&&(0,r.jsxs)(v,
|
|
1243
|
+
`,E=({className:e,mainItems:t,footerItems:n,coreActionButton:a})=>{const o=(0,i.useRef)(null),[l,u]=(0,i.useState)(t),[d,E]=(0,i.useState)(),[k,C]=(0,i.useState)(!1),[x,_]=(0,i.useState)(!1);function S(e){const t=null===o.current,n=(0,s.eventIsInside)(e,o.current);(t||!n)&&_(!1)}function T(e){null==e||e(),_(!1)}(0,i.useEffect)((()=>{if(k){if(null===o.current)return;return document.addEventListener("mouseup",S),()=>document.removeEventListener("mouseup",S)}}),[k]),(0,i.useEffect)((()=>{if(null===o.current)return;const e=e=>Array.from(e).reduce(((e,t)=>e+t.clientHeight),0),n=o.current.getElementsByTagName("nav"),r=n[0].getElementsByTagName("li"),i=e(r),l=e(n[1].getElementsByTagName("li")),s=i+l,d=o.current.clientHeight-17-(a?72:0);if(s>=d){let e=0,n=0;for(;e<d-l&&n<t.length;)e+=r[n].clientHeight,n+=1;const a=n-(e>d?1:0);u(t.filter(((e,t)=>t<a-1))),E(t.filter(((e,t)=>t>=a-1))),C(!0)}else u(t),C(!1)}),[n.length,t,o,a]);const P=e=>(0,r.jsx)(v,{children:(0,r.jsxs)(y,Object.assign({"data-testid":`${e.name}-${e.iconName}-link`,end:e.end,to:e.href,onClick:()=>T(e.onClick),onFocus:()=>_(!1)},{children:[(0,r.jsx)(c.Icon,{"aria-hidden":"true",name:e.iconName,size:"20"}),(0,r.jsx)(b,{children:e.name})]}))},`${e.name}-${e.iconName}`);return(0,r.jsxs)(m,Object.assign({className:e,ref:o},{children:[(0,r.jsxs)("div",{children:[a&&(0,r.jsx)(M,Object.assign({},a,{"data-testid":"core-action-button"})),(0,r.jsx)("nav",Object.assign({"aria-label":"App Navigation"},{children:(0,r.jsxs)(p,{children:[l.map(P),k&&(0,r.jsxs)(v,{children:[(0,r.jsx)(g,Object.assign({"aria-label":"Show more navigation elements","aria-expanded":x,"aria-haspopup":"true",type:"button","data-testid":"show-more-button",onClick:()=>_(!x)},{children:(0,r.jsx)(c.Icon,{name:"moreVertical",size:"16"})})),(0,r.jsx)(h,Object.assign({open:x,"data-testid":"show-more-menu"},{children:d&&d.map((e=>(0,r.jsx)("li",{children:(0,r.jsx)(f,Object.assign({"data-testid":`${e.name}-${e.iconName}-menu-link`,end:e.end,to:e.href,onClick:()=>T(e.onClick)},{children:e.name}))},`${e.name}-${e.iconName}`)))}))]})]})}))]}),(0,r.jsxs)("div",{children:[(0,r.jsx)(w,{}),(0,r.jsx)("nav",Object.assign({"aria-label":"App Navigation"},{children:(0,r.jsx)(p,{children:n.map(P)})}))]})]}))};t.GlobalNavigation=E;try{E.displayName="GlobalNavigation",E.__docgenInfo={description:"",displayName:"GlobalNavigation",props:{className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},coreActionButton:{defaultValue:null,description:"",name:"coreActionButton",required:!1,type:{name:"IconButtonProps"}},mainItems:{defaultValue:null,description:"Item has an icon name, a name, and a href",name:"mainItems",required:!0,type:{name:"GlobalNavigationItem[]"}},footerItems:{defaultValue:null,description:"Item has an icon name, a name, and a href",name:"footerItems",required:!0,type:{name:"GlobalNavigationItem[]"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/global-navigation/global-navigation.tsx#GlobalNavigation"]={docgenInfo:E.__docgenInfo,name:"GlobalNavigation",path:"src/components/global-navigation/global-navigation.tsx#GlobalNavigation"})}catch(e){}},3039:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Heading=void 0;const r=n(348),i=n(8156),o=a(n(1608)),l=o.default.h1`
|
|
1232
1244
|
font-size: 2rem;
|
|
1233
1245
|
font-weight: var(--font-normal);
|
|
1234
1246
|
line-height: 3rem;
|
|
@@ -1290,7 +1302,7 @@
|
|
|
1290
1302
|
::before {
|
|
1291
1303
|
background-color: ${e=>e.color||e.theme.main["primary-1.2"]};
|
|
1292
1304
|
border-radius: 50%;
|
|
1293
|
-
content:
|
|
1305
|
+
content: "";
|
|
1294
1306
|
height: 8px;
|
|
1295
1307
|
margin: var(--spacing-1x) var(--spacing-1x) 0 calc(-1 * var(--spacing-2x));
|
|
1296
1308
|
width: 8px;
|
|
@@ -1307,7 +1319,7 @@
|
|
|
1307
1319
|
`,m=o.default.ul`
|
|
1308
1320
|
background-color: ${({theme:e})=>e.greys.white};
|
|
1309
1321
|
border-radius: var(--border-radius);
|
|
1310
|
-
box-shadow: 0 0 0 1px ${({theme:e})=>e.greys.grey}, 0 10px 20px 0
|
|
1322
|
+
box-shadow: 0 0 0 1px ${({theme:e})=>e.greys.grey}, 0 10px 20px 0 rgb(0 0 0 / 19%);
|
|
1311
1323
|
list-style-type: none;
|
|
1312
1324
|
margin: 0;
|
|
1313
1325
|
max-height: ${function({numberOfItemsVisible:e,isMobile:t}){return e*(t?40:32)}}px;
|
|
@@ -1318,7 +1330,7 @@
|
|
|
1318
1330
|
z-index: 1000;
|
|
1319
1331
|
|
|
1320
1332
|
&:focus {
|
|
1321
|
-
box-shadow: ${({theme:e})=>e.tokens["focus-border-box-shadow"]}, 0 10px 20px 0
|
|
1333
|
+
box-shadow: ${({theme:e})=>e.tokens["focus-border-box-shadow"]}, 0 10px 20px 0 rgb(0 0 0 / 19%);
|
|
1322
1334
|
outline: none;
|
|
1323
1335
|
}
|
|
1324
1336
|
`,p=o.default.li`
|
|
@@ -1373,7 +1385,7 @@
|
|
|
1373
1385
|
/* TODO update with next thematization */
|
|
1374
1386
|
border: 1px solid #878f9a;
|
|
1375
1387
|
border-radius: var(--border-radius);
|
|
1376
|
-
box-shadow: 0 8px 16px 0
|
|
1388
|
+
box-shadow: 0 8px 16px 0 rgb(0 0 0 / 10%);
|
|
1377
1389
|
box-sizing: border-box;
|
|
1378
1390
|
flex-direction: column;
|
|
1379
1391
|
margin: 0;
|
|
@@ -1389,7 +1401,7 @@
|
|
|
1389
1401
|
/* TODO update with next thematization */
|
|
1390
1402
|
border: 1px solid #878f9a;
|
|
1391
1403
|
border-radius: var(--border-radius);
|
|
1392
|
-
box-shadow: 0 8px 16px 0
|
|
1404
|
+
box-shadow: 0 8px 16px 0 rgb(0 0 0 / 10%);
|
|
1393
1405
|
flex-direction: column;
|
|
1394
1406
|
left: ${({left:e})=>e}px !important;
|
|
1395
1407
|
margin: 0;
|
|
@@ -1401,7 +1413,6 @@
|
|
|
1401
1413
|
top: ${({top:e})=>e}px !important;
|
|
1402
1414
|
transform: none !important;
|
|
1403
1415
|
width: 100%;
|
|
1404
|
-
|
|
1405
1416
|
`,g=l.default.button`
|
|
1406
1417
|
align-items: center;
|
|
1407
1418
|
color: ${({theme:e})=>e.greys.black};
|
|
@@ -1459,7 +1470,7 @@
|
|
|
1459
1470
|
background-color: ${({theme:e})=>e.greys.white};
|
|
1460
1471
|
border: 1px solid ${({theme:e})=>e.greys["dark-grey"]};
|
|
1461
1472
|
border-radius: var(--border-radius-2x);
|
|
1462
|
-
box-shadow: 0 6px 10px 0
|
|
1473
|
+
box-shadow: 0 6px 10px 0 rgb(0 0 0 / 10%);
|
|
1463
1474
|
box-sizing: border-box;
|
|
1464
1475
|
display: flex;
|
|
1465
1476
|
flex-direction: column;
|
|
@@ -1473,14 +1484,14 @@
|
|
|
1473
1484
|
https://bugzilla.mozilla.org/show_bug.cgi?id=748518 */
|
|
1474
1485
|
|
|
1475
1486
|
&::after {
|
|
1476
|
-
content:
|
|
1487
|
+
content: "";
|
|
1477
1488
|
display: block;
|
|
1478
1489
|
padding-bottom: ${f};
|
|
1479
1490
|
}
|
|
1480
1491
|
|
|
1481
1492
|
&:focus {
|
|
1482
1493
|
border-color: ${({theme:e})=>e.tokens["focus-border"]};
|
|
1483
|
-
box-shadow: ${({theme:e})=>e.tokens["focus-box-shadow"]}, 0 6px 10px 0
|
|
1494
|
+
box-shadow: ${({theme:e})=>e.tokens["focus-box-shadow"]}, 0 6px 10px 0 rgb(0 0 0 / 10%);
|
|
1484
1495
|
outline: none;
|
|
1485
1496
|
}
|
|
1486
1497
|
`,v=d.default.main`
|
|
@@ -1669,7 +1680,7 @@
|
|
|
1669
1680
|
flex: 1;
|
|
1670
1681
|
margin-bottom: 0;
|
|
1671
1682
|
|
|
1672
|
-
input {
|
|
1683
|
+
input { /* stylelint-disable-line no-descending-specificity */
|
|
1673
1684
|
::-ms-reveal {
|
|
1674
1685
|
display: none;
|
|
1675
1686
|
}
|
|
@@ -1723,7 +1734,7 @@
|
|
|
1723
1734
|
&:last-child {
|
|
1724
1735
|
margin-right: 0;
|
|
1725
1736
|
}
|
|
1726
|
-
`,s=({strength:e})=>(0,r.jsxs)(l,{children:[(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.NONE}),(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.WEAK}),(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.FAIR}),(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.GOOD})]});t.PasswordStrengthMeter=s;try{s.displayName="PasswordStrengthMeter",s.__docgenInfo={description:"",displayName:"PasswordStrengthMeter",props:{strength:{defaultValue:null,description:"",name:"strength",required:!0,type:{name:"enum",value:[{value:"0"},{value:"1"},{value:"2"},{value:"3"},{value:"4"}]}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/password-creation-input/password-strength-meter.tsx#PasswordStrengthMeter"]={docgenInfo:s.__docgenInfo,name:"PasswordStrengthMeter",path:"src/components/password-creation-input/password-strength-meter.tsx#PasswordStrengthMeter"})}catch(e){}},5228:(e,t)=>{"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.PasswordStrengthEnum=void 0,(n=t.PasswordStrengthEnum||(t.PasswordStrengthEnum={}))[n.NONE=0]="NONE",n[n.WEAK=1]="WEAK",n[n.FAIR=2]="FAIR",n[n.GOOD=3]="GOOD",n[n.STRONG=4]="STRONG"},4008:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPasswordStrength=void 0;const a=n(5228),r=n(5509);t.getPasswordStrength=function(e){const t=(0,r.hasMinLength)(8)(e),n=(0,r.hasAnUpperCaseLetter)(e),i=(0,r.hasALowerCaseLetter)(e);let o=a.PasswordStrengthEnum.NONE;return e&&(o=a.PasswordStrengthEnum.WEAK),t&&(n||i)&&(o=a.PasswordStrengthEnum.FAIR),t&&n&&i&&(o=a.PasswordStrengthEnum.GOOD,e.length>=12&&(o=a.PasswordStrengthEnum.STRONG)),o}},5509:(e,t)=>{"use strict";function n(e=8){return t=>t.length>=e}function a(e){return e.toLowerCase()!==e}function r(e){return e.toUpperCase()!==e}Object.defineProperty(t,"__esModule",{value:!0}),t.getDefaultValidationConditions=t.hasALowerCaseLetter=t.hasAnUpperCaseLetter=t.hasMinLength=void 0,t.hasMinLength=n,t.hasAnUpperCaseLetter=a,t.hasALowerCaseLetter=r,t.getDefaultValidationConditions=function(e){return[{label:e("min-8-characters"),isValid:n(8)},{label:e("min-1-upper-case"),isValid:a},{label:e("min-1-lower-case"),isValid:r}]}},4872:(e,t)=>{"use strict";function n(e){return(e.match(t.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX)||[]).length}function a(e){return n(e)>0}function r(e,t,n){if(t<0)return-1;const a=e.slice(t).indexOf(n);return a>=0?t+a:a}Object.defineProperty(t,"__esModule",{value:!0}),t.findNextInsertPositionFromPatternInputDiff=t.getPreviousPlaceholderIndex=t.getNextPlaceholderIndex=t.hasAnyDecimalChar=t.getDecimalCharCount=t.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX=void 0,t.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX=/\d/g,t.getDecimalCharCount=n,t.hasAnyDecimalChar=a,t.getNextPlaceholderIndex=r,t.getPreviousPlaceholderIndex=function(e,t,n){return t<0?-1:e.slice(0,t).lastIndexOf(n)},t.findNextInsertPositionFromPatternInputDiff=function(e,t,n){for(let i=0;i<e.length;i++)if(a(e[i])&&t[i]!==n){const e=r(t,i,n);return e>=0?e+1:e}return-1};try{n.displayName="getDecimalCharCount",n.__docgenInfo={description:"",displayName:"getDecimalCharCount",props:{toString:{defaultValue:null,description:"Returns a string representation of a string.",name:"toString",required:!1,type:{name:"() => string"}},charAt:{defaultValue:null,description:"Returns the character at the specified index.\n@param pos The zero-based index of the desired character.",name:"charAt",required:!0,type:{name:"(pos: number) => string"}},charCodeAt:{defaultValue:null,description:"Returns the Unicode value of the character at the specified location.\n@param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.",name:"charCodeAt",required:!0,type:{name:"(index: number) => number"}},concat:{defaultValue:null,description:"Returns a string that contains the concatenation of two or more strings.\n@param strings The strings to append to the end of the string.",name:"concat",required:!0,type:{name:"(...strings: string[]) => string"}},indexOf:{defaultValue:null,description:"Returns the position of the first occurrence of a substring.\n@param searchString The substring to search for in the string\n@param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.",name:"indexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the last occurrence of a substring in the string.\n@param searchString The substring to search for.\n@param position The index at which to begin searching. If omitted, the search begins at the end of the string.",name:"lastIndexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},localeCompare:{defaultValue:null,description:"Determines whether two strings are equivalent in the current locale.\nDetermines whether two strings are equivalent in the current or specified locale.\n@param that String to compare to target string\n@param that String to compare to target string\n@param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n@param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.",name:"localeCompare",required:!0,type:{name:"{ (that: string): number; (that: string, locales?: string | string[] | undefined, options?: CollatorOptions | undefined): number; }"}},match:{defaultValue:null,description:"Matches a string with a regular expression, and returns an array containing the results of that search.\nMatches a string or an object that supports being matched against, and returns an array\ncontaining the results of that search, or null if no matches are found.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.\n@param matcher An object that supports being matched against.",name:"match",required:!0,type:{name:"{ (regexp: string | RegExp): RegExpMatchArray | null; (matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null; }"}},replace:{defaultValue:null,description:"Replaces text in a string, using a regular expression or search string.\nReplaces first match with string or all matches with RegExp.\nReplaces text in a string, using an object that supports replacement within a string.\n@param searchValue A string to search for.\n@param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n@param searchValue A string to search for.\n@param replacer A function that returns the replacement text.\n@param searchValue A string or RegExp search value.\n@param replaceValue A string containing the text to replace for match.\n@param searchValue A object can search for and replace matches within a string.\n@param replacer A function that returns the replacement text.",name:"replace",required:!0,type:{name:"{ (searchValue: string | RegExp, replaceValue: string): string; (searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string; (searchValue: { ...; }, replaceValue: string): string; (searchValue: { ...; }, replacer: (substring: string, ...args: any[]) => string): string; }"}},search:{defaultValue:null,description:"Finds the first substring match in a regular expression search.\n@param regexp The regular expression pattern and applicable flags.\n@param searcher An object which supports searching within a string.",name:"search",required:!0,type:{name:"{ (regexp: string | RegExp): number; (searcher: { [Symbol.search](string: string): number; }): number; }"}},slice:{defaultValue:null,description:"Returns a section of a string.\n@param start The index to the beginning of the specified portion of stringObj.\n@param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\nIf this value is not specified, the substring continues to the end of stringObj.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => string"}},split:{defaultValue:null,description:"Split a string into substrings using the specified separator and return them as an array.\n@param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n@param limit A value used to limit the number of elements returned in the array.\n@param splitter An object that can split a string.\n@param limit A value used to limit the number of elements returned in the array.",name:"split",required:!0,type:{name:"{ (separator: string | RegExp, limit?: number | undefined): string[]; (splitter: { [Symbol.split](string: string, limit?: number | undefined): string[]; }, limit?: number | undefined): string[]; }"}},substring:{defaultValue:null,description:"Returns the substring at the specified location within a String object.\n@param start The zero-based index number indicating the beginning of the substring.\n@param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\nIf end is omitted, the characters from start through the end of the original string are returned.",name:"substring",required:!0,type:{name:"(start: number, end?: number | undefined) => string"}},toLowerCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to lowercase.",name:"toLowerCase",required:!0,type:{name:"() => string"}},toLocaleLowerCase:{defaultValue:null,description:"Converts all alphabetic characters to lowercase, taking into account the host environment's current locale.",name:"toLocaleLowerCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},toUpperCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to uppercase.",name:"toUpperCase",required:!0,type:{name:"() => string"}},toLocaleUpperCase:{defaultValue:null,description:"Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale.",name:"toLocaleUpperCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},trim:{defaultValue:null,description:"Removes the leading and trailing white space and line terminator characters from a string.",name:"trim",required:!0,type:{name:"() => string"}},length:{defaultValue:null,description:"Returns the length of a String object.",name:"length",required:!0,type:{name:"number"}},substr:{defaultValue:null,description:"Gets a substring beginning at the specified location and having the specified length.\n@deprecated A legacy feature for browser compatibility\n@param from The starting position of the desired substring. The index of the first character in the string is zero.\n@param length The number of characters to include in the returned substring.",name:"substr",required:!0,type:{name:"(from: number, length?: number | undefined) => string"}},valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => string"}},codePointAt:{defaultValue:null,description:"Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\nvalue of the UTF-16 encoded code point starting at the string element at position pos in\nthe String resulting from converting this object to a String.\nIf there is no element at that position, the result is undefined.\nIf a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.",name:"codePointAt",required:!0,type:{name:"(pos: number) => number | undefined"}},includes:{defaultValue:null,description:"Returns true if searchString appears as a substring of the result of converting this\nobject to a String, at one or more positions that are\ngreater than or equal to position; otherwise, returns false.\n@param searchString search string\n@param position If position is undefined, 0 is assumed, so as to search all of the String.",name:"includes",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},endsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nendPosition – length(this). Otherwise returns false.",name:"endsWith",required:!0,type:{name:"(searchString: string, endPosition?: number | undefined) => boolean"}},normalize:{defaultValue:null,description:'Returns the String value result of normalizing the string into the normalization form\nnamed by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"',name:"normalize",required:!0,type:{name:'{ (form: "NFC" | "NFD" | "NFKC" | "NFKD"): string; (form?: string | undefined): string; }'}},repeat:{defaultValue:null,description:"Returns a String value that is made from count copies appended together. If count is 0,\nthe empty string is returned.\n@param count number of copies to append",name:"repeat",required:!0,type:{name:"(count: number) => string"}},startsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nposition. Otherwise returns false.",name:"startsWith",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},anchor:{defaultValue:null,description:"Returns an `<a>` HTML anchor element and sets the name attribute to the text value\n@deprecated A legacy feature for browser compatibility\n@param name",name:"anchor",required:!0,type:{name:"(name: string) => string"}},big:{defaultValue:null,description:"Returns a `<big>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"big",required:!0,type:{name:"() => string"}},blink:{defaultValue:null,description:"Returns a `<blink>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"blink",required:!0,type:{name:"() => string"}},bold:{defaultValue:null,description:"Returns a `<b>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"bold",required:!0,type:{name:"() => string"}},fixed:{defaultValue:null,description:"Returns a `<tt>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"fixed",required:!0,type:{name:"() => string"}},fontcolor:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the color attribute value\n@deprecated A legacy feature for browser compatibility",name:"fontcolor",required:!0,type:{name:"(color: string) => string"}},fontsize:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the size attribute value\n@deprecated A legacy feature for browser compatibility\n@deprecated A legacy feature for browser compatibility",name:"fontsize",required:!0,type:{name:"{ (size: number): string; (size: string): string; }"}},italics:{defaultValue:null,description:"Returns an `<i>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"italics",required:!0,type:{name:"() => string"}},link:{defaultValue:null,description:"Returns an `<a>` HTML element and sets the href attribute value\n@deprecated A legacy feature for browser compatibility",name:"link",required:!0,type:{name:"(url: string) => string"}},small:{defaultValue:null,description:"Returns a `<small>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"small",required:!0,type:{name:"() => string"}},strike:{defaultValue:null,description:"Returns a `<strike>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"strike",required:!0,type:{name:"() => string"}},sub:{defaultValue:null,description:"Returns a `<sub>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sub",required:!0,type:{name:"() => string"}},sup:{defaultValue:null,description:"Returns a `<sup>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sup",required:!0,type:{name:"() => string"}},padStart:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the start (left) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padStart",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},padEnd:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the end (right) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padEnd",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},trimEnd:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.",name:"trimEnd",required:!0,type:{name:"() => string"}},trimStart:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.",name:"trimStart",required:!0,type:{name:"() => string"}},trimLeft:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimStart` instead",name:"trimLeft",required:!0,type:{name:"() => string"}},trimRight:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimEnd` instead",name:"trimRight",required:!0,type:{name:"() => string"}},matchAll:{defaultValue:null,description:"Matches a string with a regular expression, and returns an iterable of matches\ncontaining the results of that search.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.",name:"matchAll",required:!0,type:{name:"(regexp: RegExp) => IterableIterator<RegExpMatchArray>"}},"__@iterator@58434":{defaultValue:null,description:"Iterator",name:"__@iterator@58434",required:!0,type:{name:"() => IterableIterator<string>"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => string | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/phone-input/phone-input-char-finder.tsx#getDecimalCharCount"]={docgenInfo:n.__docgenInfo,name:"getDecimalCharCount",path:"src/components/phone-input/phone-input-char-finder.tsx#getDecimalCharCount"})}catch(e){}try{a.displayName="hasAnyDecimalChar",a.__docgenInfo={description:"",displayName:"hasAnyDecimalChar",props:{toString:{defaultValue:null,description:"Returns a string representation of a string.",name:"toString",required:!1,type:{name:"() => string"}},charAt:{defaultValue:null,description:"Returns the character at the specified index.\n@param pos The zero-based index of the desired character.",name:"charAt",required:!0,type:{name:"(pos: number) => string"}},charCodeAt:{defaultValue:null,description:"Returns the Unicode value of the character at the specified location.\n@param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.",name:"charCodeAt",required:!0,type:{name:"(index: number) => number"}},concat:{defaultValue:null,description:"Returns a string that contains the concatenation of two or more strings.\n@param strings The strings to append to the end of the string.",name:"concat",required:!0,type:{name:"(...strings: string[]) => string"}},indexOf:{defaultValue:null,description:"Returns the position of the first occurrence of a substring.\n@param searchString The substring to search for in the string\n@param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.",name:"indexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the last occurrence of a substring in the string.\n@param searchString The substring to search for.\n@param position The index at which to begin searching. If omitted, the search begins at the end of the string.",name:"lastIndexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},localeCompare:{defaultValue:null,description:"Determines whether two strings are equivalent in the current locale.\nDetermines whether two strings are equivalent in the current or specified locale.\n@param that String to compare to target string\n@param that String to compare to target string\n@param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n@param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.",name:"localeCompare",required:!0,type:{name:"{ (that: string): number; (that: string, locales?: string | string[] | undefined, options?: CollatorOptions | undefined): number; }"}},match:{defaultValue:null,description:"Matches a string with a regular expression, and returns an array containing the results of that search.\nMatches a string or an object that supports being matched against, and returns an array\ncontaining the results of that search, or null if no matches are found.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.\n@param matcher An object that supports being matched against.",name:"match",required:!0,type:{name:"{ (regexp: string | RegExp): RegExpMatchArray | null; (matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null; }"}},replace:{defaultValue:null,description:"Replaces text in a string, using a regular expression or search string.\nReplaces first match with string or all matches with RegExp.\nReplaces text in a string, using an object that supports replacement within a string.\n@param searchValue A string to search for.\n@param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n@param searchValue A string to search for.\n@param replacer A function that returns the replacement text.\n@param searchValue A string or RegExp search value.\n@param replaceValue A string containing the text to replace for match.\n@param searchValue A object can search for and replace matches within a string.\n@param replacer A function that returns the replacement text.",name:"replace",required:!0,type:{name:"{ (searchValue: string | RegExp, replaceValue: string): string; (searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string; (searchValue: { ...; }, replaceValue: string): string; (searchValue: { ...; }, replacer: (substring: string, ...args: any[]) => string): string; }"}},search:{defaultValue:null,description:"Finds the first substring match in a regular expression search.\n@param regexp The regular expression pattern and applicable flags.\n@param searcher An object which supports searching within a string.",name:"search",required:!0,type:{name:"{ (regexp: string | RegExp): number; (searcher: { [Symbol.search](string: string): number; }): number; }"}},slice:{defaultValue:null,description:"Returns a section of a string.\n@param start The index to the beginning of the specified portion of stringObj.\n@param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\nIf this value is not specified, the substring continues to the end of stringObj.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => string"}},split:{defaultValue:null,description:"Split a string into substrings using the specified separator and return them as an array.\n@param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n@param limit A value used to limit the number of elements returned in the array.\n@param splitter An object that can split a string.\n@param limit A value used to limit the number of elements returned in the array.",name:"split",required:!0,type:{name:"{ (separator: string | RegExp, limit?: number | undefined): string[]; (splitter: { [Symbol.split](string: string, limit?: number | undefined): string[]; }, limit?: number | undefined): string[]; }"}},substring:{defaultValue:null,description:"Returns the substring at the specified location within a String object.\n@param start The zero-based index number indicating the beginning of the substring.\n@param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\nIf end is omitted, the characters from start through the end of the original string are returned.",name:"substring",required:!0,type:{name:"(start: number, end?: number | undefined) => string"}},toLowerCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to lowercase.",name:"toLowerCase",required:!0,type:{name:"() => string"}},toLocaleLowerCase:{defaultValue:null,description:"Converts all alphabetic characters to lowercase, taking into account the host environment's current locale.",name:"toLocaleLowerCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},toUpperCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to uppercase.",name:"toUpperCase",required:!0,type:{name:"() => string"}},toLocaleUpperCase:{defaultValue:null,description:"Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale.",name:"toLocaleUpperCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},trim:{defaultValue:null,description:"Removes the leading and trailing white space and line terminator characters from a string.",name:"trim",required:!0,type:{name:"() => string"}},length:{defaultValue:null,description:"Returns the length of a String object.",name:"length",required:!0,type:{name:"number"}},substr:{defaultValue:null,description:"Gets a substring beginning at the specified location and having the specified length.\n@deprecated A legacy feature for browser compatibility\n@param from The starting position of the desired substring. The index of the first character in the string is zero.\n@param length The number of characters to include in the returned substring.",name:"substr",required:!0,type:{name:"(from: number, length?: number | undefined) => string"}},valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => string"}},codePointAt:{defaultValue:null,description:"Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\nvalue of the UTF-16 encoded code point starting at the string element at position pos in\nthe String resulting from converting this object to a String.\nIf there is no element at that position, the result is undefined.\nIf a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.",name:"codePointAt",required:!0,type:{name:"(pos: number) => number | undefined"}},includes:{defaultValue:null,description:"Returns true if searchString appears as a substring of the result of converting this\nobject to a String, at one or more positions that are\ngreater than or equal to position; otherwise, returns false.\n@param searchString search string\n@param position If position is undefined, 0 is assumed, so as to search all of the String.",name:"includes",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},endsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nendPosition – length(this). Otherwise returns false.",name:"endsWith",required:!0,type:{name:"(searchString: string, endPosition?: number | undefined) => boolean"}},normalize:{defaultValue:null,description:'Returns the String value result of normalizing the string into the normalization form\nnamed by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"',name:"normalize",required:!0,type:{name:'{ (form: "NFC" | "NFD" | "NFKC" | "NFKD"): string; (form?: string | undefined): string; }'}},repeat:{defaultValue:null,description:"Returns a String value that is made from count copies appended together. If count is 0,\nthe empty string is returned.\n@param count number of copies to append",name:"repeat",required:!0,type:{name:"(count: number) => string"}},startsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nposition. Otherwise returns false.",name:"startsWith",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},anchor:{defaultValue:null,description:"Returns an `<a>` HTML anchor element and sets the name attribute to the text value\n@deprecated A legacy feature for browser compatibility\n@param name",name:"anchor",required:!0,type:{name:"(name: string) => string"}},big:{defaultValue:null,description:"Returns a `<big>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"big",required:!0,type:{name:"() => string"}},blink:{defaultValue:null,description:"Returns a `<blink>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"blink",required:!0,type:{name:"() => string"}},bold:{defaultValue:null,description:"Returns a `<b>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"bold",required:!0,type:{name:"() => string"}},fixed:{defaultValue:null,description:"Returns a `<tt>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"fixed",required:!0,type:{name:"() => string"}},fontcolor:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the color attribute value\n@deprecated A legacy feature for browser compatibility",name:"fontcolor",required:!0,type:{name:"(color: string) => string"}},fontsize:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the size attribute value\n@deprecated A legacy feature for browser compatibility\n@deprecated A legacy feature for browser compatibility",name:"fontsize",required:!0,type:{name:"{ (size: number): string; (size: string): string; }"}},italics:{defaultValue:null,description:"Returns an `<i>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"italics",required:!0,type:{name:"() => string"}},link:{defaultValue:null,description:"Returns an `<a>` HTML element and sets the href attribute value\n@deprecated A legacy feature for browser compatibility",name:"link",required:!0,type:{name:"(url: string) => string"}},small:{defaultValue:null,description:"Returns a `<small>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"small",required:!0,type:{name:"() => string"}},strike:{defaultValue:null,description:"Returns a `<strike>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"strike",required:!0,type:{name:"() => string"}},sub:{defaultValue:null,description:"Returns a `<sub>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sub",required:!0,type:{name:"() => string"}},sup:{defaultValue:null,description:"Returns a `<sup>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sup",required:!0,type:{name:"() => string"}},padStart:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the start (left) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padStart",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},padEnd:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the end (right) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padEnd",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},trimEnd:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.",name:"trimEnd",required:!0,type:{name:"() => string"}},trimStart:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.",name:"trimStart",required:!0,type:{name:"() => string"}},trimLeft:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimStart` instead",name:"trimLeft",required:!0,type:{name:"() => string"}},trimRight:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimEnd` instead",name:"trimRight",required:!0,type:{name:"() => string"}},matchAll:{defaultValue:null,description:"Matches a string with a regular expression, and returns an iterable of matches\ncontaining the results of that search.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.",name:"matchAll",required:!0,type:{name:"(regexp: RegExp) => IterableIterator<RegExpMatchArray>"}},"__@iterator@58434":{defaultValue:null,description:"Iterator",name:"__@iterator@58434",required:!0,type:{name:"() => IterableIterator<string>"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => string | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/phone-input/phone-input-char-finder.tsx#hasAnyDecimalChar"]={docgenInfo:a.__docgenInfo,name:"hasAnyDecimalChar",path:"src/components/phone-input/phone-input-char-finder.tsx#hasAnyDecimalChar"})}catch(e){}},5119:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeDigitOnMaskCharRemoval=t.removeNonDigits=t.formatFromPattern=void 0;const a=n(4872);function r(e){return e.replace(/\D/g,"")}t.formatFromPattern=function(e,t,n){return Array.from(n).reduce(((e,n)=>e.replace(t,n)),e)},t.removeNonDigits=r,t.removeDigitOnMaskCharRemoval=function(e,t,n,r){const i=t.replace(a.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX,"_"),o=r?(0,a.getPreviousPlaceholderIndex)(i,n,"_"):(0,a.getNextPlaceholderIndex)(i,n,"_");if(-1===o)return e;const l=t.slice(0,o),u=(0,a.getDecimalCharCount)(l);return e.slice(0,u)+e.slice(u+1)};try{r.displayName="removeNonDigits",r.__docgenInfo={description:"",displayName:"removeNonDigits",props:{toString:{defaultValue:null,description:"Returns a string representation of a string.",name:"toString",required:!1,type:{name:"() => string"}},charAt:{defaultValue:null,description:"Returns the character at the specified index.\n@param pos The zero-based index of the desired character.",name:"charAt",required:!0,type:{name:"(pos: number) => string"}},charCodeAt:{defaultValue:null,description:"Returns the Unicode value of the character at the specified location.\n@param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.",name:"charCodeAt",required:!0,type:{name:"(index: number) => number"}},concat:{defaultValue:null,description:"Returns a string that contains the concatenation of two or more strings.\n@param strings The strings to append to the end of the string.",name:"concat",required:!0,type:{name:"(...strings: string[]) => string"}},indexOf:{defaultValue:null,description:"Returns the position of the first occurrence of a substring.\n@param searchString The substring to search for in the string\n@param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.",name:"indexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the last occurrence of a substring in the string.\n@param searchString The substring to search for.\n@param position The index at which to begin searching. If omitted, the search begins at the end of the string.",name:"lastIndexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},localeCompare:{defaultValue:null,description:"Determines whether two strings are equivalent in the current locale.\nDetermines whether two strings are equivalent in the current or specified locale.\n@param that String to compare to target string\n@param that String to compare to target string\n@param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n@param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.",name:"localeCompare",required:!0,type:{name:"{ (that: string): number; (that: string, locales?: string | string[] | undefined, options?: CollatorOptions | undefined): number; }"}},match:{defaultValue:null,description:"Matches a string with a regular expression, and returns an array containing the results of that search.\nMatches a string or an object that supports being matched against, and returns an array\ncontaining the results of that search, or null if no matches are found.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.\n@param matcher An object that supports being matched against.",name:"match",required:!0,type:{name:"{ (regexp: string | RegExp): RegExpMatchArray | null; (matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null; }"}},replace:{defaultValue:null,description:"Replaces text in a string, using a regular expression or search string.\nReplaces first match with string or all matches with RegExp.\nReplaces text in a string, using an object that supports replacement within a string.\n@param searchValue A string to search for.\n@param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n@param searchValue A string to search for.\n@param replacer A function that returns the replacement text.\n@param searchValue A string or RegExp search value.\n@param replaceValue A string containing the text to replace for match.\n@param searchValue A object can search for and replace matches within a string.\n@param replacer A function that returns the replacement text.",name:"replace",required:!0,type:{name:"{ (searchValue: string | RegExp, replaceValue: string): string; (searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string; (searchValue: { ...; }, replaceValue: string): string; (searchValue: { ...; }, replacer: (substring: string, ...args: any[]) => string): string; }"}},search:{defaultValue:null,description:"Finds the first substring match in a regular expression search.\n@param regexp The regular expression pattern and applicable flags.\n@param searcher An object which supports searching within a string.",name:"search",required:!0,type:{name:"{ (regexp: string | RegExp): number; (searcher: { [Symbol.search](string: string): number; }): number; }"}},slice:{defaultValue:null,description:"Returns a section of a string.\n@param start The index to the beginning of the specified portion of stringObj.\n@param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\nIf this value is not specified, the substring continues to the end of stringObj.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => string"}},split:{defaultValue:null,description:"Split a string into substrings using the specified separator and return them as an array.\n@param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n@param limit A value used to limit the number of elements returned in the array.\n@param splitter An object that can split a string.\n@param limit A value used to limit the number of elements returned in the array.",name:"split",required:!0,type:{name:"{ (separator: string | RegExp, limit?: number | undefined): string[]; (splitter: { [Symbol.split](string: string, limit?: number | undefined): string[]; }, limit?: number | undefined): string[]; }"}},substring:{defaultValue:null,description:"Returns the substring at the specified location within a String object.\n@param start The zero-based index number indicating the beginning of the substring.\n@param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\nIf end is omitted, the characters from start through the end of the original string are returned.",name:"substring",required:!0,type:{name:"(start: number, end?: number | undefined) => string"}},toLowerCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to lowercase.",name:"toLowerCase",required:!0,type:{name:"() => string"}},toLocaleLowerCase:{defaultValue:null,description:"Converts all alphabetic characters to lowercase, taking into account the host environment's current locale.",name:"toLocaleLowerCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},toUpperCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to uppercase.",name:"toUpperCase",required:!0,type:{name:"() => string"}},toLocaleUpperCase:{defaultValue:null,description:"Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale.",name:"toLocaleUpperCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},trim:{defaultValue:null,description:"Removes the leading and trailing white space and line terminator characters from a string.",name:"trim",required:!0,type:{name:"() => string"}},length:{defaultValue:null,description:"Returns the length of a String object.",name:"length",required:!0,type:{name:"number"}},substr:{defaultValue:null,description:"Gets a substring beginning at the specified location and having the specified length.\n@deprecated A legacy feature for browser compatibility\n@param from The starting position of the desired substring. The index of the first character in the string is zero.\n@param length The number of characters to include in the returned substring.",name:"substr",required:!0,type:{name:"(from: number, length?: number | undefined) => string"}},valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => string"}},codePointAt:{defaultValue:null,description:"Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\nvalue of the UTF-16 encoded code point starting at the string element at position pos in\nthe String resulting from converting this object to a String.\nIf there is no element at that position, the result is undefined.\nIf a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.",name:"codePointAt",required:!0,type:{name:"(pos: number) => number | undefined"}},includes:{defaultValue:null,description:"Returns true if searchString appears as a substring of the result of converting this\nobject to a String, at one or more positions that are\ngreater than or equal to position; otherwise, returns false.\n@param searchString search string\n@param position If position is undefined, 0 is assumed, so as to search all of the String.",name:"includes",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},endsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nendPosition – length(this). Otherwise returns false.",name:"endsWith",required:!0,type:{name:"(searchString: string, endPosition?: number | undefined) => boolean"}},normalize:{defaultValue:null,description:'Returns the String value result of normalizing the string into the normalization form\nnamed by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"',name:"normalize",required:!0,type:{name:'{ (form: "NFC" | "NFD" | "NFKC" | "NFKD"): string; (form?: string | undefined): string; }'}},repeat:{defaultValue:null,description:"Returns a String value that is made from count copies appended together. If count is 0,\nthe empty string is returned.\n@param count number of copies to append",name:"repeat",required:!0,type:{name:"(count: number) => string"}},startsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nposition. Otherwise returns false.",name:"startsWith",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},anchor:{defaultValue:null,description:"Returns an `<a>` HTML anchor element and sets the name attribute to the text value\n@deprecated A legacy feature for browser compatibility\n@param name",name:"anchor",required:!0,type:{name:"(name: string) => string"}},big:{defaultValue:null,description:"Returns a `<big>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"big",required:!0,type:{name:"() => string"}},blink:{defaultValue:null,description:"Returns a `<blink>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"blink",required:!0,type:{name:"() => string"}},bold:{defaultValue:null,description:"Returns a `<b>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"bold",required:!0,type:{name:"() => string"}},fixed:{defaultValue:null,description:"Returns a `<tt>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"fixed",required:!0,type:{name:"() => string"}},fontcolor:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the color attribute value\n@deprecated A legacy feature for browser compatibility",name:"fontcolor",required:!0,type:{name:"(color: string) => string"}},fontsize:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the size attribute value\n@deprecated A legacy feature for browser compatibility\n@deprecated A legacy feature for browser compatibility",name:"fontsize",required:!0,type:{name:"{ (size: number): string; (size: string): string; }"}},italics:{defaultValue:null,description:"Returns an `<i>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"italics",required:!0,type:{name:"() => string"}},link:{defaultValue:null,description:"Returns an `<a>` HTML element and sets the href attribute value\n@deprecated A legacy feature for browser compatibility",name:"link",required:!0,type:{name:"(url: string) => string"}},small:{defaultValue:null,description:"Returns a `<small>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"small",required:!0,type:{name:"() => string"}},strike:{defaultValue:null,description:"Returns a `<strike>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"strike",required:!0,type:{name:"() => string"}},sub:{defaultValue:null,description:"Returns a `<sub>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sub",required:!0,type:{name:"() => string"}},sup:{defaultValue:null,description:"Returns a `<sup>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sup",required:!0,type:{name:"() => string"}},padStart:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the start (left) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padStart",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},padEnd:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the end (right) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padEnd",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},trimEnd:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.",name:"trimEnd",required:!0,type:{name:"() => string"}},trimStart:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.",name:"trimStart",required:!0,type:{name:"() => string"}},trimLeft:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimStart` instead",name:"trimLeft",required:!0,type:{name:"() => string"}},trimRight:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimEnd` instead",name:"trimRight",required:!0,type:{name:"() => string"}},matchAll:{defaultValue:null,description:"Matches a string with a regular expression, and returns an iterable of matches\ncontaining the results of that search.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.",name:"matchAll",required:!0,type:{name:"(regexp: RegExp) => IterableIterator<RegExpMatchArray>"}},"__@iterator@58434":{defaultValue:null,description:"Iterator",name:"__@iterator@58434",required:!0,type:{name:"() => IterableIterator<string>"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => string | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/phone-input/phone-input-value-formater.tsx#removeNonDigits"]={docgenInfo:r.__docgenInfo,name:"removeNonDigits",path:"src/components/phone-input/phone-input-value-formater.tsx#removeNonDigits"})}catch(e){}},7941:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.trimCharAfterMaxLength=t.getMaskFromSplitIndex=t.getValueFromSplitIndex=void 0;const a=n(4872);t.getValueFromSplitIndex=function(e,t){let n;return n=(0,a.hasAnyDecimalChar)(e)?-1===t?e:e.slice(0,t):"",n},t.getMaskFromSplitIndex=function(e,t,n){let r;return r=(0,a.hasAnyDecimalChar)(e)?-1===t?"":e.slice(t):n,r},t.trimCharAfterMaxLength=function(e,t){return e.substr(0,t)}},1971:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.PhoneInput=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(7217),d=n(7529),c=n(4872),m=n(5119),p=n(7941),f=l.default.div`
|
|
1737
|
+
`,s=({strength:e})=>(0,r.jsxs)(l,{children:[(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.NONE}),(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.WEAK}),(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.FAIR}),(0,r.jsx)(u,{passwordStrength:e,isFilled:e>o.PasswordStrengthEnum.GOOD})]});t.PasswordStrengthMeter=s;try{s.displayName="PasswordStrengthMeter",s.__docgenInfo={description:"",displayName:"PasswordStrengthMeter",props:{strength:{defaultValue:null,description:"",name:"strength",required:!0,type:{name:"enum",value:[{value:"0"},{value:"1"},{value:"2"},{value:"3"},{value:"4"}]}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/password-creation-input/password-strength-meter.tsx#PasswordStrengthMeter"]={docgenInfo:s.__docgenInfo,name:"PasswordStrengthMeter",path:"src/components/password-creation-input/password-strength-meter.tsx#PasswordStrengthMeter"})}catch(e){}},5228:(e,t)=>{"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.PasswordStrengthEnum=void 0,(n=t.PasswordStrengthEnum||(t.PasswordStrengthEnum={}))[n.NONE=0]="NONE",n[n.WEAK=1]="WEAK",n[n.FAIR=2]="FAIR",n[n.GOOD=3]="GOOD",n[n.STRONG=4]="STRONG"},4008:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPasswordStrength=void 0;const a=n(5228),r=n(5509);t.getPasswordStrength=function(e){const t=(0,r.hasMinLength)(8)(e),n=(0,r.hasAnUpperCaseLetter)(e),i=(0,r.hasALowerCaseLetter)(e);let o=a.PasswordStrengthEnum.NONE;return e&&(o=a.PasswordStrengthEnum.WEAK),t&&(n||i)&&(o=a.PasswordStrengthEnum.FAIR),t&&n&&i&&(o=a.PasswordStrengthEnum.GOOD,e.length>=12&&(o=a.PasswordStrengthEnum.STRONG)),o}},5509:(e,t)=>{"use strict";function n(e=8){return t=>t.length>=e}function a(e){return e.toLowerCase()!==e}function r(e){return e.toUpperCase()!==e}Object.defineProperty(t,"__esModule",{value:!0}),t.getDefaultValidationConditions=t.hasALowerCaseLetter=t.hasAnUpperCaseLetter=t.hasMinLength=void 0,t.hasMinLength=n,t.hasAnUpperCaseLetter=a,t.hasALowerCaseLetter=r,t.getDefaultValidationConditions=function(e){return[{label:e("min-8-characters"),isValid:n(8)},{label:e("min-1-upper-case"),isValid:a},{label:e("min-1-lower-case"),isValid:r}]}},4872:(e,t)=>{"use strict";function n(e){return(e.match(t.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX)||[]).length}function a(e){return n(e)>0}function r(e,t,n){if(t<0)return-1;const a=e.slice(t).indexOf(n);return a>=0?t+a:a}Object.defineProperty(t,"__esModule",{value:!0}),t.findNextInsertPositionFromPatternInputDiff=t.getPreviousPlaceholderIndex=t.getNextPlaceholderIndex=t.hasAnyDecimalChar=t.getDecimalCharCount=t.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX=void 0,t.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX=/\d/g,t.getDecimalCharCount=n,t.hasAnyDecimalChar=a,t.getNextPlaceholderIndex=r,t.getPreviousPlaceholderIndex=function(e,t,n){return t<0?-1:e.slice(0,t).lastIndexOf(n)},t.findNextInsertPositionFromPatternInputDiff=function(e,t,n){for(let i=0;i<e.length;i++)if(a(e[i])&&t[i]!==n){const e=r(t,i,n);return e>=0?e+1:e}return-1};try{n.displayName="getDecimalCharCount",n.__docgenInfo={description:"",displayName:"getDecimalCharCount",props:{toString:{defaultValue:null,description:"Returns a string representation of a string.",name:"toString",required:!1,type:{name:"() => string"}},charAt:{defaultValue:null,description:"Returns the character at the specified index.\n@param pos The zero-based index of the desired character.",name:"charAt",required:!0,type:{name:"(pos: number) => string"}},charCodeAt:{defaultValue:null,description:"Returns the Unicode value of the character at the specified location.\n@param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.",name:"charCodeAt",required:!0,type:{name:"(index: number) => number"}},concat:{defaultValue:null,description:"Returns a string that contains the concatenation of two or more strings.\n@param strings The strings to append to the end of the string.",name:"concat",required:!0,type:{name:"(...strings: string[]) => string"}},indexOf:{defaultValue:null,description:"Returns the position of the first occurrence of a substring.\n@param searchString The substring to search for in the string\n@param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.",name:"indexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the last occurrence of a substring in the string.\n@param searchString The substring to search for.\n@param position The index at which to begin searching. If omitted, the search begins at the end of the string.",name:"lastIndexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},localeCompare:{defaultValue:null,description:"Determines whether two strings are equivalent in the current locale.\nDetermines whether two strings are equivalent in the current or specified locale.\n@param that String to compare to target string\n@param that String to compare to target string\n@param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n@param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.",name:"localeCompare",required:!0,type:{name:"{ (that: string): number; (that: string, locales?: string | string[] | undefined, options?: CollatorOptions | undefined): number; }"}},match:{defaultValue:null,description:"Matches a string with a regular expression, and returns an array containing the results of that search.\nMatches a string or an object that supports being matched against, and returns an array\ncontaining the results of that search, or null if no matches are found.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.\n@param matcher An object that supports being matched against.",name:"match",required:!0,type:{name:"{ (regexp: string | RegExp): RegExpMatchArray | null; (matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null; }"}},replace:{defaultValue:null,description:"Replaces text in a string, using a regular expression or search string.\nReplaces first match with string or all matches with RegExp.\nReplaces text in a string, using an object that supports replacement within a string.\n@param searchValue A string to search for.\n@param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n@param searchValue A string to search for.\n@param replacer A function that returns the replacement text.\n@param searchValue A string or RegExp search value.\n@param replaceValue A string containing the text to replace for match.\n@param searchValue A object can search for and replace matches within a string.\n@param replacer A function that returns the replacement text.",name:"replace",required:!0,type:{name:"{ (searchValue: string | RegExp, replaceValue: string): string; (searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string; (searchValue: { ...; }, replaceValue: string): string; (searchValue: { ...; }, replacer: (substring: string, ...args: any[]) => string): string; }"}},search:{defaultValue:null,description:"Finds the first substring match in a regular expression search.\n@param regexp The regular expression pattern and applicable flags.\n@param searcher An object which supports searching within a string.",name:"search",required:!0,type:{name:"{ (regexp: string | RegExp): number; (searcher: { [Symbol.search](string: string): number; }): number; }"}},slice:{defaultValue:null,description:"Returns a section of a string.\n@param start The index to the beginning of the specified portion of stringObj.\n@param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\nIf this value is not specified, the substring continues to the end of stringObj.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => string"}},split:{defaultValue:null,description:"Split a string into substrings using the specified separator and return them as an array.\n@param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n@param limit A value used to limit the number of elements returned in the array.\n@param splitter An object that can split a string.\n@param limit A value used to limit the number of elements returned in the array.",name:"split",required:!0,type:{name:"{ (separator: string | RegExp, limit?: number | undefined): string[]; (splitter: { [Symbol.split](string: string, limit?: number | undefined): string[]; }, limit?: number | undefined): string[]; }"}},substring:{defaultValue:null,description:"Returns the substring at the specified location within a String object.\n@param start The zero-based index number indicating the beginning of the substring.\n@param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\nIf end is omitted, the characters from start through the end of the original string are returned.",name:"substring",required:!0,type:{name:"(start: number, end?: number | undefined) => string"}},toLowerCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to lowercase.",name:"toLowerCase",required:!0,type:{name:"() => string"}},toLocaleLowerCase:{defaultValue:null,description:"Converts all alphabetic characters to lowercase, taking into account the host environment's current locale.",name:"toLocaleLowerCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},toUpperCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to uppercase.",name:"toUpperCase",required:!0,type:{name:"() => string"}},toLocaleUpperCase:{defaultValue:null,description:"Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale.",name:"toLocaleUpperCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},trim:{defaultValue:null,description:"Removes the leading and trailing white space and line terminator characters from a string.",name:"trim",required:!0,type:{name:"() => string"}},length:{defaultValue:null,description:"Returns the length of a String object.",name:"length",required:!0,type:{name:"number"}},substr:{defaultValue:null,description:"Gets a substring beginning at the specified location and having the specified length.\n@deprecated A legacy feature for browser compatibility\n@param from The starting position of the desired substring. The index of the first character in the string is zero.\n@param length The number of characters to include in the returned substring.",name:"substr",required:!0,type:{name:"(from: number, length?: number | undefined) => string"}},valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => string"}},codePointAt:{defaultValue:null,description:"Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\nvalue of the UTF-16 encoded code point starting at the string element at position pos in\nthe String resulting from converting this object to a String.\nIf there is no element at that position, the result is undefined.\nIf a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.",name:"codePointAt",required:!0,type:{name:"(pos: number) => number | undefined"}},includes:{defaultValue:null,description:"Returns true if searchString appears as a substring of the result of converting this\nobject to a String, at one or more positions that are\ngreater than or equal to position; otherwise, returns false.\n@param searchString search string\n@param position If position is undefined, 0 is assumed, so as to search all of the String.",name:"includes",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},endsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nendPosition – length(this). Otherwise returns false.",name:"endsWith",required:!0,type:{name:"(searchString: string, endPosition?: number | undefined) => boolean"}},normalize:{defaultValue:null,description:'Returns the String value result of normalizing the string into the normalization form\nnamed by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"',name:"normalize",required:!0,type:{name:'{ (form: "NFC" | "NFD" | "NFKC" | "NFKD"): string; (form?: string | undefined): string; }'}},repeat:{defaultValue:null,description:"Returns a String value that is made from count copies appended together. If count is 0,\nthe empty string is returned.\n@param count number of copies to append",name:"repeat",required:!0,type:{name:"(count: number) => string"}},startsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nposition. Otherwise returns false.",name:"startsWith",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},anchor:{defaultValue:null,description:"Returns an `<a>` HTML anchor element and sets the name attribute to the text value\n@deprecated A legacy feature for browser compatibility\n@param name",name:"anchor",required:!0,type:{name:"(name: string) => string"}},big:{defaultValue:null,description:"Returns a `<big>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"big",required:!0,type:{name:"() => string"}},blink:{defaultValue:null,description:"Returns a `<blink>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"blink",required:!0,type:{name:"() => string"}},bold:{defaultValue:null,description:"Returns a `<b>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"bold",required:!0,type:{name:"() => string"}},fixed:{defaultValue:null,description:"Returns a `<tt>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"fixed",required:!0,type:{name:"() => string"}},fontcolor:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the color attribute value\n@deprecated A legacy feature for browser compatibility",name:"fontcolor",required:!0,type:{name:"(color: string) => string"}},fontsize:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the size attribute value\n@deprecated A legacy feature for browser compatibility\n@deprecated A legacy feature for browser compatibility",name:"fontsize",required:!0,type:{name:"{ (size: number): string; (size: string): string; }"}},italics:{defaultValue:null,description:"Returns an `<i>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"italics",required:!0,type:{name:"() => string"}},link:{defaultValue:null,description:"Returns an `<a>` HTML element and sets the href attribute value\n@deprecated A legacy feature for browser compatibility",name:"link",required:!0,type:{name:"(url: string) => string"}},small:{defaultValue:null,description:"Returns a `<small>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"small",required:!0,type:{name:"() => string"}},strike:{defaultValue:null,description:"Returns a `<strike>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"strike",required:!0,type:{name:"() => string"}},sub:{defaultValue:null,description:"Returns a `<sub>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sub",required:!0,type:{name:"() => string"}},sup:{defaultValue:null,description:"Returns a `<sup>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sup",required:!0,type:{name:"() => string"}},padStart:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the start (left) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padStart",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},padEnd:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the end (right) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padEnd",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},trimEnd:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.",name:"trimEnd",required:!0,type:{name:"() => string"}},trimStart:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.",name:"trimStart",required:!0,type:{name:"() => string"}},trimLeft:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimStart` instead",name:"trimLeft",required:!0,type:{name:"() => string"}},trimRight:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimEnd` instead",name:"trimRight",required:!0,type:{name:"() => string"}},matchAll:{defaultValue:null,description:"Matches a string with a regular expression, and returns an iterable of matches\ncontaining the results of that search.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.",name:"matchAll",required:!0,type:{name:"(regexp: RegExp) => IterableIterator<RegExpMatchArray>"}},"__@iterator@58433":{defaultValue:null,description:"Iterator",name:"__@iterator@58433",required:!0,type:{name:"() => IterableIterator<string>"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => string | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/phone-input/phone-input-char-finder.tsx#getDecimalCharCount"]={docgenInfo:n.__docgenInfo,name:"getDecimalCharCount",path:"src/components/phone-input/phone-input-char-finder.tsx#getDecimalCharCount"})}catch(e){}try{a.displayName="hasAnyDecimalChar",a.__docgenInfo={description:"",displayName:"hasAnyDecimalChar",props:{toString:{defaultValue:null,description:"Returns a string representation of a string.",name:"toString",required:!1,type:{name:"() => string"}},charAt:{defaultValue:null,description:"Returns the character at the specified index.\n@param pos The zero-based index of the desired character.",name:"charAt",required:!0,type:{name:"(pos: number) => string"}},charCodeAt:{defaultValue:null,description:"Returns the Unicode value of the character at the specified location.\n@param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.",name:"charCodeAt",required:!0,type:{name:"(index: number) => number"}},concat:{defaultValue:null,description:"Returns a string that contains the concatenation of two or more strings.\n@param strings The strings to append to the end of the string.",name:"concat",required:!0,type:{name:"(...strings: string[]) => string"}},indexOf:{defaultValue:null,description:"Returns the position of the first occurrence of a substring.\n@param searchString The substring to search for in the string\n@param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.",name:"indexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the last occurrence of a substring in the string.\n@param searchString The substring to search for.\n@param position The index at which to begin searching. If omitted, the search begins at the end of the string.",name:"lastIndexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},localeCompare:{defaultValue:null,description:"Determines whether two strings are equivalent in the current locale.\nDetermines whether two strings are equivalent in the current or specified locale.\n@param that String to compare to target string\n@param that String to compare to target string\n@param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n@param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.",name:"localeCompare",required:!0,type:{name:"{ (that: string): number; (that: string, locales?: string | string[] | undefined, options?: CollatorOptions | undefined): number; }"}},match:{defaultValue:null,description:"Matches a string with a regular expression, and returns an array containing the results of that search.\nMatches a string or an object that supports being matched against, and returns an array\ncontaining the results of that search, or null if no matches are found.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.\n@param matcher An object that supports being matched against.",name:"match",required:!0,type:{name:"{ (regexp: string | RegExp): RegExpMatchArray | null; (matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null; }"}},replace:{defaultValue:null,description:"Replaces text in a string, using a regular expression or search string.\nReplaces first match with string or all matches with RegExp.\nReplaces text in a string, using an object that supports replacement within a string.\n@param searchValue A string to search for.\n@param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n@param searchValue A string to search for.\n@param replacer A function that returns the replacement text.\n@param searchValue A string or RegExp search value.\n@param replaceValue A string containing the text to replace for match.\n@param searchValue A object can search for and replace matches within a string.\n@param replacer A function that returns the replacement text.",name:"replace",required:!0,type:{name:"{ (searchValue: string | RegExp, replaceValue: string): string; (searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string; (searchValue: { ...; }, replaceValue: string): string; (searchValue: { ...; }, replacer: (substring: string, ...args: any[]) => string): string; }"}},search:{defaultValue:null,description:"Finds the first substring match in a regular expression search.\n@param regexp The regular expression pattern and applicable flags.\n@param searcher An object which supports searching within a string.",name:"search",required:!0,type:{name:"{ (regexp: string | RegExp): number; (searcher: { [Symbol.search](string: string): number; }): number; }"}},slice:{defaultValue:null,description:"Returns a section of a string.\n@param start The index to the beginning of the specified portion of stringObj.\n@param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\nIf this value is not specified, the substring continues to the end of stringObj.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => string"}},split:{defaultValue:null,description:"Split a string into substrings using the specified separator and return them as an array.\n@param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n@param limit A value used to limit the number of elements returned in the array.\n@param splitter An object that can split a string.\n@param limit A value used to limit the number of elements returned in the array.",name:"split",required:!0,type:{name:"{ (separator: string | RegExp, limit?: number | undefined): string[]; (splitter: { [Symbol.split](string: string, limit?: number | undefined): string[]; }, limit?: number | undefined): string[]; }"}},substring:{defaultValue:null,description:"Returns the substring at the specified location within a String object.\n@param start The zero-based index number indicating the beginning of the substring.\n@param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\nIf end is omitted, the characters from start through the end of the original string are returned.",name:"substring",required:!0,type:{name:"(start: number, end?: number | undefined) => string"}},toLowerCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to lowercase.",name:"toLowerCase",required:!0,type:{name:"() => string"}},toLocaleLowerCase:{defaultValue:null,description:"Converts all alphabetic characters to lowercase, taking into account the host environment's current locale.",name:"toLocaleLowerCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},toUpperCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to uppercase.",name:"toUpperCase",required:!0,type:{name:"() => string"}},toLocaleUpperCase:{defaultValue:null,description:"Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale.",name:"toLocaleUpperCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},trim:{defaultValue:null,description:"Removes the leading and trailing white space and line terminator characters from a string.",name:"trim",required:!0,type:{name:"() => string"}},length:{defaultValue:null,description:"Returns the length of a String object.",name:"length",required:!0,type:{name:"number"}},substr:{defaultValue:null,description:"Gets a substring beginning at the specified location and having the specified length.\n@deprecated A legacy feature for browser compatibility\n@param from The starting position of the desired substring. The index of the first character in the string is zero.\n@param length The number of characters to include in the returned substring.",name:"substr",required:!0,type:{name:"(from: number, length?: number | undefined) => string"}},valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => string"}},codePointAt:{defaultValue:null,description:"Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\nvalue of the UTF-16 encoded code point starting at the string element at position pos in\nthe String resulting from converting this object to a String.\nIf there is no element at that position, the result is undefined.\nIf a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.",name:"codePointAt",required:!0,type:{name:"(pos: number) => number | undefined"}},includes:{defaultValue:null,description:"Returns true if searchString appears as a substring of the result of converting this\nobject to a String, at one or more positions that are\ngreater than or equal to position; otherwise, returns false.\n@param searchString search string\n@param position If position is undefined, 0 is assumed, so as to search all of the String.",name:"includes",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},endsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nendPosition – length(this). Otherwise returns false.",name:"endsWith",required:!0,type:{name:"(searchString: string, endPosition?: number | undefined) => boolean"}},normalize:{defaultValue:null,description:'Returns the String value result of normalizing the string into the normalization form\nnamed by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"',name:"normalize",required:!0,type:{name:'{ (form: "NFC" | "NFD" | "NFKC" | "NFKD"): string; (form?: string | undefined): string; }'}},repeat:{defaultValue:null,description:"Returns a String value that is made from count copies appended together. If count is 0,\nthe empty string is returned.\n@param count number of copies to append",name:"repeat",required:!0,type:{name:"(count: number) => string"}},startsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nposition. Otherwise returns false.",name:"startsWith",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},anchor:{defaultValue:null,description:"Returns an `<a>` HTML anchor element and sets the name attribute to the text value\n@deprecated A legacy feature for browser compatibility\n@param name",name:"anchor",required:!0,type:{name:"(name: string) => string"}},big:{defaultValue:null,description:"Returns a `<big>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"big",required:!0,type:{name:"() => string"}},blink:{defaultValue:null,description:"Returns a `<blink>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"blink",required:!0,type:{name:"() => string"}},bold:{defaultValue:null,description:"Returns a `<b>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"bold",required:!0,type:{name:"() => string"}},fixed:{defaultValue:null,description:"Returns a `<tt>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"fixed",required:!0,type:{name:"() => string"}},fontcolor:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the color attribute value\n@deprecated A legacy feature for browser compatibility",name:"fontcolor",required:!0,type:{name:"(color: string) => string"}},fontsize:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the size attribute value\n@deprecated A legacy feature for browser compatibility\n@deprecated A legacy feature for browser compatibility",name:"fontsize",required:!0,type:{name:"{ (size: number): string; (size: string): string; }"}},italics:{defaultValue:null,description:"Returns an `<i>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"italics",required:!0,type:{name:"() => string"}},link:{defaultValue:null,description:"Returns an `<a>` HTML element and sets the href attribute value\n@deprecated A legacy feature for browser compatibility",name:"link",required:!0,type:{name:"(url: string) => string"}},small:{defaultValue:null,description:"Returns a `<small>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"small",required:!0,type:{name:"() => string"}},strike:{defaultValue:null,description:"Returns a `<strike>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"strike",required:!0,type:{name:"() => string"}},sub:{defaultValue:null,description:"Returns a `<sub>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sub",required:!0,type:{name:"() => string"}},sup:{defaultValue:null,description:"Returns a `<sup>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sup",required:!0,type:{name:"() => string"}},padStart:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the start (left) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padStart",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},padEnd:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the end (right) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padEnd",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},trimEnd:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.",name:"trimEnd",required:!0,type:{name:"() => string"}},trimStart:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.",name:"trimStart",required:!0,type:{name:"() => string"}},trimLeft:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimStart` instead",name:"trimLeft",required:!0,type:{name:"() => string"}},trimRight:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimEnd` instead",name:"trimRight",required:!0,type:{name:"() => string"}},matchAll:{defaultValue:null,description:"Matches a string with a regular expression, and returns an iterable of matches\ncontaining the results of that search.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.",name:"matchAll",required:!0,type:{name:"(regexp: RegExp) => IterableIterator<RegExpMatchArray>"}},"__@iterator@58433":{defaultValue:null,description:"Iterator",name:"__@iterator@58433",required:!0,type:{name:"() => IterableIterator<string>"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => string | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/phone-input/phone-input-char-finder.tsx#hasAnyDecimalChar"]={docgenInfo:a.__docgenInfo,name:"hasAnyDecimalChar",path:"src/components/phone-input/phone-input-char-finder.tsx#hasAnyDecimalChar"})}catch(e){}},5119:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeDigitOnMaskCharRemoval=t.removeNonDigits=t.formatFromPattern=void 0;const a=n(4872);function r(e){return e.replace(/\D/g,"")}t.formatFromPattern=function(e,t,n){return Array.from(n).reduce(((e,n)=>e.replace(t,n)),e)},t.removeNonDigits=r,t.removeDigitOnMaskCharRemoval=function(e,t,n,r){const i=t.replace(a.MATCH_ALL_DECIMAL_CHAR_OCCURRENCE_REGEX,"_"),o=r?(0,a.getPreviousPlaceholderIndex)(i,n,"_"):(0,a.getNextPlaceholderIndex)(i,n,"_");if(-1===o)return e;const l=t.slice(0,o),u=(0,a.getDecimalCharCount)(l);return e.slice(0,u)+e.slice(u+1)};try{r.displayName="removeNonDigits",r.__docgenInfo={description:"",displayName:"removeNonDigits",props:{toString:{defaultValue:null,description:"Returns a string representation of a string.",name:"toString",required:!1,type:{name:"() => string"}},charAt:{defaultValue:null,description:"Returns the character at the specified index.\n@param pos The zero-based index of the desired character.",name:"charAt",required:!0,type:{name:"(pos: number) => string"}},charCodeAt:{defaultValue:null,description:"Returns the Unicode value of the character at the specified location.\n@param index The zero-based index of the desired character. If there is no character at the specified index, NaN is returned.",name:"charCodeAt",required:!0,type:{name:"(index: number) => number"}},concat:{defaultValue:null,description:"Returns a string that contains the concatenation of two or more strings.\n@param strings The strings to append to the end of the string.",name:"concat",required:!0,type:{name:"(...strings: string[]) => string"}},indexOf:{defaultValue:null,description:"Returns the position of the first occurrence of a substring.\n@param searchString The substring to search for in the string\n@param position The index at which to begin searching the String object. If omitted, search starts at the beginning of the string.",name:"indexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the last occurrence of a substring in the string.\n@param searchString The substring to search for.\n@param position The index at which to begin searching. If omitted, the search begins at the end of the string.",name:"lastIndexOf",required:!0,type:{name:"(searchString: string, position?: number | undefined) => number"}},localeCompare:{defaultValue:null,description:"Determines whether two strings are equivalent in the current locale.\nDetermines whether two strings are equivalent in the current or specified locale.\n@param that String to compare to target string\n@param that String to compare to target string\n@param locales A locale string or array of locale strings that contain one or more language or locale tags. If you include more than one locale string, list them in descending order of priority so that the first entry is the preferred locale. If you omit this parameter, the default locale of the JavaScript runtime is used. This parameter must conform to BCP 47 standards; see the Intl.Collator object for details.\n@param options An object that contains one or more properties that specify comparison options. see the Intl.Collator object for details.",name:"localeCompare",required:!0,type:{name:"{ (that: string): number; (that: string, locales?: string | string[] | undefined, options?: CollatorOptions | undefined): number; }"}},match:{defaultValue:null,description:"Matches a string with a regular expression, and returns an array containing the results of that search.\nMatches a string or an object that supports being matched against, and returns an array\ncontaining the results of that search, or null if no matches are found.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.\n@param matcher An object that supports being matched against.",name:"match",required:!0,type:{name:"{ (regexp: string | RegExp): RegExpMatchArray | null; (matcher: { [Symbol.match](string: string): RegExpMatchArray | null; }): RegExpMatchArray | null; }"}},replace:{defaultValue:null,description:"Replaces text in a string, using a regular expression or search string.\nReplaces first match with string or all matches with RegExp.\nReplaces text in a string, using an object that supports replacement within a string.\n@param searchValue A string to search for.\n@param replaceValue A string containing the text to replace for every successful match of searchValue in this string.\n@param searchValue A string to search for.\n@param replacer A function that returns the replacement text.\n@param searchValue A string or RegExp search value.\n@param replaceValue A string containing the text to replace for match.\n@param searchValue A object can search for and replace matches within a string.\n@param replacer A function that returns the replacement text.",name:"replace",required:!0,type:{name:"{ (searchValue: string | RegExp, replaceValue: string): string; (searchValue: string | RegExp, replacer: (substring: string, ...args: any[]) => string): string; (searchValue: { ...; }, replaceValue: string): string; (searchValue: { ...; }, replacer: (substring: string, ...args: any[]) => string): string; }"}},search:{defaultValue:null,description:"Finds the first substring match in a regular expression search.\n@param regexp The regular expression pattern and applicable flags.\n@param searcher An object which supports searching within a string.",name:"search",required:!0,type:{name:"{ (regexp: string | RegExp): number; (searcher: { [Symbol.search](string: string): number; }): number; }"}},slice:{defaultValue:null,description:"Returns a section of a string.\n@param start The index to the beginning of the specified portion of stringObj.\n@param end The index to the end of the specified portion of stringObj. The substring includes the characters up to, but not including, the character indicated by end.\nIf this value is not specified, the substring continues to the end of stringObj.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => string"}},split:{defaultValue:null,description:"Split a string into substrings using the specified separator and return them as an array.\n@param separator A string that identifies character or characters to use in separating the string. If omitted, a single-element array containing the entire string is returned.\n@param limit A value used to limit the number of elements returned in the array.\n@param splitter An object that can split a string.\n@param limit A value used to limit the number of elements returned in the array.",name:"split",required:!0,type:{name:"{ (separator: string | RegExp, limit?: number | undefined): string[]; (splitter: { [Symbol.split](string: string, limit?: number | undefined): string[]; }, limit?: number | undefined): string[]; }"}},substring:{defaultValue:null,description:"Returns the substring at the specified location within a String object.\n@param start The zero-based index number indicating the beginning of the substring.\n@param end Zero-based index number indicating the end of the substring. The substring includes the characters up to, but not including, the character indicated by end.\nIf end is omitted, the characters from start through the end of the original string are returned.",name:"substring",required:!0,type:{name:"(start: number, end?: number | undefined) => string"}},toLowerCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to lowercase.",name:"toLowerCase",required:!0,type:{name:"() => string"}},toLocaleLowerCase:{defaultValue:null,description:"Converts all alphabetic characters to lowercase, taking into account the host environment's current locale.",name:"toLocaleLowerCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},toUpperCase:{defaultValue:null,description:"Converts all the alphabetic characters in a string to uppercase.",name:"toUpperCase",required:!0,type:{name:"() => string"}},toLocaleUpperCase:{defaultValue:null,description:"Returns a string where all alphabetic characters have been converted to uppercase, taking into account the host environment's current locale.",name:"toLocaleUpperCase",required:!0,type:{name:"(locales?: string | string[] | undefined) => string"}},trim:{defaultValue:null,description:"Removes the leading and trailing white space and line terminator characters from a string.",name:"trim",required:!0,type:{name:"() => string"}},length:{defaultValue:null,description:"Returns the length of a String object.",name:"length",required:!0,type:{name:"number"}},substr:{defaultValue:null,description:"Gets a substring beginning at the specified location and having the specified length.\n@deprecated A legacy feature for browser compatibility\n@param from The starting position of the desired substring. The index of the first character in the string is zero.\n@param length The number of characters to include in the returned substring.",name:"substr",required:!0,type:{name:"(from: number, length?: number | undefined) => string"}},valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => string"}},codePointAt:{defaultValue:null,description:"Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point\nvalue of the UTF-16 encoded code point starting at the string element at position pos in\nthe String resulting from converting this object to a String.\nIf there is no element at that position, the result is undefined.\nIf a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.",name:"codePointAt",required:!0,type:{name:"(pos: number) => number | undefined"}},includes:{defaultValue:null,description:"Returns true if searchString appears as a substring of the result of converting this\nobject to a String, at one or more positions that are\ngreater than or equal to position; otherwise, returns false.\n@param searchString search string\n@param position If position is undefined, 0 is assumed, so as to search all of the String.",name:"includes",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},endsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nendPosition – length(this). Otherwise returns false.",name:"endsWith",required:!0,type:{name:"(searchString: string, endPosition?: number | undefined) => boolean"}},normalize:{defaultValue:null,description:'Returns the String value result of normalizing the string into the normalization form\nnamed by form as specified in Unicode Standard Annex #15, Unicode Normalization Forms.\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"\n@param form Applicable values: "NFC", "NFD", "NFKC", or "NFKD", If not specified default\nis "NFC"',name:"normalize",required:!0,type:{name:'{ (form: "NFC" | "NFD" | "NFKC" | "NFKD"): string; (form?: string | undefined): string; }'}},repeat:{defaultValue:null,description:"Returns a String value that is made from count copies appended together. If count is 0,\nthe empty string is returned.\n@param count number of copies to append",name:"repeat",required:!0,type:{name:"(count: number) => string"}},startsWith:{defaultValue:null,description:"Returns true if the sequence of elements of searchString converted to a String is the\nsame as the corresponding elements of this object (converted to a String) starting at\nposition. Otherwise returns false.",name:"startsWith",required:!0,type:{name:"(searchString: string, position?: number | undefined) => boolean"}},anchor:{defaultValue:null,description:"Returns an `<a>` HTML anchor element and sets the name attribute to the text value\n@deprecated A legacy feature for browser compatibility\n@param name",name:"anchor",required:!0,type:{name:"(name: string) => string"}},big:{defaultValue:null,description:"Returns a `<big>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"big",required:!0,type:{name:"() => string"}},blink:{defaultValue:null,description:"Returns a `<blink>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"blink",required:!0,type:{name:"() => string"}},bold:{defaultValue:null,description:"Returns a `<b>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"bold",required:!0,type:{name:"() => string"}},fixed:{defaultValue:null,description:"Returns a `<tt>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"fixed",required:!0,type:{name:"() => string"}},fontcolor:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the color attribute value\n@deprecated A legacy feature for browser compatibility",name:"fontcolor",required:!0,type:{name:"(color: string) => string"}},fontsize:{defaultValue:null,description:"Returns a `<font>` HTML element and sets the size attribute value\n@deprecated A legacy feature for browser compatibility\n@deprecated A legacy feature for browser compatibility",name:"fontsize",required:!0,type:{name:"{ (size: number): string; (size: string): string; }"}},italics:{defaultValue:null,description:"Returns an `<i>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"italics",required:!0,type:{name:"() => string"}},link:{defaultValue:null,description:"Returns an `<a>` HTML element and sets the href attribute value\n@deprecated A legacy feature for browser compatibility",name:"link",required:!0,type:{name:"(url: string) => string"}},small:{defaultValue:null,description:"Returns a `<small>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"small",required:!0,type:{name:"() => string"}},strike:{defaultValue:null,description:"Returns a `<strike>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"strike",required:!0,type:{name:"() => string"}},sub:{defaultValue:null,description:"Returns a `<sub>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sub",required:!0,type:{name:"() => string"}},sup:{defaultValue:null,description:"Returns a `<sup>` HTML element\n@deprecated A legacy feature for browser compatibility",name:"sup",required:!0,type:{name:"() => string"}},padStart:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the start (left) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padStart",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},padEnd:{defaultValue:null,description:'Pads the current string with a given string (possibly repeated) so that the resulting string reaches a given length.\nThe padding is applied from the end (right) of the current string.\n@param maxLength The length of the resulting string once the current string has been padded.\nIf this parameter is smaller than the current string\'s length, the current string will be returned as it is.\n@param fillString The string to pad the current string with.\nIf this string is too long, it will be truncated and the left-most part will be applied.\nThe default value for this parameter is " " (U+0020).',name:"padEnd",required:!0,type:{name:"(maxLength: number, fillString?: string | undefined) => string"}},trimEnd:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.",name:"trimEnd",required:!0,type:{name:"() => string"}},trimStart:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.",name:"trimStart",required:!0,type:{name:"() => string"}},trimLeft:{defaultValue:null,description:"Removes the leading white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimStart` instead",name:"trimLeft",required:!0,type:{name:"() => string"}},trimRight:{defaultValue:null,description:"Removes the trailing white space and line terminator characters from a string.\n@deprecated A legacy feature for browser compatibility. Use `trimEnd` instead",name:"trimRight",required:!0,type:{name:"() => string"}},matchAll:{defaultValue:null,description:"Matches a string with a regular expression, and returns an iterable of matches\ncontaining the results of that search.\n@param regexp A variable name or string literal containing the regular expression pattern and flags.",name:"matchAll",required:!0,type:{name:"(regexp: RegExp) => IterableIterator<RegExpMatchArray>"}},"__@iterator@58433":{defaultValue:null,description:"Iterator",name:"__@iterator@58433",required:!0,type:{name:"() => IterableIterator<string>"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => string | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/phone-input/phone-input-value-formater.tsx#removeNonDigits"]={docgenInfo:r.__docgenInfo,name:"removeNonDigits",path:"src/components/phone-input/phone-input-value-formater.tsx#removeNonDigits"})}catch(e){}},7941:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.trimCharAfterMaxLength=t.getMaskFromSplitIndex=t.getValueFromSplitIndex=void 0;const a=n(4872);t.getValueFromSplitIndex=function(e,t){let n;return n=(0,a.hasAnyDecimalChar)(e)?-1===t?e:e.slice(0,t):"",n},t.getMaskFromSplitIndex=function(e,t,n){let r;return r=(0,a.hasAnyDecimalChar)(e)?-1===t?"":e.slice(t):n,r},t.trimCharAfterMaxLength=function(e,t){return e.substr(0,t)}},1971:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.PhoneInput=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(7217),d=n(7529),c=n(4872),m=n(5119),p=n(7941),f=l.default.div`
|
|
1727
1738
|
background: transparent;
|
|
1728
1739
|
bottom: 1px;
|
|
1729
1740
|
color: ${({theme:e})=>e.greys["dark-grey"]};
|
|
@@ -1883,9 +1894,9 @@
|
|
|
1883
1894
|
color: ${e=>e.theme.greys["dark-grey"]};
|
|
1884
1895
|
}
|
|
1885
1896
|
`,h=({className:e,steps:t,value:n})=>{const a=t.length,i=(0,o.clamp)(n,1,a)-1;return(0,r.jsxs)(l,Object.assign({className:e},{children:[(0,r.jsx)(s,{max:a-1,value:i}),(0,r.jsx)(d,Object.assign({"data-testid":"progress-steps"},{children:t.map(((e,t)=>function(e,t,n){let a,i;return t<n?(i="progress-step-past",a=m):t===n?(i="progress-step-current",a=p):(i="progress-step-future",a=f),(0,r.jsx)(a,Object.assign({"data-testid":i},{children:(0,r.jsx)("span",{children:e.label})}),t)}(e,t,i)))}))]}))};t.Progress=h;try{h.displayName="Progress",h.__docgenInfo={description:"",displayName:"Progress",props:{className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},steps:{defaultValue:null,description:"",name:"steps",required:!0,type:{name:"ProgressStep[]"}},value:{defaultValue:null,description:"",name:"value",required:!0,type:{name:"number"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/progress/progress.tsx#Progress"]={docgenInfo:h.__docgenInfo,name:"Progress",path:"src/components/progress/progress.tsx#Progress"})}catch(e){}},2057:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.RadioButtonGroup=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(6784),d=n(1785),c=n(2651),m=l.default.div`
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1897
|
+
div + label {
|
|
1898
|
+
margin-top: var(--spacing-1x);
|
|
1899
|
+
}
|
|
1889
1900
|
`,p=l.default.label`
|
|
1890
1901
|
${e=>`\n ${e.disabled?"":"cursor: pointer;"};\n display: block;\n font-size: 0.875rem;\n line-height: 1.5rem;\n padding-left: var(--spacing-3x);\n position: relative;\n user-select: none;\n\n &:not(:first-of-type) {\n margin-top: var(--spacing-1x);\n }\n\n input {\n height: 16px;\n left: 0;\n margin: 0;\n opacity: 0;\n position: absolute;\n top: 2px;\n width: 16px;\n\n &:checked + .radioInput {\n background-color: ${e.theme.main["primary-1.1"]};\n border: 1px solid ${e.theme.main["primary-1.1"]};\n\n &::after {\n background-color: ${e.theme.greys.white};\n border-radius: 50%;\n content: "";\n height: 8px;\n left: 50%;\n position: absolute;\n top: 50%;\n transform: translate(-50%, -50%);\n width: 8px;\n }\n }\n\n ${(0,s.focus)(e,!0,"&:focus + .radioInput")}\n }\n\n .radioInput {\n background-color: ${e.disabled?e.theme.greys["light-grey"]:e.theme.greys.white};\n border: 1px solid ${e.disabled?e.theme.greys.grey:e.theme.greys["dark-grey"]};\n border-radius: 50%;\n box-sizing: border-box;\n display: inline-block;\n height: 16px;\n left: 0;\n margin-top: var(--spacing-half);\n position: absolute;\n top: 0;\n width: 16px;\n }\n\n &:hover .radioInput {\n border: 1px solid ${e.disabled?e.theme.greys.grey:e.theme.main["primary-1.1"]};\n }\n `}
|
|
1891
1902
|
`,f=e=>{var{id:t,buttons:n,groupName:r,label:l,tooltip:s,onChange:f,checkedValue:h}=e,g=a(e,["id","buttons","groupName","label","tooltip","onChange","checkedValue"]);const v=(0,u.useDataAttributes)(g),y=v["data-testid"]?v["data-testid"]:"radio-button-group",b=(0,o.useMemo)((()=>t||(0,d.v4)()),[t]);return(0,i.jsxs)(m,{children:[l&&(0,i.jsx)(c.Label,Object.assign({forId:b,tooltip:s},{children:l})),n.map((e=>(0,i.jsxs)(p,Object.assign({disabled:e.disabled},{children:[" ",e.label,(0,i.jsx)("input",{"data-testid":`${y}-${e.value}`,type:"radio",name:r,value:e.value,checked:h?h===e.value:void 0,defaultChecked:e.defaultChecked,disabled:e.disabled,onChange:f}),(0,i.jsx)("span",{className:"radioInput"})]}),`${r}-${e.value}`)))]})};t.RadioButtonGroup=f;try{f.displayName="RadioButtonGroup",f.__docgenInfo={description:"",displayName:"RadioButtonGroup",props:{id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"",name:"label",required:!1,type:{name:"string"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},groupName:{defaultValue:null,description:"Sets the name property of all buttons",name:"groupName",required:!0,type:{name:"string"}},checkedValue:{defaultValue:null,description:"",name:"checkedValue",required:!1,type:{name:"string"}},buttons:{defaultValue:null,description:"",name:"buttons",required:!0,type:{name:"{ label: string; value: string; defaultChecked?: boolean | undefined; disabled?: boolean | undefined; }[]"}},onChange:{defaultValue:null,description:"",name:"onChange",required:!1,type:{name:"((event: ChangeEvent<HTMLInputElement>) => void)"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/radio-button-group/radio-button-group.tsx#RadioButtonGroup"]={docgenInfo:f.__docgenInfo,name:"RadioButtonGroup",path:"src/components/radio-button-group/radio-button-group.tsx#RadioButtonGroup"})}catch(e){}},6106:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.RouteLink=void 0;const r=n(348),i=a(n(1608)),o=n(7217),l=n(2082),u=n(7106),s=(0,i.default)(u.StyledLink)`
|
|
@@ -1971,7 +1982,7 @@
|
|
|
1971
1982
|
padding-bottom: var(--spacing-half);
|
|
1972
1983
|
padding-left: ${({hasIcon:e})=>e?"1.75rem":"var(--spacing-1x)"};
|
|
1973
1984
|
padding-right: ${({hasReset:e})=>e?"1.75rem":"var(--spacing-1x)"};
|
|
1974
|
-
padding-top: var(--spacing-half);
|
|
1985
|
+
padding-top: var(--spacing-half); /* stylelint-disable-line declaration-block-no-redundant-longhand-properties */
|
|
1975
1986
|
|
|
1976
1987
|
label + & {
|
|
1977
1988
|
margin-top: 0;
|
|
@@ -2019,8 +2030,10 @@
|
|
|
2019
2030
|
grid-template-areas:
|
|
2020
2031
|
"icon content"
|
|
2021
2032
|
"button button";
|
|
2022
|
-
grid-template-columns: auto 1fr
|
|
2023
|
-
|
|
2033
|
+
grid-template-columns: auto 1fr;
|
|
2034
|
+
`:u.css`
|
|
2035
|
+
display: flex;
|
|
2036
|
+
`}function v(e,t,n=t){return u.default.div`
|
|
2024
2037
|
background-color: ${e};
|
|
2025
2038
|
border: 1px solid ${e=>t?e.theme.notifications[t]:e.theme.main["primary-3"]};
|
|
2026
2039
|
box-sizing: border-box;
|
|
@@ -2034,7 +2047,8 @@
|
|
|
2034
2047
|
${h} {
|
|
2035
2048
|
color: ${e=>n?e.theme.notifications[n]:e.theme.main["primary-3"]};
|
|
2036
2049
|
flex: 0 0 auto;
|
|
2037
|
-
}
|
|
2050
|
+
}
|
|
2051
|
+
`}const y=v("#f9f7fb","info-1.1"),b=v("#f6fbf8","success-1.1"),w=v("#fffbf5","warning-3.1","warning-3.4"),M=v("#fdf6f7","alert-2.1"),E=u.default.p`
|
|
2038
2052
|
font-size: ${e=>e.isMobile?"1rem":"0.875rem"};
|
|
2039
2053
|
margin: ${e=>e.isMobile?"var(--spacing-2x)":"var(--spacing-1x)"} 0 0 0;
|
|
2040
2054
|
`,k=u.default.div`
|
|
@@ -2103,7 +2117,7 @@
|
|
|
2103
2117
|
display: flex;
|
|
2104
2118
|
`,k=e=>{var{ariaLabel:t,className:n,defaultOpen:r=!1,defaultValue:l,disabled:h,noMargin:k,id:C,label:x,onChange:_,options:S,name:T,numberOfItemsVisible:P=4,placeholder:H,required:O,searchable:V,skipOption:q,tooltip:j,valid:L=!0,validationErrorMessage:A,value:D,hint:R}=e,I=a(e,["ariaLabel","className","defaultOpen","defaultValue","disabled","noMargin","id","label","onChange","options","name","numberOfItemsVisible","placeholder","required","searchable","skipOption","tooltip","valid","validationErrorMessage","value","hint"]);const{t:W}=(0,s.useTranslation)("select"),{device:N,isMobile:z}=(0,f.useDeviceContext)(),Z=(0,o.useMemo)((()=>C||(0,m.v4)()),[C]),B=(0,u.useDataAttributes)(I),[F,$]=(0,o.useState)(!1),[U,Y]=(0,o.useState)(!1),[K,X]=(0,o.useState)(!1),[G,J]=(0,o.useState)(r),[Q,ee]=(0,o.useState)(""),[te,ne]=(0,o.useState)(),[ae,re]=(0,o.useState)(l||D),ie=(0,o.useMemo)((()=>q&&q.value===ae),[ae,q]),oe=(0,o.useRef)(null),le=(0,o.useRef)(null),ue=(0,o.useRef)(null),[se,de]=(0,o.useState)(V),ce=(0,o.useMemo)((()=>se?w(S,Q):S),[S,Q,se]),me=(0,o.useCallback)((e=>S.find((t=>t.value===e))),[S]),[pe,fe]=(0,o.useState)((()=>{var e,t;return null!==(t=null===(e=me(ae))||void 0===e?void 0:e.label)&&void 0!==t?t:""}));(0,o.useEffect)((()=>{const e=me(D);e?(re(e.value),fe(e.label)):q&&q.value===D&&(re(q.value),fe(""))}),[me,S,q,ie,D]);const he=(0,o.useCallback)((()=>{var e;h||(G?(null===(e=oe.current)||void 0===e||e.focus(),$(!1),ne("")):(X(!0),V&&oe.current?(oe.current.focus(),ne("")):ne(ae)),J(!G))}),[h,G,V,ae]),ge=(0,o.useCallback)((e=>{var t;const n=!(0,d.eventIsInside)(e,le.current,ue.current);(null===le.current||n)&&G&&(he(),null===(t=oe.current)||void 0===t||t.blur())}),[G,he]);function ve(e){const t=e.find((e=>!e.disabled));t&&ne(t.value)}function ye(e){const t=[...e].reverse().find((e=>!e.disabled));t&&ne(t.value)}function be(){ne(""),fe(""),re(""),ee("")}(0,o.useEffect)((()=>(document.addEventListener("mouseup",ge),()=>document.removeEventListener("mouseup",ge))),[ge,G]);const we=(0,o.useCallback)((()=>{const e=(t=pe,S.find((e=>e.label.toLowerCase()===t.toLowerCase())));var t;e&&(re(e.value),fe(e.label))}),[pe,S]),Me=(0,o.useCallback)((e=>{var t;J(!1),X(!1),ne(""),fe(e.label),re(e.value),de(!1),null==_||_(e),V&&($(!1),ee(e.label)),null===(t=oe.current)||void 0===t||t.focus()}),[_,V]),Ee=(0,o.useCallback)((e=>{e&&fe(e.label)}),[]);(0,o.useEffect)((()=>{!G||te&&ce.find((e=>e.value===te))||(ce.length>0?ve(ce):(re(""),ne("")))}),[te,ce,G]);const ke=(0,o.useCallback)((()=>{V?ne(""):(he(),we()),$(!1)}),[he,we,V]),Ce=(0,o.useCallback)((e=>{switch(e.key){case"ArrowDown":if(G){if(V)if(""!==Q){const e=ce.length>1?ce[1]:ce[0];setTimeout((()=>ne(e.value)),10)}else setTimeout((()=>ve(ce)),10)}else he(),V||!ae?ve(ce):ne(ae);$(!0);break;case"ArrowUp":G?V?setTimeout((()=>ye(ce)),10):F&&$(!1):(he(),V||!ae?ye(ce):setTimeout((()=>ne(ae)),10)),$(!0);break;case"Enter":if(e.preventDefault(),""!==Q&&ce.length>0&&G){const e=me(te);e&&Me(e)}else G||V||(he(),setTimeout((()=>ne(ae)),10));break;case" ":G||(e.preventDefault(),he(),V||setTimeout((()=>ne(ae)),10));break;case"Escape":V&&be(),G&&(he(),we())}}),[F,ce,Me,he,we,G,Q,V,ae,me,te]),xe=(0,o.useCallback)((e=>{var t;if("Escape"===e.key)V?be():we(),ne(""),he();else if("ArrowUp"!==e.key||te){if((0,c.isLetterOrNumber)(e.key))if(V)$(!1),ne(""),null===(t=oe.current)||void 0===t||t.focus();else{const t=S.find((t=>t.label.toLowerCase().startsWith(e.key.toLowerCase())));t&&ne(t.value)}}else ye(S)}),[te,he,we,S,V]);return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(y,Object.assign({className:n,noMargin:k,fieldId:Z,label:x,tooltip:j,valid:L,validationErrorMessage:A||W("validationErrorMessage"),hint:R},{children:[(0,i.jsxs)(b,Object.assign({"aria-expanded":G,"aria-haspopup":"listbox","aria-owns":`listbox_${Z}`,"data-testid":"input-wrapper",containerOutline:U,isMobile:z,disabled:h,focus:K,ref:le,role:V?"combobox":void 0,valid:L,onClick:ke},{children:[(0,i.jsx)(M,Object.assign({"aria-label":t||x||W("inputAriaLabel"),"aria-activedescendant":ae?`${Z}_${ae}`:void 0,"aria-autocomplete":V?"both":"list","aria-controls":`listbox_${Z}`,"aria-multiline":"false","data-testid":"input",id:Z,isMobile:z,disabled:h,name:T,onBlur:function(){we(),G||X(!1),Y(!1)},onChange:function(e){if(V){const t=e.currentTarget.value,n=w(S,t);pe!==t&&de(!0),""===t?(ne(""),ee(""),fe(t),J(!1),re("")):(fe(t),ee(t),J(n.length>=1))}},onFocus:function(){X(!0),Y(!0)},onKeyDown:Ce,placeholder:H,ref:oe,required:O,searchable:V,type:"text",value:pe},B)),(0,i.jsx)(E,Object.assign({"aria-labelledby":Z,type:"button","data-testid":"arrow",tabIndex:-1,onClick:h?void 0:function(){he(),we()},disabled:h},{children:(0,i.jsx)(g.Icon,{name:G?"chevronUp":"chevronDown",size:"mobile"===N?"24":"16"})}))]})),G&&(0,i.jsx)(v.Listbox,{ariaLabelledBy:Z,autofocus:V?F:G,ref:ue,checkIndicator:!0,"data-testid":"listbox",defaultValue:l,focusedValue:te,id:`listbox_${Z}`,numberOfItemsVisible:P,onChange:Me,onFocusedValueChange:V?void 0:Ee,onKeyDown:xe,options:ce,value:ae,dropdown:!0})]})),q&&(0,i.jsx)(p.ChooserButton,Object.assign({checked:ie,"data-testid":"select-skip-option",groupName:`${Z}_skip`,onChange:function(){var e;!ie&&q&&(re(q.value),fe(""),null==_||_({label:q.label,value:null!==(e=q.value)&&void 0!==e?e:q.label}))},type:"radio",value:q.value},{children:q.label}))]})};t.Select=k;try{k.displayName="Select",k.__docgenInfo={description:"",displayName:"Select",props:{ariaLabel:{defaultValue:null,description:"Sets input's aria-label",name:"ariaLabel",required:!1,type:{name:"string"}},className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},defaultOpen:{defaultValue:{value:!1},description:"",name:"defaultOpen",required:!1,type:{name:"boolean"}},defaultValue:{defaultValue:null,description:"The default selected option",name:"defaultValue",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"Disables input",name:"disabled",required:!1,type:{name:"boolean"}},noMargin:{defaultValue:null,description:"Disables default margin",name:"noMargin",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"",name:"label",required:!1,type:{name:"string"}},name:{defaultValue:null,description:"",name:"name",required:!1,type:{name:"string"}},numberOfItemsVisible:{defaultValue:{value:4},description:"Number of visible items in the listbox before overflow",name:"numberOfItemsVisible",required:!1,type:{name:"number"}},options:{defaultValue:null,description:"{ disabled?: boolean, value: string; label: string; }[]",name:"options",required:!0,type:{name:"Option[]"}},placeholder:{defaultValue:null,description:"",name:"placeholder",required:!1,type:{name:"string"}},required:{defaultValue:null,description:"",name:"required",required:!1,type:{name:"boolean"}},searchable:{defaultValue:null,description:"Adds search functionality with autocomplete",name:"searchable",required:!1,type:{name:"boolean"}},skipOption:{defaultValue:null,description:"Adds a skip button",name:"skipOption",required:!1,type:{name:"{ label: string; value?: string; }"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},valid:{defaultValue:{value:!0},description:"Sets input validity",name:"valid",required:!1,type:{name:"boolean"}},validationErrorMessage:{defaultValue:{value:"You must select an option"},description:"Sets error message",name:"validationErrorMessage",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"Set the selected value",name:"value",required:!1,type:{name:"string"}},hint:{defaultValue:null,description:"",name:"hint",required:!1,type:{name:"string"}},onChange:{defaultValue:null,description:"OnChange callback function, invoked when an option is selected",name:"onChange",required:!1,type:{name:"((option: Option) => void)"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/select/select.tsx#Select"]={docgenInfo:k.__docgenInfo,name:"Select",path:"src/components/select/select.tsx#Select"})}catch(e){}},50:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ShadowWrapper=void 0;const a=n(348),r=n(4381),i=n(1608),o=n(1311),l=(0,r.createProxy)({},"styled-components",(({root:e,children:t})=>(0,a.jsx)(i.StyleSheetManager,Object.assign({target:e},{children:(0,a.jsx)(a.Fragment,{children:t})})))),u=({children:e,tagName:t="div"})=>{const n=l[t];return(0,a.jsxs)(n,{children:[(0,a.jsx)("style",{children:o.mainCss}),e]})};t.ShadowWrapper=u;try{u.displayName="ShadowWrapper",u.__docgenInfo={description:"",displayName:"ShadowWrapper",props:{tagName:{defaultValue:{value:"div"},description:"Sets host element tag",name:"tagName",required:!1,type:{name:"string"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/shadow-wrapper/shadow-wrapper.tsx#ShadowWrapper"]={docgenInfo:u.__docgenInfo,name:"ShadowWrapper",path:"src/components/shadow-wrapper/shadow-wrapper.tsx#ShadowWrapper"})}catch(e){}},469:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.SideDrawer=void 0;const r=n(348),i=n(8156),o=a(n(1608)),l=n(7217),u=o.default.div`
|
|
2105
2119
|
background-color: ${e=>e.theme.greys.white};
|
|
2106
|
-
box-shadow: 0 6px 10px 0
|
|
2120
|
+
box-shadow: 0 6px 10px 0 rgb(0 0 0 / 10%);
|
|
2107
2121
|
height: calc(100vh - ${({isDesktop:e})=>e?48:56}px);
|
|
2108
2122
|
${({origin:e})=>`${e}: 0`};
|
|
2109
2123
|
overflow-x: hidden; /* stylelint-disable-line declaration-empty-line-before */
|
|
@@ -2212,7 +2226,7 @@
|
|
|
2212
2226
|
margin: 0;
|
|
2213
2227
|
}
|
|
2214
2228
|
|
|
2215
|
-
&[type=number] {
|
|
2229
|
+
&[type="number"] {
|
|
2216
2230
|
-moz-appearance: textfield; /* stylelint-disable-line property-no-vendor-prefix */
|
|
2217
2231
|
}
|
|
2218
2232
|
`;function h(e){var t;null===(t=e.current)||void 0===t||t.dispatchEvent(new Event("change",{bubbles:!0}))}const g=({defaultValue:e,disabled:t,hint:n,id:a,label:o,max:c,min:g,noMargin:v,step:y,tooltip:b,valid:w=!0,validationErrorMessage:M,value:E,onBlur:k,onChange:C,onFocus:x})=>{const _=(0,i.useRef)(null),{t:S}=(0,l.useTranslation)("stepper-input"),T=(0,s.useDeviceContext)(),P=(0,i.useMemo)((()=>a||(0,u.v4)()),[a]);return(0,r.jsx)(d.FieldContainer,Object.assign({fieldId:P,hint:n,label:o,tooltip:b,noMargin:v,valid:w,validationErrorMessage:M||S("validationErrorMessage")},{children:(0,r.jsxs)(p,{children:[(0,r.jsx)(f,{"data-testid":"stepper-input",defaultValue:e,device:T,disabled:t,id:P,max:c,min:g,name:"points",onChange:e=>{const t=e.target.value;if(""===t)null==C||C(null);else{const e=Number(t);null==C||C(e)}},onBlur:k,onFocus:x,ref:_,step:y,type:"number",value:null===E?"":E}),!T.isMobile&&(0,r.jsx)(m.StepperButtons,{disabled:t,onDecrement:function(){var e,t,n;const a=Number(null===(e=_.current)||void 0===e?void 0:e.value);null===(t=_.current)||void 0===t||t.stepDown(),a!==Number(null===(n=_.current)||void 0===n?void 0:n.value)&&h(_)},onIncrement:function(){var e,t,n;const a=Number(null===(e=_.current)||void 0===e?void 0:e.value);null===(t=_.current)||void 0===t||t.stepUp(),a!==Number(null===(n=_.current)||void 0===n?void 0:n.value)&&h(_)}})]})}))};t.StepperInput=g;try{g.displayName="StepperInput",g.__docgenInfo={description:"",displayName:"StepperInput",props:{defaultValue:{defaultValue:null,description:"",name:"defaultValue",required:!1,type:{name:"number"}},hint:{defaultValue:null,description:"",name:"hint",required:!1,type:{name:"string"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"",name:"label",required:!1,type:{name:"string"}},max:{defaultValue:null,description:"",name:"max",required:!1,type:{name:"number"}},min:{defaultValue:null,description:"",name:"min",required:!1,type:{name:"number"}},noMargin:{defaultValue:null,description:"",name:"noMargin",required:!1,type:{name:"boolean"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},valid:{defaultValue:{value:!0},description:"",name:"valid",required:!1,type:{name:"boolean"}},validationErrorMessage:{defaultValue:null,description:"",name:"validationErrorMessage",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"",name:"value",required:!1,type:{name:"Value"}},onChange:{defaultValue:null,description:"",name:"onChange",required:!1,type:{name:"((value: Value) => void)"}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},onBlur:{defaultValue:null,description:"",name:"onBlur",required:!1,type:{name:"FocusEventHandler<HTMLInputElement>"}},onFocus:{defaultValue:null,description:"",name:"onFocus",required:!1,type:{name:"FocusEventHandler<HTMLInputElement>"}},step:{defaultValue:null,description:"",name:"step",required:!1,type:{name:"string | number"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/stepper-input/stepper-input.tsx#StepperInput"]={docgenInfo:g.__docgenInfo,name:"StepperInput",path:"src/components/stepper-input/stepper-input.tsx#StepperInput"})}catch(e){}},5180:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SortButtonIcon=void 0;const a=n(348),r=n(5621),i=n(2082),o=({sort:e})=>{const t=(0,r.useTheme)();switch(e){case"ascending":return(0,a.jsx)(i.Icon,{name:"arrowDown",size:"16",color:t.greys["dark-grey"]});case"descending":return(0,a.jsx)(i.Icon,{name:"arrowUp",size:"16",color:t.greys["dark-grey"]});default:return(0,a.jsx)(i.Icon,{name:"reorder",size:"16",color:t.greys["dark-grey"]})}};t.SortButtonIcon=o;try{o.displayName="SortButtonIcon",o.__docgenInfo={description:"",displayName:"SortButtonIcon",props:{sort:{defaultValue:null,description:"",name:"sort",required:!0,type:{name:"enum",value:[{value:'"none"'},{value:'"ascending"'},{value:'"descending"'}]}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/table/sort-button-icon.tsx#SortButtonIcon"]={docgenInfo:o.__docgenInfo,name:"SortButtonIcon",path:"src/components/table/sort-button-icon.tsx#SortButtonIcon"})}catch(e){}},9949:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.SortableColumnHeading=void 0;const r=n(348),i=n(8156),o=a(n(1608)),l=n(5180),u=o.default.button`
|
|
@@ -2283,20 +2297,26 @@
|
|
|
2283
2297
|
|
|
2284
2298
|
${function({theme:e,selected:t,error:n}){return t?l.css`
|
|
2285
2299
|
/* TODO fix with next thematization */
|
|
2286
|
-
background-color: #e0f0f9
|
|
2300
|
+
background-color: #e0f0f9;
|
|
2301
|
+
`:n?l.css`
|
|
2287
2302
|
/* TODO fix with next thematization theme.notifications.error4 */
|
|
2288
|
-
background-color: #fcf8f9
|
|
2303
|
+
background-color: #fcf8f9;
|
|
2304
|
+
`:l.css`
|
|
2305
|
+
background-color: ${e.greys.white};
|
|
2306
|
+
`}}
|
|
2289
2307
|
${function({theme:e,clickable:t}){return t?l.css`
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2308
|
+
:hover td {
|
|
2309
|
+
background-color: ${e.greys.grey};
|
|
2310
|
+
}
|
|
2293
2311
|
|
|
2294
|
-
|
|
2295
|
-
background-color: inherit;
|
|
2296
|
-
}`:l.css`
|
|
2297
|
-
td {
|
|
2312
|
+
:not(:hover) td {
|
|
2298
2313
|
background-color: inherit;
|
|
2299
|
-
}
|
|
2314
|
+
}
|
|
2315
|
+
`:l.css`
|
|
2316
|
+
td {
|
|
2317
|
+
background-color: inherit;
|
|
2318
|
+
}
|
|
2319
|
+
`}}
|
|
2300
2320
|
`,s=l.default.td`
|
|
2301
2321
|
${({sticky:e})=>e&&l.css`
|
|
2302
2322
|
position: sticky;
|
|
@@ -2331,7 +2351,7 @@
|
|
|
2331
2351
|
}
|
|
2332
2352
|
}
|
|
2333
2353
|
|
|
2334
|
-
|
|
2354
|
+
${".eq-table__util-column"} {
|
|
2335
2355
|
box-sizing: border-box;
|
|
2336
2356
|
color: ${({theme:e})=>e.greys["dark-grey"]};
|
|
2337
2357
|
font-size: 0.75rem;
|
|
@@ -2421,8 +2441,7 @@
|
|
|
2421
2441
|
height: ${y};
|
|
2422
2442
|
margin-right: var(--spacing-1x);
|
|
2423
2443
|
vertical-align: middle;
|
|
2424
|
-
`,w=(0,u.default)(m.Icon).attrs({"aria-hidden":"true",name:"x",color:"#60666e"})`
|
|
2425
|
-
`,M=u.default.button`
|
|
2444
|
+
`,w=(0,u.default)(m.Icon).attrs({"aria-hidden":"true",name:"x",color:"#60666e"})``,M=u.default.button`
|
|
2426
2445
|
border-radius: 50%;
|
|
2427
2446
|
cursor: pointer;
|
|
2428
2447
|
display: inline-block;
|
|
@@ -2463,7 +2482,7 @@
|
|
|
2463
2482
|
margin-left: var(--spacing-1x);
|
|
2464
2483
|
}
|
|
2465
2484
|
|
|
2466
|
-
${M} {
|
|
2485
|
+
${M} { /* stylelint-disable-line no-descending-specificity */
|
|
2467
2486
|
margin-right: calc(-1 * var(--spacing-half));
|
|
2468
2487
|
}
|
|
2469
2488
|
|
|
@@ -2479,7 +2498,8 @@
|
|
|
2479
2498
|
}
|
|
2480
2499
|
}
|
|
2481
2500
|
|
|
2482
|
-
${d.focus}
|
|
2501
|
+
${d.focus};
|
|
2502
|
+
`}};
|
|
2483
2503
|
|
|
2484
2504
|
${d.focus};
|
|
2485
2505
|
`,k=({className:e,iconName:t,onClick:n,onDelete:a,size:r="medium",value:i})=>{if(n&&a)throw new Error("Only one of onClick or onDelete can be provided.");const{t:u}=(0,s.useTranslation)("tag"),{isMobile:d}=(0,c.useDeviceContext)(),m=!(i.label.toLowerCase()===(null==t?void 0:t.toLowerCase())),p=(0,l.useCallback)((()=>{null==n||n(i)}),[n,i]),h=(0,l.useCallback)((e=>{e.stopPropagation(),null==a||a(i)}),[a,i]);return(0,o.jsxs)(E,Object.assign({as:n?"button":"span",className:e,onClick:p,type:n?"button":void 0,$isMobile:d,$tagSize:r,$clickable:!!n,$deletable:!!a,$hasIcon:!!t},{children:[t&&(0,o.jsx)(b,{"aria-label":m?t:void 0,"aria-hidden":!m,"data-testid":`${i.label}-icon`,name:t,size:f(d),role:"img",$isMobile:d,$tagSize:r,focusable:void 0}),i.label,a&&(0,o.jsx)(M,Object.assign({"data-testid":`${i.label}-delete-button`,type:"button","aria-label":u("deleteButtonAriaLabel",{label:i.label}),onClick:h,$tagSize:r,$isMobile:d},{children:(0,o.jsx)(w,{size:f(d),"aria-hidden":"true"})}))]}))};t.Tag=k;try{k.displayName="Tag",k.__docgenInfo={description:"",displayName:"Tag",props:{className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},iconName:{defaultValue:null,description:"",name:"iconName",required:!1,type:{name:"enum",value:[{value:'"alertCircle"'},{value:'"alertFilled"'},{value:'"alertTriangle"'},{value:'"alertOctagon"'},{value:'"arrowDown"'},{value:'"arrowLeft"'},{value:'"arrowRight"'},{value:'"arrowUp"'},{value:'"bell"'},{value:'"bento"'},{value:'"calendar"'},{value:'"check"'},{value:'"chevronDown"'},{value:'"chevronLeft"'},{value:'"chevronRight"'},{value:'"chevronUp"'},{value:'"chevronsLeft"'},{value:'"chevronsRight"'},{value:'"circle"'},{value:'"contracts"'},{value:'"copy"'},{value:'"edit"'},{value:'"equisoft"'},{value:'"externalLink"'},{value:'"eye"'},{value:'"eyeOff"'},{value:'"files"'},{value:'"helpCircle"'},{value:'"history"'},{value:'"home"'},{value:'"info"'},{value:'"mail"'},{value:'"mapPin"'},{value:'"megaphone"'},{value:'"menu"'},{value:'"minus"'},{value:'"moreHorizontal"'},{value:'"moreVertical"'},{value:'"organization"'},{value:'"open"'},{value:'"phone"'},{value:'"plusSign"'},{value:'"reorder"'},{value:'"search"'},{value:'"settings"'},{value:'"star"'},{value:'"transfer"'},{value:'"trash"'},{value:'"user"'},{value:'"users"'},{value:'"warningFilled"'},{value:'"x"'}]}},size:{defaultValue:{value:"medium"},description:"",name:"size",required:!1,type:{name:"enum",value:[{value:'"small"'},{value:'"medium"'}]}},value:{defaultValue:null,description:"",name:"value",required:!0,type:{name:"TagValue"}},onClick:{defaultValue:null,description:"Mutually exclusive with onDelete",name:"onClick",required:!1,type:{name:"((tag: TagValue) => void)"}},onDelete:{defaultValue:null,description:"Mutually exclusive with onClick",name:"onDelete",required:!1,type:{name:"((tag: TagValue) => void)"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/tag/tag.tsx#Tag"]={docgenInfo:k.__docgenInfo,name:"Tag",path:"src/components/tag/tag.tsx#Tag"})}catch(e){}},2289:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.TextArea=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(210),d=n(1785),c=n(6714),m=n(328),p=l.default.textarea`
|
|
@@ -2558,7 +2578,7 @@
|
|
|
2558
2578
|
${(0,r.focus)({theme:e},!0)}
|
|
2559
2579
|
`;t.responsiveInputsStyle=i;try{i.displayName="responsiveInputsStyle",i.__docgenInfo={description:"",displayName:"responsiveInputsStyle",props:{theme:{defaultValue:null,description:"",name:"theme",required:!0,type:{name:"Theme"}},device:{defaultValue:null,description:"",name:"device",required:!0,type:{name:"DeviceContextProps"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/text-input/styles/inputs.tsx#responsiveInputsStyle"]={docgenInfo:i.__docgenInfo,name:"responsiveInputsStyle",path:"src/components/text-input/styles/inputs.tsx#responsiveInputsStyle"})}catch(e){}},7529:function(e,t,n){"use strict";var a=this&&this.__rest||function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(a=Object.getOwnPropertySymbols(e);r<a.length;r++)t.indexOf(a[r])<0&&Object.prototype.propertyIsEnumerable.call(e,a[r])&&(n[a[r]]=e[a[r]])}return n},r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.TextInput=void 0;const i=n(348),o=n(8156),l=r(n(1608)),u=n(3726),s=n(210),d=n(1785),c=n(7217),m=n(6714),p=n(328),f=l.default.input`
|
|
2560
2580
|
${({theme:e,isMobile:t})=>(0,p.inputsStyle)(e,t)}
|
|
2561
|
-
`;t.TextInput=(0,o.forwardRef)(((e,t)=>{var{ariaDescribedBy:n,ariaInvalid:r,className:l,defaultValue:p,disabled:h,hint:g,id:v,inputMode:y,label:b,tooltip:w,name:M,noMargin:E,pattern:k,placeholder:C,required:x,type:_,validationErrorMessage:S,value:T,autoComplete:P,onBlur:H,onChange:O,onFocus:V,onKeyUp:q,onKeyDown:j,onMouseUp:L}=e,A=a(e,["ariaDescribedBy","ariaInvalid","className","defaultValue","disabled","hint","id","inputMode","label","tooltip","name","noMargin","pattern","placeholder","required","type","validationErrorMessage","value","autoComplete","onBlur","onChange","onFocus","onKeyUp","onKeyDown","onMouseUp"]);const{isMobile:D}=(0,c.useDeviceContext)(),{t:R}=(0,s.useTranslation)("text-input"),[{validity:I},W]=(0,o.useState)({validity:!0}),N=(0,o.useMemo)((()=>v||(0,d.v4)()),[v]),z=(0,u.useDataAttributes)(A),Z=(0,o.useCallback)((e=>{W({validity:e.currentTarget.checkValidity()}),H&&H(e)}),[H]),B=(0,o.useCallback)((()=>{W({validity:!1})}),[]),F=(0,o.useCallback)((e=>{O&&O(e)}),[O]),$=(0,o.useCallback)((e=>{V&&V(e)}),[V]);return(0,i.jsx)(m.FieldContainer,Object.assign({className:l,noMargin:E,fieldId:N,label:b,tooltip:w,valid:I,validationErrorMessage:S||R("validationErrorMessage"),hint:g,"data-testid":"field-container"},{children:(0,i.jsx)(f,Object.assign({"aria-describedby":n,"aria-invalid":r,autoComplete:P,"data-testid":"text-input",isMobile:D,defaultValue:p,disabled:h,id:N,inputMode:y,name:M,ref:t,onBlur:Z,onChange:F,onFocus:$,onMouseUp:L,onKeyUp:q,onKeyDown:j,onInvalid:B,pattern:k,placeholder:C,required:x,type:_||"text",value:T},z))}))})),t.TextInput.displayName="TextInput";try{TextInput.displayName="TextInput",TextInput.__docgenInfo={description:"",displayName:"TextInput",props:{ariaDescribedBy:{defaultValue:null,description:"",name:"ariaDescribedBy",required:!1,type:{name:"string"}},ariaInvalid:{defaultValue:null,description:"",name:"ariaInvalid",required:!1,type:{name:"boolean"}},className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},defaultValue:{defaultValue:null,description:"",name:"defaultValue",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},noMargin:{defaultValue:null,description:"Disables default margin",name:"noMargin",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"",name:"label",required:!1,type:{name:"string"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},pattern:{defaultValue:null,description:"",name:"pattern",required:!1,type:{name:"string"}},placeholder:{defaultValue:null,description:"",name:"placeholder",required:!1,type:{name:"string"}},required:{defaultValue:null,description:"",name:"required",required:!1,type:{name:"boolean"}},type:{defaultValue:null,description:"",name:"type",required:!1,type:{name:"string"}},validationErrorMessage:{defaultValue:null,description:"",name:"validationErrorMessage",required:!1,type:{name:"string"}},hint:{defaultValue:null,description:"",name:"hint",required:!1,type:{name:"string"}},onBlur:{defaultValue:null,description:"",name:"onBlur",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},onChange:{defaultValue:null,description:"",name:"onChange",required:!1,type:{name:"((event: ChangeEvent<HTMLInputElement>) => void)"}},onFocus:{defaultValue:null,description:"",name:"onFocus",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},onKeyUp:{defaultValue:null,description:"",name:"onKeyUp",required:!1,type:{name:"((event: KeyboardEvent<HTMLInputElement>) => void)"}},onKeyDown:{defaultValue:null,description:"",name:"onKeyDown",required:!1,type:{name:"((event: KeyboardEvent<HTMLInputElement>) => void)"}},onMouseUp:{defaultValue:null,description:"",name:"onMouseUp",required:!1,type:{name:"((event: MouseEvent<HTMLInputElement, MouseEvent>) => void)"}},name:{defaultValue:null,description:"",name:"name",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"",name:"value",required:!1,type:{name:"string | number | readonly string[]"}},inputMode:{defaultValue:null,description:"Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",name:"inputMode",required:!1,type:{name:"enum",value:[{value:'"search"'},{value:'"none"'},{value:'"text"'},{value:'"tel"'},{value:'"url"'},{value:'"email"'},{value:'"numeric"'},{value:'"decimal"'}]}},autoComplete:{defaultValue:null,description:"",name:"autoComplete",required:!1,type:{name:"string"}},ref:{defaultValue:null,description:"",name:"ref",required:!1,type:{name:"Ref<HTMLInputElement>"}},key:{defaultValue:null,description:"",name:"key",required:!1,type:{name:"Key | null"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/text-input/text-input.tsx#TextInput"]={docgenInfo:TextInput.__docgenInfo,name:"TextInput",path:"src/components/text-input/text-input.tsx#TextInput"})}catch(e){}},8230:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ThemeWrapper=void 0;const a=n(348),r=n(1608),i=n(1311),o=n(674),l=n(50),u=({children:e,isolateStyles:t=!1,theme:n})=>{let u,s=n;return s?0===Object.entries(s).length&&s.constructor===Object&&(s=o.equisoftTheme):s=o.equisoftTheme,u=t?(0,a.jsx)(l.ShadowWrapper,{children:e}):e,(0,i.useStyle)(t),(0,a.jsx)(r.ThemeProvider,Object.assign({theme:s},{children:u}))};t.ThemeWrapper=u;try{u.displayName="ThemeWrapper",u.__docgenInfo={description:"",displayName:"ThemeWrapper",props:{isolateStyles:{defaultValue:{value:!1},description:"When true, components are mounted in the Shadow DOM",name:"isolateStyles",required:!1,type:{name:"boolean"}},theme:{defaultValue:null,description:"",name:"theme",required:!1,type:{name:"Theme"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/theme-wrapper/theme-wrapper.tsx#ThemeWrapper"]={docgenInfo:u.__docgenInfo,name:"ThemeWrapper",path:"src/components/theme-wrapper/theme-wrapper.tsx#ThemeWrapper"})}catch(e){}},5756:function(e,t,n){"use strict";var a=this&&this.__createBinding||(Object.create?function(e,t,n,a){void 0===a&&(a=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,a,r)}:function(e,t,n,a){void 0===a&&(a=n),e[a]=t[n]}),r=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return r(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.ToastContainer=void 0;const o=n(348),l=n(8156),u=i(n(1608)),s=n(5621),d=n(7526),c=n(210),m=n(3859),p=n(7217),f=n(2082),h=u.keyframes`
|
|
2581
|
+
`;t.TextInput=(0,o.forwardRef)(((e,t)=>{var{ariaDescribedBy:n,ariaInvalid:r,className:l,defaultValue:p,disabled:h,hint:g,id:v,inputMode:y,label:b,tooltip:w,name:M,noMargin:E,pattern:k,placeholder:C,required:x,type:_,validationErrorMessage:S,value:T,autoComplete:P,onBlur:H,onChange:O,onFocus:V,onKeyUp:q,onKeyDown:j,onMouseUp:L}=e,A=a(e,["ariaDescribedBy","ariaInvalid","className","defaultValue","disabled","hint","id","inputMode","label","tooltip","name","noMargin","pattern","placeholder","required","type","validationErrorMessage","value","autoComplete","onBlur","onChange","onFocus","onKeyUp","onKeyDown","onMouseUp"]);const{isMobile:D}=(0,c.useDeviceContext)(),{t:R}=(0,s.useTranslation)("text-input"),[{validity:I},W]=(0,o.useState)({validity:!0}),N=(0,o.useMemo)((()=>v||(0,d.v4)()),[v]),z=(0,u.useDataAttributes)(A),Z=(0,o.useCallback)((e=>{W({validity:e.currentTarget.checkValidity()}),H&&H(e)}),[H]),B=(0,o.useCallback)((()=>{W({validity:!1})}),[]),F=(0,o.useCallback)((e=>{O&&O(e)}),[O]),$=(0,o.useCallback)((e=>{V&&V(e)}),[V]);return(0,i.jsx)(m.FieldContainer,Object.assign({className:l,noMargin:E,fieldId:N,label:b,tooltip:w,valid:I,validationErrorMessage:S||R("validationErrorMessage"),hint:g,"data-testid":"field-container"},{children:(0,i.jsx)(f,Object.assign({"aria-describedby":n,"aria-invalid":r,autoComplete:P,"data-testid":"text-input",isMobile:D,defaultValue:p,disabled:h,id:N,inputMode:y,name:M,ref:t,onBlur:Z,onChange:F,onFocus:$,onMouseUp:L,onKeyUp:q,onKeyDown:j,onInvalid:B,pattern:k,placeholder:C,required:x,type:_||"text",value:T},z))}))})),t.TextInput.displayName="TextInput";try{TextInput.displayName="TextInput",TextInput.__docgenInfo={description:"",displayName:"TextInput",props:{ariaDescribedBy:{defaultValue:null,description:"",name:"ariaDescribedBy",required:!1,type:{name:"string"}},ariaInvalid:{defaultValue:null,description:"",name:"ariaInvalid",required:!1,type:{name:"boolean"}},className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},defaultValue:{defaultValue:null,description:"",name:"defaultValue",required:!1,type:{name:"string"}},disabled:{defaultValue:null,description:"",name:"disabled",required:!1,type:{name:"boolean"}},noMargin:{defaultValue:null,description:"Disables default margin",name:"noMargin",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},label:{defaultValue:null,description:"",name:"label",required:!1,type:{name:"string"}},tooltip:{defaultValue:null,description:"",name:"tooltip",required:!1,type:{name:"TooltipProps"}},pattern:{defaultValue:null,description:"",name:"pattern",required:!1,type:{name:"string"}},placeholder:{defaultValue:null,description:"",name:"placeholder",required:!1,type:{name:"string"}},required:{defaultValue:null,description:"",name:"required",required:!1,type:{name:"boolean"}},type:{defaultValue:null,description:"",name:"type",required:!1,type:{name:"string"}},validationErrorMessage:{defaultValue:null,description:"",name:"validationErrorMessage",required:!1,type:{name:"string"}},hint:{defaultValue:null,description:"",name:"hint",required:!1,type:{name:"string"}},onBlur:{defaultValue:null,description:"",name:"onBlur",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},onChange:{defaultValue:null,description:"",name:"onChange",required:!1,type:{name:"((event: ChangeEvent<HTMLInputElement>) => void)"}},onFocus:{defaultValue:null,description:"",name:"onFocus",required:!1,type:{name:"((event: FocusEvent<HTMLInputElement, Element>) => void)"}},onKeyUp:{defaultValue:null,description:"",name:"onKeyUp",required:!1,type:{name:"((event: KeyboardEvent<HTMLInputElement>) => void)"}},onKeyDown:{defaultValue:null,description:"",name:"onKeyDown",required:!1,type:{name:"((event: KeyboardEvent<HTMLInputElement>) => void)"}},onMouseUp:{defaultValue:null,description:"",name:"onMouseUp",required:!1,type:{name:"((event: MouseEvent<HTMLInputElement, MouseEvent>) => void)"}},name:{defaultValue:null,description:"",name:"name",required:!1,type:{name:"string"}},value:{defaultValue:null,description:"",name:"value",required:!1,type:{name:"string | number | readonly string[]"}},inputMode:{defaultValue:null,description:"Hints at the type of data that might be entered by the user while editing the element or its contents\n@see https://html.spec.whatwg.org/multipage/interaction.html#input-modalities:-the-inputmode-attribute",name:"inputMode",required:!1,type:{name:"enum",value:[{value:'"search"'},{value:'"none"'},{value:'"text"'},{value:'"tel"'},{value:'"url"'},{value:'"email"'},{value:'"numeric"'},{value:'"decimal"'}]}},autoComplete:{defaultValue:null,description:"",name:"autoComplete",required:!1,type:{name:"string"}},ref:{defaultValue:null,description:"",name:"ref",required:!1,type:{name:"Ref<HTMLInputElement>"}},key:{defaultValue:null,description:"",name:"key",required:!1,type:{name:"Key | null"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/text-input/text-input.tsx#TextInput"]={docgenInfo:TextInput.__docgenInfo,name:"TextInput",path:"src/components/text-input/text-input.tsx#TextInput"})}catch(e){}},8230:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ThemeWrapper=void 0;const a=n(348),r=n(1608),i=n(1311),o=n(674),l=n(50),u=({children:e,isolateStyles:t=!1,theme:n})=>{let u,s=n;return s?0===Object.entries(s).length&&s.constructor===Object&&(s=o.equisoftTheme):s=o.equisoftTheme,u=t?(0,a.jsx)(l.ShadowWrapper,{children:e}):e,(0,i.useStyle)(t),(0,a.jsx)(r.ThemeProvider,Object.assign({theme:s},{children:u}))};t.ThemeWrapper=u;try{u.displayName="ThemeWrapper",u.__docgenInfo={description:"",displayName:"ThemeWrapper",props:{isolateStyles:{defaultValue:{value:!1},description:"When true, components are mounted in the Shadow DOM",name:"isolateStyles",required:!1,type:{name:"boolean"}},theme:{defaultValue:null,description:"",name:"theme",required:!1,type:{name:"Theme"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/theme-wrapper/theme-wrapper.tsx#ThemeWrapper"]={docgenInfo:u.__docgenInfo,name:"ThemeWrapper",path:"src/components/theme-wrapper/theme-wrapper.tsx#ThemeWrapper"})}catch(e){}},5756:function(e,t,n){"use strict";var a=this&&this.__createBinding||(Object.create?function(e,t,n,a){void 0===a&&(a=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,a,r)}:function(e,t,n,a){void 0===a&&(a=n),e[a]=t[n]}),r=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return r(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.ToastContainer=void 0;const o=n(348),l=n(8156),u=i(n(1608)),s=n(5621),d=n(7526),c=n(210),m=n(3859),p=n(7217),f=n(2082),h=u.keyframes` /* stylelint-disable-line keyframes-name-pattern */
|
|
2562
2582
|
from {
|
|
2563
2583
|
transform: translateX(-100%);
|
|
2564
2584
|
}
|
|
@@ -2566,7 +2586,7 @@
|
|
|
2566
2586
|
to {
|
|
2567
2587
|
transform: translateX(0);
|
|
2568
2588
|
}
|
|
2569
|
-
`,g=u.keyframes`
|
|
2589
|
+
`,g=u.keyframes` /* stylelint-disable-line keyframes-name-pattern */
|
|
2570
2590
|
from {
|
|
2571
2591
|
transform: translateX(100%);
|
|
2572
2592
|
}
|
|
@@ -2577,7 +2597,7 @@
|
|
|
2577
2597
|
`,v=u.default.div`
|
|
2578
2598
|
align-items: flex-start;
|
|
2579
2599
|
border-radius: var(--border-radius);
|
|
2580
|
-
box-shadow: 0 16px 32px 0
|
|
2600
|
+
box-shadow: 0 16px 32px 0 rgb(0 0 0 / 5%);
|
|
2581
2601
|
box-sizing: border-box;
|
|
2582
2602
|
display: flex;
|
|
2583
2603
|
flex: 1;
|
|
@@ -2587,13 +2607,19 @@
|
|
|
2587
2607
|
width: ${({isMobile:e})=>e?"100vw":"400px"};
|
|
2588
2608
|
|
|
2589
2609
|
${function({position:e}){switch(e){case"top-right":case"bottom-right":return u.css`
|
|
2590
|
-
animation: ${g} 0.25s ease-out
|
|
2591
|
-
|
|
2610
|
+
animation: ${g} 0.25s ease-out;
|
|
2611
|
+
`;case"top-left":case"bottom-left":return u.css`
|
|
2612
|
+
animation: ${h} 0.25s ease-out;
|
|
2613
|
+
`}}}
|
|
2592
2614
|
${function({theme:e,type:t}){switch(t){case"information":return u.css`
|
|
2593
|
-
background: ${e.notifications["info-1.1"]}
|
|
2594
|
-
|
|
2595
|
-
background: ${e.notifications["
|
|
2596
|
-
|
|
2615
|
+
background: ${e.notifications["info-1.1"]};
|
|
2616
|
+
`;case"success":return u.css`
|
|
2617
|
+
background: ${e.notifications["success-1.1"]};
|
|
2618
|
+
`;case"warning":return u.css`
|
|
2619
|
+
background: ${e.notifications["warning-3.3"]};
|
|
2620
|
+
`;case"error":return u.css`
|
|
2621
|
+
background: ${e.notifications["alert-2.1"]};
|
|
2622
|
+
`}}}
|
|
2597
2623
|
`,y=u.default.p`
|
|
2598
2624
|
color: ${({color:e})=>e};
|
|
2599
2625
|
flex: 1;
|
|
@@ -2618,13 +2644,17 @@
|
|
|
2618
2644
|
&:hover {
|
|
2619
2645
|
${function({$type:e,theme:t}){switch(e){case"information":return u.css`
|
|
2620
2646
|
background-color: #3a1c60; /* TODO: theme */
|
|
2621
|
-
color: ${t.greys.white}
|
|
2647
|
+
color: ${t.greys.white};
|
|
2648
|
+
`;case"success":return u.css`
|
|
2622
2649
|
background-color: #004f1e; /* TODO: theme */
|
|
2623
|
-
color: ${t.greys.white}
|
|
2650
|
+
color: ${t.greys.white};
|
|
2651
|
+
`;case"warning":return u.css`
|
|
2624
2652
|
background-color: ${t.notifications["warning-3.4"]};
|
|
2625
|
-
color: ${t.greys.black}
|
|
2653
|
+
color: ${t.greys.black};
|
|
2654
|
+
`;case"error":return u.css`
|
|
2626
2655
|
background-color: #7b1a15; /* TODO: theme */
|
|
2627
|
-
color: ${t.greys.white}
|
|
2656
|
+
color: ${t.greys.white};
|
|
2657
|
+
`}}}
|
|
2628
2658
|
}
|
|
2629
2659
|
`;function w(e){switch(e){case"information":return"info";case"success":return"success";case"warning":return"warning";case"error":return"error"}}const M=(0,u.default)(f.Icon).attrs((({type:e})=>({focusable:!0,"aria-label":w(e)})))`
|
|
2630
2660
|
height: ${({isMobile:e})=>e?"28px":"24px"};
|
|
@@ -2639,13 +2669,17 @@
|
|
|
2639
2669
|
|
|
2640
2670
|
${function({isMobile:e,position:t}){const n=e?"0":"var(--spacing-2x)";switch(t){case"top-right":return d.css`
|
|
2641
2671
|
right: ${n};
|
|
2642
|
-
top: var(--spacing-2x)
|
|
2672
|
+
top: var(--spacing-2x);
|
|
2673
|
+
`;case"bottom-right":return d.css`
|
|
2643
2674
|
bottom: var(--spacing-2x);
|
|
2644
|
-
right: ${n}
|
|
2675
|
+
right: ${n};
|
|
2676
|
+
`;case"top-left":return d.css`
|
|
2645
2677
|
left: ${n};
|
|
2646
|
-
top: var(--spacing-2x)
|
|
2678
|
+
top: var(--spacing-2x);
|
|
2679
|
+
`;case"bottom-left":return d.css`
|
|
2647
2680
|
bottom: var(--spacing-2x);
|
|
2648
|
-
left: ${n}
|
|
2681
|
+
left: ${n};
|
|
2682
|
+
`}}}
|
|
2649
2683
|
`,g=({children:e,shadowRoot:t})=>{const n=function(e){return e?e.getRootNode():document.body}(t);return u.default.createPortal(e,n)},v=({position:e})=>{const{toasts:t}=(0,c.useToasts)(),{isMobile:n}=(0,m.useDeviceContext)(),a=(0,s.useShadowRoot)();return(0,l.jsx)(g,Object.assign({shadowRoot:a},{children:(0,l.jsx)(h,Object.assign({position:e,isMobile:n,"data-testid":"toasts"},{children:t.map((({id:t,type:n,message:a},r)=>(0,l.jsx)(f,{id:t,type:n,message:a,position:e,"data-testid":`toast-${r}`},t)))}))}))};t.ToastsContainer=v;try{v.displayName="ToastsContainer",v.__docgenInfo={description:"",displayName:"ToastsContainer",props:{position:{defaultValue:null,description:"",name:"position",required:!0,type:{name:"enum",value:[{value:'"top-right"'},{value:'"bottom-right"'},{value:'"top-left"'},{value:'"bottom-left"'}]}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/toast/toasts-container.tsx#ToastsContainer"]={docgenInfo:v.__docgenInfo,name:"ToastsContainer",path:"src/components/toast/toasts-container.tsx#ToastsContainer"})}catch(e){}},3502:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useToastsReducer=t.toastsReducer=void 0;const a=n(8156);function r(e,t){switch(t.type){case"add":return[...e,t.toast];case"remove":return e.filter((e=>e.id!==t.id));default:return e}}t.toastsReducer=r,t.useToastsReducer=function(){return(0,a.useReducer)(r,[])}},668:function(e,t,n){"use strict";var a=this&&this.__createBinding||(Object.create?function(e,t,n,a){void 0===a&&(a=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,a,r)}:function(e,t,n,a){void 0===a&&(a=n),e[a]=t[n]}),r=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&a(t,e,n);return r(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.ToggleButtonGroup=void 0;const o=n(348),l=n(8156),u=i(n(1608)),s=n(6784),d=n(7217),c=u.default.div`
|
|
2650
2684
|
display: flex;
|
|
2651
2685
|
|
|
@@ -2770,7 +2804,7 @@
|
|
|
2770
2804
|
|
|
2771
2805
|
&::after {
|
|
2772
2806
|
border-style: solid;
|
|
2773
|
-
content:
|
|
2807
|
+
content: "";
|
|
2774
2808
|
display: block;
|
|
2775
2809
|
height: 0;
|
|
2776
2810
|
margin: auto;
|
|
@@ -2781,7 +2815,7 @@
|
|
|
2781
2815
|
background-color: ${({theme:e})=>e.greys.white};
|
|
2782
2816
|
border: 1px solid ${({theme:e})=>e.greys["dark-grey"]};
|
|
2783
2817
|
border-radius: var(--border-radius);
|
|
2784
|
-
box-shadow: 0 10px 20px 0
|
|
2818
|
+
box-shadow: 0 10px 20px 0 rgb(0 0 0 / 19%);
|
|
2785
2819
|
box-sizing: border-box;
|
|
2786
2820
|
color: ${({theme:e})=>e.greys.black};
|
|
2787
2821
|
display: ${({visible:e})=>e?"flex":"none"};
|
|
@@ -2796,7 +2830,7 @@
|
|
|
2796
2830
|
transition: opacity 300ms;
|
|
2797
2831
|
z-index: 1000;
|
|
2798
2832
|
|
|
2799
|
-
&[data-popper-placement*=
|
|
2833
|
+
&[data-popper-placement*="bottom"] > ${p} {
|
|
2800
2834
|
height: 1rem;
|
|
2801
2835
|
left: 0;
|
|
2802
2836
|
margin-top: -0.4rem;
|
|
@@ -2804,19 +2838,19 @@
|
|
|
2804
2838
|
width: 1rem;
|
|
2805
2839
|
}
|
|
2806
2840
|
|
|
2807
|
-
&[data-popper-placement*=
|
|
2841
|
+
&[data-popper-placement*="bottom"] > ${p}::before {
|
|
2808
2842
|
border-color: transparent transparent ${({theme:e})=>e.greys["dark-grey"]} transparent;
|
|
2809
|
-
border-width: 0 0.5rem 0.4rem
|
|
2843
|
+
border-width: 0 0.5rem 0.4rem;
|
|
2810
2844
|
position: absolute;
|
|
2811
2845
|
top: -1px;
|
|
2812
2846
|
}
|
|
2813
2847
|
|
|
2814
|
-
&[data-popper-placement*=
|
|
2848
|
+
&[data-popper-placement*="bottom"] > ${p}::after {
|
|
2815
2849
|
border-color: transparent transparent ${({theme:e})=>e.greys.white} transparent;
|
|
2816
|
-
border-width: 0 0.5rem 0.4rem
|
|
2850
|
+
border-width: 0 0.5rem 0.4rem;
|
|
2817
2851
|
}
|
|
2818
2852
|
|
|
2819
|
-
&[data-popper-placement*=
|
|
2853
|
+
&[data-popper-placement*="top"] > ${p} {
|
|
2820
2854
|
bottom: 0;
|
|
2821
2855
|
height: 1rem;
|
|
2822
2856
|
left: 0;
|
|
@@ -2824,50 +2858,50 @@
|
|
|
2824
2858
|
width: 1rem;
|
|
2825
2859
|
}
|
|
2826
2860
|
|
|
2827
|
-
&[data-popper-placement*=
|
|
2861
|
+
&[data-popper-placement*="top"] > ${p}::before {
|
|
2828
2862
|
border-color: ${({theme:e})=>e.greys["dark-grey"]} transparent transparent transparent;
|
|
2829
|
-
border-width: 0.4rem 0.5rem 0
|
|
2863
|
+
border-width: 0.4rem 0.5rem 0;
|
|
2830
2864
|
position: absolute;
|
|
2831
2865
|
top: 1px;
|
|
2832
2866
|
}
|
|
2833
2867
|
|
|
2834
|
-
&[data-popper-placement*=
|
|
2868
|
+
&[data-popper-placement*="top"] > ${p}::after {
|
|
2835
2869
|
border-color: ${({theme:e})=>e.greys.white} transparent transparent transparent;
|
|
2836
|
-
border-width: 0.4rem 0.5rem 0
|
|
2870
|
+
border-width: 0.4rem 0.5rem 0;
|
|
2837
2871
|
}
|
|
2838
2872
|
|
|
2839
|
-
&[data-popper-placement*=
|
|
2873
|
+
&[data-popper-placement*="right"] > ${p} {
|
|
2840
2874
|
height: 1rem;
|
|
2841
2875
|
left: 0;
|
|
2842
2876
|
margin-left: -0.7rem;
|
|
2843
2877
|
width: 1rem;
|
|
2844
2878
|
}
|
|
2845
2879
|
|
|
2846
|
-
&[data-popper-placement*=
|
|
2880
|
+
&[data-popper-placement*="right"] > ${p}::before {
|
|
2847
2881
|
border-color: transparent ${({theme:e})=>e.greys["dark-grey"]} transparent transparent;
|
|
2848
2882
|
border-width: 0.5rem 0.4rem 0.5rem 0;
|
|
2849
2883
|
}
|
|
2850
2884
|
|
|
2851
|
-
&[data-popper-placement*=
|
|
2885
|
+
&[data-popper-placement*="right"] > ${p}::after {
|
|
2852
2886
|
border-color: transparent ${({theme:e})=>e.greys.white} transparent transparent;
|
|
2853
2887
|
border-width: 0.5rem 0.4rem 0.5rem 0;
|
|
2854
2888
|
left: 6px;
|
|
2855
2889
|
top: 0;
|
|
2856
2890
|
}
|
|
2857
2891
|
|
|
2858
|
-
&[data-popper-placement*=
|
|
2892
|
+
&[data-popper-placement*="left"] > ${p} {
|
|
2859
2893
|
height: 1rem;
|
|
2860
2894
|
margin-right: -0.7rem;
|
|
2861
2895
|
right: 0;
|
|
2862
2896
|
width: 1rem;
|
|
2863
2897
|
}
|
|
2864
2898
|
|
|
2865
|
-
&[data-popper-placement*=
|
|
2899
|
+
&[data-popper-placement*="left"] > ${p}::before {
|
|
2866
2900
|
border-color: transparent transparent transparent ${({theme:e})=>e.greys["dark-grey"]};
|
|
2867
2901
|
border-width: 0.5rem 0 0.5rem 0.4em;
|
|
2868
2902
|
}
|
|
2869
2903
|
|
|
2870
|
-
&[data-popper-placement*=
|
|
2904
|
+
&[data-popper-placement*="left"] > ${p}::after {
|
|
2871
2905
|
border-color: transparent transparent transparent ${({theme:e})=>e.greys.white};
|
|
2872
2906
|
border-width: 0.5rem 0 0.5rem 0.4em;
|
|
2873
2907
|
left: 3px;
|
|
@@ -2888,7 +2922,7 @@
|
|
|
2888
2922
|
}
|
|
2889
2923
|
`,h=(0,u.default)(d.Avatar)`
|
|
2890
2924
|
margin-right: ${({isMobile:e})=>e?0:"var(--spacing-1x)"};
|
|
2891
|
-
`;function g(e){return e.find((e=>!e.disabled))}t.getFirstFocusableItem=g;const v=({ariaLabel:e,buttonAriaLabel:t,className:n,defaultOpen:a=!1,id:r,tag:i,onMenuVisibilityChanged:u,options:d,userEmail:m,username:v})=>{const{t:y}=(0,s.useTranslation)("user-profile"),{isMobile:b}=(0,c.useDeviceContext)(),w=g(d),M=(0,l.useRef)(null);return(0,o.jsx)(f,Object.assign({ariaLabel:e||y("ariaLabel"),buttonAriaLabel:t,className:n,"data-testid":"user-profile",defaultOpen:a,hasCaret:!b,id:r,icon:(0,o.jsx)(h,{isMobile:b,username:v}),tag:i,isMobile:b},b?{}:{label:v},{onMenuVisibilityChanged:u,firstItemRef:M,render:e=>(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(p.GroupItem,Object.assign({id:"user-label"},{children:(0,o.jsx)(p.LabelItem,{label:v,description:m})})),(0,o.jsx)(p.GroupItem,Object.assign({id:"user-actions"},{children:d.map((t=>(0,o.jsx)(p.NavItem,{"data-testid":`action-${t.value}`,ref:w===t?M:void 0,value:t.value,href:t.href,label:t.label,isHtmlLink:t.isHtmlLink,disabled:t.disabled,onClick:t.disabled?void 0:n=>{var a;null===(a=t.onClick)||void 0===a||a.call(t,n),e()}},t.value)))}))]})}))};t.UserProfile=v;try{g.displayName="getFirstFocusableItem",g.__docgenInfo={description:"",displayName:"getFirstFocusableItem",props:{length:{defaultValue:null,description:"Gets or sets the length of the array. This is a number one higher than the highest index in the array.",name:"length",required:!0,type:{name:"number"}},toString:{defaultValue:null,description:"Returns a string representation of an array.",name:"toString",required:!1,type:{name:"() => string"}},toLocaleString:{defaultValue:null,description:"Returns a string representation of an array. The elements are converted to string using their toLocaleString methods.",name:"toLocaleString",required:!1,type:{name:"() => string"}},pop:{defaultValue:null,description:"Removes the last element from an array and returns it.\nIf the array is empty, undefined is returned and the array is not modified.",name:"pop",required:!0,type:{name:"() => NavItemProps | undefined"}},push:{defaultValue:null,description:"Appends new elements to the end of an array, and returns the new length of the array.\n@param items New elements to add to the array.",name:"push",required:!0,type:{name:"(...items: NavItemProps[]) => number"}},concat:{defaultValue:null,description:"Combines two or more arrays.\nThis method returns a new array without modifying any existing arrays.\n@param items Additional arrays and/or items to add to the end of the array.\n@param items Additional arrays and/or items to add to the end of the array.",name:"concat",required:!0,type:{name:"{ (...items: ConcatArray<NavItemProps>[]): NavItemProps[]; (...items: (NavItemProps | ConcatArray<NavItemProps>)[]): NavItemProps[]; }"}},join:{defaultValue:null,description:"Adds all the elements of an array into a string, separated by the specified separator string.\n@param separator A string used to separate one element of the array from the next in the resulting string. If omitted, the array elements are separated with a comma.",name:"join",required:!0,type:{name:"(separator?: string | undefined) => string"}},reverse:{defaultValue:null,description:"Reverses the elements in an array in place.\nThis method mutates the array and returns a reference to the same array.",name:"reverse",required:!0,type:{name:"() => NavItemProps[]"}},shift:{defaultValue:null,description:"Removes the first element from an array and returns it.\nIf the array is empty, undefined is returned and the array is not modified.",name:"shift",required:!0,type:{name:"() => NavItemProps | undefined"}},slice:{defaultValue:null,description:"Returns a copy of a section of an array.\nFor both start and end, a negative index can be used to indicate an offset from the end of the array.\nFor example, -2 refers to the second to last element of the array.\n@param start The beginning index of the specified portion of the array.\nIf start is undefined, then the slice begins at index 0.\n@param end The end index of the specified portion of the array. This is exclusive of the element at the index 'end'.\nIf end is undefined, then the slice extends to the end of the array.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => NavItemProps[]"}},sort:{defaultValue:null,description:"Sorts an array in place.\nThis method mutates the array and returns a reference to the same array.\n@param compareFn Function used to determine the order of the elements. It is expected to return\na negative value if the first argument is less than the second argument, zero if they're equal, and a positive\nvalue otherwise. If omitted, the elements are sorted in ascending, ASCII character order.\n```ts\n[11,2,22,1].sort((a, b) => a - b)\n```",name:"sort",required:!0,type:{name:"(compareFn?: ((a: NavItemProps, b: NavItemProps) => number) | undefined) => NavItemProps[]"}},splice:{defaultValue:null,description:"Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n@param start The zero-based location in the array from which to start removing elements.\n@param deleteCount The number of elements to remove.\n@returns An array containing the elements that were deleted.\n@param start The zero-based location in the array from which to start removing elements.\n@param deleteCount The number of elements to remove.\n@param items Elements to insert into the array in place of the deleted elements.\n@returns An array containing the elements that were deleted.",name:"splice",required:!0,type:{name:"{ (start: number, deleteCount?: number | undefined): NavItemProps[]; (start: number, deleteCount: number, ...items: NavItemProps[]): NavItemProps[]; }"}},unshift:{defaultValue:null,description:"Inserts new elements at the start of an array, and returns the new length of the array.\n@param items Elements to insert at the start of the array.",name:"unshift",required:!0,type:{name:"(...items: NavItemProps[]) => number"}},indexOf:{defaultValue:null,description:"Returns the index of the first occurrence of a value in an array, or -1 if it is not present.\n@param searchElement The value to locate in the array.\n@param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.",name:"indexOf",required:!0,type:{name:"(searchElement: NavItemProps, fromIndex?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the index of the last occurrence of a specified value in an array, or -1 if it is not present.\n@param searchElement The value to locate in the array.\n@param fromIndex The array index at which to begin searching backward. If fromIndex is omitted, the search starts at the last index in the array.",name:"lastIndexOf",required:!0,type:{name:"(searchElement: NavItemProps, fromIndex?: number | undefined) => number"}},every:{defaultValue:null,description:"Determines whether all the members of an array satisfy the specified test.\n@param predicate A function that accepts up to three arguments. The every method calls\nthe predicate function for each element in the array until the predicate returns a value\nwhich is coercible to the Boolean value false, or until the end of the array.\n@param thisArg An object to which the this keyword can refer in the predicate function.\nIf thisArg is omitted, undefined is used as the this value.\n@param predicate A function that accepts up to three arguments. The every method calls\nthe predicate function for each element in the array until the predicate returns a value\nwhich is coercible to the Boolean value false, or until the end of the array.\n@param thisArg An object to which the this keyword can refer in the predicate function.\nIf thisArg is omitted, undefined is used as the this value.",name:"every",required:!0,type:{name:"{ <S extends NavItemProps>(predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => value is S, thisArg?: any): this is S[]; (predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => unknown, thisArg?: any): boolean; }"}},some:{defaultValue:null,description:"Determines whether the specified callback function returns true for any element of an array.\n@param predicate A function that accepts up to three arguments. The some method calls\nthe predicate function for each element in the array until the predicate returns a value\nwhich is coercible to the Boolean value true, or until the end of the array.\n@param thisArg An object to which the this keyword can refer in the predicate function.\nIf thisArg is omitted, undefined is used as the this value.",name:"some",required:!0,type:{name:"(predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => unknown, thisArg?: any) => boolean"}},forEach:{defaultValue:null,description:"Performs the specified action for each element in an array.\n@param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.",name:"forEach",required:!0,type:{name:"(callbackfn: (value: NavItemProps, index: number, array: NavItemProps[]) => void, thisArg?: any) => void"}},map:{defaultValue:null,description:"Calls a defined callback function on each element of an array, and returns an array that contains the results.\n@param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.",name:"map",required:!0,type:{name:"<U>(callbackfn: (value: NavItemProps, index: number, array: NavItemProps[]) => U, thisArg?: any) => U[]"}},filter:{defaultValue:null,description:"Returns the elements of an array that meet the condition specified in a callback function.\n@param predicate A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.\n@param predicate A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.",name:"filter",required:!0,type:{name:"{ <S extends NavItemProps>(predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => value is S, thisArg?: any): S[]; (predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => unknown, thisArg?: any): NavItemProps[]; }"}},reduce:{defaultValue:null,description:"Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n@param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n@param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.",name:"reduce",required:!0,type:{name:"{ (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps): NavItemProps; (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps, initialValue: NavItemProps): NavIt..."}},reduceRight:{defaultValue:null,description:"Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n@param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n@param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.",name:"reduceRight",required:!0,type:{name:"{ (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps): NavItemProps; (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps, initialValue: NavItemProps): NavIt..."}},find:{defaultValue:null,description:"Returns the value of the first element in the array where predicate is true, and undefined\notherwise.\n@param predicate find calls predicate once for each element of the array, in ascending\norder, until it finds one where predicate returns true. If such an element is found, find\nimmediately returns that element value. Otherwise, find returns undefined.\n@param thisArg If provided, it will be used as the this value for each invocation of\npredicate. If it is not provided, undefined is used instead.",name:"find",required:!0,type:{name:"{ <S extends NavItemProps>(predicate: (this: void, value: NavItemProps, index: number, obj: NavItemProps[]) => value is S, thisArg?: any): S | undefined; (predicate: (value: NavItemProps, index: number, obj: NavItemProps[]) => unknown, thisArg?: any): NavItemProps | undefined; }"}},findIndex:{defaultValue:null,description:"Returns the index of the first element in the array where predicate is true, and -1\notherwise.\n@param predicate find calls predicate once for each element of the array, in ascending\norder, until it finds one where predicate returns true. If such an element is found,\nfindIndex immediately returns that element index. Otherwise, findIndex returns -1.\n@param thisArg If provided, it will be used as the this value for each invocation of\npredicate. If it is not provided, undefined is used instead.",name:"findIndex",required:!0,type:{name:"(predicate: (value: NavItemProps, index: number, obj: NavItemProps[]) => unknown, thisArg?: any) => number"}},fill:{defaultValue:null,description:"Changes all array elements from `start` to `end` index to a static `value` and returns the modified array\n@param value value to fill array section with\n@param start index to start filling the array at. If start is negative, it is treated as\nlength+start where length is the length of the array.\n@param end index to stop filling the array at. If end is negative, it is treated as\nlength+end.",name:"fill",required:!0,type:{name:"(value: NavItemProps, start?: number | undefined, end?: number | undefined) => NavItemProps[]"}},copyWithin:{defaultValue:null,description:"Returns the this object after copying a section of the array identified by start and end\nto the same array starting at position target\n@param target If target is negative, it is treated as length+target where length is the\nlength of the array.\n@param start If start is negative, it is treated as length+start. If end is negative, it\nis treated as length+end.\n@param end If not specified, length of the this object is used as its default value.",name:"copyWithin",required:!0,type:{name:"(target: number, start: number, end?: number | undefined) => NavItemProps[]"}},entries:{defaultValue:null,description:"Returns an iterable of key, value pairs for every entry in the array",name:"entries",required:!0,type:{name:"() => IterableIterator<[number, NavItemProps]>"}},keys:{defaultValue:null,description:"Returns an iterable of keys in the array",name:"keys",required:!0,type:{name:"() => IterableIterator<number>"}},values:{defaultValue:null,description:"Returns an iterable of values in the array",name:"values",required:!0,type:{name:"() => IterableIterator<NavItemProps>"}},includes:{defaultValue:null,description:"Determines whether an array includes a certain element, returning true or false as appropriate.\n@param searchElement The element to search for.\n@param fromIndex The position in this array at which to begin searching for searchElement.",name:"includes",required:!0,type:{name:"(searchElement: NavItemProps, fromIndex?: number | undefined) => boolean"}},flatMap:{defaultValue:null,description:"Calls a defined callback function on each element of an array. Then, flattens the result into\na new array.\nThis is identical to a map followed by flat with depth 1.\n@param callback A function that accepts up to three arguments. The flatMap method calls the\ncallback function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the callback function. If\nthisArg is omitted, undefined is used as the this value.",name:"flatMap",required:!0,type:{name:"<U, This = undefined>(callback: (this: This, value: NavItemProps, index: number, array: NavItemProps[]) => U | readonly U[], thisArg?: This | undefined) => U[]"}},flat:{defaultValue:null,description:"Returns a new array with all sub-array elements concatenated into it recursively up to the\nspecified depth.\n@param depth The maximum recursion depth",name:"flat",required:!0,type:{name:"<A, D extends number = 1>(this: A, depth?: D | undefined) => FlatArray<A, D>[]"}},"__@iterator@58434":{defaultValue:null,description:"Iterator",name:"__@iterator@58434",required:!0,type:{name:"() => IterableIterator<NavItemProps>"}},"__@unscopables@59980":{defaultValue:null,description:"Returns an object whose properties have the value 'true'\nwhen they will be absent when used in a 'with' statement.",name:"__@unscopables@59980",required:!0,type:{name:"() => { copyWithin: boolean; entries: boolean; fill: boolean; find: boolean; findIndex: boolean; keys: boolean; values: boolean; }"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => NavItemProps | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/user-profile/user-profile.tsx#getFirstFocusableItem"]={docgenInfo:g.__docgenInfo,name:"getFirstFocusableItem",path:"src/components/user-profile/user-profile.tsx#getFirstFocusableItem"})}catch(e){}try{v.displayName="UserProfile",v.__docgenInfo={description:"",displayName:"UserProfile",props:{ariaLabel:{defaultValue:{value:"'User menu'"},description:"Sets nav's description",name:"ariaLabel",required:!1,type:{name:"string"}},buttonAriaLabel:{defaultValue:null,description:"",name:"buttonAriaLabel",required:!1,type:{name:"string"}},className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},defaultOpen:{defaultValue:{value:!1},description:"Sets menu open by default",name:"defaultOpen",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},tag:{defaultValue:null,description:"Set wrapper element tag",name:"tag",required:!1,type:{name:"enum",value:[{value:'"div"'},{value:'"nav"'}]}},options:{defaultValue:null,description:"",name:"options",required:!0,type:{name:"NavItemProps[]"}},username:{defaultValue:null,description:"",name:"username",required:!0,type:{name:"string"}},userEmail:{defaultValue:null,description:"",name:"userEmail",required:!1,type:{name:"string"}},onMenuVisibilityChanged:{defaultValue:null,description:"",name:"onMenuVisibilityChanged",required:!1,type:{name:"((isOpen: boolean) => void)"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/user-profile/user-profile.tsx#UserProfile"]={docgenInfo:v.__docgenInfo,name:"UserProfile",path:"src/components/user-profile/user-profile.tsx#UserProfile"})}catch(e){}},9497:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hiddenStyle=void 0,t.hiddenStyle="\n border: 0 !important;\n clip: rect(1px, 1px, 1px, 1px);\n height: 1px !important;\n overflow: hidden;\n padding:0 !important;\n position: absolute !important;\n width: 1px !important;\n"},4710:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.VisuallyHidden=void 0;const r=n(348),i=a(n(1608)),o=n(9497),l=i.default.span`
|
|
2925
|
+
`;function g(e){return e.find((e=>!e.disabled))}t.getFirstFocusableItem=g;const v=({ariaLabel:e,buttonAriaLabel:t,className:n,defaultOpen:a=!1,id:r,tag:i,onMenuVisibilityChanged:u,options:d,userEmail:m,username:v})=>{const{t:y}=(0,s.useTranslation)("user-profile"),{isMobile:b}=(0,c.useDeviceContext)(),w=g(d),M=(0,l.useRef)(null);return(0,o.jsx)(f,Object.assign({ariaLabel:e||y("ariaLabel"),buttonAriaLabel:t,className:n,"data-testid":"user-profile",defaultOpen:a,hasCaret:!b,id:r,icon:(0,o.jsx)(h,{isMobile:b,username:v}),tag:i,isMobile:b},b?{}:{label:v},{onMenuVisibilityChanged:u,firstItemRef:M,render:e=>(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(p.GroupItem,Object.assign({id:"user-label"},{children:(0,o.jsx)(p.LabelItem,{label:v,description:m})})),(0,o.jsx)(p.GroupItem,Object.assign({id:"user-actions"},{children:d.map((t=>(0,o.jsx)(p.NavItem,{"data-testid":`action-${t.value}`,ref:w===t?M:void 0,value:t.value,href:t.href,label:t.label,isHtmlLink:t.isHtmlLink,disabled:t.disabled,onClick:t.disabled?void 0:n=>{var a;null===(a=t.onClick)||void 0===a||a.call(t,n),e()}},t.value)))}))]})}))};t.UserProfile=v;try{g.displayName="getFirstFocusableItem",g.__docgenInfo={description:"",displayName:"getFirstFocusableItem",props:{length:{defaultValue:null,description:"Gets or sets the length of the array. This is a number one higher than the highest index in the array.",name:"length",required:!0,type:{name:"number"}},toString:{defaultValue:null,description:"Returns a string representation of an array.",name:"toString",required:!1,type:{name:"() => string"}},toLocaleString:{defaultValue:null,description:"Returns a string representation of an array. The elements are converted to string using their toLocaleString methods.",name:"toLocaleString",required:!1,type:{name:"() => string"}},pop:{defaultValue:null,description:"Removes the last element from an array and returns it.\nIf the array is empty, undefined is returned and the array is not modified.",name:"pop",required:!0,type:{name:"() => NavItemProps | undefined"}},push:{defaultValue:null,description:"Appends new elements to the end of an array, and returns the new length of the array.\n@param items New elements to add to the array.",name:"push",required:!0,type:{name:"(...items: NavItemProps[]) => number"}},concat:{defaultValue:null,description:"Combines two or more arrays.\nThis method returns a new array without modifying any existing arrays.\n@param items Additional arrays and/or items to add to the end of the array.\n@param items Additional arrays and/or items to add to the end of the array.",name:"concat",required:!0,type:{name:"{ (...items: ConcatArray<NavItemProps>[]): NavItemProps[]; (...items: (NavItemProps | ConcatArray<NavItemProps>)[]): NavItemProps[]; }"}},join:{defaultValue:null,description:"Adds all the elements of an array into a string, separated by the specified separator string.\n@param separator A string used to separate one element of the array from the next in the resulting string. If omitted, the array elements are separated with a comma.",name:"join",required:!0,type:{name:"(separator?: string | undefined) => string"}},reverse:{defaultValue:null,description:"Reverses the elements in an array in place.\nThis method mutates the array and returns a reference to the same array.",name:"reverse",required:!0,type:{name:"() => NavItemProps[]"}},shift:{defaultValue:null,description:"Removes the first element from an array and returns it.\nIf the array is empty, undefined is returned and the array is not modified.",name:"shift",required:!0,type:{name:"() => NavItemProps | undefined"}},slice:{defaultValue:null,description:"Returns a copy of a section of an array.\nFor both start and end, a negative index can be used to indicate an offset from the end of the array.\nFor example, -2 refers to the second to last element of the array.\n@param start The beginning index of the specified portion of the array.\nIf start is undefined, then the slice begins at index 0.\n@param end The end index of the specified portion of the array. This is exclusive of the element at the index 'end'.\nIf end is undefined, then the slice extends to the end of the array.",name:"slice",required:!0,type:{name:"(start?: number | undefined, end?: number | undefined) => NavItemProps[]"}},sort:{defaultValue:null,description:"Sorts an array in place.\nThis method mutates the array and returns a reference to the same array.\n@param compareFn Function used to determine the order of the elements. It is expected to return\na negative value if the first argument is less than the second argument, zero if they're equal, and a positive\nvalue otherwise. If omitted, the elements are sorted in ascending, ASCII character order.\n```ts\n[11,2,22,1].sort((a, b) => a - b)\n```",name:"sort",required:!0,type:{name:"(compareFn?: ((a: NavItemProps, b: NavItemProps) => number) | undefined) => NavItemProps[]"}},splice:{defaultValue:null,description:"Removes elements from an array and, if necessary, inserts new elements in their place, returning the deleted elements.\n@param start The zero-based location in the array from which to start removing elements.\n@param deleteCount The number of elements to remove.\n@returns An array containing the elements that were deleted.\n@param start The zero-based location in the array from which to start removing elements.\n@param deleteCount The number of elements to remove.\n@param items Elements to insert into the array in place of the deleted elements.\n@returns An array containing the elements that were deleted.",name:"splice",required:!0,type:{name:"{ (start: number, deleteCount?: number | undefined): NavItemProps[]; (start: number, deleteCount: number, ...items: NavItemProps[]): NavItemProps[]; }"}},unshift:{defaultValue:null,description:"Inserts new elements at the start of an array, and returns the new length of the array.\n@param items Elements to insert at the start of the array.",name:"unshift",required:!0,type:{name:"(...items: NavItemProps[]) => number"}},indexOf:{defaultValue:null,description:"Returns the index of the first occurrence of a value in an array, or -1 if it is not present.\n@param searchElement The value to locate in the array.\n@param fromIndex The array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.",name:"indexOf",required:!0,type:{name:"(searchElement: NavItemProps, fromIndex?: number | undefined) => number"}},lastIndexOf:{defaultValue:null,description:"Returns the index of the last occurrence of a specified value in an array, or -1 if it is not present.\n@param searchElement The value to locate in the array.\n@param fromIndex The array index at which to begin searching backward. If fromIndex is omitted, the search starts at the last index in the array.",name:"lastIndexOf",required:!0,type:{name:"(searchElement: NavItemProps, fromIndex?: number | undefined) => number"}},every:{defaultValue:null,description:"Determines whether all the members of an array satisfy the specified test.\n@param predicate A function that accepts up to three arguments. The every method calls\nthe predicate function for each element in the array until the predicate returns a value\nwhich is coercible to the Boolean value false, or until the end of the array.\n@param thisArg An object to which the this keyword can refer in the predicate function.\nIf thisArg is omitted, undefined is used as the this value.\n@param predicate A function that accepts up to three arguments. The every method calls\nthe predicate function for each element in the array until the predicate returns a value\nwhich is coercible to the Boolean value false, or until the end of the array.\n@param thisArg An object to which the this keyword can refer in the predicate function.\nIf thisArg is omitted, undefined is used as the this value.",name:"every",required:!0,type:{name:"{ <S extends NavItemProps>(predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => value is S, thisArg?: any): this is S[]; (predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => unknown, thisArg?: any): boolean; }"}},some:{defaultValue:null,description:"Determines whether the specified callback function returns true for any element of an array.\n@param predicate A function that accepts up to three arguments. The some method calls\nthe predicate function for each element in the array until the predicate returns a value\nwhich is coercible to the Boolean value true, or until the end of the array.\n@param thisArg An object to which the this keyword can refer in the predicate function.\nIf thisArg is omitted, undefined is used as the this value.",name:"some",required:!0,type:{name:"(predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => unknown, thisArg?: any) => boolean"}},forEach:{defaultValue:null,description:"Performs the specified action for each element in an array.\n@param callbackfn A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.",name:"forEach",required:!0,type:{name:"(callbackfn: (value: NavItemProps, index: number, array: NavItemProps[]) => void, thisArg?: any) => void"}},map:{defaultValue:null,description:"Calls a defined callback function on each element of an array, and returns an array that contains the results.\n@param callbackfn A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.",name:"map",required:!0,type:{name:"<U>(callbackfn: (value: NavItemProps, index: number, array: NavItemProps[]) => U, thisArg?: any) => U[]"}},filter:{defaultValue:null,description:"Returns the elements of an array that meet the condition specified in a callback function.\n@param predicate A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.\n@param predicate A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.",name:"filter",required:!0,type:{name:"{ <S extends NavItemProps>(predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => value is S, thisArg?: any): S[]; (predicate: (value: NavItemProps, index: number, array: NavItemProps[]) => unknown, thisArg?: any): NavItemProps[]; }"}},reduce:{defaultValue:null,description:"Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n@param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n@param callbackfn A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.",name:"reduce",required:!0,type:{name:"{ (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps): NavItemProps; (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps, initialValue: NavItemProps): NavIt..."}},reduceRight:{defaultValue:null,description:"Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.\n@param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.\n@param callbackfn A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.\n@param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.",name:"reduceRight",required:!0,type:{name:"{ (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps): NavItemProps; (callbackfn: (previousValue: NavItemProps, currentValue: NavItemProps, currentIndex: number, array: NavItemProps[]) => NavItemProps, initialValue: NavItemProps): NavIt..."}},find:{defaultValue:null,description:"Returns the value of the first element in the array where predicate is true, and undefined\notherwise.\n@param predicate find calls predicate once for each element of the array, in ascending\norder, until it finds one where predicate returns true. If such an element is found, find\nimmediately returns that element value. Otherwise, find returns undefined.\n@param thisArg If provided, it will be used as the this value for each invocation of\npredicate. If it is not provided, undefined is used instead.",name:"find",required:!0,type:{name:"{ <S extends NavItemProps>(predicate: (this: void, value: NavItemProps, index: number, obj: NavItemProps[]) => value is S, thisArg?: any): S | undefined; (predicate: (value: NavItemProps, index: number, obj: NavItemProps[]) => unknown, thisArg?: any): NavItemProps | undefined; }"}},findIndex:{defaultValue:null,description:"Returns the index of the first element in the array where predicate is true, and -1\notherwise.\n@param predicate find calls predicate once for each element of the array, in ascending\norder, until it finds one where predicate returns true. If such an element is found,\nfindIndex immediately returns that element index. Otherwise, findIndex returns -1.\n@param thisArg If provided, it will be used as the this value for each invocation of\npredicate. If it is not provided, undefined is used instead.",name:"findIndex",required:!0,type:{name:"(predicate: (value: NavItemProps, index: number, obj: NavItemProps[]) => unknown, thisArg?: any) => number"}},fill:{defaultValue:null,description:"Changes all array elements from `start` to `end` index to a static `value` and returns the modified array\n@param value value to fill array section with\n@param start index to start filling the array at. If start is negative, it is treated as\nlength+start where length is the length of the array.\n@param end index to stop filling the array at. If end is negative, it is treated as\nlength+end.",name:"fill",required:!0,type:{name:"(value: NavItemProps, start?: number | undefined, end?: number | undefined) => NavItemProps[]"}},copyWithin:{defaultValue:null,description:"Returns the this object after copying a section of the array identified by start and end\nto the same array starting at position target\n@param target If target is negative, it is treated as length+target where length is the\nlength of the array.\n@param start If start is negative, it is treated as length+start. If end is negative, it\nis treated as length+end.\n@param end If not specified, length of the this object is used as its default value.",name:"copyWithin",required:!0,type:{name:"(target: number, start: number, end?: number | undefined) => NavItemProps[]"}},entries:{defaultValue:null,description:"Returns an iterable of key, value pairs for every entry in the array",name:"entries",required:!0,type:{name:"() => IterableIterator<[number, NavItemProps]>"}},keys:{defaultValue:null,description:"Returns an iterable of keys in the array",name:"keys",required:!0,type:{name:"() => IterableIterator<number>"}},values:{defaultValue:null,description:"Returns an iterable of values in the array",name:"values",required:!0,type:{name:"() => IterableIterator<NavItemProps>"}},includes:{defaultValue:null,description:"Determines whether an array includes a certain element, returning true or false as appropriate.\n@param searchElement The element to search for.\n@param fromIndex The position in this array at which to begin searching for searchElement.",name:"includes",required:!0,type:{name:"(searchElement: NavItemProps, fromIndex?: number | undefined) => boolean"}},flatMap:{defaultValue:null,description:"Calls a defined callback function on each element of an array. Then, flattens the result into\na new array.\nThis is identical to a map followed by flat with depth 1.\n@param callback A function that accepts up to three arguments. The flatMap method calls the\ncallback function one time for each element in the array.\n@param thisArg An object to which the this keyword can refer in the callback function. If\nthisArg is omitted, undefined is used as the this value.",name:"flatMap",required:!0,type:{name:"<U, This = undefined>(callback: (this: This, value: NavItemProps, index: number, array: NavItemProps[]) => U | readonly U[], thisArg?: This | undefined) => U[]"}},flat:{defaultValue:null,description:"Returns a new array with all sub-array elements concatenated into it recursively up to the\nspecified depth.\n@param depth The maximum recursion depth",name:"flat",required:!0,type:{name:"<A, D extends number = 1>(this: A, depth?: D | undefined) => FlatArray<A, D>[]"}},"__@iterator@58433":{defaultValue:null,description:"Iterator",name:"__@iterator@58433",required:!0,type:{name:"() => IterableIterator<NavItemProps>"}},"__@unscopables@59979":{defaultValue:null,description:"Returns an object whose properties have the value 'true'\nwhen they will be absent when used in a 'with' statement.",name:"__@unscopables@59979",required:!0,type:{name:"() => { copyWithin: boolean; entries: boolean; fill: boolean; find: boolean; findIndex: boolean; keys: boolean; values: boolean; }"}},at:{defaultValue:null,description:"Takes an integer value and returns the item at that index,\nallowing for positive and negative integers.\nNegative integers count back from the last item in the array.",name:"at",required:!0,type:{name:"(index: number) => NavItemProps | undefined"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/user-profile/user-profile.tsx#getFirstFocusableItem"]={docgenInfo:g.__docgenInfo,name:"getFirstFocusableItem",path:"src/components/user-profile/user-profile.tsx#getFirstFocusableItem"})}catch(e){}try{v.displayName="UserProfile",v.__docgenInfo={description:"",displayName:"UserProfile",props:{ariaLabel:{defaultValue:{value:"'User menu'"},description:"Sets nav's description",name:"ariaLabel",required:!1,type:{name:"string"}},buttonAriaLabel:{defaultValue:null,description:"",name:"buttonAriaLabel",required:!1,type:{name:"string"}},className:{defaultValue:null,description:"",name:"className",required:!1,type:{name:"string"}},defaultOpen:{defaultValue:{value:!1},description:"Sets menu open by default",name:"defaultOpen",required:!1,type:{name:"boolean"}},id:{defaultValue:null,description:"",name:"id",required:!1,type:{name:"string"}},tag:{defaultValue:null,description:"Set wrapper element tag",name:"tag",required:!1,type:{name:"enum",value:[{value:'"div"'},{value:'"nav"'}]}},options:{defaultValue:null,description:"",name:"options",required:!0,type:{name:"NavItemProps[]"}},username:{defaultValue:null,description:"",name:"username",required:!0,type:{name:"string"}},userEmail:{defaultValue:null,description:"",name:"userEmail",required:!1,type:{name:"string"}},onMenuVisibilityChanged:{defaultValue:null,description:"",name:"onMenuVisibilityChanged",required:!1,type:{name:"((isOpen: boolean) => void)"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/user-profile/user-profile.tsx#UserProfile"]={docgenInfo:v.__docgenInfo,name:"UserProfile",path:"src/components/user-profile/user-profile.tsx#UserProfile"})}catch(e){}},9497:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hiddenStyle=void 0,t.hiddenStyle="\n border: 0 !important;\n clip: rect(1px, 1px, 1px, 1px);\n height: 1px !important;\n overflow: hidden;\n padding:0 !important;\n position: absolute !important;\n width: 1px !important;\n"},4710:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.VisuallyHidden=void 0;const r=n(348),i=a(n(1608)),o=n(9497),l=i.default.span`
|
|
2892
2926
|
${o.hiddenStyle}
|
|
2893
2927
|
`,u=({children:e})=>(0,r.jsx)(l,Object.assign({"aria-hidden":"false"},{children:e}));t.VisuallyHidden=u;try{u.displayName="VisuallyHidden",u.__docgenInfo={description:"",displayName:"VisuallyHidden",props:{}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/components/visually-hidden/visuallyhidden.tsx#VisuallyHidden"]={docgenInfo:u.__docgenInfo,name:"VisuallyHidden",path:"src/components/visually-hidden/visuallyhidden.tsx#VisuallyHidden"})}catch(e){}},3726:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useDataAttributes=void 0;const a=n(8156);function r(e){return null!==e&&"object"==typeof e}function i(e){return r(e)?Object.keys(e).reduce(((t,n)=>(function(e){return null!==e.match(/data-/i)}(n)&&(t[n]=e[n]),t)),{}):{}}t.useDataAttributes=function(e){const[t,n]=(0,a.useState)((()=>i(e))),o=r(e)?[...Object.values(e)]:[e];return(0,a.useEffect)((()=>{n(i(e))}),o),t}},5844:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useId=t.resetId=void 0;const a=n(8156);let r=1;t.resetId=function(){r=1},t.useId=function(e){const t=(0,a.useRef)(e);return function(e){const t=(0,a.useRef)();return(0,a.useEffect)((()=>{t.current=e})),t.current}(e)!==e&&(t.current=`${e}${r++}`),t.current}},5621:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useTheme=void 0;const a=n(8156),r=n(1608);t.useTheme=function(){return(0,a.useContext)(r.ThemeContext)}},701:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useToast=void 0;const a=n(8156),r=n(7526);t.useToast=function(){const{addToast:e,removeToast:t}=(0,r.useToasts)();return{showToast:(0,a.useCallback)(((t,n)=>e(t,n,!0)),[e]),hideToast:t}}},7526:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useToasts=void 0;const a=n(8156),r=n(7793);t.useToasts=function(){return(0,a.useContext)(r.ToastContext)}},8356:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.createI18n=void 0;const r=a(n(8661)),i=n(7735);t.createI18n=function(){const e=r.default.createInstance();return e.init({resources:i.Translations,lng:"en",fallbackLng:"en",interpolation:{escapeValue:!1}}).catch(console.error),e}},7735:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Translations=void 0,t.Translations={en:{avatar:{ariaLabel:"{{username}} avatar"},bento:{productsLabel:"Products",externalsLabel:"Resources"},common:{opensInNewTab:"opens in a new tab",opensInNewTabScreenReader:"(opens in a new tab)",error:"Error"},datepicker:{calendarButtonLabel:"Choose date",calendarButtonSelectedLabel:"Choose date. The selected date is",calendarContainerLabel:"Choose date",todayButtonAriaLabel:"Choose today's date",todayButtonLabel:"Today",validationErrorMessage:"Invalid date",monthPreviousButtonLabel:"Go to previous month",monthNextButtonLabel:"Go to next month",monthSelectLabel:"Select a month",yearSelectLabel:"Select a year"},"global-banner":{ignore:"Ignore"},modal:{closeButtonLabel:"Close dialog"},"modal-dialog":{cancelButtonLabel:"Cancel",confirmButtonLabel:"Confirm"},"money-input":{validationErrorMessage:"Invalid number"},"nav-menu-button":{ariaLabel:"Menu"},pagination:{results:"results"},"password-creation-input":{"password-strength":"Password strength: ","min-8-characters":"Minimum 8 characters","min-1-lower-case":"At least one lower case","min-1-upper-case":"At least one upper case","create-password":"Create password",weak:"Weak",fair:"Fair",good:"Good",strong:"Strong","show-password":"Show password in plain text.","hide-password":"Hide password."},"search-input":{label:"Search"},"sectional-banner":{Alert:"Alert",Warning:"Warning",Success:"Success",Info:"Information",dismissLabel:"Dismiss banner"},select:{inputAriaLabel:"Select an option",validationErrorMessage:"You must select an option"},"skip-link":{label:"Skip to main content"},"stepper-input":{validationErrorMessage:"Invalid number"},"stepper-buttons":{"increment-button-aria-label":"Increase number","decrement-button-aria-label":"Decrease number"},"tag-medium":{deleteButtonAriaLabel:"Remove tag {{label}}"},"text-area":{validationErrorMessage:"This text area is invalid",maxLengthValidationErrorMessage:"The number of characters exceeds the maximum allowed. You must shorten the description.",characters:"{{current}}/{{max}} characters"},"text-input":{validationErrorMessage:"This input is invalid"},toast:{dismissButtonLabel:"Dismiss notification"},"user-profile":{ariaLabel:"User menu"}},fr:{avatar:{ariaLabel:"Avatar de {{username}}"},bento:{productsLabel:"Produits",externalsLabel:"Ressources"},common:{opensInNewTab:"ouvre dans un nouvel onglet",opensInNewTabScreenReader:"(ouvre dans un nouvel onglet)",error:"Erreur"},datepicker:{calendarButtonLabel:"Choisissez une date",calendarButtonSelectedLabel:"Choisissez une date. La date sélectionnée est",calendarContainerLabel:"Choisissez une date",todayButtonAriaLabel:"Choisir la date d'aujourd'hui",todayButtonLabel:"Aujourd'hui",validationErrorMessage:"Date non valide",monthPreviousButtonLabel:"Aller au mois précédent",monthNextButtonLabel:"Aller au mois suivant",monthSelectLabel:"Choisissez un mois",yearSelectLabel:"Choisissez une année"},"global-banner":{ignore:"Ignorer"},modal:{closeButtonLabel:"Fermer le dialogue"},"modal-dialog":{cancelButtonLabel:"Annuler",confirmButtonLabel:"Confirmer"},"money-input":{validationErrorMessage:"Ce nombre n'est pas valide"},"nav-menu-button":{ariaLabel:"Menu"},pagination:{results:"résultats"},"password-creation-input":{"password-strength":"Force du mot de passe : ","min-8-characters":"Minimum 8 caractères","min-1-lower-case":"Au moins une minuscule","min-1-upper-case":"Au moins une majuscule","create-password":"Créer un mot de passe",weak:"Faible",fair:"Raisonnable",good:"Bon",strong:"Fort","show-password":"Montrer le mot de passe.","hide-password":"Cacher le mot de passe."},"search-input":{label:"Rechercher"},"sectional-banner":{Alert:"Alerte",Warning:"Attention",Success:"Succès",Info:"Information",dismissLabel:"Rejeter la bannière"},select:{inputAriaLabel:"Choisissez une option",validationErrorMessage:"Vous devez choisir une option"},"skip-link":{label:"Passer au contenu principal"},"stepper-input":{validationErrorMessage:"Ce nombre n'est pas valide"},"stepper-buttons":{"increment-button-aria-label":"Augmenter le nombre","decrement-button-aria-label":"Diminuer le nombre"},"tag-medium":{deleteButtonAriaLabel:"Retirer l'étiquette {{label}}"},"text-area":{validationErrorMessage:"Cette zone texte n'est pas valide",maxLengthValidationErrorMessage:"Le nombre de caractères dépasse le maximum autorisé. Vous devez raccourcir la description.",characters:"{{current}}/{{max}} caractères"},"text-input":{validationErrorMessage:"Ce champ est invalide"},toast:{dismissButtonLabel:"Rejeter la notification"},"user-profile":{ariaLabel:"Menu utilisateur"}}}},210:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useTranslation=void 0;const a=n(8156),r=n(7510);t.useTranslation=function(e){const{i18n:t}=(0,r.useIntlContext)(),n=(0,a.useCallback)((()=>{var n;return{t:t.getFixedT(null,e||(null===(n=t.options)||void 0===n?void 0:n.defaultNS)||[])}}),[t,e]),[i,o]=(0,a.useState)(n()),l=(0,a.useCallback)((()=>{o(n())}),[o,n]);return(0,a.useEffect)((()=>(t.on("languageChanged",l),()=>t.off("languageChanged",l))),[t,l]),{i18n:t,t:i.t}}},7619:function(e,t,n){"use strict";var a=this&&this.__createBinding||(Object.create?function(e,t,n,a){void 0===a&&(a=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,a,r)}:function(e,t,n,a){void 0===a&&(a=n),e[a]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||a(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.Status=t.Lozenge=t.Tag=t.ModalDialog=t.Modal=t.GlobalBanner=t.SideDrawer=t.SectionalBanner=t.Icon=t.DropdownMenuButton=t.GlobalHeader=t.Heading=t.ExternalLink=t.EnsoSpinner=t.ChooserCard=t.ChooserButtonGroup=t.CardLink=t.Card=t.Badge=t.Listbox=t.IntlProvider=t.useDeviceContext=t.DeviceContextProvider=t.ThemeWrapper=t.isLongEnough=t.hasAnUpperCaseLetter=t.hasALowerCaseLetter=t.PasswordCreationInput=t.ToggleSwitch=t.Tabs=t.Avatar=t.PhoneInput=t.TextInput=t.TextArea=t.StepperInput=t.Select=t.SearchGlobal=t.SearchContextual=t.RadioButtonGroup=t.OptionButton=t.MoneyInput=t.Datepicker=t.CheckboxGroup=t.Checkbox=t.ToggleButtonGroup=t.BentoMenuButton=t.NavMenuButton=t.MenuButton=t.IconButton=t.Button=void 0,t.useTheme=t.injectMainCss=t.testTheme=t.equisoftTheme=t.Pagination=t.ProgressCircle=t.ProgressBar=t.RouteLink=t.Breadcrumb=t.useToast=t.UserProfile=t.useModal=t.SkipLink=void 0;var i=n(1829);Object.defineProperty(t,"Button",{enumerable:!0,get:function(){return i.Button}});var o=n(3859);Object.defineProperty(t,"IconButton",{enumerable:!0,get:function(){return o.IconButton}});var l=n(4891);Object.defineProperty(t,"MenuButton",{enumerable:!0,get:function(){return l.MenuButton}});var u=n(9091);Object.defineProperty(t,"NavMenuButton",{enumerable:!0,get:function(){return u.NavMenuButton}});var s=n(7779);Object.defineProperty(t,"BentoMenuButton",{enumerable:!0,get:function(){return s.BentoMenuButton}});var d=n(668);Object.defineProperty(t,"ToggleButtonGroup",{enumerable:!0,get:function(){return d.ToggleButtonGroup}});var c=n(158);Object.defineProperty(t,"Checkbox",{enumerable:!0,get:function(){return c.Checkbox}});var m=n(4215);Object.defineProperty(t,"CheckboxGroup",{enumerable:!0,get:function(){return m.CheckboxGroup}});var p=n(7196);Object.defineProperty(t,"Datepicker",{enumerable:!0,get:function(){return p.Datepicker}});var f=n(4144);Object.defineProperty(t,"MoneyInput",{enumerable:!0,get:function(){return f.MoneyInput}});var h=n(7521);Object.defineProperty(t,"OptionButton",{enumerable:!0,get:function(){return h.OptionButton}});var g=n(2057);Object.defineProperty(t,"RadioButtonGroup",{enumerable:!0,get:function(){return g.RadioButtonGroup}});var v=n(4268);Object.defineProperty(t,"SearchContextual",{enumerable:!0,get:function(){return v.SearchContextual}});var y=n(1297);Object.defineProperty(t,"SearchGlobal",{enumerable:!0,get:function(){return y.SearchGlobal}});var b=n(1463);Object.defineProperty(t,"Select",{enumerable:!0,get:function(){return b.Select}});var w=n(4174);Object.defineProperty(t,"StepperInput",{enumerable:!0,get:function(){return w.StepperInput}});var M=n(2289);Object.defineProperty(t,"TextArea",{enumerable:!0,get:function(){return M.TextArea}});var E=n(7529);Object.defineProperty(t,"TextInput",{enumerable:!0,get:function(){return E.TextInput}});var k=n(1971);Object.defineProperty(t,"PhoneInput",{enumerable:!0,get:function(){return k.PhoneInput}});var C=n(8482);Object.defineProperty(t,"Avatar",{enumerable:!0,get:function(){return C.Avatar}});var x=n(2);Object.defineProperty(t,"Tabs",{enumerable:!0,get:function(){return x.Tabs}});var _=n(6845);Object.defineProperty(t,"ToggleSwitch",{enumerable:!0,get:function(){return _.ToggleSwitch}});var S=n(8352);Object.defineProperty(t,"PasswordCreationInput",{enumerable:!0,get:function(){return S.PasswordCreationInput}});var T=n(5509);Object.defineProperty(t,"hasALowerCaseLetter",{enumerable:!0,get:function(){return T.hasALowerCaseLetter}}),Object.defineProperty(t,"hasAnUpperCaseLetter",{enumerable:!0,get:function(){return T.hasAnUpperCaseLetter}}),Object.defineProperty(t,"isLongEnough",{enumerable:!0,get:function(){return T.hasMinLength}});var P=n(8230);Object.defineProperty(t,"ThemeWrapper",{enumerable:!0,get:function(){return P.ThemeWrapper}});var H=n(7217);Object.defineProperty(t,"DeviceContextProvider",{enumerable:!0,get:function(){return H.DeviceContextProvider}}),Object.defineProperty(t,"useDeviceContext",{enumerable:!0,get:function(){return H.useDeviceContext}});var O=n(7510);Object.defineProperty(t,"IntlProvider",{enumerable:!0,get:function(){return O.IntlProvider}});var V=n(3234);Object.defineProperty(t,"Listbox",{enumerable:!0,get:function(){return V.Listbox}});var q=n(1561);Object.defineProperty(t,"Badge",{enumerable:!0,get:function(){return q.Badge}});var j=n(4417);Object.defineProperty(t,"Card",{enumerable:!0,get:function(){return j.Card}});var L=n(9294);Object.defineProperty(t,"CardLink",{enumerable:!0,get:function(){return L.CardLink}}),r(n(1342),t);var A=n(1107);Object.defineProperty(t,"ChooserButtonGroup",{enumerable:!0,get:function(){return A.ChooserButtonGroup}});var D=n(5230);Object.defineProperty(t,"ChooserCard",{enumerable:!0,get:function(){return D.ChooserCard}});var R=n(1609);Object.defineProperty(t,"EnsoSpinner",{enumerable:!0,get:function(){return R.EnsoSpinner}});var I=n(5238);Object.defineProperty(t,"ExternalLink",{enumerable:!0,get:function(){return I.ExternalLink}});var W=n(3039);Object.defineProperty(t,"Heading",{enumerable:!0,get:function(){return W.Heading}});var N=n(7442);Object.defineProperty(t,"GlobalHeader",{enumerable:!0,get:function(){return N.GlobalHeader}});var z=n(6284);Object.defineProperty(t,"DropdownMenuButton",{enumerable:!0,get:function(){return z.DropdownMenuButton}});var Z=n(2082);Object.defineProperty(t,"Icon",{enumerable:!0,get:function(){return Z.Icon}});var B=n(3913);Object.defineProperty(t,"SectionalBanner",{enumerable:!0,get:function(){return B.SectionalBanner}}),r(n(7184),t);var F=n(469);Object.defineProperty(t,"SideDrawer",{enumerable:!0,get:function(){return F.SideDrawer}});var $=n(9865);Object.defineProperty(t,"GlobalBanner",{enumerable:!0,get:function(){return $.GlobalBanner}}),r(n(7807),t),r(n(5275),t);var U=n(590);Object.defineProperty(t,"Modal",{enumerable:!0,get:function(){return U.Modal}});var Y=n(5934);Object.defineProperty(t,"ModalDialog",{enumerable:!0,get:function(){return Y.ModalDialog}});var K=n(4818);Object.defineProperty(t,"Tag",{enumerable:!0,get:function(){return K.Tag}});var X=n(403);Object.defineProperty(t,"Lozenge",{enumerable:!0,get:function(){return X.Lozenge}});var G=n(4566);Object.defineProperty(t,"Status",{enumerable:!0,get:function(){return G.Status}});var J=n(5790);Object.defineProperty(t,"SkipLink",{enumerable:!0,get:function(){return J.SkipLink}});var Q=n(7329);Object.defineProperty(t,"useModal",{enumerable:!0,get:function(){return Q.useModal}});var ee=n(1635);Object.defineProperty(t,"UserProfile",{enumerable:!0,get:function(){return ee.UserProfile}});var te=n(701);Object.defineProperty(t,"useToast",{enumerable:!0,get:function(){return te.useToast}});var ne=n(1839);Object.defineProperty(t,"Breadcrumb",{enumerable:!0,get:function(){return ne.Breadcrumb}}),r(n(9682),t);var ae=n(6106);Object.defineProperty(t,"RouteLink",{enumerable:!0,get:function(){return ae.RouteLink}}),r(n(3552),t);var re=n(6382);Object.defineProperty(t,"ProgressBar",{enumerable:!0,get:function(){return re.ProgressBar}});var ie=n(1140);Object.defineProperty(t,"ProgressCircle",{enumerable:!0,get:function(){return ie.ProgressCircle}});var oe=n(9226);Object.defineProperty(t,"Pagination",{enumerable:!0,get:function(){return oe.Pagination}});var le=n(1124);Object.defineProperty(t,"equisoftTheme",{enumerable:!0,get:function(){return le.equisoftTheme}});var ue=n(2251);Object.defineProperty(t,"testTheme",{enumerable:!0,get:function(){return ue.testTheme}});var se=n(1311);Object.defineProperty(t,"injectMainCss",{enumerable:!0,get:function(){return se.injectMainCss}});var de=n(5621);Object.defineProperty(t,"useTheme",{enumerable:!0,get:function(){return de.useTheme}}),r(n(8393),t)},1125:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.useFont=void 0;const r=n(8156),i=a(n(8908));function o(e){(0,r.useEffect)((()=>e?(i.default.use(),()=>i.default.unuse()):()=>{}),[e])}t.useFont=o;try{o.displayName="useFont",o.__docgenInfo={description:"",displayName:"useFont",props:{valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => boolean"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/styles/font-loader.tsx#useFont"]={docgenInfo:o.__docgenInfo,name:"useFont",path:"src/styles/font-loader.tsx#useFont"})}catch(e){}},1311:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.useStyle=t.mainCss=t.injectMainCss=void 0;const r=a(n(865)),i=n(1125),o=n(4356);var l=n(4356);Object.defineProperty(t,"injectMainCss",{enumerable:!0,get:function(){return l.injectMainCss}}),t.mainCss=r.default.toString(),t.useStyle=function(e){(0,i.useFont)(e),(0,o.useMainCss)(e)}},4356:function(e,t,n){"use strict";var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.injectMainCss=t.useMainCss=void 0;const r=n(8156),i=a(n(4370));function o(e){(0,r.useEffect)((()=>e?()=>{}:(i.default.use(),()=>i.default.unuse())),[e])}t.useMainCss=o,t.injectMainCss=function(){i.default.use()};try{o.displayName="useMainCss",o.__docgenInfo={description:"",displayName:"useMainCss",props:{valueOf:{defaultValue:null,description:"Returns the primitive value of the specified object.",name:"valueOf",required:!1,type:{name:"() => boolean"}}}},"undefined"!=typeof STORYBOOK_REACT_CLASSES&&(STORYBOOK_REACT_CLASSES["src/styles/style-loader.tsx#useMainCss"]={docgenInfo:o.__docgenInfo,name:"useMainCss",path:"src/styles/style-loader.tsx#useMainCss"})}catch(e){}},1124:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.equisoftTheme=void 0;const a=n(8441),r=n(6774),i=n(9392),o=n(8257);t.equisoftTheme={main:r.main,greys:a.greys,notifications:i.notifications,tokens:o.tokens}},8441:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.greys=void 0,t.greys={white:"#FFFFFF","colored-white":"#FAFAFA","light-grey":"#F1F2F2",grey:"#DBDEE1","mid-grey":"#B7BBC2","dark-grey":"#60666E",black:"#000000"}},674:function(e,t,n){"use strict";var a=this&&this.__createBinding||(Object.create?function(e,t,n,a){void 0===a&&(a=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,a,r)}:function(e,t,n,a){void 0===a&&(a=n),e[a]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||a(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),r(n(1124),t),r(n(9470),t)},6774:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.main=void 0,t.main={"primary-1.1":"#006296","primary-1.2":"#84C6EA","primary-1.3":"#003A5A","primary-2":"#012639","primary-3":"#004E78","secondary-4.1":"#EF483E","secondary-4.2":"#F9B6B2","secondary-4.3":"#D41F14"}},9392:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.notifications=void 0,t.notifications={"info-1.1":"#602FA0","success-1.1":"#008533","success-1.2":"#F6FCF8","success-1.3":"#8ADDA9","alert-2.1":"#CD2C23","alert-2.2":"#FFFAFB","warning-3.1":"#F5A200","warning-3.2":"#FFF9F5","warning-3.3":"#FFB302","warning-3.4":"#A36D00"}},2251:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.testTheme=void 0;const a=n(8441),r=n(9392),i=n(8257);t.testTheme={main:{"primary-1.1":"#9EB3FF","primary-1.2":"#84B4E8","primary-1.3":"#8984E8","primary-2":"#282D40","primary-3":"#8EA1E6","secondary-4.1":"#B3974B","secondary-4.2":"#736130","secondary-4.3":"#FFD86B"},greys:a.greys,notifications:r.notifications,tokens:i.tokens}},9470:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},8257:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.tokens=void 0;const a=n(6774);t.tokens={"focus-box-shadow":`0 0 0 2px ${a.main["primary-1.2"]}`,"focus-border-box-shadow":` 0 0 0 1px ${a.main["primary-1.1"]}, 0 0 0 3px ${a.main["primary-1.2"]}`,"focus-border-box-shadow-inset":`inset 0 0 0 2px ${a.main["primary-1.2"]}, inset 0 0 0 3px ${a.main["primary-1.1"]}`,"focus-border":`${a.main["primary-1.1"]}`,"modal-overlay-background-color":"rgba(0, 0, 0, 0.75)","overlay-box-shadow":"0 10px 20px 0 rgba(0, 0, 0, 0.19)"}},7480:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.breakpoints=void 0,t.breakpoints={mobile:480,desktop:1024}},9580:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.menuDimensions=void 0,t.menuDimensions={maxWidth:"350px",minWidth:"200px"}},8167:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPreviousElementInArray=t.getNextElementInArray=void 0,t.getNextElementInArray=function(e,t){return e.length===t+1?e[0]:e[t+1]},t.getPreviousElementInArray=function(e,t){return 0===t?e[e.length-1]:e[t-1]}},6784:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.focusVisibleReset=t.focus=void 0;const a=n(1608);t.focus=({theme:e},t=!1,n,a=!1)=>`\n ${void 0===n?"&:focus { outline: none; }":""}\n ${void 0===n?"&:focus":`${n}`} {\n outline: none;\n ${t?`border-color: ${e.tokens["focus-border"]};`:""}\n box-shadow: ${e.tokens["focus-box-shadow"]};\n ${t?"":`box-shadow: ${a?e.tokens["focus-border-box-shadow-inset"]:e.tokens["focus-border-box-shadow"]};`}\n }\n`,t.focusVisibleReset=(e,t=!1)=>a.css`
|
|
2894
2928
|
&:focus:not(:focus-visible) {
|