tocco-legacy-bundle 0.1.120 → 0.1.121

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.
@@ -49,9 +49,9 @@ e.exports=function(){"use strict";const{entries:e,setPrototypeOf:t,isFrozen:n,ge
49
49
  *
50
50
  * This source code is licensed under the MIT license found in the
51
51
  * LICENSE file in the root directory of this source tree.
52
- */var r=n(1024),o=n(61688);var a="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=o.useSyncExternalStore,c=r.useRef,u=r.useEffect,s=r.useMemo,l=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var f=c(null);if(null===f.current){var p={hasValue:!1,value:null};f.current=p}else p=f.current;f=s((function(){function e(e){if(!u){if(u=!0,i=e,e=r(e),void 0!==o&&p.hasValue){var t=p.value;if(o(t,e))return c=t}return c=e}if(t=c,a(i,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(i=e,c=n)}var i,c,u=!1,s=void 0===n?null:n;return[function(){return e(t())},null===s?void 0:function(){return e(s())}]}),[t,n,r,o]);var d=i(e,f[0],f[1]);return u((function(){p.hasValue=!0,p.value=d}),[d]),l(d),d}},61688:(e,t,n)=>{"use strict";e.exports=n(53250)},52798:(e,t,n)=>{"use strict";e.exports=n(50139)},28721:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});const r={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let o;const a=new Uint8Array(16);function i(){if(!o&&(o="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!o))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return o(a)}const c=[];for(let e=0;e<256;++e)c.push((e+256).toString(16).slice(1));function u(e,t=0){return(c[e[t+0]]+c[e[t+1]]+c[e[t+2]]+c[e[t+3]]+"-"+c[e[t+4]]+c[e[t+5]]+"-"+c[e[t+6]]+c[e[t+7]]+"-"+c[e[t+8]]+c[e[t+9]]+"-"+c[e[t+10]]+c[e[t+11]]+c[e[t+12]]+c[e[t+13]]+c[e[t+14]]+c[e[t+15]]).toLowerCase()}const s=function(e,t,n){if(r.randomUUID&&!t&&!e)return r.randomUUID();const o=(e=e||{}).random||(e.rng||i)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t){n=n||0;for(let e=0;e<16;++e)t[n+e]=o[e];return t}return u(o)}},1024:e=>{"use strict";e.exports=t},30314:t=>{"use strict";t.exports=e},71298:e=>{e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},38088:e=>{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},87462:(e,t,n)=>{"use strict";function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,{Z:()=>r})},86:(e,t,n)=>{"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}n.d(t,{Z:()=>r})},31599:(e,t,n)=>{"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,{Z:()=>r})},28549:(e,t,n)=>{"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,{Z:()=>r})},2717:(e,t,n)=>{"use strict";function r(){return(r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,{Z:()=>r})},33417:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var r=n(28549);function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){(0,r.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}},32924:(e,t,n)=>{"use strict";function r(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}n.d(t,{Z:()=>r})},1972:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var r=n(78001);function o(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a=[],i=!0,c=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(a.push(r.value),!t||a.length!==t);i=!0);}catch(e){c=!0,o=e}finally{try{i||null==n.return||n.return()}finally{if(c)throw o}}return a}}(e,t)||(0,r.Z)(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},62360:(e,t,n)=>{"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}n.d(t,{Z:()=>r})},78001:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var r=n(31599);function o(e,t){if(e){if("string"==typeof e)return(0,r.Z)(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?(0,r.Z)(e,t):void 0}}}},a={};function i(e){var t=a[e];if(void 0!==t)return t.exports;var n=a[e]={id:e,loaded:!1,exports:{}};return o[e].call(n.exports,n,n.exports,i),n.loaded=!0,n.exports}i.m=o,i.amdD=function(){throw new Error("define cannot be used indirect")},i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.f={},i.e=e=>Promise.all(Object.keys(i.f).reduce(((t,n)=>(i.f[n](e,t),t)),[])),i.u=e=>"chunk-"+({85:"code-editor",198:"vendor-fontawesome",614:"vendor-icons",877:"vendor-libphonenumber-js"}[e]||e)+"."+{85:"2a582123630afe2abf6a",198:"ab9f2eea50d01a3a62a9",560:"e3d5772311dd2d78dc20",608:"3186988649a5c8a6b487",614:"43d0265825ef4c143339",631:"11bdfa70b80bb7423112",877:"a7f934130ec5ac7a8cff"}[e]+".js",i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.hmd=e=>((e=Object.create(e)).children||(e.children=[]),Object.defineProperty(e,"exports",{enumerable:!0,set:()=>{throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+e.id)}}),e),i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n={},r="tocco-:",i.l=(e,t,o,a)=>{if(n[e])n[e].push(t);else{var c,u;if(void 0!==o)for(var s=document.getElementsByTagName("script"),l=0;l<s.length;l++){var f=s[l];if(f.getAttribute("src")==e||f.getAttribute("data-webpack")==r+o){c=f;break}}c||(u=!0,(c=document.createElement("script")).charset="utf-8",c.timeout=120,i.nc&&c.setAttribute("nonce",i.nc),c.setAttribute("data-webpack",r+o),c.src=e),n[e]=[t];var p=(t,r)=>{c.onerror=c.onload=null,clearTimeout(d);var o=n[e];if(delete n[e],c.parentNode&&c.parentNode.removeChild(c),o&&o.forEach((e=>e(r))),t)return t(r)},d=setTimeout(p.bind(null,void 0,{type:"timeout",target:c}),12e4);c.onerror=p.bind(null,c.onerror),c.onload=p.bind(null,c.onload),u&&document.head.appendChild(c)}},i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),i.j=280,i.p="/",(()=>{var e={280:0};i.f.j=(t,n)=>{var r=i.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else{var o=new Promise(((n,o)=>r=e[t]=[n,o]));n.push(r[2]=o);var a=i.p+i.u(t),c=new Error;i.l(a,(n=>{if(i.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var o=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;c.message="Loading chunk "+t+" failed.\n("+o+": "+a+")",c.name="ChunkLoadError",c.type=o,c.request=a,r[1](c)}}),"chunk-"+t,t)}};var t=(t,n)=>{var r,o,[a,c,u]=n,s=0;if(a.some((t=>0!==e[t]))){for(r in c)i.o(c,r)&&(i.m[r]=c[r]);if(u)u(i)}for(t&&t(n);s<a.length;s++)o=a[s],i.o(e,o)&&e[o]&&e[o][0](),e[o]=0},n=self.webpackChunktocco_=self.webpackChunktocco_||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))})(),i.nc=void 0;var c={};return(()=>{"use strict";i.r(c),i.d(c,{app:()=>Ch});var e,t,n,r,o,a,u=i(18882),s=i(59713),l=i.n(s),f=i(45697),p=i.n(f),d=i(19743),h=i(19241),m=i(30604),v=i(74806),g=i(50558),y="two-factor-connector/INITIALIZE",b="two-factor-connector/SET_TWO_STEP_ACTIVE",w="two-factor-connector/SET_SECRET",O="two-factor-connector/SET_USER_NAME",x="two-factor-connector/REQUEST_SECRET",k="two-factor-connector/GO_TO_SECRET_VERIFICATION",S="two-factor-connector/GO_TO_START",P="two-factor-connector/GO_TO_SECRET",_="two-factor-connector/VERIFY_CODE",j="root/SUCCESS",E="root/SET_SETUP_SUCCESSFUL",C="root/GO_TO_RESULT",D=function(){return{type:y}},T=function(e){return{type:b,payload:{twoFactorActive:e}}},M=function(e){return{type:w,payload:{secret:e}}},R=function(e){return{type:O,payload:{username:e}}},I=function(){return{type:S}},N=function(e){return{type:E,payload:{setupSuccessful:e}}},A=i(1024),Z=i.n(A),L=i(35728),F=i(44012),H=i(83324),U=i(88162),B=i(34206),W=i(65035),z=i(28655),Y=i.n(z),V=i(38205),q=i(7281),G=i(58129),K=V.ZP.div.withConfig({displayName:"StyledButtonWrapper"})(e||(e=Y()(["\n display: flex;\n justify-content: flex-end;\n margin-top: ",";\n\n > "," {\n margin-right: 0;\n }\n"])),q.Z.space(.5),G.Z),X=i(24875),Q=V.ZP.div.withConfig({displayName:"StyledMessageWrapper"})(t||(t=Y()(["\n display: grid;\n grid-template-columns: 9% 1fr;\n grid-column-gap: ",";\n"])),q.Z.space(-.5)),$=V.ZP.span.withConfig({displayName:"StyledIconWrapper"})(n||(n=Y()(["\n display: flex;\n align-items: center;\n color: ",";\n font-size: ",";\n\n > * {\n max-width: 100%;\n }\n"])),(function(e){return e.isSuccessful?X.FS.color("signal.success"):X.FS.color("signal.danger")}),q.Z.font(10)),J=V.ZP.div.withConfig({displayName:"StyledTextWrapper"})(r||(r=Y()(["\n display: flex;\n align-items: center;\n"]))),ee=i(85893);const te=function(e){var t=e.success,n=e.goToStart,r=e.setupSuccessful,i=e.intl;(0,H.z)(t);var c=function(e){return i.formatMessage({id:e})};return r?(0,ee.jsxs)(ee.Fragment,{children:[o||(o=(0,ee.jsxs)(Q,{children:[(0,ee.jsx)($,{isSuccessful:!0,children:(0,ee.jsx)(U.Z,{icon:"check"})}),(0,ee.jsx)(J,{children:(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.successfulText"})})})]})),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:c("client.two-factor-connector.okButton"),ink:"primary",look:"raised",onClick:t})})]}):(0,ee.jsxs)(ee.Fragment,{children:[a||(a=(0,ee.jsxs)(Q,{children:[(0,ee.jsx)($,{isSuccessful:!1,children:(0,ee.jsx)(U.Z,{icon:"times"})}),(0,ee.jsx)(J,{children:(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.errorText"})})})]})),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:c("client.two-factor-connector.okButton"),ink:"primary",look:"raised",onClick:n})})]})};var ne={success:function(){return{type:j}},goToStart:I};const re=(0,g.connect)((function(e){return{setupSuccessful:e.twoFactorConnector.setupSuccessful}}),ne)((0,v.ZP)(te));var oe,ae=Object.defineProperty,ie=Object.getOwnPropertySymbols,ce=Object.prototype.hasOwnProperty,ue=Object.prototype.propertyIsEnumerable,se=(e,t,n)=>t in e?ae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,le=(e,t)=>{for(var n in t||(t={}))ce.call(t,n)&&se(e,n,t[n]);if(ie)for(var n of ie(t))ue.call(t,n)&&se(e,n,t[n]);return e},fe=(e,t)=>{var n={};for(var r in e)ce.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&ie)for(var r of ie(e))t.indexOf(r)<0&&ue.call(e,r)&&(n[r]=e[r]);return n};(e=>{const t=class{constructor(e,n,r,o){if(this.version=e,this.errorCorrectionLevel=n,this.modules=[],this.isFunction=[],e<t.MIN_VERSION||e>t.MAX_VERSION)throw new RangeError("Version value out of range");if(o<-1||o>7)throw new RangeError("Mask value out of range");this.size=4*e+17;let i=[];for(let e=0;e<this.size;e++)i.push(!1);for(let e=0;e<this.size;e++)this.modules.push(i.slice()),this.isFunction.push(i.slice());this.drawFunctionPatterns();const c=this.addEccAndInterleave(r);if(this.drawCodewords(c),-1==o){let e=1e9;for(let t=0;t<8;t++){this.applyMask(t),this.drawFormatBits(t);const n=this.getPenaltyScore();n<e&&(o=t,e=n),this.applyMask(t)}}a(0<=o&&o<=7),this.mask=o,this.applyMask(o),this.drawFormatBits(o),this.isFunction=[]}static encodeText(n,r){const o=e.QrSegment.makeSegments(n);return t.encodeSegments(o,r)}static encodeBinary(n,r){const o=e.QrSegment.makeBytes(n);return t.encodeSegments([o],r)}static encodeSegments(e,n,o=1,i=40,u=-1,s=!0){if(!(t.MIN_VERSION<=o&&o<=i&&i<=t.MAX_VERSION)||u<-1||u>7)throw new RangeError("Invalid value");let l,f;for(l=o;;l++){const r=8*t.getNumDataCodewords(l,n),o=c.getTotalBits(e,l);if(o<=r){f=o;break}if(l>=i)throw new RangeError("Data too long")}for(const e of[t.Ecc.MEDIUM,t.Ecc.QUARTILE,t.Ecc.HIGH])s&&f<=8*t.getNumDataCodewords(l,e)&&(n=e);let p=[];for(const t of e){r(t.mode.modeBits,4,p),r(t.numChars,t.mode.numCharCountBits(l),p);for(const e of t.getData())p.push(e)}a(p.length==f);const d=8*t.getNumDataCodewords(l,n);a(p.length<=d),r(0,Math.min(4,d-p.length),p),r(0,(8-p.length%8)%8,p),a(p.length%8==0);for(let e=236;p.length<d;e^=253)r(e,8,p);let h=[];for(;8*h.length<p.length;)h.push(0);return p.forEach(((e,t)=>h[t>>>3]|=e<<7-(7&t))),new t(l,n,h,u)}getModule(e,t){return 0<=e&&e<this.size&&0<=t&&t<this.size&&this.modules[t][e]}getModules(){return this.modules}drawFunctionPatterns(){for(let e=0;e<this.size;e++)this.setFunctionModule(6,e,e%2==0),this.setFunctionModule(e,6,e%2==0);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);const e=this.getAlignmentPatternPositions(),t=e.length;for(let n=0;n<t;n++)for(let r=0;r<t;r++)0==n&&0==r||0==n&&r==t-1||n==t-1&&0==r||this.drawAlignmentPattern(e[n],e[r]);this.drawFormatBits(0),this.drawVersion()}drawFormatBits(e){const t=this.errorCorrectionLevel.formatBits<<3|e;let n=t;for(let e=0;e<10;e++)n=n<<1^1335*(n>>>9);const r=21522^(t<<10|n);a(r>>>15==0);for(let e=0;e<=5;e++)this.setFunctionModule(8,e,o(r,e));this.setFunctionModule(8,7,o(r,6)),this.setFunctionModule(8,8,o(r,7)),this.setFunctionModule(7,8,o(r,8));for(let e=9;e<15;e++)this.setFunctionModule(14-e,8,o(r,e));for(let e=0;e<8;e++)this.setFunctionModule(this.size-1-e,8,o(r,e));for(let e=8;e<15;e++)this.setFunctionModule(8,this.size-15+e,o(r,e));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let e=this.version;for(let t=0;t<12;t++)e=e<<1^7973*(e>>>11);const t=this.version<<12|e;a(t>>>18==0);for(let e=0;e<18;e++){const n=o(t,e),r=this.size-11+e%3,a=Math.floor(e/3);this.setFunctionModule(r,a,n),this.setFunctionModule(a,r,n)}}drawFinderPattern(e,t){for(let n=-4;n<=4;n++)for(let r=-4;r<=4;r++){const o=Math.max(Math.abs(r),Math.abs(n)),a=e+r,i=t+n;0<=a&&a<this.size&&0<=i&&i<this.size&&this.setFunctionModule(a,i,2!=o&&4!=o)}}drawAlignmentPattern(e,t){for(let n=-2;n<=2;n++)for(let r=-2;r<=2;r++)this.setFunctionModule(e+r,t+n,1!=Math.max(Math.abs(r),Math.abs(n)))}setFunctionModule(e,t,n){this.modules[t][e]=n,this.isFunction[t][e]=!0}addEccAndInterleave(e){const n=this.version,r=this.errorCorrectionLevel;if(e.length!=t.getNumDataCodewords(n,r))throw new RangeError("Invalid argument");const o=t.NUM_ERROR_CORRECTION_BLOCKS[r.ordinal][n],i=t.ECC_CODEWORDS_PER_BLOCK[r.ordinal][n],c=Math.floor(t.getNumRawDataModules(n)/8),u=o-c%o,s=Math.floor(c/o);let l=[];const f=t.reedSolomonComputeDivisor(i);for(let n=0,r=0;n<o;n++){let o=e.slice(r,r+s-i+(n<u?0:1));r+=o.length;const a=t.reedSolomonComputeRemainder(o,f);n<u&&o.push(0),l.push(o.concat(a))}let p=[];for(let e=0;e<l[0].length;e++)l.forEach(((t,n)=>{(e!=s-i||n>=u)&&p.push(t[e])}));return a(p.length==c),p}drawCodewords(e){if(e.length!=Math.floor(t.getNumRawDataModules(this.version)/8))throw new RangeError("Invalid argument");let n=0;for(let t=this.size-1;t>=1;t-=2){6==t&&(t=5);for(let r=0;r<this.size;r++)for(let a=0;a<2;a++){const i=t-a,c=0==(t+1&2)?this.size-1-r:r;!this.isFunction[c][i]&&n<8*e.length&&(this.modules[c][i]=o(e[n>>>3],7-(7&n)),n++)}}a(n==8*e.length)}applyMask(e){if(e<0||e>7)throw new RangeError("Mask value out of range");for(let t=0;t<this.size;t++)for(let n=0;n<this.size;n++){let r;switch(e){case 0:r=(n+t)%2==0;break;case 1:r=t%2==0;break;case 2:r=n%3==0;break;case 3:r=(n+t)%3==0;break;case 4:r=(Math.floor(n/3)+Math.floor(t/2))%2==0;break;case 5:r=n*t%2+n*t%3==0;break;case 6:r=(n*t%2+n*t%3)%2==0;break;case 7:r=((n+t)%2+n*t%3)%2==0;break;default:throw new Error("Unreachable")}!this.isFunction[t][n]&&r&&(this.modules[t][n]=!this.modules[t][n])}}getPenaltyScore(){let e=0;for(let n=0;n<this.size;n++){let r=!1,o=0,a=[0,0,0,0,0,0,0];for(let i=0;i<this.size;i++)this.modules[n][i]==r?(o++,5==o?e+=t.PENALTY_N1:o>5&&e++):(this.finderPenaltyAddHistory(o,a),r||(e+=this.finderPenaltyCountPatterns(a)*t.PENALTY_N3),r=this.modules[n][i],o=1);e+=this.finderPenaltyTerminateAndCount(r,o,a)*t.PENALTY_N3}for(let n=0;n<this.size;n++){let r=!1,o=0,a=[0,0,0,0,0,0,0];for(let i=0;i<this.size;i++)this.modules[i][n]==r?(o++,5==o?e+=t.PENALTY_N1:o>5&&e++):(this.finderPenaltyAddHistory(o,a),r||(e+=this.finderPenaltyCountPatterns(a)*t.PENALTY_N3),r=this.modules[i][n],o=1);e+=this.finderPenaltyTerminateAndCount(r,o,a)*t.PENALTY_N3}for(let n=0;n<this.size-1;n++)for(let r=0;r<this.size-1;r++){const o=this.modules[n][r];o==this.modules[n][r+1]&&o==this.modules[n+1][r]&&o==this.modules[n+1][r+1]&&(e+=t.PENALTY_N2)}let n=0;for(const e of this.modules)n=e.reduce(((e,t)=>e+(t?1:0)),n);const r=this.size*this.size,o=Math.ceil(Math.abs(20*n-10*r)/r)-1;return a(0<=o&&o<=9),e+=o*t.PENALTY_N4,a(0<=e&&e<=2568888),e}getAlignmentPatternPositions(){if(1==this.version)return[];{const e=Math.floor(this.version/7)+2,t=32==this.version?26:2*Math.ceil((4*this.version+4)/(2*e-2));let n=[6];for(let r=this.size-7;n.length<e;r-=t)n.splice(1,0,r);return n}}static getNumRawDataModules(e){if(e<t.MIN_VERSION||e>t.MAX_VERSION)throw new RangeError("Version number out of range");let n=(16*e+128)*e+64;if(e>=2){const t=Math.floor(e/7)+2;n-=(25*t-10)*t-55,e>=7&&(n-=36)}return a(208<=n&&n<=29648),n}static getNumDataCodewords(e,n){return Math.floor(t.getNumRawDataModules(e)/8)-t.ECC_CODEWORDS_PER_BLOCK[n.ordinal][e]*t.NUM_ERROR_CORRECTION_BLOCKS[n.ordinal][e]}static reedSolomonComputeDivisor(e){if(e<1||e>255)throw new RangeError("Degree out of range");let n=[];for(let t=0;t<e-1;t++)n.push(0);n.push(1);let r=1;for(let o=0;o<e;o++){for(let e=0;e<n.length;e++)n[e]=t.reedSolomonMultiply(n[e],r),e+1<n.length&&(n[e]^=n[e+1]);r=t.reedSolomonMultiply(r,2)}return n}static reedSolomonComputeRemainder(e,n){let r=n.map((e=>0));for(const o of e){const e=o^r.shift();r.push(0),n.forEach(((n,o)=>r[o]^=t.reedSolomonMultiply(n,e)))}return r}static reedSolomonMultiply(e,t){if(e>>>8!=0||t>>>8!=0)throw new RangeError("Byte out of range");let n=0;for(let r=7;r>=0;r--)n=n<<1^285*(n>>>7),n^=(t>>>r&1)*e;return a(n>>>8==0),n}finderPenaltyCountPatterns(e){const t=e[1];a(t<=3*this.size);const n=t>0&&e[2]==t&&e[3]==3*t&&e[4]==t&&e[5]==t;return(n&&e[0]>=4*t&&e[6]>=t?1:0)+(n&&e[6]>=4*t&&e[0]>=t?1:0)}finderPenaltyTerminateAndCount(e,t,n){return e&&(this.finderPenaltyAddHistory(t,n),t=0),t+=this.size,this.finderPenaltyAddHistory(t,n),this.finderPenaltyCountPatterns(n)}finderPenaltyAddHistory(e,t){0==t[0]&&(e+=this.size),t.pop(),t.unshift(e)}};let n=t;function r(e,t,n){if(t<0||t>31||e>>>t!=0)throw new RangeError("Value out of range");for(let r=t-1;r>=0;r--)n.push(e>>>r&1)}function o(e,t){return 0!=(e>>>t&1)}function a(e){if(!e)throw new Error("Assertion error")}n.MIN_VERSION=1,n.MAX_VERSION=40,n.PENALTY_N1=3,n.PENALTY_N2=3,n.PENALTY_N3=40,n.PENALTY_N4=10,n.ECC_CODEWORDS_PER_BLOCK=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],n.NUM_ERROR_CORRECTION_BLOCKS=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],e.QrCode=n;const i=class{constructor(e,t,n){if(this.mode=e,this.numChars=t,this.bitData=n,t<0)throw new RangeError("Invalid argument");this.bitData=n.slice()}static makeBytes(e){let t=[];for(const n of e)r(n,8,t);return new i(i.Mode.BYTE,e.length,t)}static makeNumeric(e){if(!i.isNumeric(e))throw new RangeError("String contains non-numeric characters");let t=[];for(let n=0;n<e.length;){const o=Math.min(e.length-n,3);r(parseInt(e.substr(n,o),10),3*o+1,t),n+=o}return new i(i.Mode.NUMERIC,e.length,t)}static makeAlphanumeric(e){if(!i.isAlphanumeric(e))throw new RangeError("String contains unencodable characters in alphanumeric mode");let t,n=[];for(t=0;t+2<=e.length;t+=2){let o=45*i.ALPHANUMERIC_CHARSET.indexOf(e.charAt(t));o+=i.ALPHANUMERIC_CHARSET.indexOf(e.charAt(t+1)),r(o,11,n)}return t<e.length&&r(i.ALPHANUMERIC_CHARSET.indexOf(e.charAt(t)),6,n),new i(i.Mode.ALPHANUMERIC,e.length,n)}static makeSegments(e){return""==e?[]:i.isNumeric(e)?[i.makeNumeric(e)]:i.isAlphanumeric(e)?[i.makeAlphanumeric(e)]:[i.makeBytes(i.toUtf8ByteArray(e))]}static makeEci(e){let t=[];if(e<0)throw new RangeError("ECI assignment value out of range");if(e<128)r(e,8,t);else if(e<16384)r(2,2,t),r(e,14,t);else{if(!(e<1e6))throw new RangeError("ECI assignment value out of range");r(6,3,t),r(e,21,t)}return new i(i.Mode.ECI,0,t)}static isNumeric(e){return i.NUMERIC_REGEX.test(e)}static isAlphanumeric(e){return i.ALPHANUMERIC_REGEX.test(e)}getData(){return this.bitData.slice()}static getTotalBits(e,t){let n=0;for(const r of e){const e=r.mode.numCharCountBits(t);if(r.numChars>=1<<e)return 1/0;n+=4+e+r.bitData.length}return n}static toUtf8ByteArray(e){e=encodeURI(e);let t=[];for(let n=0;n<e.length;n++)"%"!=e.charAt(n)?t.push(e.charCodeAt(n)):(t.push(parseInt(e.substr(n+1,2),16)),n+=2);return t}};let c=i;c.NUMERIC_REGEX=/^[0-9]*$/,c.ALPHANUMERIC_REGEX=/^[A-Z0-9 $%*+.\/:-]*$/,c.ALPHANUMERIC_CHARSET="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:",e.QrSegment=c})(oe||(oe={})),(e=>{let t;(e=>{const t=class{constructor(e,t){this.ordinal=e,this.formatBits=t}};let n=t;n.LOW=new t(0,1),n.MEDIUM=new t(1,0),n.QUARTILE=new t(2,3),n.HIGH=new t(3,2),e.Ecc=n})(t=e.QrCode||(e.QrCode={}))})(oe||(oe={})),(e=>{let t;(e=>{const t=class{constructor(e,t){this.modeBits=e,this.numBitsCharCount=t}numCharCountBits(e){return this.numBitsCharCount[Math.floor((e+7)/17)]}};let n=t;n.NUMERIC=new t(1,[10,12,14]),n.ALPHANUMERIC=new t(2,[9,11,13]),n.BYTE=new t(4,[8,16,16]),n.KANJI=new t(8,[8,10,12]),n.ECI=new t(7,[0,0,0]),e.Mode=n})(t=e.QrSegment||(e.QrSegment={}))})(oe||(oe={}));var pe=oe,de={L:pe.QrCode.Ecc.LOW,M:pe.QrCode.Ecc.MEDIUM,Q:pe.QrCode.Ecc.QUARTILE,H:pe.QrCode.Ecc.HIGH},he=128,me="L",ve="#FFFFFF",ge="#000000",ye=!1;
52
+ */var r=n(1024),o=n(61688);var a="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=o.useSyncExternalStore,c=r.useRef,u=r.useEffect,s=r.useMemo,l=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var f=c(null);if(null===f.current){var p={hasValue:!1,value:null};f.current=p}else p=f.current;f=s((function(){function e(e){if(!u){if(u=!0,i=e,e=r(e),void 0!==o&&p.hasValue){var t=p.value;if(o(t,e))return c=t}return c=e}if(t=c,a(i,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(i=e,c=n)}var i,c,u=!1,s=void 0===n?null:n;return[function(){return e(t())},null===s?void 0:function(){return e(s())}]}),[t,n,r,o]);var d=i(e,f[0],f[1]);return u((function(){p.hasValue=!0,p.value=d}),[d]),l(d),d}},61688:(e,t,n)=>{"use strict";e.exports=n(53250)},52798:(e,t,n)=>{"use strict";e.exports=n(50139)},28721:(e,t,n)=>{"use strict";n.d(t,{Z:()=>s});const r={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let o;const a=new Uint8Array(16);function i(){if(!o&&(o="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!o))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return o(a)}const c=[];for(let e=0;e<256;++e)c.push((e+256).toString(16).slice(1));function u(e,t=0){return(c[e[t+0]]+c[e[t+1]]+c[e[t+2]]+c[e[t+3]]+"-"+c[e[t+4]]+c[e[t+5]]+"-"+c[e[t+6]]+c[e[t+7]]+"-"+c[e[t+8]]+c[e[t+9]]+"-"+c[e[t+10]]+c[e[t+11]]+c[e[t+12]]+c[e[t+13]]+c[e[t+14]]+c[e[t+15]]).toLowerCase()}const s=function(e,t,n){if(r.randomUUID&&!t&&!e)return r.randomUUID();const o=(e=e||{}).random||(e.rng||i)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t){n=n||0;for(let e=0;e<16;++e)t[n+e]=o[e];return t}return u(o)}},1024:e=>{"use strict";e.exports=t},30314:t=>{"use strict";t.exports=e},71298:e=>{e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},38088:e=>{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},87462:(e,t,n)=>{"use strict";function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,{Z:()=>r})},86:(e,t,n)=>{"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}n.d(t,{Z:()=>r})},31599:(e,t,n)=>{"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}n.d(t,{Z:()=>r})},28549:(e,t,n)=>{"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,{Z:()=>r})},2717:(e,t,n)=>{"use strict";function r(){return(r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,{Z:()=>r})},33417:(e,t,n)=>{"use strict";n.d(t,{Z:()=>a});var r=n(28549);function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach((function(t){(0,r.Z)(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}},32924:(e,t,n)=>{"use strict";function r(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}n.d(t,{Z:()=>r})},1972:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var r=n(78001);function o(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a=[],i=!0,c=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(a.push(r.value),!t||a.length!==t);i=!0);}catch(e){c=!0,o=e}finally{try{i||null==n.return||n.return()}finally{if(c)throw o}}return a}}(e,t)||(0,r.Z)(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},62360:(e,t,n)=>{"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}n.d(t,{Z:()=>r})},78001:(e,t,n)=>{"use strict";n.d(t,{Z:()=>o});var r=n(31599);function o(e,t){if(e){if("string"==typeof e)return(0,r.Z)(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?(0,r.Z)(e,t):void 0}}}},a={};function i(e){var t=a[e];if(void 0!==t)return t.exports;var n=a[e]={id:e,loaded:!1,exports:{}};return o[e].call(n.exports,n,n.exports,i),n.loaded=!0,n.exports}i.m=o,i.amdD=function(){throw new Error("define cannot be used indirect")},i.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return i.d(t,{a:t}),t},i.d=(e,t)=>{for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.f={},i.e=e=>Promise.all(Object.keys(i.f).reduce(((t,n)=>(i.f[n](e,t),t)),[])),i.u=e=>"chunk-"+({85:"code-editor",198:"vendor-fontawesome",614:"vendor-icons",877:"vendor-libphonenumber-js"}[e]||e)+"."+{85:"450940dd04b3ad4b2b2c",198:"ab9f2eea50d01a3a62a9",560:"e3d5772311dd2d78dc20",608:"3186988649a5c8a6b487",614:"43d0265825ef4c143339",631:"11bdfa70b80bb7423112",877:"a7f934130ec5ac7a8cff"}[e]+".js",i.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),i.hmd=e=>((e=Object.create(e)).children||(e.children=[]),Object.defineProperty(e,"exports",{enumerable:!0,set:()=>{throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+e.id)}}),e),i.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n={},r="tocco-:",i.l=(e,t,o,a)=>{if(n[e])n[e].push(t);else{var c,u;if(void 0!==o)for(var s=document.getElementsByTagName("script"),l=0;l<s.length;l++){var f=s[l];if(f.getAttribute("src")==e||f.getAttribute("data-webpack")==r+o){c=f;break}}c||(u=!0,(c=document.createElement("script")).charset="utf-8",c.timeout=120,i.nc&&c.setAttribute("nonce",i.nc),c.setAttribute("data-webpack",r+o),c.src=e),n[e]=[t];var p=(t,r)=>{c.onerror=c.onload=null,clearTimeout(d);var o=n[e];if(delete n[e],c.parentNode&&c.parentNode.removeChild(c),o&&o.forEach((e=>e(r))),t)return t(r)},d=setTimeout(p.bind(null,void 0,{type:"timeout",target:c}),12e4);c.onerror=p.bind(null,c.onerror),c.onload=p.bind(null,c.onload),u&&document.head.appendChild(c)}},i.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nmd=e=>(e.paths=[],e.children||(e.children=[]),e),i.j=280,i.p="/",(()=>{var e={280:0};i.f.j=(t,n)=>{var r=i.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else{var o=new Promise(((n,o)=>r=e[t]=[n,o]));n.push(r[2]=o);var a=i.p+i.u(t),c=new Error;i.l(a,(n=>{if(i.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var o=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;c.message="Loading chunk "+t+" failed.\n("+o+": "+a+")",c.name="ChunkLoadError",c.type=o,c.request=a,r[1](c)}}),"chunk-"+t,t)}};var t=(t,n)=>{var r,o,[a,c,u]=n,s=0;if(a.some((t=>0!==e[t]))){for(r in c)i.o(c,r)&&(i.m[r]=c[r]);if(u)u(i)}for(t&&t(n);s<a.length;s++)o=a[s],i.o(e,o)&&e[o]&&e[o][0](),e[o]=0},n=self.webpackChunktocco_=self.webpackChunktocco_||[];n.forEach(t.bind(null,0)),n.push=t.bind(null,n.push.bind(n))})(),i.nc=void 0;var c={};return(()=>{"use strict";i.r(c),i.d(c,{app:()=>Dh});var e,t,n,r,o,a,u=i(18882),s=i(59713),l=i.n(s),f=i(45697),p=i.n(f),d=i(19743),h=i(19241),m=i(30604),v=i(74806),g=i(50558),y="two-factor-connector/INITIALIZE",b="two-factor-connector/SET_TWO_STEP_ACTIVE",w="two-factor-connector/SET_SECRET",O="two-factor-connector/SET_USER_NAME",x="two-factor-connector/REQUEST_SECRET",k="two-factor-connector/GO_TO_SECRET_VERIFICATION",S="two-factor-connector/GO_TO_START",P="two-factor-connector/GO_TO_SECRET",_="two-factor-connector/VERIFY_CODE",j="root/SUCCESS",E="root/SET_SETUP_SUCCESSFUL",C="root/GO_TO_RESULT",D=function(){return{type:y}},T=function(e){return{type:b,payload:{twoFactorActive:e}}},M=function(e){return{type:w,payload:{secret:e}}},R=function(e){return{type:O,payload:{username:e}}},I=function(){return{type:S}},N=function(e){return{type:E,payload:{setupSuccessful:e}}},A=i(1024),Z=i.n(A),L=i(35728),F=i(44012),H=i(83324),U=i(88162),B=i(34206),W=i(65035),z=i(28655),Y=i.n(z),V=i(38205),q=i(7281),G=i(58129),K=V.ZP.div.withConfig({displayName:"StyledButtonWrapper"})(e||(e=Y()(["\n display: flex;\n justify-content: flex-end;\n margin-top: ",";\n\n > "," {\n margin-right: 0;\n }\n"])),q.Z.space(.5),G.Z),X=i(24875),Q=V.ZP.div.withConfig({displayName:"StyledMessageWrapper"})(t||(t=Y()(["\n display: grid;\n grid-template-columns: 9% 1fr;\n grid-column-gap: ",";\n"])),q.Z.space(-.5)),$=V.ZP.span.withConfig({displayName:"StyledIconWrapper"})(n||(n=Y()(["\n display: flex;\n align-items: center;\n color: ",";\n font-size: ",";\n\n > * {\n max-width: 100%;\n }\n"])),(function(e){return e.isSuccessful?X.FS.color("signal.success"):X.FS.color("signal.danger")}),q.Z.font(10)),J=V.ZP.div.withConfig({displayName:"StyledTextWrapper"})(r||(r=Y()(["\n display: flex;\n align-items: center;\n"]))),ee=i(85893);const te=function(e){var t=e.success,n=e.goToStart,r=e.setupSuccessful,i=e.intl;(0,H.z)(t);var c=function(e){return i.formatMessage({id:e})};return r?(0,ee.jsxs)(ee.Fragment,{children:[o||(o=(0,ee.jsxs)(Q,{children:[(0,ee.jsx)($,{isSuccessful:!0,children:(0,ee.jsx)(U.Z,{icon:"check"})}),(0,ee.jsx)(J,{children:(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.successfulText"})})})]})),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:c("client.two-factor-connector.okButton"),ink:"primary",look:"raised",onClick:t})})]}):(0,ee.jsxs)(ee.Fragment,{children:[a||(a=(0,ee.jsxs)(Q,{children:[(0,ee.jsx)($,{isSuccessful:!1,children:(0,ee.jsx)(U.Z,{icon:"times"})}),(0,ee.jsx)(J,{children:(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.errorText"})})})]})),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:c("client.two-factor-connector.okButton"),ink:"primary",look:"raised",onClick:n})})]})};var ne={success:function(){return{type:j}},goToStart:I};const re=(0,g.connect)((function(e){return{setupSuccessful:e.twoFactorConnector.setupSuccessful}}),ne)((0,v.ZP)(te));var oe,ae=Object.defineProperty,ie=Object.getOwnPropertySymbols,ce=Object.prototype.hasOwnProperty,ue=Object.prototype.propertyIsEnumerable,se=(e,t,n)=>t in e?ae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,le=(e,t)=>{for(var n in t||(t={}))ce.call(t,n)&&se(e,n,t[n]);if(ie)for(var n of ie(t))ue.call(t,n)&&se(e,n,t[n]);return e},fe=(e,t)=>{var n={};for(var r in e)ce.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&ie)for(var r of ie(e))t.indexOf(r)<0&&ue.call(e,r)&&(n[r]=e[r]);return n};(e=>{const t=class{constructor(e,n,r,o){if(this.version=e,this.errorCorrectionLevel=n,this.modules=[],this.isFunction=[],e<t.MIN_VERSION||e>t.MAX_VERSION)throw new RangeError("Version value out of range");if(o<-1||o>7)throw new RangeError("Mask value out of range");this.size=4*e+17;let i=[];for(let e=0;e<this.size;e++)i.push(!1);for(let e=0;e<this.size;e++)this.modules.push(i.slice()),this.isFunction.push(i.slice());this.drawFunctionPatterns();const c=this.addEccAndInterleave(r);if(this.drawCodewords(c),-1==o){let e=1e9;for(let t=0;t<8;t++){this.applyMask(t),this.drawFormatBits(t);const n=this.getPenaltyScore();n<e&&(o=t,e=n),this.applyMask(t)}}a(0<=o&&o<=7),this.mask=o,this.applyMask(o),this.drawFormatBits(o),this.isFunction=[]}static encodeText(n,r){const o=e.QrSegment.makeSegments(n);return t.encodeSegments(o,r)}static encodeBinary(n,r){const o=e.QrSegment.makeBytes(n);return t.encodeSegments([o],r)}static encodeSegments(e,n,o=1,i=40,u=-1,s=!0){if(!(t.MIN_VERSION<=o&&o<=i&&i<=t.MAX_VERSION)||u<-1||u>7)throw new RangeError("Invalid value");let l,f;for(l=o;;l++){const r=8*t.getNumDataCodewords(l,n),o=c.getTotalBits(e,l);if(o<=r){f=o;break}if(l>=i)throw new RangeError("Data too long")}for(const e of[t.Ecc.MEDIUM,t.Ecc.QUARTILE,t.Ecc.HIGH])s&&f<=8*t.getNumDataCodewords(l,e)&&(n=e);let p=[];for(const t of e){r(t.mode.modeBits,4,p),r(t.numChars,t.mode.numCharCountBits(l),p);for(const e of t.getData())p.push(e)}a(p.length==f);const d=8*t.getNumDataCodewords(l,n);a(p.length<=d),r(0,Math.min(4,d-p.length),p),r(0,(8-p.length%8)%8,p),a(p.length%8==0);for(let e=236;p.length<d;e^=253)r(e,8,p);let h=[];for(;8*h.length<p.length;)h.push(0);return p.forEach(((e,t)=>h[t>>>3]|=e<<7-(7&t))),new t(l,n,h,u)}getModule(e,t){return 0<=e&&e<this.size&&0<=t&&t<this.size&&this.modules[t][e]}getModules(){return this.modules}drawFunctionPatterns(){for(let e=0;e<this.size;e++)this.setFunctionModule(6,e,e%2==0),this.setFunctionModule(e,6,e%2==0);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);const e=this.getAlignmentPatternPositions(),t=e.length;for(let n=0;n<t;n++)for(let r=0;r<t;r++)0==n&&0==r||0==n&&r==t-1||n==t-1&&0==r||this.drawAlignmentPattern(e[n],e[r]);this.drawFormatBits(0),this.drawVersion()}drawFormatBits(e){const t=this.errorCorrectionLevel.formatBits<<3|e;let n=t;for(let e=0;e<10;e++)n=n<<1^1335*(n>>>9);const r=21522^(t<<10|n);a(r>>>15==0);for(let e=0;e<=5;e++)this.setFunctionModule(8,e,o(r,e));this.setFunctionModule(8,7,o(r,6)),this.setFunctionModule(8,8,o(r,7)),this.setFunctionModule(7,8,o(r,8));for(let e=9;e<15;e++)this.setFunctionModule(14-e,8,o(r,e));for(let e=0;e<8;e++)this.setFunctionModule(this.size-1-e,8,o(r,e));for(let e=8;e<15;e++)this.setFunctionModule(8,this.size-15+e,o(r,e));this.setFunctionModule(8,this.size-8,!0)}drawVersion(){if(this.version<7)return;let e=this.version;for(let t=0;t<12;t++)e=e<<1^7973*(e>>>11);const t=this.version<<12|e;a(t>>>18==0);for(let e=0;e<18;e++){const n=o(t,e),r=this.size-11+e%3,a=Math.floor(e/3);this.setFunctionModule(r,a,n),this.setFunctionModule(a,r,n)}}drawFinderPattern(e,t){for(let n=-4;n<=4;n++)for(let r=-4;r<=4;r++){const o=Math.max(Math.abs(r),Math.abs(n)),a=e+r,i=t+n;0<=a&&a<this.size&&0<=i&&i<this.size&&this.setFunctionModule(a,i,2!=o&&4!=o)}}drawAlignmentPattern(e,t){for(let n=-2;n<=2;n++)for(let r=-2;r<=2;r++)this.setFunctionModule(e+r,t+n,1!=Math.max(Math.abs(r),Math.abs(n)))}setFunctionModule(e,t,n){this.modules[t][e]=n,this.isFunction[t][e]=!0}addEccAndInterleave(e){const n=this.version,r=this.errorCorrectionLevel;if(e.length!=t.getNumDataCodewords(n,r))throw new RangeError("Invalid argument");const o=t.NUM_ERROR_CORRECTION_BLOCKS[r.ordinal][n],i=t.ECC_CODEWORDS_PER_BLOCK[r.ordinal][n],c=Math.floor(t.getNumRawDataModules(n)/8),u=o-c%o,s=Math.floor(c/o);let l=[];const f=t.reedSolomonComputeDivisor(i);for(let n=0,r=0;n<o;n++){let o=e.slice(r,r+s-i+(n<u?0:1));r+=o.length;const a=t.reedSolomonComputeRemainder(o,f);n<u&&o.push(0),l.push(o.concat(a))}let p=[];for(let e=0;e<l[0].length;e++)l.forEach(((t,n)=>{(e!=s-i||n>=u)&&p.push(t[e])}));return a(p.length==c),p}drawCodewords(e){if(e.length!=Math.floor(t.getNumRawDataModules(this.version)/8))throw new RangeError("Invalid argument");let n=0;for(let t=this.size-1;t>=1;t-=2){6==t&&(t=5);for(let r=0;r<this.size;r++)for(let a=0;a<2;a++){const i=t-a,c=0==(t+1&2)?this.size-1-r:r;!this.isFunction[c][i]&&n<8*e.length&&(this.modules[c][i]=o(e[n>>>3],7-(7&n)),n++)}}a(n==8*e.length)}applyMask(e){if(e<0||e>7)throw new RangeError("Mask value out of range");for(let t=0;t<this.size;t++)for(let n=0;n<this.size;n++){let r;switch(e){case 0:r=(n+t)%2==0;break;case 1:r=t%2==0;break;case 2:r=n%3==0;break;case 3:r=(n+t)%3==0;break;case 4:r=(Math.floor(n/3)+Math.floor(t/2))%2==0;break;case 5:r=n*t%2+n*t%3==0;break;case 6:r=(n*t%2+n*t%3)%2==0;break;case 7:r=((n+t)%2+n*t%3)%2==0;break;default:throw new Error("Unreachable")}!this.isFunction[t][n]&&r&&(this.modules[t][n]=!this.modules[t][n])}}getPenaltyScore(){let e=0;for(let n=0;n<this.size;n++){let r=!1,o=0,a=[0,0,0,0,0,0,0];for(let i=0;i<this.size;i++)this.modules[n][i]==r?(o++,5==o?e+=t.PENALTY_N1:o>5&&e++):(this.finderPenaltyAddHistory(o,a),r||(e+=this.finderPenaltyCountPatterns(a)*t.PENALTY_N3),r=this.modules[n][i],o=1);e+=this.finderPenaltyTerminateAndCount(r,o,a)*t.PENALTY_N3}for(let n=0;n<this.size;n++){let r=!1,o=0,a=[0,0,0,0,0,0,0];for(let i=0;i<this.size;i++)this.modules[i][n]==r?(o++,5==o?e+=t.PENALTY_N1:o>5&&e++):(this.finderPenaltyAddHistory(o,a),r||(e+=this.finderPenaltyCountPatterns(a)*t.PENALTY_N3),r=this.modules[i][n],o=1);e+=this.finderPenaltyTerminateAndCount(r,o,a)*t.PENALTY_N3}for(let n=0;n<this.size-1;n++)for(let r=0;r<this.size-1;r++){const o=this.modules[n][r];o==this.modules[n][r+1]&&o==this.modules[n+1][r]&&o==this.modules[n+1][r+1]&&(e+=t.PENALTY_N2)}let n=0;for(const e of this.modules)n=e.reduce(((e,t)=>e+(t?1:0)),n);const r=this.size*this.size,o=Math.ceil(Math.abs(20*n-10*r)/r)-1;return a(0<=o&&o<=9),e+=o*t.PENALTY_N4,a(0<=e&&e<=2568888),e}getAlignmentPatternPositions(){if(1==this.version)return[];{const e=Math.floor(this.version/7)+2,t=32==this.version?26:2*Math.ceil((4*this.version+4)/(2*e-2));let n=[6];for(let r=this.size-7;n.length<e;r-=t)n.splice(1,0,r);return n}}static getNumRawDataModules(e){if(e<t.MIN_VERSION||e>t.MAX_VERSION)throw new RangeError("Version number out of range");let n=(16*e+128)*e+64;if(e>=2){const t=Math.floor(e/7)+2;n-=(25*t-10)*t-55,e>=7&&(n-=36)}return a(208<=n&&n<=29648),n}static getNumDataCodewords(e,n){return Math.floor(t.getNumRawDataModules(e)/8)-t.ECC_CODEWORDS_PER_BLOCK[n.ordinal][e]*t.NUM_ERROR_CORRECTION_BLOCKS[n.ordinal][e]}static reedSolomonComputeDivisor(e){if(e<1||e>255)throw new RangeError("Degree out of range");let n=[];for(let t=0;t<e-1;t++)n.push(0);n.push(1);let r=1;for(let o=0;o<e;o++){for(let e=0;e<n.length;e++)n[e]=t.reedSolomonMultiply(n[e],r),e+1<n.length&&(n[e]^=n[e+1]);r=t.reedSolomonMultiply(r,2)}return n}static reedSolomonComputeRemainder(e,n){let r=n.map((e=>0));for(const o of e){const e=o^r.shift();r.push(0),n.forEach(((n,o)=>r[o]^=t.reedSolomonMultiply(n,e)))}return r}static reedSolomonMultiply(e,t){if(e>>>8!=0||t>>>8!=0)throw new RangeError("Byte out of range");let n=0;for(let r=7;r>=0;r--)n=n<<1^285*(n>>>7),n^=(t>>>r&1)*e;return a(n>>>8==0),n}finderPenaltyCountPatterns(e){const t=e[1];a(t<=3*this.size);const n=t>0&&e[2]==t&&e[3]==3*t&&e[4]==t&&e[5]==t;return(n&&e[0]>=4*t&&e[6]>=t?1:0)+(n&&e[6]>=4*t&&e[0]>=t?1:0)}finderPenaltyTerminateAndCount(e,t,n){return e&&(this.finderPenaltyAddHistory(t,n),t=0),t+=this.size,this.finderPenaltyAddHistory(t,n),this.finderPenaltyCountPatterns(n)}finderPenaltyAddHistory(e,t){0==t[0]&&(e+=this.size),t.pop(),t.unshift(e)}};let n=t;function r(e,t,n){if(t<0||t>31||e>>>t!=0)throw new RangeError("Value out of range");for(let r=t-1;r>=0;r--)n.push(e>>>r&1)}function o(e,t){return 0!=(e>>>t&1)}function a(e){if(!e)throw new Error("Assertion error")}n.MIN_VERSION=1,n.MAX_VERSION=40,n.PENALTY_N1=3,n.PENALTY_N2=3,n.PENALTY_N3=40,n.PENALTY_N4=10,n.ECC_CODEWORDS_PER_BLOCK=[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]],n.NUM_ERROR_CORRECTION_BLOCKS=[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]],e.QrCode=n;const i=class{constructor(e,t,n){if(this.mode=e,this.numChars=t,this.bitData=n,t<0)throw new RangeError("Invalid argument");this.bitData=n.slice()}static makeBytes(e){let t=[];for(const n of e)r(n,8,t);return new i(i.Mode.BYTE,e.length,t)}static makeNumeric(e){if(!i.isNumeric(e))throw new RangeError("String contains non-numeric characters");let t=[];for(let n=0;n<e.length;){const o=Math.min(e.length-n,3);r(parseInt(e.substr(n,o),10),3*o+1,t),n+=o}return new i(i.Mode.NUMERIC,e.length,t)}static makeAlphanumeric(e){if(!i.isAlphanumeric(e))throw new RangeError("String contains unencodable characters in alphanumeric mode");let t,n=[];for(t=0;t+2<=e.length;t+=2){let o=45*i.ALPHANUMERIC_CHARSET.indexOf(e.charAt(t));o+=i.ALPHANUMERIC_CHARSET.indexOf(e.charAt(t+1)),r(o,11,n)}return t<e.length&&r(i.ALPHANUMERIC_CHARSET.indexOf(e.charAt(t)),6,n),new i(i.Mode.ALPHANUMERIC,e.length,n)}static makeSegments(e){return""==e?[]:i.isNumeric(e)?[i.makeNumeric(e)]:i.isAlphanumeric(e)?[i.makeAlphanumeric(e)]:[i.makeBytes(i.toUtf8ByteArray(e))]}static makeEci(e){let t=[];if(e<0)throw new RangeError("ECI assignment value out of range");if(e<128)r(e,8,t);else if(e<16384)r(2,2,t),r(e,14,t);else{if(!(e<1e6))throw new RangeError("ECI assignment value out of range");r(6,3,t),r(e,21,t)}return new i(i.Mode.ECI,0,t)}static isNumeric(e){return i.NUMERIC_REGEX.test(e)}static isAlphanumeric(e){return i.ALPHANUMERIC_REGEX.test(e)}getData(){return this.bitData.slice()}static getTotalBits(e,t){let n=0;for(const r of e){const e=r.mode.numCharCountBits(t);if(r.numChars>=1<<e)return 1/0;n+=4+e+r.bitData.length}return n}static toUtf8ByteArray(e){e=encodeURI(e);let t=[];for(let n=0;n<e.length;n++)"%"!=e.charAt(n)?t.push(e.charCodeAt(n)):(t.push(parseInt(e.substr(n+1,2),16)),n+=2);return t}};let c=i;c.NUMERIC_REGEX=/^[0-9]*$/,c.ALPHANUMERIC_REGEX=/^[A-Z0-9 $%*+.\/:-]*$/,c.ALPHANUMERIC_CHARSET="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:",e.QrSegment=c})(oe||(oe={})),(e=>{let t;(e=>{const t=class{constructor(e,t){this.ordinal=e,this.formatBits=t}};let n=t;n.LOW=new t(0,1),n.MEDIUM=new t(1,0),n.QUARTILE=new t(2,3),n.HIGH=new t(3,2),e.Ecc=n})(t=e.QrCode||(e.QrCode={}))})(oe||(oe={})),(e=>{let t;(e=>{const t=class{constructor(e,t){this.modeBits=e,this.numBitsCharCount=t}numCharCountBits(e){return this.numBitsCharCount[Math.floor((e+7)/17)]}};let n=t;n.NUMERIC=new t(1,[10,12,14]),n.ALPHANUMERIC=new t(2,[9,11,13]),n.BYTE=new t(4,[8,16,16]),n.KANJI=new t(8,[8,10,12]),n.ECI=new t(7,[0,0,0]),e.Mode=n})(t=e.QrSegment||(e.QrSegment={}))})(oe||(oe={}));var pe=oe,de={L:pe.QrCode.Ecc.LOW,M:pe.QrCode.Ecc.MEDIUM,Q:pe.QrCode.Ecc.QUARTILE,H:pe.QrCode.Ecc.HIGH},he=128,me="L",ve="#FFFFFF",ge="#000000",ye=!1;
53
53
  /**
54
54
  * @license qrcode.react
55
55
  * Copyright (c) Paul O'Shannessy
56
56
  * SPDX-License-Identifier: ISC
57
- */function be(e,t=0){const n=[];return e.forEach((function(e,r){let o=null;e.forEach((function(a,i){if(!a&&null!==o)return n.push(`M${o+t} ${r+t}h${i-o}v1H${o+t}z`),void(o=null);if(i!==e.length-1)a&&null===o&&(o=i);else{if(!a)return;null===o?n.push(`M${i+t},${r+t} h1v1H${i+t}z`):n.push(`M${o+t},${r+t} h${i+1-o}v1H${o+t}z`)}}))})),n.join("")}function we(e,t){return e.slice().map(((e,n)=>n<t.y||n>=t.y+t.h?e:e.map(((e,n)=>(n<t.x||n>=t.x+t.w)&&e))))}function Oe(e,t,n,r){if(null==r)return null;const o=n?4:0,a=e.length+2*o,i=Math.floor(.1*t),c=a/t,u=(r.width||i)*c,s=(r.height||i)*c,l=null==r.x?e.length/2-u/2:r.x*c,f=null==r.y?e.length/2-s/2:r.y*c;let p=null;if(r.excavate){let e=Math.floor(l),t=Math.floor(f);p={x:e,y:t,w:Math.ceil(u+l-e),h:Math.ceil(s+f-t)}}return{x:l,y:f,h:s,w:u,excavation:p}}var xe=function(){try{(new Path2D).addPath(new Path2D)}catch(e){return!1}return!0}();function ke(e){const t=e,{value:n,size:r=he,level:o=me,bgColor:a=ve,fgColor:i=ge,includeMargin:c=ye,style:u,imageSettings:s}=t,l=fe(t,["value","size","level","bgColor","fgColor","includeMargin","style","imageSettings"]),f=null==s?void 0:s.src,p=(0,A.useRef)(null),d=(0,A.useRef)(null),[h,m]=(0,A.useState)(!1);(0,A.useEffect)((()=>{if(null!=p.current){const e=p.current,t=e.getContext("2d");if(!t)return;let u=pe.QrCode.encodeText(n,de[o]).getModules();const l=c?4:0,f=u.length+2*l,h=Oe(u,r,c,s),m=d.current,v=null!=h&&null!==m&&m.complete&&0!==m.naturalHeight&&0!==m.naturalWidth;v&&null!=h.excavation&&(u=we(u,h.excavation));const g=window.devicePixelRatio||1;e.height=e.width=r*g;const y=r/f*g;t.scale(y,y),t.fillStyle=a,t.fillRect(0,0,f,f),t.fillStyle=i,xe?t.fill(new Path2D(be(u,l))):u.forEach((function(e,n){e.forEach((function(e,r){e&&t.fillRect(r+l,n+l,1,1)}))})),v&&t.drawImage(m,h.x+l,h.y+l,h.w,h.h)}})),(0,A.useEffect)((()=>{m(!1)}),[f]);const v=le({height:r,width:r},u);let g=null;return null!=f&&(g=Z().createElement("img",{src:f,key:f,style:{display:"none"},onLoad:()=>{m(!0)},ref:d})),Z().createElement(Z().Fragment,null,Z().createElement("canvas",le({style:v,height:r,width:r,ref:p},l)),g)}function Se(e){const t=e,{value:n,size:r=he,level:o=me,bgColor:a=ve,fgColor:i=ge,includeMargin:c=ye,imageSettings:u}=t,s=fe(t,["value","size","level","bgColor","fgColor","includeMargin","imageSettings"]);let l=pe.QrCode.encodeText(n,de[o]).getModules();const f=c?4:0,p=l.length+2*f,d=Oe(l,r,c,u);let h=null;null!=u&&null!=d&&(null!=d.excavation&&(l=we(l,d.excavation)),h=Z().createElement("image",{xlinkHref:u.src,height:d.h,width:d.w,x:d.x+f,y:d.y+f,preserveAspectRatio:"none"}));const m=be(l,f);return Z().createElement("svg",le({height:r,width:r,viewBox:`0 0 ${p} ${p}`},s),Z().createElement("path",{fill:a,d:`M0,0 h${p}v${p}H0z`,shapeRendering:"crispEdges"}),Z().createElement("path",{fill:i,d:m,shapeRendering:"crispEdges"}),h)}var Pe=e=>{const t=e,{renderAs:n}=t,r=fe(t,["renderAs"]);return"svg"===n?Z().createElement(Se,le({},r)):Z().createElement(ke,le({},r))};const _e=function(e){var t=e.value;return(0,ee.jsx)(Pe,{value:t,renderAs:"svg"})};var je,Ee,Ce,De,Te,Me,Re=V.ZP.div.withConfig({displayName:"StyledQRCodeWrapper"})(je||(je=Y()(["\n display: flex;\n justify-content: center;\n margin: "," "," "," ",";\n"])),q.Z.space(1.2),q.Z.space(1),q.Z.space(1.5),q.Z.space(1)),Ie=V.ZP.div.withConfig({displayName:"StyledParagraph"})(Ee||(Ee=Y()(["\n display: flex;\n justify-content: center;\n margin-top: ",";\n margin-bottom: ",";\n"])),q.Z.space(-1),q.Z.space(-.9));const Ne=function(e){var t=e.secret,n=e.goToSecretVerification;return(0,H.z)(n),(0,ee.jsxs)(ee.Fragment,{children:[Ce||(Ce=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.qrCodeInfo"})})),(0,ee.jsx)(Re,{children:(0,ee.jsx)(_e,{value:t.uri})}),De||(De=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.secretInfo"})})),(0,ee.jsx)(Ie,{children:(0,ee.jsx)(B.ZP.B,{children:t.secret})}),Te||(Te=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.backupInfo"})})),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{ink:"primary",look:"raised",onClick:n,children:Me||(Me=(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.nextButton"}))})})]})};var Ae={goToSecretVerification:function(){return{type:k}}};const Ze=(0,g.connect)((function(e){return{secret:e.twoFactorConnector.secret}}),Ae)((0,v.ZP)(Ne));var Le;const Fe=function(e){var t=e.twoFactorActive,n=e.forced,r=e.requestSecret,o=e.intl;(0,H.z)(r);var a=function(e){return o.formatMessage({id:e})};return(0,ee.jsxs)(ee.Fragment,{children:[(0,ee.jsx)(B.ZP.P,{children:function(){if(t)return Le||(Le=(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.overwriteInfo"}));var e=a(n?"client.two-factor-connector.forcedInfo":"client.two-factor-connector.info");return(0,ee.jsx)("span",{dangerouslySetInnerHTML:{__html:e}})}()}),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:a("client.two-factor-connector.nextButton"),ink:"primary",look:"raised",onClick:r})})]})};var He={initialize:D,requestSecret:function(){return{type:x}}};const Ue=(0,g.connect)((function(e){return{twoFactorActive:e.twoFactorConnector.twoFactorActive,secret:e.twoFactorConnector.secret,forced:e.input.forced}}),He)((0,v.ZP)(Fe));var Be=i(63038),We=i.n(Be),ze=i(28002),Ye=i(6479),Ve=i.n(Ye),qe=i(41505),Ge=i.n(qe),Ke=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},Xe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qe=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t},$e={outline:"none"},Je=function(e){function t(){var n,r;Ke(this,t);for(var o=arguments.length,a=Array(o),i=0;i<o;i++)a[i]=arguments[i];return n=r=Qe(this,e.call.apply(e,[this].concat(a))),r.state={focused:!1},r._isMounted=!1,r._lastBlurEvent=null,r.ref=Z().createRef(),r._onFocusIn=function(){r._isMounted&&r._lastBlurEvent&&r.isInsideNode(r.ref.current,r._lastBlurEvent.target)&&!r.isInsideNode(r.ref.current,document.activeElement)&&r.setState({focused:!1},(function(){document.removeEventListener("focusin",r._onFocusIn),r.props.onBlur(r._lastBlurEvent)}))},r.onFocus=function(e){var t=r.props.onFocus;r.state.focused||r.setState({focused:!0},(function(){document.addEventListener("focusin",r._onFocusIn),t(e)}))},r.onBlur=function(e){e.persist(),r._lastBlurEvent=e},r.isInsideNode=function(e,t){return null!=e&&e.contains(t)},Qe(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.componentDidMount=function(){null!=document&&document.querySelector("body").setAttribute("tabindex","-1"),this._isMounted=!0},t.prototype.componentWillUnmount=function(){this._isMounted=!1,document.removeEventListener("focusin",this._onFocusIn)},t.prototype.focus=function(){var e=this.ref.current;null!=e&&"function"==typeof e.focus&&e.focus()},t.prototype.render=function(){var e=this.props.children,t=this.state.focused,n={onFocus:this.onFocus,onBlur:this.onBlur};return"function"==typeof e?Z().cloneElement(e({focused:t,getRef:this.ref}),n):Z().createElement("div",Xe({ref:this.ref,style:$e},n),e)},t}(Z().Component);Je.propTypes={children:Ge().oneOfType([Ge().node,Ge().func]).isRequired,onBlur:Ge().func,onFocus:Ge().func},Je.defaultProps={onBlur:function(){},onFocus:function(){}};const et=Je;var tt,nt,rt,ot,at=i(70696),it=i(10535),ct=i(23427),ut=i(319),st=i.n(ut),lt=i(37188),ft=(tt={},l()(tt,ct.Z.condition.BASE,"inherit"),l()(tt,ct.Z.condition.DANGER,X.FS.color("signal.danger")),l()(tt,ct.Z.condition.SUCCESS,X.FS.color("signal.success")),l()(tt,ct.Z.condition.WARNING,X.FS.color("signal.warning")),l()(tt,ct.Z.condition.INFO,X.FS.color("signal.info")),tt),pt=(0,V.ZP)(lt.hc).withConfig({displayName:"StyledSignalList"})(nt||(nt=Y()(["\n && {\n list-style-type: none;\n }\n"]))),dt=V.ZP.span.withConfig({displayName:"StyledSignalListIcon"})(rt||(rt=Y()(["\n position: absolute;\n left: -1.6rem;\n text-align: left;\n"]))),ht=(0,V.ZP)(lt.EF).withConfig({displayName:"StyledSignalListItem"})(ot||(ot=Y()(["\n && {\n color: ",";\n position: relative;\n padding: 0;\n }\n"])),(function(e){return function(e){return ft[e.condition]||"inherit"}(e)}));const mt=function(e){return(0,ee.jsx)(pt,{as:"ul",children:Z().Children.map(e.children,(function(e){return Z().cloneElement(e)}))})};var vt,gt,yt=(vt={},l()(vt,ct.Z.condition.BASE,!1),l()(vt,ct.Z.condition.DANGER,"times"),l()(vt,ct.Z.condition.SUCCESS,"check"),l()(vt,ct.Z.condition.WARNING,"exclamation-triangle"),l()(vt,ct.Z.condition.INFO,"info"),vt),bt=function(e){var t=yt[e.condition];return t?(0,ee.jsx)(U.Z,{icon:t,position:ct.Z.position.SOLE}):gt||(gt=(0,ee.jsx)("i",{children:"•"}))},wt=function(e){return(0,ee.jsxs)(ht,{condition:e.condition,children:[(0,ee.jsx)(dt,{children:bt(e)}),e.label,Z().Children.map(e.children,(function(e){return Z().cloneElement(e)}))]})};wt.defaultProps={condition:ct.Z.condition.BASE};const Ot={List:mt,Item:wt};const xt=function(e){if(!e.error)return null;var t=[];return Object.keys(e.error).forEach((function(n){t.push.apply(t,st()(e.error[n]))})),(0,ee.jsx)(Ot.List,{children:t.map((function(e,t){return(0,ee.jsx)(Ot.Item,{condition:"danger",label:e},t)}))})};var kt,St,Pt,_t,jt,Et,Ct,Dt,Tt,Mt,Rt,It,Nt,At,Zt,Lt=i(79686),Ft=i(30759),Ht=i(27361),Ut=i.n(Ht),Bt={base:function(e){var t=e.theme;return Ut()(t,"colors.text")},shade1:function(e){var t=e.theme;return Ut()(t,"colors.textLight")},shade2:function(e){var t=e.theme;return Ut()(t,"colors.textLighter")},signal:function(e){var t=e.theme,n=e.signal;return Ut()(t,"colors.signal.".concat(n))},hasValue:function(e){var t=e.theme;return Ut()(t,"colors.signal.info")}},Wt={base:function(e){var t=e.theme;return Ut()(t,"colors.border")},signal:function(e){var t=e.theme,n=e.signal;return Ut()(t,"colors.signal.".concat(n))},isDirty:function(e){var t=e.theme;return Ut()(t,"colors.secondaryLight")},transparent:function(){return"transparent"}},zt=i(76538),Yt="1.1px",Vt=function(e){var t=e.isDisplay,n=e.immutable;return"cursor: ".concat(!t&&n?"not-allowed":"auto",";")},qt=V.ZP.label.withConfig({displayName:"StyledStatedValueLabel"})(St||(St=Y()(["\n &&& {\n display: flex;\n width: 40%;\n flex-grow: 1;\n flex-basis: 125px;\n ","\n background-color: ",";\n pointer-events: auto;\n ","\n word-break: break-word;\n white-space: pre-wrap;\n ","\n ","\n ","\n }\n"])),(0,Ft.Z)({lineHeight:X.FS.lineHeight("dense")}),X.FS.color("paper"),(function(e){return Vt(e)}),(function(e){return"outside"===e.labelPosition&&(0,V.iv)(Pt||(Pt=Y()(["\n margin-bottom: ",";\n display: block;\n width: auto;\n "])),q.Z.space(-1.5))}),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(_t||(_t=Y()(["\n flex-basis: unset;\n position: absolute;\n top: 0;\n z-index: 1;\n display: inline-block;\n padding: 0 "," 0 ","; // if immutable remove left padding\n width: fit-content;\n left: ",";\n "])),q.Z.space(-2),(function(e){return e.immutable&&"0"}),q.Z.space(-1.8))}),(function(e){return e.styles})),Gt=V.ZP.div.withConfig({displayName:"StyledInputArea"})(jt||(jt=Y()(["\n width: 60%;\n flex-grow: 1;\n ","\n"])),(function(e){return"outside"===e.labelPosition&&(0,V.iv)(Et||(Et=Y()(["\n width: auto;\n "])))})),Kt=V.ZP.div.withConfig({displayName:"StyledStatedValueBox"})(Ct||(Ct=Y()(["\n &&& {\n position: relative;\n height: fit-content; // prevent height getting bigger due to tall labels\n border: "," solid ",";\n border-radius: ",";\n padding: "," ",";\n ","\n ","\n\n > "," {\n padding-top: ",";\n position: relative;\n top: 5px;\n\n p:first-of-type {\n margin-top: 0;\n }\n }\n ","\n ","\n }\n"])),Yt,(function(e){return Wt[function(e){var t=e.immutable,n=e.isDisplay,r=e.signal;return e.isDirty?"isDirty":n||t?"transparent":r?"signal":"base"}(e)](e)}),X.FS.radii("form"),q.Z.space(-2.5),q.Z.space(-1.5),(function(e){return!e.immutable&&function(e){var t=Ut()(e.theme,"colors.signal.info",ct.Z.fallbackColors.INFO);return(0,V.iv)(kt||(kt=Y()(["\n transition: border-color ease-in-out 100ms;\n will-change: border-color;\n\n &:focus,\n &:focus-within {\n border-color: ",";\n box-shadow: 0 0 6px ",";\n outline: 0;\n\n /**\n * Disable box-shadow for Safari\n * in order to be able to tab through the form fluently\n */\n @media not all and (min-resolution: 0.001dpcm) {\n @supports (-webkit-appearance: none) {\n box-shadow: none;\n }\n }\n }\n "])),t,(0,zt.DZ)(.4,t))}(e)}),(function(e){return Vt(e)}),Lt.j,(function(e){return e.isDisplay&&q.Z.space(-1)}),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(Dt||(Dt=Y()(["\n padding: "," "," "," ",";\n "])),q.Z.space(-1),q.Z.space(-1.7),q.Z.space(-2),q.Z.space(-1))}),(function(e){return e.styles})),Xt=V.ZP.p.withConfig({displayName:"StyledStatedValueDescription"})(Tt||(Tt=Y()(["\n &&& {\n ","\n }\n"])),(0,Ft.Z)({fontSize:q.Z.font(-1)})),Qt=V.ZP.div.withConfig({displayName:"StyledStatedValueError"})(Mt||(Mt=Y()([""]))),$t=V.ZP.div.withConfig({displayName:"StyledStatedValueOuterWrapper"})(Rt||(Rt=Y()(["\n &:not(:last-child) {\n margin-bottom: ",";\n }\n ","\n"])),q.Z.space(-.7),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(It||(It=Y()(["\n padding-top: ",";\n margin-bottom: 0.65rem;\n position: relative;\n "])),q.Z.space(-1.5))})),Jt=V.ZP.div.withConfig({displayName:"StyledStatedValueInnerWrapper"})(Nt||(Nt=Y()(["\n &&& {\n display: flex;\n flex-wrap: wrap;\n gap: ",";\n align-items: center;\n\n ",",\n ",",\n "," {\n margin-bottom: ",";\n\n &:last-child {\n margin-bottom: 0;\n }\n }\n\n "," {\n margin-left: calc("," + ",");\n }\n ","\n ","\n }\n"])),q.Z.space(-1.5),Kt,Xt,Qt,q.Z.space(-2),Xt,q.Z.space(-1),Yt,(function(e){return"outside"===e.labelPosition&&(0,V.iv)(At||(At=Y()(["\n display: block;\n "])))}),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(Zt||(Zt=Y()(["\n padding-top: 0;\n "])))}));function en(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function tn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?en(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):en(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const nn=function(e){var t,n,r,o=e.children,a=e.description,i=e.dirty,c=e.isDisplay,u=e.error,s=e.hasValue,l=e.id,f=e.label,p=e.mandatory,d=e.mandatoryTitle,h=e.immutable,m=e.touched,v=e.signal,g=e.labelPosition,y=e.styles,b=!h&&m&&u&&Object.keys(u).length>0,w=p&&d?", ".concat(d):"",O="".concat(at.Z.adjustedHTMLString(f)).concat(w),x=v||function(e,t,n,r){return t?ct.Z.condition.DANGER:e?ct.Z.condition.INFO:n&&!r?ct.Z.condition.WARNING:void 0}(i,b,p,s),k={__html:"".concat(it.Z.sanitizeHtml(f)).concat(p?" *":"")},S=!c&&!h&&{htmlFor:l};return(0,ee.jsx)(et,{children:function(e){var l=e.getRef;return(0,ee.jsx)($t,{labelPosition:g,children:(0,ee.jsxs)(Jt,{labelPosition:g,ref:l,label:f,children:[f&&(0,ee.jsx)(qt,tn(tn({},S),{},{hasValue:s,dirty:i,title:O,immutable:h,isDisplay:c,signal:x,labelPosition:g,styles:null==y?void 0:y.labelStyles,children:t||(t=(0,ee.jsx)("span",{dangerouslySetInnerHTML:k}))})),(0,ee.jsxs)(Gt,{labelPosition:g,children:[(0,ee.jsx)(Kt,{hasValue:s,immutable:h,isDisplay:c,signal:x,labelPosition:g,styles:null==y?void 0:y.valueStyles,children:o}),b&&(n||(n=(0,ee.jsx)(Qt,{children:(0,ee.jsx)(xt,{error:u})}))),a&&(r||(r=(0,ee.jsx)(Xt,{children:a})))]})]})})}})};var rn,on,an,cn=function(e){return(0,V.iv)(rn||(rn=Y()(["\n color: ",";\n font-weight: ",";\n"])),Bt[function(e){var t=e.isDisplay,n=e.immutable,r=e.signal,o=e.hasValue;return r?"signal":o?"hasValue":t?"shade1":n?"base":"shade1"}(e)](e),(function(e){return e.dirty?X.FS.fontWeight("bold"):X.FS.fontWeight("regular")}))},un=function(){return(0,V.iv)(on||(on=Y()(["\n padding-top: ",";\n padding-left: ",";\n"])),(function(e){var t=e.isDisplay,n=e.immutable;if(t&&n)return(0,V.iv)(an||(an=Y()(["\n ","\n "])),q.Z.space(-1))}),(function(e){return e.immutable&&0}))},sn=["labelPosition"];function ln(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const fn=function(e){var t=e.labelPosition,n=Ve()(e,sn);return(0,ee.jsx)(nn,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ln(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ln(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({styles:{labelStyles:cn,valueStyles:un},labelPosition:t||"outside-responsive"},n))};var pn,dn,hn,mn=function(e){return e.signal?"signal":"shade1"},vn=function(e){return(0,V.iv)(pn||(pn=Y()(["\n color: ",";\n font-weight: ",";\n"])),Bt[mn(e)](e),X.FS.fontWeight("bold"))},gn=function(){return(0,V.iv)(dn||(dn=Y()(["\n padding-top: ",";\n padding-left: ",";\n"])),(function(e){var t=e.isDisplay,n=e.immutable;return n?0:t&&n?(0,V.iv)(hn||(hn=Y()(["\n ","\n "])),q.Z.space(-1)):void 0}),(function(e){return e.immutable&&0}))},yn=["labelPosition"];function bn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const wn=function(e){var t=e.labelPosition,n=Ve()(e,yn);return(0,ee.jsx)(nn,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bn(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({styles:{labelStyles:vn,valueStyles:gn},labelPosition:t||"outside"},n))};var On,xn=(On={},l()(On,ze.Z.EmbedType.admin,fn),l()(On,ze.Z.EmbedType.widget,wn),On);const kn=ze.Z.embedStrategyFactory({mapping:xn});var Sn,Pn,_n,jn,En,Cn,Dn,Tn,Mn,Rn=i(57557),In=i.n(Rn),Nn=i(41609),An=i.n(Nn),Zn=i(50008),Ln=i.n(Zn),Fn=i(58808),Hn=i.n(Fn),Un=i(41291),Bn=i(93235),Wn=(0,V.iv)(Sn||(Sn=Y()(["\n align-items: center;\n cursor: ",";\n display: flex;\n"])),(function(e){return e.immutable?"not-allowed":"default"})),zn=V.ZP.label.withConfig({displayName:"StyledEditableWrapper"})(Pn||(Pn=Y()(["\n &&& {\n margin: 0; /* reset Bootstrap and Ext JS */\n padding: 0; /* reset Ext JS */\n ","\n }\n"])),Wn),Yn=(0,V.iv)(_n||(_n=Y()(["\n background-color: transparent;\n border: 0;\n cursor: ",";\n flex-grow: 1;\n min-height: 2.6rem;\n min-width: 0;\n outline: 0;\n padding: 0;\n ","\n &::-ms-clear {\n display: none;\n }\n\n &::-webkit-clear-button {\n display: none;\n }\n\n &::-webkit-inner-spin-button {\n display: none;\n }\n\n &[type='number'] {\n appearance: textfield;\n }\n\n &[type='search'] {\n appearance: none;\n }\n\n &:disabled {\n -webkit-text-fill-color: ","; // Safari fix\n opacity: 1; // iOS fix\n }\n\n /* remove indicators */\n &[type='date'],\n &[type='datetime-local'],\n &[type='month'],\n &[type='time'],\n &[type='week'] {\n appearance: none;\n display: flex;\n\n /* reset margin on smaller screens */\n ::-webkit-date-and-time-value {\n ","\n }\n }\n\n // allow pointer event only on touch devices\n @media (pointer: coarse) {\n pointer-events: ",";\n }\n"])),(function(e){return e.immutable?"not-allowed":"default"}),(function(){return(0,Ft.Z)({color:X.FS.color("text")})}),X.FS.color("text"),(function(e){return e.immutable&&"margin: unset;"}),(function(e){return e.immutable?"none":"auto"})),Vn=(0,V.iv)(jn||(jn=Y()(["\n display: flex;\n align-items: center;\n"]))),qn=V.ZP.div.withConfig({displayName:"StyledEditableControl"})(En||(En=Y()(["\n &&& {\n ","\n }\n"])),Vn),Gn=V.ZP.span.withConfig({displayName:"StyledEditableValue"})(Cn||(Cn=Y()(["\n width: 100%;\n\n && {\n //url\n [type='url'] + .input-group-addon > a {\n color: inherit; // reset bootstrap default\n }\n\n //url\n [type='tel'] + .input-group-addon > a {\n color: inherit; // reset bootstrap default\n }\n\n //date\n .date-edit {\n .input-group-addon {\n cursor: pointer;\n }\n\n input {\n z-index: 0;\n }\n\n &.disabled {\n input {\n cursor: not-allowed;\n }\n }\n\n .right-addon {\n position: relative;\n }\n\n .right-addon input {\n padding-right: 30px;\n }\n\n .reset {\n position: absolute;\n padding-right: 10px;\n padding-top: 5px;\n right: 0;\n color: #999;\n font-size: 18px;\n font-style: normal;\n cursor: pointer;\n }\n\n .reset:hover {\n color: ",";\n }\n }\n }\n"])),X.FS.color("signal.danger")),Kn=V.ZP.div.withConfig({displayName:"StyledLocationEdit"})(Dn||(Dn=Y()(["\n && {\n ","\n position: relative;\n\n div {\n :nth-of-type(1) {\n flex: 0 0 13ch;\n margin-right: ",";\n }\n\n :nth-of-type(2) {\n flex: 1 1 auto;\n }\n }\n\n > span {\n flex: 0 0 auto;\n margin-right: ",";\n color: ",";\n }\n\n .react-autosuggest__input {\n ","\n width: 100%;\n }\n\n .react-autosuggest__suggestions-container--open {\n width: calc(100% + 17.5px);\n background-color: ",";\n box-shadow: 0 0 6px ",";\n border: 1px solid ",";\n bottom: -9px;\n left: -10px;\n max-height: 300px;\n overflow-y: auto;\n position: absolute;\n transform: translateY(100%);\n z-index: 2; // higher than StyledIndicatorsContainerWrapper\n }\n\n .react-autosuggest__suggestions-list {\n margin: 0;\n padding: 0;\n list-style-type: none;\n }\n\n .react-autosuggest__suggestion {\n cursor: pointer;\n padding: 8px 12px;\n }\n\n .react-autosuggest__suggestion--highlighted {\n background-color: ",";\n }\n }\n"])),Wn,q.Z.space(-2),q.Z.space(-2),(function(e){var t=e.immutable,n=e.theme;return t?Ut()(n,"colors.textDisabled"):Ut()(n,"colors.text")}),Yn,X.FS.color("paper"),X.FS.color("signal.info"),X.FS.color("secondaryLight"),X.FS.color("backgroundItemHover")),Xn=(0,V.ZP)(Kn).withConfig({displayName:"StyledAddressEdit"})(Tn||(Tn=Y()(["\n && {\n div {\n :nth-of-type(1) {\n flex: auto;\n width: 100%;\n }\n }\n }\n"])));function Qn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $n(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qn(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Jn=function(e){var t,n=e.onChange,r=e.options,o=e.value,a=e.id,i=e.immutable,c=e.name,u=function(e){var t=e.street,n=e.houseNr;return n?"".concat(t," ").concat(n):t},s=function(e){var t=e.street,n=e.state,r=e.country,o=e.postcode,a=e.city;if(!t)return null;var i=u(e),c=n?"- ".concat(n):"",s=r?"/ ".concat(r.display):"";return(0,ee.jsxs)(B.ZP.Span,{children:[i,", ",o," ",a," ",c," ",s]})},f=function(e,t){var o=t.suggestion;!0===o.validationRequired?r.validateLocation(o,n):n(o)},p=function(e){var t=e.value,n=r.locationValues,o=n.postcode,a=n.city,i=n.country,c={street:t,postcode:o,city:a};r.fetchSuggestions(c,i)},d={id:a,value:o&&o.street?u(o):"",onChange:(t="street",function(e,r){var a=r.newValue;n($n($n({},o),{},l()({},t,a)))}),disabled:i};return(0,ee.jsx)(et,{children:function(e){var t,n,o,a,u,l,h,m=e.getRef;return(0,ee.jsxs)(Xn,{immutable:i,name:c,ref:m,children:[(0,ee.jsx)(Hn(),{suggestions:r.suggestions||[],onSuggestionsFetchRequested:p,getSuggestionValue:(h="street",function(e){return e[h]}),renderSuggestion:s,onSuggestionsClearRequested:function(){},inputProps:d,onSuggestionSelected:f,focusInputOnSuggestionClick:!1,shouldRenderSuggestions:function(e){return e&&!i}}),(0,ee.jsxs)(qn,{children:[r.isLoading&&(Mn||(Mn=(0,ee.jsx)(Bn.Z,{size:"1.8rem"}))),(o=r.locationValues,a=o.street,u=o.city,l=o.postcode,Boolean(a&&(u||l))&&(0,ee.jsx)(Un.Z,{href:(t=r.locationValues,n=t?Object.values(t).filter(Boolean).map((function(e){var t="object"===Ln()(e)&&e.display?e.display:e;return encodeURIComponent(t)})).join("+"):"","".concat("https://www.google.com/maps/search/?api=1&query=").concat(n)),icon:"map-marked",tabIndex:-1,target:"_blank",dense:!1,title:r.mapButtonTitle||"Show on map",neutral:!0}))]})]})}})};var er=i(14293),tr=i.n(er),nr=i(23493),rr=i.n(nr),or=i(33417),ar=i(1972),ir=i(32924),cr=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];var ur=i(2717);function sr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function lr(e,t){return(lr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function fr(e){return(fr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var pr=i(62360);function dr(e,t){if(t&&("object"===(0,pr.Z)(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function hr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=fr(e);if(t){var o=fr(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return dr(this,n)}}var mr=i(31599);var vr=i(78001);function gr(e){return function(e){if(Array.isArray(e))return(0,mr.Z)(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||(0,vr.Z)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var yr=i(29382),br=i(1537),wr=Number.isNaN||function(e){return"number"==typeof e&&e!=e};function Or(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(r=e[n],o=t[n],!(r===o||wr(r)&&wr(o)))return!1;var r,o;return!0}for(var xr={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},kr=function(e){return(0,br.tZ)("span",(0,ur.Z)({css:xr},e))},Sr={guidance:function(e){var t=e.isSearchable,n=e.isMulti,r=e.isDisabled,o=e.tabSelectsValue;switch(e.context){case"menu":return"Use Up and Down to choose options".concat(r?"":", press Enter to select the currently focused option",", press Escape to exit the menu").concat(o?", press Tab to select the option and exit the menu":"",".");case"input":return"".concat(e["aria-label"]||"Select"," is focused ").concat(t?",type to refine list":"",", press Down to open the menu, ").concat(n?" press left to focus selected values":"");case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(e){var t=e.action,n=e.label,r=void 0===n?"":n,o=e.labels,a=e.isDisabled;switch(t){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(r,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(o.length>1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return"option ".concat(r,a?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(e){var t=e.context,n=e.focused,r=e.options,o=e.label,a=void 0===o?"":o,i=e.selectValue,c=e.isDisabled,u=e.isSelected,s=function(e,t){return e&&e.length?"".concat(e.indexOf(t)+1," of ").concat(e.length):""};if("value"===t&&i)return"value ".concat(a," focused, ").concat(s(i,n),".");if("menu"===t){var l=c?" disabled":"",f="".concat(u?"selected":"focused").concat(l);return"option ".concat(a," ").concat(f,", ").concat(s(r,n),".")}return""},onFilter:function(e){var t=e.inputValue,n=e.resultsMessage;return"".concat(n).concat(t?" for search term "+t:"",".")}},Pr=function(e){var t=e.ariaSelection,n=e.focusedOption,r=e.focusedValue,o=e.focusableOptions,a=e.isFocused,i=e.selectValue,c=e.selectProps,u=e.id,s=c.ariaLiveMessages,l=c.getOptionLabel,f=c.inputValue,p=c.isMulti,d=c.isOptionDisabled,h=c.isSearchable,m=c.menuIsOpen,v=c.options,g=c.screenReaderStatus,y=c.tabSelectsValue,b=c["aria-label"],w=c["aria-live"],O=(0,A.useMemo)((function(){return(0,or.Z)((0,or.Z)({},Sr),s||{})}),[s]),x=(0,A.useMemo)((function(){var e,n="";if(t&&O.onChange){var r=t.option,o=t.options,a=t.removedValue,c=t.removedValues,u=t.value,s=a||r||(e=u,Array.isArray(e)?null:e),f=s?l(s):"",p=o||c||void 0,h=p?p.map(l):[],m=(0,or.Z)({isDisabled:s&&d(s,i),label:f,labels:h},t);n=O.onChange(m)}return n}),[t,O,d,i,l]),k=(0,A.useMemo)((function(){var e="",t=n||r,a=!!(n&&i&&i.includes(n));if(t&&O.onFocus){var c={focused:t,label:l(t),isDisabled:d(t,i),isSelected:a,options:o,context:t===n?"menu":"value",selectValue:i};e=O.onFocus(c)}return e}),[n,r,l,d,O,o,i]),S=(0,A.useMemo)((function(){var e="";if(m&&v.length&&O.onFilter){var t=g({count:o.length});e=O.onFilter({inputValue:f,resultsMessage:t})}return e}),[o,f,m,O,v,g]),P=(0,A.useMemo)((function(){var e="";if(O.guidance){var t=r?"value":m?"menu":"input";e=O.guidance({"aria-label":b,context:t,isDisabled:n&&d(n,i),isMulti:p,isSearchable:h,tabSelectsValue:y})}return e}),[b,n,r,p,d,h,m,O,i,y]),_="".concat(k," ").concat(S," ").concat(P),j=(0,br.tZ)(A.Fragment,null,(0,br.tZ)("span",{id:"aria-selection"},x),(0,br.tZ)("span",{id:"aria-context"},_)),E="initial-input-focus"===(null==t?void 0:t.action);return(0,br.tZ)(A.Fragment,null,(0,br.tZ)(kr,{id:u},E&&j),(0,br.tZ)(kr,{"aria-live":w,"aria-atomic":"false","aria-relevant":"additions text"},a&&!E&&j))},_r=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],jr=new RegExp("["+_r.map((function(e){return e.letters})).join("")+"]","g"),Er={},Cr=0;Cr<_r.length;Cr++)for(var Dr=_r[Cr],Tr=0;Tr<Dr.letters.length;Tr++)Er[Dr.letters[Tr]]=Dr.base;var Mr=function(e){return e.replace(jr,(function(e){return Er[e]}))},Rr=function(e,t){void 0===t&&(t=Or);var n=null;function r(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];if(n&&n.lastThis===this&&t(r,n.lastArgs))return n.lastResult;var a=e.apply(this,r);return n={lastResult:a,lastArgs:r,lastThis:this},a}return r.clear=function(){n=null},r}(Mr),Ir=function(e){return e.replace(/^\s+|\s+$/g,"")},Nr=function(e){return"".concat(e.label," ").concat(e.value)},Ar=["innerRef"];function Zr(e){var t=e.innerRef,n=(0,ir.Z)(e,Ar),r=(0,yr.r)(n,"onExited","in","enter","exit","appear");return(0,br.tZ)("input",(0,ur.Z)({ref:t},r,{css:(0,br.iv)({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var Lr=["boxSizing","height","overflow","paddingRight","position"],Fr={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function Hr(e){e.preventDefault()}function Ur(e){e.stopPropagation()}function Br(){var e=this.scrollTop,t=this.scrollHeight,n=e+this.offsetHeight;0===e?this.scrollTop=1:n===t&&(this.scrollTop=e-1)}function Wr(){return"ontouchstart"in window||navigator.maxTouchPoints}var zr=!("undefined"==typeof window||!window.document||!window.document.createElement),Yr=0,Vr={capture:!1,passive:!1};var qr=function(){return document.activeElement&&document.activeElement.blur()},Gr={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function Kr(e){var t=e.children,n=e.lockEnabled,r=e.captureEnabled,o=function(e){var t=e.isEnabled,n=e.onBottomArrive,r=e.onBottomLeave,o=e.onTopArrive,a=e.onTopLeave,i=(0,A.useRef)(!1),c=(0,A.useRef)(!1),u=(0,A.useRef)(0),s=(0,A.useRef)(null),l=(0,A.useCallback)((function(e,t){if(null!==s.current){var u=s.current,l=u.scrollTop,f=u.scrollHeight,p=u.clientHeight,d=s.current,h=t>0,m=f-p-l,v=!1;m>t&&i.current&&(r&&r(e),i.current=!1),h&&c.current&&(a&&a(e),c.current=!1),h&&t>m?(n&&!i.current&&n(e),d.scrollTop=f,v=!0,i.current=!0):!h&&-t>l&&(o&&!c.current&&o(e),d.scrollTop=0,v=!0,c.current=!0),v&&function(e){e.preventDefault(),e.stopPropagation()}(e)}}),[n,r,o,a]),f=(0,A.useCallback)((function(e){l(e,e.deltaY)}),[l]),p=(0,A.useCallback)((function(e){u.current=e.changedTouches[0].clientY}),[]),d=(0,A.useCallback)((function(e){var t=u.current-e.changedTouches[0].clientY;l(e,t)}),[l]),h=(0,A.useCallback)((function(e){if(e){var t=!!yr.s&&{passive:!1};e.addEventListener("wheel",f,t),e.addEventListener("touchstart",p,t),e.addEventListener("touchmove",d,t)}}),[d,p,f]),m=(0,A.useCallback)((function(e){e&&(e.removeEventListener("wheel",f,!1),e.removeEventListener("touchstart",p,!1),e.removeEventListener("touchmove",d,!1))}),[d,p,f]);return(0,A.useEffect)((function(){if(t){var e=s.current;return h(e),function(){m(e)}}}),[t,h,m]),function(e){s.current=e}}({isEnabled:void 0===r||r,onBottomArrive:e.onBottomArrive,onBottomLeave:e.onBottomLeave,onTopArrive:e.onTopArrive,onTopLeave:e.onTopLeave}),a=function(e){var t=e.isEnabled,n=e.accountForScrollbars,r=void 0===n||n,o=(0,A.useRef)({}),a=(0,A.useRef)(null),i=(0,A.useCallback)((function(e){if(zr){var t=document.body,n=t&&t.style;if(r&&Lr.forEach((function(e){var t=n&&n[e];o.current[e]=t})),r&&Yr<1){var a=parseInt(o.current.paddingRight,10)||0,i=document.body?document.body.clientWidth:0,c=window.innerWidth-i+a||0;Object.keys(Fr).forEach((function(e){var t=Fr[e];n&&(n[e]=t)})),n&&(n.paddingRight="".concat(c,"px"))}t&&Wr()&&(t.addEventListener("touchmove",Hr,Vr),e&&(e.addEventListener("touchstart",Br,Vr),e.addEventListener("touchmove",Ur,Vr))),Yr+=1}}),[r]),c=(0,A.useCallback)((function(e){if(zr){var t=document.body,n=t&&t.style;Yr=Math.max(Yr-1,0),r&&Yr<1&&Lr.forEach((function(e){var t=o.current[e];n&&(n[e]=t)})),t&&Wr()&&(t.removeEventListener("touchmove",Hr,Vr),e&&(e.removeEventListener("touchstart",Br,Vr),e.removeEventListener("touchmove",Ur,Vr)))}}),[r]);return(0,A.useEffect)((function(){if(t){var e=a.current;return i(e),function(){c(e)}}}),[t,i,c]),function(e){a.current=e}}({isEnabled:n});return(0,br.tZ)(A.Fragment,null,n&&(0,br.tZ)("div",{onClick:qr,css:Gr}),t((function(e){o(e),a(e)})))}var Xr={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Qr=function(e){var t=e.name,n=e.onFocus;return(0,br.tZ)("input",{required:!0,name:t,tabIndex:-1,"aria-hidden":"true",onFocus:n,css:Xr,value:"",onChange:function(){}})},$r={clearIndicator:yr.a,container:yr.b,control:yr.d,dropdownIndicator:yr.e,group:yr.g,groupHeading:yr.f,indicatorsContainer:yr.i,indicatorSeparator:yr.h,input:yr.j,loadingIndicator:yr.l,loadingMessage:yr.k,menu:yr.m,menuList:yr.n,menuPortal:yr.o,multiValue:yr.p,multiValueLabel:yr.q,multiValueRemove:yr.t,noOptionsMessage:yr.u,option:yr.v,placeholder:yr.w,singleValue:yr.x,valueContainer:yr.y};var Jr,eo={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},to={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:(0,yr.z)(),captureMenuScroll:!(0,yr.z)(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(e,t){if(e.data.__isNew__)return!0;var n=(0,or.Z)({ignoreCase:!0,ignoreAccents:!0,stringify:Nr,trim:!0,matchFrom:"any"},Jr),r=n.ignoreCase,o=n.ignoreAccents,a=n.stringify,i=n.trim,c=n.matchFrom,u=i?Ir(t):t,s=i?Ir(a(e)):a(e);return r&&(u=u.toLowerCase(),s=s.toLowerCase()),o&&(u=Rr(u),s=Mr(s)),"start"===c?s.substr(0,u.length)===u:s.indexOf(u)>-1},formatGroupLabel:function(e){return e.label},getOptionLabel:function(e){return e.label},getOptionValue:function(e){return e.value},isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(e){return!!e.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!(0,yr.A)(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(e){var t=e.count;return"".concat(t," result").concat(1!==t?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function no(e,t,n,r){return{type:"option",data:t,isDisabled:uo(e,t,n),isSelected:so(e,t,n),label:io(e,t),value:co(e,t),index:r}}function ro(e,t){return e.options.map((function(n,r){if("options"in n){var o=n.options.map((function(n,r){return no(e,n,t,r)})).filter((function(t){return ao(e,t)}));return o.length>0?{type:"group",data:n,options:o,index:r}:void 0}var a=no(e,n,t,r);return ao(e,a)?a:void 0})).filter(yr.K)}function oo(e){return e.reduce((function(e,t){return"group"===t.type?e.push.apply(e,gr(t.options.map((function(e){return e.data})))):e.push(t.data),e}),[])}function ao(e,t){var n=e.inputValue,r=void 0===n?"":n,o=t.data,a=t.isSelected,i=t.label,c=t.value;return(!fo(e)||!a)&&lo(e,{label:i,value:c,data:o},r)}var io=function(e,t){return e.getOptionLabel(t)},co=function(e,t){return e.getOptionValue(t)};function uo(e,t,n){return"function"==typeof e.isOptionDisabled&&e.isOptionDisabled(t,n)}function so(e,t,n){if(n.indexOf(t)>-1)return!0;if("function"==typeof e.isOptionSelected)return e.isOptionSelected(t,n);var r=co(e,t);return n.some((function(t){return co(e,t)===r}))}function lo(e,t,n){return!e.filterOption||e.filterOption(t,n)}var fo=function(e){var t=e.hideSelectedOptions,n=e.isMulti;return void 0===t?n:t},po=1,ho=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&lr(e,t)}(a,e);var t,n,r,o=hr(a);function a(e){var t;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=o.call(this,e)).state={ariaSelection:null,focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0},t.blockOptionHover=!1,t.isComposing=!1,t.commonProps=void 0,t.initialTouchX=0,t.initialTouchY=0,t.instancePrefix="",t.openAfterFocus=!1,t.scrollToFocusedOptionOnUpdate=!1,t.userIsDragging=void 0,t.controlRef=null,t.getControlRef=function(e){t.controlRef=e},t.focusedOptionRef=null,t.getFocusedOptionRef=function(e){t.focusedOptionRef=e},t.menuListRef=null,t.getMenuListRef=function(e){t.menuListRef=e},t.inputRef=null,t.getInputRef=function(e){t.inputRef=e},t.focus=t.focusInput,t.blur=t.blurInput,t.onChange=function(e,n){var r=t.props,o=r.onChange,a=r.name;n.name=a,t.ariaOnChange(e,n),o(e,n)},t.setValue=function(e,n,r){var o=t.props,a=o.closeMenuOnSelect,i=o.isMulti,c=o.inputValue;t.onInputChange("",{action:"set-value",prevInputValue:c}),a&&(t.setState({inputIsHiddenAfterUpdate:!i}),t.onMenuClose()),t.setState({clearFocusValueOnUpdate:!0}),t.onChange(e,{action:n,option:r})},t.selectOption=function(e){var n=t.props,r=n.blurInputOnSelect,o=n.isMulti,a=n.name,i=t.state.selectValue,c=o&&t.isOptionSelected(e,i),u=t.isOptionDisabled(e,i);if(c){var s=t.getOptionValue(e);t.setValue((0,yr.B)(i.filter((function(e){return t.getOptionValue(e)!==s}))),"deselect-option",e)}else{if(u)return void t.ariaOnChange((0,yr.C)(e),{action:"select-option",option:e,name:a});o?t.setValue((0,yr.B)([].concat(gr(i),[e])),"select-option",e):t.setValue((0,yr.C)(e),"select-option")}r&&t.blurInput()},t.removeValue=function(e){var n=t.props.isMulti,r=t.state.selectValue,o=t.getOptionValue(e),a=r.filter((function(e){return t.getOptionValue(e)!==o})),i=(0,yr.D)(n,a,a[0]||null);t.onChange(i,{action:"remove-value",removedValue:e}),t.focusInput()},t.clearValue=function(){var e=t.state.selectValue;t.onChange((0,yr.D)(t.props.isMulti,[],null),{action:"clear",removedValues:e})},t.popValue=function(){var e=t.props.isMulti,n=t.state.selectValue,r=n[n.length-1],o=n.slice(0,n.length-1),a=(0,yr.D)(e,o,o[0]||null);t.onChange(a,{action:"pop-value",removedValue:r})},t.getValue=function(){return t.state.selectValue},t.cx=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return yr.E.apply(void 0,[t.props.classNamePrefix].concat(n))},t.getOptionLabel=function(e){return io(t.props,e)},t.getOptionValue=function(e){return co(t.props,e)},t.getStyles=function(e,n){var r=t.props.unstyled,o=$r[e](n,r);o.boxSizing="border-box";var a=t.props.styles[e];return a?a(o,n):o},t.getClassNames=function(e,n){var r,o;return null===(r=(o=t.props.classNames)[e])||void 0===r?void 0:r.call(o,n)},t.getElementId=function(e){return"".concat(t.instancePrefix,"-").concat(e)},t.getComponents=function(){return(0,yr.F)(t.props)},t.buildCategorizedOptions=function(){return ro(t.props,t.state.selectValue)},t.getCategorizedOptions=function(){return t.props.menuIsOpen?t.buildCategorizedOptions():[]},t.buildFocusableOptions=function(){return oo(t.buildCategorizedOptions())},t.getFocusableOptions=function(){return t.props.menuIsOpen?t.buildFocusableOptions():[]},t.ariaOnChange=function(e,n){t.setState({ariaSelection:(0,or.Z)({value:e},n)})},t.onMenuMouseDown=function(e){0===e.button&&(e.stopPropagation(),e.preventDefault(),t.focusInput())},t.onMenuMouseMove=function(e){t.blockOptionHover=!1},t.onControlMouseDown=function(e){if(!e.defaultPrevented){var n=t.props.openMenuOnClick;t.state.isFocused?t.props.menuIsOpen?"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&t.onMenuClose():n&&t.openMenu("first"):(n&&(t.openAfterFocus=!0),t.focusInput()),"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&e.preventDefault()}},t.onDropdownIndicatorMouseDown=function(e){if(!(e&&"mousedown"===e.type&&0!==e.button||t.props.isDisabled)){var n=t.props,r=n.isMulti,o=n.menuIsOpen;t.focusInput(),o?(t.setState({inputIsHiddenAfterUpdate:!r}),t.onMenuClose()):t.openMenu("first"),e.preventDefault()}},t.onClearIndicatorMouseDown=function(e){e&&"mousedown"===e.type&&0!==e.button||(t.clearValue(),e.preventDefault(),t.openAfterFocus=!1,"touchend"===e.type?t.focusInput():setTimeout((function(){return t.focusInput()})))},t.onScroll=function(e){"boolean"==typeof t.props.closeMenuOnScroll?e.target instanceof HTMLElement&&(0,yr.G)(e.target)&&t.props.onMenuClose():"function"==typeof t.props.closeMenuOnScroll&&t.props.closeMenuOnScroll(e)&&t.props.onMenuClose()},t.onCompositionStart=function(){t.isComposing=!0},t.onCompositionEnd=function(){t.isComposing=!1},t.onTouchStart=function(e){var n=e.touches,r=n&&n.item(0);r&&(t.initialTouchX=r.clientX,t.initialTouchY=r.clientY,t.userIsDragging=!1)},t.onTouchMove=function(e){var n=e.touches,r=n&&n.item(0);if(r){var o=Math.abs(r.clientX-t.initialTouchX),a=Math.abs(r.clientY-t.initialTouchY);t.userIsDragging=o>5||a>5}},t.onTouchEnd=function(e){t.userIsDragging||(t.controlRef&&!t.controlRef.contains(e.target)&&t.menuListRef&&!t.menuListRef.contains(e.target)&&t.blurInput(),t.initialTouchX=0,t.initialTouchY=0)},t.onControlTouchEnd=function(e){t.userIsDragging||t.onControlMouseDown(e)},t.onClearIndicatorTouchEnd=function(e){t.userIsDragging||t.onClearIndicatorMouseDown(e)},t.onDropdownIndicatorTouchEnd=function(e){t.userIsDragging||t.onDropdownIndicatorMouseDown(e)},t.handleInputChange=function(e){var n=t.props.inputValue,r=e.currentTarget.value;t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange(r,{action:"input-change",prevInputValue:n}),t.props.menuIsOpen||t.onMenuOpen()},t.onInputFocus=function(e){t.props.onFocus&&t.props.onFocus(e),t.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(t.openAfterFocus||t.props.openMenuOnFocus)&&t.openMenu("first"),t.openAfterFocus=!1},t.onInputBlur=function(e){var n=t.props.inputValue;t.menuListRef&&t.menuListRef.contains(document.activeElement)?t.inputRef.focus():(t.props.onBlur&&t.props.onBlur(e),t.onInputChange("",{action:"input-blur",prevInputValue:n}),t.onMenuClose(),t.setState({focusedValue:null,isFocused:!1}))},t.onOptionHover=function(e){t.blockOptionHover||t.state.focusedOption===e||t.setState({focusedOption:e})},t.shouldHideSelectedOptions=function(){return fo(t.props)},t.onValueInputFocus=function(e){e.preventDefault(),e.stopPropagation(),t.focus()},t.onKeyDown=function(e){var n=t.props,r=n.isMulti,o=n.backspaceRemovesValue,a=n.escapeClearsValue,i=n.inputValue,c=n.isClearable,u=n.isDisabled,s=n.menuIsOpen,l=n.onKeyDown,f=n.tabSelectsValue,p=n.openMenuOnFocus,d=t.state,h=d.focusedOption,m=d.focusedValue,v=d.selectValue;if(!(u||"function"==typeof l&&(l(e),e.defaultPrevented))){switch(t.blockOptionHover=!0,e.key){case"ArrowLeft":if(!r||i)return;t.focusValue("previous");break;case"ArrowRight":if(!r||i)return;t.focusValue("next");break;case"Delete":case"Backspace":if(i)return;if(m)t.removeValue(m);else{if(!o)return;r?t.popValue():c&&t.clearValue()}break;case"Tab":if(t.isComposing)return;if(e.shiftKey||!s||!f||!h||p&&t.isOptionSelected(h,v))return;t.selectOption(h);break;case"Enter":if(229===e.keyCode)break;if(s){if(!h)return;if(t.isComposing)return;t.selectOption(h);break}return;case"Escape":s?(t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange("",{action:"menu-close",prevInputValue:i}),t.onMenuClose()):c&&a&&t.clearValue();break;case" ":if(i)return;if(!s){t.openMenu("first");break}if(!h)return;t.selectOption(h);break;case"ArrowUp":s?t.focusOption("up"):t.openMenu("last");break;case"ArrowDown":s?t.focusOption("down"):t.openMenu("first");break;case"PageUp":if(!s)return;t.focusOption("pageup");break;case"PageDown":if(!s)return;t.focusOption("pagedown");break;case"Home":if(!s)return;t.focusOption("first");break;case"End":if(!s)return;t.focusOption("last");break;default:return}e.preventDefault()}},t.instancePrefix="react-select-"+(t.props.instanceId||++po),t.state.selectValue=(0,yr.H)(e.value),e.menuIsOpen&&t.state.selectValue.length){var n=t.buildFocusableOptions(),r=n.indexOf(t.state.selectValue[0]);t.state.focusedOption=n[r]}return t}return t=a,r=[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r=t.clearFocusValueOnUpdate,o=t.inputIsHiddenAfterUpdate,a=t.ariaSelection,i=t.isFocused,c=t.prevWasFocused,u=e.options,s=e.value,l=e.menuIsOpen,f=e.inputValue,p=e.isMulti,d=(0,yr.H)(s),h={};if(n&&(s!==n.value||u!==n.options||l!==n.menuIsOpen||f!==n.inputValue)){var m=l?function(e,t){return oo(ro(e,t))}(e,d):[],v=r?function(e,t){var n=e.focusedValue,r=e.selectValue.indexOf(n);if(r>-1){if(t.indexOf(n)>-1)return n;if(r<t.length)return t[r]}return null}(t,d):null;h={selectValue:d,focusedOption:function(e,t){var n=e.focusedOption;return n&&t.indexOf(n)>-1?n:t[0]}(t,m),focusedValue:v,clearFocusValueOnUpdate:!1}}var g=null!=o&&e!==n?{inputIsHidden:o,inputIsHiddenAfterUpdate:void 0}:{},y=a,b=i&&c;return i&&!b&&(y={value:(0,yr.D)(p,d,d[0]||null),options:d,action:"initial-input-focus"},b=!c),"initial-input-focus"===(null==a?void 0:a.action)&&(y=null),(0,or.Z)((0,or.Z)((0,or.Z)({},h),g),{},{prevProps:e,ariaSelection:y,prevWasFocused:b})}}],(n=[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&(0,yr.I)(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isDisabled,r=t.menuIsOpen,o=this.state.isFocused;(o&&!n&&e.isDisabled||o&&r&&!e.menuIsOpen)&&this.focusInput(),o&&n&&!e.isDisabled?this.setState({isFocused:!1},this.onMenuClose):o||n||!e.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&((0,yr.I)(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(e,t){this.props.onInputChange(e,t)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(e){var t=this,n=this.state,r=n.selectValue,o=n.isFocused,a=this.buildFocusableOptions(),i="first"===e?0:a.length-1;if(!this.props.isMulti){var c=a.indexOf(r[0]);c>-1&&(i=c)}this.scrollToFocusedOptionOnUpdate=!(o&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:a[i]},(function(){return t.onMenuOpen()}))}},{key:"focusValue",value:function(e){var t=this.state,n=t.selectValue,r=t.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var o=n.indexOf(r);r||(o=-1);var a=n.length-1,i=-1;if(n.length){switch(e){case"previous":i=0===o?0:-1===o?a:o-1;break;case"next":o>-1&&o<a&&(i=o+1)}this.setState({inputIsHidden:-1!==i,focusedValue:n[i]})}}}},{key:"focusOption",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"first",t=this.props.pageSize,n=this.state.focusedOption,r=this.getFocusableOptions();if(r.length){var o=0,a=r.indexOf(n);n||(a=-1),"up"===e?o=a>0?a-1:r.length-1:"down"===e?o=(a+1)%r.length:"pageup"===e?(o=a-t)<0&&(o=0):"pagedown"===e?(o=a+t)>r.length-1&&(o=r.length-1):"last"===e&&(o=r.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:r[o],focusedValue:null})}}},{key:"getTheme",value:function(){return this.props.theme?"function"==typeof this.props.theme?this.props.theme(eo):(0,or.Z)((0,or.Z)({},eo),this.props.theme):eo}},{key:"getCommonProps",value:function(){var e=this.clearValue,t=this.cx,n=this.getStyles,r=this.getClassNames,o=this.getValue,a=this.selectOption,i=this.setValue,c=this.props,u=c.isMulti,s=c.isRtl,l=c.options;return{clearValue:e,cx:t,getStyles:n,getClassNames:r,getValue:o,hasValue:this.hasValue(),isMulti:u,isRtl:s,options:l,selectOption:a,selectProps:c,setValue:i,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var e=this.props,t=e.isClearable,n=e.isMulti;return void 0===t?n:t}},{key:"isOptionDisabled",value:function(e,t){return uo(this.props,e,t)}},{key:"isOptionSelected",value:function(e,t){return so(this.props,e,t)}},{key:"filterOption",value:function(e,t){return lo(this.props,e,t)}},{key:"formatOptionLabel",value:function(e,t){if("function"==typeof this.props.formatOptionLabel){var n=this.props.inputValue,r=this.state.selectValue;return this.props.formatOptionLabel(e,{context:t,inputValue:n,selectValue:r})}return this.getOptionLabel(e)}},{key:"formatGroupLabel",value:function(e){return this.props.formatGroupLabel(e)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var e=this.props,t=e.isDisabled,n=e.isSearchable,r=e.inputId,o=e.inputValue,a=e.tabIndex,i=e.form,c=e.menuIsOpen,u=e.required,s=this.getComponents().Input,l=this.state,f=l.inputIsHidden,p=l.ariaSelection,d=this.commonProps,h=r||this.getElementId("input"),m=(0,or.Z)((0,or.Z)((0,or.Z)({"aria-autocomplete":"list","aria-expanded":c,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":u,role:"combobox"},c&&{"aria-controls":this.getElementId("listbox"),"aria-owns":this.getElementId("listbox")}),!n&&{"aria-readonly":!0}),this.hasValue()?"initial-input-focus"===(null==p?void 0:p.action)&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return n?A.createElement(s,(0,ur.Z)({},d,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:h,innerRef:this.getInputRef,isDisabled:t,isHidden:f,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:a,form:i,type:"text",value:o},m)):A.createElement(Zr,(0,ur.Z)({id:h,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:yr.J,onFocus:this.onInputFocus,disabled:t,tabIndex:a,inputMode:"none",form:i,value:""},m))}},{key:"renderPlaceholderOrValue",value:function(){var e=this,t=this.getComponents(),n=t.MultiValue,r=t.MultiValueContainer,o=t.MultiValueLabel,a=t.MultiValueRemove,i=t.SingleValue,c=t.Placeholder,u=this.commonProps,s=this.props,l=s.controlShouldRenderValue,f=s.isDisabled,p=s.isMulti,d=s.inputValue,h=s.placeholder,m=this.state,v=m.selectValue,g=m.focusedValue,y=m.isFocused;if(!this.hasValue()||!l)return d?null:A.createElement(c,(0,ur.Z)({},u,{key:"placeholder",isDisabled:f,isFocused:y,innerProps:{id:this.getElementId("placeholder")}}),h);if(p)return v.map((function(t,i){var c=t===g,s="".concat(e.getOptionLabel(t),"-").concat(e.getOptionValue(t));return A.createElement(n,(0,ur.Z)({},u,{components:{Container:r,Label:o,Remove:a},isFocused:c,isDisabled:f,key:s,index:i,removeProps:{onClick:function(){return e.removeValue(t)},onTouchEnd:function(){return e.removeValue(t)},onMouseDown:function(e){e.preventDefault()}},data:t}),e.formatOptionLabel(t,"value"))}));if(d)return null;var b=v[0];return A.createElement(i,(0,ur.Z)({},u,{data:b,isDisabled:f}),this.formatOptionLabel(b,"value"))}},{key:"renderClearIndicator",value:function(){var e=this.getComponents().ClearIndicator,t=this.commonProps,n=this.props,r=n.isDisabled,o=n.isLoading,a=this.state.isFocused;if(!this.isClearable()||!e||r||!this.hasValue()||o)return null;var i={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(e,(0,ur.Z)({},t,{innerProps:i,isFocused:a}))}},{key:"renderLoadingIndicator",value:function(){var e=this.getComponents().LoadingIndicator,t=this.commonProps,n=this.props,r=n.isDisabled,o=n.isLoading,a=this.state.isFocused;return e&&o?A.createElement(e,(0,ur.Z)({},t,{innerProps:{"aria-hidden":"true"},isDisabled:r,isFocused:a})):null}},{key:"renderIndicatorSeparator",value:function(){var e=this.getComponents(),t=e.DropdownIndicator,n=e.IndicatorSeparator;if(!t||!n)return null;var r=this.commonProps,o=this.props.isDisabled,a=this.state.isFocused;return A.createElement(n,(0,ur.Z)({},r,{isDisabled:o,isFocused:a}))}},{key:"renderDropdownIndicator",value:function(){var e=this.getComponents().DropdownIndicator;if(!e)return null;var t=this.commonProps,n=this.props.isDisabled,r=this.state.isFocused,o={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(e,(0,ur.Z)({},t,{innerProps:o,isDisabled:n,isFocused:r}))}},{key:"renderMenu",value:function(){var e=this,t=this.getComponents(),n=t.Group,r=t.GroupHeading,o=t.Menu,a=t.MenuList,i=t.MenuPortal,c=t.LoadingMessage,u=t.NoOptionsMessage,s=t.Option,l=this.commonProps,f=this.state.focusedOption,p=this.props,d=p.captureMenuScroll,h=p.inputValue,m=p.isLoading,v=p.loadingMessage,g=p.minMenuHeight,y=p.maxMenuHeight,b=p.menuIsOpen,w=p.menuPlacement,O=p.menuPosition,x=p.menuPortalTarget,k=p.menuShouldBlockScroll,S=p.menuShouldScrollIntoView,P=p.noOptionsMessage,_=p.onMenuScrollToTop,j=p.onMenuScrollToBottom;if(!b)return null;var E,C=function(t,n){var r=t.type,o=t.data,a=t.isDisabled,i=t.isSelected,c=t.label,u=t.value,p=f===o,d=a?void 0:function(){return e.onOptionHover(o)},h=a?void 0:function(){return e.selectOption(o)},m="".concat(e.getElementId("option"),"-").concat(n),v={id:m,onClick:h,onMouseMove:d,onMouseOver:d,tabIndex:-1};return A.createElement(s,(0,ur.Z)({},l,{innerProps:v,data:o,isDisabled:a,isSelected:i,key:m,label:c,type:r,value:u,isFocused:p,innerRef:p?e.getFocusedOptionRef:void 0}),e.formatOptionLabel(t.data,"menu"))};if(this.hasOptions())E=this.getCategorizedOptions().map((function(t){if("group"===t.type){var o=t.data,a=t.options,i=t.index,c="".concat(e.getElementId("group"),"-").concat(i),u="".concat(c,"-heading");return A.createElement(n,(0,ur.Z)({},l,{key:c,data:o,options:a,Heading:r,headingProps:{id:u,data:t.data},label:e.formatGroupLabel(t.data)}),t.options.map((function(e){return C(e,"".concat(i,"-").concat(e.index))})))}if("option"===t.type)return C(t,"".concat(t.index))}));else if(m){var D=v({inputValue:h});if(null===D)return null;E=A.createElement(c,l,D)}else{var T=P({inputValue:h});if(null===T)return null;E=A.createElement(u,l,T)}var M={minMenuHeight:g,maxMenuHeight:y,menuPlacement:w,menuPosition:O,menuShouldScrollIntoView:S},R=A.createElement(yr.M,(0,ur.Z)({},l,M),(function(t){var n=t.ref,r=t.placerProps,i=r.placement,c=r.maxHeight;return A.createElement(o,(0,ur.Z)({},l,M,{innerRef:n,innerProps:{onMouseDown:e.onMenuMouseDown,onMouseMove:e.onMenuMouseMove,id:e.getElementId("listbox")},isLoading:m,placement:i}),A.createElement(Kr,{captureEnabled:d,onTopArrive:_,onBottomArrive:j,lockEnabled:k},(function(t){return A.createElement(a,(0,ur.Z)({},l,{innerRef:function(n){e.getMenuListRef(n),t(n)},isLoading:m,maxHeight:c,focusedOption:f}),E)})))}));return x||"fixed"===O?A.createElement(i,(0,ur.Z)({},l,{appendTo:x,controlElement:this.controlRef,menuPlacement:w,menuPosition:O}),R):R}},{key:"renderFormField",value:function(){var e=this,t=this.props,n=t.delimiter,r=t.isDisabled,o=t.isMulti,a=t.name,i=t.required,c=this.state.selectValue;if(i&&!this.hasValue()&&!r)return A.createElement(Qr,{name:a,onFocus:this.onValueInputFocus});if(a&&!r){if(o){if(n){var u=c.map((function(t){return e.getOptionValue(t)})).join(n);return A.createElement("input",{name:a,type:"hidden",value:u})}var s=c.length>0?c.map((function(t,n){return A.createElement("input",{key:"i-".concat(n),name:a,type:"hidden",value:e.getOptionValue(t)})})):A.createElement("input",{name:a,type:"hidden",value:""});return A.createElement("div",null,s)}var l=c[0]?this.getOptionValue(c[0]):"";return A.createElement("input",{name:a,type:"hidden",value:l})}}},{key:"renderLiveRegion",value:function(){var e=this.commonProps,t=this.state,n=t.ariaSelection,r=t.focusedOption,o=t.focusedValue,a=t.isFocused,i=t.selectValue,c=this.getFocusableOptions();return A.createElement(Pr,(0,ur.Z)({},e,{id:this.getElementId("live-region"),ariaSelection:n,focusedOption:r,focusedValue:o,isFocused:a,selectValue:i,focusableOptions:c}))}},{key:"render",value:function(){var e=this.getComponents(),t=e.Control,n=e.IndicatorsContainer,r=e.SelectContainer,o=e.ValueContainer,a=this.props,i=a.className,c=a.id,u=a.isDisabled,s=a.menuIsOpen,l=this.state.isFocused,f=this.commonProps=this.getCommonProps();return A.createElement(r,(0,ur.Z)({},f,{className:i,innerProps:{id:c,onKeyDown:this.onKeyDown},isDisabled:u,isFocused:l}),this.renderLiveRegion(),A.createElement(t,(0,ur.Z)({},f,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:u,isFocused:l,menuIsOpen:s}),A.createElement(o,(0,ur.Z)({},f,{isDisabled:u}),this.renderPlaceholderOrValue(),this.renderInput()),A.createElement(n,(0,ur.Z)({},f,{isDisabled:u}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}])&&sr(t.prototype,n),r&&sr(t,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(A.Component);ho.defaultProps=to;i(66751),i(30314),i(73469);var mo=(0,A.forwardRef)((function(e,t){var n=function(e){var t=e.defaultInputValue,n=void 0===t?"":t,r=e.defaultMenuIsOpen,o=void 0!==r&&r,a=e.defaultValue,i=void 0===a?null:a,c=e.inputValue,u=e.menuIsOpen,s=e.onChange,l=e.onInputChange,f=e.onMenuClose,p=e.onMenuOpen,d=e.value,h=(0,ir.Z)(e,cr),m=(0,A.useState)(void 0!==c?c:n),v=(0,ar.Z)(m,2),g=v[0],y=v[1],b=(0,A.useState)(void 0!==u?u:o),w=(0,ar.Z)(b,2),O=w[0],x=w[1],k=(0,A.useState)(void 0!==d?d:i),S=(0,ar.Z)(k,2),P=S[0],_=S[1],j=(0,A.useCallback)((function(e,t){"function"==typeof s&&s(e,t),_(e)}),[s]),E=(0,A.useCallback)((function(e,t){var n;"function"==typeof l&&(n=l(e,t)),y(void 0!==n?n:e)}),[l]),C=(0,A.useCallback)((function(){"function"==typeof p&&p(),x(!0)}),[p]),D=(0,A.useCallback)((function(){"function"==typeof f&&f(),x(!1)}),[f]),T=void 0!==c?c:g,M=void 0!==u?u:O,R=void 0!==d?d:P;return(0,or.Z)((0,or.Z)({},h),{},{inputValue:T,menuIsOpen:M,onChange:j,onInputChange:E,onMenuClose:D,onMenuOpen:C,value:R})}(e);return A.createElement(ho,(0,ur.Z)({ref:t},n))})),vo=i(80470);function go(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function yo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?go(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):go(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const bo=(0,v.ZP)((function(e){var t;return(0,ee.jsx)("span",yo(yo({},e.innerProps),{},{children:(0,ee.jsx)(vo.Z,{icon:"times",tabIndex:-1,"aria-label":(t="client.component.select.clearFieldLabel",e.intl.formatMessage({id:t}))})}))}));var wo=i(95497);function Oo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function xo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Oo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Oo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const ko=function(e){var t=e.selectProps,n=t.isDisabled,r=t.menuIsOpen;return n?null:(0,ee.jsx)(yr.c.DropdownIndicator,xo(xo({},e),{},{children:(0,ee.jsx)(wo.M6,{children:(0,ee.jsx)(vo.Z,{icon:r?"chevron-up":"chevron-down",visible:!0,tabIndex:-1})})}))};var So,Po,_o;function jo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Eo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?jo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Co=function(e,t,n){return function(r){r.stopPropagation(),e(t,n)}},Do=function(e,t){return function(n){n.stopPropagation(),e(t)}},To=function(e,t){return function(n){n.stopPropagation(),e(t)}},Mo=function(e){e.stopPropagation()};const Ro=function(e){var t=e.selectProps,n=t.openDocsTreeSearch,r=t.openAdvancedSearch,o=t.openRemoteCreate,a=t.isDisabled,i=t.hasDocsTreeSearch,c=t.hasAdvancedSearch,u=t.createPermission,s=t.value,l=t.isMulti,f=t.inputValue,p=l&&(c||i);return(0,ee.jsx)(wo.HO,{isTopAligned:p,children:(0,ee.jsxs)(yr.c.IndicatorsContainer,Eo(Eo({},e),{},{children:[e.children,n&&!a&&(0,ee.jsx)("span",{onTouchEnd:Mo,onMouseDown:Do(n,s),children:So||(So=(0,ee.jsx)(vo.Z,{icon:"folder",tabIndex:-1}))}),r&&!a&&(0,ee.jsx)("span",{onTouchEnd:Mo,onMouseDown:Co(r,f,s),children:Po||(Po=(0,ee.jsx)(vo.Z,{icon:"search",tabIndex:-1}))}),u&&!a&&(0,ee.jsx)("span",{onTouchEnd:Mo,onMouseDown:To(o,s),children:_o||(_o=(0,ee.jsx)(vo.Z,{icon:"plus",tabIndex:-1}))})]}))})};var Io;const No=function(){return Io||(Io=(0,ee.jsx)("span",{children:(0,ee.jsx)(Bn.Z,{size:"1.8rem"})}))};var Ao=i(15315);function Zo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Lo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Zo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Zo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Fo=function(e){var t=e.selectProps,n=e.children;return(0,ee.jsx)(wo._M,{attachment:"top left",targetAttachment:"bottom left",constraints:[{to:"window",attachment:"together"}],renderTarget:function(e){return(0,ee.jsx)("div",{ref:e})},renderElement:function(r){return(0,ee.jsx)("div",{ref:r,className:Ao.c,children:(0,ee.jsx)(wo.l2,Lo(Lo({},In()(e,["innerRef"])),{},{wrapperWidth:t.wrapperWidth,wrapperHeight:t.wrapperHeight,children:n}))})}})};function Ho(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Uo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ho(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ho(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Bo=function(e){var t=e.selectProps,n=e.children,r=t.moreOptionsAvailable,o=t.moreOptionsAvailableText;return(0,ee.jsxs)(yr.c.MenuList,Uo(Uo({},e),{},{className:"MenuList",children:[n,r&&(0,ee.jsx)(wo.OA,{children:o})]}))};var Wo=i(76791);function zo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Yo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Vo=function(e){var t=e.data,n=e.innerProps,r=e.children,o=e.selectProps,a=o.tooltips,i=o.loadTooltip,c=o.DetailLink,u=Ut()(a,t.key,null),s=(0,ee.jsx)("span",Yo(Yo({},n),{},{children:r})),l=c?(0,ee.jsx)(wo.vR,{onMouseDown:function(e){e.stopPropagation(),e.preventDefault()},children:(0,ee.jsx)(c,{entityKey:t.key,tabIndex:-1,children:(0,ee.jsx)(Wo.Z,{content:u?(0,ee.jsx)("div",{dangerouslySetInnerHTML:{__html:it.Z.sanitizeHtml(u)}}):null,children:(0,ee.jsx)("span",{onMouseOver:function(){return i&&!u&&i(t.key)},children:s})})})}):s;return(0,ee.jsx)(wo.B1,{children:l})};var qo=i(47037),Go=i.n(qo),Ko=i(14176),Xo=i.n(Ko);function Qo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function $o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Qo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Qo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Jo=["linkComp"],ea=function(e,t){var n=at.Z.difference(e,t),r=Xo()(In()(n,Jo),(function(e){return 0===Object.keys(e).length}));return 0===Object.entries(r).length},ta=(0,A.memo)((function(e){var t=e.linkComp,n=e.entityKey,r=e.children;return t&&Go()(n)?(0,ee.jsx)(wo.vR,{onMouseDown:function(e){e.stopPropagation(),e.preventDefault()},children:(0,ee.jsx)(t,{entityKey:n,children:r})}):r}),ea);ta.propTypes={children:p().node,entityKey:p().any,linkComp:p().func};const na=function(e){var t=e.data,n=e.selectProps,r=e.isDisabled,o=e.children,a=n.tooltips,i=n.loadTooltip,c=n.DetailLink,u=Ut()(a,t.key,null);return(0,ee.jsx)(yr.c.SingleValue,$o($o({},e),{},{children:(0,ee.jsx)(wo.xq,{onMouseOver:function(){return i&&!u&&i(t.key)},isDisabled:r,children:(0,ee.jsx)(Wo.Z,{content:u?(0,ee.jsx)("div",{dangerouslySetInnerHTML:{__html:it.Z.sanitizeHtml(u)}}):null,children:(0,ee.jsx)(ta,{linkComp:c,entityKey:t.key,children:o})})})}))};function ra(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var oa=function(e){var t;return"Input"===(null==e||null===(t=e.type)||void 0===t?void 0:t.name)};const aa=function(e){var t=e.selectProps,n=e.hasValue,r=e.children,o=t.isMulti,a=t.hasAdvancedSearch,i=t.hasDocsTreeSearch,c=t.isDisabled;if(!(o&&(a||i)))return(0,ee.jsx)(yr.c.ValueContainer,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ra(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ra(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e));var u=A.Children.map(r,(function(e){return oa(e)?e:null})),s=A.Children.map(r,(function(e){return oa(e)?null:e})),f=c&&n;return(0,ee.jsxs)(ee.Fragment,{children:[!f&&(0,ee.jsx)(ee.Fragment,{children:u}),(0,ee.jsx)(wo.eQ,{children:s})]})};function ia(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ca(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ia(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ia(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const ua=(0,V.Zz)((function(e){var t=e.fetchOptions,n=e.id,r=e.immutable,o=e.isLoading,a=e.isMulti,i=e.loadTooltip,c=e.moreOptionsAvailable,u=e.moreOptionsAvailableText,s=e.noResultsText,l=e.noResultsComp,f=e.onChange,p=e.openDocsTreeSearch,d=e.openAdvancedSearch,h=e.options,m=e.searchOptions,v=e.theme,g=e.tooltips,y=e.value,b=e.DetailLink,w=e.createPermission,O=e.openRemoteCreate,x=(0,A.useRef)(null),k=(0,A.useRef)(null),S=function(){var e;return(null===(e=k.current)||void 0===e?void 0:e.clientWidth)||300},P=function(){var e;return(null===(e=k.current)||void 0===e?void 0:e.clientHeight)||35},_=(0,A.useState)(S()),j=We()(_,2),E=j[0],C=j[1],D=(0,A.useState)(P()),T=We()(D,2),M=T[0],R=T[1],I=(0,A.useState)(!1),N=We()(I,2),Z=N[0],L=N[1],F=function(e){t&&t(e)},H=(0,A.useCallback)(m||function(){},[]),U=(0,A.useCallback)(rr()(H,800,{trailing:!0}),[]),B=Boolean(d),W=Boolean(p),z=Boolean(w);return(0,ee.jsx)(wo.sP,{tabIndex:"-1",id:n,onFocus:function(){x.current.focus(),setTimeout((function(){C(S()),R(P())}),0)},children:(0,ee.jsx)(wo.RU,{ref:k,children:(0,ee.jsx)(mo,ca(ca({getOptionLabel:function(e){return e.display},getOptionValue:function(e){return e.key},wrapperWidth:E,wrapperHeight:M,components:{ClearIndicator:bo,LoadingIndicator:No,DropdownIndicator:ko,IndicatorsContainer:Ro,IndicatorSeparator:null,Menu:Fo,MenuList:Bo,MultiValueLabel:Vo,SingleValue:na,ValueContainer:aa},noOptionsMessage:function(e){return s||("function"==typeof l?(0,ee.jsx)(l,ca({},e)):" - ")},isMulti:a,closeMenuOnSelect:!a,isSearchable:!0},m?{filterOption:function(){return!0}}:{}),{},{isClearable:!0,loadingMessage:function(){return null},placeholder:"",menuShouldScrollIntoView:!1,autoFocus:!1,value:y||null,onChange:function(e){f(e),F(e)},onInputChange:function(e,t){var n=t.action;m&&e&&U(e,y),""===e&&"input-change"===n&&F(y)},options:st()(h||[]),onKeyDown:function(e){"Enter"===e.key&&Z?(e.stopPropagation(),x.current&&null===x.current.focusedOptionRef&&e.preventDefault()):"Tab"===e.key&&(e.preventDefault=function(){})},isLoading:o,isDisabled:r,ref:x,onMenuOpen:function(){F(y),L(!0)},onMenuClose:function(){L(!1)},styles:(0,wo.i4)(v),loadTooltip:i,tooltips:g,DetailLink:b,hasDocsTreeSearch:W,openDocsTreeSearch:p,hasAdvancedSearch:B,openAdvancedSearch:d,moreOptionsAvailable:c,moreOptionsAvailableText:u,blurInputOnSelect:!1,hasCreatePermission:z,createPermission:w,openRemoteCreate:O,closeMenuOnScroll:function(e){var t;return!(null!==(t=e.target.classList)&&void 0!==t&&t.contains("MenuList"))}}))})})}));const sa=function(e){var t=e.id,n=e.immutable,r=e.value,o=e.options,a=o.trueLabel,i=o.falseLabel,c=e.onChange;return(0,ee.jsx)(ua,{id:t,immutable:n,isMulti:!1,onChange:function(e){return c(e?e.key:null)},value:tr()(r)?r:{key:r,display:r?a:i},openMenuOnClick:!0,options:[{key:!0,display:a},{key:!1,display:i}]})};var la,fa=V.ZP.div.withConfig({displayName:"StyledBoolEdit"})(la||(la=Y()(["\n margin: 5px 0;\n"])));const pa=function(e){return(0,ee.jsx)(fa,{children:(0,ee.jsx)("input",{type:"checkbox",checked:e.value||!1,name:e.name,onChange:function(t){e.onChange&&e.onChange(t.target.checked)},id:e.id,disabled:e.immutable})})};var da,ha;function ma(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function va(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ma(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ma(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ga=V.ZP.div.withConfig({displayName:"StyledOption"})(da||(da=Y()(["\n margin: "," 0;\n"])),q.Z.space(-1.4)),ya=V.ZP.span.withConfig({displayName:"StyledLabel"})(ha||(ha=Y()(["\n ","\n display: inline-block;\n margin-left: ",";\n"])),(0,Ft.Z)(),q.Z.space(-1.5)),ba={single:"radio",multiple:"checkbox"},wa={single:{checked:!1},multiple:{}},Oa=function(e,t){return t?(0,ee.jsx)(Lt.Z,{value:e}):e},xa=function(e){var t=e.groupName,n=e.id,r=e.label,o=e.labelComponent,a=e.checked,i=e.immutable,c=e.hideCheckbox,u=e.selectionType,s=e.renderHtmlInOptions,l=e.handleChange;return(0,ee.jsxs)(ga,{children:[!c&&(0,ee.jsx)("input",{name:t,type:ba[u],checked:a||!1,onChange:l,id:n,disabled:i}),(0,ee.jsx)(ya,{children:o||Oa(r,s)})]})};const ka=function(e){var t=function(t){if(e.onChange){var n=e.value.options.map((function(n){return va(va({},n),n.id===t.target.id?{checked:t.target.checked}:wa[e.options.selectionType])}));e.onChange({options:n})}};return(0,ee.jsx)(ee.Fragment,{children:e.value.options.map((function(n){return(0,ee.jsx)(xa,{groupName:e.id,id:n.id,label:n.label,labelComponent:n.labelComponent,checked:n.checked,immutable:e.immutable||n.immutable,hideCheckbox:n.hideCheckbox,selectionType:e.options.selectionType,renderHtmlInOptions:e.options.renderHtmlInOptions,handleChange:t},n.id)}))})};var Sa=i(23279),Pa=i.n(Sa);function _a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ja(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_a(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ea=(0,A.lazy)((function(){return Promise.all([i.e(560),i.e(85)]).then(i.bind(i,30919))}));const Ca=function(e){return(0,ee.jsx)(A.Suspense,{fallback:(t=e.value,(0,ee.jsx)("div",{children:(0,ee.jsx)("p",{children:t})})),children:(0,ee.jsx)(Ea,ja({},e))});var t};var Da,Ta=V.ZP.div.withConfig({displayName:"StyledEditorWrapper"})(Da||(Da=Y()(["\n margin-top: ",";\n"])),q.Z.space(-1.5));const Ma=function(e){var t=e.value,n=e.onChange,r=e.immutable,o=e.options;return(0,ee.jsx)(Ta,{children:(0,ee.jsx)(Ca,{value:t,onChange:Pa()(n,1e3),autoFocusOnMount:o.autoFocusOnMount,mode:o.mode,theme:"textmate",showGutter:!0,editorOptions:{enableBasicAutocompletion:!0,enableLiveAutocompletion:!0,enableSnippets:!0,minLines:5,maxLines:50,readOnly:r,wrap:!0,indentedSoftWrap:!1},implicitModel:o.implicitModel})})};var Ra=i(86896),Ia=i(23842),Na=i(93379),Aa=i.n(Na),Za=i(7795),La=i.n(Za),Fa=i(90569),Ha=i.n(Fa),Ua=i(3565),Ba=i.n(Ua),Wa=i(19216),za=i.n(Wa),Ya=i(44589),Va=i.n(Ya),qa=i(16721),Ga={};Ga.styleTagTransform=Va(),Ga.setAttributes=Ba(),Ga.insert=Ha().bind(null,"head"),Ga.domAPI=La(),Ga.insertStyleElement=za();Aa()(qa.Z,Ga);qa.Z&&qa.Z.locals&&qa.Z.locals;var Ka=i(9198),Xa=i.n(Ka),Qa=(Math.pow(10,8),6e4),$a=36e5,Ja=i(13882),ei=i(83946);var ti={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},ni=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,ri=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,oi=/^([+-])(\d{2})(?::?(\d{2}))?$/;function ai(e){var t,n={},r=e.split(ti.dateTimeDelimiter);if(r.length>2)return n;if(/:/.test(r[0])?t=r[0]:(n.date=r[0],t=r[1],ti.timeZoneDelimiter.test(n.date)&&(n.date=e.split(ti.timeZoneDelimiter)[0],t=e.substr(n.date.length,e.length))),t){var o=ti.timezone.exec(t);o?(n.time=t.replace(o[1],""),n.timezone=o[1]):n.time=t}return n}function ii(e,t){var n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:NaN,restDateString:""};var o=r[1]?parseInt(r[1]):null,a=r[2]?parseInt(r[2]):null;return{year:null===a?o:100*a,restDateString:e.slice((r[1]||r[2]).length)}}function ci(e,t){if(null===t)return new Date(NaN);var n=e.match(ni);if(!n)return new Date(NaN);var r=!!n[4],o=ui(n[1]),a=ui(n[2])-1,i=ui(n[3]),c=ui(n[4]),u=ui(n[5])-1;if(r)return function(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}(0,c,u)?function(e,t,n){var r=new Date(0);r.setUTCFullYear(e,0,4);var o=r.getUTCDay()||7,a=7*(t-1)+n+1-o;return r.setUTCDate(r.getUTCDate()+a),r}(t,c,u):new Date(NaN);var s=new Date(0);return function(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(pi[t]||(di(e)?29:28))}(t,a,i)&&function(e,t){return t>=1&&t<=(di(e)?366:365)}(t,o)?(s.setUTCFullYear(t,a,Math.max(o,i)),s):new Date(NaN)}function ui(e){return e?parseInt(e):1}function si(e){var t=e.match(ri);if(!t)return NaN;var n=li(t[1]),r=li(t[2]),o=li(t[3]);return function(e,t,n){if(24===e)return 0===t&&0===n;return n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}(n,r,o)?n*$a+r*Qa+1e3*o:NaN}function li(e){return e&&parseFloat(e.replace(",","."))||0}function fi(e){if("Z"===e)return 0;var t=e.match(oi);if(!t)return 0;var n="+"===t[1]?-1:1,r=parseInt(t[2]),o=t[3]&&parseInt(t[3])||0;return function(e,t){return t>=0&&t<=59}(0,o)?n*(r*$a+o*Qa):NaN}var pi=[31,null,31,30,31,30,31,31,30,31,30,31];function di(e){return e%400==0||e%4==0&&e%100!=0}var hi,mi,vi,gi=V.ZP.div.withConfig({displayName:"StyledDatePickerOuterWrapper"})(hi||(hi=Y()(["\n outline: ",";\n"])),(function(e){return e.immutable?0:"initial"})),yi=V.ZP.div.withConfig({displayName:"StyledDatePickerWrapper"})(mi||(mi=Y()(["\n &&&& {\n ","\n\n & .react-datepicker__input-container {\n & input {\n ","\n width: calc(100% - 5px);\n }\n }\n\n & .react-datepicker {\n & .react-datepicker__today-button {\n ","\n }\n }\n }\n"])),Wn,Yn,(function(e){return e.hasTime&&"border-bottom: 1px solid #aeaeae;"})),bi=V.ZP.input.withConfig({displayName:"StyledTimeInput"})(vi||(vi=Y()(["\n &&&& {\n ","\n }\n"])),Yn),wi=i(37042),Oi=i(4543),xi=i(39880),ki=i(85817),Si=i(39159),Pi=i(19013);function _i(e){(0,Ja.Z)(1,arguments);var t=(0,Pi.Z)(e),n=t.getSeconds();return n}var ji=i(86);function Ei(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ci(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return Ei(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ei(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){c=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(c)throw a}}}}var Di=i(44941),Ti=i(29558);function Mi(e,t){if(null==e)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}var Ri=i(97621),Ii=i(24262),Ni=i(5267);function Ai(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Zi(e,t){return(Zi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function Li(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Zi(e,t)}function Fi(e){return(Fi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function Hi(e,t){if(t&&("object"===(0,ji.Z)(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Ai(e)}function Ui(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Fi(e);if(t){var o=Fi(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Hi(this,n)}}function Bi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Wi(e){var t=function(e,t){if("object"!==(0,ji.Z)(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==(0,ji.Z)(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===(0,ji.Z)(t)?t:String(t)}function zi(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Wi(r.key),r)}}function Yi(e,t,n){return t&&zi(e.prototype,t),n&&zi(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Vi(e,t,n){return(t=Wi(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var qi=function(){function e(){Bi(this,e),Vi(this,"priority",void 0),Vi(this,"subPriority",0)}return Yi(e,[{key:"validate",value:function(e,t){return!0}}]),e}(),Gi=function(e){Li(n,e);var t=Ui(n);function n(e,r,o,a,i){var c;return Bi(this,n),(c=t.call(this)).value=e,c.validateValue=r,c.setValue=o,c.priority=a,i&&(c.subPriority=i),c}return Yi(n,[{key:"validate",value:function(e,t){return this.validateValue(e,this.value,t)}},{key:"set",value:function(e,t,n){return this.setValue(e,t,this.value,n)}}]),n}(qi),Ki=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",10),Vi(Ai(e),"subPriority",-1),e}return Yi(n,[{key:"set",value:function(e,t){if(t.timestampIsSet)return e;var n=new Date(0);return n.setFullYear(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()),n.setHours(e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()),n}}]),n}(qi),Xi=function(){function e(){Bi(this,e),Vi(this,"incompatibleTokens",void 0),Vi(this,"priority",void 0),Vi(this,"subPriority",void 0)}return Yi(e,[{key:"run",value:function(e,t,n,r){var o=this.parse(e,t,n,r);return o?{setter:new Gi(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}},{key:"validate",value:function(e,t,n){return!0}}]),e}(),Qi=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",140),Vi(Ai(e),"incompatibleTokens",["R","u","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"G":case"GG":case"GGG":return n.era(e,{width:"abbreviated"})||n.era(e,{width:"narrow"});case"GGGGG":return n.era(e,{width:"narrow"});case"GGGG":default:return n.era(e,{width:"wide"})||n.era(e,{width:"abbreviated"})||n.era(e,{width:"narrow"})}}},{key:"set",value:function(e,t,n){return t.era=n,e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),$i=/^(1[0-2]|0?\d)/,Ji=/^(3[0-1]|[0-2]?\d)/,ec=/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,tc=/^(5[0-3]|[0-4]?\d)/,nc=/^(2[0-3]|[0-1]?\d)/,rc=/^(2[0-4]|[0-1]?\d)/,oc=/^(1[0-1]|0?\d)/,ac=/^(1[0-2]|0?\d)/,ic=/^[0-5]?\d/,cc=/^[0-5]?\d/,uc=/^\d/,sc=/^\d{1,2}/,lc=/^\d{1,3}/,fc=/^\d{1,4}/,pc=/^-?\d+/,dc=/^-?\d/,hc=/^-?\d{1,2}/,mc=/^-?\d{1,3}/,vc=/^-?\d{1,4}/,gc=/^([+-])(\d{2})(\d{2})?|Z/,yc=/^([+-])(\d{2})(\d{2})|Z/,bc=/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,wc=/^([+-])(\d{2}):(\d{2})|Z/,Oc=/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/;function xc(e,t){return e?{value:t(e.value),rest:e.rest}:e}function kc(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function Sc(e,t){var n=t.match(e);if(!n)return null;if("Z"===n[0])return{value:0,rest:t.slice(1)};var r="+"===n[1]?1:-1,o=n[2]?parseInt(n[2],10):0,a=n[3]?parseInt(n[3],10):0,i=n[5]?parseInt(n[5],10):0;return{value:r*(o*$a+a*Qa+1e3*i),rest:t.slice(n[0].length)}}function Pc(e){return kc(pc,e)}function _c(e,t){switch(e){case 1:return kc(uc,t);case 2:return kc(sc,t);case 3:return kc(lc,t);case 4:return kc(fc,t);default:return kc(new RegExp("^\\d{1,"+e+"}"),t)}}function jc(e,t){switch(e){case 1:return kc(dc,t);case 2:return kc(hc,t);case 3:return kc(mc,t);case 4:return kc(vc,t);default:return kc(new RegExp("^-?\\d{1,"+e+"}"),t)}}function Ec(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function Cc(e,t){var n,r=t>0,o=r?t:1-t;if(o<=50)n=e||100;else{var a=o+50;n=e+100*Math.floor(a/100)-(e>=a%100?100:0)}return r?n:1-n}function Dc(e){return e%400==0||e%4==0&&e%100!=0}var Tc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",130),Vi(Ai(e),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return{year:e,isTwoDigitYear:"yy"===t}};switch(t){case"y":return xc(_c(4,e),r);case"yo":return xc(n.ordinalNumber(e,{unit:"year"}),r);default:return xc(_c(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,n){var r=e.getUTCFullYear();if(n.isTwoDigitYear){var o=Cc(n.year,r);return e.setUTCFullYear(o,0,1),e.setUTCHours(0,0,0,0),e}var a="era"in t&&1!==t.era?1-n.year:n.year;return e.setUTCFullYear(a,0,1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Mc=i(7651),Rc=i(59025),Ic=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",130),Vi(Ai(e),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return{year:e,isTwoDigitYear:"YY"===t}};switch(t){case"Y":return xc(_c(4,e),r);case"Yo":return xc(n.ordinalNumber(e,{unit:"year"}),r);default:return xc(_c(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,n,r){var o=(0,Mc.Z)(e,r);if(n.isTwoDigitYear){var a=Cc(n.year,o);return e.setUTCFullYear(a,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,Rc.Z)(e,r)}var i="era"in t&&1!==t.era?1-n.year:n.year;return e.setUTCFullYear(i,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,Rc.Z)(e,r)}}]),n}(Xi),Nc=i(66979),Ac=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",130),Vi(Ai(e),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t){return jc("R"===t?4:t.length,e)}},{key:"set",value:function(e,t,n){var r=new Date(0);return r.setUTCFullYear(n,0,4),r.setUTCHours(0,0,0,0),(0,Nc.Z)(r)}}]),n}(Xi),Zc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",130),Vi(Ai(e),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t){return jc("u"===t?4:t.length,e)}},{key:"set",value:function(e,t,n){return e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Lc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",120),Vi(Ai(e),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"Q":case"QQ":return _c(t.length,e);case"Qo":return n.ordinalNumber(e,{unit:"quarter"});case"QQQ":return n.quarter(e,{width:"abbreviated",context:"formatting"})||n.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return n.quarter(e,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(e,{width:"wide",context:"formatting"})||n.quarter(e,{width:"abbreviated",context:"formatting"})||n.quarter(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,n){return e.setUTCMonth(3*(n-1),1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Fc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",120),Vi(Ai(e),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"q":case"qq":return _c(t.length,e);case"qo":return n.ordinalNumber(e,{unit:"quarter"});case"qqq":return n.quarter(e,{width:"abbreviated",context:"standalone"})||n.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return n.quarter(e,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(e,{width:"wide",context:"standalone"})||n.quarter(e,{width:"abbreviated",context:"standalone"})||n.quarter(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,n){return e.setUTCMonth(3*(n-1),1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Hc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),Vi(Ai(e),"priority",110),e}return Yi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return e-1};switch(t){case"M":return xc(kc($i,e),r);case"MM":return xc(_c(2,e),r);case"Mo":return xc(n.ordinalNumber(e,{unit:"month"}),r);case"MMM":return n.month(e,{width:"abbreviated",context:"formatting"})||n.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return n.month(e,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(e,{width:"wide",context:"formatting"})||n.month(e,{width:"abbreviated",context:"formatting"})||n.month(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.setUTCMonth(n,1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Uc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",110),Vi(Ai(e),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return e-1};switch(t){case"L":return xc(kc($i,e),r);case"LL":return xc(_c(2,e),r);case"Lo":return xc(n.ordinalNumber(e,{unit:"month"}),r);case"LLL":return n.month(e,{width:"abbreviated",context:"standalone"})||n.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return n.month(e,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(e,{width:"wide",context:"standalone"})||n.month(e,{width:"abbreviated",context:"standalone"})||n.month(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.setUTCMonth(n,1),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Bc=i(23324);var Wc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",100),Vi(Ai(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"w":return kc(tc,e);case"wo":return n.ordinalNumber(e,{unit:"week"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,n,r){return(0,Rc.Z)(function(e,t,n){(0,Ja.Z)(2,arguments);var r=(0,Pi.Z)(e),o=(0,ei.Z)(t),a=(0,Bc.Z)(r,n)-o;return r.setUTCDate(r.getUTCDate()-7*a),r}(e,n,r),r)}}]),n}(Xi),zc=i(49702);var Yc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",100),Vi(Ai(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"I":return kc(tc,e);case"Io":return n.ordinalNumber(e,{unit:"week"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,n){return(0,Nc.Z)(function(e,t){(0,Ja.Z)(2,arguments);var n=(0,Pi.Z)(e),r=(0,ei.Z)(t),o=(0,zc.Z)(n)-r;return n.setUTCDate(n.getUTCDate()-7*o),n}(e,n))}}]),n}(Xi),Vc=[31,28,31,30,31,30,31,31,30,31,30,31],qc=[31,29,31,30,31,30,31,31,30,31,30,31],Gc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",90),Vi(Ai(e),"subPriority",1),Vi(Ai(e),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"d":return kc(Ji,e);case"do":return n.ordinalNumber(e,{unit:"date"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){var n=Dc(e.getUTCFullYear()),r=e.getUTCMonth();return n?t>=1&&t<=qc[r]:t>=1&&t<=Vc[r]}},{key:"set",value:function(e,t,n){return e.setUTCDate(n),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Kc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",90),Vi(Ai(e),"subpriority",1),Vi(Ai(e),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"D":case"DD":return kc(ec,e);case"Do":return n.ordinalNumber(e,{unit:"date"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return Dc(e.getUTCFullYear())?t>=1&&t<=366:t>=1&&t<=365}},{key:"set",value:function(e,t,n){return e.setUTCMonth(0,n),e.setUTCHours(0,0,0,0),e}}]),n}(Xi),Xc=i(84314);function Qc(e,t,n){var r,o,a,i,c,u,s,l;(0,Ja.Z)(2,arguments);var f=(0,Xc.j)(),p=(0,ei.Z)(null!==(r=null!==(o=null!==(a=null!==(i=null==n?void 0:n.weekStartsOn)&&void 0!==i?i:null==n||null===(c=n.locale)||void 0===c||null===(u=c.options)||void 0===u?void 0:u.weekStartsOn)&&void 0!==a?a:f.weekStartsOn)&&void 0!==o?o:null===(s=f.locale)||void 0===s||null===(l=s.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==r?r:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var d=(0,Pi.Z)(e),h=(0,ei.Z)(t),m=d.getUTCDay(),v=h%7,g=(v+7)%7,y=(g<p?7:0)+h-m;return d.setUTCDate(d.getUTCDate()+y),d}var $c=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",90),Vi(Ai(e),"incompatibleTokens",["D","i","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"E":case"EE":case"EEE":return n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return n.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"EEEE":default:return n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return(e=Qc(e,n,r)).setUTCHours(0,0,0,0),e}}]),n}(Xi),Jc=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",90),Vi(Ai(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n,r){var o=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"e":case"ee":return xc(_c(t.length,e),o);case"eo":return xc(n.ordinalNumber(e,{unit:"day"}),o);case"eee":return n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"eeeee":return n.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"eeee":default:return n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return(e=Qc(e,n,r)).setUTCHours(0,0,0,0),e}}]),n}(Xi),eu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",90),Vi(Ai(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n,r){var o=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"c":case"cc":return xc(_c(t.length,e),o);case"co":return xc(n.ordinalNumber(e,{unit:"day"}),o);case"ccc":return n.day(e,{width:"abbreviated",context:"standalone"})||n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"});case"ccccc":return n.day(e,{width:"narrow",context:"standalone"});case"cccccc":return n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"});case"cccc":default:return n.day(e,{width:"wide",context:"standalone"})||n.day(e,{width:"abbreviated",context:"standalone"})||n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return(e=Qc(e,n,r)).setUTCHours(0,0,0,0),e}}]),n}(Xi);var tu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",90),Vi(Ai(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return 0===e?7:e};switch(t){case"i":case"ii":return _c(t.length,e);case"io":return n.ordinalNumber(e,{unit:"day"});case"iii":return xc(n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r);case"iiiii":return xc(n.day(e,{width:"narrow",context:"formatting"}),r);case"iiiiii":return xc(n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r);case"iiii":default:return xc(n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r)}}},{key:"validate",value:function(e,t){return t>=1&&t<=7}},{key:"set",value:function(e,t,n){return(e=function(e,t){(0,Ja.Z)(2,arguments);var n=(0,ei.Z)(t);n%7==0&&(n-=7);var r=1,o=(0,Pi.Z)(e),a=o.getUTCDay(),i=((n%7+7)%7<r?7:0)+n-a;return o.setUTCDate(o.getUTCDate()+i),o}(e,n)).setUTCHours(0,0,0,0),e}}]),n}(Xi),nu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",80),Vi(Ai(e),"incompatibleTokens",["b","B","H","k","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"a":case"aa":case"aaa":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaaa":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(Ec(n),0,0,0),e}}]),n}(Xi),ru=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",80),Vi(Ai(e),"incompatibleTokens",["a","B","H","k","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"b":case"bb":case"bbb":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbbb":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(Ec(n),0,0,0),e}}]),n}(Xi),ou=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",80),Vi(Ai(e),"incompatibleTokens",["a","b","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"B":case"BB":case"BBB":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBBB":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(Ec(n),0,0,0),e}}]),n}(Xi),au=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",70),Vi(Ai(e),"incompatibleTokens",["H","K","k","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"h":return kc(ac,e);case"ho":return n.ordinalNumber(e,{unit:"hour"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=12}},{key:"set",value:function(e,t,n){var r=e.getUTCHours()>=12;return r&&n<12?e.setUTCHours(n+12,0,0,0):r||12!==n?e.setUTCHours(n,0,0,0):e.setUTCHours(0,0,0,0),e}}]),n}(Xi),iu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",70),Vi(Ai(e),"incompatibleTokens",["a","b","h","K","k","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"H":return kc(nc,e);case"Ho":return n.ordinalNumber(e,{unit:"hour"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=23}},{key:"set",value:function(e,t,n){return e.setUTCHours(n,0,0,0),e}}]),n}(Xi),cu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",70),Vi(Ai(e),"incompatibleTokens",["h","H","k","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"K":return kc(oc,e);case"Ko":return n.ordinalNumber(e,{unit:"hour"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.getUTCHours()>=12&&n<12?e.setUTCHours(n+12,0,0,0):e.setUTCHours(n,0,0,0),e}}]),n}(Xi),uu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",70),Vi(Ai(e),"incompatibleTokens",["a","b","h","H","K","t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"k":return kc(rc,e);case"ko":return n.ordinalNumber(e,{unit:"hour"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=24}},{key:"set",value:function(e,t,n){var r=n<=24?n%24:n;return e.setUTCHours(r,0,0,0),e}}]),n}(Xi),su=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",60),Vi(Ai(e),"incompatibleTokens",["t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"m":return kc(ic,e);case"mo":return n.ordinalNumber(e,{unit:"minute"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,n){return e.setUTCMinutes(n,0,0),e}}]),n}(Xi),lu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",50),Vi(Ai(e),"incompatibleTokens",["t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t,n){switch(t){case"s":return kc(cc,e);case"so":return n.ordinalNumber(e,{unit:"second"});default:return _c(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,n){return e.setUTCSeconds(n,0),e}}]),n}(Xi),fu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",30),Vi(Ai(e),"incompatibleTokens",["t","T"]),e}return Yi(n,[{key:"parse",value:function(e,t){return xc(_c(t.length,e),(function(e){return Math.floor(e*Math.pow(10,3-t.length))}))}},{key:"set",value:function(e,t,n){return e.setUTCMilliseconds(n),e}}]),n}(Xi),pu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",10),Vi(Ai(e),"incompatibleTokens",["t","T","x"]),e}return Yi(n,[{key:"parse",value:function(e,t){switch(t){case"X":return Sc(gc,e);case"XX":return Sc(yc,e);case"XXXX":return Sc(bc,e);case"XXXXX":return Sc(Oc,e);case"XXX":default:return Sc(wc,e)}}},{key:"set",value:function(e,t,n){return t.timestampIsSet?e:new Date(e.getTime()-n)}}]),n}(Xi),du=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",10),Vi(Ai(e),"incompatibleTokens",["t","T","X"]),e}return Yi(n,[{key:"parse",value:function(e,t){switch(t){case"x":return Sc(gc,e);case"xx":return Sc(yc,e);case"xxxx":return Sc(bc,e);case"xxxxx":return Sc(Oc,e);case"xxx":default:return Sc(wc,e)}}},{key:"set",value:function(e,t,n){return t.timestampIsSet?e:new Date(e.getTime()-n)}}]),n}(Xi),hu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",40),Vi(Ai(e),"incompatibleTokens","*"),e}return Yi(n,[{key:"parse",value:function(e){return Pc(e)}},{key:"set",value:function(e,t,n){return[new Date(1e3*n),{timestampIsSet:!0}]}}]),n}(Xi),mu=function(e){Li(n,e);var t=Ui(n);function n(){var e;Bi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Vi(Ai(e=t.call.apply(t,[this].concat(o))),"priority",20),Vi(Ai(e),"incompatibleTokens","*"),e}return Yi(n,[{key:"parse",value:function(e){return Pc(e)}},{key:"set",value:function(e,t,n){return[new Date(n),{timestampIsSet:!0}]}}]),n}(Xi),vu={G:new Qi,y:new Tc,Y:new Ic,R:new Ac,u:new Zc,Q:new Lc,q:new Fc,M:new Hc,L:new Uc,w:new Wc,I:new Yc,d:new Gc,D:new Kc,E:new $c,e:new Jc,c:new eu,i:new tu,a:new nu,b:new ru,B:new ou,h:new au,H:new iu,K:new cu,k:new uu,m:new su,s:new lu,S:new fu,X:new pu,x:new du,t:new hu,T:new mu},gu=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,yu=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,bu=/^'([^]*?)'?$/,wu=/''/g,Ou=/\S/,xu=/[a-zA-Z]/;function ku(e,t,n,r){var o,a,i,c,u,s,l,f,p,d,h,m,v,g,y,b,w,O;(0,Ja.Z)(3,arguments);var x=String(e),k=String(t),S=(0,Xc.j)(),P=null!==(o=null!==(a=null==r?void 0:r.locale)&&void 0!==a?a:S.locale)&&void 0!==o?o:Di.Z;if(!P.match)throw new RangeError("locale must contain match property");var _=(0,ei.Z)(null!==(i=null!==(c=null!==(u=null!==(s=null==r?void 0:r.firstWeekContainsDate)&&void 0!==s?s:null==r||null===(l=r.locale)||void 0===l||null===(f=l.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==u?u:S.firstWeekContainsDate)&&void 0!==c?c:null===(p=S.locale)||void 0===p||null===(d=p.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==i?i:1);if(!(_>=1&&_<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var j=(0,ei.Z)(null!==(h=null!==(m=null!==(v=null!==(g=null==r?void 0:r.weekStartsOn)&&void 0!==g?g:null==r||null===(y=r.locale)||void 0===y||null===(b=y.options)||void 0===b?void 0:b.weekStartsOn)&&void 0!==v?v:S.weekStartsOn)&&void 0!==m?m:null===(w=S.locale)||void 0===w||null===(O=w.options)||void 0===O?void 0:O.weekStartsOn)&&void 0!==h?h:0);if(!(j>=0&&j<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(""===k)return""===x?(0,Pi.Z)(n):new Date(NaN);var E,C={firstWeekContainsDate:_,weekStartsOn:j,locale:P},D=[new Ki],T=k.match(yu).map((function(e){var t=e[0];return t in Ri.Z?(0,Ri.Z[t])(e,P.formatLong):e})).join("").match(gu),M=[],R=Ci(T);try{var I=function(){var t=E.value;null!=r&&r.useAdditionalWeekYearTokens||!(0,Ni.Do)(t)||(0,Ni.qp)(t,k,e),null!=r&&r.useAdditionalDayOfYearTokens||!(0,Ni.Iu)(t)||(0,Ni.qp)(t,k,e);var n=t[0],o=vu[n];if(o){var a=o.incompatibleTokens;if(Array.isArray(a)){var i=M.find((function(e){return a.includes(e.token)||e.token===n}));if(i)throw new RangeError("The format string mustn't contain `".concat(i.fullToken,"` and `").concat(t,"` at the same time"))}else if("*"===o.incompatibleTokens&&M.length>0)throw new RangeError("The format string mustn't contain `".concat(t,"` and any other token at the same time"));M.push({token:n,fullToken:t});var c=o.run(x,t,P.match,C);if(!c)return{v:new Date(NaN)};D.push(c.setter),x=c.rest}else{if(n.match(xu))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");if("''"===t?t="'":"'"===n&&(t=Su(t)),0!==x.indexOf(t))return{v:new Date(NaN)};x=x.slice(t.length)}};for(R.s();!(E=R.n()).done;){var N=I();if("object"===(0,ji.Z)(N))return N.v}}catch(e){R.e(e)}finally{R.f()}if(x.length>0&&Ou.test(x))return new Date(NaN);var A=D.map((function(e){return e.priority})).sort((function(e,t){return t-e})).filter((function(e,t,n){return n.indexOf(e)===t})).map((function(e){return D.filter((function(t){return t.priority===e})).sort((function(e,t){return t.subPriority-e.subPriority}))})).map((function(e){return e[0]})),Z=(0,Pi.Z)(n);if(isNaN(Z.getTime()))return new Date(NaN);var L,F=(0,Ti.Z)(Z,(0,Ii.Z)(Z)),H={},U=Ci(A);try{for(U.s();!(L=U.n()).done;){var B=L.value;if(!B.validate(F,C))return new Date(NaN);var W=B.set(F,H,C);Array.isArray(W)?(F=W[0],Mi(H,W[1])):F=W}}catch(e){U.e(e)}finally{U.f()}return F}function Su(e){return e.match(bu)[1].replace(wu,"'")}var Pu=i(49599);function _u(e,t,n){return(0,Ja.Z)(2,arguments),(0,Pu.Z)(ku(e,t,new Date,n))}var ju="react-datepicker-time__input",Eu="react-datepicker__day",Cu="react-datepicker__input",Du=function(e){return e.classList.contains(Eu)},Tu=function(e){return e.classList.contains(ju)},Mu=function(e){return e.classList.contains(Cu)},Ru=function(e,t){var n=t.hour,r=void 0===n?0:n,o=t.minute,a=void 0===o?0:o,i=t.second,c=void 0===i?0:i;return(0,wi.Z)((0,Oi.Z)((0,xi.Z)(e,c),a),r)},Iu=function(e){setTimeout((function(){if(e){var t=e.querySelector(".".concat(Eu,'[tabindex="0"]'));t&&t.focus({preventScroll:!0})}}),0)},Nu=function(e){setTimeout((function(){e&&e.focus({preventScroll:!0})}),0)},Au=function(e){var t=function(e,t){var n;(0,Ja.Z)(1,arguments);var r=(0,ei.Z)(null!==(n=null==t?void 0:t.additionalDigits)&&void 0!==n?n:2);if(2!==r&&1!==r&&0!==r)throw new RangeError("additionalDigits must be 0, 1 or 2");if("string"!=typeof e&&"[object String]"!==Object.prototype.toString.call(e))return new Date(NaN);var o,a=ai(e);if(a.date){var i=ii(a.date,r);o=ci(i.restDateString,i.year)}if(!o||isNaN(o.getTime()))return new Date(NaN);var c,u=o.getTime(),s=0;if(a.time&&(s=si(a.time),isNaN(s)))return new Date(NaN);if(!a.timezone){var l=new Date(u+s),f=new Date(0);return f.setFullYear(l.getUTCFullYear(),l.getUTCMonth(),l.getUTCDate()),f.setHours(l.getUTCHours(),l.getUTCMinutes(),l.getUTCSeconds(),l.getUTCMilliseconds()),f}return c=fi(a.timezone),isNaN(c)?new Date(NaN):new Date(u+s+c)}(e);return isNaN(t)?null:t},Zu=function(e){return e?e.toISOString():null};const Lu=function(e,t,n){var r=n.dateFormats,o=void 0===r?[]:r,a=n.minDate,i=n.maxDate,c=n.hasTime,u=n.valueToDate,s=void 0===u?Au:u,l=n.dateToValue,f=void 0===l?Zu:l,p=(0,A.useRef)(null),d=(0,A.useState)(!1),h=We()(d,2),m=h[0],v=h[1],g=(0,A.useState)(!1),y=We()(g,2),b=y[0],w=y[1],O=s(e),x=a?s(a):void 0,k=i?s(i):void 0;(0,A.useEffect)((function(){(p.current&&"function"==typeof p.current.setOpen&&p.current.setOpen(m),m)&&document.querySelectorAll("button.react-datepicker__navigation").forEach((function(e){return e.setAttribute("tabindex","-1")}))}),[m]);var S=function(){return v(!1)},P=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(p.current&&"function"==typeof p.current.getPreSelection){var t,n=e?p.current.getPreSelection():null;return(null===(t=p.current.state)||void 0===t?void 0:t.preSelection)||n}return null},_=function(e){p.current&&"function"==typeof p.current.setPreSelection&&p.current.setPreSelection(e)},j=function(){t(null),_(null)},E=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=P(!1);if(n){var r=O||new Date,o=t?Ru(n,{hour:(0,ki.Z)(r),minute:(0,Si.Z)(r),second:_i(r)}):n;C(o,e)}},C=function(n,r){if(n){var a,i=!e&&Boolean(n),u=null==r||null===(a=r.target)||void 0===a?void 0:a.value,s=!!u&&o.some((function(e){return _u(u,e)})),l=function(e){(0,Ja.Z)(1,arguments);var t=(0,Pi.Z)(e);return t.setHours(0,0,0,0),t}(n),d=(0,ki.Z)(n)!==(0,ki.Z)(l)||(0,Si.Z)(n)!==(0,Si.Z)(l);(i&&!d||s)&&c&&(n=Ia.Z.setCurrentTime(n)),t(f(n))}else j();var h;c||"click"!==(null==r?void 0:r.type)||(S(),Nu(null===(h=p.current)||void 0===h?void 0:h.input))},D=function(e){if("Tab"===e.key)if(e.shiftKey)if(Mu(e.target))setTimeout((function(){return S()}),0);else if(Tu(e.target)){var t,n;_(O||P(!0)),Iu(null===(t=p.current)||void 0===t||null===(n=t.calendar)||void 0===n?void 0:n.componentNode)}else Du(e.target)&&S();else Mu(e.target)&&m?(E(e),setTimeout((function(){return S()}),0)):Tu(e.target)?S():Du(e.target)&&(c?(E(e,!0),_(null),w(!0),setTimeout((function(){var e,t,n;n=null===(e=p.current)||void 0===e||null===(t=e.calendar)||void 0===t?void 0:t.componentNode,setTimeout((function(){if(n){var e=n.querySelector("input.".concat(ju));e&&e.focus({preventScroll:!0})}}),0),w(!1)}),0)):(E(e),S()));var r;"Enter"===e.key&&(S(),e.preventDefault(),e.stopPropagation(),Nu(null===(r=p.current)||void 0===r?void 0:r.input));if(["ArrowDown","ArrowUp","Enter"].includes(e.key))if(m){if(m&&null===P(!1)){var o,a;_(O||P(!0)),Iu(null===(o=p.current)||void 0===o||null===(a=o.calendar)||void 0===a?void 0:a.componentNode)}}else v(!0),e.key="Handled".concat(e.key)},T=function(){var e;v((function(e){return!e})),_(null),Nu(null===(e=p.current)||void 0===e?void 0:e.input)};return{reactDatePickerProps:{closeOnScroll:function(){return S(),!0},onClickOutside:S,onInputClick:T,onKeyDown:D,onChange:C,onCalendarOpen:function(){_(null)},onBlur:function(){p.current&&p.current.setState({inputValue:null})},preventOpenOnFocus:!0,enableTabLoop:!1,shouldCloseOnSelect:!1,open:m,selected:O,showTimeInput:c,minDate:x,maxDate:k,ref:p,className:Cu},timeInputProps:{onKeyDown:D,className:ju,tabIndex:b?void 0:"-1"},clearButtonProps:{onMouseDown:function(e){e.preventDefault(),j()}},calendarButtonProps:{onClick:T,className:m?"react-datepicker-ignore-onclickoutside":""}}};var Fu=i(49546),Hu=i(35997),Uu="HH:mm:ss",Bu="HH:mm",Wu=function(e){return _u(e,Bu)},zu=function(e){var t=function(e){return _u(e,Uu)?ku(e,Uu,new Date):_u(e,Bu)?ku(e,Bu,new Date):_u(e,"HH:")?ku(e,"HH:",new Date):_u(e,"H")?ku(e,"H",new Date):null}(e);return t&&!isNaN(t)?function(e){return(0,Fu.Z)(e,Bu)}(t):""};const Yu=function(e,t){var n=zu(e),r=(0,A.useState)(n),o=We()(r,2),a=o[0],i=o[1],c=(0,A.useRef)(a),u=Hu.Z.usePrevious(n);(0,A.useEffect)((function(){u!==n&&a===u&&i(n)}),[n,a,u]);return{inputProps:{onChange:function(e){if(e.target.value!==a&&function(e){return/^(\d{0,2}|\d{1,2}:\d{0,2})$/.test(e)}(e.target.value)){var n=function(e,t){return e&&t?2!==e.length||3===t.length||e.includes(":")?e.length+1===t.length&&t.indexOf(":")===t.length-1?e.slice(0,-1):e:"".concat(e,":"):e}(e.target.value,c.current),r=n.indexOf(":"),o=n.substring(0,r),u=n.substring(r+1),s=parseInt(o,10),l=parseInt(u,10),f=!o||!Number.isNaN(s)&&s<24,p=!u||!Number.isNaN(l)&&l<60;if(!f||!p)return!1;c.current=n,i(n),n&&!Wu(n)||t(n)}},onBlur:function(){if(a!==n){var e=zu(a);e&&Wu(e)?(c.current=e,i(e),t(e)):i(n)}},onFocus:function(e){a&&"function"==typeof e.target.select&&e.target.select()},value:a||""},clearButtonProps:{onClick:function(){t(""),i("")}}}};var Vu=["value","onChange","onKeyDown"];function qu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Gu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qu(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qu(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}(0,Ka.registerLocale)("en",Ia.Z.getDateFnsLocale("en")),(0,Ka.registerLocale)("en-US",Ia.Z.getDateFnsLocale("en")),(0,Ka.registerLocale)("de-CH",Ia.Z.getDateFnsLocale("de-CH")),(0,Ka.registerLocale)("de",Ia.Z.getDateFnsLocale("de")),(0,Ka.registerLocale)("fr",Ia.Z.getDateFnsLocale("fr")),(0,Ka.registerLocale)("fr-CH",Ia.Z.getDateFnsLocale("fr")),(0,Ka.registerLocale)("it",Ia.Z.getDateFnsLocale("it")),(0,Ka.registerLocale)("it-CH",Ia.Z.getDateFnsLocale("it")),(0,Ka.setDefaultLocale)("de");var Ku=function(e){var t=e.onChange,n=e.label;return(0,ee.jsx)(W.Z,{onMouseDown:function(e){e.preventDefault(),t(null)},tabIndex:-1,children:n})},Xu=function(e){var t=e.value,n=e.onChange,r=e.onKeyDown,o=Ve()(e,Vu),a=Yu(t,(function(e){n&&n(e||"00:00")})).inputProps;return(0,ee.jsx)(bi,Gu(Gu(Gu({},a),o),{},{type:"text",onKeyDown:r,onClick:function(e){e.target.focus()}}))},Qu={strategy:"fixed"};const $u=(0,V.Zz)((0,v.ZP)((function(e){var t=e.immutable,n=e.id,r=e.value,o=e.minDate,a=e.maxDate,i=e.valueToDate,c=e.dateToValue,u=e.onChange,s=e.intl,l=e.placeholder,f=e.hasTime,p=e.dateFormats,d=void 0===p?[]:p,h=e.dateTimeFormats,m=void 0===h?[]:h,v=e.events,g=(0,A.useRef)(void 0),y=s.locale,b=function(e){return s.formatMessage({id:e})},w=(0,A.useRef)(null),O=Boolean(r),x=!t&&O,k=function(e){g.current=e,u(e)},S=Lu(r,k,{dateFormats:d,dateTimeFormats:m,minDate:o,maxDate:a,valueToDate:i,dateToValue:c,hasTime:f}),P=S.reactDatePickerProps,_=S.timeInputProps,j=S.clearButtonProps,E=S.calendarButtonProps;return(0,ee.jsx)(gi,{immutable:t,id:n,tabIndex:"-1",children:(0,ee.jsxs)(yi,{immutable:t,ref:w,hasTime:f,onBlur:function(e){if("function"==typeof(null==v?void 0:v.onBlur)){var t=void 0!==g.current?g.current:r;v.onBlur(t)}e.stopPropagation()},children:[(0,ee.jsx)(Xa(),Gu(Gu({},P),{},{disabled:t,dateFormat:[].concat(st()(m),st()(d)),placeholderText:l,showMonthDropdown:!0,showYearDropdown:!0,scrollableYearDropdown:!1,fixedHeight:!0,showPopperArrow:!1,locale:y,customTimeInput:(0,ee.jsx)(Xu,Gu({},_)),timeInputLabel:"",popperProps:Qu,todayButton:(0,ee.jsx)(Ku,{onChange:k,label:b("client.component.datePicker.todayLabel")})})),x&&(0,ee.jsx)(vo.Z,Gu({icon:"times",tabIndex:-1,"aria-label":b("client.component.datePicker.clearDateLabel")},j)),!t&&(0,ee.jsx)(vo.Z,Gu({icon:"calendar",tabIndex:-1},E))]})})})));function Ju(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const es=function(e){var t=e.onChange,n=e.options,r=e.id,o=e.value,a=e.immutable,i=e.events,c=e.placeholder,u=(0,Ra.Z)(),s=(null==n?void 0:n.datePickerOptions)||{},f="".concat(Ia.Z.getLocalizedDateFormat(u.locale)),p=Ia.Z.getLocalizedDateFormatWithoutPunctuation(u.locale),d=[f,p,Ia.Z.useTwoDigitYear(f),Ia.Z.useTwoDigitYear(p)];return(0,ee.jsx)($u,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ju(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ju(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:r,value:o,onChange:t,dateFormats:d,hasTime:!1,immutable:a,placeholder:c,events:i},s))};function ts(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const ns=(0,v.ZP)((function(e){var t=e.onChange,n=e.options,r=e.value,o=e.immutable,a=e.placeholder,i=(0,Ra.Z)(),c=(null==n?void 0:n.datePickerOptions)||{},u="".concat(Ia.Z.getLocalizedDateTimeFormat(i.locale)),s="".concat(Ia.Z.getLocalizedDateFormat(i.locale)),f=Ia.Z.getLocalizedDateTimeFormatWithoutPunctuation(i.locale),p=[u,f,Ia.Z.useTwoDigitYear(u),Ia.Z.useTwoDigitYear(f)],d=Ia.Z.getLocalizedDateFormatWithoutPunctuation(i.locale),h=[s,d,Ia.Z.useTwoDigitYear(s),Ia.Z.useTwoDigitYear(d)];return(0,ee.jsx)($u,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ts(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ts(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({value:r,onChange:t,dateTimeFormats:p,dateFormats:h,hasTime:!0,immutable:o,placeholder:a},c))}));var rs=i(18446),os=i.n(rs);function as(e,t,n,r){return new(n||(n=Promise))((function(o,a){function i(e){try{u(r.next(e))}catch(e){a(e)}}function c(e){try{u(r.throw(e))}catch(e){a(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,c)}u((r=r.apply(e,t||[])).next())}))}function is(e,t){var n,r,o,a,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function c(c){return function(u){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,c[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&c[0]?r.return:c[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,c[1])).done)return o;switch(r=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,r=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==c[0]&&2!==c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(e,i)}catch(e){c=[6,e],r=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,u])}}}Object.create;function cs(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,a=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=a.next()).done;)i.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=a.return)&&n.call(a)}finally{if(o)throw o.error}}return i}function us(e,t,n){if(n||2===arguments.length)for(var r,o=0,a=t.length;o<a;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}Object.create;var ss=new Map([["aac","audio/aac"],["abw","application/x-abiword"],["arc","application/x-freearc"],["avif","image/avif"],["avi","video/x-msvideo"],["azw","application/vnd.amazon.ebook"],["bin","application/octet-stream"],["bmp","image/bmp"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["cda","application/x-cdf"],["csh","application/x-csh"],["css","text/css"],["csv","text/csv"],["doc","application/msword"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["eot","application/vnd.ms-fontobject"],["epub","application/epub+zip"],["gz","application/gzip"],["gif","image/gif"],["heic","image/heic"],["heif","image/heif"],["htm","text/html"],["html","text/html"],["ico","image/vnd.microsoft.icon"],["ics","text/calendar"],["jar","application/java-archive"],["jpeg","image/jpeg"],["jpg","image/jpeg"],["js","text/javascript"],["json","application/json"],["jsonld","application/ld+json"],["mid","audio/midi"],["midi","audio/midi"],["mjs","text/javascript"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mpeg","video/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["opus","audio/opus"],["otf","font/otf"],["png","image/png"],["pdf","application/pdf"],["php","application/x-httpd-php"],["ppt","application/vnd.ms-powerpoint"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["rar","application/vnd.rar"],["rtf","application/rtf"],["sh","application/x-sh"],["svg","image/svg+xml"],["swf","application/x-shockwave-flash"],["tar","application/x-tar"],["tif","image/tiff"],["tiff","image/tiff"],["ts","video/mp2t"],["ttf","font/ttf"],["txt","text/plain"],["vsd","application/vnd.visio"],["wav","audio/wav"],["weba","audio/webm"],["webm","video/webm"],["webp","image/webp"],["woff","font/woff"],["woff2","font/woff2"],["xhtml","application/xhtml+xml"],["xls","application/vnd.ms-excel"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xml","application/xml"],["xul","application/vnd.mozilla.xul+xml"],["zip","application/zip"],["7z","application/x-7z-compressed"],["mkv","video/x-matroska"],["mov","video/quicktime"],["msg","application/vnd.ms-outlook"]]);function ls(e,t){var n=function(e){var t=e.name;if(t&&-1!==t.lastIndexOf(".")&&!e.type){var n=t.split(".").pop().toLowerCase(),r=ss.get(n);r&&Object.defineProperty(e,"type",{value:r,writable:!1,configurable:!1,enumerable:!0})}return e}(e);if("string"!=typeof n.path){var r=e.webkitRelativePath;Object.defineProperty(n,"path",{value:"string"==typeof t?t:"string"==typeof r&&r.length>0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return n}var fs=[".DS_Store","Thumbs.db"];function ps(e){return"object"==typeof e&&null!==e}function ds(e){return gs(e.target.files).map((function(e){return ls(e)}))}function hs(e){return as(this,void 0,void 0,(function(){return is(this,(function(t){switch(t.label){case 0:return[4,Promise.all(e.map((function(e){return e.getFile()})))];case 1:return[2,t.sent().map((function(e){return ls(e)}))]}}))}))}function ms(e,t){return as(this,void 0,void 0,(function(){var n;return is(this,(function(r){switch(r.label){case 0:return e.items?(n=gs(e.items).filter((function(e){return"file"===e.kind})),"drop"!==t?[2,n]:[4,Promise.all(n.map(ys))]):[3,2];case 1:return[2,vs(bs(r.sent()))];case 2:return[2,vs(gs(e.files).map((function(e){return ls(e)})))]}}))}))}function vs(e){return e.filter((function(e){return-1===fs.indexOf(e.name)}))}function gs(e){if(null===e)return[];for(var t=[],n=0;n<e.length;n++){var r=e[n];t.push(r)}return t}function ys(e){if("function"!=typeof e.webkitGetAsEntry)return ws(e);var t=e.webkitGetAsEntry();return t&&t.isDirectory?xs(t):ws(e)}function bs(e){return e.reduce((function(e,t){return us(us([],cs(e),!1),cs(Array.isArray(t)?bs(t):[t]),!1)}),[])}function ws(e){var t=e.getAsFile();if(!t)return Promise.reject("".concat(e," is not a File"));var n=ls(t);return Promise.resolve(n)}function Os(e){return as(this,void 0,void 0,(function(){return is(this,(function(t){return[2,e.isDirectory?xs(e):ks(e)]}))}))}function xs(e){var t=e.createReader();return new Promise((function(e,n){var r=[];!function o(){var a=this;t.readEntries((function(t){return as(a,void 0,void 0,(function(){var a,i,c;return is(this,(function(u){switch(u.label){case 0:if(t.length)return[3,5];u.label=1;case 1:return u.trys.push([1,3,,4]),[4,Promise.all(r)];case 2:return a=u.sent(),e(a),[3,4];case 3:return i=u.sent(),n(i),[3,4];case 4:return[3,6];case 5:c=Promise.all(t.map(Os)),r.push(c),o(),u.label=6;case 6:return[2]}}))}))}),(function(e){n(e)}))}()}))}function ks(e){return as(this,void 0,void 0,(function(){return is(this,(function(t){return[2,new Promise((function(t,n){e.file((function(n){var r=ls(n,e.fullPath);t(r)}),(function(e){n(e)}))}))]}))}))}var Ss=i(58363);function Ps(e){return function(e){if(Array.isArray(e))return Ts(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Ds(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function js(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_s(Object(n),!0).forEach((function(t){Es(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_s(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Es(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Cs(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==n)return;var r,o,a=[],i=!0,c=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(a.push(r.value),!t||a.length!==t);i=!0);}catch(e){c=!0,o=e}finally{try{i||null==n.return||n.return()}finally{if(c)throw o}}return a}(e,t)||Ds(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ds(e,t){if(e){if("string"==typeof e)return Ts(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ts(e,t):void 0}}function Ts(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Ms="file-invalid-type",Rs="file-too-large",Is="file-too-small",Ns="too-many-files",As=function(e){e=Array.isArray(e)&&1===e.length?e[0]:e;var t=Array.isArray(e)?"one of ".concat(e.join(", ")):e;return{code:Ms,message:"File type must be ".concat(t)}},Zs=function(e){return{code:Rs,message:"File is larger than ".concat(e," ").concat(1===e?"byte":"bytes")}},Ls=function(e){return{code:Is,message:"File is smaller than ".concat(e," ").concat(1===e?"byte":"bytes")}},Fs={code:Ns,message:"Too many files"};function Hs(e,t){var n="application/x-moz-file"===e.type||(0,Ss.Z)(e,t);return[n,n?null:As(t)]}function Us(e,t,n){if(Bs(e.size))if(Bs(t)&&Bs(n)){if(e.size>n)return[!1,Zs(n)];if(e.size<t)return[!1,Ls(t)]}else{if(Bs(t)&&e.size<t)return[!1,Ls(t)];if(Bs(n)&&e.size>n)return[!1,Zs(n)]}return[!0,null]}function Bs(e){return null!=e}function Ws(e){var t=e.files,n=e.accept,r=e.minSize,o=e.maxSize,a=e.multiple,i=e.maxFiles,c=e.validator;return!(!a&&t.length>1||a&&i>=1&&t.length>i)&&t.every((function(e){var t=Cs(Hs(e,n),1)[0],a=Cs(Us(e,r,o),1)[0],i=c?c(e):null;return t&&a&&!i}))}function zs(e){return"function"==typeof e.isPropagationStopped?e.isPropagationStopped():void 0!==e.cancelBubble&&e.cancelBubble}function Ys(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,(function(e){return"Files"===e||"application/x-moz-file"===e})):!!e.target&&!!e.target.files}function Vs(e){e.preventDefault()}function qs(e){return-1!==e.indexOf("MSIE")||-1!==e.indexOf("Trident/")}function Gs(e){return-1!==e.indexOf("Edge/")}function Ks(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.navigator.userAgent;return qs(e)||Gs(e)}function Xs(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return t.some((function(t){return!zs(e)&&t&&t.apply(void 0,[e].concat(r)),zs(e)}))}}function Qs(){return"showOpenFilePicker"in window}function $s(e){return Bs(e)?[{description:"Files",accept:Object.entries(e).filter((function(e){var t=Cs(e,2),n=t[0],r=t[1],o=!0;return nl(n)||(console.warn('Skipped "'.concat(n,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),Array.isArray(r)&&r.every(rl)||(console.warn('Skipped "'.concat(n,'" because an invalid file extension was provided.')),o=!1),o})).reduce((function(e,t){var n=Cs(t,2),r=n[0],o=n[1];return js(js({},e),{},Es({},r,o))}),{})}]:e}function Js(e){if(Bs(e))return Object.entries(e).reduce((function(e,t){var n=Cs(t,2),r=n[0],o=n[1];return[].concat(Ps(e),[r],Ps(o))}),[]).filter((function(e){return nl(e)||rl(e)})).join(",")}function el(e){return e instanceof DOMException&&("AbortError"===e.name||e.code===e.ABORT_ERR)}function tl(e){return e instanceof DOMException&&("SecurityError"===e.name||e.code===e.SECURITY_ERR)}function nl(e){return"audio/*"===e||"video/*"===e||"image/*"===e||"text/*"===e||/\w+\/[-+.\w]+/g.test(e)}function rl(e){return/^.*\.[\w]+$/.test(e)}var ol=["children"],al=["open"],il=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],cl=["refKey","onChange","onClick"];function ul(e){return function(e){if(Array.isArray(e))return fl(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||ll(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function sl(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==n)return;var r,o,a=[],i=!0,c=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(a.push(r.value),!t||a.length!==t);i=!0);}catch(e){c=!0,o=e}finally{try{i||null==n.return||n.return()}finally{if(c)throw o}}return a}(e,t)||ll(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ll(e,t){if(e){if("string"==typeof e)return fl(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?fl(e,t):void 0}}function fl(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function pl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function dl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?pl(Object(n),!0).forEach((function(t){hl(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):pl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function hl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ml(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var vl=(0,A.forwardRef)((function(e,t){var n=e.children,r=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=dl(dl({},gl),e),n=t.accept,r=t.disabled,o=t.getFilesFromEvent,a=t.maxSize,i=t.minSize,c=t.multiple,u=t.maxFiles,s=t.onDragEnter,l=t.onDragLeave,f=t.onDragOver,p=t.onDrop,d=t.onDropAccepted,h=t.onDropRejected,m=t.onFileDialogCancel,v=t.onFileDialogOpen,g=t.useFsAccessApi,y=t.autoFocus,b=t.preventDropOnDocument,w=t.noClick,O=t.noKeyboard,x=t.noDrag,k=t.noDragEventsBubbling,S=t.onError,P=t.validator,_=(0,A.useMemo)((function(){return Js(n)}),[n]),j=(0,A.useMemo)((function(){return $s(n)}),[n]),E=(0,A.useMemo)((function(){return"function"==typeof v?v:Ol}),[v]),C=(0,A.useMemo)((function(){return"function"==typeof m?m:Ol}),[m]),D=(0,A.useRef)(null),T=(0,A.useRef)(null),M=sl((0,A.useReducer)(wl,bl),2),R=M[0],I=M[1],N=R.isFocused,Z=R.isFileDialogActive,L=(0,A.useRef)("undefined"!=typeof window&&window.isSecureContext&&g&&Qs()),F=function(){!L.current&&Z&&setTimeout((function(){T.current&&(T.current.files.length||(I({type:"closeDialog"}),C()))}),300)};(0,A.useEffect)((function(){return window.addEventListener("focus",F,!1),function(){window.removeEventListener("focus",F,!1)}}),[T,Z,C,L]);var H=(0,A.useRef)([]),U=function(e){D.current&&D.current.contains(e.target)||(e.preventDefault(),H.current=[])};(0,A.useEffect)((function(){return b&&(document.addEventListener("dragover",Vs,!1),document.addEventListener("drop",U,!1)),function(){b&&(document.removeEventListener("dragover",Vs),document.removeEventListener("drop",U))}}),[D,b]),(0,A.useEffect)((function(){return!r&&y&&D.current&&D.current.focus(),function(){}}),[D,y,r]);var B=(0,A.useCallback)((function(e){S?S(e):console.error(e)}),[S]),W=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e),H.current=[].concat(ul(H.current),[e.target]),Ys(e)&&Promise.resolve(o(e)).then((function(t){if(!zs(e)||k){var n=t.length,r=n>0&&Ws({files:t,accept:_,minSize:i,maxSize:a,multiple:c,maxFiles:u,validator:P});I({isDragAccept:r,isDragReject:n>0&&!r,isDragActive:!0,type:"setDraggedFiles"}),s&&s(e)}})).catch((function(e){return B(e)}))}),[o,s,B,k,_,i,a,c,u,P]),z=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e);var t=Ys(e);if(t&&e.dataTransfer)try{e.dataTransfer.dropEffect="copy"}catch(e){}return t&&f&&f(e),!1}),[f,k]),Y=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e);var t=H.current.filter((function(e){return D.current&&D.current.contains(e)})),n=t.indexOf(e.target);-1!==n&&t.splice(n,1),H.current=t,t.length>0||(I({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),Ys(e)&&l&&l(e))}),[D,l,k]),V=(0,A.useCallback)((function(e,t){var n=[],r=[];e.forEach((function(e){var t=sl(Hs(e,_),2),o=t[0],c=t[1],u=sl(Us(e,i,a),2),s=u[0],l=u[1],f=P?P(e):null;if(o&&s&&!f)n.push(e);else{var p=[c,l];f&&(p=p.concat(f)),r.push({file:e,errors:p.filter((function(e){return e}))})}})),(!c&&n.length>1||c&&u>=1&&n.length>u)&&(n.forEach((function(e){r.push({file:e,errors:[Fs]})})),n.splice(0)),I({acceptedFiles:n,fileRejections:r,type:"setFiles"}),p&&p(n,r,t),r.length>0&&h&&h(r,t),n.length>0&&d&&d(n,t)}),[I,c,_,i,a,u,p,d,h,P]),q=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e),H.current=[],Ys(e)&&Promise.resolve(o(e)).then((function(t){zs(e)&&!k||V(t,e)})).catch((function(e){return B(e)})),I({type:"reset"})}),[o,V,B,k]),G=(0,A.useCallback)((function(){if(L.current){I({type:"openDialog"}),E();var e={multiple:c,types:j};window.showOpenFilePicker(e).then((function(e){return o(e)})).then((function(e){V(e,null),I({type:"closeDialog"})})).catch((function(e){el(e)?(C(e),I({type:"closeDialog"})):tl(e)?(L.current=!1,T.current?(T.current.value=null,T.current.click()):B(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):B(e)}))}else T.current&&(I({type:"openDialog"}),E(),T.current.value=null,T.current.click())}),[I,E,C,g,V,B,j,c]),K=(0,A.useCallback)((function(e){D.current&&D.current.isEqualNode(e.target)&&(" "!==e.key&&"Enter"!==e.key&&32!==e.keyCode&&13!==e.keyCode||(e.preventDefault(),G()))}),[D,G]),X=(0,A.useCallback)((function(){I({type:"focus"})}),[]),Q=(0,A.useCallback)((function(){I({type:"blur"})}),[]),$=(0,A.useCallback)((function(){w||(Ks()?setTimeout(G,0):G())}),[w,G]),J=function(e){return r?null:e},ee=function(e){return O?null:J(e)},te=function(e){return x?null:J(e)},ne=function(e){k&&e.stopPropagation()},re=(0,A.useMemo)((function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=void 0===t?"ref":t,o=e.role,a=e.onKeyDown,i=e.onFocus,c=e.onBlur,u=e.onClick,s=e.onDragEnter,l=e.onDragOver,f=e.onDragLeave,p=e.onDrop,d=ml(e,il);return dl(dl(hl({onKeyDown:ee(Xs(a,K)),onFocus:ee(Xs(i,X)),onBlur:ee(Xs(c,Q)),onClick:J(Xs(u,$)),onDragEnter:te(Xs(s,W)),onDragOver:te(Xs(l,z)),onDragLeave:te(Xs(f,Y)),onDrop:te(Xs(p,q)),role:"string"==typeof o&&""!==o?o:"presentation"},n,D),r||O?{}:{tabIndex:0}),d)}}),[D,K,X,Q,$,W,z,Y,q,O,x,r]),oe=(0,A.useCallback)((function(e){e.stopPropagation()}),[]),ae=(0,A.useMemo)((function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=void 0===t?"ref":t,r=e.onChange,o=e.onClick,a=ml(e,cl);return dl(dl({},hl({accept:_,multiple:c,type:"file",style:{display:"none"},onChange:J(Xs(r,q)),onClick:J(Xs(o,oe)),tabIndex:-1},n,T)),a)}}),[T,n,c,q,r]);return dl(dl({},R),{},{isFocused:N&&!r,getRootProps:re,getInputProps:ae,rootRef:D,inputRef:T,open:J(G)})}(ml(e,ol)),o=r.open,a=ml(r,al);return(0,A.useImperativeHandle)(t,(function(){return{open:o}}),[o]),Z().createElement(A.Fragment,null,n(dl(dl({},a),{},{open:o})))}));vl.displayName="Dropzone";var gl={disabled:!1,getFilesFromEvent:function(e){return as(this,void 0,void 0,(function(){return is(this,(function(t){return ps(e)&&ps(e.dataTransfer)?[2,ms(e.dataTransfer,e.type)]:function(e){return ps(e)&&ps(e.target)}(e)?[2,ds(e)]:Array.isArray(e)&&e.every((function(e){return"getFile"in e&&"function"==typeof e.getFile}))?[2,hs(e)]:[2,[]]}))}))},maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!0,autoFocus:!1};vl.defaultProps=gl,vl.propTypes={children:p().func,accept:p().objectOf(p().arrayOf(p().string)),multiple:p().bool,preventDropOnDocument:p().bool,noClick:p().bool,noKeyboard:p().bool,noDrag:p().bool,noDragEventsBubbling:p().bool,minSize:p().number,maxSize:p().number,maxFiles:p().number,disabled:p().bool,getFilesFromEvent:p().func,onFileDialogCancel:p().func,onFileDialogOpen:p().func,useFsAccessApi:p().bool,autoFocus:p().bool,onDragEnter:p().func,onDragLeave:p().func,onDragOver:p().func,onDrop:p().func,onDropAccepted:p().func,onDropRejected:p().func,onError:p().func,validator:p().func};const yl=vl;var bl={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function wl(e,t){switch(t.type){case"focus":return dl(dl({},e),{},{isFocused:!0});case"blur":return dl(dl({},e),{},{isFocused:!1});case"openDialog":return dl(dl({},bl),{},{isFileDialogActive:!0});case"closeDialog":return dl(dl({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return dl(dl({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return dl(dl({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections});case"reset":return dl({},bl);default:return e}}function Ol(){}var xl,kl,Sl,Pl,_l,jl,El,Cl,Dl,Tl=i(69829),Ml=V.ZP.section.withConfig({displayName:"StyledSection"})(xl||(xl=Y()(["\n flex: 1;\n display: flex;\n justify-content: flex-end;\n"]))),Rl=V.ZP.div.withConfig({displayName:"StyledButtonsWrapper"})(kl||(kl=Y()(["\n display: flex;\n align-items: center;\n\n "," {\n margin: 0;\n border-radius: 50%;\n padding: ",";\n\n a:hover {\n color: unset;\n }\n }\n"])),G.Z,q.Z.space(-2)),Il=V.ZP.div.withConfig({displayName:"StyledDropzone"})(Sl||(Sl=Y()(["\n width: 100%;\n\n &:hover {\n "," {\n background-color: ",";\n }\n }\n"])),G.Z,X.FS.color("backgroundItemHover")),Nl=V.ZP.div.withConfig({displayName:"StyledUploadInput"})(Pl||(Pl=Y()(["\n ","\n cursor: ",";\n background-color: ",";\n color: ",";\n padding: "," 0 0 0;\n display: flex;\n\n "," {\n float: right;\n position: relative;\n top: -",";\n margin: 0;\n border-radius: 50%;\n padding: ",";\n }\n"])),(0,Ft.Z)(),(function(e){return e.immutable?"not-allowed":"pointer"}),X.FS.color("paper"),(function(e){return e.immutable?Bt.shade2(e):Bt.base(e)}),q.Z.space(-2),G.Z,q.Z.space(-3.1),q.Z.space(-1.5)),Al=V.ZP.div.withConfig({displayName:"StyledUploadProgress"})(_l||(_l=Y()(["\n && {\n padding-top: ",";\n text-align: center;\n display: inline-block;\n }\n"])),q.Z.space(-2)),Zl=(0,V.ZP)(Tl.Fe).withConfig({displayName:"StyledUploadProgressText"})(jl||(jl=Y()(["\n && {\n ","\n }\n"])),(0,Ft.Z)({fontSize:q.Z.font(-1)})),Ll=V.ZP.div.withConfig({displayName:"StyledUploadProgressIconAndText"})(El||(El=Y()(["\n && {\n display: flex;\n justify-content: center;\n align-items: center;\n\n span {\n margin-left: ",";\n }\n }\n"])),q.Z.space(-2)),Fl=V.ZP.div.withConfig({displayName:"StyledView"})(Cl||(Cl=Y()(["\n display: flex;\n justify-content: space-between;\n padding-top: ",";\n"])),q.Z.space(-2));function Hl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ul(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Hl(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Hl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Bl=function(e){var t=e.onDrop,n=e.immutable,r=e.text,o=e.onChoose;return(0,ee.jsxs)(Nl,{immutable:n,children:[(0,ee.jsx)(yl,{onDrop:function(e){var n=e.map((function(e){return Object.assign(e,{preview:URL.createObjectURL(e)})}));t(n[0])},multiple:!1,disabled:n,title:r||"drag and drop or click",children:function(e){var t=e.getRootProps,n=e.getInputProps;return(0,ee.jsx)(Ml,{children:(0,ee.jsxs)(Il,Ul(Ul({},t()),{},{children:[(0,ee.jsx)("input",Ul({},n())),Dl||(Dl=(0,ee.jsx)(W.Z,{icon:"arrow-to-top"}))]}))})}}),o&&(0,ee.jsx)(W.Z,{onClick:function(e){o(),e.stopPropagation()},icon:"folder",label:"browse docs",iconOnly:!0})]})};var Wl=i(73906),zl=function(e){var t=Math.floor(Math.log(e)/Math.log(1024));return"".concat(1*(e/Math.pow(1024,t)).toFixed(2)," ").concat(["Bytes","KB","MB","GB","TB"][t])};const Yl=function(e){var t=e.file,n=e.text;return(0,ee.jsxs)(Al,{children:[(0,ee.jsx)(Wl.Z,{alt:t.name,caption:t.name,maxDimensionX:"96px",maxDimensionY:"96px",srcUrl:t.preview,thumbnailUrl:t.type.startsWith("image")?t.preview:null}),(0,ee.jsxs)(Ll,{children:[(0,ee.jsx)(Bn.Z,{position:ct.Z.position.PREPEND}),(0,ee.jsxs)(Zl,{children:[n||"uploading"," (",zl(t.size),")"]})]})]})};var Vl=i(28247);function ql(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Gl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ql(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ql(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Kl=function(e){var t,n=e.value,r=e.downloadTitle,o=e.immutable,a=e.onUpload,i=e.deleteTitle,c=null===(t=n.binaryLink)||void 0===t?void 0:t.startsWith("blob:");return(0,ee.jsxs)(Fl,{className:"StyledView",children:[(0,ee.jsx)(Wl.Z,Gl(Gl({alt:n.fileName},c&&{caption:n.fileName}),{},{fileName:n.fileName,maxDimensionX:"96px",maxDimensionY:"96px",srcUrl:n.binaryLink,thumbnailUrl:n.thumbnailLink})),(0,ee.jsxs)(Rl,{children:[!o&&(0,ee.jsx)(W.Z,{icon:"trash",onClick:function(){return a(null)},tabIndex:-1,title:i||"delete"}),(0,ee.jsx)(W.Z,{children:(0,ee.jsx)(Un.Z,{neutral:!0,icon:"arrow-to-bottom",target:"_blank",href:Vl.Z.getDownloadUrl(n.binaryLink),tabIndex:-1,title:r||"download"})})]})]})};function Xl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ql(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Xl(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Xl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var $l=function(e){var t=e.value,n=e.textResources,r=e.onUpload,o=e.onChoose,a=(0,A.useRef)(t),i=(0,A.useState)({isUploading:!1,previewFile:null}),c=We()(i,2),u=c[0],s=c[1];return(0,A.useEffect)((function(){os()(a.current,t)||s({isUploading:!1,previewFile:null}),a.current=t}),[t]),null!=t&&t.binaryLink?(0,ee.jsx)(Kl,Ql(Ql({},e),{},{deleteTitle:n.delete,downloadTitle:n.download})):u.isUploading?(0,ee.jsx)(Yl,Ql({file:u.previewFile,text:n.uploading},e)):(0,ee.jsx)(Bl,Ql(Ql({},e),{},{onDrop:function(e){!function(e){s({isUploading:!0,previewFile:e})}(e),r(e)},onChoose:o}))};$l.defaultProps={textResources:{}};const Jl=$l;var ef=function(e){return(0,ee.jsx)(Jl,{onUpload:function(t){null===t?e.onChange&&e.onChange(null):e.options.upload&&e.options.upload(t)},onChoose:e.options.choose,immutable:e.immutable,textResources:{upload:e.options.uploadText,uploading:e.options.uploadingText,delete:e.options.deleteText,download:e.options.downloadText},value:e.value?e.value:null})};ef.defaultProps={options:{}};const tf=ef;var nf,rf,of=function(e){return-1*Math.abs(e)},af=V.ZP.input.withConfig({displayName:"StyledDurationEdit"})(nf||(nf=Y()(["\n &&&& {\n ","\n flex-grow: 0;\n width: ","px;\n min-width: 2.5ch;\n }\n"])),Yn,(function(e){return e.width})),cf=V.ZP.label.withConfig({displayName:"StyledDurationEditFocusable"})(rf||(rf=Y()(["\n &&& {\n align-items: center;\n display: flex;\n flex-wrap: nowrap;\n margin-bottom: 0; /* reset bootstrap */\n margin-left: ",";\n\n &:first-child {\n margin-left: 0;\n }\n\n > span {\n color: ",";\n cursor: ",";\n }\n }\n"])),q.Z.space(1),(function(e){return e.immutable?X.FS.color("textDisabled"):X.FS.color("text")}),(function(e){return e.immutable?"not-allowed":"default"})),uf=function(e){var t=e.value,n=e.immutable,r=e.onChange,o=e.options,a=Ia.Z.millisecondsToDuration(t),i=(0,A.useState)(!1),c=We()(i,2),u=c[0],s=c[1],l=function(e,t){var n,o,i=null!==t?t:a.minutes,c=null!==e?e:a.hours;""!==i||""!==c?(i>=60&&(c=0),r((o=i,(n=c)||o?((n<0||o<0)&&(n=of(n),o=of(o)),60*(n||0)*6e4+6e4*(o||0)):null))):r(null)},f=function(){s(!0)},p=function(e){e.charCode>=48&&e.charCode<=57||45===e.charCode&&!0===o.allowNegative||e.preventDefault()},d=function(){return!0===o.allowNegative?"-?d+":"d+"},h=function(){return u||"number"==typeof t},m=function(e){return 9*(e+"").length},v=n&&Boolean(a.seconds);return(0,ee.jsxs)(zn,{onBlur:function(){s(!1)},immutable:n,children:[(0,ee.jsxs)(cf,{immutable:n,children:[(0,ee.jsx)(af,{disabled:n,immutable:n,min:!0===o.allowNegative?void 0:0,onChange:function(){},onFocus:f,onInput:function(e){var t=e.target.value.replace(/[^-\d]/g,"");l(t,null)},onKeyPress:p,pattern:d(),step:1,width:m(a.hours),type:"number",value:"number"!=typeof a.hours||0===a.hours&&!n?"":a.hours+""}),h()&&(0,ee.jsx)(B.ZP.Span,{children:o.hoursLabel})]}),(0,ee.jsxs)(cf,{immutable:n,children:[(0,ee.jsx)(af,{disabled:n,immutable:n,min:!0!==o.allowNegative||null!==a.hours&&0!==a.hours?0:void 0,onChange:function(){},onFocus:f,onInput:function(e){var t=e.target.value.replace(/[^-\d]/g,"");l(null,t)},onKeyPress:p,pattern:d(),step:1,width:m(a.minutes),type:"number",value:a.minutes+""}),h()&&(0,ee.jsx)(B.ZP.Span,{children:o.minutesLabel})]}),v&&(0,ee.jsxs)(cf,{immutable:n,children:[(0,ee.jsx)(af,{disabled:n,immutable:n,onChange:function(){},width:m(a.seconds),type:"number",value:a.seconds+""}),h()&&(0,ee.jsx)(B.ZP.Span,{children:o.secondsLabel})]})]})};uf.defaultProps={options:{hoursLabel:"hrs",minutesLabel:"min",secondsLabel:"s"}};const sf=uf;var lf;const ff=V.ZP.input.attrs((function(e){return{type:"text"}})).withConfig({displayName:"StyledStringEdit"})(lf||(lf=Y()(["\n &&&& {\n ","\n }\n"])),Yn);const pf=Hu.Z.Debouncer((function(e){return(0,ee.jsxs)(zn,{immutable:e.immutable,children:[(0,ee.jsx)(ff,{disabled:e.immutable,id:e.id,name:e.name,onChange:function(t){return e.onChange(t.target.value)},immutable:e.immutable,value:e.value||""}),e.value&&(0,ee.jsx)(qn,{children:(0,ee.jsx)(Un.Z,{href:"mailto:".concat(e.value.toString()),icon:"envelope",look:"ball",tabIndex:-1,target:"_blank",neutral:!0})})]})}));var df=i(2205),hf=i.n(df),mf=i(99489),vf=i.n(mf),gf=i(78718),yf=i.n(gf);function bf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function wf(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bf(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Of(){Of=function(e,t){return new n(e,void 0,t)};var e=RegExp.prototype,t=new WeakMap;function n(e,r,o){var a=new RegExp(e,r);return t.set(a,o||t.get(e)),vf()(a,n.prototype)}function r(e,n){var r=t.get(n);return Object.keys(r).reduce((function(t,n){var o=r[n];if("number"==typeof o)t[n]=e[o];else{for(var a=0;void 0===e[o[a]]&&a+1<o.length;)a++;t[n]=e[o[a]]}return t}),Object.create(null))}return hf()(n,RegExp),n.prototype.exec=function(t){var n=e.exec.call(this,t);if(n){n.groups=r(n,this);var o=n.indices;o&&(o.groups=r(o,this))}return n},n.prototype[Symbol.replace]=function(n,o){if("string"==typeof o){var a=t.get(this);return e[Symbol.replace].call(this,n,o.replace(/\$<([^>]+)>/g,(function(e,t){var n=a[t];return"$"+(Array.isArray(n)?n.join("$"):n)})))}if("function"==typeof o){var i=this;return e[Symbol.replace].call(this,n,(function(){var e=arguments;return"object"!=Ln()(e[e.length-1])&&(e=[].slice.call(e)).push(r(e,i)),o.apply(this,e)}))}return e[Symbol.replace].call(this,n,o)},Of.apply(this,arguments)}var xf,kf=["key","display","postcode","city","country","latitude","longitude"],Sf=function(e){return e*Math.PI/180},Pf=function(e){var t=e.state,n=e.country,r=e.postcode,o=e.city,a=e.latitude,i=e.longitude,c=t?"- ".concat(t):"",u=n?"/ ".concat(n.display):"";return{key:r,display:"".concat(r," ").concat(o," ").concat(c," ").concat(u),postcode:r,city:o,country:n,latitude:Sf(a),longitude:Sf(i)}};function _f(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function jf(){}function Ef(e){return!!(e||"").match(/\d/)}function Cf(e){return null==e}function Df(e){return"number"==typeof e&&isNaN(e)}function Tf(e){return e.replace(/[-[\]/{}()*+?.\\^$|]/g,"\\$&")}function Mf(e,t){void 0===t&&(t=!0);var n="-"===e[0],r=n&&t,o=(e=e.replace("-","")).split(".");return{beforeDecimal:o[0],afterDecimal:o[1]||"",hasNegation:n,addNegation:r}}function Rf(e,t,n){for(var r="",o=n?"0":"",a=0;a<=t-1;a++)r+=e[a]||o;return r}function If(e,t){return Array(t+1).join(e)}function Nf(e){var t=e+"",n="-"===t[0]?"-":"";n&&(t=t.substring(1));var r=t.split(/[eE]/g),o=r[0],a=r[1];if(!(a=Number(a)))return n+o;var i=1+a,c=(o=o.replace(".","")).length;return i<0?o="0."+If("0",Math.abs(i))+o:i>=c?o+=If("0",i-c):o=(o.substring(0,i)||"0")+"."+o.substring(i),n+o}function Af(e,t,n){if(-1!==["","-"].indexOf(e))return e;var r=(-1!==e.indexOf(".")||n)&&t,o=Mf(e),a=o.beforeDecimal,i=o.afterDecimal,c=o.hasNegation,u=parseFloat("0."+(i||"0")),s=(i.length<=t?"0."+i:u.toFixed(t)).split(".");return""+(c?"-":"")+a.split("").reverse().reduce((function(e,t,n){return e.length>n?(Number(e[0])+Number(t)).toString()+e.substring(1,e.length):t+e}),s[0])+(r?".":"")+Rf(s[1]||"",t,n)}function Zf(e,t){if(e.value=e.value,null!==e){if(e.createTextRange){var n=e.createTextRange();return n.move("character",t),n.select(),!0}return e.selectionStart||0===e.selectionStart?(e.focus(),e.setSelectionRange(t,t),!0):(e.focus(),!1)}}function Lf(e){return Math.max(e.selectionStart,e.selectionEnd)}function Ff(e){return{from:{start:0,end:0},to:{start:0,end:e.length},lastValue:""}}function Hf(e,t,n,r){var o,a,i,c=e.length;if(o=t,a=0,i=c,t=Math.min(Math.max(o,a),i),"left"===r){for(;t>=0&&!n[t];)t--;-1===t&&(t=n.indexOf(!0))}else{for(;t<=c&&!n[t];)t++;t>c&&(t=n.lastIndexOf(!0))}return-1===t&&(t=c),t}function Uf(e){for(var t=Array.from({length:e.length+1}).map((function(){return!0})),n=0,r=t.length;n<r;n++)t[n]=Boolean(Ef(e[n])||Ef(e[n-1]));return t}function Bf(e,t,n,r,o,a){void 0===a&&(a=jf);var i,c,u=(0,A.useRef)(),s=(i=function(e){var t,a;return Cf(e)||Df(e)?(a="",t=""):"number"==typeof e||n?(a="number"==typeof e?Nf(e):e,t=r(a)):(a=o(e,void 0),t=e),{formattedValue:t,numAsString:a}},(c=(0,A.useRef)(i)).current=i,(0,A.useRef)((function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return c.current.apply(c,e)})).current),l=(0,A.useState)((function(){return s(t)})),f=l[0],p=l[1];return(0,A.useMemo)((function(){Cf(e)?u.current=void 0:(u.current=s(e),p(u.current))}),[e,s]),[f,function(e,t){p({formattedValue:e.formattedValue,numAsString:e.value}),a(e,t)}]}function Wf(e){return e.replace(/[^0-9]/g,"")}function zf(e){return e}function Yf(e){var t=e.type;void 0===t&&(t="text");var n=e.displayType;void 0===n&&(n="input");var r=e.customInput,o=e.renderText,a=e.getInputRef,i=e.format;void 0===i&&(i=zf);var c=e.removeFormatting;void 0===c&&(c=Wf);var u=e.defaultValue,s=e.valueIsNumericString,l=e.onValueChange,f=e.isAllowed,p=e.onChange;void 0===p&&(p=jf);var d=e.onKeyDown;void 0===d&&(d=jf);var h=e.onMouseUp;void 0===h&&(h=jf);var m=e.onFocus;void 0===m&&(m=jf);var v=e.onBlur;void 0===v&&(v=jf);var g=e.value,y=e.getCaretBoundary;void 0===y&&(y=Uf);var b=e.isValidInputCharacter;void 0===b&&(b=Ef);var w=_f(e,["type","displayType","customInput","renderText","getInputRef","format","removeFormatting","defaultValue","valueIsNumericString","onValueChange","isAllowed","onChange","onKeyDown","onMouseUp","onFocus","onBlur","value","getCaretBoundary","isValidInputCharacter"]),O=Bf(g,u,Boolean(s),i,c,l),x=O[0],k=x.formattedValue,S=x.numAsString,P=O[1],_=(0,A.useRef)();(0,A.useEffect)((function(){var e=i(S);if(void 0===_.current||e!==_.current){var t=D.current,n=c(e,void 0);F({formattedValue:e,numAsString:n,input:t,setCaretPosition:!0,source:xf.props,event:void 0})}}));var j=(0,A.useState)(!1),E=j[0],C=j[1],D=(0,A.useRef)(null),T=(0,A.useRef)({setCaretTimeout:null,focusTimeout:null});(0,A.useEffect)((function(){return C(!0),function(){clearTimeout(T.current.setCaretTimeout),clearTimeout(T.current.focusTimeout)}}),[]);var M=i,R=function(e,t){var n=parseFloat(t);return{formattedValue:e,value:t,floatValue:isNaN(n)?void 0:n}},I=function(e,t,n){Zf(e,t),T.current.setCaretTimeout=setTimeout((function(){e.value===n&&Zf(e,t)}),0)},N=function(e,t,n){return Hf(e,t,y(e),n)},L=function(e,t,n){var r=y(t),o=function(e,t,n,r,o,a){var i=o.findIndex((function(e){return e})),c=e.slice(0,i);t||n.startsWith(c)||(n=c+n,r+=c.length);for(var u=n.length,s=e.length,l={},f=new Array(u),p=0;p<u;p++){f[p]=-1;for(var d=0,h=s;d<h;d++)if(n[p]===e[d]&&!0!==l[d]){f[p]=d,l[d]=!0;break}}for(var m=r;m<u&&(-1===f[m]||!a(n[m]));)m++;var v=m===u||-1===f[m]?s:f[m];for(m=r-1;m>0&&-1===f[m];)m--;var g=-1===m||-1===f[m]?0:f[m]+1;return g>v?v:r-g<v-r?g:v}(t,k,e,n,r,b);return o=Hf(t,o,r)},F=function(e){var t=e.formattedValue;void 0===t&&(t="");var n=e.input,r=e.setCaretPosition;void 0===r&&(r=!0);var o=e.source,a=e.event,i=e.numAsString,c=e.caretPos;if(n){if(void 0===c&&r){var u=e.inputValue||n.value,s=Lf(n);n.value=t,c=L(u,t,s)}n.value=t,r&&void 0!==c&&I(n,c,t)}t!==k&&function(e,t){_.current=e.formattedValue,P(e,t)}(R(t,i),{event:a,source:o})},H=!E||"undefined"==typeof navigator||navigator.platform&&/iPhone|iPod/.test(navigator.platform)?void 0:"numeric",U=Object.assign({inputMode:H},w,{type:t,value:k,onChange:function(e){(function(e,t,n){var r=function(e,t){for(var n=0,r=0,o=e.length,a=t.length;e[n]===t[n]&&n<o;)n++;for(;e[o-1-r]===t[a-1-r]&&a-r>n&&o-r>n;)r++;return{from:{start:n,end:o-r},to:{start:n,end:a-r}}}(k,e),o=Object.assign(Object.assign({},r),{lastValue:k}),a=c(e,o),i=M(a);if(a=c(i,void 0),f&&!f(R(i,a))){var u=t.target,s=Lf(u),l=L(e,k,s);return I(u,l,k),!1}return F({formattedValue:i,numAsString:a,inputValue:e,event:t,source:n,setCaretPosition:!0,input:t.target}),!0})(e.target.value,e,xf.event)&&p(e)},onKeyDown:function(e){var t,n=e.target,r=e.key,o=n.selectionStart,a=n.selectionEnd,i=n.value;if(void 0===i&&(i=""),"ArrowLeft"===r||"Backspace"===r?t=Math.max(o-1,0):"ArrowRight"===r?t=Math.min(o+1,i.length):"Delete"===r&&(t=o),void 0!==t&&o===a){var c=t;if("ArrowLeft"===r||"ArrowRight"===r)c=N(i,t,"ArrowLeft"===r?"left":"right");else"Delete"!==r||b(i[t])?"Backspace"!==r||b(i[t])||(c=N(i,t,"left")):c=N(i,t,"right");c!==t&&I(n,c,i),e.isUnitTestRun&&I(n,c,i),d(e)}else d(e)},onMouseUp:function(e){var t=e.target,n=t.selectionStart,r=t.selectionEnd,o=t.value;if(void 0===o&&(o=""),n===r){var a=N(o,n);a!==n&&I(t,a,o)}h(e)},onFocus:function(e){e.persist&&e.persist();var t=e.target;D.current=t,T.current.focusTimeout=setTimeout((function(){var n=t.selectionStart,r=t.selectionEnd,o=t.value;void 0===o&&(o="");var a=N(o,n);a===n||0===n&&r===o.length||I(t,a,o),m(e)}),0)},onBlur:function(e){D.current=null,clearTimeout(T.current.focusTimeout),clearTimeout(T.current.setCaretTimeout),v(e)}});if("text"===n)return o?Z().createElement(Z().Fragment,null,o(k,w)||null):Z().createElement("span",Object.assign({},w,{ref:a}),k);if(r){var B=r;return Z().createElement(B,Object.assign({},U,{ref:a}))}return Z().createElement("input",Object.assign({},U,{ref:a}))}function Vf(e,t){var n=t.decimalScale,r=t.fixedDecimalScale,o=t.prefix;void 0===o&&(o="");var a=t.suffix;void 0===a&&(a="");var i=t.allowNegative,c=t.thousandsGroupStyle;if(void 0===c&&(c="thousand"),""===e||"-"===e)return e;var u=qf(t),s=u.thousandSeparator,l=u.decimalSeparator,f=0!==n&&-1!==e.indexOf(".")||n&&r,p=Mf(e,i),d=p.beforeDecimal,h=p.afterDecimal,m=p.addNegation;return void 0!==n&&(h=Rf(h,n,!!r)),s&&(d=function(e,t,n){var r=function(e){switch(e){case"lakh":return/(\d+?)(?=(\d\d)+(\d)(?!\d))(\.\d+)?/g;case"wan":return/(\d)(?=(\d{4})+(?!\d))/g;case"thousand":default:return/(\d)(?=(\d{3})+(?!\d))/g}}(n),o=e.search(/[1-9]/);return o=-1===o?e.length:o,e.substring(0,o)+e.substring(o,e.length).replace(r,"$1"+t)}(d,s,c)),o&&(d=o+d),a&&(h+=a),m&&(d="-"+d),e=d+(f&&l||"")+h}function qf(e){var t=e.decimalSeparator;void 0===t&&(t=".");var n=e.thousandSeparator,r=e.allowedDecimalSeparators;return!0===n&&(n=","),r||(r=[t,"."]),{decimalSeparator:t,thousandSeparator:n,allowedDecimalSeparators:r}}function Gf(e,t,n){var r;void 0===t&&(t=Ff(e));var o=n.allowNegative,a=n.prefix;void 0===a&&(a="");var i=n.suffix;void 0===i&&(i="");var c=n.decimalScale,u=t.from,s=t.to,l=s.start,f=s.end,p=qf(n),d=p.allowedDecimalSeparators,h=p.decimalSeparator,m=e[f]===h;if(Ef(e)&&(e===a||e===i)&&""===t.lastValue)return e;if(f-l==1&&-1!==d.indexOf(e[l])){var v=0===c?"":h;e=e.substring(0,l)+v+e.substring(l+1,e.length)}var g=function(e,t,n){var r=!1,o=!1;a.startsWith("-")?r=!1:e.startsWith("--")?(r=!1,o=!0):i.startsWith("-")&&e.length===i.length?r=!1:"-"===e[0]&&(r=!0);var c=r?1:0;return o&&(c=2),c&&(e=e.substring(c),t-=c,n-=c),{value:e,start:t,end:n,hasNegation:r}},y=g(e,l,f),b=y.hasNegation;e=(r=y).value,l=r.start,f=r.end;var w=g(t.lastValue,u.start,u.end),O=w.start,x=w.end,k=w.value,S=e.substring(l,f);!(e.length&&k.length&&(O>k.length-i.length||x<a.length))||S&&i.startsWith(S)||(e=k);var P=0;e.startsWith(a)?P+=a.length:l<a.length&&(P=l),f-=P;var _=(e=e.substring(P)).length,j=e.length-i.length;e.endsWith(i)?_=j:(f>j||f>e.length-i.length)&&(_=f),e=e.substring(0,_);var E=(e=((e=function(e,t){void 0===e&&(e="");var n=new RegExp("(-)"),r=new RegExp("(-)(.)*(-)"),o=n.test(e),a=r.test(e);return e=e.replace(/-/g,""),o&&!a&&t&&(e="-"+e),e}(b?"-"+e:e,o)).match(function(e,t){return new RegExp("(^-)|[0-9]|"+Tf(e),t?"g":void 0)}(h,!0))||[]).join("")).indexOf(h),C=Mf(e=e.replace(new RegExp(Tf(h),"g"),(function(e,t){return t===E?".":""})),o),D=C.beforeDecimal,T=C.afterDecimal,M=C.addNegation;return s.end-s.start<u.end-u.start&&""===D&&m&&!parseFloat(T)&&(e=M?"-":""),e}function Kf(e){var t=(e=function(e){var t=qf(e),n=t.thousandSeparator,r=t.decimalSeparator,o=e.prefix;void 0===o&&(o="");var a=e.allowNegative;if(void 0===a&&(a=!0),n===r)throw new Error("\n Decimal separator can't be same as thousand separator.\n thousandSeparator: "+n+' (thousandSeparator = {true} is same as thousandSeparator = ",")\n decimalSeparator: '+r+" (default value for decimalSeparator is .)\n ");return o.startsWith("-")&&a&&(console.error("\n Prefix can't start with '-' when allowNegative is true.\n prefix: "+o+"\n allowNegative: "+a+"\n "),a=!1),Object.assign(Object.assign({},e),{allowNegative:a})}(e)).decimalSeparator;void 0===t&&(t=".");e.allowedDecimalSeparators,e.thousandsGroupStyle,e.suffix;var n=e.allowNegative,r=e.allowLeadingZeros,o=e.onKeyDown;void 0===o&&(o=jf);var a=e.onBlur;void 0===a&&(a=jf);var i=e.thousandSeparator,c=e.decimalScale,u=e.fixedDecimalScale,s=e.prefix;void 0===s&&(s="");var l=e.defaultValue,f=e.value,p=e.valueIsNumericString,d=e.onValueChange,h=_f(e,["decimalSeparator","allowedDecimalSeparators","thousandsGroupStyle","suffix","allowNegative","allowLeadingZeros","onKeyDown","onBlur","thousandSeparator","decimalScale","fixedDecimalScale","prefix","defaultValue","value","valueIsNumericString","onValueChange"]),m=function(t){return Vf(t,e)},v=function(t,n){return Gf(t,n,e)},g=p;Cf(f)?Cf(l)||(g=null!=p?p:"number"==typeof l):g=null!=p?p:"number"==typeof f;var y=function(e){return Cf(e)||Df(e)?e:("number"==typeof e&&(e=Nf(e)),g&&"number"==typeof c?Af(e,c,Boolean(u)):e)},b=Bf(y(f),y(l),Boolean(g),m,v,d),w=b[0],O=w.numAsString,x=w.formattedValue,k=b[1];return Object.assign(Object.assign({},h),{value:x,valueIsNumericString:!1,isValidInputCharacter:function(e){return e===t||Ef(e)},onValueChange:k,format:m,removeFormatting:v,getCaretBoundary:function(t){return function(e,t){var n=t.prefix;void 0===n&&(n="");var r=t.suffix;void 0===r&&(r="");var o=Array.from({length:e.length+1}).map((function(){return!0})),a="-"===e[0];o.fill(!1,0,n.length+(a?1:0));var i=e.length;return o.fill(!1,i-r.length+1,i+1),o}(t,e)},onKeyDown:function(t){var r=t.target,a=t.key,l=r.selectionStart,f=r.selectionEnd,p=r.value;if(void 0===p&&(p=""),l===f){"Backspace"===a&&"-"===p[0]&&l===s.length+1&&n&&Zf(r,1);var d=qf(e),h=d.decimalSeparator,m=d.allowedDecimalSeparators;"Backspace"===a&&p[l-1]===h&&c&&u&&(Zf(r,l-1),t.preventDefault()),(null==m?void 0:m.includes(a))&&p[l]===h&&Zf(r,l+1);var v=!0===i?",":i;"Backspace"===a&&p[l-1]===v&&Zf(r,l-1),"Delete"===a&&p[l]===v&&Zf(r,l+1),o(t)}else o(t)},onBlur:function(t){var n=O;if(n.match(/\d/g)||(n=""),r||(n=function(e){if(!e)return e;var t="-"===e[0];t&&(e=e.substring(1,e.length));var n=e.split("."),r=n[0].replace(/^0+/,"")||"0",o=n[1]||"";return(t?"-":"")+r+(o?"."+o:"")}(n)),u&&c&&(n=Af(n,c,u)),n!==O){var o=Vf(n,e);k({formattedValue:o,value:n,floatValue:parseFloat(n)},{event:t,source:xf.event})}a(t)}})}function Xf(e){var t=Kf(e);return Z().createElement(Yf,Object.assign({},t))}!function(e){e.event="event",e.props="prop"}(xf||(xf={}));var Qf,$f=["immutable"];function Jf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const ep=(0,V.ZP)((function(e){e.immutable;var t=Ve()(e,$f);return(0,ee.jsx)(Xf,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jf(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},t))})).withConfig({displayName:"StyledNumberEdit"})(Qf||(Qf=Y()(["\n &&&& {\n ","\n }\n"])),Yn);function tp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function np(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var rp=function(e){return 0!==e?Math.ceil(Math.log10(Math.abs(e)+1)):1},op=function(e){return null!=e&&!isNaN(parseFloat(e))},ap=function(e,t,n){return!op(n)||!(op(t)&&n>t)&&!(op(e)&&n<e)},ip=function(e,t){return function(n){var r=n.floatValue;return rp(r)<rp(e)||ap(e,t,r)}};const cp=(0,v.ZP)(Hu.Z.Debouncer((function(e){var t,n=(t=e.intl.locale,{thousandSeparator:1111..toLocaleString(t).replace(/1/g,""),decimalSeparator:1.1.toLocaleString(t).replace(/1/g,"")}),r=n.thousandSeparator,o=n.decimalSeparator,a=e.options||{},i=a.prePointDigits,c=a.postPointDigits,u=a.minValue,s=a.maxValue,l=a.allowNegative,f=a.fixedDecimalScale,p=a.suffix,d=a.prefix,h=a.format,m=function(e,t,n){if(e){var r=Math.pow(10,e)-(t?1/Math.pow(10,t):1);return n&&n>r?n:r}return n}(i,c,s),v=np(np({isAllowed:ip(u,m),allowNegative:!!l},isNaN(c)?{}:{decimalScale:c}),{},{fixedDecimalScale:!!f});return(0,ee.jsx)(zn,{immutable:e.immutable,children:(0,ee.jsx)(ep,np(np({decimalSeparator:o,disabled:e.immutable,id:e.id,valueIsNumericString:!0,name:e.name,onValueChange:function(t){e.onChange&&ap(u,m,t.floatValue)&&e.onChange(void 0!==t.floatValue?t.floatValue:null)},immutable:e.immutable,thousandSeparator:r,value:e.value,suffix:p,prefix:d},v),{},{format:h,placeholder:e.placeholder,onBlur:function(t){var n,r=!(n=t.target.value)||isNaN(n)?null:parseFloat(n);e.onChange&&!ap(u,m,r)&&(t.target.value=null)}}))})}),800));const up=Hu.Z.Debouncer((function(e){var t=e.value,n=e.onChange,r=e.options,o=e.immutable,a=e.name,i=e.id,c=e.placeholder,u=r||{},s=u.minValue,l=u.maxValue,f=u.format,p=u.allowLeadingZeros,d=u.suffix;return(0,ee.jsx)(zn,{immutable:o,children:(0,ee.jsx)(ep,{isAllowed:ip(s,l),allowNegative:!0,decimalScale:0,disabled:o,id:i,name:a,onValueChange:function(e){var t=e.value,r=e.floatValue,o=p?t:r;void 0===o&&(o=null),ap(s,l,r)&&n(o)},value:t,allowLeadingZeros:p,suffix:d,format:f,placeholder:c})})}),800);var sp,lp,fp,pp=V.ZP.div.withConfig({displayName:"StyledWrapper"})(sp||(sp=Y()(["\n display: flex;\n justify-content: stretch;\n"]))),dp=V.ZP.div.withConfig({displayName:"StyledLocationWrapper"})(lp||(lp=Y()(["\n flex-grow: 1;\n"]))),hp=V.ZP.div.withConfig({displayName:"StyledDistanceWrapper"})(fp||(fp=Y()(["\n width: 50px;\n border-left: 1px solid ",";\n margin-left: ",";\n padding-left: ",";\n"])),X.FS.color("border"),q.Z.space(-.8),q.Z.space(.5));function mp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function vp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?mp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const gp=function(e){var t=e.id,n=e.immutable,r=e.value,o=e.onChange,a=e.options,i=void 0===a?{}:a,c=i.suggestions,u=i.isLoading,s=i.fetchSuggestions,l=i.latitudeField,f=i.longitudeField,p=i.emptySearchText,d=i.noResultsText,h=i.kmSuffixText,m=r?r.distance:0,v=function(e){return null!=e&&e.latitude&&null!=e&&e.longitude?yf()(e,kf):void 0}(r),g=function(e){return e?e.map(Pf):[]}(c);return(0,ee.jsxs)(pp,{children:[(0,ee.jsx)(dp,{children:(0,ee.jsx)(ua,{id:t,immutable:n,onChange:function(e){o(vp(vp({},function(e,t){return t?wf(wf({},e),yf()(t,kf)):In()(e,kf)}(r,e)),{},{latitudeField:l,longitudeField:f}))},isLoading:u,options:g,searchOptions:function(e){var t=function(e){if(!e)return null;var t=st()(e.matchAll(Of(/([\d]*)([^\d\s]*)/g,{postcode:1,city:2}))).map((function(e){return e.groups})),n=t.find((function(e){return e.postcode})),r=t.find((function(e){return e.city}));return wf(wf({},r?{city:r.city}:{}),n?{postcode:n.postcode}:{})}(e);s(t,null)},fetchOptions:function(e){e||s(null,null)},value:v,noResultsComp:function(e){return e.inputValue?d:p}})}),(0,ee.jsx)(hp,{children:(0,ee.jsx)(up,{value:m,onChange:function(e){o(vp(vp({},r),{},{distance:e}))},immutable:n,options:{minValue:0,maxValue:100,suffix:" ".concat(h)}})})]})};var yp,bp=(0,A.lazy)((function(){return i.e(85).then(i.bind(i,17676))})),wp=function(e){var t=e.onChange,n=e.immutable,r=e.value,o=e.options;if(n)return(0,ee.jsx)(B.ZP.Span,{children:(0,ee.jsx)("div",{dangerouslySetInnerHTML:{__html:r}})});var a=o||{},i=a.contentLang,c=a.ckEditorConfig;return(0,ee.jsx)(A.Suspense,{fallback:yp||(yp=(0,ee.jsx)("i",{})),children:(0,ee.jsx)(bp,{onChange:function(e){t&&t(e)},value:r,contentLang:i,ckEditorConfig:c})})};wp.defaultProps={value:""};const Op=wp;var xp,kp;function Sp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Pp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Sp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Sp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const _p=function(e){var t=e.onChange,n=e.options,r=e.value,o=e.id,a=e.immutable,i=e.name,c=function(e){return function(t){return t[e]}},u=function(e){var t=e.state,n=e.country,r=e.postcode,o=e.city,a=t?"- ".concat(t):"",i=n?"/ ".concat(n.display):"";return(0,ee.jsxs)(B.ZP.Span,{children:[r," ",o," ",a," ",i]})},s=function(e){return function(n,o){var a=o.newValue;t(Pp(Pp({},r),{},l()({},e,a)))}},f=function(e,n){var r=n.suggestion;t(r)},p=function(e){return function(t){var r=t.value;n.fetchSuggestions(l()({},e,r),n.locationValues.country)}},d={id:o,value:r.postcode||"",onChange:s("postcode"),disabled:a},h={value:r.city||"",onChange:s("city"),disabled:a};return(0,ee.jsx)(et,{children:function(e){var t,o,s,l=e.focused,m=e.getRef;return(0,ee.jsxs)(Kn,{immutable:a,name:i,ref:m,children:[(0,ee.jsx)(Hn(),{suggestions:n.suggestions||[],onSuggestionsFetchRequested:p("postcode"),getSuggestionValue:c("postcode"),renderSuggestion:u,onSuggestionsClearRequested:function(){},inputProps:d,onSuggestionSelected:f,focusInputOnSuggestionClick:!1,shouldRenderSuggestions:function(e){return e&&!a}}),(l||r.city||r.postcode)&&(xp||(xp=(0,ee.jsx)(B.ZP.Span,{children:"/"}))),(0,ee.jsx)(Hn(),{suggestions:n.suggestions||[],onSuggestionsFetchRequested:p("city"),getSuggestionValue:c("city"),renderSuggestion:u,onSuggestionsClearRequested:function(){},inputProps:h,onSuggestionSelected:f,focusInputOnSuggestionClick:!1,shouldRenderSuggestions:function(e){return e&&!a}}),(0,ee.jsxs)(qn,{children:[n.isLoading&&(kp||(kp=(0,ee.jsx)(Bn.Z,{size:"1.8rem"}))),(s=n.locationValues,Boolean(s.city||s.postcode)&&!s.street&&(0,ee.jsx)(Un.Z,{href:(t=n.locationValues,o=t?Object.values(t).filter(Boolean).map((function(e){return"object"===Ln()(e)&&e.display?e.display:e})).join("+"):"","".concat("https://www.google.com/maps/search/?api=1&query=").concat(o)),icon:"map-marked",tabIndex:-1,target:"_blank",dense:!1,title:n.mapButtonTitle||"Show on map",neutral:!0}))]})]})}})};function jp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Ep=function(e){return(0,ee.jsx)(ua,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?jp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):jp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,isMulti:!0,immutable:e.immutable,onChange:e.onChange,value:e.value},e.options))};function Cp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Dp=function(e){return(0,ee.jsx)(ua,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Cp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,isMulti:!0,immutable:e.immutable,onChange:e.onChange,value:e.value,openMenuOnClick:!0},e.options))};var Tp,Mp=i(48926),Rp=i.n(Mp),Ip=i(87757),Np=i.n(Ip);const Ap=V.ZP.input.attrs((function(e){return{type:"tel"}})).withConfig({displayName:"StyledPhoneEdit"})(Tp||(Tp=Y()(["\n &&&& {\n ","\n }\n"])),Yn);const Zp=function(e){var t=e.onChange,n=e.value,r=e.immutable,o=e.id,a=e.onLibLoaded,c=Ut()(e,"options.defaultCountry")||"CH",u=(0,A.useState)(null),s=We()(u,2),l=s[0],f=s[1],p=Z().createRef();(0,A.useEffect)((function(){(function(){var e=Rp()(Np().mark((function e(){var t;return Np().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all([i.e(631),i.e(877)]).then(i.bind(i,41866));case 2:t=e.sent,f(t),a&&a();case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()()}),[a]);var d=function(e,t){var n=e.substring(0,t-1).match(/\s/g);return(null==n?void 0:n.length)||0},h=n&&null!=l&&l.AsYouType?new l.AsYouType(c).input(n):n||"";return(0,ee.jsxs)(zn,{immutable:r,children:[(0,ee.jsx)(Ap,{disabled:r||!l,id:o,name,onChange:function(e){var r=e.target.value,o=l?l.parseNumber(r,c):r,a=An()(o)?new l.AsYouType(c).input(r).replace(/\s/g,""):l.formatNumber(o,"E.164");t(a);var i=e.target.selectionStart;!function(e,t,n){if(n&&e.length!==n){var r=new l.AsYouType(c).input(t),o=new l.AsYouType(c).input(e),a=d(r,n),i=d(o,n)-a;window.requestAnimationFrame(function(){var e=n+i;this.setSelectionRange(e,e)}.bind(p.current))}}(r,n,i)},immutable:r||!l,ref:p,value:h}),h&&(0,ee.jsx)(qn,{children:(0,ee.jsx)(Un.Z,{href:"tel:".concat(n),icon:"phone",tabIndex:-1,target:"_blank",neutral:!0})})]})};function Lp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Fp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Lp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Lp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Hp=function(e){return e.map((function(e){return yf()(e,["key","display"])}))};const Up=function(e){var t=e.id,n=e.immutable,r=e.onChange,o=e.options.isMulti,a=e.value;return(0,ee.jsx)(ua,{id:t,immutable:n,isMulti:o,onChange:function(e){var t=o?e.map((function(e){return e.key})):[null==e?void 0:e.key],n=a.options.map((function(e){return Fp(Fp({},e),t.includes(e.key)?{selected:!0}:{selected:!1})}));r({options:n})},value:Hp(a.options.filter((function(e){return e.selected}))),openMenuOnClick:!0,options:Hp(a.options)})};function Bp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Wp=function(e){return(0,ee.jsx)(ua,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,isMulti:!1,immutable:e.immutable,onChange:e.onChange,value:e.value},e.options))};function zp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Yp=function(e){return(0,ee.jsx)(ua,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({immutable:e.immutable,onChange:e.onChange,value:e.value},e.options))};function Vp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const qp=function(e){return(0,ee.jsx)(ua,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,immutable:e.immutable,isMulti:!1,onChange:e.onChange,value:e.value,openMenuOnClick:!0},e.options))};const Gp=Hu.Z.Debouncer((function(e){return(0,ee.jsx)(zn,{immutable:e.immutable,children:(0,ee.jsx)(ff,{disabled:e.immutable,id:e.id,name:e.name,onChange:function(t){return e.onChange(t.target.value)},immutable:e.immutable,value:e.value||""})})}));const Kp=function(){var e,t=(null===(e=navigator)||void 0===e?void 0:e.userAgent)||"";return/^((?!chrome|android).)*safari/i.test(t)};var Xp,Qp,$p,Jp=(0,V.iv)(Xp||(Xp=Y()(["\n ","\n width: 100%;\n grid-area: 1 / 1 / 2 / 2;\n max-height: 25rem;\n box-sizing: border-box;\n"])),Yn),ed=V.ZP.div.withConfig({displayName:"StyledSizeWrapper"})(Qp||(Qp=Y()(["\n display: grid;\n width: 100%;\n\n &:after {\n content: attr(data-replicated-value) ' ';\n white-space: pre-wrap;\n word-break: break-all;\n visibility: hidden;\n ","\n\n /* prevent scrollbar on Firefox */\n padding-right: 15px;\n }\n"])),Jp),td=V.ZP.textarea.withConfig({displayName:"StyledTextarea"})($p||($p=Y()(["\n &&&& {\n ","\n resize: none;\n margin: 0;\n min-height: 4em;\n }\n"])),Jp);function nd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function rd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?nd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const od=function(e){var t=e.value,n=e.onChange,r=e.name,o=e.id,a=e.disabled,i=e.immutable,c=(0,A.useState)(t),u=We()(c,2),s=u[0],l=u[1],f=!Kp(),p=(0,A.useCallback)(rr()(l,500,{trailing:!0}),[]);return(0,A.useEffect)((function(){f&&p(t)}),[t,f,p]),(0,ee.jsx)(ed,rd(rd({"data-testid":"replicated-test"},f?{"data-replicated-value":s}:{}),{},{children:(0,ee.jsx)(td,{value:t,name:r,id:o,onChange:n,disabled:a,immutable:i,rows:"1"})}))};const ad=Hu.Z.Debouncer((function(e){return(0,ee.jsx)(zn,{immutable:e.immutable,children:(0,ee.jsx)(od,{id:e.id,immutable:e.immutable,maxRows:20,name:e.name,onChange:function(t){return e.onChange(t.target.value)},disabled:e.immutable,rows:2,value:e.value})})}));var id;const cd=V.ZP.input.withConfig({displayName:"StyledTimeEdit"})(id||(id=Y()(["\n &&&& {\n ","\n }\n"])),Yn);function ud(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function sd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ud(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ud(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const ld=function(e){var t=e.onChange,n=e.value,r=e.immutable,o=e.id,a=e.name,i=Yu(n,t),c=i.inputProps,u=i.clearButtonProps,s=n&&!r;return(0,ee.jsxs)(zn,{immutable:r,children:[(0,ee.jsx)(cd,sd({type:"text",disabled:r,id:o,immutable:r,name:a},c)),s&&(0,ee.jsx)(qn,{children:(0,ee.jsx)(vo.Z,sd(sd({icon:"times"},u),{},{tabIndex:-1}))})]})};var fd;const pd=V.ZP.input.attrs((function(e){return{type:"url"}})).withConfig({displayName:"StyledUrlEdit"})(fd||(fd=Y()(["\n &&&& {\n ","\n }\n"])),Yn);const dd=Hu.Z.Debouncer((function(e){return(0,ee.jsxs)(zn,{immutable:e.immutable,children:[(0,ee.jsx)(pd,{disabled:e.immutable,id:e.id,immutable:e.immutable,name:e.name,onChange:function(t){return e.onChange((n=t.target.value,r=/^[a-zA-Z0-9]+:\/\//.test(n),n.indexOf(".")>0&&!r?"https://".concat(n):n));var n,r},value:e.value}),e.value&&(0,ee.jsx)(qn,{children:(0,ee.jsx)(Un.Z,{href:e.value,icon:"external-link",look:"ball",tabIndex:-1,target:"_blank",neutral:!0})})]})}));function hd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function md(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?hd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var vd={boolean:pa,"boolean-select":sa,choice:ka,code:Ma,date:es,datetime:ns,document:tf,duration:sf,email:pf,geosearch:gp,html:Op,integer:up,address:Jn,location:_p,"multi-remote":Ep,"multi-select":Dp,number:cp,phone:Zp,"pseudo-select":Up,remote:Wp,"search-filter":Yp,"single-select":qp,string:Gp,text:ad,url:dd,time:ld};const gd=function(e){var t=e.componentType,n=e.value,r=e.options,o=e.id,a=e.events,i=e.placeholder,c=e.readOnly,u=void 0!==c&&c;if(vd[t]){var s=vd[t],l=md(md({},In()(a,"onChange")),{},{onBlur:function(){"function"==typeof(null==a?void 0:a.onBlur)&&a.onBlur(n)}});return(0,ee.jsx)("div",md(md({},l),{},{"data-cy":"form-field",children:(0,ee.jsx)(s,md(md({value:n,onChange:null==a?void 0:a.onChange},An()(r)?{}:{options:r}),{},{id:o,immutable:u,placeholder:i,events:a}))}))}return console.log("No type-editor defined for component type",t),null};function yd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function bd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?yd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):yd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const wd=function(e){return(0,ee.jsx)(Gn,{children:(0,ee.jsx)(gd,bd({componentType:e.type},In()(e,"type")))})};var Od,xd,kd=V.ZP.div.withConfig({displayName:"StyledLoginFormInputWrapper"})(Od||(Od=Y()(["\n && {\n ","\n }\n"])),Wn);const Sd=function(e){var t=e.verifyCode,n=e.intl,r=(0,A.useState)(null),o=We()(r,2),a=o[0],i=o[1],c=function(e){return n.formatMessage({id:e})},u=a&&a.toString().length>=6,s=function(e){e&&(e.preventDefault(),e.stopPropagation()),u&&t(a)};(0,H.z)(s);var l=ze.Z.isInAdminEmbedded();return(0,ee.jsxs)(ee.Fragment,{children:[xd||(xd=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.verificationText"})})),(0,ee.jsxs)("form",{onSubmit:s,children:[(0,ee.jsx)(kn,{hasValue:Boolean(a),id:"verification-input",label:c("client.two-factor-connector.verificationInputLabel"),labelPosition:l?"inside":"outside",children:(0,ee.jsx)(kd,{children:(0,ee.jsx)(wd,{type:"integer",value:a,events:{onChange:i},options:{format:"### ###",allowLeadingZeros:!0}})})}),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:c("client.two-factor-connector.okButton"),ink:"primary",look:"raised",type:"submit",disabled:!u})})]})]})};var Pd={verifyCode:function(e){return{type:_,payload:{userCode:e}}}};const _d=(0,g.connect)((function(e,t){return{}}),Pd)((0,v.ZP)(Sd));var jd,Ed,Cd,Dd,Td,Md,Rd=0,Id=1,Nd=2,Ad=3;const Zd=function(e){var t=e.initialize,n=e.stage;(0,A.useEffect)((function(){t()}),[t]);return(0,ee.jsxs)(ee.Fragment,{children:[Md||(Md=(0,ee.jsx)(m.Z.Notifications,{})),function(){switch(n){case Rd:return jd||(jd=(0,ee.jsx)(Ue,{}));case Id:return Ed||(Ed=(0,ee.jsx)(Ze,{}));case Nd:return Cd||(Cd=(0,ee.jsx)(_d,{}));case Ad:return Dd||(Dd=(0,ee.jsx)(re,{}));default:return Td||(Td=(0,ee.jsx)(L.Z,{}))}}()]})};var Ld={initialize:D};const Fd=(0,g.connect)((function(e){return{stage:e.twoFactorConnector.stage}}),Ld)((0,v.ZP)(Zd));var Hd,Ud=i(81770);function Bd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Wd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var zd=function(e){return function(t){return Wd(Wd({},t),{},{stage:e})}},Yd=(Hd={},l()(Hd,b,Ud.Z.singleTransferReducer("twoFactorActive")),l()(Hd,w,Ud.Z.singleTransferReducer("secret")),l()(Hd,O,Ud.Z.singleTransferReducer("username")),l()(Hd,E,Ud.Z.singleTransferReducer("setupSuccessful")),l()(Hd,S,zd(0)),l()(Hd,P,zd(1)),l()(Hd,k,zd(2)),l()(Hd,C,zd(3)),Hd),Vd={stage:null,twoFactorActive:null,secret:null,username:null,setupSuccessful:null};var qd=i(34857),Gd=i(81719),Kd=i(54159),Xd=Np().mark(sh),Qd=Np().mark(fh),$d=Np().mark(ph),Jd=Np().mark(hh),eh=Np().mark(mh),th=Np().mark(vh),nh=Np().mark(gh),rh=Np().mark(yh),oh=Np().mark(bh),ah="relTwo_step_login_status",ih=function(e){return e.twoFactorConnector.username},ch=function(e){return e.twoFactorConnector.secret},uh=function(e){return e.input};function sh(){var e,t,n,r,o,a;return Np().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,(0,qd.Ys)(uh);case 2:if(e=i.sent,e.secret){i.next=14;break}return i.next=7,(0,qd.Ys)(ih);case 7:return t=i.sent,i.next=10,(0,qd.RE)(Gd.Z.requestSaga,"principals/".concat(t,"/two-factor"),{method:"GET"});case 10:return n=i.sent,r=n.body,o=r.secret,a=r.totpUri,i.next=14,(0,qd.gz)(M({secret:o,uri:a}));case 14:return i.next=16,(0,qd.gz)({type:P});case 16:case"end":return i.stop()}}),Xd)}function lh(e,t){return Kd.Z.executeRequest(e,t).then(Kd.Z.extractBody)}function fh(e,t,n,r){var o,a;return Np().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return o={secret:e,userCode:t,username:n,password:r},i.next=3,(0,qd.RE)(lh,"login",{method:"POST",headers:new Headers({"Content-Type":"application/x-www-form-urlencoded; charset=utf-8"}),body:Object.keys(o).filter((function(e){return!!o[e]})).sort().map((function(e){return"".concat(encodeURIComponent(e),"=").concat(encodeURIComponent(o[e]))})).join("&")});case 3:return a=i.sent,i.next=6,(0,qd.gz)(N(Ut()(a,"TWOSTEPLOGIN_ACTIVATION.success",!1)));case 6:case"end":return i.stop()}}),Qd)}function ph(e,t,n){var r;return Np().wrap((function(o){for(;;)switch(o.prev=o.next){case 0:return o.next=2,(0,qd.RE)(Gd.Z.requestSaga,"principals/".concat(e,"/two-factor"),{method:"POST",body:{secret:t,code:n},acceptedStatusCodes:[400]});case 2:return r=o.sent,o.next=5,(0,qd.gz)(N(204===r.status));case 5:case"end":return o.stop()}}),$d)}function dh(e){var t=e.payload.userCode;return Np().mark((function e(){var n,r,o,a,i;return Np().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,qd.Ys)(ih);case 2:return n=e.sent,e.next=5,(0,qd.Ys)(ch);case 5:return r=e.sent,o=r.secret,e.next=9,(0,qd.Ys)(uh);case 9:if(a=e.sent,i=a.password,!a.forced){e.next=17;break}return e.next=15,(0,qd.RE)(fh,o,t,n,i);case 15:e.next=19;break;case 17:return e.next=19,(0,qd.RE)(ph,n,o,t);case 19:return e.next=21,(0,qd.gz)({type:C});case 21:case"end":return e.stop()}}),e)}))()}function hh(){var e,t;return Np().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,(0,qd.RE)(vh);case 2:return n.next=4,(0,qd.Ys)(uh);case 4:if(e=n.sent,!(t=e.secret)){n.next=9;break}return n.next=9,(0,qd.gz)(M(t));case 9:return n.next=11,(0,qd.gz)(I());case 11:case"end":return n.stop()}}),Jd)}function mh(){return Np().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,qd.gz)(h.Z.fireExternalEvent("onSuccess"));case 2:case"end":return e.stop()}}),eh)}function vh(){var e,t,n,r,o;return Np().wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,(0,qd.RE)(gh);case 2:return e=a.sent,a.next=5,(0,qd.gz)(R(e));case 5:return t='username === "'.concat(e,'"'),a.next=8,(0,qd.RE)(Gd.Z.fetchEntitiesPage,"Principal",{where:t,paths:[ah]});case 8:if(!((n=a.sent).length>1)){a.next=11;break}throw new Error("More than one user found for username ".concat(e));case 11:return r=Ut()(n,"[0].paths.".concat(ah,".value.key")),o="1"===r,a.next=15,(0,qd.gz)(T(o));case 15:case"end":return a.stop()}}),th)}function gh(){var e,t,n;return Np().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,(0,qd.Ys)(uh);case 2:if(e=r.sent,!(t=e.username)){r.next=8;break}return r.abrupt("return",t);case 8:return r.next=10,(0,qd.RE)(Gd.Z.requestSaga,"principals");case 10:return n=r.sent,r.abrupt("return",n.body.username);case 12:case"end":return r.stop()}}),nh)}function yh(){return Np().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,qd.gz)(h.Z.fireExternalEvent("onResize"));case 2:case"end":return e.stop()}}),rh)}function bh(){return Np().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,qd.$6)([(0,qd.Fm)(x,sh),(0,qd.Fm)(_,dh),(0,qd.Fm)(y,hh),(0,qd.Fm)(j,mh),(0,qd.Fm)(S,yh),(0,qd.Fm)(P,yh),(0,qd.Fm)(k,yh),(0,qd.Fm)(C,yh)]);case 2:case"end":return e.stop()}}),oh)}const wh={twoFactorConnector:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Vd,t=arguments.length>1?arguments[1]:void 0,n=Yd[t.type];return n?n(e,t):e}};var Oh,xh=[bh];function kh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Sh(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?kh(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kh(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Ph="two-factor-connector",_h=function(e,t,n,r){var o=Oh||(Oh=(0,ee.jsx)(Fd,{})),a=u.Z.createStore(wh,xh,t,Ph);return m.Z.addToStore(a,!0),d.Z.addToStore(a,!0,["console","remote","notification"]),h.Z.addToStore(a,(function(e){return u.Z.getEvents(jh,e.input)})),u.Z.createApp(Ph,o,a,{input:t,events:n,actions:[],publicPath:r,textResourceModules:["component","common",Ph]})},jh=["onSuccess","onCancel","onResize"],Eh=function(e){return u.Z.useApp({initApp:_h,props:e,packageName:Ph,externalEvents:jh}).component};Eh.propTypes=Sh(Sh({},jh.reduce((function(e,t){return Sh(Sh({},e),{},l()({},t,p().func))}),{})),{},{username:p().string,password:p().string,secret:p().shape({secret:p().string.isRequired,uri:p().string.isRequired}),forced:p().bool});var Ch=u.Z.createBundleableApp(Ph,_h,Eh);u.Z.registerAppInRegistry(Ch.name,Ch.init)})(),c})()));
57
+ */function be(e,t=0){const n=[];return e.forEach((function(e,r){let o=null;e.forEach((function(a,i){if(!a&&null!==o)return n.push(`M${o+t} ${r+t}h${i-o}v1H${o+t}z`),void(o=null);if(i!==e.length-1)a&&null===o&&(o=i);else{if(!a)return;null===o?n.push(`M${i+t},${r+t} h1v1H${i+t}z`):n.push(`M${o+t},${r+t} h${i+1-o}v1H${o+t}z`)}}))})),n.join("")}function we(e,t){return e.slice().map(((e,n)=>n<t.y||n>=t.y+t.h?e:e.map(((e,n)=>(n<t.x||n>=t.x+t.w)&&e))))}function Oe(e,t,n,r){if(null==r)return null;const o=n?4:0,a=e.length+2*o,i=Math.floor(.1*t),c=a/t,u=(r.width||i)*c,s=(r.height||i)*c,l=null==r.x?e.length/2-u/2:r.x*c,f=null==r.y?e.length/2-s/2:r.y*c;let p=null;if(r.excavate){let e=Math.floor(l),t=Math.floor(f);p={x:e,y:t,w:Math.ceil(u+l-e),h:Math.ceil(s+f-t)}}return{x:l,y:f,h:s,w:u,excavation:p}}var xe=function(){try{(new Path2D).addPath(new Path2D)}catch(e){return!1}return!0}();function ke(e){const t=e,{value:n,size:r=he,level:o=me,bgColor:a=ve,fgColor:i=ge,includeMargin:c=ye,style:u,imageSettings:s}=t,l=fe(t,["value","size","level","bgColor","fgColor","includeMargin","style","imageSettings"]),f=null==s?void 0:s.src,p=(0,A.useRef)(null),d=(0,A.useRef)(null),[h,m]=(0,A.useState)(!1);(0,A.useEffect)((()=>{if(null!=p.current){const e=p.current,t=e.getContext("2d");if(!t)return;let u=pe.QrCode.encodeText(n,de[o]).getModules();const l=c?4:0,f=u.length+2*l,h=Oe(u,r,c,s),m=d.current,v=null!=h&&null!==m&&m.complete&&0!==m.naturalHeight&&0!==m.naturalWidth;v&&null!=h.excavation&&(u=we(u,h.excavation));const g=window.devicePixelRatio||1;e.height=e.width=r*g;const y=r/f*g;t.scale(y,y),t.fillStyle=a,t.fillRect(0,0,f,f),t.fillStyle=i,xe?t.fill(new Path2D(be(u,l))):u.forEach((function(e,n){e.forEach((function(e,r){e&&t.fillRect(r+l,n+l,1,1)}))})),v&&t.drawImage(m,h.x+l,h.y+l,h.w,h.h)}})),(0,A.useEffect)((()=>{m(!1)}),[f]);const v=le({height:r,width:r},u);let g=null;return null!=f&&(g=Z().createElement("img",{src:f,key:f,style:{display:"none"},onLoad:()=>{m(!0)},ref:d})),Z().createElement(Z().Fragment,null,Z().createElement("canvas",le({style:v,height:r,width:r,ref:p},l)),g)}function Se(e){const t=e,{value:n,size:r=he,level:o=me,bgColor:a=ve,fgColor:i=ge,includeMargin:c=ye,imageSettings:u}=t,s=fe(t,["value","size","level","bgColor","fgColor","includeMargin","imageSettings"]);let l=pe.QrCode.encodeText(n,de[o]).getModules();const f=c?4:0,p=l.length+2*f,d=Oe(l,r,c,u);let h=null;null!=u&&null!=d&&(null!=d.excavation&&(l=we(l,d.excavation)),h=Z().createElement("image",{xlinkHref:u.src,height:d.h,width:d.w,x:d.x+f,y:d.y+f,preserveAspectRatio:"none"}));const m=be(l,f);return Z().createElement("svg",le({height:r,width:r,viewBox:`0 0 ${p} ${p}`},s),Z().createElement("path",{fill:a,d:`M0,0 h${p}v${p}H0z`,shapeRendering:"crispEdges"}),Z().createElement("path",{fill:i,d:m,shapeRendering:"crispEdges"}),h)}var Pe=e=>{const t=e,{renderAs:n}=t,r=fe(t,["renderAs"]);return"svg"===n?Z().createElement(Se,le({},r)):Z().createElement(ke,le({},r))};const _e=function(e){var t=e.value;return(0,ee.jsx)(Pe,{value:t,renderAs:"svg"})};var je,Ee,Ce,De,Te,Me,Re=V.ZP.div.withConfig({displayName:"StyledQRCodeWrapper"})(je||(je=Y()(["\n display: flex;\n justify-content: center;\n margin: "," "," "," ",";\n"])),q.Z.space(1.2),q.Z.space(1),q.Z.space(1.5),q.Z.space(1)),Ie=V.ZP.div.withConfig({displayName:"StyledParagraph"})(Ee||(Ee=Y()(["\n display: flex;\n justify-content: center;\n margin-top: ",";\n margin-bottom: ",";\n"])),q.Z.space(-1),q.Z.space(-.9));const Ne=function(e){var t=e.secret,n=e.goToSecretVerification;return(0,H.z)(n),(0,ee.jsxs)(ee.Fragment,{children:[Ce||(Ce=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.qrCodeInfo"})})),(0,ee.jsx)(Re,{children:(0,ee.jsx)(_e,{value:t.uri})}),De||(De=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.secretInfo"})})),(0,ee.jsx)(Ie,{children:(0,ee.jsx)(B.ZP.B,{children:t.secret})}),Te||(Te=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.backupInfo"})})),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{ink:"primary",look:"raised",onClick:n,children:Me||(Me=(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.nextButton"}))})})]})};var Ae={goToSecretVerification:function(){return{type:k}}};const Ze=(0,g.connect)((function(e){return{secret:e.twoFactorConnector.secret}}),Ae)((0,v.ZP)(Ne));var Le;const Fe=function(e){var t=e.twoFactorActive,n=e.forced,r=e.requestSecret,o=e.intl;(0,H.z)(r);var a=function(e){return o.formatMessage({id:e})};return(0,ee.jsxs)(ee.Fragment,{children:[(0,ee.jsx)(B.ZP.P,{children:function(){if(t)return Le||(Le=(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.overwriteInfo"}));var e=a(n?"client.two-factor-connector.forcedInfo":"client.two-factor-connector.info");return(0,ee.jsx)("span",{dangerouslySetInnerHTML:{__html:e}})}()}),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:a("client.two-factor-connector.nextButton"),ink:"primary",look:"raised",onClick:r})})]})};var He={initialize:D,requestSecret:function(){return{type:x}}};const Ue=(0,g.connect)((function(e){return{twoFactorActive:e.twoFactorConnector.twoFactorActive,secret:e.twoFactorConnector.secret,forced:e.input.forced}}),He)((0,v.ZP)(Fe));var Be=i(63038),We=i.n(Be),ze=i(28002),Ye=i(6479),Ve=i.n(Ye),qe=i(41505),Ge=i.n(qe),Ke=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},Xe=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qe=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t},$e={outline:"none"},Je=function(e){function t(){var n,r;Ke(this,t);for(var o=arguments.length,a=Array(o),i=0;i<o;i++)a[i]=arguments[i];return n=r=Qe(this,e.call.apply(e,[this].concat(a))),r.state={focused:!1},r._isMounted=!1,r._lastBlurEvent=null,r.ref=Z().createRef(),r._onFocusIn=function(){r._isMounted&&r._lastBlurEvent&&r.isInsideNode(r.ref.current,r._lastBlurEvent.target)&&!r.isInsideNode(r.ref.current,document.activeElement)&&r.setState({focused:!1},(function(){document.removeEventListener("focusin",r._onFocusIn),r.props.onBlur(r._lastBlurEvent)}))},r.onFocus=function(e){var t=r.props.onFocus;r.state.focused||r.setState({focused:!0},(function(){document.addEventListener("focusin",r._onFocusIn),t(e)}))},r.onBlur=function(e){e.persist(),r._lastBlurEvent=e},r.isInsideNode=function(e,t){return null!=e&&e.contains(t)},Qe(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.componentDidMount=function(){null!=document&&document.querySelector("body").setAttribute("tabindex","-1"),this._isMounted=!0},t.prototype.componentWillUnmount=function(){this._isMounted=!1,document.removeEventListener("focusin",this._onFocusIn)},t.prototype.focus=function(){var e=this.ref.current;null!=e&&"function"==typeof e.focus&&e.focus()},t.prototype.render=function(){var e=this.props.children,t=this.state.focused,n={onFocus:this.onFocus,onBlur:this.onBlur};return"function"==typeof e?Z().cloneElement(e({focused:t,getRef:this.ref}),n):Z().createElement("div",Xe({ref:this.ref,style:$e},n),e)},t}(Z().Component);Je.propTypes={children:Ge().oneOfType([Ge().node,Ge().func]).isRequired,onBlur:Ge().func,onFocus:Ge().func},Je.defaultProps={onBlur:function(){},onFocus:function(){}};const et=Je;var tt,nt,rt,ot,at=i(70696),it=i(10535),ct=i(23427),ut=i(319),st=i.n(ut),lt=i(37188),ft=(tt={},l()(tt,ct.Z.condition.BASE,"inherit"),l()(tt,ct.Z.condition.DANGER,X.FS.color("signal.danger")),l()(tt,ct.Z.condition.SUCCESS,X.FS.color("signal.success")),l()(tt,ct.Z.condition.WARNING,X.FS.color("signal.warning")),l()(tt,ct.Z.condition.INFO,X.FS.color("signal.info")),tt),pt=(0,V.ZP)(lt.hc).withConfig({displayName:"StyledSignalList"})(nt||(nt=Y()(["\n && {\n list-style-type: none;\n }\n"]))),dt=V.ZP.span.withConfig({displayName:"StyledSignalListIcon"})(rt||(rt=Y()(["\n position: absolute;\n left: -1.6rem;\n text-align: left;\n"]))),ht=(0,V.ZP)(lt.EF).withConfig({displayName:"StyledSignalListItem"})(ot||(ot=Y()(["\n && {\n color: ",";\n position: relative;\n padding: 0;\n }\n"])),(function(e){return function(e){return ft[e.condition]||"inherit"}(e)}));const mt=function(e){return(0,ee.jsx)(pt,{as:"ul",children:Z().Children.map(e.children,(function(e){return Z().cloneElement(e)}))})};var vt,gt,yt=(vt={},l()(vt,ct.Z.condition.BASE,!1),l()(vt,ct.Z.condition.DANGER,"times"),l()(vt,ct.Z.condition.SUCCESS,"check"),l()(vt,ct.Z.condition.WARNING,"exclamation-triangle"),l()(vt,ct.Z.condition.INFO,"info"),vt),bt=function(e){var t=yt[e.condition];return t?(0,ee.jsx)(U.Z,{icon:t,position:ct.Z.position.SOLE}):gt||(gt=(0,ee.jsx)("i",{children:"•"}))},wt=function(e){return(0,ee.jsxs)(ht,{condition:e.condition,children:[(0,ee.jsx)(dt,{children:bt(e)}),e.label,Z().Children.map(e.children,(function(e){return Z().cloneElement(e)}))]})};wt.defaultProps={condition:ct.Z.condition.BASE};const Ot={List:mt,Item:wt};const xt=function(e){if(!e.error)return null;var t=[];return Object.keys(e.error).forEach((function(n){t.push.apply(t,st()(e.error[n]))})),(0,ee.jsx)(Ot.List,{children:t.map((function(e,t){return(0,ee.jsx)(Ot.Item,{condition:"danger",label:e},t)}))})};var kt,St,Pt,_t,jt,Et,Ct,Dt,Tt,Mt,Rt,It,Nt,At,Zt,Lt=i(79686),Ft=i(30759),Ht=i(27361),Ut=i.n(Ht),Bt={base:function(e){var t=e.theme;return Ut()(t,"colors.text")},shade1:function(e){var t=e.theme;return Ut()(t,"colors.textLight")},shade2:function(e){var t=e.theme;return Ut()(t,"colors.textLighter")},signal:function(e){var t=e.theme,n=e.signal;return Ut()(t,"colors.signal.".concat(n))},hasValue:function(e){var t=e.theme;return Ut()(t,"colors.signal.info")}},Wt={base:function(e){var t=e.theme;return Ut()(t,"colors.border")},signal:function(e){var t=e.theme,n=e.signal;return Ut()(t,"colors.signal.".concat(n))},isDirty:function(e){var t=e.theme;return Ut()(t,"colors.secondaryLight")},transparent:function(){return"transparent"}},zt=i(76538),Yt="1.1px",Vt=function(e){var t=e.isDisplay,n=e.immutable;return"cursor: ".concat(!t&&n?"not-allowed":"auto",";")},qt=V.ZP.label.withConfig({displayName:"StyledStatedValueLabel"})(St||(St=Y()(["\n &&& {\n display: flex;\n width: 40%;\n flex-grow: 1;\n flex-basis: 125px;\n ","\n background-color: ",";\n pointer-events: auto;\n ","\n word-break: break-word;\n white-space: pre-wrap;\n ","\n ","\n ","\n }\n"])),(0,Ft.Z)({lineHeight:X.FS.lineHeight("dense")}),X.FS.color("paper"),(function(e){return Vt(e)}),(function(e){return"outside"===e.labelPosition&&(0,V.iv)(Pt||(Pt=Y()(["\n margin-bottom: ",";\n display: block;\n width: auto;\n "])),q.Z.space(-1.5))}),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(_t||(_t=Y()(["\n flex-basis: unset;\n position: absolute;\n top: 0;\n z-index: 1;\n display: inline-block;\n padding: 0 "," 0 ","; // if immutable remove left padding\n width: fit-content;\n left: ",";\n "])),q.Z.space(-2),(function(e){return e.immutable&&"0"}),q.Z.space(-1.8))}),(function(e){return e.styles})),Gt=V.ZP.div.withConfig({displayName:"StyledInputArea"})(jt||(jt=Y()(["\n width: 60%;\n flex-grow: 1;\n ","\n"])),(function(e){return"outside"===e.labelPosition&&(0,V.iv)(Et||(Et=Y()(["\n width: auto;\n "])))})),Kt=V.ZP.div.withConfig({displayName:"StyledStatedValueBox"})(Ct||(Ct=Y()(["\n &&& {\n position: relative;\n height: fit-content; // prevent height getting bigger due to tall labels\n border: "," solid ",";\n border-radius: ",";\n padding: "," ",";\n ","\n ","\n\n > "," {\n padding-top: ",";\n position: relative;\n top: 5px;\n\n p:first-of-type {\n margin-top: 0;\n }\n }\n ","\n ","\n }\n"])),Yt,(function(e){return Wt[function(e){var t=e.immutable,n=e.isDisplay,r=e.signal;return e.isDirty?"isDirty":n||t?"transparent":r?"signal":"base"}(e)](e)}),X.FS.radii("form"),q.Z.space(-2.5),q.Z.space(-1.5),(function(e){return!e.immutable&&function(e){var t=Ut()(e.theme,"colors.signal.info",ct.Z.fallbackColors.INFO);return(0,V.iv)(kt||(kt=Y()(["\n transition: border-color ease-in-out 100ms;\n will-change: border-color;\n\n &:focus,\n &:focus-within {\n border-color: ",";\n box-shadow: 0 0 6px ",";\n outline: 0;\n\n /**\n * Disable box-shadow for Safari\n * in order to be able to tab through the form fluently\n */\n @media not all and (min-resolution: 0.001dpcm) {\n @supports (-webkit-appearance: none) {\n box-shadow: none;\n }\n }\n }\n "])),t,(0,zt.DZ)(.4,t))}(e)}),(function(e){return Vt(e)}),Lt.j,(function(e){return e.isDisplay&&q.Z.space(-1)}),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(Dt||(Dt=Y()(["\n padding: "," "," "," ",";\n "])),q.Z.space(-1),q.Z.space(-1.7),q.Z.space(-2),q.Z.space(-1))}),(function(e){return e.styles})),Xt=V.ZP.p.withConfig({displayName:"StyledStatedValueDescription"})(Tt||(Tt=Y()(["\n &&& {\n ","\n }\n"])),(0,Ft.Z)({fontSize:q.Z.font(-1)})),Qt=V.ZP.div.withConfig({displayName:"StyledStatedValueError"})(Mt||(Mt=Y()([""]))),$t=V.ZP.div.withConfig({displayName:"StyledStatedValueOuterWrapper"})(Rt||(Rt=Y()(["\n &:not(:last-child) {\n margin-bottom: ",";\n }\n ","\n"])),q.Z.space(-.7),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(It||(It=Y()(["\n padding-top: ",";\n margin-bottom: 0.65rem;\n position: relative;\n "])),q.Z.space(-1.5))})),Jt=V.ZP.div.withConfig({displayName:"StyledStatedValueInnerWrapper"})(Nt||(Nt=Y()(["\n &&& {\n display: flex;\n flex-wrap: wrap;\n gap: ",";\n align-items: center;\n\n ",",\n ",",\n "," {\n margin-bottom: ",";\n\n &:last-child {\n margin-bottom: 0;\n }\n }\n\n "," {\n margin-left: calc("," + ",");\n }\n ","\n ","\n }\n"])),q.Z.space(-1.5),Kt,Xt,Qt,q.Z.space(-2),Xt,q.Z.space(-1),Yt,(function(e){return"outside"===e.labelPosition&&(0,V.iv)(At||(At=Y()(["\n display: block;\n "])))}),(function(e){return"inside"===e.labelPosition&&(0,V.iv)(Zt||(Zt=Y()(["\n padding-top: 0;\n "])))}));function en(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function tn(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?en(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):en(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const nn=function(e){var t,n,r,o=e.children,a=e.description,i=e.dirty,c=e.isDisplay,u=e.error,s=e.hasValue,l=e.id,f=e.label,p=e.mandatory,d=e.mandatoryTitle,h=e.immutable,m=e.touched,v=e.signal,g=e.labelPosition,y=e.styles,b=!h&&m&&u&&Object.keys(u).length>0,w=p&&d?", ".concat(d):"",O="".concat(at.Z.adjustedHTMLString(f)).concat(w),x=v||function(e,t,n,r){return t?ct.Z.condition.DANGER:e?ct.Z.condition.INFO:n&&!r?ct.Z.condition.WARNING:void 0}(i,b,p,s),k={__html:"".concat(it.Z.sanitizeHtml(f)).concat(p?" *":"")},S=!c&&!h&&{htmlFor:l};return(0,ee.jsx)(et,{children:function(e){var l=e.getRef;return(0,ee.jsx)($t,{labelPosition:g,children:(0,ee.jsxs)(Jt,{labelPosition:g,ref:l,label:f,children:[f&&(0,ee.jsx)(qt,tn(tn({},S),{},{hasValue:s,dirty:i,title:O,immutable:h,isDisplay:c,signal:x,labelPosition:g,styles:null==y?void 0:y.labelStyles,children:t||(t=(0,ee.jsx)("span",{dangerouslySetInnerHTML:k}))})),(0,ee.jsxs)(Gt,{labelPosition:g,children:[(0,ee.jsx)(Kt,{hasValue:s,immutable:h,isDisplay:c,signal:x,labelPosition:g,styles:null==y?void 0:y.valueStyles,children:o}),b&&(n||(n=(0,ee.jsx)(Qt,{children:(0,ee.jsx)(xt,{error:u})}))),a&&(r||(r=(0,ee.jsx)(Xt,{children:a})))]})]})})}})};var rn,on,an,cn=function(e){return(0,V.iv)(rn||(rn=Y()(["\n color: ",";\n font-weight: ",";\n"])),Bt[function(e){var t=e.isDisplay,n=e.immutable,r=e.signal,o=e.hasValue;return r?"signal":o?"hasValue":t?"shade1":n?"base":"shade1"}(e)](e),(function(e){return e.dirty?X.FS.fontWeight("bold"):X.FS.fontWeight("regular")}))},un=function(){return(0,V.iv)(on||(on=Y()(["\n padding-top: ",";\n padding-left: ",";\n"])),(function(e){var t=e.isDisplay,n=e.immutable;if(t&&n)return(0,V.iv)(an||(an=Y()(["\n ","\n "])),q.Z.space(-1))}),(function(e){return e.immutable&&0}))},sn=["labelPosition"];function ln(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const fn=function(e){var t=e.labelPosition,n=Ve()(e,sn);return(0,ee.jsx)(nn,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ln(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ln(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({styles:{labelStyles:cn,valueStyles:un},labelPosition:t||"outside-responsive"},n))};var pn,dn,hn,mn=function(e){return e.signal?"signal":"shade1"},vn=function(e){return(0,V.iv)(pn||(pn=Y()(["\n color: ",";\n font-weight: ",";\n"])),Bt[mn(e)](e),X.FS.fontWeight("bold"))},gn=function(){return(0,V.iv)(dn||(dn=Y()(["\n padding-top: ",";\n padding-left: ",";\n"])),(function(e){var t=e.isDisplay,n=e.immutable;return n?0:t&&n?(0,V.iv)(hn||(hn=Y()(["\n ","\n "])),q.Z.space(-1)):void 0}),(function(e){return e.immutable&&0}))},yn=["labelPosition"];function bn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const wn=function(e){var t=e.labelPosition,n=Ve()(e,yn);return(0,ee.jsx)(nn,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bn(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({styles:{labelStyles:vn,valueStyles:gn},labelPosition:t||"outside"},n))};var On,xn=(On={},l()(On,ze.Z.EmbedType.admin,fn),l()(On,ze.Z.EmbedType.widget,wn),On);const kn=ze.Z.embedStrategyFactory({mapping:xn});var Sn,Pn,_n,jn,En,Cn,Dn,Tn,Mn,Rn=i(57557),In=i.n(Rn),Nn=i(41609),An=i.n(Nn),Zn=i(58808),Ln=i.n(Zn),Fn=i(41291),Hn=i(93235),Un=(0,V.iv)(Sn||(Sn=Y()(["\n align-items: center;\n cursor: ",";\n display: flex;\n"])),(function(e){return e.immutable?"not-allowed":"default"})),Bn=V.ZP.label.withConfig({displayName:"StyledEditableWrapper"})(Pn||(Pn=Y()(["\n &&& {\n margin: 0; /* reset Bootstrap and Ext JS */\n padding: 0; /* reset Ext JS */\n ","\n }\n"])),Un),Wn=(0,V.iv)(_n||(_n=Y()(["\n background-color: transparent;\n border: 0;\n cursor: ",";\n flex-grow: 1;\n min-height: 2.6rem;\n min-width: 0;\n outline: 0;\n padding: 0;\n ","\n &::-ms-clear {\n display: none;\n }\n\n &::-webkit-clear-button {\n display: none;\n }\n\n &::-webkit-inner-spin-button {\n display: none;\n }\n\n &[type='number'] {\n appearance: textfield;\n }\n\n &[type='search'] {\n appearance: none;\n }\n\n &:disabled {\n -webkit-text-fill-color: ","; // Safari fix\n opacity: 1; // iOS fix\n }\n\n /* remove indicators */\n &[type='date'],\n &[type='datetime-local'],\n &[type='month'],\n &[type='time'],\n &[type='week'] {\n appearance: none;\n display: flex;\n\n /* reset margin on smaller screens */\n ::-webkit-date-and-time-value {\n ","\n }\n }\n\n // allow pointer event only on touch devices\n @media (pointer: coarse) {\n pointer-events: ",";\n }\n"])),(function(e){return e.immutable?"not-allowed":"default"}),(function(){return(0,Ft.Z)({color:X.FS.color("text")})}),X.FS.color("text"),(function(e){return e.immutable&&"margin: unset;"}),(function(e){return e.immutable?"none":"auto"})),zn=(0,V.iv)(jn||(jn=Y()(["\n display: flex;\n align-items: center;\n"]))),Yn=V.ZP.div.withConfig({displayName:"StyledEditableControl"})(En||(En=Y()(["\n &&& {\n ","\n }\n"])),zn),Vn=V.ZP.span.withConfig({displayName:"StyledEditableValue"})(Cn||(Cn=Y()(["\n width: 100%;\n\n && {\n //url\n [type='url'] + .input-group-addon > a {\n color: inherit; // reset bootstrap default\n }\n\n //url\n [type='tel'] + .input-group-addon > a {\n color: inherit; // reset bootstrap default\n }\n\n //date\n .date-edit {\n .input-group-addon {\n cursor: pointer;\n }\n\n input {\n z-index: 0;\n }\n\n &.disabled {\n input {\n cursor: not-allowed;\n }\n }\n\n .right-addon {\n position: relative;\n }\n\n .right-addon input {\n padding-right: 30px;\n }\n\n .reset {\n position: absolute;\n padding-right: 10px;\n padding-top: 5px;\n right: 0;\n color: #999;\n font-size: 18px;\n font-style: normal;\n cursor: pointer;\n }\n\n .reset:hover {\n color: ",";\n }\n }\n }\n"])),X.FS.color("signal.danger")),qn=i(50008),Gn=i.n(qn),Kn=function(e){return-1*Math.abs(e)},Xn=function(e){var t=[e.street,e.postcode,e.city,e.country].filter(Boolean).map((function(e){var t="object"===Gn()(e)&&e.display?e.display:e;return encodeURIComponent(t)})).join("+");return"".concat("https://www.google.com/maps/search/?api=1&query=").concat(t)},Qn=V.ZP.div.withConfig({displayName:"StyledLocationEdit"})(Dn||(Dn=Y()(["\n && {\n ","\n position: relative;\n\n div {\n :nth-of-type(1) {\n flex: 0 0 13ch;\n margin-right: ",";\n }\n\n :nth-of-type(2) {\n flex: 1 1 auto;\n }\n }\n\n > span {\n flex: 0 0 auto;\n margin-right: ",";\n color: ",";\n }\n\n .react-autosuggest__input {\n ","\n width: 100%;\n }\n\n .react-autosuggest__suggestions-container--open {\n width: calc(100% + 17.5px);\n background-color: ",";\n box-shadow: 0 0 6px ",";\n border: 1px solid ",";\n bottom: -9px;\n left: -10px;\n max-height: 300px;\n overflow-y: auto;\n position: absolute;\n transform: translateY(100%);\n z-index: 2; // higher than StyledIndicatorsContainerWrapper\n }\n\n .react-autosuggest__suggestions-list {\n margin: 0;\n padding: 0;\n list-style-type: none;\n }\n\n .react-autosuggest__suggestion {\n cursor: pointer;\n padding: 8px 12px;\n }\n\n .react-autosuggest__suggestion--highlighted {\n background-color: ",";\n }\n }\n"])),Un,q.Z.space(-2),q.Z.space(-2),(function(e){var t=e.immutable,n=e.theme;return t?Ut()(n,"colors.textDisabled"):Ut()(n,"colors.text")}),Wn,X.FS.color("paper"),X.FS.color("signal.info"),X.FS.color("secondaryLight"),X.FS.color("backgroundItemHover")),$n=(0,V.ZP)(Qn).withConfig({displayName:"StyledAddressEdit"})(Tn||(Tn=Y()(["\n && {\n div {\n :nth-of-type(1) {\n flex: auto;\n width: 100%;\n }\n }\n }\n"])));function Jn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function er(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jn(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jn(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const tr=function(e){var t,n=e.onChange,r=e.options,o=e.value,a=e.id,i=e.immutable,c=e.name,u=function(e){var t=e.street,n=e.houseNr;return n?"".concat(t," ").concat(n):t},s=function(e){var t=e.street,n=e.state,r=e.country,o=e.postcode,a=e.city;if(!t)return null;var i=u(e),c=n?"- ".concat(n):"",s=r?"/ ".concat(r.display):"";return(0,ee.jsxs)(B.ZP.Span,{children:[i,", ",o," ",a," ",c," ",s]})},f=function(e,t){var o=t.suggestion;!0===o.validationRequired?r.validateLocation(o,n):n(o)},p=function(e){var t=e.value,n=r.locationValues,o=n.postcode,a=n.city,i=n.country,c={street:t,postcode:o,city:a};r.fetchSuggestions(c,i)},d={id:a,value:o&&o.street?u(o):"",onChange:(t="street",function(e,r){var a=r.newValue;n(er(er({},o),{},l()({},t,a)))}),disabled:i};return(0,ee.jsx)(et,{children:function(e){var t,n,o,a,u,l=e.getRef;return(0,ee.jsxs)($n,{immutable:i,name:c,ref:l,children:[(0,ee.jsx)(Ln(),{suggestions:r.suggestions||[],onSuggestionsFetchRequested:p,getSuggestionValue:(u="street",function(e){return e[u]}),renderSuggestion:s,onSuggestionsClearRequested:function(){},inputProps:d,onSuggestionSelected:f,focusInputOnSuggestionClick:!1,shouldRenderSuggestions:function(e){return e&&!i}}),(0,ee.jsxs)(Yn,{children:[r.isLoading&&(Mn||(Mn=(0,ee.jsx)(Hn.Z,{size:"1.8rem"}))),(t=r.locationValues,n=t.street,o=t.city,a=t.postcode,Boolean(n&&(o||a))&&(0,ee.jsx)(Fn.Z,{href:Xn(r.locationValues),icon:"map-marked",tabIndex:-1,target:"_blank",dense:!1,title:r.mapButtonTitle||"Show on map",neutral:!0}))]})]})}})};var nr=i(14293),rr=i.n(nr),or=i(23493),ar=i.n(or),ir=i(33417),cr=i(1972),ur=i(32924),sr=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];var lr=i(2717);function fr(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function pr(e,t){return(pr=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function dr(e){return(dr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}var hr=i(62360);function mr(e,t){if(t&&("object"===(0,hr.Z)(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}function vr(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=dr(e);if(t){var o=dr(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return mr(this,n)}}var gr=i(31599);var yr=i(78001);function br(e){return function(e){if(Array.isArray(e))return(0,gr.Z)(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||(0,yr.Z)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var wr=i(29382),Or=i(1537),xr=Number.isNaN||function(e){return"number"==typeof e&&e!=e};function kr(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(r=e[n],o=t[n],!(r===o||xr(r)&&xr(o)))return!1;var r,o;return!0}for(var Sr={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},Pr=function(e){return(0,Or.tZ)("span",(0,lr.Z)({css:Sr},e))},_r={guidance:function(e){var t=e.isSearchable,n=e.isMulti,r=e.isDisabled,o=e.tabSelectsValue;switch(e.context){case"menu":return"Use Up and Down to choose options".concat(r?"":", press Enter to select the currently focused option",", press Escape to exit the menu").concat(o?", press Tab to select the option and exit the menu":"",".");case"input":return"".concat(e["aria-label"]||"Select"," is focused ").concat(t?",type to refine list":"",", press Down to open the menu, ").concat(n?" press left to focus selected values":"");case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(e){var t=e.action,n=e.label,r=void 0===n?"":n,o=e.labels,a=e.isDisabled;switch(t){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(r,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(o.length>1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return"option ".concat(r,a?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(e){var t=e.context,n=e.focused,r=e.options,o=e.label,a=void 0===o?"":o,i=e.selectValue,c=e.isDisabled,u=e.isSelected,s=function(e,t){return e&&e.length?"".concat(e.indexOf(t)+1," of ").concat(e.length):""};if("value"===t&&i)return"value ".concat(a," focused, ").concat(s(i,n),".");if("menu"===t){var l=c?" disabled":"",f="".concat(u?"selected":"focused").concat(l);return"option ".concat(a," ").concat(f,", ").concat(s(r,n),".")}return""},onFilter:function(e){var t=e.inputValue,n=e.resultsMessage;return"".concat(n).concat(t?" for search term "+t:"",".")}},jr=function(e){var t=e.ariaSelection,n=e.focusedOption,r=e.focusedValue,o=e.focusableOptions,a=e.isFocused,i=e.selectValue,c=e.selectProps,u=e.id,s=c.ariaLiveMessages,l=c.getOptionLabel,f=c.inputValue,p=c.isMulti,d=c.isOptionDisabled,h=c.isSearchable,m=c.menuIsOpen,v=c.options,g=c.screenReaderStatus,y=c.tabSelectsValue,b=c["aria-label"],w=c["aria-live"],O=(0,A.useMemo)((function(){return(0,ir.Z)((0,ir.Z)({},_r),s||{})}),[s]),x=(0,A.useMemo)((function(){var e,n="";if(t&&O.onChange){var r=t.option,o=t.options,a=t.removedValue,c=t.removedValues,u=t.value,s=a||r||(e=u,Array.isArray(e)?null:e),f=s?l(s):"",p=o||c||void 0,h=p?p.map(l):[],m=(0,ir.Z)({isDisabled:s&&d(s,i),label:f,labels:h},t);n=O.onChange(m)}return n}),[t,O,d,i,l]),k=(0,A.useMemo)((function(){var e="",t=n||r,a=!!(n&&i&&i.includes(n));if(t&&O.onFocus){var c={focused:t,label:l(t),isDisabled:d(t,i),isSelected:a,options:o,context:t===n?"menu":"value",selectValue:i};e=O.onFocus(c)}return e}),[n,r,l,d,O,o,i]),S=(0,A.useMemo)((function(){var e="";if(m&&v.length&&O.onFilter){var t=g({count:o.length});e=O.onFilter({inputValue:f,resultsMessage:t})}return e}),[o,f,m,O,v,g]),P=(0,A.useMemo)((function(){var e="";if(O.guidance){var t=r?"value":m?"menu":"input";e=O.guidance({"aria-label":b,context:t,isDisabled:n&&d(n,i),isMulti:p,isSearchable:h,tabSelectsValue:y})}return e}),[b,n,r,p,d,h,m,O,i,y]),_="".concat(k," ").concat(S," ").concat(P),j=(0,Or.tZ)(A.Fragment,null,(0,Or.tZ)("span",{id:"aria-selection"},x),(0,Or.tZ)("span",{id:"aria-context"},_)),E="initial-input-focus"===(null==t?void 0:t.action);return(0,Or.tZ)(A.Fragment,null,(0,Or.tZ)(Pr,{id:u},E&&j),(0,Or.tZ)(Pr,{"aria-live":w,"aria-atomic":"false","aria-relevant":"additions text"},a&&!E&&j))},Er=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],Cr=new RegExp("["+Er.map((function(e){return e.letters})).join("")+"]","g"),Dr={},Tr=0;Tr<Er.length;Tr++)for(var Mr=Er[Tr],Rr=0;Rr<Mr.letters.length;Rr++)Dr[Mr.letters[Rr]]=Mr.base;var Ir=function(e){return e.replace(Cr,(function(e){return Dr[e]}))},Nr=function(e,t){void 0===t&&(t=kr);var n=null;function r(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];if(n&&n.lastThis===this&&t(r,n.lastArgs))return n.lastResult;var a=e.apply(this,r);return n={lastResult:a,lastArgs:r,lastThis:this},a}return r.clear=function(){n=null},r}(Ir),Ar=function(e){return e.replace(/^\s+|\s+$/g,"")},Zr=function(e){return"".concat(e.label," ").concat(e.value)},Lr=["innerRef"];function Fr(e){var t=e.innerRef,n=(0,ur.Z)(e,Lr),r=(0,wr.r)(n,"onExited","in","enter","exit","appear");return(0,Or.tZ)("input",(0,lr.Z)({ref:t},r,{css:(0,Or.iv)({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var Hr=["boxSizing","height","overflow","paddingRight","position"],Ur={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function Br(e){e.preventDefault()}function Wr(e){e.stopPropagation()}function zr(){var e=this.scrollTop,t=this.scrollHeight,n=e+this.offsetHeight;0===e?this.scrollTop=1:n===t&&(this.scrollTop=e-1)}function Yr(){return"ontouchstart"in window||navigator.maxTouchPoints}var Vr=!("undefined"==typeof window||!window.document||!window.document.createElement),qr=0,Gr={capture:!1,passive:!1};var Kr=function(){return document.activeElement&&document.activeElement.blur()},Xr={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function Qr(e){var t=e.children,n=e.lockEnabled,r=e.captureEnabled,o=function(e){var t=e.isEnabled,n=e.onBottomArrive,r=e.onBottomLeave,o=e.onTopArrive,a=e.onTopLeave,i=(0,A.useRef)(!1),c=(0,A.useRef)(!1),u=(0,A.useRef)(0),s=(0,A.useRef)(null),l=(0,A.useCallback)((function(e,t){if(null!==s.current){var u=s.current,l=u.scrollTop,f=u.scrollHeight,p=u.clientHeight,d=s.current,h=t>0,m=f-p-l,v=!1;m>t&&i.current&&(r&&r(e),i.current=!1),h&&c.current&&(a&&a(e),c.current=!1),h&&t>m?(n&&!i.current&&n(e),d.scrollTop=f,v=!0,i.current=!0):!h&&-t>l&&(o&&!c.current&&o(e),d.scrollTop=0,v=!0,c.current=!0),v&&function(e){e.preventDefault(),e.stopPropagation()}(e)}}),[n,r,o,a]),f=(0,A.useCallback)((function(e){l(e,e.deltaY)}),[l]),p=(0,A.useCallback)((function(e){u.current=e.changedTouches[0].clientY}),[]),d=(0,A.useCallback)((function(e){var t=u.current-e.changedTouches[0].clientY;l(e,t)}),[l]),h=(0,A.useCallback)((function(e){if(e){var t=!!wr.s&&{passive:!1};e.addEventListener("wheel",f,t),e.addEventListener("touchstart",p,t),e.addEventListener("touchmove",d,t)}}),[d,p,f]),m=(0,A.useCallback)((function(e){e&&(e.removeEventListener("wheel",f,!1),e.removeEventListener("touchstart",p,!1),e.removeEventListener("touchmove",d,!1))}),[d,p,f]);return(0,A.useEffect)((function(){if(t){var e=s.current;return h(e),function(){m(e)}}}),[t,h,m]),function(e){s.current=e}}({isEnabled:void 0===r||r,onBottomArrive:e.onBottomArrive,onBottomLeave:e.onBottomLeave,onTopArrive:e.onTopArrive,onTopLeave:e.onTopLeave}),a=function(e){var t=e.isEnabled,n=e.accountForScrollbars,r=void 0===n||n,o=(0,A.useRef)({}),a=(0,A.useRef)(null),i=(0,A.useCallback)((function(e){if(Vr){var t=document.body,n=t&&t.style;if(r&&Hr.forEach((function(e){var t=n&&n[e];o.current[e]=t})),r&&qr<1){var a=parseInt(o.current.paddingRight,10)||0,i=document.body?document.body.clientWidth:0,c=window.innerWidth-i+a||0;Object.keys(Ur).forEach((function(e){var t=Ur[e];n&&(n[e]=t)})),n&&(n.paddingRight="".concat(c,"px"))}t&&Yr()&&(t.addEventListener("touchmove",Br,Gr),e&&(e.addEventListener("touchstart",zr,Gr),e.addEventListener("touchmove",Wr,Gr))),qr+=1}}),[r]),c=(0,A.useCallback)((function(e){if(Vr){var t=document.body,n=t&&t.style;qr=Math.max(qr-1,0),r&&qr<1&&Hr.forEach((function(e){var t=o.current[e];n&&(n[e]=t)})),t&&Yr()&&(t.removeEventListener("touchmove",Br,Gr),e&&(e.removeEventListener("touchstart",zr,Gr),e.removeEventListener("touchmove",Wr,Gr)))}}),[r]);return(0,A.useEffect)((function(){if(t){var e=a.current;return i(e),function(){c(e)}}}),[t,i,c]),function(e){a.current=e}}({isEnabled:n});return(0,Or.tZ)(A.Fragment,null,n&&(0,Or.tZ)("div",{onClick:Kr,css:Xr}),t((function(e){o(e),a(e)})))}var $r={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},Jr=function(e){var t=e.name,n=e.onFocus;return(0,Or.tZ)("input",{required:!0,name:t,tabIndex:-1,"aria-hidden":"true",onFocus:n,css:$r,value:"",onChange:function(){}})},eo={clearIndicator:wr.a,container:wr.b,control:wr.d,dropdownIndicator:wr.e,group:wr.g,groupHeading:wr.f,indicatorsContainer:wr.i,indicatorSeparator:wr.h,input:wr.j,loadingIndicator:wr.l,loadingMessage:wr.k,menu:wr.m,menuList:wr.n,menuPortal:wr.o,multiValue:wr.p,multiValueLabel:wr.q,multiValueRemove:wr.t,noOptionsMessage:wr.u,option:wr.v,placeholder:wr.w,singleValue:wr.x,valueContainer:wr.y};var to,no={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},ro={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:(0,wr.z)(),captureMenuScroll:!(0,wr.z)(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(e,t){if(e.data.__isNew__)return!0;var n=(0,ir.Z)({ignoreCase:!0,ignoreAccents:!0,stringify:Zr,trim:!0,matchFrom:"any"},to),r=n.ignoreCase,o=n.ignoreAccents,a=n.stringify,i=n.trim,c=n.matchFrom,u=i?Ar(t):t,s=i?Ar(a(e)):a(e);return r&&(u=u.toLowerCase(),s=s.toLowerCase()),o&&(u=Nr(u),s=Ir(s)),"start"===c?s.substr(0,u.length)===u:s.indexOf(u)>-1},formatGroupLabel:function(e){return e.label},getOptionLabel:function(e){return e.label},getOptionValue:function(e){return e.value},isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(e){return!!e.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!(0,wr.A)(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(e){var t=e.count;return"".concat(t," result").concat(1!==t?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function oo(e,t,n,r){return{type:"option",data:t,isDisabled:lo(e,t,n),isSelected:fo(e,t,n),label:uo(e,t),value:so(e,t),index:r}}function ao(e,t){return e.options.map((function(n,r){if("options"in n){var o=n.options.map((function(n,r){return oo(e,n,t,r)})).filter((function(t){return co(e,t)}));return o.length>0?{type:"group",data:n,options:o,index:r}:void 0}var a=oo(e,n,t,r);return co(e,a)?a:void 0})).filter(wr.K)}function io(e){return e.reduce((function(e,t){return"group"===t.type?e.push.apply(e,br(t.options.map((function(e){return e.data})))):e.push(t.data),e}),[])}function co(e,t){var n=e.inputValue,r=void 0===n?"":n,o=t.data,a=t.isSelected,i=t.label,c=t.value;return(!ho(e)||!a)&&po(e,{label:i,value:c,data:o},r)}var uo=function(e,t){return e.getOptionLabel(t)},so=function(e,t){return e.getOptionValue(t)};function lo(e,t,n){return"function"==typeof e.isOptionDisabled&&e.isOptionDisabled(t,n)}function fo(e,t,n){if(n.indexOf(t)>-1)return!0;if("function"==typeof e.isOptionSelected)return e.isOptionSelected(t,n);var r=so(e,t);return n.some((function(t){return so(e,t)===r}))}function po(e,t,n){return!e.filterOption||e.filterOption(t,n)}var ho=function(e){var t=e.hideSelectedOptions,n=e.isMulti;return void 0===t?n:t},mo=1,vo=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&pr(e,t)}(a,e);var t,n,r,o=vr(a);function a(e){var t;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=o.call(this,e)).state={ariaSelection:null,focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0},t.blockOptionHover=!1,t.isComposing=!1,t.commonProps=void 0,t.initialTouchX=0,t.initialTouchY=0,t.instancePrefix="",t.openAfterFocus=!1,t.scrollToFocusedOptionOnUpdate=!1,t.userIsDragging=void 0,t.controlRef=null,t.getControlRef=function(e){t.controlRef=e},t.focusedOptionRef=null,t.getFocusedOptionRef=function(e){t.focusedOptionRef=e},t.menuListRef=null,t.getMenuListRef=function(e){t.menuListRef=e},t.inputRef=null,t.getInputRef=function(e){t.inputRef=e},t.focus=t.focusInput,t.blur=t.blurInput,t.onChange=function(e,n){var r=t.props,o=r.onChange,a=r.name;n.name=a,t.ariaOnChange(e,n),o(e,n)},t.setValue=function(e,n,r){var o=t.props,a=o.closeMenuOnSelect,i=o.isMulti,c=o.inputValue;t.onInputChange("",{action:"set-value",prevInputValue:c}),a&&(t.setState({inputIsHiddenAfterUpdate:!i}),t.onMenuClose()),t.setState({clearFocusValueOnUpdate:!0}),t.onChange(e,{action:n,option:r})},t.selectOption=function(e){var n=t.props,r=n.blurInputOnSelect,o=n.isMulti,a=n.name,i=t.state.selectValue,c=o&&t.isOptionSelected(e,i),u=t.isOptionDisabled(e,i);if(c){var s=t.getOptionValue(e);t.setValue((0,wr.B)(i.filter((function(e){return t.getOptionValue(e)!==s}))),"deselect-option",e)}else{if(u)return void t.ariaOnChange((0,wr.C)(e),{action:"select-option",option:e,name:a});o?t.setValue((0,wr.B)([].concat(br(i),[e])),"select-option",e):t.setValue((0,wr.C)(e),"select-option")}r&&t.blurInput()},t.removeValue=function(e){var n=t.props.isMulti,r=t.state.selectValue,o=t.getOptionValue(e),a=r.filter((function(e){return t.getOptionValue(e)!==o})),i=(0,wr.D)(n,a,a[0]||null);t.onChange(i,{action:"remove-value",removedValue:e}),t.focusInput()},t.clearValue=function(){var e=t.state.selectValue;t.onChange((0,wr.D)(t.props.isMulti,[],null),{action:"clear",removedValues:e})},t.popValue=function(){var e=t.props.isMulti,n=t.state.selectValue,r=n[n.length-1],o=n.slice(0,n.length-1),a=(0,wr.D)(e,o,o[0]||null);t.onChange(a,{action:"pop-value",removedValue:r})},t.getValue=function(){return t.state.selectValue},t.cx=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return wr.E.apply(void 0,[t.props.classNamePrefix].concat(n))},t.getOptionLabel=function(e){return uo(t.props,e)},t.getOptionValue=function(e){return so(t.props,e)},t.getStyles=function(e,n){var r=t.props.unstyled,o=eo[e](n,r);o.boxSizing="border-box";var a=t.props.styles[e];return a?a(o,n):o},t.getClassNames=function(e,n){var r,o;return null===(r=(o=t.props.classNames)[e])||void 0===r?void 0:r.call(o,n)},t.getElementId=function(e){return"".concat(t.instancePrefix,"-").concat(e)},t.getComponents=function(){return(0,wr.F)(t.props)},t.buildCategorizedOptions=function(){return ao(t.props,t.state.selectValue)},t.getCategorizedOptions=function(){return t.props.menuIsOpen?t.buildCategorizedOptions():[]},t.buildFocusableOptions=function(){return io(t.buildCategorizedOptions())},t.getFocusableOptions=function(){return t.props.menuIsOpen?t.buildFocusableOptions():[]},t.ariaOnChange=function(e,n){t.setState({ariaSelection:(0,ir.Z)({value:e},n)})},t.onMenuMouseDown=function(e){0===e.button&&(e.stopPropagation(),e.preventDefault(),t.focusInput())},t.onMenuMouseMove=function(e){t.blockOptionHover=!1},t.onControlMouseDown=function(e){if(!e.defaultPrevented){var n=t.props.openMenuOnClick;t.state.isFocused?t.props.menuIsOpen?"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&t.onMenuClose():n&&t.openMenu("first"):(n&&(t.openAfterFocus=!0),t.focusInput()),"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&e.preventDefault()}},t.onDropdownIndicatorMouseDown=function(e){if(!(e&&"mousedown"===e.type&&0!==e.button||t.props.isDisabled)){var n=t.props,r=n.isMulti,o=n.menuIsOpen;t.focusInput(),o?(t.setState({inputIsHiddenAfterUpdate:!r}),t.onMenuClose()):t.openMenu("first"),e.preventDefault()}},t.onClearIndicatorMouseDown=function(e){e&&"mousedown"===e.type&&0!==e.button||(t.clearValue(),e.preventDefault(),t.openAfterFocus=!1,"touchend"===e.type?t.focusInput():setTimeout((function(){return t.focusInput()})))},t.onScroll=function(e){"boolean"==typeof t.props.closeMenuOnScroll?e.target instanceof HTMLElement&&(0,wr.G)(e.target)&&t.props.onMenuClose():"function"==typeof t.props.closeMenuOnScroll&&t.props.closeMenuOnScroll(e)&&t.props.onMenuClose()},t.onCompositionStart=function(){t.isComposing=!0},t.onCompositionEnd=function(){t.isComposing=!1},t.onTouchStart=function(e){var n=e.touches,r=n&&n.item(0);r&&(t.initialTouchX=r.clientX,t.initialTouchY=r.clientY,t.userIsDragging=!1)},t.onTouchMove=function(e){var n=e.touches,r=n&&n.item(0);if(r){var o=Math.abs(r.clientX-t.initialTouchX),a=Math.abs(r.clientY-t.initialTouchY);t.userIsDragging=o>5||a>5}},t.onTouchEnd=function(e){t.userIsDragging||(t.controlRef&&!t.controlRef.contains(e.target)&&t.menuListRef&&!t.menuListRef.contains(e.target)&&t.blurInput(),t.initialTouchX=0,t.initialTouchY=0)},t.onControlTouchEnd=function(e){t.userIsDragging||t.onControlMouseDown(e)},t.onClearIndicatorTouchEnd=function(e){t.userIsDragging||t.onClearIndicatorMouseDown(e)},t.onDropdownIndicatorTouchEnd=function(e){t.userIsDragging||t.onDropdownIndicatorMouseDown(e)},t.handleInputChange=function(e){var n=t.props.inputValue,r=e.currentTarget.value;t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange(r,{action:"input-change",prevInputValue:n}),t.props.menuIsOpen||t.onMenuOpen()},t.onInputFocus=function(e){t.props.onFocus&&t.props.onFocus(e),t.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(t.openAfterFocus||t.props.openMenuOnFocus)&&t.openMenu("first"),t.openAfterFocus=!1},t.onInputBlur=function(e){var n=t.props.inputValue;t.menuListRef&&t.menuListRef.contains(document.activeElement)?t.inputRef.focus():(t.props.onBlur&&t.props.onBlur(e),t.onInputChange("",{action:"input-blur",prevInputValue:n}),t.onMenuClose(),t.setState({focusedValue:null,isFocused:!1}))},t.onOptionHover=function(e){t.blockOptionHover||t.state.focusedOption===e||t.setState({focusedOption:e})},t.shouldHideSelectedOptions=function(){return ho(t.props)},t.onValueInputFocus=function(e){e.preventDefault(),e.stopPropagation(),t.focus()},t.onKeyDown=function(e){var n=t.props,r=n.isMulti,o=n.backspaceRemovesValue,a=n.escapeClearsValue,i=n.inputValue,c=n.isClearable,u=n.isDisabled,s=n.menuIsOpen,l=n.onKeyDown,f=n.tabSelectsValue,p=n.openMenuOnFocus,d=t.state,h=d.focusedOption,m=d.focusedValue,v=d.selectValue;if(!(u||"function"==typeof l&&(l(e),e.defaultPrevented))){switch(t.blockOptionHover=!0,e.key){case"ArrowLeft":if(!r||i)return;t.focusValue("previous");break;case"ArrowRight":if(!r||i)return;t.focusValue("next");break;case"Delete":case"Backspace":if(i)return;if(m)t.removeValue(m);else{if(!o)return;r?t.popValue():c&&t.clearValue()}break;case"Tab":if(t.isComposing)return;if(e.shiftKey||!s||!f||!h||p&&t.isOptionSelected(h,v))return;t.selectOption(h);break;case"Enter":if(229===e.keyCode)break;if(s){if(!h)return;if(t.isComposing)return;t.selectOption(h);break}return;case"Escape":s?(t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange("",{action:"menu-close",prevInputValue:i}),t.onMenuClose()):c&&a&&t.clearValue();break;case" ":if(i)return;if(!s){t.openMenu("first");break}if(!h)return;t.selectOption(h);break;case"ArrowUp":s?t.focusOption("up"):t.openMenu("last");break;case"ArrowDown":s?t.focusOption("down"):t.openMenu("first");break;case"PageUp":if(!s)return;t.focusOption("pageup");break;case"PageDown":if(!s)return;t.focusOption("pagedown");break;case"Home":if(!s)return;t.focusOption("first");break;case"End":if(!s)return;t.focusOption("last");break;default:return}e.preventDefault()}},t.instancePrefix="react-select-"+(t.props.instanceId||++mo),t.state.selectValue=(0,wr.H)(e.value),e.menuIsOpen&&t.state.selectValue.length){var n=t.buildFocusableOptions(),r=n.indexOf(t.state.selectValue[0]);t.state.focusedOption=n[r]}return t}return t=a,r=[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r=t.clearFocusValueOnUpdate,o=t.inputIsHiddenAfterUpdate,a=t.ariaSelection,i=t.isFocused,c=t.prevWasFocused,u=e.options,s=e.value,l=e.menuIsOpen,f=e.inputValue,p=e.isMulti,d=(0,wr.H)(s),h={};if(n&&(s!==n.value||u!==n.options||l!==n.menuIsOpen||f!==n.inputValue)){var m=l?function(e,t){return io(ao(e,t))}(e,d):[],v=r?function(e,t){var n=e.focusedValue,r=e.selectValue.indexOf(n);if(r>-1){if(t.indexOf(n)>-1)return n;if(r<t.length)return t[r]}return null}(t,d):null;h={selectValue:d,focusedOption:function(e,t){var n=e.focusedOption;return n&&t.indexOf(n)>-1?n:t[0]}(t,m),focusedValue:v,clearFocusValueOnUpdate:!1}}var g=null!=o&&e!==n?{inputIsHidden:o,inputIsHiddenAfterUpdate:void 0}:{},y=a,b=i&&c;return i&&!b&&(y={value:(0,wr.D)(p,d,d[0]||null),options:d,action:"initial-input-focus"},b=!c),"initial-input-focus"===(null==a?void 0:a.action)&&(y=null),(0,ir.Z)((0,ir.Z)((0,ir.Z)({},h),g),{},{prevProps:e,ariaSelection:y,prevWasFocused:b})}}],(n=[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&(0,wr.I)(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isDisabled,r=t.menuIsOpen,o=this.state.isFocused;(o&&!n&&e.isDisabled||o&&r&&!e.menuIsOpen)&&this.focusInput(),o&&n&&!e.isDisabled?this.setState({isFocused:!1},this.onMenuClose):o||n||!e.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&((0,wr.I)(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(e,t){this.props.onInputChange(e,t)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(e){var t=this,n=this.state,r=n.selectValue,o=n.isFocused,a=this.buildFocusableOptions(),i="first"===e?0:a.length-1;if(!this.props.isMulti){var c=a.indexOf(r[0]);c>-1&&(i=c)}this.scrollToFocusedOptionOnUpdate=!(o&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:a[i]},(function(){return t.onMenuOpen()}))}},{key:"focusValue",value:function(e){var t=this.state,n=t.selectValue,r=t.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var o=n.indexOf(r);r||(o=-1);var a=n.length-1,i=-1;if(n.length){switch(e){case"previous":i=0===o?0:-1===o?a:o-1;break;case"next":o>-1&&o<a&&(i=o+1)}this.setState({inputIsHidden:-1!==i,focusedValue:n[i]})}}}},{key:"focusOption",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"first",t=this.props.pageSize,n=this.state.focusedOption,r=this.getFocusableOptions();if(r.length){var o=0,a=r.indexOf(n);n||(a=-1),"up"===e?o=a>0?a-1:r.length-1:"down"===e?o=(a+1)%r.length:"pageup"===e?(o=a-t)<0&&(o=0):"pagedown"===e?(o=a+t)>r.length-1&&(o=r.length-1):"last"===e&&(o=r.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:r[o],focusedValue:null})}}},{key:"getTheme",value:function(){return this.props.theme?"function"==typeof this.props.theme?this.props.theme(no):(0,ir.Z)((0,ir.Z)({},no),this.props.theme):no}},{key:"getCommonProps",value:function(){var e=this.clearValue,t=this.cx,n=this.getStyles,r=this.getClassNames,o=this.getValue,a=this.selectOption,i=this.setValue,c=this.props,u=c.isMulti,s=c.isRtl,l=c.options;return{clearValue:e,cx:t,getStyles:n,getClassNames:r,getValue:o,hasValue:this.hasValue(),isMulti:u,isRtl:s,options:l,selectOption:a,selectProps:c,setValue:i,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var e=this.props,t=e.isClearable,n=e.isMulti;return void 0===t?n:t}},{key:"isOptionDisabled",value:function(e,t){return lo(this.props,e,t)}},{key:"isOptionSelected",value:function(e,t){return fo(this.props,e,t)}},{key:"filterOption",value:function(e,t){return po(this.props,e,t)}},{key:"formatOptionLabel",value:function(e,t){if("function"==typeof this.props.formatOptionLabel){var n=this.props.inputValue,r=this.state.selectValue;return this.props.formatOptionLabel(e,{context:t,inputValue:n,selectValue:r})}return this.getOptionLabel(e)}},{key:"formatGroupLabel",value:function(e){return this.props.formatGroupLabel(e)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var e=this.props,t=e.isDisabled,n=e.isSearchable,r=e.inputId,o=e.inputValue,a=e.tabIndex,i=e.form,c=e.menuIsOpen,u=e.required,s=this.getComponents().Input,l=this.state,f=l.inputIsHidden,p=l.ariaSelection,d=this.commonProps,h=r||this.getElementId("input"),m=(0,ir.Z)((0,ir.Z)((0,ir.Z)({"aria-autocomplete":"list","aria-expanded":c,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":u,role:"combobox"},c&&{"aria-controls":this.getElementId("listbox"),"aria-owns":this.getElementId("listbox")}),!n&&{"aria-readonly":!0}),this.hasValue()?"initial-input-focus"===(null==p?void 0:p.action)&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return n?A.createElement(s,(0,lr.Z)({},d,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:h,innerRef:this.getInputRef,isDisabled:t,isHidden:f,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:a,form:i,type:"text",value:o},m)):A.createElement(Fr,(0,lr.Z)({id:h,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:wr.J,onFocus:this.onInputFocus,disabled:t,tabIndex:a,inputMode:"none",form:i,value:""},m))}},{key:"renderPlaceholderOrValue",value:function(){var e=this,t=this.getComponents(),n=t.MultiValue,r=t.MultiValueContainer,o=t.MultiValueLabel,a=t.MultiValueRemove,i=t.SingleValue,c=t.Placeholder,u=this.commonProps,s=this.props,l=s.controlShouldRenderValue,f=s.isDisabled,p=s.isMulti,d=s.inputValue,h=s.placeholder,m=this.state,v=m.selectValue,g=m.focusedValue,y=m.isFocused;if(!this.hasValue()||!l)return d?null:A.createElement(c,(0,lr.Z)({},u,{key:"placeholder",isDisabled:f,isFocused:y,innerProps:{id:this.getElementId("placeholder")}}),h);if(p)return v.map((function(t,i){var c=t===g,s="".concat(e.getOptionLabel(t),"-").concat(e.getOptionValue(t));return A.createElement(n,(0,lr.Z)({},u,{components:{Container:r,Label:o,Remove:a},isFocused:c,isDisabled:f,key:s,index:i,removeProps:{onClick:function(){return e.removeValue(t)},onTouchEnd:function(){return e.removeValue(t)},onMouseDown:function(e){e.preventDefault()}},data:t}),e.formatOptionLabel(t,"value"))}));if(d)return null;var b=v[0];return A.createElement(i,(0,lr.Z)({},u,{data:b,isDisabled:f}),this.formatOptionLabel(b,"value"))}},{key:"renderClearIndicator",value:function(){var e=this.getComponents().ClearIndicator,t=this.commonProps,n=this.props,r=n.isDisabled,o=n.isLoading,a=this.state.isFocused;if(!this.isClearable()||!e||r||!this.hasValue()||o)return null;var i={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(e,(0,lr.Z)({},t,{innerProps:i,isFocused:a}))}},{key:"renderLoadingIndicator",value:function(){var e=this.getComponents().LoadingIndicator,t=this.commonProps,n=this.props,r=n.isDisabled,o=n.isLoading,a=this.state.isFocused;return e&&o?A.createElement(e,(0,lr.Z)({},t,{innerProps:{"aria-hidden":"true"},isDisabled:r,isFocused:a})):null}},{key:"renderIndicatorSeparator",value:function(){var e=this.getComponents(),t=e.DropdownIndicator,n=e.IndicatorSeparator;if(!t||!n)return null;var r=this.commonProps,o=this.props.isDisabled,a=this.state.isFocused;return A.createElement(n,(0,lr.Z)({},r,{isDisabled:o,isFocused:a}))}},{key:"renderDropdownIndicator",value:function(){var e=this.getComponents().DropdownIndicator;if(!e)return null;var t=this.commonProps,n=this.props.isDisabled,r=this.state.isFocused,o={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return A.createElement(e,(0,lr.Z)({},t,{innerProps:o,isDisabled:n,isFocused:r}))}},{key:"renderMenu",value:function(){var e=this,t=this.getComponents(),n=t.Group,r=t.GroupHeading,o=t.Menu,a=t.MenuList,i=t.MenuPortal,c=t.LoadingMessage,u=t.NoOptionsMessage,s=t.Option,l=this.commonProps,f=this.state.focusedOption,p=this.props,d=p.captureMenuScroll,h=p.inputValue,m=p.isLoading,v=p.loadingMessage,g=p.minMenuHeight,y=p.maxMenuHeight,b=p.menuIsOpen,w=p.menuPlacement,O=p.menuPosition,x=p.menuPortalTarget,k=p.menuShouldBlockScroll,S=p.menuShouldScrollIntoView,P=p.noOptionsMessage,_=p.onMenuScrollToTop,j=p.onMenuScrollToBottom;if(!b)return null;var E,C=function(t,n){var r=t.type,o=t.data,a=t.isDisabled,i=t.isSelected,c=t.label,u=t.value,p=f===o,d=a?void 0:function(){return e.onOptionHover(o)},h=a?void 0:function(){return e.selectOption(o)},m="".concat(e.getElementId("option"),"-").concat(n),v={id:m,onClick:h,onMouseMove:d,onMouseOver:d,tabIndex:-1};return A.createElement(s,(0,lr.Z)({},l,{innerProps:v,data:o,isDisabled:a,isSelected:i,key:m,label:c,type:r,value:u,isFocused:p,innerRef:p?e.getFocusedOptionRef:void 0}),e.formatOptionLabel(t.data,"menu"))};if(this.hasOptions())E=this.getCategorizedOptions().map((function(t){if("group"===t.type){var o=t.data,a=t.options,i=t.index,c="".concat(e.getElementId("group"),"-").concat(i),u="".concat(c,"-heading");return A.createElement(n,(0,lr.Z)({},l,{key:c,data:o,options:a,Heading:r,headingProps:{id:u,data:t.data},label:e.formatGroupLabel(t.data)}),t.options.map((function(e){return C(e,"".concat(i,"-").concat(e.index))})))}if("option"===t.type)return C(t,"".concat(t.index))}));else if(m){var D=v({inputValue:h});if(null===D)return null;E=A.createElement(c,l,D)}else{var T=P({inputValue:h});if(null===T)return null;E=A.createElement(u,l,T)}var M={minMenuHeight:g,maxMenuHeight:y,menuPlacement:w,menuPosition:O,menuShouldScrollIntoView:S},R=A.createElement(wr.M,(0,lr.Z)({},l,M),(function(t){var n=t.ref,r=t.placerProps,i=r.placement,c=r.maxHeight;return A.createElement(o,(0,lr.Z)({},l,M,{innerRef:n,innerProps:{onMouseDown:e.onMenuMouseDown,onMouseMove:e.onMenuMouseMove,id:e.getElementId("listbox")},isLoading:m,placement:i}),A.createElement(Qr,{captureEnabled:d,onTopArrive:_,onBottomArrive:j,lockEnabled:k},(function(t){return A.createElement(a,(0,lr.Z)({},l,{innerRef:function(n){e.getMenuListRef(n),t(n)},isLoading:m,maxHeight:c,focusedOption:f}),E)})))}));return x||"fixed"===O?A.createElement(i,(0,lr.Z)({},l,{appendTo:x,controlElement:this.controlRef,menuPlacement:w,menuPosition:O}),R):R}},{key:"renderFormField",value:function(){var e=this,t=this.props,n=t.delimiter,r=t.isDisabled,o=t.isMulti,a=t.name,i=t.required,c=this.state.selectValue;if(i&&!this.hasValue()&&!r)return A.createElement(Jr,{name:a,onFocus:this.onValueInputFocus});if(a&&!r){if(o){if(n){var u=c.map((function(t){return e.getOptionValue(t)})).join(n);return A.createElement("input",{name:a,type:"hidden",value:u})}var s=c.length>0?c.map((function(t,n){return A.createElement("input",{key:"i-".concat(n),name:a,type:"hidden",value:e.getOptionValue(t)})})):A.createElement("input",{name:a,type:"hidden",value:""});return A.createElement("div",null,s)}var l=c[0]?this.getOptionValue(c[0]):"";return A.createElement("input",{name:a,type:"hidden",value:l})}}},{key:"renderLiveRegion",value:function(){var e=this.commonProps,t=this.state,n=t.ariaSelection,r=t.focusedOption,o=t.focusedValue,a=t.isFocused,i=t.selectValue,c=this.getFocusableOptions();return A.createElement(jr,(0,lr.Z)({},e,{id:this.getElementId("live-region"),ariaSelection:n,focusedOption:r,focusedValue:o,isFocused:a,selectValue:i,focusableOptions:c}))}},{key:"render",value:function(){var e=this.getComponents(),t=e.Control,n=e.IndicatorsContainer,r=e.SelectContainer,o=e.ValueContainer,a=this.props,i=a.className,c=a.id,u=a.isDisabled,s=a.menuIsOpen,l=this.state.isFocused,f=this.commonProps=this.getCommonProps();return A.createElement(r,(0,lr.Z)({},f,{className:i,innerProps:{id:c,onKeyDown:this.onKeyDown},isDisabled:u,isFocused:l}),this.renderLiveRegion(),A.createElement(t,(0,lr.Z)({},f,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:u,isFocused:l,menuIsOpen:s}),A.createElement(o,(0,lr.Z)({},f,{isDisabled:u}),this.renderPlaceholderOrValue(),this.renderInput()),A.createElement(n,(0,lr.Z)({},f,{isDisabled:u}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}])&&fr(t.prototype,n),r&&fr(t,r),Object.defineProperty(t,"prototype",{writable:!1}),a}(A.Component);vo.defaultProps=ro;i(66751),i(30314),i(73469);var go=(0,A.forwardRef)((function(e,t){var n=function(e){var t=e.defaultInputValue,n=void 0===t?"":t,r=e.defaultMenuIsOpen,o=void 0!==r&&r,a=e.defaultValue,i=void 0===a?null:a,c=e.inputValue,u=e.menuIsOpen,s=e.onChange,l=e.onInputChange,f=e.onMenuClose,p=e.onMenuOpen,d=e.value,h=(0,ur.Z)(e,sr),m=(0,A.useState)(void 0!==c?c:n),v=(0,cr.Z)(m,2),g=v[0],y=v[1],b=(0,A.useState)(void 0!==u?u:o),w=(0,cr.Z)(b,2),O=w[0],x=w[1],k=(0,A.useState)(void 0!==d?d:i),S=(0,cr.Z)(k,2),P=S[0],_=S[1],j=(0,A.useCallback)((function(e,t){"function"==typeof s&&s(e,t),_(e)}),[s]),E=(0,A.useCallback)((function(e,t){var n;"function"==typeof l&&(n=l(e,t)),y(void 0!==n?n:e)}),[l]),C=(0,A.useCallback)((function(){"function"==typeof p&&p(),x(!0)}),[p]),D=(0,A.useCallback)((function(){"function"==typeof f&&f(),x(!1)}),[f]),T=void 0!==c?c:g,M=void 0!==u?u:O,R=void 0!==d?d:P;return(0,ir.Z)((0,ir.Z)({},h),{},{inputValue:T,menuIsOpen:M,onChange:j,onInputChange:E,onMenuClose:D,onMenuOpen:C,value:R})}(e);return A.createElement(vo,(0,lr.Z)({ref:t},n))})),yo=i(80470);function bo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function wo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Oo=(0,v.ZP)((function(e){var t;return(0,ee.jsx)("span",wo(wo({},e.innerProps),{},{children:(0,ee.jsx)(yo.Z,{icon:"times",tabIndex:-1,"aria-label":(t="client.component.select.clearFieldLabel",e.intl.formatMessage({id:t}))})}))}));var xo=i(95497);function ko(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function So(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ko(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ko(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Po=function(e){var t=e.selectProps,n=t.isDisabled,r=t.menuIsOpen;return n?null:(0,ee.jsx)(wr.c.DropdownIndicator,So(So({},e),{},{children:(0,ee.jsx)(xo.M6,{children:(0,ee.jsx)(yo.Z,{icon:r?"chevron-up":"chevron-down",visible:!0,tabIndex:-1})})}))};var _o,jo,Eo;function Co(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Do(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Co(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Co(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var To=function(e,t,n){return function(r){r.stopPropagation(),e(t,n)}},Mo=function(e,t){return function(n){n.stopPropagation(),e(t)}},Ro=function(e,t){return function(n){n.stopPropagation(),e(t)}},Io=function(e){e.stopPropagation()};const No=function(e){var t=e.selectProps,n=t.openDocsTreeSearch,r=t.openAdvancedSearch,o=t.openRemoteCreate,a=t.isDisabled,i=t.hasDocsTreeSearch,c=t.hasAdvancedSearch,u=t.createPermission,s=t.value,l=t.isMulti,f=t.inputValue,p=l&&(c||i);return(0,ee.jsx)(xo.HO,{isTopAligned:p,children:(0,ee.jsxs)(wr.c.IndicatorsContainer,Do(Do({},e),{},{children:[e.children,n&&!a&&(0,ee.jsx)("span",{onTouchEnd:Io,onMouseDown:Mo(n,s),children:_o||(_o=(0,ee.jsx)(yo.Z,{icon:"folder",tabIndex:-1}))}),r&&!a&&(0,ee.jsx)("span",{onTouchEnd:Io,onMouseDown:To(r,f,s),children:jo||(jo=(0,ee.jsx)(yo.Z,{icon:"search",tabIndex:-1}))}),u&&!a&&(0,ee.jsx)("span",{onTouchEnd:Io,onMouseDown:Ro(o,s),children:Eo||(Eo=(0,ee.jsx)(yo.Z,{icon:"plus",tabIndex:-1}))})]}))})};var Ao;const Zo=function(){return Ao||(Ao=(0,ee.jsx)("span",{children:(0,ee.jsx)(Hn.Z,{size:"1.8rem"})}))};var Lo=i(15315);function Fo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ho(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Uo=function(e){var t=e.selectProps,n=e.children;return(0,ee.jsx)(xo._M,{attachment:"top left",targetAttachment:"bottom left",constraints:[{to:"window",attachment:"together"}],renderTarget:function(e){return(0,ee.jsx)("div",{ref:e})},renderElement:function(r){return(0,ee.jsx)("div",{ref:r,className:Lo.c,children:(0,ee.jsx)(xo.l2,Ho(Ho({},In()(e,["innerRef"])),{},{wrapperWidth:t.wrapperWidth,wrapperHeight:t.wrapperHeight,children:n}))})}})};function Bo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Wo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const zo=function(e){var t=e.selectProps,n=e.children,r=t.moreOptionsAvailable,o=t.moreOptionsAvailableText;return(0,ee.jsxs)(wr.c.MenuList,Wo(Wo({},e),{},{className:"MenuList",children:[n,r&&(0,ee.jsx)(xo.OA,{children:o})]}))};var Yo=i(76791);function Vo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function qo(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Go=function(e){var t=e.data,n=e.innerProps,r=e.children,o=e.selectProps,a=o.tooltips,i=o.loadTooltip,c=o.DetailLink,u=Ut()(a,t.key,null),s=(0,ee.jsx)("span",qo(qo({},n),{},{children:r})),l=c?(0,ee.jsx)(xo.vR,{onMouseDown:function(e){e.stopPropagation(),e.preventDefault()},children:(0,ee.jsx)(c,{entityKey:t.key,tabIndex:-1,children:(0,ee.jsx)(Yo.Z,{content:u?(0,ee.jsx)("div",{dangerouslySetInnerHTML:{__html:it.Z.sanitizeHtml(u)}}):null,children:(0,ee.jsx)("span",{onMouseOver:function(){return i&&!u&&i(t.key)},children:s})})})}):s;return(0,ee.jsx)(xo.B1,{children:l})};var Ko=i(47037),Xo=i.n(Ko),Qo=i(14176),$o=i.n(Qo);function Jo(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ea(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Jo(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jo(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ta=["linkComp"],na=function(e,t){var n=at.Z.difference(e,t),r=$o()(In()(n,ta),(function(e){return 0===Object.keys(e).length}));return 0===Object.entries(r).length},ra=(0,A.memo)((function(e){var t=e.linkComp,n=e.entityKey,r=e.children;return t&&Xo()(n)?(0,ee.jsx)(xo.vR,{onMouseDown:function(e){e.stopPropagation(),e.preventDefault()},children:(0,ee.jsx)(t,{entityKey:n,children:r})}):r}),na);ra.propTypes={children:p().node,entityKey:p().any,linkComp:p().func};const oa=function(e){var t=e.data,n=e.selectProps,r=e.isDisabled,o=e.children,a=n.tooltips,i=n.loadTooltip,c=n.DetailLink,u=Ut()(a,t.key,null);return(0,ee.jsx)(wr.c.SingleValue,ea(ea({},e),{},{children:(0,ee.jsx)(xo.xq,{onMouseOver:function(){return i&&!u&&i(t.key)},isDisabled:r,children:(0,ee.jsx)(Yo.Z,{content:u?(0,ee.jsx)("div",{dangerouslySetInnerHTML:{__html:it.Z.sanitizeHtml(u)}}):null,children:(0,ee.jsx)(ra,{linkComp:c,entityKey:t.key,children:o})})})}))};function aa(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var ia=function(e){var t;return"Input"===(null==e||null===(t=e.type)||void 0===t?void 0:t.name)};const ca=function(e){var t=e.selectProps,n=e.hasValue,r=e.children,o=t.isMulti,a=t.hasAdvancedSearch,i=t.hasDocsTreeSearch,c=t.isDisabled;if(!(o&&(a||i)))return(0,ee.jsx)(wr.c.ValueContainer,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?aa(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):aa(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e));var u=A.Children.map(r,(function(e){return ia(e)?e:null})),s=A.Children.map(r,(function(e){return ia(e)?null:e})),f=c&&n;return(0,ee.jsxs)(ee.Fragment,{children:[!f&&(0,ee.jsx)(ee.Fragment,{children:u}),(0,ee.jsx)(xo.eQ,{children:s})]})};function ua(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function sa(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ua(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ua(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const la=(0,V.Zz)((function(e){var t=e.fetchOptions,n=e.id,r=e.immutable,o=e.isLoading,a=e.isMulti,i=e.loadTooltip,c=e.moreOptionsAvailable,u=e.moreOptionsAvailableText,s=e.noResultsText,l=e.noResultsComp,f=e.onChange,p=e.openDocsTreeSearch,d=e.openAdvancedSearch,h=e.options,m=e.searchOptions,v=e.theme,g=e.tooltips,y=e.value,b=e.DetailLink,w=e.createPermission,O=e.openRemoteCreate,x=(0,A.useRef)(null),k=(0,A.useRef)(null),S=function(){var e;return(null===(e=k.current)||void 0===e?void 0:e.clientWidth)||300},P=function(){var e;return(null===(e=k.current)||void 0===e?void 0:e.clientHeight)||35},_=(0,A.useState)(S()),j=We()(_,2),E=j[0],C=j[1],D=(0,A.useState)(P()),T=We()(D,2),M=T[0],R=T[1],I=(0,A.useState)(!1),N=We()(I,2),Z=N[0],L=N[1],F=function(e){t&&t(e)},H=(0,A.useCallback)(m||function(){},[]),U=(0,A.useCallback)(ar()(H,800,{trailing:!0}),[]),B=Boolean(d),W=Boolean(p),z=Boolean(w);return(0,ee.jsx)(xo.sP,{tabIndex:"-1",id:n,onFocus:function(){x.current.focus(),setTimeout((function(){C(S()),R(P())}),0)},children:(0,ee.jsx)(xo.RU,{ref:k,children:(0,ee.jsx)(go,sa(sa({getOptionLabel:function(e){return e.display},getOptionValue:function(e){return e.key},wrapperWidth:E,wrapperHeight:M,components:{ClearIndicator:Oo,LoadingIndicator:Zo,DropdownIndicator:Po,IndicatorsContainer:No,IndicatorSeparator:null,Menu:Uo,MenuList:zo,MultiValueLabel:Go,SingleValue:oa,ValueContainer:ca},noOptionsMessage:function(e){return s||("function"==typeof l?(0,ee.jsx)(l,sa({},e)):" - ")},isMulti:a,closeMenuOnSelect:!a,isSearchable:!0},m?{filterOption:function(){return!0}}:{}),{},{isClearable:!0,loadingMessage:function(){return null},placeholder:"",menuShouldScrollIntoView:!1,autoFocus:!1,value:y||null,onChange:function(e){f(e),F(e)},onInputChange:function(e,t){var n=t.action;m&&e&&U(e,y),""===e&&"input-change"===n&&F(y)},options:st()(h||[]),onKeyDown:function(e){"Enter"===e.key&&Z?(e.stopPropagation(),x.current&&null===x.current.focusedOptionRef&&e.preventDefault()):"Tab"===e.key&&(e.preventDefault=function(){})},isLoading:o,isDisabled:r,ref:x,onMenuOpen:function(){F(y),L(!0)},onMenuClose:function(){L(!1)},styles:(0,xo.i4)(v),loadTooltip:i,tooltips:g,DetailLink:b,hasDocsTreeSearch:W,openDocsTreeSearch:p,hasAdvancedSearch:B,openAdvancedSearch:d,moreOptionsAvailable:c,moreOptionsAvailableText:u,blurInputOnSelect:!1,hasCreatePermission:z,createPermission:w,openRemoteCreate:O,closeMenuOnScroll:function(e){var t;return!(null!==(t=e.target.classList)&&void 0!==t&&t.contains("MenuList"))}}))})})}));const fa=function(e){var t=e.id,n=e.immutable,r=e.value,o=e.options,a=o.trueLabel,i=o.falseLabel,c=e.onChange;return(0,ee.jsx)(la,{id:t,immutable:n,isMulti:!1,onChange:function(e){return c(e?e.key:null)},value:rr()(r)?r:{key:r,display:r?a:i},openMenuOnClick:!0,options:[{key:!0,display:a},{key:!1,display:i}]})};var pa,da=V.ZP.div.withConfig({displayName:"StyledBoolEdit"})(pa||(pa=Y()(["\n margin: 5px 0;\n"])));const ha=function(e){return(0,ee.jsx)(da,{children:(0,ee.jsx)("input",{type:"checkbox",checked:e.value||!1,name:e.name,onChange:function(t){e.onChange&&e.onChange(t.target.checked)},id:e.id,disabled:e.immutable})})};var ma,va;function ga(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ya(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ga(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ga(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ba=V.ZP.div.withConfig({displayName:"StyledOption"})(ma||(ma=Y()(["\n margin: "," 0;\n"])),q.Z.space(-1.4)),wa=V.ZP.span.withConfig({displayName:"StyledLabel"})(va||(va=Y()(["\n ","\n display: inline-block;\n margin-left: ",";\n"])),(0,Ft.Z)(),q.Z.space(-1.5)),Oa={single:"radio",multiple:"checkbox"},xa={single:{checked:!1},multiple:{}},ka=function(e,t){return t?(0,ee.jsx)(Lt.Z,{value:e}):e},Sa=function(e){var t=e.groupName,n=e.id,r=e.label,o=e.labelComponent,a=e.checked,i=e.immutable,c=e.hideCheckbox,u=e.selectionType,s=e.renderHtmlInOptions,l=e.handleChange;return(0,ee.jsxs)(ba,{children:[!c&&(0,ee.jsx)("input",{name:t,type:Oa[u],checked:a||!1,onChange:l,id:n,disabled:i}),(0,ee.jsx)(wa,{children:o||ka(r,s)})]})};const Pa=function(e){var t=function(t){if(e.onChange){var n=e.value.options.map((function(n){return ya(ya({},n),n.id===t.target.id?{checked:t.target.checked}:xa[e.options.selectionType])}));e.onChange({options:n})}};return(0,ee.jsx)(ee.Fragment,{children:e.value.options.map((function(n){return(0,ee.jsx)(Sa,{groupName:e.id,id:n.id,label:n.label,labelComponent:n.labelComponent,checked:n.checked,immutable:e.immutable||n.immutable,hideCheckbox:n.hideCheckbox,selectionType:e.options.selectionType,renderHtmlInOptions:e.options.renderHtmlInOptions,handleChange:t},n.id)}))})};var _a=i(23279),ja=i.n(_a);function Ea(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ca(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ea(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ea(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Da=(0,A.lazy)((function(){return Promise.all([i.e(560),i.e(85)]).then(i.bind(i,30919))}));const Ta=function(e){return(0,ee.jsx)(A.Suspense,{fallback:(t=e.value,(0,ee.jsx)("div",{children:(0,ee.jsx)("p",{children:t})})),children:(0,ee.jsx)(Da,Ca({},e))});var t};var Ma,Ra=V.ZP.div.withConfig({displayName:"StyledEditorWrapper"})(Ma||(Ma=Y()(["\n margin-top: ",";\n"])),q.Z.space(-1.5));const Ia=function(e){var t=e.value,n=e.onChange,r=e.immutable,o=e.options;return(0,ee.jsx)(Ra,{children:(0,ee.jsx)(Ta,{value:t,onChange:ja()(n,1e3),autoFocusOnMount:o.autoFocusOnMount,mode:o.mode,theme:"textmate",showGutter:!0,editorOptions:{enableBasicAutocompletion:!0,enableLiveAutocompletion:!0,enableSnippets:!0,minLines:5,maxLines:50,readOnly:r,wrap:!0,indentedSoftWrap:!1},implicitModel:o.implicitModel})})};var Na=i(86896),Aa=i(23842),Za=i(93379),La=i.n(Za),Fa=i(7795),Ha=i.n(Fa),Ua=i(90569),Ba=i.n(Ua),Wa=i(3565),za=i.n(Wa),Ya=i(19216),Va=i.n(Ya),qa=i(44589),Ga=i.n(qa),Ka=i(16721),Xa={};Xa.styleTagTransform=Ga(),Xa.setAttributes=za(),Xa.insert=Ba().bind(null,"head"),Xa.domAPI=Ha(),Xa.insertStyleElement=Va();La()(Ka.Z,Xa);Ka.Z&&Ka.Z.locals&&Ka.Z.locals;var Qa=i(9198),$a=i.n(Qa),Ja=(Math.pow(10,8),6e4),ei=36e5,ti=i(13882),ni=i(83946);var ri={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},oi=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,ai=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,ii=/^([+-])(\d{2})(?::?(\d{2}))?$/;function ci(e){var t,n={},r=e.split(ri.dateTimeDelimiter);if(r.length>2)return n;if(/:/.test(r[0])?t=r[0]:(n.date=r[0],t=r[1],ri.timeZoneDelimiter.test(n.date)&&(n.date=e.split(ri.timeZoneDelimiter)[0],t=e.substr(n.date.length,e.length))),t){var o=ri.timezone.exec(t);o?(n.time=t.replace(o[1],""),n.timezone=o[1]):n.time=t}return n}function ui(e,t){var n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:NaN,restDateString:""};var o=r[1]?parseInt(r[1]):null,a=r[2]?parseInt(r[2]):null;return{year:null===a?o:100*a,restDateString:e.slice((r[1]||r[2]).length)}}function si(e,t){if(null===t)return new Date(NaN);var n=e.match(oi);if(!n)return new Date(NaN);var r=!!n[4],o=li(n[1]),a=li(n[2])-1,i=li(n[3]),c=li(n[4]),u=li(n[5])-1;if(r)return function(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}(0,c,u)?function(e,t,n){var r=new Date(0);r.setUTCFullYear(e,0,4);var o=r.getUTCDay()||7,a=7*(t-1)+n+1-o;return r.setUTCDate(r.getUTCDate()+a),r}(t,c,u):new Date(NaN);var s=new Date(0);return function(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(hi[t]||(mi(e)?29:28))}(t,a,i)&&function(e,t){return t>=1&&t<=(mi(e)?366:365)}(t,o)?(s.setUTCFullYear(t,a,Math.max(o,i)),s):new Date(NaN)}function li(e){return e?parseInt(e):1}function fi(e){var t=e.match(ai);if(!t)return NaN;var n=pi(t[1]),r=pi(t[2]),o=pi(t[3]);return function(e,t,n){if(24===e)return 0===t&&0===n;return n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}(n,r,o)?n*ei+r*Ja+1e3*o:NaN}function pi(e){return e&&parseFloat(e.replace(",","."))||0}function di(e){if("Z"===e)return 0;var t=e.match(ii);if(!t)return 0;var n="+"===t[1]?-1:1,r=parseInt(t[2]),o=t[3]&&parseInt(t[3])||0;return function(e,t){return t>=0&&t<=59}(0,o)?n*(r*ei+o*Ja):NaN}var hi=[31,null,31,30,31,30,31,31,30,31,30,31];function mi(e){return e%400==0||e%4==0&&e%100!=0}var vi,gi,yi,bi=V.ZP.div.withConfig({displayName:"StyledDatePickerOuterWrapper"})(vi||(vi=Y()(["\n outline: ",";\n"])),(function(e){return e.immutable?0:"initial"})),wi=V.ZP.div.withConfig({displayName:"StyledDatePickerWrapper"})(gi||(gi=Y()(["\n &&&& {\n ","\n\n & .react-datepicker__input-container {\n & input {\n ","\n width: calc(100% - 5px);\n }\n }\n\n & .react-datepicker {\n & .react-datepicker__today-button {\n ","\n }\n }\n }\n"])),Un,Wn,(function(e){return e.hasTime&&"border-bottom: 1px solid #aeaeae;"})),Oi=V.ZP.input.withConfig({displayName:"StyledTimeInput"})(yi||(yi=Y()(["\n &&&& {\n ","\n }\n"])),Wn),xi=i(37042),ki=i(4543),Si=i(39880),Pi=i(85817),_i=i(39159),ji=i(19013);function Ei(e){(0,ti.Z)(1,arguments);var t=(0,ji.Z)(e),n=t.getSeconds();return n}var Ci=i(86);function Di(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Ti(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return Di(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Di(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i=!0,c=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){c=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(c)throw a}}}}var Mi=i(44941),Ri=i(29558);function Ii(e,t){if(null==e)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}var Ni=i(97621),Ai=i(24262),Zi=i(5267);function Li(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Fi(e,t){return(Fi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function Hi(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Fi(e,t)}function Ui(e){return(Ui=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function Bi(e,t){if(t&&("object"===(0,Ci.Z)(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Li(e)}function Wi(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Ui(e);if(t){var o=Ui(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bi(this,n)}}function zi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Yi(e){var t=function(e,t){if("object"!==(0,Ci.Z)(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==(0,Ci.Z)(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===(0,Ci.Z)(t)?t:String(t)}function Vi(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Yi(r.key),r)}}function qi(e,t,n){return t&&Vi(e.prototype,t),n&&Vi(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Gi(e,t,n){return(t=Yi(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ki=function(){function e(){zi(this,e),Gi(this,"priority",void 0),Gi(this,"subPriority",0)}return qi(e,[{key:"validate",value:function(e,t){return!0}}]),e}(),Xi=function(e){Hi(n,e);var t=Wi(n);function n(e,r,o,a,i){var c;return zi(this,n),(c=t.call(this)).value=e,c.validateValue=r,c.setValue=o,c.priority=a,i&&(c.subPriority=i),c}return qi(n,[{key:"validate",value:function(e,t){return this.validateValue(e,this.value,t)}},{key:"set",value:function(e,t,n){return this.setValue(e,t,this.value,n)}}]),n}(Ki),Qi=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",10),Gi(Li(e),"subPriority",-1),e}return qi(n,[{key:"set",value:function(e,t){if(t.timestampIsSet)return e;var n=new Date(0);return n.setFullYear(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()),n.setHours(e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds()),n}}]),n}(Ki),$i=function(){function e(){zi(this,e),Gi(this,"incompatibleTokens",void 0),Gi(this,"priority",void 0),Gi(this,"subPriority",void 0)}return qi(e,[{key:"run",value:function(e,t,n,r){var o=this.parse(e,t,n,r);return o?{setter:new Xi(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}},{key:"validate",value:function(e,t,n){return!0}}]),e}(),Ji=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",140),Gi(Li(e),"incompatibleTokens",["R","u","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"G":case"GG":case"GGG":return n.era(e,{width:"abbreviated"})||n.era(e,{width:"narrow"});case"GGGGG":return n.era(e,{width:"narrow"});case"GGGG":default:return n.era(e,{width:"wide"})||n.era(e,{width:"abbreviated"})||n.era(e,{width:"narrow"})}}},{key:"set",value:function(e,t,n){return t.era=n,e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}}]),n}($i),ec=/^(1[0-2]|0?\d)/,tc=/^(3[0-1]|[0-2]?\d)/,nc=/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,rc=/^(5[0-3]|[0-4]?\d)/,oc=/^(2[0-3]|[0-1]?\d)/,ac=/^(2[0-4]|[0-1]?\d)/,ic=/^(1[0-1]|0?\d)/,cc=/^(1[0-2]|0?\d)/,uc=/^[0-5]?\d/,sc=/^[0-5]?\d/,lc=/^\d/,fc=/^\d{1,2}/,pc=/^\d{1,3}/,dc=/^\d{1,4}/,hc=/^-?\d+/,mc=/^-?\d/,vc=/^-?\d{1,2}/,gc=/^-?\d{1,3}/,yc=/^-?\d{1,4}/,bc=/^([+-])(\d{2})(\d{2})?|Z/,wc=/^([+-])(\d{2})(\d{2})|Z/,Oc=/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,xc=/^([+-])(\d{2}):(\d{2})|Z/,kc=/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/;function Sc(e,t){return e?{value:t(e.value),rest:e.rest}:e}function Pc(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function _c(e,t){var n=t.match(e);if(!n)return null;if("Z"===n[0])return{value:0,rest:t.slice(1)};var r="+"===n[1]?1:-1,o=n[2]?parseInt(n[2],10):0,a=n[3]?parseInt(n[3],10):0,i=n[5]?parseInt(n[5],10):0;return{value:r*(o*ei+a*Ja+1e3*i),rest:t.slice(n[0].length)}}function jc(e){return Pc(hc,e)}function Ec(e,t){switch(e){case 1:return Pc(lc,t);case 2:return Pc(fc,t);case 3:return Pc(pc,t);case 4:return Pc(dc,t);default:return Pc(new RegExp("^\\d{1,"+e+"}"),t)}}function Cc(e,t){switch(e){case 1:return Pc(mc,t);case 2:return Pc(vc,t);case 3:return Pc(gc,t);case 4:return Pc(yc,t);default:return Pc(new RegExp("^-?\\d{1,"+e+"}"),t)}}function Dc(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function Tc(e,t){var n,r=t>0,o=r?t:1-t;if(o<=50)n=e||100;else{var a=o+50;n=e+100*Math.floor(a/100)-(e>=a%100?100:0)}return r?n:1-n}function Mc(e){return e%400==0||e%4==0&&e%100!=0}var Rc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",130),Gi(Li(e),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return{year:e,isTwoDigitYear:"yy"===t}};switch(t){case"y":return Sc(Ec(4,e),r);case"yo":return Sc(n.ordinalNumber(e,{unit:"year"}),r);default:return Sc(Ec(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,n){var r=e.getUTCFullYear();if(n.isTwoDigitYear){var o=Tc(n.year,r);return e.setUTCFullYear(o,0,1),e.setUTCHours(0,0,0,0),e}var a="era"in t&&1!==t.era?1-n.year:n.year;return e.setUTCFullYear(a,0,1),e.setUTCHours(0,0,0,0),e}}]),n}($i),Ic=i(7651),Nc=i(59025),Ac=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",130),Gi(Li(e),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return{year:e,isTwoDigitYear:"YY"===t}};switch(t){case"Y":return Sc(Ec(4,e),r);case"Yo":return Sc(n.ordinalNumber(e,{unit:"year"}),r);default:return Sc(Ec(t.length,e),r)}}},{key:"validate",value:function(e,t){return t.isTwoDigitYear||t.year>0}},{key:"set",value:function(e,t,n,r){var o=(0,Ic.Z)(e,r);if(n.isTwoDigitYear){var a=Tc(n.year,o);return e.setUTCFullYear(a,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,Nc.Z)(e,r)}var i="era"in t&&1!==t.era?1-n.year:n.year;return e.setUTCFullYear(i,0,r.firstWeekContainsDate),e.setUTCHours(0,0,0,0),(0,Nc.Z)(e,r)}}]),n}($i),Zc=i(66979),Lc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",130),Gi(Li(e),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t){return Cc("R"===t?4:t.length,e)}},{key:"set",value:function(e,t,n){var r=new Date(0);return r.setUTCFullYear(n,0,4),r.setUTCHours(0,0,0,0),(0,Zc.Z)(r)}}]),n}($i),Fc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",130),Gi(Li(e),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t){return Cc("u"===t?4:t.length,e)}},{key:"set",value:function(e,t,n){return e.setUTCFullYear(n,0,1),e.setUTCHours(0,0,0,0),e}}]),n}($i),Hc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",120),Gi(Li(e),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"Q":case"QQ":return Ec(t.length,e);case"Qo":return n.ordinalNumber(e,{unit:"quarter"});case"QQQ":return n.quarter(e,{width:"abbreviated",context:"formatting"})||n.quarter(e,{width:"narrow",context:"formatting"});case"QQQQQ":return n.quarter(e,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(e,{width:"wide",context:"formatting"})||n.quarter(e,{width:"abbreviated",context:"formatting"})||n.quarter(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,n){return e.setUTCMonth(3*(n-1),1),e.setUTCHours(0,0,0,0),e}}]),n}($i),Uc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",120),Gi(Li(e),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"q":case"qq":return Ec(t.length,e);case"qo":return n.ordinalNumber(e,{unit:"quarter"});case"qqq":return n.quarter(e,{width:"abbreviated",context:"standalone"})||n.quarter(e,{width:"narrow",context:"standalone"});case"qqqqq":return n.quarter(e,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(e,{width:"wide",context:"standalone"})||n.quarter(e,{width:"abbreviated",context:"standalone"})||n.quarter(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=1&&t<=4}},{key:"set",value:function(e,t,n){return e.setUTCMonth(3*(n-1),1),e.setUTCHours(0,0,0,0),e}}]),n}($i),Bc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),Gi(Li(e),"priority",110),e}return qi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return e-1};switch(t){case"M":return Sc(Pc(ec,e),r);case"MM":return Sc(Ec(2,e),r);case"Mo":return Sc(n.ordinalNumber(e,{unit:"month"}),r);case"MMM":return n.month(e,{width:"abbreviated",context:"formatting"})||n.month(e,{width:"narrow",context:"formatting"});case"MMMMM":return n.month(e,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(e,{width:"wide",context:"formatting"})||n.month(e,{width:"abbreviated",context:"formatting"})||n.month(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.setUTCMonth(n,1),e.setUTCHours(0,0,0,0),e}}]),n}($i),Wc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",110),Gi(Li(e),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return e-1};switch(t){case"L":return Sc(Pc(ec,e),r);case"LL":return Sc(Ec(2,e),r);case"Lo":return Sc(n.ordinalNumber(e,{unit:"month"}),r);case"LLL":return n.month(e,{width:"abbreviated",context:"standalone"})||n.month(e,{width:"narrow",context:"standalone"});case"LLLLL":return n.month(e,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(e,{width:"wide",context:"standalone"})||n.month(e,{width:"abbreviated",context:"standalone"})||n.month(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.setUTCMonth(n,1),e.setUTCHours(0,0,0,0),e}}]),n}($i),zc=i(23324);var Yc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",100),Gi(Li(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"w":return Pc(rc,e);case"wo":return n.ordinalNumber(e,{unit:"week"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,n,r){return(0,Nc.Z)(function(e,t,n){(0,ti.Z)(2,arguments);var r=(0,ji.Z)(e),o=(0,ni.Z)(t),a=(0,zc.Z)(r,n)-o;return r.setUTCDate(r.getUTCDate()-7*a),r}(e,n,r),r)}}]),n}($i),Vc=i(49702);var qc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",100),Gi(Li(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"I":return Pc(rc,e);case"Io":return n.ordinalNumber(e,{unit:"week"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=53}},{key:"set",value:function(e,t,n){return(0,Zc.Z)(function(e,t){(0,ti.Z)(2,arguments);var n=(0,ji.Z)(e),r=(0,ni.Z)(t),o=(0,Vc.Z)(n)-r;return n.setUTCDate(n.getUTCDate()-7*o),n}(e,n))}}]),n}($i),Gc=[31,28,31,30,31,30,31,31,30,31,30,31],Kc=[31,29,31,30,31,30,31,31,30,31,30,31],Xc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",90),Gi(Li(e),"subPriority",1),Gi(Li(e),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"d":return Pc(tc,e);case"do":return n.ordinalNumber(e,{unit:"date"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){var n=Mc(e.getUTCFullYear()),r=e.getUTCMonth();return n?t>=1&&t<=Kc[r]:t>=1&&t<=Gc[r]}},{key:"set",value:function(e,t,n){return e.setUTCDate(n),e.setUTCHours(0,0,0,0),e}}]),n}($i),Qc=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",90),Gi(Li(e),"subpriority",1),Gi(Li(e),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"D":case"DD":return Pc(nc,e);case"Do":return n.ordinalNumber(e,{unit:"date"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return Mc(e.getUTCFullYear())?t>=1&&t<=366:t>=1&&t<=365}},{key:"set",value:function(e,t,n){return e.setUTCMonth(0,n),e.setUTCHours(0,0,0,0),e}}]),n}($i),$c=i(84314);function Jc(e,t,n){var r,o,a,i,c,u,s,l;(0,ti.Z)(2,arguments);var f=(0,$c.j)(),p=(0,ni.Z)(null!==(r=null!==(o=null!==(a=null!==(i=null==n?void 0:n.weekStartsOn)&&void 0!==i?i:null==n||null===(c=n.locale)||void 0===c||null===(u=c.options)||void 0===u?void 0:u.weekStartsOn)&&void 0!==a?a:f.weekStartsOn)&&void 0!==o?o:null===(s=f.locale)||void 0===s||null===(l=s.options)||void 0===l?void 0:l.weekStartsOn)&&void 0!==r?r:0);if(!(p>=0&&p<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var d=(0,ji.Z)(e),h=(0,ni.Z)(t),m=d.getUTCDay(),v=h%7,g=(v+7)%7,y=(g<p?7:0)+h-m;return d.setUTCDate(d.getUTCDate()+y),d}var eu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",90),Gi(Li(e),"incompatibleTokens",["D","i","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"E":case"EE":case"EEE":return n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"EEEEE":return n.day(e,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"EEEE":default:return n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return(e=Jc(e,n,r)).setUTCHours(0,0,0,0),e}}]),n}($i),tu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",90),Gi(Li(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n,r){var o=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"e":case"ee":return Sc(Ec(t.length,e),o);case"eo":return Sc(n.ordinalNumber(e,{unit:"day"}),o);case"eee":return n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"eeeee":return n.day(e,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"});case"eeee":default:return n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return(e=Jc(e,n,r)).setUTCHours(0,0,0,0),e}}]),n}($i),nu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",90),Gi(Li(e),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n,r){var o=function(e){var t=7*Math.floor((e-1)/7);return(e+r.weekStartsOn+6)%7+t};switch(t){case"c":case"cc":return Sc(Ec(t.length,e),o);case"co":return Sc(n.ordinalNumber(e,{unit:"day"}),o);case"ccc":return n.day(e,{width:"abbreviated",context:"standalone"})||n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"});case"ccccc":return n.day(e,{width:"narrow",context:"standalone"});case"cccccc":return n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"});case"cccc":default:return n.day(e,{width:"wide",context:"standalone"})||n.day(e,{width:"abbreviated",context:"standalone"})||n.day(e,{width:"short",context:"standalone"})||n.day(e,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(e,t){return t>=0&&t<=6}},{key:"set",value:function(e,t,n,r){return(e=Jc(e,n,r)).setUTCHours(0,0,0,0),e}}]),n}($i);var ru=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",90),Gi(Li(e),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){var r=function(e){return 0===e?7:e};switch(t){case"i":case"ii":return Ec(t.length,e);case"io":return n.ordinalNumber(e,{unit:"day"});case"iii":return Sc(n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r);case"iiiii":return Sc(n.day(e,{width:"narrow",context:"formatting"}),r);case"iiiiii":return Sc(n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r);case"iiii":default:return Sc(n.day(e,{width:"wide",context:"formatting"})||n.day(e,{width:"abbreviated",context:"formatting"})||n.day(e,{width:"short",context:"formatting"})||n.day(e,{width:"narrow",context:"formatting"}),r)}}},{key:"validate",value:function(e,t){return t>=1&&t<=7}},{key:"set",value:function(e,t,n){return(e=function(e,t){(0,ti.Z)(2,arguments);var n=(0,ni.Z)(t);n%7==0&&(n-=7);var r=1,o=(0,ji.Z)(e),a=o.getUTCDay(),i=((n%7+7)%7<r?7:0)+n-a;return o.setUTCDate(o.getUTCDate()+i),o}(e,n)).setUTCHours(0,0,0,0),e}}]),n}($i),ou=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",80),Gi(Li(e),"incompatibleTokens",["b","B","H","k","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"a":case"aa":case"aaa":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaaa":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(Dc(n),0,0,0),e}}]),n}($i),au=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",80),Gi(Li(e),"incompatibleTokens",["a","B","H","k","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"b":case"bb":case"bbb":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbbb":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(Dc(n),0,0,0),e}}]),n}($i),iu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",80),Gi(Li(e),"incompatibleTokens",["a","b","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"B":case"BB":case"BBB":return n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBBB":return n.dayPeriod(e,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(e,{width:"wide",context:"formatting"})||n.dayPeriod(e,{width:"abbreviated",context:"formatting"})||n.dayPeriod(e,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(e,t,n){return e.setUTCHours(Dc(n),0,0,0),e}}]),n}($i),cu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",70),Gi(Li(e),"incompatibleTokens",["H","K","k","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"h":return Pc(cc,e);case"ho":return n.ordinalNumber(e,{unit:"hour"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=12}},{key:"set",value:function(e,t,n){var r=e.getUTCHours()>=12;return r&&n<12?e.setUTCHours(n+12,0,0,0):r||12!==n?e.setUTCHours(n,0,0,0):e.setUTCHours(0,0,0,0),e}}]),n}($i),uu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",70),Gi(Li(e),"incompatibleTokens",["a","b","h","K","k","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"H":return Pc(oc,e);case"Ho":return n.ordinalNumber(e,{unit:"hour"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=23}},{key:"set",value:function(e,t,n){return e.setUTCHours(n,0,0,0),e}}]),n}($i),su=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",70),Gi(Li(e),"incompatibleTokens",["h","H","k","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"K":return Pc(ic,e);case"Ko":return n.ordinalNumber(e,{unit:"hour"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=11}},{key:"set",value:function(e,t,n){return e.getUTCHours()>=12&&n<12?e.setUTCHours(n+12,0,0,0):e.setUTCHours(n,0,0,0),e}}]),n}($i),lu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",70),Gi(Li(e),"incompatibleTokens",["a","b","h","H","K","t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"k":return Pc(ac,e);case"ko":return n.ordinalNumber(e,{unit:"hour"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=1&&t<=24}},{key:"set",value:function(e,t,n){var r=n<=24?n%24:n;return e.setUTCHours(r,0,0,0),e}}]),n}($i),fu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",60),Gi(Li(e),"incompatibleTokens",["t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"m":return Pc(uc,e);case"mo":return n.ordinalNumber(e,{unit:"minute"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,n){return e.setUTCMinutes(n,0,0),e}}]),n}($i),pu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",50),Gi(Li(e),"incompatibleTokens",["t","T"]),e}return qi(n,[{key:"parse",value:function(e,t,n){switch(t){case"s":return Pc(sc,e);case"so":return n.ordinalNumber(e,{unit:"second"});default:return Ec(t.length,e)}}},{key:"validate",value:function(e,t){return t>=0&&t<=59}},{key:"set",value:function(e,t,n){return e.setUTCSeconds(n,0),e}}]),n}($i),du=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",30),Gi(Li(e),"incompatibleTokens",["t","T"]),e}return qi(n,[{key:"parse",value:function(e,t){return Sc(Ec(t.length,e),(function(e){return Math.floor(e*Math.pow(10,3-t.length))}))}},{key:"set",value:function(e,t,n){return e.setUTCMilliseconds(n),e}}]),n}($i),hu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",10),Gi(Li(e),"incompatibleTokens",["t","T","x"]),e}return qi(n,[{key:"parse",value:function(e,t){switch(t){case"X":return _c(bc,e);case"XX":return _c(wc,e);case"XXXX":return _c(Oc,e);case"XXXXX":return _c(kc,e);case"XXX":default:return _c(xc,e)}}},{key:"set",value:function(e,t,n){return t.timestampIsSet?e:new Date(e.getTime()-n)}}]),n}($i),mu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",10),Gi(Li(e),"incompatibleTokens",["t","T","X"]),e}return qi(n,[{key:"parse",value:function(e,t){switch(t){case"x":return _c(bc,e);case"xx":return _c(wc,e);case"xxxx":return _c(Oc,e);case"xxxxx":return _c(kc,e);case"xxx":default:return _c(xc,e)}}},{key:"set",value:function(e,t,n){return t.timestampIsSet?e:new Date(e.getTime()-n)}}]),n}($i),vu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",40),Gi(Li(e),"incompatibleTokens","*"),e}return qi(n,[{key:"parse",value:function(e){return jc(e)}},{key:"set",value:function(e,t,n){return[new Date(1e3*n),{timestampIsSet:!0}]}}]),n}($i),gu=function(e){Hi(n,e);var t=Wi(n);function n(){var e;zi(this,n);for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return Gi(Li(e=t.call.apply(t,[this].concat(o))),"priority",20),Gi(Li(e),"incompatibleTokens","*"),e}return qi(n,[{key:"parse",value:function(e){return jc(e)}},{key:"set",value:function(e,t,n){return[new Date(n),{timestampIsSet:!0}]}}]),n}($i),yu={G:new Ji,y:new Rc,Y:new Ac,R:new Lc,u:new Fc,Q:new Hc,q:new Uc,M:new Bc,L:new Wc,w:new Yc,I:new qc,d:new Xc,D:new Qc,E:new eu,e:new tu,c:new nu,i:new ru,a:new ou,b:new au,B:new iu,h:new cu,H:new uu,K:new su,k:new lu,m:new fu,s:new pu,S:new du,X:new hu,x:new mu,t:new vu,T:new gu},bu=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,wu=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Ou=/^'([^]*?)'?$/,xu=/''/g,ku=/\S/,Su=/[a-zA-Z]/;function Pu(e,t,n,r){var o,a,i,c,u,s,l,f,p,d,h,m,v,g,y,b,w,O;(0,ti.Z)(3,arguments);var x=String(e),k=String(t),S=(0,$c.j)(),P=null!==(o=null!==(a=null==r?void 0:r.locale)&&void 0!==a?a:S.locale)&&void 0!==o?o:Mi.Z;if(!P.match)throw new RangeError("locale must contain match property");var _=(0,ni.Z)(null!==(i=null!==(c=null!==(u=null!==(s=null==r?void 0:r.firstWeekContainsDate)&&void 0!==s?s:null==r||null===(l=r.locale)||void 0===l||null===(f=l.options)||void 0===f?void 0:f.firstWeekContainsDate)&&void 0!==u?u:S.firstWeekContainsDate)&&void 0!==c?c:null===(p=S.locale)||void 0===p||null===(d=p.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==i?i:1);if(!(_>=1&&_<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var j=(0,ni.Z)(null!==(h=null!==(m=null!==(v=null!==(g=null==r?void 0:r.weekStartsOn)&&void 0!==g?g:null==r||null===(y=r.locale)||void 0===y||null===(b=y.options)||void 0===b?void 0:b.weekStartsOn)&&void 0!==v?v:S.weekStartsOn)&&void 0!==m?m:null===(w=S.locale)||void 0===w||null===(O=w.options)||void 0===O?void 0:O.weekStartsOn)&&void 0!==h?h:0);if(!(j>=0&&j<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(""===k)return""===x?(0,ji.Z)(n):new Date(NaN);var E,C={firstWeekContainsDate:_,weekStartsOn:j,locale:P},D=[new Qi],T=k.match(wu).map((function(e){var t=e[0];return t in Ni.Z?(0,Ni.Z[t])(e,P.formatLong):e})).join("").match(bu),M=[],R=Ti(T);try{var I=function(){var t=E.value;null!=r&&r.useAdditionalWeekYearTokens||!(0,Zi.Do)(t)||(0,Zi.qp)(t,k,e),null!=r&&r.useAdditionalDayOfYearTokens||!(0,Zi.Iu)(t)||(0,Zi.qp)(t,k,e);var n=t[0],o=yu[n];if(o){var a=o.incompatibleTokens;if(Array.isArray(a)){var i=M.find((function(e){return a.includes(e.token)||e.token===n}));if(i)throw new RangeError("The format string mustn't contain `".concat(i.fullToken,"` and `").concat(t,"` at the same time"))}else if("*"===o.incompatibleTokens&&M.length>0)throw new RangeError("The format string mustn't contain `".concat(t,"` and any other token at the same time"));M.push({token:n,fullToken:t});var c=o.run(x,t,P.match,C);if(!c)return{v:new Date(NaN)};D.push(c.setter),x=c.rest}else{if(n.match(Su))throw new RangeError("Format string contains an unescaped latin alphabet character `"+n+"`");if("''"===t?t="'":"'"===n&&(t=_u(t)),0!==x.indexOf(t))return{v:new Date(NaN)};x=x.slice(t.length)}};for(R.s();!(E=R.n()).done;){var N=I();if("object"===(0,Ci.Z)(N))return N.v}}catch(e){R.e(e)}finally{R.f()}if(x.length>0&&ku.test(x))return new Date(NaN);var A=D.map((function(e){return e.priority})).sort((function(e,t){return t-e})).filter((function(e,t,n){return n.indexOf(e)===t})).map((function(e){return D.filter((function(t){return t.priority===e})).sort((function(e,t){return t.subPriority-e.subPriority}))})).map((function(e){return e[0]})),Z=(0,ji.Z)(n);if(isNaN(Z.getTime()))return new Date(NaN);var L,F=(0,Ri.Z)(Z,(0,Ai.Z)(Z)),H={},U=Ti(A);try{for(U.s();!(L=U.n()).done;){var B=L.value;if(!B.validate(F,C))return new Date(NaN);var W=B.set(F,H,C);Array.isArray(W)?(F=W[0],Ii(H,W[1])):F=W}}catch(e){U.e(e)}finally{U.f()}return F}function _u(e){return e.match(Ou)[1].replace(xu,"'")}var ju=i(49599);function Eu(e,t,n){return(0,ti.Z)(2,arguments),(0,ju.Z)(Pu(e,t,new Date,n))}var Cu="react-datepicker-time__input",Du="react-datepicker__day",Tu="react-datepicker__input",Mu=function(e){return e.classList.contains(Du)},Ru=function(e){return e.classList.contains(Cu)},Iu=function(e){return e.classList.contains(Tu)},Nu=function(e,t){var n=t.hour,r=void 0===n?0:n,o=t.minute,a=void 0===o?0:o,i=t.second,c=void 0===i?0:i;return(0,xi.Z)((0,ki.Z)((0,Si.Z)(e,c),a),r)},Au=function(e){setTimeout((function(){if(e){var t=e.querySelector(".".concat(Du,'[tabindex="0"]'));t&&t.focus({preventScroll:!0})}}),0)},Zu=function(e){setTimeout((function(){e&&e.focus({preventScroll:!0})}),0)},Lu=function(e){var t=function(e,t){var n;(0,ti.Z)(1,arguments);var r=(0,ni.Z)(null!==(n=null==t?void 0:t.additionalDigits)&&void 0!==n?n:2);if(2!==r&&1!==r&&0!==r)throw new RangeError("additionalDigits must be 0, 1 or 2");if("string"!=typeof e&&"[object String]"!==Object.prototype.toString.call(e))return new Date(NaN);var o,a=ci(e);if(a.date){var i=ui(a.date,r);o=si(i.restDateString,i.year)}if(!o||isNaN(o.getTime()))return new Date(NaN);var c,u=o.getTime(),s=0;if(a.time&&(s=fi(a.time),isNaN(s)))return new Date(NaN);if(!a.timezone){var l=new Date(u+s),f=new Date(0);return f.setFullYear(l.getUTCFullYear(),l.getUTCMonth(),l.getUTCDate()),f.setHours(l.getUTCHours(),l.getUTCMinutes(),l.getUTCSeconds(),l.getUTCMilliseconds()),f}return c=di(a.timezone),isNaN(c)?new Date(NaN):new Date(u+s+c)}(e);return isNaN(t)?null:t},Fu=function(e){return e?e.toISOString():null};const Hu=function(e,t,n){var r=n.dateFormats,o=void 0===r?[]:r,a=n.minDate,i=n.maxDate,c=n.hasTime,u=n.valueToDate,s=void 0===u?Lu:u,l=n.dateToValue,f=void 0===l?Fu:l,p=(0,A.useRef)(null),d=(0,A.useState)(!1),h=We()(d,2),m=h[0],v=h[1],g=(0,A.useState)(!1),y=We()(g,2),b=y[0],w=y[1],O=s(e),x=a?s(a):void 0,k=i?s(i):void 0;(0,A.useEffect)((function(){(p.current&&"function"==typeof p.current.setOpen&&p.current.setOpen(m),m)&&document.querySelectorAll("button.react-datepicker__navigation").forEach((function(e){return e.setAttribute("tabindex","-1")}))}),[m]);var S=function(){return v(!1)},P=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(p.current&&"function"==typeof p.current.getPreSelection){var t,n=e?p.current.getPreSelection():null;return(null===(t=p.current.state)||void 0===t?void 0:t.preSelection)||n}return null},_=function(e){p.current&&"function"==typeof p.current.setPreSelection&&p.current.setPreSelection(e)},j=function(){t(null),_(null)},E=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=P(!1);if(n){var r=O||new Date,o=t?Nu(n,{hour:(0,Pi.Z)(r),minute:(0,_i.Z)(r),second:Ei(r)}):n;C(o,e)}},C=function(n,r){if(n){var a,i=!e&&Boolean(n),u=null==r||null===(a=r.target)||void 0===a?void 0:a.value,s=!!u&&o.some((function(e){return Eu(u,e)})),l=function(e){(0,ti.Z)(1,arguments);var t=(0,ji.Z)(e);return t.setHours(0,0,0,0),t}(n),d=(0,Pi.Z)(n)!==(0,Pi.Z)(l)||(0,_i.Z)(n)!==(0,_i.Z)(l);(i&&!d||s)&&c&&(n=Aa.Z.setCurrentTime(n)),t(f(n))}else j();var h;c||"click"!==(null==r?void 0:r.type)||(S(),Zu(null===(h=p.current)||void 0===h?void 0:h.input))},D=function(e){if("Tab"===e.key)if(e.shiftKey)if(Iu(e.target))setTimeout((function(){return S()}),0);else if(Ru(e.target)){var t,n;_(O||P(!0)),Au(null===(t=p.current)||void 0===t||null===(n=t.calendar)||void 0===n?void 0:n.componentNode)}else Mu(e.target)&&S();else Iu(e.target)&&m?(E(e),setTimeout((function(){return S()}),0)):Ru(e.target)?S():Mu(e.target)&&(c?(E(e,!0),_(null),w(!0),setTimeout((function(){var e,t,n;n=null===(e=p.current)||void 0===e||null===(t=e.calendar)||void 0===t?void 0:t.componentNode,setTimeout((function(){if(n){var e=n.querySelector("input.".concat(Cu));e&&e.focus({preventScroll:!0})}}),0),w(!1)}),0)):(E(e),S()));var r;"Enter"===e.key&&(S(),e.preventDefault(),e.stopPropagation(),Zu(null===(r=p.current)||void 0===r?void 0:r.input));if(["ArrowDown","ArrowUp","Enter"].includes(e.key))if(m){if(m&&null===P(!1)){var o,a;_(O||P(!0)),Au(null===(o=p.current)||void 0===o||null===(a=o.calendar)||void 0===a?void 0:a.componentNode)}}else v(!0),e.key="Handled".concat(e.key)},T=function(){var e;v((function(e){return!e})),_(null),Zu(null===(e=p.current)||void 0===e?void 0:e.input)};return{reactDatePickerProps:{closeOnScroll:function(){return S(),!0},onClickOutside:S,onInputClick:T,onKeyDown:D,onChange:C,onCalendarOpen:function(){_(null)},onBlur:function(){p.current&&p.current.setState({inputValue:null})},preventOpenOnFocus:!0,enableTabLoop:!1,shouldCloseOnSelect:!1,open:m,selected:O,showTimeInput:c,minDate:x,maxDate:k,ref:p,className:Tu},timeInputProps:{onKeyDown:D,className:Cu,tabIndex:b?void 0:"-1"},clearButtonProps:{onMouseDown:function(e){e.preventDefault(),j()}},calendarButtonProps:{onClick:T,className:m?"react-datepicker-ignore-onclickoutside":""}}};var Uu=i(49546),Bu=i(35997),Wu="HH:mm:ss",zu="HH:mm",Yu=function(e){return Eu(e,zu)},Vu=function(e){var t=function(e){return Eu(e,Wu)?Pu(e,Wu,new Date):Eu(e,zu)?Pu(e,zu,new Date):Eu(e,"HH:")?Pu(e,"HH:",new Date):Eu(e,"H")?Pu(e,"H",new Date):null}(e);return t&&!isNaN(t)?function(e){return(0,Uu.Z)(e,zu)}(t):""};const qu=function(e,t){var n=Vu(e),r=(0,A.useState)(n),o=We()(r,2),a=o[0],i=o[1],c=(0,A.useRef)(a),u=Bu.Z.usePrevious(n);(0,A.useEffect)((function(){u!==n&&a===u&&i(n)}),[n,a,u]);return{inputProps:{onChange:function(e){if(e.target.value!==a&&function(e){return/^(\d{0,2}|\d{1,2}:\d{0,2})$/.test(e)}(e.target.value)){var n=function(e,t){return e&&t?2!==e.length||3===t.length||e.includes(":")?e.length+1===t.length&&t.indexOf(":")===t.length-1?e.slice(0,-1):e:"".concat(e,":"):e}(e.target.value,c.current),r=n.indexOf(":"),o=n.substring(0,r),u=n.substring(r+1),s=parseInt(o,10),l=parseInt(u,10),f=!o||!Number.isNaN(s)&&s<24,p=!u||!Number.isNaN(l)&&l<60;if(!f||!p)return!1;c.current=n,i(n),n&&!Yu(n)||t(n)}},onBlur:function(){if(a!==n){var e=Vu(a);e&&Yu(e)?(c.current=e,i(e),t(e)):i(n)}},onFocus:function(e){a&&"function"==typeof e.target.select&&e.target.select()},value:a||""},clearButtonProps:{onClick:function(){t(""),i("")}}}};var Gu=["value","onChange","onKeyDown"];function Ku(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Xu(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ku(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ku(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}(0,Qa.registerLocale)("en",Aa.Z.getDateFnsLocale("en")),(0,Qa.registerLocale)("en-US",Aa.Z.getDateFnsLocale("en")),(0,Qa.registerLocale)("de-CH",Aa.Z.getDateFnsLocale("de-CH")),(0,Qa.registerLocale)("de",Aa.Z.getDateFnsLocale("de")),(0,Qa.registerLocale)("fr",Aa.Z.getDateFnsLocale("fr")),(0,Qa.registerLocale)("fr-CH",Aa.Z.getDateFnsLocale("fr")),(0,Qa.registerLocale)("it",Aa.Z.getDateFnsLocale("it")),(0,Qa.registerLocale)("it-CH",Aa.Z.getDateFnsLocale("it")),(0,Qa.setDefaultLocale)("de");var Qu=function(e){var t=e.onChange,n=e.label;return(0,ee.jsx)(W.Z,{onMouseDown:function(e){e.preventDefault(),t(null)},tabIndex:-1,children:n})},$u=function(e){var t=e.value,n=e.onChange,r=e.onKeyDown,o=Ve()(e,Gu),a=qu(t,(function(e){n&&n(e||"00:00")})).inputProps;return(0,ee.jsx)(Oi,Xu(Xu(Xu({},a),o),{},{type:"text",onKeyDown:r,onClick:function(e){e.target.focus()}}))},Ju={strategy:"fixed"};const es=(0,V.Zz)((0,v.ZP)((function(e){var t=e.immutable,n=e.id,r=e.value,o=e.minDate,a=e.maxDate,i=e.valueToDate,c=e.dateToValue,u=e.onChange,s=e.intl,l=e.placeholder,f=e.hasTime,p=e.dateFormats,d=void 0===p?[]:p,h=e.dateTimeFormats,m=void 0===h?[]:h,v=e.events,g=(0,A.useRef)(void 0),y=s.locale,b=function(e){return s.formatMessage({id:e})},w=(0,A.useRef)(null),O=Boolean(r),x=!t&&O,k=function(e){g.current=e,u(e)},S=Hu(r,k,{dateFormats:d,dateTimeFormats:m,minDate:o,maxDate:a,valueToDate:i,dateToValue:c,hasTime:f}),P=S.reactDatePickerProps,_=S.timeInputProps,j=S.clearButtonProps,E=S.calendarButtonProps;return(0,ee.jsx)(bi,{immutable:t,id:n,tabIndex:"-1",children:(0,ee.jsxs)(wi,{immutable:t,ref:w,hasTime:f,onBlur:function(e){if("function"==typeof(null==v?void 0:v.onBlur)){var t=void 0!==g.current?g.current:r;v.onBlur(t)}e.stopPropagation()},children:[(0,ee.jsx)($a(),Xu(Xu({},P),{},{disabled:t,dateFormat:[].concat(st()(m),st()(d)),placeholderText:l,showMonthDropdown:!0,showYearDropdown:!0,scrollableYearDropdown:!1,fixedHeight:!0,showPopperArrow:!1,locale:y,customTimeInput:(0,ee.jsx)($u,Xu({},_)),timeInputLabel:"",popperProps:Ju,todayButton:(0,ee.jsx)(Qu,{onChange:k,label:b("client.component.datePicker.todayLabel")})})),x&&(0,ee.jsx)(yo.Z,Xu({icon:"times",tabIndex:-1,"aria-label":b("client.component.datePicker.clearDateLabel")},j)),!t&&(0,ee.jsx)(yo.Z,Xu({icon:"calendar",tabIndex:-1},E))]})})})));function ts(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const ns=function(e){var t=e.onChange,n=e.options,r=e.id,o=e.value,a=e.immutable,i=e.events,c=e.placeholder,u=(0,Na.Z)(),s=(null==n?void 0:n.datePickerOptions)||{},f="".concat(Aa.Z.getLocalizedDateFormat(u.locale)),p=Aa.Z.getLocalizedDateFormatWithoutPunctuation(u.locale),d=[f,p,Aa.Z.useTwoDigitYear(f),Aa.Z.useTwoDigitYear(p)];return(0,ee.jsx)(es,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ts(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ts(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:r,value:o,onChange:t,dateFormats:d,hasTime:!1,immutable:a,placeholder:c,events:i},s))};function rs(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const os=(0,v.ZP)((function(e){var t=e.onChange,n=e.options,r=e.value,o=e.immutable,a=e.placeholder,i=(0,Na.Z)(),c=(null==n?void 0:n.datePickerOptions)||{},u="".concat(Aa.Z.getLocalizedDateTimeFormat(i.locale)),s="".concat(Aa.Z.getLocalizedDateFormat(i.locale)),f=Aa.Z.getLocalizedDateTimeFormatWithoutPunctuation(i.locale),p=[u,f,Aa.Z.useTwoDigitYear(u),Aa.Z.useTwoDigitYear(f)],d=Aa.Z.getLocalizedDateFormatWithoutPunctuation(i.locale),h=[s,d,Aa.Z.useTwoDigitYear(s),Aa.Z.useTwoDigitYear(d)];return(0,ee.jsx)(es,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rs(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rs(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({value:r,onChange:t,dateTimeFormats:p,dateFormats:h,hasTime:!0,immutable:o,placeholder:a},c))}));var as=i(18446),is=i.n(as);function cs(e,t,n,r){return new(n||(n=Promise))((function(o,a){function i(e){try{u(r.next(e))}catch(e){a(e)}}function c(e){try{u(r.throw(e))}catch(e){a(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,c)}u((r=r.apply(e,t||[])).next())}))}function us(e,t){var n,r,o,a,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return a={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function c(c){return function(u){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,c[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&c[0]?r.return:c[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,c[1])).done)return o;switch(r=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,r=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==c[0]&&2!==c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(e,i)}catch(e){c=[6,e],r=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([c,u])}}}Object.create;function ss(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,a=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=a.next()).done;)i.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=a.return)&&n.call(a)}finally{if(o)throw o.error}}return i}function ls(e,t,n){if(n||2===arguments.length)for(var r,o=0,a=t.length;o<a;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}Object.create;var fs=new Map([["aac","audio/aac"],["abw","application/x-abiword"],["arc","application/x-freearc"],["avif","image/avif"],["avi","video/x-msvideo"],["azw","application/vnd.amazon.ebook"],["bin","application/octet-stream"],["bmp","image/bmp"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["cda","application/x-cdf"],["csh","application/x-csh"],["css","text/css"],["csv","text/csv"],["doc","application/msword"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["eot","application/vnd.ms-fontobject"],["epub","application/epub+zip"],["gz","application/gzip"],["gif","image/gif"],["heic","image/heic"],["heif","image/heif"],["htm","text/html"],["html","text/html"],["ico","image/vnd.microsoft.icon"],["ics","text/calendar"],["jar","application/java-archive"],["jpeg","image/jpeg"],["jpg","image/jpeg"],["js","text/javascript"],["json","application/json"],["jsonld","application/ld+json"],["mid","audio/midi"],["midi","audio/midi"],["mjs","text/javascript"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mpeg","video/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["opus","audio/opus"],["otf","font/otf"],["png","image/png"],["pdf","application/pdf"],["php","application/x-httpd-php"],["ppt","application/vnd.ms-powerpoint"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["rar","application/vnd.rar"],["rtf","application/rtf"],["sh","application/x-sh"],["svg","image/svg+xml"],["swf","application/x-shockwave-flash"],["tar","application/x-tar"],["tif","image/tiff"],["tiff","image/tiff"],["ts","video/mp2t"],["ttf","font/ttf"],["txt","text/plain"],["vsd","application/vnd.visio"],["wav","audio/wav"],["weba","audio/webm"],["webm","video/webm"],["webp","image/webp"],["woff","font/woff"],["woff2","font/woff2"],["xhtml","application/xhtml+xml"],["xls","application/vnd.ms-excel"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xml","application/xml"],["xul","application/vnd.mozilla.xul+xml"],["zip","application/zip"],["7z","application/x-7z-compressed"],["mkv","video/x-matroska"],["mov","video/quicktime"],["msg","application/vnd.ms-outlook"]]);function ps(e,t){var n=function(e){var t=e.name;if(t&&-1!==t.lastIndexOf(".")&&!e.type){var n=t.split(".").pop().toLowerCase(),r=fs.get(n);r&&Object.defineProperty(e,"type",{value:r,writable:!1,configurable:!1,enumerable:!0})}return e}(e);if("string"!=typeof n.path){var r=e.webkitRelativePath;Object.defineProperty(n,"path",{value:"string"==typeof t?t:"string"==typeof r&&r.length>0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return n}var ds=[".DS_Store","Thumbs.db"];function hs(e){return"object"==typeof e&&null!==e}function ms(e){return bs(e.target.files).map((function(e){return ps(e)}))}function vs(e){return cs(this,void 0,void 0,(function(){return us(this,(function(t){switch(t.label){case 0:return[4,Promise.all(e.map((function(e){return e.getFile()})))];case 1:return[2,t.sent().map((function(e){return ps(e)}))]}}))}))}function gs(e,t){return cs(this,void 0,void 0,(function(){var n;return us(this,(function(r){switch(r.label){case 0:return e.items?(n=bs(e.items).filter((function(e){return"file"===e.kind})),"drop"!==t?[2,n]:[4,Promise.all(n.map(ws))]):[3,2];case 1:return[2,ys(Os(r.sent()))];case 2:return[2,ys(bs(e.files).map((function(e){return ps(e)})))]}}))}))}function ys(e){return e.filter((function(e){return-1===ds.indexOf(e.name)}))}function bs(e){if(null===e)return[];for(var t=[],n=0;n<e.length;n++){var r=e[n];t.push(r)}return t}function ws(e){if("function"!=typeof e.webkitGetAsEntry)return xs(e);var t=e.webkitGetAsEntry();return t&&t.isDirectory?Ss(t):xs(e)}function Os(e){return e.reduce((function(e,t){return ls(ls([],ss(e),!1),ss(Array.isArray(t)?Os(t):[t]),!1)}),[])}function xs(e){var t=e.getAsFile();if(!t)return Promise.reject("".concat(e," is not a File"));var n=ps(t);return Promise.resolve(n)}function ks(e){return cs(this,void 0,void 0,(function(){return us(this,(function(t){return[2,e.isDirectory?Ss(e):Ps(e)]}))}))}function Ss(e){var t=e.createReader();return new Promise((function(e,n){var r=[];!function o(){var a=this;t.readEntries((function(t){return cs(a,void 0,void 0,(function(){var a,i,c;return us(this,(function(u){switch(u.label){case 0:if(t.length)return[3,5];u.label=1;case 1:return u.trys.push([1,3,,4]),[4,Promise.all(r)];case 2:return a=u.sent(),e(a),[3,4];case 3:return i=u.sent(),n(i),[3,4];case 4:return[3,6];case 5:c=Promise.all(t.map(ks)),r.push(c),o(),u.label=6;case 6:return[2]}}))}))}),(function(e){n(e)}))}()}))}function Ps(e){return cs(this,void 0,void 0,(function(){return us(this,(function(t){return[2,new Promise((function(t,n){e.file((function(n){var r=ps(n,e.fullPath);t(r)}),(function(e){n(e)}))}))]}))}))}var _s=i(58363);function js(e){return function(e){if(Array.isArray(e))return Rs(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Ms(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Es(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Cs(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Es(Object(n),!0).forEach((function(t){Ds(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Es(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Ds(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ts(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==n)return;var r,o,a=[],i=!0,c=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(a.push(r.value),!t||a.length!==t);i=!0);}catch(e){c=!0,o=e}finally{try{i||null==n.return||n.return()}finally{if(c)throw o}}return a}(e,t)||Ms(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ms(e,t){if(e){if("string"==typeof e)return Rs(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Rs(e,t):void 0}}function Rs(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var Is="file-invalid-type",Ns="file-too-large",As="file-too-small",Zs="too-many-files",Ls=function(e){e=Array.isArray(e)&&1===e.length?e[0]:e;var t=Array.isArray(e)?"one of ".concat(e.join(", ")):e;return{code:Is,message:"File type must be ".concat(t)}},Fs=function(e){return{code:Ns,message:"File is larger than ".concat(e," ").concat(1===e?"byte":"bytes")}},Hs=function(e){return{code:As,message:"File is smaller than ".concat(e," ").concat(1===e?"byte":"bytes")}},Us={code:Zs,message:"Too many files"};function Bs(e,t){var n="application/x-moz-file"===e.type||(0,_s.Z)(e,t);return[n,n?null:Ls(t)]}function Ws(e,t,n){if(zs(e.size))if(zs(t)&&zs(n)){if(e.size>n)return[!1,Fs(n)];if(e.size<t)return[!1,Hs(t)]}else{if(zs(t)&&e.size<t)return[!1,Hs(t)];if(zs(n)&&e.size>n)return[!1,Fs(n)]}return[!0,null]}function zs(e){return null!=e}function Ys(e){var t=e.files,n=e.accept,r=e.minSize,o=e.maxSize,a=e.multiple,i=e.maxFiles,c=e.validator;return!(!a&&t.length>1||a&&i>=1&&t.length>i)&&t.every((function(e){var t=Ts(Bs(e,n),1)[0],a=Ts(Ws(e,r,o),1)[0],i=c?c(e):null;return t&&a&&!i}))}function Vs(e){return"function"==typeof e.isPropagationStopped?e.isPropagationStopped():void 0!==e.cancelBubble&&e.cancelBubble}function qs(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,(function(e){return"Files"===e||"application/x-moz-file"===e})):!!e.target&&!!e.target.files}function Gs(e){e.preventDefault()}function Ks(e){return-1!==e.indexOf("MSIE")||-1!==e.indexOf("Trident/")}function Xs(e){return-1!==e.indexOf("Edge/")}function Qs(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.navigator.userAgent;return Ks(e)||Xs(e)}function $s(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return t.some((function(t){return!Vs(e)&&t&&t.apply(void 0,[e].concat(r)),Vs(e)}))}}function Js(){return"showOpenFilePicker"in window}function el(e){return zs(e)?[{description:"Files",accept:Object.entries(e).filter((function(e){var t=Ts(e,2),n=t[0],r=t[1],o=!0;return ol(n)||(console.warn('Skipped "'.concat(n,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),o=!1),Array.isArray(r)&&r.every(al)||(console.warn('Skipped "'.concat(n,'" because an invalid file extension was provided.')),o=!1),o})).reduce((function(e,t){var n=Ts(t,2),r=n[0],o=n[1];return Cs(Cs({},e),{},Ds({},r,o))}),{})}]:e}function tl(e){if(zs(e))return Object.entries(e).reduce((function(e,t){var n=Ts(t,2),r=n[0],o=n[1];return[].concat(js(e),[r],js(o))}),[]).filter((function(e){return ol(e)||al(e)})).join(",")}function nl(e){return e instanceof DOMException&&("AbortError"===e.name||e.code===e.ABORT_ERR)}function rl(e){return e instanceof DOMException&&("SecurityError"===e.name||e.code===e.SECURITY_ERR)}function ol(e){return"audio/*"===e||"video/*"===e||"image/*"===e||"text/*"===e||/\w+\/[-+.\w]+/g.test(e)}function al(e){return/^.*\.[\w]+$/.test(e)}var il=["children"],cl=["open"],ul=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDrop"],sl=["refKey","onChange","onClick"];function ll(e){return function(e){if(Array.isArray(e))return dl(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||pl(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fl(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==n)return;var r,o,a=[],i=!0,c=!1;try{for(n=n.call(e);!(i=(r=n.next()).done)&&(a.push(r.value),!t||a.length!==t);i=!0);}catch(e){c=!0,o=e}finally{try{i||null==n.return||n.return()}finally{if(c)throw o}}return a}(e,t)||pl(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function pl(e,t){if(e){if("string"==typeof e)return dl(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?dl(e,t):void 0}}function dl(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function hl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ml(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?hl(Object(n),!0).forEach((function(t){vl(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function vl(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gl(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var yl=(0,A.forwardRef)((function(e,t){var n=e.children,r=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=ml(ml({},bl),e),n=t.accept,r=t.disabled,o=t.getFilesFromEvent,a=t.maxSize,i=t.minSize,c=t.multiple,u=t.maxFiles,s=t.onDragEnter,l=t.onDragLeave,f=t.onDragOver,p=t.onDrop,d=t.onDropAccepted,h=t.onDropRejected,m=t.onFileDialogCancel,v=t.onFileDialogOpen,g=t.useFsAccessApi,y=t.autoFocus,b=t.preventDropOnDocument,w=t.noClick,O=t.noKeyboard,x=t.noDrag,k=t.noDragEventsBubbling,S=t.onError,P=t.validator,_=(0,A.useMemo)((function(){return tl(n)}),[n]),j=(0,A.useMemo)((function(){return el(n)}),[n]),E=(0,A.useMemo)((function(){return"function"==typeof v?v:kl}),[v]),C=(0,A.useMemo)((function(){return"function"==typeof m?m:kl}),[m]),D=(0,A.useRef)(null),T=(0,A.useRef)(null),M=fl((0,A.useReducer)(xl,Ol),2),R=M[0],I=M[1],N=R.isFocused,Z=R.isFileDialogActive,L=(0,A.useRef)("undefined"!=typeof window&&window.isSecureContext&&g&&Js()),F=function(){!L.current&&Z&&setTimeout((function(){T.current&&(T.current.files.length||(I({type:"closeDialog"}),C()))}),300)};(0,A.useEffect)((function(){return window.addEventListener("focus",F,!1),function(){window.removeEventListener("focus",F,!1)}}),[T,Z,C,L]);var H=(0,A.useRef)([]),U=function(e){D.current&&D.current.contains(e.target)||(e.preventDefault(),H.current=[])};(0,A.useEffect)((function(){return b&&(document.addEventListener("dragover",Gs,!1),document.addEventListener("drop",U,!1)),function(){b&&(document.removeEventListener("dragover",Gs),document.removeEventListener("drop",U))}}),[D,b]),(0,A.useEffect)((function(){return!r&&y&&D.current&&D.current.focus(),function(){}}),[D,y,r]);var B=(0,A.useCallback)((function(e){S?S(e):console.error(e)}),[S]),W=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e),H.current=[].concat(ll(H.current),[e.target]),qs(e)&&Promise.resolve(o(e)).then((function(t){if(!Vs(e)||k){var n=t.length,r=n>0&&Ys({files:t,accept:_,minSize:i,maxSize:a,multiple:c,maxFiles:u,validator:P});I({isDragAccept:r,isDragReject:n>0&&!r,isDragActive:!0,type:"setDraggedFiles"}),s&&s(e)}})).catch((function(e){return B(e)}))}),[o,s,B,k,_,i,a,c,u,P]),z=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e);var t=qs(e);if(t&&e.dataTransfer)try{e.dataTransfer.dropEffect="copy"}catch(e){}return t&&f&&f(e),!1}),[f,k]),Y=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e);var t=H.current.filter((function(e){return D.current&&D.current.contains(e)})),n=t.indexOf(e.target);-1!==n&&t.splice(n,1),H.current=t,t.length>0||(I({type:"setDraggedFiles",isDragActive:!1,isDragAccept:!1,isDragReject:!1}),qs(e)&&l&&l(e))}),[D,l,k]),V=(0,A.useCallback)((function(e,t){var n=[],r=[];e.forEach((function(e){var t=fl(Bs(e,_),2),o=t[0],c=t[1],u=fl(Ws(e,i,a),2),s=u[0],l=u[1],f=P?P(e):null;if(o&&s&&!f)n.push(e);else{var p=[c,l];f&&(p=p.concat(f)),r.push({file:e,errors:p.filter((function(e){return e}))})}})),(!c&&n.length>1||c&&u>=1&&n.length>u)&&(n.forEach((function(e){r.push({file:e,errors:[Us]})})),n.splice(0)),I({acceptedFiles:n,fileRejections:r,type:"setFiles"}),p&&p(n,r,t),r.length>0&&h&&h(r,t),n.length>0&&d&&d(n,t)}),[I,c,_,i,a,u,p,d,h,P]),q=(0,A.useCallback)((function(e){e.preventDefault(),e.persist(),ne(e),H.current=[],qs(e)&&Promise.resolve(o(e)).then((function(t){Vs(e)&&!k||V(t,e)})).catch((function(e){return B(e)})),I({type:"reset"})}),[o,V,B,k]),G=(0,A.useCallback)((function(){if(L.current){I({type:"openDialog"}),E();var e={multiple:c,types:j};window.showOpenFilePicker(e).then((function(e){return o(e)})).then((function(e){V(e,null),I({type:"closeDialog"})})).catch((function(e){nl(e)?(C(e),I({type:"closeDialog"})):rl(e)?(L.current=!1,T.current?(T.current.value=null,T.current.click()):B(new Error("Cannot open the file picker because the https://developer.mozilla.org/en-US/docs/Web/API/File_System_Access_API is not supported and no <input> was provided."))):B(e)}))}else T.current&&(I({type:"openDialog"}),E(),T.current.value=null,T.current.click())}),[I,E,C,g,V,B,j,c]),K=(0,A.useCallback)((function(e){D.current&&D.current.isEqualNode(e.target)&&(" "!==e.key&&"Enter"!==e.key&&32!==e.keyCode&&13!==e.keyCode||(e.preventDefault(),G()))}),[D,G]),X=(0,A.useCallback)((function(){I({type:"focus"})}),[]),Q=(0,A.useCallback)((function(){I({type:"blur"})}),[]),$=(0,A.useCallback)((function(){w||(Qs()?setTimeout(G,0):G())}),[w,G]),J=function(e){return r?null:e},ee=function(e){return O?null:J(e)},te=function(e){return x?null:J(e)},ne=function(e){k&&e.stopPropagation()},re=(0,A.useMemo)((function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=void 0===t?"ref":t,o=e.role,a=e.onKeyDown,i=e.onFocus,c=e.onBlur,u=e.onClick,s=e.onDragEnter,l=e.onDragOver,f=e.onDragLeave,p=e.onDrop,d=gl(e,ul);return ml(ml(vl({onKeyDown:ee($s(a,K)),onFocus:ee($s(i,X)),onBlur:ee($s(c,Q)),onClick:J($s(u,$)),onDragEnter:te($s(s,W)),onDragOver:te($s(l,z)),onDragLeave:te($s(f,Y)),onDrop:te($s(p,q)),role:"string"==typeof o&&""!==o?o:"presentation"},n,D),r||O?{}:{tabIndex:0}),d)}}),[D,K,X,Q,$,W,z,Y,q,O,x,r]),oe=(0,A.useCallback)((function(e){e.stopPropagation()}),[]),ae=(0,A.useMemo)((function(){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.refKey,n=void 0===t?"ref":t,r=e.onChange,o=e.onClick,a=gl(e,sl);return ml(ml({},vl({accept:_,multiple:c,type:"file",style:{display:"none"},onChange:J($s(r,q)),onClick:J($s(o,oe)),tabIndex:-1},n,T)),a)}}),[T,n,c,q,r]);return ml(ml({},R),{},{isFocused:N&&!r,getRootProps:re,getInputProps:ae,rootRef:D,inputRef:T,open:J(G)})}(gl(e,il)),o=r.open,a=gl(r,cl);return(0,A.useImperativeHandle)(t,(function(){return{open:o}}),[o]),Z().createElement(A.Fragment,null,n(ml(ml({},a),{},{open:o})))}));yl.displayName="Dropzone";var bl={disabled:!1,getFilesFromEvent:function(e){return cs(this,void 0,void 0,(function(){return us(this,(function(t){return hs(e)&&hs(e.dataTransfer)?[2,gs(e.dataTransfer,e.type)]:function(e){return hs(e)&&hs(e.target)}(e)?[2,ms(e)]:Array.isArray(e)&&e.every((function(e){return"getFile"in e&&"function"==typeof e.getFile}))?[2,vs(e)]:[2,[]]}))}))},maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!0,autoFocus:!1};yl.defaultProps=bl,yl.propTypes={children:p().func,accept:p().objectOf(p().arrayOf(p().string)),multiple:p().bool,preventDropOnDocument:p().bool,noClick:p().bool,noKeyboard:p().bool,noDrag:p().bool,noDragEventsBubbling:p().bool,minSize:p().number,maxSize:p().number,maxFiles:p().number,disabled:p().bool,getFilesFromEvent:p().func,onFileDialogCancel:p().func,onFileDialogOpen:p().func,useFsAccessApi:p().bool,autoFocus:p().bool,onDragEnter:p().func,onDragLeave:p().func,onDragOver:p().func,onDrop:p().func,onDropAccepted:p().func,onDropRejected:p().func,onError:p().func,validator:p().func};const wl=yl;var Ol={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function xl(e,t){switch(t.type){case"focus":return ml(ml({},e),{},{isFocused:!0});case"blur":return ml(ml({},e),{},{isFocused:!1});case"openDialog":return ml(ml({},Ol),{},{isFileDialogActive:!0});case"closeDialog":return ml(ml({},e),{},{isFileDialogActive:!1});case"setDraggedFiles":return ml(ml({},e),{},{isDragActive:t.isDragActive,isDragAccept:t.isDragAccept,isDragReject:t.isDragReject});case"setFiles":return ml(ml({},e),{},{acceptedFiles:t.acceptedFiles,fileRejections:t.fileRejections});case"reset":return ml({},Ol);default:return e}}function kl(){}var Sl,Pl,_l,jl,El,Cl,Dl,Tl,Ml,Rl=i(69829),Il=V.ZP.section.withConfig({displayName:"StyledSection"})(Sl||(Sl=Y()(["\n flex: 1;\n display: flex;\n justify-content: flex-end;\n"]))),Nl=V.ZP.div.withConfig({displayName:"StyledButtonsWrapper"})(Pl||(Pl=Y()(["\n display: flex;\n align-items: center;\n\n "," {\n margin: 0;\n border-radius: 50%;\n padding: ",";\n\n a:hover {\n color: unset;\n }\n }\n"])),G.Z,q.Z.space(-2)),Al=V.ZP.div.withConfig({displayName:"StyledDropzone"})(_l||(_l=Y()(["\n width: 100%;\n\n &:hover {\n "," {\n background-color: ",";\n }\n }\n"])),G.Z,X.FS.color("backgroundItemHover")),Zl=V.ZP.div.withConfig({displayName:"StyledUploadInput"})(jl||(jl=Y()(["\n ","\n cursor: ",";\n background-color: ",";\n color: ",";\n padding: "," 0 0 0;\n display: flex;\n\n "," {\n float: right;\n position: relative;\n top: -",";\n margin: 0;\n border-radius: 50%;\n padding: ",";\n }\n"])),(0,Ft.Z)(),(function(e){return e.immutable?"not-allowed":"pointer"}),X.FS.color("paper"),(function(e){return e.immutable?Bt.shade2(e):Bt.base(e)}),q.Z.space(-2),G.Z,q.Z.space(-3.1),q.Z.space(-1.5)),Ll=V.ZP.div.withConfig({displayName:"StyledUploadProgress"})(El||(El=Y()(["\n && {\n padding-top: ",";\n text-align: center;\n display: inline-block;\n }\n"])),q.Z.space(-2)),Fl=(0,V.ZP)(Rl.Fe).withConfig({displayName:"StyledUploadProgressText"})(Cl||(Cl=Y()(["\n && {\n ","\n }\n"])),(0,Ft.Z)({fontSize:q.Z.font(-1)})),Hl=V.ZP.div.withConfig({displayName:"StyledUploadProgressIconAndText"})(Dl||(Dl=Y()(["\n && {\n display: flex;\n justify-content: center;\n align-items: center;\n\n span {\n margin-left: ",";\n }\n }\n"])),q.Z.space(-2)),Ul=V.ZP.div.withConfig({displayName:"StyledView"})(Tl||(Tl=Y()(["\n display: flex;\n justify-content: space-between;\n padding-top: ",";\n"])),q.Z.space(-2));function Bl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Wl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Bl(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Bl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const zl=function(e){var t=e.onDrop,n=e.immutable,r=e.text,o=e.onChoose;return(0,ee.jsxs)(Zl,{immutable:n,children:[(0,ee.jsx)(wl,{onDrop:function(e){var n=e.map((function(e){return Object.assign(e,{preview:URL.createObjectURL(e)})}));t(n[0])},multiple:!1,disabled:n,title:r||"drag and drop or click",children:function(e){var t=e.getRootProps,n=e.getInputProps;return(0,ee.jsx)(Il,{children:(0,ee.jsxs)(Al,Wl(Wl({},t()),{},{children:[(0,ee.jsx)("input",Wl({},n())),Ml||(Ml=(0,ee.jsx)(W.Z,{icon:"arrow-to-top"}))]}))})}}),o&&(0,ee.jsx)(W.Z,{onClick:function(e){o(),e.stopPropagation()},icon:"folder",label:"browse docs",iconOnly:!0})]})};var Yl=i(73906),Vl=function(e){var t=Math.floor(Math.log(e)/Math.log(1024));return"".concat(1*(e/Math.pow(1024,t)).toFixed(2)," ").concat(["Bytes","KB","MB","GB","TB"][t])};const ql=function(e){var t=e.file,n=e.text;return(0,ee.jsxs)(Ll,{children:[(0,ee.jsx)(Yl.Z,{alt:t.name,caption:t.name,maxDimensionX:"96px",maxDimensionY:"96px",srcUrl:t.preview,thumbnailUrl:t.type.startsWith("image")?t.preview:null}),(0,ee.jsxs)(Hl,{children:[(0,ee.jsx)(Hn.Z,{position:ct.Z.position.PREPEND}),(0,ee.jsxs)(Fl,{children:[n||"uploading"," (",Vl(t.size),")"]})]})]})};var Gl=i(28247);function Kl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Xl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Kl(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Kl(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Ql=function(e){var t,n=e.value,r=e.downloadTitle,o=e.immutable,a=e.onUpload,i=e.deleteTitle,c=null===(t=n.binaryLink)||void 0===t?void 0:t.startsWith("blob:");return(0,ee.jsxs)(Ul,{className:"StyledView",children:[(0,ee.jsx)(Yl.Z,Xl(Xl({alt:n.fileName},c&&{caption:n.fileName}),{},{fileName:n.fileName,maxDimensionX:"96px",maxDimensionY:"96px",srcUrl:n.binaryLink,thumbnailUrl:n.thumbnailLink})),(0,ee.jsxs)(Nl,{children:[!o&&(0,ee.jsx)(W.Z,{icon:"trash",onClick:function(){return a(null)},tabIndex:-1,title:i||"delete"}),(0,ee.jsx)(W.Z,{children:(0,ee.jsx)(Fn.Z,{neutral:!0,icon:"arrow-to-bottom",target:"_blank",href:Gl.Z.getDownloadUrl(n.binaryLink),tabIndex:-1,title:r||"download"})})]})]})};function $l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Jl(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$l(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var ef=function(e){var t=e.value,n=e.textResources,r=e.onUpload,o=e.onChoose,a=(0,A.useRef)(t),i=(0,A.useState)({isUploading:!1,previewFile:null}),c=We()(i,2),u=c[0],s=c[1];return(0,A.useEffect)((function(){is()(a.current,t)||s({isUploading:!1,previewFile:null}),a.current=t}),[t]),null!=t&&t.binaryLink?(0,ee.jsx)(Ql,Jl(Jl({},e),{},{deleteTitle:n.delete,downloadTitle:n.download})):u.isUploading?(0,ee.jsx)(ql,Jl({file:u.previewFile,text:n.uploading},e)):(0,ee.jsx)(zl,Jl(Jl({},e),{},{onDrop:function(e){!function(e){s({isUploading:!0,previewFile:e})}(e),r(e)},onChoose:o}))};ef.defaultProps={textResources:{}};const tf=ef;var nf=function(e){return(0,ee.jsx)(tf,{onUpload:function(t){null===t?e.onChange&&e.onChange(null):e.options.upload&&e.options.upload(t)},onChoose:e.options.choose,immutable:e.immutable,textResources:{upload:e.options.uploadText,uploading:e.options.uploadingText,delete:e.options.deleteText,download:e.options.downloadText},value:e.value?e.value:null})};nf.defaultProps={options:{}};const rf=nf;var of,af,cf=V.ZP.input.withConfig({displayName:"StyledDurationEdit"})(of||(of=Y()(["\n &&&& {\n ","\n flex-grow: 0;\n width: ","px;\n min-width: 2.5ch;\n }\n"])),Wn,(function(e){return e.width})),uf=V.ZP.label.withConfig({displayName:"StyledDurationEditFocusable"})(af||(af=Y()(["\n &&& {\n align-items: center;\n display: flex;\n flex-wrap: nowrap;\n margin-bottom: 0; /* reset bootstrap */\n margin-left: ",";\n\n &:first-child {\n margin-left: 0;\n }\n\n > span {\n color: ",";\n cursor: ",";\n }\n }\n"])),q.Z.space(1),(function(e){return e.immutable?X.FS.color("textDisabled"):X.FS.color("text")}),(function(e){return e.immutable?"not-allowed":"default"})),sf=function(e){var t=e.value,n=e.immutable,r=e.onChange,o=e.options,a=Aa.Z.millisecondsToDuration(t),i=(0,A.useState)(!1),c=We()(i,2),u=c[0],s=c[1],l=function(e,t){var n,o,i=null!==t?t:a.minutes,c=null!==e?e:a.hours;""!==i||""!==c?(i>=60&&(c=0),r((o=i,(n=c)||o?((n<0||o<0)&&(n=Kn(n),o=Kn(o)),60*(n||0)*6e4+6e4*(o||0)):null))):r(null)},f=function(){s(!0)},p=function(e){e.charCode>=48&&e.charCode<=57||45===e.charCode&&!0===o.allowNegative||e.preventDefault()},d=function(){return!0===o.allowNegative?"-?d+":"d+"},h=function(){return u||"number"==typeof t},m=function(e){return 9*(e+"").length},v=n&&Boolean(a.seconds);return(0,ee.jsxs)(Bn,{onBlur:function(){s(!1)},immutable:n,children:[(0,ee.jsxs)(uf,{immutable:n,children:[(0,ee.jsx)(cf,{disabled:n,immutable:n,min:!0===o.allowNegative?void 0:0,onChange:function(){},onFocus:f,onInput:function(e){var t=e.target.value.replace(/[^-\d]/g,"");l(t,null)},onKeyPress:p,pattern:d(),step:1,width:m(a.hours),type:"number",value:"number"!=typeof a.hours||0===a.hours&&!n?"":a.hours+""}),h()&&(0,ee.jsx)(B.ZP.Span,{children:o.hoursLabel})]}),(0,ee.jsxs)(uf,{immutable:n,children:[(0,ee.jsx)(cf,{disabled:n,immutable:n,min:!0!==o.allowNegative||null!==a.hours&&0!==a.hours?0:void 0,onChange:function(){},onFocus:f,onInput:function(e){var t=e.target.value.replace(/[^-\d]/g,"");l(null,t)},onKeyPress:p,pattern:d(),step:1,width:m(a.minutes),type:"number",value:a.minutes+""}),h()&&(0,ee.jsx)(B.ZP.Span,{children:o.minutesLabel})]}),v&&(0,ee.jsxs)(uf,{immutable:n,children:[(0,ee.jsx)(cf,{disabled:n,immutable:n,onChange:function(){},width:m(a.seconds),type:"number",value:a.seconds+""}),h()&&(0,ee.jsx)(B.ZP.Span,{children:o.secondsLabel})]})]})};sf.defaultProps={options:{hoursLabel:"hrs",minutesLabel:"min",secondsLabel:"s"}};const lf=sf;var ff;const pf=V.ZP.input.attrs((function(e){return{type:"text"}})).withConfig({displayName:"StyledStringEdit"})(ff||(ff=Y()(["\n &&&& {\n ","\n }\n"])),Wn);const df=Bu.Z.Debouncer((function(e){return(0,ee.jsxs)(Bn,{immutable:e.immutable,children:[(0,ee.jsx)(pf,{disabled:e.immutable,id:e.id,name:e.name,onChange:function(t){return e.onChange(t.target.value)},immutable:e.immutable,value:e.value||""}),e.value&&(0,ee.jsx)(Yn,{children:(0,ee.jsx)(Fn.Z,{href:"mailto:".concat(e.value.toString()),icon:"envelope",look:"ball",tabIndex:-1,target:"_blank",neutral:!0})})]})}));var hf=i(2205),mf=i.n(hf),vf=i(99489),gf=i.n(vf),yf=i(78718),bf=i.n(yf);function wf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Of(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?wf(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wf(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function xf(){xf=function(e,t){return new n(e,void 0,t)};var e=RegExp.prototype,t=new WeakMap;function n(e,r,o){var a=new RegExp(e,r);return t.set(a,o||t.get(e)),gf()(a,n.prototype)}function r(e,n){var r=t.get(n);return Object.keys(r).reduce((function(t,n){var o=r[n];if("number"==typeof o)t[n]=e[o];else{for(var a=0;void 0===e[o[a]]&&a+1<o.length;)a++;t[n]=e[o[a]]}return t}),Object.create(null))}return mf()(n,RegExp),n.prototype.exec=function(t){var n=e.exec.call(this,t);if(n){n.groups=r(n,this);var o=n.indices;o&&(o.groups=r(o,this))}return n},n.prototype[Symbol.replace]=function(n,o){if("string"==typeof o){var a=t.get(this);return e[Symbol.replace].call(this,n,o.replace(/\$<([^>]+)>/g,(function(e,t){var n=a[t];return"$"+(Array.isArray(n)?n.join("$"):n)})))}if("function"==typeof o){var i=this;return e[Symbol.replace].call(this,n,(function(){var e=arguments;return"object"!=Gn()(e[e.length-1])&&(e=[].slice.call(e)).push(r(e,i)),o.apply(this,e)}))}return e[Symbol.replace].call(this,n,o)},xf.apply(this,arguments)}var kf,Sf=["key","display","postcode","city","country","latitude","longitude"],Pf=function(e){return e*Math.PI/180},_f=function(e){var t=e.state,n=e.country,r=e.postcode,o=e.city,a=e.latitude,i=e.longitude,c=t?"- ".concat(t):"",u=n?"/ ".concat(n.display):"";return{key:r,display:"".concat(r," ").concat(o," ").concat(c," ").concat(u),postcode:r,city:o,country:n,latitude:Pf(a),longitude:Pf(i)}};function jf(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function Ef(){}function Cf(e){return!!(e||"").match(/\d/)}function Df(e){return null==e}function Tf(e){return"number"==typeof e&&isNaN(e)}function Mf(e){return e.replace(/[-[\]/{}()*+?.\\^$|]/g,"\\$&")}function Rf(e,t){void 0===t&&(t=!0);var n="-"===e[0],r=n&&t,o=(e=e.replace("-","")).split(".");return{beforeDecimal:o[0],afterDecimal:o[1]||"",hasNegation:n,addNegation:r}}function If(e,t,n){for(var r="",o=n?"0":"",a=0;a<=t-1;a++)r+=e[a]||o;return r}function Nf(e,t){return Array(t+1).join(e)}function Af(e){var t=e+"",n="-"===t[0]?"-":"";n&&(t=t.substring(1));var r=t.split(/[eE]/g),o=r[0],a=r[1];if(!(a=Number(a)))return n+o;var i=1+a,c=(o=o.replace(".","")).length;return i<0?o="0."+Nf("0",Math.abs(i))+o:i>=c?o+=Nf("0",i-c):o=(o.substring(0,i)||"0")+"."+o.substring(i),n+o}function Zf(e,t,n){if(-1!==["","-"].indexOf(e))return e;var r=(-1!==e.indexOf(".")||n)&&t,o=Rf(e),a=o.beforeDecimal,i=o.afterDecimal,c=o.hasNegation,u=parseFloat("0."+(i||"0")),s=(i.length<=t?"0."+i:u.toFixed(t)).split(".");return""+(c?"-":"")+a.split("").reverse().reduce((function(e,t,n){return e.length>n?(Number(e[0])+Number(t)).toString()+e.substring(1,e.length):t+e}),s[0])+(r?".":"")+If(s[1]||"",t,n)}function Lf(e,t){if(e.value=e.value,null!==e){if(e.createTextRange){var n=e.createTextRange();return n.move("character",t),n.select(),!0}return e.selectionStart||0===e.selectionStart?(e.focus(),e.setSelectionRange(t,t),!0):(e.focus(),!1)}}function Ff(e){return Math.max(e.selectionStart,e.selectionEnd)}function Hf(e){return{from:{start:0,end:0},to:{start:0,end:e.length},lastValue:""}}function Uf(e,t,n,r){var o,a,i,c=e.length;if(o=t,a=0,i=c,t=Math.min(Math.max(o,a),i),"left"===r){for(;t>=0&&!n[t];)t--;-1===t&&(t=n.indexOf(!0))}else{for(;t<=c&&!n[t];)t++;t>c&&(t=n.lastIndexOf(!0))}return-1===t&&(t=c),t}function Bf(e){for(var t=Array.from({length:e.length+1}).map((function(){return!0})),n=0,r=t.length;n<r;n++)t[n]=Boolean(Cf(e[n])||Cf(e[n-1]));return t}function Wf(e,t,n,r,o,a){void 0===a&&(a=Ef);var i,c,u=(0,A.useRef)(),s=(i=function(e){var t,a;return Df(e)||Tf(e)?(a="",t=""):"number"==typeof e||n?(a="number"==typeof e?Af(e):e,t=r(a)):(a=o(e,void 0),t=e),{formattedValue:t,numAsString:a}},(c=(0,A.useRef)(i)).current=i,(0,A.useRef)((function(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return c.current.apply(c,e)})).current),l=(0,A.useState)((function(){return s(t)})),f=l[0],p=l[1];return(0,A.useMemo)((function(){Df(e)?u.current=void 0:(u.current=s(e),p(u.current))}),[e,s]),[f,function(e,t){p({formattedValue:e.formattedValue,numAsString:e.value}),a(e,t)}]}function zf(e){return e.replace(/[^0-9]/g,"")}function Yf(e){return e}function Vf(e){var t=e.type;void 0===t&&(t="text");var n=e.displayType;void 0===n&&(n="input");var r=e.customInput,o=e.renderText,a=e.getInputRef,i=e.format;void 0===i&&(i=Yf);var c=e.removeFormatting;void 0===c&&(c=zf);var u=e.defaultValue,s=e.valueIsNumericString,l=e.onValueChange,f=e.isAllowed,p=e.onChange;void 0===p&&(p=Ef);var d=e.onKeyDown;void 0===d&&(d=Ef);var h=e.onMouseUp;void 0===h&&(h=Ef);var m=e.onFocus;void 0===m&&(m=Ef);var v=e.onBlur;void 0===v&&(v=Ef);var g=e.value,y=e.getCaretBoundary;void 0===y&&(y=Bf);var b=e.isValidInputCharacter;void 0===b&&(b=Cf);var w=jf(e,["type","displayType","customInput","renderText","getInputRef","format","removeFormatting","defaultValue","valueIsNumericString","onValueChange","isAllowed","onChange","onKeyDown","onMouseUp","onFocus","onBlur","value","getCaretBoundary","isValidInputCharacter"]),O=Wf(g,u,Boolean(s),i,c,l),x=O[0],k=x.formattedValue,S=x.numAsString,P=O[1],_=(0,A.useRef)();(0,A.useEffect)((function(){var e=i(S);if(void 0===_.current||e!==_.current){var t=D.current,n=c(e,void 0);F({formattedValue:e,numAsString:n,input:t,setCaretPosition:!0,source:kf.props,event:void 0})}}));var j=(0,A.useState)(!1),E=j[0],C=j[1],D=(0,A.useRef)(null),T=(0,A.useRef)({setCaretTimeout:null,focusTimeout:null});(0,A.useEffect)((function(){return C(!0),function(){clearTimeout(T.current.setCaretTimeout),clearTimeout(T.current.focusTimeout)}}),[]);var M=i,R=function(e,t){var n=parseFloat(t);return{formattedValue:e,value:t,floatValue:isNaN(n)?void 0:n}},I=function(e,t,n){Lf(e,t),T.current.setCaretTimeout=setTimeout((function(){e.value===n&&Lf(e,t)}),0)},N=function(e,t,n){return Uf(e,t,y(e),n)},L=function(e,t,n){var r=y(t),o=function(e,t,n,r,o,a){var i=o.findIndex((function(e){return e})),c=e.slice(0,i);t||n.startsWith(c)||(n=c+n,r+=c.length);for(var u=n.length,s=e.length,l={},f=new Array(u),p=0;p<u;p++){f[p]=-1;for(var d=0,h=s;d<h;d++)if(n[p]===e[d]&&!0!==l[d]){f[p]=d,l[d]=!0;break}}for(var m=r;m<u&&(-1===f[m]||!a(n[m]));)m++;var v=m===u||-1===f[m]?s:f[m];for(m=r-1;m>0&&-1===f[m];)m--;var g=-1===m||-1===f[m]?0:f[m]+1;return g>v?v:r-g<v-r?g:v}(t,k,e,n,r,b);return o=Uf(t,o,r)},F=function(e){var t=e.formattedValue;void 0===t&&(t="");var n=e.input,r=e.setCaretPosition;void 0===r&&(r=!0);var o=e.source,a=e.event,i=e.numAsString,c=e.caretPos;if(n){if(void 0===c&&r){var u=e.inputValue||n.value,s=Ff(n);n.value=t,c=L(u,t,s)}n.value=t,r&&void 0!==c&&I(n,c,t)}t!==k&&function(e,t){_.current=e.formattedValue,P(e,t)}(R(t,i),{event:a,source:o})},H=!E||"undefined"==typeof navigator||navigator.platform&&/iPhone|iPod/.test(navigator.platform)?void 0:"numeric",U=Object.assign({inputMode:H},w,{type:t,value:k,onChange:function(e){(function(e,t,n){var r=function(e,t){for(var n=0,r=0,o=e.length,a=t.length;e[n]===t[n]&&n<o;)n++;for(;e[o-1-r]===t[a-1-r]&&a-r>n&&o-r>n;)r++;return{from:{start:n,end:o-r},to:{start:n,end:a-r}}}(k,e),o=Object.assign(Object.assign({},r),{lastValue:k}),a=c(e,o),i=M(a);if(a=c(i,void 0),f&&!f(R(i,a))){var u=t.target,s=Ff(u),l=L(e,k,s);return I(u,l,k),!1}return F({formattedValue:i,numAsString:a,inputValue:e,event:t,source:n,setCaretPosition:!0,input:t.target}),!0})(e.target.value,e,kf.event)&&p(e)},onKeyDown:function(e){var t,n=e.target,r=e.key,o=n.selectionStart,a=n.selectionEnd,i=n.value;if(void 0===i&&(i=""),"ArrowLeft"===r||"Backspace"===r?t=Math.max(o-1,0):"ArrowRight"===r?t=Math.min(o+1,i.length):"Delete"===r&&(t=o),void 0!==t&&o===a){var c=t;if("ArrowLeft"===r||"ArrowRight"===r)c=N(i,t,"ArrowLeft"===r?"left":"right");else"Delete"!==r||b(i[t])?"Backspace"!==r||b(i[t])||(c=N(i,t,"left")):c=N(i,t,"right");c!==t&&I(n,c,i),e.isUnitTestRun&&I(n,c,i),d(e)}else d(e)},onMouseUp:function(e){var t=e.target,n=t.selectionStart,r=t.selectionEnd,o=t.value;if(void 0===o&&(o=""),n===r){var a=N(o,n);a!==n&&I(t,a,o)}h(e)},onFocus:function(e){e.persist&&e.persist();var t=e.target;D.current=t,T.current.focusTimeout=setTimeout((function(){var n=t.selectionStart,r=t.selectionEnd,o=t.value;void 0===o&&(o="");var a=N(o,n);a===n||0===n&&r===o.length||I(t,a,o),m(e)}),0)},onBlur:function(e){D.current=null,clearTimeout(T.current.focusTimeout),clearTimeout(T.current.setCaretTimeout),v(e)}});if("text"===n)return o?Z().createElement(Z().Fragment,null,o(k,w)||null):Z().createElement("span",Object.assign({},w,{ref:a}),k);if(r){var B=r;return Z().createElement(B,Object.assign({},U,{ref:a}))}return Z().createElement("input",Object.assign({},U,{ref:a}))}function qf(e,t){var n=t.decimalScale,r=t.fixedDecimalScale,o=t.prefix;void 0===o&&(o="");var a=t.suffix;void 0===a&&(a="");var i=t.allowNegative,c=t.thousandsGroupStyle;if(void 0===c&&(c="thousand"),""===e||"-"===e)return e;var u=Gf(t),s=u.thousandSeparator,l=u.decimalSeparator,f=0!==n&&-1!==e.indexOf(".")||n&&r,p=Rf(e,i),d=p.beforeDecimal,h=p.afterDecimal,m=p.addNegation;return void 0!==n&&(h=If(h,n,!!r)),s&&(d=function(e,t,n){var r=function(e){switch(e){case"lakh":return/(\d+?)(?=(\d\d)+(\d)(?!\d))(\.\d+)?/g;case"wan":return/(\d)(?=(\d{4})+(?!\d))/g;case"thousand":default:return/(\d)(?=(\d{3})+(?!\d))/g}}(n),o=e.search(/[1-9]/);return o=-1===o?e.length:o,e.substring(0,o)+e.substring(o,e.length).replace(r,"$1"+t)}(d,s,c)),o&&(d=o+d),a&&(h+=a),m&&(d="-"+d),e=d+(f&&l||"")+h}function Gf(e){var t=e.decimalSeparator;void 0===t&&(t=".");var n=e.thousandSeparator,r=e.allowedDecimalSeparators;return!0===n&&(n=","),r||(r=[t,"."]),{decimalSeparator:t,thousandSeparator:n,allowedDecimalSeparators:r}}function Kf(e,t,n){var r;void 0===t&&(t=Hf(e));var o=n.allowNegative,a=n.prefix;void 0===a&&(a="");var i=n.suffix;void 0===i&&(i="");var c=n.decimalScale,u=t.from,s=t.to,l=s.start,f=s.end,p=Gf(n),d=p.allowedDecimalSeparators,h=p.decimalSeparator,m=e[f]===h;if(Cf(e)&&(e===a||e===i)&&""===t.lastValue)return e;if(f-l==1&&-1!==d.indexOf(e[l])){var v=0===c?"":h;e=e.substring(0,l)+v+e.substring(l+1,e.length)}var g=function(e,t,n){var r=!1,o=!1;a.startsWith("-")?r=!1:e.startsWith("--")?(r=!1,o=!0):i.startsWith("-")&&e.length===i.length?r=!1:"-"===e[0]&&(r=!0);var c=r?1:0;return o&&(c=2),c&&(e=e.substring(c),t-=c,n-=c),{value:e,start:t,end:n,hasNegation:r}},y=g(e,l,f),b=y.hasNegation;e=(r=y).value,l=r.start,f=r.end;var w=g(t.lastValue,u.start,u.end),O=w.start,x=w.end,k=w.value,S=e.substring(l,f);!(e.length&&k.length&&(O>k.length-i.length||x<a.length))||S&&i.startsWith(S)||(e=k);var P=0;e.startsWith(a)?P+=a.length:l<a.length&&(P=l),f-=P;var _=(e=e.substring(P)).length,j=e.length-i.length;e.endsWith(i)?_=j:(f>j||f>e.length-i.length)&&(_=f),e=e.substring(0,_);var E=(e=((e=function(e,t){void 0===e&&(e="");var n=new RegExp("(-)"),r=new RegExp("(-)(.)*(-)"),o=n.test(e),a=r.test(e);return e=e.replace(/-/g,""),o&&!a&&t&&(e="-"+e),e}(b?"-"+e:e,o)).match(function(e,t){return new RegExp("(^-)|[0-9]|"+Mf(e),t?"g":void 0)}(h,!0))||[]).join("")).indexOf(h),C=Rf(e=e.replace(new RegExp(Mf(h),"g"),(function(e,t){return t===E?".":""})),o),D=C.beforeDecimal,T=C.afterDecimal,M=C.addNegation;return s.end-s.start<u.end-u.start&&""===D&&m&&!parseFloat(T)&&(e=M?"-":""),e}function Xf(e){var t=(e=function(e){var t=Gf(e),n=t.thousandSeparator,r=t.decimalSeparator,o=e.prefix;void 0===o&&(o="");var a=e.allowNegative;if(void 0===a&&(a=!0),n===r)throw new Error("\n Decimal separator can't be same as thousand separator.\n thousandSeparator: "+n+' (thousandSeparator = {true} is same as thousandSeparator = ",")\n decimalSeparator: '+r+" (default value for decimalSeparator is .)\n ");return o.startsWith("-")&&a&&(console.error("\n Prefix can't start with '-' when allowNegative is true.\n prefix: "+o+"\n allowNegative: "+a+"\n "),a=!1),Object.assign(Object.assign({},e),{allowNegative:a})}(e)).decimalSeparator;void 0===t&&(t=".");e.allowedDecimalSeparators,e.thousandsGroupStyle,e.suffix;var n=e.allowNegative,r=e.allowLeadingZeros,o=e.onKeyDown;void 0===o&&(o=Ef);var a=e.onBlur;void 0===a&&(a=Ef);var i=e.thousandSeparator,c=e.decimalScale,u=e.fixedDecimalScale,s=e.prefix;void 0===s&&(s="");var l=e.defaultValue,f=e.value,p=e.valueIsNumericString,d=e.onValueChange,h=jf(e,["decimalSeparator","allowedDecimalSeparators","thousandsGroupStyle","suffix","allowNegative","allowLeadingZeros","onKeyDown","onBlur","thousandSeparator","decimalScale","fixedDecimalScale","prefix","defaultValue","value","valueIsNumericString","onValueChange"]),m=function(t){return qf(t,e)},v=function(t,n){return Kf(t,n,e)},g=p;Df(f)?Df(l)||(g=null!=p?p:"number"==typeof l):g=null!=p?p:"number"==typeof f;var y=function(e){return Df(e)||Tf(e)?e:("number"==typeof e&&(e=Af(e)),g&&"number"==typeof c?Zf(e,c,Boolean(u)):e)},b=Wf(y(f),y(l),Boolean(g),m,v,d),w=b[0],O=w.numAsString,x=w.formattedValue,k=b[1];return Object.assign(Object.assign({},h),{value:x,valueIsNumericString:!1,isValidInputCharacter:function(e){return e===t||Cf(e)},onValueChange:k,format:m,removeFormatting:v,getCaretBoundary:function(t){return function(e,t){var n=t.prefix;void 0===n&&(n="");var r=t.suffix;void 0===r&&(r="");var o=Array.from({length:e.length+1}).map((function(){return!0})),a="-"===e[0];o.fill(!1,0,n.length+(a?1:0));var i=e.length;return o.fill(!1,i-r.length+1,i+1),o}(t,e)},onKeyDown:function(t){var r=t.target,a=t.key,l=r.selectionStart,f=r.selectionEnd,p=r.value;if(void 0===p&&(p=""),l===f){"Backspace"===a&&"-"===p[0]&&l===s.length+1&&n&&Lf(r,1);var d=Gf(e),h=d.decimalSeparator,m=d.allowedDecimalSeparators;"Backspace"===a&&p[l-1]===h&&c&&u&&(Lf(r,l-1),t.preventDefault()),(null==m?void 0:m.includes(a))&&p[l]===h&&Lf(r,l+1);var v=!0===i?",":i;"Backspace"===a&&p[l-1]===v&&Lf(r,l-1),"Delete"===a&&p[l]===v&&Lf(r,l+1),o(t)}else o(t)},onBlur:function(t){var n=O;if(n.match(/\d/g)||(n=""),r||(n=function(e){if(!e)return e;var t="-"===e[0];t&&(e=e.substring(1,e.length));var n=e.split("."),r=n[0].replace(/^0+/,"")||"0",o=n[1]||"";return(t?"-":"")+r+(o?"."+o:"")}(n)),u&&c&&(n=Zf(n,c,u)),n!==O){var o=qf(n,e);k({formattedValue:o,value:n,floatValue:parseFloat(n)},{event:t,source:kf.event})}a(t)}})}function Qf(e){var t=Xf(e);return Z().createElement(Vf,Object.assign({},t))}!function(e){e.event="event",e.props="prop"}(kf||(kf={}));var $f,Jf=["immutable"];function ep(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const tp=(0,V.ZP)((function(e){e.immutable;var t=Ve()(e,Jf);return(0,ee.jsx)(Qf,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ep(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ep(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},t))})).withConfig({displayName:"StyledNumberEdit"})($f||($f=Y()(["\n &&&& {\n ","\n }\n"])),Wn);function np(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function rp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?np(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):np(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var op=function(e){return 0!==e?Math.ceil(Math.log10(Math.abs(e)+1)):1},ap=function(e){return null!=e&&!isNaN(parseFloat(e))},ip=function(e,t,n){return!ap(n)||!(ap(t)&&n>t)&&!(ap(e)&&n<e)},cp=function(e,t){return function(n){var r=n.floatValue;return op(r)<op(e)||ip(e,t,r)}};const up=(0,v.ZP)(Bu.Z.Debouncer((function(e){var t,n=(t=e.intl.locale,{thousandSeparator:1111..toLocaleString(t).replace(/1/g,""),decimalSeparator:1.1.toLocaleString(t).replace(/1/g,"")}),r=n.thousandSeparator,o=n.decimalSeparator,a=e.options||{},i=a.prePointDigits,c=a.postPointDigits,u=a.minValue,s=a.maxValue,l=a.allowNegative,f=a.fixedDecimalScale,p=a.suffix,d=a.prefix,h=a.format,m=function(e,t,n){if(e){var r=Math.pow(10,e)-(t?1/Math.pow(10,t):1);return n&&n>r?n:r}return n}(i,c,s),v=rp(rp({isAllowed:cp(u,m),allowNegative:!!l},isNaN(c)?{}:{decimalScale:c}),{},{fixedDecimalScale:!!f});return(0,ee.jsx)(Bn,{immutable:e.immutable,children:(0,ee.jsx)(tp,rp(rp({decimalSeparator:o,disabled:e.immutable,id:e.id,valueIsNumericString:!0,name:e.name,onValueChange:function(t){e.onChange&&ip(u,m,t.floatValue)&&e.onChange(void 0!==t.floatValue?t.floatValue:null)},immutable:e.immutable,thousandSeparator:r,value:e.value,suffix:p,prefix:d},v),{},{format:h,placeholder:e.placeholder,onBlur:function(t){var n,r=!(n=t.target.value)||isNaN(n)?null:parseFloat(n);e.onChange&&!ip(u,m,r)&&(t.target.value=null)}}))})}),800));const sp=Bu.Z.Debouncer((function(e){var t=e.value,n=e.onChange,r=e.options,o=e.immutable,a=e.name,i=e.id,c=e.placeholder,u=r||{},s=u.minValue,l=u.maxValue,f=u.format,p=u.allowLeadingZeros,d=u.suffix;return(0,ee.jsx)(Bn,{immutable:o,children:(0,ee.jsx)(tp,{isAllowed:cp(s,l),allowNegative:!0,decimalScale:0,disabled:o,id:i,name:a,onValueChange:function(e){var t=e.value,r=e.floatValue,o=p?t:r;void 0===o&&(o=null),ip(s,l,r)&&n(o)},value:t,allowLeadingZeros:p,suffix:d,format:f,placeholder:c})})}),800);var lp,fp,pp,dp=V.ZP.div.withConfig({displayName:"StyledWrapper"})(lp||(lp=Y()(["\n display: flex;\n justify-content: stretch;\n"]))),hp=V.ZP.div.withConfig({displayName:"StyledLocationWrapper"})(fp||(fp=Y()(["\n flex-grow: 1;\n"]))),mp=V.ZP.div.withConfig({displayName:"StyledDistanceWrapper"})(pp||(pp=Y()(["\n width: 50px;\n border-left: 1px solid ",";\n margin-left: ",";\n padding-left: ",";\n"])),X.FS.color("border"),q.Z.space(-.8),q.Z.space(.5));function vp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function gp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?vp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const yp=function(e){var t=e.id,n=e.immutable,r=e.value,o=e.onChange,a=e.options,i=void 0===a?{}:a,c=i.suggestions,u=i.isLoading,s=i.fetchSuggestions,l=i.latitudeField,f=i.longitudeField,p=i.emptySearchText,d=i.noResultsText,h=i.kmSuffixText,m=r?r.distance:0,v=function(e){return null!=e&&e.latitude&&null!=e&&e.longitude?bf()(e,Sf):void 0}(r),g=function(e){return e?e.map(_f):[]}(c);return(0,ee.jsxs)(dp,{children:[(0,ee.jsx)(hp,{children:(0,ee.jsx)(la,{id:t,immutable:n,onChange:function(e){o(gp(gp({},function(e,t){return t?Of(Of({},e),bf()(t,Sf)):In()(e,Sf)}(r,e)),{},{latitudeField:l,longitudeField:f}))},isLoading:u,options:g,searchOptions:function(e){var t=function(e){if(!e)return null;var t=st()(e.matchAll(xf(/([\d]*)([^\d\s]*)/g,{postcode:1,city:2}))).map((function(e){return e.groups})),n=t.find((function(e){return e.postcode})),r=t.find((function(e){return e.city}));return Of(Of({},r?{city:r.city}:{}),n?{postcode:n.postcode}:{})}(e);s(t,null)},fetchOptions:function(e){e||s(null,null)},value:v,noResultsComp:function(e){return e.inputValue?d:p}})}),(0,ee.jsx)(mp,{children:(0,ee.jsx)(sp,{value:m,onChange:function(e){o(gp(gp({},r),{},{distance:e}))},immutable:n,options:{minValue:0,maxValue:100,suffix:" ".concat(h)}})})]})};var bp,wp=(0,A.lazy)((function(){return i.e(85).then(i.bind(i,17676))})),Op=function(e){var t=e.onChange,n=e.immutable,r=e.value,o=e.options;if(n)return(0,ee.jsx)(B.ZP.Span,{children:(0,ee.jsx)("div",{dangerouslySetInnerHTML:{__html:r}})});var a=o||{},i=a.contentLang,c=a.ckEditorConfig;return(0,ee.jsx)(A.Suspense,{fallback:bp||(bp=(0,ee.jsx)("i",{})),children:(0,ee.jsx)(wp,{onChange:function(e){t&&t(e)},value:r,contentLang:i,ckEditorConfig:c})})};Op.defaultProps={value:""};const xp=Op;var kp,Sp;function Pp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Pp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Pp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const jp=function(e){var t=e.onChange,n=e.options,r=e.value,o=e.id,a=e.immutable,i=e.name,c=function(e){return function(t){return t[e]}},u=function(e){var t=e.state,n=e.country,r=e.postcode,o=e.city,a=t?"- ".concat(t):"",i=n?"/ ".concat(n.display):"";return(0,ee.jsxs)(B.ZP.Span,{children:[r," ",o," ",a," ",i]})},s=function(e){return function(n,o){var a=o.newValue;t(_p(_p({},r),{},l()({},e,a)))}},f=function(e,n){var r=n.suggestion;t(r)},p=function(e){return function(t){var r=t.value;n.fetchSuggestions(l()({},e,r),n.locationValues.country)}},d={id:o,value:r.postcode||"",onChange:s("postcode"),disabled:a},h={value:r.city||"",onChange:s("city"),disabled:a};return(0,ee.jsx)(et,{children:function(e){var t,o=e.focused,s=e.getRef;return(0,ee.jsxs)(Qn,{immutable:a,name:i,ref:s,children:[(0,ee.jsx)(Ln(),{suggestions:n.suggestions||[],onSuggestionsFetchRequested:p("postcode"),getSuggestionValue:c("postcode"),renderSuggestion:u,onSuggestionsClearRequested:function(){},inputProps:d,onSuggestionSelected:f,focusInputOnSuggestionClick:!1,shouldRenderSuggestions:function(e){return e&&!a}}),(o||r.city||r.postcode)&&(kp||(kp=(0,ee.jsx)(B.ZP.Span,{children:"/"}))),(0,ee.jsx)(Ln(),{suggestions:n.suggestions||[],onSuggestionsFetchRequested:p("city"),getSuggestionValue:c("city"),renderSuggestion:u,onSuggestionsClearRequested:function(){},inputProps:h,onSuggestionSelected:f,focusInputOnSuggestionClick:!1,shouldRenderSuggestions:function(e){return e&&!a}}),(0,ee.jsxs)(Yn,{children:[n.isLoading&&(Sp||(Sp=(0,ee.jsx)(Hn.Z,{size:"1.8rem"}))),(t=n.locationValues,Boolean(t.city||t.postcode)&&!t.street&&(0,ee.jsx)(Fn.Z,{href:Xn(n.locationValues),icon:"map-marked",tabIndex:-1,target:"_blank",dense:!1,title:n.mapButtonTitle||"Show on map",neutral:!0}))]})]})}})};function Ep(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Cp=function(e){return(0,ee.jsx)(la,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ep(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ep(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,isMulti:!0,immutable:e.immutable,onChange:e.onChange,value:e.value},e.options))};function Dp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Tp=function(e){return(0,ee.jsx)(la,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Dp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,isMulti:!0,immutable:e.immutable,onChange:e.onChange,value:e.value,openMenuOnClick:!0},e.options))};var Mp,Rp=i(48926),Ip=i.n(Rp),Np=i(87757),Ap=i.n(Np);const Zp=V.ZP.input.attrs((function(e){return{type:"tel"}})).withConfig({displayName:"StyledPhoneEdit"})(Mp||(Mp=Y()(["\n &&&& {\n ","\n }\n"])),Wn);const Lp=function(e){var t=e.onChange,n=e.value,r=e.immutable,o=e.id,a=e.onLibLoaded,c=Ut()(e,"options.defaultCountry")||"CH",u=(0,A.useState)(null),s=We()(u,2),l=s[0],f=s[1],p=Z().createRef();(0,A.useEffect)((function(){(function(){var e=Ip()(Ap().mark((function e(){var t;return Ap().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all([i.e(631),i.e(877)]).then(i.bind(i,41866));case 2:t=e.sent,f(t),a&&a();case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()()}),[a]);var d=function(e,t){var n=e.substring(0,t-1).match(/\s/g);return(null==n?void 0:n.length)||0},h=n&&null!=l&&l.AsYouType?new l.AsYouType(c).input(n):n||"";return(0,ee.jsxs)(Bn,{immutable:r,children:[(0,ee.jsx)(Zp,{disabled:r||!l,id:o,name,onChange:function(e){var r=e.target.value,o=l?l.parseNumber(r,c):r,a=An()(o)?new l.AsYouType(c).input(r).replace(/\s/g,""):l.formatNumber(o,"E.164");t(a);var i=e.target.selectionStart;!function(e,t,n){if(n&&e.length!==n){var r=new l.AsYouType(c).input(t),o=new l.AsYouType(c).input(e),a=d(r,n),i=d(o,n)-a;window.requestAnimationFrame(function(){var e=n+i;this.setSelectionRange(e,e)}.bind(p.current))}}(r,n,i)},immutable:r||!l,ref:p,value:h}),h&&(0,ee.jsx)(Yn,{children:(0,ee.jsx)(Fn.Z,{href:"tel:".concat(n),icon:"phone",tabIndex:-1,target:"_blank",neutral:!0})})]})};function Fp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Hp(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Fp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Fp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Up=function(e){return e.map((function(e){return bf()(e,["key","display"])}))};const Bp=function(e){var t=e.id,n=e.immutable,r=e.onChange,o=e.options.isMulti,a=e.value;return(0,ee.jsx)(la,{id:t,immutable:n,isMulti:o,onChange:function(e){var t=o?e.map((function(e){return e.key})):[null==e?void 0:e.key],n=a.options.map((function(e){return Hp(Hp({},e),t.includes(e.key)?{selected:!0}:{selected:!1})}));r({options:n})},value:Up(a.options.filter((function(e){return e.selected}))),openMenuOnClick:!0,options:Up(a.options)})};function Wp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const zp=function(e){return(0,ee.jsx)(la,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Wp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Wp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,isMulti:!1,immutable:e.immutable,onChange:e.onChange,value:e.value},e.options))};function Yp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Vp=function(e){return(0,ee.jsx)(la,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({immutable:e.immutable,onChange:e.onChange,value:e.value},e.options))};function qp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Gp=function(e){return(0,ee.jsx)(la,function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qp(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qp(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({id:e.id,immutable:e.immutable,isMulti:!1,onChange:e.onChange,value:e.value,openMenuOnClick:!0},e.options))};const Kp=Bu.Z.Debouncer((function(e){return(0,ee.jsx)(Bn,{immutable:e.immutable,children:(0,ee.jsx)(pf,{disabled:e.immutable,id:e.id,name:e.name,onChange:function(t){return e.onChange(t.target.value)},immutable:e.immutable,value:e.value||""})})}));const Xp=function(){var e,t=(null===(e=navigator)||void 0===e?void 0:e.userAgent)||"";return/^((?!chrome|android).)*safari/i.test(t)};var Qp,$p,Jp,ed=(0,V.iv)(Qp||(Qp=Y()(["\n ","\n width: 100%;\n grid-area: 1 / 1 / 2 / 2;\n max-height: 25rem;\n box-sizing: border-box;\n"])),Wn),td=V.ZP.div.withConfig({displayName:"StyledSizeWrapper"})($p||($p=Y()(["\n display: grid;\n width: 100%;\n\n &:after {\n content: attr(data-replicated-value) ' ';\n white-space: pre-wrap;\n word-break: break-all;\n visibility: hidden;\n ","\n\n /* prevent scrollbar on Firefox */\n padding-right: 15px;\n }\n"])),ed),nd=V.ZP.textarea.withConfig({displayName:"StyledTextarea"})(Jp||(Jp=Y()(["\n &&&& {\n ","\n resize: none;\n margin: 0;\n min-height: 4em;\n }\n"])),ed);function rd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function od(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?rd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):rd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const ad=function(e){var t=e.value,n=e.onChange,r=e.name,o=e.id,a=e.disabled,i=e.immutable,c=(0,A.useState)(t),u=We()(c,2),s=u[0],l=u[1],f=!Xp(),p=(0,A.useCallback)(ar()(l,500,{trailing:!0}),[]);return(0,A.useEffect)((function(){f&&p(t)}),[t,f,p]),(0,ee.jsx)(td,od(od({"data-testid":"replicated-test"},f?{"data-replicated-value":s}:{}),{},{children:(0,ee.jsx)(nd,{value:t,name:r,id:o,onChange:n,disabled:a,immutable:i,rows:"1"})}))};const id=Bu.Z.Debouncer((function(e){return(0,ee.jsx)(Bn,{immutable:e.immutable,children:(0,ee.jsx)(ad,{id:e.id,immutable:e.immutable,maxRows:20,name:e.name,onChange:function(t){return e.onChange(t.target.value)},disabled:e.immutable,rows:2,value:e.value})})}));var cd;const ud=V.ZP.input.withConfig({displayName:"StyledTimeEdit"})(cd||(cd=Y()(["\n &&&& {\n ","\n }\n"])),Wn);function sd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ld(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const fd=function(e){var t=e.onChange,n=e.value,r=e.immutable,o=e.id,a=e.name,i=qu(n,t),c=i.inputProps,u=i.clearButtonProps,s=n&&!r;return(0,ee.jsxs)(Bn,{immutable:r,children:[(0,ee.jsx)(ud,ld({type:"text",disabled:r,id:o,immutable:r,name:a},c)),s&&(0,ee.jsx)(Yn,{children:(0,ee.jsx)(yo.Z,ld(ld({icon:"times"},u),{},{tabIndex:-1}))})]})};var pd;const dd=V.ZP.input.attrs((function(e){return{type:"url"}})).withConfig({displayName:"StyledUrlEdit"})(pd||(pd=Y()(["\n &&&& {\n ","\n }\n"])),Wn);const hd=Bu.Z.Debouncer((function(e){return(0,ee.jsxs)(Bn,{immutable:e.immutable,children:[(0,ee.jsx)(dd,{disabled:e.immutable,id:e.id,immutable:e.immutable,name:e.name,onChange:function(t){return e.onChange((n=t.target.value,r=/^[a-zA-Z0-9]+:\/\//.test(n),n.indexOf(".")>0&&!r?"https://".concat(n):n));var n,r},value:e.value}),e.value&&(0,ee.jsx)(Yn,{children:(0,ee.jsx)(Fn.Z,{href:e.value,icon:"external-link",look:"ball",tabIndex:-1,target:"_blank",neutral:!0})})]})}));function md(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function vd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?md(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):md(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var gd={boolean:ha,"boolean-select":fa,choice:Pa,code:Ia,date:ns,datetime:os,document:rf,duration:lf,email:df,geosearch:yp,html:xp,integer:sp,address:tr,location:jp,"multi-remote":Cp,"multi-select":Tp,number:up,phone:Lp,"pseudo-select":Bp,remote:zp,"search-filter":Vp,"single-select":Gp,string:Kp,text:id,url:hd,time:fd};const yd=function(e){var t=e.componentType,n=e.value,r=e.options,o=e.id,a=e.events,i=e.placeholder,c=e.readOnly,u=void 0!==c&&c;if(gd[t]){var s=gd[t],l=vd(vd({},In()(a,"onChange")),{},{onBlur:function(){"function"==typeof(null==a?void 0:a.onBlur)&&a.onBlur(n)}});return(0,ee.jsx)("div",vd(vd({},l),{},{"data-cy":"form-field",children:(0,ee.jsx)(s,vd(vd({value:n,onChange:null==a?void 0:a.onChange},An()(r)?{}:{options:r}),{},{id:o,immutable:u,placeholder:i,events:a}))}))}return console.log("No type-editor defined for component type",t),null};function bd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function wd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}const Od=function(e){return(0,ee.jsx)(Vn,{children:(0,ee.jsx)(yd,wd({componentType:e.type},In()(e,"type")))})};var xd,kd,Sd=V.ZP.div.withConfig({displayName:"StyledLoginFormInputWrapper"})(xd||(xd=Y()(["\n && {\n ","\n }\n"])),Un);const Pd=function(e){var t=e.verifyCode,n=e.intl,r=(0,A.useState)(null),o=We()(r,2),a=o[0],i=o[1],c=function(e){return n.formatMessage({id:e})},u=a&&a.toString().length>=6,s=function(e){e&&(e.preventDefault(),e.stopPropagation()),u&&t(a)};(0,H.z)(s);var l=ze.Z.isInAdminEmbedded();return(0,ee.jsxs)(ee.Fragment,{children:[kd||(kd=(0,ee.jsx)(B.ZP.P,{children:(0,ee.jsx)(F.Z,{id:"client.two-factor-connector.verificationText"})})),(0,ee.jsxs)("form",{onSubmit:s,children:[(0,ee.jsx)(kn,{hasValue:Boolean(a),id:"verification-input",label:c("client.two-factor-connector.verificationInputLabel"),labelPosition:l?"inside":"outside",children:(0,ee.jsx)(Sd,{children:(0,ee.jsx)(Od,{type:"integer",value:a,events:{onChange:i},options:{format:"### ###",allowLeadingZeros:!0}})})}),(0,ee.jsx)(K,{children:(0,ee.jsx)(W.Z,{label:c("client.two-factor-connector.okButton"),ink:"primary",look:"raised",type:"submit",disabled:!u})})]})]})};var _d={verifyCode:function(e){return{type:_,payload:{userCode:e}}}};const jd=(0,g.connect)((function(e,t){return{}}),_d)((0,v.ZP)(Pd));var Ed,Cd,Dd,Td,Md,Rd,Id=0,Nd=1,Ad=2,Zd=3;const Ld=function(e){var t=e.initialize,n=e.stage;(0,A.useEffect)((function(){t()}),[t]);return(0,ee.jsxs)(ee.Fragment,{children:[Rd||(Rd=(0,ee.jsx)(m.Z.Notifications,{})),function(){switch(n){case Id:return Ed||(Ed=(0,ee.jsx)(Ue,{}));case Nd:return Cd||(Cd=(0,ee.jsx)(Ze,{}));case Ad:return Dd||(Dd=(0,ee.jsx)(jd,{}));case Zd:return Td||(Td=(0,ee.jsx)(re,{}));default:return Md||(Md=(0,ee.jsx)(L.Z,{}))}}()]})};var Fd={initialize:D};const Hd=(0,g.connect)((function(e){return{stage:e.twoFactorConnector.stage}}),Fd)((0,v.ZP)(Ld));var Ud,Bd=i(81770);function Wd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function zd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Wd(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Wd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var Yd=function(e){return function(t){return zd(zd({},t),{},{stage:e})}},Vd=(Ud={},l()(Ud,b,Bd.Z.singleTransferReducer("twoFactorActive")),l()(Ud,w,Bd.Z.singleTransferReducer("secret")),l()(Ud,O,Bd.Z.singleTransferReducer("username")),l()(Ud,E,Bd.Z.singleTransferReducer("setupSuccessful")),l()(Ud,S,Yd(0)),l()(Ud,P,Yd(1)),l()(Ud,k,Yd(2)),l()(Ud,C,Yd(3)),Ud),qd={stage:null,twoFactorActive:null,secret:null,username:null,setupSuccessful:null};var Gd=i(34857),Kd=i(81719),Xd=i(54159),Qd=Ap().mark(lh),$d=Ap().mark(ph),Jd=Ap().mark(dh),eh=Ap().mark(mh),th=Ap().mark(vh),nh=Ap().mark(gh),rh=Ap().mark(yh),oh=Ap().mark(bh),ah=Ap().mark(wh),ih="relTwo_step_login_status",ch=function(e){return e.twoFactorConnector.username},uh=function(e){return e.twoFactorConnector.secret},sh=function(e){return e.input};function lh(){var e,t,n,r,o,a;return Ap().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return i.next=2,(0,Gd.Ys)(sh);case 2:if(e=i.sent,e.secret){i.next=14;break}return i.next=7,(0,Gd.Ys)(ch);case 7:return t=i.sent,i.next=10,(0,Gd.RE)(Kd.Z.requestSaga,"principals/".concat(t,"/two-factor"),{method:"GET"});case 10:return n=i.sent,r=n.body,o=r.secret,a=r.totpUri,i.next=14,(0,Gd.gz)(M({secret:o,uri:a}));case 14:return i.next=16,(0,Gd.gz)({type:P});case 16:case"end":return i.stop()}}),Qd)}function fh(e,t){return Xd.Z.executeRequest(e,t).then(Xd.Z.extractBody)}function ph(e,t,n,r){var o,a;return Ap().wrap((function(i){for(;;)switch(i.prev=i.next){case 0:return o={secret:e,userCode:t,username:n,password:r},i.next=3,(0,Gd.RE)(fh,"login",{method:"POST",headers:new Headers({"Content-Type":"application/x-www-form-urlencoded; charset=utf-8"}),body:Object.keys(o).filter((function(e){return!!o[e]})).sort().map((function(e){return"".concat(encodeURIComponent(e),"=").concat(encodeURIComponent(o[e]))})).join("&")});case 3:return a=i.sent,i.next=6,(0,Gd.gz)(N(Ut()(a,"TWOSTEPLOGIN_ACTIVATION.success",!1)));case 6:case"end":return i.stop()}}),$d)}function dh(e,t,n){var r;return Ap().wrap((function(o){for(;;)switch(o.prev=o.next){case 0:return o.next=2,(0,Gd.RE)(Kd.Z.requestSaga,"principals/".concat(e,"/two-factor"),{method:"POST",body:{secret:t,code:n},acceptedStatusCodes:[400]});case 2:return r=o.sent,o.next=5,(0,Gd.gz)(N(204===r.status));case 5:case"end":return o.stop()}}),Jd)}function hh(e){var t=e.payload.userCode;return Ap().mark((function e(){var n,r,o,a,i;return Ap().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,Gd.Ys)(ch);case 2:return n=e.sent,e.next=5,(0,Gd.Ys)(uh);case 5:return r=e.sent,o=r.secret,e.next=9,(0,Gd.Ys)(sh);case 9:if(a=e.sent,i=a.password,!a.forced){e.next=17;break}return e.next=15,(0,Gd.RE)(ph,o,t,n,i);case 15:e.next=19;break;case 17:return e.next=19,(0,Gd.RE)(dh,n,o,t);case 19:return e.next=21,(0,Gd.gz)({type:C});case 21:case"end":return e.stop()}}),e)}))()}function mh(){var e,t;return Ap().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,(0,Gd.RE)(gh);case 2:return n.next=4,(0,Gd.Ys)(sh);case 4:if(e=n.sent,!(t=e.secret)){n.next=9;break}return n.next=9,(0,Gd.gz)(M(t));case 9:return n.next=11,(0,Gd.gz)(I());case 11:case"end":return n.stop()}}),eh)}function vh(){return Ap().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,Gd.gz)(h.Z.fireExternalEvent("onSuccess"));case 2:case"end":return e.stop()}}),th)}function gh(){var e,t,n,r,o;return Ap().wrap((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,(0,Gd.RE)(yh);case 2:return e=a.sent,a.next=5,(0,Gd.gz)(R(e));case 5:return t='username === "'.concat(e,'"'),a.next=8,(0,Gd.RE)(Kd.Z.fetchEntitiesPage,"Principal",{where:t,paths:[ih]});case 8:if(!((n=a.sent).length>1)){a.next=11;break}throw new Error("More than one user found for username ".concat(e));case 11:return r=Ut()(n,"[0].paths.".concat(ih,".value.key")),o="1"===r,a.next=15,(0,Gd.gz)(T(o));case 15:case"end":return a.stop()}}),nh)}function yh(){var e,t,n;return Ap().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,(0,Gd.Ys)(sh);case 2:if(e=r.sent,!(t=e.username)){r.next=8;break}return r.abrupt("return",t);case 8:return r.next=10,(0,Gd.RE)(Kd.Z.requestSaga,"principals");case 10:return n=r.sent,r.abrupt("return",n.body.username);case 12:case"end":return r.stop()}}),rh)}function bh(){return Ap().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,Gd.gz)(h.Z.fireExternalEvent("onResize"));case 2:case"end":return e.stop()}}),oh)}function wh(){return Ap().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,Gd.$6)([(0,Gd.Fm)(x,lh),(0,Gd.Fm)(_,hh),(0,Gd.Fm)(y,mh),(0,Gd.Fm)(j,vh),(0,Gd.Fm)(S,bh),(0,Gd.Fm)(P,bh),(0,Gd.Fm)(k,bh),(0,Gd.Fm)(C,bh)]);case 2:case"end":return e.stop()}}),ah)}const Oh={twoFactorConnector:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:qd,t=arguments.length>1?arguments[1]:void 0,n=Vd[t.type];return n?n(e,t):e}};var xh,kh=[wh];function Sh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Ph(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Sh(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Sh(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var _h="two-factor-connector",jh=function(e,t,n,r){var o=xh||(xh=(0,ee.jsx)(Hd,{})),a=u.Z.createStore(Oh,kh,t,_h);return m.Z.addToStore(a,!0),d.Z.addToStore(a,!0,["console","remote","notification"]),h.Z.addToStore(a,(function(e){return u.Z.getEvents(Eh,e.input)})),u.Z.createApp(_h,o,a,{input:t,events:n,actions:[],publicPath:r,textResourceModules:["component","common",_h]})},Eh=["onSuccess","onCancel","onResize"],Ch=function(e){return u.Z.useApp({initApp:jh,props:e,packageName:_h,externalEvents:Eh}).component};Ch.propTypes=Ph(Ph({},Eh.reduce((function(e,t){return Ph(Ph({},e),{},l()({},t,p().func))}),{})),{},{username:p().string,password:p().string,secret:p().shape({secret:p().string.isRequired,uri:p().string.isRequired}),forced:p().bool});var Dh=u.Z.createBundleableApp(_h,jh,Ch);u.Z.registerAppInRegistry(Dh.name,Dh.init)})(),c})()));