@regulaforensics/idv-capture-web 2.3.150-nightly → 2.3.152-nightly
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/main.iife.js
CHANGED
|
@@ -44,7 +44,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
44
44
|
`)&&(k="(?: "+k+")",pe=" "+pe,W++),w=new RegExp("^(?:"+k+")",K)),j&&(w=new RegExp("^"+k+"$(?!\\s)",K)),A&&(R=U.lastIndex),Y=t(I,G?w:U,pe),G?Y?(Y.input=E(Y.input,W),Y[0]=E(Y[0],W),Y.index=U.lastIndex,U.lastIndex+=Y[0].length):U.lastIndex=0:A&&Y&&(U.lastIndex=U.global?Y.index+Y[0].length:R),j&&Y&&Y.length>1&&t(M,Y[0],w,function(){for(V=1;V<arguments.length-2;V++)arguments[V]===void 0&&(Y[V]=void 0)}),Y&&z)for(Y.groups=q=l(null),V=0;V<z.length;V++)te=z[V],q[te[0]]=Y[te[1]];return Y}),ZE=y,ZE}var I$;function KE(){if(I$)return c$;I$=1;var t=wt(),e=WE();return t({target:"RegExp",proto:!0,forced:/./.exec!==e},{exec:e}),c$}KE();var y$={},h$;function Yve(){if(h$)return y$;h$=1,KE();var t=wt(),e=yn(),n=qn(),a=_n(),o=Ni(),s=function(){var d=!1,f=/[ac]/;return f.exec=function(){return d=!0,/./.exec.apply(this,arguments)},f.test("abc")===!0&&d}(),l=/./.test;return t({target:"RegExp",proto:!0,forced:!s},{test:function(d){var f=a(this),g=o(d),M=f.exec;if(!n(M))return e(l,f,g);var I=e(M,f,g);return I===null?!1:(a(I),!0)}}),y$}Yve();function $ve(t,e){return Vve(t)||Hve(t,e)||Fve(t,e)||Qve()}function Qve(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
45
45
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Fve(t,e){if(t){if(typeof t=="string")return v$(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?v$(t,e):void 0}}function v$(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}function Hve(t,e){var n=t==null?null:typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a,o,s,l,d=[],f=!0,g=!1;try{if(s=(n=n.call(t)).next,e!==0)for(;!(f=(a=s.call(n)).done)&&(d.push(a.value),d.length!==e);f=!0);}catch(M){g=!0,o=M}finally{try{if(!f&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(g)throw o}}return d}}function Vve(t){if(Array.isArray(t))return t}function Bve(){var t=function(){return window.matchMedia("(orientation: landscape)").matches?"landscape":"portrait"},e=ht.useState(function(){var l=t();return{isPortrait:l==="portrait",isLandscape:l==="landscape",orientation:l}}),n=$ve(e,2),a=n[0],o=n[1],s=ht.useCallback(function(){var l=t();o(function(d){return d.orientation!==l?{isPortrait:l==="portrait",isLandscape:l==="landscape",orientation:l}:d})},[]);return ht.useEffect(function(){return typeof window!="undefined"&&(s(),window.addEventListener("load",s,!1),window.addEventListener("resize",s,!1)),function(){window.removeEventListener("load",s,!1),window.removeEventListener("resize",s,!1)}},[s]),a}function Dp(t){"@babel/helpers - typeof";return Dp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Dp(t)}function $u(t,e,n){return(e=Gve(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Gve(t){var e=Zve(t,"string");return Dp(e)=="symbol"?e:e+""}function Zve(t,e){if(Dp(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(Dp(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function qE(t){var e,n=t.children,a=t.direction,o=Bve(),s=o.isPortrait,l=ht.useRef(null);return vi.jsx("div",{"data-device":LE.isMobile&&s?"mobile":"desktop","data-direction":a||_h.Ltr,style:(e={},$u($u($u($u($u($u($u($u($u($u(e,"--base-main-color","#3075F4"),"--base-font-family","sans-serif"),"width","100%"),"maxWidth","680px"),"height","100%"),"position","relative"),"background","white"),"overflow","hidden"),"WebkitBackfaceVisibility","hidden"),"MozBackfaceVisibility","hidden"),$u($u($u($u(e,"WebkitTransform","translate3d(0, 0, 0)"),"MozTransform","translate3d(0, 0, 0)"),"margin","0 auto"),"fontFamily","var(--base-font-family)")),children:vi.jsx("div",{ref:l,style:{overflow:"auto",height:"100%",display:"flex",flexDirection:"column"},children:n})})}function Y4(t){"@babel/helpers - typeof";return Y4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Y4(t)}function Wve(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function m$(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,qve(a.key),a)}}function Kve(t,e,n){return e&&m$(t.prototype,e),n&&m$(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function qve(t){var e=Jve(t,"string");return Y4(e)=="symbol"?e:e+""}function Jve(t,e){if(Y4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(Y4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}function Xve(t,e,n){return e=bh(e),e3e(t,N$()?Reflect.construct(e,n||[],bh(t).constructor):e.apply(t,n))}function e3e(t,e){if(e&&(Y4(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return t3e(t)}function t3e(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function N$(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(N$=function(){return!!t})()}function bh(t){return bh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},bh(t)}function r3e(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&JE(t,e)}function JE(t,e){return JE=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},JE(t,e)}var n3e=function(t){function e(n){var a;return Wve(this,e),a=Xve(this,e,[n]),a.state={hasError:!1},a}return r3e(e,t),Kve(e,[{key:"componentDidCatch",value:function(a,o){console.warn("ErrorBoundary caught an error",a,o)}},{key:"render",value:function(){return this.state.hasError?vi.jsx(qE,{children:vi.jsxs("div",{style:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",padding:"20px",position:"absolute",width:"100%",height:"100%",top:0,left:0},children:[vi.jsx("div",{style:{fontSize:"20px",fontWeight:"bold",marginBottom:"10px"},children:"Error Page"}),vi.jsx("div",{style:{marginBottom:"10px"},children:"Details"})]})}):this.props.children}}],[{key:"getDerivedStateFromError",value:function(a){return{hasError:!0}}}])}(ht.Component),E$={},D$;function i3e(){if(D$)return E$;D$=1;var t=wt(),e=X1().filter,n=xh(),a=n("filter");return t({target:"Array",proto:!0,forced:!a},{filter:function(s){return e(this,s,arguments.length>1?arguments[1]:void 0)}}),E$}i3e();var T$={},j$;function a3e(){if(j$)return T$;j$=1;var t=wt(),e=X1().find,n=w5(),a="find",o=!0;return a in[]&&Array(1)[a](function(){o=!1}),t({target:"Array",proto:!0,forced:o},{find:function(l){return e(this,l,arguments.length>1?arguments[1]:void 0)}}),n(a),T$}a3e();var S$={},XE,C$;function A$(){if(C$)return XE;C$=1;var t=X1().forEach,e=P4(),n=e("forEach");return XE=n?[].forEach:function(o){return t(this,o,arguments.length>1?arguments[1]:void 0)},XE}var O$;function o3e(){if(O$)return S$;O$=1;var t=wt(),e=A$();return t({target:"Array",proto:!0,forced:[].forEach!==e},{forEach:e}),S$}o3e();var _$={},x$;function u3e(){if(x$)return _$;x$=1;var t=wt(),e=wN().includes,n=dr(),a=w5(),o=n(function(){return!Array(1).includes()});return t({target:"Array",proto:!0,forced:o},{includes:function(l){return e(this,l,arguments.length>1?arguments[1]:void 0)}}),a("includes"),_$}u3e();var w$={},b$;function s3e(){if(b$)return w$;b$=1;var t=wt(),e=tn(),n=ZN().f;return t({target:"Object",stat:!0,forced:Object.defineProperties!==n,sham:!e},{defineProperties:n}),w$}s3e();var L$={},k$;function l3e(){if(k$)return L$;k$=1;var t=wt(),e=dr(),n=hl(),a=RM().f,o=tn(),s=!o||e(function(){a(1)});return t({target:"Object",stat:!0,forced:s,sham:!o},{getOwnPropertyDescriptor:function(d,f){return a(n(d),f)}}),L$}l3e();var R$={},z$;function c3e(){if(z$)return R$;z$=1;var t=wt(),e=tn(),n=bz(),a=hl(),o=RM(),s=Ep();return t({target:"Object",stat:!0,sham:!e},{getOwnPropertyDescriptors:function(d){for(var f=a(d),g=o.f,M=n(f),I={},y=0,h,m;M.length>y;)m=g(f,h=M[y++]),m!==void 0&&s(I,h,m);return I}}),R$}c3e();var P$={},U$;function f3e(){if(U$)return P$;U$=1;var t=wt(),e=Su(),n=lp(),a=dr(),o=a(function(){n(1)});return t({target:"Object",stat:!0,forced:o},{keys:function(l){return n(e(l))}}),P$}f3e();var Y$={},eD,$$;function Q$(){if($$)return eD;$$=1;var t=Jn(),e=yl(),n=Zn(),a=n("match");return eD=function(o){var s;return t(o)&&((s=o[a])!==void 0?!!s:e(o)==="RegExp")},eD}var tD,F$;function H$(){if(F$)return tD;F$=1;var t=Q$(),e=TypeError;return tD=function(n){if(t(n))throw new e("The method doesn't accept regular expressions");return n},tD}var rD,V$;function B$(){if(V$)return rD;V$=1;var t=Zn(),e=t("match");return rD=function(n){var a=/./;try{"/./"[n](a)}catch(o){try{return a[e]=!1,"/./"[n](a)}catch(s){}}return!1},rD}var G$;function d3e(){if(G$)return Y$;G$=1;var t=wt(),e=Mr(),n=H$(),a=Tu(),o=Ni(),s=B$(),l=e("".indexOf);return t({target:"String",proto:!0,forced:!s("includes")},{includes:function(f){return!!~l(o(a(this)),o(n(f)),arguments.length>1?arguments[1]:void 0)}}),Y$}d3e();var Z$={},W$={},K$;function g3e(){if(K$)return W$;K$=1;var t=wt(),e=Lr(),n=PM(),a=_n(),o=qn(),s=gp(),l=Uu(),d=Ep(),f=dr(),g=mi(),M=Zn(),I=jh().IteratorPrototype,y=tn(),h=yu(),m="constructor",N="Iterator",E=M("toStringTag"),A=TypeError,T=e[N],j=h||!o(T)||T.prototype!==I||!f(function(){T({})}),C=function(){if(n(this,I),s(this)===I)throw new A("Abstract class Iterator not directly constructable")},_=function(L,U){y?l(I,L,{configurable:!0,get:function(){return U},set:function(H){if(a(this),this===I)throw new A("You can't redefine this property");g(this,L)?this[L]=H:d(this,L,H)}}):I[L]=U};return g(I,E)||_(E,N),(j||!g(I,m)||I[m]===Object)&&_(m,C),C.prototype=I,t({global:!0,constructor:!0,forced:j},{Iterator:C}),W$}var q$;function M3e(){return q$||(q$=1,g3e()),Z$}M3e();var J$={},X$={},nD,eQ;function rd(){return eQ||(eQ=1,nD=function(t){return{iterator:t,next:t.next,done:!1}}),nD}var iD,tQ;function rQ(){if(tQ)return iD;tQ=1;var t=yn(),e=Vl(),n=Hl(),a=Ip(),o=Zn(),s=Au(),l=K1(),d=jh().IteratorPrototype,f=Mp(),g=ml(),M=o("toStringTag"),I="IteratorHelper",y="WrapForValidIterator",h=s.set,m=function(A){var T=s.getterFor(A?y:I);return a(e(d),{next:function(){var C=T(this);if(A)return C.nextHandler();if(C.done)return f(void 0,!0);try{var _=C.nextHandler();return C.returnHandlerResult?_:f(_,C.done)}catch(L){throw C.done=!0,L}},return:function(){var j=T(this),C=j.iterator;if(j.done=!0,A){var _=l(C,"return");return _?t(_,C):f(void 0,!0)}if(j.inner)try{g(j.inner.iterator,"normal")}catch(L){return g(C,"throw",L)}return C&&g(C,"normal"),f(void 0,!0)}})},N=m(!0),E=m(!1);return n(E,M,"Iterator Helper"),iD=function(A,T,j){var C=function(L,U){U?(U.iterator=L.iterator,U.next=L.next):U=L,U.type=T?y:I,U.returnHandlerResult=!!j,U.nextHandler=A,U.counter=0,U.done=!1,h(this,U)};return C.prototype=T?N:E,C},iD}var aD,nQ;function $M(){if(nQ)return aD;nQ=1;var t=Lr();return aD=function(e,n){var a=t.Iterator,o=a&&a.prototype,s=o&&o[e],l=!1;if(s)try{s.call({next:function(){return{done:!0}},return:function(){l=!0}},-1)}catch(d){d instanceof n||(l=!1)}if(!l)return s},aD}var iQ;function p3e(){if(iQ)return X$;iQ=1;var t=wt(),e=yn(),n=yo(),a=_n(),o=rd(),s=rQ(),l=YE(),d=yu(),f=ml(),g=$M(),M=!d&&g("filter",TypeError),I=s(function(){for(var y=this.iterator,h=this.predicate,m=this.next,N,E,A;;){if(N=a(e(m,y)),E=this.done=!!N.done,E)return;if(A=N.value,l(y,h,[A,this.counter++],!0))return A}});return t({target:"Iterator",proto:!0,real:!0,forced:d||M},{filter:function(h){a(this);try{n(h)}catch(m){f(this,"throw",m)}return M?e(M,this,h):new I(o(this),{predicate:h})}}),X$}var aQ;function I3e(){return aQ||(aQ=1,p3e()),J$}I3e();var oQ={},uQ={},sQ;function y3e(){if(sQ)return uQ;sQ=1;var t=wt(),e=yn(),n=$f(),a=yo(),o=_n(),s=rd(),l=ml(),d=$M(),f=d("find",TypeError);return t({target:"Iterator",proto:!0,real:!0,forced:f},{find:function(M){o(this);try{a(M)}catch(h){l(this,"throw",h)}if(f)return e(f,this,M);var I=s(this),y=0;return n(I,function(h,m){if(M(h,y++))return m(h)},{IS_RECORD:!0,INTERRUPTED:!0}).result}}),uQ}var lQ;function h3e(){return lQ||(lQ=1,y3e()),oQ}h3e();var cQ={},fQ={},dQ;function v3e(){if(dQ)return fQ;dQ=1;var t=wt(),e=yn(),n=$f(),a=yo(),o=_n(),s=rd(),l=ml(),d=$M(),f=d("forEach",TypeError);return t({target:"Iterator",proto:!0,real:!0,forced:f},{forEach:function(M){o(this);try{a(M)}catch(h){l(this,"throw",h)}if(f)return e(f,this,M);var I=s(this),y=0;n(I,function(h){M(h,y++)},{IS_RECORD:!0})}}),fQ}var gQ;function m3e(){return gQ||(gQ=1,v3e()),cQ}m3e();var MQ={},pQ;function N3e(){if(pQ)return MQ;pQ=1;var t=Lr(),e=OY(),n=xY(),a=A$(),o=Hl(),s=function(d){if(d&&d.forEach!==a)try{o(d,"forEach",a)}catch(f){d.forEach=a}};for(var l in e)e[l]&&s(t[l]&&t[l].prototype);return s(n),MQ}N3e();const IQ=t=>{let e;const n=new Set,a=(g,M)=>{const I=typeof g=="function"?g(e):g;if(!Object.is(I,e)){const y=e;e=(M!=null?M:typeof I!="object"||I===null)?I:Object.assign({},e,I),n.forEach(h=>h(e,y))}},o=()=>e,d={setState:a,getState:o,getInitialState:()=>f,subscribe:g=>(n.add(g),()=>n.delete(g))},f=e=t(a,o,d);return d},E3e=t=>t?IQ(t):IQ,D3e=t=>t;function T3e(t,e=D3e){const n=Rn.useSyncExternalStore(t.subscribe,()=>e(t.getState()),()=>e(t.getInitialState()));return Rn.useDebugValue(n),n}const yQ=t=>{const e=E3e(t),n=a=>T3e(e,a);return Object.assign(n,e),n},j3e=t=>t?yQ(t):yQ;var hQ={},vQ;function S3e(){if(vQ)return hQ;vQ=1;var t=cp();return t("asyncIterator"),hQ}S3e();var mQ={},NQ;function C3e(){if(NQ)return mQ;NQ=1;var t=ju(),e=cp(),n=vl();return e("toStringTag"),n(t("Symbol"),"Symbol"),mQ}C3e();var EQ={},DQ;function A3e(){if(DQ)return EQ;DQ=1;var t=wt(),e=X1().map,n=xh(),a=n("map");return t({target:"Array",proto:!0,forced:!a},{map:function(s){return e(this,s,arguments.length>1?arguments[1]:void 0)}}),EQ}A3e();var TQ={},oD,jQ;function O3e(){if(jQ)return oD;jQ=1;var t=yo(),e=Su(),n=rp(),a=E1(),o=TypeError,s="Reduce of empty array with no initial value",l=function(d){return function(f,g,M,I){var y=e(f),h=n(y),m=a(y);if(t(g),m===0&&M<2)throw new o(s);var N=d?m-1:0,E=d?-1:1;if(M<2)for(;;){if(N in h){I=h[N],N+=E;break}if(N+=E,d?N<0:m<=N)throw new o(s)}for(;d?N>=0:m>N;N+=E)N in h&&(I=g(I,h[N],N,y));return I}};return oD={left:l(!1),right:l(!0)},oD}var uD,SQ;function Lh(){if(SQ)return uD;SQ=1;var t=AE();return uD=t==="NODE",uD}var CQ;function _3e(){if(CQ)return TQ;CQ=1;var t=wt(),e=O3e().left,n=P4(),a=np(),o=Lh(),s=!o&&a>79&&a<83,l=s||!n("reduce");return t({target:"Array",proto:!0,forced:l},{reduce:function(f){var g=arguments.length;return e(this,f,g,g>1?arguments[1]:void 0)}}),TQ}_3e();var AQ={},sD,OQ;function x3e(){if(OQ)return sD;OQ=1;var t=b4(),e=TypeError;return sD=function(n,a){if(!delete n[a])throw new e("Cannot delete property "+t(a)+" of "+t(n))},sD}var _Q;function w3e(){if(_Q)return AQ;_Q=1;var t=wt(),e=Su(),n=E1(),a=MU(),o=x3e(),s=V5(),l=[].unshift(0)!==1,d=function(){try{Object.defineProperty([],"length",{writable:!1}).unshift()}catch(g){return g instanceof TypeError}},f=l||!d();return t({target:"Array",proto:!0,arity:1,forced:f},{unshift:function(M){var I=e(this),y=n(I),h=arguments.length;if(h){s(y+h);for(var m=y;m--;){var N=m+h;m in I?I[N]=I[m]:o(I,N)}for(var E=0;E<h;E++)I[E]=arguments[E]}return a(I,y+h)}}),AQ}w3e();var xQ={},wQ;function b3e(){if(wQ)return xQ;wQ=1;var t=wt(),e=dr(),n=Su(),a=oN(),o=e(function(){return new Date(NaN).toJSON()!==null||Date.prototype.toJSON.call({toISOString:function(){return 1}})!==1});return t({target:"Date",proto:!0,arity:1,forced:o},{toJSON:function(l){var d=n(this),f=a(d,"number");return typeof f=="number"&&!isFinite(f)?null:d.toISOString()}}),xQ}b3e(),NP();var bQ={},LQ;function L3e(){if(LQ)return bQ;LQ=1;var t=Lr(),e=vl();return e(t.JSON,"JSON",!0),bQ}L3e();var kQ={},RQ;function k3e(){if(RQ)return kQ;RQ=1;var t=vl();return t(Math,"Math",!0),kQ}k3e();var zQ={},PQ={},lD,UQ;function YQ(){if(UQ)return lD;UQ=1;var t=_n(),e=gY(),n=kM(),a=Zn(),o=a("species");return lD=function(s,l){var d=t(s).constructor,f;return d===void 0||n(f=t(d)[o])?l:e(f)},lD}var cD,$Q;function QQ(){if($Q)return cD;$Q=1;var t=x4();return cD=/(?:ipad|iphone|ipod).*applewebkit/i.test(t),cD}var fD,FQ;function HQ(){if(FQ)return fD;FQ=1;var t=Lr(),e=ed(),n=J1(),a=qn(),o=mi(),s=dr(),l=Fz(),d=q1(),f=mh(),g=U4(),M=QQ(),I=Lh(),y=t.setImmediate,h=t.clearImmediate,m=t.process,N=t.Dispatch,E=t.Function,A=t.MessageChannel,T=t.String,j=0,C={},_="onreadystatechange",L,U,H,Q;s(function(){L=t.location});var x=function(Y){if(o(C,Y)){var V=C[Y];delete C[Y],V()}},O=function(Y){return function(){x(Y)}},w=function(Y){x(Y.data)},R=function(Y){t.postMessage(T(Y),L.protocol+"//"+L.host)};return(!y||!h)&&(y=function(V){g(arguments.length,1);var q=a(V)?V:E(V),te=d(arguments,1);return C[++j]=function(){e(q,void 0,te)},U(j),j},h=function(V){delete C[V]},I?U=function(Y){m.nextTick(O(Y))}:N&&N.now?U=function(Y){N.now(O(Y))}:A&&!M?(H=new A,Q=H.port2,H.port1.onmessage=w,U=n(Q.postMessage,Q)):t.addEventListener&&a(t.postMessage)&&!t.importScripts&&L&&L.protocol!=="file:"&&!s(R)?(U=R,t.addEventListener("message",w,!1)):_ in f("script")?U=function(Y){l.appendChild(f("script"))[_]=function(){l.removeChild(this),x(Y)}}:U=function(Y){setTimeout(O(Y),0)}),fD={set:y,clear:h},fD}var dD,VQ;function BQ(){if(VQ)return dD;VQ=1;var t=Lr(),e=tn(),n=Object.getOwnPropertyDescriptor;return dD=function(a){if(!e)return t[a];var o=n(t,a);return o&&o.value},dD}var gD,GQ;function ZQ(){if(GQ)return gD;GQ=1;var t=function(){this.head=null,this.tail=null};return t.prototype={add:function(e){var n={item:e,next:null},a=this.tail;a?a.next=n:this.head=n,this.tail=n},get:function(){var e=this.head;if(e){var n=this.head=e.next;return n===null&&(this.tail=null),e.item}}},gD=t,gD}var MD,WQ;function R3e(){if(WQ)return MD;WQ=1;var t=x4();return MD=/ipad|iphone|ipod/i.test(t)&&typeof Pebble!="undefined",MD}var pD,KQ;function z3e(){if(KQ)return pD;KQ=1;var t=x4();return pD=/web0s(?!.*chrome)/i.test(t),pD}var ID,qQ;function P3e(){if(qQ)return ID;qQ=1;var t=Lr(),e=BQ(),n=J1(),a=HQ().set,o=ZQ(),s=QQ(),l=R3e(),d=z3e(),f=Lh(),g=t.MutationObserver||t.WebKitMutationObserver,M=t.document,I=t.process,y=t.Promise,h=e("queueMicrotask"),m,N,E,A,T;if(!h){var j=new o,C=function(){var _,L;for(f&&(_=I.domain)&&_.exit();L=j.get();)try{L()}catch(U){throw j.head&&m(),U}_&&_.enter()};!s&&!f&&!d&&g&&M?(N=!0,E=M.createTextNode(""),new g(C).observe(E,{characterData:!0}),m=function(){E.data=N=!N}):!l&&y&&y.resolve?(A=y.resolve(void 0),A.constructor=y,T=n(A.then,A),m=function(){T(C)}):f?m=function(){I.nextTick(C)}:(a=n(a,t),m=function(){a(C)}),h=function(_){j.head||m(),j.add(_)}}return ID=h,ID}var yD,JQ;function U3e(){return JQ||(JQ=1,yD=function(t,e){try{arguments.length===1?console.error(t):console.error(t,e)}catch(n){}}),yD}var hD,XQ;function vD(){return XQ||(XQ=1,hD=function(t){try{return{error:!1,value:t()}}catch(e){return{error:!0,value:e}}}),hD}var mD,eF;function Tp(){if(eF)return mD;eF=1;var t=Lr();return mD=t.Promise,mD}var ND,tF;function jp(){if(tF)return ND;tF=1;var t=Lr(),e=Tp(),n=qn(),a=up(),o=hN(),s=Zn(),l=AE(),d=yu(),f=np(),g=e&&e.prototype,M=s("species"),I=!1,y=n(t.PromiseRejectionEvent),h=a("Promise",function(){var m=o(e),N=m!==String(e);if(!N&&f===66||d&&!(g.catch&&g.finally))return!0;if(!f||f<51||!/native code/.test(m)){var E=new e(function(j){j(1)}),A=function(j){j(function(){},function(){})},T=E.constructor={};if(T[M]=A,I=E.then(function(){})instanceof A,!I)return!0}return!N&&(l==="BROWSER"||l==="DENO")&&!y});return ND={CONSTRUCTOR:h,REJECTION_EVENT:y,SUBCLASSING:I},ND}var ED={},rF;function Sp(){if(rF)return ED;rF=1;var t=yo(),e=TypeError,n=function(a){var o,s;this.promise=new a(function(l,d){if(o!==void 0||s!==void 0)throw new e("Bad Promise constructor");o=l,s=d}),this.resolve=t(o),this.reject=t(s)};return ED.f=function(a){return new n(a)},ED}var nF;function Y3e(){if(nF)return PQ;nF=1;var t=wt(),e=yu(),n=Lh(),a=Lr(),o=yn(),s=Ra(),l=fp(),d=vl(),f=dE(),g=yo(),M=qn(),I=Jn(),y=PM(),h=YQ(),m=HQ().set,N=P3e(),E=U3e(),A=vD(),T=ZQ(),j=Au(),C=Tp(),_=jp(),L=Sp(),U="Promise",H=_.CONSTRUCTOR,Q=_.REJECTION_EVENT,x=_.SUBCLASSING,O=j.getterFor(U),w=j.set,R=C&&C.prototype,Y=C,V=R,q=a.TypeError,te=a.document,z=a.process,G=L.f,K=G,k=!!(te&&te.createEvent&&a.dispatchEvent),W="unhandledrejection",pe="rejectionhandled",Me=0,le=1,Oe=2,Pe=1,me=2,Le,Ze,Xe,tt,ct=function(fe){var xe;return I(fe)&&M(xe=fe.then)?xe:!1},Dt=function(fe,xe){var ve=xe.value,ge=xe.state===le,de=ge?fe.ok:fe.fail,we=fe.resolve,et=fe.reject,rt=fe.domain,Ye,Te,_e;try{de?(ge||(xe.rejection===me&&pt(xe),xe.rejection=Pe),de===!0?Ye=ve:(rt&&rt.enter(),Ye=de(ve),rt&&(rt.exit(),_e=!0)),Ye===fe.promise?et(new q("Promise-chain cycle")):(Te=ct(Ye))?o(Te,Ye,we,et):we(Ye)):et(ve)}catch(Be){rt&&!_e&&rt.exit(),et(Be)}},Et=function(fe,xe){fe.notified||(fe.notified=!0,N(function(){for(var ve=fe.reactions,ge;ge=ve.get();)Dt(ge,fe);fe.notified=!1,xe&&!fe.rejection&&Je(fe)}))},vt=function(fe,xe,ve){var ge,de;k?(ge=te.createEvent("Event"),ge.promise=xe,ge.reason=ve,ge.initEvent(fe,!1,!0),a.dispatchEvent(ge)):ge={promise:xe,reason:ve},!Q&&(de=a["on"+fe])?de(ge):fe===W&&E("Unhandled promise rejection",ve)},Je=function(fe){o(m,a,function(){var xe=fe.facade,ve=fe.value,ge=dt(fe),de;if(ge&&(de=A(function(){n?z.emit("unhandledRejection",ve,xe):vt(W,xe,ve)}),fe.rejection=n||dt(fe)?me:Pe,de.error))throw de.value})},dt=function(fe){return fe.rejection!==Pe&&!fe.parent},pt=function(fe){o(m,a,function(){var xe=fe.facade;n?z.emit("rejectionHandled",xe):vt(pe,xe,fe.value)})},Ke=function(fe,xe,ve){return function(ge){fe(xe,ge,ve)}},Ce=function(fe,xe,ve){fe.done||(fe.done=!0,ve&&(fe=ve),fe.value=xe,fe.state=Oe,Et(fe,!0))},Ue=function(fe,xe,ve){if(!fe.done){fe.done=!0,ve&&(fe=ve);try{if(fe.facade===xe)throw new q("Promise can't be resolved itself");var ge=ct(xe);ge?N(function(){var de={done:!1};try{o(ge,xe,Ke(Ue,de,fe),Ke(Ce,de,fe))}catch(we){Ce(de,we,fe)}}):(fe.value=xe,fe.state=le,Et(fe,!1))}catch(de){Ce({done:!1},de,fe)}}};if(H&&(Y=function(xe){y(this,V),g(xe),o(Le,this);var ve=O(this);try{xe(Ke(Ue,ve),Ke(Ce,ve))}catch(ge){Ce(ve,ge)}},V=Y.prototype,Le=function(xe){w(this,{type:U,done:!1,notified:!1,parent:!1,reactions:new T,rejection:!1,state:Me,value:null})},Le.prototype=s(V,"then",function(xe,ve){var ge=O(this),de=G(h(this,Y));return ge.parent=!0,de.ok=M(xe)?xe:!0,de.fail=M(ve)&&ve,de.domain=n?z.domain:void 0,ge.state===Me?ge.reactions.add(de):N(function(){Dt(de,ge)}),de.promise}),Ze=function(){var fe=new Le,xe=O(fe);this.promise=fe,this.resolve=Ke(Ue,xe),this.reject=Ke(Ce,xe)},L.f=G=function(fe){return fe===Y||fe===Xe?new Ze(fe):K(fe)},!e&&M(C)&&R!==Object.prototype)){tt=R.then,x||s(R,"then",function(xe,ve){var ge=this;return new Y(function(de,we){o(tt,ge,de,we)}).then(xe,ve)},{unsafe:!0});try{delete R.constructor}catch(fe){}l&&l(R,V)}return t({global:!0,constructor:!0,wrap:!0,forced:H},{Promise:Y}),d(Y,U,!1,!0),f(U),PQ}var iF={},DD,aF;function oF(){if(aF)return DD;aF=1;var t=Tp(),e=uE(),n=jp().CONSTRUCTOR;return DD=n||!e(function(a){t.all(a).then(void 0,function(){})}),DD}var uF;function $3e(){if(uF)return iF;uF=1;var t=wt(),e=yn(),n=yo(),a=Sp(),o=vD(),s=$f(),l=oF();return t({target:"Promise",stat:!0,forced:l},{all:function(f){var g=this,M=a.f(g),I=M.resolve,y=M.reject,h=o(function(){var m=n(g.resolve),N=[],E=0,A=1;s(f,function(T){var j=E++,C=!1;A++,e(m,g,T).then(function(_){C||(C=!0,N[j]=_,--A||I(N))},y)}),--A||I(N)});return h.error&&y(h.value),M.promise}}),iF}var sF={},lF;function Q3e(){if(lF)return sF;lF=1;var t=wt(),e=yu(),n=jp().CONSTRUCTOR,a=Tp(),o=ju(),s=qn(),l=Ra(),d=a&&a.prototype;if(t({target:"Promise",proto:!0,forced:n,real:!0},{catch:function(g){return this.then(void 0,g)}}),!e&&s(a)){var f=o("Promise").prototype.catch;d.catch!==f&&l(d,"catch",f,{unsafe:!0})}return sF}var cF={},fF;function F3e(){if(fF)return cF;fF=1;var t=wt(),e=yn(),n=yo(),a=Sp(),o=vD(),s=$f(),l=oF();return t({target:"Promise",stat:!0,forced:l},{race:function(f){var g=this,M=a.f(g),I=M.reject,y=o(function(){var h=n(g.resolve);s(f,function(m){e(h,g,m).then(M.resolve,I)})});return y.error&&I(y.value),M.promise}}),cF}var dF={},gF;function H3e(){if(gF)return dF;gF=1;var t=wt(),e=Sp(),n=jp().CONSTRUCTOR;return t({target:"Promise",stat:!0,forced:n},{reject:function(o){var s=e.f(this),l=s.reject;return l(o),s.promise}}),dF}var MF={},TD,pF;function V3e(){if(pF)return TD;pF=1;var t=_n(),e=Jn(),n=Sp();return TD=function(a,o){if(t(a),e(o)&&o.constructor===a)return o;var s=n.f(a),l=s.resolve;return l(o),s.promise},TD}var IF;function B3e(){if(IF)return MF;IF=1;var t=wt(),e=ju(),n=yu(),a=Tp(),o=jp().CONSTRUCTOR,s=V3e(),l=e("Promise"),d=n&&!o;return t({target:"Promise",stat:!0,forced:n||o},{resolve:function(g){return s(d&&this===l?a:this,g)}}),MF}var yF;function G3e(){return yF||(yF=1,Y3e(),$3e(),Q3e(),F3e(),H3e(),B3e()),zQ}G3e();var hF={},vF={},mF;function Z3e(){if(mF)return vF;mF=1;var t=lE(),e=HU();return t("Set",function(n){return function(){return n(this,arguments.length?arguments[0]:void 0)}},e),vF}var NF;function W3e(){return NF||(NF=1,Z3e()),hF}W3e();var EF={},jD,DF;function Hf(){if(DF)return jD;DF=1;var t=Mr(),e=Set.prototype;return jD={Set,add:t(e.add),has:t(e.has),remove:t(e.delete),proto:e},jD}var SD,TF;function QM(){if(TF)return SD;TF=1;var t=Hf().has;return SD=function(e){return t(e),e},SD}var CD,jF;function FM(){if(jF)return CD;jF=1;var t=yn();return CD=function(e,n,a){for(var o=a?e:e.iterator,s=e.next,l,d;!(l=t(s,o)).done;)if(d=n(l.value),d!==void 0)return d},CD}var AD,SF;function Cp(){if(SF)return AD;SF=1;var t=Mr(),e=FM(),n=Hf(),a=n.Set,o=n.proto,s=t(o.forEach),l=t(o.keys),d=l(new a).next;return AD=function(f,g,M){return M?e({iterator:l(f),next:d},g):s(f,g)},AD}var OD,CF;function _D(){if(CF)return OD;CF=1;var t=Hf(),e=Cp(),n=t.Set,a=t.add;return OD=function(o){var s=new n;return e(o,function(l){a(s,l)}),s},OD}var xD,AF;function Ap(){if(AF)return xD;AF=1;var t=bP(),e=Hf();return xD=t(e.proto,"size","get")||function(n){return n.size},xD}var wD,OF;function HM(){if(OF)return wD;OF=1;var t=yo(),e=_n(),n=yn(),a=zM(),o=rd(),s="Invalid size",l=RangeError,d=TypeError,f=Math.max,g=function(M,I){this.set=M,this.size=f(I,0),this.has=t(M.has),this.keys=t(M.keys)};return g.prototype={getIterator:function(){return o(e(n(this.keys,this.set)))},includes:function(M){return n(this.has,this.set,M)}},wD=function(M){e(M);var I=+M.size;if(I!==I)throw new d(s);var y=a(I);if(y<0)throw new l(s);return new g(M,y)},wD}var bD,_F;function K3e(){if(_F)return bD;_F=1;var t=QM(),e=Hf(),n=_D(),a=Ap(),o=HM(),s=Cp(),l=FM(),d=e.has,f=e.remove;return bD=function(M){var I=t(this),y=o(M),h=n(I);return a(I)<=y.size?s(I,function(m){y.includes(m)&&f(h,m)}):l(y.getIterator(),function(m){d(I,m)&&f(h,m)}),h},bD}var LD,xF;function VM(){if(xF)return LD;xF=1;var t=ju(),e=function(a){return{size:a,has:function(){return!1},keys:function(){return{next:function(){return{done:!0}}}}}},n=function(a){return{size:a,has:function(){return!0},keys:function(){throw new Error("e")}}};return LD=function(a,o){var s=t("Set");try{new s()[a](e(0));try{return new s()[a](e(-1)),!1}catch(d){if(!o)return!0;try{return new s()[a](n(-1/0)),!1}catch(f){var l=new s;return l.add(1),l.add(2),o(l[a](n(1/0)))}}}catch(d){return!1}},LD}var wF;function q3e(){if(wF)return EF;wF=1;var t=wt(),e=K3e(),n=VM(),a=!n("difference",function(o){return o.size===0});return t({target:"Set",proto:!0,real:!0,forced:a},{difference:e}),EF}q3e();var bF={},kD,LF;function J3e(){if(LF)return kD;LF=1;var t=QM(),e=Hf(),n=Ap(),a=HM(),o=Cp(),s=FM(),l=e.Set,d=e.add,f=e.has;return kD=function(M){var I=t(this),y=a(M),h=new l;return n(I)>y.size?s(y.getIterator(),function(m){f(I,m)&&d(h,m)}):o(I,function(m){y.includes(m)&&d(h,m)}),h},kD}var kF;function X3e(){if(kF)return bF;kF=1;var t=wt(),e=dr(),n=J3e(),a=VM(),o=!a("intersection",function(s){return s.size===2&&s.has(1)&&s.has(2)})||e(function(){return String(Array.from(new Set([1,2,3]).intersection(new Set([3,2]))))!=="3,2"});return t({target:"Set",proto:!0,real:!0,forced:o},{intersection:n}),bF}X3e();var RF={},RD,zF;function eme(){if(zF)return RD;zF=1;var t=QM(),e=Hf().has,n=Ap(),a=HM(),o=Cp(),s=FM(),l=ml();return RD=function(f){var g=t(this),M=a(f);if(n(g)<=M.size)return o(g,function(y){if(M.includes(y))return!1},!0)!==!1;var I=M.getIterator();return s(I,function(y){if(e(g,y))return l(I,"normal",!1)})!==!1},RD}var PF;function tme(){if(PF)return RF;PF=1;var t=wt(),e=eme(),n=VM(),a=!n("isDisjointFrom",function(o){return!o});return t({target:"Set",proto:!0,real:!0,forced:a},{isDisjointFrom:e}),RF}tme();var UF={},zD,YF;function rme(){if(YF)return zD;YF=1;var t=QM(),e=Ap(),n=Cp(),a=HM();return zD=function(s){var l=t(this),d=a(s);return e(l)>d.size?!1:n(l,function(f){if(!d.includes(f))return!1},!0)!==!1},zD}var $F;function nme(){if($F)return UF;$F=1;var t=wt(),e=rme(),n=VM(),a=!n("isSubsetOf",function(o){return o});return t({target:"Set",proto:!0,real:!0,forced:a},{isSubsetOf:e}),UF}nme();var QF={},PD,FF;function ime(){if(FF)return PD;FF=1;var t=QM(),e=Hf().has,n=Ap(),a=HM(),o=FM(),s=ml();return PD=function(d){var f=t(this),g=a(d);if(n(f)<g.size)return!1;var M=g.getIterator();return o(M,function(I){if(!e(f,I))return s(M,"normal",!1)})!==!1},PD}var HF;function ame(){if(HF)return QF;HF=1;var t=wt(),e=ime(),n=VM(),a=!n("isSupersetOf",function(o){return!o});return t({target:"Set",proto:!0,real:!0,forced:a},{isSupersetOf:e}),QF}ame();var VF={},UD,BF;function ome(){if(BF)return UD;BF=1;var t=QM(),e=Hf(),n=_D(),a=HM(),o=FM(),s=e.add,l=e.has,d=e.remove;return UD=function(g){var M=t(this),I=a(g).getIterator(),y=n(M);return o(I,function(h){l(M,h)?d(y,h):s(y,h)}),y},UD}var GF;function ume(){if(GF)return VF;GF=1;var t=wt(),e=ome(),n=VM();return t({target:"Set",proto:!0,real:!0,forced:!n("symmetricDifference")},{symmetricDifference:e}),VF}ume();var ZF={},YD,WF;function sme(){if(WF)return YD;WF=1;var t=QM(),e=Hf().add,n=_D(),a=HM(),o=FM();return YD=function(l){var d=t(this),f=a(l).getIterator(),g=n(d);return o(f,function(M){e(g,M)}),g},YD}var KF;function lme(){if(KF)return ZF;KF=1;var t=wt(),e=sme(),n=VM();return t({target:"Set",proto:!0,real:!0,forced:!n("union")},{union:e}),ZF}lme();var qF={},JF={},XF;function cme(){if(XF)return JF;XF=1;var t=wt(),e=yn(),n=yo(),a=_n(),o=rd(),s=rQ(),l=YE(),d=ml(),f=$M(),g=yu(),M=!g&&f("map",TypeError),I=s(function(){var y=this.iterator,h=a(e(this.next,y)),m=this.done=!!h.done;if(!m)return l(y,this.mapper,[h.value,this.counter++],!0)});return t({target:"Iterator",proto:!0,real:!0,forced:g||M},{map:function(h){a(this);try{n(h)}catch(m){d(this,"throw",m)}return M?e(M,this,h):new I(o(this),{mapper:h})}}),JF}var eH;function fme(){return eH||(eH=1,cme()),qF}fme();var tH={},rH={},nH;function dme(){if(nH)return rH;nH=1;var t=wt(),e=$f(),n=yo(),a=_n(),o=rd(),s=ml(),l=$M(),d=ed(),f=dr(),g=TypeError,M=f(function(){[].keys().reduce(function(){},void 0)}),I=!M&&l("reduce",g);return t({target:"Iterator",proto:!0,real:!0,forced:M||I},{reduce:function(h){a(this);try{n(h)}catch(T){s(this,"throw",T)}var m=arguments.length<2,N=m?void 0:arguments[1];if(I)return d(I,this,m?[h]:[h,N]);var E=o(this),A=0;if(e(E,function(T){m?(m=!1,N=T):N=h(N,T,A),A++},{IS_RECORD:!0}),m)throw new g("Reduce of empty iterator with no initial value");return N}}),rH}var iH;function gme(){return iH||(iH=1,dme()),tH}gme();function kh(t){"@babel/helpers - typeof";return kh=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},kh(t)}var Mme=function(e,n){return $D(e,n)},$D=function(e,n){var a=QD(e,n);for(var o in a)if(Object.prototype.hasOwnProperty.call(a,o)){var s=a[o];if(kh(s)==="object"&&!Array.isArray(s))a[o]=QD(s,n);else if(Array.isArray(s)){var l=s.map(function(d){return kh(d)==="object"?$D(d,n):d});a[o]=l}}return a},QD=function(e,n){var a=pme(e),o=e.layout;if(!o||o.length===0)return a;var s=null;if(o.forEach(function(g){var M=n[g];s?M&&Ime(M,s):s=M}),s){var l=QD(s,n);for(var d in l)if(Object.prototype.hasOwnProperty.call(l,d)){var f=l[d];Object.prototype.hasOwnProperty.call(a,d)||(a[d]=f)}}return $D(a,n)},pme=function(e){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&a.toLowerCase()!=="layout"&&(n[a]=e[a]);return n},Ime=function(e,n){for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(n[a]=e[a])};function Op(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */Op=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&_p(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(_p(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function _p(t){"@babel/helpers - typeof";return _p=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_p(t)}function yme(t,e){return mme(t)||vme(t,e)||oH(t,e)||hme()}function hme(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
46
46
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vme(t,e){var n=t==null?null:typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a,o,s,l,d=[],f=!0,g=!1;try{if(s=(n=n.call(t)).next,e!==0)for(;!(f=(a=s.call(n)).done)&&(d.push(a.value),d.length!==e);f=!0);}catch(M){g=!0,o=M}finally{try{if(!f&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(g)throw o}}return d}}function mme(t){if(Array.isArray(t))return t}function aH(t){return Dme(t)||Eme(t)||oH(t)||Nme()}function Nme(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
47
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function oH(t,e){if(t){if(typeof t=="string")return FD(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?FD(t,e):void 0}}function Eme(t){if(typeof Symbol!="undefined"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function Dme(t){if(Array.isArray(t))return FD(t)}function FD(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}function uH(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function sH(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){uH(s,a,o,l,d,"next",f)}function d(f){uH(s,a,o,l,d,"throw",f)}l(void 0)})}}function HD(t){try{return JSON.parse(JSON.stringify(t))}catch(e){return console.warn("Failed to copy object:",e),null}}var lH=function(e,n){if(!e||!n)return null;var a=null;return a=HD(e),a&&(a=Mme(a,n)),a};function Tme(t){return VD.apply(this,arguments)}function VD(){return VD=sH(Op().mark(function t(e){return Op().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.abrupt("return",new Promise(function(o){return setTimeout(o,e)}));case 1:case"end":return a.stop()}},t)})),VD.apply(this,arguments)}function BD(t,e){return GD.apply(this,arguments)}function GD(){return GD=sH(Op().mark(function t(e,n){var a,o,s,l,d=arguments;return Op().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:a=d.length>2&&d[2]!==void 0?d[2]:wve,o=d.length>3&&d[3]!==void 0?d[3]:bve,s=0;case 3:if(!(s<a)){g.next=15;break}return g.next=6,e();case 6:if(l=g.sent,l===null){g.next=9;break}return g.abrupt("return",l);case 9:if(s++,!(s<a)){g.next=13;break}return g.next=13,Tme(o);case 13:g.next=3;break;case 15:return g.abrupt("return",n());case 16:case"end":return g.stop()}},t)})),GD.apply(this,arguments)}var jme=function(e,n,a){var o=e.reduce(function(l,d){return l.push.apply(l,aH(d.supportedTemplates)),l},[]),s=n.find(function(l){return l.id===a});return o.includes(s==null?void 0:s.client.templateId)},Sme=function(e,n){if(!e||!n)return!1;var a=e.find(function(s){return s.id===n}),o=(a==null?void 0:a.type)==="DATA"||(a==null?void 0:a.type)==="QUESTIONARY";return o},Cme=function(e,n){var a=e.reduce(function(d,f){return d.push.apply(d,aH(f.supportedTemplates)),d},[]),o=Array.from(new Set(n.filter(function(d){return d.type==="DATA"&&!d.final}).map(function(d){return d.client.templateId})));function s(d,f){var g=new Set(d);return f.filter(function(M){return!g.has(M)})}var l=s(a,o);return{isAllTemplatesSupported:l.length===0,unsupportedSteps:l.length>0?l:void 0}},Ame=function(e,n){return e+":"+n},ZD={setSessionIdWorkflowIdToLs:function(e,n){var a=Ame(e,n);localStorage.setItem(PE,a)},getSessionIdWorkflowIdFromLS:function(){var e=localStorage.getItem(PE);if(e){var n=e.split(":"),a=yme(n,2),o=a[0],s=a[1];if(o&&s)return{sessionId:o,workflowId:s}}return null},removeSessionIdWorkflowIdFromLS:function(){localStorage.removeItem(PE)}},Ome=function(e){var n;try{var a;n=(a=window.localStorage.getItem(e))!==null&&a!==void 0?a:window.crypto.randomUUID(),window.localStorage.setItem(e,n)}catch(o){n=window.crypto.randomUUID()}return n};function _me(t){return Object.prototype.toString.call(t)==="[object Object]"&&Object.keys(t).length>0}function xme(t){return _p(t)==="object"&&t!==null&&!Array.isArray(t)&&Object.getPrototypeOf(t)===Object.prototype}function wme(){return typeof document=="undefined"?null:document.documentElement.getAttribute("lang")||null}function bme(){return typeof navigator!="undefined"?navigator.language:null}var Lme=function(e){var n=kve,a=typeof e=="string"?e:null,o=wme(),s=bme();return a||o||s||n};function xp(t){"@babel/helpers - typeof";return xp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},xp(t)}function cH(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function WD(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?cH(Object(n),!0).forEach(function(a){kme(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):cH(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function kme(t,e,n){return(e=Rme(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Rme(t){var e=zme(t,"string");return xp(e)=="symbol"?e:e+""}function zme(t,e){if(xp(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(xp(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var fH={sessionProperties:[],currentSessionData:null,sessionRestoreMode:!1,processingTransformedTemplate:null,nonce:void 0,currentStepId:null,layout:null,currentScreenConfig:null,workflowId:null,modulesConfig:{},workflow:null,externalModulesNames:[],externalModules:[],serviceToken:void 0,listener:function(){}},Pme=function(e,n){return WD(WD({},fH),{},{setSessionProperties:function(o){e({sessionProperties:o})},setServiceSessionToken:function(o){e({serviceToken:o})},setListener:function(o){e({listener:o})},getCurrentSessionDataLs:function(){var o=ZD.getSessionIdWorkflowIdFromLS();return o!=null&&o.sessionId?o:null},setCurrentSessionDataLsAndStore:function(o){if(o===null)return ZD.removeSessionIdWorkflowIdFromLS(),e(function(){return{currentSessionData:null}});ZD.setSessionIdWorkflowIdToLs(o.sessionId,o.workflowId),e(function(){return{currentSessionData:o}})},getCurrentSessionId:function(){var o=n().currentSessionData;return o?o.sessionId:null},setWorkflowId:function(o){e(function(){return{workflowId:o}})},setWorkflow:function(o){e(function(){return{workflow:o}})},setLayout:function(o){e(function(){return{layout:o}})},setCurrentStepId:function(o){e(function(){return{currentStepId:o}})},setSessionRestoreMode:function(o){e(function(){return{sessionRestoreMode:o}})},setNonce:function(o){e(function(){return{nonce:o}})},getNonce:function(){return n().nonce},resetProps:function(){return e(function(){return WD({},fH)})}})},dH={},gH;function Ume(){if(gH)return dH;gH=1;var t=wt(),e=Mr(),n=rp(),a=hl(),o=P4(),s=e([].join),l=n!==Object,d=l||!o("join",",");return t({target:"Array",proto:!0,forced:d},{join:function(g){return s(a(this),g===void 0?",":g)}}),dH}Ume();var MH={},pH;function Yme(){if(pH)return MH;pH=1;var t=wt(),e=X1().some,n=P4(),a=n("some");return t({target:"Array",proto:!0,forced:!a},{some:function(s){return e(this,s,arguments.length>1?arguments[1]:void 0)}}),MH}Yme();var IH={},yH={},hH;function $me(){if(hH)return yH;hH=1;var t=wt(),e=yn(),n=$f(),a=yo(),o=_n(),s=rd(),l=ml(),d=$M(),f=d("some",TypeError);return t({target:"Iterator",proto:!0,real:!0,forced:f},{some:function(M){o(this);try{a(M)}catch(h){l(this,"throw",h)}if(f)return e(f,this,M);var I=s(this),y=0;return n(I,function(h,m){if(M(h,y++))return m()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}}),yH}var vH;function Qme(){return vH||(vH=1,$me()),IH}Qme();var mH={},NH;function Fme(){if(NH)return mH;NH=1;var t=wt(),e=dr(),n=z4(),a=Jn(),o=Su(),s=E1(),l=V5(),d=Ep(),f=sP(),g=xh(),M=Zn(),I=np(),y=M("isConcatSpreadable"),h=I>=51||!e(function(){var E=[];return E[y]=!1,E.concat()[0]!==E}),m=function(E){if(!a(E))return!1;var A=E[y];return A!==void 0?!!A:n(E)},N=!h||!g("concat");return t({target:"Array",proto:!0,arity:1,forced:N},{concat:function(A){var T=o(this),j=f(T,0),C=0,_,L,U,H,Q;for(_=-1,U=arguments.length;_<U;_++)if(Q=_===-1?T:arguments[_],m(Q))for(H=s(Q),l(C+H),L=0;L<H;L++,C++)L in Q&&d(j,C,Q[L]);else l(C+1),d(j,C++,Q);return j.length=C,j}}),mH}Fme();function wp(t){"@babel/helpers - typeof";return wp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wp(t)}function Hme(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function EH(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,DH(a.key),a)}}function Vme(t,e,n){return e&&EH(t.prototype,e),n&&EH(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function D1(t,e,n){return(e=DH(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function DH(t){var e=Bme(t,"string");return wp(e)=="symbol"?e:e+""}function Bme(t,e){if(wp(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(wp(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var ri=function(){function t(e){var n=e.errorCode,a=e.errorCodeKey,o=e.message,s=e.underlyingError,l=e.underlyingBaseError,d=e.domain,f=e.module,g=e.errorEnumName,M=e.shortDomainCode;Hme(this,t),D1(this,"errorCode",void 0),D1(this,"errorCodeKey",void 0),D1(this,"message",void 0),D1(this,"underlyingError",void 0),D1(this,"underlyingBaseError",void 0),D1(this,"domain",void 0),D1(this,"module",void 0),D1(this,"errorEnumName",void 0),D1(this,"shortDomainCode",void 0),this.errorCode=n,this.errorCodeKey=a,this.message=o,this.underlyingError=s,this.underlyingBaseError=l,this.module=f,this.domain=d,this.errorEnumName=g,this.shortDomainCode=M}return Vme(t,[{key:"lastUnderlyingError",get:function(){for(var n,a=this.underlyingBaseError;((o=a)===null||o===void 0?void 0:o.underlyingBaseError)instanceof t;){var o;a=a.underlyingBaseError}return(n=a)===null||n===void 0?void 0:n.underlyingError}},{key:"toObject",value:function(){var n={errorCode:this.errorCode,errorCodeKey:this.errorCodeKey,errorEnumName:this.errorEnumName,message:this.message,module:this.module,underlyingError:this.underlyingError,lastUnderlineError:this.lastUnderlyingError};return this.underlyingBaseError&&this.underlyingBaseError instanceof t&&(n.underlyingBaseError=this.underlyingBaseError.toObject()),n}},{key:"shortChain",get:function(){var n="".concat(this.shortDomainCode,":").concat(this.errorCode).concat(this.underlyingError?"-"+this.underlyingError:"");return this.underlyingBaseError instanceof t&&(n+="-".concat(this.underlyingBaseError.shortChain)),n}},{key:"fullChain",get:function(){var n="".concat(this.module,".").concat(this.domain,":").concat(this.errorCodeKey).concat(this.underlyingError?"-"+this.underlyingError:"");return this.underlyingBaseError instanceof t&&(n+="-".concat(this.underlyingBaseError.fullChain)),n}}],[{key:"getErrorKey",value:function(n,a){var o=Object.keys(a).find(function(s){return a[s]===n});if(!o)throw new Error("Invalid errorCode: ".concat(n," in enum"));return o}}])}();function $4(t){"@babel/helpers - typeof";return $4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$4(t)}function Vf(t,e,n){return Object.defineProperty(t,"prototype",{writable:!1}),t}function Bf(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Gf(t,e,n){return e=Rh(e),Gme(t,TH()?Reflect.construct(e,n||[],Rh(t).constructor):e.apply(t,n))}function Gme(t,e){if(e&&($4(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Zme(t)}function Zme(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function TH(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(TH=function(){return!!t})()}function Rh(t){return Rh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Rh(t)}function Zf(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&KD(t,e)}function KD(t,e){return KD=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},KD(t,e)}function Xn(t,e,n){return(e=Wme(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Wme(t){var e=Kme(t,"string");return $4(e)=="symbol"?e:e+""}function Kme(t,e){if($4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if($4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var bp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,mp);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(bp,"MODULE",Ff),Xn(bp,"ERROR_ENUM_NAME","InitializeError"),Xn(bp,"SHORT_CODE","IN");var zh=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,RE);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(zh,"MODULE",Ff),Xn(zh,"ERROR_ENUM_NAME","TokenInitializeError"),Xn(zh,"SHORT_CODE","TI");var Wf=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Qf);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(Wf,"MODULE",Ff),Xn(Wf,"ERROR_ENUM_NAME","PrepareWorkflowError"),Xn(Wf,"SHORT_CODE","PW");var T1=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,td);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(T1,"MODULE",Ff),Xn(T1,"ERROR_ENUM_NAME","ConfigureError"),Xn(T1,"SHORT_CODE","CO");var vu=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,hu);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(vu,"MODULE",Ff),Xn(vu,"ERROR_ENUM_NAME","ScenarioError"),Xn(vu,"SHORT_CODE","SC");var Lp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,YM);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(Lp,"MODULE",Ff),Xn(Lp,"ERROR_ENUM_NAME","ScenarioError"),Xn(Lp,"SHORT_CODE","CO");var kp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Nl);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(kp,"MODULE",Ff),Xn(kp,"ERROR_ENUM_NAME","SessionError"),Xn(kp,"SHORT_CODE","SE");var BM=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,UM);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(BM,"MODULE",Ff),Xn(BM,"ERROR_ENUM_NAME","StartSessionError"),Xn(BM,"SHORT_CODE","ST");var Rp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Np);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(Rp,"MODULE",Ff),Xn(Rp,"ERROR_ENUM_NAME","DeinitializationError"),Xn(Rp,"SHORT_CODE","DE");var zp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Bl);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(zp,"MODULE",Ff),Xn(zp,"ERROR_ENUM_NAME","WorkflowError"),Xn(zp,"SHORT_CODE","WR");function GM(t){"@babel/helpers - typeof";return GM=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},GM(t)}function ho(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ho=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&GM(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(GM(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function jH(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function Pp(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?jH(Object(n),!0).forEach(function(a){qme(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):jH(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function qme(t,e,n){return(e=Jme(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Jme(t){var e=Xme(t,"string");return GM(e)=="symbol"?e:e+""}function Xme(t,e){if(GM(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(GM(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function SH(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function j1(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){SH(s,a,o,l,d,"next",f)}function d(f){SH(s,a,o,l,d,"throw",f)}l(void 0)})}}var eNe=function(e,n){return{_isInitialized:!1,_initializationInProgress:!1,_isConnectedToPlatform:!1,_prepareDataForWorkflow:function(o){n().setWorkflowId(o.workflow.id),n().setWorkflow(o.workflow),n().setLayout(o.workflow.client.layout),n().setProcessingTemplate(o.workflow.client.steps),n().setSessionProperties(o.properties)},_continueSession:function(){var a=j1(ho().mark(function s(){var l,d,f,g,M,I,y,h,m,N,E,A,T;return ho().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:if(l={isContinue:!1},d=n().workflowId,f=n().getCurrentSessionDataLs(),g=n().sessionRestoreMode,g){C.next=6;break}return C.abrupt("return",l);case 6:if(f){C.next=8;break}return C.abrupt("return",l);case 8:if(M=f.sessionId,I=f.workflowId,!(!M||I!==d)){C.next=11;break}return C.abrupt("return",l);case 11:return C.next=13,n().wasmService.continueSession(M);case 13:if(y=C.sent,h=y.data,"id"in h&&"currentStep"in h){C.next=20;break}return m=new BM({errorCode:UM.DECODING_FAILED}),N=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:m}),l=Pp(Pp({},l),{},{error:N}),C.abrupt("return",l);case 20:return E=h.currentStep,n()._prepareDataForWorkflow(h),A=n()._findStepById(E),(A==null?void 0:A.final)===!1?(T=h.currentStep,n().setIsProcessing(!1),n().setCurrentStepId(T),n().setCurrentSessionDataLsAndStore({sessionId:h.id,workflowId:I}),n().listener({eventType:hp.MESSAGE,message:vp.DID_START_RESTORE_SESSION,module:"IDV"}),l=Pp(Pp({},l),{},{isContinue:!0})):n().setCurrentSessionDataLsAndStore(null),C.abrupt("return",l);case 25:case"end":return C.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),initialize:function(o){return j1(ho().mark(function s(){var l;return ho().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(!n()._isInitialized){f.next=3;break}return console.warn("Idv:: Already initialized"),f.abrupt("return",{});case 3:if(!n()._initializationInProgress){f.next=5;break}return f.abrupt("return",new bp({errorCode:mp.INITIALIZATION_IN_PROGRESS}));case 5:return e({_initializationInProgress:!0}),f.next=8,n().setAndInitWasmService();case 8:return e({modulesConfig:o.modulesConfig||{},externalModulesNames:o.includedModules}),f.next=11,n().loadModules();case 11:if(l=f.sent,!l.error){f.next=14;break}return f.abrupt("return",{error:l.error});case 14:return e({_initializationInProgress:!1,_isInitialized:!0}),f.abrupt("return",{});case 16:case"end":return f.stop()}},s)}))()},configureWithUrl:function(o){return j1(ho().mark(function s(){var l;return ho().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(n()._isInitialized){f.next=2;break}return f.abrupt("return",{error:new T1({errorCode:td.INITIALIZATION_REQUIRED})});case 2:if(!n().currentScreenConfig){f.next=4;break}return f.abrupt("return",{error:new T1({errorCode:td.SCENARIO_IN_PROGRESS})});case 4:return f.next=6,n().connectByUrl(o);case 6:if(l=f.sent,!l.error){f.next=9;break}return f.abrupt("return",{error:l.error});case 9:return e({_isConnectedToPlatform:!0}),f.abrupt("return",l.workflows);case 11:case"end":return f.stop()}},s)}))()},configure:function(o){return j1(ho().mark(function s(){var l,d,f,g;return ho().wrap(function(I){for(;;)switch(I.prev=I.next){case 0:if(n()._isInitialized){I.next=2;break}return I.abrupt("return",{error:new T1({errorCode:td.INITIALIZATION_REQUIRED})});case 2:if(!n().currentScreenConfig){I.next=4;break}return I.abrupt("return",{error:new T1({errorCode:td.SCENARIO_IN_PROGRESS})});case 4:if(l=["password","userName","host"],d=l.filter(function(y){return!(o!=null&&o[y])}),!(d.length>0)){I.next=8;break}return I.abrupt("return",{error:new T1({errorCode:td.CONFIG_MISSED_OR_INVALID,message:"Missing parameters: ".concat(d.join(", "))})});case 8:return I.next=10,n().connectToIdv(o);case 10:if(f=I.sent,!f.error){I.next=14;break}return g=new T1({errorCode:td.CONNECTION_ISSUE,underlyingBaseError:f.error}),I.abrupt("return",{error:g});case 14:return e({_isConnectedToPlatform:!0}),I.abrupt("return",{workflows:[]});case 16:case"end":return I.stop()}},s)}))()},getWorkflows:function(){var o=arguments;return j1(ho().mark(function s(){var l,d,f,g,M,I,y;return ho().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:if(l=o.length>0&&o[0]!==void 0?o[0]:{limit:100,skip:0},n()._isInitialized){m.next=4;break}return d=new Wf({errorCode:Qf.INITIALIZATION_REQUIRED}),m.abrupt("return",{error:d});case 4:if(n()._isConnectedToPlatform){m.next=7;break}return f=new Wf({errorCode:Qf.CONNECTION_ISSUE}),m.abrupt("return",{error:f});case 7:return m.next=9,n().wasmService.listWorkflows(l);case 9:if(g=m.sent,M=null,g.code===4&&(M=Bl.HTTP_ISSUE),g.code!==0&&g.code!==4&&(M=Bl.PROVIDER_ERROR),g.code===0&&!g.data.items&&(M=Bl.DECODING_FAILED),M===null){m.next=18;break}return I=new zp({errorCode:M}),y=new Wf({errorCode:Qf.WORKFLOW_ISSUE,message:"No workflow list",underlyingBaseError:I}),m.abrupt("return",{error:y});case 18:return m.abrupt("return",{results:g.data.items});case 19:case"end":return m.stop()}},s)}))()},prepareWorkflowAndPrepareUi:function(o){return j1(ho().mark(function s(){var l,d,f,g,M,I,y,h,m,N,E,A,T,j,C,_,L;return ho().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:if(n()._isInitialized){H.next=3;break}return d=new Wf({errorCode:Qf.INITIALIZATION_REQUIRED}),H.abrupt("return",{error:d});case 3:if(n()._isConnectedToPlatform){H.next=6;break}return f=new Wf({errorCode:Qf.CONNECTION_ISSUE}),H.abrupt("return",{error:f});case 6:if(!n().currentScreenConfig){H.next=9;break}return g=new Wf({errorCode:Qf.SCENARIO_IN_PROGRESS}),H.abrupt("return",{error:g});case 9:return H.next=11,n().wasmService.getWorkflow(o);case 11:if(M=H.sent,I=HD(M.data),y=((l=I.client)===null||l===void 0?void 0:l.steps)&&I.client.steps.some(function(Q){return Q.templateId===zE}),h=null,M.code===4&&(h=Bl.HTTP_ISSUE),M.code!==0&&M.code!==4&&(h=Bl.PROVIDER_ERROR),M.code===0&&!M.data.id&&(h=Bl.DECODING_FAILED),M.data.id&&I===null&&(h=Bl.DECODING_FAILED),y||(h=Bl.DECODING_FAILED),h===null){H.next=24;break}return m=new zp({errorCode:h}),N=new Wf({errorCode:Qf.INTERNAL_ISSUE,underlyingBaseError:m}),H.abrupt("return",{error:N});case 24:return E=n().externalModules,A=I.steps,T=Cme(E,A),j=T.isAllTemplatesSupported,C=T.unsupportedSteps,j||console.log("IDV:: Warning. Unsupported steps found: ",C),_=n().workflowId,_&&o!==_&&E.forEach(function(Q){Q.component.deinitialize()}),L=n().modulesConfig,E.forEach(function(Q){Q.component.isReady()||Q.component.initialize(L)}),n().setLayout(I.client.layout),n().setProcessingTemplate(I.client.steps),n().setWorkflowId(o),H.abrupt("return",{workflow:I});case 36:case"end":return H.stop()}},s)}))()},startNewSession:function(o,s){return j1(ho().mark(function l(){var d,f,g,M,I,y,h,m,N,E,A,T,j,C,_,L,U,H,Q,x,O,w,R,Y,V,q;return ho().wrap(function(z){for(;;)switch(z.prev=z.next){case 0:if(n()._isInitialized){z.next=3;break}return d=new vu({errorCode:hu.INITIALIZATION_REQUIRED}),z.abrupt("return",{error:d});case 3:if(f=n().workflowId,f){z.next=7;break}return g=new vu({errorCode:hu.PREPARED_REQUIRED}),z.abrupt("return",{error:g});case 7:if(!n().currentScreenConfig){z.next=10;break}return M=new vu({errorCode:hu.ALREADY_STARTED}),z.abrupt("return",{error:M});case 10:return n().setIsProcessing(!0),I=function(){var G=j1(ho().mark(function K(){var k,W;return ho().wrap(function(Me){for(;;)switch(Me.prev=Me.next){case 0:return W=(k=n().wasmService)===null||k===void 0?void 0:k.isServiceRunning(),Me.abrupt("return",W||null);case 2:case"end":return Me.stop()}},K)}));return function(){return G.apply(this,arguments)}}(),y=function(){return null},z.next=15,BD(I,y);case 15:if(h=z.sent,h){z.next=19;break}return m=new vu({errorCode:hu.INTERNAL_ISSUE,message:"Service is not running"}),z.abrupt("return",{error:m});case 19:return z.next=21,n().wasmService.getServiceToken();case 21:if(N=z.sent,E=N.data,!(!E||typeof E!="string")){z.next=27;break}return A=new BM({errorCode:UM.TOKEN_ERROR}),T=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:A}),z.abrupt("return",{error:T});case 27:return n().setServiceSessionToken(E),z.next=30,n()._continueSession();case 30:if(j=z.sent,!j.error){z.next=33;break}return z.abrupt("return",{error:j.error});case 33:if(!j.isContinue){z.next=35;break}return z.abrupt("return",{});case 35:return z.next=37,n().wasmService.startSession(f,o,s);case 37:if(C=z.sent,!("httpCode"in C.data)){z.next=43;break}return U=typeof((_=C.data)===null||_===void 0?void 0:_.what)=="string"&&C.data.what.length?(L=C.data)===null||L===void 0?void 0:L.what:null,H=new BM(Pp({errorCode:UM.HTTP_ISSUE},U?{message:U}:{})),Q=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:H}),z.abrupt("return",{error:Q});case 43:if(x=C.data,O=x.id,w=x.currentStep,R=x.workflow,Y=O&&w&&R,Y){z.next=49;break}return V=new BM({errorCode:UM.DECODING_FAILED}),q=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:V}),z.abrupt("return",{error:q});case 49:return n()._prepareDataForWorkflow(C.data),n().setCurrentSessionDataLsAndStore({sessionId:C.data.id,workflowId:f}),n().setIsProcessing(!1),n().setCurrentStepId(w),n().listener({eventType:hp.MESSAGE,message:vp.DID_START_SESSION,module:"IDV"}),z.abrupt("return",{});case 55:case"end":return z.stop()}},l)}))()},playWorkflow:function(o){var s=n().currentStepId;if(n().setWorkflowSessionCompletion(o),s)n().onChangeScreen(s);else{var l=new vu({errorCode:hu.UNKNOWN_STEP});n().workflowSessionCompletion({error:l})}},deinitialize:function(){return j1(ho().mark(function o(){var s,l,d;return ho().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:if(n()._isInitialized){g.next=3;break}return s=new Rp({errorCode:Np.INITIALIZATION_REQUIRED}),g.abrupt("return",{error:s});case 3:if(!n().currentScreenConfig){g.next=6;break}return l=new Rp({errorCode:Np.SCENARIO_IN_PROGRESS}),g.abrupt("return",{error:l});case 6:return g.next=8,n().deinitializationIdv();case 8:return d=g.sent,n().resetProps(),e({_isInitialized:!1}),g.abrupt("return",d);case 12:case"end":return g.stop()}},o)}))()}}},CH={},AH;function tNe(){if(AH)return CH;AH=1;var t=wt(),e=X1().every,n=P4(),a=n("every");return t({target:"Array",proto:!0,forced:!a},{every:function(s){return e(this,s,arguments.length>1?arguments[1]:void 0)}}),CH}tNe();var OH={},qD,_H;function rNe(){if(_H)return qD;_H=1;var t=zM(),e=Ni(),n=Tu(),a=RangeError;return qD=function(s){var l=e(n(this)),d="",f=t(s);if(f<0||f===1/0)throw new a("Wrong number of repetitions");for(;f>0;(f>>>=1)&&(l+=l))f&1&&(d+=l);return d},qD}var JD,xH;function nNe(){if(xH)return JD;xH=1;var t=Mr(),e=k4(),n=Ni(),a=rNe(),o=Tu(),s=t(a),l=t("".slice),d=Math.ceil,f=function(g){return function(M,I,y){var h=n(o(M)),m=e(I),N=h.length,E=y===void 0?" ":n(y),A,T;return m<=N||E===""?h:(A=m-N,T=s(E,d(A/E.length)),T.length>A&&(T=l(T,0,A)),g?h+T:T+h)}};return JD={start:f(!1),end:f(!0)},JD}var XD,wH;function iNe(){if(wH)return XD;wH=1;var t=Mr(),e=dr(),n=nNe().start,a=RangeError,o=isFinite,s=Math.abs,l=Date.prototype,d=l.toISOString,f=t(l.getTime),g=t(l.getUTCDate),M=t(l.getUTCFullYear),I=t(l.getUTCHours),y=t(l.getUTCMilliseconds),h=t(l.getUTCMinutes),m=t(l.getUTCMonth),N=t(l.getUTCSeconds);return XD=e(function(){return d.call(new Date(-50000000000001))!=="0385-07-25T07:06:39.999Z"})||!e(function(){d.call(new Date(NaN))})?function(){if(!o(f(this)))throw new a("Invalid time value");var A=this,T=M(A),j=y(A),C=T<0?"-":T>9999?"+":"";return C+n(s(T),C?6:4,0)+"-"+n(m(A)+1,2,0)+"-"+n(g(A),2,0)+"T"+n(I(A),2,0)+":"+n(h(A),2,0)+":"+n(N(A),2,0)+"."+n(j,3,0)+"Z"}:d,XD}var bH;function aNe(){if(bH)return OH;bH=1;var t=wt(),e=iNe();return t({target:"Date",proto:!0,forced:Date.prototype.toISOString!==e},{toISOString:e}),OH}aNe();var LH={},kH;function oNe(){if(kH)return LH;kH=1;var t=wt(),e=Lr();return t({global:!0,forced:e.globalThis!==e},{globalThis:e}),LH}oNe();var RH={},zH;function uNe(){if(zH)return RH;zH=1;var t=wt(),e=Nz();return t({target:"Math",stat:!0},{trunc:e}),RH}uNe();var PH={},eT,UH;function sNe(){if(UH)return eT;UH=1;var t=Lr(),e=t.isFinite;return eT=Number.isFinite||function(a){return typeof a=="number"&&e(a)},eT}var YH;function lNe(){if(YH)return PH;YH=1;var t=wt(),e=sNe();return t({target:"Number",stat:!0},{isFinite:e}),PH}lNe();var $H={},QH;function cNe(){if(QH)return $H;QH=1;var t=wt();return t({target:"Number",stat:!0},{isNaN:function(n){return n!==n}}),$H}cNe();var FH={},tT,HH;function VH(){if(HH)return tT;HH=1;var t=tn(),e=Mr(),n=yn(),a=dr(),o=lp(),s=Eh(),l=hh(),d=Su(),f=rp(),g=Object.assign,M=Object.defineProperty,I=e([].concat);return tT=!g||a(function(){if(t&&g({b:1},g(M({},"a",{enumerable:!0,get:function(){M(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var y={},h={},m=Symbol("assign detection"),N="abcdefghijklmnopqrst";return y[m]=7,N.split("").forEach(function(E){h[E]=E}),g({},y)[m]!==7||o(g({},h)).join("")!==N})?function(h,m){for(var N=d(h),E=arguments.length,A=1,T=s.f,j=l.f;E>A;)for(var C=f(arguments[A++]),_=T?I(o(C),T(C)):o(C),L=_.length,U=0,H;L>U;)H=_[U++],(!t||n(j,C,H))&&(N[H]=C[H]);return N}:g,tT}var BH;function fNe(){if(BH)return FH;BH=1;var t=wt(),e=VH();return t({target:"Object",stat:!0,arity:2,forced:Object.assign!==e},{assign:e}),FH}fNe();var GH={},rT,ZH;function WH(){if(ZH)return rT;ZH=1;var t=tn(),e=dr(),n=Mr(),a=gp(),o=lp(),s=hl(),l=hh().f,d=n(l),f=n([].push),g=t&&e(function(){var I=Object.create(null);return I[2]=2,!d(I,2)}),M=function(I){return function(y){for(var h=s(y),m=o(h),N=g&&a(h)===null,E=m.length,A=0,T=[],j;E>A;)j=m[A++],(!t||(N?j in h:d(h,j)))&&f(T,I?[j,h[j]]:h[j]);return T}};return rT={entries:M(!0),values:M(!1)},rT}var KH;function dNe(){if(KH)return GH;KH=1;var t=wt(),e=WH().entries;return t({target:"Object",stat:!0},{entries:function(a){return e(a)}}),GH}dNe();var qH={},JH;function gNe(){if(JH)return qH;JH=1;var t=wt(),e=J5(),n=dr(),a=Jn(),o=pp().onFreeze,s=Object.freeze,l=n(function(){s(1)});return t({target:"Object",stat:!0,forced:l,sham:!e},{freeze:function(f){return s&&a(f)?s(o(f)):f}}),qH}gNe();var XH={},eV;function MNe(){if(eV)return XH;eV=1;var t=wt(),e=dr(),n=XN().f,a=e(function(){return!Object.getOwnPropertyNames(1)});return t({target:"Object",stat:!0,forced:a},{getOwnPropertyNames:n}),XH}MNe();var tV={},rV;function pNe(){if(rV)return tV;rV=1;var t=wt(),e=mi();return t({target:"Object",stat:!0},{hasOwn:e}),tV}pNe();var nV={},iV;function INe(){if(iV)return nV;iV=1;var t=wt(),e=WH().values;return t({target:"Object",stat:!0},{values:function(a){return e(a)}}),nV}INe();var aV={},nT,oV;function yNe(){if(oV)return nT;oV=1;var t=Lr(),e=dr(),n=Mr(),a=Ni(),o=Ah().trim,s=Ch(),l=n("".charAt),d=t.parseFloat,f=t.Symbol,g=f&&f.iterator,M=1/d(s+"-0")!==-1/0||g&&!e(function(){d(Object(g))});return nT=M?function(y){var h=o(a(y)),m=d(h);return m===0&&l(h,0)==="-"?-0:m}:d,nT}var uV;function hNe(){if(uV)return aV;uV=1;var t=wt(),e=yNe();return t({global:!0,forced:parseFloat!==e},{parseFloat:e}),aV}hNe();var sV={},iT,lV;function vNe(){if(lV)return iT;lV=1;var t=Lr(),e=dr(),n=Mr(),a=Ni(),o=Ah().trim,s=Ch(),l=t.parseInt,d=t.Symbol,f=d&&d.iterator,g=/^[+-]?0x/i,M=n(g.exec),I=l(s+"08")!==8||l(s+"0x16")!==22||f&&!e(function(){l(Object(f))});return iT=I?function(h,m){var N=o(a(h));return l(N,m>>>0||(M(g,N)?16:10))}:l,iT}var cV;function mNe(){if(cV)return sV;cV=1;var t=wt(),e=vNe();return t({global:!0,forced:parseInt!==e},{parseInt:e}),sV}mNe();var fV={},dV;function NNe(){if(dV)return fV;dV=1;var t=wt(),e=ed(),n=yo(),a=_n(),o=dr(),s=!o(function(){Reflect.apply(function(){})});return t({target:"Reflect",stat:!0,forced:s},{apply:function(d,f,g){return e(n(d),f,a(g))}}),fV}NNe();var gV={},MV;function ENe(){if(MV)return gV;MV=1;var t=wt(),e=Lr(),n=vl();return t({global:!0},{Reflect:{}}),n(e.Reflect,"Reflect",!0),gV}ENe();var pV={},IV;function DNe(){if(IV)return pV;IV=1;var t=tn(),e=Lr(),n=Mr(),a=up(),o=Th(),s=Hl(),l=Vl(),d=R4().f,f=N1(),g=Q$(),M=Ni(),I=hY(),y=wh(),h=UP(),m=Ra(),N=dr(),E=mi(),A=Au().enforce,T=dE(),j=Zn(),C=BE(),_=M$(),L=j("match"),U=e.RegExp,H=U.prototype,Q=e.SyntaxError,x=n(H.exec),O=n("".charAt),w=n("".replace),R=n("".indexOf),Y=n("".slice),V=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,q=/a/g,te=/a/g,z=new U(q)!==q,G=y.MISSED_STICKY,K=y.UNSUPPORTED_Y,k=t&&(!z||G||C||_||N(function(){return te[L]=!1,U(q)!==q||U(te)===te||String(U(q,"i"))!=="/a/i"})),W=function(Pe){for(var me=Pe.length,Le=0,Ze="",Xe=!1,tt;Le<=me;Le++){if(tt=O(Pe,Le),tt==="\\"){Ze+=tt+O(Pe,++Le);continue}!Xe&&tt==="."?Ze+="[\\s\\S]":(tt==="["?Xe=!0:tt==="]"&&(Xe=!1),Ze+=tt)}return Ze},pe=function(Pe){for(var me=Pe.length,Le=0,Ze="",Xe=[],tt=l(null),ct=!1,Dt=!1,Et=0,vt="",Je;Le<=me;Le++){if(Je=O(Pe,Le),Je==="\\")Je+=O(Pe,++Le);else if(Je==="]")ct=!1;else if(!ct)switch(!0){case Je==="[":ct=!0;break;case Je==="(":if(Ze+=Je,Y(Pe,Le+1,Le+3)==="?:")continue;x(V,Y(Pe,Le+1))&&(Le+=2,Dt=!0),Et++;continue;case(Je===">"&&Dt):if(vt===""||E(tt,vt))throw new Q("Invalid capture group name");tt[vt]=!0,Xe[Xe.length]=[vt,Et],Dt=!1,vt="";continue}Dt?vt+=Je:Ze+=Je}return[Ze,Xe]};if(a("RegExp",k)){for(var Me=function(me,Le){var Ze=f(H,this),Xe=g(me),tt=Le===void 0,ct=[],Dt=me,Et,vt,Je,dt,pt,Ke;if(!Ze&&Xe&&tt&&me.constructor===Me)return me;if((Xe||f(H,me))&&(me=me.source,tt&&(Le=I(Dt))),me=me===void 0?"":M(me),Le=Le===void 0?"":M(Le),Dt=me,C&&"dotAll"in q&&(vt=!!Le&&R(Le,"s")>-1,vt&&(Le=w(Le,/s/g,""))),Et=Le,G&&"sticky"in q&&(Je=!!Le&&R(Le,"y")>-1,Je&&K&&(Le=w(Le,/y/g,""))),_&&(dt=pe(me),me=dt[0],ct=dt[1]),pt=o(U(me,Le),Ze?this:H,Me),(vt||Je||ct.length)&&(Ke=A(pt),vt&&(Ke.dotAll=!0,Ke.raw=Me(W(me),Et)),Je&&(Ke.sticky=!0),ct.length&&(Ke.groups=ct)),me!==Dt)try{s(pt,"source",Dt===""?"(?:)":Dt)}catch(Ce){}return pt},le=d(U),Oe=0;le.length>Oe;)h(Me,U,le[Oe++]);H.constructor=Me,Me.prototype=H,m(e,"RegExp",Me,{constructor:!0})}return T("RegExp"),pV}DNe();var yV={},hV;function TNe(){if(hV)return yV;hV=1;var t=tn(),e=BE(),n=yl(),a=Uu(),o=Au().get,s=RegExp.prototype,l=TypeError;return t&&e&&a(s,"dotAll",{configurable:!0,get:function(){if(this!==s){if(n(this)==="RegExp")return!!o(this).dotAll;throw new l("Incompatible receiver, RegExp required")}}}),yV}TNe();var vV={},mV;function jNe(){if(mV)return vV;mV=1;var t=Lr(),e=tn(),n=Uu(),a=mE(),o=dr(),s=t.RegExp,l=s.prototype,d=e&&o(function(){var f=!0;try{s(".","d")}catch(E){f=!1}var g={},M="",I=f?"dgimsy":"gimsy",y=function(E,A){Object.defineProperty(g,E,{get:function(){return M+=A,!0}})},h={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};f&&(h.hasIndices="d");for(var m in h)y(m,h[m]);var N=Object.getOwnPropertyDescriptor(l,"flags").get.call(g);return N!==I||M!==I});return d&&n(l,"flags",{configurable:!0,get:a}),vV}jNe();var NV={},EV;function SNe(){if(EV)return NV;EV=1;var t=tn(),e=wh().MISSED_STICKY,n=yl(),a=Uu(),o=Au().get,s=RegExp.prototype,l=TypeError;return t&&e&&a(s,"sticky",{configurable:!0,get:function(){if(this!==s){if(n(this)==="RegExp")return!!o(this).sticky;throw new l("Incompatible receiver, RegExp required")}}}),NV}SNe();var DV={},aT,TV;function Ph(){if(TV)return aT;TV=1,KE();var t=yn(),e=Ra(),n=WE(),a=dr(),o=Zn(),s=Hl(),l=o("species"),d=RegExp.prototype;return aT=function(f,g,M,I){var y=o(f),h=!a(function(){var A={};return A[y]=function(){return 7},""[f](A)!==7}),m=h&&!a(function(){var A=!1,T=/a/;return f==="split"&&(T={},T.constructor={},T.constructor[l]=function(){return T},T.flags="",T[y]=/./[y]),T.exec=function(){return A=!0,null},T[y](""),!A});if(!h||!m||M){var N=/./[y],E=g(y,""[f],function(A,T,j,C,_){var L=T.exec;return L===n||L===d.exec?h&&!_?{done:!0,value:t(N,T,j,C)}:{done:!0,value:t(A,j,T,C)}:{done:!1}});e(String.prototype,f,E[0]),e(d,y,E[1])}I&&s(d[y],"sham",!0)},aT}var oT,jV;function uT(){if(jV)return oT;jV=1;var t=DE().charAt;return oT=function(e,n,a){return n+(a?t(e,n).length:1)},oT}var sT,SV;function Uh(){if(SV)return sT;SV=1;var t=yn(),e=_n(),n=qn(),a=yl(),o=WE(),s=TypeError;return sT=function(l,d){var f=l.exec;if(n(f)){var g=t(f,l,d);return g!==null&&e(g),g}if(a(l)==="RegExp")return t(o,l,d);throw new s("RegExp#exec called on incompatible receiver")},sT}var CV;function CNe(){if(CV)return DV;CV=1;var t=yn(),e=Ph(),n=_n(),a=Jn(),o=k4(),s=Ni(),l=Tu(),d=K1(),f=uT(),g=Uh();return e("match",function(M,I,y){return[function(m){var N=l(this),E=a(m)?d(m,M):void 0;return E?t(E,m,N):new RegExp(m)[M](s(N))},function(h){var m=n(this),N=s(h),E=y(I,m,N);if(E.done)return E.value;if(!m.global)return g(m,N);var A=m.unicode;m.lastIndex=0;for(var T=[],j=0,C;(C=g(m,N))!==null;){var _=s(C[0]);T[j]=_,_===""&&(m.lastIndex=f(N,o(m.lastIndex),A)),j++}return j===0?null:T}]}),DV}CNe();var AV={},lT,OV;function ANe(){if(OV)return lT;OV=1;var t=Mr(),e=Su(),n=Math.floor,a=t("".charAt),o=t("".replace),s=t("".slice),l=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,d=/\$([$&'`]|\d{1,2})/g;return lT=function(f,g,M,I,y,h){var m=M+f.length,N=I.length,E=d;return y!==void 0&&(y=e(y),E=l),o(h,E,function(A,T){var j;switch(a(T,0)){case"$":return"$";case"&":return f;case"`":return s(g,0,M);case"'":return s(g,m);case"<":j=y[s(T,1,-1)];break;default:var C=+T;if(C===0)return A;if(C>N){var _=n(C/10);return _===0?A:_<=N?I[_-1]===void 0?a(T,1):I[_-1]+a(T,1):A}j=I[C-1]}return j===void 0?"":j})},lT}var _V;function ONe(){if(_V)return AV;_V=1;var t=ed(),e=yn(),n=Mr(),a=Ph(),o=dr(),s=_n(),l=qn(),d=Jn(),f=zM(),g=k4(),M=Ni(),I=Tu(),y=uT(),h=K1(),m=ANe(),N=Uh(),E=Zn(),A=E("replace"),T=Math.max,j=Math.min,C=n([].concat),_=n([].push),L=n("".indexOf),U=n("".slice),H=function(w){return w===void 0?w:String(w)},Q=function(){return"a".replace(/./,"$0")==="$0"}(),x=function(){return/./[A]?/./[A]("a","$0")==="":!1}(),O=!o(function(){var w=/./;return w.exec=function(){var R=[];return R.groups={a:"7"},R},"".replace(w,"$<a>")!=="7"});return a("replace",function(w,R,Y){var V=x?"$":"$0";return[function(te,z){var G=I(this),K=d(te)?h(te,A):void 0;return K?e(K,te,G,z):e(R,M(G),te,z)},function(q,te){var z=s(this),G=M(q);if(typeof te=="string"&&L(te,V)===-1&&L(te,"$<")===-1){var K=Y(R,z,G,te);if(K.done)return K.value}var k=l(te);k||(te=M(te));var W=z.global,pe;W&&(pe=z.unicode,z.lastIndex=0);for(var Me=[],le;le=N(z,G),!(le===null||(_(Me,le),!W));){var Oe=M(le[0]);Oe===""&&(z.lastIndex=y(G,g(z.lastIndex),pe))}for(var Pe="",me=0,Le=0;Le<Me.length;Le++){le=Me[Le];for(var Ze=M(le[0]),Xe=T(j(f(le.index),G.length),0),tt=[],ct,Dt=1;Dt<le.length;Dt++)_(tt,H(le[Dt]));var Et=le.groups;if(k){var vt=C([Ze],tt,Xe,G);Et!==void 0&&_(vt,Et),ct=M(t(te,void 0,vt))}else ct=m(Ze,G,Xe,tt,Et,te);Xe>=me&&(Pe+=U(G,me,Xe)+ct,me=Xe+Ze.length)}return Pe+U(G,me)}]},!O||!Q||x),AV}ONe();var xV={},cT,wV;function _Ne(){return wV||(wV=1,cT=Object.is||function(e,n){return e===n?e!==0||1/e===1/n:e!==e&&n!==n}),cT}var bV;function xNe(){if(bV)return xV;bV=1;var t=yn(),e=Ph(),n=_n(),a=Jn(),o=Tu(),s=_Ne(),l=Ni(),d=K1(),f=Uh();return e("search",function(g,M,I){return[function(h){var m=o(this),N=a(h)?d(h,g):void 0;return N?t(N,h,m):new RegExp(h)[g](l(m))},function(y){var h=n(this),m=l(y),N=I(M,h,m);if(N.done)return N.value;var E=h.lastIndex;s(E,0)||(h.lastIndex=0);var A=f(h,m);return s(h.lastIndex,E)||(h.lastIndex=E),A===null?-1:A.index}]}),xV}xNe();var LV={},kV;function wNe(){if(kV)return LV;kV=1;var t=yn(),e=Mr(),n=Ph(),a=_n(),o=Jn(),s=Tu(),l=YQ(),d=uT(),f=k4(),g=Ni(),M=K1(),I=Uh(),y=wh(),h=dr(),m=y.UNSUPPORTED_Y,N=4294967295,E=Math.min,A=e([].push),T=e("".slice),j=!h(function(){var _=/(?:)/,L=_.exec;_.exec=function(){return L.apply(this,arguments)};var U="ab".split(_);return U.length!==2||U[0]!=="a"||U[1]!=="b"}),C="abbc".split(/(b)*/)[1]==="c"||"test".split(/(?:)/,-1).length!==4||"ab".split(/(?:ab)*/).length!==2||".".split(/(.?)(.?)/).length!==4||".".split(/()()/).length>1||"".split(/.?/).length;return n("split",function(_,L,U){var H="0".split(void 0,0).length?function(Q,x){return Q===void 0&&x===0?[]:t(L,this,Q,x)}:L;return[function(x,O){var w=s(this),R=o(x)?M(x,_):void 0;return R?t(R,x,w,O):t(H,g(w),x,O)},function(Q,x){var O=a(this),w=g(Q);if(!C){var R=U(H,O,w,x,H!==L);if(R.done)return R.value}var Y=l(O,RegExp),V=O.unicode,q=(O.ignoreCase?"i":"")+(O.multiline?"m":"")+(O.unicode?"u":"")+(m?"g":"y"),te=new Y(m?"^(?:"+O.source+")":O,q),z=x===void 0?N:x>>>0;if(z===0)return[];if(w.length===0)return I(te,w)===null?[w]:[];for(var G=0,K=0,k=[];K<w.length;){te.lastIndex=m?0:K;var W=I(te,m?T(w,K):w),pe;if(W===null||(pe=E(f(te.lastIndex+(m?K:0)),w.length))===G)K=d(w,K,V);else{if(A(k,T(w,G,K)),k.length===z)return k;for(var Me=1;Me<=W.length-1;Me++)if(A(k,W[Me]),k.length===z)return k;K=G=pe}}return A(k,T(w,G)),k}]},C||!j,m),LV}wNe();var RV={},zV;function bNe(){if(zV)return RV;zV=1;var t=wt(),e=u5(),n=RM().f,a=k4(),o=Ni(),s=H$(),l=Tu(),d=B$(),f=yu(),g=e("".slice),M=Math.min,I=d("startsWith"),y=!f&&!I&&!!function(){var h=n(String.prototype,"startsWith");return h&&!h.writable}();return t({target:"String",proto:!0,forced:!y&&!I},{startsWith:function(m){var N=o(l(this));s(m);var E=a(M(arguments.length>1?arguments[1]:void 0,N.length)),A=o(m);return g(N,E,E+A.length)===A}}),RV}bNe();var PV={},UV;function LNe(){if(UV)return PV;UV=1;var t=wt(),e=Mr(),n=Tu(),a=zM(),o=Ni(),s=e("".slice),l=Math.max,d=Math.min,f=!"".substr||"ab".substr(-1)!=="b";return t({target:"String",proto:!0,forced:f},{substr:function(M,I){var y=o(n(this)),h=y.length,m=a(M),N,E;return m===1/0&&(m=0),m<0&&(m=l(h+m,0)),N=I===void 0?h:a(I),N<=0||N===1/0?"":(E=d(m+N,h),m>=E?"":s(y,m,E))}}),PV}LNe();var YV={},$V={},fT,QV;function kNe(){if(QV)return fT;QV=1;var t=Mr(),e=Ip(),n=pp().getWeakData,a=PM(),o=_n(),s=kM(),l=Jn(),d=$f(),f=X1(),g=mi(),M=Au(),I=M.set,y=M.getterFor,h=f.find,m=f.findIndex,N=t([].splice),E=0,A=function(C){return C.frozen||(C.frozen=new T)},T=function(){this.entries=[]},j=function(C,_){return h(C.entries,function(L){return L[0]===_})};return T.prototype={get:function(C){var _=j(this,C);if(_)return _[1]},has:function(C){return!!j(this,C)},set:function(C,_){var L=j(this,C);L?L[1]=_:this.entries.push([C,_])},delete:function(C){var _=m(this.entries,function(L){return L[0]===C});return~_&&N(this.entries,_,1),!!~_}},fT={getConstructor:function(C,_,L,U){var H=C(function(w,R){a(w,Q),I(w,{type:_,id:E++,frozen:null}),s(R)||d(R,w[U],{that:w,AS_ENTRIES:L})}),Q=H.prototype,x=y(_),O=function(w,R,Y){var V=x(w),q=n(o(R),!0);return q===!0?A(V).set(R,Y):q[V.id]=Y,w};return e(Q,{delete:function(w){var R=x(this);if(!l(w))return!1;var Y=n(w);return Y===!0?A(R).delete(w):Y&&g(Y,R.id)&&delete Y[R.id]},has:function(R){var Y=x(this);if(!l(R))return!1;var V=n(R);return V===!0?A(Y).has(R):V&&g(V,Y.id)}}),e(Q,L?{get:function(R){var Y=x(this);if(l(R)){var V=n(R);if(V===!0)return A(Y).get(R);if(V)return V[Y.id]}},set:function(R,Y){return O(this,R,Y)}}:{add:function(R){return O(this,R,!0)}}),H}},fT}var FV;function RNe(){if(FV)return $V;FV=1;var t=J5(),e=Lr(),n=Mr(),a=Ip(),o=pp(),s=lE(),l=kNe(),d=Jn(),f=Au().enforce,g=dr(),M=gz(),I=Object,y=Array.isArray,h=I.isExtensible,m=I.isFrozen,N=I.isSealed,E=I.freeze,A=I.seal,T=!e.ActiveXObject&&"ActiveXObject"in e,j,C=function(w){return function(){return w(this,arguments.length?arguments[0]:void 0)}},_=s("WeakMap",C,l),L=_.prototype,U=n(L.set),H=function(){return t&&g(function(){var w=E([]);return U(new _,w,1),!m(w)})};if(M)if(T){j=l.getConstructor(C,"WeakMap",!0),o.enable();var Q=n(L.delete),x=n(L.has),O=n(L.get);a(L,{delete:function(w){if(d(w)&&!h(w)){var R=f(this);return R.frozen||(R.frozen=new j),Q(this,w)||R.frozen.delete(w)}return Q(this,w)},has:function(R){if(d(R)&&!h(R)){var Y=f(this);return Y.frozen||(Y.frozen=new j),x(this,R)||Y.frozen.has(R)}return x(this,R)},get:function(R){if(d(R)&&!h(R)){var Y=f(this);return Y.frozen||(Y.frozen=new j),x(this,R)?O(this,R):Y.frozen.get(R)}return O(this,R)},set:function(R,Y){if(d(R)&&!h(R)){var V=f(this);V.frozen||(V.frozen=new j),x(this,R)?U(this,R,Y):V.frozen.set(R,Y)}else U(this,R,Y);return this}})}else H()&&a(L,{set:function(R,Y){var V;return y(R)&&(m(R)?V=E:N(R)&&(V=A)),U(this,R,Y),V&&V(R),this}});return $V}var HV;function zNe(){return HV||(HV=1,RNe()),YV}zNe();var VV={},BV={},GV;function PNe(){if(GV)return BV;GV=1;var t=wt(),e=yn(),n=$f(),a=yo(),o=_n(),s=rd(),l=ml(),d=$M(),f=d("every",TypeError);return t({target:"Iterator",proto:!0,real:!0,forced:f},{every:function(M){o(this);try{a(M)}catch(h){l(this,"throw",h)}if(f)return e(f,this,M);var I=s(this),y=0;return!n(I,function(h,m){if(!M(h,y++))return m()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}}),BV}var ZV;function UNe(){return ZV||(ZV=1,PNe()),VV}UNe();var WV={},KV;function YNe(){if(KV)return WV;KV=1;var t=wt(),e=Lr(),n=Uu(),a=tn(),o=TypeError,s=Object.defineProperty,l=e.self!==e;try{if(a){var d=Object.getOwnPropertyDescriptor(e,"self");(l||!d||!d.get||!d.enumerable)&&n(e,"self",{get:function(){return e},set:function(g){if(this!==e)throw new o("Illegal invocation");s(e,"self",{value:g,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}else t({global:!0,simple:!0,forced:l},{self:e})}catch(f){}return WV}YNe();var $Ne=GY();function Sa(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */Sa=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&ni(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(ni(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function Kf(t){return HNe(t)||FNe(t)||gT(t)||QNe()}function QNe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
47
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function oH(t,e){if(t){if(typeof t=="string")return FD(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?FD(t,e):void 0}}function Eme(t){if(typeof Symbol!="undefined"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function Dme(t){if(Array.isArray(t))return FD(t)}function FD(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}function uH(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function sH(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){uH(s,a,o,l,d,"next",f)}function d(f){uH(s,a,o,l,d,"throw",f)}l(void 0)})}}function HD(t){try{return JSON.parse(JSON.stringify(t))}catch(e){return console.warn("Failed to copy object:",e),null}}var lH=function(e,n){if(!e||!n)return null;var a=null;return a=HD(e),a&&(a=Mme(a,n)),a};function Tme(t){return VD.apply(this,arguments)}function VD(){return VD=sH(Op().mark(function t(e){return Op().wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return a.abrupt("return",new Promise(function(o){return setTimeout(o,e)}));case 1:case"end":return a.stop()}},t)})),VD.apply(this,arguments)}function BD(t,e){return GD.apply(this,arguments)}function GD(){return GD=sH(Op().mark(function t(e,n){var a,o,s,l,d=arguments;return Op().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:a=d.length>2&&d[2]!==void 0?d[2]:wve,o=d.length>3&&d[3]!==void 0?d[3]:bve,s=0;case 3:if(!(s<a)){g.next=15;break}return g.next=6,e();case 6:if(l=g.sent,l===null){g.next=9;break}return g.abrupt("return",l);case 9:if(s++,!(s<a)){g.next=13;break}return g.next=13,Tme(o);case 13:g.next=3;break;case 15:return g.abrupt("return",n());case 16:case"end":return g.stop()}},t)})),GD.apply(this,arguments)}var jme=function(e,n,a){var o=e.reduce(function(l,d){return l.push.apply(l,aH(d.supportedTemplates)),l},[]),s=n.find(function(l){return l.id===a});return o.includes(s==null?void 0:s.client.templateId)},Sme=function(e,n){if(!e||!n)return!1;var a=e.find(function(s){return s.id===n}),o=(a==null?void 0:a.type)==="DATA"||(a==null?void 0:a.type)==="QUESTIONARY";return o},Cme=function(e,n){var a=e.reduce(function(d,f){return d.push.apply(d,aH(f.supportedTemplates)),d},[]),o=Array.from(new Set(n.filter(function(d){return d.type==="DATA"&&!d.final}).map(function(d){return d.client.templateId})));function s(d,f){var g=new Set(d);return f.filter(function(M){return!g.has(M)})}var l=s(a,o);return{isAllTemplatesSupported:l.length===0,unsupportedSteps:l.length>0?l:void 0}},Ame=function(e,n){return e+":"+n},ZD={setSessionIdWorkflowIdToLs:function(e,n){var a=Ame(e,n);localStorage.setItem(PE,a)},getSessionIdWorkflowIdFromLS:function(){var e=localStorage.getItem(PE);if(e){var n=e.split(":"),a=yme(n,2),o=a[0],s=a[1];if(o&&s)return{sessionId:o,workflowId:s}}return null},removeSessionIdWorkflowIdFromLS:function(){localStorage.removeItem(PE)}},Ome=function(e){var n;try{var a;n=(a=window.localStorage.getItem(e))!==null&&a!==void 0?a:window.crypto.randomUUID(),window.localStorage.setItem(e,n)}catch(o){n=window.crypto.randomUUID()}return n};function _me(t){return Object.prototype.toString.call(t)==="[object Object]"&&Object.keys(t).length>0}function xme(t){return _p(t)==="object"&&t!==null&&!Array.isArray(t)&&Object.getPrototypeOf(t)===Object.prototype}function wme(){return typeof document=="undefined"?null:document.documentElement.getAttribute("lang")||null}function bme(){return typeof navigator!="undefined"?navigator.language:null}var Lme=function(e){var n=kve,a=typeof e=="string"?e:null,o=wme(),s=bme();return a||o||s||n};function xp(t){"@babel/helpers - typeof";return xp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},xp(t)}function cH(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function WD(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?cH(Object(n),!0).forEach(function(a){kme(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):cH(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function kme(t,e,n){return(e=Rme(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Rme(t){var e=zme(t,"string");return xp(e)=="symbol"?e:e+""}function zme(t,e){if(xp(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(xp(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var fH={sessionProperties:[],currentSessionData:null,sessionRestoreMode:!1,processingTransformedTemplate:null,nonce:void 0,currentStepId:null,layout:null,currentScreenConfig:null,workflowId:null,modulesConfig:{},workflow:null,externalModulesNames:[],externalModules:[],serviceToken:void 0,listener:function(){}},Pme=function(e,n){return WD(WD({},fH),{},{setSessionProperties:function(o){e({sessionProperties:o})},setServiceSessionToken:function(o){e({serviceToken:o})},setListener:function(o){e({listener:o})},getCurrentSessionDataLs:function(){var o=ZD.getSessionIdWorkflowIdFromLS();return o!=null&&o.sessionId?o:null},setCurrentSessionDataLsAndStore:function(o){if(o===null)return ZD.removeSessionIdWorkflowIdFromLS(),e(function(){return{currentSessionData:null}});ZD.setSessionIdWorkflowIdToLs(o.sessionId,o.workflowId),e(function(){return{currentSessionData:o}})},getCurrentSessionId:function(){var o=n().currentSessionData;return o?o.sessionId:null},setWorkflowId:function(o){e(function(){return{workflowId:o}})},setWorkflow:function(o){e(function(){return{workflow:o}})},setLayout:function(o){e(function(){return{layout:o}})},setCurrentStepId:function(o){e(function(){return{currentStepId:o}})},setSessionRestoreMode:function(o){e(function(){return{sessionRestoreMode:o}})},setNonce:function(o){e(function(){return{nonce:o}})},getNonce:function(){return n().nonce},resetProps:function(){return e(function(){return WD({},fH)})}})},dH={},gH;function Ume(){if(gH)return dH;gH=1;var t=wt(),e=Mr(),n=rp(),a=hl(),o=P4(),s=e([].join),l=n!==Object,d=l||!o("join",",");return t({target:"Array",proto:!0,forced:d},{join:function(g){return s(a(this),g===void 0?",":g)}}),dH}Ume();var MH={},pH;function Yme(){if(pH)return MH;pH=1;var t=wt(),e=X1().some,n=P4(),a=n("some");return t({target:"Array",proto:!0,forced:!a},{some:function(s){return e(this,s,arguments.length>1?arguments[1]:void 0)}}),MH}Yme();var IH={},yH={},hH;function $me(){if(hH)return yH;hH=1;var t=wt(),e=yn(),n=$f(),a=yo(),o=_n(),s=rd(),l=ml(),d=$M(),f=d("some",TypeError);return t({target:"Iterator",proto:!0,real:!0,forced:f},{some:function(M){o(this);try{a(M)}catch(h){l(this,"throw",h)}if(f)return e(f,this,M);var I=s(this),y=0;return n(I,function(h,m){if(M(h,y++))return m()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}}),yH}var vH;function Qme(){return vH||(vH=1,$me()),IH}Qme();var mH={},NH;function Fme(){if(NH)return mH;NH=1;var t=wt(),e=dr(),n=z4(),a=Jn(),o=Su(),s=E1(),l=V5(),d=Ep(),f=sP(),g=xh(),M=Zn(),I=np(),y=M("isConcatSpreadable"),h=I>=51||!e(function(){var E=[];return E[y]=!1,E.concat()[0]!==E}),m=function(E){if(!a(E))return!1;var A=E[y];return A!==void 0?!!A:n(E)},N=!h||!g("concat");return t({target:"Array",proto:!0,arity:1,forced:N},{concat:function(A){var T=o(this),j=f(T,0),C=0,_,L,U,H,Q;for(_=-1,U=arguments.length;_<U;_++)if(Q=_===-1?T:arguments[_],m(Q))for(H=s(Q),l(C+H),L=0;L<H;L++,C++)L in Q&&d(j,C,Q[L]);else l(C+1),d(j,C++,Q);return j.length=C,j}}),mH}Fme();function wp(t){"@babel/helpers - typeof";return wp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wp(t)}function Hme(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function EH(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,DH(a.key),a)}}function Vme(t,e,n){return e&&EH(t.prototype,e),n&&EH(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function D1(t,e,n){return(e=DH(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function DH(t){var e=Bme(t,"string");return wp(e)=="symbol"?e:e+""}function Bme(t,e){if(wp(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(wp(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var ri=function(){function t(e){var n=e.errorCode,a=e.errorCodeKey,o=e.message,s=e.underlyingError,l=e.underlyingBaseError,d=e.domain,f=e.module,g=e.errorEnumName,M=e.shortDomainCode;Hme(this,t),D1(this,"errorCode",void 0),D1(this,"errorCodeKey",void 0),D1(this,"message",void 0),D1(this,"underlyingError",void 0),D1(this,"underlyingBaseError",void 0),D1(this,"domain",void 0),D1(this,"module",void 0),D1(this,"errorEnumName",void 0),D1(this,"shortDomainCode",void 0),this.errorCode=n,this.errorCodeKey=a,this.message=o,this.underlyingError=s,this.underlyingBaseError=l,this.module=f,this.domain=d,this.errorEnumName=g,this.shortDomainCode=M}return Vme(t,[{key:"lastUnderlyingError",get:function(){for(var n,a=this.underlyingBaseError;((o=a)===null||o===void 0?void 0:o.underlyingBaseError)instanceof t;){var o;a=a.underlyingBaseError}return(n=a)===null||n===void 0?void 0:n.underlyingError}},{key:"toObject",value:function(){var n={errorCode:this.errorCode,errorCodeKey:this.errorCodeKey,errorEnumName:this.errorEnumName,message:this.message,module:this.module,underlyingError:this.underlyingError,lastUnderlineError:this.lastUnderlyingError};return this.underlyingBaseError&&this.underlyingBaseError instanceof t&&(n.underlyingBaseError=this.underlyingBaseError.toObject()),n}},{key:"shortChain",get:function(){var n="".concat(this.shortDomainCode,":").concat(this.errorCode).concat(this.underlyingError?"-"+this.underlyingError:"");return this.underlyingBaseError instanceof t&&(n+="-".concat(this.underlyingBaseError.shortChain)),n}},{key:"fullChain",get:function(){var n="".concat(this.module,".").concat(this.domain,":").concat(this.errorCodeKey).concat(this.underlyingError?"-"+this.underlyingError:"");return this.underlyingBaseError instanceof t&&(n+="-".concat(this.underlyingBaseError.fullChain)),n}}],[{key:"getErrorKey",value:function(n,a){var o=Object.keys(a).find(function(s){return a[s]===n});if(!o)throw new Error("Invalid errorCode: ".concat(n," in enum"));return o}}])}();function $4(t){"@babel/helpers - typeof";return $4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$4(t)}function Vf(t,e,n){return Object.defineProperty(t,"prototype",{writable:!1}),t}function Bf(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Gf(t,e,n){return e=Rh(e),Gme(t,TH()?Reflect.construct(e,n||[],Rh(t).constructor):e.apply(t,n))}function Gme(t,e){if(e&&($4(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Zme(t)}function Zme(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function TH(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(TH=function(){return!!t})()}function Rh(t){return Rh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Rh(t)}function Zf(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&KD(t,e)}function KD(t,e){return KD=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},KD(t,e)}function Xn(t,e,n){return(e=Wme(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Wme(t){var e=Kme(t,"string");return $4(e)=="symbol"?e:e+""}function Kme(t,e){if($4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if($4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var bp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,mp);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(bp,"MODULE",Ff),Xn(bp,"ERROR_ENUM_NAME","InitializeError"),Xn(bp,"SHORT_CODE","IN");var zh=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,RE);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(zh,"MODULE",Ff),Xn(zh,"ERROR_ENUM_NAME","TokenInitializeError"),Xn(zh,"SHORT_CODE","TI");var Wf=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Qf);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(Wf,"MODULE",Ff),Xn(Wf,"ERROR_ENUM_NAME","PrepareWorkflowError"),Xn(Wf,"SHORT_CODE","PW");var T1=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,td);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(T1,"MODULE",Ff),Xn(T1,"ERROR_ENUM_NAME","ConfigureError"),Xn(T1,"SHORT_CODE","CO");var vu=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,hu);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(vu,"MODULE",Ff),Xn(vu,"ERROR_ENUM_NAME","ScenarioError"),Xn(vu,"SHORT_CODE","SC");var Lp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,YM);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(Lp,"MODULE",Ff),Xn(Lp,"ERROR_ENUM_NAME","ScenarioError"),Xn(Lp,"SHORT_CODE","CO");var kp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Nl);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(kp,"MODULE",Ff),Xn(kp,"ERROR_ENUM_NAME","SessionError"),Xn(kp,"SHORT_CODE","SE");var BM=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,UM);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(BM,"MODULE",Ff),Xn(BM,"ERROR_ENUM_NAME","StartSessionError"),Xn(BM,"SHORT_CODE","ST");var Rp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Np);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(Rp,"MODULE",Ff),Xn(Rp,"ERROR_ENUM_NAME","DeinitializationError"),Xn(Rp,"SHORT_CODE","DE");var zp=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;Bf(this,e);var d=ri.getErrorKey(a,Bl);return Gf(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return Zf(e,t),Vf(e)}(ri);Xn(zp,"MODULE",Ff),Xn(zp,"ERROR_ENUM_NAME","WorkflowError"),Xn(zp,"SHORT_CODE","WR");function GM(t){"@babel/helpers - typeof";return GM=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},GM(t)}function ho(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ho=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&GM(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(GM(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function jH(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function Pp(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?jH(Object(n),!0).forEach(function(a){qme(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):jH(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function qme(t,e,n){return(e=Jme(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Jme(t){var e=Xme(t,"string");return GM(e)=="symbol"?e:e+""}function Xme(t,e){if(GM(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(GM(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function SH(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function j1(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){SH(s,a,o,l,d,"next",f)}function d(f){SH(s,a,o,l,d,"throw",f)}l(void 0)})}}var eNe=function(e,n){return{_isInitialized:!1,_initializationInProgress:!1,_isConnectedToPlatform:!1,_prepareDataForWorkflow:function(o){n().setWorkflowId(o.workflow.id),n().setWorkflow(o.workflow),n().setLayout(o.workflow.client.layout),n().setProcessingTemplate(o.workflow.client.steps),n().setSessionProperties(o.properties)},_continueSession:function(){var a=j1(ho().mark(function s(l){var d,f,g,M,I,y,h,m,N,E,A,T,j;return ho().wrap(function(_){for(;;)switch(_.prev=_.next){case 0:if(d={isContinue:!1},f=n().workflowId,g=n().getCurrentSessionDataLs(),M=n().sessionRestoreMode,M){_.next=6;break}return _.abrupt("return",d);case 6:if(g){_.next=8;break}return _.abrupt("return",d);case 8:if(I=g.sessionId,y=g.workflowId,!(!I||y!==f)){_.next=11;break}return _.abrupt("return",d);case 11:return _.next=13,n().wasmService.continueSession(I,l);case 13:if(h=_.sent,m=h.data,"id"in m&&"currentStep"in m){_.next=20;break}return N=new BM({errorCode:UM.DECODING_FAILED}),E=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:N}),d=Pp(Pp({},d),{},{error:E}),_.abrupt("return",d);case 20:return A=m.currentStep,n()._prepareDataForWorkflow(m),T=n()._findStepById(A),(T==null?void 0:T.final)===!1?(j=m.currentStep,n().setIsProcessing(!1),n().setCurrentStepId(j),n().setCurrentSessionDataLsAndStore({sessionId:m.id,workflowId:y}),n().listener({eventType:hp.MESSAGE,message:vp.DID_START_RESTORE_SESSION,module:"IDV"}),d=Pp(Pp({},d),{},{isContinue:!0})):n().setCurrentSessionDataLsAndStore(null),_.abrupt("return",d);case 25:case"end":return _.stop()}},s)}));function o(s){return a.apply(this,arguments)}return o}(),initialize:function(o){return j1(ho().mark(function s(){var l;return ho().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(!n()._isInitialized){f.next=3;break}return console.warn("Idv:: Already initialized"),f.abrupt("return",{});case 3:if(!n()._initializationInProgress){f.next=5;break}return f.abrupt("return",new bp({errorCode:mp.INITIALIZATION_IN_PROGRESS}));case 5:return e({_initializationInProgress:!0}),f.next=8,n().setAndInitWasmService();case 8:return e({modulesConfig:o.modulesConfig||{},externalModulesNames:o.includedModules}),f.next=11,n().loadModules();case 11:if(l=f.sent,!l.error){f.next=14;break}return f.abrupt("return",{error:l.error});case 14:return e({_initializationInProgress:!1,_isInitialized:!0}),f.abrupt("return",{});case 16:case"end":return f.stop()}},s)}))()},configureWithUrl:function(o){return j1(ho().mark(function s(){var l;return ho().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(n()._isInitialized){f.next=2;break}return f.abrupt("return",{error:new T1({errorCode:td.INITIALIZATION_REQUIRED})});case 2:if(!n().currentScreenConfig){f.next=4;break}return f.abrupt("return",{error:new T1({errorCode:td.SCENARIO_IN_PROGRESS})});case 4:return f.next=6,n().connectByUrl(o);case 6:if(l=f.sent,!l.error){f.next=9;break}return f.abrupt("return",{error:l.error});case 9:return e({_isConnectedToPlatform:!0}),f.abrupt("return",l.workflows);case 11:case"end":return f.stop()}},s)}))()},configure:function(o){return j1(ho().mark(function s(){var l,d,f,g;return ho().wrap(function(I){for(;;)switch(I.prev=I.next){case 0:if(n()._isInitialized){I.next=2;break}return I.abrupt("return",{error:new T1({errorCode:td.INITIALIZATION_REQUIRED})});case 2:if(!n().currentScreenConfig){I.next=4;break}return I.abrupt("return",{error:new T1({errorCode:td.SCENARIO_IN_PROGRESS})});case 4:if(l=["password","userName","host"],d=l.filter(function(y){return!(o!=null&&o[y])}),!(d.length>0)){I.next=8;break}return I.abrupt("return",{error:new T1({errorCode:td.CONFIG_MISSED_OR_INVALID,message:"Missing parameters: ".concat(d.join(", "))})});case 8:return I.next=10,n().connectToIdv(o);case 10:if(f=I.sent,!f.error){I.next=14;break}return g=new T1({errorCode:td.CONNECTION_ISSUE,underlyingBaseError:f.error}),I.abrupt("return",{error:g});case 14:return e({_isConnectedToPlatform:!0}),I.abrupt("return",{workflows:[]});case 16:case"end":return I.stop()}},s)}))()},getWorkflows:function(){var o=arguments;return j1(ho().mark(function s(){var l,d,f,g,M,I,y;return ho().wrap(function(m){for(;;)switch(m.prev=m.next){case 0:if(l=o.length>0&&o[0]!==void 0?o[0]:{limit:100,skip:0},n()._isInitialized){m.next=4;break}return d=new Wf({errorCode:Qf.INITIALIZATION_REQUIRED}),m.abrupt("return",{error:d});case 4:if(n()._isConnectedToPlatform){m.next=7;break}return f=new Wf({errorCode:Qf.CONNECTION_ISSUE}),m.abrupt("return",{error:f});case 7:return m.next=9,n().wasmService.listWorkflows(l);case 9:if(g=m.sent,M=null,g.code===4&&(M=Bl.HTTP_ISSUE),g.code!==0&&g.code!==4&&(M=Bl.PROVIDER_ERROR),g.code===0&&!g.data.items&&(M=Bl.DECODING_FAILED),M===null){m.next=18;break}return I=new zp({errorCode:M}),y=new Wf({errorCode:Qf.WORKFLOW_ISSUE,message:"No workflow list",underlyingBaseError:I}),m.abrupt("return",{error:y});case 18:return m.abrupt("return",{results:g.data.items});case 19:case"end":return m.stop()}},s)}))()},prepareWorkflowAndPrepareUi:function(o){return j1(ho().mark(function s(){var l,d,f,g,M,I,y,h,m,N,E,A,T,j,C,_,L;return ho().wrap(function(H){for(;;)switch(H.prev=H.next){case 0:if(n()._isInitialized){H.next=3;break}return d=new Wf({errorCode:Qf.INITIALIZATION_REQUIRED}),H.abrupt("return",{error:d});case 3:if(n()._isConnectedToPlatform){H.next=6;break}return f=new Wf({errorCode:Qf.CONNECTION_ISSUE}),H.abrupt("return",{error:f});case 6:if(!n().currentScreenConfig){H.next=9;break}return g=new Wf({errorCode:Qf.SCENARIO_IN_PROGRESS}),H.abrupt("return",{error:g});case 9:return H.next=11,n().wasmService.getWorkflow(o);case 11:if(M=H.sent,I=HD(M.data),y=((l=I.client)===null||l===void 0?void 0:l.steps)&&I.client.steps.some(function(Q){return Q.templateId===zE}),h=null,M.code===4&&(h=Bl.HTTP_ISSUE),M.code!==0&&M.code!==4&&(h=Bl.PROVIDER_ERROR),M.code===0&&!M.data.id&&(h=Bl.DECODING_FAILED),M.data.id&&I===null&&(h=Bl.DECODING_FAILED),y||(h=Bl.DECODING_FAILED),h===null){H.next=24;break}return m=new zp({errorCode:h}),N=new Wf({errorCode:Qf.INTERNAL_ISSUE,underlyingBaseError:m}),H.abrupt("return",{error:N});case 24:return E=n().externalModules,A=I.steps,T=Cme(E,A),j=T.isAllTemplatesSupported,C=T.unsupportedSteps,j||console.log("IDV:: Warning. Unsupported steps found: ",C),_=n().workflowId,_&&o!==_&&E.forEach(function(Q){Q.component.deinitialize()}),L=n().modulesConfig,E.forEach(function(Q){Q.component.isReady()||Q.component.initialize(L)}),n().setLayout(I.client.layout),n().setProcessingTemplate(I.client.steps),n().setWorkflowId(o),H.abrupt("return",{workflow:I});case 36:case"end":return H.stop()}},s)}))()},startNewSession:function(o,s){return j1(ho().mark(function l(){var d,f,g,M,I,y,h,m,N,E,A,T,j,C,_,L,U,H,Q,x,O,w,R,Y,V,q;return ho().wrap(function(z){for(;;)switch(z.prev=z.next){case 0:if(n()._isInitialized){z.next=3;break}return d=new vu({errorCode:hu.INITIALIZATION_REQUIRED}),z.abrupt("return",{error:d});case 3:if(f=n().workflowId,f){z.next=7;break}return g=new vu({errorCode:hu.PREPARED_REQUIRED}),z.abrupt("return",{error:g});case 7:if(!n().currentScreenConfig){z.next=10;break}return M=new vu({errorCode:hu.ALREADY_STARTED}),z.abrupt("return",{error:M});case 10:return n().setIsProcessing(!0),I=function(){var G=j1(ho().mark(function K(){var k,W;return ho().wrap(function(Me){for(;;)switch(Me.prev=Me.next){case 0:return W=(k=n().wasmService)===null||k===void 0?void 0:k.isServiceRunning(),Me.abrupt("return",W||null);case 2:case"end":return Me.stop()}},K)}));return function(){return G.apply(this,arguments)}}(),y=function(){return null},z.next=15,BD(I,y);case 15:if(h=z.sent,h){z.next=19;break}return m=new vu({errorCode:hu.INTERNAL_ISSUE,message:"Service is not running"}),z.abrupt("return",{error:m});case 19:return z.next=21,n().wasmService.getServiceToken();case 21:if(N=z.sent,E=N.data,!(!E||typeof E!="string")){z.next=27;break}return A=new BM({errorCode:UM.TOKEN_ERROR}),T=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:A}),z.abrupt("return",{error:T});case 27:return n().setServiceSessionToken(E),z.next=30,n()._continueSession(o);case 30:if(j=z.sent,!j.error){z.next=33;break}return z.abrupt("return",{error:j.error});case 33:if(!j.isContinue){z.next=35;break}return z.abrupt("return",{});case 35:return z.next=37,n().wasmService.startSession(f,o,s);case 37:if(C=z.sent,!("httpCode"in C.data)){z.next=43;break}return U=typeof((_=C.data)===null||_===void 0?void 0:_.what)=="string"&&C.data.what.length?(L=C.data)===null||L===void 0?void 0:L.what:null,H=new BM(Pp({errorCode:UM.HTTP_ISSUE},U?{message:U}:{})),Q=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:H}),z.abrupt("return",{error:Q});case 43:if(x=C.data,O=x.id,w=x.currentStep,R=x.workflow,Y=O&&w&&R,Y){z.next=49;break}return V=new BM({errorCode:UM.DECODING_FAILED}),q=new vu({errorCode:hu.START_SESSION_ERROR,underlyingBaseError:V}),z.abrupt("return",{error:q});case 49:return n()._prepareDataForWorkflow(C.data),n().setCurrentSessionDataLsAndStore({sessionId:C.data.id,workflowId:f}),n().setIsProcessing(!1),n().setCurrentStepId(w),n().listener({eventType:hp.MESSAGE,message:vp.DID_START_SESSION,module:"IDV"}),z.abrupt("return",{});case 55:case"end":return z.stop()}},l)}))()},playWorkflow:function(o){var s=n().currentStepId;if(n().setWorkflowSessionCompletion(o),s)n().onChangeScreen(s);else{var l=new vu({errorCode:hu.UNKNOWN_STEP});n().workflowSessionCompletion({error:l})}},deinitialize:function(){return j1(ho().mark(function o(){var s,l,d;return ho().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:if(n()._isInitialized){g.next=3;break}return s=new Rp({errorCode:Np.INITIALIZATION_REQUIRED}),g.abrupt("return",{error:s});case 3:if(!n().currentScreenConfig){g.next=6;break}return l=new Rp({errorCode:Np.SCENARIO_IN_PROGRESS}),g.abrupt("return",{error:l});case 6:return g.next=8,n().deinitializationIdv();case 8:return d=g.sent,n().resetProps(),e({_isInitialized:!1}),g.abrupt("return",d);case 12:case"end":return g.stop()}},o)}))()}}},CH={},AH;function tNe(){if(AH)return CH;AH=1;var t=wt(),e=X1().every,n=P4(),a=n("every");return t({target:"Array",proto:!0,forced:!a},{every:function(s){return e(this,s,arguments.length>1?arguments[1]:void 0)}}),CH}tNe();var OH={},qD,_H;function rNe(){if(_H)return qD;_H=1;var t=zM(),e=Ni(),n=Tu(),a=RangeError;return qD=function(s){var l=e(n(this)),d="",f=t(s);if(f<0||f===1/0)throw new a("Wrong number of repetitions");for(;f>0;(f>>>=1)&&(l+=l))f&1&&(d+=l);return d},qD}var JD,xH;function nNe(){if(xH)return JD;xH=1;var t=Mr(),e=k4(),n=Ni(),a=rNe(),o=Tu(),s=t(a),l=t("".slice),d=Math.ceil,f=function(g){return function(M,I,y){var h=n(o(M)),m=e(I),N=h.length,E=y===void 0?" ":n(y),A,T;return m<=N||E===""?h:(A=m-N,T=s(E,d(A/E.length)),T.length>A&&(T=l(T,0,A)),g?h+T:T+h)}};return JD={start:f(!1),end:f(!0)},JD}var XD,wH;function iNe(){if(wH)return XD;wH=1;var t=Mr(),e=dr(),n=nNe().start,a=RangeError,o=isFinite,s=Math.abs,l=Date.prototype,d=l.toISOString,f=t(l.getTime),g=t(l.getUTCDate),M=t(l.getUTCFullYear),I=t(l.getUTCHours),y=t(l.getUTCMilliseconds),h=t(l.getUTCMinutes),m=t(l.getUTCMonth),N=t(l.getUTCSeconds);return XD=e(function(){return d.call(new Date(-50000000000001))!=="0385-07-25T07:06:39.999Z"})||!e(function(){d.call(new Date(NaN))})?function(){if(!o(f(this)))throw new a("Invalid time value");var A=this,T=M(A),j=y(A),C=T<0?"-":T>9999?"+":"";return C+n(s(T),C?6:4,0)+"-"+n(m(A)+1,2,0)+"-"+n(g(A),2,0)+"T"+n(I(A),2,0)+":"+n(h(A),2,0)+":"+n(N(A),2,0)+"."+n(j,3,0)+"Z"}:d,XD}var bH;function aNe(){if(bH)return OH;bH=1;var t=wt(),e=iNe();return t({target:"Date",proto:!0,forced:Date.prototype.toISOString!==e},{toISOString:e}),OH}aNe();var LH={},kH;function oNe(){if(kH)return LH;kH=1;var t=wt(),e=Lr();return t({global:!0,forced:e.globalThis!==e},{globalThis:e}),LH}oNe();var RH={},zH;function uNe(){if(zH)return RH;zH=1;var t=wt(),e=Nz();return t({target:"Math",stat:!0},{trunc:e}),RH}uNe();var PH={},eT,UH;function sNe(){if(UH)return eT;UH=1;var t=Lr(),e=t.isFinite;return eT=Number.isFinite||function(a){return typeof a=="number"&&e(a)},eT}var YH;function lNe(){if(YH)return PH;YH=1;var t=wt(),e=sNe();return t({target:"Number",stat:!0},{isFinite:e}),PH}lNe();var $H={},QH;function cNe(){if(QH)return $H;QH=1;var t=wt();return t({target:"Number",stat:!0},{isNaN:function(n){return n!==n}}),$H}cNe();var FH={},tT,HH;function VH(){if(HH)return tT;HH=1;var t=tn(),e=Mr(),n=yn(),a=dr(),o=lp(),s=Eh(),l=hh(),d=Su(),f=rp(),g=Object.assign,M=Object.defineProperty,I=e([].concat);return tT=!g||a(function(){if(t&&g({b:1},g(M({},"a",{enumerable:!0,get:function(){M(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var y={},h={},m=Symbol("assign detection"),N="abcdefghijklmnopqrst";return y[m]=7,N.split("").forEach(function(E){h[E]=E}),g({},y)[m]!==7||o(g({},h)).join("")!==N})?function(h,m){for(var N=d(h),E=arguments.length,A=1,T=s.f,j=l.f;E>A;)for(var C=f(arguments[A++]),_=T?I(o(C),T(C)):o(C),L=_.length,U=0,H;L>U;)H=_[U++],(!t||n(j,C,H))&&(N[H]=C[H]);return N}:g,tT}var BH;function fNe(){if(BH)return FH;BH=1;var t=wt(),e=VH();return t({target:"Object",stat:!0,arity:2,forced:Object.assign!==e},{assign:e}),FH}fNe();var GH={},rT,ZH;function WH(){if(ZH)return rT;ZH=1;var t=tn(),e=dr(),n=Mr(),a=gp(),o=lp(),s=hl(),l=hh().f,d=n(l),f=n([].push),g=t&&e(function(){var I=Object.create(null);return I[2]=2,!d(I,2)}),M=function(I){return function(y){for(var h=s(y),m=o(h),N=g&&a(h)===null,E=m.length,A=0,T=[],j;E>A;)j=m[A++],(!t||(N?j in h:d(h,j)))&&f(T,I?[j,h[j]]:h[j]);return T}};return rT={entries:M(!0),values:M(!1)},rT}var KH;function dNe(){if(KH)return GH;KH=1;var t=wt(),e=WH().entries;return t({target:"Object",stat:!0},{entries:function(a){return e(a)}}),GH}dNe();var qH={},JH;function gNe(){if(JH)return qH;JH=1;var t=wt(),e=J5(),n=dr(),a=Jn(),o=pp().onFreeze,s=Object.freeze,l=n(function(){s(1)});return t({target:"Object",stat:!0,forced:l,sham:!e},{freeze:function(f){return s&&a(f)?s(o(f)):f}}),qH}gNe();var XH={},eV;function MNe(){if(eV)return XH;eV=1;var t=wt(),e=dr(),n=XN().f,a=e(function(){return!Object.getOwnPropertyNames(1)});return t({target:"Object",stat:!0,forced:a},{getOwnPropertyNames:n}),XH}MNe();var tV={},rV;function pNe(){if(rV)return tV;rV=1;var t=wt(),e=mi();return t({target:"Object",stat:!0},{hasOwn:e}),tV}pNe();var nV={},iV;function INe(){if(iV)return nV;iV=1;var t=wt(),e=WH().values;return t({target:"Object",stat:!0},{values:function(a){return e(a)}}),nV}INe();var aV={},nT,oV;function yNe(){if(oV)return nT;oV=1;var t=Lr(),e=dr(),n=Mr(),a=Ni(),o=Ah().trim,s=Ch(),l=n("".charAt),d=t.parseFloat,f=t.Symbol,g=f&&f.iterator,M=1/d(s+"-0")!==-1/0||g&&!e(function(){d(Object(g))});return nT=M?function(y){var h=o(a(y)),m=d(h);return m===0&&l(h,0)==="-"?-0:m}:d,nT}var uV;function hNe(){if(uV)return aV;uV=1;var t=wt(),e=yNe();return t({global:!0,forced:parseFloat!==e},{parseFloat:e}),aV}hNe();var sV={},iT,lV;function vNe(){if(lV)return iT;lV=1;var t=Lr(),e=dr(),n=Mr(),a=Ni(),o=Ah().trim,s=Ch(),l=t.parseInt,d=t.Symbol,f=d&&d.iterator,g=/^[+-]?0x/i,M=n(g.exec),I=l(s+"08")!==8||l(s+"0x16")!==22||f&&!e(function(){l(Object(f))});return iT=I?function(h,m){var N=o(a(h));return l(N,m>>>0||(M(g,N)?16:10))}:l,iT}var cV;function mNe(){if(cV)return sV;cV=1;var t=wt(),e=vNe();return t({global:!0,forced:parseInt!==e},{parseInt:e}),sV}mNe();var fV={},dV;function NNe(){if(dV)return fV;dV=1;var t=wt(),e=ed(),n=yo(),a=_n(),o=dr(),s=!o(function(){Reflect.apply(function(){})});return t({target:"Reflect",stat:!0,forced:s},{apply:function(d,f,g){return e(n(d),f,a(g))}}),fV}NNe();var gV={},MV;function ENe(){if(MV)return gV;MV=1;var t=wt(),e=Lr(),n=vl();return t({global:!0},{Reflect:{}}),n(e.Reflect,"Reflect",!0),gV}ENe();var pV={},IV;function DNe(){if(IV)return pV;IV=1;var t=tn(),e=Lr(),n=Mr(),a=up(),o=Th(),s=Hl(),l=Vl(),d=R4().f,f=N1(),g=Q$(),M=Ni(),I=hY(),y=wh(),h=UP(),m=Ra(),N=dr(),E=mi(),A=Au().enforce,T=dE(),j=Zn(),C=BE(),_=M$(),L=j("match"),U=e.RegExp,H=U.prototype,Q=e.SyntaxError,x=n(H.exec),O=n("".charAt),w=n("".replace),R=n("".indexOf),Y=n("".slice),V=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,q=/a/g,te=/a/g,z=new U(q)!==q,G=y.MISSED_STICKY,K=y.UNSUPPORTED_Y,k=t&&(!z||G||C||_||N(function(){return te[L]=!1,U(q)!==q||U(te)===te||String(U(q,"i"))!=="/a/i"})),W=function(Pe){for(var me=Pe.length,Le=0,Ze="",Xe=!1,tt;Le<=me;Le++){if(tt=O(Pe,Le),tt==="\\"){Ze+=tt+O(Pe,++Le);continue}!Xe&&tt==="."?Ze+="[\\s\\S]":(tt==="["?Xe=!0:tt==="]"&&(Xe=!1),Ze+=tt)}return Ze},pe=function(Pe){for(var me=Pe.length,Le=0,Ze="",Xe=[],tt=l(null),ct=!1,Dt=!1,Et=0,vt="",Je;Le<=me;Le++){if(Je=O(Pe,Le),Je==="\\")Je+=O(Pe,++Le);else if(Je==="]")ct=!1;else if(!ct)switch(!0){case Je==="[":ct=!0;break;case Je==="(":if(Ze+=Je,Y(Pe,Le+1,Le+3)==="?:")continue;x(V,Y(Pe,Le+1))&&(Le+=2,Dt=!0),Et++;continue;case(Je===">"&&Dt):if(vt===""||E(tt,vt))throw new Q("Invalid capture group name");tt[vt]=!0,Xe[Xe.length]=[vt,Et],Dt=!1,vt="";continue}Dt?vt+=Je:Ze+=Je}return[Ze,Xe]};if(a("RegExp",k)){for(var Me=function(me,Le){var Ze=f(H,this),Xe=g(me),tt=Le===void 0,ct=[],Dt=me,Et,vt,Je,dt,pt,Ke;if(!Ze&&Xe&&tt&&me.constructor===Me)return me;if((Xe||f(H,me))&&(me=me.source,tt&&(Le=I(Dt))),me=me===void 0?"":M(me),Le=Le===void 0?"":M(Le),Dt=me,C&&"dotAll"in q&&(vt=!!Le&&R(Le,"s")>-1,vt&&(Le=w(Le,/s/g,""))),Et=Le,G&&"sticky"in q&&(Je=!!Le&&R(Le,"y")>-1,Je&&K&&(Le=w(Le,/y/g,""))),_&&(dt=pe(me),me=dt[0],ct=dt[1]),pt=o(U(me,Le),Ze?this:H,Me),(vt||Je||ct.length)&&(Ke=A(pt),vt&&(Ke.dotAll=!0,Ke.raw=Me(W(me),Et)),Je&&(Ke.sticky=!0),ct.length&&(Ke.groups=ct)),me!==Dt)try{s(pt,"source",Dt===""?"(?:)":Dt)}catch(Ce){}return pt},le=d(U),Oe=0;le.length>Oe;)h(Me,U,le[Oe++]);H.constructor=Me,Me.prototype=H,m(e,"RegExp",Me,{constructor:!0})}return T("RegExp"),pV}DNe();var yV={},hV;function TNe(){if(hV)return yV;hV=1;var t=tn(),e=BE(),n=yl(),a=Uu(),o=Au().get,s=RegExp.prototype,l=TypeError;return t&&e&&a(s,"dotAll",{configurable:!0,get:function(){if(this!==s){if(n(this)==="RegExp")return!!o(this).dotAll;throw new l("Incompatible receiver, RegExp required")}}}),yV}TNe();var vV={},mV;function jNe(){if(mV)return vV;mV=1;var t=Lr(),e=tn(),n=Uu(),a=mE(),o=dr(),s=t.RegExp,l=s.prototype,d=e&&o(function(){var f=!0;try{s(".","d")}catch(E){f=!1}var g={},M="",I=f?"dgimsy":"gimsy",y=function(E,A){Object.defineProperty(g,E,{get:function(){return M+=A,!0}})},h={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};f&&(h.hasIndices="d");for(var m in h)y(m,h[m]);var N=Object.getOwnPropertyDescriptor(l,"flags").get.call(g);return N!==I||M!==I});return d&&n(l,"flags",{configurable:!0,get:a}),vV}jNe();var NV={},EV;function SNe(){if(EV)return NV;EV=1;var t=tn(),e=wh().MISSED_STICKY,n=yl(),a=Uu(),o=Au().get,s=RegExp.prototype,l=TypeError;return t&&e&&a(s,"sticky",{configurable:!0,get:function(){if(this!==s){if(n(this)==="RegExp")return!!o(this).sticky;throw new l("Incompatible receiver, RegExp required")}}}),NV}SNe();var DV={},aT,TV;function Ph(){if(TV)return aT;TV=1,KE();var t=yn(),e=Ra(),n=WE(),a=dr(),o=Zn(),s=Hl(),l=o("species"),d=RegExp.prototype;return aT=function(f,g,M,I){var y=o(f),h=!a(function(){var A={};return A[y]=function(){return 7},""[f](A)!==7}),m=h&&!a(function(){var A=!1,T=/a/;return f==="split"&&(T={},T.constructor={},T.constructor[l]=function(){return T},T.flags="",T[y]=/./[y]),T.exec=function(){return A=!0,null},T[y](""),!A});if(!h||!m||M){var N=/./[y],E=g(y,""[f],function(A,T,j,C,_){var L=T.exec;return L===n||L===d.exec?h&&!_?{done:!0,value:t(N,T,j,C)}:{done:!0,value:t(A,j,T,C)}:{done:!1}});e(String.prototype,f,E[0]),e(d,y,E[1])}I&&s(d[y],"sham",!0)},aT}var oT,jV;function uT(){if(jV)return oT;jV=1;var t=DE().charAt;return oT=function(e,n,a){return n+(a?t(e,n).length:1)},oT}var sT,SV;function Uh(){if(SV)return sT;SV=1;var t=yn(),e=_n(),n=qn(),a=yl(),o=WE(),s=TypeError;return sT=function(l,d){var f=l.exec;if(n(f)){var g=t(f,l,d);return g!==null&&e(g),g}if(a(l)==="RegExp")return t(o,l,d);throw new s("RegExp#exec called on incompatible receiver")},sT}var CV;function CNe(){if(CV)return DV;CV=1;var t=yn(),e=Ph(),n=_n(),a=Jn(),o=k4(),s=Ni(),l=Tu(),d=K1(),f=uT(),g=Uh();return e("match",function(M,I,y){return[function(m){var N=l(this),E=a(m)?d(m,M):void 0;return E?t(E,m,N):new RegExp(m)[M](s(N))},function(h){var m=n(this),N=s(h),E=y(I,m,N);if(E.done)return E.value;if(!m.global)return g(m,N);var A=m.unicode;m.lastIndex=0;for(var T=[],j=0,C;(C=g(m,N))!==null;){var _=s(C[0]);T[j]=_,_===""&&(m.lastIndex=f(N,o(m.lastIndex),A)),j++}return j===0?null:T}]}),DV}CNe();var AV={},lT,OV;function ANe(){if(OV)return lT;OV=1;var t=Mr(),e=Su(),n=Math.floor,a=t("".charAt),o=t("".replace),s=t("".slice),l=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,d=/\$([$&'`]|\d{1,2})/g;return lT=function(f,g,M,I,y,h){var m=M+f.length,N=I.length,E=d;return y!==void 0&&(y=e(y),E=l),o(h,E,function(A,T){var j;switch(a(T,0)){case"$":return"$";case"&":return f;case"`":return s(g,0,M);case"'":return s(g,m);case"<":j=y[s(T,1,-1)];break;default:var C=+T;if(C===0)return A;if(C>N){var _=n(C/10);return _===0?A:_<=N?I[_-1]===void 0?a(T,1):I[_-1]+a(T,1):A}j=I[C-1]}return j===void 0?"":j})},lT}var _V;function ONe(){if(_V)return AV;_V=1;var t=ed(),e=yn(),n=Mr(),a=Ph(),o=dr(),s=_n(),l=qn(),d=Jn(),f=zM(),g=k4(),M=Ni(),I=Tu(),y=uT(),h=K1(),m=ANe(),N=Uh(),E=Zn(),A=E("replace"),T=Math.max,j=Math.min,C=n([].concat),_=n([].push),L=n("".indexOf),U=n("".slice),H=function(w){return w===void 0?w:String(w)},Q=function(){return"a".replace(/./,"$0")==="$0"}(),x=function(){return/./[A]?/./[A]("a","$0")==="":!1}(),O=!o(function(){var w=/./;return w.exec=function(){var R=[];return R.groups={a:"7"},R},"".replace(w,"$<a>")!=="7"});return a("replace",function(w,R,Y){var V=x?"$":"$0";return[function(te,z){var G=I(this),K=d(te)?h(te,A):void 0;return K?e(K,te,G,z):e(R,M(G),te,z)},function(q,te){var z=s(this),G=M(q);if(typeof te=="string"&&L(te,V)===-1&&L(te,"$<")===-1){var K=Y(R,z,G,te);if(K.done)return K.value}var k=l(te);k||(te=M(te));var W=z.global,pe;W&&(pe=z.unicode,z.lastIndex=0);for(var Me=[],le;le=N(z,G),!(le===null||(_(Me,le),!W));){var Oe=M(le[0]);Oe===""&&(z.lastIndex=y(G,g(z.lastIndex),pe))}for(var Pe="",me=0,Le=0;Le<Me.length;Le++){le=Me[Le];for(var Ze=M(le[0]),Xe=T(j(f(le.index),G.length),0),tt=[],ct,Dt=1;Dt<le.length;Dt++)_(tt,H(le[Dt]));var Et=le.groups;if(k){var vt=C([Ze],tt,Xe,G);Et!==void 0&&_(vt,Et),ct=M(t(te,void 0,vt))}else ct=m(Ze,G,Xe,tt,Et,te);Xe>=me&&(Pe+=U(G,me,Xe)+ct,me=Xe+Ze.length)}return Pe+U(G,me)}]},!O||!Q||x),AV}ONe();var xV={},cT,wV;function _Ne(){return wV||(wV=1,cT=Object.is||function(e,n){return e===n?e!==0||1/e===1/n:e!==e&&n!==n}),cT}var bV;function xNe(){if(bV)return xV;bV=1;var t=yn(),e=Ph(),n=_n(),a=Jn(),o=Tu(),s=_Ne(),l=Ni(),d=K1(),f=Uh();return e("search",function(g,M,I){return[function(h){var m=o(this),N=a(h)?d(h,g):void 0;return N?t(N,h,m):new RegExp(h)[g](l(m))},function(y){var h=n(this),m=l(y),N=I(M,h,m);if(N.done)return N.value;var E=h.lastIndex;s(E,0)||(h.lastIndex=0);var A=f(h,m);return s(h.lastIndex,E)||(h.lastIndex=E),A===null?-1:A.index}]}),xV}xNe();var LV={},kV;function wNe(){if(kV)return LV;kV=1;var t=yn(),e=Mr(),n=Ph(),a=_n(),o=Jn(),s=Tu(),l=YQ(),d=uT(),f=k4(),g=Ni(),M=K1(),I=Uh(),y=wh(),h=dr(),m=y.UNSUPPORTED_Y,N=4294967295,E=Math.min,A=e([].push),T=e("".slice),j=!h(function(){var _=/(?:)/,L=_.exec;_.exec=function(){return L.apply(this,arguments)};var U="ab".split(_);return U.length!==2||U[0]!=="a"||U[1]!=="b"}),C="abbc".split(/(b)*/)[1]==="c"||"test".split(/(?:)/,-1).length!==4||"ab".split(/(?:ab)*/).length!==2||".".split(/(.?)(.?)/).length!==4||".".split(/()()/).length>1||"".split(/.?/).length;return n("split",function(_,L,U){var H="0".split(void 0,0).length?function(Q,x){return Q===void 0&&x===0?[]:t(L,this,Q,x)}:L;return[function(x,O){var w=s(this),R=o(x)?M(x,_):void 0;return R?t(R,x,w,O):t(H,g(w),x,O)},function(Q,x){var O=a(this),w=g(Q);if(!C){var R=U(H,O,w,x,H!==L);if(R.done)return R.value}var Y=l(O,RegExp),V=O.unicode,q=(O.ignoreCase?"i":"")+(O.multiline?"m":"")+(O.unicode?"u":"")+(m?"g":"y"),te=new Y(m?"^(?:"+O.source+")":O,q),z=x===void 0?N:x>>>0;if(z===0)return[];if(w.length===0)return I(te,w)===null?[w]:[];for(var G=0,K=0,k=[];K<w.length;){te.lastIndex=m?0:K;var W=I(te,m?T(w,K):w),pe;if(W===null||(pe=E(f(te.lastIndex+(m?K:0)),w.length))===G)K=d(w,K,V);else{if(A(k,T(w,G,K)),k.length===z)return k;for(var Me=1;Me<=W.length-1;Me++)if(A(k,W[Me]),k.length===z)return k;K=G=pe}}return A(k,T(w,G)),k}]},C||!j,m),LV}wNe();var RV={},zV;function bNe(){if(zV)return RV;zV=1;var t=wt(),e=u5(),n=RM().f,a=k4(),o=Ni(),s=H$(),l=Tu(),d=B$(),f=yu(),g=e("".slice),M=Math.min,I=d("startsWith"),y=!f&&!I&&!!function(){var h=n(String.prototype,"startsWith");return h&&!h.writable}();return t({target:"String",proto:!0,forced:!y&&!I},{startsWith:function(m){var N=o(l(this));s(m);var E=a(M(arguments.length>1?arguments[1]:void 0,N.length)),A=o(m);return g(N,E,E+A.length)===A}}),RV}bNe();var PV={},UV;function LNe(){if(UV)return PV;UV=1;var t=wt(),e=Mr(),n=Tu(),a=zM(),o=Ni(),s=e("".slice),l=Math.max,d=Math.min,f=!"".substr||"ab".substr(-1)!=="b";return t({target:"String",proto:!0,forced:f},{substr:function(M,I){var y=o(n(this)),h=y.length,m=a(M),N,E;return m===1/0&&(m=0),m<0&&(m=l(h+m,0)),N=I===void 0?h:a(I),N<=0||N===1/0?"":(E=d(m+N,h),m>=E?"":s(y,m,E))}}),PV}LNe();var YV={},$V={},fT,QV;function kNe(){if(QV)return fT;QV=1;var t=Mr(),e=Ip(),n=pp().getWeakData,a=PM(),o=_n(),s=kM(),l=Jn(),d=$f(),f=X1(),g=mi(),M=Au(),I=M.set,y=M.getterFor,h=f.find,m=f.findIndex,N=t([].splice),E=0,A=function(C){return C.frozen||(C.frozen=new T)},T=function(){this.entries=[]},j=function(C,_){return h(C.entries,function(L){return L[0]===_})};return T.prototype={get:function(C){var _=j(this,C);if(_)return _[1]},has:function(C){return!!j(this,C)},set:function(C,_){var L=j(this,C);L?L[1]=_:this.entries.push([C,_])},delete:function(C){var _=m(this.entries,function(L){return L[0]===C});return~_&&N(this.entries,_,1),!!~_}},fT={getConstructor:function(C,_,L,U){var H=C(function(w,R){a(w,Q),I(w,{type:_,id:E++,frozen:null}),s(R)||d(R,w[U],{that:w,AS_ENTRIES:L})}),Q=H.prototype,x=y(_),O=function(w,R,Y){var V=x(w),q=n(o(R),!0);return q===!0?A(V).set(R,Y):q[V.id]=Y,w};return e(Q,{delete:function(w){var R=x(this);if(!l(w))return!1;var Y=n(w);return Y===!0?A(R).delete(w):Y&&g(Y,R.id)&&delete Y[R.id]},has:function(R){var Y=x(this);if(!l(R))return!1;var V=n(R);return V===!0?A(Y).has(R):V&&g(V,Y.id)}}),e(Q,L?{get:function(R){var Y=x(this);if(l(R)){var V=n(R);if(V===!0)return A(Y).get(R);if(V)return V[Y.id]}},set:function(R,Y){return O(this,R,Y)}}:{add:function(R){return O(this,R,!0)}}),H}},fT}var FV;function RNe(){if(FV)return $V;FV=1;var t=J5(),e=Lr(),n=Mr(),a=Ip(),o=pp(),s=lE(),l=kNe(),d=Jn(),f=Au().enforce,g=dr(),M=gz(),I=Object,y=Array.isArray,h=I.isExtensible,m=I.isFrozen,N=I.isSealed,E=I.freeze,A=I.seal,T=!e.ActiveXObject&&"ActiveXObject"in e,j,C=function(w){return function(){return w(this,arguments.length?arguments[0]:void 0)}},_=s("WeakMap",C,l),L=_.prototype,U=n(L.set),H=function(){return t&&g(function(){var w=E([]);return U(new _,w,1),!m(w)})};if(M)if(T){j=l.getConstructor(C,"WeakMap",!0),o.enable();var Q=n(L.delete),x=n(L.has),O=n(L.get);a(L,{delete:function(w){if(d(w)&&!h(w)){var R=f(this);return R.frozen||(R.frozen=new j),Q(this,w)||R.frozen.delete(w)}return Q(this,w)},has:function(R){if(d(R)&&!h(R)){var Y=f(this);return Y.frozen||(Y.frozen=new j),x(this,R)||Y.frozen.has(R)}return x(this,R)},get:function(R){if(d(R)&&!h(R)){var Y=f(this);return Y.frozen||(Y.frozen=new j),x(this,R)?O(this,R):Y.frozen.get(R)}return O(this,R)},set:function(R,Y){if(d(R)&&!h(R)){var V=f(this);V.frozen||(V.frozen=new j),x(this,R)?U(this,R,Y):V.frozen.set(R,Y)}else U(this,R,Y);return this}})}else H()&&a(L,{set:function(R,Y){var V;return y(R)&&(m(R)?V=E:N(R)&&(V=A)),U(this,R,Y),V&&V(R),this}});return $V}var HV;function zNe(){return HV||(HV=1,RNe()),YV}zNe();var VV={},BV={},GV;function PNe(){if(GV)return BV;GV=1;var t=wt(),e=yn(),n=$f(),a=yo(),o=_n(),s=rd(),l=ml(),d=$M(),f=d("every",TypeError);return t({target:"Iterator",proto:!0,real:!0,forced:f},{every:function(M){o(this);try{a(M)}catch(h){l(this,"throw",h)}if(f)return e(f,this,M);var I=s(this),y=0;return!n(I,function(h,m){if(!M(h,y++))return m()},{IS_RECORD:!0,INTERRUPTED:!0}).stopped}}),BV}var ZV;function UNe(){return ZV||(ZV=1,PNe()),VV}UNe();var WV={},KV;function YNe(){if(KV)return WV;KV=1;var t=wt(),e=Lr(),n=Uu(),a=tn(),o=TypeError,s=Object.defineProperty,l=e.self!==e;try{if(a){var d=Object.getOwnPropertyDescriptor(e,"self");(l||!d||!d.get||!d.enumerable)&&n(e,"self",{get:function(){return e},set:function(g){if(this!==e)throw new o("Illegal invocation");s(e,"self",{value:g,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})}else t({global:!0,simple:!0,forced:l},{self:e})}catch(f){}return WV}YNe();var $Ne=GY();function Sa(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */Sa=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&ni(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(ni(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function Kf(t){return HNe(t)||FNe(t)||gT(t)||QNe()}function QNe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
48
48
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function FNe(t){if(typeof Symbol!="undefined"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function HNe(t){if(Array.isArray(t))return MT(t)}function dT(t,e,n){return(e=VNe(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function VNe(t){var e=BNe(t,"string");return ni(e)=="symbol"?e:e+""}function BNe(t,e){if(ni(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(ni(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Yh(t,e){return WNe(t)||ZNe(t,e)||gT(t,e)||GNe()}function GNe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
49
49
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ZNe(t,e){var n=t==null?null:typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a,o,s,l,d=[],f=!0,g=!1;try{if(s=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;f=!1}else for(;!(f=(a=s.call(n)).done)&&(d.push(a.value),d.length!==e);f=!0);}catch(M){g=!0,o=M}finally{try{if(!f&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(g)throw o}}return d}}function WNe(t){if(Array.isArray(t))return t}function ni(t){"@babel/helpers - typeof";return ni=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ni(t)}function Gl(t,e){var n=typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=gT(t))||e){n&&(t=n);var a=0,o=function(){};return{s:o,n:function(){return a>=t.length?{done:!0}:{done:!1,value:t[a++]}},e:function(g){throw g},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
50
50
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var s,l=!0,d=!1;return{s:function(){n=n.call(t)},n:function(){var g=n.next();return l=g.done,g},e:function(g){d=!0,s=g},f:function(){try{l||n.return==null||n.return()}finally{if(d)throw s}}}}function gT(t,e){if(t){if(typeof t=="string")return MT(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?MT(t,e):void 0}}function MT(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}var KNe=Object.defineProperty,qNe=Object.defineProperties,JNe=Object.getOwnPropertyDescriptors,$h=Object.getOwnPropertySymbols,qV=Object.prototype.hasOwnProperty,JV=Object.prototype.propertyIsEnumerable,XV=function(e,n,a){return n in e?KNe(e,n,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[n]=a},Tt=function(e,n){for(var a in n||(n={}))qV.call(n,a)&&XV(e,a,n[a]);if($h){var o=Gl($h(n)),s;try{for(o.s();!(s=o.n()).done;){var a=s.value;JV.call(n,a)&&XV(e,a,n[a])}}catch(l){o.e(l)}finally{o.f()}}return e},xn=function(e,n){return qNe(e,JNe(n))},Qh=function(e,n){var a={};for(var o in e)qV.call(e,o)&&n.indexOf(o)<0&&(a[o]=e[o]);if(e!=null&&$h){var s=Gl($h(e)),l;try{for(s.s();!(l=s.n()).done;){var o=l.value;n.indexOf(o)<0&&JV.call(e,o)&&(a[o]=e[o])}}catch(d){s.e(d)}finally{s.f()}}return a},S1=function(e,n,a){return new Promise(function(o,s){var l=function(M){try{f(a.next(M))}catch(I){s(I)}},d=function(M){try{f(a.throw(M))}catch(I){s(I)}},f=function(M){return M.done?o(M.value):Promise.resolve(M.value).then(l,d)};f((a=a.apply(e,n)).next())})},eB=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},tB={exports:{}},Up={};/**
|
|
@@ -82,7 +82,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
82
82
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TOe(t,e){if(t){if(typeof t=="string")return _ee(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_ee(t,e):void 0}}function _ee(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}function jOe(t,e){var n=t==null?null:typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a,o,s,l,d=[],f=!0,g=!1;try{if(s=(n=n.call(t)).next,e!==0)for(;!(f=(a=s.call(n)).done)&&(d.push(a.value),d.length!==e);f=!0);}catch(M){g=!0,o=M}finally{try{if(!f&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(g)throw o}}return d}}function SOe(t){if(Array.isArray(t))return t}var COe=function(e){var n=e.option,a=e.layout,o=e.dataSourceQuestion,s=e.register,l=e.watch,d=ht.useState(!1),f=EOe(d,2),g=f[0],M=f[1],I=Tee(),y=String(o.id),h=l(y),m=h===String(n.id),N=a.option,E=a.optionSelected,A={borderRadius:N.cornerRadius,background:Br(N.backgroundColor),borderColor:Br(N.borderColor),borderWidth:N.borderWidth},T={borderRadius:E.cornerRadius,background:Br(E.backgroundColor),borderColor:Br(E.borderColor),borderWidth:E.borderWidth},j=g&&I?{outline:"2px solid ".concat(e2)}:{};return ne.jsx("div",{style:{display:"flex",flexGrow:1},children:ne.jsxs("label",{style:Oee(Oee({width:"100%",padding:"8px 16px",cursor:"pointer",borderStyle:"solid",position:"relative"},m?T:A),j),children:[ne.jsx("input",xn(Tt({style:{width:1,height:1,opacity:0,position:"absolute",left:"50%"}},s(y,{required:!!o.required,validate:e0(o.validators,!!o.required)})),{value:n.id,type:"radio",onFocus:function(){return M(!0)},onBlur:function(){return M(!1)}})),ne.jsx(Ou,xn(Tt({},m?E.title:N.title),{text:n.text}))]})},n.id)},AOe=function(e){var n=e.layout,a=e.watch,o=e.register,s=e.dataSourceQuestion;return ne.jsx("div",{style:{boxSizing:"border-box"},children:ne.jsxs("fieldset",{style:{margin:0,padding:0,border:"none"},children:[n.title&&ne.jsx("legend",{style:{margin:0,padding:0,marginBottom:"16px"},children:ne.jsx(Ou,xn(Tt({},n.title),{text:s.text}))}),ne.jsx("div",{style:{display:"flex",justifyContent:"center",gap:5},children:s.options.map(function(l){return ne.jsx(COe,{register:o,watch:a,layout:n,option:l,dataSourceQuestion:s},l.id)})})]})})};function C2(t){"@babel/helpers - typeof";return C2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},C2(t)}function xee(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function cA(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?xee(Object(n),!0).forEach(function(a){OOe(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):xee(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function OOe(t,e,n){return(e=_Oe(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function _Oe(t){var e=xOe(t,"string");return C2(e)=="symbol"?e:e+""}function xOe(t,e){if(C2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(C2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var wOe=function(e){var n=e.children,a=e.backgroundColor,o=e.cornerRadius,s=o===void 0?0:o,l=e.isError,d=e.isRequired,f=e.validationBorderColor,g=e.validationBorderWidth,M=cA({position:"relative",flexShrink:0,width:"100%",fontWeight:300,lineHeight:"140%",backgroundColor:Br(a)||"transparent",borderRadius:s,padding:"16px",boxSizing:"border-box",height:"auto"},l&&cA(cA({},Br(f)&&{borderColor:f,borderStyle:"solid"}),g&&{borderWidth:g}));return ne.jsxs("div",{style:M,children:[d&&ne.jsx("span",{style:{color:Br(f),position:"absolute",left:"6px",top:"18px"},children:"*"}),n]})};function bOe(t,e){return zOe(t)||ROe(t,e)||kOe(t,e)||LOe()}function LOe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
83
83
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function kOe(t,e){if(t){if(typeof t=="string")return wee(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?wee(t,e):void 0}}function wee(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}function ROe(t,e){var n=t==null?null:typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a,o,s,l,d=[],f=!0,g=!1;try{if(s=(n=n.call(t)).next,e!==0)for(;!(f=(a=s.call(n)).done)&&(d.push(a.value),d.length!==e);f=!0);}catch(M){g=!0,o=M}finally{try{if(!f&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(g)throw o}}return d}}function zOe(t){if(Array.isArray(t))return t}var POe=function(e){var n=e.validationErrorsTypes,a=e.title;return n?ne.jsx("div",{style:{width:"100%",fontSize:12},children:Object.entries(n).map(function(o){var s=bOe(o,2),l=s[0],d=s[1];return ne.jsx(Ou,xn(Tt({},a),{text:d}),l)})}):null},UOe=function(e){var n,a,o,s,l,d,f,g,M,I,y,h,m,N,E=e.layout,A=e.dataSourceQuestion,T=e.register,j=String(A.id),C=function(L){return L?L===rv.EMAIL?"email":L===rv.FREE_TEXT?"text":L===rv.NUMBER?"number":L===rv.SECURE?"password":"text":"text"};return ne.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:"16px"},children:[ne.jsx(Ou,xn(Tt({},E.title),{text:A.text,htmlFor:j})),ne.jsx("input",xn(Tt({},T(j,{required:!!A.required,validate:e0(A.validators,!!A.required)})),{id:j,type:C((n=E.textField)===null||n===void 0?void 0:n.inputType),style:{fontFamily:(a=E==null||(o=E.textField)===null||o===void 0?void 0:o.fontName)!==null&&a!==void 0?a:"sans-serif",fontSize:(s=E==null||(l=E.textField)===null||l===void 0?void 0:l.fontSize)!==null&&s!==void 0?s:15,color:(d=Br(E==null||(f=E.textField)===null||f===void 0?void 0:f.fontColor))!==null&&d!==void 0?d:"#000000",height:"42px",borderWidth:(g=E==null||(M=E.textField)===null||M===void 0?void 0:M.borderWidth)!==null&&g!==void 0?g:1,borderColor:(I=Br(E==null||(y=E.textField)===null||y===void 0?void 0:y.borderColor))!==null&&I!==void 0?I:"#d9d9d9",borderStyle:"solid",borderRadius:(h=E==null||(m=E.textField)===null||m===void 0?void 0:m.cornerRadius)!==null&&h!==void 0?h:8,padding:"11px",boxSizing:"border-box",outlineColor:e2},placeholder:(N=A.placeholder)!==null&&N!==void 0?N:"","data-id":j}))]})},YOe=function(e){var n,a,o,s,l,d,f,g,M,I,y,h=e.layout,m=e.dataSourceQuestion,N=e.register,E=String(m.id);return ne.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:"16px"},children:[ne.jsx(Ou,xn(Tt({},h.title),{text:m.text,htmlFor:E})),ne.jsx("textarea",xn(Tt({},N(E,{required:!!m.required,validate:e0(m.validators,!!m.required)})),{id:E,placeholder:(n=m.placeholder)!==null&&n!==void 0?n:"",onChange:function(T){T.target.style.height="auto",T.target.style.height="".concat(T.target.scrollHeight-15,"px")},"data-id":E,style:{fontFamily:"sans-serif",fontSize:(a=h==null||(o=h.textField)===null||o===void 0?void 0:o.fontSize)!==null&&a!==void 0?a:15,color:(s=Br(h==null||(l=h.textField)===null||l===void 0?void 0:l.fontColor))!==null&&s!==void 0?s:"#000000",resize:"none",overflow:"hidden",height:"42px",minHeight:"42px",borderWidth:(d=h==null||(f=h.textField)===null||f===void 0?void 0:f.borderWidth)!==null&&d!==void 0?d:1,borderColor:(g=Br(h==null||(M=h.textField)===null||M===void 0?void 0:M.borderColor))!==null&&g!==void 0?g:"#d9d9d9",borderStyle:"solid",borderRadius:(I=h==null||(y=h.textField)===null||y===void 0?void 0:y.cornerRadius)!==null&&I!==void 0?I:8,padding:"11px",boxSizing:"border-box",outlineColor:e2}}))]})},bee={},fA,Lee;function kee(){if(Lee)return fA;Lee=1;var t=ei(),e=Wl(),n=Oo(),a=Ca(),o=Zp(),s=$p(),l=Function,d=t([].concat),f=t([].join),g={},M=function(y,h,m){if(!a(g,h)){for(var N=[],E=0;E<h;E++)N[E]="a["+E+"]";g[h]=l("C,a","return new C("+f(N,",")+")")}return g[h](y,m)};return fA=s?l.bind:function(I){var y=e(this),h=y.prototype,m=o(arguments,1),N=function(){var A=d(m,o(arguments));return this instanceof N?M(y,A.length,A):y.apply(I,A)};return n(h)&&(N.prototype=h),N},fA}var Ree;function $Oe(){if(Ree)return bee;Ree=1;var t=kr(),e=kee();return t({target:"Function",proto:!0,forced:Function.bind!==e},{bind:e}),bee}$Oe();var zee={},Pee;function QOe(){if(Pee)return zee;Pee=1;var t=kr(),e=ii(),n=O1();return t({target:"Object",stat:!0,sham:!e},{create:n}),zee}QOe();var Uee={},Yee;function FOe(){if(Yee)return Uee;Yee=1;var t=kr(),e=pn(),n=El(),a=Bp(),o=bG(),s=e(function(){a(1)});return t({target:"Object",stat:!0,forced:s,sham:!o},{getPrototypeOf:function(d){return a(n(d))}}),Uee}FOe();var $ee={},Qee;function HOe(){if(Qee)return $ee;Qee=1;var t=ii(),e=id(),n=Oo(),a=FG(),o=El(),s=ZM(),l=Object.getPrototypeOf,d=Object.setPrototypeOf,f=Object.prototype,g="__proto__";if(t&&l&&d&&!(g in f))try{e(f,g,{configurable:!0,get:function(){return l(o(this))},set:function(I){var y=s(this);a(I)&&n(y)&&d(y,I)}})}catch(M){}return $ee}HOe();var Fee={},Hee;function VOe(){if(Hee)return Fee;Hee=1;var t=kr(),e=Zh();return t({target:"Object",stat:!0},{setPrototypeOf:e}),Fee}VOe();var Vee={},dA,Bee;function BOe(){if(Bee)return dA;Bee=1;var t=qh(),e=Fp(),n=TypeError;return dA=function(o){if(t(o))return o;throw new n(e(o)+" is not a constructor")},dA}var Gee;function GOe(){if(Gee)return Vee;Gee=1;var t=kr(),e=Jf(),n=Gp(),a=kee(),o=BOe(),s=Aa(),l=Oo(),d=O1(),f=pn(),g=e("Reflect","construct"),M=Object.prototype,I=[].push,y=f(function(){function N(){}return!(g(function(){},[],N)instanceof N)}),h=!f(function(){g(function(){})}),m=y||h;return t({target:"Reflect",stat:!0,forced:m,sham:m},{construct:function(E,A){o(E),s(A);var T=arguments.length<3?E:o(arguments[2]);if(h&&!y)return g(E,A,T);if(E===T){switch(A.length){case 0:return new E;case 1:return new E(A[0]);case 2:return new E(A[0],A[1]);case 3:return new E(A[0],A[1],A[2]);case 4:return new E(A[0],A[1],A[2],A[3])}var j=[null];return n(I,j,A),new(n(a,E,j))}var C=T.prototype,_=d(l(C)?C:M),L=n(E,_,A);return l(L)?L:_}}),Vee}GOe();var Zee={},Wee;function ZOe(){if(Wee)return Zee;Wee=1;var t=kr(),e=pn(),n=B4(),a=Oo(),o=El(),s=nd(),l=CW(),d=qp(),f=bZ(),g=Xh(),M=Qi(),I=Fh(),y=M("isConcatSpreadable"),h=I>=51||!e(function(){var E=[];return E[y]=!1,E.concat()[0]!==E}),m=function(A){if(!a(A))return!1;var T=A[y];return T!==void 0?!!T:n(A)},N=!h||!g("concat");return t({target:"Array",proto:!0,arity:1,forced:N},{concat:function(A){var T=o(this),j=f(T,0),C=0,_,L,U,H,Q;for(_=-1,U=arguments.length;_<U;_++)if(Q=_===-1?T:arguments[_],m(Q))for(H=s(Q),l(C+H),L=0;L<H;L++,C++)L in Q&&d(j,C,Q[L]);else l(C+1),d(j,C++,Q);return j.length=C,j}}),Zee}ZOe();function A2(t){"@babel/helpers - typeof";return A2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},A2(t)}function WOe(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Kee(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,qee(a.key),a)}}function KOe(t,e,n){return e&&Kee(t.prototype,e),n&&Kee(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function L1(t,e,n){return(e=qee(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function qee(t){var e=qOe(t,"string");return A2(e)=="symbol"?e:e+""}function qOe(t,e){if(A2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(A2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var Jee=function(){function t(e){var n=e.errorCode,a=e.errorCodeKey,o=e.message,s=e.underlyingError,l=e.underlyingBaseError,d=e.domain,f=e.module,g=e.errorEnumName,M=e.shortDomainCode;WOe(this,t),L1(this,"errorCode",void 0),L1(this,"errorCodeKey",void 0),L1(this,"message",void 0),L1(this,"underlyingError",void 0),L1(this,"underlyingBaseError",void 0),L1(this,"domain",void 0),L1(this,"module",void 0),L1(this,"errorEnumName",void 0),L1(this,"shortDomainCode",void 0),this.errorCode=n,this.errorCodeKey=a,this.message=o,this.underlyingError=s,this.underlyingBaseError=l,this.module=f,this.domain=d,this.errorEnumName=g,this.shortDomainCode=M}return KOe(t,[{key:"lastUnderlyingError",get:function(){for(var n,a=this.underlyingBaseError;((o=a)===null||o===void 0?void 0:o.underlyingBaseError)instanceof t;){var o;a=a.underlyingBaseError}return(n=a)===null||n===void 0?void 0:n.underlyingError}},{key:"toObject",value:function(){var n={errorCode:this.errorCode,errorCodeKey:this.errorCodeKey,errorEnumName:this.errorEnumName,message:this.message,module:this.module,underlyingError:this.underlyingError,lastUnderlineError:this.lastUnderlyingError};return this.underlyingBaseError&&this.underlyingBaseError instanceof t&&(n.underlyingBaseError=this.underlyingBaseError.toObject()),n}},{key:"shortChain",get:function(){var n="".concat(this.shortDomainCode,":").concat(this.errorCode).concat(this.underlyingError?"-"+this.underlyingError:"");return this.underlyingBaseError instanceof t&&(n+="-".concat(this.underlyingBaseError.shortChain)),n}},{key:"fullChain",get:function(){var n="".concat(this.module,".").concat(this.domain,":").concat(this.errorCodeKey).concat(this.underlyingError?"-"+this.underlyingError:"");return this.underlyingBaseError instanceof t&&(n+="-".concat(this.underlyingBaseError.fullChain)),n}}],[{key:"getErrorKey",value:function(n,a){var o=Object.keys(a).find(function(s){return a[s]===n});if(!o)throw new Error("Invalid errorCode: ".concat(n," in enum"));return o}}])}();function t0(t){"@babel/helpers - typeof";return t0=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t0(t)}function JOe(t,e,n){return Object.defineProperty(t,"prototype",{writable:!1}),t}function XOe(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function e6e(t,e,n){return e=bv(e),t6e(t,Xee()?Reflect.construct(e,n||[],bv(t).constructor):e.apply(t,n))}function t6e(t,e){if(e&&(t0(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return r6e(t)}function r6e(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Xee(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(Xee=function(){return!!t})()}function bv(t){return bv=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},bv(t)}function n6e(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&gA(t,e)}function gA(t,e){return gA=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},gA(t,e)}function MA(t,e,n){return(e=i6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i6e(t){var e=a6e(t,"string");return t0(e)=="symbol"?e:e+""}function a6e(t,e){if(t0(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(t0(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Lv=function(t){function e(n){var a=n.errorCode,o=n.message,s=n.underlyingError,l=n.underlyingBaseError;XOe(this,e);var d=Jee.getErrorKey(a,Pq);return e6e(this,e,[{errorCode:a,errorCodeKey:d,errorEnumName:e.ERROR_ENUM_NAME,module:e.MODULE,message:o,underlyingError:s,underlyingBaseError:l,domain:e.ERROR_ENUM_NAME,shortDomainCode:e.SHORT_CODE}])}return n6e(e,t),JOe(e)}(Jee);MA(Lv,"MODULE",EC),MA(Lv,"ERROR_ENUM_NAME","GuiModuleError"),MA(Lv,"SHORT_CODE","GM");var o6e=function(e){var n=e.header,a=e.title,o=e.buttons,s=e.footer,l=e.questions,d=e.dataSource,f=e.properties,g=e.backgroundColor,M=nS(),I=M.perform,y=f?ZEe(d.questions,f):{},h=qTe({criteriaMode:"all",defaultValues:y}),m=h.register,N=h.handleSubmit,E=h.formState.errors,A=h.reset,T=h.watch,j=h.control,C=function(L){I(BEe(L)),A()};return ne.jsx(u2,{header:n,footer:s,backgroundColor:g,children:ne.jsxs("form",{onSubmit:N(C),style:{height:"100%",fontFamily:"sans-serif",display:"flex",flexDirection:"column",gap:"15px"},noValidate:!0,children:[ne.jsxs("div",{style:{flex:"1 1 100%",display:"flex",justifyContent:"flex-start",alignItems:"center",alignContent:"center",flexDirection:"column",gap:"10px",height:"100%",width:"100%",overflow:"auto",position:"relative",backgroundColor:Br(l.backgroundColor)||"transparent"},children:[a&&ne.jsx("div",{style:{lineHeight:"39.2px",width:"100%"},children:ne.jsx(Ou,Tt({},a))}),ne.jsx("div",{"data-ui":"gui-questions",part:"gui-questions",style:{width:"100%",display:"flex",gap:"10px",flexDirection:"column"},children:d.questions.map(function(_){var L,U=d.static,H=function(V,q){return q.find(function(te){var z;if((z=te.questionIds)!==null&&z!==void 0&&z.length)return te.questionIds.find(function(G){return V===G})})},Q=function(V,q){return q.find(function(te){return!te.questionIds&&te.answerType===V})},x=U?H(String(_.id),l.itemTypes)||Q(_.answerType,l.itemTypes):l.itemTypes.find(function(Y){return Y.answerType===_.answerType});if(!x){var O=new Lv({errorCode:Pq.DECODING_FAILED,message:"The question template has not been found"});I(O);return}var w=x==null?void 0:x.displayType,R=_.id in E&&((L=E[_.id])===null||L===void 0?void 0:L.types);return ne.jsxs(ht.Fragment,{children:[ne.jsxs(wOe,{backgroundColor:x==null?void 0:x.backgroundColor,cornerRadius:x==null?void 0:x.cornerRadius,isError:!!R,isRequired:_.required,validationBorderColor:x==null?void 0:x.validationBorderColor,validationBorderWidth:x==null?void 0:x.validationBorderWidth,children:[w===G4.TEXT_EXPANDABLE&&ne.jsx(YOe,{layout:x,dataSourceQuestion:_,register:m}),w===G4.TEXT_SINGLE_LINE&&ne.jsx(UOe,{layout:x,dataSourceQuestion:_,register:m}),w===G4.SELECTOR_OPTIONS&&ne.jsx(hOe,{layout:x,dataSourceQuestion:_,watch:T,register:m}),w===G4.SELECTOR_BUTTONS&&ne.jsx(AOe,{layout:x,dataSourceQuestion:_,watch:T,register:m}),w===G4.SELECTOR_DROPDOWN&&ne.jsx(VAe,{control:j,layout:x,dataSourceQuestion:_}),w===G4.MULTI_SELECTOR_DROPDOWN&&ne.jsx(nOe,{control:j,layout:x,dataSourceQuestion:_})]}),R&&ne.jsx(POe,{validationErrorsTypes:R,title:x.validationMessage})]},_.id)})})]}),!!(o!=null&&o.length)&&ne.jsx("div",{style:{display:"flex",width:"100%",flexGrow:0,flexShrink:0,justifyContent:"center",alignItems:"flex-end",padding:"2px"},children:o.map(function(_,L){return ne.jsx(eJ,Tt({dataTestId:"question-button"},_),L)})})]})})},ete=function(e){var n=e.templateId,a=e.templateLayout,o=e.dataSource,s=e.properties;return!n||!a?ne.jsx(sJ,{}):n===od.STATUS?ne.jsx(uTe,{header:a==null?void 0:a.header,footer:a==null?void 0:a.footer,image:a==null?void 0:a.image,title:a==null?void 0:a.title,buttons:a==null?void 0:a.buttons,backgroundColor:a==null?void 0:a.backgroundColor}):n===od.INFO?ne.jsx(gTe,{header:a==null?void 0:a.header,footer:a==null?void 0:a.footer,image:a==null?void 0:a.image,title:a==null?void 0:a.title,description:a==null?void 0:a.description,buttons:a==null?void 0:a.buttons,backgroundColor:a==null?void 0:a.backgroundColor}):n===od.PROGRESS?ne.jsx(sJ,{header:a==null?void 0:a.header,footer:a==null?void 0:a.footer,progressView:a==null?void 0:a.progressView,backgroundColor:a==null?void 0:a.backgroundColor}):n===od.INFO_DETAILS?ne.jsx(OTe,{header:a==null?void 0:a.header,title:a==null?void 0:a.title,details:a==null?void 0:a.details,buttons:a==null?void 0:a.buttons,footer:a==null?void 0:a.footer,backgroundColor:a==null?void 0:a.backgroundColor}):o&&o!==null&&o!==void 0&&o.questions.length&&n===od.QUESTIONS?ne.jsx(o6e,{dataSource:o,properties:s,questions:a.questions,header:a==null?void 0:a.header,footer:a==null?void 0:a.footer,title:a==null?void 0:a.title,buttons:a==null?void 0:a.buttons,backgroundColor:a==null?void 0:a.backgroundColor}):n===od.QUESTIONS&&!o?ne.jsx("div",{style:{width:"100%",height:"100%",fontFamily:"sans-serif",display:"flex",alignItems:"center",justifyContent:"center",textAlign:"center"},children:"IDV Gui :: No data for questions"}):ne.jsx("div",{style:{width:"100%",height:"100%",fontFamily:"sans-serif",display:"flex",alignItems:"center",justifyContent:"center",textAlign:"center"},children:"IDV Gui :: Unsupported step template"})},pA=!1,a1=function(e){var n=e.moduleProps,a=e.perform,o=n,s=o.templateId,l=o.templateLayout,d=o.dataSource,f=o.properties,g=function(I){a&&a(I)};return s===od.QUESTIONS?ne.jsx(cZ,{perform:g,children:ne.jsx(ete,{properties:f,dataSource:d,templateId:s,templateLayout:l})}):ne.jsx(cZ,{perform:g,children:ne.jsx(ete,{templateId:s,templateLayout:l})})};a1.getIdentifier=function(){return EC},a1.getSupportedTemplates=function(){return Object.values(od)},a1.deinitialize=function(){pA=!1},a1.initialize=function(){pA=!0},a1.isReady=function(){return pA},a1.displayName=EC;var tte={},rte;function u6e(){if(rte)return tte;rte=1;var t=wt(),e=Mr(),n=Date,a=e(n.prototype.getTime);return t({target:"Date",stat:!0},{now:function(){return a(new n)}}),tte}u6e();var nte={},ite={},IA,ate;function ote(){if(ate)return IA;ate=1;var t=dr(),e=Zn(),n=tn(),a=yu(),o=e("iterator");return IA=!t(function(){var s=new URL("b?a=1&b=2&c=3","https://a"),l=s.searchParams,d=new URLSearchParams("a=1&a=2&b=3"),f="";return s.pathname="c%20d",l.forEach(function(g,M){l.delete("b"),f+=M+g}),d.delete("a",2),d.delete("b",void 0),a&&(!s.toJSON||!d.has("a",1)||d.has("a",2)||!d.has("a",void 0)||d.has("b"))||!l.size&&(a||!n)||!l.sort||s.href!=="https://a/c%20d?a=1&c=3"||l.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!l[o]||new URL("https://a@b").username!=="a"||new URLSearchParams(new URLSearchParams("a=b")).get("a")!=="b"||new URL("https://тест").host!=="xn--e1aybc"||new URL("https://a#б").hash!=="#%D0%B1"||f!=="a1c3"||new URL("https://x",void 0).host!=="x"}),IA}var yA,ute;function s6e(){if(ute)return yA;ute=1;var t=Mr(),e=2147483647,n=36,a=1,o=26,s=38,l=700,d=72,f=128,g="-",M=/[^\0-\u007E]/,I=/[.\u3002\uFF0E\uFF61]/g,y="Overflow: input needs wider integers to process",h=n-a,m=RangeError,N=t(I.exec),E=Math.floor,A=String.fromCharCode,T=t("".charCodeAt),j=t([].join),C=t([].push),_=t("".replace),L=t("".split),U=t("".toLowerCase),H=function(w){for(var R=[],Y=0,V=w.length;Y<V;){var q=T(w,Y++);if(q>=55296&&q<=56319&&Y<V){var te=T(w,Y++);(te&64512)===56320?C(R,((q&1023)<<10)+(te&1023)+65536):(C(R,q),Y--)}else C(R,q)}return R},Q=function(w){return w+22+75*(w<26)},x=function(w,R,Y){var V=0;for(w=Y?E(w/l):w>>1,w+=E(w/R);w>h*o>>1;)w=E(w/h),V+=n;return E(V+(h+1)*w/(w+s))},O=function(w){var R=[];w=H(w);var Y=w.length,V=f,q=0,te=d,z,G;for(z=0;z<w.length;z++)G=w[z],G<128&&C(R,A(G));var K=R.length,k=K;for(K&&C(R,g);k<Y;){var W=e;for(z=0;z<w.length;z++)G=w[z],G>=V&&G<W&&(W=G);var pe=k+1;if(W-V>E((e-q)/pe))throw new m(y);for(q+=(W-V)*pe,V=W,z=0;z<w.length;z++){if(G=w[z],G<V&&++q>e)throw new m(y);if(G===V){for(var Me=q,le=n;;){var Oe=le<=te?a:le>=te+o?o:le-te;if(Me<Oe)break;var Pe=Me-Oe,me=n-Oe;C(R,A(Q(Oe+Pe%me))),Me=E(Pe/me),le+=n}C(R,A(Q(Me))),te=x(q,pe,k===K),q=0,k++}}q++,V++}return j(R,"")};return yA=function(w){var R=[],Y=L(_(U(w),I,"."),"."),V,q;for(V=0;V<Y.length;V++)q=Y[V],C(R,N(M,q)?"xn--"+O(q):q);return j(R,".")},yA}var ste={},lte;function l6e(){if(lte)return ste;lte=1;var t=wt(),e=Mr(),n=AN(),a=RangeError,o=String.fromCharCode,s=String.fromCodePoint,l=e([].join),d=!!s&&s.length!==1;return t({target:"String",stat:!0,arity:1,forced:d},{fromCodePoint:function(g){for(var M=[],I=arguments.length,y=0,h;I>y;){if(h=+arguments[y++],n(h,1114111)!==h)throw new a(h+" is not a valid code point");M[y]=h<65536?o(h):o(((h-=65536)>>10)+55296,h%1024+56320)}return l(M,"")}}),ste}var hA,cte;function c6e(){if(cte)return hA;cte=1;var t=q1(),e=Math.floor,n=function(a,o){var s=a.length;if(s<8)for(var l=1,d,f;l<s;){for(f=l,d=a[l];f&&o(a[f-1],d)>0;)a[f]=a[--f];f!==l++&&(a[f]=d)}else for(var g=e(s/2),M=n(t(a,0,g),o),I=n(t(a,g),o),y=M.length,h=I.length,m=0,N=0;m<y||N<h;)a[m+N]=m<y&&N<h?o(M[m],I[N])<=0?M[m++]:I[N++]:m<y?M[m++]:I[N++];return a};return hA=n,hA}var vA,fte;function dte(){if(fte)return vA;fte=1,Q5(),l6e();var t=wt(),e=Lr(),n=BQ(),a=ju(),o=yn(),s=Mr(),l=tn(),d=ote(),f=Ra(),g=Uu(),M=Ip(),I=vl(),y=sU(),h=Au(),m=PM(),N=qn(),E=mi(),A=J1(),T=sp(),j=_n(),C=Jn(),_=Ni(),L=Vl(),U=LM(),H=rE(),Q=Sh(),x=Mp(),O=U4(),w=Zn(),R=c6e(),Y=w("iterator"),V="URLSearchParams",q=V+"Iterator",te=h.set,z=h.getterFor(V),G=h.getterFor(q),K=n("fetch"),k=n("Request"),W=n("Headers"),pe=k&&k.prototype,Me=W&&W.prototype,le=e.TypeError,Oe=e.encodeURIComponent,Pe=String.fromCharCode,me=a("String","fromCodePoint"),Le=parseInt,Ze=s("".charAt),Xe=s([].join),tt=s([].push),ct=s("".replace),Dt=s([].shift),Et=s([].splice),vt=s("".split),Je=s("".slice),dt=s(/./.exec),pt=/\+/g,Ke="�",Ce=/^[0-9a-f]+$/i,Ue=function(he,Re){var $e=Je(he,Re,Re+2);return dt(Ce,$e)?Le($e,16):NaN},fe=function(he){for(var Re=0,$e=128;$e>0&&(he&$e)!==0;$e>>=1)Re++;return Re},xe=function(he){var Re=null;switch(he.length){case 1:Re=he[0];break;case 2:Re=(he[0]&31)<<6|he[1]&63;break;case 3:Re=(he[0]&15)<<12|(he[1]&63)<<6|he[2]&63;break;case 4:Re=(he[0]&7)<<18|(he[1]&63)<<12|(he[2]&63)<<6|he[3]&63;break}return Re>1114111?null:Re},ve=function(he){he=ct(he,pt," ");for(var Re=he.length,$e="",be=0;be<Re;){var ot=Ze(he,be);if(ot==="%"){if(Ze(he,be+1)==="%"||be+3>Re){$e+="%",be++;continue}var It=Ue(he,be+1);if(It!==It){$e+=ot,be++;continue}be+=2;var At=fe(It);if(At===0)ot=Pe(It);else{if(At===1||At>4){$e+=Ke,be++;continue}for(var St=[It],Ft=1;Ft<At&&(be++,!(be+3>Re||Ze(he,be)!=="%"));){var ir=Ue(he,be+1);if(ir!==ir){be+=3;break}if(ir>191||ir<128)break;tt(St,ir),be+=2,Ft++}if(St.length!==At){$e+=Ke;continue}var Ir=xe(St);Ir===null?$e+=Ke:ot=me(Ir)}}$e+=ot,be++}return $e},ge=/[!'()~]|%20/g,de={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},we=function(he){return de[he]},et=function(he){return ct(Oe(he),ge,we)},rt=y(function(Re,$e){te(this,{type:q,target:z(Re).entries,index:0,kind:$e})},V,function(){var Re=G(this),$e=Re.target,be=Re.index++;if(!$e||be>=$e.length)return Re.target=null,x(void 0,!0);var ot=$e[be];switch(Re.kind){case"keys":return x(ot.key,!1);case"values":return x(ot.value,!1)}return x([ot.key,ot.value],!1)},!0),Ye=function(he){this.entries=[],this.url=null,he!==void 0&&(C(he)?this.parseObject(he):this.parseQuery(typeof he=="string"?Ze(he,0)==="?"?Je(he,1):he:_(he)))};Ye.prototype={type:V,bindURL:function(he){this.url=he,this.update()},parseObject:function(he){var Re=this.entries,$e=Q(he),be,ot,It,At,St,Ft,ir;if($e)for(be=H(he,$e),ot=be.next;!(It=o(ot,be)).done;){if(At=H(j(It.value)),St=At.next,(Ft=o(St,At)).done||(ir=o(St,At)).done||!o(St,At).done)throw new le("Expected sequence with length 2");tt(Re,{key:_(Ft.value),value:_(ir.value)})}else for(var Ir in he)E(he,Ir)&&tt(Re,{key:Ir,value:_(he[Ir])})},parseQuery:function(he){if(he)for(var Re=this.entries,$e=vt(he,"&"),be=0,ot,It;be<$e.length;)ot=$e[be++],ot.length&&(It=vt(ot,"="),tt(Re,{key:ve(Dt(It)),value:ve(Xe(It,"="))}))},serialize:function(){for(var he=this.entries,Re=[],$e=0,be;$e<he.length;)be=he[$e++],tt(Re,et(be.key)+"="+et(be.value));return Xe(Re,"&")},update:function(){this.entries.length=0,this.parseQuery(this.url.query)},updateURL:function(){this.url&&this.url.update()}};var Te=function(){m(this,_e);var Re=arguments.length>0?arguments[0]:void 0,$e=te(this,new Ye(Re));l||(this.size=$e.entries.length)},_e=Te.prototype;if(M(_e,{append:function(Re,$e){var be=z(this);O(arguments.length,2),tt(be.entries,{key:_(Re),value:_($e)}),l||this.length++,be.updateURL()},delete:function(he){for(var Re=z(this),$e=O(arguments.length,1),be=Re.entries,ot=_(he),It=$e<2?void 0:arguments[1],At=It===void 0?It:_(It),St=0;St<be.length;){var Ft=be[St];if(Ft.key===ot&&(At===void 0||Ft.value===At)){if(Et(be,St,1),At!==void 0)break}else St++}l||(this.size=be.length),Re.updateURL()},get:function(Re){var $e=z(this).entries;O(arguments.length,1);for(var be=_(Re),ot=0;ot<$e.length;ot++)if($e[ot].key===be)return $e[ot].value;return null},getAll:function(Re){var $e=z(this).entries;O(arguments.length,1);for(var be=_(Re),ot=[],It=0;It<$e.length;It++)$e[It].key===be&&tt(ot,$e[It].value);return ot},has:function(Re){for(var $e=z(this).entries,be=O(arguments.length,1),ot=_(Re),It=be<2?void 0:arguments[1],At=It===void 0?It:_(It),St=0;St<$e.length;){var Ft=$e[St++];if(Ft.key===ot&&(At===void 0||Ft.value===At))return!0}return!1},set:function(Re,$e){var be=z(this);O(arguments.length,1);for(var ot=be.entries,It=!1,At=_(Re),St=_($e),Ft=0,ir;Ft<ot.length;Ft++)ir=ot[Ft],ir.key===At&&(It?Et(ot,Ft--,1):(It=!0,ir.value=St));It||tt(ot,{key:At,value:St}),l||(this.size=ot.length),be.updateURL()},sort:function(){var Re=z(this);R(Re.entries,function($e,be){return $e.key>be.key?1:-1}),Re.updateURL()},forEach:function(Re){for(var $e=z(this).entries,be=A(Re,arguments.length>1?arguments[1]:void 0),ot=0,It;ot<$e.length;)It=$e[ot++],be(It.value,It.key,this)},keys:function(){return new rt(this,"keys")},values:function(){return new rt(this,"values")},entries:function(){return new rt(this,"entries")}},{enumerable:!0}),f(_e,Y,_e.entries,{name:"entries"}),f(_e,"toString",function(){return z(this).serialize()},{enumerable:!0}),l&&g(_e,"size",{get:function(){return z(this).entries.length},configurable:!0,enumerable:!0}),I(Te,V),t({global:!0,constructor:!0,forced:!d},{URLSearchParams:Te}),!d&&N(W)){var Be=s(Me.has),gt=s(Me.set),lt=function(he){if(C(he)){var Re=he.body,$e;if(T(Re)===V)return $e=he.headers?new W(he.headers):new W,Be($e,"content-type")||gt($e,"content-type","application/x-www-form-urlencoded;charset=UTF-8"),L(he,{body:U(0,_(Re)),headers:U(0,$e)})}return he};if(N(K)&&t({global:!0,enumerable:!0,dontCallGetSet:!0,forced:!0},{fetch:function(Re){return K(Re,arguments.length>1?lt(arguments[1]):{})}}),N(k)){var Ut=function(Re){return m(this,pe),new k(Re,arguments.length>1?lt(arguments[1]):{})};pe.constructor=Ut,Ut.prototype=pe,t({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:Ut})}}return vA={URLSearchParams:Te,getState:z},vA}var gte;function f6e(){if(gte)return ite;gte=1,DY();var t=wt(),e=tn(),n=ote(),a=Lr(),o=J1(),s=Mr(),l=Ra(),d=Uu(),f=PM(),g=mi(),M=VH(),I=t$(),y=q1(),h=DE().codeAt,m=s6e(),N=Ni(),E=vl(),A=U4(),T=dte(),j=Au(),C=j.set,_=j.getterFor("URL"),L=T.URLSearchParams,U=T.getState,H=a.URL,Q=a.TypeError,x=a.parseInt,O=Math.floor,w=Math.pow,R=s("".charAt),Y=s(/./.exec),V=s([].join),q=s(1 .toString),te=s([].pop),z=s([].push),G=s("".replace),K=s([].shift),k=s("".split),W=s("".slice),pe=s("".toLowerCase),Me=s([].unshift),le="Invalid authority",Oe="Invalid scheme",Pe="Invalid host",me="Invalid port",Le=/[a-z]/i,Ze=/[\d+-.a-z]/i,Xe=/\d/,tt=/^0x/i,ct=/^[0-7]+$/,Dt=/^\d+$/,Et=/^[\da-f]+$/i,vt=/[\0\t\n\r #%/:<>?@[\\\]^|]/,Je=/[\0\t\n\r #/:<>?@[\\\]^|]/,dt=/^[\u0000-\u0020]+/,pt=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,Ke=/[\t\n\r]/g,Ce,Ue=function(ie){var Ie=k(ie,"."),se,J,je,ut,Fe,bt,yt;if(Ie.length&&Ie[Ie.length-1]===""&&Ie.length--,se=Ie.length,se>4)return ie;for(J=[],je=0;je<se;je++){if(ut=Ie[je],ut==="")return ie;if(Fe=10,ut.length>1&&R(ut,0)==="0"&&(Fe=Y(tt,ut)?16:8,ut=W(ut,Fe===8?1:2)),ut==="")bt=0;else{if(!Y(Fe===10?Dt:Fe===8?ct:Et,ut))return ie;bt=x(ut,Fe)}z(J,bt)}for(je=0;je<se;je++)if(bt=J[je],je===se-1){if(bt>=w(256,5-se))return null}else if(bt>255)return null;for(yt=te(J),je=0;je<J.length;je++)yt+=J[je]*w(256,3-je);return yt},fe=function(ie){var Ie=[0,0,0,0,0,0,0,0],se=0,J=null,je=0,ut,Fe,bt,yt,er,sr,De,Lt=function(){return R(ie,je)};if(Lt()===":"){if(R(ie,1)!==":")return;je+=2,se++,J=se}for(;Lt();){if(se===8)return;if(Lt()===":"){if(J!==null)return;je++,se++,J=se;continue}for(ut=Fe=0;Fe<4&&Y(Et,Lt());)ut=ut*16+x(Lt(),16),je++,Fe++;if(Lt()==="."){if(Fe===0||(je-=Fe,se>6))return;for(bt=0;Lt();){if(yt=null,bt>0)if(Lt()==="."&&bt<4)je++;else return;if(!Y(Xe,Lt()))return;for(;Y(Xe,Lt());){if(er=x(Lt(),10),yt===null)yt=er;else{if(yt===0)return;yt=yt*10+er}if(yt>255)return;je++}Ie[se]=Ie[se]*256+yt,bt++,(bt===2||bt===4)&&se++}if(bt!==4)return;break}else if(Lt()===":"){if(je++,!Lt())return}else if(Lt())return;Ie[se++]=ut}if(J!==null)for(sr=se-J,se=7;se!==0&&sr>0;)De=Ie[se],Ie[se--]=Ie[J+sr-1],Ie[J+--sr]=De;else if(se!==8)return;return Ie},xe=function(ie){for(var Ie=null,se=1,J=null,je=0,ut=0;ut<8;ut++)ie[ut]!==0?(je>se&&(Ie=J,se=je),J=null,je=0):(J===null&&(J=ut),++je);return je>se?J:Ie},ve=function(ie){var Ie,se,J,je;if(typeof ie=="number"){for(Ie=[],se=0;se<4;se++)Me(Ie,ie%256),ie=O(ie/256);return V(Ie,".")}if(typeof ie=="object"){for(Ie="",J=xe(ie),se=0;se<8;se++)je&&ie[se]===0||(je&&(je=!1),J===se?(Ie+=se?":":"::",je=!0):(Ie+=q(ie[se],16),se<7&&(Ie+=":")));return"["+Ie+"]"}return ie},ge={},de=M({},ge,{" ":1,'"':1,"<":1,">":1,"`":1}),we=M({},de,{"#":1,"?":1,"{":1,"}":1}),et=M({},we,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),rt=function(ie,Ie){var se=h(ie,0);return se>32&&se<127&&!g(Ie,ie)?ie:encodeURIComponent(ie)},Ye={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Te=function(ie,Ie){var se;return ie.length===2&&Y(Le,R(ie,0))&&((se=R(ie,1))===":"||!Ie&&se==="|")},_e=function(ie){var Ie;return ie.length>1&&Te(W(ie,0,2))&&(ie.length===2||(Ie=R(ie,2))==="/"||Ie==="\\"||Ie==="?"||Ie==="#")},Be=function(ie){return ie==="."||pe(ie)==="%2e"},gt=function(ie){return ie=pe(ie),ie===".."||ie==="%2e."||ie===".%2e"||ie==="%2e%2e"},lt={},Ut={},he={},Re={},$e={},be={},ot={},It={},At={},St={},Ft={},ir={},Ir={},ui={},Ar={},Pn={},Ht={},Or={},Nn={},_r={},yr={},Un=function(ie,Ie,se){var J=N(ie),je,ut,Fe;if(Ie){if(ut=this.parse(J),ut)throw new Q(ut);this.searchParams=null}else{if(se!==void 0&&(je=new Un(se,!0)),ut=this.parse(J,null,je),ut)throw new Q(ut);Fe=U(new L),Fe.bindURL(this),this.searchParams=Fe}};Un.prototype={type:"URL",parse:function(ie,Ie,se){var J=this,je=Ie||lt,ut=0,Fe="",bt=!1,yt=!1,er=!1,sr,De,Lt,Zr;for(ie=N(ie),Ie||(J.scheme="",J.username="",J.password="",J.host=null,J.port=null,J.path=[],J.query=null,J.fragment=null,J.cannotBeABaseURL=!1,ie=G(ie,dt,""),ie=G(ie,pt,"$1")),ie=G(ie,Ke,""),sr=I(ie);ut<=sr.length;){switch(De=sr[ut],je){case lt:if(De&&Y(Le,De))Fe+=pe(De),je=Ut;else{if(Ie)return Oe;je=he;continue}break;case Ut:if(De&&(Y(Ze,De)||De==="+"||De==="-"||De==="."))Fe+=pe(De);else if(De===":"){if(Ie&&(J.isSpecial()!==g(Ye,Fe)||Fe==="file"&&(J.includesCredentials()||J.port!==null)||J.scheme==="file"&&!J.host))return;if(J.scheme=Fe,Ie){J.isSpecial()&&Ye[J.scheme]===J.port&&(J.port=null);return}Fe="",J.scheme==="file"?je=ui:J.isSpecial()&&se&&se.scheme===J.scheme?je=Re:J.isSpecial()?je=It:sr[ut+1]==="/"?(je=$e,ut++):(J.cannotBeABaseURL=!0,z(J.path,""),je=Nn)}else{if(Ie)return Oe;Fe="",je=he,ut=0;continue}break;case he:if(!se||se.cannotBeABaseURL&&De!=="#")return Oe;if(se.cannotBeABaseURL&&De==="#"){J.scheme=se.scheme,J.path=y(se.path),J.query=se.query,J.fragment="",J.cannotBeABaseURL=!0,je=yr;break}je=se.scheme==="file"?ui:be;continue;case Re:if(De==="/"&&sr[ut+1]==="/")je=At,ut++;else{je=be;continue}break;case $e:if(De==="/"){je=St;break}else{je=Or;continue}case be:if(J.scheme=se.scheme,De===Ce)J.username=se.username,J.password=se.password,J.host=se.host,J.port=se.port,J.path=y(se.path),J.query=se.query;else if(De==="/"||De==="\\"&&J.isSpecial())je=ot;else if(De==="?")J.username=se.username,J.password=se.password,J.host=se.host,J.port=se.port,J.path=y(se.path),J.query="",je=_r;else if(De==="#")J.username=se.username,J.password=se.password,J.host=se.host,J.port=se.port,J.path=y(se.path),J.query=se.query,J.fragment="",je=yr;else{J.username=se.username,J.password=se.password,J.host=se.host,J.port=se.port,J.path=y(se.path),J.path.length--,je=Or;continue}break;case ot:if(J.isSpecial()&&(De==="/"||De==="\\"))je=At;else if(De==="/")je=St;else{J.username=se.username,J.password=se.password,J.host=se.host,J.port=se.port,je=Or;continue}break;case It:if(je=At,De!=="/"||R(Fe,ut+1)!=="/")continue;ut++;break;case At:if(De!=="/"&&De!=="\\"){je=St;continue}break;case St:if(De==="@"){bt&&(Fe="%40"+Fe),bt=!0,Lt=I(Fe);for(var Ci=0;Ci<Lt.length;Ci++){var si=Lt[Ci];if(si===":"&&!er){er=!0;continue}var xr=rt(si,et);er?J.password+=xr:J.username+=xr}Fe=""}else if(De===Ce||De==="/"||De==="?"||De==="#"||De==="\\"&&J.isSpecial()){if(bt&&Fe==="")return le;ut-=I(Fe).length+1,Fe="",je=Ft}else Fe+=De;break;case Ft:case ir:if(Ie&&J.scheme==="file"){je=Pn;continue}else if(De===":"&&!yt){if(Fe==="")return Pe;if(Zr=J.parseHost(Fe),Zr)return Zr;if(Fe="",je=Ir,Ie===ir)return}else if(De===Ce||De==="/"||De==="?"||De==="#"||De==="\\"&&J.isSpecial()){if(J.isSpecial()&&Fe==="")return Pe;if(Ie&&Fe===""&&(J.includesCredentials()||J.port!==null))return;if(Zr=J.parseHost(Fe),Zr)return Zr;if(Fe="",je=Ht,Ie)return;continue}else De==="["?yt=!0:De==="]"&&(yt=!1),Fe+=De;break;case Ir:if(Y(Xe,De))Fe+=De;else if(De===Ce||De==="/"||De==="?"||De==="#"||De==="\\"&&J.isSpecial()||Ie){if(Fe!==""){var ra=x(Fe,10);if(ra>65535)return me;J.port=J.isSpecial()&&ra===Ye[J.scheme]?null:ra,Fe=""}if(Ie)return;je=Ht;continue}else return me;break;case ui:if(J.scheme="file",De==="/"||De==="\\")je=Ar;else if(se&&se.scheme==="file")switch(De){case Ce:J.host=se.host,J.path=y(se.path),J.query=se.query;break;case"?":J.host=se.host,J.path=y(se.path),J.query="",je=_r;break;case"#":J.host=se.host,J.path=y(se.path),J.query=se.query,J.fragment="",je=yr;break;default:_e(V(y(sr,ut),""))||(J.host=se.host,J.path=y(se.path),J.shortenPath()),je=Or;continue}else{je=Or;continue}break;case Ar:if(De==="/"||De==="\\"){je=Pn;break}se&&se.scheme==="file"&&!_e(V(y(sr,ut),""))&&(Te(se.path[0],!0)?z(J.path,se.path[0]):J.host=se.host),je=Or;continue;case Pn:if(De===Ce||De==="/"||De==="\\"||De==="?"||De==="#"){if(!Ie&&Te(Fe))je=Or;else if(Fe===""){if(J.host="",Ie)return;je=Ht}else{if(Zr=J.parseHost(Fe),Zr)return Zr;if(J.host==="localhost"&&(J.host=""),Ie)return;Fe="",je=Ht}continue}else Fe+=De;break;case Ht:if(J.isSpecial()){if(je=Or,De!=="/"&&De!=="\\")continue}else if(!Ie&&De==="?")J.query="",je=_r;else if(!Ie&&De==="#")J.fragment="",je=yr;else if(De!==Ce&&(je=Or,De!=="/"))continue;break;case Or:if(De===Ce||De==="/"||De==="\\"&&J.isSpecial()||!Ie&&(De==="?"||De==="#")){if(gt(Fe)?(J.shortenPath(),De!=="/"&&!(De==="\\"&&J.isSpecial())&&z(J.path,"")):Be(Fe)?De!=="/"&&!(De==="\\"&&J.isSpecial())&&z(J.path,""):(J.scheme==="file"&&!J.path.length&&Te(Fe)&&(J.host&&(J.host=""),Fe=R(Fe,0)+":"),z(J.path,Fe)),Fe="",J.scheme==="file"&&(De===Ce||De==="?"||De==="#"))for(;J.path.length>1&&J.path[0]==="";)K(J.path);De==="?"?(J.query="",je=_r):De==="#"&&(J.fragment="",je=yr)}else Fe+=rt(De,we);break;case Nn:De==="?"?(J.query="",je=_r):De==="#"?(J.fragment="",je=yr):De!==Ce&&(J.path[0]+=rt(De,ge));break;case _r:!Ie&&De==="#"?(J.fragment="",je=yr):De!==Ce&&(De==="'"&&J.isSpecial()?J.query+="%27":De==="#"?J.query+="%23":J.query+=rt(De,ge));break;case yr:De!==Ce&&(J.fragment+=rt(De,de));break}ut++}},parseHost:function(ie){var Ie,se,J;if(R(ie,0)==="["){if(R(ie,ie.length-1)!=="]"||(Ie=fe(W(ie,1,-1)),!Ie))return Pe;this.host=Ie}else if(this.isSpecial()){if(ie=m(ie),Y(vt,ie)||(Ie=Ue(ie),Ie===null))return Pe;this.host=Ie}else{if(Y(Je,ie))return Pe;for(Ie="",se=I(ie),J=0;J<se.length;J++)Ie+=rt(se[J],ge);this.host=Ie}},cannotHaveUsernamePasswordPort:function(){return!this.host||this.cannotBeABaseURL||this.scheme==="file"},includesCredentials:function(){return this.username!==""||this.password!==""},isSpecial:function(){return g(Ye,this.scheme)},shortenPath:function(){var ie=this.path,Ie=ie.length;Ie&&(this.scheme!=="file"||Ie!==1||!Te(ie[0],!0))&&ie.length--},serialize:function(){var ie=this,Ie=ie.scheme,se=ie.username,J=ie.password,je=ie.host,ut=ie.port,Fe=ie.path,bt=ie.query,yt=ie.fragment,er=Ie+":";return je!==null?(er+="//",ie.includesCredentials()&&(er+=se+(J?":"+J:"")+"@"),er+=ve(je),ut!==null&&(er+=":"+ut)):Ie==="file"&&(er+="//"),er+=ie.cannotBeABaseURL?Fe[0]:Fe.length?"/"+V(Fe,"/"):"",bt!==null&&(er+="?"+bt),yt!==null&&(er+="#"+yt),er},setHref:function(ie){var Ie=this.parse(ie);if(Ie)throw new Q(Ie);this.searchParams.update()},getOrigin:function(){var ie=this.scheme,Ie=this.port;if(ie==="blob")try{return new En(ie.path[0]).origin}catch(se){return"null"}return ie==="file"||!this.isSpecial()?"null":ie+"://"+ve(this.host)+(Ie!==null?":"+Ie:"")},getProtocol:function(){return this.scheme+":"},setProtocol:function(ie){this.parse(N(ie)+":",lt)},getUsername:function(){return this.username},setUsername:function(ie){var Ie=I(N(ie));if(!this.cannotHaveUsernamePasswordPort()){this.username="";for(var se=0;se<Ie.length;se++)this.username+=rt(Ie[se],et)}},getPassword:function(){return this.password},setPassword:function(ie){var Ie=I(N(ie));if(!this.cannotHaveUsernamePasswordPort()){this.password="";for(var se=0;se<Ie.length;se++)this.password+=rt(Ie[se],et)}},getHost:function(){var ie=this.host,Ie=this.port;return ie===null?"":Ie===null?ve(ie):ve(ie)+":"+Ie},setHost:function(ie){this.cannotBeABaseURL||this.parse(ie,Ft)},getHostname:function(){var ie=this.host;return ie===null?"":ve(ie)},setHostname:function(ie){this.cannotBeABaseURL||this.parse(ie,ir)},getPort:function(){var ie=this.port;return ie===null?"":N(ie)},setPort:function(ie){this.cannotHaveUsernamePasswordPort()||(ie=N(ie),ie===""?this.port=null:this.parse(ie,Ir))},getPathname:function(){var ie=this.path;return this.cannotBeABaseURL?ie[0]:ie.length?"/"+V(ie,"/"):""},setPathname:function(ie){this.cannotBeABaseURL||(this.path=[],this.parse(ie,Ht))},getSearch:function(){var ie=this.query;return ie?"?"+ie:""},setSearch:function(ie){ie=N(ie),ie===""?this.query=null:(R(ie,0)==="?"&&(ie=W(ie,1)),this.query="",this.parse(ie,_r)),this.searchParams.update()},getSearchParams:function(){return this.searchParams.facade},getHash:function(){var ie=this.fragment;return ie?"#"+ie:""},setHash:function(ie){if(ie=N(ie),ie===""){this.fragment=null;return}R(ie,0)==="#"&&(ie=W(ie,1)),this.fragment="",this.parse(ie,yr)},update:function(){this.query=this.searchParams.serialize()||null}};var En=function(Ie){var se=f(this,rr),J=A(arguments.length,1)>1?arguments[1]:void 0,je=C(se,new Un(Ie,!1,J));e||(se.href=je.serialize(),se.origin=je.getOrigin(),se.protocol=je.getProtocol(),se.username=je.getUsername(),se.password=je.getPassword(),se.host=je.getHost(),se.hostname=je.getHostname(),se.port=je.getPort(),se.pathname=je.getPathname(),se.search=je.getSearch(),se.searchParams=je.getSearchParams(),se.hash=je.getHash())},rr=En.prototype,Dr=function(ie,Ie){return{get:function(){return _(this)[ie]()},set:Ie&&function(se){return _(this)[Ie](se)},configurable:!0,enumerable:!0}};if(e&&(d(rr,"href",Dr("serialize","setHref")),d(rr,"origin",Dr("getOrigin")),d(rr,"protocol",Dr("getProtocol","setProtocol")),d(rr,"username",Dr("getUsername","setUsername")),d(rr,"password",Dr("getPassword","setPassword")),d(rr,"host",Dr("getHost","setHost")),d(rr,"hostname",Dr("getHostname","setHostname")),d(rr,"port",Dr("getPort","setPort")),d(rr,"pathname",Dr("getPathname","setPathname")),d(rr,"search",Dr("getSearch","setSearch")),d(rr,"searchParams",Dr("getSearchParams")),d(rr,"hash",Dr("getHash","setHash"))),l(rr,"toJSON",function(){return _(this).serialize()},{enumerable:!0}),l(rr,"toString",function(){return _(this).serialize()},{enumerable:!0}),H){var un=H.createObjectURL,ta=H.revokeObjectURL;un&&l(En,"createObjectURL",o(un,H)),ta&&l(En,"revokeObjectURL",o(ta,H))}return E(En,"URL"),t({global:!0,constructor:!0,forced:!n,sham:!e},{URL:En}),ite}var Mte;function d6e(){return Mte||(Mte=1,f6e()),nte}d6e();var pte={},Ite;function g6e(){if(Ite)return pte;Ite=1;var t=wt(),e=yn();return t({target:"URL",proto:!0,enumerable:!0},{toJSON:function(){return e(URL.prototype.toString,this)}}),pte}g6e();var yte={},hte;function M6e(){return hte||(hte=1,dte()),yte}M6e();var vte={},mte;function p6e(){if(mte)return vte;mte=1;var t=Ra(),e=Mr(),n=Ni(),a=U4(),o=URLSearchParams,s=o.prototype,l=e(s.append),d=e(s.delete),f=e(s.forEach),g=e([].push),M=new o("a=1&a=2&b=3");return M.delete("a",1),M.delete("b",void 0),M+""!="a=2"&&t(s,"delete",function(I){var y=arguments.length,h=y<2?void 0:arguments[1];if(y&&h===void 0)return d(this,I);var m=[];f(this,function(L,U){g(m,{key:U,value:L})}),a(y,1);for(var N=n(I),E=n(h),A=0,T=0,j=!1,C=m.length,_;A<C;)_=m[A++],j||_.key===N?(j=!0,d(this,_.key)):T++;for(;T<C;)_=m[T++],_.key===N&&_.value===E||l(this,_.key,_.value)},{enumerable:!0,unsafe:!0}),vte}p6e();var Nte={},Ete;function I6e(){if(Ete)return Nte;Ete=1;var t=Ra(),e=Mr(),n=Ni(),a=U4(),o=URLSearchParams,s=o.prototype,l=e(s.getAll),d=e(s.has),f=new o("a=1");return(f.has("a",2)||!f.has("a",void 0))&&t(s,"has",function(M){var I=arguments.length,y=I<2?void 0:arguments[1];if(I&&y===void 0)return d(this,M);var h=l(this,M);a(I,1);for(var m=n(y),N=0;N<h.length;)if(h[N++]===m)return!0;return!1},{enumerable:!0,unsafe:!0}),Nte}I6e();var Dte={},Tte;function y6e(){if(Tte)return Dte;Tte=1;var t=tn(),e=Mr(),n=Uu(),a=URLSearchParams.prototype,o=e(a.forEach);return t&&!("size"in a)&&n(a,"size",{get:function(){var l=0;return o(this,function(){l++}),l},configurable:!0,enumerable:!0}),Dte}y6e();function O2(t){"@babel/helpers - typeof";return O2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},O2(t)}function h6e(t,e){return E6e(t)||N6e(t,e)||m6e(t,e)||v6e()}function v6e(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
84
84
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function m6e(t,e){if(t){if(typeof t=="string")return jte(t,e);var n={}.toString.call(t).slice(8,-1);return n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set"?Array.from(t):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?jte(t,e):void 0}}function jte(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,a=Array(e);n<e;n++)a[n]=t[n];return a}function N6e(t,e){var n=t==null?null:typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var a,o,s,l,d=[],f=!0,g=!1;try{if(s=(n=n.call(t)).next,e!==0)for(;!(f=(a=s.call(n)).done)&&(d.push(a.value),d.length!==e);f=!0);}catch(M){g=!0,o=M}finally{try{if(!f&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(g)throw o}}return d}}function E6e(t){if(Array.isArray(t))return t}function D6e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function T6e(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,Ste(a.key),a)}}function j6e(t,e,n){return e&&T6e(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function kv(t,e,n){return(e=Ste(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ste(t){var e=S6e(t,"string");return O2(e)=="symbol"?e:e+""}function S6e(t,e){if(O2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(O2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var C6e=function(){function t(){D6e(this,t),kv(this,"_levels",[]),kv(this,"_transports",[]),kv(this,"_logs",[]),kv(this,"_prevTime",0);try{if(!window.localStorage)return;var e=window.localStorage.getItem("logger");if(!e)return;var n=e.split(">"),a=h6e(n,2),o=a[0],s=a[1];this._levels=o.split(","),s&&(this._transports=s.split(","))}catch(l){return}}return j6e(t,[{key:"create",value:function(n,a){var o=this;return function(s){var l=Date.now(),d=0;if(o._prevTime&&(d=l-o._prevTime),o._prevTime=l,o._levels.includes(n)&&o._transports.includes("console")){var f=(a==null?void 0:a.color)||"blue";console.log("%c%s: %c%s %c+%dms","color: ".concat(f,";"),n,"",s,"color: ".concat(f,";"),d)}o._logs.push("".concat(n,": ").concat(s," +").concat(d,"ms"))}}},{key:"getLogs",value:function(){return this._logs}},{key:"cleanLogs",value:function(){this._logs=[]}},{key:"saveLogsToFile",value:function(){if(!(!this._transports.includes("file")||!this._logs.length)){var n=this._logs.join(`
|
|
85
|
-
`),a=new Blob([n],{type:"text/plain"}),o=window.URL.createObjectURL(a),s=document.createElement("a");s.download="log.txt",s.href=o,s.click(),window.URL.revokeObjectURL(o),this.cleanLogs()}}}])}(),mA=new C6e;function XM(t){"@babel/helpers - typeof";return XM=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},XM(t)}function bn(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */bn=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&XM(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(XM(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function Cte(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function Nu(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){Cte(s,a,o,l,d,"next",f)}function d(f){Cte(s,a,o,l,d,"throw",f)}l(void 0)})}}function A6e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function O6e(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,Ate(a.key),a)}}function _6e(t,e,n){return e&&O6e(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function r0(t,e,n){return(e=Ate(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ate(t){var e=x6e(t,"string");return XM(e)=="symbol"?e:e+""}function x6e(t,e){if(XM(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(XM(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var wo=mA.create("wasm_idv"),w6e=function(){function t(e){A6e(this,t),r0(this,"_worker",null),r0(this,"_initialized",!1),r0(this,"_connectedToIdv",!1),r0(this,"_serviceRunning",!1),r0(this,"_userId",Ome(Lve)),r0(this,"_setErrorScreen",null),e&&(this._setErrorScreen=e)}return _6e(t,[{key:"init",value:function(){var e=Nu(bn().mark(function a(){var o,s,l,d;return bn().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return g.prev=1,g.next=4,fetch("https://wasm-development.regulaforensics.com/idv/nightly/2.3/27441b5-1a9959378//PlatformAdaptor.worker.js");case 4:return o=g.sent,g.next=7,o.blob();case 7:s=g.sent,l=URL.createObjectURL(s),this._worker=new Worker(l),g.next=15;break;case 12:g.prev=12,g.t0=g.catch(1),wo("Creating worker error: ".concat(JSON.stringify(g.t0)));case 15:g.next=18;break;case 17:this._worker=new Worker("./PlatformAdaptor.worker.js");case 18:if(this._worker){g.next=20;break}return g.abrupt("return");case 20:return this._worker.postMessage({target:"gl",op:"setPrefetched",preMain:!0}),g.next=23,this.sendMessage({target:"worker-init",URL:document.URL,currentScriptUrl:"https://wasm-development.regulaforensics.com/idv/nightly/2.3/27441b5-1a9959378/",preMain:!0});case 23:return d=g.sent,d.code===0&&wo("Worker was created successfully"),g.abrupt("return",d);case 26:case"end":return g.stop()}},a,this,[[1,12]])}));function n(){return e.apply(this,arguments)}return n}()},{key:"prepareAndConnect",value:function(){var e=Nu(bn().mark(function a(o){var s,l;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return f.next=2,this.sendMessage({target:"custom",method:"connect_idv",connectionParams:{deviceDescriptor:{deviceId:this._userId,deviceType:LE.deviceType,serial:"1111111222211",macAddress:"00:00:00:00:00:00",heartbeatCadence:2},host:o.host,httpRetryCount:o.httpRetryCount||0,httpTimeoutMs:o.httpTimeoutMs||0,isSecure:(s=o.isSecure)!==null&&s!==void 0?s:!0,password:o.password,port:o.port?o.port:0,schema:o.schema?o.schema:"basic",userName:o.userName},preMain:!0});case 2:return l=f.sent,l.code===0&&(this._serviceRunning=!0,this._connectedToIdv=!0),wo("IdvWasmService result code: ".concat(l.code)),f.abrupt("return",l);case 6:case"end":return f.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"connectByUrl",value:function(){var e=Nu(bn().mark(function a(o){var s;return bn().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.next=2,this.sendMessage({target:"custom",method:"connect_by_url",connectByUrlParams:{deviceDescriptor:{deviceId:this._userId,deviceType:LE.deviceType,serial:"1111111222211",macAddress:"00:00:00:00:00:00",heartbeatCadence:2},httpRetryCount:5,httpTimeoutMs:1e3,url:o},preMain:!0});case 2:return s=d.sent,s.code===0&&(this._serviceRunning=!0,this._connectedToIdv=!0),wo("Connection by URL result code: ".concat(s.code)),d.abrupt("return",s);case 6:case"end":return d.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"startSession",value:function(){var e=Nu(bn().mark(function a(o,s,l){var d,f;return bn().wrap(function(M){for(;;)switch(M.prev=M.next){case 0:return d={workflowId:o,locale:s},l&&(_me(l)?d.metadata=l:console.log("WARN (Idv):: metadata is not an object or an empty object")),M.next=4,this.sendMessage({target:"custom",method:"start_session",sessionParams:d,preMain:!0});case 4:return f=M.sent,wo("Start session result code: ".concat(f.code)),M.abrupt("return",f);case 7:case"end":return M.stop()}},a,this)}));function n(a,o,s){return e.apply(this,arguments)}return n}()},{key:"continueSession",value:function(){var e=Nu(bn().mark(function a(o){var s,l;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return s={sessionId:o},f.next=3,this.sendMessage({continueParams:s,target:"custom",method:"continue_session",preMain:!0});case 3:return l=f.sent,wo("Continue session result code: ".concat(l.code)),f.abrupt("return",l);case 6:case"end":return f.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"listWorkflows",value:function(){var e=Nu(bn().mark(function a(){var o,s,l=arguments;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return o=l.length>0&&l[0]!==void 0?l[0]:{limit:0,skip:0},f.next=3,this.sendMessage({workflowsParams:o,target:"custom",method:"list_workflows",preMain:!0});case 3:return s=f.sent,wo("listWorkflows result code: ".concat(s.code)),f.abrupt("return",s);case 6:case"end":return f.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"getHealth",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"get_health",preMain:!0});case 2:return o=l.sent,wo("getHealth result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"getServiceToken",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"get_service_token",preMain:!0});case 2:return o=l.sent,wo("getServiceToken result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"abandonSession",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"abandon_session",preMain:!0});case 2:return o=l.sent,wo("abandonSession result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"getWorkflow",value:function(){var e=Nu(bn().mark(function a(o){var s;return bn().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.next=2,this.sendMessage({workflowIdParams:{workflowId:o},target:"custom",method:"get_workflow",preMain:!0});case 2:return s=d.sent,wo("getWorkflow result code: ".concat(s.code)),d.abrupt("return",s);case 5:case"end":return d.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"pushData",value:function(){var e=Nu(bn().mark(function a(o,s){var l;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return f.next=2,this.sendMessage({target:"custom",method:"push_data",pushDataParams:{data:s,stage:0,step:o},preMain:!0});case 2:return l=f.sent,wo("pushData result code: ".concat(l.code)),f.abrupt("return",l);case 5:case"end":return f.stop()}},a,this)}));function n(a,o){return e.apply(this,arguments)}return n}()},{key:"getSessionState",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"get_session_state",preMain:!0});case 2:return o=l.sent,wo("getSessionState result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"waitForSessionUpdate",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({waitingSessionParams:{periodMs:1e3},target:"custom",method:"wait_for_session_update",preMain:!0});case 2:return o=l.sent,wo("waitForSessionUpdate result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"disconnect",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"disconnect",preMain:!0});case 2:return o=l.sent,this._connectedToIdv=!1,this._serviceRunning=!1,wo("disconnect result code: ".concat(o.code)),l.abrupt("return",o);case 7:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"sendMessage",value:function(){var e=Nu(bn().mark(function a(o){var s=this;return bn().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.abrupt("return",new Promise(function(f,g){if(!s._worker)return g();s._worker.onmessage=function(M){var I=M.data.target;if(I==="stdout"){wo(JSON.stringify(M.data.content));return}if(I==="custom"){var y=M.data,h=y.method,m=y.data;h==="onRuntimeInitialized"&&(s._initialized=!0),f(m)}if(I==="stderr"){var N=M.data.content;wo(JSON.stringify(N)),s._setErrorScreen&&s._setErrorScreen(N)}},s._worker.postMessage(o)}));case 1:case"end":return d.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"isServiceRunning",value:function(){return this._serviceRunning}},{key:"isServiceConnected",value:function(){return this._connectedToIdv}},{key:"terminateWorker",value:function(){if(this.isServiceRunning()){var n;(n=this._worker)===null||n===void 0||n.terminate(),this._serviceRunning=!1,this._initialized=!1,this._connectedToIdv=!1}}},{key:"shutdown",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:if(this._worker){l.next=2;break}return l.abrupt("return",{code:0});case 2:if(this._connectedToIdv){l.next=5;break}return this.terminateWorker(),l.abrupt("return",{code:0});case 5:return l.next=7,this.disconnect();case 7:return o=l.sent,this.terminateWorker(),l.abrupt("return",o);case 10:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()}])}();function e4(t){"@babel/helpers - typeof";return e4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e4(t)}function Ote(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function _2(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Ote(Object(n),!0).forEach(function(a){NA(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Ote(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function NA(t,e,n){return(e=b6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function b6e(t){var e=L6e(t,"string");return e4(e)=="symbol"?e:e+""}function L6e(t,e){if(e4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(e4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Fi(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */Fi=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&e4(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(e4(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function _te(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function Jl(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){_te(s,a,o,l,d,"next",f)}function d(f){_te(s,a,o,l,d,"throw",f)}l(void 0)})}}var k6e=mA.create("store_idv"),R6e=function(e,n){return{wasmService:null,isProcessing:!1,isFinalWaitingUi:!1,setAndInitWasmService:function(){var a=Jl(Fi().mark(function s(){var l;return Fi().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return l=new w6e,f.next=3,l.init();case 3:e({wasmService:l});case 4:case"end":return f.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),setFinalWaitingUi:function(o){e({isFinalWaitingUi:o})},connectToIdv:function(o){return Jl(Fi().mark(function s(){var l,d,f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:if(!((l=n().wasmService)!==null&&l!==void 0&&l.isServiceConnected())){y.next=3;break}return y.next=3,(d=n().wasmService)===null||d===void 0?void 0:d.disconnect();case 3:return y.next=5,n().wasmService.prepareAndConnect(o);case 5:if(f=y.sent,g=null,f.code===4&&(g=YM.HTTP_ISSUE),f.code!==0&&f.code!==4&&(g=YM.PROVIDER_ERROR),g===null){y.next=12;break}return M=new Lp({errorCode:g}),y.abrupt("return",{error:M});case 12:return y.abrupt("return",{});case 13:case"end":return y.stop()}},s)}))()},connectByUrl:function(o){return Jl(Fi().mark(function s(){var l,d,f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return l=n().wasmService,y.next=3,l.connectByUrl(o);case 3:if(d=y.sent,f=null,d.code===4&&(f=YM.HTTP_ISSUE),d.code!==0&&d.code!==4&&(f=YM.PROVIDER_ERROR),f===null){y.next=13;break}return g=new Lp({errorCode:f}),M=new zh({errorCode:RE.CONNECTION_ISSUE,underlyingBaseError:g}),y.abrupt("return",{workflows:[],error:M});case 13:return y.abrupt("return",{workflows:d.data});case 14:case"end":return y.stop()}},s)}))()},workflowSessionCompletion:function(){},setWorkflowSessionCompletion:function(o){var s=function(d){var f,g=(f=n().currentSessionData)===null||f===void 0?void 0:f.sessionId,M=_2(_2({},d.results),{},{sessionId:g}),I=_2({results:M},d.error&&{error:d.error});n().setCurrentSessionDataLsAndStore(null),o(I)};e(function(){return{workflowSessionCompletion:s}})},loadModules:function(){var a=Jl(Fi().mark(function s(){var l,d,f,g;return Fi().wrap(function(I){for(;;)switch(I.prev=I.next){case 0:return l=n().externalModulesNames,I.prev=1,I.next=4,z6e(l);case 4:return d=I.sent,e(function(){return{externalModules:d}}),I.abrupt("return",{});case 9:return I.prev=9,I.t0=I.catch(1),(f=n().wasmService)===null||f===void 0||f.shutdown(),n().resetWasmService(),n().resetProps(),g=new bp({errorCode:mp.MODULES_INSTANTIATION_FAILURE}),I.abrupt("return",{error:g});case 16:case"end":return I.stop()}},s,null,[[1,9]])}));function o(){return a.apply(this,arguments)}return o}(),setProcessingTemplate:function(o){var s=HD(o.find(function(l){return l.templateId===zE}));s.templateLayout=lH(s.templateLayout,n().layout),e({processingTransformedTemplate:s})},setIsProcessing:function(o){e({isProcessing:o})},_pushStep:function(){var a=Jl(Fi().mark(function s(l,d){var f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return f=null,g=function(){var h=Jl(Fi().mark(function m(){var N,E,A,T;return Fi().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:return C.next=2,n().wasmService.pushData(l,d);case 2:if(N=C.sent,E=null,N.code===4&&(E=Nl.HTTP_ISSUE),N.code!==0&&N.code!==4&&(E=Nl.PROVIDER_ERROR),E!==null&&(A=new kp({errorCode:Nl.HTTP_ISSUE}),T=new vu({errorCode:hu.INTERNAL_ISSUE,message:"Error from external module",underlyingBaseError:A}),f=T),N.code!==0){C.next=12;break}return f=null,C.abrupt("return",N);case 12:return C.abrupt("return",null);case 13:case"end":return C.stop()}},m)}));return function(){return h.apply(this,arguments)}}(),M=function(){return null},y.next=5,BD(g,M);case 5:return y.abrupt("return",f?{error:f}:{});case 6:case"end":return y.stop()}},s)}));function o(s,l){return a.apply(this,arguments)}return o}(),_findStepById:function(o){var s=n().workflow;if(!s||!o)return null;var l=s.steps.find(function(d){return d.id===o});return l!=null?l:null},_waitingForNextStep:function(){var a=Jl(Fi().mark(function s(){var l,d,f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return l=n().currentStepId,d=null,f=function(){var h=Jl(Fi().mark(function m(){var N,E,A,T,j,C,_,L,U,H,Q,x,O,w,R;return Fi().wrap(function(V){for(;;)switch(V.prev=V.next){case 0:return V.next=2,n().wasmService.getSessionState();case 2:if(T=V.sent,j=(N=T.data)===null||N===void 0?void 0:N.currentStep,C=(E=T.data)===null||E===void 0?void 0:E.isProcessingFiles,_=(A=T.data)===null||A===void 0||(A=A.workflow)===null||A===void 0?void 0:A.steps,L=Sme(_,j),U=T.code===4,H=T.code!==0&&T.code!==4,Q=T.code===0&&(!T.data.workflow||!T.data.currentStep),x=j&&j===l,O=null,_&&!L&&(O=Nl.NOT_DATA_TYPE),U&&(O=Nl.HTTP_ISSUE),H&&(O=Nl.PROVIDER_ERROR),C&&(O=Nl.IS_PROCESSING),x&&(O=Nl.SAME_STEP),Q&&(O=Nl.DECODING_FAILED),O!==null&&(w=new kp({errorCode:O}),R=new vu({errorCode:hu.INTERNAL_ISSUE,underlyingBaseError:w}),d=R),k6e(JSON.stringify({nextStep:j,isDataType:L,isProcessingFiles:C})),!(L&&!x&&!C&&!U&&!H&&!Q)){V.next=23;break}return d=null,V.abrupt("return",T.data);case 23:return V.abrupt("return",null);case 24:case"end":return V.stop()}},m)}));return function(){return h.apply(this,arguments)}}(),g=function(){return null},y.next=6,BD(f,g);case 6:if(M=y.sent,!d){y.next=9;break}return y.abrupt("return",{error:d});case 9:return y.abrupt("return",{sessionData:M});case 10:case"end":return y.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),setFinalStepAndStopProcess:function(o){var s=o||n().currentStepId;if(s){var l=n()._findStepById(s);l&&(n().workflowSessionCompletion({results:{finalStep:{id:l.id,name:l.name,final:l.final}}}),n().resetSession(),n().listener({eventType:hp.MESSAGE,message:vp.DID_END_SESSION,module:"IDV"}))}},pushStepWaitNextStepAndSet:function(){var a=Jl(Fi().mark(function s(l){var d,f,g,M,I,y,h,m,N,E,A,T;return Fi().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:if(M=n().currentStepId,M){C.next=3;break}return C.abrupt("return");case 3:if(n().setIsProcessing(!0),!n().isFinalWaitingUi){C.next=7;break}return n().setFinalStepAndStopProcess(),C.abrupt("return");case 7:if(!(l instanceof ri)){C.next=13;break}return I=l,y=new vu({errorCode:hu.MODULES_ISSUE,message:"Error from external module",underlyingBaseError:I}),n().workflowSessionCompletion({error:y}),n().resetSession(),C.abrupt("return");case 13:return C.next=15,n()._pushStep(M,l);case 15:if(h=C.sent,!h.error){C.next=20;break}return n().workflowSessionCompletion({error:h.error}),n().resetSession(),C.abrupt("return");case 20:return C.next=22,n()._waitingForNextStep();case 22:if(m=C.sent,!m.error){C.next=27;break}return n().workflowSessionCompletion({error:m.error}),n().resetSession(),C.abrupt("return");case 27:if(N=(d=m.sessionData)===null||d===void 0?void 0:d.workflow,E=(f=m.sessionData)===null||f===void 0?void 0:f.currentStep,n().setWorkflow(N),n().setLayout(N.client.layout),n().setProcessingTemplate(N.client.steps),n().setSessionProperties((g=m.sessionData)===null||g===void 0?void 0:g.properties),A=n()._findStepById(E),T=function(L){return!!L&&Object.prototype.toString.call(L)==="[object Object]"&&L.templateId},!(A!=null&&A.final&&!T(A.client))){C.next=38;break}return n().setFinalStepAndStopProcess(A.id),C.abrupt("return");case 38:A!=null&&A.final&&T(A.client)&&n().setFinalWaitingUi(!0),n().onChangeScreen(E),n().setIsProcessing(!1);case 41:case"end":return C.stop()}},s)}));function o(s){return a.apply(this,arguments)}return o}(),onChangeScreen:function(o){if(!o)return e(function(){return{currentScreenConfig:null}});var s=n().workflow,l=n().sessionProperties,d=null;if(o===zE&&n().processingTransformedTemplate!==null){var f=n().processingTransformedTemplate;f&&(d={templateId:f.templateId,templateLayout:f.templateLayout,dataSource:null})}else{var g,M,I=n()._findStepById(o);if(typeof(I==null||(g=I.client)===null||g===void 0?void 0:g.templateId)=="string"){var y;d=_2(_2({},I==null?void 0:I.client),{},{templateId:I.client.templateId,dataSource:(y=I.dataSource)!==null&&y!==void 0?y:null,properties:l})}if(d){var h;d.sessionId=(h=n().currentSessionData)===null||h===void 0?void 0:h.sessionId,d.serviceToken=n().serviceToken}if(d&&xme(I==null||(M=I.client)===null||M===void 0?void 0:M.templateLayout)){var m=lH(I.client.templateLayout,n().layout);m&&(d.templateLayout=m)}}var N=jme(n().externalModules,s.steps,o);if(d===null||!N){var E=new vu({errorCode:hu.UNKNOWN_STEP,message:"Unsupported step template"});n().workflowSessionCompletion({error:E}),e(function(){return{currentScreenConfig:null}}),n().resetSession();return}n().setCurrentStepId(o),e(function(){return{currentScreenConfig:d}})},deinitializationIdv:function(){var a=Jl(Fi().mark(function s(){var l,d;return Fi().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return g.next=2,(l=n().wasmService)===null||l===void 0?void 0:l.shutdown();case 2:if(d=g.sent,n().resetWasmService(),n().externalModules.forEach(function(M){M.component.deinitialize&&M.component.isReady&&M.component.deinitialize()}),(d==null?void 0:d.code)!==0){g.next=7;break}return g.abrupt("return",{});case 7:return g.abrupt("return",{});case 8:case"end":return g.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),resetSession:function(){return e(function(){return{isFinalWaitingUi:!1,isProcessing:!1,processingTransformedTemplate:null,currentStepId:null,layout:null,currentScreenConfig:null,workflowId:void 0,workflow:null,serviceToken:void 0}})},resetWasmService:function(){return e(function(){return{wasmService:null}})}}};function z6e(t){return EA.apply(this,arguments)}function EA(){return EA=Jl(Fi().mark(function t(e){var n,a,o,s,l,d;return Fi().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:n=[{id:a1.getIdentifier(),supportedTemplates:a1.getSupportedTemplates(),component:a1}],a=NA(NA({},kE.LIVENESS,function(){return Promise.resolve().then(()=>Iut)}),kE.DOC_READER,function(){return Promise.resolve().then(()=>$Pt)}),o=Fi().mark(function M(){var I,y,h;return Fi().wrap(function(N){for(;;)switch(N.prev=N.next){case 0:if(I=l[s],y=function(){return a[I]()},!y){N.next=7;break}return N.next=5,y();case 5:h=N.sent,n.push({id:h.default.getIdentifier(),supportedTemplates:h.default.getSupportedTemplates(),component:h.default});case 7:case"end":return N.stop()}},M)}),s=0,l=e;case 4:if(!(s<l.length)){g.next=9;break}return g.delegateYield(o(),"t0",6);case 6:s++,g.next=4;break;case 9:return d=n.filter(function(M){return M!==null}),g.abrupt("return",d);case 11:case"end":return g.stop()}},t)})),EA.apply(this,arguments)}function x2(t){"@babel/helpers - typeof";return x2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},x2(t)}function xte(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function DA(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?xte(Object(n),!0).forEach(function(a){P6e(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):xte(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function P6e(t,e,n){return(e=U6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function U6e(t){var e=Y6e(t,"string");return x2(e)=="symbol"?e:e+""}function Y6e(t,e){if(x2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(x2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var wa=j3e(function(){return DA(DA(DA({},Pme.apply(void 0,arguments)),eNe.apply(void 0,arguments)),R6e.apply(void 0,arguments))}),wte=function(e){var n=e.children;return vi.jsx("div",{style:{position:"absolute",top:0,left:0,flex:"1 1 100%",display:"flex",justifyContent:"center",alignItems:"center",alignContent:"center",height:"100%",width:"100%",background:"white",zIndex:1},children:n})};function w2(t){"@babel/helpers - typeof";return w2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w2(t)}function bte(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function Lte(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?bte(Object(n),!0).forEach(function(a){$6e(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):bte(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function $6e(t,e,n){return(e=Q6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Q6e(t){var e=F6e(t,"string");return w2(e)=="symbol"?e:e+""}function F6e(t,e){if(w2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(w2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var H6e=function(){var e=wa(function(h){return h.currentScreenConfig}),n=wa(function(h){return h.pushStepWaitNextStepAndSet}),a=wa(function(h){return h.processingTransformedTemplate}),o=wa(function(h){return h.isProcessing}),s=wa(function(h){return h.setIsProcessing}),l=wa(function(h){return h.listener}),d=wa(function(h){return h.externalModules}),f=wa(function(h){return h.modulesConfig}),g=function(m,N){l({eventType:hp.MESSAGE,message:N,module:m})},M=function(m){s(m)},I=function(m){s(!1),n(m)},y=ht.useCallback(function(){if(!e)return null;var h=d.find(function(m){return m.supportedTemplates.includes(e.templateId)});if(h&&e)return vi.jsx(h.component,{perform:I,moduleProps:e,modulesConfig:f,idvEventListener:g,isProcessing:M})},[e,d]);return!e&&!a?vi.jsx(qE,{direction:_h.Ltr,children:vi.jsx(wte,{children:"Waiting for play... or process completed"})}):vi.jsx(vi.Fragment,{children:vi.jsx(qE,{direction:_h.Ltr,children:vi.jsxs(vi.Fragment,{children:[o&&vi.jsx(wte,{children:a?vi.jsx(a1,{perform:I,moduleProps:Lte(Lte({},a),{},{templateId:"PROGRESS"}),idvEventListener:g,isProcessing:M}):"Processing..."}),y()]})})})};function V6e(){return vi.jsx(ht.StrictMode,{children:vi.jsx(n3e,{children:vi.jsx(H6e,{})})})}function n0(t){"@babel/helpers - typeof";return n0=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n0(t)}function B6e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function kte(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,zte(a.key),a)}}function G6e(t,e,n){return e&&kte(t.prototype,e),n&&kte(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function Z6e(t,e,n){return e=L2(e),W6e(t,jA()?Reflect.construct(e,[],L2(t).constructor):e.apply(t,n))}function W6e(t,e){if(e&&(n0(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return K6e(t)}function K6e(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function q6e(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&b2(t,e)}function TA(t){var e=typeof Map=="function"?new Map:void 0;return TA=function(a){if(a===null||!X6e(a))return a;if(typeof a!="function")throw new TypeError("Super expression must either be null or a function");if(e!==void 0){if(e.has(a))return e.get(a);e.set(a,o)}function o(){return J6e(a,arguments,L2(this).constructor)}return o.prototype=Object.create(a.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),b2(o,a)},TA(t)}function J6e(t,e,n){if(jA())return Reflect.construct.apply(null,arguments);var a=[null];a.push.apply(a,e);var o=new(t.bind.apply(t,a));return n&&b2(o,n.prototype),o}function jA(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(jA=function(){return!!t})()}function X6e(t){try{return Function.toString.call(t).indexOf("[native code]")!==-1}catch(e){return typeof t=="function"}}function b2(t,e){return b2=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},b2(t,e)}function L2(t){return L2=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},L2(t)}function Rte(t,e,n){return(e=zte(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function zte(t){var e=e_e(t,"string");return n0(e)=="symbol"?e:e+""}function e_e(t,e){if(n0(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(n0(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var t_e="*,::after,::before{box-sizing:border-box}h1,h2,h3,h4,p,ul{padding:0;margin:0}li{list-style:none}:host{display:block;container-type:inline-size;container-name:host;width:100%;height:100%}",Pte=function(t){function e(){var n;return B6e(this,e),n=Z6e(this,e),Rte(n,"_root",Ave.createRoot(n.attachShadow({mode:"open"}))),Rte(n,"_mounted",!1),n}return q6e(e,t),G6e(e,[{key:"connectedCallback",value:function(){this.render(),this._mounted=!0}},{key:"version",get:function(){return"".concat("2.3.150-nightly".trim())}},{key:"render",value:function(){this._root.render(vi.jsxs("div",{part:"idv",className:"idv",style:{backgroundColor:"white",height:"100%"},children:[vi.jsx("style",{nonce:wa.getState().getNonce(),children:t_e}),vi.jsx(V6e,{})]}))}},{key:"disconnectedCallback",value:function(){var a=this;setTimeout(function(){a._mounted&&(a._mounted=!1,a._root.unmount(),mA.cleanLogs())})}}],[{key:"observedAttributes",get:function(){return[]}}])}(TA(HTMLElement));function t4(t){"@babel/helpers - typeof";return t4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t4(t)}function sl(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */sl=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&t4(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(t4(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function Ute(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function i0(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){Ute(s,a,o,l,d,"next",f)}function d(f){Ute(s,a,o,l,d,"throw",f)}l(void 0)})}}function r_e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function n_e(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a_e(a.key),a)}}function i_e(t,e,n){return e&&n_e(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function a_e(t){var e=o_e(t,"string");return t4(e)=="symbol"?e:e+""}function o_e(t,e){if(t4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(t4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var u_e=function(){function t(){r_e(this,t)}return i_e(t,[{key:"initialize",value:function(){var e=i0(sl().mark(function a(o){var s;return sl().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return s=wa.getState().initialize(o),d.abrupt("return",s);case 2:case"end":return d.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"configure",value:function(){var e=i0(sl().mark(function a(o){var s,l;return sl().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(typeof o=="string"){f.next=5;break}return f.next=3,wa.getState().configure(o);case 3:return s=f.sent,f.abrupt("return",s);case 5:return f.next=7,wa.getState().configureWithUrl(o);case 7:return l=f.sent,f.abrupt("return",l);case 9:case"end":return f.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"getWorkFlows",value:function(){var e=i0(sl().mark(function a(o){var s;return sl().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.next=2,wa.getState().getWorkflows(o);case 2:return s=d.sent,d.abrupt("return",s);case 4:case"end":return d.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"prepareWorkflow",value:function(){var e=i0(sl().mark(function a(o){var s,l;return sl().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return s=o.workflowId,f.next=3,wa.getState().prepareWorkflowAndPrepareUi(s);case 3:return l=f.sent,f.abrupt("return",l);case 5:case"end":return f.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"startWorkflow",value:function(){var e=i0(sl().mark(function a(o){var s,l,d,f;return sl().wrap(function(M){for(;;)switch(M.prev=M.next){case 0:return s=o==null?void 0:o.locale,l=o==null?void 0:o.metadata,d=Lme(s),M.next=5,wa.getState().startNewSession(d,l);case 5:if(f=M.sent,!f.error){M.next=8;break}return M.abrupt("return",f);case 8:return M.abrupt("return",new Promise(function(I){var y=function(m){I(m)};wa.getState().playWorkflow(y)}));case 9:case"end":return M.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"deinitialize",value:function(){var e=i0(sl().mark(function a(){var o;return sl().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,wa.getState().deinitialize();case 2:return o=l.sent,l.abrupt("return",o);case 4:case"end":return l.stop()}},a)}));function n(){return e.apply(this,arguments)}return n}()},{key:"version",get:function(){var n;return(n="2.3.150-nightly")!==null&&n!==void 0?n:"Version unavailable. Something went wrong"}},{key:"setNonce",value:function(n){wa.getState().setNonce(n)}},{key:"eventListener",set:function(n){if(!n||typeof n!="function"){console.warn("IdvIntegrationService:: listener is not a function");return}wa.getState().setListener(n)}},{key:"sessionRestoreMode",set:function(n){wa.getState().setSessionRestoreMode(n)}},{key:"currentSessionId",get:function(){return wa.getState().getCurrentSessionId()}}])}(),s_e=window.customElements.get("idv-flow");s_e||window.customElements.define("idv-flow",Pte);var l_e=Object.defineProperty,c_e=Object.defineProperties,f_e=Object.getOwnPropertyDescriptors,Yte=Object.getOwnPropertySymbols,d_e=Object.prototype.hasOwnProperty,g_e=Object.prototype.propertyIsEnumerable,$te=(t,e,n)=>e in t?l_e(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,SA=(t,e)=>{for(var n in e||(e={}))d_e.call(e,n)&&$te(t,n,e[n]);if(Yte)for(var n of Yte(e))g_e.call(e,n)&&$te(t,n,e[n]);return t},M_e=(t,e)=>c_e(t,f_e(e)),bo=(t,e,n)=>new Promise((a,o)=>{var s=f=>{try{d(n.next(f))}catch(g){o(g)}},l=f=>{try{d(n.throw(f))}catch(g){o(g)}},d=f=>f.done?a(f.value):Promise.resolve(f.value).then(s,l);d((n=n.apply(t,e)).next())}),Qte=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function Fte(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Hte={exports:{}},k2={},Vte={exports:{}},rn={},Bte;function p_e(){if(Bte)return rn;Bte=1;/**
|
|
85
|
+
`),a=new Blob([n],{type:"text/plain"}),o=window.URL.createObjectURL(a),s=document.createElement("a");s.download="log.txt",s.href=o,s.click(),window.URL.revokeObjectURL(o),this.cleanLogs()}}}])}(),mA=new C6e;function XM(t){"@babel/helpers - typeof";return XM=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},XM(t)}function bn(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */bn=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&XM(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(XM(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function Cte(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function Nu(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){Cte(s,a,o,l,d,"next",f)}function d(f){Cte(s,a,o,l,d,"throw",f)}l(void 0)})}}function A6e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function O6e(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,Ate(a.key),a)}}function _6e(t,e,n){return e&&O6e(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function r0(t,e,n){return(e=Ate(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ate(t){var e=x6e(t,"string");return XM(e)=="symbol"?e:e+""}function x6e(t,e){if(XM(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(XM(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var wo=mA.create("wasm_idv"),w6e=function(){function t(e){A6e(this,t),r0(this,"_worker",null),r0(this,"_initialized",!1),r0(this,"_connectedToIdv",!1),r0(this,"_serviceRunning",!1),r0(this,"_userId",Ome(Lve)),r0(this,"_setErrorScreen",null),e&&(this._setErrorScreen=e)}return _6e(t,[{key:"init",value:function(){var e=Nu(bn().mark(function a(){var o,s,l,d;return bn().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return g.prev=1,g.next=4,fetch("https://wasm-development.regulaforensics.com/idv/nightly/2.3/570d971-bca5a312c//PlatformAdaptor.worker.js");case 4:return o=g.sent,g.next=7,o.blob();case 7:s=g.sent,l=URL.createObjectURL(s),this._worker=new Worker(l),g.next=15;break;case 12:g.prev=12,g.t0=g.catch(1),wo("Creating worker error: ".concat(JSON.stringify(g.t0)));case 15:g.next=18;break;case 17:this._worker=new Worker("./PlatformAdaptor.worker.js");case 18:if(this._worker){g.next=20;break}return g.abrupt("return");case 20:return this._worker.postMessage({target:"gl",op:"setPrefetched",preMain:!0}),g.next=23,this.sendMessage({target:"worker-init",URL:document.URL,currentScriptUrl:"https://wasm-development.regulaforensics.com/idv/nightly/2.3/570d971-bca5a312c/",preMain:!0});case 23:return d=g.sent,d.code===0&&wo("Worker was created successfully"),g.abrupt("return",d);case 26:case"end":return g.stop()}},a,this,[[1,12]])}));function n(){return e.apply(this,arguments)}return n}()},{key:"prepareAndConnect",value:function(){var e=Nu(bn().mark(function a(o){var s,l;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return f.next=2,this.sendMessage({target:"custom",method:"connect_idv",connectionParams:{deviceDescriptor:{deviceId:this._userId,deviceType:LE.deviceType,serial:"1111111222211",macAddress:"00:00:00:00:00:00",heartbeatCadence:2},host:o.host,httpRetryCount:o.httpRetryCount||0,httpTimeoutMs:o.httpTimeoutMs||0,isSecure:(s=o.isSecure)!==null&&s!==void 0?s:!0,password:o.password,port:o.port?o.port:0,schema:o.schema?o.schema:"basic",userName:o.userName},preMain:!0});case 2:return l=f.sent,l.code===0&&(this._serviceRunning=!0,this._connectedToIdv=!0),wo("IdvWasmService result code: ".concat(l.code)),f.abrupt("return",l);case 6:case"end":return f.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"connectByUrl",value:function(){var e=Nu(bn().mark(function a(o){var s;return bn().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.next=2,this.sendMessage({target:"custom",method:"connect_by_url",connectByUrlParams:{deviceDescriptor:{deviceId:this._userId,deviceType:LE.deviceType,serial:"1111111222211",macAddress:"00:00:00:00:00:00",heartbeatCadence:2},httpRetryCount:5,httpTimeoutMs:1e3,url:o},preMain:!0});case 2:return s=d.sent,s.code===0&&(this._serviceRunning=!0,this._connectedToIdv=!0),wo("Connection by URL result code: ".concat(s.code)),d.abrupt("return",s);case 6:case"end":return d.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"startSession",value:function(){var e=Nu(bn().mark(function a(o,s,l){var d,f;return bn().wrap(function(M){for(;;)switch(M.prev=M.next){case 0:return d={workflowId:o,locale:s},l&&(_me(l)?d.metadata=l:console.log("WARN (Idv):: metadata is not an object or an empty object")),M.next=4,this.sendMessage({target:"custom",method:"start_session",sessionParams:d,preMain:!0});case 4:return f=M.sent,wo("Start session result code: ".concat(f.code)),M.abrupt("return",f);case 7:case"end":return M.stop()}},a,this)}));function n(a,o,s){return e.apply(this,arguments)}return n}()},{key:"continueSession",value:function(){var e=Nu(bn().mark(function a(o,s){var l,d;return bn().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return l={sessionId:o,locale:s},g.next=3,this.sendMessage({continueParams:l,target:"custom",method:"continue_session",preMain:!0});case 3:return d=g.sent,wo("Continue session result code: ".concat(d.code)),g.abrupt("return",d);case 6:case"end":return g.stop()}},a,this)}));function n(a,o){return e.apply(this,arguments)}return n}()},{key:"listWorkflows",value:function(){var e=Nu(bn().mark(function a(){var o,s,l=arguments;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return o=l.length>0&&l[0]!==void 0?l[0]:{limit:0,skip:0},f.next=3,this.sendMessage({workflowsParams:o,target:"custom",method:"list_workflows",preMain:!0});case 3:return s=f.sent,wo("listWorkflows result code: ".concat(s.code)),f.abrupt("return",s);case 6:case"end":return f.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"getHealth",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"get_health",preMain:!0});case 2:return o=l.sent,wo("getHealth result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"getServiceToken",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"get_service_token",preMain:!0});case 2:return o=l.sent,wo("getServiceToken result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"abandonSession",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"abandon_session",preMain:!0});case 2:return o=l.sent,wo("abandonSession result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"getWorkflow",value:function(){var e=Nu(bn().mark(function a(o){var s;return bn().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.next=2,this.sendMessage({workflowIdParams:{workflowId:o},target:"custom",method:"get_workflow",preMain:!0});case 2:return s=d.sent,wo("getWorkflow result code: ".concat(s.code)),d.abrupt("return",s);case 5:case"end":return d.stop()}},a,this)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"pushData",value:function(){var e=Nu(bn().mark(function a(o,s){var l;return bn().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return f.next=2,this.sendMessage({target:"custom",method:"push_data",pushDataParams:{data:s,stage:0,step:o},preMain:!0});case 2:return l=f.sent,wo("pushData result code: ".concat(l.code)),f.abrupt("return",l);case 5:case"end":return f.stop()}},a,this)}));function n(a,o){return e.apply(this,arguments)}return n}()},{key:"getSessionState",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"get_session_state",preMain:!0});case 2:return o=l.sent,wo("getSessionState result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"waitForSessionUpdate",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({waitingSessionParams:{periodMs:1e3},target:"custom",method:"wait_for_session_update",preMain:!0});case 2:return o=l.sent,wo("waitForSessionUpdate result code: ".concat(o.code)),l.abrupt("return",o);case 5:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"disconnect",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,this.sendMessage({target:"custom",method:"disconnect",preMain:!0});case 2:return o=l.sent,this._connectedToIdv=!1,this._serviceRunning=!1,wo("disconnect result code: ".concat(o.code)),l.abrupt("return",o);case 7:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()},{key:"sendMessage",value:function(){var e=Nu(bn().mark(function a(o){var s=this;return bn().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.abrupt("return",new Promise(function(f,g){if(!s._worker)return g();s._worker.onmessage=function(M){var I=M.data.target;if(I==="stdout"){wo(JSON.stringify(M.data.content));return}if(I==="custom"){var y=M.data,h=y.method,m=y.data;h==="onRuntimeInitialized"&&(s._initialized=!0),f(m)}if(I==="stderr"){var N=M.data.content;wo(JSON.stringify(N)),s._setErrorScreen&&s._setErrorScreen(N)}},s._worker.postMessage(o)}));case 1:case"end":return d.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"isServiceRunning",value:function(){return this._serviceRunning}},{key:"isServiceConnected",value:function(){return this._connectedToIdv}},{key:"terminateWorker",value:function(){if(this.isServiceRunning()){var n;(n=this._worker)===null||n===void 0||n.terminate(),this._serviceRunning=!1,this._initialized=!1,this._connectedToIdv=!1}}},{key:"shutdown",value:function(){var e=Nu(bn().mark(function a(){var o;return bn().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:if(this._worker){l.next=2;break}return l.abrupt("return",{code:0});case 2:if(this._connectedToIdv){l.next=5;break}return this.terminateWorker(),l.abrupt("return",{code:0});case 5:return l.next=7,this.disconnect();case 7:return o=l.sent,this.terminateWorker(),l.abrupt("return",o);case 10:case"end":return l.stop()}},a,this)}));function n(){return e.apply(this,arguments)}return n}()}])}();function e4(t){"@babel/helpers - typeof";return e4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e4(t)}function Ote(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function _2(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Ote(Object(n),!0).forEach(function(a){NA(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Ote(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function NA(t,e,n){return(e=b6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function b6e(t){var e=L6e(t,"string");return e4(e)=="symbol"?e:e+""}function L6e(t,e){if(e4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(e4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Fi(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */Fi=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&e4(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(e4(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function _te(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function Jl(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){_te(s,a,o,l,d,"next",f)}function d(f){_te(s,a,o,l,d,"throw",f)}l(void 0)})}}var k6e=mA.create("store_idv"),R6e=function(e,n){return{wasmService:null,isProcessing:!1,isFinalWaitingUi:!1,setAndInitWasmService:function(){var a=Jl(Fi().mark(function s(){var l;return Fi().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return l=new w6e,f.next=3,l.init();case 3:e({wasmService:l});case 4:case"end":return f.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),setFinalWaitingUi:function(o){e({isFinalWaitingUi:o})},connectToIdv:function(o){return Jl(Fi().mark(function s(){var l,d,f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:if(!((l=n().wasmService)!==null&&l!==void 0&&l.isServiceConnected())){y.next=3;break}return y.next=3,(d=n().wasmService)===null||d===void 0?void 0:d.disconnect();case 3:return y.next=5,n().wasmService.prepareAndConnect(o);case 5:if(f=y.sent,g=null,f.code===4&&(g=YM.HTTP_ISSUE),f.code!==0&&f.code!==4&&(g=YM.PROVIDER_ERROR),g===null){y.next=12;break}return M=new Lp({errorCode:g}),y.abrupt("return",{error:M});case 12:return y.abrupt("return",{});case 13:case"end":return y.stop()}},s)}))()},connectByUrl:function(o){return Jl(Fi().mark(function s(){var l,d,f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return l=n().wasmService,y.next=3,l.connectByUrl(o);case 3:if(d=y.sent,f=null,d.code===4&&(f=YM.HTTP_ISSUE),d.code!==0&&d.code!==4&&(f=YM.PROVIDER_ERROR),f===null){y.next=13;break}return g=new Lp({errorCode:f}),M=new zh({errorCode:RE.CONNECTION_ISSUE,underlyingBaseError:g}),y.abrupt("return",{workflows:[],error:M});case 13:return y.abrupt("return",{workflows:d.data});case 14:case"end":return y.stop()}},s)}))()},workflowSessionCompletion:function(){},setWorkflowSessionCompletion:function(o){var s=function(d){var f,g=(f=n().currentSessionData)===null||f===void 0?void 0:f.sessionId,M=_2(_2({},d.results),{},{sessionId:g}),I=_2({results:M},d.error&&{error:d.error});n().setCurrentSessionDataLsAndStore(null),o(I)};e(function(){return{workflowSessionCompletion:s}})},loadModules:function(){var a=Jl(Fi().mark(function s(){var l,d,f,g;return Fi().wrap(function(I){for(;;)switch(I.prev=I.next){case 0:return l=n().externalModulesNames,I.prev=1,I.next=4,z6e(l);case 4:return d=I.sent,e(function(){return{externalModules:d}}),I.abrupt("return",{});case 9:return I.prev=9,I.t0=I.catch(1),(f=n().wasmService)===null||f===void 0||f.shutdown(),n().resetWasmService(),n().resetProps(),g=new bp({errorCode:mp.MODULES_INSTANTIATION_FAILURE}),I.abrupt("return",{error:g});case 16:case"end":return I.stop()}},s,null,[[1,9]])}));function o(){return a.apply(this,arguments)}return o}(),setProcessingTemplate:function(o){var s=HD(o.find(function(l){return l.templateId===zE}));s.templateLayout=lH(s.templateLayout,n().layout),e({processingTransformedTemplate:s})},setIsProcessing:function(o){e({isProcessing:o})},_pushStep:function(){var a=Jl(Fi().mark(function s(l,d){var f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return f=null,g=function(){var h=Jl(Fi().mark(function m(){var N,E,A,T;return Fi().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:return C.next=2,n().wasmService.pushData(l,d);case 2:if(N=C.sent,E=null,N.code===4&&(E=Nl.HTTP_ISSUE),N.code!==0&&N.code!==4&&(E=Nl.PROVIDER_ERROR),E!==null&&(A=new kp({errorCode:Nl.HTTP_ISSUE}),T=new vu({errorCode:hu.INTERNAL_ISSUE,message:"Error from external module",underlyingBaseError:A}),f=T),N.code!==0){C.next=12;break}return f=null,C.abrupt("return",N);case 12:return C.abrupt("return",null);case 13:case"end":return C.stop()}},m)}));return function(){return h.apply(this,arguments)}}(),M=function(){return null},y.next=5,BD(g,M);case 5:return y.abrupt("return",f?{error:f}:{});case 6:case"end":return y.stop()}},s)}));function o(s,l){return a.apply(this,arguments)}return o}(),_findStepById:function(o){var s=n().workflow;if(!s||!o)return null;var l=s.steps.find(function(d){return d.id===o});return l!=null?l:null},_waitingForNextStep:function(){var a=Jl(Fi().mark(function s(){var l,d,f,g,M;return Fi().wrap(function(y){for(;;)switch(y.prev=y.next){case 0:return l=n().currentStepId,d=null,f=function(){var h=Jl(Fi().mark(function m(){var N,E,A,T,j,C,_,L,U,H,Q,x,O,w,R;return Fi().wrap(function(V){for(;;)switch(V.prev=V.next){case 0:return V.next=2,n().wasmService.getSessionState();case 2:if(T=V.sent,j=(N=T.data)===null||N===void 0?void 0:N.currentStep,C=(E=T.data)===null||E===void 0?void 0:E.isProcessingFiles,_=(A=T.data)===null||A===void 0||(A=A.workflow)===null||A===void 0?void 0:A.steps,L=Sme(_,j),U=T.code===4,H=T.code!==0&&T.code!==4,Q=T.code===0&&(!T.data.workflow||!T.data.currentStep),x=j&&j===l,O=null,_&&!L&&(O=Nl.NOT_DATA_TYPE),U&&(O=Nl.HTTP_ISSUE),H&&(O=Nl.PROVIDER_ERROR),C&&(O=Nl.IS_PROCESSING),x&&(O=Nl.SAME_STEP),Q&&(O=Nl.DECODING_FAILED),O!==null&&(w=new kp({errorCode:O}),R=new vu({errorCode:hu.INTERNAL_ISSUE,underlyingBaseError:w}),d=R),k6e(JSON.stringify({nextStep:j,isDataType:L,isProcessingFiles:C})),!(L&&!x&&!C&&!U&&!H&&!Q)){V.next=23;break}return d=null,V.abrupt("return",T.data);case 23:return V.abrupt("return",null);case 24:case"end":return V.stop()}},m)}));return function(){return h.apply(this,arguments)}}(),g=function(){return null},y.next=6,BD(f,g);case 6:if(M=y.sent,!d){y.next=9;break}return y.abrupt("return",{error:d});case 9:return y.abrupt("return",{sessionData:M});case 10:case"end":return y.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),setFinalStepAndStopProcess:function(o){var s=o||n().currentStepId;if(s){var l=n()._findStepById(s);l&&(n().workflowSessionCompletion({results:{finalStep:{id:l.id,name:l.name,final:l.final}}}),n().resetSession(),n().listener({eventType:hp.MESSAGE,message:vp.DID_END_SESSION,module:"IDV"}))}},pushStepWaitNextStepAndSet:function(){var a=Jl(Fi().mark(function s(l){var d,f,g,M,I,y,h,m,N,E,A,T;return Fi().wrap(function(C){for(;;)switch(C.prev=C.next){case 0:if(M=n().currentStepId,M){C.next=3;break}return C.abrupt("return");case 3:if(n().setIsProcessing(!0),!n().isFinalWaitingUi){C.next=7;break}return n().setFinalStepAndStopProcess(),C.abrupt("return");case 7:if(!(l instanceof ri)){C.next=13;break}return I=l,y=new vu({errorCode:hu.MODULES_ISSUE,message:"Error from external module",underlyingBaseError:I}),n().workflowSessionCompletion({error:y}),n().resetSession(),C.abrupt("return");case 13:return C.next=15,n()._pushStep(M,l);case 15:if(h=C.sent,!h.error){C.next=20;break}return n().workflowSessionCompletion({error:h.error}),n().resetSession(),C.abrupt("return");case 20:return C.next=22,n()._waitingForNextStep();case 22:if(m=C.sent,!m.error){C.next=27;break}return n().workflowSessionCompletion({error:m.error}),n().resetSession(),C.abrupt("return");case 27:if(N=(d=m.sessionData)===null||d===void 0?void 0:d.workflow,E=(f=m.sessionData)===null||f===void 0?void 0:f.currentStep,n().setWorkflow(N),n().setLayout(N.client.layout),n().setProcessingTemplate(N.client.steps),n().setSessionProperties((g=m.sessionData)===null||g===void 0?void 0:g.properties),A=n()._findStepById(E),T=function(L){return!!L&&Object.prototype.toString.call(L)==="[object Object]"&&L.templateId},!(A!=null&&A.final&&!T(A.client))){C.next=38;break}return n().setFinalStepAndStopProcess(A.id),C.abrupt("return");case 38:A!=null&&A.final&&T(A.client)&&n().setFinalWaitingUi(!0),n().onChangeScreen(E),n().setIsProcessing(!1);case 41:case"end":return C.stop()}},s)}));function o(s){return a.apply(this,arguments)}return o}(),onChangeScreen:function(o){if(!o)return e(function(){return{currentScreenConfig:null}});var s=n().workflow,l=n().sessionProperties,d=null;if(o===zE&&n().processingTransformedTemplate!==null){var f=n().processingTransformedTemplate;f&&(d={templateId:f.templateId,templateLayout:f.templateLayout,dataSource:null})}else{var g,M,I=n()._findStepById(o);if(typeof(I==null||(g=I.client)===null||g===void 0?void 0:g.templateId)=="string"){var y;d=_2(_2({},I==null?void 0:I.client),{},{templateId:I.client.templateId,dataSource:(y=I.dataSource)!==null&&y!==void 0?y:null,properties:l})}if(d){var h;d.sessionId=(h=n().currentSessionData)===null||h===void 0?void 0:h.sessionId,d.serviceToken=n().serviceToken}if(d&&xme(I==null||(M=I.client)===null||M===void 0?void 0:M.templateLayout)){var m=lH(I.client.templateLayout,n().layout);m&&(d.templateLayout=m)}}var N=jme(n().externalModules,s.steps,o);if(d===null||!N){var E=new vu({errorCode:hu.UNKNOWN_STEP,message:"Unsupported step template"});n().workflowSessionCompletion({error:E}),e(function(){return{currentScreenConfig:null}}),n().resetSession();return}n().setCurrentStepId(o),e(function(){return{currentScreenConfig:d}})},deinitializationIdv:function(){var a=Jl(Fi().mark(function s(){var l,d;return Fi().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:return g.next=2,(l=n().wasmService)===null||l===void 0?void 0:l.shutdown();case 2:if(d=g.sent,n().resetWasmService(),n().externalModules.forEach(function(M){M.component.deinitialize&&M.component.isReady&&M.component.deinitialize()}),(d==null?void 0:d.code)!==0){g.next=7;break}return g.abrupt("return",{});case 7:return g.abrupt("return",{});case 8:case"end":return g.stop()}},s)}));function o(){return a.apply(this,arguments)}return o}(),resetSession:function(){return e(function(){return{isFinalWaitingUi:!1,isProcessing:!1,processingTransformedTemplate:null,currentStepId:null,layout:null,currentScreenConfig:null,workflowId:void 0,workflow:null,serviceToken:void 0}})},resetWasmService:function(){return e(function(){return{wasmService:null}})}}};function z6e(t){return EA.apply(this,arguments)}function EA(){return EA=Jl(Fi().mark(function t(e){var n,a,o,s,l,d;return Fi().wrap(function(g){for(;;)switch(g.prev=g.next){case 0:n=[{id:a1.getIdentifier(),supportedTemplates:a1.getSupportedTemplates(),component:a1}],a=NA(NA({},kE.LIVENESS,function(){return Promise.resolve().then(()=>Iut)}),kE.DOC_READER,function(){return Promise.resolve().then(()=>$Pt)}),o=Fi().mark(function M(){var I,y,h;return Fi().wrap(function(N){for(;;)switch(N.prev=N.next){case 0:if(I=l[s],y=function(){return a[I]()},!y){N.next=7;break}return N.next=5,y();case 5:h=N.sent,n.push({id:h.default.getIdentifier(),supportedTemplates:h.default.getSupportedTemplates(),component:h.default});case 7:case"end":return N.stop()}},M)}),s=0,l=e;case 4:if(!(s<l.length)){g.next=9;break}return g.delegateYield(o(),"t0",6);case 6:s++,g.next=4;break;case 9:return d=n.filter(function(M){return M!==null}),g.abrupt("return",d);case 11:case"end":return g.stop()}},t)})),EA.apply(this,arguments)}function x2(t){"@babel/helpers - typeof";return x2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},x2(t)}function xte(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function DA(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?xte(Object(n),!0).forEach(function(a){P6e(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):xte(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function P6e(t,e,n){return(e=U6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function U6e(t){var e=Y6e(t,"string");return x2(e)=="symbol"?e:e+""}function Y6e(t,e){if(x2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(x2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var wa=j3e(function(){return DA(DA(DA({},Pme.apply(void 0,arguments)),eNe.apply(void 0,arguments)),R6e.apply(void 0,arguments))}),wte=function(e){var n=e.children;return vi.jsx("div",{style:{position:"absolute",top:0,left:0,flex:"1 1 100%",display:"flex",justifyContent:"center",alignItems:"center",alignContent:"center",height:"100%",width:"100%",background:"white",zIndex:1},children:n})};function w2(t){"@babel/helpers - typeof";return w2=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w2(t)}function bte(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,a)}return n}function Lte(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?bte(Object(n),!0).forEach(function(a){$6e(t,a,n[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):bte(Object(n)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(n,a))})}return t}function $6e(t,e,n){return(e=Q6e(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Q6e(t){var e=F6e(t,"string");return w2(e)=="symbol"?e:e+""}function F6e(t,e){if(w2(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(w2(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var H6e=function(){var e=wa(function(h){return h.currentScreenConfig}),n=wa(function(h){return h.pushStepWaitNextStepAndSet}),a=wa(function(h){return h.processingTransformedTemplate}),o=wa(function(h){return h.isProcessing}),s=wa(function(h){return h.setIsProcessing}),l=wa(function(h){return h.listener}),d=wa(function(h){return h.externalModules}),f=wa(function(h){return h.modulesConfig}),g=function(m,N){l({eventType:hp.MESSAGE,message:N,module:m})},M=function(m){s(m)},I=function(m){s(!1),n(m)},y=ht.useCallback(function(){if(!e)return null;var h=d.find(function(m){return m.supportedTemplates.includes(e.templateId)});if(h&&e)return vi.jsx(h.component,{perform:I,moduleProps:e,modulesConfig:f,idvEventListener:g,isProcessing:M})},[e,d]);return!e&&!a?vi.jsx(qE,{direction:_h.Ltr,children:vi.jsx(wte,{children:"Waiting for play... or process completed"})}):vi.jsx(vi.Fragment,{children:vi.jsx(qE,{direction:_h.Ltr,children:vi.jsxs(vi.Fragment,{children:[o&&vi.jsx(wte,{children:a?vi.jsx(a1,{perform:I,moduleProps:Lte(Lte({},a),{},{templateId:"PROGRESS"}),idvEventListener:g,isProcessing:M}):"Processing..."}),y()]})})})};function V6e(){return vi.jsx(ht.StrictMode,{children:vi.jsx(n3e,{children:vi.jsx(H6e,{})})})}function n0(t){"@babel/helpers - typeof";return n0=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n0(t)}function B6e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function kte(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,zte(a.key),a)}}function G6e(t,e,n){return e&&kte(t.prototype,e),n&&kte(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function Z6e(t,e,n){return e=L2(e),W6e(t,jA()?Reflect.construct(e,[],L2(t).constructor):e.apply(t,n))}function W6e(t,e){if(e&&(n0(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return K6e(t)}function K6e(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function q6e(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&b2(t,e)}function TA(t){var e=typeof Map=="function"?new Map:void 0;return TA=function(a){if(a===null||!X6e(a))return a;if(typeof a!="function")throw new TypeError("Super expression must either be null or a function");if(e!==void 0){if(e.has(a))return e.get(a);e.set(a,o)}function o(){return J6e(a,arguments,L2(this).constructor)}return o.prototype=Object.create(a.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),b2(o,a)},TA(t)}function J6e(t,e,n){if(jA())return Reflect.construct.apply(null,arguments);var a=[null];a.push.apply(a,e);var o=new(t.bind.apply(t,a));return n&&b2(o,n.prototype),o}function jA(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(jA=function(){return!!t})()}function X6e(t){try{return Function.toString.call(t).indexOf("[native code]")!==-1}catch(e){return typeof t=="function"}}function b2(t,e){return b2=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},b2(t,e)}function L2(t){return L2=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},L2(t)}function Rte(t,e,n){return(e=zte(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function zte(t){var e=e_e(t,"string");return n0(e)=="symbol"?e:e+""}function e_e(t,e){if(n0(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(n0(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var t_e="*,::after,::before{box-sizing:border-box}h1,h2,h3,h4,p,ul{padding:0;margin:0}li{list-style:none}:host{display:block;container-type:inline-size;container-name:host;width:100%;height:100%}",Pte=function(t){function e(){var n;return B6e(this,e),n=Z6e(this,e),Rte(n,"_root",Ave.createRoot(n.attachShadow({mode:"open"}))),Rte(n,"_mounted",!1),n}return q6e(e,t),G6e(e,[{key:"connectedCallback",value:function(){this.render(),this._mounted=!0}},{key:"version",get:function(){return"".concat("2.3.152-nightly".trim())}},{key:"render",value:function(){this._root.render(vi.jsxs("div",{part:"idv",className:"idv",style:{backgroundColor:"white",height:"100%"},children:[vi.jsx("style",{nonce:wa.getState().getNonce(),children:t_e}),vi.jsx(V6e,{})]}))}},{key:"disconnectedCallback",value:function(){var a=this;setTimeout(function(){a._mounted&&(a._mounted=!1,a._root.unmount(),mA.cleanLogs())})}}],[{key:"observedAttributes",get:function(){return[]}}])}(TA(HTMLElement));function t4(t){"@babel/helpers - typeof";return t4=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t4(t)}function sl(){/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */sl=function(){return e};var t,e={},n=Object.prototype,a=n.hasOwnProperty,o=typeof Symbol=="function"?Symbol:{},s=o.iterator||"@@iterator",l=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function f(x,O,w,R){return Object.defineProperty(x,O,{value:w,enumerable:!R,configurable:!R,writable:!R})}try{f({},"")}catch(x){f=function(w,R,Y){return w[R]=Y}}function g(x,O,w,R){var Y=O&&O.prototype instanceof y?O:y,V=Object.create(Y.prototype);return f(V,"_invoke",function(q,te,z){var G=1;return function(K,k){if(G===3)throw Error("Generator is already running");if(G===4){if(K==="throw")throw k;return{value:t,done:!0}}for(z.method=K,z.arg=k;;){var W=z.delegate;if(W){var pe=_(W,z);if(pe){if(pe===I)continue;return pe}}if(z.method==="next")z.sent=z._sent=z.arg;else if(z.method==="throw"){if(G===1)throw G=4,z.arg;z.dispatchException(z.arg)}else z.method==="return"&&z.abrupt("return",z.arg);G=3;var Me=M(q,te,z);if(Me.type==="normal"){if(G=z.done?4:2,Me.arg===I)continue;return{value:Me.arg,done:z.done}}Me.type==="throw"&&(G=4,z.method="throw",z.arg=Me.arg)}}}(x,w,new H(R||[])),!0),V}function M(x,O,w){try{return{type:"normal",arg:x.call(O,w)}}catch(R){return{type:"throw",arg:R}}}e.wrap=g;var I={};function y(){}function h(){}function m(){}var N={};f(N,s,function(){return this});var E=Object.getPrototypeOf,A=E&&E(E(Q([])));A&&A!==n&&a.call(A,s)&&(N=A);var T=m.prototype=y.prototype=Object.create(N);function j(x){["next","throw","return"].forEach(function(O){f(x,O,function(w){return this._invoke(O,w)})})}function C(x,O){function w(Y,V,q,te){var z=M(x[Y],x,V);if(z.type!=="throw"){var G=z.arg,K=G.value;return K&&t4(K)=="object"&&a.call(K,"__await")?O.resolve(K.__await).then(function(k){w("next",k,q,te)},function(k){w("throw",k,q,te)}):O.resolve(K).then(function(k){G.value=k,q(G)},function(k){return w("throw",k,q,te)})}te(z.arg)}var R;f(this,"_invoke",function(Y,V){function q(){return new O(function(te,z){w(Y,V,te,z)})}return R=R?R.then(q,q):q()},!0)}function _(x,O){var w=O.method,R=x.i[w];if(R===t)return O.delegate=null,w==="throw"&&x.i.return&&(O.method="return",O.arg=t,_(x,O),O.method==="throw")||w!=="return"&&(O.method="throw",O.arg=new TypeError("The iterator does not provide a '"+w+"' method")),I;var Y=M(R,x.i,O.arg);if(Y.type==="throw")return O.method="throw",O.arg=Y.arg,O.delegate=null,I;var V=Y.arg;return V?V.done?(O[x.r]=V.value,O.next=x.n,O.method!=="return"&&(O.method="next",O.arg=t),O.delegate=null,I):V:(O.method="throw",O.arg=new TypeError("iterator result is not an object"),O.delegate=null,I)}function L(x){this.tryEntries.push(x)}function U(x){var O=x[4]||{};O.type="normal",O.arg=t,x[4]=O}function H(x){this.tryEntries=[[-1]],x.forEach(L,this),this.reset(!0)}function Q(x){if(x!=null){var O=x[s];if(O)return O.call(x);if(typeof x.next=="function")return x;if(!isNaN(x.length)){var w=-1,R=function Y(){for(;++w<x.length;)if(a.call(x,w))return Y.value=x[w],Y.done=!1,Y;return Y.value=t,Y.done=!0,Y};return R.next=R}}throw new TypeError(t4(x)+" is not iterable")}return h.prototype=m,f(T,"constructor",m),f(m,"constructor",h),h.displayName=f(m,d,"GeneratorFunction"),e.isGeneratorFunction=function(x){var O=typeof x=="function"&&x.constructor;return!!O&&(O===h||(O.displayName||O.name)==="GeneratorFunction")},e.mark=function(x){return Object.setPrototypeOf?Object.setPrototypeOf(x,m):(x.__proto__=m,f(x,d,"GeneratorFunction")),x.prototype=Object.create(T),x},e.awrap=function(x){return{__await:x}},j(C.prototype),f(C.prototype,l,function(){return this}),e.AsyncIterator=C,e.async=function(x,O,w,R,Y){Y===void 0&&(Y=Promise);var V=new C(g(x,O,w,R),Y);return e.isGeneratorFunction(O)?V:V.next().then(function(q){return q.done?q.value:V.next()})},j(T),f(T,d,"Generator"),f(T,s,function(){return this}),f(T,"toString",function(){return"[object Generator]"}),e.keys=function(x){var O=Object(x),w=[];for(var R in O)w.unshift(R);return function Y(){for(;w.length;)if((R=w.pop())in O)return Y.value=R,Y.done=!1,Y;return Y.done=!0,Y}},e.values=Q,H.prototype={constructor:H,reset:function(O){if(this.prev=this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(U),!O)for(var w in this)w.charAt(0)==="t"&&a.call(this,w)&&!isNaN(+w.slice(1))&&(this[w]=t)},stop:function(){this.done=!0;var O=this.tryEntries[0][4];if(O.type==="throw")throw O.arg;return this.rval},dispatchException:function(O){if(this.done)throw O;var w=this;function R(K){q.type="throw",q.arg=O,w.next=K}for(var Y=w.tryEntries.length-1;Y>=0;--Y){var V=this.tryEntries[Y],q=V[4],te=this.prev,z=V[1],G=V[2];if(V[0]===-1)return R("end"),!1;if(!z&&!G)throw Error("try statement without catch or finally");if(V[0]!=null&&V[0]<=te){if(te<z)return this.method="next",this.arg=t,R(z),!0;if(te<G)return R(G),!1}}},abrupt:function(O,w){for(var R=this.tryEntries.length-1;R>=0;--R){var Y=this.tryEntries[R];if(Y[0]>-1&&Y[0]<=this.prev&&this.prev<Y[2]){var V=Y;break}}V&&(O==="break"||O==="continue")&&V[0]<=w&&w<=V[2]&&(V=null);var q=V?V[4]:{};return q.type=O,q.arg=w,V?(this.method="next",this.next=V[2],I):this.complete(q)},complete:function(O,w){if(O.type==="throw")throw O.arg;return O.type==="break"||O.type==="continue"?this.next=O.arg:O.type==="return"?(this.rval=this.arg=O.arg,this.method="return",this.next="end"):O.type==="normal"&&w&&(this.next=w),I},finish:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[2]===O)return this.complete(R[4],R[3]),U(R),I}},catch:function(O){for(var w=this.tryEntries.length-1;w>=0;--w){var R=this.tryEntries[w];if(R[0]===O){var Y=R[4];if(Y.type==="throw"){var V=Y.arg;U(R)}return V}}throw Error("illegal catch attempt")},delegateYield:function(O,w,R){return this.delegate={i:Q(O),r:w,n:R},this.method==="next"&&(this.arg=t),I}},e}function Ute(t,e,n,a,o,s,l){try{var d=t[s](l),f=d.value}catch(g){return void n(g)}d.done?e(f):Promise.resolve(f).then(a,o)}function i0(t){return function(){var e=this,n=arguments;return new Promise(function(a,o){var s=t.apply(e,n);function l(f){Ute(s,a,o,l,d,"next",f)}function d(f){Ute(s,a,o,l,d,"throw",f)}l(void 0)})}}function r_e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function n_e(t,e){for(var n=0;n<e.length;n++){var a=e[n];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(t,a_e(a.key),a)}}function i_e(t,e,n){return e&&n_e(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function a_e(t){var e=o_e(t,"string");return t4(e)=="symbol"?e:e+""}function o_e(t,e){if(t4(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var a=n.call(t,e);if(t4(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}var u_e=function(){function t(){r_e(this,t)}return i_e(t,[{key:"initialize",value:function(){var e=i0(sl().mark(function a(o){var s;return sl().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return s=wa.getState().initialize(o),d.abrupt("return",s);case 2:case"end":return d.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"configure",value:function(){var e=i0(sl().mark(function a(o){var s,l;return sl().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:if(typeof o=="string"){f.next=5;break}return f.next=3,wa.getState().configure(o);case 3:return s=f.sent,f.abrupt("return",s);case 5:return f.next=7,wa.getState().configureWithUrl(o);case 7:return l=f.sent,f.abrupt("return",l);case 9:case"end":return f.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"getWorkFlows",value:function(){var e=i0(sl().mark(function a(o){var s;return sl().wrap(function(d){for(;;)switch(d.prev=d.next){case 0:return d.next=2,wa.getState().getWorkflows(o);case 2:return s=d.sent,d.abrupt("return",s);case 4:case"end":return d.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"prepareWorkflow",value:function(){var e=i0(sl().mark(function a(o){var s,l;return sl().wrap(function(f){for(;;)switch(f.prev=f.next){case 0:return s=o.workflowId,f.next=3,wa.getState().prepareWorkflowAndPrepareUi(s);case 3:return l=f.sent,f.abrupt("return",l);case 5:case"end":return f.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"startWorkflow",value:function(){var e=i0(sl().mark(function a(o){var s,l,d,f;return sl().wrap(function(M){for(;;)switch(M.prev=M.next){case 0:return s=o==null?void 0:o.locale,l=o==null?void 0:o.metadata,d=Lme(s),M.next=5,wa.getState().startNewSession(d,l);case 5:if(f=M.sent,!f.error){M.next=8;break}return M.abrupt("return",f);case 8:return M.abrupt("return",new Promise(function(I){var y=function(m){I(m)};wa.getState().playWorkflow(y)}));case 9:case"end":return M.stop()}},a)}));function n(a){return e.apply(this,arguments)}return n}()},{key:"deinitialize",value:function(){var e=i0(sl().mark(function a(){var o;return sl().wrap(function(l){for(;;)switch(l.prev=l.next){case 0:return l.next=2,wa.getState().deinitialize();case 2:return o=l.sent,l.abrupt("return",o);case 4:case"end":return l.stop()}},a)}));function n(){return e.apply(this,arguments)}return n}()},{key:"version",get:function(){var n;return(n="2.3.152-nightly")!==null&&n!==void 0?n:"Version unavailable. Something went wrong"}},{key:"setNonce",value:function(n){wa.getState().setNonce(n)}},{key:"eventListener",set:function(n){if(!n||typeof n!="function"){console.warn("IdvIntegrationService:: listener is not a function");return}wa.getState().setListener(n)}},{key:"sessionRestoreMode",set:function(n){wa.getState().setSessionRestoreMode(n)}},{key:"currentSessionId",get:function(){return wa.getState().getCurrentSessionId()}}])}(),s_e=window.customElements.get("idv-flow");s_e||window.customElements.define("idv-flow",Pte);var l_e=Object.defineProperty,c_e=Object.defineProperties,f_e=Object.getOwnPropertyDescriptors,Yte=Object.getOwnPropertySymbols,d_e=Object.prototype.hasOwnProperty,g_e=Object.prototype.propertyIsEnumerable,$te=(t,e,n)=>e in t?l_e(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,SA=(t,e)=>{for(var n in e||(e={}))d_e.call(e,n)&&$te(t,n,e[n]);if(Yte)for(var n of Yte(e))g_e.call(e,n)&&$te(t,n,e[n]);return t},M_e=(t,e)=>c_e(t,f_e(e)),bo=(t,e,n)=>new Promise((a,o)=>{var s=f=>{try{d(n.next(f))}catch(g){o(g)}},l=f=>{try{d(n.throw(f))}catch(g){o(g)}},d=f=>f.done?a(f.value):Promise.resolve(f.value).then(s,l);d((n=n.apply(t,e)).next())}),Qte=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function Fte(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var Hte={exports:{}},k2={},Vte={exports:{}},rn={},Bte;function p_e(){if(Bte)return rn;Bte=1;/**
|
|
86
86
|
* @license React
|
|
87
87
|
* react.production.min.js
|
|
88
88
|
*
|