@cling-se/widget 0.10.2 → 0.10.4-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AddClientCallout-c91ca331.js → AddClientCallout-ac04b0e5.js} +5 -5
- package/dist/{AnswerModal-8a2e1b96.js → AnswerModal-ab94492a.js} +3 -3
- package/dist/{AttachmentItem-2fcd4102.js → AttachmentItem-3fe7f93e.js} +3 -3
- package/dist/{BaseDatePicker-764430e7.js → BaseDatePicker-bc7a7a38.js} +2 -2
- package/dist/{BaseInput-16ff95d4.js → BaseInput-0128f8e7.js} +1 -1
- package/dist/{BaseUpload-cde6c150.js → BaseUpload-72ba3ed6.js} +2 -2
- package/dist/{BlockMedia-73c89da8.js → BlockMedia-34f3880e.js} +1 -1
- package/dist/{CCallout-80f62120.js → CCallout-25f57fce.js} +2 -2
- package/dist/{CDropdownItem-b703493e.js → CDropdownItem-5b7319d8.js} +1 -1
- package/dist/{CField-82e3942c.js → CField-7d3f84b4.js} +1 -1
- package/dist/{CPhoneFormat-6f544ea2.js → CPhoneFormat-c733eed8.js} +1 -1
- package/dist/{CSlider.vue_vue_type_style_index_0_lang-ee3915b1.js → CSlider.vue_vue_type_style_index_0_lang-2908d3f1.js} +1 -1
- package/dist/{ClientAutocomplete-ea981ce9.js → ClientAutocomplete-977b5a9e.js} +2 -2
- package/dist/{ClientModal-b1f06e4b.js → ClientModal-be37f1fc.js} +5 -5
- package/dist/{ColorPicker-db332e31.js → ColorPicker-42cda4ee.js} +1 -1
- package/dist/{CompanyModal-37d80a52.js → CompanyModal-c864241c.js} +3 -3
- package/dist/{ContentWrapper-530ac6c4.js → ContentWrapper-f36e7350.js} +13 -13
- package/dist/{CoverBlockSettings-70f33b4e.js → CoverBlockSettings-362d1abb.js} +7 -7
- package/dist/{DocAnswer-b3af9c74.js → DocAnswer-d7d3e570.js} +4 -4
- package/dist/{DocDetails-4569f591.js → DocDetails-99c9480f.js} +4 -4
- package/dist/{DocForm-e6dbd1b7.js → DocForm-d42c6859.js} +28 -28
- package/dist/{DocFormSend-097fad46.js → DocFormSend-5cfcec8a.js} +17 -17
- package/dist/{DocLinks-de9a4377.js → DocLinks-4eb1de5e.js} +2 -2
- package/dist/{DocModalBase-1d7b3e3a.js → DocModalBase-3199ead0.js} +1 -1
- package/dist/{DocPrint-1747a6cc.js → DocPrint-ffd6bd0a.js} +1 -1
- package/dist/{DocReceipt-a7b28565.js → DocReceipt-dcb76efe.js} +1 -1
- package/dist/{DocSendReminder-f9861a59.js → DocSendReminder-63f7d042.js} +1 -1
- package/dist/{DocTextEditor-5ca1ab49.js → DocTextEditor-f7aa5610.js} +8 -8
- package/dist/{DocTimeline-fed91a61.js → DocTimeline-637ce0d3.js} +1 -1
- package/dist/{DocumentClient-a10eb849.js → DocumentClient-a8c0c1f0.js} +7 -7
- package/dist/{DocumentLayout-3a00c75c.js → DocumentLayout-d0b0264c.js} +4 -4
- package/dist/{DocumentLogotype-47bdfc02.js → DocumentLogotype-cf798645.js} +3 -3
- package/dist/{DocumentVoided-10eb3206.js → DocumentVoided-32256b94.js} +1 -1
- package/dist/{EmbedInput-a393b7a7.js → EmbedInput-90aa3ad1.js} +2 -2
- package/dist/{EmbedSettings-e34184f5.js → EmbedSettings-fb61b264.js} +3 -3
- package/dist/{ErrorCallout-bb4bb30b.js → ErrorCallout-cd3bfacb.js} +1 -1
- package/dist/{FilePreviewModal-63bf0717.js → FilePreviewModal-7176df5b.js} +5 -5
- package/dist/{Flag-952ef47c.js → Flag-f48640d5.js} +1 -1
- package/dist/{HeaderSettings-0f324256.js → HeaderSettings-d3083244.js} +15 -15
- package/dist/{ImageSelectModal-9454fc9b.js → ImageSelectModal-44047f1e.js} +8 -8
- package/dist/{ImageUploadWrapper-0f3f712f.js → ImageUploadWrapper-9d102509.js} +2 -2
- package/dist/{Index-11fce018.js → Index-007fa122.js} +4 -4
- package/dist/{Index-62311015.js → Index-01311f76.js} +5 -5
- package/dist/{Index-94e5bdd2.js → Index-08900b5e.js} +6 -6
- package/dist/{Index-53f5e92b.js → Index-13103bfa.js} +4 -4
- package/dist/{Index-1ad2a354.js → Index-153fb302.js} +7 -7
- package/dist/{Index-5d78cedc.js → Index-15cda543.js} +9 -9
- package/dist/{Index-f31c6bf6.js → Index-160a7d88.js} +2 -2
- package/dist/{Index-08b3f0d9.js → Index-2621b655.js} +6 -6
- package/dist/{Index-902c62af.js → Index-268a3680.js} +2 -2
- package/dist/{Index-ab589ff1.js → Index-2dd0855b.js} +6 -6
- package/dist/{Index-89d7293e.js → Index-34f8ec3d.js} +4 -4
- package/dist/{Index-4600f943.js → Index-4a077c97.js} +13 -13
- package/dist/{Index-a13a8628.js → Index-4a69a722.js} +2 -2
- package/dist/{Index-e7af00fd.js → Index-4e013912.js} +4 -4
- package/dist/{Index-85ba630b.js → Index-50f1f14e.js} +4 -4
- package/dist/{Index-11417826.js → Index-6a965ec8.js} +1 -1
- package/dist/{Index-22a6ac2c.js → Index-70e37c05.js} +2 -2
- package/dist/{Index-733a87b2.js → Index-7adb0086.js} +8 -8
- package/dist/{Index-c3100eb8.js → Index-8a130821.js} +2 -2
- package/dist/{Index-5962c5fa.js → Index-8dd0a4a3.js} +6 -6
- package/dist/{Index-7b01d5f3.js → Index-8e42fd14.js} +1 -1
- package/dist/{Index-bbb1eed9.js → Index-8ffa87b4.js} +2 -2
- package/dist/{Index-6a0bc652.js → Index-91923bb3.js} +14 -14
- package/dist/{Index-b320d668.js → Index-a3dd0100.js} +3 -3
- package/dist/{Index-722972c7.js → Index-a6c2348f.js} +4 -4
- package/dist/{Index-3b07edd1.js → Index-a8ab221c.js} +4 -4
- package/dist/{Index-9c5778a0.js → Index-a9255882.js} +10 -10
- package/dist/{Index-6052206b.js → Index-b2861f7a.js} +2 -2
- package/dist/{Index-2e836913.js → Index-d5c54afa.js} +4 -4
- package/dist/{Index-a99bd8f6.js → Index-d5ed245c.js} +2 -2
- package/dist/{Index-1899a59d.js → Index-e9cf6266.js} +9 -9
- package/dist/{Index-7f9f54df.js → Index-f10ed000.js} +5 -5
- package/dist/{Index-496348ea.js → Index-f4270151.js} +14 -14
- package/dist/{Index-445dc171.js → Index-ff9efb43.js} +7 -7
- package/dist/{InputToggleRow-04ccd5f2.js → InputToggleRow-f7c8fad0.js} +1 -1
- package/dist/{IsPremiumPreStep-fd71afe7.js → IsPremiumPreStep-c57d25d5.js} +2 -2
- package/dist/{ManualPopover-66e2fbda.js → ManualPopover-8a1b6a31.js} +1 -1
- package/dist/{MediaWrapper-0895cb0a.js → MediaWrapper-5dcfede8.js} +3 -3
- package/dist/{NotBindingText-bbb75490.js → NotBindingText-0464a81e.js} +2 -2
- package/dist/{PackageGroup-d0c8c851.js → PackageGroup-339ce6cb.js} +12 -12
- package/dist/{PdfTerms-3ca871a7.js → PdfTerms-0f433ba4.js} +5 -5
- package/dist/{PdfViewer-f8877419.js → PdfViewer-dfb6816e.js} +9 -9
- package/dist/{PlainHtml-70f73857.js → PlainHtml-511f00f4.js} +1 -1
- package/dist/{PriceHeader-bd7f2fa0.js → PriceHeader-81c0f36c.js} +13 -13
- package/dist/{SearchApi-dfd24f3e.js → SearchApi-0d8acefc.js} +2 -2
- package/dist/{Setup-67aa6fe8.js → Setup-bbdf4e98.js} +1 -1
- package/dist/{TermsSettings-fe4e225f.js → TermsSettings-e6827dae.js} +7 -7
- package/dist/{ThemeColorRow-81f8615a.js → ThemeColorRow-0a7ade13.js} +3 -3
- package/dist/{ToggleBinding-5af2df09.js → ToggleBinding-34338d89.js} +3 -3
- package/dist/{UploadModal-8c766ba7.js → UploadModal-08b3ecb6.js} +3 -3
- package/dist/{VideoPlayerInput-0a11df1e.js → VideoPlayerInput-a1592195.js} +3 -3
- package/dist/{VideoPlayerSettings-e54bdb5e.js → VideoPlayerSettings-d8ed1e19.js} +4 -4
- package/dist/{VideoSelectModal-023186e1.js → VideoSelectModal-421df4a2.js} +8 -8
- package/dist/{answerDocumentMixin-97203107.js → answerDocumentMixin-a3a4e70d.js} +3 -3
- package/dist/{debounce-653d5a89.js → debounce-7b692c87.js} +1 -1
- package/dist/{focusDrawerMixin-7f321c15.js → focusDrawerMixin-5b5ac90c.js} +1 -1
- package/dist/{formComponentsInstall-fd01cdd2.js → formComponentsInstall-897fd293.js} +12 -12
- package/dist/{formDrawerState-3c299bf6.js → formDrawerState-09657030.js} +1 -1
- package/dist/{formValidationMixin-c20cb8fe.js → formValidationMixin-090f1841.js} +1 -1
- package/dist/{index-2aa11fa3.js → index-10f9f703.js} +5 -5
- package/dist/{index-01437260.js → index-3f979f04.js} +3 -3
- package/dist/{index-aa0b2a84.js → index-71606148.js} +9 -9
- package/dist/{index-60e8f1c3.js → index-74a344c7.js} +1 -1
- package/dist/{index-bf9f0618.js → index-a3dfaf0e.js} +1 -1
- package/dist/{index-dc39dc99.js → index-c6a51a6f.js} +1 -1
- package/dist/index.es.js +1 -1
- package/dist/index.umd.js +3 -3
- package/dist/{main-6be1d89a.js → main-fe7caa96.js} +14 -14
- package/dist/{mapFormMixin-ab97e85b.js → mapFormMixin-821b98b6.js} +1 -1
- package/dist/{publicSenderState-2ca5021f.js → publicSenderState-7387a06a.js} +1 -1
- package/dist/{throttle-78ffe6e1.js → throttle-cc268af2.js} +2 -2
- package/dist/{tinycolor-8972e238.js → tinycolor-91424e70.js} +1 -1
- package/dist/{tippy.esm-d62237ec.js → tippy.esm-95ab3202.js} +5 -5
- package/dist/{utils-24c33071.js → utils-3f18d789.js} +1 -1
- package/dist/{vuedraggable.umd-78b3c86e.js → vuedraggable.umd-797c9a23.js} +1 -1
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -434,7 +434,7 @@ $t(documentTemplateView.smsContent) $t(documentTemplateView.readMore)
|
|
|
434
434
|
* (c) 2017 Evan You
|
|
435
435
|
* @license MIT
|
|
436
436
|
*/function C3(n){return Object.prototype.toString.call(n).indexOf("Error")>-1}var ixe={name:"router-view",functional:!0,props:{name:{type:String,default:"default"}},render:function(t,r){var i=r.props,a=r.children,o=r.parent,s=r.data;s.routerView=!0;for(var c=o.$createElement,l=i.name,u=o.$route,d=o._routerViewCache||(o._routerViewCache={}),p=0,f=!1;o&&o._routerRoot!==o;)o.$vnode&&o.$vnode.data.routerView&&p++,o._inactive&&(f=!0),o=o.$parent;if(s.routerViewDepth=p,f)return c(d[l],s,a);var h=u.matched[p];if(!h)return d[l]=null,c();var m=d[l]=h.components[l];s.registerRouteInstance=function(w,S){var k=h.instances[l];(S&&k!==w||!S&&k===w)&&(h.instances[l]=S)},(s.hook||(s.hook={})).prepatch=function(w,S){h.instances[l]=S.componentInstance};var g=s.props=axe(u,h.props&&h.props[l]);if(g){g=s.props=oxe({},g);var y=s.attrs=s.attrs||{};for(var b in g)(!m.props||!(b in m.props))&&(y[b]=g[b],delete g[b])}return c(m,s,a)}};function axe(n,t){switch(typeof t){case"undefined":return;case"object":return t;case"function":return t(n);case"boolean":return t?n.params:void 0}}function oxe(n,t){for(var r in t)n[r]=t[r];return n}var sxe=/[!'()*]/g,lxe=function(n){return"%"+n.charCodeAt(0).toString(16)},cxe=/%2C/g,Mp=function(n){return encodeURIComponent(n).replace(sxe,lxe).replace(cxe,",")},tI=decodeURIComponent;function uxe(n,t,r){t===void 0&&(t={});var i=r||dxe,a;try{a=i(n||"")}catch{a={}}for(var o in t)a[o]=t[o];return a}function dxe(n){var t={};return n=n.trim().replace(/^(\?|#|&)/,""),n&&n.split("&").forEach(function(r){var i=r.replace(/\+/g," ").split("="),a=tI(i.shift()),o=i.length>0?tI(i.join("=")):null;t[a]===void 0?t[a]=o:Array.isArray(t[a])?t[a].push(o):t[a]=[t[a],o]}),t}function pxe(n){var t=n?Object.keys(n).map(function(r){var i=n[r];if(i===void 0)return"";if(i===null)return Mp(r);if(Array.isArray(i)){var a=[];return i.forEach(function(o){o!==void 0&&(o===null?a.push(Mp(r)):a.push(Mp(r)+"="+Mp(o)))}),a.join("&")}return Mp(r)+"="+Mp(i)}).filter(function(r){return r.length>0}).join("&"):null;return t?"?"+t:""}var V0=/\/?$/;function U0(n,t,r,i){var a=i&&i.options.stringifyQuery,o=t.query||{};try{o=k3(o)}catch{}var s={name:t.name||n&&n.name,meta:n&&n.meta||{},path:t.path||"/",hash:t.hash||"",query:o,params:t.params||{},fullPath:nI(t,a),matched:n?fxe(n):[]};return r&&(s.redirectedFrom=nI(r,a)),Object.freeze(s)}function k3(n){if(Array.isArray(n))return n.map(k3);if(n&&typeof n=="object"){var t={};for(var r in n)t[r]=k3(n[r]);return t}else return n}var H0=U0(null,{path:"/"});function fxe(n){for(var t=[];n;)t.unshift(n),n=n.parent;return t}function nI(n,t){var r=n.path,i=n.query;i===void 0&&(i={});var a=n.hash;a===void 0&&(a="");var o=t||pxe;return(r||"/")+o(i)+a}function rI(n,t){return t===H0?n===t:t?n.path&&t.path?n.path.replace(V0,"")===t.path.replace(V0,"")&&n.hash===t.hash&&W0(n.query,t.query):n.name&&t.name?n.name===t.name&&n.hash===t.hash&&W0(n.query,t.query)&&W0(n.params,t.params):!1:!1}function W0(n,t){if(n===void 0&&(n={}),t===void 0&&(t={}),!n||!t)return n===t;var r=Object.keys(n),i=Object.keys(t);return r.length!==i.length?!1:r.every(function(a){var o=n[a],s=t[a];return typeof o=="object"&&typeof s=="object"?W0(o,s):String(o)===String(s)})}function hxe(n,t){return n.path.replace(V0,"/").indexOf(t.path.replace(V0,"/"))===0&&(!t.hash||n.hash===t.hash)&&mxe(n.query,t.query)}function mxe(n,t){for(var r in t)if(!(r in n))return!1;return!0}var gxe=[String,Object],vxe=[String,Array],yxe={name:"router-link",props:{to:{type:gxe,required:!0},tag:{type:String,default:"a"},exact:Boolean,append:Boolean,replace:Boolean,activeClass:String,exactActiveClass:String,event:{type:vxe,default:"click"}},render:function(t){var r=this,i=this.$router,a=this.$route,o=i.resolve(this.to,a,this.append),s=o.location,c=o.route,l=o.href,u={},d=i.options.linkActiveClass,p=i.options.linkExactActiveClass,f=d??"router-link-active",h=p??"router-link-exact-active",m=this.activeClass==null?f:this.activeClass,g=this.exactActiveClass==null?h:this.exactActiveClass,y=s.path?U0(null,s,null,i):c;u[g]=rI(a,y),u[m]=this.exact?u[g]:hxe(a,y);var b=function(E){iI(E)&&(r.replace?i.replace(s):i.push(s))},w={click:iI};Array.isArray(this.event)?this.event.forEach(function(E){w[E]=b}):w[this.event]=b;var S={class:u};if(this.tag==="a")S.on=w,S.attrs={href:l};else{var k=aI(this.$slots.default);if(k){k.isStatic=!1;var $=Um.util.extend,T=k.data=$({},k.data);T.on=w;var A=k.data.attrs=$({},k.data.attrs);A.href=l}else S.on=w}return t(this.tag,S,this.$slots.default)}};function iI(n){if(!(n.metaKey||n.altKey||n.ctrlKey||n.shiftKey)&&!n.defaultPrevented&&!(n.button!==void 0&&n.button!==0)){if(n.currentTarget&&n.currentTarget.getAttribute){var t=n.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return n.preventDefault&&n.preventDefault(),!0}}function aI(n){if(n){for(var t,r=0;r<n.length;r++)if(t=n[r],t.tag==="a"||t.children&&(t=aI(t.children)))return t}}var Um;function S3(n){if(!(S3.installed&&Um===n)){S3.installed=!0,Um=n;var t=function(a){return a!==void 0},r=function(a,o){var s=a.$options._parentVnode;t(s)&&t(s=s.data)&&t(s=s.registerRouteInstance)&&s(a,o)};n.mixin({beforeCreate:function(){t(this.$options.router)?(this._routerRoot=this,this._router=this.$options.router,this._router.init(this),n.util.defineReactive(this,"_route",this._router.history.current)):this._routerRoot=this.$parent&&this.$parent._routerRoot||this,r(this,this)},destroyed:function(){r(this)}}),Object.defineProperty(n.prototype,"$router",{get:function(){return this._routerRoot._router}}),Object.defineProperty(n.prototype,"$route",{get:function(){return this._routerRoot._route}}),n.component("router-view",ixe),n.component("router-link",yxe);var i=n.config.optionMergeStrategies;i.beforeRouteEnter=i.beforeRouteLeave=i.beforeRouteUpdate=i.created}}var Hm=typeof window<"u";function oI(n,t,r){var i=n.charAt(0);if(i==="/")return n;if(i==="?"||i==="#")return t+n;var a=t.split("/");(!r||!a[a.length-1])&&a.pop();for(var o=n.replace(/^\//,"").split("/"),s=0;s<o.length;s++){var c=o[s];c===".."?a.pop():c!=="."&&a.push(c)}return a[0]!==""&&a.unshift(""),a.join("/")}function bxe(n){var t="",r="",i=n.indexOf("#");i>=0&&(t=n.slice(i),n=n.slice(0,i));var a=n.indexOf("?");return a>=0&&(r=n.slice(a+1),n=n.slice(0,a)),{path:n,query:r,hash:t}}function Eu(n){return n.replace(/\/\//g,"/")}var G0=Array.isArray||function(n){return Object.prototype.toString.call(n)=="[object Array]"},Pp=uI,_xe=T3,wxe=Sxe,xxe=sI,Cxe=cI,kxe=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function T3(n,t){for(var r=[],i=0,a=0,o="",s=t&&t.delimiter||"/",c;(c=kxe.exec(n))!=null;){var l=c[0],u=c[1],d=c.index;if(o+=n.slice(a,d),a=d+l.length,u){o+=u[1];continue}var p=n[a],f=c[2],h=c[3],m=c[4],g=c[5],y=c[6],b=c[7];o&&(r.push(o),o="");var w=f!=null&&p!=null&&p!==f,S=y==="+"||y==="*",k=y==="?"||y==="*",$=c[2]||s,T=m||g;r.push({name:h||i++,prefix:f||"",delimiter:$,optional:k,repeat:S,partial:w,asterisk:!!b,pattern:T?$xe(T):b?".*":"[^"+q0($)+"]+?"})}return a<n.length&&(o+=n.substr(a)),o&&r.push(o),r}function Sxe(n,t){return sI(T3(n,t))}function Txe(n){return encodeURI(n).replace(/[\/?#]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}function Exe(n){return encodeURI(n).replace(/[?#]/g,function(t){return"%"+t.charCodeAt(0).toString(16).toUpperCase()})}function sI(n){for(var t=new Array(n.length),r=0;r<n.length;r++)typeof n[r]=="object"&&(t[r]=new RegExp("^(?:"+n[r].pattern+")$"));return function(i,a){for(var o="",s=i||{},c=a||{},l=c.pretty?Txe:encodeURIComponent,u=0;u<n.length;u++){var d=n[u];if(typeof d=="string"){o+=d;continue}var p=s[d.name],f;if(p==null)if(d.optional){d.partial&&(o+=d.prefix);continue}else throw new TypeError('Expected "'+d.name+'" to be defined');if(G0(p)){if(!d.repeat)throw new TypeError('Expected "'+d.name+'" to not repeat, but received `'+JSON.stringify(p)+"`");if(p.length===0){if(d.optional)continue;throw new TypeError('Expected "'+d.name+'" to not be empty')}for(var h=0;h<p.length;h++){if(f=l(p[h]),!t[u].test(f))throw new TypeError('Expected all "'+d.name+'" to match "'+d.pattern+'", but received `'+JSON.stringify(f)+"`");o+=(h===0?d.prefix:d.delimiter)+f}continue}if(f=d.asterisk?Exe(p):l(p),!t[u].test(f))throw new TypeError('Expected "'+d.name+'" to match "'+d.pattern+'", but received "'+f+'"');o+=d.prefix+f}return o}}function q0(n){return n.replace(/([.+*?=^!:${}()[\]|\/\\])/g,"\\$1")}function $xe(n){return n.replace(/([=!:$\/()])/g,"\\$1")}function E3(n,t){return n.keys=t,n}function lI(n){return n.sensitive?"":"i"}function Axe(n,t){var r=n.source.match(/\((?!\?)/g);if(r)for(var i=0;i<r.length;i++)t.push({name:i,prefix:null,delimiter:null,optional:!1,repeat:!1,partial:!1,asterisk:!1,pattern:null});return E3(n,t)}function Oxe(n,t,r){for(var i=[],a=0;a<n.length;a++)i.push(uI(n[a],t,r).source);var o=new RegExp("(?:"+i.join("|")+")",lI(r));return E3(o,t)}function Dxe(n,t,r){return cI(T3(n,r),t,r)}function cI(n,t,r){G0(t)||(r=t||r,t=[]),r=r||{};for(var i=r.strict,a=r.end!==!1,o="",s=0;s<n.length;s++){var c=n[s];if(typeof c=="string")o+=q0(c);else{var l=q0(c.prefix),u="(?:"+c.pattern+")";t.push(c),c.repeat&&(u+="(?:"+l+u+")*"),c.optional?c.partial?u=l+"("+u+")?":u="(?:"+l+"("+u+"))?":u=l+"("+u+")",o+=u}}var d=q0(r.delimiter||"/"),p=o.slice(-d.length)===d;return i||(o=(p?o.slice(0,-d.length):o)+"(?:"+d+"(?=$))?"),a?o+="$":o+=i&&p?"":"(?="+d+"|$)",E3(new RegExp("^"+o,lI(r)),t)}function uI(n,t,r){return G0(t)||(r=t||r,t=[]),r=r||{},n instanceof RegExp?Axe(n,t):G0(n)?Oxe(n,t,r):Dxe(n,t,r)}Pp.parse=_xe,Pp.compile=wxe,Pp.tokensToFunction=xxe,Pp.tokensToRegExp=Cxe;var dI=Object.create(null);function Y0(n,t,r){try{var i=dI[n]||(dI[n]=Pp.compile(n));return i(t||{},{pretty:!0})}catch{return""}}function pI(n,t,r,i){var a=t||[],o=r||Object.create(null),s=i||Object.create(null);n.forEach(function(u){$3(a,o,s,u)});for(var c=0,l=a.length;c<l;c++)a[c]==="*"&&(a.push(a.splice(c,1)[0]),l--,c--);return{pathList:a,pathMap:o,nameMap:s}}function $3(n,t,r,i,a,o){var s=i.path,c=i.name,l=i.pathToRegexpOptions||{},u=Pxe(s,a,l.strict);typeof i.caseSensitive=="boolean"&&(l.sensitive=i.caseSensitive);var d={path:u,regex:Mxe(u,l),components:i.components||{default:i.component},instances:{},name:c,parent:a,matchAs:o,redirect:i.redirect,beforeEnter:i.beforeEnter,meta:i.meta||{},props:i.props==null?{}:i.components?i.props:{default:i.props}};if(i.children&&i.children.forEach(function(f){var h=o?Eu(o+"/"+f.path):void 0;$3(n,t,r,f,d,h)}),i.alias!==void 0){var p=Array.isArray(i.alias)?i.alias:[i.alias];p.forEach(function(f){var h={path:f,children:i.children};$3(n,t,r,h,a,d.path||"/")})}t[d.path]||(n.push(d.path),t[d.path]=d),c&&(r[c]||(r[c]=d))}function Mxe(n,t){var r=Pp(n,[],t);return r}function Pxe(n,t,r){return r||(n=n.replace(/\/$/,"")),n[0]==="/"||t==null?n:Eu(t.path+"/"+n)}function fI(n,t,r,i){var a=typeof n=="string"?{path:n}:n;if(a.name||a._normalized)return a;if(!a.path&&a.params&&t){a=A3({},a),a._normalized=!0;var o=A3(A3({},t.params),a.params);if(t.name)a.name=t.name,a.params=o;else if(t.matched.length){var s=t.matched[t.matched.length-1].path;a.path=Y0(s,o,"path "+t.path)}return a}var c=bxe(a.path||""),l=t&&t.path||"/",u=c.path?oI(c.path,l,r||a.append):l,d=uxe(c.query,a.query,i&&i.options.parseQuery),p=a.hash||c.hash;return p&&p.charAt(0)!=="#"&&(p="#"+p),{_normalized:!0,path:u,query:d,hash:p}}function A3(n,t){for(var r in t)n[r]=t[r];return n}function Ixe(n,t){var r=pI(n),i=r.pathList,a=r.pathMap,o=r.nameMap;function s(p){pI(p,i,a,o)}function c(p,f,h){var m=fI(p,f,!1,t),g=m.name;if(g){var y=o[g];if(!y)return d(null,m);var b=y.regex.keys.filter(function(T){return!T.optional}).map(function(T){return T.name});if(typeof m.params!="object"&&(m.params={}),f&&typeof f.params=="object")for(var w in f.params)!(w in m.params)&&b.indexOf(w)>-1&&(m.params[w]=f.params[w]);if(y)return m.path=Y0(y.path,m.params),d(y,m,h)}else if(m.path){m.params={};for(var S=0;S<i.length;S++){var k=i[S],$=a[k];if(Rxe($.regex,m.path,m.params))return d($,m,h)}}return d(null,m)}function l(p,f){var h=p.redirect,m=typeof h=="function"?h(U0(p,f,null,t)):h;if(typeof m=="string"&&(m={path:m}),!m||typeof m!="object")return d(null,f);var g=m,y=g.name,b=g.path,w=f.query,S=f.hash,k=f.params;if(w=g.hasOwnProperty("query")?g.query:w,S=g.hasOwnProperty("hash")?g.hash:S,k=g.hasOwnProperty("params")?g.params:k,y)return o[y],c({_normalized:!0,name:y,query:w,hash:S,params:k},void 0,f);if(b){var $=Lxe(b,p),T=Y0($,k);return c({_normalized:!0,path:T,query:w,hash:S},void 0,f)}else return d(null,f)}function u(p,f,h){var m=Y0(h,f.params),g=c({_normalized:!0,path:m});if(g){var y=g.matched,b=y[y.length-1];return f.params=g.params,d(b,f)}return d(null,f)}function d(p,f,h){return p&&p.redirect?l(p,h||f):p&&p.matchAs?u(p,f,p.matchAs):U0(p,f,h,t)}return{match:c,addRoutes:s}}function Rxe(n,t,r){var i=t.match(n);if(i){if(!r)return!0}else return!1;for(var a=1,o=i.length;a<o;++a){var s=n.keys[a-1],c=typeof i[a]=="string"?decodeURIComponent(i[a]):i[a];s&&(r[s.name]=c)}return!0}function Lxe(n,t){return oI(n,t.parent?t.parent.path:"/",!0)}var hI=Object.create(null);function mI(){window.history.replaceState({key:O3()},""),window.addEventListener("popstate",function(n){gI(),n.state&&n.state.key&&zxe(n.state.key)})}function Ip(n,t,r,i){if(n.app){var a=n.options.scrollBehavior;a&&n.app.$nextTick(function(){var o=Fxe(),s=a(t,r,i?o:null);s&&(typeof s.then=="function"?s.then(function(c){bI(c,o)}).catch(function(c){}):bI(s,o))})}}function gI(){var n=O3();n&&(hI[n]={x:window.pageXOffset,y:window.pageYOffset})}function Fxe(){var n=O3();if(n)return hI[n]}function Nxe(n,t){var r=document.documentElement,i=r.getBoundingClientRect(),a=n.getBoundingClientRect();return{x:a.left-i.left-t.x,y:a.top-i.top-t.y}}function vI(n){return Rp(n.x)||Rp(n.y)}function yI(n){return{x:Rp(n.x)?n.x:window.pageXOffset,y:Rp(n.y)?n.y:window.pageYOffset}}function Bxe(n){return{x:Rp(n.x)?n.x:0,y:Rp(n.y)?n.y:0}}function Rp(n){return typeof n=="number"}function bI(n,t){var r=typeof n=="object";if(r&&typeof n.selector=="string"){var i=document.querySelector(n.selector);if(i){var a=n.offset&&typeof n.offset=="object"?n.offset:{};a=Bxe(a),t=Nxe(i,a)}else vI(n)&&(t=yI(n))}else r&&vI(n)&&(t=yI(n));t&&window.scrollTo(t.x,t.y)}var Lp=Hm&&function(){var n=window.navigator.userAgent;return(n.indexOf("Android 2.")!==-1||n.indexOf("Android 4.0")!==-1)&&n.indexOf("Mobile Safari")!==-1&&n.indexOf("Chrome")===-1&&n.indexOf("Windows Phone")===-1?!1:window.history&&"pushState"in window.history}(),jxe=Hm&&window.performance&&window.performance.now?window.performance:Date,Wm=_I();function _I(){return jxe.now().toFixed(3)}function O3(){return Wm}function zxe(n){Wm=n}function K0(n,t){gI();var r=window.history;try{t?r.replaceState({key:Wm},"",n):(Wm=_I(),r.pushState({key:Wm},"",n))}catch{window.location[t?"replace":"assign"](n)}}function D3(n){K0(n,!0)}function wI(n,t,r){var i=function(a){a>=n.length?r():n[a]?t(n[a],function(){i(a+1)}):i(a+1)};i(0)}function Vxe(n){return function(t,r,i){var a=!1,o=0,s=null;xI(n,function(c,l,u,d){if(typeof c=="function"&&c.cid===void 0){a=!0,o++;var p=kI(function(g){Hxe(g)&&(g=g.default),c.resolved=typeof g=="function"?g:Um.extend(g),u.components[d]=g,o--,o<=0&&i()}),f=kI(function(g){var y="Failed to resolve async component "+d+": "+g;s||(s=C3(g)?g:new Error(y),i(s))}),h;try{h=c(p,f)}catch(g){f(g)}if(h)if(typeof h.then=="function")h.then(p,f);else{var m=h.component;m&&typeof m.then=="function"&&m.then(p,f)}}}),a||i()}}function xI(n,t){return CI(n.map(function(r){return Object.keys(r.components).map(function(i){return t(r.components[i],r.instances[i],r,i)})}))}function CI(n){return Array.prototype.concat.apply([],n)}var Uxe=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol";function Hxe(n){return n.__esModule||Uxe&&n[Symbol.toStringTag]==="Module"}function kI(n){var t=!1;return function(){for(var r=[],i=arguments.length;i--;)r[i]=arguments[i];if(!t)return t=!0,n.apply(this,r)}}var Vs=function(t,r){this.router=t,this.base=Wxe(r),this.current=H0,this.pending=null,this.ready=!1,this.readyCbs=[],this.readyErrorCbs=[],this.errorCbs=[]};Vs.prototype.listen=function(t){this.cb=t},Vs.prototype.onReady=function(t,r){this.ready?t():(this.readyCbs.push(t),r&&this.readyErrorCbs.push(r))},Vs.prototype.onError=function(t){this.errorCbs.push(t)},Vs.prototype.transitionTo=function(t,r,i){var a=this,o=this.router.match(t,this.current);this.confirmTransition(o,function(){a.updateRoute(o),r&&r(o),a.ensureURL(),a.ready||(a.ready=!0,a.readyCbs.forEach(function(s){s(o)}))},function(s){i&&i(s),s&&!a.ready&&(a.ready=!0,a.readyErrorCbs.forEach(function(c){c(s)}))})},Vs.prototype.confirmTransition=function(t,r,i){var a=this,o=this.current,s=function(h){C3(h)&&(a.errorCbs.length?a.errorCbs.forEach(function(m){m(h)}):console.error(h)),i&&i(h)};if(rI(t,o)&&t.matched.length===o.matched.length)return this.ensureURL(),s();var c=Gxe(this.current.matched,t.matched),l=c.updated,u=c.deactivated,d=c.activated,p=[].concat(Yxe(u),this.router.beforeHooks,Kxe(l),d.map(function(h){return h.beforeEnter}),Vxe(d));this.pending=t;var f=function(h,m){if(a.pending!==t)return s();try{h(t,o,function(g){g===!1||C3(g)?(a.ensureURL(!0),s(g)):typeof g=="string"||typeof g=="object"&&(typeof g.path=="string"||typeof g.name=="string")?(s(),typeof g=="object"&&g.replace?a.replace(g):a.push(g)):m(g)})}catch(g){s(g)}};wI(p,f,function(){var h=[],m=function(){return a.current===t},g=Zxe(d,h,m),y=g.concat(a.router.resolveHooks);wI(y,f,function(){if(a.pending!==t)return s();a.pending=null,r(t),a.router.app&&a.router.app.$nextTick(function(){h.forEach(function(b){b()})})})})},Vs.prototype.updateRoute=function(t){var r=this.current;this.current=t,this.cb&&this.cb(t),this.router.afterHooks.forEach(function(i){i&&i(t,r)})};function Wxe(n){if(!n)if(Hm){var t=document.querySelector("base");n=t&&t.getAttribute("href")||"/",n=n.replace(/^https?:\/\/[^\/]+/,"")}else n="/";return n.charAt(0)!=="/"&&(n="/"+n),n.replace(/\/$/,"")}function Gxe(n,t){var r,i=Math.max(n.length,t.length);for(r=0;r<i&&n[r]===t[r];r++);return{updated:t.slice(0,r),activated:t.slice(r),deactivated:n.slice(r)}}function M3(n,t,r,i){var a=xI(n,function(o,s,c,l){var u=qxe(o,t);if(u)return Array.isArray(u)?u.map(function(d){return r(d,s,c,l)}):r(u,s,c,l)});return CI(i?a.reverse():a)}function qxe(n,t){return typeof n!="function"&&(n=Um.extend(n)),n.options[t]}function Yxe(n){return M3(n,"beforeRouteLeave",SI,!0)}function Kxe(n){return M3(n,"beforeRouteUpdate",SI)}function SI(n,t){if(t)return function(){return n.apply(t,arguments)}}function Zxe(n,t,r){return M3(n,"beforeRouteEnter",function(i,a,o,s){return Jxe(i,o,s,t,r)})}function Jxe(n,t,r,i,a){return function(s,c,l){return n(s,c,function(u){l(u),typeof u=="function"&&i.push(function(){TI(u,t.instances,r,a)})})}}function TI(n,t,r,i){t[r]?n(t[r]):i()&&setTimeout(function(){TI(n,t,r,i)},16)}var EI=function(n){function t(r,i){var a=this;n.call(this,r,i);var o=r.options.scrollBehavior;o&&mI();var s=Gm(this.base);window.addEventListener("popstate",function(c){var l=a.current,u=Gm(a.base);a.current===H0&&u===s||a.transitionTo(u,function(d){o&&Ip(r,d,l,!0)})})}return n&&(t.__proto__=n),t.prototype=Object.create(n&&n.prototype),t.prototype.constructor=t,t.prototype.go=function(i){window.history.go(i)},t.prototype.push=function(i,a,o){var s=this,c=this,l=c.current;this.transitionTo(i,function(u){K0(Eu(s.base+u.fullPath)),Ip(s.router,u,l,!1),a&&a(u)},o)},t.prototype.replace=function(i,a,o){var s=this,c=this,l=c.current;this.transitionTo(i,function(u){D3(Eu(s.base+u.fullPath)),Ip(s.router,u,l,!1),a&&a(u)},o)},t.prototype.ensureURL=function(i){if(Gm(this.base)!==this.current.fullPath){var a=Eu(this.base+this.current.fullPath);i?K0(a):D3(a)}},t.prototype.getCurrentLocation=function(){return Gm(this.base)},t}(Vs);function Gm(n){var t=window.location.pathname;return n&&t.indexOf(n)===0&&(t=t.slice(n.length)),(t||"/")+window.location.search+window.location.hash}var $I=function(n){function t(r,i,a){n.call(this,r,i),!(a&&Xxe(this.base))&&AI()}return n&&(t.__proto__=n),t.prototype=Object.create(n&&n.prototype),t.prototype.constructor=t,t.prototype.setupListeners=function(){var i=this,a=this.router,o=a.options.scrollBehavior,s=Lp&&o;s&&mI(),window.addEventListener(Lp?"popstate":"hashchange",function(){var c=i.current;AI()&&i.transitionTo(Z0(),function(l){s&&Ip(i.router,l,c,!0),Lp||J0(l.fullPath)})})},t.prototype.push=function(i,a,o){var s=this,c=this,l=c.current;this.transitionTo(i,function(u){OI(u.fullPath),Ip(s.router,u,l,!1),a&&a(u)},o)},t.prototype.replace=function(i,a,o){var s=this,c=this,l=c.current;this.transitionTo(i,function(u){J0(u.fullPath),Ip(s.router,u,l,!1),a&&a(u)},o)},t.prototype.go=function(i){window.history.go(i)},t.prototype.ensureURL=function(i){var a=this.current.fullPath;Z0()!==a&&(i?OI(a):J0(a))},t.prototype.getCurrentLocation=function(){return Z0()},t}(Vs);function Xxe(n){var t=Gm(n);if(!/^\/#/.test(t))return window.location.replace(Eu(n+"/#"+t)),!0}function AI(){var n=Z0();return n.charAt(0)==="/"?!0:(J0("/"+n),!1)}function Z0(){var n=window.location.href,t=n.indexOf("#");return t===-1?"":n.slice(t+1)}function P3(n){var t=window.location.href,r=t.indexOf("#"),i=r>=0?t.slice(0,r):t;return i+"#"+n}function OI(n){Lp?K0(P3(n)):window.location.hash=n}function J0(n){Lp?D3(P3(n)):window.location.replace(P3(n))}var Qxe=function(n){function t(r,i){n.call(this,r,i),this.stack=[],this.index=-1}return n&&(t.__proto__=n),t.prototype=Object.create(n&&n.prototype),t.prototype.constructor=t,t.prototype.push=function(i,a,o){var s=this;this.transitionTo(i,function(c){s.stack=s.stack.slice(0,s.index+1).concat(c),s.index++,a&&a(c)},o)},t.prototype.replace=function(i,a,o){var s=this;this.transitionTo(i,function(c){s.stack=s.stack.slice(0,s.index).concat(c),a&&a(c)},o)},t.prototype.go=function(i){var a=this,o=this.index+i;if(!(o<0||o>=this.stack.length)){var s=this.stack[o];this.confirmTransition(s,function(){a.index=o,a.updateRoute(s)})}},t.prototype.getCurrentLocation=function(){var i=this.stack[this.stack.length-1];return i?i.fullPath:"/"},t.prototype.ensureURL=function(){},t}(Vs),yr=function(t){t===void 0&&(t={}),this.app=null,this.apps=[],this.options=t,this.beforeHooks=[],this.resolveHooks=[],this.afterHooks=[],this.matcher=Ixe(t.routes||[],this);var r=t.mode||"hash";switch(this.fallback=r==="history"&&!Lp&&t.fallback!==!1,this.fallback&&(r="hash"),Hm||(r="abstract"),this.mode=r,r){case"history":this.history=new EI(this,t.base);break;case"hash":this.history=new $I(this,t.base,this.fallback);break;case"abstract":this.history=new Qxe(this,t.base);break}},DI={currentRoute:{configurable:!0}};yr.prototype.match=function(t,r,i){return this.matcher.match(t,r,i)},DI.currentRoute.get=function(){return this.history&&this.history.current},yr.prototype.init=function(t){var r=this;if(this.apps.push(t),!this.app){this.app=t;var i=this.history;if(i instanceof EI)i.transitionTo(i.getCurrentLocation());else if(i instanceof $I){var a=function(){i.setupListeners()};i.transitionTo(i.getCurrentLocation(),a,a)}i.listen(function(o){r.apps.forEach(function(s){s._route=o})})}},yr.prototype.beforeEach=function(t){return I3(this.beforeHooks,t)},yr.prototype.beforeResolve=function(t){return I3(this.resolveHooks,t)},yr.prototype.afterEach=function(t){return I3(this.afterHooks,t)},yr.prototype.onReady=function(t,r){this.history.onReady(t,r)},yr.prototype.onError=function(t){this.history.onError(t)},yr.prototype.push=function(t,r,i){this.history.push(t,r,i)},yr.prototype.replace=function(t,r,i){this.history.replace(t,r,i)},yr.prototype.go=function(t){this.history.go(t)},yr.prototype.back=function(){this.go(-1)},yr.prototype.forward=function(){this.go(1)},yr.prototype.getMatchedComponents=function(t){var r=t?t.matched?t:this.resolve(t).route:this.currentRoute;return r?[].concat.apply([],r.matched.map(function(i){return Object.keys(i.components).map(function(a){return i.components[a]})})):[]},yr.prototype.resolve=function(t,r,i){var a=fI(t,r||this.history.current,i,this),o=this.match(a,r),s=o.redirectedFrom||o.fullPath,c=this.history.base,l=e5e(c,s,this.mode);return{location:a,route:o,href:l,normalizedTo:a,resolved:o}},yr.prototype.addRoutes=function(t){this.matcher.addRoutes(t),this.history.current!==H0&&this.history.transitionTo(this.history.getCurrentLocation())},Object.defineProperties(yr.prototype,DI);function I3(n,t){return n.push(t),function(){var r=n.indexOf(t);r>-1&&n.splice(r,1)}}function e5e(n,t,r){var i=r==="hash"?"#"+t:t;return n?Eu(n+"/"+i):i}yr.install=S3,yr.version="3.0.1",Hm&&window.Vue&&window.Vue.use(yr);const t5e=[{name:"form",path:"/form",component:()=>Promise.resolve().then(()=>Gpt),props:!0,meta:{mode:"modal",placement:"center",width:"100vw",height:"100vh"}},{name:"document",path:"/document",component:()=>Promise.resolve().then(()=>MXe),props:!0,meta:{mode:"modal",placement:"center",width:"100vw",height:"100vh",scroll:!0}},{name:"send",path:"/send",component:()=>Promise.resolve().then(()=>Xpt),props:!0,meta:{mode:"drawer",placement:"right",width:620,height:"100%"}},{name:"print",path:"/print",component:()=>Promise.resolve().then(()=>lft),props:!0,meta:{mode:"modal",placement:"center",width:400}},{name:"sendReminder",path:"/sendReminder",component:()=>Promise.resolve().then(()=>bft),props:!0,meta:{mode:"modal",placement:"center",width:400}},{name:"timeline",path:"/timeline",component:()=>Promise.resolve().then(()=>Hft),props:!0,meta:{mode:"modal",width:400}},{name:"receipt",path:"/receipt",component:()=>Promise.resolve().then(()=>eht),props:!0,meta:{mode:"modal",width:600}},{name:"clientLinks",path:"/clientLinks",component:()=>Promise.resolve().then(()=>oht),props:!0,meta:{mode:"modal",width:400}},{name:"documentClient",path:"/documentClient",component:()=>Promise.resolve().then(()=>xht),props:!0,meta:{mode:"modal",placement:"center",width:"100vw",height:"100vh"}},{name:"setup",path:"/setup",component:()=>Promise.resolve().then(()=>$ht),props:!0,meta:{mode:"modal",placement:"center",width:"500px",height:"700px"}},{name:"docAnswer",path:"/docAnswer",component:()=>Promise.resolve().then(()=>Iht),props:!0,meta:{mode:"modal",placement:"center",width:420}},{name:"docDetails",path:"/docDetails",component:()=>Promise.resolve().then(()=>Qht),props:!0,meta:{mode:"drawer",placement:"right",width:540,height:"100%"}}];Ne.use(yr);const Us=new yr({mode:"abstract",routes:t5e}),mn=Ne.observable({_openViews:[],_styleVars:{},get openViews(){return this._openViews},get view(){var n;return this.open&&((n=Us.currentRoute)==null?void 0:n.name)||null},get language(){return Be.lang},get locale(){return Be.locale},get styleVars(){return this._styleVars},set styleVars(n){this._styleVars={...n}},addView({key:n,view:t,mode:r,viewOpts:i}){const a={view:t,mode:r,key:n,viewOpts:i};if(["modal","drawer"].includes(r)&&Us.push({name:t,params:i}),r==="mount"){const{routes:o}=Us.options||[];if(!o.map(c=>c.name).includes(t))throw new Error(`View ${t} not supported`);const s=o.find(c=>c.name===t);a.viewOpts={component:s.component,...i}}this._openViews.push(a),Pr.trigger("ui:open",{key:n,view:t,mode:r})},removeView({key:n,view:t,mode:r}){const i=this._openViews.findIndex(a=>a.key===n&&a.mode===r&&a.view===t);if(r==="mount"){const a=document.getElementById(`${n}-${r}-${t}`);a&&(a.textContent="")}i>-1&&this._openViews.splice(i,1),["modal","drawer"].includes(r)&&Us.push("/"),Pr.trigger("ui:close",{key:n,mode:r,view:t})},removeAllOverlayViews(){var n,t,r,i;(r=(t=(n=Ne.prototype)==null?void 0:n.$modal)==null?void 0:t.hideAll)==null||r.call(t),(i=this._openViews.filter(a=>a.mode==="modal"||a.mode==="dynamicModal"||a.mode==="drawer"))==null||i.forEach(a=>this.removeView(a))},setLanguage(n){Be.i18next.changeLanguage(n,!0)},setLocale(n){Be.l10n.changeLocale(n,!0)},on(n,t){if(!["open","close","document.block.answer.visible"].includes(n))throw new Error(`Event ${n} not supported`);return Pr.on(`ui:${n}`,t)}});var n5e=dp,r5e=js,i5e="[object Symbol]";function a5e(n){return typeof n=="symbol"||r5e(n)&&n5e(n)==i5e}var X0=a5e,o5e=Zo,s5e=X0,l5e=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,c5e=/^\w*$/;function u5e(n,t){if(o5e(n))return!1;var r=typeof n;return r=="number"||r=="symbol"||r=="boolean"||n==null||s5e(n)?!0:c5e.test(n)||!l5e.test(n)||t!=null&&n in Object(t)}var R3=u5e,MI=m4,d5e="Expected a function";function L3(n,t){if(typeof n!="function"||t!=null&&typeof t!="function")throw new TypeError(d5e);var r=function(){var i=arguments,a=t?t.apply(this,i):i[0],o=r.cache;if(o.has(a))return o.get(a);var s=n.apply(this,i);return r.cache=o.set(a,s)||o,s};return r.cache=new(L3.Cache||MI),r}L3.Cache=MI;var p5e=L3,f5e=p5e,h5e=500;function m5e(n){var t=f5e(n,function(i){return r.size===h5e&&r.clear(),i}),r=t.cache;return t}var g5e=m5e,v5e=g5e,y5e=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,b5e=/\\(\\)?/g,_5e=v5e(function(n){var t=[];return n.charCodeAt(0)===46&&t.push(""),n.replace(y5e,function(r,i,a,o){t.push(a?o.replace(b5e,"$1"):i||r)}),t}),w5e=_5e;function x5e(n,t){for(var r=-1,i=n==null?0:n.length,a=Array(i);++r<i;)a[r]=t(n[r],r,n);return a}var F3=x5e,PI=up,C5e=F3,k5e=Zo,S5e=X0,T5e=1/0,II=PI?PI.prototype:void 0,RI=II?II.toString:void 0;function LI(n){if(typeof n=="string")return n;if(k5e(n))return C5e(n,LI)+"";if(S5e(n))return RI?RI.call(n):"";var t=n+"";return t=="0"&&1/n==-T5e?"-0":t}var E5e=LI,$5e=E5e;function A5e(n){return n==null?"":$5e(n)}var O5e=A5e,D5e=Zo,M5e=R3,P5e=w5e,I5e=O5e;function R5e(n,t){return D5e(n)?n:M5e(n,t)?[n]:P5e(I5e(n))}var Fp=R5e,L5e=X0,F5e=1/0;function N5e(n){if(typeof n=="string"||L5e(n))return n;var t=n+"";return t=="0"&&1/n==-F5e?"-0":t}var Np=N5e,B5e=Fp,j5e=Np;function z5e(n,t){t=B5e(t,n);for(var r=0,i=t.length;n!=null&&r<i;)n=n[j5e(t[r++])];return r&&r==i?n:void 0}var Q0=z5e,V5e=v4,U5e=Fp,H5e=_4,FI=Ko,W5e=Np;function G5e(n,t,r,i){if(!FI(n))return n;t=U5e(t,n);for(var a=-1,o=t.length,s=o-1,c=n;c!=null&&++a<o;){var l=W5e(t[a]),u=r;if(l==="__proto__"||l==="constructor"||l==="prototype")return n;if(a!=s){var d=c[l];u=i?i(d,l,c):void 0,u===void 0&&(u=FI(d)?d:H5e(t[a+1])?[]:{})}V5e(c,l,u),c=c[l]}return n}var NI=G5e,q5e=Q0,Y5e=NI,K5e=Fp;function Z5e(n,t,r){for(var i=-1,a=t.length,o={};++i<a;){var s=t[i],c=q5e(n,s);r(c,s)&&Y5e(o,K5e(s,n),c)}return o}var J5e=Z5e;function X5e(n,t){return n!=null&&t in Object(n)}var Q5e=X5e,e4e=Fp,t4e=y4,n4e=Zo,r4e=_4,i4e=w4,a4e=Np;function o4e(n,t,r){t=e4e(t,n);for(var i=-1,a=t.length,o=!1;++i<a;){var s=a4e(t[i]);if(!(o=n!=null&&r(n,s)))break;n=n[s]}return o||++i!=a?o:(a=n==null?0:n.length,!!a&&i4e(a)&&r4e(s,a)&&(n4e(n)||t4e(n)))}var s4e=o4e,l4e=Q5e,c4e=s4e;function u4e(n,t){return n!=null&&c4e(n,t,l4e)}var BI=u4e,d4e=J5e,p4e=BI;function f4e(n,t){return d4e(n,t,function(r,i){return p4e(n,i)})}var h4e=f4e,jI=up,m4e=y4,g4e=Zo,zI=jI?jI.isConcatSpreadable:void 0;function v4e(n){return g4e(n)||m4e(n)||!!(zI&&n&&n[zI])}var y4e=v4e,b4e=E4,_4e=y4e;function VI(n,t,r,i,a){var o=-1,s=n.length;for(r||(r=_4e),a||(a=[]);++o<s;){var c=n[o];t>0&&r(c)?t>1?VI(c,t-1,r,i,a):b4e(a,c):i||(a[a.length]=c)}return a}var UI=VI,w4e=UI;function x4e(n){var t=n==null?0:n.length;return t?w4e(n,1):[]}var C4e=x4e;function k4e(n,t,r){switch(r.length){case 0:return n.call(t);case 1:return n.call(t,r[0]);case 2:return n.call(t,r[0],r[1]);case 3:return n.call(t,r[0],r[1],r[2])}return n.apply(t,r)}var S4e=k4e,T4e=S4e,HI=Math.max;function E4e(n,t,r){return t=HI(t===void 0?n.length-1:t,0),function(){for(var i=arguments,a=-1,o=HI(i.length-t,0),s=Array(o);++a<o;)s[a]=i[t+a];a=-1;for(var c=Array(t+1);++a<t;)c[a]=i[a];return c[t]=r(s),T4e(n,this,c)}}var WI=E4e;function $4e(n){return function(){return n}}var A4e=$4e;function O4e(n){return n}var N3=O4e,D4e=A4e,GI=_D,M4e=N3,P4e=GI?function(n,t){return GI(n,"toString",{configurable:!0,enumerable:!1,value:D4e(t),writable:!0})}:M4e,I4e=P4e,R4e=800,L4e=16,F4e=Date.now;function N4e(n){var t=0,r=0;return function(){var i=F4e(),a=L4e-(i-r);if(r=i,a>0){if(++t>=R4e)return arguments[0]}else t=0;return n.apply(void 0,arguments)}}var B4e=N4e,j4e=I4e,z4e=B4e,V4e=z4e(j4e),qI=V4e,U4e=C4e,H4e=WI,W4e=qI;function G4e(n){return W4e(H4e(n,void 0,U4e),n+"")}var YI=G4e,q4e=h4e,Y4e=YI,K4e=Y4e(function(n,t){return n==null?{}:q4e(n,t)}),Z4e=K4e;const J4e=cn(Z4e);var X4e=R4,Q4e=1,e3e=4;function t3e(n){return X4e(n,Q4e|e3e)}var n3e=t3e;const Hs=cn(n3e);class qm extends Error{constructor(r={}){super(r);Pn(this,"isCustom",!0);Pn(this,"code",null);Pn(this,"httpStatusCode",null);Pn(this,"payload",{code:null,fallbackCode:null,string:null,object:null,objectId:null,action:null,actionPayload:null,retries:0,axios:null,showMessage:!0});typeof r.stack=="string"&&(this.stack=r.stack.replace(/.*\n/i,`${this.constructor.name}: ${r.message}
|
|
437
|
-
`))}add(r){return this.payload={...this.payload,...r},this}getPayload(){return this.payload}setErrorCodeFromResponse(){const{data:r,status:i}=this.getPayload().axios||{};if(!r&&!i)return;const{errorCode:a}=r||{};a&&this.add({code:a}),i&&(this.httpStatusCode=i)}setMessageFromResponse(){const{data:r}=this.getPayload().axios||{};if(!r)return!1;const{message:i}=r||{};return i?(this.message=i,!0):!1}}class KI extends qm{constructor(t){if(super(t),this.name="NotFoundError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse()}}class ZI extends qm{constructor(t){if(super(t),this.name="ForbiddenError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse(),this.setMessageFromResponse()}}class JI extends qm{constructor(t){if(super(t),this.name="ValidationError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse(),this.setMessageFromResponse()}}class XI extends qm{constructor(t){if(super(t),this.name="NetworkError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{config:r}=t;this.add({axios:r}),this.code="ECONNREFUSED"}}class B3 extends qm{constructor(t){if(super(t),this.name="GeneralError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse(),this.setMessageFromResponse()}}const QI=Object.freeze(Object.defineProperty({__proto__:null,ForbiddenError:ZI,GeneralError:B3,NetworkError:XI,NotFoundError:KI,ValidationError:JI},Symbol.toStringTag,{value:"Module"})),r3e=n=>{const t=Object.keys(n);let r="";return t.forEach(i=>{const a=typeof n[i]=="object",o=a&&n[i].length>=0;a||(r+=`${i}=${n[i]}&`),a&&o&&n[i].forEach(s=>{r+=`${i}=${s}&`})}),r&&r.slice(0,-1)},eR=n=>{j3.push(n)},i3e=n=>{j3.map(t=>t(n))};function tR(){console.error("User should be logged out!!"),wt.removeItem("token"),wt.removeItem("tokenExpires"),wt.removeItem("refreshToken"),Pr.trigger("user:unauthorized",{error})}let Ym=!1,j3=[];const a3e=(n,{renewToken:t})=>{n.interceptors.request.use(r=>{const i=r;if(i.url.includes("/auth")||i.url.startsWith("/public/"))return i;const a=i.headers["X-TOKEN"];if(!a)return i;const o=wt.getItem("tokenExpires");if(a&&o){const s=new Date;s.setSeconds(s.getSeconds()+30);const c=new Date(o);if(s>c)return t(),new Promise(u=>{eR(d=>{i.headers["X-TOKEN"]=d,u(i)})})}return i},r=>Promise.reject(r))},o3e=(n,{renewToken:t})=>{n.interceptors.response.use(r=>r,r=>{if(!r||!r.response)return Promise.reject(r);const{config:i,response:a}=r,{status:o,data:s}=a,{errorCode:c}=s,l=i;if(l.url.startsWith("/public/"))return Promise.reject(r);function u(){if(c===8001)return!0;const d=wt.getItem("tokenExpires");if(d){const p=new Date,f=new Date(d);return p>f}return!1}if(o===401&&l.headers["X-TOKEN"]&&u()&&!Ym)return t(),new Promise(p=>{eR(f=>{l.headers["X-TOKEN"]=f,p(gi(l))})});if(o===401&&typeof c>"u"){if(l.url.includes("auth/companyUser")&&!l.headers["X-TOKEN"])return Promise.reject(r);if(l.url.includes("auth/actionlink")&&!l.headers["X-TOKEN"])return Promise.reject(r);tR()}return Promise.reject(r)})},nR=n=>(v0(n.data),n),s3e=n=>{n.interceptors.response.use(nR,t=>{const{response:r,config:i}=t;if(!r)throw new XI(t);if(Object.prototype.hasOwnProperty.call(i,"errorHandle")&&i.errorHandle===!1)return Promise.reject(t);const{status:a}=r;switch(a){case 404:throw new KI(t);case 401:throw new ZI(t);case 412:throw new JI(t);default:throw new B3(t)}})},l3e=n=>{n.interceptors.response.use(t=>{var r,i;if((i=(r=t.config)==null?void 0:r.url)!=null&&i.includes("document")&&t.config.method==="post"){const a=JSON.parse(t.config.data);a.__tempId&&(t.data.__tempId=a.__tempId)}return t},t=>Promise.reject(t))},c3e=n=>{n.interceptors.request.use(t=>{if(["post","put"].includes(t.method)&&t.data&&!(t.data instanceof FormData)){const r=Hs(t.data);N4(r),t.data=r}return t},t=>Promise.reject(t))},u3e=({baseUrl:n,withCredentials:t,cache:r})=>{const i=gi.create({baseURL:n,timeout:2e4,adapter:r,withCredentials:t,paramsSerializer:p=>r3e(p)});i.defaults.headers["X-CLIENT"]="widget",i.defaults.headers["X-CLIENT-VERSION"]="0.10.1";const a=async(p,f,h=null,m={})=>{const g=f.startsWith("/public/"),y=wt.getItem("token");switch(y&&!g&&(i.defaults.headers["X-TOKEN"]=y),p){case"get":return i.get(f,m);case"post":return i.post(f,h,m);case"put":return i.put(f,h,m);case"delete":return i.delete(f,m);case"patch":return i.patch(f,h,m);default:throw new Error(`SendRequest failed as method: '${p}' is not implemented`)}},o=(p,f={})=>a("get",p,null,f),s=(p,f={},h={})=>a("put",p,f,h),c=(p,f,h={})=>a("post",p,f,h),l=(p,f={})=>a("delete",p,null,f),u=(p,f={})=>a("patch",p,null,f),d=async()=>{if(!Ym)try{Ym=!0;const p=wt.getItem("refreshToken"),f=await c("/auth/companyUser",{refreshToken:p});if(!f.data||!f.data.token)throw new Error("No token was defined in result");const{token:h,tokenExpires:m,refreshToken:g}=f.data;wt.setItem("token",h),wt.setItem("tokenExpires",m),g&&wt.setItem("refreshToken",g),Ym=!1,i3e(h),j3=[]}catch(p){return console.error(p),tR()}finally{Ym=!1}};return a3e(i,{renewToken:d}),o3e(i,{renewToken:d}),nR(i),s3e(i),c3e(i),l3e(i),{instance:i,get:o,put:s,post:c,del:l,patch:u,renewToken:d}},z3=new Map;function d3e(n){if(typeof n>"u")throw new Error("Missing valid parameter url");if(typeof n!="string")throw new Error("Parameter url must be a string");const{data:t,cachedAt:r,expiresAt:i}=z3.get(n)||{};return Date.now()>r+6e4*30||i&&Date.now()>i?(z3.delete(n),null):t}const p3e=async n=>{const{url:t,params:r={}}=n,i=Object.keys(r).map(s=>`${s}=${r[s]}`).join("&"),a=`${t}${i?`?${i}`:""}`;return d3e(a),await gi({...n,adapter:gi.defaults.adapter})},Bp={withCredentials:!0,baseUrl:Xe.api.baseUrl},{get:xt,post:nn,put:Vr,patch:Xo,del:qi,instance:U9t,renewToken:f3e}=u3e({withCredentials:Bp.withCredentials,baseUrl:Bp.baseUrl,cache:p3e});async function rR(n){const t=F1e(n);return xt(`/project${t}`,{saveCache:!0})}const h3e=async(n,t={})=>xt("/project",n,{params:t}),m3e=async(n,t={})=>xt(`/project/${n}`,{params:t,saveCache:!0}),g3e=async(n,t,r={})=>Vr(`/project/${n}`,t,{params:r,invalidateCache:{type:"project",id:n}}),v3e=async n=>Xo(`/project/${n}`),y3e=async(n,t={})=>qi(`/project/${n}`,{params:t,invalidateCache:{type:"project",id:n}}),b3e=async()=>xt("/project/createDemo"),_3e=()=>xt("/"),w3e=async(n,t={})=>nn("/auth/actionlink",{token:n,...t}),x3e=async n=>nn("/register",n),C3e=async(n,t)=>nn("/companyUser/forgottenPassword/new",{password:n,resetPasswordToken:t}),k3e=async n=>nn("/public/consent",n),S3e=async n=>xt(`/projectFile/${n}`),T3e=async n=>nn("/projectFile",n),E3e=async(n,t)=>Vr(`/projectFile/${n}`,t),$3e=async n=>qi(`/projectFile/${n}`),A3e=async n=>Xo(`/projectFile/${n}`),O3e=async(n,t={})=>xt(`/projectNote/${n}`,{params:t}),D3e=async(n,t={})=>nn("/projectNote",n,{params:t}),M3e=async(n,t,r={})=>Vr(`/projectNote/${n}`,t,{params:r}),P3e=async n=>xt(`/file/${n}`),iR=async n=>nn("/file",n),I3e=async(n,t)=>Vr(`/file/${n}`,t),R3e=async n=>qi(`/file/${n}`),L3e=async n=>Xo(`/file/${n}`),F3e=async(n={})=>xt("/article",{params:n}),N3e=async n=>xt(`/article/${n}`),B3e=async n=>nn("/article",n),j3e=async(n,t)=>Vr(`/article/${n}`,t),z3e=async n=>qi(`/article/${n}`),V3e=async n=>Xo(`/article/${n}`),U3e=async n=>nn("/search",{type:"article",query:n}),Km={get:async(n,t={})=>xt(n?`/unitType/${n}`:"/unitType",{params:t,saveCache:!0}),post:async(n,t={})=>nn("/unitType",n,{params:t}),put:async(n,t,r={})=>Vr(`/unitType/${n}`,t,{params:r,invalidateCache:{type:"unitType",id:n}}),delete:async(n,t={})=>qi(`/unitType/${n}`,{params:t,invalidateCache:{type:"unitType",id:n}})},H3e=async(n={})=>xt("/templateMessage",{params:n,saveCache:!0}),W3e=async(n,t={})=>xt(`/templateMessage/${n}`,{params:t,saveCache:!0}),G3e=async(n,t={})=>nn("/templateMessage",n,{params:t}),q3e=async(n,t,r={})=>Vr(`/templateMessage/${n}`,t,{params:r,invalidateCache:{type:"templateMessage",id:n}}),Y3e=async(n,t={})=>qi(`/templateMessage/${n}`,{params:t,invalidateCache:{type:"templateMessage",id:n}}),K3e=async(n,t={})=>Xo(`/templateMessage/${n}`,{params:t}),Z3e=async(n={})=>xt("/endCustomer",{params:n}),J3e=async(n,t={})=>xt(`/endCustomer/${n}`,{params:t}),X3e=async(n,t={})=>nn("/endCustomer",n,{params:t}),Q3e=async(n,t,r={})=>Vr(`/endCustomer/${n}`,t,{params:r}),eCe=async(n,t={})=>qi(`/endCustomer/${n}`,{params:t}),tCe=async(n,t={})=>Xo(`/endCustomer/${n}`,{params:t}),nCe=async(n={})=>xt("/companyUser",{params:n,saveCache:!0}),rCe=async(n,t={})=>xt(`/companyUser/${n}`,{params:t,saveCache:!0}),iCe=async(n,t={})=>nn("/companyUser",n,{params:t}),aCe=async(n,t,r={})=>Vr(`/companyUser/${n}`,t,{params:r,invalidateCache:{type:"companyUser",id:n}}),oCe=async(n,t={})=>qi(`/companyUser/${n}`,{params:t,invalidateCache:{type:"companyUser",id:n}}),sCe=async(n,t={})=>Xo(`/companyUser/${n}`,{params:t}),aR={getPublic:async(n,t={})=>xt(`/public/companyUser/${n}`,{params:t}),getConnectedUsers:async(n={})=>xt("/companyUser/self/connectedUsers",{params:n}),getConnectedUserAuth:async(n,t={})=>xt(`/companyUser/self/connectedUsers/${n}/auth`,{params:t}),setConnectedUserDefault:async(n,t={})=>Vr(`/companyUser/self/connectedUsers/${n}/setDefaultAuth`,{params:t}),verifyEmail:async(n,t={})=>nn("/public/verifyEmail/companyUser",n,{params:t})},lCe=async(n,t=null,r={})=>Vr(`/companyAccount/accountType/${n}`,t,{params:r}),cCe=async(n={})=>xt("/companyAccount/getNumberOfManagers",{params:n}),uCe=async(n={})=>nn("/companyAccount/addUserLicenseInvoice",{},{params:n}),dCe=async(n,t={})=>xt(`/promotionCode/${n}/canUse`,{params:t}),pCe=async(n,t={})=>xt("/promotionCode/inUse",{params:t}),ey={product:async(n,t={})=>nn("/companyAccount/product",n,{params:t}),cancelAll:async(n={})=>qi("/companyAccount/subscription",{params:n}),getPrices:async(n={})=>xt("/companyAccount/price",{params:n}),getUpcomingInvoices:async(n={})=>xt("/companyAccount/upcomingInvoice",{params:n}),getPaymentHistory:async(n={})=>xt("/companyAccount/paymentHistory",{params:n}),putPaymentMethod:async(n,t={})=>Vr("/companyAccount/paymentMethod",n,{params:t}),putCustomer:async(n,t={})=>Vr("/companyAccount/customer",n,{params:t}),createCheckoutSession:async(n,t={})=>nn("/companyAccount/create-checkout-session",n,{params:t})},fCe=async(n,t)=>nn(`/project/${n}/projectMember/${t}`,null,{invalidateCache:{type:"project",id:n}}),hCe=async(n,t)=>qi(`/project/${n}/projectMember/${t}`,{invalidateCache:{type:"project",id:n}}),Yi={get:async(n,t={})=>xt(`/document/${n}`,{params:t,saveCache:!0}),getAll:async(n={})=>xt("/document",{params:n,saveCache:!0}),post:async(n,t={})=>nn("/document",n,{params:t}),send:async(n,t={},r={})=>nn(`/document/${n}/send`,t,{params:r,invalidateCache:{type:"document",id:n}}),clearAnswers:async(n,t={},r={})=>nn(`/document/${n}/clearAnswers`,t,{params:r,invalidateCache:{type:"document",id:n}}),put:async(n,t,r={})=>Vr(`/document/${n}`,t,{params:r,invalidateCache:{type:"document",id:n}}),delete:async(n,t={})=>qi(`/document/${n}`,{params:t,invalidateCache:{type:"document",id:n}}),patch:async(n,t={})=>Xo(`/document/${n}`,{params:t}),validate:async(n,t={})=>nn("/documentValidate",n,{params:t})},$u={get:async(n,t={})=>xt(n?`/template/${n}`:"/template",{params:t}),post:async(n,t={})=>nn("/template",n,{params:t}),put:async(n,t,r={})=>Vr(`/template/${n}`,t,{params:r}),delete:async(n,t={})=>qi(`/template/${n}`,{params:t}),patch:async(n,t={})=>Xo(`/template/${n}`,{params:t})},mCe={get:async(n={})=>xt("/templateGallery",{params:n})},gCe={get:async(n,t={})=>xt(`/public/templateStat/${n}`,{params:t})},jp={get:async(n,t={})=>xt(`/public/document/${n}`,{params:t}),put:async(n,t,r={})=>Vr(`/public/document/${n}`,t,{headers:r}),answer:async(n,t,r={},i={})=>nn(`/public/document/${n}/answer`,t,{params:r,headers:i}),feedback:async(n,t,r={})=>nn(`/public/document/${n}/feedback`,t,{params:r})},oR={get:async(n,t={})=>xt(`/public/pdfJob/${n}`,{params:t}),addDocument:async(n,t={})=>xt(`/public/document/${n}/pdfJob/start`,{params:t})},sR={getDocuments:async(n={})=>{const t=wt.getItem("clientToken");return gi.get(`${Bp.baseUrl}/client/document`,{headers:{Authorization:t},params:n})},requestMagicLink:async(n,t={})=>gi.post(`${Bp.baseUrl}/client/requestMagicLink`,n,{params:t})},ty={get:async(n,t={})=>xt(`/public/company/${n}`,{params:t}),getCertificates:async(n,t={})=>xt(`/public/company/${n}/certificates`,{params:t}),getReferences:async(n,t={})=>xt(`/public/company/${n}/references`,{params:t})},vCe={get:async(n,t={})=>xt(`${Bp.baseUrl}/public/signature/${n}`,{params:t})},V3={post:async(n,t={})=>nn("/voucher",n,{params:t}),canUse:async(n,t={})=>xt(`/voucher/${n}/canUse`,{params:t})},Jl={getAuthUrl:async(n,t={})=>xt("/extension/authUrl",{params:{...t,service:n}}),getPublicAuthUrl:async(n,t={})=>xt("/public/extension/authUrl",{params:{...t,service:n}}),install:async(n,t,r={})=>nn("/extension/install",t,{params:{...r,service:n}}),uninstall:async(n,t={})=>qi("/extension/uninstall",{params:{...t,service:n}}),suggestClients:async(n,t={})=>xt("/extension/suggestClients",{params:{...t,service:n},saveCache:!0,cacheTtl:20}),signupWithCrm:async(n,t,r={})=>nn("/public/extension/register",t,{params:{...r,service:n}}),search:async(n,t={})=>xt("/extension/search",{params:{...t,service:n},saveCache:!0,cacheTtl:10}),getFields:async(n,t={})=>xt("/extension/fields",{params:{...t,service:n},saveCache:!0,cacheTtl:60}),getExternalReferenceDetails:async(n,t={})=>xt("/extension/externalReferenceDetails",{params:{...t,service:n},saveCache:!0,cacheTtl:20}),settings:async(n,t={})=>xt("/extension/settings",{params:{...t,service:n}})},ni={get:xt,post:nn,put:Vr,del:qi,patch:Xo,authData:Bp,getProjects:rR};var lR={exports:{}};(function(n,t){(function(r,i){n.exports=i()})(Kt,function(){return function(r){var i={};function a(o){if(i[o])return i[o].exports;var s=i[o]={i:o,l:!1,exports:{}};return r[o].call(s.exports,s,s.exports,a),s.l=!0,s.exports}return a.m=r,a.c=i,a.d=function(o,s,c){a.o(o,s)||Object.defineProperty(o,s,{enumerable:!0,get:c})},a.r=function(o){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(o,"__esModule",{value:!0})},a.t=function(o,s){if(1&s&&(o=a(o)),8&s||4&s&&typeof o=="object"&&o&&o.__esModule)return o;var c=Object.create(null);if(a.r(c),Object.defineProperty(c,"default",{enumerable:!0,value:o}),2&s&&typeof o!="string")for(var l in o)a.d(c,l,function(u){return o[u]}.bind(null,l));return c},a.n=function(o){var s=o&&o.__esModule?function(){return o.default}:function(){return o};return a.d(s,"a",s),s},a.o=function(o,s){return Object.prototype.hasOwnProperty.call(o,s)},a.p="",a(a.s=6)}([function(r,i,a){var o=a(12),s={};function c($,T){return T===l($)}function l($){var T=typeof $;return T!=="object"?T:$?$ instanceof Error?"error":{}.toString.call($).match(/\s([a-zA-Z]+)/)[1].toLowerCase():"null"}function u($){return c($,"function")}function d($){var T=Function.prototype.toString.call(Object.prototype.hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?"),A=RegExp("^"+T+"$");return p($)&&A.test($)}function p($){var T=typeof $;return $!=null&&(T=="object"||T=="function")}function f(){var $=k();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(T){var A=($+16*Math.random())%16|0;return $=Math.floor($/16),(T==="x"?A:7&A|8).toString(16)})}var h={strictMode:!1,key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],q:{name:"queryKey",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}};function m($,T){var A,E;try{A=s.stringify($)}catch(I){if(T&&u(T))try{A=T($)}catch(R){E=R}else E=I}return{error:E,value:A}}function g($,T){return function(A,E){try{T(A,E)}catch(I){$.error(I)}}}function y($){return function T(A,E){var I,R,Y,L={};try{for(R in A)(I=A[R])&&(c(I,"object")||c(I,"array"))?E.includes(I)?L[R]="Removed circular reference: "+l(I):((Y=E.slice()).push(I),L[R]=T(I,Y)):L[R]=I}catch(D){L="Failed cloning custom data: "+D.message}return L}($,[$])}var b=["log","network","dom","navigation","error","manual"],w=["critical","error","warning","info","debug"];function S($,T){for(var A=0;A<$.length;++A)if($[A]===T)return!0;return!1}function k(){return Date.now?+Date.now():+new Date}r.exports={addParamsAndAccessTokenToPath:function($,T,A){(A=A||{}).access_token=$;var E,I=[];for(E in A)Object.prototype.hasOwnProperty.call(A,E)&&I.push([E,A[E]].join("="));var R="?"+I.sort().join("&");(T=T||{}).path=T.path||"";var Y,L=T.path.indexOf("?"),D=T.path.indexOf("#");L!==-1&&(D===-1||D>L)?(Y=T.path,T.path=Y.substring(0,L)+R+"&"+Y.substring(L+1)):D!==-1?(Y=T.path,T.path=Y.substring(0,D)+R+Y.substring(D)):T.path=T.path+R},createItem:function($,T,A,E,I){for(var R,Y,L,D,B,z,K=[],te=[],j=0,M=$.length;j<M;++j){var q=l(z=$[j]);switch(te.push(q),q){case"undefined":break;case"string":R?K.push(z):R=z;break;case"function":D=g(T,z);break;case"date":K.push(z);break;case"error":case"domexception":case"exception":Y?K.push(z):Y=z;break;case"object":case"array":if(z instanceof Error||typeof DOMException<"u"&&z instanceof DOMException){Y?K.push(z):Y=z;break}if(E&&q==="object"&&!B){for(var G=0,ee=E.length;G<ee;++G)if(z[E[G]]!==void 0){B=z;break}if(B)break}L?K.push(z):L=z;break;default:if(z instanceof Error||typeof DOMException<"u"&&z instanceof DOMException){Y?K.push(z):Y=z;break}K.push(z)}}L&&(L=y(L)),K.length>0&&(L||(L=y({})),L.extraArgs=y(K));var ae={message:R,err:Y,custom:L,timestamp:k(),callback:D,notifier:A,diagnostic:{},uuid:f()};return function(ve,ye){ye&&ye.level!==void 0&&(ve.level=ye.level,delete ye.level),ye&&ye.skipFrames!==void 0&&(ve.skipFrames=ye.skipFrames,delete ye.skipFrames)}(ae,L),E&&B&&(ae.request=B),I&&(ae.lambdaContext=I),ae._originalArgs=$,ae.diagnostic.original_arg_types=te,ae},addErrorContext:function($,T){var A=$.data.custom||{},E=!1;try{for(var I=0;I<T.length;++I)T[I].hasOwnProperty("rollbarContext")&&(A=o(A,y(T[I].rollbarContext)),E=!0);E&&($.data.custom=A)}catch(R){$.diagnostic.error_context="Failed: "+R.message}},createTelemetryEvent:function($){for(var T,A,E,I,R=0,Y=$.length;R<Y;++R)switch(l(I=$[R])){case"string":!T&&S(b,I)?T=I:!E&&S(w,I)&&(E=I);break;case"object":A=I}return{type:T||"manual",metadata:A||{},level:E}},filterIp:function($,T){if($&&$.user_ip&&T!==!0){var A=$.user_ip;if(T)try{var E;if(A.indexOf(".")!==-1)(E=A.split(".")).pop(),E.push("0"),A=E.join(".");else if(A.indexOf(":")!==-1){if((E=A.split(":")).length>2){var I=E.slice(0,3),R=I[2].indexOf("/");R!==-1&&(I[2]=I[2].substring(0,R)),A=I.concat("0000:0000:0000:0000:0000").join(":")}}else A=null}catch{A=null}else A=null;$.user_ip=A}},formatArgsAsString:function($){var T,A,E,I=[];for(T=0,A=$.length;T<A;++T){switch(l(E=$[T])){case"object":(E=(E=m(E)).error||E.value).length>500&&(E=E.substr(0,497)+"...");break;case"null":E="null";break;case"undefined":E="undefined";break;case"symbol":E=E.toString()}I.push(E)}return I.join(" ")},formatUrl:function($,T){if(!(T=T||$.protocol)&&$.port&&($.port===80?T="http:":$.port===443&&(T="https:")),T=T||"https:",!$.hostname)return null;var A=T+"//"+$.hostname;return $.port&&(A=A+":"+$.port),$.path&&(A+=$.path),A},get:function($,T){if($){var A=T.split("."),E=$;try{for(var I=0,R=A.length;I<R;++I)E=E[A[I]]}catch{E=void 0}return E}},handleOptions:function($,T,A,E){var I=o($,T,A);return I=function(R,Y){return R.hostWhiteList&&!R.hostSafeList&&(R.hostSafeList=R.hostWhiteList,R.hostWhiteList=void 0,Y&&Y.log("hostWhiteList is deprecated. Use hostSafeList.")),R.hostBlackList&&!R.hostBlockList&&(R.hostBlockList=R.hostBlackList,R.hostBlackList=void 0,Y&&Y.log("hostBlackList is deprecated. Use hostBlockList.")),R}(I,E),!T||T.overwriteScrubFields||T.scrubFields&&(I.scrubFields=($.scrubFields||[]).concat(T.scrubFields)),I},isError:function($){return c($,"error")||c($,"exception")},isFiniteNumber:function($){return Number.isFinite($)},isFunction:u,isIterable:function($){var T=l($);return T==="object"||T==="array"},isNativeFunction:d,isObject:p,isString:function($){return typeof $=="string"||$ instanceof String},isType:c,isPromise:function($){return p($)&&c($.then,"function")},jsonParse:function($){var T,A;try{T=s.parse($)}catch(E){A=E}return{error:A,value:T}},LEVELS:{debug:0,info:1,warning:2,error:3,critical:4},makeUnhandledStackInfo:function($,T,A,E,I,R,Y,L){var D={url:T||"",line:A,column:E};D.func=L.guessFunctionName(D.url,D.line),D.context=L.gatherContext(D.url,D.line);var B=typeof document<"u"&&document&&document.location&&document.location.href,z=typeof window<"u"&&window&&window.navigator&&window.navigator.userAgent;return{mode:R,message:I?String(I):$||Y,url:B,stack:[D],useragent:z}},merge:o,now:k,redact:function(){return"********"},RollbarJSON:s,sanitizeUrl:function($){var T=function(A){if(c(A,"string")){for(var E=h,I=E.parser[E.strictMode?"strict":"loose"].exec(A),R={},Y=0,L=E.key.length;Y<L;++Y)R[E.key[Y]]=I[Y]||"";return R[E.q.name]={},R[E.key[12]].replace(E.q.parser,function(D,B,z){B&&(R[E.q.name][B]=z)}),R}}($);return T?(T.anchor===""&&(T.source=T.source.replace("#","")),$=T.source.replace("?"+T.query,"")):"(unknown)"},set:function($,T,A){if($){var E=T.split("."),I=E.length;if(!(I<1))if(I!==1)try{for(var R=$[E[0]]||{},Y=R,L=1;L<I-1;++L)R[E[L]]=R[E[L]]||{},R=R[E[L]];R[E[I-1]]=A,$[E[0]]=Y}catch{return}else $[E[0]]=A}},setupJSON:function($){u(s.stringify)&&u(s.parse)||(c(JSON,"undefined")||($?(d(JSON.stringify)&&(s.stringify=JSON.stringify),d(JSON.parse)&&(s.parse=JSON.parse)):(u(JSON.stringify)&&(s.stringify=JSON.stringify),u(JSON.parse)&&(s.parse=JSON.parse))),u(s.stringify)&&u(s.parse)||$&&$(s))},stringify:m,maxByteSize:function($){for(var T=0,A=$.length,E=0;E<A;E++){var I=$.charCodeAt(E);I<128?T+=1:I<2048?T+=2:I<65536&&(T+=3)}return T},typeName:l,uuid4:f}},function(r,i,a){a(17);var o=a(18),s=a(0);r.exports={error:function(){var c=Array.prototype.slice.call(arguments,0);c.unshift("Rollbar:"),o.ieVersion()<=8?console.error(s.formatArgsAsString(c)):console.error.apply(console,c)},info:function(){var c=Array.prototype.slice.call(arguments,0);c.unshift("Rollbar:"),o.ieVersion()<=8?console.info(s.formatArgsAsString(c)):console.info.apply(console,c)},log:function(){var c=Array.prototype.slice.call(arguments,0);c.unshift("Rollbar:"),o.ieVersion()<=8?console.log(s.formatArgsAsString(c)):console.log.apply(console,c)}}},function(r,i,a){r.exports={parse:function(o){var s,c,l={protocol:null,auth:null,host:null,path:null,hash:null,href:o,hostname:null,port:null,pathname:null,search:null,query:null};if((s=o.indexOf("//"))!==-1?(l.protocol=o.substring(0,s),c=s+2):c=0,(s=o.indexOf("@",c))!==-1&&(l.auth=o.substring(c,s),c=s+1),(s=o.indexOf("/",c))===-1){if((s=o.indexOf("?",c))===-1)return(s=o.indexOf("#",c))===-1?l.host=o.substring(c):(l.host=o.substring(c,s),l.hash=o.substring(s)),l.hostname=l.host.split(":")[0],l.port=l.host.split(":")[1],l.port&&(l.port=parseInt(l.port,10)),l;l.host=o.substring(c,s),l.hostname=l.host.split(":")[0],l.port=l.host.split(":")[1],l.port&&(l.port=parseInt(l.port,10)),c=s}else l.host=o.substring(c,s),l.hostname=l.host.split(":")[0],l.port=l.host.split(":")[1],l.port&&(l.port=parseInt(l.port,10)),c=s;if((s=o.indexOf("#",c))===-1?l.path=o.substring(c):(l.path=o.substring(c,s),l.hash=o.substring(s)),l.path){var u=l.path.split("?");l.pathname=u[0],l.query=u[1],l.search=l.query?"?"+l.query:null}return l}}},function(r,i,a){var o=a(24),s=new RegExp("^(([a-zA-Z0-9-_$ ]*): *)?(Uncaught )?([a-zA-Z0-9-_$ ]*): ");function c(){return null}function l(p){var f={};return f._stackFrame=p,f.url=p.fileName,f.line=p.lineNumber,f.func=p.functionName,f.column=p.columnNumber,f.args=p.args,f.context=null,f}function u(p,f){return{stack:function(){var h=[];f=f||0;try{h=o.parse(p)}catch{h=[]}for(var m=[],g=f;g<h.length;g++)m.push(new l(h[g]));return m}(),message:p.message,name:d(p),rawStack:p.stack,rawException:p}}function d(p){var f=p.name&&p.name.length&&p.name,h=p.constructor.name&&p.constructor.name.length&&p.constructor.name;return f&&h?f==="Error"?h:f:f||h}r.exports={guessFunctionName:function(){return"?"},guessErrorClass:function(p){if(!p||!p.match)return["Unknown error. There was no error message to display.",""];var f=p.match(s),h="(unknown)";return f&&(h=f[f.length-1],p=(p=p.replace((f[f.length-2]||"")+h+":","")).replace(/(^[\s]+|[\s]+$)/g,"")),[h,p]},gatherContext:c,parse:function(p,f){var h=p;if(h.nested||h.cause){for(var m=[];h;)m.push(new u(h,f)),h=h.nested||h.cause,f=0;return m[0].traceChain=m,m[0]}return new u(h,f)},Stack:u,Frame:l}},function(r,i,a){var o=a(0),s=a(5);function c(l,u){var d=u.split("."),p=d.length-1;try{for(var f=0;f<=p;++f)f<p?l=l[d[f]]:l[d[f]]=o.redact()}catch{}}r.exports=function(l,u,d){if(u=u||[],d)for(var p=0;p<d.length;++p)c(l,d[p]);var f=function(g){for(var y,b=[],w=0;w<g.length;++w)y="^\\[?(%5[bB])?"+g[w]+"\\[?(%5[bB])?\\]?(%5[dD])?$",b.push(new RegExp(y,"i"));return b}(u),h=function(g){for(var y,b=[],w=0;w<g.length;++w)y="\\[?(%5[bB])?"+g[w]+"\\[?(%5[bB])?\\]?(%5[dD])?",b.push(new RegExp("("+y+"=)([^&\\n]+)","igm"));return b}(u);function m(g,y){return y+o.redact()}return s(l,function g(y,b,w){var S=function(k,$){var T;for(T=0;T<f.length;++T)if(f[T].test(k)){$=o.redact();break}return $}(y,b);return S===b?o.isType(b,"object")||o.isType(b,"array")?s(b,g,w):function(k){var $;if(o.isType(k,"string"))for($=0;$<h.length;++$)k=k.replace(h[$],m);return k}(S):S})}},function(r,i,a){var o=a(0);r.exports=function(s,c,l){var u,d,p,f,h=o.isType(s,"object"),m=o.isType(s,"array"),g=[];if(l=l||{obj:[],mapped:[]},h){if(f=l.obj.indexOf(s),h&&f!==-1)return l.mapped[f]||l.obj[f];l.obj.push(s),f=l.obj.length-1}if(h)for(u in s)Object.prototype.hasOwnProperty.call(s,u)&&g.push(u);else if(m)for(p=0;p<s.length;++p)g.push(p);var y=h?{}:[],b=!0;for(p=0;p<g.length;++p)d=s[u=g[p]],y[u]=c(u,d,l),b=b&&y[u]===s[u];return h&&!b&&(l.mapped[f]=y),b?s:y}},function(r,i,a){r.exports=a(7)},function(r,i,a){var o=a(8),s=typeof window<"u"&&window._rollbarConfig,c=s&&s.globalAlias||"Rollbar",l=typeof window<"u"&&window[c]&&typeof window[c].shimId=="function"&&window[c].shimId()!==void 0;if(typeof window>"u"||window._rollbarStartTime||(window._rollbarStartTime=new Date().getTime()),!l&&s){var u=new o(s);window[c]=u}else typeof window<"u"?(window.rollbar=o,window._rollbarDidLoad=!0):typeof self<"u"&&(self.rollbar=o,self._rollbarDidLoad=!0);r.exports=o},function(r,i,a){var o=a(9),s=a(31),c=a(32),l=a(35),u=a(37),d=a(4),p=a(38);o.setComponents({telemeter:s,instrumenter:c,polyfillJSON:l,wrapGlobals:u,scrub:d,truncation:p}),r.exports=o},function(r,i,a){var o=a(10),s=a(0),c=a(15),l=a(1),u=a(19),d=a(20),p=a(2),f=a(23),h=a(26),m=a(27),g=a(28),y=a(3);function b(I,R){this.options=s.handleOptions(E,I,null,l),this.options._configuredOptions=I;var Y=this.components.telemeter,L=this.components.instrumenter,D=this.components.polyfillJSON;this.wrapGlobals=this.components.wrapGlobals,this.scrub=this.components.scrub;var B=this.components.truncation,z=new d(B),K=new c(this.options,z,p,B);Y&&(this.telemeter=new Y(this.options)),this.client=R||new o(this.options,K,l,this.telemeter,"browser");var te=$(),j=typeof document<"u"&&document;this.isChrome=te.chrome&&te.chrome.runtime,this.anonymousErrorsPending=0,function(M,q,G){M.addTransform(f.handleDomException).addTransform(f.handleItemWithError).addTransform(f.ensureItemHasSomethingToSay).addTransform(f.addBaseInfo).addTransform(f.addRequestInfo(G)).addTransform(f.addClientInfo(G)).addTransform(f.addPluginInfo(G)).addTransform(f.addBody).addTransform(h.addMessageWithError).addTransform(h.addTelemetryData).addTransform(h.addConfigToPayload).addTransform(f.addScrubber(q.scrub)).addTransform(h.addPayloadOptions).addTransform(h.userTransform(l)).addTransform(h.addConfiguredOptions).addTransform(h.addDiagnosticKeys).addTransform(h.itemToPayload)}(this.client.notifier,this,te),this.client.queue.addPredicate(g.checkLevel).addPredicate(m.checkIgnore).addPredicate(g.userCheckIgnore(l)).addPredicate(g.urlIsNotBlockListed(l)).addPredicate(g.urlIsSafeListed(l)).addPredicate(g.messageIsIgnored(l)),this.setupUnhandledCapture(),L&&(this.instrumenter=new L(this.options,this.client.telemeter,this,te,j),this.instrumenter.instrument()),s.setupJSON(D),this.rollbar=this}var w=null;function S(I){var R="Rollbar is not initialized";l.error(R),I&&I(new Error(R))}function k(I){for(var R=0,Y=I.length;R<Y;++R)if(s.isFunction(I[R]))return I[R]}function $(){return typeof window<"u"&&window||typeof self<"u"&&self}b.init=function(I,R){return w?w.global(I).configure(I):w=new b(I,R)},b.prototype.components={},b.setComponents=function(I){b.prototype.components=I},b.prototype.global=function(I){return this.client.global(I),this},b.global=function(I){if(w)return w.global(I);S()},b.prototype.configure=function(I,R){var Y=this.options,L={};return R&&(L={payload:R}),this.options=s.handleOptions(Y,I,L,l),this.options._configuredOptions=s.handleOptions(Y._configuredOptions,I,L),this.client.configure(this.options,R),this.instrumenter&&this.instrumenter.configure(this.options),this.setupUnhandledCapture(),this},b.configure=function(I,R){if(w)return w.configure(I,R);S()},b.prototype.lastError=function(){return this.client.lastError},b.lastError=function(){if(w)return w.lastError();S()},b.prototype.log=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.log(I),{uuid:R}},b.log=function(){if(w)return w.log.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.debug=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.debug(I),{uuid:R}},b.debug=function(){if(w)return w.debug.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.info=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.info(I),{uuid:R}},b.info=function(){if(w)return w.info.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.warn=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.warn(I),{uuid:R}},b.warn=function(){if(w)return w.warn.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.warning=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.warning(I),{uuid:R}},b.warning=function(){if(w)return w.warning.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.error=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.error(I),{uuid:R}},b.error=function(){if(w)return w.error.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.critical=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.critical(I),{uuid:R}},b.critical=function(){if(w)return w.critical.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.buildJsonPayload=function(I){return this.client.buildJsonPayload(I)},b.buildJsonPayload=function(){if(w)return w.buildJsonPayload.apply(w,arguments);S()},b.prototype.sendJsonPayload=function(I){return this.client.sendJsonPayload(I)},b.sendJsonPayload=function(){if(w)return w.sendJsonPayload.apply(w,arguments);S()},b.prototype.setupUnhandledCapture=function(){var I=$();this.unhandledExceptionsInitialized||(this.options.captureUncaught||this.options.handleUncaughtExceptions)&&(u.captureUncaughtExceptions(I,this),this.wrapGlobals&&this.options.wrapGlobalEventHandlers&&this.wrapGlobals(I,this),this.unhandledExceptionsInitialized=!0),this.unhandledRejectionsInitialized||(this.options.captureUnhandledRejections||this.options.handleUnhandledRejections)&&(u.captureUnhandledRejections(I,this),this.unhandledRejectionsInitialized=!0)},b.prototype.handleUncaughtException=function(I,R,Y,L,D,B){if(this.options.captureUncaught||this.options.handleUncaughtExceptions){if(this.options.inspectAnonymousErrors&&this.isChrome&&D===null&&R==="")return"anonymous";var z,K=s.makeUnhandledStackInfo(I,R,Y,L,D,"onerror","uncaught exception",y);s.isError(D)?(z=this._createItem([I,D,B]))._unhandledStackInfo=K:s.isError(R)?(z=this._createItem([I,R,B]))._unhandledStackInfo=K:(z=this._createItem([I,B])).stackInfo=K,z.level=this.options.uncaughtErrorLevel,z._isUncaught=!0,this.client.log(z)}},b.prototype.handleAnonymousErrors=function(){if(this.options.inspectAnonymousErrors&&this.isChrome){var I=this;try{Error.prepareStackTrace=function(R,Y){if(I.options.inspectAnonymousErrors&&I.anonymousErrorsPending){if(I.anonymousErrorsPending-=1,!R)return;R._isAnonymous=!0,I.handleUncaughtException(R.message,null,null,null,R)}return R.stack}}catch(R){this.options.inspectAnonymousErrors=!1,this.error("anonymous error handler failed",R)}}},b.prototype.handleUnhandledRejection=function(I,R){if(this.options.captureUnhandledRejections||this.options.handleUnhandledRejections){var Y="unhandled rejection was null or undefined!";if(I)if(I.message)Y=I.message;else{var L=s.stringify(I);L.value&&(Y=L.value)}var D,B=I&&I._rollbarContext||R&&R._rollbarContext;s.isError(I)?D=this._createItem([Y,I,B]):(D=this._createItem([Y,I,B])).stackInfo=s.makeUnhandledStackInfo(Y,"",0,0,null,"unhandledrejection","",y),D.level=this.options.uncaughtErrorLevel,D._isUncaught=!0,D._originalArgs=D._originalArgs||[],D._originalArgs.push(R),this.client.log(D)}},b.prototype.wrap=function(I,R,Y){try{var L;if(L=s.isFunction(R)?R:function(){return R||{}},!s.isFunction(I)||I._isWrap)return I;if(!I._rollbar_wrapped&&(I._rollbar_wrapped=function(){Y&&s.isFunction(Y)&&Y.apply(this,arguments);try{return I.apply(this,arguments)}catch(z){var B=z;throw B&&window._rollbarWrappedError!==B&&(s.isType(B,"string")&&(B=new String(B)),B._rollbarContext=L()||{},B._rollbarContext._wrappedSource=I.toString(),window._rollbarWrappedError=B),B}},I._rollbar_wrapped._isWrap=!0,I.hasOwnProperty))for(var D in I)I.hasOwnProperty(D)&&D!=="_rollbar_wrapped"&&(I._rollbar_wrapped[D]=I[D]);return I._rollbar_wrapped}catch{return I}},b.wrap=function(I,R){if(w)return w.wrap(I,R);S()},b.prototype.captureEvent=function(){var I=s.createTelemetryEvent(arguments);return this.client.captureEvent(I.type,I.metadata,I.level)},b.captureEvent=function(){if(w)return w.captureEvent.apply(w,arguments);S()},b.prototype.captureDomContentLoaded=function(I,R){return R||(R=new Date),this.client.captureDomContentLoaded(R)},b.prototype.captureLoad=function(I,R){return R||(R=new Date),this.client.captureLoad(R)},b.prototype.loadFull=function(){l.info("Unexpected Rollbar.loadFull() called on a Notifier instance. This can happen when Rollbar is loaded multiple times.")},b.prototype._createItem=function(I){return s.createItem(I,l,this)};var T=a(29),A=a(30),E={version:T.version,scrubFields:A.scrubFields,logLevel:T.logLevel,reportLevel:T.reportLevel,uncaughtErrorLevel:T.uncaughtErrorLevel,endpoint:T.endpoint,verbose:!1,enabled:!0,transmit:!0,sendConfig:!1,includeItemsInTelemetry:!0,captureIp:!0,inspectAnonymousErrors:!0,ignoreDuplicateErrors:!0,wrapGlobalEventHandlers:!1};r.exports=b},function(r,i,a){var o=a(11),s=a(13),c=a(14),l=a(0);function u(f,h,m,g,y){this.options=l.merge(f),this.logger=m,u.rateLimiter.configureGlobal(this.options),u.rateLimiter.setPlatformOptions(y,this.options),this.api=h,this.queue=new s(u.rateLimiter,h,m,this.options);var b=this.options.tracer||null;p(b)?(this.tracer=b,this.options.tracer="opentracing-tracer-enabled",this.options._configuredOptions.tracer="opentracing-tracer-enabled"):this.tracer=null,this.notifier=new c(this.queue,this.options),this.telemeter=g,d(f),this.lastError=null,this.lastErrorHash="none"}function d(f){f.stackTraceLimit&&(Error.stackTraceLimit=f.stackTraceLimit)}function p(f){if(!f||!f.scope||typeof f.scope!="function")return!1;var h=f.scope();return!(!h||!h.active||typeof h.active!="function")}u.rateLimiter=new o({maxItems:0,itemsPerMinute:60}),u.prototype.global=function(f){return u.rateLimiter.configureGlobal(f),this},u.prototype.configure=function(f,h){var m=this.options,g={};h&&(g={payload:h}),this.options=l.merge(m,f,g);var y=this.options.tracer||null;return p(y)?(this.tracer=y,this.options.tracer="opentracing-tracer-enabled",this.options._configuredOptions.tracer="opentracing-tracer-enabled"):this.tracer=null,this.notifier&&this.notifier.configure(this.options),this.telemeter&&this.telemeter.configure(this.options),d(f),this.global(this.options),p(f.tracer)&&(this.tracer=f.tracer),this},u.prototype.log=function(f){var h=this._defaultLogLevel();return this._log(h,f)},u.prototype.debug=function(f){this._log("debug",f)},u.prototype.info=function(f){this._log("info",f)},u.prototype.warn=function(f){this._log("warning",f)},u.prototype.warning=function(f){this._log("warning",f)},u.prototype.error=function(f){this._log("error",f)},u.prototype.critical=function(f){this._log("critical",f)},u.prototype.wait=function(f){this.queue.wait(f)},u.prototype.captureEvent=function(f,h,m){return this.telemeter&&this.telemeter.captureEvent(f,h,m)},u.prototype.captureDomContentLoaded=function(f){return this.telemeter&&this.telemeter.captureDomContentLoaded(f)},u.prototype.captureLoad=function(f){return this.telemeter&&this.telemeter.captureLoad(f)},u.prototype.buildJsonPayload=function(f){return this.api.buildJsonPayload(f)},u.prototype.sendJsonPayload=function(f){this.api.postJsonPayload(f)},u.prototype._log=function(f,h){var m;if(h.callback&&(m=h.callback,delete h.callback),this.options.ignoreDuplicateErrors&&this._sameAsLastError(h)){if(m){var g=new Error("ignored identical item");g.item=h,m(g)}}else try{this._addTracingInfo(h),h.level=h.level||f,this.telemeter&&this.telemeter._captureRollbarItem(h),h.telemetryEvents=this.telemeter&&this.telemeter.copyEvents()||[],this.notifier.log(h,m)}catch(y){m&&m(y),this.logger.error(y)}},u.prototype._defaultLogLevel=function(){return this.options.logLevel||"debug"},u.prototype._sameAsLastError=function(f){if(!f._isUncaught)return!1;var h=function(m){var g=m.message||"",y=(m.err||{}).stack||String(m.err);return g+"::"+y}(f);return this.lastErrorHash===h||(this.lastError=f.err,this.lastErrorHash=h,!1)},u.prototype._addTracingInfo=function(f){if(this.tracer){var h=this.tracer.scope().active();if(function(y){if(!y||!y.context||typeof y.context!="function")return!1;var b=y.context();return!(!b||!b.toSpanId||!b.toTraceId||typeof b.toSpanId!="function"||typeof b.toTraceId!="function")}(h)){h.setTag("rollbar.error_uuid",f.uuid),h.setTag("rollbar.has_error",!0),h.setTag("error",!0),h.setTag("rollbar.item_url","https://rollbar.com/item/uuid/?uuid="+f.uuid),h.setTag("rollbar.occurrence_url","https://rollbar.com/occurrence/uuid/?uuid="+f.uuid);var m=h.context().toSpanId(),g=h.context().toTraceId();f.custom?(f.custom.opentracing_span_id=m,f.custom.opentracing_trace_id=g):f.custom={opentracing_span_id:m,opentracing_trace_id:g}}}},r.exports=u},function(r,i,a){var o=a(0);function s(u){this.startTime=o.now(),this.counter=0,this.perMinCounter=0,this.platform=null,this.platformOptions={},this.configureGlobal(u)}function c(u,d,p){return!u.ignoreRateLimit&&d>=1&&p>d}function l(u,d,p,f,h,m,g){var y=null;return p&&(p=new Error(p)),p||f||(y=function(b,w,S,k,$){var T,A=w.environment||w.payload&&w.payload.environment;T=$?"item per minute limit reached, ignoring errors until timeout":"maxItems has been hit, ignoring errors until reset.";var E={body:{message:{body:T,extra:{maxItems:S,itemsPerMinute:k}}},language:"javascript",environment:A,notifier:{version:w.notifier&&w.notifier.version||w.version}};return b==="browser"?(E.platform="browser",E.framework="browser-js",E.notifier.name="rollbar-browser-js"):b==="server"?(E.framework=w.framework||"node-js",E.notifier.name=w.notifier.name):b==="react-native"&&(E.framework=w.framework||"react-native",E.notifier.name=w.notifier.name),E}(u,d,h,m,g)),{error:p,shouldSend:f,payload:y}}s.globalSettings={startTime:o.now(),maxItems:void 0,itemsPerMinute:void 0},s.prototype.configureGlobal=function(u){u.startTime!==void 0&&(s.globalSettings.startTime=u.startTime),u.maxItems!==void 0&&(s.globalSettings.maxItems=u.maxItems),u.itemsPerMinute!==void 0&&(s.globalSettings.itemsPerMinute=u.itemsPerMinute)},s.prototype.shouldSend=function(u,d){var p=(d=d||o.now())-this.startTime;(p<0||p>=6e4)&&(this.startTime=d,this.perMinCounter=0);var f=s.globalSettings.maxItems,h=s.globalSettings.itemsPerMinute;if(c(u,f,this.counter))return l(this.platform,this.platformOptions,f+" max items reached",!1);if(c(u,h,this.perMinCounter))return l(this.platform,this.platformOptions,h+" items per minute reached",!1);this.counter++,this.perMinCounter++;var m=!c(u,f,this.counter),g=m;return m=m&&!c(u,h,this.perMinCounter),l(this.platform,this.platformOptions,null,m,f,h,g)},s.prototype.setPlatformOptions=function(u,d){this.platform=u,this.platformOptions=d},r.exports=s},function(r,i,a){var o=Object.prototype.hasOwnProperty,s=Object.prototype.toString,c=function(l){if(!l||s.call(l)!=="[object Object]")return!1;var u,d=o.call(l,"constructor"),p=l.constructor&&l.constructor.prototype&&o.call(l.constructor.prototype,"isPrototypeOf");if(l.constructor&&!d&&!p)return!1;for(u in l);return u===void 0||o.call(l,u)};r.exports=function l(){var u,d,p,f,h,m={},g=null,y=arguments.length;for(u=0;u<y;u++)if((g=arguments[u])!=null)for(h in g)d=m[h],m!==(p=g[h])&&(p&&c(p)?(f=d&&c(d)?d:{},m[h]=l(f,p)):p!==void 0&&(m[h]=p));return m}},function(r,i,a){var o=a(0);function s(l,u,d,p){this.rateLimiter=l,this.api=u,this.logger=d,this.options=p,this.predicates=[],this.pendingItems=[],this.pendingRequests=[],this.retryQueue=[],this.retryHandle=null,this.waitCallback=null,this.waitIntervalID=null}s.prototype.configure=function(l){this.api&&this.api.configure(l);var u=this.options;return this.options=o.merge(u,l),this},s.prototype.addPredicate=function(l){return o.isFunction(l)&&this.predicates.push(l),this},s.prototype.addPendingItem=function(l){this.pendingItems.push(l)},s.prototype.removePendingItem=function(l){var u=this.pendingItems.indexOf(l);u!==-1&&this.pendingItems.splice(u,1)},s.prototype.addItem=function(l,u,d,p){u&&o.isFunction(u)||(u=function(){});var f=this._applyPredicates(l);if(f.stop)return this.removePendingItem(p),void u(f.err);if(this._maybeLog(l,d),this.removePendingItem(p),this.options.transmit){this.pendingRequests.push(l);try{this._makeApiRequest(l,function(h,m){this._dequeuePendingRequest(l),u(h,m)}.bind(this))}catch(h){this._dequeuePendingRequest(l),u(h)}}else u(new Error("Transmit disabled"))},s.prototype.wait=function(l){o.isFunction(l)&&(this.waitCallback=l,this._maybeCallWait()||(this.waitIntervalID&&(this.waitIntervalID=clearInterval(this.waitIntervalID)),this.waitIntervalID=setInterval(function(){this._maybeCallWait()}.bind(this),500)))},s.prototype._applyPredicates=function(l){for(var u=null,d=0,p=this.predicates.length;d<p;d++)if(!(u=this.predicates[d](l,this.options))||u.err!==void 0)return{stop:!0,err:u.err};return{stop:!1,err:null}},s.prototype._makeApiRequest=function(l,u){var d=this.rateLimiter.shouldSend(l);d.shouldSend?this.api.postItem(l,function(p,f){p?this._maybeRetry(p,l,u):u(p,f)}.bind(this)):d.error?u(d.error):this.api.postItem(d.payload,u)};var c=["ECONNRESET","ENOTFOUND","ESOCKETTIMEDOUT","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH","EPIPE","EAI_AGAIN"];s.prototype._maybeRetry=function(l,u,d){var p=!1;if(this.options.retryInterval){for(var f=0,h=c.length;f<h;f++)if(l.code===c[f]){p=!0;break}p&&o.isFiniteNumber(this.options.maxRetries)&&(u.retries=u.retries?u.retries+1:1,u.retries>this.options.maxRetries&&(p=!1))}p?this._retryApiRequest(u,d):d(l)},s.prototype._retryApiRequest=function(l,u){this.retryQueue.push({item:l,callback:u}),this.retryHandle||(this.retryHandle=setInterval(function(){for(;this.retryQueue.length;){var d=this.retryQueue.shift();this._makeApiRequest(d.item,d.callback)}}.bind(this),this.options.retryInterval))},s.prototype._dequeuePendingRequest=function(l){var u=this.pendingRequests.indexOf(l);u!==-1&&(this.pendingRequests.splice(u,1),this._maybeCallWait())},s.prototype._maybeLog=function(l,u){if(this.logger&&this.options.verbose){var d=u;if(d=(d=d||o.get(l,"body.trace.exception.message"))||o.get(l,"body.trace_chain.0.exception.message"))return void this.logger.error(d);(d=o.get(l,"body.message.body"))&&this.logger.log(d)}},s.prototype._maybeCallWait=function(){return!(!o.isFunction(this.waitCallback)||this.pendingItems.length!==0||this.pendingRequests.length!==0)&&(this.waitIntervalID&&(this.waitIntervalID=clearInterval(this.waitIntervalID)),this.waitCallback(),!0)},r.exports=s},function(r,i,a){var o=a(0);function s(c,l){this.queue=c,this.options=l,this.transforms=[],this.diagnostic={}}s.prototype.configure=function(c){this.queue&&this.queue.configure(c);var l=this.options;return this.options=o.merge(l,c),this},s.prototype.addTransform=function(c){return o.isFunction(c)&&this.transforms.push(c),this},s.prototype.log=function(c,l){if(l&&o.isFunction(l)||(l=function(){}),!this.options.enabled)return l(new Error("Rollbar is not enabled"));this.queue.addPendingItem(c);var u=c.err;this._applyTransforms(c,function(d,p){if(d)return this.queue.removePendingItem(c),l(d,null);this.queue.addItem(p,l,u,c)}.bind(this))},s.prototype._applyTransforms=function(c,l){var u=-1,d=this.transforms.length,p=this.transforms,f=this.options,h=function(m,g){m?l(m,null):++u!==d?p[u](g,f,h):l(null,g)};h(null,c)},r.exports=s},function(r,i,a){var o=a(0),s=a(16),c={hostname:"api.rollbar.com",path:"/api/1/item/",search:null,version:"1",protocol:"https:",port:443};function l(d,p,f,h,m){this.options=d,this.transport=p,this.url=f,this.truncation=h,this.jsonBackup=m,this.accessToken=d.accessToken,this.transportOptions=u(d,f)}function u(d,p){return s.getTransportFromOptions(d,c,p)}l.prototype.postItem=function(d,p){var f=s.transportOptions(this.transportOptions,"POST"),h=s.buildPayload(this.accessToken,d,this.jsonBackup),m=this;setTimeout(function(){m.transport.post(m.accessToken,f,h,p)},0)},l.prototype.buildJsonPayload=function(d,p){var f,h=s.buildPayload(this.accessToken,d,this.jsonBackup);return(f=this.truncation?this.truncation.truncate(h):o.stringify(h)).error?(p&&p(f.error),null):f.value},l.prototype.postJsonPayload=function(d,p){var f=s.transportOptions(this.transportOptions,"POST");this.transport.postJsonPayload(this.accessToken,f,d,p)},l.prototype.configure=function(d){var p=this.oldOptions;return this.options=o.merge(p,d),this.transportOptions=u(this.options,this.url),this.options.accessToken!==void 0&&(this.accessToken=this.options.accessToken),this},r.exports=l},function(r,i,a){var o=a(0);r.exports={buildPayload:function(s,c,l){if(!o.isType(c.context,"string")){var u=o.stringify(c.context,l);u.error?c.context="Error: could not serialize 'context'":c.context=u.value||"",c.context.length>255&&(c.context=c.context.substr(0,255))}return{access_token:s,data:c}},getTransportFromOptions:function(s,c,l){var u=c.hostname,d=c.protocol,p=c.port,f=c.path,h=c.search,m=s.timeout,g=function(w){var S=typeof window<"u"&&window||typeof self<"u"&&self,k=w.defaultTransport||"xhr";return S.fetch===void 0&&(k="xhr"),S.XMLHttpRequest===void 0&&(k="fetch"),k}(s),y=s.proxy;if(s.endpoint){var b=l.parse(s.endpoint);u=b.hostname,d=b.protocol,p=b.port,f=b.pathname,h=b.search}return{timeout:m,hostname:u,protocol:d,port:p,path:f,search:h,proxy:y,transport:g}},transportOptions:function(s,c){var l=s.protocol||"https:",u=s.port||(l==="http:"?80:l==="https:"?443:void 0),d=s.hostname,p=s.path,f=s.timeout,h=s.transport;return s.search&&(p+=s.search),s.proxy&&(p=l+"//"+d+p,d=s.proxy.host||s.proxy.hostname,u=s.proxy.port,l=s.proxy.protocol||l),{timeout:f,protocol:l,hostname:d,path:p,port:u,method:c,transport:h}},appendPathToPath:function(s,c){var l=/\/$/.test(s),u=/^\//.test(c);return l&&u?c=c.substring(1):l||u||(c="/"+c),s+c}}},function(r,i){(function(a){a.console||(a.console={});for(var o,s,c=a.console,l=function(){},u=["memory"],d="assert,clear,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,markTimeline,profile,profiles,profileEnd,show,table,time,timeEnd,timeline,timelineEnd,timeStamp,trace,warn".split(",");o=u.pop();)c[o]||(c[o]={});for(;s=d.pop();)c[s]||(c[s]=l)})(typeof window>"u"?this:window)},function(r,i,a){var o={ieVersion:function(){if(typeof document<"u"){for(var s=3,c=document.createElement("div"),l=c.getElementsByTagName("i");c.innerHTML="<!--[if gt IE "+ ++s+"]><i></i><![endif]-->",l[0];);return s>4?s:void 0}}};r.exports=o},function(r,i,a){function o(s,c,l,u){s._rollbarWrappedError&&(u[4]||(u[4]=s._rollbarWrappedError),u[5]||(u[5]=s._rollbarWrappedError._rollbarContext),s._rollbarWrappedError=null);var d=c.handleUncaughtException.apply(c,u);l&&l.apply(s,u),d==="anonymous"&&(c.anonymousErrorsPending+=1)}r.exports={captureUncaughtExceptions:function(s,c,l){if(s){var u;if(typeof c._rollbarOldOnError=="function")u=c._rollbarOldOnError;else if(s.onerror){for(u=s.onerror;u._rollbarOldOnError;)u=u._rollbarOldOnError;c._rollbarOldOnError=u}c.handleAnonymousErrors();var d=function(){var p=Array.prototype.slice.call(arguments,0);o(s,c,u,p)};l&&(d._rollbarOldOnError=u),s.onerror=d}},captureUnhandledRejections:function(s,c,l){if(s){typeof s._rollbarURH=="function"&&s._rollbarURH.belongsToShim&&s.removeEventListener("unhandledrejection",s._rollbarURH);var u=function(d){var p,f,h;try{p=d.reason}catch{p=void 0}try{f=d.promise}catch{f="[unhandledrejection] error getting `promise` from event"}try{h=d.detail,!p&&h&&(p=h.reason,f=h.promise)}catch{}p||(p="[unhandledrejection] error getting `reason` from event"),c&&c.handleUnhandledRejection&&c.handleUnhandledRejection(p,f)};u.belongsToShim=l,s._rollbarURH=u,s.addEventListener("unhandledrejection",u)}}}},function(r,i,a){var o=a(0),s=a(21),c=a(22);function l(u){this.truncation=u}l.prototype.get=function(u,d,p,f,h){f&&o.isFunction(f)||(f=function(){}),o.addParamsAndAccessTokenToPath(u,d,p);var m=o.formatUrl(d);this._makeZoneRequest(u,m,"GET",null,f,h,d.timeout,d.transport)},l.prototype.post=function(u,d,p,f,h){if(f&&o.isFunction(f)||(f=function(){}),!p)return f(new Error("Cannot send empty request"));var m;if((m=this.truncation?this.truncation.truncate(p):o.stringify(p)).error)return f(m.error);var g=m.value,y=o.formatUrl(d);this._makeZoneRequest(u,y,"POST",g,f,h,d.timeout,d.transport)},l.prototype.postJsonPayload=function(u,d,p,f,h){f&&o.isFunction(f)||(f=function(){});var m=o.formatUrl(d);this._makeZoneRequest(u,m,"POST",p,f,h,d.timeout,d.transport)},l.prototype._makeZoneRequest=function(){var u=typeof window<"u"&&window||h!==void 0&&h,d=u&&u.Zone&&u.Zone.current,p=Array.prototype.slice.call(arguments);if(d&&d._name==="angular"){var f=d._parent,h=this;f.run(function(){h._makeRequest.apply(void 0,p)})}else this._makeRequest.apply(void 0,p)},l.prototype._makeRequest=function(u,d,p,f,h,m,g,y){if(typeof RollbarProxy<"u")return function(b,w){new RollbarProxy().sendJsonPayload(b,function(S){},function(S){w(new Error(S))})}(f,h);y==="fetch"?s(u,d,p,f,h,g):c(u,d,p,f,h,m,g)},r.exports=l},function(r,i,a){var o=a(1),s=a(0);r.exports=function(c,l,u,d,p,f){var h,m;s.isFiniteNumber(f)&&(h=new AbortController,m=setTimeout(function(){h.abort()},f)),fetch(l,{method:u,headers:{"Content-Type":"application/json","X-Rollbar-Access-Token":c,signal:h&&h.signal},body:d}).then(function(g){return m&&clearTimeout(m),g.json()}).then(function(g){p(null,g)}).catch(function(g){o.error(g.message),p(g)})}},function(r,i,a){var o=a(0),s=a(1);function c(l,u){var d=new Error(l);return d.code=u||"ENOTFOUND",d}r.exports=function(l,u,d,p,f,h,m){var g;if(!(g=h?h():function(){var w,S,k=[function(){return new XMLHttpRequest},function(){return new ActiveXObject("Msxml2.XMLHTTP")},function(){return new ActiveXObject("Msxml3.XMLHTTP")},function(){return new ActiveXObject("Microsoft.XMLHTTP")}],$=k.length;for(S=0;S<$;S++)try{w=k[S]();break}catch{}return w}()))return f(new Error("No way to send a request"));try{try{var y=function(){try{if(y&&g.readyState===4){y=void 0;var w=o.jsonParse(g.responseText);if(($=g)&&$.status&&$.status===200)return void f(w.error,w.value);if(function(T){return T&&o.isType(T.status,"number")&&T.status>=400&&T.status<600}(g)){if(g.status===403){var S=w.value&&w.value.message;s.error(S)}f(new Error(String(g.status)))}else f(c("XHR response had no status code (likely connection failure)"))}}catch(T){var k;k=T&&T.stack?T:new Error(T),f(k)}var $};g.open(d,u,!0),g.setRequestHeader&&(g.setRequestHeader("Content-Type","application/json"),g.setRequestHeader("X-Rollbar-Access-Token",l)),o.isFiniteNumber(m)&&(g.timeout=m),g.onreadystatechange=y,g.send(p)}catch{if(typeof XDomainRequest<"u"){if(!window||!window.location)return f(new Error("No window available during request, unknown environment"));window.location.href.substring(0,5)==="http:"&&u.substring(0,5)==="https"&&(u="http"+u.substring(5));var b=new XDomainRequest;b.onprogress=function(){},b.ontimeout=function(){f(c("Request timed out","ETIMEDOUT"))},b.onerror=function(){f(new Error("Error during request"))},b.onload=function(){var S=o.jsonParse(b.responseText);f(S.error,S.value)},b.open(d,u,!0),b.send(p)}else f(new Error("Cannot find a method to transport a request"))}}catch(w){f(w)}}},function(r,i,a){var o=a(0),s=a(3),c=a(1);function l(f,h,m){var g=f.message,y=f.custom;g||(g="Item sent with null or missing arguments.");var b={body:g};y&&(b.extra=o.merge(y)),o.set(f,"data.body",{message:b}),m(null,f)}function u(f){var h=f.stackInfo.stack;return h&&h.length===0&&f._unhandledStackInfo&&f._unhandledStackInfo.stack&&(h=f._unhandledStackInfo.stack),h}function d(f,h,m){var g=f&&f.data.description,y=f&&f.custom,b=u(f),w=s.guessErrorClass(h.message),S={exception:{class:p(h,w[0],m),message:w[1]}};if(g&&(S.exception.description=g),b){var k,$,T,A,E,I,R,Y;for(b.length===0&&(S.exception.stack=h.rawStack,S.exception.raw=String(h.rawException)),S.frames=[],R=0;R<b.length;++R)$={filename:(k=b[R]).url?o.sanitizeUrl(k.url):"(unknown)",lineno:k.line||null,method:k.func&&k.func!=="?"?k.func:"[anonymous]",colno:k.column},m.sendFrameUrl&&($.url=k.url),$.method&&$.method.endsWith&&$.method.endsWith("_rollbar_wrapped")||(T=A=E=null,(I=k.context?k.context.length:0)&&(Y=Math.floor(I/2),A=k.context.slice(0,Y),T=k.context[Y],E=k.context.slice(Y)),T&&($.code=T),(A||E)&&($.context={},A&&A.length&&($.context.pre=A),E&&E.length&&($.context.post=E)),k.args&&($.args=k.args),S.frames.push($));S.frames.reverse(),y&&(S.extra=o.merge(y))}return S}function p(f,h,m){return f.name?f.name:m.guessErrorClass?h:"(unknown)"}r.exports={handleDomException:function(f,h,m){if(f.err&&s.Stack(f.err).name==="DOMException"){var g=new Error;g.name=f.err.name,g.message=f.err.message,g.stack=f.err.stack,g.nested=f.err,f.err=g}m(null,f)},handleItemWithError:function(f,h,m){if(f.data=f.data||{},f.err)try{f.stackInfo=f.err._savedStackTrace||s.parse(f.err,f.skipFrames),h.addErrorContext&&function(g){var y=[],b=g.err;for(y.push(b);b.nested||b.cause;)b=b.nested||b.cause,y.push(b);o.addErrorContext(g,y)}(f)}catch(g){c.error("Error while parsing the error object.",g);try{f.message=f.err.message||f.err.description||f.message||String(f.err)}catch(y){f.message=String(f.err)||String(y)}delete f.err}m(null,f)},ensureItemHasSomethingToSay:function(f,h,m){f.message||f.stackInfo||f.custom||m(new Error("No message, stack info, or custom data"),null),m(null,f)},addBaseInfo:function(f,h,m){var g=h.payload&&h.payload.environment||h.environment;f.data=o.merge(f.data,{environment:g,level:f.level,endpoint:h.endpoint,platform:"browser",framework:"browser-js",language:"javascript",server:{},uuid:f.uuid,notifier:{name:"rollbar-browser-js",version:h.version},custom:f.custom}),m(null,f)},addRequestInfo:function(f){return function(h,m,g){var y={};f&&f.location&&(y.url=f.location.href,y.query_string=f.location.search);var b="$remote_ip";m.captureIp?m.captureIp!==!0&&(b+="_anonymize"):b=null,b&&(y.user_ip=b),Object.keys(y).length>0&&o.set(h,"data.request",y),g(null,h)}},addClientInfo:function(f){return function(h,m,g){if(!f)return g(null,h);var y=f.navigator||{},b=f.screen||{};o.set(h,"data.client",{runtime_ms:h.timestamp-f._rollbarStartTime,timestamp:Math.round(h.timestamp/1e3),javascript:{browser:y.userAgent,language:y.language,cookie_enabled:y.cookieEnabled,screen:{width:b.width,height:b.height}}}),g(null,h)}},addPluginInfo:function(f){return function(h,m,g){if(!f||!f.navigator)return g(null,h);for(var y,b=[],w=f.navigator.plugins||[],S=0,k=w.length;S<k;++S)y=w[S],b.push({name:y.name,description:y.description});o.set(h,"data.client.javascript.plugins",b),g(null,h)}},addBody:function(f,h,m){f.stackInfo?f.stackInfo.traceChain?function(g,y,b){for(var w=g.stackInfo.traceChain,S=[],k=w.length,$=0;$<k;$++){var T=d(g,w[$],y);S.push(T)}o.set(g,"data.body",{trace_chain:S}),b(null,g)}(f,h,m):function(g,y,b){if(u(g)){var w=d(g,g.stackInfo,y);o.set(g,"data.body",{trace:w}),b(null,g)}else{var S=g.stackInfo,k=s.guessErrorClass(S.message),$=p(S,k[0],y),T=k[1];g.message=$+": "+T,l(g,y,b)}}(f,h,m):l(f,h,m)},addScrubber:function(f){return function(h,m,g){if(f){var y=m.scrubFields||[],b=m.scrubPaths||[];h.data=f(h.data,y,b)}g(null,h)}}}},function(r,i,a){var o,s,c;(function(l,u){s=[a(25)],(c=typeof(o=function(d){var p=/(^|@)\S+:\d+/,f=/^\s*at .*(\S+:\d+|\(native\))/m,h=/^(eval@)?(\[native code])?$/;return{parse:function(m){if(m.stacktrace!==void 0||m["opera#sourceloc"]!==void 0)return this.parseOpera(m);if(m.stack&&m.stack.match(f))return this.parseV8OrIE(m);if(m.stack)return this.parseFFOrSafari(m);throw new Error("Cannot parse given Error object")},extractLocation:function(m){if(m.indexOf(":")===-1)return[m];var g=/(.+?)(?::(\d+))?(?::(\d+))?$/.exec(m.replace(/[()]/g,""));return[g[1],g[2]||void 0,g[3]||void 0]},parseV8OrIE:function(m){return m.stack.split(`
|
|
437
|
+
`))}add(r){return this.payload={...this.payload,...r},this}getPayload(){return this.payload}setErrorCodeFromResponse(){const{data:r,status:i}=this.getPayload().axios||{};if(!r&&!i)return;const{errorCode:a}=r||{};a&&this.add({code:a}),i&&(this.httpStatusCode=i)}setMessageFromResponse(){const{data:r}=this.getPayload().axios||{};if(!r)return!1;const{message:i}=r||{};return i?(this.message=i,!0):!1}}class KI extends qm{constructor(t){if(super(t),this.name="NotFoundError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse()}}class ZI extends qm{constructor(t){if(super(t),this.name="ForbiddenError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse(),this.setMessageFromResponse()}}class JI extends qm{constructor(t){if(super(t),this.name="ValidationError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse(),this.setMessageFromResponse()}}class XI extends qm{constructor(t){if(super(t),this.name="NetworkError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{config:r}=t;this.add({axios:r}),this.code="ECONNREFUSED"}}class B3 extends qm{constructor(t){if(super(t),this.name="GeneralError",this.message=typeof t=="string"||!t?t:t.message,typeof t=="string"||!t)return;const{response:r}=t;this.add({axios:r}),this.setErrorCodeFromResponse(),this.setMessageFromResponse()}}const QI=Object.freeze(Object.defineProperty({__proto__:null,ForbiddenError:ZI,GeneralError:B3,NetworkError:XI,NotFoundError:KI,ValidationError:JI},Symbol.toStringTag,{value:"Module"})),r3e=n=>{const t=Object.keys(n);let r="";return t.forEach(i=>{const a=typeof n[i]=="object",o=a&&n[i].length>=0;a||(r+=`${i}=${n[i]}&`),a&&o&&n[i].forEach(s=>{r+=`${i}=${s}&`})}),r&&r.slice(0,-1)},eR=n=>{j3.push(n)},i3e=n=>{j3.map(t=>t(n))};function tR(){console.error("User should be logged out!!"),wt.removeItem("token"),wt.removeItem("tokenExpires"),wt.removeItem("refreshToken"),Pr.trigger("user:unauthorized",{error})}let Ym=!1,j3=[];const a3e=(n,{renewToken:t})=>{n.interceptors.request.use(r=>{const i=r;if(i.url.includes("/auth")||i.url.startsWith("/public/"))return i;const a=i.headers["X-TOKEN"];if(!a)return i;const o=wt.getItem("tokenExpires");if(a&&o){const s=new Date;s.setSeconds(s.getSeconds()+30);const c=new Date(o);if(s>c)return t(),new Promise(u=>{eR(d=>{i.headers["X-TOKEN"]=d,u(i)})})}return i},r=>Promise.reject(r))},o3e=(n,{renewToken:t})=>{n.interceptors.response.use(r=>r,r=>{if(!r||!r.response)return Promise.reject(r);const{config:i,response:a}=r,{status:o,data:s}=a,{errorCode:c}=s,l=i;if(l.url.startsWith("/public/"))return Promise.reject(r);function u(){if(c===8001)return!0;const d=wt.getItem("tokenExpires");if(d){const p=new Date,f=new Date(d);return p>f}return!1}if(o===401&&l.headers["X-TOKEN"]&&u()&&!Ym)return t(),new Promise(p=>{eR(f=>{l.headers["X-TOKEN"]=f,p(gi(l))})});if(o===401&&typeof c>"u"){if(l.url.includes("auth/companyUser")&&!l.headers["X-TOKEN"])return Promise.reject(r);if(l.url.includes("auth/actionlink")&&!l.headers["X-TOKEN"])return Promise.reject(r);tR()}return Promise.reject(r)})},nR=n=>(v0(n.data),n),s3e=n=>{n.interceptors.response.use(nR,t=>{const{response:r,config:i}=t;if(!r)throw new XI(t);if(Object.prototype.hasOwnProperty.call(i,"errorHandle")&&i.errorHandle===!1)return Promise.reject(t);const{status:a}=r;switch(a){case 404:throw new KI(t);case 401:throw new ZI(t);case 412:throw new JI(t);default:throw new B3(t)}})},l3e=n=>{n.interceptors.response.use(t=>{var r,i;if((i=(r=t.config)==null?void 0:r.url)!=null&&i.includes("document")&&t.config.method==="post"){const a=JSON.parse(t.config.data);a.__tempId&&(t.data.__tempId=a.__tempId)}return t},t=>Promise.reject(t))},c3e=n=>{n.interceptors.request.use(t=>{if(["post","put"].includes(t.method)&&t.data&&!(t.data instanceof FormData)){const r=Hs(t.data);N4(r),t.data=r}return t},t=>Promise.reject(t))},u3e=({baseUrl:n,withCredentials:t,cache:r})=>{const i=gi.create({baseURL:n,timeout:2e4,adapter:r,withCredentials:t,paramsSerializer:p=>r3e(p)});i.defaults.headers["X-CLIENT"]="widget",i.defaults.headers["X-CLIENT-VERSION"]="0.10.4-beta.0";const a=async(p,f,h=null,m={})=>{const g=f.startsWith("/public/"),y=wt.getItem("token");switch(y&&!g&&(i.defaults.headers["X-TOKEN"]=y),p){case"get":return i.get(f,m);case"post":return i.post(f,h,m);case"put":return i.put(f,h,m);case"delete":return i.delete(f,m);case"patch":return i.patch(f,h,m);default:throw new Error(`SendRequest failed as method: '${p}' is not implemented`)}},o=(p,f={})=>a("get",p,null,f),s=(p,f={},h={})=>a("put",p,f,h),c=(p,f,h={})=>a("post",p,f,h),l=(p,f={})=>a("delete",p,null,f),u=(p,f={})=>a("patch",p,null,f),d=async()=>{if(!Ym)try{Ym=!0;const p=wt.getItem("refreshToken"),f=await c("/auth/companyUser",{refreshToken:p});if(!f.data||!f.data.token)throw new Error("No token was defined in result");const{token:h,tokenExpires:m,refreshToken:g}=f.data;wt.setItem("token",h),wt.setItem("tokenExpires",m),g&&wt.setItem("refreshToken",g),Ym=!1,i3e(h),j3=[]}catch(p){return console.error(p),tR()}finally{Ym=!1}};return a3e(i,{renewToken:d}),o3e(i,{renewToken:d}),nR(i),s3e(i),c3e(i),l3e(i),{instance:i,get:o,put:s,post:c,del:l,patch:u,renewToken:d}},z3=new Map;function d3e(n){if(typeof n>"u")throw new Error("Missing valid parameter url");if(typeof n!="string")throw new Error("Parameter url must be a string");const{data:t,cachedAt:r,expiresAt:i}=z3.get(n)||{};return Date.now()>r+6e4*30||i&&Date.now()>i?(z3.delete(n),null):t}const p3e=async n=>{const{url:t,params:r={}}=n,i=Object.keys(r).map(s=>`${s}=${r[s]}`).join("&"),a=`${t}${i?`?${i}`:""}`;return d3e(a),await gi({...n,adapter:gi.defaults.adapter})},Bp={withCredentials:!0,baseUrl:Xe.api.baseUrl},{get:xt,post:nn,put:Vr,patch:Xo,del:qi,instance:U9t,renewToken:f3e}=u3e({withCredentials:Bp.withCredentials,baseUrl:Bp.baseUrl,cache:p3e});async function rR(n){const t=F1e(n);return xt(`/project${t}`,{saveCache:!0})}const h3e=async(n,t={})=>xt("/project",n,{params:t}),m3e=async(n,t={})=>xt(`/project/${n}`,{params:t,saveCache:!0}),g3e=async(n,t,r={})=>Vr(`/project/${n}`,t,{params:r,invalidateCache:{type:"project",id:n}}),v3e=async n=>Xo(`/project/${n}`),y3e=async(n,t={})=>qi(`/project/${n}`,{params:t,invalidateCache:{type:"project",id:n}}),b3e=async()=>xt("/project/createDemo"),_3e=()=>xt("/"),w3e=async(n,t={})=>nn("/auth/actionlink",{token:n,...t}),x3e=async n=>nn("/register",n),C3e=async(n,t)=>nn("/companyUser/forgottenPassword/new",{password:n,resetPasswordToken:t}),k3e=async n=>nn("/public/consent",n),S3e=async n=>xt(`/projectFile/${n}`),T3e=async n=>nn("/projectFile",n),E3e=async(n,t)=>Vr(`/projectFile/${n}`,t),$3e=async n=>qi(`/projectFile/${n}`),A3e=async n=>Xo(`/projectFile/${n}`),O3e=async(n,t={})=>xt(`/projectNote/${n}`,{params:t}),D3e=async(n,t={})=>nn("/projectNote",n,{params:t}),M3e=async(n,t,r={})=>Vr(`/projectNote/${n}`,t,{params:r}),P3e=async n=>xt(`/file/${n}`),iR=async n=>nn("/file",n),I3e=async(n,t)=>Vr(`/file/${n}`,t),R3e=async n=>qi(`/file/${n}`),L3e=async n=>Xo(`/file/${n}`),F3e=async(n={})=>xt("/article",{params:n}),N3e=async n=>xt(`/article/${n}`),B3e=async n=>nn("/article",n),j3e=async(n,t)=>Vr(`/article/${n}`,t),z3e=async n=>qi(`/article/${n}`),V3e=async n=>Xo(`/article/${n}`),U3e=async n=>nn("/search",{type:"article",query:n}),Km={get:async(n,t={})=>xt(n?`/unitType/${n}`:"/unitType",{params:t,saveCache:!0}),post:async(n,t={})=>nn("/unitType",n,{params:t}),put:async(n,t,r={})=>Vr(`/unitType/${n}`,t,{params:r,invalidateCache:{type:"unitType",id:n}}),delete:async(n,t={})=>qi(`/unitType/${n}`,{params:t,invalidateCache:{type:"unitType",id:n}})},H3e=async(n={})=>xt("/templateMessage",{params:n,saveCache:!0}),W3e=async(n,t={})=>xt(`/templateMessage/${n}`,{params:t,saveCache:!0}),G3e=async(n,t={})=>nn("/templateMessage",n,{params:t}),q3e=async(n,t,r={})=>Vr(`/templateMessage/${n}`,t,{params:r,invalidateCache:{type:"templateMessage",id:n}}),Y3e=async(n,t={})=>qi(`/templateMessage/${n}`,{params:t,invalidateCache:{type:"templateMessage",id:n}}),K3e=async(n,t={})=>Xo(`/templateMessage/${n}`,{params:t}),Z3e=async(n={})=>xt("/endCustomer",{params:n}),J3e=async(n,t={})=>xt(`/endCustomer/${n}`,{params:t}),X3e=async(n,t={})=>nn("/endCustomer",n,{params:t}),Q3e=async(n,t,r={})=>Vr(`/endCustomer/${n}`,t,{params:r}),eCe=async(n,t={})=>qi(`/endCustomer/${n}`,{params:t}),tCe=async(n,t={})=>Xo(`/endCustomer/${n}`,{params:t}),nCe=async(n={})=>xt("/companyUser",{params:n,saveCache:!0}),rCe=async(n,t={})=>xt(`/companyUser/${n}`,{params:t,saveCache:!0}),iCe=async(n,t={})=>nn("/companyUser",n,{params:t}),aCe=async(n,t,r={})=>Vr(`/companyUser/${n}`,t,{params:r,invalidateCache:{type:"companyUser",id:n}}),oCe=async(n,t={})=>qi(`/companyUser/${n}`,{params:t,invalidateCache:{type:"companyUser",id:n}}),sCe=async(n,t={})=>Xo(`/companyUser/${n}`,{params:t}),aR={getPublic:async(n,t={})=>xt(`/public/companyUser/${n}`,{params:t}),getConnectedUsers:async(n={})=>xt("/companyUser/self/connectedUsers",{params:n}),getConnectedUserAuth:async(n,t={})=>xt(`/companyUser/self/connectedUsers/${n}/auth`,{params:t}),setConnectedUserDefault:async(n,t={})=>Vr(`/companyUser/self/connectedUsers/${n}/setDefaultAuth`,{params:t}),verifyEmail:async(n,t={})=>nn("/public/verifyEmail/companyUser",n,{params:t})},lCe=async(n,t=null,r={})=>Vr(`/companyAccount/accountType/${n}`,t,{params:r}),cCe=async(n={})=>xt("/companyAccount/getNumberOfManagers",{params:n}),uCe=async(n={})=>nn("/companyAccount/addUserLicenseInvoice",{},{params:n}),dCe=async(n,t={})=>xt(`/promotionCode/${n}/canUse`,{params:t}),pCe=async(n,t={})=>xt("/promotionCode/inUse",{params:t}),ey={product:async(n,t={})=>nn("/companyAccount/product",n,{params:t}),cancelAll:async(n={})=>qi("/companyAccount/subscription",{params:n}),getPrices:async(n={})=>xt("/companyAccount/price",{params:n}),getUpcomingInvoices:async(n={})=>xt("/companyAccount/upcomingInvoice",{params:n}),getPaymentHistory:async(n={})=>xt("/companyAccount/paymentHistory",{params:n}),putPaymentMethod:async(n,t={})=>Vr("/companyAccount/paymentMethod",n,{params:t}),putCustomer:async(n,t={})=>Vr("/companyAccount/customer",n,{params:t}),createCheckoutSession:async(n,t={})=>nn("/companyAccount/create-checkout-session",n,{params:t})},fCe=async(n,t)=>nn(`/project/${n}/projectMember/${t}`,null,{invalidateCache:{type:"project",id:n}}),hCe=async(n,t)=>qi(`/project/${n}/projectMember/${t}`,{invalidateCache:{type:"project",id:n}}),Yi={get:async(n,t={})=>xt(`/document/${n}`,{params:t,saveCache:!0}),getAll:async(n={})=>xt("/document",{params:n,saveCache:!0}),post:async(n,t={})=>nn("/document",n,{params:t}),send:async(n,t={},r={})=>nn(`/document/${n}/send`,t,{params:r,invalidateCache:{type:"document",id:n}}),clearAnswers:async(n,t={},r={})=>nn(`/document/${n}/clearAnswers`,t,{params:r,invalidateCache:{type:"document",id:n}}),put:async(n,t,r={})=>Vr(`/document/${n}`,t,{params:r,invalidateCache:{type:"document",id:n}}),delete:async(n,t={})=>qi(`/document/${n}`,{params:t,invalidateCache:{type:"document",id:n}}),patch:async(n,t={})=>Xo(`/document/${n}`,{params:t}),validate:async(n,t={})=>nn("/documentValidate",n,{params:t})},$u={get:async(n,t={})=>xt(n?`/template/${n}`:"/template",{params:t}),post:async(n,t={})=>nn("/template",n,{params:t}),put:async(n,t,r={})=>Vr(`/template/${n}`,t,{params:r}),delete:async(n,t={})=>qi(`/template/${n}`,{params:t}),patch:async(n,t={})=>Xo(`/template/${n}`,{params:t})},mCe={get:async(n={})=>xt("/templateGallery",{params:n})},gCe={get:async(n,t={})=>xt(`/public/templateStat/${n}`,{params:t})},jp={get:async(n,t={})=>xt(`/public/document/${n}`,{params:t}),put:async(n,t,r={})=>Vr(`/public/document/${n}`,t,{headers:r}),answer:async(n,t,r={},i={})=>nn(`/public/document/${n}/answer`,t,{params:r,headers:i}),feedback:async(n,t,r={})=>nn(`/public/document/${n}/feedback`,t,{params:r})},oR={get:async(n,t={})=>xt(`/public/pdfJob/${n}`,{params:t}),addDocument:async(n,t={})=>xt(`/public/document/${n}/pdfJob/start`,{params:t})},sR={getDocuments:async(n={})=>{const t=wt.getItem("clientToken");return gi.get(`${Bp.baseUrl}/client/document`,{headers:{Authorization:t},params:n})},requestMagicLink:async(n,t={})=>gi.post(`${Bp.baseUrl}/client/requestMagicLink`,n,{params:t})},ty={get:async(n,t={})=>xt(`/public/company/${n}`,{params:t}),getCertificates:async(n,t={})=>xt(`/public/company/${n}/certificates`,{params:t}),getReferences:async(n,t={})=>xt(`/public/company/${n}/references`,{params:t})},vCe={get:async(n,t={})=>xt(`${Bp.baseUrl}/public/signature/${n}`,{params:t})},V3={post:async(n,t={})=>nn("/voucher",n,{params:t}),canUse:async(n,t={})=>xt(`/voucher/${n}/canUse`,{params:t})},Jl={getAuthUrl:async(n,t={})=>xt("/extension/authUrl",{params:{...t,service:n}}),getPublicAuthUrl:async(n,t={})=>xt("/public/extension/authUrl",{params:{...t,service:n}}),install:async(n,t,r={})=>nn("/extension/install",t,{params:{...r,service:n}}),uninstall:async(n,t={})=>qi("/extension/uninstall",{params:{...t,service:n}}),suggestClients:async(n,t={})=>xt("/extension/suggestClients",{params:{...t,service:n},saveCache:!0,cacheTtl:20}),signupWithCrm:async(n,t,r={})=>nn("/public/extension/register",t,{params:{...r,service:n}}),search:async(n,t={})=>xt("/extension/search",{params:{...t,service:n},saveCache:!0,cacheTtl:10}),getFields:async(n,t={})=>xt("/extension/fields",{params:{...t,service:n},saveCache:!0,cacheTtl:60}),getExternalReferenceDetails:async(n,t={})=>xt("/extension/externalReferenceDetails",{params:{...t,service:n},saveCache:!0,cacheTtl:20}),settings:async(n,t={})=>xt("/extension/settings",{params:{...t,service:n}})},ni={get:xt,post:nn,put:Vr,del:qi,patch:Xo,authData:Bp,getProjects:rR};var lR={exports:{}};(function(n,t){(function(r,i){n.exports=i()})(Kt,function(){return function(r){var i={};function a(o){if(i[o])return i[o].exports;var s=i[o]={i:o,l:!1,exports:{}};return r[o].call(s.exports,s,s.exports,a),s.l=!0,s.exports}return a.m=r,a.c=i,a.d=function(o,s,c){a.o(o,s)||Object.defineProperty(o,s,{enumerable:!0,get:c})},a.r=function(o){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(o,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(o,"__esModule",{value:!0})},a.t=function(o,s){if(1&s&&(o=a(o)),8&s||4&s&&typeof o=="object"&&o&&o.__esModule)return o;var c=Object.create(null);if(a.r(c),Object.defineProperty(c,"default",{enumerable:!0,value:o}),2&s&&typeof o!="string")for(var l in o)a.d(c,l,function(u){return o[u]}.bind(null,l));return c},a.n=function(o){var s=o&&o.__esModule?function(){return o.default}:function(){return o};return a.d(s,"a",s),s},a.o=function(o,s){return Object.prototype.hasOwnProperty.call(o,s)},a.p="",a(a.s=6)}([function(r,i,a){var o=a(12),s={};function c($,T){return T===l($)}function l($){var T=typeof $;return T!=="object"?T:$?$ instanceof Error?"error":{}.toString.call($).match(/\s([a-zA-Z]+)/)[1].toLowerCase():"null"}function u($){return c($,"function")}function d($){var T=Function.prototype.toString.call(Object.prototype.hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?"),A=RegExp("^"+T+"$");return p($)&&A.test($)}function p($){var T=typeof $;return $!=null&&(T=="object"||T=="function")}function f(){var $=k();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(T){var A=($+16*Math.random())%16|0;return $=Math.floor($/16),(T==="x"?A:7&A|8).toString(16)})}var h={strictMode:!1,key:["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],q:{name:"queryKey",parser:/(?:^|&)([^&=]*)=?([^&]*)/g},parser:{strict:/^(?:([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?((((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/,loose:/^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/}};function m($,T){var A,E;try{A=s.stringify($)}catch(I){if(T&&u(T))try{A=T($)}catch(R){E=R}else E=I}return{error:E,value:A}}function g($,T){return function(A,E){try{T(A,E)}catch(I){$.error(I)}}}function y($){return function T(A,E){var I,R,Y,L={};try{for(R in A)(I=A[R])&&(c(I,"object")||c(I,"array"))?E.includes(I)?L[R]="Removed circular reference: "+l(I):((Y=E.slice()).push(I),L[R]=T(I,Y)):L[R]=I}catch(D){L="Failed cloning custom data: "+D.message}return L}($,[$])}var b=["log","network","dom","navigation","error","manual"],w=["critical","error","warning","info","debug"];function S($,T){for(var A=0;A<$.length;++A)if($[A]===T)return!0;return!1}function k(){return Date.now?+Date.now():+new Date}r.exports={addParamsAndAccessTokenToPath:function($,T,A){(A=A||{}).access_token=$;var E,I=[];for(E in A)Object.prototype.hasOwnProperty.call(A,E)&&I.push([E,A[E]].join("="));var R="?"+I.sort().join("&");(T=T||{}).path=T.path||"";var Y,L=T.path.indexOf("?"),D=T.path.indexOf("#");L!==-1&&(D===-1||D>L)?(Y=T.path,T.path=Y.substring(0,L)+R+"&"+Y.substring(L+1)):D!==-1?(Y=T.path,T.path=Y.substring(0,D)+R+Y.substring(D)):T.path=T.path+R},createItem:function($,T,A,E,I){for(var R,Y,L,D,B,z,K=[],te=[],j=0,M=$.length;j<M;++j){var q=l(z=$[j]);switch(te.push(q),q){case"undefined":break;case"string":R?K.push(z):R=z;break;case"function":D=g(T,z);break;case"date":K.push(z);break;case"error":case"domexception":case"exception":Y?K.push(z):Y=z;break;case"object":case"array":if(z instanceof Error||typeof DOMException<"u"&&z instanceof DOMException){Y?K.push(z):Y=z;break}if(E&&q==="object"&&!B){for(var G=0,ee=E.length;G<ee;++G)if(z[E[G]]!==void 0){B=z;break}if(B)break}L?K.push(z):L=z;break;default:if(z instanceof Error||typeof DOMException<"u"&&z instanceof DOMException){Y?K.push(z):Y=z;break}K.push(z)}}L&&(L=y(L)),K.length>0&&(L||(L=y({})),L.extraArgs=y(K));var ae={message:R,err:Y,custom:L,timestamp:k(),callback:D,notifier:A,diagnostic:{},uuid:f()};return function(ve,ye){ye&&ye.level!==void 0&&(ve.level=ye.level,delete ye.level),ye&&ye.skipFrames!==void 0&&(ve.skipFrames=ye.skipFrames,delete ye.skipFrames)}(ae,L),E&&B&&(ae.request=B),I&&(ae.lambdaContext=I),ae._originalArgs=$,ae.diagnostic.original_arg_types=te,ae},addErrorContext:function($,T){var A=$.data.custom||{},E=!1;try{for(var I=0;I<T.length;++I)T[I].hasOwnProperty("rollbarContext")&&(A=o(A,y(T[I].rollbarContext)),E=!0);E&&($.data.custom=A)}catch(R){$.diagnostic.error_context="Failed: "+R.message}},createTelemetryEvent:function($){for(var T,A,E,I,R=0,Y=$.length;R<Y;++R)switch(l(I=$[R])){case"string":!T&&S(b,I)?T=I:!E&&S(w,I)&&(E=I);break;case"object":A=I}return{type:T||"manual",metadata:A||{},level:E}},filterIp:function($,T){if($&&$.user_ip&&T!==!0){var A=$.user_ip;if(T)try{var E;if(A.indexOf(".")!==-1)(E=A.split(".")).pop(),E.push("0"),A=E.join(".");else if(A.indexOf(":")!==-1){if((E=A.split(":")).length>2){var I=E.slice(0,3),R=I[2].indexOf("/");R!==-1&&(I[2]=I[2].substring(0,R)),A=I.concat("0000:0000:0000:0000:0000").join(":")}}else A=null}catch{A=null}else A=null;$.user_ip=A}},formatArgsAsString:function($){var T,A,E,I=[];for(T=0,A=$.length;T<A;++T){switch(l(E=$[T])){case"object":(E=(E=m(E)).error||E.value).length>500&&(E=E.substr(0,497)+"...");break;case"null":E="null";break;case"undefined":E="undefined";break;case"symbol":E=E.toString()}I.push(E)}return I.join(" ")},formatUrl:function($,T){if(!(T=T||$.protocol)&&$.port&&($.port===80?T="http:":$.port===443&&(T="https:")),T=T||"https:",!$.hostname)return null;var A=T+"//"+$.hostname;return $.port&&(A=A+":"+$.port),$.path&&(A+=$.path),A},get:function($,T){if($){var A=T.split("."),E=$;try{for(var I=0,R=A.length;I<R;++I)E=E[A[I]]}catch{E=void 0}return E}},handleOptions:function($,T,A,E){var I=o($,T,A);return I=function(R,Y){return R.hostWhiteList&&!R.hostSafeList&&(R.hostSafeList=R.hostWhiteList,R.hostWhiteList=void 0,Y&&Y.log("hostWhiteList is deprecated. Use hostSafeList.")),R.hostBlackList&&!R.hostBlockList&&(R.hostBlockList=R.hostBlackList,R.hostBlackList=void 0,Y&&Y.log("hostBlackList is deprecated. Use hostBlockList.")),R}(I,E),!T||T.overwriteScrubFields||T.scrubFields&&(I.scrubFields=($.scrubFields||[]).concat(T.scrubFields)),I},isError:function($){return c($,"error")||c($,"exception")},isFiniteNumber:function($){return Number.isFinite($)},isFunction:u,isIterable:function($){var T=l($);return T==="object"||T==="array"},isNativeFunction:d,isObject:p,isString:function($){return typeof $=="string"||$ instanceof String},isType:c,isPromise:function($){return p($)&&c($.then,"function")},jsonParse:function($){var T,A;try{T=s.parse($)}catch(E){A=E}return{error:A,value:T}},LEVELS:{debug:0,info:1,warning:2,error:3,critical:4},makeUnhandledStackInfo:function($,T,A,E,I,R,Y,L){var D={url:T||"",line:A,column:E};D.func=L.guessFunctionName(D.url,D.line),D.context=L.gatherContext(D.url,D.line);var B=typeof document<"u"&&document&&document.location&&document.location.href,z=typeof window<"u"&&window&&window.navigator&&window.navigator.userAgent;return{mode:R,message:I?String(I):$||Y,url:B,stack:[D],useragent:z}},merge:o,now:k,redact:function(){return"********"},RollbarJSON:s,sanitizeUrl:function($){var T=function(A){if(c(A,"string")){for(var E=h,I=E.parser[E.strictMode?"strict":"loose"].exec(A),R={},Y=0,L=E.key.length;Y<L;++Y)R[E.key[Y]]=I[Y]||"";return R[E.q.name]={},R[E.key[12]].replace(E.q.parser,function(D,B,z){B&&(R[E.q.name][B]=z)}),R}}($);return T?(T.anchor===""&&(T.source=T.source.replace("#","")),$=T.source.replace("?"+T.query,"")):"(unknown)"},set:function($,T,A){if($){var E=T.split("."),I=E.length;if(!(I<1))if(I!==1)try{for(var R=$[E[0]]||{},Y=R,L=1;L<I-1;++L)R[E[L]]=R[E[L]]||{},R=R[E[L]];R[E[I-1]]=A,$[E[0]]=Y}catch{return}else $[E[0]]=A}},setupJSON:function($){u(s.stringify)&&u(s.parse)||(c(JSON,"undefined")||($?(d(JSON.stringify)&&(s.stringify=JSON.stringify),d(JSON.parse)&&(s.parse=JSON.parse)):(u(JSON.stringify)&&(s.stringify=JSON.stringify),u(JSON.parse)&&(s.parse=JSON.parse))),u(s.stringify)&&u(s.parse)||$&&$(s))},stringify:m,maxByteSize:function($){for(var T=0,A=$.length,E=0;E<A;E++){var I=$.charCodeAt(E);I<128?T+=1:I<2048?T+=2:I<65536&&(T+=3)}return T},typeName:l,uuid4:f}},function(r,i,a){a(17);var o=a(18),s=a(0);r.exports={error:function(){var c=Array.prototype.slice.call(arguments,0);c.unshift("Rollbar:"),o.ieVersion()<=8?console.error(s.formatArgsAsString(c)):console.error.apply(console,c)},info:function(){var c=Array.prototype.slice.call(arguments,0);c.unshift("Rollbar:"),o.ieVersion()<=8?console.info(s.formatArgsAsString(c)):console.info.apply(console,c)},log:function(){var c=Array.prototype.slice.call(arguments,0);c.unshift("Rollbar:"),o.ieVersion()<=8?console.log(s.formatArgsAsString(c)):console.log.apply(console,c)}}},function(r,i,a){r.exports={parse:function(o){var s,c,l={protocol:null,auth:null,host:null,path:null,hash:null,href:o,hostname:null,port:null,pathname:null,search:null,query:null};if((s=o.indexOf("//"))!==-1?(l.protocol=o.substring(0,s),c=s+2):c=0,(s=o.indexOf("@",c))!==-1&&(l.auth=o.substring(c,s),c=s+1),(s=o.indexOf("/",c))===-1){if((s=o.indexOf("?",c))===-1)return(s=o.indexOf("#",c))===-1?l.host=o.substring(c):(l.host=o.substring(c,s),l.hash=o.substring(s)),l.hostname=l.host.split(":")[0],l.port=l.host.split(":")[1],l.port&&(l.port=parseInt(l.port,10)),l;l.host=o.substring(c,s),l.hostname=l.host.split(":")[0],l.port=l.host.split(":")[1],l.port&&(l.port=parseInt(l.port,10)),c=s}else l.host=o.substring(c,s),l.hostname=l.host.split(":")[0],l.port=l.host.split(":")[1],l.port&&(l.port=parseInt(l.port,10)),c=s;if((s=o.indexOf("#",c))===-1?l.path=o.substring(c):(l.path=o.substring(c,s),l.hash=o.substring(s)),l.path){var u=l.path.split("?");l.pathname=u[0],l.query=u[1],l.search=l.query?"?"+l.query:null}return l}}},function(r,i,a){var o=a(24),s=new RegExp("^(([a-zA-Z0-9-_$ ]*): *)?(Uncaught )?([a-zA-Z0-9-_$ ]*): ");function c(){return null}function l(p){var f={};return f._stackFrame=p,f.url=p.fileName,f.line=p.lineNumber,f.func=p.functionName,f.column=p.columnNumber,f.args=p.args,f.context=null,f}function u(p,f){return{stack:function(){var h=[];f=f||0;try{h=o.parse(p)}catch{h=[]}for(var m=[],g=f;g<h.length;g++)m.push(new l(h[g]));return m}(),message:p.message,name:d(p),rawStack:p.stack,rawException:p}}function d(p){var f=p.name&&p.name.length&&p.name,h=p.constructor.name&&p.constructor.name.length&&p.constructor.name;return f&&h?f==="Error"?h:f:f||h}r.exports={guessFunctionName:function(){return"?"},guessErrorClass:function(p){if(!p||!p.match)return["Unknown error. There was no error message to display.",""];var f=p.match(s),h="(unknown)";return f&&(h=f[f.length-1],p=(p=p.replace((f[f.length-2]||"")+h+":","")).replace(/(^[\s]+|[\s]+$)/g,"")),[h,p]},gatherContext:c,parse:function(p,f){var h=p;if(h.nested||h.cause){for(var m=[];h;)m.push(new u(h,f)),h=h.nested||h.cause,f=0;return m[0].traceChain=m,m[0]}return new u(h,f)},Stack:u,Frame:l}},function(r,i,a){var o=a(0),s=a(5);function c(l,u){var d=u.split("."),p=d.length-1;try{for(var f=0;f<=p;++f)f<p?l=l[d[f]]:l[d[f]]=o.redact()}catch{}}r.exports=function(l,u,d){if(u=u||[],d)for(var p=0;p<d.length;++p)c(l,d[p]);var f=function(g){for(var y,b=[],w=0;w<g.length;++w)y="^\\[?(%5[bB])?"+g[w]+"\\[?(%5[bB])?\\]?(%5[dD])?$",b.push(new RegExp(y,"i"));return b}(u),h=function(g){for(var y,b=[],w=0;w<g.length;++w)y="\\[?(%5[bB])?"+g[w]+"\\[?(%5[bB])?\\]?(%5[dD])?",b.push(new RegExp("("+y+"=)([^&\\n]+)","igm"));return b}(u);function m(g,y){return y+o.redact()}return s(l,function g(y,b,w){var S=function(k,$){var T;for(T=0;T<f.length;++T)if(f[T].test(k)){$=o.redact();break}return $}(y,b);return S===b?o.isType(b,"object")||o.isType(b,"array")?s(b,g,w):function(k){var $;if(o.isType(k,"string"))for($=0;$<h.length;++$)k=k.replace(h[$],m);return k}(S):S})}},function(r,i,a){var o=a(0);r.exports=function(s,c,l){var u,d,p,f,h=o.isType(s,"object"),m=o.isType(s,"array"),g=[];if(l=l||{obj:[],mapped:[]},h){if(f=l.obj.indexOf(s),h&&f!==-1)return l.mapped[f]||l.obj[f];l.obj.push(s),f=l.obj.length-1}if(h)for(u in s)Object.prototype.hasOwnProperty.call(s,u)&&g.push(u);else if(m)for(p=0;p<s.length;++p)g.push(p);var y=h?{}:[],b=!0;for(p=0;p<g.length;++p)d=s[u=g[p]],y[u]=c(u,d,l),b=b&&y[u]===s[u];return h&&!b&&(l.mapped[f]=y),b?s:y}},function(r,i,a){r.exports=a(7)},function(r,i,a){var o=a(8),s=typeof window<"u"&&window._rollbarConfig,c=s&&s.globalAlias||"Rollbar",l=typeof window<"u"&&window[c]&&typeof window[c].shimId=="function"&&window[c].shimId()!==void 0;if(typeof window>"u"||window._rollbarStartTime||(window._rollbarStartTime=new Date().getTime()),!l&&s){var u=new o(s);window[c]=u}else typeof window<"u"?(window.rollbar=o,window._rollbarDidLoad=!0):typeof self<"u"&&(self.rollbar=o,self._rollbarDidLoad=!0);r.exports=o},function(r,i,a){var o=a(9),s=a(31),c=a(32),l=a(35),u=a(37),d=a(4),p=a(38);o.setComponents({telemeter:s,instrumenter:c,polyfillJSON:l,wrapGlobals:u,scrub:d,truncation:p}),r.exports=o},function(r,i,a){var o=a(10),s=a(0),c=a(15),l=a(1),u=a(19),d=a(20),p=a(2),f=a(23),h=a(26),m=a(27),g=a(28),y=a(3);function b(I,R){this.options=s.handleOptions(E,I,null,l),this.options._configuredOptions=I;var Y=this.components.telemeter,L=this.components.instrumenter,D=this.components.polyfillJSON;this.wrapGlobals=this.components.wrapGlobals,this.scrub=this.components.scrub;var B=this.components.truncation,z=new d(B),K=new c(this.options,z,p,B);Y&&(this.telemeter=new Y(this.options)),this.client=R||new o(this.options,K,l,this.telemeter,"browser");var te=$(),j=typeof document<"u"&&document;this.isChrome=te.chrome&&te.chrome.runtime,this.anonymousErrorsPending=0,function(M,q,G){M.addTransform(f.handleDomException).addTransform(f.handleItemWithError).addTransform(f.ensureItemHasSomethingToSay).addTransform(f.addBaseInfo).addTransform(f.addRequestInfo(G)).addTransform(f.addClientInfo(G)).addTransform(f.addPluginInfo(G)).addTransform(f.addBody).addTransform(h.addMessageWithError).addTransform(h.addTelemetryData).addTransform(h.addConfigToPayload).addTransform(f.addScrubber(q.scrub)).addTransform(h.addPayloadOptions).addTransform(h.userTransform(l)).addTransform(h.addConfiguredOptions).addTransform(h.addDiagnosticKeys).addTransform(h.itemToPayload)}(this.client.notifier,this,te),this.client.queue.addPredicate(g.checkLevel).addPredicate(m.checkIgnore).addPredicate(g.userCheckIgnore(l)).addPredicate(g.urlIsNotBlockListed(l)).addPredicate(g.urlIsSafeListed(l)).addPredicate(g.messageIsIgnored(l)),this.setupUnhandledCapture(),L&&(this.instrumenter=new L(this.options,this.client.telemeter,this,te,j),this.instrumenter.instrument()),s.setupJSON(D),this.rollbar=this}var w=null;function S(I){var R="Rollbar is not initialized";l.error(R),I&&I(new Error(R))}function k(I){for(var R=0,Y=I.length;R<Y;++R)if(s.isFunction(I[R]))return I[R]}function $(){return typeof window<"u"&&window||typeof self<"u"&&self}b.init=function(I,R){return w?w.global(I).configure(I):w=new b(I,R)},b.prototype.components={},b.setComponents=function(I){b.prototype.components=I},b.prototype.global=function(I){return this.client.global(I),this},b.global=function(I){if(w)return w.global(I);S()},b.prototype.configure=function(I,R){var Y=this.options,L={};return R&&(L={payload:R}),this.options=s.handleOptions(Y,I,L,l),this.options._configuredOptions=s.handleOptions(Y._configuredOptions,I,L),this.client.configure(this.options,R),this.instrumenter&&this.instrumenter.configure(this.options),this.setupUnhandledCapture(),this},b.configure=function(I,R){if(w)return w.configure(I,R);S()},b.prototype.lastError=function(){return this.client.lastError},b.lastError=function(){if(w)return w.lastError();S()},b.prototype.log=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.log(I),{uuid:R}},b.log=function(){if(w)return w.log.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.debug=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.debug(I),{uuid:R}},b.debug=function(){if(w)return w.debug.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.info=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.info(I),{uuid:R}},b.info=function(){if(w)return w.info.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.warn=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.warn(I),{uuid:R}},b.warn=function(){if(w)return w.warn.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.warning=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.warning(I),{uuid:R}},b.warning=function(){if(w)return w.warning.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.error=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.error(I),{uuid:R}},b.error=function(){if(w)return w.error.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.critical=function(){var I=this._createItem(arguments),R=I.uuid;return this.client.critical(I),{uuid:R}},b.critical=function(){if(w)return w.critical.apply(w,arguments);var I=k(arguments);S(I)},b.prototype.buildJsonPayload=function(I){return this.client.buildJsonPayload(I)},b.buildJsonPayload=function(){if(w)return w.buildJsonPayload.apply(w,arguments);S()},b.prototype.sendJsonPayload=function(I){return this.client.sendJsonPayload(I)},b.sendJsonPayload=function(){if(w)return w.sendJsonPayload.apply(w,arguments);S()},b.prototype.setupUnhandledCapture=function(){var I=$();this.unhandledExceptionsInitialized||(this.options.captureUncaught||this.options.handleUncaughtExceptions)&&(u.captureUncaughtExceptions(I,this),this.wrapGlobals&&this.options.wrapGlobalEventHandlers&&this.wrapGlobals(I,this),this.unhandledExceptionsInitialized=!0),this.unhandledRejectionsInitialized||(this.options.captureUnhandledRejections||this.options.handleUnhandledRejections)&&(u.captureUnhandledRejections(I,this),this.unhandledRejectionsInitialized=!0)},b.prototype.handleUncaughtException=function(I,R,Y,L,D,B){if(this.options.captureUncaught||this.options.handleUncaughtExceptions){if(this.options.inspectAnonymousErrors&&this.isChrome&&D===null&&R==="")return"anonymous";var z,K=s.makeUnhandledStackInfo(I,R,Y,L,D,"onerror","uncaught exception",y);s.isError(D)?(z=this._createItem([I,D,B]))._unhandledStackInfo=K:s.isError(R)?(z=this._createItem([I,R,B]))._unhandledStackInfo=K:(z=this._createItem([I,B])).stackInfo=K,z.level=this.options.uncaughtErrorLevel,z._isUncaught=!0,this.client.log(z)}},b.prototype.handleAnonymousErrors=function(){if(this.options.inspectAnonymousErrors&&this.isChrome){var I=this;try{Error.prepareStackTrace=function(R,Y){if(I.options.inspectAnonymousErrors&&I.anonymousErrorsPending){if(I.anonymousErrorsPending-=1,!R)return;R._isAnonymous=!0,I.handleUncaughtException(R.message,null,null,null,R)}return R.stack}}catch(R){this.options.inspectAnonymousErrors=!1,this.error("anonymous error handler failed",R)}}},b.prototype.handleUnhandledRejection=function(I,R){if(this.options.captureUnhandledRejections||this.options.handleUnhandledRejections){var Y="unhandled rejection was null or undefined!";if(I)if(I.message)Y=I.message;else{var L=s.stringify(I);L.value&&(Y=L.value)}var D,B=I&&I._rollbarContext||R&&R._rollbarContext;s.isError(I)?D=this._createItem([Y,I,B]):(D=this._createItem([Y,I,B])).stackInfo=s.makeUnhandledStackInfo(Y,"",0,0,null,"unhandledrejection","",y),D.level=this.options.uncaughtErrorLevel,D._isUncaught=!0,D._originalArgs=D._originalArgs||[],D._originalArgs.push(R),this.client.log(D)}},b.prototype.wrap=function(I,R,Y){try{var L;if(L=s.isFunction(R)?R:function(){return R||{}},!s.isFunction(I)||I._isWrap)return I;if(!I._rollbar_wrapped&&(I._rollbar_wrapped=function(){Y&&s.isFunction(Y)&&Y.apply(this,arguments);try{return I.apply(this,arguments)}catch(z){var B=z;throw B&&window._rollbarWrappedError!==B&&(s.isType(B,"string")&&(B=new String(B)),B._rollbarContext=L()||{},B._rollbarContext._wrappedSource=I.toString(),window._rollbarWrappedError=B),B}},I._rollbar_wrapped._isWrap=!0,I.hasOwnProperty))for(var D in I)I.hasOwnProperty(D)&&D!=="_rollbar_wrapped"&&(I._rollbar_wrapped[D]=I[D]);return I._rollbar_wrapped}catch{return I}},b.wrap=function(I,R){if(w)return w.wrap(I,R);S()},b.prototype.captureEvent=function(){var I=s.createTelemetryEvent(arguments);return this.client.captureEvent(I.type,I.metadata,I.level)},b.captureEvent=function(){if(w)return w.captureEvent.apply(w,arguments);S()},b.prototype.captureDomContentLoaded=function(I,R){return R||(R=new Date),this.client.captureDomContentLoaded(R)},b.prototype.captureLoad=function(I,R){return R||(R=new Date),this.client.captureLoad(R)},b.prototype.loadFull=function(){l.info("Unexpected Rollbar.loadFull() called on a Notifier instance. This can happen when Rollbar is loaded multiple times.")},b.prototype._createItem=function(I){return s.createItem(I,l,this)};var T=a(29),A=a(30),E={version:T.version,scrubFields:A.scrubFields,logLevel:T.logLevel,reportLevel:T.reportLevel,uncaughtErrorLevel:T.uncaughtErrorLevel,endpoint:T.endpoint,verbose:!1,enabled:!0,transmit:!0,sendConfig:!1,includeItemsInTelemetry:!0,captureIp:!0,inspectAnonymousErrors:!0,ignoreDuplicateErrors:!0,wrapGlobalEventHandlers:!1};r.exports=b},function(r,i,a){var o=a(11),s=a(13),c=a(14),l=a(0);function u(f,h,m,g,y){this.options=l.merge(f),this.logger=m,u.rateLimiter.configureGlobal(this.options),u.rateLimiter.setPlatformOptions(y,this.options),this.api=h,this.queue=new s(u.rateLimiter,h,m,this.options);var b=this.options.tracer||null;p(b)?(this.tracer=b,this.options.tracer="opentracing-tracer-enabled",this.options._configuredOptions.tracer="opentracing-tracer-enabled"):this.tracer=null,this.notifier=new c(this.queue,this.options),this.telemeter=g,d(f),this.lastError=null,this.lastErrorHash="none"}function d(f){f.stackTraceLimit&&(Error.stackTraceLimit=f.stackTraceLimit)}function p(f){if(!f||!f.scope||typeof f.scope!="function")return!1;var h=f.scope();return!(!h||!h.active||typeof h.active!="function")}u.rateLimiter=new o({maxItems:0,itemsPerMinute:60}),u.prototype.global=function(f){return u.rateLimiter.configureGlobal(f),this},u.prototype.configure=function(f,h){var m=this.options,g={};h&&(g={payload:h}),this.options=l.merge(m,f,g);var y=this.options.tracer||null;return p(y)?(this.tracer=y,this.options.tracer="opentracing-tracer-enabled",this.options._configuredOptions.tracer="opentracing-tracer-enabled"):this.tracer=null,this.notifier&&this.notifier.configure(this.options),this.telemeter&&this.telemeter.configure(this.options),d(f),this.global(this.options),p(f.tracer)&&(this.tracer=f.tracer),this},u.prototype.log=function(f){var h=this._defaultLogLevel();return this._log(h,f)},u.prototype.debug=function(f){this._log("debug",f)},u.prototype.info=function(f){this._log("info",f)},u.prototype.warn=function(f){this._log("warning",f)},u.prototype.warning=function(f){this._log("warning",f)},u.prototype.error=function(f){this._log("error",f)},u.prototype.critical=function(f){this._log("critical",f)},u.prototype.wait=function(f){this.queue.wait(f)},u.prototype.captureEvent=function(f,h,m){return this.telemeter&&this.telemeter.captureEvent(f,h,m)},u.prototype.captureDomContentLoaded=function(f){return this.telemeter&&this.telemeter.captureDomContentLoaded(f)},u.prototype.captureLoad=function(f){return this.telemeter&&this.telemeter.captureLoad(f)},u.prototype.buildJsonPayload=function(f){return this.api.buildJsonPayload(f)},u.prototype.sendJsonPayload=function(f){this.api.postJsonPayload(f)},u.prototype._log=function(f,h){var m;if(h.callback&&(m=h.callback,delete h.callback),this.options.ignoreDuplicateErrors&&this._sameAsLastError(h)){if(m){var g=new Error("ignored identical item");g.item=h,m(g)}}else try{this._addTracingInfo(h),h.level=h.level||f,this.telemeter&&this.telemeter._captureRollbarItem(h),h.telemetryEvents=this.telemeter&&this.telemeter.copyEvents()||[],this.notifier.log(h,m)}catch(y){m&&m(y),this.logger.error(y)}},u.prototype._defaultLogLevel=function(){return this.options.logLevel||"debug"},u.prototype._sameAsLastError=function(f){if(!f._isUncaught)return!1;var h=function(m){var g=m.message||"",y=(m.err||{}).stack||String(m.err);return g+"::"+y}(f);return this.lastErrorHash===h||(this.lastError=f.err,this.lastErrorHash=h,!1)},u.prototype._addTracingInfo=function(f){if(this.tracer){var h=this.tracer.scope().active();if(function(y){if(!y||!y.context||typeof y.context!="function")return!1;var b=y.context();return!(!b||!b.toSpanId||!b.toTraceId||typeof b.toSpanId!="function"||typeof b.toTraceId!="function")}(h)){h.setTag("rollbar.error_uuid",f.uuid),h.setTag("rollbar.has_error",!0),h.setTag("error",!0),h.setTag("rollbar.item_url","https://rollbar.com/item/uuid/?uuid="+f.uuid),h.setTag("rollbar.occurrence_url","https://rollbar.com/occurrence/uuid/?uuid="+f.uuid);var m=h.context().toSpanId(),g=h.context().toTraceId();f.custom?(f.custom.opentracing_span_id=m,f.custom.opentracing_trace_id=g):f.custom={opentracing_span_id:m,opentracing_trace_id:g}}}},r.exports=u},function(r,i,a){var o=a(0);function s(u){this.startTime=o.now(),this.counter=0,this.perMinCounter=0,this.platform=null,this.platformOptions={},this.configureGlobal(u)}function c(u,d,p){return!u.ignoreRateLimit&&d>=1&&p>d}function l(u,d,p,f,h,m,g){var y=null;return p&&(p=new Error(p)),p||f||(y=function(b,w,S,k,$){var T,A=w.environment||w.payload&&w.payload.environment;T=$?"item per minute limit reached, ignoring errors until timeout":"maxItems has been hit, ignoring errors until reset.";var E={body:{message:{body:T,extra:{maxItems:S,itemsPerMinute:k}}},language:"javascript",environment:A,notifier:{version:w.notifier&&w.notifier.version||w.version}};return b==="browser"?(E.platform="browser",E.framework="browser-js",E.notifier.name="rollbar-browser-js"):b==="server"?(E.framework=w.framework||"node-js",E.notifier.name=w.notifier.name):b==="react-native"&&(E.framework=w.framework||"react-native",E.notifier.name=w.notifier.name),E}(u,d,h,m,g)),{error:p,shouldSend:f,payload:y}}s.globalSettings={startTime:o.now(),maxItems:void 0,itemsPerMinute:void 0},s.prototype.configureGlobal=function(u){u.startTime!==void 0&&(s.globalSettings.startTime=u.startTime),u.maxItems!==void 0&&(s.globalSettings.maxItems=u.maxItems),u.itemsPerMinute!==void 0&&(s.globalSettings.itemsPerMinute=u.itemsPerMinute)},s.prototype.shouldSend=function(u,d){var p=(d=d||o.now())-this.startTime;(p<0||p>=6e4)&&(this.startTime=d,this.perMinCounter=0);var f=s.globalSettings.maxItems,h=s.globalSettings.itemsPerMinute;if(c(u,f,this.counter))return l(this.platform,this.platformOptions,f+" max items reached",!1);if(c(u,h,this.perMinCounter))return l(this.platform,this.platformOptions,h+" items per minute reached",!1);this.counter++,this.perMinCounter++;var m=!c(u,f,this.counter),g=m;return m=m&&!c(u,h,this.perMinCounter),l(this.platform,this.platformOptions,null,m,f,h,g)},s.prototype.setPlatformOptions=function(u,d){this.platform=u,this.platformOptions=d},r.exports=s},function(r,i,a){var o=Object.prototype.hasOwnProperty,s=Object.prototype.toString,c=function(l){if(!l||s.call(l)!=="[object Object]")return!1;var u,d=o.call(l,"constructor"),p=l.constructor&&l.constructor.prototype&&o.call(l.constructor.prototype,"isPrototypeOf");if(l.constructor&&!d&&!p)return!1;for(u in l);return u===void 0||o.call(l,u)};r.exports=function l(){var u,d,p,f,h,m={},g=null,y=arguments.length;for(u=0;u<y;u++)if((g=arguments[u])!=null)for(h in g)d=m[h],m!==(p=g[h])&&(p&&c(p)?(f=d&&c(d)?d:{},m[h]=l(f,p)):p!==void 0&&(m[h]=p));return m}},function(r,i,a){var o=a(0);function s(l,u,d,p){this.rateLimiter=l,this.api=u,this.logger=d,this.options=p,this.predicates=[],this.pendingItems=[],this.pendingRequests=[],this.retryQueue=[],this.retryHandle=null,this.waitCallback=null,this.waitIntervalID=null}s.prototype.configure=function(l){this.api&&this.api.configure(l);var u=this.options;return this.options=o.merge(u,l),this},s.prototype.addPredicate=function(l){return o.isFunction(l)&&this.predicates.push(l),this},s.prototype.addPendingItem=function(l){this.pendingItems.push(l)},s.prototype.removePendingItem=function(l){var u=this.pendingItems.indexOf(l);u!==-1&&this.pendingItems.splice(u,1)},s.prototype.addItem=function(l,u,d,p){u&&o.isFunction(u)||(u=function(){});var f=this._applyPredicates(l);if(f.stop)return this.removePendingItem(p),void u(f.err);if(this._maybeLog(l,d),this.removePendingItem(p),this.options.transmit){this.pendingRequests.push(l);try{this._makeApiRequest(l,function(h,m){this._dequeuePendingRequest(l),u(h,m)}.bind(this))}catch(h){this._dequeuePendingRequest(l),u(h)}}else u(new Error("Transmit disabled"))},s.prototype.wait=function(l){o.isFunction(l)&&(this.waitCallback=l,this._maybeCallWait()||(this.waitIntervalID&&(this.waitIntervalID=clearInterval(this.waitIntervalID)),this.waitIntervalID=setInterval(function(){this._maybeCallWait()}.bind(this),500)))},s.prototype._applyPredicates=function(l){for(var u=null,d=0,p=this.predicates.length;d<p;d++)if(!(u=this.predicates[d](l,this.options))||u.err!==void 0)return{stop:!0,err:u.err};return{stop:!1,err:null}},s.prototype._makeApiRequest=function(l,u){var d=this.rateLimiter.shouldSend(l);d.shouldSend?this.api.postItem(l,function(p,f){p?this._maybeRetry(p,l,u):u(p,f)}.bind(this)):d.error?u(d.error):this.api.postItem(d.payload,u)};var c=["ECONNRESET","ENOTFOUND","ESOCKETTIMEDOUT","ETIMEDOUT","ECONNREFUSED","EHOSTUNREACH","EPIPE","EAI_AGAIN"];s.prototype._maybeRetry=function(l,u,d){var p=!1;if(this.options.retryInterval){for(var f=0,h=c.length;f<h;f++)if(l.code===c[f]){p=!0;break}p&&o.isFiniteNumber(this.options.maxRetries)&&(u.retries=u.retries?u.retries+1:1,u.retries>this.options.maxRetries&&(p=!1))}p?this._retryApiRequest(u,d):d(l)},s.prototype._retryApiRequest=function(l,u){this.retryQueue.push({item:l,callback:u}),this.retryHandle||(this.retryHandle=setInterval(function(){for(;this.retryQueue.length;){var d=this.retryQueue.shift();this._makeApiRequest(d.item,d.callback)}}.bind(this),this.options.retryInterval))},s.prototype._dequeuePendingRequest=function(l){var u=this.pendingRequests.indexOf(l);u!==-1&&(this.pendingRequests.splice(u,1),this._maybeCallWait())},s.prototype._maybeLog=function(l,u){if(this.logger&&this.options.verbose){var d=u;if(d=(d=d||o.get(l,"body.trace.exception.message"))||o.get(l,"body.trace_chain.0.exception.message"))return void this.logger.error(d);(d=o.get(l,"body.message.body"))&&this.logger.log(d)}},s.prototype._maybeCallWait=function(){return!(!o.isFunction(this.waitCallback)||this.pendingItems.length!==0||this.pendingRequests.length!==0)&&(this.waitIntervalID&&(this.waitIntervalID=clearInterval(this.waitIntervalID)),this.waitCallback(),!0)},r.exports=s},function(r,i,a){var o=a(0);function s(c,l){this.queue=c,this.options=l,this.transforms=[],this.diagnostic={}}s.prototype.configure=function(c){this.queue&&this.queue.configure(c);var l=this.options;return this.options=o.merge(l,c),this},s.prototype.addTransform=function(c){return o.isFunction(c)&&this.transforms.push(c),this},s.prototype.log=function(c,l){if(l&&o.isFunction(l)||(l=function(){}),!this.options.enabled)return l(new Error("Rollbar is not enabled"));this.queue.addPendingItem(c);var u=c.err;this._applyTransforms(c,function(d,p){if(d)return this.queue.removePendingItem(c),l(d,null);this.queue.addItem(p,l,u,c)}.bind(this))},s.prototype._applyTransforms=function(c,l){var u=-1,d=this.transforms.length,p=this.transforms,f=this.options,h=function(m,g){m?l(m,null):++u!==d?p[u](g,f,h):l(null,g)};h(null,c)},r.exports=s},function(r,i,a){var o=a(0),s=a(16),c={hostname:"api.rollbar.com",path:"/api/1/item/",search:null,version:"1",protocol:"https:",port:443};function l(d,p,f,h,m){this.options=d,this.transport=p,this.url=f,this.truncation=h,this.jsonBackup=m,this.accessToken=d.accessToken,this.transportOptions=u(d,f)}function u(d,p){return s.getTransportFromOptions(d,c,p)}l.prototype.postItem=function(d,p){var f=s.transportOptions(this.transportOptions,"POST"),h=s.buildPayload(this.accessToken,d,this.jsonBackup),m=this;setTimeout(function(){m.transport.post(m.accessToken,f,h,p)},0)},l.prototype.buildJsonPayload=function(d,p){var f,h=s.buildPayload(this.accessToken,d,this.jsonBackup);return(f=this.truncation?this.truncation.truncate(h):o.stringify(h)).error?(p&&p(f.error),null):f.value},l.prototype.postJsonPayload=function(d,p){var f=s.transportOptions(this.transportOptions,"POST");this.transport.postJsonPayload(this.accessToken,f,d,p)},l.prototype.configure=function(d){var p=this.oldOptions;return this.options=o.merge(p,d),this.transportOptions=u(this.options,this.url),this.options.accessToken!==void 0&&(this.accessToken=this.options.accessToken),this},r.exports=l},function(r,i,a){var o=a(0);r.exports={buildPayload:function(s,c,l){if(!o.isType(c.context,"string")){var u=o.stringify(c.context,l);u.error?c.context="Error: could not serialize 'context'":c.context=u.value||"",c.context.length>255&&(c.context=c.context.substr(0,255))}return{access_token:s,data:c}},getTransportFromOptions:function(s,c,l){var u=c.hostname,d=c.protocol,p=c.port,f=c.path,h=c.search,m=s.timeout,g=function(w){var S=typeof window<"u"&&window||typeof self<"u"&&self,k=w.defaultTransport||"xhr";return S.fetch===void 0&&(k="xhr"),S.XMLHttpRequest===void 0&&(k="fetch"),k}(s),y=s.proxy;if(s.endpoint){var b=l.parse(s.endpoint);u=b.hostname,d=b.protocol,p=b.port,f=b.pathname,h=b.search}return{timeout:m,hostname:u,protocol:d,port:p,path:f,search:h,proxy:y,transport:g}},transportOptions:function(s,c){var l=s.protocol||"https:",u=s.port||(l==="http:"?80:l==="https:"?443:void 0),d=s.hostname,p=s.path,f=s.timeout,h=s.transport;return s.search&&(p+=s.search),s.proxy&&(p=l+"//"+d+p,d=s.proxy.host||s.proxy.hostname,u=s.proxy.port,l=s.proxy.protocol||l),{timeout:f,protocol:l,hostname:d,path:p,port:u,method:c,transport:h}},appendPathToPath:function(s,c){var l=/\/$/.test(s),u=/^\//.test(c);return l&&u?c=c.substring(1):l||u||(c="/"+c),s+c}}},function(r,i){(function(a){a.console||(a.console={});for(var o,s,c=a.console,l=function(){},u=["memory"],d="assert,clear,count,debug,dir,dirxml,error,exception,group,groupCollapsed,groupEnd,info,log,markTimeline,profile,profiles,profileEnd,show,table,time,timeEnd,timeline,timelineEnd,timeStamp,trace,warn".split(",");o=u.pop();)c[o]||(c[o]={});for(;s=d.pop();)c[s]||(c[s]=l)})(typeof window>"u"?this:window)},function(r,i,a){var o={ieVersion:function(){if(typeof document<"u"){for(var s=3,c=document.createElement("div"),l=c.getElementsByTagName("i");c.innerHTML="<!--[if gt IE "+ ++s+"]><i></i><![endif]-->",l[0];);return s>4?s:void 0}}};r.exports=o},function(r,i,a){function o(s,c,l,u){s._rollbarWrappedError&&(u[4]||(u[4]=s._rollbarWrappedError),u[5]||(u[5]=s._rollbarWrappedError._rollbarContext),s._rollbarWrappedError=null);var d=c.handleUncaughtException.apply(c,u);l&&l.apply(s,u),d==="anonymous"&&(c.anonymousErrorsPending+=1)}r.exports={captureUncaughtExceptions:function(s,c,l){if(s){var u;if(typeof c._rollbarOldOnError=="function")u=c._rollbarOldOnError;else if(s.onerror){for(u=s.onerror;u._rollbarOldOnError;)u=u._rollbarOldOnError;c._rollbarOldOnError=u}c.handleAnonymousErrors();var d=function(){var p=Array.prototype.slice.call(arguments,0);o(s,c,u,p)};l&&(d._rollbarOldOnError=u),s.onerror=d}},captureUnhandledRejections:function(s,c,l){if(s){typeof s._rollbarURH=="function"&&s._rollbarURH.belongsToShim&&s.removeEventListener("unhandledrejection",s._rollbarURH);var u=function(d){var p,f,h;try{p=d.reason}catch{p=void 0}try{f=d.promise}catch{f="[unhandledrejection] error getting `promise` from event"}try{h=d.detail,!p&&h&&(p=h.reason,f=h.promise)}catch{}p||(p="[unhandledrejection] error getting `reason` from event"),c&&c.handleUnhandledRejection&&c.handleUnhandledRejection(p,f)};u.belongsToShim=l,s._rollbarURH=u,s.addEventListener("unhandledrejection",u)}}}},function(r,i,a){var o=a(0),s=a(21),c=a(22);function l(u){this.truncation=u}l.prototype.get=function(u,d,p,f,h){f&&o.isFunction(f)||(f=function(){}),o.addParamsAndAccessTokenToPath(u,d,p);var m=o.formatUrl(d);this._makeZoneRequest(u,m,"GET",null,f,h,d.timeout,d.transport)},l.prototype.post=function(u,d,p,f,h){if(f&&o.isFunction(f)||(f=function(){}),!p)return f(new Error("Cannot send empty request"));var m;if((m=this.truncation?this.truncation.truncate(p):o.stringify(p)).error)return f(m.error);var g=m.value,y=o.formatUrl(d);this._makeZoneRequest(u,y,"POST",g,f,h,d.timeout,d.transport)},l.prototype.postJsonPayload=function(u,d,p,f,h){f&&o.isFunction(f)||(f=function(){});var m=o.formatUrl(d);this._makeZoneRequest(u,m,"POST",p,f,h,d.timeout,d.transport)},l.prototype._makeZoneRequest=function(){var u=typeof window<"u"&&window||h!==void 0&&h,d=u&&u.Zone&&u.Zone.current,p=Array.prototype.slice.call(arguments);if(d&&d._name==="angular"){var f=d._parent,h=this;f.run(function(){h._makeRequest.apply(void 0,p)})}else this._makeRequest.apply(void 0,p)},l.prototype._makeRequest=function(u,d,p,f,h,m,g,y){if(typeof RollbarProxy<"u")return function(b,w){new RollbarProxy().sendJsonPayload(b,function(S){},function(S){w(new Error(S))})}(f,h);y==="fetch"?s(u,d,p,f,h,g):c(u,d,p,f,h,m,g)},r.exports=l},function(r,i,a){var o=a(1),s=a(0);r.exports=function(c,l,u,d,p,f){var h,m;s.isFiniteNumber(f)&&(h=new AbortController,m=setTimeout(function(){h.abort()},f)),fetch(l,{method:u,headers:{"Content-Type":"application/json","X-Rollbar-Access-Token":c,signal:h&&h.signal},body:d}).then(function(g){return m&&clearTimeout(m),g.json()}).then(function(g){p(null,g)}).catch(function(g){o.error(g.message),p(g)})}},function(r,i,a){var o=a(0),s=a(1);function c(l,u){var d=new Error(l);return d.code=u||"ENOTFOUND",d}r.exports=function(l,u,d,p,f,h,m){var g;if(!(g=h?h():function(){var w,S,k=[function(){return new XMLHttpRequest},function(){return new ActiveXObject("Msxml2.XMLHTTP")},function(){return new ActiveXObject("Msxml3.XMLHTTP")},function(){return new ActiveXObject("Microsoft.XMLHTTP")}],$=k.length;for(S=0;S<$;S++)try{w=k[S]();break}catch{}return w}()))return f(new Error("No way to send a request"));try{try{var y=function(){try{if(y&&g.readyState===4){y=void 0;var w=o.jsonParse(g.responseText);if(($=g)&&$.status&&$.status===200)return void f(w.error,w.value);if(function(T){return T&&o.isType(T.status,"number")&&T.status>=400&&T.status<600}(g)){if(g.status===403){var S=w.value&&w.value.message;s.error(S)}f(new Error(String(g.status)))}else f(c("XHR response had no status code (likely connection failure)"))}}catch(T){var k;k=T&&T.stack?T:new Error(T),f(k)}var $};g.open(d,u,!0),g.setRequestHeader&&(g.setRequestHeader("Content-Type","application/json"),g.setRequestHeader("X-Rollbar-Access-Token",l)),o.isFiniteNumber(m)&&(g.timeout=m),g.onreadystatechange=y,g.send(p)}catch{if(typeof XDomainRequest<"u"){if(!window||!window.location)return f(new Error("No window available during request, unknown environment"));window.location.href.substring(0,5)==="http:"&&u.substring(0,5)==="https"&&(u="http"+u.substring(5));var b=new XDomainRequest;b.onprogress=function(){},b.ontimeout=function(){f(c("Request timed out","ETIMEDOUT"))},b.onerror=function(){f(new Error("Error during request"))},b.onload=function(){var S=o.jsonParse(b.responseText);f(S.error,S.value)},b.open(d,u,!0),b.send(p)}else f(new Error("Cannot find a method to transport a request"))}}catch(w){f(w)}}},function(r,i,a){var o=a(0),s=a(3),c=a(1);function l(f,h,m){var g=f.message,y=f.custom;g||(g="Item sent with null or missing arguments.");var b={body:g};y&&(b.extra=o.merge(y)),o.set(f,"data.body",{message:b}),m(null,f)}function u(f){var h=f.stackInfo.stack;return h&&h.length===0&&f._unhandledStackInfo&&f._unhandledStackInfo.stack&&(h=f._unhandledStackInfo.stack),h}function d(f,h,m){var g=f&&f.data.description,y=f&&f.custom,b=u(f),w=s.guessErrorClass(h.message),S={exception:{class:p(h,w[0],m),message:w[1]}};if(g&&(S.exception.description=g),b){var k,$,T,A,E,I,R,Y;for(b.length===0&&(S.exception.stack=h.rawStack,S.exception.raw=String(h.rawException)),S.frames=[],R=0;R<b.length;++R)$={filename:(k=b[R]).url?o.sanitizeUrl(k.url):"(unknown)",lineno:k.line||null,method:k.func&&k.func!=="?"?k.func:"[anonymous]",colno:k.column},m.sendFrameUrl&&($.url=k.url),$.method&&$.method.endsWith&&$.method.endsWith("_rollbar_wrapped")||(T=A=E=null,(I=k.context?k.context.length:0)&&(Y=Math.floor(I/2),A=k.context.slice(0,Y),T=k.context[Y],E=k.context.slice(Y)),T&&($.code=T),(A||E)&&($.context={},A&&A.length&&($.context.pre=A),E&&E.length&&($.context.post=E)),k.args&&($.args=k.args),S.frames.push($));S.frames.reverse(),y&&(S.extra=o.merge(y))}return S}function p(f,h,m){return f.name?f.name:m.guessErrorClass?h:"(unknown)"}r.exports={handleDomException:function(f,h,m){if(f.err&&s.Stack(f.err).name==="DOMException"){var g=new Error;g.name=f.err.name,g.message=f.err.message,g.stack=f.err.stack,g.nested=f.err,f.err=g}m(null,f)},handleItemWithError:function(f,h,m){if(f.data=f.data||{},f.err)try{f.stackInfo=f.err._savedStackTrace||s.parse(f.err,f.skipFrames),h.addErrorContext&&function(g){var y=[],b=g.err;for(y.push(b);b.nested||b.cause;)b=b.nested||b.cause,y.push(b);o.addErrorContext(g,y)}(f)}catch(g){c.error("Error while parsing the error object.",g);try{f.message=f.err.message||f.err.description||f.message||String(f.err)}catch(y){f.message=String(f.err)||String(y)}delete f.err}m(null,f)},ensureItemHasSomethingToSay:function(f,h,m){f.message||f.stackInfo||f.custom||m(new Error("No message, stack info, or custom data"),null),m(null,f)},addBaseInfo:function(f,h,m){var g=h.payload&&h.payload.environment||h.environment;f.data=o.merge(f.data,{environment:g,level:f.level,endpoint:h.endpoint,platform:"browser",framework:"browser-js",language:"javascript",server:{},uuid:f.uuid,notifier:{name:"rollbar-browser-js",version:h.version},custom:f.custom}),m(null,f)},addRequestInfo:function(f){return function(h,m,g){var y={};f&&f.location&&(y.url=f.location.href,y.query_string=f.location.search);var b="$remote_ip";m.captureIp?m.captureIp!==!0&&(b+="_anonymize"):b=null,b&&(y.user_ip=b),Object.keys(y).length>0&&o.set(h,"data.request",y),g(null,h)}},addClientInfo:function(f){return function(h,m,g){if(!f)return g(null,h);var y=f.navigator||{},b=f.screen||{};o.set(h,"data.client",{runtime_ms:h.timestamp-f._rollbarStartTime,timestamp:Math.round(h.timestamp/1e3),javascript:{browser:y.userAgent,language:y.language,cookie_enabled:y.cookieEnabled,screen:{width:b.width,height:b.height}}}),g(null,h)}},addPluginInfo:function(f){return function(h,m,g){if(!f||!f.navigator)return g(null,h);for(var y,b=[],w=f.navigator.plugins||[],S=0,k=w.length;S<k;++S)y=w[S],b.push({name:y.name,description:y.description});o.set(h,"data.client.javascript.plugins",b),g(null,h)}},addBody:function(f,h,m){f.stackInfo?f.stackInfo.traceChain?function(g,y,b){for(var w=g.stackInfo.traceChain,S=[],k=w.length,$=0;$<k;$++){var T=d(g,w[$],y);S.push(T)}o.set(g,"data.body",{trace_chain:S}),b(null,g)}(f,h,m):function(g,y,b){if(u(g)){var w=d(g,g.stackInfo,y);o.set(g,"data.body",{trace:w}),b(null,g)}else{var S=g.stackInfo,k=s.guessErrorClass(S.message),$=p(S,k[0],y),T=k[1];g.message=$+": "+T,l(g,y,b)}}(f,h,m):l(f,h,m)},addScrubber:function(f){return function(h,m,g){if(f){var y=m.scrubFields||[],b=m.scrubPaths||[];h.data=f(h.data,y,b)}g(null,h)}}}},function(r,i,a){var o,s,c;(function(l,u){s=[a(25)],(c=typeof(o=function(d){var p=/(^|@)\S+:\d+/,f=/^\s*at .*(\S+:\d+|\(native\))/m,h=/^(eval@)?(\[native code])?$/;return{parse:function(m){if(m.stacktrace!==void 0||m["opera#sourceloc"]!==void 0)return this.parseOpera(m);if(m.stack&&m.stack.match(f))return this.parseV8OrIE(m);if(m.stack)return this.parseFFOrSafari(m);throw new Error("Cannot parse given Error object")},extractLocation:function(m){if(m.indexOf(":")===-1)return[m];var g=/(.+?)(?::(\d+))?(?::(\d+))?$/.exec(m.replace(/[()]/g,""));return[g[1],g[2]||void 0,g[3]||void 0]},parseV8OrIE:function(m){return m.stack.split(`
|
|
438
438
|
`).filter(function(g){return!!g.match(f)},this).map(function(g){g.indexOf("(eval ")>-1&&(g=g.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(,.*$)/g,""));var y=g.replace(/^\s+/,"").replace(/\(eval code/g,"(").replace(/^.*?\s+/,""),b=y.match(/ (\(.+\)$)/);y=b?y.replace(b[0],""):y;var w=this.extractLocation(b?b[1]:y),S=b&&y||void 0,k=["eval","<anonymous>"].indexOf(w[0])>-1?void 0:w[0];return new d({functionName:S,fileName:k,lineNumber:w[1],columnNumber:w[2],source:g})},this)},parseFFOrSafari:function(m){return m.stack.split(`
|
|
439
439
|
`).filter(function(g){return!g.match(h)},this).map(function(g){if(g.indexOf(" > eval")>-1&&(g=g.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),g.indexOf("@")===-1&&g.indexOf(":")===-1)return new d({functionName:g});var y=/((.*".+"[^@]*)?[^@]*)(?:@)/,b=g.match(y),w=b&&b[1]?b[1]:void 0,S=this.extractLocation(g.replace(y,""));return new d({functionName:w,fileName:S[0],lineNumber:S[1],columnNumber:S[2],source:g})},this)},parseOpera:function(m){return!m.stacktrace||m.message.indexOf(`
|
|
440
440
|
`)>-1&&m.message.split(`
|
|
@@ -449,7 +449,7 @@ $t(documentTemplateView.smsContent) $t(documentTemplateView.readMore)
|
|
|
449
449
|
`+o+te.join(`,
|
|
450
450
|
`+o)+`
|
|
451
451
|
`+j+"}":"{"+te.join(",")+"}",o=j,z}}("",{"":T})}),typeof a.parse!="function"&&(a.parse=(m={"\\":"\\",'"':'"',"/":"/",t:" ",n:`
|
|
452
|
-
`,r:"\r",f:"\f",b:"\b"},g={go:function(){u="ok"},firstokey:function(){f=h,u="colon"},okey:function(){f=h,u="colon"},ovalue:function(){u="ocomma"},firstavalue:function(){u="acomma"},avalue:function(){u="acomma"}},y={go:function(){u="ok"},ovalue:function(){u="ocomma"},firstavalue:function(){u="acomma"},avalue:function(){u="acomma"}},b={"{":{go:function(){d.push({state:"ok"}),p={},u="firstokey"},ovalue:function(){d.push({container:p,state:"ocomma",key:f}),p={},u="firstokey"},firstavalue:function(){d.push({container:p,state:"acomma"}),p={},u="firstokey"},avalue:function(){d.push({container:p,state:"acomma"}),p={},u="firstokey"}},"}":{firstokey:function(){var T=d.pop();h=p,p=T.container,f=T.key,u=T.state},ocomma:function(){var T=d.pop();p[f]=h,h=p,p=T.container,f=T.key,u=T.state}},"[":{go:function(){d.push({state:"ok"}),p=[],u="firstavalue"},ovalue:function(){d.push({container:p,state:"ocomma",key:f}),p=[],u="firstavalue"},firstavalue:function(){d.push({container:p,state:"acomma"}),p=[],u="firstavalue"},avalue:function(){d.push({container:p,state:"acomma"}),p=[],u="firstavalue"}},"]":{firstavalue:function(){var T=d.pop();h=p,p=T.container,f=T.key,u=T.state},acomma:function(){var T=d.pop();p.push(h),h=p,p=T.container,f=T.key,u=T.state}},":":{colon:function(){if(Object.hasOwnProperty.call(p,f))throw new SyntaxError("Duplicate key '"+f+'"');u="ovalue"}},",":{ocomma:function(){p[f]=h,u="okey"},acomma:function(){p.push(h),u="avalue"}},true:{go:function(){h=!0,u="ok"},ovalue:function(){h=!0,u="ocomma"},firstavalue:function(){h=!0,u="acomma"},avalue:function(){h=!0,u="acomma"}},false:{go:function(){h=!1,u="ok"},ovalue:function(){h=!1,u="ocomma"},firstavalue:function(){h=!1,u="acomma"},avalue:function(){h=!1,u="acomma"}},null:{go:function(){h=null,u="ok"},ovalue:function(){h=null,u="ocomma"},firstavalue:function(){h=null,u="acomma"},avalue:function(){h=null,u="acomma"}}},function(T,A){var E,I,R=/^[\u0020\t\n\r]*(?:([,:\[\]{}]|true|false|null)|(-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)|"((?:[^\r\n\t\\\"]|\\(?:["\\\/trnfb]|u[0-9a-fA-F]{4}))*)")/;u="go",d=[];try{for(;E=R.exec(T);)E[1]?b[E[1]][u]():E[2]?(h=+E[2],y[u]()):(I=E[3],h=I.replace(/\\(?:u(.{4})|([^u]))/g,function(Y,L,D){return L?String.fromCharCode(parseInt(L,16)):m[D]}),g[u]()),T=T.slice(E[0].length)}catch(Y){u=Y}if(u!=="ok"||/[^\u0020\t\n\r]/.test(T))throw u instanceof SyntaxError?u:new SyntaxError("JSON");return typeof A=="function"?function Y(L,D){var B,z,K=L[D];if(K&&typeof K=="object")for(B in h)Object.prototype.hasOwnProperty.call(K,B)&&((z=Y(K,B))!==void 0?K[B]=z:delete K[B]);return A.call(L,D,K)}({"":h},""):h}))}},function(r,i,a){function o(s,c,l){if(c.hasOwnProperty&&c.hasOwnProperty("addEventListener")){for(var u=c.addEventListener;u._rollbarOldAdd&&u.belongsToShim;)u=u._rollbarOldAdd;var d=function(h,m,g){u.call(this,h,s.wrap(m),g)};d._rollbarOldAdd=u,d.belongsToShim=l,c.addEventListener=d;for(var p=c.removeEventListener;p._rollbarOldRemove&&p.belongsToShim;)p=p._rollbarOldRemove;var f=function(h,m,g){p.call(this,h,m&&m._rollbar_wrapped||m,g)};f._rollbarOldRemove=p,f.belongsToShim=l,c.removeEventListener=f}}r.exports=function(s,c,l){if(s){var u,d,p="EventTarget,Window,Node,ApplicationCache,AudioTrackList,ChannelMergerNode,CryptoOperation,EventSource,FileReader,HTMLUnknownElement,IDBDatabase,IDBRequest,IDBTransaction,KeyOperation,MediaController,MessagePort,ModalWindow,Notification,SVGElementInstance,Screen,TextTrack,TextTrackCue,TextTrackList,WebSocket,WebSocketWorker,Worker,XMLHttpRequest,XMLHttpRequestEventTarget,XMLHttpRequestUpload".split(",");for(u=0;u<p.length;++u)s[d=p[u]]&&s[d].prototype&&o(c,s[d].prototype,l)}}},function(r,i,a){var o=a(0),s=a(5);function c(g,y){return[g,o.stringify(g,y)]}function l(g,y){var b=g.length;return b>2*y?g.slice(0,y).concat(g.slice(b-y)):g}function u(g,y,b){b=b===void 0?30:b;var w,S=g.data.body;if(S.trace_chain)for(var k=S.trace_chain,$=0;$<k.length;$++)w=l(w=k[$].frames,b),k[$].frames=w;else S.trace&&(w=l(w=S.trace.frames,b),S.trace.frames=w);return[g,o.stringify(g,y)]}function d(g,y){return y&&y.length>g?y.slice(0,g-3).concat("..."):y}function p(g,y,b){return[y=s(y,function w(S,k,$){switch(o.typeName(k)){case"string":return d(g,k);case"object":case"array":return s(k,w,$);default:return k}}),o.stringify(y,b)]}function f(g){return g.exception&&(delete g.exception.description,g.exception.message=d(255,g.exception.message)),g.frames=l(g.frames,1),g}function h(g,y){var b=g.data.body;if(b.trace_chain)for(var w=b.trace_chain,S=0;S<w.length;S++)w[S]=f(w[S]);else b.trace&&(b.trace=f(b.trace));return[g,o.stringify(g,y)]}function m(g,y){return o.maxByteSize(g)>y}r.exports={truncate:function(g,y,b){b=b===void 0?524288:b;for(var w,S,k,$=[c,u,p.bind(null,1024),p.bind(null,512),p.bind(null,256),h];w=$.shift();)if(g=(S=w(g,y))[0],(k=S[1]).error||!m(k.value,b))return k;return k},raw:c,truncateFrames:u,truncateStrings:p,maybeTruncateValue:d}}])})})(lR);var yCe=lR.exports;const bCe=cn(yCe);function _Ce(n){if(typeof n!="string")throw new Error("Param name must be a string");try{const t=`${n}=`,r=document.cookie.split(";");for(let i=0;i<r.length;i++){let a=r[i];for(;a.charAt(0)===" ";)a=a.substring(1,a.length);if(a.indexOf(t)===0)return a.substring(t.length,a.length)}}catch{}return null}const wCe="disabledThirdParties",xCe=["google","facebook","segment","logrocket","rollbar"];function CCe(){let n=[];try{const t=JSON.parse(_Ce(wCe));Array.isArray(t)&&(n=t)}catch{}return n.filter(t=>xCe.includes(t))}const cR=Xe.rollbar.clientToken,U3=new bCe({accessToken:cR,captureUncaught:!0,captureUnhandledRejections:!0,source_map_enabled:!0,environment:Xe.rollbar.environment||Xe.environment,enabled:!1,ignoredMessages:["The operation is insecure","Script error.","null is not an object (evaluating 'localStorage.getItem')","Unexpected token '<'","expected expression, got '<'","ChunkLoadError","Loading chunk","ResizeObserver loop limit exceeded","Failed to update a ServiceWorker for scope","Object Not Found Matching Id","newestWorker is null"],payload:{client:{javascript:{code_version:"0.10.
|
|
452
|
+
`,r:"\r",f:"\f",b:"\b"},g={go:function(){u="ok"},firstokey:function(){f=h,u="colon"},okey:function(){f=h,u="colon"},ovalue:function(){u="ocomma"},firstavalue:function(){u="acomma"},avalue:function(){u="acomma"}},y={go:function(){u="ok"},ovalue:function(){u="ocomma"},firstavalue:function(){u="acomma"},avalue:function(){u="acomma"}},b={"{":{go:function(){d.push({state:"ok"}),p={},u="firstokey"},ovalue:function(){d.push({container:p,state:"ocomma",key:f}),p={},u="firstokey"},firstavalue:function(){d.push({container:p,state:"acomma"}),p={},u="firstokey"},avalue:function(){d.push({container:p,state:"acomma"}),p={},u="firstokey"}},"}":{firstokey:function(){var T=d.pop();h=p,p=T.container,f=T.key,u=T.state},ocomma:function(){var T=d.pop();p[f]=h,h=p,p=T.container,f=T.key,u=T.state}},"[":{go:function(){d.push({state:"ok"}),p=[],u="firstavalue"},ovalue:function(){d.push({container:p,state:"ocomma",key:f}),p=[],u="firstavalue"},firstavalue:function(){d.push({container:p,state:"acomma"}),p=[],u="firstavalue"},avalue:function(){d.push({container:p,state:"acomma"}),p=[],u="firstavalue"}},"]":{firstavalue:function(){var T=d.pop();h=p,p=T.container,f=T.key,u=T.state},acomma:function(){var T=d.pop();p.push(h),h=p,p=T.container,f=T.key,u=T.state}},":":{colon:function(){if(Object.hasOwnProperty.call(p,f))throw new SyntaxError("Duplicate key '"+f+'"');u="ovalue"}},",":{ocomma:function(){p[f]=h,u="okey"},acomma:function(){p.push(h),u="avalue"}},true:{go:function(){h=!0,u="ok"},ovalue:function(){h=!0,u="ocomma"},firstavalue:function(){h=!0,u="acomma"},avalue:function(){h=!0,u="acomma"}},false:{go:function(){h=!1,u="ok"},ovalue:function(){h=!1,u="ocomma"},firstavalue:function(){h=!1,u="acomma"},avalue:function(){h=!1,u="acomma"}},null:{go:function(){h=null,u="ok"},ovalue:function(){h=null,u="ocomma"},firstavalue:function(){h=null,u="acomma"},avalue:function(){h=null,u="acomma"}}},function(T,A){var E,I,R=/^[\u0020\t\n\r]*(?:([,:\[\]{}]|true|false|null)|(-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)|"((?:[^\r\n\t\\\"]|\\(?:["\\\/trnfb]|u[0-9a-fA-F]{4}))*)")/;u="go",d=[];try{for(;E=R.exec(T);)E[1]?b[E[1]][u]():E[2]?(h=+E[2],y[u]()):(I=E[3],h=I.replace(/\\(?:u(.{4})|([^u]))/g,function(Y,L,D){return L?String.fromCharCode(parseInt(L,16)):m[D]}),g[u]()),T=T.slice(E[0].length)}catch(Y){u=Y}if(u!=="ok"||/[^\u0020\t\n\r]/.test(T))throw u instanceof SyntaxError?u:new SyntaxError("JSON");return typeof A=="function"?function Y(L,D){var B,z,K=L[D];if(K&&typeof K=="object")for(B in h)Object.prototype.hasOwnProperty.call(K,B)&&((z=Y(K,B))!==void 0?K[B]=z:delete K[B]);return A.call(L,D,K)}({"":h},""):h}))}},function(r,i,a){function o(s,c,l){if(c.hasOwnProperty&&c.hasOwnProperty("addEventListener")){for(var u=c.addEventListener;u._rollbarOldAdd&&u.belongsToShim;)u=u._rollbarOldAdd;var d=function(h,m,g){u.call(this,h,s.wrap(m),g)};d._rollbarOldAdd=u,d.belongsToShim=l,c.addEventListener=d;for(var p=c.removeEventListener;p._rollbarOldRemove&&p.belongsToShim;)p=p._rollbarOldRemove;var f=function(h,m,g){p.call(this,h,m&&m._rollbar_wrapped||m,g)};f._rollbarOldRemove=p,f.belongsToShim=l,c.removeEventListener=f}}r.exports=function(s,c,l){if(s){var u,d,p="EventTarget,Window,Node,ApplicationCache,AudioTrackList,ChannelMergerNode,CryptoOperation,EventSource,FileReader,HTMLUnknownElement,IDBDatabase,IDBRequest,IDBTransaction,KeyOperation,MediaController,MessagePort,ModalWindow,Notification,SVGElementInstance,Screen,TextTrack,TextTrackCue,TextTrackList,WebSocket,WebSocketWorker,Worker,XMLHttpRequest,XMLHttpRequestEventTarget,XMLHttpRequestUpload".split(",");for(u=0;u<p.length;++u)s[d=p[u]]&&s[d].prototype&&o(c,s[d].prototype,l)}}},function(r,i,a){var o=a(0),s=a(5);function c(g,y){return[g,o.stringify(g,y)]}function l(g,y){var b=g.length;return b>2*y?g.slice(0,y).concat(g.slice(b-y)):g}function u(g,y,b){b=b===void 0?30:b;var w,S=g.data.body;if(S.trace_chain)for(var k=S.trace_chain,$=0;$<k.length;$++)w=l(w=k[$].frames,b),k[$].frames=w;else S.trace&&(w=l(w=S.trace.frames,b),S.trace.frames=w);return[g,o.stringify(g,y)]}function d(g,y){return y&&y.length>g?y.slice(0,g-3).concat("..."):y}function p(g,y,b){return[y=s(y,function w(S,k,$){switch(o.typeName(k)){case"string":return d(g,k);case"object":case"array":return s(k,w,$);default:return k}}),o.stringify(y,b)]}function f(g){return g.exception&&(delete g.exception.description,g.exception.message=d(255,g.exception.message)),g.frames=l(g.frames,1),g}function h(g,y){var b=g.data.body;if(b.trace_chain)for(var w=b.trace_chain,S=0;S<w.length;S++)w[S]=f(w[S]);else b.trace&&(b.trace=f(b.trace));return[g,o.stringify(g,y)]}function m(g,y){return o.maxByteSize(g)>y}r.exports={truncate:function(g,y,b){b=b===void 0?524288:b;for(var w,S,k,$=[c,u,p.bind(null,1024),p.bind(null,512),p.bind(null,256),h];w=$.shift();)if(g=(S=w(g,y))[0],(k=S[1]).error||!m(k.value,b))return k;return k},raw:c,truncateFrames:u,truncateStrings:p,maybeTruncateValue:d}}])})})(lR);var yCe=lR.exports;const bCe=cn(yCe);function _Ce(n){if(typeof n!="string")throw new Error("Param name must be a string");try{const t=`${n}=`,r=document.cookie.split(";");for(let i=0;i<r.length;i++){let a=r[i];for(;a.charAt(0)===" ";)a=a.substring(1,a.length);if(a.indexOf(t)===0)return a.substring(t.length,a.length)}}catch{}return null}const wCe="disabledThirdParties",xCe=["google","facebook","segment","logrocket","rollbar"];function CCe(){let n=[];try{const t=JSON.parse(_Ce(wCe));Array.isArray(t)&&(n=t)}catch{}return n.filter(t=>xCe.includes(t))}const cR=Xe.rollbar.clientToken,U3=new bCe({accessToken:cR,captureUncaught:!0,captureUnhandledRejections:!0,source_map_enabled:!0,environment:Xe.rollbar.environment||Xe.environment,enabled:!1,ignoredMessages:["The operation is insecure","Script error.","null is not an object (evaluating 'localStorage.getItem')","Unexpected token '<'","expected expression, got '<'","ChunkLoadError","Loading chunk","ResizeObserver loop limit exceeded","Failed to update a ServiceWorker for scope","Object Not Found Matching Id","newestWorker is null"],payload:{client:{javascript:{code_version:"0.10.4-beta.0",source_map_enabled:!0,guess_uncaught_frames:!0}}},transform:n=>{const{trace:t}=n.body;if(t&&t.frames)for(let r=0;r<t.frames.length;r++){const{filename:i}=t.frames[r];i&&(t.frames[r].filename=t.frames[r].filename.replace(Xe.baseUrl,"https://dynamichost"))}}}),kCe=!!cR&&!CCe().includes("rollbar");window.enableErrorTracker=()=>{kCe&&U3.configure({enabled:!0})};const SCe=[9001,9002,9003,9004,9005,9006],TCe=[401];function ECe(n){const{payload:t}=n,r=a=>Be.te(`errors:${a}`)&&Be.t(`errors:${a}`);let i=r(n.code);return t.code&&r(t.code)?i=r(t.code):t.fallbackCode&&r(t.fallbackCode)?i=r(t.fallbackCode):t.string&&(i=t.string),i}class $Ce{constructor(){Pn(this,"errors",new Map);this.handleError.bind(this)}init({logger:t=console,showMessage:r,onNetworkError:i,clearNetworkError:a}={}){if(this._logger=t,typeof r!="function")throw Error("showMessage must be a function");this._showMessage=r,this._onNetworkError=i,this._clearNetworkError=a}normalizeError(t){return this.getErrorType(t)!=="Error"?t:new B3(t)}_showNotification(t,r){const i=` Tyvärr har ett okänt fel inträffat, vi har loggat felet och kommer snarast att åtgärda det.
|
|
453
453
|
`;this._showMessage({type:r||"error",message:t||i})}logError(t){this._logger?(this._logger.error(t),this._logger.debug(`${t.name}: ${t.message}`,t.payload)):(console.error(t),console.debug(`${t.name}: ${t.message}`,t.payload))}getErrorType(t){return Object.keys(QI).some(i=>t instanceof QI[i])?t.name:"Error"}addCustomData(t,r){hn(r)!=="object"||this.getErrorType(t)==="Error"||t.add(r)}saveError(t){const r=this.getErrorType(t);this.errors.has(r)||this.errors.set(r,[]);const i=this.errors.get(r);this.errors.set(r,{...i,[t.message]:{count:((i[t.message]||{}).count||0)+1,lastError:new Date}})}isDuplicate(t,r=1){const i=this.getErrorType(t),{lastError:a}=(this.errors.get(i)||{})[t.message]||{};return!!(a&&E1e(O1e(a,r)))}notifyUser(t){if(this.isDuplicate(t)||t.payload&&!t.payload.showMessage)return;const r=ECe(t);r&&this._showNotification(r)}sendRollbarError(t,r=10){if(this.isDuplicate(t,r))return;const{payload:i={},httpStatusCode:a}=t||{},{code:o}=i;o&&SCe.includes(o)||!o&&a&&TCe.includes(a)||U3.error(t,i)}async resolveNetworkError(t){var r;try{await _3e(),(r=this._clearNetworkError)==null||r.call(this)}catch(i){this.getErrorType(i)!=="NetworkError"&&this.handleError(i),setTimeout(()=>{this.resolveNetworkError(t).catch(this.handleError)},5e3)}}}class ACe extends $Ce{handleError(t,r){var a;const i=this.normalizeError(t);this.addCustomData(i,r),this.notifyUser(i),this.logError(i),this.sendRollbarError(i),!this.isDuplicate(i)&&this.getErrorType(i)==="NetworkError"&&((a=this._onNetworkError)==null||a.call(this,i),this.resolveNetworkError(i).catch(this.handleError)),this.saveError(i)}onVueException(t,r,i){r.$nextTick(()=>{this.handleError(t)})}}const uR=new ACe,Ir=uR.handleError.bind(uR),Qo=Ne.observable({messages:[],actions:{}}),OCe=n=>Qo.messages.push(yp(n)),Zm=n=>{const t=Qo.messages[n];Qo.actions[t==null?void 0:t._uniqueId]&&delete Qo.actions[t._uniqueId],Qo.messages.splice(n,1)},dR=({index:n,type:t})=>{try{const r={cancel:()=>Zm(n)},i=Qo.messages[n];if(!i||!i._uniqueId)throw Error("message not found, failed to trigger action");const a=Qo.actions[i._uniqueId];if(!a)throw Error("message has no actions, failed to trigger action");const o=a[t];if(!o)throw Error(`message has no action of type ${t}`);let s=o;if(typeof o=="string"&&(s=r[o],!s))throw Error(`No predefined action of type ${o}`);if(typeof s!="function")throw Error("Unable to extract function from message action");return s(i)}catch(r){return Ir(r)}},Jm=n=>{const{type:t,displayType:r="notification",time:i=5e3,title:a,message:o,closeButton:s,omit:c=""}=n,l={},u={};if((f=>f.split(",").some(h=>{const[m="foo",g="bar"]=h.split(":");return Ne.prototype[m]===g}))(c))return;n.actions&&Object.keys(n.actions).forEach(f=>{const h=n.actions[f];if(typeof h=="object"&&!Array.isArray(h)){if(!h.fn&&!h.callback)throw Error(`No callback function provided for action ${f}`);l[f]=h.fn||h.callback,delete h.fn,delete h.callback,u[f]=h}else if(typeof h=="string")l[f]=h,u[f]={};else if(typeof h=="function")l[f]=h,u[f]={};else throw Error(`Action, ${f} , must be one of: object|string|function`)}),OCe({actions:u,title:a,message:o,type:t,displayType:r,time:i,closeButton:s});const p=Qo.messages.slice(-1)[0];Qo.actions[p._uniqueId]=l},Ws=(n,t)=>Jm({type:n,message:t}),pR=Qo,H9t="";function he(n,t,r,i,a,o,s,c){var l=typeof n=="function"?n.options:n;t&&(l.render=t,l.staticRenderFns=r,l._compiled=!0),i&&(l.functional=!0),o&&(l._scopeId="data-v-"+o);var u;if(s?(u=function(f){f=f||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,!f&&typeof __VUE_SSR_CONTEXT__<"u"&&(f=__VUE_SSR_CONTEXT__),a&&a.call(this,f),f&&f._registeredComponents&&f._registeredComponents.add(s)},l._ssrRegister=u):a&&(u=c?function(){a.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:a),u)if(l.functional){l._injectStyles=u;var d=l.render;l.render=function(h,m){return u.call(m),d(h,m)}}else{var p=l.beforeCreate;l.beforeCreate=p?[].concat(p,u):[u]}return{exports:n,options:l}}const DCe={props:{size:{type:String,default:"40px"},strokeWidth:{type:Number,default:6},color:{type:String,default:""}}};var MCe=function(t,r){return t("svg",{staticClass:"spinner spinner--circle inline-block",class:[r.props.color],style:{width:r.props.size,height:r.props.size,lineHeight:r.props.size,...r.data.staticStyle},attrs:{viewBox:"0 0 66 66",xmlns:"http://www.w3.org/2000/svg"}},[t("circle",{staticClass:"path",attrs:{fill:"none","stroke-width":r.props.strokeWidth,"stroke-linecap":"round",cx:"33",cy:"33",r:"30"}})])},PCe=[],ICe=he(DCe,MCe,PCe,!0,null,"c4dd8c6e",null,null);const Xm=ICe.exports,RCe={name:"UserMessages",components:{Spinner:Xm},props:{notification:{type:Object,default:()=>({message:"",time:null,type:"error",actions:[],closeButton:!0})},index:{type:Number,default:null}},data(){return{timer:null,displayTimer:null,countDownInterval:null}},async mounted(){this.notification&&(this.notification.time&&await this.addTimer(this.notification.time),this.notification.type==="countdown"&&this.startCountDown(Math.round(this.notification.time/1e3)))},beforeDestroy(){this.countDownInterval&&this.stopCountDown()},methods:{close(){Zm(this.index)},async addTimer(n){if(typeof this.notification.time=="function"){await this.notification.time()==="close"&&this.close();return}const t=()=>Zm(this.index);this.timer=setTimeout(t,n)},clearTimer(){this.timer&&clearTimeout(this.timer)},onMouseOver(){this.clearTimer()},onMouseOut(){this.notification.time,this.addTimer(3e3)},onActionClick(n){dR({index:this.index,type:n}),Zm(this.index)},startCountDown(n){this.displayTimer=n,this.countDownInterval=setInterval(()=>{this.displayTimer===0&&this.stopCountDown(),this.displayTimer-=1},1e3)},stopCountDown(){clearInterval(this.countDownInterval)}}};var LCe=function(){var t=this,r=t._self._c;return r("transition",{attrs:{appear:"","enter-active-class":"transition-all duration-200 ease-out","enter-class":"translate-y-full opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-all duration-200 ease-in","leave-class":"opacity-100","leave-to-class":"translate-y-full opacity-0"}},[r("div",{staticClass:"flex justify-center w-full left-1/2 fixed z-[2147483647] -translate-x-1/2 bottom-4 pointer-events-none",class:[t.notification.type]},[r("div",{staticClass:"z-[100] flex items-center leading-none text-white font-medium h-11 pl-4 rounded-lg pointer-events-auto",class:["notification",t.notification.type,t.notification.closeButton||Object.keys(t.notification.actions||{}).length?"pr-2":"pr-5",{"bg-green-600":t.notification.type==="success","bg-red-500":t.notification.type==="error","bg-orange-600":t.notification.type==="warning","bg-primary-500":!["success","error","warning"].includes(t.notification.type)}],staticStyle:{"max-width":"calc(100% - calc(2 * var(--rem)))"},on:{"mouse-over":t.onMouseOver,"mouse-leave":t.onMouseOut}},[r("div",{staticClass:"block mt-px mr-3 font-semibold"},[t.notification.type==="success"?r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("path",{attrs:{d:"M14 9V5a3 3 0 0 0-3-3l-4 9v11h11.28a2 2 0 0 0 2-1.7l1.38-9a2 2 0 0 0-2-2.3zM7 22H4a2 2 0 0 1-2-2v-7a2 2 0 0 1 2-2h3"}})]):t.notification.type==="error"?r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("polygon",{attrs:{points:"7.86 2 16.14 2 22 7.86 22 16.14 16.14 22 7.86 22 2 16.14 2 7.86 7.86 2"}}),r("line",{attrs:{x1:"12",y1:"8",x2:"12",y2:"12"}}),r("line",{attrs:{x1:"12",y1:"16",x2:"12",y2:"16"}})]):t.notification.type==="warning"?r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("path",{attrs:{d:"M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"}}),r("line",{attrs:{x1:"12",y1:"9",x2:"12",y2:"13"}}),r("line",{attrs:{x1:"12",y1:"17",x2:"12",y2:"17"}})]):["spinner","countdown"].includes(t.notification.type)?r("Spinner",{attrs:{size:"18px",color:"white","stroke-width":8}}):r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("path",{attrs:{d:"M22 17H2a3 3 0 0 0 3-3V9a7 7 0 0 1 14 0v5a3 3 0 0 0 3 3zm-8.27 4a2 2 0 0 1-3.46 0"}})])],1),r("div",{staticClass:"flex-auto text-sm"},[t._v(" "+t._s(t.notification.message)+" ")]),t.notification.type==="countdown"?r("div",{staticClass:"ml-5 font-medium countdown-text"},[t._v(" "+t._s(t.$t("time.secondsLeft",{time:t.displayTimer}))+" ")]):t._e(),Object.keys(t.notification.actions||{}).length?r("div",{staticClass:"w-4"}):t._e(),t.notification.actions&&t.notification.actions.submit?r("div",{staticClass:"px-3 py-2 ml-1 font-semibold leading-none text-white transition-all rounded-md cursor-pointer font-sm bg-white/20 hover:bg-white/30 active:scale-95",on:{click:function(i){return i.preventDefault(),t.onActionClick("submit")}}},[t._v(" "+t._s(t.notification.actions.submit.text)+" ")]):t._e(),t.notification.actions&&t.notification.actions.undo?r("div",{staticClass:"px-3 py-2 ml-1 font-semibold leading-none text-white transition-all rounded-md cursor-pointer font-sm bg-white/20 hover:bg-white/30 active:scale-95",on:{click:function(i){return i.preventDefault(),t.onActionClick("undo")}}},[t._v(" "+t._s(t.notification.actions.undo.text||t.$t("undo"))+" ")]):t._e(),t.notification.closeButton?r("div",{staticClass:"flex items-center justify-center p-2 ml-1 text-white transition-all rounded-full cursor-pointer hover:bg-white/30 active:scale-95",on:{click:function(i){return i.preventDefault(),t.close.apply(null,arguments)}}},[r("BaseIcon",{attrs:{type:"x",size:"14"}})],1):t._e()])])])},FCe=[],NCe=he(RCe,LCe,FCe,!1,null,null,null,null);const BCe=NCe.exports,W9t="",jCe={name:"Dialog",props:{dialog:{type:Object,default:()=>({type:""})},index:{type:Number,default:null}},data(){return{name:"dialog-modal"}},computed:{hasSubmit(){const{submit:n}=this.dialog.actions||{};return typeof n=="object"&&!Array.isArray(n)},submitText(){const{submit:n={}}=this.dialog.actions||{};return n.text||this.$t("continue")},submitType(){return this.dialog.type||"danger"},hasCancel(){const{cancel:n}=this.dialog.actions||{};return typeof n=="object"&&!Array.isArray(n)},cancelText(){const{cancel:n={}}=this.dialog.actions||{};return n.text||this.$t("cancel")}},mounted(){this.$modal.show(this.name),setTimeout(()=>{this.$refs.action&&this.$refs.action.$el.focus()},100),window.addEventListener("keyup",this.handleEscapeKeyUp)},beforeDestroy(){this.$modal.hide(this.name),window.removeEventListener("keyup",this.handleEscapeKeyUp)},methods:{onMessageAction(n){dR({index:this.index,type:n}),Zm(this.index),this.$modal.hide(this.name)},handleEscapeKeyUp(n){n.which===27&&this.onMessageAction("cancel")}}};var zCe=function(){var t=this,r=t._self._c;return r("modal",{staticClass:"transition-fix",staticStyle:{"z-index":"99999999"},attrs:{classes:["v--modal",t.name,"bg-white !rounded-xl shadow-2xl py-4 px-4 duration-100 border border-gray-200"],adaptive:!0,width:"90%","max-width":380,scrollable:!1,height:"auto","click-to-close":!1,transition:"modal-pop",name:"dialog-modal"}},[r("div",{staticClass:"p-2 mb-6 text-base font-normal text-gray-700 select-none"},[t.dialog.title?r("div",{staticClass:"text-md font-bold mb-1 text-gray-900"},[t._v(" "+t._s(t.dialog.title)+" ")]):t._e(),r("div",{staticClass:"text-sm"},[t._v(" "+t._s(t.dialog.message)+" ")])]),r("div",{staticClass:"button-row flex justify-end"},[t.hasCancel?r("CButton",{attrs:{type:"none",pattern:"tertiary",tabindex:"-1",size:"small",taller:""},on:{click:function(i){return t.onMessageAction("cancel")}}},[t._v(" "+t._s(t.cancelText)+" ")]):t._e(),t.hasSubmit?r("CButton",{ref:"action",staticStyle:{"margin-left":"calc(1 * var(--rem))"},attrs:{type:t.submitType,tabindex:"0",size:"small",taller:""},on:{click:function(i){return t.onMessageAction("submit")}}},[t._v(" "+t._s(t.submitText)+" ")]):t._e()],1)])},VCe=[],UCe=he(jCe,zCe,VCe,!1,null,null,null,null);const HCe=UCe.exports,WCe={name:"UserMessages",components:{Notification:BCe,Dialog:HCe},props:{disableNotification:{type:Boolean,default:!1},disableDialog:{type:Boolean,default:!1}},computed:{notification(){const{messages:n}=pR,t=n.findIndex(r=>r.displayType==="notification");return t!==-1&&{index:t,data:n[t]}},dialog(){const{messages:n}=pR,t=n.findIndex(r=>r.displayType==="dialog");return t!==-1&&{index:t,data:n[t]}}}};var GCe=function(){var t=this,r=t._self._c;return r("div",[t.notification&&!t.disableNotification?r("Notification",{key:t.notification.data&&t.notification.data._uniqueId,attrs:{notification:t.notification.data,index:t.notification.index}}):t._e(),t.dialog&&!t.disableDialog?r("Dialog",{key:t.dialog.data&&t.dialog.data._uniqueId,attrs:{dialog:t.dialog.data,index:t.dialog.index}}):t._e()],1)},qCe=[],YCe=he(WCe,GCe,qCe,!1,null,null,null,null);const KCe=YCe.exports;var ny=function(n){return n&&n.Math==Math&&n},Ur=ny(typeof globalThis=="object"&&globalThis)||ny(typeof window=="object"&&window)||ny(typeof self=="object"&&self)||ny(typeof Kt=="object"&&Kt)||function(){return this}()||Function("return this")(),H3={},Vn=function(n){try{return!!n()}catch{return!0}},ZCe=Vn,fo=!ZCe(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),JCe=Vn,ry=!JCe(function(){var n=function(){}.bind();return typeof n!="function"||n.hasOwnProperty("prototype")}),XCe=ry,iy=Function.prototype.call,Fa=XCe?iy.bind(iy):function(){return iy.apply(iy,arguments)},W3={},fR={}.propertyIsEnumerable,hR=Object.getOwnPropertyDescriptor,QCe=hR&&!fR.call({1:2},1);W3.f=QCe?function(t){var r=hR(this,t);return!!r&&r.enumerable}:fR;var ay=function(n,t){return{enumerable:!(n&1),configurable:!(n&2),writable:!(n&4),value:t}},mR=ry,gR=Function.prototype,G3=gR.call,eke=mR&&gR.bind.bind(G3,G3),vR=mR?eke:function(n){return function(){return G3.apply(n,arguments)}},yR=vR,tke=yR({}.toString),nke=yR("".slice),Xl=function(n){return nke(tke(n),8,-1)},rke=Xl,ike=vR,qn=function(n){if(rke(n)==="Function")return ike(n)},ake=qn,oke=Vn,ske=Xl,q3=Object,lke=ake("".split),oy=oke(function(){return!q3("z").propertyIsEnumerable(0)})?function(n){return ske(n)=="String"?lke(n,""):q3(n)}:q3,Au=function(n){return n==null},cke=Au,uke=TypeError,zp=function(n){if(cke(n))throw uke("Can't call method on "+n);return n},dke=oy,pke=zp,Vp=function(n){return dke(pke(n))},Y3=typeof document=="object"&&document.all,fke=typeof Y3>"u"&&Y3!==void 0,bR={all:Y3,IS_HTMLDDA:fke},_R=bR,hke=_R.all,Tr=_R.IS_HTMLDDA?function(n){return typeof n=="function"||n===hke}:function(n){return typeof n=="function"},wR=Tr,xR=bR,mke=xR.all,Ki=xR.IS_HTMLDDA?function(n){return typeof n=="object"?n!==null:wR(n)||n===mke}:function(n){return typeof n=="object"?n!==null:wR(n)},K3=Ur,gke=Tr,vke=function(n){return gke(n)?n:void 0},Qm=function(n,t){return arguments.length<2?vke(K3[n]):K3[n]&&K3[n][t]},yke=qn,Z3=yke({}.isPrototypeOf),bke=Qm,_ke=bke("navigator","userAgent")||"",CR=Ur,J3=_ke,kR=CR.process,SR=CR.Deno,TR=kR&&kR.versions||SR&&SR.version,ER=TR&&TR.v8,ho,sy;ER&&(ho=ER.split("."),sy=ho[0]>0&&ho[0]<4?1:+(ho[0]+ho[1])),!sy&&J3&&(ho=J3.match(/Edge\/(\d+)/),(!ho||ho[1]>=74)&&(ho=J3.match(/Chrome\/(\d+)/),ho&&(sy=+ho[1])));var ly=sy,$R=ly,wke=Vn,AR=!!Object.getOwnPropertySymbols&&!wke(function(){var n=Symbol();return!String(n)||!(Object(n)instanceof Symbol)||!Symbol.sham&&$R&&$R<41}),xke=AR,OR=xke&&!Symbol.sham&&typeof Symbol.iterator=="symbol",Cke=Qm,kke=Tr,Ske=Z3,Tke=OR,Eke=Object,DR=Tke?function(n){return typeof n=="symbol"}:function(n){var t=Cke("Symbol");return kke(t)&&Ske(t.prototype,Eke(n))},$ke=String,X3=function(n){try{return $ke(n)}catch{return"Object"}},Ake=Tr,Oke=X3,Dke=TypeError,cy=function(n){if(Ake(n))return n;throw Dke(Oke(n)+" is not a function")},Mke=cy,Pke=Au,eg=function(n,t){var r=n[t];return Pke(r)?void 0:Mke(r)},Q3=Fa,eC=Tr,tC=Ki,Ike=TypeError,Rke=function(n,t){var r,i;if(t==="string"&&eC(r=n.toString)&&!tC(i=Q3(r,n))||eC(r=n.valueOf)&&!tC(i=Q3(r,n))||t!=="string"&&eC(r=n.toString)&&!tC(i=Q3(r,n)))return i;throw Ike("Can't convert object to primitive value")},MR={exports:{}},PR=Ur,Lke=Object.defineProperty,nC=function(n,t){try{Lke(PR,n,{value:t,configurable:!0,writable:!0})}catch{PR[n]=t}return t},Fke=Ur,Nke=nC,IR="__core-js_shared__",Bke=Fke[IR]||Nke(IR,{}),rC=Bke,RR=rC;(MR.exports=function(n,t){return RR[n]||(RR[n]=t!==void 0?t:{})})("versions",[]).push({version:"3.26.0",mode:"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.26.0/LICENSE",source:"https://github.com/zloirock/core-js"});var iC=MR.exports,jke=zp,zke=Object,Ou=function(n){return zke(jke(n))},Vke=qn,Uke=Ou,Hke=Vke({}.hasOwnProperty),mo=Object.hasOwn||function(t,r){return Hke(Uke(t),r)},Wke=qn,Gke=0,qke=Math.random(),Yke=Wke(1 .toString),aC=function(n){return"Symbol("+(n===void 0?"":n)+")_"+Yke(++Gke+qke,36)},Kke=Ur,Zke=iC,LR=mo,Jke=aC,FR=AR,NR=OR,Up=Zke("wks"),Du=Kke.Symbol,BR=Du&&Du.for,Xke=NR?Du:Du&&Du.withoutSetter||Jke,vi=function(n){if(!LR(Up,n)||!(FR||typeof Up[n]=="string")){var t="Symbol."+n;FR&&LR(Du,n)?Up[n]=Du[n]:NR&&BR?Up[n]=BR(t):Up[n]=Xke(t)}return Up[n]},Qke=Fa,jR=Ki,zR=DR,e6e=eg,t6e=Rke,n6e=vi,r6e=TypeError,i6e=n6e("toPrimitive"),a6e=function(n,t){if(!jR(n)||zR(n))return n;var r=e6e(n,i6e),i;if(r){if(t===void 0&&(t="default"),i=Qke(r,n,t),!jR(i)||zR(i))return i;throw r6e("Can't convert object to primitive value")}return t===void 0&&(t="number"),t6e(n,t)},o6e=a6e,s6e=DR,oC=function(n){var t=o6e(n,"string");return s6e(t)?t:t+""},l6e=Ur,VR=Ki,sC=l6e.document,c6e=VR(sC)&&VR(sC.createElement),lC=function(n){return c6e?sC.createElement(n):{}},u6e=fo,d6e=Vn,p6e=lC,UR=!u6e&&!d6e(function(){return Object.defineProperty(p6e("div"),"a",{get:function(){return 7}}).a!=7}),f6e=fo,h6e=Fa,m6e=W3,g6e=ay,v6e=Vp,y6e=oC,b6e=mo,_6e=UR,HR=Object.getOwnPropertyDescriptor;H3.f=f6e?HR:function(t,r){if(t=v6e(t),r=y6e(r),_6e)try{return HR(t,r)}catch{}if(b6e(t,r))return g6e(!h6e(m6e.f,t,r),t[r])};var go={},w6e=fo,x6e=Vn,WR=w6e&&x6e(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!=42}),C6e=Ki,k6e=String,S6e=TypeError,ma=function(n){if(C6e(n))return n;throw S6e(k6e(n)+" is not an object")},T6e=fo,E6e=UR,$6e=WR,uy=ma,GR=oC,A6e=TypeError,cC=Object.defineProperty,O6e=Object.getOwnPropertyDescriptor,uC="enumerable",dC="configurable",pC="writable";go.f=T6e?$6e?function(t,r,i){if(uy(t),r=GR(r),uy(i),typeof t=="function"&&r==="prototype"&&"value"in i&&pC in i&&!i[pC]){var a=O6e(t,r);a&&a[pC]&&(t[r]=i.value,i={configurable:dC in i?i[dC]:a[dC],enumerable:uC in i?i[uC]:a[uC],writable:!1})}return cC(t,r,i)}:cC:function(t,r,i){if(uy(t),r=GR(r),uy(i),E6e)try{return cC(t,r,i)}catch{}if("get"in i||"set"in i)throw A6e("Accessors not supported");return"value"in i&&(t[r]=i.value),t};var D6e=fo,M6e=go,P6e=ay,Hp=D6e?function(n,t,r){return M6e.f(n,t,P6e(1,r))}:function(n,t,r){return n[t]=r,n},qR={exports:{}},fC=fo,I6e=mo,YR=Function.prototype,R6e=fC&&Object.getOwnPropertyDescriptor,hC=I6e(YR,"name"),L6e=hC&&function(){}.name==="something",F6e=hC&&(!fC||fC&&R6e(YR,"name").configurable),mC={EXISTS:hC,PROPER:L6e,CONFIGURABLE:F6e},N6e=qn,B6e=Tr,gC=rC,j6e=N6e(Function.toString);B6e(gC.inspectSource)||(gC.inspectSource=function(n){return j6e(n)});var KR=gC.inspectSource,z6e=Ur,V6e=Tr,ZR=z6e.WeakMap,JR=V6e(ZR)&&/native code/.test(String(ZR)),U6e=iC,H6e=aC,XR=U6e("keys"),vC=function(n){return XR[n]||(XR[n]=H6e(n))},dy={},W6e=JR,QR=Ur,G6e=Ki,q6e=Hp,yC=mo,bC=rC,Y6e=vC,K6e=dy,eL="Object already initialized",_C=QR.TypeError,Z6e=QR.WeakMap,py,tg,fy,J6e=function(n){return fy(n)?tg(n):py(n,{})},X6e=function(n){return function(t){var r;if(!G6e(t)||(r=tg(t)).type!==n)throw _C("Incompatible receiver, "+n+" required");return r}};if(W6e||bC.state){var es=bC.state||(bC.state=new Z6e);es.get=es.get,es.has=es.has,es.set=es.set,py=function(n,t){if(es.has(n))throw _C(eL);return t.facade=n,es.set(n,t),t},tg=function(n){return es.get(n)||{}},fy=function(n){return es.has(n)}}else{var Wp=Y6e("state");K6e[Wp]=!0,py=function(n,t){if(yC(n,Wp))throw _C(eL);return t.facade=n,q6e(n,Wp,t),t},tg=function(n){return yC(n,Wp)?n[Wp]:{}},fy=function(n){return yC(n,Wp)}}var Gp={set:py,get:tg,has:fy,enforce:J6e,getterFor:X6e},Q6e=Vn,eSe=Tr,hy=mo,wC=fo,tSe=mC.CONFIGURABLE,nSe=KR,tL=Gp,rSe=tL.enforce,iSe=tL.get,my=Object.defineProperty,aSe=wC&&!Q6e(function(){return my(function(){},"length",{value:8}).length!==8}),oSe=String(String).split("String"),sSe=qR.exports=function(n,t,r){String(t).slice(0,7)==="Symbol("&&(t="["+String(t).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!hy(n,"name")||tSe&&n.name!==t)&&(wC?my(n,"name",{value:t,configurable:!0}):n.name=t),aSe&&r&&hy(r,"arity")&&n.length!==r.arity&&my(n,"length",{value:r.arity});try{r&&hy(r,"constructor")&&r.constructor?wC&&my(n,"prototype",{writable:!1}):n.prototype&&(n.prototype=void 0)}catch{}var i=rSe(n);return hy(i,"source")||(i.source=oSe.join(typeof t=="string"?t:"")),n};Function.prototype.toString=sSe(function(){return eSe(this)&&iSe(this).source||nSe(this)},"toString");var lSe=qR.exports,cSe=Tr,uSe=go,dSe=lSe,pSe=nC,Mu=function(n,t,r,i){i||(i={});var a=i.enumerable,o=i.name!==void 0?i.name:t;if(cSe(r)&&dSe(r,o,i),i.global)a?n[t]=r:pSe(t,r);else{try{i.unsafe?n[t]&&(a=!0):delete n[t]}catch{}a?n[t]=r:uSe.f(n,t,{value:r,enumerable:!1,configurable:!i.nonConfigurable,writable:!i.nonWritable})}return n},gy={},fSe=Math.ceil,hSe=Math.floor,mSe=Math.trunc||function(t){var r=+t;return(r>0?hSe:fSe)(r)},gSe=mSe,vy=function(n){var t=+n;return t!==t||t===0?0:gSe(t)},vSe=vy,ySe=Math.max,bSe=Math.min,nL=function(n,t){var r=vSe(n);return r<0?ySe(r+t,0):bSe(r,t)},_Se=vy,wSe=Math.min,xC=function(n){return n>0?wSe(_Se(n),9007199254740991):0},xSe=xC,qp=function(n){return xSe(n.length)},CSe=Vp,kSe=nL,SSe=qp,rL=function(n){return function(t,r,i){var a=CSe(t),o=SSe(a),s=kSe(i,o),c;if(n&&r!=r){for(;o>s;)if(c=a[s++],c!=c)return!0}else for(;o>s;s++)if((n||s in a)&&a[s]===r)return n||s||0;return!n&&-1}},TSe={includes:rL(!0),indexOf:rL(!1)},ESe=qn,CC=mo,$Se=Vp,ASe=TSe.indexOf,OSe=dy,iL=ESe([].push),aL=function(n,t){var r=$Se(n),i=0,a=[],o;for(o in r)!CC(OSe,o)&&CC(r,o)&&iL(a,o);for(;t.length>i;)CC(r,o=t[i++])&&(~ASe(a,o)||iL(a,o));return a},kC=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],DSe=aL,MSe=kC,PSe=MSe.concat("length","prototype");gy.f=Object.getOwnPropertyNames||function(t){return DSe(t,PSe)};var SC={};SC.f=Object.getOwnPropertySymbols;var ISe=Qm,RSe=qn,LSe=gy,FSe=SC,NSe=ma,BSe=RSe([].concat),jSe=ISe("Reflect","ownKeys")||function(t){var r=LSe.f(NSe(t)),i=FSe.f;return i?BSe(r,i(t)):r},oL=mo,zSe=jSe,VSe=H3,USe=go,HSe=function(n,t,r){for(var i=zSe(t),a=USe.f,o=VSe.f,s=0;s<i.length;s++){var c=i[s];!oL(n,c)&&!(r&&oL(r,c))&&a(n,c,o(t,c))}},WSe=Vn,GSe=Tr,qSe=/#|\.prototype\./,ng=function(n,t){var r=KSe[YSe(n)];return r==JSe?!0:r==ZSe?!1:GSe(t)?WSe(t):!!t},YSe=ng.normalize=function(n){return String(n).replace(qSe,".").toLowerCase()},KSe=ng.data={},ZSe=ng.NATIVE="N",JSe=ng.POLYFILL="P",sL=ng,TC=Ur,XSe=H3.f,QSe=Hp,e8e=Mu,t8e=nC,n8e=HSe,r8e=sL,Gs=function(n,t){var r=n.target,i=n.global,a=n.stat,o,s,c,l,u,d;if(i?s=TC:a?s=TC[r]||t8e(r,{}):s=(TC[r]||{}).prototype,s)for(c in t){if(u=t[c],n.dontCallGetSet?(d=XSe(s,c),l=d&&d.value):l=s[c],o=r8e(i?c:r+(a?".":"#")+c,n.forced),!o&&l!==void 0){if(typeof u==typeof l)continue;n8e(u,l)}(n.sham||l&&l.sham)&&QSe(u,"sham",!0),e8e(s,c,u,n)}},i8e=Xl,lL=Array.isArray||function(t){return i8e(t)=="Array"},a8e=TypeError,o8e=9007199254740991,s8e=function(n){if(n>o8e)throw a8e("Maximum allowed index exceeded");return n},l8e=oC,c8e=go,u8e=ay,cL=function(n,t,r){var i=l8e(t);i in n?c8e.f(n,i,u8e(0,r)):n[i]=r},d8e=vi,p8e=d8e("toStringTag"),uL={};uL[p8e]="z";var EC=String(uL)==="[object z]",f8e=EC,h8e=Tr,yy=Xl,m8e=vi,g8e=m8e("toStringTag"),v8e=Object,y8e=yy(function(){return arguments}())=="Arguments",b8e=function(n,t){try{return n[t]}catch{}},by=f8e?yy:function(n){var t,r,i;return n===void 0?"Undefined":n===null?"Null":typeof(r=b8e(t=v8e(n),g8e))=="string"?r:y8e?yy(t):(i=yy(t))=="Object"&&h8e(t.callee)?"Arguments":i},_8e=qn,w8e=Vn,dL=Tr,x8e=by,C8e=Qm,k8e=KR,pL=function(){},S8e=[],fL=C8e("Reflect","construct"),$C=/^\s*(?:class|function)\b/,T8e=_8e($C.exec),E8e=!$C.exec(pL),rg=function(t){if(!dL(t))return!1;try{return fL(pL,S8e,t),!0}catch{return!1}},hL=function(t){if(!dL(t))return!1;switch(x8e(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return E8e||!!T8e($C,k8e(t))}catch{return!0}};hL.sham=!0;var $8e=!fL||w8e(function(){var n;return rg(rg.call)||!rg(Object)||!rg(function(){n=!0})||n})?hL:rg,mL=lL,A8e=$8e,O8e=Ki,D8e=vi,M8e=D8e("species"),gL=Array,P8e=function(n){var t;return mL(n)&&(t=n.constructor,A8e(t)&&(t===gL||mL(t.prototype))?t=void 0:O8e(t)&&(t=t[M8e],t===null&&(t=void 0))),t===void 0?gL:t},I8e=P8e,vL=function(n,t){return new(I8e(n))(t===0?0:t)},R8e=Vn,L8e=vi,F8e=ly,N8e=L8e("species"),yL=function(n){return F8e>=51||!R8e(function(){var t=[],r=t.constructor={};return r[N8e]=function(){return{foo:1}},t[n](Boolean).foo!==1})},B8e=Gs,j8e=Vn,z8e=lL,V8e=Ki,U8e=Ou,H8e=qp,bL=s8e,_L=cL,W8e=vL,G8e=yL,q8e=vi,Y8e=ly,wL=q8e("isConcatSpreadable"),K8e=Y8e>=51||!j8e(function(){var n=[];return n[wL]=!1,n.concat()[0]!==n}),Z8e=G8e("concat"),J8e=function(n){if(!V8e(n))return!1;var t=n[wL];return t!==void 0?!!t:z8e(n)},X8e=!K8e||!Z8e;B8e({target:"Array",proto:!0,arity:1,forced:X8e},{concat:function(t){var r=U8e(this),i=W8e(r,0),a=0,o,s,c,l,u;for(o=-1,c=arguments.length;o<c;o++)if(u=o===-1?r:arguments[o],J8e(u))for(l=H8e(u),bL(a+l),s=0;s<l;s++,a++)s in u&&_L(i,a,u[s]);else bL(a+1),_L(i,a++,u);return i.length=a,i}});var Q8e=EC,e7e=by,t7e=Q8e?{}.toString:function(){return"[object "+e7e(this)+"]"},n7e=EC,r7e=Mu,i7e=t7e;n7e||r7e(Object.prototype,"toString",i7e,{unsafe:!0});var xL={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},a7e=lC,AC=a7e("span").classList,CL=AC&&AC.constructor&&AC.constructor.prototype,kL=CL===Object.prototype?void 0:CL,SL=qn,o7e=cy,s7e=ry,l7e=SL(SL.bind),TL=function(n,t){return o7e(n),t===void 0?n:s7e?l7e(n,t):function(){return n.apply(t,arguments)}},c7e=TL,u7e=qn,d7e=oy,p7e=Ou,f7e=qp,h7e=vL,EL=u7e([].push),Ql=function(n){var t=n==1,r=n==2,i=n==3,a=n==4,o=n==6,s=n==7,c=n==5||o;return function(l,u,d,p){for(var f=p7e(l),h=d7e(f),m=c7e(u,d),g=f7e(h),y=0,b=p||h7e,w=t?b(l,g):r||s?b(l,0):void 0,S,k;g>y;y++)if((c||y in h)&&(S=h[y],k=m(S,y,f),n))if(t)w[y]=k;else if(k)switch(n){case 3:return!0;case 5:return S;case 6:return y;case 2:EL(w,S)}else switch(n){case 4:return!1;case 7:EL(w,S)}return o?-1:i||a?a:w}},OC={forEach:Ql(0),map:Ql(1),filter:Ql(2),some:Ql(3),every:Ql(4),find:Ql(5),findIndex:Ql(6),filterReject:Ql(7)},m7e=Vn,$L=function(n,t){var r=[][n];return!!r&&m7e(function(){r.call(null,t||function(){return 1},1)})},g7e=OC.forEach,v7e=$L,y7e=v7e("forEach"),b7e=y7e?[].forEach:function(t){return g7e(this,t,arguments.length>1?arguments[1]:void 0)},AL=Ur,OL=xL,_7e=kL,DC=b7e,w7e=Hp,DL=function(n){if(n&&n.forEach!==DC)try{w7e(n,"forEach",DC)}catch{n.forEach=DC}};for(var MC in OL)OL[MC]&&DL(AL[MC]&&AL[MC].prototype);DL(_7e);var x7e=!!(typeof window<"u"&&window.document&&window.document.createElement),C7e=x7e;const PC=cn(C7e);var k7e=by,S7e=String,Pu=function(n){if(k7e(n)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return S7e(n)},ML=`
|
|
454
454
|
\v\f\r \u2028\u2029\uFEFF`,T7e=qn,E7e=zp,$7e=Pu,A7e=ML,PL=T7e("".replace),_y="["+A7e+"]",O7e=RegExp("^"+_y+_y+"*"),D7e=RegExp(_y+_y+"*$"),IC=function(n){return function(t){var r=$7e(E7e(t));return n&1&&(r=PL(r,O7e,"")),n&2&&(r=PL(r,D7e,"")),r}},M7e={start:IC(1),end:IC(2),trim:IC(3)},IL=Ur,P7e=Vn,I7e=qn,R7e=Pu,L7e=M7e.trim,RL=ML,ig=IL.parseInt,LL=IL.Symbol,FL=LL&&LL.iterator,NL=/^[+-]?0x/i,F7e=I7e(NL.exec),N7e=ig(RL+"08")!==8||ig(RL+"0x16")!==22||FL&&!P7e(function(){ig(Object(FL))}),B7e=N7e?function(t,r){var i=L7e(R7e(t));return ig(i,r>>>0||(F7e(NL,i)?16:10))}:ig,j7e=Gs,BL=B7e;j7e({global:!0,forced:parseInt!=BL},{parseInt:BL});var z7e=aL,V7e=kC,jL=Object.keys||function(t){return z7e(t,V7e)},zL=fo,U7e=qn,H7e=Fa,W7e=Vn,RC=jL,G7e=SC,q7e=W3,Y7e=Ou,K7e=oy,Yp=Object.assign,VL=Object.defineProperty,Z7e=U7e([].concat),J7e=!Yp||W7e(function(){if(zL&&Yp({b:1},Yp(VL({},"a",{enumerable:!0,get:function(){VL(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var n={},t={},r=Symbol(),i="abcdefghijklmnopqrst";return n[r]=7,i.split("").forEach(function(a){t[a]=a}),Yp({},n)[r]!=7||RC(Yp({},t)).join("")!=i})?function(t,r){for(var i=Y7e(t),a=arguments.length,o=1,s=G7e.f,c=q7e.f;a>o;)for(var l=K7e(arguments[o++]),u=s?Z7e(RC(l),s(l)):RC(l),d=u.length,p=0,f;d>p;)f=u[p++],(!zL||H7e(c,l,f))&&(i[f]=l[f]);return i}:Yp,X7e=Gs,UL=J7e;X7e({target:"Object",stat:!0,arity:2,forced:Object.assign!==UL},{assign:UL});var Q7e=Gs,eTe=OC.filter,tTe=yL,nTe=tTe("filter");Q7e({target:"Array",proto:!0,forced:!nTe},{filter:function(t){return eTe(this,t,arguments.length>1?arguments[1]:void 0)}});var HL={},rTe=fo,iTe=WR,aTe=go,oTe=ma,sTe=Vp,lTe=jL;HL.f=rTe&&!iTe?Object.defineProperties:function(t,r){oTe(t);for(var i=sTe(r),a=lTe(r),o=a.length,s=0,c;o>s;)aTe.f(t,c=a[s++],i[c]);return t};var cTe=Qm,uTe=cTe("document","documentElement"),dTe=ma,pTe=HL,WL=kC,fTe=dy,hTe=uTe,mTe=lC,gTe=vC,GL=">",qL="<",LC="prototype",FC="script",YL=gTe("IE_PROTO"),NC=function(){},KL=function(n){return qL+FC+GL+n+qL+"/"+FC+GL},ZL=function(n){n.write(KL("")),n.close();var t=n.parentWindow.Object;return n=null,t},vTe=function(){var n=mTe("iframe"),t="java"+FC+":",r;return n.style.display="none",hTe.appendChild(n),n.src=String(t),r=n.contentWindow.document,r.open(),r.write(KL("document.F=Object")),r.close(),r.F},wy,xy=function(){try{wy=new ActiveXObject("htmlfile")}catch{}xy=typeof document<"u"?document.domain&&wy?ZL(wy):vTe():ZL(wy);for(var n=WL.length;n--;)delete xy[LC][WL[n]];return xy()};fTe[YL]=!0;var BC=Object.create||function(t,r){var i;return t!==null?(NC[LC]=dTe(t),i=new NC,NC[LC]=null,i[YL]=t):i=xy(),r===void 0?i:pTe.f(i,r)},yTe=vi,bTe=BC,_Te=go.f,jC=yTe("unscopables"),zC=Array.prototype;zC[jC]==null&&_Te(zC,jC,{configurable:!0,value:bTe(null)});var wTe=function(n){zC[jC][n]=!0},ag={},xTe=Vn,CTe=!xTe(function(){function n(){}return n.prototype.constructor=null,Object.getPrototypeOf(new n)!==n.prototype}),kTe=mo,STe=Tr,TTe=Ou,ETe=vC,$Te=CTe,JL=ETe("IE_PROTO"),VC=Object,ATe=VC.prototype,XL=$Te?VC.getPrototypeOf:function(n){var t=TTe(n);if(kTe(t,JL))return t[JL];var r=t.constructor;return STe(r)&&t instanceof r?r.prototype:t instanceof VC?ATe:null},OTe=Vn,DTe=Tr,MTe=Ki,QL=XL,PTe=Mu,ITe=vi,UC=ITe("iterator"),eF=!1,Iu,HC,WC;[].keys&&(WC=[].keys(),"next"in WC?(HC=QL(QL(WC)),HC!==Object.prototype&&(Iu=HC)):eF=!0);var RTe=!MTe(Iu)||OTe(function(){var n={};return Iu[UC].call(n)!==n});RTe&&(Iu={}),DTe(Iu[UC])||PTe(Iu,UC,function(){return this});var tF={IteratorPrototype:Iu,BUGGY_SAFARI_ITERATORS:eF},LTe=go.f,FTe=mo,NTe=vi,nF=NTe("toStringTag"),GC=function(n,t,r){n&&!r&&(n=n.prototype),n&&!FTe(n,nF)&<e(n,nF,{configurable:!0,value:t})},BTe=tF.IteratorPrototype,jTe=BC,zTe=ay,VTe=GC,UTe=ag,HTe=function(){return this},WTe=function(n,t,r,i){var a=t+" Iterator";return n.prototype=jTe(BTe,{next:zTe(+!i,r)}),VTe(n,a,!1),UTe[a]=HTe,n},GTe=Tr,qTe=String,YTe=TypeError,KTe=function(n){if(typeof n=="object"||GTe(n))return n;throw YTe("Can't set "+qTe(n)+" as a prototype")},ZTe=qn,JTe=ma,XTe=KTe,rF=Object.setPrototypeOf||("__proto__"in{}?function(){var n=!1,t={},r;try{r=ZTe(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set),r(t,[]),n=t instanceof Array}catch{}return function(a,o){return JTe(a),XTe(o),n?r(a,o):a.__proto__=o,a}}():void 0),QTe=Gs,eEe=Fa,iF=mC,tEe=Tr,nEe=WTe,aF=XL,oF=rF,rEe=GC,iEe=Hp,qC=Mu,aEe=vi,oEe=ag,sF=tF,sEe=iF.PROPER,lEe=iF.CONFIGURABLE,lF=sF.IteratorPrototype,Cy=sF.BUGGY_SAFARI_ITERATORS,og=aEe("iterator"),cF="keys",sg="values",uF="entries",cEe=function(){return this},dF=function(n,t,r,i,a,o,s){nEe(r,t,i);var c=function(b){if(b===a&&f)return f;if(!Cy&&b in d)return d[b];switch(b){case cF:return function(){return new r(this,b)};case sg:return function(){return new r(this,b)};case uF:return function(){return new r(this,b)}}return function(){return new r(this)}},l=t+" Iterator",u=!1,d=n.prototype,p=d[og]||d["@@iterator"]||a&&d[a],f=!Cy&&p||c(a),h=t=="Array"&&d.entries||p,m,g,y;if(h&&(m=aF(h.call(new n)),m!==Object.prototype&&m.next&&(aF(m)!==lF&&(oF?oF(m,lF):tEe(m[og])||qC(m,og,cEe)),rEe(m,l,!0))),sEe&&a==sg&&p&&p.name!==sg&&(lEe?iEe(d,"name",sg):(u=!0,f=function(){return eEe(p,this)})),a)if(g={values:c(sg),keys:o?f:c(cF),entries:c(uF)},s)for(y in g)(Cy||u||!(y in d))&&qC(d,y,g[y]);else QTe({target:t,proto:!0,forced:Cy||u},g);return d[og]!==f&&qC(d,og,f,{name:a}),oEe[t]=f,g},pF=function(n,t){return{value:n,done:t}},uEe=Vp,YC=wTe,fF=ag,hF=Gp,dEe=go.f,pEe=dF,ky=pF,fEe=fo,mF="Array Iterator",hEe=hF.set,mEe=hF.getterFor(mF),gEe=pEe(Array,"Array",function(n,t){hEe(this,{type:mF,target:uEe(n),index:0,kind:t})},function(){var n=mEe(this),t=n.target,r=n.kind,i=n.index++;return!t||i>=t.length?(n.target=void 0,ky(void 0,!0)):r=="keys"?ky(i,!1):r=="values"?ky(t[i],!1):ky([i,t[i]],!1)},"values"),gF=fF.Arguments=fF.Array;if(YC("keys"),YC("values"),YC("entries"),fEe&&gF.name!=="values")try{dEe(gF,"name",{value:"values"})}catch{}var KC=qn,vEe=vy,yEe=Pu,bEe=zp,_Ee=KC("".charAt),vF=KC("".charCodeAt),wEe=KC("".slice),yF=function(n){return function(t,r){var i=yEe(bEe(t)),a=vEe(r),o=i.length,s,c;return a<0||a>=o?n?"":void 0:(s=vF(i,a),s<55296||s>56319||a+1===o||(c=vF(i,a+1))<56320||c>57343?n?_Ee(i,a):s:n?wEe(i,a,a+2):(s-55296<<10)+(c-56320)+65536)}},bF={codeAt:yF(!1),charAt:yF(!0)},xEe=bF.charAt,CEe=Pu,_F=Gp,kEe=dF,wF=pF,xF="String Iterator",SEe=_F.set,TEe=_F.getterFor(xF);kEe(String,"String",function(n){SEe(this,{type:xF,string:CEe(n),index:0})},function(){var t=TEe(this),r=t.string,i=t.index,a;return i>=r.length?wF(void 0,!0):(a=xEe(r,i),t.index+=a.length,wF(a,!1))});var EEe=Mu,CF=function(n,t,r){for(var i in t)EEe(n,i,t[i],r);return n},kF={exports:{}},SF={},TF=nL,$Ee=qp,AEe=cL,OEe=Array,DEe=Math.max,MEe=function(n,t,r){for(var i=$Ee(n),a=TF(t,i),o=TF(r===void 0?i:r,i),s=OEe(DEe(o-a,0)),c=0;a<o;a++,c++)AEe(s,c,n[a]);return s.length=c,s},PEe=Xl,IEe=Vp,EF=gy.f,REe=MEe,$F=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],LEe=function(n){try{return EF(n)}catch{return REe($F)}};SF.f=function(t){return $F&&PEe(t)=="Window"?LEe(t):EF(IEe(t))};var FEe=Vn,NEe=FEe(function(){if(typeof ArrayBuffer=="function"){var n=new ArrayBuffer(8);Object.isExtensible(n)&&Object.defineProperty(n,"a",{value:8})}}),BEe=Vn,jEe=Ki,zEe=Xl,AF=NEe,Sy=Object.isExtensible,VEe=BEe(function(){Sy(1)}),OF=VEe||AF?function(t){return!jEe(t)||AF&&zEe(t)=="ArrayBuffer"?!1:Sy?Sy(t):!0}:Sy,UEe=Vn,HEe=!UEe(function(){return Object.isExtensible(Object.preventExtensions({}))}),WEe=Gs,GEe=qn,qEe=dy,YEe=Ki,ZC=mo,KEe=go.f,DF=gy,ZEe=SF,JC=OF,JEe=aC,XEe=HEe,MF=!1,qs=JEe("meta"),QEe=0,XC=function(n){KEe(n,qs,{value:{objectID:"O"+QEe++,weakData:{}}})},e9e=function(n,t){if(!YEe(n))return typeof n=="symbol"?n:(typeof n=="string"?"S":"P")+n;if(!ZC(n,qs)){if(!JC(n))return"F";if(!t)return"E";XC(n)}return n[qs].objectID},t9e=function(n,t){if(!ZC(n,qs)){if(!JC(n))return!0;if(!t)return!1;XC(n)}return n[qs].weakData},n9e=function(n){return XEe&&MF&&JC(n)&&!ZC(n,qs)&&XC(n),n},r9e=function(){i9e.enable=function(){},MF=!0;var n=DF.f,t=GEe([].splice),r={};r[qs]=1,n(r).length&&(DF.f=function(i){for(var a=n(i),o=0,s=a.length;o<s;o++)if(a[o]===qs){t(a,o,1);break}return a},WEe({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:ZEe.f}))},i9e=kF.exports={enable:r9e,fastKey:e9e,getWeakData:t9e,onFreeze:n9e};qEe[qs]=!0;var QC=kF.exports,a9e=vi,o9e=ag,s9e=a9e("iterator"),l9e=Array.prototype,c9e=function(n){return n!==void 0&&(o9e.Array===n||l9e[s9e]===n)},u9e=by,PF=eg,d9e=Au,p9e=ag,f9e=vi,h9e=f9e("iterator"),IF=function(n){if(!d9e(n))return PF(n,h9e)||PF(n,"@@iterator")||p9e[u9e(n)]},m9e=Fa,g9e=cy,v9e=ma,y9e=X3,b9e=IF,_9e=TypeError,w9e=function(n,t){var r=arguments.length<2?b9e(n):t;if(g9e(r))return v9e(m9e(r,n));throw _9e(y9e(n)+" is not iterable")},x9e=Fa,RF=ma,C9e=eg,k9e=function(n,t,r){var i,a;RF(n);try{if(i=C9e(n,"return"),!i){if(t==="throw")throw r;return r}i=x9e(i,n)}catch(o){a=!0,i=o}if(t==="throw")throw r;if(a)throw i;return RF(i),r},S9e=TL,T9e=Fa,E9e=ma,$9e=X3,A9e=c9e,O9e=qp,LF=Z3,D9e=w9e,M9e=IF,FF=k9e,P9e=TypeError,Ty=function(n,t){this.stopped=n,this.result=t},NF=Ty.prototype,BF=function(n,t,r){var i=r&&r.that,a=!!(r&&r.AS_ENTRIES),o=!!(r&&r.IS_RECORD),s=!!(r&&r.IS_ITERATOR),c=!!(r&&r.INTERRUPTED),l=S9e(t,i),u,d,p,f,h,m,g,y=function(w){return u&&FF(u,"normal",w),new Ty(!0,w)},b=function(w){return a?(E9e(w),c?l(w[0],w[1],y):l(w[0],w[1])):c?l(w,y):l(w)};if(o)u=n.iterator;else if(s)u=n;else{if(d=M9e(n),!d)throw P9e($9e(n)+" is not iterable");if(A9e(d)){for(p=0,f=O9e(n);f>p;p++)if(h=b(n[p]),h&&LF(NF,h))return h;return new Ty(!1)}u=D9e(n,d)}for(m=o?n.next:u.next;!(g=T9e(m,u)).done;){try{h=b(g.value)}catch(w){FF(u,"throw",w)}if(typeof h=="object"&&h&&LF(NF,h))return h}return new Ty(!1)},I9e=Z3,R9e=TypeError,jF=function(n,t){if(I9e(t,n))return n;throw R9e("Incorrect invocation")},L9e=vi,zF=L9e("iterator"),VF=!1;try{var F9e=0,UF={next:function(){return{done:!!F9e++}},return:function(){VF=!0}};UF[zF]=function(){return this},Array.from(UF,function(){throw 2})}catch{}var N9e=function(n,t){if(!t&&!VF)return!1;var r=!1;try{var i={};i[zF]=function(){return{next:function(){return{done:r=!0}}}},n(i)}catch{}return r},B9e=Tr,j9e=Ki,HF=rF,z9e=function(n,t,r){var i,a;return HF&&B9e(i=t.constructor)&&i!==r&&j9e(a=i.prototype)&&a!==r.prototype&&HF(n,a),n},V9e=Gs,U9e=Ur,H9e=qn,WF=sL,W9e=Mu,G9e=QC,q9e=BF,Y9e=jF,K9e=Tr,Z9e=Au,ek=Ki,tk=Vn,J9e=N9e,X9e=GC,Q9e=z9e,e$e=function(n,t,r){var i=n.indexOf("Map")!==-1,a=n.indexOf("Weak")!==-1,o=i?"set":"add",s=U9e[n],c=s&&s.prototype,l=s,u={},d=function(b){var w=H9e(c[b]);W9e(c,b,b=="add"?function(k){return w(this,k===0?0:k),this}:b=="delete"?function(S){return a&&!ek(S)?!1:w(this,S===0?0:S)}:b=="get"?function(k){return a&&!ek(k)?void 0:w(this,k===0?0:k)}:b=="has"?function(k){return a&&!ek(k)?!1:w(this,k===0?0:k)}:function(k,$){return w(this,k===0?0:k,$),this})},p=WF(n,!K9e(s)||!(a||c.forEach&&!tk(function(){new s().entries().next()})));if(p)l=r.getConstructor(t,n,i,o),G9e.enable();else if(WF(n,!0)){var f=new l,h=f[o](a?{}:-0,1)!=f,m=tk(function(){f.has(1)}),g=J9e(function(b){new s(b)}),y=!a&&tk(function(){for(var b=new s,w=5;w--;)b[o](w,w);return!b.has(-0)});g||(l=t(function(b,w){Y9e(b,c);var S=Q9e(new s,b,l);return Z9e(w)||q9e(w,S[o],{that:S,AS_ENTRIES:i}),S}),l.prototype=c,c.constructor=l),(m||y)&&(d("delete"),d("has"),i&&d("get")),(y||h)&&d(o),a&&c.clear&&delete c.clear}return u[n]=l,V9e({global:!0,constructor:!0,forced:l!=s},u),X9e(l,n),a||r.setStrong(l,n,i),l},t$e=qn,GF=CF,Ey=QC.getWeakData,n$e=jF,r$e=ma,i$e=Au,nk=Ki,a$e=BF,qF=OC,YF=mo,KF=Gp,o$e=KF.set,s$e=KF.getterFor,l$e=qF.find,c$e=qF.findIndex,u$e=t$e([].splice),d$e=0,$y=function(n){return n.frozen||(n.frozen=new ZF)},ZF=function(){this.entries=[]},rk=function(n,t){return l$e(n.entries,function(r){return r[0]===t})};ZF.prototype={get:function(n){var t=rk(this,n);if(t)return t[1]},has:function(n){return!!rk(this,n)},set:function(n,t){var r=rk(this,n);r?r[1]=t:this.entries.push([n,t])},delete:function(n){var t=c$e(this.entries,function(r){return r[0]===n});return~t&&u$e(this.entries,t,1),!!~t}};var p$e={getConstructor:function(n,t,r,i){var a=n(function(l,u){n$e(l,o),o$e(l,{type:t,id:d$e++,frozen:void 0}),i$e(u)||a$e(u,l[i],{that:l,AS_ENTRIES:r})}),o=a.prototype,s=s$e(t),c=function(l,u,d){var p=s(l),f=Ey(r$e(u),!0);return f===!0?$y(p).set(u,d):f[p.id]=d,l};return GF(o,{delete:function(l){var u=s(this);if(!nk(l))return!1;var d=Ey(l);return d===!0?$y(u).delete(l):d&&YF(d,u.id)&&delete d[u.id]},has:function(u){var d=s(this);if(!nk(u))return!1;var p=Ey(u);return p===!0?$y(d).has(u):p&&YF(p,d.id)}}),GF(o,r?{get:function(u){var d=s(this);if(nk(u)){var p=Ey(u);return p===!0?$y(d).get(u):p?p[d.id]:void 0}},set:function(u,d){return c(this,u,d)}}:{add:function(u){return c(this,u,!0)}}),a}},JF=Ur,Ay=qn,f$e=CF,h$e=QC,m$e=e$e,XF=p$e,Oy=Ki,Dy=OF,My=Gp.enforce,g$e=JR,v$e=!JF.ActiveXObject&&"ActiveXObject"in JF,lg,QF=function(n){return function(){return n(this,arguments.length?arguments[0]:void 0)}},y$e=m$e("WeakMap",QF,XF);if(g$e&&v$e){lg=XF.getConstructor(QF,"WeakMap",!0),h$e.enable();var cg=y$e.prototype,eN=Ay(cg.delete),Py=Ay(cg.has),tN=Ay(cg.get),nN=Ay(cg.set);f$e(cg,{delete:function(n){if(Oy(n)&&!Dy(n)){var t=My(this);return t.frozen||(t.frozen=new lg),eN(this,n)||t.frozen.delete(n)}return eN(this,n)},has:function(t){if(Oy(t)&&!Dy(t)){var r=My(this);return r.frozen||(r.frozen=new lg),Py(this,t)||r.frozen.has(t)}return Py(this,t)},get:function(t){if(Oy(t)&&!Dy(t)){var r=My(this);return r.frozen||(r.frozen=new lg),Py(this,t)?tN(this,t):r.frozen.get(t)}return tN(this,t)},set:function(t,r){if(Oy(t)&&!Dy(t)){var i=My(this);i.frozen||(i.frozen=new lg),Py(this,t)?nN(this,t,r):i.frozen.set(t,r)}else nN(this,t,r);return this}})}var rN=Ur,iN=xL,b$e=kL,ug=gEe,ik=Hp,aN=vi,ak=aN("iterator"),oN=aN("toStringTag"),ok=ug.values,sN=function(n,t){if(n){if(n[ak]!==ok)try{ik(n,ak,ok)}catch{n[ak]=ok}if(n[oN]||ik(n,oN,t),iN[t]){for(var r in ug)if(n[r]!==ug[r])try{ik(n,r,ug[r])}catch{n[r]=ug[r]}}}};for(var sk in iN)sN(rN[sk]&&rN[sk].prototype,sk);sN(b$e,"DOMTokenList");var lN="Expected a function",cN=0/0,_$e="[object Symbol]",w$e=/^\s+|\s+$/g,x$e=/^[-+]0x[0-9a-f]+$/i,C$e=/^0b[01]+$/i,k$e=/^0o[0-7]+$/i,S$e=parseInt,T$e=typeof Kt=="object"&&Kt&&Kt.Object===Object&&Kt,E$e=typeof self=="object"&&self&&self.Object===Object&&self,$$e=T$e||E$e||Function("return this")(),A$e=Object.prototype,O$e=A$e.toString,D$e=Math.max,M$e=Math.min,lk=function(){return $$e.Date.now()};function P$e(n,t,r){var i,a,o,s,c,l,u=0,d=!1,p=!1,f=!0;if(typeof n!="function")throw new TypeError(lN);t=uN(t)||0,Iy(r)&&(d=!!r.leading,p="maxWait"in r,o=p?D$e(uN(r.maxWait)||0,t):o,f="trailing"in r?!!r.trailing:f);function h(T){var A=i,E=a;return i=a=void 0,u=T,s=n.apply(E,A),s}function m(T){return u=T,c=setTimeout(b,t),d?h(T):s}function g(T){var A=T-l,E=T-u,I=t-A;return p?M$e(I,o-E):I}function y(T){var A=T-l,E=T-u;return l===void 0||A>=t||A<0||p&&E>=o}function b(){var T=lk();if(y(T))return w(T);c=setTimeout(b,g(T))}function w(T){return c=void 0,f&&i?h(T):(i=a=void 0,s)}function S(){c!==void 0&&clearTimeout(c),u=0,i=l=a=c=void 0}function k(){return c===void 0?s:w(lk())}function $(){var T=lk(),A=y(T);if(i=arguments,a=this,l=T,A){if(c===void 0)return m(l);if(p)return c=setTimeout(b,t),h(l)}return c===void 0&&(c=setTimeout(b,t)),s}return $.cancel=S,$.flush=k,$}function I$e(n,t,r){var i=!0,a=!0;if(typeof n!="function")throw new TypeError(lN);return Iy(r)&&(i="leading"in r?!!r.leading:i,a="trailing"in r?!!r.trailing:a),P$e(n,t,{leading:i,maxWait:t,trailing:a})}function Iy(n){var t=typeof n;return!!n&&(t=="object"||t=="function")}function R$e(n){return!!n&&typeof n=="object"}function L$e(n){return typeof n=="symbol"||R$e(n)&&O$e.call(n)==_$e}function uN(n){if(typeof n=="number")return n;if(L$e(n))return cN;if(Iy(n)){var t=typeof n.valueOf=="function"?n.valueOf():n;n=Iy(t)?t+"":t}if(typeof n!="string")return n===0?n:+n;n=n.replace(w$e,"");var r=C$e.test(n);return r||k$e.test(n)?S$e(n.slice(2),r?2:8):x$e.test(n)?cN:+n}var F$e=I$e;const dN=cn(F$e);var N$e="Expected a function",pN=0/0,B$e="[object Symbol]",j$e=/^\s+|\s+$/g,z$e=/^[-+]0x[0-9a-f]+$/i,V$e=/^0b[01]+$/i,U$e=/^0o[0-7]+$/i,H$e=parseInt,W$e=typeof Kt=="object"&&Kt&&Kt.Object===Object&&Kt,G$e=typeof self=="object"&&self&&self.Object===Object&&self,q$e=W$e||G$e||Function("return this")(),Y$e=Object.prototype,K$e=Y$e.toString,Z$e=Math.max,J$e=Math.min,ck=function(){return q$e.Date.now()};function X$e(n,t,r){var i,a,o,s,c,l,u=0,d=!1,p=!1,f=!0;if(typeof n!="function")throw new TypeError(N$e);t=fN(t)||0,uk(r)&&(d=!!r.leading,p="maxWait"in r,o=p?Z$e(fN(r.maxWait)||0,t):o,f="trailing"in r?!!r.trailing:f);function h(T){var A=i,E=a;return i=a=void 0,u=T,s=n.apply(E,A),s}function m(T){return u=T,c=setTimeout(b,t),d?h(T):s}function g(T){var A=T-l,E=T-u,I=t-A;return p?J$e(I,o-E):I}function y(T){var A=T-l,E=T-u;return l===void 0||A>=t||A<0||p&&E>=o}function b(){var T=ck();if(y(T))return w(T);c=setTimeout(b,g(T))}function w(T){return c=void 0,f&&i?h(T):(i=a=void 0,s)}function S(){c!==void 0&&clearTimeout(c),u=0,i=l=a=c=void 0}function k(){return c===void 0?s:w(ck())}function $(){var T=ck(),A=y(T);if(i=arguments,a=this,l=T,A){if(c===void 0)return m(l);if(p)return c=setTimeout(b,t),h(l)}return c===void 0&&(c=setTimeout(b,t)),s}return $.cancel=S,$.flush=k,$}function uk(n){var t=typeof n;return!!n&&(t=="object"||t=="function")}function Q$e(n){return!!n&&typeof n=="object"}function eAe(n){return typeof n=="symbol"||Q$e(n)&&K$e.call(n)==B$e}function fN(n){if(typeof n=="number")return n;if(eAe(n))return pN;if(uk(n)){var t=typeof n.valueOf=="function"?n.valueOf():n;n=uk(t)?t+"":t}if(typeof n!="string")return n===0?n:+n;n=n.replace(j$e,"");var r=V$e.test(n);return r||U$e.test(n)?H$e(n.slice(2),r?2:8):z$e.test(n)?pN:+n}var tAe=X$e;const hN=cn(tAe);var nAe="Expected a function",mN="__lodash_hash_undefined__",rAe="[object Function]",iAe="[object GeneratorFunction]",aAe=/[\\^$.*+?()[\]{}|]/g,oAe=/^\[object .+?Constructor\]$/,sAe=typeof Kt=="object"&&Kt&&Kt.Object===Object&&Kt,lAe=typeof self=="object"&&self&&self.Object===Object&&self,gN=sAe||lAe||Function("return this")();function cAe(n,t){return n==null?void 0:n[t]}function uAe(n){var t=!1;if(n!=null&&typeof n.toString!="function")try{t=!!(n+"")}catch{}return t}var dAe=Array.prototype,pAe=Function.prototype,vN=Object.prototype,dk=gN["__core-js_shared__"],yN=function(){var n=/[^.]+$/.exec(dk&&dk.keys&&dk.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""}(),bN=pAe.toString,pk=vN.hasOwnProperty,fAe=vN.toString,hAe=RegExp("^"+bN.call(pk).replace(aAe,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),mAe=dAe.splice,gAe=_N(gN,"Map"),dg=_N(Object,"create");function Ru(n){var t=-1,r=n?n.length:0;for(this.clear();++t<r;){var i=n[t];this.set(i[0],i[1])}}function vAe(){this.__data__=dg?dg(null):{}}function yAe(n){return this.has(n)&&delete this.__data__[n]}function bAe(n){var t=this.__data__;if(dg){var r=t[n];return r===mN?void 0:r}return pk.call(t,n)?t[n]:void 0}function _Ae(n){var t=this.__data__;return dg?t[n]!==void 0:pk.call(t,n)}function wAe(n,t){var r=this.__data__;return r[n]=dg&&t===void 0?mN:t,this}Ru.prototype.clear=vAe,Ru.prototype.delete=yAe,Ru.prototype.get=bAe,Ru.prototype.has=_Ae,Ru.prototype.set=wAe;function Kp(n){var t=-1,r=n?n.length:0;for(this.clear();++t<r;){var i=n[t];this.set(i[0],i[1])}}function xAe(){this.__data__=[]}function CAe(n){var t=this.__data__,r=Ry(t,n);if(r<0)return!1;var i=t.length-1;return r==i?t.pop():mAe.call(t,r,1),!0}function kAe(n){var t=this.__data__,r=Ry(t,n);return r<0?void 0:t[r][1]}function SAe(n){return Ry(this.__data__,n)>-1}function TAe(n,t){var r=this.__data__,i=Ry(r,n);return i<0?r.push([n,t]):r[i][1]=t,this}Kp.prototype.clear=xAe,Kp.prototype.delete=CAe,Kp.prototype.get=kAe,Kp.prototype.has=SAe,Kp.prototype.set=TAe;function Lu(n){var t=-1,r=n?n.length:0;for(this.clear();++t<r;){var i=n[t];this.set(i[0],i[1])}}function EAe(){this.__data__={hash:new Ru,map:new(gAe||Kp),string:new Ru}}function $Ae(n){return Ly(this,n).delete(n)}function AAe(n){return Ly(this,n).get(n)}function OAe(n){return Ly(this,n).has(n)}function DAe(n,t){return Ly(this,n).set(n,t),this}Lu.prototype.clear=EAe,Lu.prototype.delete=$Ae,Lu.prototype.get=AAe,Lu.prototype.has=OAe,Lu.prototype.set=DAe;function Ry(n,t){for(var r=n.length;r--;)if(LAe(n[r][0],t))return r;return-1}function MAe(n){if(!wN(n)||IAe(n))return!1;var t=FAe(n)||uAe(n)?hAe:oAe;return t.test(RAe(n))}function Ly(n,t){var r=n.__data__;return PAe(t)?r[typeof t=="string"?"string":"hash"]:r.map}function _N(n,t){var r=cAe(n,t);return MAe(r)?r:void 0}function PAe(n){var t=typeof n;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?n!=="__proto__":n===null}function IAe(n){return!!yN&&yN in n}function RAe(n){if(n!=null){try{return bN.call(n)}catch{}try{return n+""}catch{}}return""}function fk(n,t){if(typeof n!="function"||t&&typeof t!="function")throw new TypeError(nAe);var r=function(){var i=arguments,a=t?t.apply(this,i):i[0],o=r.cache;if(o.has(a))return o.get(a);var s=n.apply(this,i);return r.cache=o.set(a,s),s};return r.cache=new(fk.Cache||Lu),r}fk.Cache=Lu;function LAe(n,t){return n===t||n!==n&&t!==t}function FAe(n){var t=wN(n)?fAe.call(n):"";return t==rAe||t==iAe}function wN(n){var t=typeof n;return!!n&&(t=="object"||t=="function")}var NAe=fk;const BAe=cn(NAe);var Fu=[],jAe=function(){return Fu.some(function(n){return n.activeTargets.length>0})},zAe=function(){return Fu.some(function(n){return n.skippedTargets.length>0})},xN="ResizeObserver loop completed with undelivered notifications.",VAe=function(){var n;typeof ErrorEvent=="function"?n=new ErrorEvent("error",{message:xN}):(n=document.createEvent("Event"),n.initEvent("error",!1,!1),n.message=xN),window.dispatchEvent(n)},pg;(function(n){n.BORDER_BOX="border-box",n.CONTENT_BOX="content-box",n.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(pg||(pg={}));var Nu=function(n){return Object.freeze(n)},UAe=function(){function n(t,r){this.inlineSize=t,this.blockSize=r,Nu(this)}return n}(),CN=function(){function n(t,r,i,a){return this.x=t,this.y=r,this.width=i,this.height=a,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,Nu(this)}return n.prototype.toJSON=function(){var t=this,r=t.x,i=t.y,a=t.top,o=t.right,s=t.bottom,c=t.left,l=t.width,u=t.height;return{x:r,y:i,top:a,right:o,bottom:s,left:c,width:l,height:u}},n.fromRect=function(t){return new n(t.x,t.y,t.width,t.height)},n}(),hk=function(n){return n instanceof SVGElement&&"getBBox"in n},kN=function(n){if(hk(n)){var t=n.getBBox(),r=t.width,i=t.height;return!r&&!i}var a=n,o=a.offsetWidth,s=a.offsetHeight;return!(o||s||n.getClientRects().length)},SN=function(n){var t;if(n instanceof Element)return!0;var r=(t=n==null?void 0:n.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(r&&n instanceof r.Element)},HAe=function(n){switch(n.tagName){case"INPUT":if(n.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},fg=typeof window<"u"?window:{},Fy=new WeakMap,TN=/auto|scroll/,WAe=/^tb|vertical/,GAe=/msie|trident/i.test(fg.navigator&&fg.navigator.userAgent),ts=function(n){return parseFloat(n||"0")},Zp=function(n,t,r){return n===void 0&&(n=0),t===void 0&&(t=0),r===void 0&&(r=!1),new UAe((r?t:n)||0,(r?n:t)||0)},EN=Nu({devicePixelContentBoxSize:Zp(),borderBoxSize:Zp(),contentBoxSize:Zp(),contentRect:new CN(0,0,0,0)}),$N=function(n,t){if(t===void 0&&(t=!1),Fy.has(n)&&!t)return Fy.get(n);if(kN(n))return Fy.set(n,EN),EN;var r=getComputedStyle(n),i=hk(n)&&n.ownerSVGElement&&n.getBBox(),a=!GAe&&r.boxSizing==="border-box",o=WAe.test(r.writingMode||""),s=!i&&TN.test(r.overflowY||""),c=!i&&TN.test(r.overflowX||""),l=i?0:ts(r.paddingTop),u=i?0:ts(r.paddingRight),d=i?0:ts(r.paddingBottom),p=i?0:ts(r.paddingLeft),f=i?0:ts(r.borderTopWidth),h=i?0:ts(r.borderRightWidth),m=i?0:ts(r.borderBottomWidth),g=i?0:ts(r.borderLeftWidth),y=p+u,b=l+d,w=g+h,S=f+m,k=c?n.offsetHeight-S-n.clientHeight:0,$=s?n.offsetWidth-w-n.clientWidth:0,T=a?y+w:0,A=a?b+S:0,E=i?i.width:ts(r.width)-T-$,I=i?i.height:ts(r.height)-A-k,R=E+y+$+w,Y=I+b+k+S,L=Nu({devicePixelContentBoxSize:Zp(Math.round(E*devicePixelRatio),Math.round(I*devicePixelRatio),o),borderBoxSize:Zp(R,Y,o),contentBoxSize:Zp(E,I,o),contentRect:new CN(p,l,E,I)});return Fy.set(n,L),L},AN=function(n,t,r){var i=$N(n,r),a=i.borderBoxSize,o=i.contentBoxSize,s=i.devicePixelContentBoxSize;switch(t){case pg.DEVICE_PIXEL_CONTENT_BOX:return s;case pg.BORDER_BOX:return a;default:return o}},qAe=function(){function n(t){var r=$N(t);this.target=t,this.contentRect=r.contentRect,this.borderBoxSize=Nu([r.borderBoxSize]),this.contentBoxSize=Nu([r.contentBoxSize]),this.devicePixelContentBoxSize=Nu([r.devicePixelContentBoxSize])}return n}(),ON=function(n){if(kN(n))return 1/0;for(var t=0,r=n.parentNode;r;)t+=1,r=r.parentNode;return t},YAe=function(){var n=1/0,t=[];Fu.forEach(function(s){if(s.activeTargets.length!==0){var c=[];s.activeTargets.forEach(function(u){var d=new qAe(u.target),p=ON(u.target);c.push(d),u.lastReportedSize=AN(u.target,u.observedBox),p<n&&(n=p)}),t.push(function(){s.callback.call(s.observer,c,s.observer)}),s.activeTargets.splice(0,s.activeTargets.length)}});for(var r=0,i=t;r<i.length;r++){var a=i[r];a()}return n},DN=function(n){Fu.forEach(function(r){r.activeTargets.splice(0,r.activeTargets.length),r.skippedTargets.splice(0,r.skippedTargets.length),r.observationTargets.forEach(function(a){a.isActive()&&(ON(a.target)>n?r.activeTargets.push(a):r.skippedTargets.push(a))})})},KAe=function(){var n=0;for(DN(n);jAe();)n=YAe(),DN(n);return zAe()&&VAe(),n>0},mk,MN=[],ZAe=function(){return MN.splice(0).forEach(function(n){return n()})},JAe=function(n){if(!mk){var t=0,r=document.createTextNode(""),i={characterData:!0};new MutationObserver(function(){return ZAe()}).observe(r,i),mk=function(){r.textContent="".concat(t?t--:t++)}}MN.push(n),mk()},XAe=function(n){JAe(function(){requestAnimationFrame(n)})},Ny=0,QAe=function(){return!!Ny},eOe=250,tOe={attributes:!0,characterData:!0,childList:!0,subtree:!0},PN=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],IN=function(n){return n===void 0&&(n=0),Date.now()+n},gk=!1,nOe=function(){function n(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return n.prototype.run=function(t){var r=this;if(t===void 0&&(t=eOe),!gk){gk=!0;var i=IN(t);XAe(function(){var a=!1;try{a=KAe()}finally{if(gk=!1,t=i-IN(),!QAe())return;a?r.run(1e3):t>0?r.run(t):r.start()}})}},n.prototype.schedule=function(){this.stop(),this.run()},n.prototype.observe=function(){var t=this,r=function(){return t.observer&&t.observer.observe(document.body,tOe)};document.body?r():fg.addEventListener("DOMContentLoaded",r)},n.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),PN.forEach(function(r){return fg.addEventListener(r,t.listener,!0)}))},n.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),PN.forEach(function(r){return fg.removeEventListener(r,t.listener,!0)}),this.stopped=!0)},n}(),vk=new nOe,RN=function(n){!Ny&&n>0&&vk.start(),Ny+=n,!Ny&&vk.stop()},rOe=function(n){return!hk(n)&&!HAe(n)&&getComputedStyle(n).display==="inline"},iOe=function(){function n(t,r){this.target=t,this.observedBox=r||pg.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return n.prototype.isActive=function(){var t=AN(this.target,this.observedBox,!0);return rOe(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},n}(),aOe=function(){function n(t,r){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=r}return n}(),By=new WeakMap,LN=function(n,t){for(var r=0;r<n.length;r+=1)if(n[r].target===t)return r;return-1},jy=function(){function n(){}return n.connect=function(t,r){var i=new aOe(t,r);By.set(t,i)},n.observe=function(t,r,i){var a=By.get(t),o=a.observationTargets.length===0;LN(a.observationTargets,r)<0&&(o&&Fu.push(a),a.observationTargets.push(new iOe(r,i&&i.box)),RN(1),vk.schedule())},n.unobserve=function(t,r){var i=By.get(t),a=LN(i.observationTargets,r),o=i.observationTargets.length===1;a>=0&&(o&&Fu.splice(Fu.indexOf(i),1),i.observationTargets.splice(a,1),RN(-1))},n.disconnect=function(t){var r=this,i=By.get(t);i.observationTargets.slice().forEach(function(a){return r.unobserve(t,a.target)}),i.activeTargets.splice(0,i.activeTargets.length)},n}(),oOe=function(){function n(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");jy.connect(this,t)}return n.prototype.observe=function(t,r){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!SN(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");jy.observe(this,t,r)},n.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!SN(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");jy.unobserve(this,t)},n.prototype.disconnect=function(){jy.disconnect(this)},n.toString=function(){return"function ResizeObserver () { [polyfill code] }"},n}(),sOe=cy,lOe=Ou,cOe=oy,uOe=qp,dOe=TypeError,FN=function(n){return function(t,r,i,a){sOe(r);var o=lOe(t),s=cOe(o),c=uOe(o),l=n?c-1:0,u=n?-1:1;if(i<2)for(;;){if(l in s){a=s[l],l+=u;break}if(l+=u,n?l<0:c<=l)throw dOe("Reduce of empty array with no initial value")}for(;n?l>=0:c>l;l+=u)l in s&&(a=r(a,s[l],l,o));return a}},pOe={left:FN(!1),right:FN(!0)},fOe=Xl,hOe=Ur,mOe=fOe(hOe.process)=="process",gOe=Gs,vOe=pOe.left,yOe=$L,NN=ly,bOe=mOe,_Oe=yOe("reduce"),wOe=!bOe&&NN>79&&NN<83;gOe({target:"Array",proto:!0,forced:!_Oe||wOe},{reduce:function(t){var r=arguments.length;return vOe(this,t,r,r>1?arguments[1]:void 0)}});var xOe=ma,COe=function(){var n=xOe(this),t="";return n.hasIndices&&(t+="d"),n.global&&(t+="g"),n.ignoreCase&&(t+="i"),n.multiline&&(t+="m"),n.dotAll&&(t+="s"),n.unicode&&(t+="u"),n.unicodeSets&&(t+="v"),n.sticky&&(t+="y"),t},yk=Vn,kOe=Ur,bk=kOe.RegExp,_k=yk(function(){var n=bk("a","y");return n.lastIndex=2,n.exec("abcd")!=null}),SOe=_k||yk(function(){return!bk("a","y").sticky}),TOe=_k||yk(function(){var n=bk("^r","gy");return n.lastIndex=2,n.exec("str")!=null}),EOe={BROKEN_CARET:TOe,MISSED_STICKY:SOe,UNSUPPORTED_Y:_k},$Oe=Vn,AOe=Ur,OOe=AOe.RegExp,DOe=$Oe(function(){var n=OOe(".","s");return!(n.dotAll&&n.exec(`
|
|
455
455
|
`)&&n.flags==="s")}),MOe=Vn,POe=Ur,IOe=POe.RegExp,ROe=MOe(function(){var n=IOe("(?<a>b)","g");return n.exec("b").groups.a!=="b"||"b".replace(n,"$<a>c")!=="bc"}),Jp=Fa,zy=qn,LOe=Pu,FOe=COe,NOe=EOe,BOe=iC,jOe=BC,zOe=Gp.get,VOe=DOe,UOe=ROe,HOe=BOe("native-string-replace",String.prototype.replace),Vy=RegExp.prototype.exec,wk=Vy,WOe=zy("".charAt),GOe=zy("".indexOf),qOe=zy("".replace),xk=zy("".slice),Ck=function(){var n=/a/,t=/b*/g;return Jp(Vy,n,"a"),Jp(Vy,t,"a"),n.lastIndex!==0||t.lastIndex!==0}(),BN=NOe.BROKEN_CARET,kk=/()??/.exec("")[1]!==void 0,YOe=Ck||kk||BN||VOe||UOe;YOe&&(wk=function(t){var r=this,i=zOe(r),a=LOe(t),o=i.raw,s,c,l,u,d,p,f;if(o)return o.lastIndex=r.lastIndex,s=Jp(wk,o,a),r.lastIndex=o.lastIndex,s;var h=i.groups,m=BN&&r.sticky,g=Jp(FOe,r),y=r.source,b=0,w=a;if(m&&(g=qOe(g,"y",""),GOe(g,"g")===-1&&(g+="g"),w=xk(a,r.lastIndex),r.lastIndex>0&&(!r.multiline||r.multiline&&WOe(a,r.lastIndex-1)!==`
|
|
@@ -2856,7 +2856,7 @@ Minimum version required to store current data is: `+q+`.
|
|
|
2856
2856
|
...(!canSendType('email', client) && {
|
|
2857
2857
|
content: $t('_common:missing', { thing: $t('_common:email') })
|
|
2858
2858
|
})
|
|
2859
|
-
}`}],staticClass:"font-medium",attrs:{value:t.isTypeActive("email",i),size:"tiny",disabled:!t.canSendType("email",i)},on:{input:function(o){return t.setDeliveryMethod("email",a)}}},[t._v(" "+t._s(t.$t("_common:email").capitalize())+" ")])],1)])])}),r("CButton",{staticClass:"font-semibold mt-8",attrs:{type:"secondary",size:"small",taller:"",icon:"send",wide:""},on:{click:t.submit}},[t._v(" "+t._s(t.$t("_common:send",{thing:t.$t("_common:reminder")}))+" ")])],2)},dft=[],pft=he(cft,uft,dft,!1,null,null,null,null);const fft=pft.exports,hft={props:{document:{type:Object,required:!0}},components:{DocumentSendReminderModal:fft}};var mft=function(){var t=this,r=t._self._c;return r("DocumentSendReminderModal",{attrs:{document:t.document},on:{close:function(i){return t.$router.push("/")}}})},gft=[],vft=he(hft,mft,gft,!1,null,null,null,null);const yft=vft.exports,bft=Object.freeze(Object.defineProperty({__proto__:null,default:yft},Symbol.toStringTag,{value:"Module"})),VOt="",PY={new:{statusClass:"draft",icon:"statusDraft"},draft:{statusClass:"draft",icon:"statusDraft"},scheduled:{statusClass:"scheduled",icon:"statusScheduled"},sent:{statusClass:"sent",icon:"statusSent"},denied:{statusClass:"denied",icon:"statusDenied"},accepted:{statusClass:"accepted",icon:"statusAccepted"},signed:{statusClass:"accepted",icon:"statusAccepted"},semiSigned:{statusClass:"accepted",icon:"statusSemiSigned"},expired:{statusClass:"expired",icon:"statusExpired"},voided:{statusClass:"voided",icon:"statusVoided"},active:{statusClass:"active",icon:"statusActive"},completed:{statusClass:"completed",icon:"statusCompleted"},archived:{statusClass:"archived",icon:"statusArchive"}},_ft={props:{status:{type:String,default:""},split:{type:String,default:""}},computed:{text(){return this.status?Be.t(`_common:status.${this.status}`):""},className(){const{statusClass:n=""}=PY[this.status]||{};return n},icon(){return Ce(PY,`${this.status}.icon`)}}};var wft=function(){var t=this,r=t._self._c;return r("div",{staticClass:"inline-flex items-center h-6 pl-1 pr-2 text-xs font-medium leading-none rounded-full c-badge_status",class:t.className},[t.icon?r("BaseIcon",{staticClass:"mr-1 status-icon",attrs:{type:t.icon,size:"16"}}):t._e(),r("span",[t._v(t._s(t.text))])],1)},xft=[],Cft=he(_ft,wft,xft,!1,null,null,null,null);const kft=Cft.exports,Sft={name:"DynamicLink",props:{template:{type:String,required:!0}},computed:{transformed(){return{template:this.template}}}};var Tft=function(){var t=this,r=t._self._c;return r(t.transformed,{tag:"component"})},Eft=[],$ft=he(Sft,Tft,Eft,!1,null,null,null,null);const Aft={name:"EventItem",components:{DynamicLink:$ft.exports},props:{title:{type:String,default:""},template:{type:String,default:""},content:{type:[String,Array],default:""},createdAt:{type:String,default:""},icon:{type:String,default:"square"},compact:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},color:{type:String,default:"gray",validator:n=>["blue","teal","orange","green","red","purple","gray","primary"].indexOf(n)!==-1},isFuture:{type:Boolean,default:!1},size:{type:String,default:""}},computed:{date(){return Hl(vu(this.createdAt))?this.$formatDate(this.createdAt,"Pp"):null},dayOfMonth(){return Hl(vu(this.createdAt))?this.$formatDate(this.createdAt,"d"):null},month(){return Hl(vu(this.createdAt))?this.$formatDate(this.createdAt,"MMM"):null},iconClasses(){const n={blue:"text-blue-600 bg-blue-50",teal:"text-cyan-600 bg-cyan-50",orange:"text-orange-600 bg-orange-50",green:"text-green-600 bg-green-50",red:"text-red-600 bg-red-50",purple:"text-purple-600 bg-purple-50",gray:"text-gray-500 bg-gray-100",primary:"text-primary-500 bg-primary-50"};return this.isFuture?"bg-purple-100 text-purple-500":n[this.color]||n.gray},titleSize(){return this.size==="large"?"text-base":"text-sm"},textSize(){return this.size==="large"?"text-[15px]":"text-[13px]"},dateSize(){return this.size==="large"?"text-sm":"text-xs"}}};var Oft=function(){var t=this,r=t._self._c;return r("div",{staticClass:"flex flex-nowrap relative text-primary-500 cursor-default pb-5 ml-4 event before:content-[''] before:absolute before:w-px before:h-full before:bg-gray-300 before:-left-px before:top-4 last:before:hidden"},[r("div",{staticClass:"m-0 h-[23px] relative",staticStyle:{"--bg":"#fff"}},[r("div",{staticClass:"rounded-full absolute left-1/2 top-1/2 z-[1] w-7 h-7 flex items-center justify-center border-none bg-gray-100",class:t.iconClasses,staticStyle:{transform:"translate(-50%, calc(-50% + 8px))","box-shadow":"0 0 0 2px var(--bg)"}},[t.loading?t._e():r("BaseIcon",{attrs:{type:t.icon,size:"14"}})],1)]),r("div",{staticClass:"ml-7 min-w-0 flex-grow flex flex-col pt-1"},[t.loading?[r("CSkeleton",{staticClass:"max-w-md text-gray-900 font-medium",class:t.titleSize,attrs:{width:"80%"}}),r("CSkeleton",{staticClass:"text-gray-600",class:t.textSize,attrs:{width:"40%"}}),r("CSkeleton",{staticClass:"text-center text-gray-500 text-xs inline-flex pt-0.5",class:t.dateSize,attrs:{hidden:""}})]:t._e(),r("div",{staticClass:"max-w-md font-medium",class:[t.isFuture?"text-gray-500":"text-gray-700",t.titleSize]},[t.template?r("DynamicLink",{attrs:{template:t.template}}):[t._v(t._s(t.title))]],2),t.content?r("div",{class:[t.isFuture?"text-gray-400":"text-gray-600",t.textSize]},[r("div",{domProps:{innerHTML:t._s(t.content)}})]):t._e(),r("div",{staticClass:"text-center text-gray-500 inline-flex pt-1",class:t.dateSize},[r("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.date,expression:"date"}]},[t._v(t._s(t.dayOfMonth)+" "+t._s(t.month))])])],2)])},Dft=[],Mft=he(Aft,Oft,Dft,!1,null,null,null,null);const Pft=Mft.exports,Ift={name:"DocumentTimeline",i18nOptions:{namespaces:"documentTimeline",messages:{sv:{clientName:"Kunden",byName:"Av {{- name}}",withBankId:"med BankID",propertyDesignation:"Begäran om fastighetsbeteckning",viewed:"Granskat",viewedContent:"{{- name}} har visat dokumentet",statusChangedAccepted:"Dokumentet har blivit signerat",statusChangedDenied:"Dokumentet har blivit nekat",requestChange:"Markerades manuellt som",mailOpened:"Mail visat",mailOpenedContent:"{{email}} visat",mailDropped:"E-post kunde inte skickas",smsDropped:"SMS kunde inte skickas",expired:"Dokumentet har förfallit",expiredContent:"Giltighetstiden har passerats",toEmail:"Till: {{email}}"},en:{clientName:"Client",byName:"By {{- name}}",withBankId:"with BankID",propertyDesignation:"Request for property designation",viewed:"Viewed",viewedContent:"{{- name}} has viewed the document",statusChangedAccepted:"The document has been signed",statusChangedDenied:"The document has been declined",requestChange:"Manually marked as",mailOpened:"Email opened",mailOpenedContent:"{{email}} viewed",mailDropped:"Could not send email",smsDropped:"Could not send SMS",expired:"Expired",expiredContent:"The expiration date has passed",toEmail:"To: {{email}}"}}},components:{EventItem:Pft},props:{document:{type:Object,required:!0},colors:{type:Object,default:()=>({})},size:{type:String,default:""}},computed:{...Ut({userById:"companyUsers/byId"}),events(){var i,a;const n=[this.formatEvent({code:"created",createdAt:(i=this.document)==null?void 0:i.createdAt})],{events:t,scheduledFirstDelivery:r}=this.document||{};if((r==null?void 0:r.status)==="active"){const o=r.deliveryTypes.join(` ${this.$t("_common:and")} `);n.push({title:this.$t("_common:scheduledDelivery"),content:`${this.$t("_common:via")} ${o}, ${this.$formatDate(r.sendAt)}`,isFuture:!0,icon:"calendar",color:((a=this.colors)==null?void 0:a.scheduledDelivery)||"primary"})}return t==null||t.forEach(o=>n.push(this.formatEvent(o))),n}},methods:{formatEvent({code:n,data:t,createdAt:r,children:i=[]}){var g;const{client:a={},clients:o,email:s,status:c,counter:l,sendSource:u,companyUserId:d}=t||{},p=l||i.length+1,f=a.name,h={created:()=>({title:this.$t("_common:created"),createdAt:r,icon:"folder",color:"primary"}),viewed:()=>({title:this.$t("viewed"),content:(f?this.$t("viewedContent",{name:f}):"")+(p?` ${this.$tc("_common:times",{count:p})}`:""),createdAt:r,icon:"eye",color:"primary"}),accepted:()=>{var b;const y={title:this.$t("_common:status.signed"),content:f?this.$t("byName",{name:f}):"",createdAt:r,icon:"check",color:"primary"};return y.content&&((b=a.answerMethod)==null?void 0:b.accept)==="bankId"&&(y.content+=` ${this.$t("withBankId")}`),y},denied:()=>({title:this.$t("_common:status.denied"),content:f?this.$t("byName",{name:f}):"",createdAt:r,icon:"x",color:"primary"}),sent:()=>{let y=this.$t("_common:sent");return["reminder","propertyDesignation"].includes(u)&&(y=this.$t("_common:sentThing",{thing:u==="reminder"?this.$t("_common:reminder"):this.$t("propertyDesignation")})),{title:y,content:o==null?void 0:o.map(b=>["email","cellphone"].filter(w=>!!b[w]).map(w=>b[w]).join(` ${this.$t("_common:and")} `)).reduce((b,w)=>b?`${b}<div>${w}</div>`:`${this.$t("_common:to")}: ${w}`.capitalize(),""),createdAt:r,icon:u==="reminder"?"bell":"send",color:"primary"}},statusChanged:()=>["accepted","denied"].includes(c)?{title:c==="accepted"?this.$t("statusChangedAccepted"):this.$t("statusChangedDenied"),createdAt:r,icon:c==="accepted"?"check":"x",color:c==="accepted"?"green":"red"}:null,requestChange:()=>{var b;const y=((b=this.userById(d))==null?void 0:b.fullName)||"";return{title:`${this.$t("requestChange")} ${this.$t(`_common:status.${c}`)}`,content:y&&this.$t("byName",{name:y}),createdAt:r,icon:"tool",color:"primary"}},mailDelivered:()=>({title:this.$t("_common:sentThing",{thing:this.$t("_common:email").capitalize()}),content:s?`${this.$t("_common:to")}: ${s}`.capitalize():"",createdAt:r,icon:"inbox",color:"primary"}),mailOpened:()=>({title:this.$t("mailOpened"),content:`${this.$t("mailOpenedContent",{email:s})} ${p?this.$tc("_common:times",{count:p}):""}`,createdAt:r,icon:"email",color:"primary"}),mailDropped:()=>({title:this.$t("mailDropped"),content:s?this.$t("toEmail",{email:s}):null,createdAt:r,icon:"alert-triangle",color:"orange"}),smsDropped:()=>({title:this.$t("smsDropped"),content:t?`${this.$t("_common:to")}: ${t}`.capitalize():"",createdAt:r,icon:"alert-triangle",color:"orange"}),expired:()=>({title:this.$t("expired"),content:this.$t("expiredContent"),createdAt:r,icon:"moon",color:"gray"})},m=(g=this.colors)==null?void 0:g[n];return{...h[n](),...m&&{color:m}}}}};var Rft=function(){var t=this,r=t._self._c;return r("div",[t._t("header"),t._l(t.events,function(i,a){return r("EventItem",{key:a,attrs:{title:i.title,content:i.content,createdAt:i.createdAt,icon:i.icon,color:i.color,"is-future":i.isFuture,size:t.size}})})],2)},Lft=[],Fft=he(Ift,Rft,Lft,!1,null,null,null,null);const Nft=Fft.exports,Bft={name:"DocTimeline",components:{StatusBadge:kft,DocumentTimeline:Nft},props:{document:{type:Object,required:!0},showHeader:{type:Boolean,default:!0},viewType:{type:String,default:"modal"}}};var jft=function(){var t=this,r=t._self._c;return r("div",{class:{"p-8":t.viewType!=="mount"}},[r("DocumentTimeline",{attrs:{document:t.document,size:"large"}},[t.showHeader?r("div",{staticClass:"border-b mb-4 pb-4",attrs:{slot:"header"},slot:"header"},[r("div",{staticClass:"mb-2"},[r("div",{staticClass:"text-xs text-gray-600",domProps:{textContent:t._s(t.$t("_common:document").capitalize())}}),r("div",{staticClass:"font-semibold text-lg"},[t._v(t._s(t.document.name))])]),r("div",{staticClass:"inline-flex items-center -ml-2"},[r("div",{staticClass:"text-xs text-gray-600 mr-1.5 py-1 pl-2",domProps:{textContent:t._s(t.$t("_common:status.status"))}}),r("StatusBadge",{attrs:{status:t.document.status}})],1)]):t._e()])],1)},zft=[],Vft=he(Bft,jft,zft,!1,null,null,null,null);const Uft=Vft.exports,Hft=Object.freeze(Object.defineProperty({__proto__:null,default:Uft},Symbol.toStringTag,{value:"Module"})),Wft={name:"DocumentReceipt",i18nOptions:{namespaces:"documentReceipt",messages:{sv:{title:"Verifikat på signering",waitingForSign:"Väntar på signatur",signMethod:"Signeringsmetod",remaining:"{{count}} st signaturer kvarstår innan dokumentet är helt signerat.",confirmChangeMessage:"Vill du verkligen byta signeringsmetod för {{- name}}?",bankIdHint:"Identifiering och signering säkerställd med BankID."},en:{title:"Signature verification",waitingForSign:"Waiting for signature",signMethod:"Sign method",remaining:"{{count}} signatures are remaining before the document is completely signed.",confirmChangeMessage:"Do you really want to change sign method for {{- name}}?",bankIdHint:"Identity and signature confirmed with BankID"}}},props:{document:{type:Object,required:!0},allowSignMethodUpdate:{type:Boolean,default:!0}},computed:{...Ut({feature:"application/feature"}),signees(){const{senderClient:n,clients:t}=this.document;return[...n?[n]:[],...(t||[]).map((i,a)=>({...i,index:a}))].filter(i=>{var a;return["signee","approver"].includes(i.documentRole)||((a=i.answer)==null?void 0:a.didAccept)}).map(({name:i="",companyName:a,email:o,socialNo:s=null,answerMethod:c,answer:l,documentRole:u,index:d})=>({name:i||a||o,socialNo:s,method:(c==null?void 0:c.accept)||"",documentRole:u,...l,index:d}))},waitingFor(){return this.document.recipients.reduce((n,t)=>{var r;return t.answer||!["signee","approver"].includes(t.documentRole)||((r=t.answerMethod)==null?void 0:r.accept)==="inPerson"?n:[...n,t]},[])},documentName(){return this.document.name||""},sentByName(){var n,t;return((t=(n=this.document.sender)==null?void 0:n.user)==null?void 0:t.name)||""}},methods:{...xn({showMessage:We.SHOW_MESSAGE,updateDocument:We.UPDATE_DOCUMENT2}),getIconType(n){return n==="signee"?"pen-tool":n==="recipient"?"eye":n==="approver"?"check":"shield"},getBrowserString({browser:n,os:t,device:r}){return[n==null?void 0:n.name,t==null?void 0:t.name,r==null?void 0:r.model].filter(i=>!!i).join(", ")},onUpdate(n,t){this.showMessage({displayType:"dialog",type:"secondary",title:this.$t("_common:change",{thing:this.$t("_common:signMethod.title").toLowerCase()}),message:this.$t("confirmChangeMessage",{name:n.name}),actions:{cancel:{text:this.$t("_common:cancel"),callback:"cancel"},submit:{text:this.$t("actions:updateDocumentDialog.submit"),callback:()=>this.updateSignMethod(n.index,t)}}})},async updateSignMethod(n,t){const{id:r}=this.document||{},i={[`clients.${n}.answerMethod.accept`]:t};await this.updateDocument({id:r,body:i,params:{type:"paths"}})}}};var Gft=function(){var t=this,r=t._self._c;return r("div",{staticClass:"rounded-lg text-gray-600 pt-4 px-1 pb-1 bg-gray-100 border border-gray-200"},[r("div",{staticClass:"mb-1 relative leading-5"},[r("div",{staticClass:"pl-4 pb-1"},[r("div",{staticClass:"font-medium text-black"},[t._v(t._s(t.$t("title")))]),r("div",{staticClass:"data-label"},[t._v(t._s(t.documentName))]),r("div",{staticClass:"grid grid-cols-3 gap-2 pb-1 pt-4",staticStyle:{"grid-template-columns":"repeat(auto-fit, minmax(200px, 1fr))"}},[t._l([[t.$t("_common:sentByName"),t.sentByName],[t.$t("_components:status.sent"),t.$formatDate(t.document.sentAt,"Pp")],[t.$t("_components:replyBy"),t.document.status==="sent"&&t.$formatDate(t.document.expiresAt)],[t.$t("_components:status.accepted"),t.$formatDate(t.document.acceptedAt,"Pp")]],function([i,a],o){return[a?r("div",{key:o},[r("div",{staticClass:"text-gray-900 text-xs",domProps:{textContent:t._s(i)}}),r("div",{staticClass:"text-gray-600 mr-1.5",domProps:{textContent:t._s(a)}})]):t._e()]})],2)]),t.waitingFor.length?r("div",{staticClass:"mt-2 inline-flex items-center text-xs font-medium bg-orange-50 border border-orange-200/90 px-1 py-0.5 rounded-full ml-3 text-black/80"},[r("BaseIcon",{staticClass:"text-orange-500/80",attrs:{type:"info",size:"14"}}),r("div",{staticClass:"px-1.5"},[t._v(" "+t._s(t.$t("remaining",{count:t.waitingFor.length}))+" ")])],1):t._e(),r("BaseIcon",{staticClass:"absolute top-1 right-5 text-gray-500",attrs:{type:"lock",size:"18"}})],1),r("div",{staticClass:"flex flex-col gap-2 p-2"},t._l(t.signees,function(i,a){var o,s;return r("div",{key:a,staticClass:"bg-white relative text-gray-700 border border-gray-200 rounded-md"},[r("div",{staticClass:"px-4 py-3"},[i.didAccept&&i.method==="bankId"?r("BaseIcon",{staticClass:"absolute top-3 right-4",attrs:{type:"bankIdColor",size:"22"}}):i.didAccept?r("BaseIcon",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.$t(`_common:documentRole.${i.documentRole}.label`),expression:"$t(`_common:documentRole.${signee.documentRole}.label`)"}],staticClass:"lock-icon absolute right-6 top-4 opacity-70",attrs:{size:18,type:t.getIconType(i.documentRole)}}):t._e(),i.didAccept===!1?r("div",{staticClass:"absolute right-3 top-3 bg-red-200 border border-red-400/50 rounded-full text-xs py-0.5 px-2 inline-flex font-medium text-red-700"},[t._v(" "+t._s(t.$t("_common:denied").capitalize())+" ")]):!i.didAccept&&i.method!=="inPerson"?r("div",{staticClass:"absolute right-3 top-3 bg-orange-50 border border-orange-200/70 rounded-full text-xs py-0.5 px-2 inline-flex font-medium text-black/80"},[t._v(" "+t._s(t.$t("waitingForSign"))+" ")]):t._e(),r("div",{staticClass:"font-medium text-[15px] text-black pb-1"},[t._v(" "+t._s(((o=i.response)==null?void 0:o.name)||i.name)+" ")]),r("div",{staticClass:"grid grid-cols-3 gap-2 py-1",staticStyle:{"grid-template-columns":"repeat(auto-fit, minmax(190px, 1fr))"}},[t._l([[t.$t("_common:socialNo").capitalize(),i.socialNo],[t.$t("signMethod"),t.$t(`_common:signMethod.${i.method}`),"signMethod"],[`${t.$t("_common:date").capitalize()} & ${t.$t("_common:time.time")}`,t.$formatDate(i.didAnswerAt,"Pp")],["IP-"+t.$t("_common:address"),i.ip],[`${t.$t("_common:browser")}, OS & ${t.$t("_common:device")}`,t.getBrowserString(i)]],function([c,l,u],d){return[l?r("div",{key:d,staticClass:"text-[13px]"},[r("div",{staticClass:"text-gray-900",domProps:{textContent:t._s(c)}}),r("div",{staticClass:"flex items-center"},[r("div",{staticClass:"text-gray-500 mr-1.5",domProps:{textContent:t._s(l)}}),u==="signMethod"&&i.method&&t.allowSignMethodUpdate&&t.document.status!=="accepted"&&i.didAccept===void 0?r("CDropdown",{attrs:{"append-to-body":!0,"menu-styling":{width:"180px"}}},[r("div",{staticClass:"underline text-primary-500 font-medium text-xs",attrs:{slot:"trigger"},domProps:{textContent:t._s(t.$t("_common:change"))},slot:"trigger"}),t._l([...t.feature("bankId")?["bankId"]:[],"signature","inPerson"],function(p){return r("CDropdownItem",{key:p,attrs:{"icon-right":i.method===p?"check":""},on:{click:function(f){i.method!==p&&t.onUpdate(i,p)}}},[t._v(" "+t._s(t.$t(`_common:signMethod.${p}`))+" ")])})],2):t._e()],1)]):t._e()]})],2)],1),i.signatureDataURL?r("div",{staticClass:"h-20 mx-4 py-6 border-t border-gray-100"},[r("img",{staticClass:"h-full",attrs:{src:i.signatureDataURL}})]):i.didAccept&&i.method==="bankId"?r("div",{staticClass:"bg-gray-300 mx-4 mb-4 text-white/90 flex items-center p-1.5 rounded-md",staticStyle:{border:"1px solid #35677e"},style:"background: linear-gradient(45deg,hsl(200deg 35% 17%),hsl(199deg 25% 30%));"},[r("div",{staticClass:"rounded-md w-9 h-9 flex items-center justify-center mr-2 ml-0.5 bg-[#183e4f] border border-[#275369]"},[r("BaseIcon",{attrs:{type:"bankId",size:"22"}})],1),r("div",[r("div",{staticClass:"text-xs font-medium",domProps:{textContent:t._s(t.$t("bankIdHint"))}}),r("div",{staticClass:"text-xs opacity-70"},[t._v(" "+t._s(((s=i.response)==null?void 0:s.name)||i.name)+" · "+t._s(i.socialNo)+" ")])])]):t._e()])}),0)])},qft=[],Yft=he(Wft,Gft,qft,!1,null,null,null,null);const Kft={name:"DocReceipt",components:{DocumentReceipt:Yft.exports},props:{document:{type:Object,required:!0}}};var Zft=function(){var t=this,r=t._self._c;return r("div",[r("DocumentReceipt",{attrs:{document:t.document,"allow-sign-method-update":!1}})],1)},Jft=[],Xft=he(Kft,Zft,Jft,!1,null,null,null,null);const Qft=Xft.exports,eht=Object.freeze(Object.defineProperty({__proto__:null,default:Qft},Symbol.toStringTag,{value:"Module"})),tht={name:"DocLinks",components:{ClientLinks:_Y},props:{document:{type:Object,required:!0},closeFunc:{type:Function,default:null}},methods:{close(){this.closeFunc&&this.closeFunc()}}};var nht=function(){var t=this,r=t._self._c;return r("div",{staticClass:"h-full w-full overflow-auto"},[r("ClientLinks",{attrs:{id:t.document.id},on:{close:t.close}})],1)},rht=[],iht=he(tht,nht,rht,!1,null,null,null,null);const aht=iht.exports,oht=Object.freeze(Object.defineProperty({__proto__:null,default:aht},Symbol.toStringTag,{value:"Module"})),IY=({documentKey:n="document"}={})=>({mixins:[br],inject:{formValidation:{default:null}},methods:{isValid(){const{isFormValid:t,scrollToInvalidInput:r}=this.formValidation||this;return!t||!r||t()?!0:r({offset:120})},isAnswerModalOpen(){const t=this.$modal.getOpenInstances();return t&&t.length&&t.some(r=>{var i;return((i=r.modalAttrs)==null?void 0:i.name)==="AnswerModal"})},onAnswer(t="accept",r={}){if(this.isAnswerModalOpen())return;const i=Ce(this,n);if(!i)return;const a=t==="decline"?!0:this.isValid();if(!i.isPreview&&!a)return;const o=this.mq==="sm"?"100%":"auto",s=()=>Promise.resolve().then(()=>Ddt);this.$modal.show(s,{mode:t,_document:i,fullScreen:o==="100%",calcHeight:!!r.calcHeight},{name:"AnswerModal",adaptive:!0,height:"auto",width:"90%",maxWidth:420,classes:"overflow-visible",transition:"modal-soft",clickToClose:!1})}}}),sht=n=>{var t;return(t=window==null?void 0:window.parent)==null?void 0:t.postMessage(n,"*")},RY=n=>typeof n=="object"&&"event"in n;class lht{constructor(){this.observers={},this.registered=!0,window.addEventListener("message",this._onMessage.bind(this))}_onMessage(t){if(t.source===window.parent&&RY(t==null?void 0:t.data)){const{event:r,data:i}=t.data;this.observers[r]&&this.observers[r].forEach(a=>a(i))}}on(t,r){this.registered||window.addEventListener("message",this._onMessage.bind(this)),this.observers[t]=this.observers[t]||[],this.observers[t].push(r)}off(t,r){if(this.observers[t]){if(!r){delete this.observers[t];return}this.observers[t]=this.observers[t].filter(i=>i!==r)}}emit(t){if(!RY(t))throw new Error("Invalid message, must be an object including an event property");sht(t)}destroy(){window.removeEventListener("message",this._onMessage.bind(this)),this.registered=!1}}const LY=new lht,cht={name:"DocumentVoided",props:{document:{type:Object,required:!0}}};var uht=function(){var t=this,r=t._self._c;return r("div",{staticClass:"grid h-full text-center place-items-center"},[r("div",{staticClass:"py-12"},[r("BaseIcon",{staticClass:"mb-2 text-primary-500",attrs:{type:"info"}}),r("div",{staticClass:"text-lg font-medium",domProps:{textContent:t._s(t.document.$t("documentVoided.title"))}}),r("div",{staticClass:"text-gray-700",domProps:{textContent:t._s(t.document.$t("documentVoided.description"))}})],1)])},dht=[],pht=he(cht,uht,dht,!1,null,null,null,null);const FY=pht.exports,NY=Ne.observable({canEdit:!1,isForm:!1,setFormValue:null}),fht={props:{document:{type:Object,required:!0},setFormValue:{type:Function,required:!0}},components:{DocumentLayout:C8,DocumentVoided:FY},mixins:[cq,IY()],provide:()=>({viewSettings:NY}),created(){this.setFormValue&&(NY.setFormValue=this.setFormValue),LY.on("answer",this.onAnswerMessage)},beforeDestroy(){LY.off("answer",this.onAnswerMessage)},methods:{onAnswerMessage(n){this.onAnswer(n==null?void 0:n.mode)}}};var hht=function(){var i;var t=this,r=t._self._c;return r("div",[t._t("default"),((i=t.document)==null?void 0:i.status)==="voided"?r("DocumentVoided",{attrs:{document:t.document}}):r("DocumentLayout",{attrs:{document:t.document}})],2)},mht=[],ght=he(fht,hht,mht,!1,null,null,null,null);const vht={name:"DocumentClient",components:{ClientView:ght.exports},props:{document:{type:Object,required:!0},setFormValue:{type:Function,required:!0}}};var yht=function(){var t=this,r=t._self._c;return r("ClientView",{attrs:{document:t.document,"set-form-value":t.setFormValue}})},bht=[],_ht=he(vht,yht,bht,!1,null,null,null,null);const wht=_ht.exports,xht=Object.freeze(Object.defineProperty({__proto__:null,default:wht},Symbol.toStringTag,{value:"Module"})),Cht={name:"Setup",props:{partnerName:{type:String,default:"Partner"},closeFunc:{type:Function,default:()=>{}}},computed:{baseAppUrl(){return Xe.baseUrl},iframeUrl(){return`${this.baseAppUrl}/partner/connect?partnerName=${this.partnerName}`}},created(){window.addEventListener("message",this.onReceiveMessage)},beforeDestroy(){window.removeEventListener("message",this.onReceiveMessage)},methods:{onReceiveMessage({data:n,origin:t,source:r}){var i;t===this.baseAppUrl&&((n==null?void 0:n.type)==="channelPartnerConnect"&&(r==null||r.postMessage({type:"readyForPartnerConnect"},t)),(n==null?void 0:n.type)==="partnerUserConnect"&&(Pr.trigger("account:userConnect",n==null?void 0:n.value),(i=this.closeFunc)==null||i.call(this)))}}};var kht=function(){var t=this,r=t._self._c;return r("iframe",{staticClass:"w-full h-full",attrs:{title:"Partner Connect",src:t.iframeUrl,frameborder:"0"}})},Sht=[],Tht=he(Cht,kht,Sht,!1,null,null,null,null);const Eht=Tht.exports,$ht=Object.freeze(Object.defineProperty({__proto__:null,default:Eht},Symbol.toStringTag,{value:"Module"})),Aht={components:{AnswerModal:G7},props:{document:{type:Object,required:!0},answerType:{type:String,required:!0},closeFunc:{type:Function,default:null}}};var Oht=function(){var t=this,r=t._self._c;return r("AnswerModal",{attrs:{mode:t.answerType,_document:t.document},on:{close:t.closeFunc}})},Dht=[],Mht=he(Aht,Oht,Dht,!1,null,null,null,null);const Pht=Mht.exports,Iht=Object.freeze(Object.defineProperty({__proto__:null,default:Pht},Symbol.toStringTag,{value:"Module"}));var Rht=he({name:"PublicDocumentEvents",props:{document:{type:Object,default:()=>({})}},computed:{events(){const n=[],{acceptedAt:t}=this.document;return this.document.events.filter(({createdAt:r})=>t?L4(t,r):!0).forEach(r=>{const{code:i,createdAt:a,children:o=[]}=r;let{data:s={}}=r;s===null&&(s={});const{client:c={},clients:l=[],status:u,counter:d}=s,p={sent:()=>l.map(f=>{const h=this.getClientName(f.id),m=this.filteredOxfordComma([f.email,f.cellphone]);return{text:this.document.$t("event.sent",{to:`${h?h+", ":""}${m}`}),time:a}}),viewed:()=>{const f=d||o.length+1;return[{text:`${this.document.$t(`event.${c.name?"viewedName":"viewed"}`,{name:c.name})} ${f?this.document.$tc("times",{count:f}):""}.`,time:a}]},accepted:()=>[{text:this.document.$t("event.accepted",{by:c.name||c.email||c.cellphone}),time:a}],denied:()=>[{text:this.document.$t("event.denied",{by:c.name||c.email||c.cellphone}),time:a}],statusChanged:()=>[{text:this.document.$t("event.statusChanged",{status:this.document.$t(`status.${u}`).toLowerCase()}),time:a}],requestChange:()=>[{text:this.document.$t("event.requestChange",{status:this.document.$t(`status.${u}`).toLowerCase()}),time:a}],expired:()=>[{text:this.document.$t("event.expired"),time:a}]};p[i]&&n.push(...p[i]())}),n}},methods:{filteredOxfordComma(n=[]){const t=n.filter(i=>!!i),r=t.length;return r?r<2?t[0]:`${t.slice(0,-1).join(", ")} ${this.document.$t("and")} ${t.slice(-1)}`:""},getClientName(n){const t=this.document.clients.find(({id:r})=>r===n);return t?t.name:""}},render(){return this.$scopedSlots.default({events:this.events})}},null,null,!1,null,null,null,null);const Lht=Rht.exports;var Fht=he({name:"CPhoneFormat",props:{phone:{type:String,required:!1,default:""},region:{type:String,required:!1,default:null}},data(){return{formattedPhone:""}},watch:{phone:{immediate:!0,async handler(){this.doFormatPhone()}}},methods:{async doFormatPhone(){if(!this.phone){this.formattedPhone="";return}const n=await uM(this.phone,{defaultRegion:this.region});if(!n){this.formattedPhone=this.phone;return}this.formattedPhone=n.national}},render(){return this.$scopedSlots.default?this.$scopedSlots.default({formattedValue:this.formattedPhone}):xte("span",[this.formattedPhone])}},null,null,!1,null,null,null,null);const BY=Fht.exports,eDt="",tDt="",Nht={name:"PublicRecipientItem",i18nOptions:{namespaces:"components",keyPrefix:"document.myPagesDrawer"},components:{CPhoneFormat:BY},props:{recipient:{type:Object,required:!0}},methods:{get:Ce,getBrowserString({browser:n,os:t,device:r}){return[n&&n.name,t&&t.name,r&&r.model].filter(i=>!!i).join(", ")}}};var Bht=function(){var t=this,r=t._self._c;return r("div",{staticStyle:{border:"1px solid hsl(0, 0%, 84%)","border-radius":"3px","margin-bottom":"1em"}},[r("div",{staticStyle:{padding:"0.5em 0.75em"}},[t._l([t.recipient.name,t.recipient.companyName,t.recipient.orgNo],function(i,a){return r("span",{key:`${i}-${a}`,style:a===0?{fontWeight:500}:{opacity:.65}},[t._v(" "+t._s(i&&a>0?"·":"")+" "+t._s(i)+" ")])}),r("div",{staticClass:"flex flex-col w-full",staticStyle:{"font-size":"14px","align-items":"baseline"}},[t.recipient.email?r("a",{attrs:{href:`mailto:${t.recipient.email}`,target:"_blank"}},[t._v(" "+t._s(t.recipient.email)+" ")]):t._e(),t.recipient.cellphone?r("CPhoneFormat",{attrs:{phone:t.recipient.cellphone,region:t.recipient.cellphoneRegion},scopedSlots:t._u([{key:"default",fn:function({formattedValue:i}){return r("a",{attrs:{href:`tel:${t.recipient.cellphone}`}},[t._v(" "+t._s(i)+" ")])}}],null,!1,2469850174)}):t._e()],1)],2),r("div",{staticStyle:{"background-color":"hsl(0, 0%, 94%)",padding:"0.75em 0.75em","font-weight":"500","font-size":"13px","line-height":"1",color:"hsl(0, 0%, 40%)",position:"relative"}},[r("div",[t._v(" "+t._s(t.$t(`_common:documentRole.${t.recipient.documentRole}.label`))+" ")]),r("div",{staticStyle:{position:"absolute",right:"1em",top:"0px",transform:"translate(0, -50%)"}},[r("v-popover",{attrs:{"popover-inner-class":"signee-popover",trigger:"hover",placement:"bottom-end"}},[t.recipient.documentRole==="signee"?r("div",{staticStyle:{padding:"5px 0.75em",background:"hsl(0, 0%, 60%)","border-radius":"4px","font-size":"13px",color:"hsl(0, 0%, 100%)",cursor:"default",display:"inline-flex","align-items":"center"}},[r("BaseIcon",{staticStyle:{"margin-right":"0.5ch"},attrs:{size:15,type:"info","stroke-width":"2"}}),t.recipient.answer&&t.recipient.answer.didAccept?[t._v(" "+t._s(t.$t("_common:approved").capitalize())+" ")]:t.recipient.answer?[t._v(" "+t._s(t.$t("_common:denied").capitalize())+" ")]:[t._v(" "+t._s(t.$t("views:publicDocument.pdfVerification.waitingForAnswer"))+" ")]],2):t._e(),r("div",{staticStyle:{padding:"0"},attrs:{slot:"popover"},slot:"popover"},[r("div",{staticStyle:{padding:"1em 1.5em"}},[t.recipient.answer&&t.recipient.answer.didAccept?[t.recipient.answer.signatureDataURL?r("div",{staticStyle:{"padding-bottom":"0.5em"}},[r("div",{staticClass:"has-text-grey",staticStyle:{"padding-bottom":"1em"}},[t._v(" "+t._s(t.$t("_common:signature").capitalize())+" ")]),r("img",{staticStyle:{width:"80%"},attrs:{src:t.recipient.answer.signatureDataURL}})]):r("div",{staticStyle:{"font-size":"13px","padding-top":"3px"}},[t.get(t.recipient,"answerMethod.accept")==="bankId"?[r("div",{staticStyle:{"font-weight":"500"}},[t._v(" "+t._s(t.$t("views:publicDocument.pdfVerification.recipient.signedBankId"))+" ")]),r("div",[t._v(t._s(t.recipient.answer.response.name))]),r("div",[t._v(t._s(t.recipient.socialNo))])]:t.get(t.recipient,"answerMethod.accept")==="login"?r("div",{staticStyle:{"font-weight":"500"}},[t._v(" "+t._s(t.$t("views:publicDocument.pdfVerification.recipient.verifiedLogin"))+" ")]):t._e()],2)]:t.recipient.answer?r("div",[t._v(" "+t._s(t.$t("_common:denied").capitalize())+" ")]):r("div",[t._v(" "+t._s(t.$t("pendingAnswer"))+" ")])],2),t.recipient.answer?r("div",{staticStyle:{padding:"8px 1.5em","border-top":"1px solid hsl(0deg 0% 88%)","background-color":"hsl(0deg 0% 95%)","font-size":"13px",color:"hsl(0, 0%, 35%)","font-weight":"500"}},[t.recipient.answer.didAnswerAt?r("div",[r("div",[t._v(" "+t._s(t.$t("_common:date").capitalize())+": "+t._s(t.$formatDate(t.recipient.answer.didAnswerAt,"P"))+" ")]),r("div",[t._v(" "+t._s(t.$t("_common:time.time").capitalize())+": "+t._s(t.$formatDate(t.recipient.answer.didAnswerAt,"p"))+" ")])]):t._e(),t.recipient.answer.ip?r("div",[t._v(" IP: "+t._s(t.recipient.answer.ip)+" ")]):t._e(),t.recipient.answer.browser?r("div",[t._v(" Browser: "+t._s(t.getBrowserString(t.recipient.answer))+" ")]):t._e()]):t._e()])])],1)])])},jht=[],zht=he(Nht,Bht,jht,!1,null,"7bf07f05",null,null);const Vht=zht.exports,nDt="",Uht={name:"DocumentDetails",mixins:[br],components:{PublicDocumentEvents:Lht,PublicRecipientItem:Vht,CDropdown:Of,CDropdownItem:nd},props:{document:{type:Object,required:!0},openPrintFunc:{type:Function,default:null}},data(){return{docLanguages:pM,nativeTranslations:ave}},computed:{viewer(){return this.document.viewer}},methods:{changeLanguage(n){this.document.language=n,this.$root.$i18n.i18next.changeLanguage(JA.includes(n)?n:"en")}}};var Hht=function(){var t=this,r=t._self._c;return r("div",{staticStyle:{width:"100%",height:"100%",display:"flex","flex-direction":"column","font-size":"16px",background:"hsl(0, 0%, 100%)","border-radius":"10px",overflow:"hidden","box-shadow":"0 10px 20px rgba(0, 0, 0, 0.2)",position:"relative"}},[r("div",{staticClass:"flex w-full justify-end items-center",staticStyle:{position:"absolute",top:"20px",right:"20px","z-index":"2"}},[t.openPrintFunc?[r("CButton",{staticStyle:{"padding-left":"1em","padding-right":"1em"},attrs:{"icon-left":"print",type:"none",pattern:"tertiary",taller:"",size:"small"},on:{click:t.openPrintFunc}},[t._v(" "+t._s(t.document.$t("download",{thing:"PDF"}))+" ")]),r("div",{staticStyle:{height:"2rem",width:"1px","background-color":"hsl(0, 0%, 88%)",margin:"0 6px"}})]:t._e(),r("CDropdown",{attrs:{value:t.document.language}},[r("CButton",{staticStyle:{color:"hsla(0, 0%, 45%, 1)"},attrs:{slot:"trigger","icon-props":{size:18},size:"normal",icon:"globe",circle:""},slot:"trigger"}),t._l(t.docLanguages,function(i){return r("CDropdownItem",{key:i,attrs:{value:i},on:{click:function(a){return t.changeLanguage(i)}}},[t._v(" "+t._s(t.nativeTranslations[i])+" ")])})],2),r("CButton",{staticStyle:{"margin-left":"6px",color:"hsla(0, 0%, 45%, 1)"},attrs:{"icon-props":{size:18},size:"normal",icon:"x",circle:""},on:{click:function(i){return t.$emit("close")}}})],2),r("div",{staticClass:"d-root"},[r("div",{staticClass:"flex justify-between",staticStyle:{"margin-bottom":"3em"}},[r("div",[r("div",{staticStyle:{"font-size":"18px","font-weight":"600"}},[t._v(" "+t._s(t.document.$t("detail_plural").capitalize())+" ")]),r("div",{staticClass:"has-text-grey",staticStyle:{"font-size":"14px"}},[t._v(" "+t._s(t.document.$t("documentDetails.subTitle"))+" ")])])]),r("div",{staticClass:"d-option",staticStyle:{"margin-bottom":"3em"}},[r("div",{staticClass:"d-option-title",staticStyle:{"padding-bottom":"0.5rem"}},[t._v(" "+t._s(t.document.$t("participant_plural").capitalize())+" ")]),t._l(t.document.recipients,function(i,a){return r("PublicRecipientItem",{key:i._uniqueId+a,attrs:{recipient:i}})})],2),r("PublicDocumentEvents",{attrs:{document:t.document},scopedSlots:t._u([{key:"default",fn:function({events:i}){return[i&&i.length?r("div",{staticClass:"d-option"},[r("div",{staticClass:"d-option-title"},[t._v(" "+t._s(t.document.$t("event.event_plural").capitalize())+" ")]),r("div",{attrs:{id:"timeline"}},[r("div",t._l(i,function(a,o){return r("div",{key:o,staticClass:"e-item"},[r("div",{staticClass:"e-data"},[r("div",{staticClass:"e-text"},[t._v(t._s(a.text))]),r("div",{staticClass:"e-timestamp"},[r("div",{staticClass:"e-date"},[t._v(t._s(t.$formatDate(a.time,"P")))]),r("div",{staticClass:"e-time",staticStyle:{"padding-left":"0.5ch"}},[t._v(" "+t._s(t.$formatDate(a.time,"p"))+" ")])])])])}),0)])]):t._e()]}}])}),t.mq==="sm"?r("div",[t._t("footer")],2):t._e()],1),t.mq!=="sm"?r("div",[t._t("footer")],2):t._e()])},Wht=[],Ght=he(Uht,Hht,Wht,!1,null,"0d868038",null,null);const qht=Ght.exports,rDt="",Yht={components:{DocumentDetails:qht,DocumentVoided:FY},props:{document:{type:Object,required:!0},closeFunc:{type:Function,default:null}}};var Kht=function(){var t=this,r=t._self._c;return t.document&&t.document.status==="voided"?r("DocumentVoided",{attrs:{document:t.document}}):r("DocumentDetails",{attrs:{document:t.document},on:{close:t.closeFunc}})},Zht=[],Jht=he(Yht,Kht,Zht,!1,null,"d3b68450",null,null);const Xht=Jht.exports,Qht=Object.freeze(Object.defineProperty({__proto__:null,default:Xht},Symbol.toStringTag,{value:"Module"})),iDt="",emt={name:"DocModalBase",components:{},props:{showClose:{type:Boolean,default:!1}}};var tmt=function(){var t=this,r=t._self._c;return r("div",{staticClass:"doc-modal-base"},[t.showClose?r("CButton",{staticClass:"absolute text-gray-500 top-4 right-4",attrs:{circle:"",icon:"x"},on:{click:function(i){return t.$parent.$emit("close")}}}):t._e(),t._t("default")],2)},nmt=[],rmt=he(emt,tmt,nmt,!1,null,"b672a873",null,null);const jY=rmt.exports,imt={i18nOptions:{namespaces:"components",keyPrefix:"document.propertyDesignationModal"},mixins:[br],components:{DocModalBase:jY},props:{senderName:{type:String,required:!0},propertyDesignation:{type:Object,default:null},fullScreen:{type:Boolean,default:!1}},data(){return{cornerRadius:0,spacing:0,view:"start",form:"",realEstateId:"",condominiumId:null,condominiumOrgNo:null}},validations:{condominiumId:{required:ln.requiredIf(n=>n.form==="condominium"),minLength:ln.minLength(4),maxLength:ln.maxLength(4)},condominiumOrgNo:{required:ln.requiredIf(n=>n.form==="condominium")},realEstateId:{required:ln.requiredIf(n=>n.form==="realEstate")}},computed:{messages(){const n=t=>this.$t(`validations.${t}`);return{condominiumId:{required:n("condominiumId.required"),minLength:n("condominiumId.minLength"),maxLength:n("condominiumId.maxLength")},condominiumOrgNo:{required:n("condominiumOrgNo.required")},realEstateId:{required:n("realEstateId.required")}}}},created(){if(this.propertyDesignation){const{propertyType:n="",propertyId:t="",condominiumOrgNo:r=null}=this.propertyDesignation;this.form=n,n==="realEstate"?this.realEstateId=t:this.condominiumId=t,this.condominiumOrgNo=r}},mounted(){this.spacing=window.getComputedStyle(this.$refs.root.$el).paddingTop,this.cornerRadius=window.getComputedStyle(this.$refs.root.$el).borderRadius},methods:{...xn({putCurrentDoc:We.PUT_CURRENT_PUBLIC_DOCUMENT,reloadCurrentDocument:We.RELOAD_CURRENT_DOCUMENT}),async updateClientPropertyDesignation(){if(this.$v.$touch(),this.$v.$invalid)return;const n={propertyType:this.form,propertyId:this.form==="realEstate"?this.realEstateId:this.condominiumId,...this.form==="condominium"&&{condominiumOrgNo:this.condominiumOrgNo}};try{const t="clients[0].region.propertyDesignation";await this.putCurrentDoc({body:{[t]:n}}),this.reloadCurrentDocument(),this.view="complete"}catch(t){Ir(t)}}}};var amt=function(){var t=this,r=t._self._c;return r("doc-modal-base",{ref:"root",class:[{"full-screen":t.mq==="sm"}]},[t.fullScreen?r("CButton",{staticClass:"absolute z-50 top-4 right-4",attrs:{icon:"x",circle:""},on:{click:function(i){return t.$emit("close")}}}):t._e(),r("div",[t.view!=="complete"?r("div",{staticClass:"relative pb-8 mb-8 text-center border-b border-gray-100 negate-padding bg-gray-50",style:{paddingTop:t.spacing,marginTop:`-${t.spacing}`,borderRadius:`${t.cornerRadius} ${t.cornerRadius} 0 0`}},[t.view==="start"?r("div",{key:1},[r("div",{staticClass:"mb-2 text-lg font-semibold"},[t._v(t._s(t.$t("title")))]),r("div",{staticClass:"text-gray-700"},[t._v(" "+t._s(t.$t("subTitle",{senderName:t.senderName}))+" ")])]):t._e(),t.view==="form"?r("div",{key:2},[r("CButton",{staticClass:"absolute top-4 left-4",attrs:{circle:"",icon:"arrow-left"},on:{click:function(i){t.view="start"}}}),r("div",{staticClass:"mb-2 text-lg font-semibold"},[t._v(t._s(t.$t("howToFind")))]),r("div",{staticClass:"text-gray-700"},[t._v(" "+t._s(t.$t("goto1"))+" "),r("a",{staticStyle:{"text-decoration":"underline"},attrs:{href:"https://www.lantmateriet.se/",target:"_blank",rel:"noopener"}},[t._v(" "+t._s(t.$t("goto2"))+" ")]),t._v(" "+t._s(t.$t("goto3"))+" ")])],1):t._e()]):t._e(),t.view==="start"?r("div",{key:1,staticClass:"mb-12 text-center"},[r("div",{staticClass:"mb-4 text-base font-medium"},[t._v(t._s(t.$t("whereTitle")))]),r("div",{staticClass:"flex justify-center"},[r("div",{staticClass:"mx-4"},[r("div",{staticClass:"flex items-center justify-center w-24 h-24 mb-2 border border-gray-300 cursor-pointer bg-gray-50 rounded-xl hover:bg-gray-100 active:bg-gray-200",on:{click:function(i){t.view="form",t.form="realEstate"}}},[r("svg",{staticClass:"text-gray-400",attrs:{width:"59",height:"41",viewBox:"0 0 59 59",xmlns:"http://www.w3.org/2000/svg"}},[r("g",{attrs:{fill:"currentColor","fill-rule":"evenodd"}},[r("path",{attrs:{d:"M6 28h47v29H6V28zm6 7.998101V40.0019C12 41.113294 12.89458 42 13.998101 42H18.0019C19.113294 42 20 41.10542 20 40.001899V35.9981C20 34.886706 19.10542 34 18.001899 34H13.9981C12.886706 34 12 34.89458 12 35.998101zm22-.007306V54h11V35.990795C45 34.898212 44.108144 34 43.007983 34h-7.015966C34.900177 34 34 34.89131 34 35.990795zM27.189354 1.837583C28.46549.536998 30.53366.53613 31.813677 1.840673L56.5 27h-54l9.85551-10.044348V7.141778h6.733007v2.95186l8.100837-8.256055zM25.5 15.861211v4.003797c0 1.111395.89458 1.998102 1.998101 1.998102H31.5019c1.111395 0 1.998101-.89458 1.998101-1.998102v-4.003797c0-1.111395-.89458-1.998101-1.998101-1.998101H27.4981c-1.111395 0-1.998101.89458-1.998101 1.998101z"}}),r("path",{attrs:{d:"M0 56.004882C0 54.897616.90314 54 1.996843 54h55.006314C58.105983 54 59 54.8939 59 56.004882V59H0v-2.995118z"}})])])]),r("div",{staticClass:"text-sm leading-tight text-gray-700"},[t._v(" "+t._s(t.$t("house"))),r("br"),t._v("/ "+t._s(t.$t("realEstate"))+" ")])]),r("div",{staticClass:"mx-4"},[r("div",{staticClass:"flex items-center justify-center w-24 h-24 mb-2 border border-gray-300 cursor-pointer bg-gray-50 rounded-xl hover:bg-gray-100 active:bg-gray-200",on:{click:function(i){t.view="form",t.form="condominium"}}},[r("svg",{staticClass:"text-gray-400",attrs:{width:"59",height:"50",viewBox:"0 0 59 73",xmlns:"http://www.w3.org/2000/svg"}},[r("g",{attrs:{fill:"currentColor","fill-rule":"evenodd"}},[r("path",{attrs:{d:"M6 9.004723C6 7.34526 7.343394 6 8.993614 6h41.012771C51.659714 6 53 7.342697 53 9.004723V71H6V9.004723zm5 4.993378V18.0019C11 19.113294 11.89458 20 12.998101 20H17.0019C18.113294 20 19 19.10542 19 18.001899V13.9981C19 12.886706 18.10542 12 17.001899 12H12.9981C11.886706 12 11 12.89458 11 13.998101zm14.5 0V18.0019C25.5 19.113294 26.39458 20 27.498101 20H31.5019C32.613294 20 33.5 19.10542 33.5 18.001899V13.9981C33.5 12.886706 32.60542 12 31.501899 12H27.4981C26.386706 12 25.5 12.89458 25.5 13.998101zm14.5 0V18.0019C40 19.113294 40.89458 20 41.998101 20H46.0019C47.113294 20 48 19.10542 48 18.001899V13.9981C48 12.886706 47.10542 12 46.001899 12H41.9981C40.886706 12 40 12.89458 40 13.998101zm-29 12V30.0019C11 31.113294 11.89458 32 12.998101 32H17.0019C18.113294 32 19 31.10542 19 30.001899V25.9981C19 24.886706 18.10542 24 17.001899 24H12.9981C11.886706 24 11 24.89458 11 25.998101zm14.5 0V30.0019C25.5 31.113294 26.39458 32 27.498101 32H31.5019C32.613294 32 33.5 31.10542 33.5 30.001899V25.9981C33.5 24.886706 32.60542 24 31.501899 24H27.4981C26.386706 24 25.5 24.89458 25.5 25.998101zm14.5 0V30.0019C40 31.113294 40.89458 32 41.998101 32H46.0019C47.113294 32 48 31.10542 48 30.001899V25.9981C48 24.886706 47.10542 24 46.001899 24H41.9981C40.886706 24 40 24.89458 40 25.998101zm-29 12V42.0019C11 43.113294 11.89458 44 12.998101 44H17.0019C18.113294 44 19 43.10542 19 42.001899V37.9981C19 36.886706 18.10542 36 17.001899 36H12.9981C11.886706 36 11 36.89458 11 37.998101zm14.5 0V42.0019C25.5 43.113294 26.39458 44 27.498101 44H31.5019C32.613294 44 33.5 43.10542 33.5 42.001899V37.9981C33.5 36.886706 32.60542 36 31.501899 36H27.4981C26.386706 36 25.5 36.89458 25.5 37.998101zm14.5 0V42.0019C40 43.113294 40.89458 44 41.998101 44H46.0019C47.113294 44 48 43.10542 48 42.001899V37.9981C48 36.886706 47.10542 36 46.001899 36H41.9981C40.886706 36 40 36.89458 40 37.998101zm-29 12V54.0019C11 55.113294 11.89458 56 12.998101 56H17.0019C18.113294 56 19 55.10542 19 54.001899V49.9981C19 48.886706 18.10542 48 17.001899 48H12.9981C11.886706 48 11 48.89458 11 49.998101zm14.5 0V54.0019C25.5 55.113294 26.39458 56 27.498101 56H31.5019C32.613294 56 33.5 55.10542 33.5 54.001899V49.9981C33.5 48.886706 32.60542 48 31.501899 48H27.4981C26.386706 48 25.5 48.89458 25.5 49.998101zM21 60.997391V68h17v-7.002608C38 59.895858 37.104522 59 35.999894 59H23.000106C21.890058 59 21 59.894263 21 60.997392zm19-10.99929V54.0019C40 55.113294 40.89458 56 41.998101 56H46.0019C47.113294 56 48 55.10542 48 54.001899V49.9981C48 48.886706 47.10542 48 46.001899 48H41.9981C40.886706 48 40 48.89458 40 49.998101zM10 2.5C10 1.119288 11.125134 0 12.498953 0h34.002094C47.88118 0 49 1.109662 49 2.5V5H10V2.5z"}}),r("path",{attrs:{d:"M0 70.004881C0 68.897616.90314 68 1.996843 68h55.006314C58.105983 68 59 68.8939 59 70.004881V73H0v-2.995119z"}})])])]),r("div",{staticClass:"text-sm leading-tight text-gray-700"},[t._v(" "+t._s(t.$t("condominium"))),r("br"),t._v("/ "+t._s(t.$t("apartment"))+" ")])])])]):t._e(),t.view==="form"?r("div",{key:2},[r("div",[t.form==="realEstate"?r("CField",{attrs:{vuelidate:t.$v.realEstateId,"vuelidate-messages":t.messages.realEstateId,label:t.$t("propertyDesignation")}},[r("CInput",{attrs:{placeholder:t.$t("propertyDesignationPlaceholder"),autofocus:""},model:{value:t.realEstateId,callback:function(i){t.realEstateId=i},expression:"realEstateId"}})],1):t._e(),t.form==="condominium"?r("CField",{attrs:{vuelidate:t.$v.condominiumId,"vuelidate-messages":t.messages.condominiumId,label:t.$t("condominiumId")}},[r("CInput",{attrs:{placeholder:t.$t("condominiumIdPlaceholder"),autofocus:"",type:"number"},model:{value:t.condominiumId,callback:function(i){t.condominiumId=i},expression:"condominiumId"}})],1):t._e(),t.form==="condominium"?r("CField",{attrs:{vuelidate:t.$v.condominiumOrgNo,"vuelidate-messages":t.messages.condominiumOrgNo,label:t.$t("condominiumOrgNo")}},[r("CInput",{attrs:{placeholder:t.$t("condominiumOrgNoPlaceholder"),type:"number"},model:{value:t.condominiumOrgNo,callback:function(i){t.condominiumOrgNo=i},expression:"condominiumOrgNo"}})],1):t._e(),r("div",{staticClass:"mt-8"},[r("CButton",{attrs:{type:"secondary",wide:""},on:{click:t.updateClientPropertyDesignation}},[t._v(t._s(t.$t("_common:save")))])],1)],1)]):t._e(),t.view==="complete"?r("div",{key:3},[r("div",{staticClass:"flex flex-col items-center justify-center text-center"},[r("div",{staticClass:"flex items-center justify-center w-12 h-12 mb-4 rounded-full bg-primary-50"},[r("BaseIcon",{staticClass:"text-primary-500",attrs:{type:"check"}})],1),r("div",{staticClass:"mb-1 text-base font-semibold"},[t._v(" "+t._s(t.$t("savedTitle"))+" ")]),r("div",{staticClass:"mb-6 text-base text-gray-700"},[t._v(" "+t._s(t.$t("savedSubTitle",{senderName:t.senderName}))+" ")]),r("div",{staticClass:"w-full mt-4"},[r("CButton",{attrs:{type:"secondary",wide:""},on:{click:function(i){return t.$emit("close")}}},[t._v(t._s(t.$t("_common:close")))])],1)])]):t._e()])],1)},omt=[],smt=he(imt,amt,omt,!1,null,null,null,null);const lmt=smt.exports,aDt="",cmt={i18nOptions:{namespaces:"docAnswer",messages:{en:{previewTooltip:"Preview how your recipients will answer."},sv:{previewTooltip:"Förhandsgranska hur dina mottagare kommer att lämna svar."}}},name:"DocumentAnswerRead",mixins:[IY({documentKey:"_document"}),br],inject:{isPdf:{default:!1}},props:{_document:{type:Object,required:!0}},data(){return{isInViewport:!1,scrollToElement:$m}},computed:{viewerId(){var n;return((n=this._document._doc)==null?void 0:n.viewerId)||null},isPreview(){return this._document.isPreview},modalHeight(){return this.mq==="sm"?"100%":"auto"},allowPropertyDesignation(){const{prices:n}=this._document;if(!n||!n.region)return!1;const{houseWorkType:t}=n.region;return["rot","greenRot15","greenRot20","greenRot50"].includes(t)},propertyDesignation(){return Ce(this._document,"clients[0].region.propertyDesignation",null)}},mounted(){window.addEventListener("scroll",this.scrollHandler,{capture:!0,passive:!0}),this.$route.name==="docPropertyDesignation"&&this.showPropertyDesignation()},destroyed(){window.removeEventListener("scroll",this.scrollHandler)},watch:{$route:{immediate:!0,handler(n){n!=null&&n.hash&&this.onAnswer("accept",{calcHeight:!0})}},isInViewport:{immediate:!0,handler(n,t){n!==t&&Pr.trigger("ui:document.block.answer.visible",n)}}},methods:{scrollHandler(){this.$refs.answerButtons&&(this.isInViewport=iM(this.$refs.answerButtons))},showPropertyDesignation(){this.$modal.show(lmt,{senderName:this._document.sender.user.name,propertyDesignation:this.propertyDesignation,fullScreen:this.modalHeight==="100%"},{adaptive:!0,height:this.modalHeight,width:"100%",maxWidth:this.modalHeight==="100%"?999:400,classes:"overflow-visible",transition:"fade-in-slide-up"})}}};var umt=function(){var i,a;var t=this,r=t._self._c;return t._document.answerActions.showActions&&!t.isPdf?r("div",{staticStyle:{padding:"calc(3 * var(--rem)) 0"}},[r("div",{ref:"answerButtons",staticClass:"flex justify-center w-full"},[r("transition",{attrs:{name:"fade",mode:"out-in"}},[((a=(i=t._document.viewer)==null?void 0:i.answerMethod)==null?void 0:a.accept)==="inPerson"?r("div",{key:0,staticStyle:{"max-width":"720px",margin:"0 auto",padding:"0 calc(3 * var(--rem))"},style:t.mq==="sm"?{padding:"0 calc(1.5 * var(--rem))"}:null},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.inPersonSignatureHint"))+" "),r(t._document.sender.user.email?"a":"span",{tag:"component",attrs:{href:`mailto:${t._document.sender.user.email}`}},[t._v(" "+t._s(t._document.sender.company.name||t._document.$t("theSender"))+" ")])],1):(t._document.answerActions.canAnswer||t.isPreview)&&t._document.answerActions.showActions?r("div",{key:1,staticClass:"flex justify-center w-full"},[r("CButton",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.isPreview&&t.$t("previewTooltip"),expression:"isPreview && $t('previewTooltip')"}],staticClass:"text-gray-400",attrs:{size:"medium"},on:{click:function(o){return t.onAnswer("decline")}}},[t._v(" "+t._s(t._document.$t("deny").capitalize())+" ")]),r("CButton",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.isPreview&&t.$t("previewTooltip"),expression:"isPreview && $t('previewTooltip')"}],staticStyle:{"margin-left":"1em","padding-left":"1.5em","padding-right":"1.5em"},attrs:{"icon-props":{strokeWidth:2.5},type:"success",size:"medium","icon-left":"check",raised:""},on:{click:function(o){return t.onAnswer("accept")}}},[t._v(" "+t._s(t._document.$t("sign").capitalize())+" ")])],1):t._document.answerActions.hasAnswered&&t._document.answerActions.waitingForOthers?r("div",{key:2,staticClass:"text-center"},[r("div",{staticStyle:{"font-weight":"600","font-size":"calc(calc(1 * var(--rem)) + 2px)","margin-bottom":"calc(0.5 * var(--rem))"}},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.youHave"))+" "),r("span",{directives:[{name:"tooltip",rawName:"v-tooltip",value:`${t.$formatDate(t._document.viewer.answer.didAnswerAt,"Pp")}`,expression:"\n `${$formatDate(_document.viewer.answer.didAnswerAt, 'Pp')}`\n "}],staticStyle:{"text-decoration":"underline"}},[t._v(t._s(t._document.viewer.answer.didAccept?t._document.$t("approved"):t._document.$t("denied")))]),t._v(" "+t._s(" "+t._document.$t("theDocument"))+". ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.waitingDescription",{remaining:t._document.remainingSignatures}))+" ")])]):t._document.status==="accepted"?r("div",{key:3},[r("div",{staticClass:"callout accepted"},[r("div",{staticClass:"title"},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.approveTitle"))+" ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.approveDescription",{sender:t._document.sender.company.name||t._document.$t("theSender")}))+" ")])])]):t._document.status==="denied"?r("div",{key:4,staticClass:"callout denied"},[r("div",{staticClass:"title"},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.denyTitle"))+" ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.denyDescription",{sender:t._document.sender.company.name||t._document.$t("theSender")}))+" ")])]):t._document.status==="expired"?r("div",{key:5,staticClass:"callout expired"},[r("div",{staticClass:"title"},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.expiredTitle"))+" ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.expiredDescription",{sender:t._document.sender.company.name||t._document.$t("theSender")}))+" ")])]):t._e()])],1),t._document.status==="accepted"&&t.allowPropertyDesignation&&t._document.answerActions.hasAnswered?r("div",{staticClass:"flex justify-center"},[r("div",{staticClass:"answer button accept",staticStyle:{"padding-left":"calc(1.5 * var(--rem))","padding-right":"calc(1.5 * var(--rem))"},on:{click:function(o){return t.showPropertyDesignation()}}},[t._v(" "+t._s(t._document.$t(`chapters.answerButtons.${t.propertyDesignation?"editPropDes":"enterPropDes"}`))+" ")])]):t._e()]):t._e()},dmt=[],pmt=he(cmt,umt,dmt,!1,null,"e023f071",null,null);const fmt=pmt.exports,hmt=Object.freeze(Object.defineProperty({__proto__:null,default:fmt},Symbol.toStringTag,{value:"Module"})),oDt="";let zY,VY,UY,HY,WY;function mmt(n){return typeof n=="object"&&n!==null&&n.__PDFDocumentLoadingTask===!0}const gmt={name:"PdfPage",props:{src:{type:[String,Object,Promise],default:""},page:{type:Number,default:1},rotate:{type:Number,default:0},scale:{type:[Number,String],default:"page-width"},resize:{type:Boolean,default:!0},text:{type:Boolean,default:!0},pdfLoadingTask:{type:Promise,required:!0},containerClass:{type:[Array,String],default:""}},components:{WithDimensions:Af},data(){return{internalSrc:this.src,pdf:null,pdfViewer:null,loading:!0}},watch:{pdf(n){const t=n.pdfInfo||n._pdfInfo;this.$emit("numpages",t.numPages)},page(n){this.pdf.getPage(n).then(t=>{this.pdfViewer.setPdfPage(t),this.pdfViewer.draw()})},scale(n){this.drawScaled(n)},rotate(n){this.pdfViewer&&(this.pdfViewer.update({scale:this.scale,rotation:n}),this.pdfViewer.draw())}},mounted(){zY=window.pdfjsViewer.DefaultTextLayerFactory,VY=window.pdfjsViewer.PDFFindController,UY=window.pdfjsViewer.PDFLinkService,HY=window.pdfjsViewer.PDFPageView,WY=window.pdfjsViewer.EventBus,this.init()},beforeDestroy(){this.pdfViewer&&(this.pdfViewer.destroy(),this.pdfViewer=null)},methods:{init(){mmt(this.internalSrc)||(this.internalSrc=this.pdfLoadingTask,this.$emit("loading",!0));const n=this.$refs.container,t=new WY;t.on("pagerendered",i=>{this.$emit("pagerendered",i)}),this.pdfLinkService=new UY({eventBus:t,externalLinkTarget:2}),this.pdfFindController=new VY({eventBus:t,linkService:this.pdfLinkService});let r;this.text&&(r=new zY),this.internalSrc.then(i=>(this.pdf=i,i.getPage(this.page))).then(i=>{this.pdfViewer=new HY({container:n,id:this.page,scale:1,defaultViewport:i.getViewport({scale:1}),eventBus:t,textLayerFactory:r}),this.pdfViewer.setPdfPage(i);const a={scrollPageIntoView:o=>{this.$emit("link-clicked",o)}};return this.pdfLinkService.setDocument(this.pdf),this.pdfLinkService.setViewer(a),this.pdfFindController.setDocument(this.pdf),this.drawScaled(this.scale)}).catch(i=>{this.$emit("error",i),this.loading=!1,this.$emit("loading",!1)})},calculateScale(n=-1,t=-1){return this.pdfViewer.update({scale:1,rotation:this.rotate}),n===-1&&t===-1&&(n=this.$refs.container.offsetWidth),n/this.pdfViewer.viewport.width},calculateScaleHeight(){this.pdfViewer.update({scale:1,rotation:this.rotate});var n=this.$refs.container.offsetHeight,t=this.$refs.container.parentElement.parentElement;return t.offsetHeight/n},async drawScaled(n){this.pdfViewer&&(n==="page-width"?(n=this.calculateScale(),this.$emit("update:scale",n)):n==="page-height"&&(n=this.calculateScaleHeight(),this.$emit("update:scale",n)),this.pdfViewer.update({scale:n,rotation:this.rotate}),await this.pdfViewer.draw(),this.text&&(this.pdfViewer.textLayer.findController=this.pdfFindController),this.loading=!1,this.$emit("loading",!1))},resizeScale(){this.resize&&this.drawScaled("page-width")}}};var vmt=function(){var t=this,r=t._self._c;return r("div",[t.loading?t._t("loading"):t._e(),r("WithDimensions",{on:{resize:t.resizeScale}},[r("div",{ref:"container",staticClass:"pdfViewer",class:t.containerClass})])],2)},ymt=[],bmt=he(gmt,vmt,ymt,!1,null,null,null,null);const _mt=bmt.exports,R_=new mM;function wmt(n,t){let r;if(typeof n=="string")r={url:n};else if(typeof n=="object"&&n!==null)r={...n};else throw new TypeError("invalid src type");const i=window.pdfjsLib.getDocument(r).promise;return i.__PDFDocumentLoadingTask=!0,t&&t.onPassword&&(i.onPassword=t.onPassword),t&&t.onProgress&&(i.onProgress=t.onProgress),i}const K7={add(n){R_.trigger("add",n)},remove(n){R_.trigger("remove",n)},onAdd(n){R_.on("add",n)},onRemove(n){R_.on("remove",n)}},xmt={props:{src:{type:String,default:null},docFilePath:{type:String,default:null}},components:{VuePdf:_mt},inject:{isPdf:{default:!1}},data(){return{numPages:void 0,pdfLoadingTask:null,hasLoadedScripts:!1,loading:!1,pdfRenderBus:K7}},created(){this.isPdf||K7.add(this._uid)},watch:{src:{immediate:!0,async handler(n){this.hasLoadedScripts||(await g0("https://unpkg.com/pdfjs-dist@3.0.279/build/pdf.min.js"),await g0("https://unpkg.com/pdfjs-dist@3.0.279/web/pdf_viewer.js"),window.pdfjsLib.GlobalWorkerOptions.workerSrc="https://unpkg.com/pdfjs-dist@3.0.279/build/pdf.worker.min.js",this.hasLoadedScripts=!0),this.setPdf(n)}}},methods:{createLoadingTask:wmt,async setPdf(n){n&&(this.loading=!0,this.pdfLoadingTask=this.createLoadingTask(n),this.$nextTick(()=>{this.pdfLoadingTask.then(t=>{this.loading=!1,this.numPages=t.numPages,this.$emit("numPages",t.numPages),this.$emit("rendered"),K7.remove(this._uid)})}))}}};var Cmt=function(){var t=this,r=t._self._c;return r("div",{key:t.src},[t.isPdf?r("pre",[t._v(" ClingPDFReplaceStart:["+t._s(this.docFilePath)+`]ClingPDFReplaceEnd
|
|
2859
|
+
}`}],staticClass:"font-medium",attrs:{value:t.isTypeActive("email",i),size:"tiny",disabled:!t.canSendType("email",i)},on:{input:function(o){return t.setDeliveryMethod("email",a)}}},[t._v(" "+t._s(t.$t("_common:email").capitalize())+" ")])],1)])])}),r("CButton",{staticClass:"font-semibold mt-8",attrs:{type:"secondary",size:"small",taller:"",icon:"send",wide:""},on:{click:t.submit}},[t._v(" "+t._s(t.$t("_common:send",{thing:t.$t("_common:reminder")}))+" ")])],2)},dft=[],pft=he(cft,uft,dft,!1,null,null,null,null);const fft=pft.exports,hft={props:{document:{type:Object,required:!0}},components:{DocumentSendReminderModal:fft}};var mft=function(){var t=this,r=t._self._c;return r("DocumentSendReminderModal",{attrs:{document:t.document},on:{close:function(i){return t.$router.push("/")}}})},gft=[],vft=he(hft,mft,gft,!1,null,null,null,null);const yft=vft.exports,bft=Object.freeze(Object.defineProperty({__proto__:null,default:yft},Symbol.toStringTag,{value:"Module"})),VOt="",PY={new:{statusClass:"draft",icon:"statusDraft"},draft:{statusClass:"draft",icon:"statusDraft"},scheduled:{statusClass:"scheduled",icon:"statusScheduled"},sent:{statusClass:"sent",icon:"statusSent"},denied:{statusClass:"denied",icon:"statusDenied"},accepted:{statusClass:"accepted",icon:"statusAccepted"},signed:{statusClass:"accepted",icon:"statusAccepted"},semiSigned:{statusClass:"accepted",icon:"statusSemiSigned"},expired:{statusClass:"expired",icon:"statusExpired"},voided:{statusClass:"voided",icon:"statusVoided"},active:{statusClass:"active",icon:"statusActive"},completed:{statusClass:"completed",icon:"statusCompleted"},archived:{statusClass:"archived",icon:"statusArchive"}},_ft={props:{status:{type:String,default:""},split:{type:String,default:""}},computed:{text(){return this.status?Be.t(`_common:status.${this.status}`):""},className(){const{statusClass:n=""}=PY[this.status]||{};return n},icon(){return Ce(PY,`${this.status}.icon`)}}};var wft=function(){var t=this,r=t._self._c;return r("div",{staticClass:"inline-flex items-center h-6 pl-1 pr-2 text-xs font-medium leading-none rounded-full c-badge_status",class:t.className},[t.icon?r("BaseIcon",{staticClass:"mr-1 status-icon",attrs:{type:t.icon,size:"16"}}):t._e(),r("span",[t._v(t._s(t.text))])],1)},xft=[],Cft=he(_ft,wft,xft,!1,null,null,null,null);const kft=Cft.exports,Sft={name:"DynamicLink",props:{template:{type:String,required:!0}},computed:{transformed(){return{template:this.template}}}};var Tft=function(){var t=this,r=t._self._c;return r(t.transformed,{tag:"component"})},Eft=[],$ft=he(Sft,Tft,Eft,!1,null,null,null,null);const Aft={name:"EventItem",components:{DynamicLink:$ft.exports},props:{title:{type:String,default:""},template:{type:String,default:""},content:{type:[String,Array],default:""},createdAt:{type:String,default:""},icon:{type:String,default:"square"},compact:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},color:{type:String,default:"gray",validator:n=>["blue","teal","orange","green","red","purple","gray","primary"].indexOf(n)!==-1},isFuture:{type:Boolean,default:!1},size:{type:String,default:""}},computed:{date(){return Hl(vu(this.createdAt))?this.$formatDate(this.createdAt,"Pp"):null},dayOfMonth(){return Hl(vu(this.createdAt))?this.$formatDate(this.createdAt,"d"):null},month(){return Hl(vu(this.createdAt))?this.$formatDate(this.createdAt,"MMM"):null},iconClasses(){const n={blue:"text-blue-600 bg-blue-50",teal:"text-cyan-600 bg-cyan-50",orange:"text-orange-600 bg-orange-50",green:"text-green-600 bg-green-50",red:"text-red-600 bg-red-50",purple:"text-purple-600 bg-purple-50",gray:"text-gray-500 bg-gray-100",primary:"text-primary-500 bg-primary-50"};return this.isFuture?"bg-purple-100 text-purple-500":n[this.color]||n.gray},titleSize(){return this.size==="large"?"text-base":"text-sm"},textSize(){return this.size==="large"?"text-[15px]":"text-[13px]"},dateSize(){return this.size==="large"?"text-sm":"text-xs"}}};var Oft=function(){var t=this,r=t._self._c;return r("div",{staticClass:"flex flex-nowrap relative text-primary-500 cursor-default pb-5 ml-4 event before:content-[''] before:absolute before:w-px before:h-full before:bg-gray-300 before:-left-px before:top-4 last:before:hidden"},[r("div",{staticClass:"m-0 h-[23px] relative",staticStyle:{"--bg":"#fff"}},[r("div",{staticClass:"rounded-full absolute left-1/2 top-1/2 z-[1] w-7 h-7 flex items-center justify-center border-none bg-gray-100",class:t.iconClasses,staticStyle:{transform:"translate(-50%, calc(-50% + 8px))","box-shadow":"0 0 0 2px var(--bg)"}},[t.loading?t._e():r("BaseIcon",{attrs:{type:t.icon,size:"14"}})],1)]),r("div",{staticClass:"ml-7 min-w-0 flex-grow flex flex-col pt-1"},[t.loading?[r("CSkeleton",{staticClass:"max-w-md text-gray-900 font-medium",class:t.titleSize,attrs:{width:"80%"}}),r("CSkeleton",{staticClass:"text-gray-600",class:t.textSize,attrs:{width:"40%"}}),r("CSkeleton",{staticClass:"text-center text-gray-500 text-xs inline-flex pt-0.5",class:t.dateSize,attrs:{hidden:""}})]:t._e(),r("div",{staticClass:"max-w-md font-medium",class:[t.isFuture?"text-gray-500":"text-gray-700",t.titleSize]},[t.template?r("DynamicLink",{attrs:{template:t.template}}):[t._v(t._s(t.title))]],2),t.content?r("div",{class:[t.isFuture?"text-gray-400":"text-gray-600",t.textSize]},[r("div",{domProps:{innerHTML:t._s(t.content)}})]):t._e(),r("div",{staticClass:"text-center text-gray-500 inline-flex pt-1",class:t.dateSize},[r("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.date,expression:"date"}]},[t._v(t._s(t.dayOfMonth)+" "+t._s(t.month))])])],2)])},Dft=[],Mft=he(Aft,Oft,Dft,!1,null,null,null,null);const Pft=Mft.exports,Ift={name:"DocumentTimeline",i18nOptions:{namespaces:"documentTimeline",messages:{sv:{clientName:"Kunden",byName:"Av {{- name}}",withBankId:"med BankID",propertyDesignation:"Begäran om fastighetsbeteckning",viewed:"Granskat",viewedContent:"{{- name}} har visat dokumentet",statusChangedAccepted:"Dokumentet har blivit signerat",statusChangedDenied:"Dokumentet har blivit nekat",requestChange:"Markerades manuellt som",mailOpened:"Mail visat",mailOpenedContent:"{{email}} visat",mailDropped:"E-post kunde inte skickas",smsDropped:"SMS kunde inte skickas",expired:"Dokumentet har förfallit",expiredContent:"Giltighetstiden har passerats",toEmail:"Till: {{email}}"},en:{clientName:"Client",byName:"By {{- name}}",withBankId:"with BankID",propertyDesignation:"Request for property designation",viewed:"Viewed",viewedContent:"{{- name}} has viewed the document",statusChangedAccepted:"The document has been signed",statusChangedDenied:"The document has been declined",requestChange:"Manually marked as",mailOpened:"Email opened",mailOpenedContent:"{{email}} viewed",mailDropped:"Could not send email",smsDropped:"Could not send SMS",expired:"Expired",expiredContent:"The expiration date has passed",toEmail:"To: {{email}}"}}},components:{EventItem:Pft},props:{document:{type:Object,required:!0},colors:{type:Object,default:()=>({})},size:{type:String,default:""}},computed:{...Ut({userById:"companyUsers/byId"}),events(){var i,a;const n=[this.formatEvent({code:"created",createdAt:(i=this.document)==null?void 0:i.createdAt})],{events:t,scheduledFirstDelivery:r}=this.document||{};if((r==null?void 0:r.status)==="active"){const o=r.deliveryTypes.join(` ${this.$t("_common:and")} `);n.push({title:this.$t("_common:scheduledDelivery"),content:`${this.$t("_common:via")} ${o}, ${this.$formatDate(r.sendAt)}`,isFuture:!0,icon:"calendar",color:((a=this.colors)==null?void 0:a.scheduledDelivery)||"primary"})}return t==null||t.forEach(o=>n.push(this.formatEvent(o))),n}},methods:{formatEvent({code:n,data:t,createdAt:r,children:i=[]}){var g;const{client:a={},clients:o,email:s,status:c,counter:l,sendSource:u,companyUserId:d}=t||{},p=l||i.length+1,f=a.name,h={created:()=>({title:this.$t("_common:created"),createdAt:r,icon:"folder",color:"primary"}),viewed:()=>({title:this.$t("viewed"),content:(f?this.$t("viewedContent",{name:f}):"")+(p?` ${this.$tc("_common:times",{count:p})}`:""),createdAt:r,icon:"eye",color:"primary"}),accepted:()=>{var b;const y={title:this.$t("_common:status.signed"),content:f?this.$t("byName",{name:f}):"",createdAt:r,icon:"check",color:"primary"};return y.content&&((b=a.answerMethod)==null?void 0:b.accept)==="bankId"&&(y.content+=` ${this.$t("withBankId")}`),y},denied:()=>({title:this.$t("_common:status.denied"),content:f?this.$t("byName",{name:f}):"",createdAt:r,icon:"x",color:"primary"}),sent:()=>{let y=this.$t("_common:sent");return["reminder","propertyDesignation"].includes(u)&&(y=this.$t("_common:sentThing",{thing:u==="reminder"?this.$t("_common:reminder"):this.$t("propertyDesignation")})),{title:y,content:o==null?void 0:o.map(b=>["email","cellphone"].filter(w=>!!b[w]).map(w=>b[w]).join(` ${this.$t("_common:and")} `)).reduce((b,w)=>b?`${b}<div>${w}</div>`:`${this.$t("_common:to")}: ${w}`.capitalize(),""),createdAt:r,icon:u==="reminder"?"bell":"send",color:"primary"}},statusChanged:()=>["accepted","denied"].includes(c)?{title:c==="accepted"?this.$t("statusChangedAccepted"):this.$t("statusChangedDenied"),createdAt:r,icon:c==="accepted"?"check":"x",color:c==="accepted"?"green":"red"}:null,requestChange:()=>{var b;const y=((b=this.userById(d))==null?void 0:b.fullName)||"";return{title:`${this.$t("requestChange")} ${this.$t(`_common:status.${c}`)}`,content:y&&this.$t("byName",{name:y}),createdAt:r,icon:"tool",color:"primary"}},mailDelivered:()=>({title:this.$t("_common:sentThing",{thing:this.$t("_common:email").capitalize()}),content:s?`${this.$t("_common:to")}: ${s}`.capitalize():"",createdAt:r,icon:"inbox",color:"primary"}),mailOpened:()=>({title:this.$t("mailOpened"),content:`${this.$t("mailOpenedContent",{email:s})} ${p?this.$tc("_common:times",{count:p}):""}`,createdAt:r,icon:"email",color:"primary"}),mailDropped:()=>({title:this.$t("mailDropped"),content:s?this.$t("toEmail",{email:s}):null,createdAt:r,icon:"alert-triangle",color:"orange"}),smsDropped:()=>({title:this.$t("smsDropped"),content:t?`${this.$t("_common:to")}: ${t}`.capitalize():"",createdAt:r,icon:"alert-triangle",color:"orange"}),expired:()=>({title:this.$t("expired"),content:this.$t("expiredContent"),createdAt:r,icon:"moon",color:"gray"})},m=(g=this.colors)==null?void 0:g[n];return{...h[n](),...m&&{color:m}}}}};var Rft=function(){var t=this,r=t._self._c;return r("div",[t._t("header"),t._l(t.events,function(i,a){return r("EventItem",{key:a,attrs:{title:i.title,content:i.content,createdAt:i.createdAt,icon:i.icon,color:i.color,"is-future":i.isFuture,size:t.size}})})],2)},Lft=[],Fft=he(Ift,Rft,Lft,!1,null,null,null,null);const Nft=Fft.exports,Bft={name:"DocTimeline",components:{StatusBadge:kft,DocumentTimeline:Nft},props:{document:{type:Object,required:!0},showHeader:{type:Boolean,default:!0},viewType:{type:String,default:"modal"}}};var jft=function(){var t=this,r=t._self._c;return r("div",{class:{"p-8":t.viewType!=="mount"}},[r("DocumentTimeline",{attrs:{document:t.document,size:"large"}},[t.showHeader?r("div",{staticClass:"border-b mb-4 pb-4",attrs:{slot:"header"},slot:"header"},[r("div",{staticClass:"mb-2"},[r("div",{staticClass:"text-xs text-gray-600",domProps:{textContent:t._s(t.$t("_common:document").capitalize())}}),r("div",{staticClass:"font-semibold text-lg"},[t._v(t._s(t.document.name))])]),r("div",{staticClass:"inline-flex items-center -ml-2"},[r("div",{staticClass:"text-xs text-gray-600 mr-1.5 py-1 pl-2",domProps:{textContent:t._s(t.$t("_common:status.status"))}}),r("StatusBadge",{attrs:{status:t.document.status}})],1)]):t._e()])],1)},zft=[],Vft=he(Bft,jft,zft,!1,null,null,null,null);const Uft=Vft.exports,Hft=Object.freeze(Object.defineProperty({__proto__:null,default:Uft},Symbol.toStringTag,{value:"Module"})),Wft={name:"DocumentReceipt",i18nOptions:{namespaces:"documentReceipt",messages:{sv:{title:"Verifikat på signering",waitingForSign:"Väntar på signatur",signMethod:"Signeringsmetod",remaining:"{{count}} st signaturer kvarstår innan dokumentet är helt signerat.",confirmChangeMessage:"Vill du verkligen byta signeringsmetod för {{- name}}?",bankIdHint:"Identifiering och signering säkerställd med BankID."},en:{title:"Signature verification",waitingForSign:"Waiting for signature",signMethod:"Sign method",remaining:"{{count}} signatures are remaining before the document is completely signed.",confirmChangeMessage:"Do you really want to change sign method for {{- name}}?",bankIdHint:"Identity and signature confirmed with BankID"}}},props:{document:{type:Object,required:!0},allowSignMethodUpdate:{type:Boolean,default:!0}},computed:{...Ut({feature:"application/feature"}),signees(){const{senderClient:n,clients:t}=this.document;return[...n?[n]:[],...(t||[]).map((i,a)=>({...i,index:a}))].filter(i=>{var a;return["signee","approver"].includes(i.documentRole)||((a=i.answer)==null?void 0:a.didAccept)}).map(({name:i="",companyName:a,email:o,socialNo:s=null,answerMethod:c,answer:l,documentRole:u,index:d})=>({name:i||a||o,socialNo:s,method:(c==null?void 0:c.accept)||"",documentRole:u,...l,index:d}))},waitingFor(){return this.document.recipients.reduce((n,t)=>{var r;return t.answer||!["signee","approver"].includes(t.documentRole)||((r=t.answerMethod)==null?void 0:r.accept)==="inPerson"?n:[...n,t]},[])},documentName(){return this.document.name||""},sentByName(){var n,t;return((t=(n=this.document.sender)==null?void 0:n.user)==null?void 0:t.name)||""}},methods:{...xn({showMessage:We.SHOW_MESSAGE,updateDocument:We.UPDATE_DOCUMENT2}),getIconType(n){return n==="signee"?"pen-tool":n==="recipient"?"eye":n==="approver"?"check":"shield"},getBrowserString({browser:n,os:t,device:r}){return[n==null?void 0:n.name,t==null?void 0:t.name,r==null?void 0:r.model].filter(i=>!!i).join(", ")},onUpdate(n,t){this.showMessage({displayType:"dialog",type:"secondary",title:this.$t("_common:change",{thing:this.$t("_common:signMethod.title").toLowerCase()}),message:this.$t("confirmChangeMessage",{name:n.name}),actions:{cancel:{text:this.$t("_common:cancel"),callback:"cancel"},submit:{text:this.$t("actions:updateDocumentDialog.submit"),callback:()=>this.updateSignMethod(n.index,t)}}})},async updateSignMethod(n,t){const{id:r}=this.document||{},i={[`clients.${n}.answerMethod.accept`]:t};await this.updateDocument({id:r,body:i,params:{type:"paths"}})}}};var Gft=function(){var t=this,r=t._self._c;return r("div",{staticClass:"rounded-lg text-gray-600 pt-4 px-1 pb-1 bg-gray-100 border border-gray-200"},[r("div",{staticClass:"mb-1 relative leading-5"},[r("div",{staticClass:"pl-4 pb-1"},[r("div",{staticClass:"font-medium text-black"},[t._v(t._s(t.$t("title")))]),r("div",{staticClass:"data-label"},[t._v(t._s(t.documentName))]),r("div",{staticClass:"grid grid-cols-3 gap-2 pb-1 pt-4",staticStyle:{"grid-template-columns":"repeat(auto-fit, minmax(200px, 1fr))"}},[t._l([[t.$t("_common:sentByName"),t.sentByName],[t.$t("_components:status.sent"),t.$formatDate(t.document.sentAt,"Pp")],[t.$t("_components:replyBy"),t.document.status==="sent"&&t.$formatDate(t.document.expiresAt)],[t.$t("_components:status.accepted"),t.$formatDate(t.document.acceptedAt,"Pp")]],function([i,a],o){return[a?r("div",{key:o},[r("div",{staticClass:"text-gray-900 text-xs",domProps:{textContent:t._s(i)}}),r("div",{staticClass:"text-gray-600 mr-1.5",domProps:{textContent:t._s(a)}})]):t._e()]})],2)]),t.waitingFor.length?r("div",{staticClass:"mt-2 inline-flex items-center text-xs font-medium bg-orange-50 border border-orange-200/90 px-1 py-0.5 rounded-full ml-3 text-black/80"},[r("BaseIcon",{staticClass:"text-orange-500/80",attrs:{type:"info",size:"14"}}),r("div",{staticClass:"px-1.5"},[t._v(" "+t._s(t.$t("remaining",{count:t.waitingFor.length}))+" ")])],1):t._e(),r("BaseIcon",{staticClass:"absolute top-1 right-5 text-gray-500",attrs:{type:"lock",size:"18"}})],1),r("div",{staticClass:"flex flex-col gap-2 p-2"},t._l(t.signees,function(i,a){var o,s;return r("div",{key:a,staticClass:"bg-white relative text-gray-700 border border-gray-200 rounded-md"},[r("div",{staticClass:"px-4 py-3"},[i.didAccept&&i.method==="bankId"?r("BaseIcon",{staticClass:"absolute top-3 right-4",attrs:{type:"bankIdColor",size:"22"}}):i.didAccept?r("BaseIcon",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.$t(`_common:documentRole.${i.documentRole}.label`),expression:"$t(`_common:documentRole.${signee.documentRole}.label`)"}],staticClass:"lock-icon absolute right-6 top-4 opacity-70",attrs:{size:18,type:t.getIconType(i.documentRole)}}):t._e(),i.didAccept===!1?r("div",{staticClass:"absolute right-3 top-3 bg-red-200 border border-red-400/50 rounded-full text-xs py-0.5 px-2 inline-flex font-medium text-red-700"},[t._v(" "+t._s(t.$t("_common:denied").capitalize())+" ")]):!i.didAccept&&i.method!=="inPerson"?r("div",{staticClass:"absolute right-3 top-3 bg-orange-50 border border-orange-200/70 rounded-full text-xs py-0.5 px-2 inline-flex font-medium text-black/80"},[t._v(" "+t._s(t.$t("waitingForSign"))+" ")]):t._e(),r("div",{staticClass:"font-medium text-[15px] text-black pb-1"},[t._v(" "+t._s(((o=i.response)==null?void 0:o.name)||i.name)+" ")]),r("div",{staticClass:"grid grid-cols-3 gap-2 py-1",staticStyle:{"grid-template-columns":"repeat(auto-fit, minmax(190px, 1fr))"}},[t._l([[t.$t("_common:socialNo").capitalize(),i.socialNo],[t.$t("signMethod"),t.$t(`_common:signMethod.${i.method}`),"signMethod"],[`${t.$t("_common:date").capitalize()} & ${t.$t("_common:time.time")}`,t.$formatDate(i.didAnswerAt,"Pp")],["IP-"+t.$t("_common:address"),i.ip],[`${t.$t("_common:browser")}, OS & ${t.$t("_common:device")}`,t.getBrowserString(i)]],function([c,l,u],d){return[l?r("div",{key:d,staticClass:"text-[13px]"},[r("div",{staticClass:"text-gray-900",domProps:{textContent:t._s(c)}}),r("div",{staticClass:"flex items-center"},[r("div",{staticClass:"text-gray-500 mr-1.5",domProps:{textContent:t._s(l)}}),u==="signMethod"&&i.method&&t.allowSignMethodUpdate&&t.document.status!=="accepted"&&i.didAccept===void 0?r("CDropdown",{attrs:{"append-to-body":!0,"menu-styling":{width:"180px"}}},[r("div",{staticClass:"underline text-primary-500 font-medium text-xs",attrs:{slot:"trigger"},domProps:{textContent:t._s(t.$t("_common:change"))},slot:"trigger"}),t._l([...t.feature("bankId")?["bankId"]:[],"signature","inPerson"],function(p){return r("CDropdownItem",{key:p,attrs:{"icon-right":i.method===p?"check":""},on:{click:function(f){i.method!==p&&t.onUpdate(i,p)}}},[t._v(" "+t._s(t.$t(`_common:signMethod.${p}`))+" ")])})],2):t._e()],1)]):t._e()]})],2)],1),i.signatureDataURL?r("div",{staticClass:"h-20 mx-4 py-6 border-t border-gray-100"},[r("img",{staticClass:"h-full",attrs:{src:i.signatureDataURL}})]):i.didAccept&&i.method==="bankId"?r("div",{staticClass:"bg-gray-300 mx-4 mb-4 text-white/90 flex items-center p-1.5 rounded-md",staticStyle:{border:"1px solid #35677e"},style:"background: linear-gradient(45deg,hsl(200deg 35% 17%),hsl(199deg 25% 30%));"},[r("div",{staticClass:"rounded-md w-9 h-9 flex items-center justify-center mr-2 ml-0.5 bg-[#183e4f] border border-[#275369]"},[r("BaseIcon",{attrs:{type:"bankId",size:"22"}})],1),r("div",[r("div",{staticClass:"text-xs font-medium",domProps:{textContent:t._s(t.$t("bankIdHint"))}}),r("div",{staticClass:"text-xs opacity-70"},[t._v(" "+t._s(((s=i.response)==null?void 0:s.name)||i.name)+" · "+t._s(i.socialNo)+" ")])])]):t._e()])}),0)])},qft=[],Yft=he(Wft,Gft,qft,!1,null,null,null,null);const Kft={name:"DocReceipt",components:{DocumentReceipt:Yft.exports},props:{document:{type:Object,required:!0}}};var Zft=function(){var t=this,r=t._self._c;return r("div",[r("DocumentReceipt",{attrs:{document:t.document,"allow-sign-method-update":!1}})],1)},Jft=[],Xft=he(Kft,Zft,Jft,!1,null,null,null,null);const Qft=Xft.exports,eht=Object.freeze(Object.defineProperty({__proto__:null,default:Qft},Symbol.toStringTag,{value:"Module"})),tht={name:"DocLinks",components:{ClientLinks:_Y},props:{document:{type:Object,required:!0},closeFunc:{type:Function,default:null}},methods:{close(){this.closeFunc&&this.closeFunc()}}};var nht=function(){var t=this,r=t._self._c;return r("div",{staticClass:"h-full w-full overflow-auto"},[r("ClientLinks",{attrs:{id:t.document.id},on:{close:t.close}})],1)},rht=[],iht=he(tht,nht,rht,!1,null,null,null,null);const aht=iht.exports,oht=Object.freeze(Object.defineProperty({__proto__:null,default:aht},Symbol.toStringTag,{value:"Module"})),IY=({documentKey:n="document"}={})=>({mixins:[br],inject:{formValidation:{default:null}},methods:{isValid(){const{isFormValid:t,scrollToInvalidInput:r}=this.formValidation||this;return!t||!r||t()?!0:r({offset:120})},isAnswerModalOpen(){const t=this.$modal.getOpenInstances();return t&&t.length&&t.some(r=>{var i;return((i=r.modalAttrs)==null?void 0:i.name)==="AnswerModal"})},onAnswer(t="accept",r={}){if(this.isAnswerModalOpen())return;const i=Ce(this,n);if(!i)return;const a=t==="decline"?!0:this.isValid();if(!i.isPreview&&!a)return;const o=this.mq==="sm"?"100%":"auto",s=()=>Promise.resolve().then(()=>Ddt);this.$modal.show(s,{mode:t,_document:i,fullScreen:o==="100%",calcHeight:!!r.calcHeight},{name:"AnswerModal",adaptive:!0,height:"auto",width:"90%",maxWidth:420,classes:"overflow-visible",transition:"modal-soft",clickToClose:!1})}}}),sht=n=>{var t;return(t=window==null?void 0:window.parent)==null?void 0:t.postMessage(n,"*")},RY=n=>typeof n=="object"&&"event"in n;class lht{constructor(){this.observers={},this.registered=!0,window.addEventListener("message",this._onMessage.bind(this))}_onMessage(t){if(t.source===window.parent&&RY(t==null?void 0:t.data)){const{event:r,data:i}=t.data;this.observers[r]&&this.observers[r].forEach(a=>a(i))}}on(t,r){this.registered||window.addEventListener("message",this._onMessage.bind(this)),this.observers[t]=this.observers[t]||[],this.observers[t].push(r)}off(t,r){if(this.observers[t]){if(!r){delete this.observers[t];return}this.observers[t]=this.observers[t].filter(i=>i!==r)}}emit(t){if(!RY(t))throw new Error("Invalid message, must be an object including an event property");sht(t)}destroy(){window.removeEventListener("message",this._onMessage.bind(this)),this.registered=!1}}const LY=new lht,cht={name:"DocumentVoided",props:{document:{type:Object,required:!0}}};var uht=function(){var t=this,r=t._self._c;return r("div",{staticClass:"grid h-full text-center place-items-center"},[r("div",{staticClass:"py-12"},[r("BaseIcon",{staticClass:"mb-2 text-primary-500",attrs:{type:"info"}}),r("div",{staticClass:"text-lg font-medium",domProps:{textContent:t._s(t.document.$t("documentVoided.title"))}}),r("div",{staticClass:"text-gray-700",domProps:{textContent:t._s(t.document.$t("documentVoided.description"))}})],1)])},dht=[],pht=he(cht,uht,dht,!1,null,null,null,null);const FY=pht.exports,NY=Ne.observable({canEdit:!1,isForm:!1,setFormValue:null}),fht={props:{document:{type:Object,required:!0},setFormValue:{type:Function,required:!0}},components:{DocumentLayout:C8,DocumentVoided:FY},mixins:[cq,IY()],provide:()=>({viewSettings:NY}),created(){this.setFormValue&&(NY.setFormValue=this.setFormValue),LY.on("answer",this.onAnswerMessage)},beforeDestroy(){LY.off("answer",this.onAnswerMessage)},methods:{onAnswerMessage(n){this.onAnswer(n==null?void 0:n.mode)}}};var hht=function(){var i;var t=this,r=t._self._c;return r("div",[t._t("default"),((i=t.document)==null?void 0:i.status)==="voided"?r("DocumentVoided",{attrs:{document:t.document}}):r("DocumentLayout",{attrs:{document:t.document}})],2)},mht=[],ght=he(fht,hht,mht,!1,null,null,null,null);const vht={name:"DocumentClient",components:{ClientView:ght.exports},props:{document:{type:Object,required:!0},setFormValue:{type:Function,required:!0}}};var yht=function(){var t=this,r=t._self._c;return r("ClientView",{attrs:{document:t.document,"set-form-value":t.setFormValue}})},bht=[],_ht=he(vht,yht,bht,!1,null,null,null,null);const wht=_ht.exports,xht=Object.freeze(Object.defineProperty({__proto__:null,default:wht},Symbol.toStringTag,{value:"Module"})),Cht={name:"Setup",props:{partnerName:{type:String,default:"Partner"},closeFunc:{type:Function,default:()=>{}}},computed:{baseAppUrl(){return Xe.baseUrl},iframeUrl(){return`${this.baseAppUrl}/partner/connect?partnerName=${this.partnerName}`}},created(){window.addEventListener("message",this.onReceiveMessage)},beforeDestroy(){window.removeEventListener("message",this.onReceiveMessage)},methods:{onReceiveMessage({data:n,origin:t,source:r}){var i;t===this.baseAppUrl&&((n==null?void 0:n.type)==="channelPartnerConnect"&&(r==null||r.postMessage({type:"readyForPartnerConnect"},t)),(n==null?void 0:n.type)==="partnerUserConnect"&&(Pr.trigger("account:userConnect",n==null?void 0:n.value),(i=this.closeFunc)==null||i.call(this)))}}};var kht=function(){var t=this,r=t._self._c;return r("iframe",{staticClass:"w-full h-full",attrs:{title:"Partner Connect",src:t.iframeUrl,frameborder:"0"}})},Sht=[],Tht=he(Cht,kht,Sht,!1,null,null,null,null);const Eht=Tht.exports,$ht=Object.freeze(Object.defineProperty({__proto__:null,default:Eht},Symbol.toStringTag,{value:"Module"})),Aht={components:{AnswerModal:G7},props:{document:{type:Object,required:!0},answerType:{type:String,required:!0},closeFunc:{type:Function,default:null}}};var Oht=function(){var t=this,r=t._self._c;return r("AnswerModal",{attrs:{mode:t.answerType,_document:t.document},on:{close:t.closeFunc}})},Dht=[],Mht=he(Aht,Oht,Dht,!1,null,null,null,null);const Pht=Mht.exports,Iht=Object.freeze(Object.defineProperty({__proto__:null,default:Pht},Symbol.toStringTag,{value:"Module"}));var Rht=he({name:"PublicDocumentEvents",props:{document:{type:Object,default:()=>({})}},computed:{events(){const n=[],{acceptedAt:t}=this.document;return this.document.events.filter(({createdAt:r})=>t?L4(t,r):!0).forEach(r=>{const{code:i,createdAt:a,children:o=[]}=r;let{data:s={}}=r;s===null&&(s={});const{client:c={},clients:l=[],status:u,counter:d}=s,p={sent:()=>l.map(f=>{const h=this.getClientName(f.id),m=this.filteredOxfordComma([f.email,f.cellphone]);return{text:this.document.$t("event.sent",{to:`${h?h+", ":""}${m}`}),time:a}}),viewed:()=>{const f=d||o.length+1;return[{text:`${this.document.$t(`event.${c.name?"viewedName":"viewed"}`,{name:c.name})} ${f?this.document.$tc("times",{count:f}):""}.`,time:a}]},accepted:()=>[{text:this.document.$t("event.accepted",{by:c.name||c.email||c.cellphone}),time:a}],denied:()=>[{text:this.document.$t("event.denied",{by:c.name||c.email||c.cellphone}),time:a}],statusChanged:()=>[{text:this.document.$t("event.statusChanged",{status:this.document.$t(`status.${u}`).toLowerCase()}),time:a}],requestChange:()=>[{text:this.document.$t("event.requestChange",{status:this.document.$t(`status.${u}`).toLowerCase()}),time:a}],expired:()=>[{text:this.document.$t("event.expired"),time:a}]};p[i]&&n.push(...p[i]())}),n}},methods:{filteredOxfordComma(n=[]){const t=n.filter(i=>!!i),r=t.length;return r?r<2?t[0]:`${t.slice(0,-1).join(", ")} ${this.document.$t("and")} ${t.slice(-1)}`:""},getClientName(n){const t=this.document.clients.find(({id:r})=>r===n);return t?t.name:""}},render(){return this.$scopedSlots.default({events:this.events})}},null,null,!1,null,null,null,null);const Lht=Rht.exports;var Fht=he({name:"CPhoneFormat",props:{phone:{type:String,required:!1,default:""},region:{type:String,required:!1,default:null}},data(){return{formattedPhone:""}},watch:{phone:{immediate:!0,async handler(){this.doFormatPhone()}}},methods:{async doFormatPhone(){if(!this.phone){this.formattedPhone="";return}const n=await uM(this.phone,{defaultRegion:this.region});if(!n){this.formattedPhone=this.phone;return}this.formattedPhone=n.national}},render(){return this.$scopedSlots.default?this.$scopedSlots.default({formattedValue:this.formattedPhone}):xte("span",[this.formattedPhone])}},null,null,!1,null,null,null,null);const BY=Fht.exports,eDt="",tDt="",Nht={name:"PublicRecipientItem",i18nOptions:{namespaces:"components",keyPrefix:"document.myPagesDrawer"},components:{CPhoneFormat:BY},props:{recipient:{type:Object,required:!0}},methods:{get:Ce,getBrowserString({browser:n,os:t,device:r}){return[n&&n.name,t&&t.name,r&&r.model].filter(i=>!!i).join(", ")}}};var Bht=function(){var t=this,r=t._self._c;return r("div",{staticStyle:{border:"1px solid hsl(0, 0%, 84%)","border-radius":"3px","margin-bottom":"1em"}},[r("div",{staticStyle:{padding:"0.5em 0.75em"}},[t._l([t.recipient.name,t.recipient.companyName,t.recipient.orgNo],function(i,a){return r("span",{key:`${i}-${a}`,style:a===0?{fontWeight:500}:{opacity:.65}},[t._v(" "+t._s(i&&a>0?"·":"")+" "+t._s(i)+" ")])}),r("div",{staticClass:"flex flex-col w-full",staticStyle:{"font-size":"14px","align-items":"baseline"}},[t.recipient.email?r("a",{attrs:{href:`mailto:${t.recipient.email}`,target:"_blank"}},[t._v(" "+t._s(t.recipient.email)+" ")]):t._e(),t.recipient.cellphone?r("CPhoneFormat",{attrs:{phone:t.recipient.cellphone,region:t.recipient.cellphoneRegion},scopedSlots:t._u([{key:"default",fn:function({formattedValue:i}){return r("a",{attrs:{href:`tel:${t.recipient.cellphone}`}},[t._v(" "+t._s(i)+" ")])}}],null,!1,2469850174)}):t._e()],1)],2),r("div",{staticStyle:{"background-color":"hsl(0, 0%, 94%)",padding:"0.75em 0.75em","font-weight":"500","font-size":"13px","line-height":"1",color:"hsl(0, 0%, 40%)",position:"relative"}},[r("div",[t._v(" "+t._s(t.$t(`_common:documentRole.${t.recipient.documentRole}.label`))+" ")]),r("div",{staticStyle:{position:"absolute",right:"1em",top:"0px",transform:"translate(0, -50%)"}},[r("v-popover",{attrs:{"popover-inner-class":"signee-popover",trigger:"hover",placement:"bottom-end"}},[t.recipient.documentRole==="signee"?r("div",{staticStyle:{padding:"5px 0.75em",background:"hsl(0, 0%, 60%)","border-radius":"4px","font-size":"13px",color:"hsl(0, 0%, 100%)",cursor:"default",display:"inline-flex","align-items":"center"}},[r("BaseIcon",{staticStyle:{"margin-right":"0.5ch"},attrs:{size:15,type:"info","stroke-width":"2"}}),t.recipient.answer&&t.recipient.answer.didAccept?[t._v(" "+t._s(t.$t("_common:approved").capitalize())+" ")]:t.recipient.answer?[t._v(" "+t._s(t.$t("_common:denied").capitalize())+" ")]:[t._v(" "+t._s(t.$t("views:publicDocument.pdfVerification.waitingForAnswer"))+" ")]],2):t._e(),r("div",{staticStyle:{padding:"0"},attrs:{slot:"popover"},slot:"popover"},[r("div",{staticStyle:{padding:"1em 1.5em"}},[t.recipient.answer&&t.recipient.answer.didAccept?[t.recipient.answer.signatureDataURL?r("div",{staticStyle:{"padding-bottom":"0.5em"}},[r("div",{staticClass:"has-text-grey",staticStyle:{"padding-bottom":"1em"}},[t._v(" "+t._s(t.$t("_common:signature").capitalize())+" ")]),r("img",{staticStyle:{width:"80%"},attrs:{src:t.recipient.answer.signatureDataURL}})]):r("div",{staticStyle:{"font-size":"13px","padding-top":"3px"}},[t.get(t.recipient,"answerMethod.accept")==="bankId"?[r("div",{staticStyle:{"font-weight":"500"}},[t._v(" "+t._s(t.$t("views:publicDocument.pdfVerification.recipient.signedBankId"))+" ")]),r("div",[t._v(t._s(t.recipient.answer.response.name))]),r("div",[t._v(t._s(t.recipient.socialNo))])]:t.get(t.recipient,"answerMethod.accept")==="login"?r("div",{staticStyle:{"font-weight":"500"}},[t._v(" "+t._s(t.$t("views:publicDocument.pdfVerification.recipient.verifiedLogin"))+" ")]):t._e()],2)]:t.recipient.answer?r("div",[t._v(" "+t._s(t.$t("_common:denied").capitalize())+" ")]):r("div",[t._v(" "+t._s(t.$t("pendingAnswer"))+" ")])],2),t.recipient.answer?r("div",{staticStyle:{padding:"8px 1.5em","border-top":"1px solid hsl(0deg 0% 88%)","background-color":"hsl(0deg 0% 95%)","font-size":"13px",color:"hsl(0, 0%, 35%)","font-weight":"500"}},[t.recipient.answer.didAnswerAt?r("div",[r("div",[t._v(" "+t._s(t.$t("_common:date").capitalize())+": "+t._s(t.$formatDate(t.recipient.answer.didAnswerAt,"P"))+" ")]),r("div",[t._v(" "+t._s(t.$t("_common:time.time").capitalize())+": "+t._s(t.$formatDate(t.recipient.answer.didAnswerAt,"p"))+" ")])]):t._e(),t.recipient.answer.ip?r("div",[t._v(" IP: "+t._s(t.recipient.answer.ip)+" ")]):t._e(),t.recipient.answer.browser?r("div",[t._v(" Browser: "+t._s(t.getBrowserString(t.recipient.answer))+" ")]):t._e()]):t._e()])])],1)])])},jht=[],zht=he(Nht,Bht,jht,!1,null,"7bf07f05",null,null);const Vht=zht.exports,nDt="",Uht={name:"DocumentDetails",mixins:[br],components:{PublicDocumentEvents:Lht,PublicRecipientItem:Vht,CDropdown:Of,CDropdownItem:nd},props:{document:{type:Object,required:!0},openPrintFunc:{type:Function,default:null}},data(){return{docLanguages:pM,nativeTranslations:ave}},computed:{viewer(){return this.document.viewer}},methods:{changeLanguage(n){this.document.language=n,this.$root.$i18n.i18next.changeLanguage(JA.includes(n)?n:"en")}}};var Hht=function(){var t=this,r=t._self._c;return r("div",{staticStyle:{width:"100%",height:"100%",display:"flex","flex-direction":"column","font-size":"16px",background:"hsl(0, 0%, 100%)","border-radius":"10px",overflow:"hidden","box-shadow":"0 10px 20px rgba(0, 0, 0, 0.2)",position:"relative"}},[r("div",{staticClass:"flex w-full justify-end items-center",staticStyle:{position:"absolute",top:"20px",right:"20px","z-index":"2"}},[t.openPrintFunc?[r("CButton",{staticStyle:{"padding-left":"1em","padding-right":"1em"},attrs:{"icon-left":"print",type:"none",pattern:"tertiary",taller:"",size:"small"},on:{click:t.openPrintFunc}},[t._v(" "+t._s(t.document.$t("download",{thing:"PDF"}))+" ")]),r("div",{staticStyle:{height:"2rem",width:"1px","background-color":"hsl(0, 0%, 88%)",margin:"0 6px"}})]:t._e(),r("CDropdown",{attrs:{value:t.document.language}},[r("CButton",{staticStyle:{color:"hsla(0, 0%, 45%, 1)"},attrs:{slot:"trigger","icon-props":{size:18},size:"normal",icon:"globe",circle:""},slot:"trigger"}),t._l(t.docLanguages,function(i){return r("CDropdownItem",{key:i,attrs:{value:i},on:{click:function(a){return t.changeLanguage(i)}}},[t._v(" "+t._s(t.nativeTranslations[i])+" ")])})],2),r("CButton",{staticStyle:{"margin-left":"6px",color:"hsla(0, 0%, 45%, 1)"},attrs:{"icon-props":{size:18},size:"normal",icon:"x",circle:""},on:{click:function(i){return t.$emit("close")}}})],2),r("div",{staticClass:"d-root"},[r("div",{staticClass:"flex justify-between",staticStyle:{"margin-bottom":"3em"}},[r("div",[r("div",{staticStyle:{"font-size":"18px","font-weight":"600"}},[t._v(" "+t._s(t.document.$t("detail_plural").capitalize())+" ")]),r("div",{staticClass:"has-text-grey",staticStyle:{"font-size":"14px"}},[t._v(" "+t._s(t.document.$t("documentDetails.subTitle"))+" ")])])]),r("div",{staticClass:"d-option",staticStyle:{"margin-bottom":"3em"}},[r("div",{staticClass:"d-option-title",staticStyle:{"padding-bottom":"0.5rem"}},[t._v(" "+t._s(t.document.$t("participant_plural").capitalize())+" ")]),t._l(t.document.recipients,function(i,a){return r("PublicRecipientItem",{key:i._uniqueId+a,attrs:{recipient:i}})})],2),r("PublicDocumentEvents",{attrs:{document:t.document},scopedSlots:t._u([{key:"default",fn:function({events:i}){return[i&&i.length?r("div",{staticClass:"d-option"},[r("div",{staticClass:"d-option-title"},[t._v(" "+t._s(t.document.$t("event.event_plural").capitalize())+" ")]),r("div",{attrs:{id:"timeline"}},[r("div",t._l(i,function(a,o){return r("div",{key:o,staticClass:"e-item"},[r("div",{staticClass:"e-data"},[r("div",{staticClass:"e-text"},[t._v(t._s(a.text))]),r("div",{staticClass:"e-timestamp"},[r("div",{staticClass:"e-date"},[t._v(t._s(t.$formatDate(a.time,"P")))]),r("div",{staticClass:"e-time",staticStyle:{"padding-left":"0.5ch"}},[t._v(" "+t._s(t.$formatDate(a.time,"p"))+" ")])])])])}),0)])]):t._e()]}}])}),t.mq==="sm"?r("div",[t._t("footer")],2):t._e()],1),t.mq!=="sm"?r("div",[t._t("footer")],2):t._e()])},Wht=[],Ght=he(Uht,Hht,Wht,!1,null,"0d868038",null,null);const qht=Ght.exports,rDt="",Yht={components:{DocumentDetails:qht,DocumentVoided:FY},props:{document:{type:Object,required:!0},closeFunc:{type:Function,default:null}}};var Kht=function(){var t=this,r=t._self._c;return t.document&&t.document.status==="voided"?r("DocumentVoided",{attrs:{document:t.document}}):r("DocumentDetails",{attrs:{document:t.document},on:{close:t.closeFunc}})},Zht=[],Jht=he(Yht,Kht,Zht,!1,null,"d3b68450",null,null);const Xht=Jht.exports,Qht=Object.freeze(Object.defineProperty({__proto__:null,default:Xht},Symbol.toStringTag,{value:"Module"})),iDt="",emt={name:"DocModalBase",components:{},props:{showClose:{type:Boolean,default:!1}}};var tmt=function(){var t=this,r=t._self._c;return r("div",{staticClass:"doc-modal-base"},[t.showClose?r("CButton",{staticClass:"absolute text-gray-500 top-4 right-4",attrs:{circle:"",icon:"x"},on:{click:function(i){return t.$parent.$emit("close")}}}):t._e(),t._t("default")],2)},nmt=[],rmt=he(emt,tmt,nmt,!1,null,"b672a873",null,null);const jY=rmt.exports,imt={i18nOptions:{namespaces:"components",keyPrefix:"document.propertyDesignationModal"},mixins:[br],components:{DocModalBase:jY},props:{senderName:{type:String,required:!0},propertyDesignation:{type:Object,default:null},fullScreen:{type:Boolean,default:!1}},data(){return{cornerRadius:0,spacing:0,view:"start",form:"",realEstateId:"",condominiumId:null,condominiumOrgNo:null}},validations:{condominiumId:{required:ln.requiredIf(n=>n.form==="condominium"),minLength:ln.minLength(4),maxLength:ln.maxLength(4)},condominiumOrgNo:{required:ln.requiredIf(n=>n.form==="condominium")},realEstateId:{required:ln.requiredIf(n=>n.form==="realEstate")}},computed:{messages(){const n=t=>this.$t(`validations.${t}`);return{condominiumId:{required:n("condominiumId.required"),minLength:n("condominiumId.minLength"),maxLength:n("condominiumId.maxLength")},condominiumOrgNo:{required:n("condominiumOrgNo.required")},realEstateId:{required:n("realEstateId.required")}}}},created(){if(this.propertyDesignation){const{propertyType:n="",propertyId:t="",condominiumOrgNo:r=null}=this.propertyDesignation;this.form=n,n==="realEstate"?this.realEstateId=t:this.condominiumId=t,this.condominiumOrgNo=r}},mounted(){this.spacing=window.getComputedStyle(this.$refs.root.$el).paddingTop,this.cornerRadius=window.getComputedStyle(this.$refs.root.$el).borderRadius},methods:{...xn({putCurrentDoc:We.PUT_CURRENT_PUBLIC_DOCUMENT,reloadCurrentDocument:We.RELOAD_CURRENT_DOCUMENT}),async updateClientPropertyDesignation(){if(this.$v.$touch(),this.$v.$invalid)return;const n={propertyType:this.form,propertyId:this.form==="realEstate"?this.realEstateId:this.condominiumId,...this.form==="condominium"&&{condominiumOrgNo:this.condominiumOrgNo}};try{const t="clients[0].region.propertyDesignation";await this.putCurrentDoc({body:{[t]:n}}),this.reloadCurrentDocument(),this.view="complete"}catch(t){Ir(t)}}}};var amt=function(){var t=this,r=t._self._c;return r("doc-modal-base",{ref:"root",class:[{"full-screen":t.mq==="sm"}]},[t.fullScreen?r("CButton",{staticClass:"absolute z-50 top-4 right-4",attrs:{icon:"x",circle:""},on:{click:function(i){return t.$emit("close")}}}):t._e(),r("div",[t.view!=="complete"?r("div",{staticClass:"relative pb-8 mb-8 text-center border-b border-gray-100 negate-padding bg-gray-50",style:{paddingTop:t.spacing,marginTop:`-${t.spacing}`,borderRadius:`${t.cornerRadius} ${t.cornerRadius} 0 0`}},[t.view==="start"?r("div",{key:1},[r("div",{staticClass:"mb-2 text-lg font-semibold"},[t._v(t._s(t.$t("title")))]),r("div",{staticClass:"text-gray-700"},[t._v(" "+t._s(t.$t("subTitle",{senderName:t.senderName}))+" ")])]):t._e(),t.view==="form"?r("div",{key:2},[r("CButton",{staticClass:"absolute top-4 left-4",attrs:{circle:"",icon:"arrow-left"},on:{click:function(i){t.view="start"}}}),r("div",{staticClass:"mb-2 text-lg font-semibold"},[t._v(t._s(t.$t("howToFind")))]),r("div",{staticClass:"text-gray-700"},[t._v(" "+t._s(t.$t("goto1"))+" "),r("a",{staticStyle:{"text-decoration":"underline"},attrs:{href:"https://www.lantmateriet.se/",target:"_blank",rel:"noopener"}},[t._v(" "+t._s(t.$t("goto2"))+" ")]),t._v(" "+t._s(t.$t("goto3"))+" ")])],1):t._e()]):t._e(),t.view==="start"?r("div",{key:1,staticClass:"mb-12 text-center"},[r("div",{staticClass:"mb-4 text-base font-medium"},[t._v(t._s(t.$t("whereTitle")))]),r("div",{staticClass:"flex justify-center"},[r("div",{staticClass:"mx-4"},[r("div",{staticClass:"flex items-center justify-center w-24 h-24 mb-2 border border-gray-300 cursor-pointer bg-gray-50 rounded-xl hover:bg-gray-100 active:bg-gray-200",on:{click:function(i){t.view="form",t.form="realEstate"}}},[r("svg",{staticClass:"text-gray-400",attrs:{width:"59",height:"41",viewBox:"0 0 59 59",xmlns:"http://www.w3.org/2000/svg"}},[r("g",{attrs:{fill:"currentColor","fill-rule":"evenodd"}},[r("path",{attrs:{d:"M6 28h47v29H6V28zm6 7.998101V40.0019C12 41.113294 12.89458 42 13.998101 42H18.0019C19.113294 42 20 41.10542 20 40.001899V35.9981C20 34.886706 19.10542 34 18.001899 34H13.9981C12.886706 34 12 34.89458 12 35.998101zm22-.007306V54h11V35.990795C45 34.898212 44.108144 34 43.007983 34h-7.015966C34.900177 34 34 34.89131 34 35.990795zM27.189354 1.837583C28.46549.536998 30.53366.53613 31.813677 1.840673L56.5 27h-54l9.85551-10.044348V7.141778h6.733007v2.95186l8.100837-8.256055zM25.5 15.861211v4.003797c0 1.111395.89458 1.998102 1.998101 1.998102H31.5019c1.111395 0 1.998101-.89458 1.998101-1.998102v-4.003797c0-1.111395-.89458-1.998101-1.998101-1.998101H27.4981c-1.111395 0-1.998101.89458-1.998101 1.998101z"}}),r("path",{attrs:{d:"M0 56.004882C0 54.897616.90314 54 1.996843 54h55.006314C58.105983 54 59 54.8939 59 56.004882V59H0v-2.995118z"}})])])]),r("div",{staticClass:"text-sm leading-tight text-gray-700"},[t._v(" "+t._s(t.$t("house"))),r("br"),t._v("/ "+t._s(t.$t("realEstate"))+" ")])]),r("div",{staticClass:"mx-4"},[r("div",{staticClass:"flex items-center justify-center w-24 h-24 mb-2 border border-gray-300 cursor-pointer bg-gray-50 rounded-xl hover:bg-gray-100 active:bg-gray-200",on:{click:function(i){t.view="form",t.form="condominium"}}},[r("svg",{staticClass:"text-gray-400",attrs:{width:"59",height:"50",viewBox:"0 0 59 73",xmlns:"http://www.w3.org/2000/svg"}},[r("g",{attrs:{fill:"currentColor","fill-rule":"evenodd"}},[r("path",{attrs:{d:"M6 9.004723C6 7.34526 7.343394 6 8.993614 6h41.012771C51.659714 6 53 7.342697 53 9.004723V71H6V9.004723zm5 4.993378V18.0019C11 19.113294 11.89458 20 12.998101 20H17.0019C18.113294 20 19 19.10542 19 18.001899V13.9981C19 12.886706 18.10542 12 17.001899 12H12.9981C11.886706 12 11 12.89458 11 13.998101zm14.5 0V18.0019C25.5 19.113294 26.39458 20 27.498101 20H31.5019C32.613294 20 33.5 19.10542 33.5 18.001899V13.9981C33.5 12.886706 32.60542 12 31.501899 12H27.4981C26.386706 12 25.5 12.89458 25.5 13.998101zm14.5 0V18.0019C40 19.113294 40.89458 20 41.998101 20H46.0019C47.113294 20 48 19.10542 48 18.001899V13.9981C48 12.886706 47.10542 12 46.001899 12H41.9981C40.886706 12 40 12.89458 40 13.998101zm-29 12V30.0019C11 31.113294 11.89458 32 12.998101 32H17.0019C18.113294 32 19 31.10542 19 30.001899V25.9981C19 24.886706 18.10542 24 17.001899 24H12.9981C11.886706 24 11 24.89458 11 25.998101zm14.5 0V30.0019C25.5 31.113294 26.39458 32 27.498101 32H31.5019C32.613294 32 33.5 31.10542 33.5 30.001899V25.9981C33.5 24.886706 32.60542 24 31.501899 24H27.4981C26.386706 24 25.5 24.89458 25.5 25.998101zm14.5 0V30.0019C40 31.113294 40.89458 32 41.998101 32H46.0019C47.113294 32 48 31.10542 48 30.001899V25.9981C48 24.886706 47.10542 24 46.001899 24H41.9981C40.886706 24 40 24.89458 40 25.998101zm-29 12V42.0019C11 43.113294 11.89458 44 12.998101 44H17.0019C18.113294 44 19 43.10542 19 42.001899V37.9981C19 36.886706 18.10542 36 17.001899 36H12.9981C11.886706 36 11 36.89458 11 37.998101zm14.5 0V42.0019C25.5 43.113294 26.39458 44 27.498101 44H31.5019C32.613294 44 33.5 43.10542 33.5 42.001899V37.9981C33.5 36.886706 32.60542 36 31.501899 36H27.4981C26.386706 36 25.5 36.89458 25.5 37.998101zm14.5 0V42.0019C40 43.113294 40.89458 44 41.998101 44H46.0019C47.113294 44 48 43.10542 48 42.001899V37.9981C48 36.886706 47.10542 36 46.001899 36H41.9981C40.886706 36 40 36.89458 40 37.998101zm-29 12V54.0019C11 55.113294 11.89458 56 12.998101 56H17.0019C18.113294 56 19 55.10542 19 54.001899V49.9981C19 48.886706 18.10542 48 17.001899 48H12.9981C11.886706 48 11 48.89458 11 49.998101zm14.5 0V54.0019C25.5 55.113294 26.39458 56 27.498101 56H31.5019C32.613294 56 33.5 55.10542 33.5 54.001899V49.9981C33.5 48.886706 32.60542 48 31.501899 48H27.4981C26.386706 48 25.5 48.89458 25.5 49.998101zM21 60.997391V68h17v-7.002608C38 59.895858 37.104522 59 35.999894 59H23.000106C21.890058 59 21 59.894263 21 60.997392zm19-10.99929V54.0019C40 55.113294 40.89458 56 41.998101 56H46.0019C47.113294 56 48 55.10542 48 54.001899V49.9981C48 48.886706 47.10542 48 46.001899 48H41.9981C40.886706 48 40 48.89458 40 49.998101zM10 2.5C10 1.119288 11.125134 0 12.498953 0h34.002094C47.88118 0 49 1.109662 49 2.5V5H10V2.5z"}}),r("path",{attrs:{d:"M0 70.004881C0 68.897616.90314 68 1.996843 68h55.006314C58.105983 68 59 68.8939 59 70.004881V73H0v-2.995119z"}})])])]),r("div",{staticClass:"text-sm leading-tight text-gray-700"},[t._v(" "+t._s(t.$t("condominium"))),r("br"),t._v("/ "+t._s(t.$t("apartment"))+" ")])])])]):t._e(),t.view==="form"?r("div",{key:2},[r("div",[t.form==="realEstate"?r("CField",{attrs:{vuelidate:t.$v.realEstateId,"vuelidate-messages":t.messages.realEstateId,label:t.$t("propertyDesignation")}},[r("CInput",{attrs:{placeholder:t.$t("propertyDesignationPlaceholder"),autofocus:""},model:{value:t.realEstateId,callback:function(i){t.realEstateId=i},expression:"realEstateId"}})],1):t._e(),t.form==="condominium"?r("CField",{attrs:{vuelidate:t.$v.condominiumId,"vuelidate-messages":t.messages.condominiumId,label:t.$t("condominiumId")}},[r("CInput",{attrs:{placeholder:t.$t("condominiumIdPlaceholder"),autofocus:"",type:"number"},model:{value:t.condominiumId,callback:function(i){t.condominiumId=i},expression:"condominiumId"}})],1):t._e(),t.form==="condominium"?r("CField",{attrs:{vuelidate:t.$v.condominiumOrgNo,"vuelidate-messages":t.messages.condominiumOrgNo,label:t.$t("condominiumOrgNo")}},[r("CInput",{attrs:{placeholder:t.$t("condominiumOrgNoPlaceholder"),type:"number"},model:{value:t.condominiumOrgNo,callback:function(i){t.condominiumOrgNo=i},expression:"condominiumOrgNo"}})],1):t._e(),r("div",{staticClass:"mt-8"},[r("CButton",{attrs:{type:"secondary",wide:""},on:{click:t.updateClientPropertyDesignation}},[t._v(t._s(t.$t("_common:save")))])],1)],1)]):t._e(),t.view==="complete"?r("div",{key:3},[r("div",{staticClass:"flex flex-col items-center justify-center text-center"},[r("div",{staticClass:"flex items-center justify-center w-12 h-12 mb-4 rounded-full bg-primary-50"},[r("BaseIcon",{staticClass:"text-primary-500",attrs:{type:"check"}})],1),r("div",{staticClass:"mb-1 text-base font-semibold"},[t._v(" "+t._s(t.$t("savedTitle"))+" ")]),r("div",{staticClass:"mb-6 text-base text-gray-700"},[t._v(" "+t._s(t.$t("savedSubTitle",{senderName:t.senderName}))+" ")]),r("div",{staticClass:"w-full mt-4"},[r("CButton",{attrs:{type:"secondary",wide:""},on:{click:function(i){return t.$emit("close")}}},[t._v(t._s(t.$t("_common:close")))])],1)])]):t._e()])],1)},omt=[],smt=he(imt,amt,omt,!1,null,null,null,null);const lmt=smt.exports,aDt="",cmt={i18nOptions:{namespaces:"docAnswer",messages:{en:{previewTooltip:"Preview how your recipients will answer."},sv:{previewTooltip:"Förhandsgranska hur dina mottagare kommer att lämna svar."}}},name:"DocumentAnswerRead",mixins:[IY({documentKey:"_document"}),br],inject:{isPdf:{default:!1}},props:{_document:{type:Object,required:!0}},data(){return{isInViewport:!1,scrollToElement:$m}},computed:{viewerId(){var n;return((n=this._document._doc)==null?void 0:n.viewerId)||null},isPreview(){return this._document.isPreview},modalHeight(){return this.mq==="sm"?"100%":"auto"},allowPropertyDesignation(){const{prices:n}=this._document;if(!n||!n.region)return!1;const{houseWorkType:t}=n.region;return["rot","greenRot15","greenRot20","greenRot50"].includes(t)},propertyDesignation(){return Ce(this._document,"clients[0].region.propertyDesignation",null)}},mounted(){window.addEventListener("scroll",this.scrollHandler,{capture:!0,passive:!0}),this.$route.name==="docPropertyDesignation"&&this.showPropertyDesignation()},destroyed(){window.removeEventListener("scroll",this.scrollHandler)},watch:{$route:{immediate:!0,handler(n){n!=null&&n.hash&&this.onAnswer("accept",{calcHeight:!0})}},isInViewport:{immediate:!0,handler(n,t){n!==t&&Pr.trigger("ui:document.block.answer.visible",n)}}},methods:{scrollHandler(){this.$refs.answerButtons&&(this.isInViewport=iM(this.$refs.answerButtons))},showPropertyDesignation(){this.$modal.show(lmt,{senderName:this._document.sender.user.name,propertyDesignation:this.propertyDesignation,fullScreen:this.modalHeight==="100%"},{adaptive:!0,height:this.modalHeight,width:"100%",maxWidth:this.modalHeight==="100%"?999:400,classes:"overflow-visible",transition:"fade-in-slide-up"})}}};var umt=function(){var i,a;var t=this,r=t._self._c;return t._document.answerActions.showActions&&!t.isPdf?r("div",{staticStyle:{padding:"calc(3 * var(--rem)) 0"}},[r("div",{ref:"answerButtons",staticClass:"flex justify-center w-full"},[r("transition",{attrs:{name:"fade",mode:"out-in"}},[((a=(i=t._document.viewer)==null?void 0:i.answerMethod)==null?void 0:a.accept)==="inPerson"?r("div",{key:0,staticStyle:{"max-width":"720px",margin:"0 auto",padding:"0 calc(3 * var(--rem))"},style:t.mq==="sm"?{padding:"0 calc(1.5 * var(--rem))"}:null},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.inPersonSignatureHint"))+" "),r(t._document.sender.user.email?"a":"span",{tag:"component",attrs:{href:`mailto:${t._document.sender.user.email}`}},[t._v(" "+t._s(t._document.sender.company.name||t._document.$t("theSender"))+" ")])],1):(t._document.answerActions.canAnswer||t.isPreview)&&t._document.answerActions.showActions?r("div",{key:1,staticClass:"flex justify-center w-full"},[r("CButton",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.isPreview&&t.$t("previewTooltip"),expression:"isPreview && $t('previewTooltip')"}],staticClass:"text-gray-400",attrs:{size:"medium"},on:{click:function(o){return t.onAnswer("decline")}}},[t._v(" "+t._s(t._document.$t("deny").capitalize())+" ")]),r("CButton",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.isPreview&&t.$t("previewTooltip"),expression:"isPreview && $t('previewTooltip')"}],staticStyle:{"margin-left":"1em","padding-left":"1.5em","padding-right":"1.5em"},attrs:{"icon-props":{strokeWidth:2.5},type:"success",size:"medium","icon-left":"check",raised:""},on:{click:function(o){return t.onAnswer("accept")}}},[t._v(" "+t._s(t._document.$t("sign").capitalize())+" ")])],1):t._document.answerActions.hasAnswered&&t._document.answerActions.waitingForOthers?r("div",{key:2,staticClass:"text-center"},[r("div",{staticStyle:{"font-weight":"600","font-size":"calc(calc(1 * var(--rem)) + 2px)","margin-bottom":"calc(0.5 * var(--rem))"}},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.youHave"))+" "),r("span",{directives:[{name:"tooltip",rawName:"v-tooltip",value:`${t.$formatDate(t._document.viewer.answer.didAnswerAt,"Pp")}`,expression:"\n `${$formatDate(_document.viewer.answer.didAnswerAt, 'Pp')}`\n "}],staticStyle:{"text-decoration":"underline"}},[t._v(t._s(t._document.viewer.answer.didAccept?t._document.$t("approved"):t._document.$t("denied")))]),t._v(" "+t._s(" "+t._document.$t("theDocument"))+". ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.waitingDescription",{remaining:t._document.remainingSignatures}))+" ")])]):t._document.status==="accepted"?r("div",{key:3},[r("div",{staticClass:"callout accepted"},[r("div",{staticClass:"title"},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.approveTitle"))+" ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.approveDescription",{sender:t._document.sender.company.name||t._document.$t("theSender")}))+" ")])])]):t._document.status==="denied"?r("div",{key:4,staticClass:"callout denied"},[r("div",{staticClass:"title"},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.denyTitle"))+" ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.denyDescription",{sender:t._document.sender.company.name||t._document.$t("theSender")}))+" ")])]):t._document.status==="expired"?r("div",{key:5,staticClass:"callout expired"},[r("div",{staticClass:"title"},[t._v(" "+t._s(t._document.$t("chapters.answerButtons.expiredTitle"))+" ")]),r("div",[t._v(" "+t._s(t._document.$t("chapters.answerButtons.expiredDescription",{sender:t._document.sender.company.name||t._document.$t("theSender")}))+" ")])]):t._e()])],1),t._document.status==="accepted"&&t.allowPropertyDesignation&&t._document.answerActions.hasAnswered?r("div",{staticClass:"flex justify-center"},[r("div",{staticClass:"answer button accept",staticStyle:{"padding-left":"calc(1.5 * var(--rem))","padding-right":"calc(1.5 * var(--rem))"},on:{click:function(o){return t.showPropertyDesignation()}}},[t._v(" "+t._s(t._document.$t(`chapters.answerButtons.${t.propertyDesignation?"editPropDes":"enterPropDes"}`))+" ")])]):t._e()]):t._e()},dmt=[],pmt=he(cmt,umt,dmt,!1,null,"e023f071",null,null);const fmt=pmt.exports,hmt=Object.freeze(Object.defineProperty({__proto__:null,default:fmt},Symbol.toStringTag,{value:"Module"})),oDt="";let zY,VY,UY,HY,WY;function mmt(n){return typeof n=="object"&&n!==null&&n.__PDFDocumentLoadingTask===!0}const gmt={name:"PdfPage",props:{src:{type:[String,Object,Promise],default:""},page:{type:Number,default:1},rotate:{type:Number,default:0},scale:{type:[Number,String],default:"page-width"},resize:{type:Boolean,default:!0},text:{type:Boolean,default:!0},pdfLoadingTask:{type:Promise,required:!0},containerClass:{type:[Array,String],default:""}},components:{WithDimensions:Af},data(){return{internalSrc:this.src,pdf:null,pdfViewer:null,loading:!0}},watch:{pdf(n){const t=n.pdfInfo||n._pdfInfo;this.$emit("numpages",t.numPages)},page(n){this.pdf.getPage(n).then(t=>{this.pdfViewer.setPdfPage(t),this.pdfViewer.draw()})},scale(n){this.drawScaled(n)},rotate(n){this.pdfViewer&&(this.pdfViewer.update({scale:this.scale,rotation:n}),this.pdfViewer.draw())}},mounted(){zY=window.pdfjsViewer.DefaultTextLayerFactory,VY=window.pdfjsViewer.PDFFindController,UY=window.pdfjsViewer.PDFLinkService,HY=window.pdfjsViewer.PDFPageView,WY=window.pdfjsViewer.EventBus,this.init()},beforeDestroy(){this.pdfViewer&&(this.pdfViewer.destroy(),this.pdfViewer=null)},methods:{init(){mmt(this.internalSrc)||(this.internalSrc=this.pdfLoadingTask,this.$emit("loading",!0));const n=this.$refs.container,t=new WY;t.on("pagerendered",i=>{this.$emit("pagerendered",i)}),this.pdfLinkService=new UY({eventBus:t,externalLinkTarget:2}),this.pdfFindController=new VY({eventBus:t,linkService:this.pdfLinkService});let r;this.text&&(r=new zY),this.internalSrc.then(i=>(this.pdf=i,i.getPage(this.page))).then(i=>{this.pdfViewer=new HY({container:n,id:this.page,scale:1,defaultViewport:i.getViewport({scale:1}),eventBus:t,textLayerFactory:r}),this.pdfViewer.setPdfPage(i);const a={scrollPageIntoView:o=>{this.$emit("link-clicked",o)}};return this.pdfLinkService.setDocument(this.pdf),this.pdfLinkService.setViewer(a),this.pdfFindController.setDocument(this.pdf),this.drawScaled(this.scale)}).catch(i=>{this.$emit("error",i),this.loading=!1,this.$emit("loading",!1)})},calculateScale(n=-1,t=-1){return this.pdfViewer.update({scale:1,rotation:this.rotate}),n===-1&&t===-1&&(n=this.$refs.container.offsetWidth),n/this.pdfViewer.viewport.width},calculateScaleHeight(){this.pdfViewer.update({scale:1,rotation:this.rotate});var n=this.$refs.container.offsetHeight,t=this.$refs.container.parentElement.parentElement;return t.offsetHeight/n},async drawScaled(n){this.pdfViewer&&(n==="page-width"?(n=this.calculateScale(),this.$emit("update:scale",n)):n==="page-height"&&(n=this.calculateScaleHeight(),this.$emit("update:scale",n)),this.pdfViewer.update({scale:n,rotation:this.rotate}),await this.pdfViewer.draw(),this.text&&(this.pdfViewer.textLayer.findController=this.pdfFindController),this.loading=!1,this.$emit("loading",!1))},resizeScale(){this.resize&&this.drawScaled("page-width")}}};var vmt=function(){var t=this,r=t._self._c;return r("div",[t.loading?t._t("loading"):t._e(),r("WithDimensions",{on:{resize:t.resizeScale}},[r("div",{ref:"container",staticClass:"pdfViewer",class:t.containerClass})])],2)},ymt=[],bmt=he(gmt,vmt,ymt,!1,null,null,null,null);const _mt=bmt.exports,R_=new mM;function wmt(n,t){let r;if(typeof n=="string")r={url:n};else if(typeof n=="object"&&n!==null)r={...n};else throw new TypeError("invalid src type");const i=window.pdfjsLib.getDocument(r).promise;return i.__PDFDocumentLoadingTask=!0,t&&t.onPassword&&(i.onPassword=t.onPassword),t&&t.onProgress&&(i.onProgress=t.onProgress),i}const K7={add(n){R_.trigger("add",n)},remove(n){R_.trigger("remove",n)},onAdd(n){R_.on("add",n)},onRemove(n){R_.on("remove",n)}},xmt={props:{src:{type:String,default:null},docFilePath:{type:String,default:null}},components:{VuePdf:_mt},inject:{isPdf:{default:!1}},data(){return{numPages:void 0,pdfLoadingTask:null,hasLoadedScripts:!1,loading:!1,pdfRenderBus:K7}},created(){this.isPdf||K7.add(this._uid)},watch:{src:{immediate:!0,async handler(n){this.hasLoadedScripts||(await g0(`${this.$apiUrl}/js/pdfjs-dist@3.0.279/build/pdf.min.js`),await g0(`${this.$apiUrl}/js/pdfjs-dist@3.0.279/web/pdf_viewer.js`),window.pdfjsLib.GlobalWorkerOptions.workerSrc=`${this.$apiUrl}/js/pdfjs-dist@3.0.279/build/pdf.worker.min.js`,this.hasLoadedScripts=!0),this.setPdf(n)}}},methods:{createLoadingTask:wmt,async setPdf(n){n&&(this.loading=!0,this.pdfLoadingTask=this.createLoadingTask(n),this.$nextTick(()=>{this.pdfLoadingTask.then(t=>{this.loading=!1,this.numPages=t.numPages,this.$emit("numPages",t.numPages),this.$emit("rendered"),K7.remove(this._uid)})}))}}};var Cmt=function(){var t=this,r=t._self._c;return r("div",{key:t.src},[t.isPdf?r("pre",[t._v(" ClingPDFReplaceStart:["+t._s(this.docFilePath)+`]ClingPDFReplaceEnd
|
|
2860
2860
|
`),r("div",[t._v("This page should have been replaced with URL: "+t._s(t.src))]),t._v(`
|
|
2861
2861
|
`)]):r("div",[t.loading?r("div",{staticClass:"mb-4 border border-gray-100 bg-gray-50 aspect-[210/297] grid place-items-center"},[r("BaseIcon",{staticClass:"animate-spin text-gray-400",attrs:{type:"loader",size:"28"}})],1):t._e(),t._l(t.numPages,function(i){return r("VuePdf",t._b({key:i,ref:"vuePdf",refInFor:!0,attrs:{page:i,"container-class":t.isPdf?"":"mb-4 shadow-[0_2px_4px_hsla(0,0%,0%,0.25)]"},on:{"hook:created":function(a){return t.pdfRenderBus.add(`${t._uid}-${i}`)},loading:a=>a?null:t.pdfRenderBus.remove(`${t._uid}-${i}`)}},"VuePdf",{...t.$attrs,...t.$props,pdfLoadingTask:t.pdfLoadingTask},!1),[t._t("loading",function(){return[r("div",{staticClass:"mb-4 border border-gray-100 bg-gray-50 aspect-[210/297] grid place-items-center",attrs:{slot:"loading"},slot:"loading"},[r("BaseIcon",{staticClass:"animate-spin text-gray-400",attrs:{type:"loader",size:"28"}})],1)]})],2)})],2)])},kmt=[],Smt=he(xmt,Cmt,kmt,!1,null,null,null,null);const Z7=Smt.exports,sDt="",Tmt={name:"FilesPreviewModal",components:{Spinner:Xm,VuePdf:Z7},props:{index:{type:Number,default:0},list:{type:Array,required:!0}},data(){return{isLoading:!0,currentIndex:this.index}},computed:{isPdf(){return this.list[this.currentIndex].mime==="application/pdf"}},mounted(){window.addEventListener("keyup",this.handleKey,{capture:!0}),this.toggleIsLoading()},beforeDestroy(){window.removeEventListener("keyup",this.handleKey,{capture:!0})},methods:{onGo(n){const t=this.currentIndex+n;this.list[t]&&(this.currentIndex=t,this.toggleIsLoading())},toggleIsLoading(){this.isLoading=!0,setTimeout(()=>{this.isLoading=!1},1e3)},handleKey(n){n.stopPropagation(),parseInt(n.keyCode,10)===37&&this.onGo(-1),parseInt(n.keyCode,10)===39&&this.onGo(1);const t=n.key||n.keyCode;(t==="Escape"||t==="Esc"||t===27)&&this.$emit("close")}}};var Emt=function(){var t=this,r=t._self._c;return r("div",{staticClass:"flex flex-col w-full",staticStyle:{height:"100%"}},[r("div",{staticClass:"image-modal-overlay"}),r("div",{staticClass:"image-modal-nav",staticStyle:{"z-index":"2"}},[r("div",{staticClass:"truncate-text",staticStyle:{"align-items":"center",display:"flex"}},[r("div",{staticClass:"truncate-text"},[t._v(t._s(t.list[t.currentIndex].name))])]),r("div",{staticStyle:{display:"flex"}},[r("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.$t("show",{thing:t.$t("previous")}),expression:"$t('show', { thing: $t('previous') })"}],staticClass:"image-modal-nav-button",class:{disabled:!t.list[t.currentIndex-1]},on:{click:function(i){return t.onGo(-1)}}},[r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("path",{attrs:{d:"M19 12H6M12 5l-7 7 7 7"}})])]),r("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.$t("show",{thing:t.$t("next")}),expression:"$t('show', { thing: $t('next') })"}],staticClass:"image-modal-nav-button",class:{disabled:!t.list[t.currentIndex+1]},on:{click:function(i){return t.onGo(1)}}},[r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("path",{attrs:{d:"M5 12h13M12 5l7 7-7 7"}})])]),r("a",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.$t("download"),expression:"$t('download')"}],staticClass:"image-modal-nav-button",attrs:{href:t.list[t.currentIndex].url,target:"_blank",download:""}},[r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("path",{attrs:{d:"M3 15v4c0 1.1.9 2 2 2h14a2 2 0 0 0 2-2v-4M17 9l-5 5-5-5M12 12.8V2.5"}})])]),r("div",{directives:[{name:"tooltip",rawName:"v-tooltip",value:t.$t("close"),expression:"$t('close')"}],staticClass:"image-modal-nav-button",on:{click:function(i){return t.$emit("close")}}},[r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"22",height:"22",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[r("line",{attrs:{x1:"18",y1:"6",x2:"6",y2:"18"}}),r("line",{attrs:{x1:"6",y1:"6",x2:"18",y2:"18"}})])])])]),r("div",{staticClass:"flex items-center justify-center w-full content-container",staticStyle:{position:"relative"},on:{click:function(i){return t.$emit("close")}}},[t.isLoading?r("Spinner",{staticStyle:{position:"absolute",left:"50%",top:"50%",transform:"translate(-50%, -50%)"},attrs:{size:"50px"}}):t._e(),t.isPdf?r("div",{staticClass:"pdf-root"},[r("VuePdf",{staticClass:"pdf-page",attrs:{src:t.list[t.currentIndex].url},on:{rendered:()=>{t.isLoading=!1}},nativeOn:{click:function(i){i.stopPropagation()}}})],1):t.isLoading?t._e():r("img",{staticClass:"modal-image",attrs:{src:t.list[t.currentIndex].url},on:{load:function(i){t.isLoading=!1}}})],1)])},$mt=[],Amt=he(Tmt,Emt,$mt,!1,null,"d70d5a87",null,null);const J7=Amt.exports,Omt=Object.freeze(Object.defineProperty({__proto__:null,default:J7},Symbol.toStringTag,{value:"Module"}));var Dmt=he({name:"FilePreviewWrapper",components:{FilePreviewModal:J7},props:{list:{type:Array,default:()=>[],validator:n=>n.length?!(!n[0].hasOwnProperty("url")||!n[0].hasOwnProperty("name")||!n[0].hasOwnProperty("mime")):!0}},computed:{fileList(){return this.list.reduce((n,t)=>this.isImage(t.mime)||this.isPdf(t.mime)?[...n,t]:n,[])}},methods:{isImage(n){const t=n.toLowerCase(n);return/image\/(gif|jpg|jpeg|png|bmp|svg|svg\+xml|tiff)$/.test(t)},isPdf(n){return n==="application/pdf"},FilePreviewModal(n){this.$modal.show(J7,{index:this.fileList.indexOf(this.list[n]),list:this.fileList},{adaptive:!0,height:"100%",width:"100%",classes:"",transition:""})}},render(){return this.$scopedSlots.default({openModal:n=>this.FilePreviewModal(n),isImageOrPdf:n=>this.isImage(n)||this.isPdf(n)})}},null,null,!1,null,null,null,null);const Mmt={name:"AttachmentList",components:{FilePreviewWrapper:Dmt.exports,BaseUpload:()=>Promise.resolve().then(()=>$X),AttachmentItem:()=>Promise.resolve().then(()=>x3t)},mixins:[pt(["attachments"])],data(){return{hoverIndex:null,newFiles:[]}},computed:{cAttachments(){return[...this.attachments,...this.newFiles.map(({displayName:n,type:t,url:r,progress:i})=>({name:n,mime:t,url:r,progress:parseInt(i,10)}))]},showRecentModal(){return!this.viewSettings.isPublicForm}},methods:{immutable:z4,async onUploadSuccess(n){const{id:t,displayName:r,url:i,mime:a}=n.response;if(!t)throw new Error("Could not read id from uploaded file");this.attachments=[...this.attachments,{fileId:t,name:r,mime:a,url:i}],this.$refs.uploader.remove(n)},remove(n){if(!this.attachments[n])return;const t=this.attachments.slice();t.splice(n,1),this.attachments=t}}};var Pmt=function(){var t=this,r=t._self._c;return r("div",{staticClass:"font-inter"},[r("FilePreviewWrapper",{attrs:{list:t.cAttachments},scopedSlots:t._u([{key:"default",fn:function({openModal:i,isImageOrPdf:a}){return[r("div",t._l(t.cAttachments,function(o,s){return r("AttachmentItem",{key:s,attrs:{"is-image-or-pdf":a(o.mime),attachment:o,"can-edit":t.canEdit,"upload-progress":o.progress},on:{click:function(c){a(o.mime)&&i(s)},remove:function(c){return t.remove(s)},input:function(c){t.attachments=t.immutable(t.attachments).set(c,s)}}})}),1)]}}])}),t.canEdit?[r("BaseUpload",{ref:"uploader",attrs:{"recent-modal":t.showRecentModal,"autostart-upload":!0,extensions:"png,gif,jpg,jpeg,svg,bmp,heic,heif,pdf,txt,odp,ods,odt,rtf,doc,docx,xls,xlsx,ppt,pptx,csv,ogv,mp4,webm,m4v,ogg,mp3,wav,zip,rar,json,7z,mpeg,oga,ogv,vsd,weba,webm,webp,xml,gz,tif,jfif,dwg,dwf,dwfx,dwt,msg,ai,psd,md,markdown,mdown,markdn",accept:"*"},on:{"upload-success":t.onUploadSuccess},model:{value:t.newFiles,callback:function(i){t.newFiles=i},expression:"newFiles"}}),r("CButton",{attrs:{type:"none",pattern:"secondary",wide:"","icon-left":"upload-cloud"},on:{click:()=>t.$refs.uploader?t.$refs.uploader.open():null}},[t._v(" "+t._s(t.$t("_common:upload",{thing:t.$t("_common:file")}))+" ")])]:t._e()],2)},Imt=[],Rmt=he(Mmt,Pmt,Imt,!1,null,null,null,null);const Lmt=Rmt.exports,Fmt=Object.freeze(Object.defineProperty({__proto__:null,default:Lmt},Symbol.toStringTag,{value:"Module"})),v1={inject:{sectionTopNode:{type:[String,Number],default:null}},computed:{showDrawer(){return this.sectionTopNode&&tr.openSection&&this.sectionTopNode===tr.openSection}},methods:{openDrawer(){this.sectionTopNode&&(tr.openSection=this.sectionTopNode)}}};function li(n){this.content=n}li.prototype={constructor:li,find:function(n){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===n)return t;return-1},get:function(n){var t=this.find(n);return t==-1?void 0:this.content[t+1]},update:function(n,t,r){var i=r&&r!=n?this.remove(r):this,a=i.find(n),o=i.content.slice();return a==-1?o.push(r||n,t):(o[a+1]=t,r&&(o[a]=r)),new li(o)},remove:function(n){var t=this.find(n);if(t==-1)return this;var r=this.content.slice();return r.splice(t,2),new li(r)},addToStart:function(n,t){return new li([n,t].concat(this.remove(n).content))},addToEnd:function(n,t){var r=this.remove(n).content.slice();return r.push(n,t),new li(r)},addBefore:function(n,t,r){var i=this.remove(t),a=i.content.slice(),o=i.find(n);return a.splice(o==-1?a.length:o,0,t,r),new li(a)},forEach:function(n){for(var t=0;t<this.content.length;t+=2)n(this.content[t],this.content[t+1])},prepend:function(n){return n=li.from(n),n.size?new li(n.content.concat(this.subtract(n).content)):this},append:function(n){return n=li.from(n),n.size?new li(this.subtract(n).content.concat(n.content)):this},subtract:function(n){var t=this;n=li.from(n);for(var r=0;r<n.content.length;r+=2)t=t.remove(n.content[r]);return t},toObject:function(){var n={};return this.forEach(function(t,r){n[t]=r}),n},get size(){return this.content.length>>1}},li.from=function(n){if(n instanceof li)return n;var t=[];if(n)for(var r in n)t.push(r,n[r]);return new li(t)};function GY(n,t,r){for(let i=0;;i++){if(i==n.childCount||i==t.childCount)return n.childCount==t.childCount?null:r;let a=n.child(i),o=t.child(i);if(a==o){r+=a.nodeSize;continue}if(!a.sameMarkup(o))return r;if(a.isText&&a.text!=o.text){for(let s=0;a.text[s]==o.text[s];s++)r++;return r}if(a.content.size||o.content.size){let s=GY(a.content,o.content,r+1);if(s!=null)return s}r+=a.nodeSize}}function qY(n,t,r,i){for(let a=n.childCount,o=t.childCount;;){if(a==0||o==0)return a==o?null:{a:r,b:i};let s=n.child(--a),c=t.child(--o),l=s.nodeSize;if(s==c){r-=l,i-=l;continue}if(!s.sameMarkup(c))return{a:r,b:i};if(s.isText&&s.text!=c.text){let u=0,d=Math.min(s.text.length,c.text.length);for(;u<d&&s.text[s.text.length-u-1]==c.text[c.text.length-u-1];)u++,r--,i--;return{a:r,b:i}}if(s.content.size||c.content.size){let u=qY(s.content,c.content,r-1,i-1);if(u)return u}r-=l,i-=l}}class qe{constructor(t,r){if(this.content=t,this.size=r||0,r==null)for(let i=0;i<t.length;i++)this.size+=t[i].nodeSize}nodesBetween(t,r,i,a=0,o){for(let s=0,c=0;c<r;s++){let l=this.content[s],u=c+l.nodeSize;if(u>t&&i(l,a+c,o||null,s)!==!1&&l.content.size){let d=c+1;l.nodesBetween(Math.max(0,t-d),Math.min(l.content.size,r-d),i,a+d)}c=u}}descendants(t){this.nodesBetween(0,this.size,t)}textBetween(t,r,i,a){let o="",s=!0;return this.nodesBetween(t,r,(c,l)=>{c.isText?(o+=c.text.slice(Math.max(t,l)-l,r-l),s=!i):c.isLeaf?(a?o+=typeof a=="function"?a(c):a:c.type.spec.leafText&&(o+=c.type.spec.leafText(c)),s=!i):!s&&c.isBlock&&(o+=i,s=!0)},0),o}append(t){if(!t.size)return this;if(!this.size)return t;let r=this.lastChild,i=t.firstChild,a=this.content.slice(),o=0;for(r.isText&&r.sameMarkup(i)&&(a[a.length-1]=r.withText(r.text+i.text),o=1);o<t.content.length;o++)a.push(t.content[o]);return new qe(a,this.size+t.size)}cut(t,r=this.size){if(t==0&&r==this.size)return this;let i=[],a=0;if(r>t)for(let o=0,s=0;s<r;o++){let c=this.content[o],l=s+c.nodeSize;l>t&&((s<t||l>r)&&(c.isText?c=c.cut(Math.max(0,t-s),Math.min(c.text.length,r-s)):c=c.cut(Math.max(0,t-s-1),Math.min(c.content.size,r-s-1))),i.push(c),a+=c.nodeSize),s=l}return new qe(i,a)}cutByIndex(t,r){return t==r?qe.empty:t==0&&r==this.content.length?this:new qe(this.content.slice(t,r))}replaceChild(t,r){let i=this.content[t];if(i==r)return this;let a=this.content.slice(),o=this.size+r.nodeSize-i.nodeSize;return a[t]=r,new qe(a,o)}addToStart(t){return new qe([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new qe(this.content.concat(t),this.size+t.nodeSize)}eq(t){if(this.content.length!=t.content.length)return!1;for(let r=0;r<this.content.length;r++)if(!this.content[r].eq(t.content[r]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(t){let r=this.content[t];if(!r)throw new RangeError("Index "+t+" out of range for "+this);return r}maybeChild(t){return this.content[t]||null}forEach(t){for(let r=0,i=0;r<this.content.length;r++){let a=this.content[r];t(a,i,r),i+=a.nodeSize}}findDiffStart(t,r=0){return GY(this,t,r)}findDiffEnd(t,r=this.size,i=t.size){return qY(this,t,r,i)}findIndex(t,r=-1){if(t==0)return L_(0,t);if(t==this.size)return L_(this.content.length,t);if(t>this.size||t<0)throw new RangeError(`Position ${t} outside of fragment (${this})`);for(let i=0,a=0;;i++){let o=this.child(i),s=a+o.nodeSize;if(s>=t)return s==t||r>0?L_(i+1,s):L_(i,a);a=s}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(t=>t.toJSON()):null}static fromJSON(t,r){if(!r)return qe.empty;if(!Array.isArray(r))throw new RangeError("Invalid input for Fragment.fromJSON");return new qe(r.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return qe.empty;let r,i=0;for(let a=0;a<t.length;a++){let o=t[a];i+=o.nodeSize,a&&o.isText&&t[a-1].sameMarkup(o)?(r||(r=t.slice(0,a)),r[r.length-1]=o.withText(r[r.length-1].text+o.text)):r&&r.push(o)}return new qe(r||t,i)}static from(t){if(!t)return qe.empty;if(t instanceof qe)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new qe([t],t.nodeSize);throw new RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}qe.empty=new qe([],0);const X7={index:0,offset:0};function L_(n,t){return X7.index=n,X7.offset=t,X7}function F_(n,t){if(n===t)return!0;if(!(n&&typeof n=="object")||!(t&&typeof t=="object"))return!1;let r=Array.isArray(n);if(Array.isArray(t)!=r)return!1;if(r){if(n.length!=t.length)return!1;for(let i=0;i<n.length;i++)if(!F_(n[i],t[i]))return!1}else{for(let i in n)if(!(i in t)||!F_(n[i],t[i]))return!1;for(let i in t)if(!(i in n))return!1}return!0}let On=class j9{constructor(t,r){this.type=t,this.attrs=r}addToSet(t){let r,i=!1;for(let a=0;a<t.length;a++){let o=t[a];if(this.eq(o))return t;if(this.type.excludes(o.type))r||(r=t.slice(0,a));else{if(o.type.excludes(this.type))return t;!i&&o.type.rank>this.type.rank&&(r||(r=t.slice(0,a)),r.push(this),i=!0),r&&r.push(o)}}return r||(r=t.slice()),i||r.push(this),r}removeFromSet(t){for(let r=0;r<t.length;r++)if(this.eq(t[r]))return t.slice(0,r).concat(t.slice(r+1));return t}isInSet(t){for(let r=0;r<t.length;r++)if(this.eq(t[r]))return!0;return!1}eq(t){return this==t||this.type==t.type&&F_(this.attrs,t.attrs)}toJSON(){let t={type:this.type.name};for(let r in this.attrs){t.attrs=this.attrs;break}return t}static fromJSON(t,r){if(!r)throw new RangeError("Invalid input for Mark.fromJSON");let i=t.marks[r.type];if(!i)throw new RangeError(`There is no mark type ${r.type} in this schema`);return i.create(r.attrs)}static sameSet(t,r){if(t==r)return!0;if(t.length!=r.length)return!1;for(let i=0;i<t.length;i++)if(!t[i].eq(r[i]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return j9.none;if(t instanceof j9)return[t];let r=t.slice();return r.sort((i,a)=>i.type.rank-a.type.rank),r}};On.none=[];class y1 extends Error{}class rt{constructor(t,r,i){this.content=t,this.openStart=r,this.openEnd=i}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,r){let i=KY(this.content,t+this.openStart,r);return i&&new rt(i,this.openStart,this.openEnd)}removeBetween(t,r){return new rt(YY(this.content,t+this.openStart,r+this.openStart),this.openStart,this.openEnd)}eq(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}static fromJSON(t,r){if(!r)return rt.empty;let i=r.openStart||0,a=r.openEnd||0;if(typeof i!="number"||typeof a!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new rt(qe.fromJSON(t,r.content),i,a)}static maxOpen(t,r=!0){let i=0,a=0;for(let o=t.firstChild;o&&!o.isLeaf&&(r||!o.type.spec.isolating);o=o.firstChild)i++;for(let o=t.lastChild;o&&!o.isLeaf&&(r||!o.type.spec.isolating);o=o.lastChild)a++;return new rt(t,i,a)}}rt.empty=new rt(qe.empty,0,0);function YY(n,t,r){let{index:i,offset:a}=n.findIndex(t),o=n.maybeChild(i),{index:s,offset:c}=n.findIndex(r);if(a==t||o.isText){if(c!=r&&!n.child(s).isText)throw new RangeError("Removing non-flat range");return n.cut(0,t).append(n.cut(r))}if(i!=s)throw new RangeError("Removing non-flat range");return n.replaceChild(i,o.copy(YY(o.content,t-a-1,r-a-1)))}function KY(n,t,r,i){let{index:a,offset:o}=n.findIndex(t),s=n.maybeChild(a);if(o==t||s.isText)return i&&!i.canReplace(a,a,r)?null:n.cut(0,t).append(r).append(n.cut(t));let c=KY(s.content,t-o-1,r);return c&&n.replaceChild(a,s.copy(c))}function Nmt(n,t,r){if(r.openStart>n.depth)throw new y1("Inserted content deeper than insertion position");if(n.depth-r.openStart!=t.depth-r.openEnd)throw new y1("Inconsistent open depths");return ZY(n,t,r,0)}function ZY(n,t,r,i){let a=n.index(i),o=n.node(i);if(a==t.index(i)&&i<n.depth-r.openStart){let s=ZY(n,t,r,i+1);return o.copy(o.content.replaceChild(a,s))}else if(r.content.size)if(!r.openStart&&!r.openEnd&&n.depth==i&&t.depth==i){let s=n.parent,c=s.content;return gd(s,c.cut(0,n.parentOffset).append(r.content).append(c.cut(t.parentOffset)))}else{let{start:s,end:c}=Bmt(r,n);return gd(o,XY(n,s,c,t,i))}else return gd(o,N_(n,t,i))}function JY(n,t){if(!t.type.compatibleContent(n.type))throw new y1("Cannot join "+t.type.name+" onto "+n.type.name)}function Q7(n,t,r){let i=n.node(r);return JY(i,t.node(r)),i}function md(n,t){let r=t.length-1;r>=0&&n.isText&&n.sameMarkup(t[r])?t[r]=n.withText(t[r].text+n.text):t.push(n)}function b1(n,t,r,i){let a=(t||n).node(r),o=0,s=t?t.index(r):a.childCount;n&&(o=n.index(r),n.depth>r?o++:n.textOffset&&(md(n.nodeAfter,i),o++));for(let c=o;c<s;c++)md(a.child(c),i);t&&t.depth==r&&t.textOffset&&md(t.nodeBefore,i)}function gd(n,t){if(!n.type.validContent(t))throw new y1("Invalid content for node "+n.type.name);return n.copy(t)}function XY(n,t,r,i,a){let o=n.depth>a&&Q7(n,t,a+1),s=i.depth>a&&Q7(r,i,a+1),c=[];return b1(null,n,a,c),o&&s&&t.index(a)==r.index(a)?(JY(o,s),md(gd(o,XY(n,t,r,i,a+1)),c)):(o&&md(gd(o,N_(n,t,a+1)),c),b1(t,r,a,c),s&&md(gd(s,N_(r,i,a+1)),c)),b1(i,null,a,c),new qe(c)}function N_(n,t,r){let i=[];if(b1(null,n,r,i),n.depth>r){let a=Q7(n,t,r+1);md(gd(a,N_(n,t,r+1)),i)}return b1(t,null,r,i),new qe(i)}function Bmt(n,t){let r=t.depth-n.openStart,a=t.node(r).copy(n.content);for(let o=r-1;o>=0;o--)a=t.node(o).copy(qe.from(a));return{start:a.resolveNoCache(n.openStart+r),end:a.resolveNoCache(a.content.size-n.openEnd-r)}}class _1{constructor(t,r,i){this.pos=t,this.path=r,this.parentOffset=i,this.depth=r.length/3-1}resolveDepth(t){return t==null?this.depth:t<0?this.depth+t:t}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(t){return this.path[this.resolveDepth(t)*3]}index(t){return this.path[this.resolveDepth(t)*3+1]}indexAfter(t){return t=this.resolveDepth(t),this.index(t)+(t==this.depth&&!this.textOffset?0:1)}start(t){return t=this.resolveDepth(t),t==0?0:this.path[t*3-1]+1}end(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}before(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]}after(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]+this.path[t*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let t=this.parent,r=this.index(this.depth);if(r==t.childCount)return null;let i=this.pos-this.path[this.path.length-1],a=t.child(r);return i?t.child(r).cut(i):a}get nodeBefore(){let t=this.index(this.depth),r=this.pos-this.path[this.path.length-1];return r?this.parent.child(t).cut(0,r):t==0?null:this.parent.child(t-1)}posAtIndex(t,r){r=this.resolveDepth(r);let i=this.path[r*3],a=r==0?0:this.path[r*3-1]+1;for(let o=0;o<t;o++)a+=i.child(o).nodeSize;return a}marks(){let t=this.parent,r=this.index();if(t.content.size==0)return On.none;if(this.textOffset)return t.child(r).marks;let i=t.maybeChild(r-1),a=t.maybeChild(r);if(!i){let c=i;i=a,a=c}let o=i.marks;for(var s=0;s<o.length;s++)o[s].type.spec.inclusive===!1&&(!a||!o[s].isInSet(a.marks))&&(o=o[s--].removeFromSet(o));return o}marksAcross(t){let r=this.parent.maybeChild(this.index());if(!r||!r.isInline)return null;let i=r.marks,a=t.parent.maybeChild(t.index());for(var o=0;o<i.length;o++)i[o].type.spec.inclusive===!1&&(!a||!i[o].isInSet(a.marks))&&(i=i[o--].removeFromSet(i));return i}sharedDepth(t){for(let r=this.depth;r>0;r--)if(this.start(r)<=t&&this.end(r)>=t)return r;return 0}blockRange(t=this,r){if(t.pos<this.pos)return t.blockRange(this);for(let i=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);i>=0;i--)if(t.pos<=this.end(i)&&(!r||r(this.node(i))))return new B_(this,t,i);return null}sameParent(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}max(t){return t.pos>this.pos?t:this}min(t){return t.pos<this.pos?t:this}toString(){let t="";for(let r=1;r<=this.depth;r++)t+=(t?"/":"")+this.node(r).type.name+"_"+this.index(r-1);return t+":"+this.parentOffset}static resolve(t,r){if(!(r>=0&&r<=t.content.size))throw new RangeError("Position "+r+" out of range");let i=[],a=0,o=r;for(let s=t;;){let{index:c,offset:l}=s.content.findIndex(o),u=o-l;if(i.push(s,c,a+l),!u||(s=s.child(c),s.isText))break;o=u-1,a+=l+1}return new _1(r,i,o)}static resolveCached(t,r){for(let a=0;a<eT.length;a++){let o=eT[a];if(o.pos==r&&o.doc==t)return o}let i=eT[tT]=_1.resolve(t,r);return tT=(tT+1)%jmt,i}}let eT=[],tT=0,jmt=12;class B_{constructor(t,r,i){this.$from=t,this.$to=r,this.depth=i}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const zmt=Object.create(null);let vd=class z9{constructor(t,r,i,a=On.none){this.type=t,this.attrs=r,this.marks=a,this.content=i||qe.empty}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(t){return this.content.child(t)}maybeChild(t){return this.content.maybeChild(t)}forEach(t){this.content.forEach(t)}nodesBetween(t,r,i,a=0){this.content.nodesBetween(t,r,i,a,this)}descendants(t){this.nodesBetween(0,this.content.size,t)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(t,r,i,a){return this.content.textBetween(t,r,i,a)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}sameMarkup(t){return this.hasMarkup(t.type,t.attrs,t.marks)}hasMarkup(t,r,i){return this.type==t&&F_(this.attrs,r||t.defaultAttrs||zmt)&&On.sameSet(this.marks,i||On.none)}copy(t=null){return t==this.content?this:new z9(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new z9(this.type,this.attrs,this.content,t)}cut(t,r=this.content.size){return t==0&&r==this.content.size?this:this.copy(this.content.cut(t,r))}slice(t,r=this.content.size,i=!1){if(t==r)return rt.empty;let a=this.resolve(t),o=this.resolve(r),s=i?0:a.sharedDepth(r),c=a.start(s),u=a.node(s).content.cut(a.pos-c,o.pos-c);return new rt(u,a.depth-s,o.depth-s)}replace(t,r,i){return Nmt(this.resolve(t),this.resolve(r),i)}nodeAt(t){for(let r=this;;){let{index:i,offset:a}=r.content.findIndex(t);if(r=r.maybeChild(i),!r)return null;if(a==t||r.isText)return r;t-=a+1}}childAfter(t){let{index:r,offset:i}=this.content.findIndex(t);return{node:this.content.maybeChild(r),index:r,offset:i}}childBefore(t){if(t==0)return{node:null,index:0,offset:0};let{index:r,offset:i}=this.content.findIndex(t);if(i<t)return{node:this.content.child(r),index:r,offset:i};let a=this.content.child(r-1);return{node:a,index:r-1,offset:i-a.nodeSize}}resolve(t){return _1.resolveCached(this,t)}resolveNoCache(t){return _1.resolve(this,t)}rangeHasMark(t,r,i){let a=!1;return r>t&&this.nodesBetween(t,r,o=>(i.isInSet(o.marks)&&(a=!0),!a)),a}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),QY(this.marks,t)}contentMatchAt(t){let r=this.type.contentMatch.matchFragment(this.content,0,t);if(!r)throw new Error("Called contentMatchAt on a node with invalid content");return r}canReplace(t,r,i=qe.empty,a=0,o=i.childCount){let s=this.contentMatchAt(t).matchFragment(i,a,o),c=s&&s.matchFragment(this.content,r);if(!c||!c.validEnd)return!1;for(let l=a;l<o;l++)if(!this.type.allowsMarks(i.child(l).marks))return!1;return!0}canReplaceWith(t,r,i,a){if(a&&!this.type.allowsMarks(a))return!1;let o=this.contentMatchAt(t).matchType(i),s=o&&o.matchFragment(this.content,r);return s?s.validEnd:!1}canAppend(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}check(){if(!this.type.validContent(this.content))throw new RangeError(`Invalid content for node ${this.type.name}: ${this.content.toString().slice(0,50)}`);let t=On.none;for(let r=0;r<this.marks.length;r++)t=this.marks[r].addToSet(t);if(!On.sameSet(t,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(r=>r.type.name)}`);this.content.forEach(r=>r.check())}toJSON(){let t={type:this.type.name};for(let r in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map(r=>r.toJSON())),t}static fromJSON(t,r){if(!r)throw new RangeError("Invalid input for Node.fromJSON");let i=null;if(r.marks){if(!Array.isArray(r.marks))throw new RangeError("Invalid mark data for Node.fromJSON");i=r.marks.map(t.markFromJSON)}if(r.type=="text"){if(typeof r.text!="string")throw new RangeError("Invalid text node in JSON");return t.text(r.text,i)}let a=qe.fromJSON(t,r.content);return t.nodeType(r.type).create(r.attrs,a,i)}};vd.prototype.text=void 0;class j_ extends vd{constructor(t,r,i,a){if(super(t,r,null,a),!i)throw new RangeError("Empty text nodes are not allowed");this.text=i}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):QY(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(t,r){return this.text.slice(t,r)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new j_(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new j_(this.type,this.attrs,t,this.marks)}cut(t=0,r=this.text.length){return t==0&&r==this.text.length?this:this.withText(this.text.slice(t,r))}eq(t){return this.sameMarkup(t)&&this.text==t.text}toJSON(){let t=super.toJSON();return t.text=this.text,t}}function QY(n,t){for(let r=n.length-1;r>=0;r--)t=n[r].type.name+"("+t+")";return t}class yd{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,r){let i=new Vmt(t,r);if(i.next==null)return yd.empty;let a=eK(i);i.next&&i.err("Unexpected trailing text");let o=Kmt(Ymt(a));return Zmt(o,i),o}matchType(t){for(let r=0;r<this.next.length;r++)if(this.next[r].type==t)return this.next[r].next;return null}matchFragment(t,r=0,i=t.childCount){let a=this;for(let o=r;a&&o<i;o++)a=a.matchType(t.child(o).type);return a}get inlineContent(){return this.next.length&&this.next[0].type.isInline}get defaultType(){for(let t=0;t<this.next.length;t++){let{type:r}=this.next[t];if(!(r.isText||r.hasRequiredAttrs()))return r}return null}compatible(t){for(let r=0;r<this.next.length;r++)for(let i=0;i<t.next.length;i++)if(this.next[r].type==t.next[i].type)return!0;return!1}fillBefore(t,r=!1,i=0){let a=[this];function o(s,c){let l=s.matchFragment(t,i);if(l&&(!r||l.validEnd))return qe.from(c.map(u=>u.createAndFill()));for(let u=0;u<s.next.length;u++){let{type:d,next:p}=s.next[u];if(!(d.isText||d.hasRequiredAttrs())&&a.indexOf(p)==-1){a.push(p);let f=o(p,c.concat(d));if(f)return f}}return null}return o(this,[])}findWrapping(t){for(let i=0;i<this.wrapCache.length;i+=2)if(this.wrapCache[i]==t)return this.wrapCache[i+1];let r=this.computeWrapping(t);return this.wrapCache.push(t,r),r}computeWrapping(t){let r=Object.create(null),i=[{match:this,type:null,via:null}];for(;i.length;){let a=i.shift(),o=a.match;if(o.matchType(t)){let s=[];for(let c=a;c.type;c=c.via)s.push(c.type);return s.reverse()}for(let s=0;s<o.next.length;s++){let{type:c,next:l}=o.next[s];!c.isLeaf&&!c.hasRequiredAttrs()&&!(c.name in r)&&(!a.type||l.validEnd)&&(i.push({match:c.contentMatch,type:c,via:a}),r[c.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(t){if(t>=this.next.length)throw new RangeError(`There's no ${t}th edge in this content match`);return this.next[t]}toString(){let t=[];function r(i){t.push(i);for(let a=0;a<i.next.length;a++)t.indexOf(i.next[a].next)==-1&&r(i.next[a].next)}return r(this),t.map((i,a)=>{let o=a+(i.validEnd?"*":" ")+" ";for(let s=0;s<i.next.length;s++)o+=(s?", ":"")+i.next[s].type.name+"->"+t.indexOf(i.next[s].next);return o}).join(`
|
|
2862
2862
|
`)}}yd.empty=new yd(!0);class Vmt{constructor(t,r){this.string=t,this.nodeTypes=r,this.inline=null,this.pos=0,this.tokens=t.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(t){return this.next==t&&(this.pos++||!0)}err(t){throw new SyntaxError(t+" (in content expression '"+this.string+"')")}}function eK(n){let t=[];do t.push(Umt(n));while(n.eat("|"));return t.length==1?t[0]:{type:"choice",exprs:t}}function Umt(n){let t=[];do t.push(Hmt(n));while(n.next&&n.next!=")"&&n.next!="|");return t.length==1?t[0]:{type:"seq",exprs:t}}function Hmt(n){let t=qmt(n);for(;;)if(n.eat("+"))t={type:"plus",expr:t};else if(n.eat("*"))t={type:"star",expr:t};else if(n.eat("?"))t={type:"opt",expr:t};else if(n.eat("{"))t=Wmt(n,t);else break;return t}function tK(n){/\D/.test(n.next)&&n.err("Expected number, got '"+n.next+"'");let t=Number(n.next);return n.pos++,t}function Wmt(n,t){let r=tK(n),i=r;return n.eat(",")&&(n.next!="}"?i=tK(n):i=-1),n.eat("}")||n.err("Unclosed braced range"),{type:"range",min:r,max:i,expr:t}}function Gmt(n,t){let r=n.nodeTypes,i=r[t];if(i)return[i];let a=[];for(let o in r){let s=r[o];s.groups.indexOf(t)>-1&&a.push(s)}return a.length==0&&n.err("No node type or group '"+t+"' found"),a}function qmt(n){if(n.eat("(")){let t=eK(n);return n.eat(")")||n.err("Missing closing paren"),t}else if(/\W/.test(n.next))n.err("Unexpected token '"+n.next+"'");else{let t=Gmt(n,n.next).map(r=>(n.inline==null?n.inline=r.isInline:n.inline!=r.isInline&&n.err("Mixing inline and block content"),{type:"name",value:r}));return n.pos++,t.length==1?t[0]:{type:"choice",exprs:t}}}function Ymt(n){let t=[[]];return a(o(n,0),r()),t;function r(){return t.push([])-1}function i(s,c,l){let u={term:l,to:c};return t[s].push(u),u}function a(s,c){s.forEach(l=>l.to=c)}function o(s,c){if(s.type=="choice")return s.exprs.reduce((l,u)=>l.concat(o(u,c)),[]);if(s.type=="seq")for(let l=0;;l++){let u=o(s.exprs[l],c);if(l==s.exprs.length-1)return u;a(u,c=r())}else if(s.type=="star"){let l=r();return i(c,l),a(o(s.expr,l),l),[i(l)]}else if(s.type=="plus"){let l=r();return a(o(s.expr,c),l),a(o(s.expr,l),l),[i(l)]}else{if(s.type=="opt")return[i(c)].concat(o(s.expr,c));if(s.type=="range"){let l=c;for(let u=0;u<s.min;u++){let d=r();a(o(s.expr,l),d),l=d}if(s.max==-1)a(o(s.expr,l),l);else for(let u=s.min;u<s.max;u++){let d=r();i(l,d),a(o(s.expr,l),d),l=d}return[i(l)]}else{if(s.type=="name")return[i(c,void 0,s.value)];throw new Error("Unknown expr type")}}}}function nK(n,t){return t-n}function rK(n,t){let r=[];return i(t),r.sort(nK);function i(a){let o=n[a];if(o.length==1&&!o[0].term)return i(o[0].to);r.push(a);for(let s=0;s<o.length;s++){let{term:c,to:l}=o[s];!c&&r.indexOf(l)==-1&&i(l)}}}function Kmt(n){let t=Object.create(null);return r(rK(n,0));function r(i){let a=[];i.forEach(s=>{n[s].forEach(({term:c,to:l})=>{if(!c)return;let u;for(let d=0;d<a.length;d++)a[d][0]==c&&(u=a[d][1]);rK(n,l).forEach(d=>{u||a.push([c,u=[]]),u.indexOf(d)==-1&&u.push(d)})})});let o=t[i.join(",")]=new yd(i.indexOf(n.length-1)>-1);for(let s=0;s<a.length;s++){let c=a[s][1].sort(nK);o.next.push({type:a[s][0],next:t[c.join(",")]||r(c)})}return o}}function Zmt(n,t){for(let r=0,i=[n];r<i.length;r++){let a=i[r],o=!a.validEnd,s=[];for(let c=0;c<a.next.length;c++){let{type:l,next:u}=a.next[c];s.push(l.name),o&&!(l.isText||l.hasRequiredAttrs())&&(o=!1),i.indexOf(u)==-1&&i.push(u)}o&&t.err("Only non-generatable nodes ("+s.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function iK(n){let t=Object.create(null);for(let r in n){let i=n[r];if(!i.hasDefault)return null;t[r]=i.default}return t}function aK(n,t){let r=Object.create(null);for(let i in n){let a=t&&t[i];if(a===void 0){let o=n[i];if(o.hasDefault)a=o.default;else throw new RangeError("No value supplied for attribute "+i)}r[i]=a}return r}function oK(n){let t=Object.create(null);if(n)for(let r in n)t[r]=new Jmt(n[r]);return t}let sK=class wee{constructor(t,r,i){this.name=t,this.schema=r,this.spec=i,this.markSet=null,this.groups=i.group?i.group.split(" "):[],this.attrs=oK(i.attrs),this.defaultAttrs=iK(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(i.inline||t=="text"),this.isText=t=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==yd.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let t in this.attrs)if(this.attrs[t].isRequired)return!0;return!1}compatibleContent(t){return this==t||this.contentMatch.compatible(t.contentMatch)}computeAttrs(t){return!t&&this.defaultAttrs?this.defaultAttrs:aK(this.attrs,t)}create(t=null,r,i){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new vd(this,this.computeAttrs(t),qe.from(r),On.setFrom(i))}createChecked(t=null,r,i){if(r=qe.from(r),!this.validContent(r))throw new RangeError("Invalid content for node "+this.name);return new vd(this,this.computeAttrs(t),r,On.setFrom(i))}createAndFill(t=null,r,i){if(t=this.computeAttrs(t),r=qe.from(r),r.size){let s=this.contentMatch.fillBefore(r);if(!s)return null;r=s.append(r)}let a=this.contentMatch.matchFragment(r),o=a&&a.fillBefore(qe.empty,!0);return o?new vd(this,t,r.append(o),On.setFrom(i)):null}validContent(t){let r=this.contentMatch.matchFragment(t);if(!r||!r.validEnd)return!1;for(let i=0;i<t.childCount;i++)if(!this.allowsMarks(t.child(i).marks))return!1;return!0}allowsMarkType(t){return this.markSet==null||this.markSet.indexOf(t)>-1}allowsMarks(t){if(this.markSet==null)return!0;for(let r=0;r<t.length;r++)if(!this.allowsMarkType(t[r].type))return!1;return!0}allowedMarks(t){if(this.markSet==null)return t;let r;for(let i=0;i<t.length;i++)this.allowsMarkType(t[i].type)?r&&r.push(t[i]):r||(r=t.slice(0,i));return r?r.length?r:On.none:t}static compile(t,r){let i=Object.create(null);t.forEach((o,s)=>i[o]=new wee(o,r,s));let a=r.spec.topNode||"doc";if(!i[a])throw new RangeError("Schema is missing its top node type ('"+a+"')");if(!i.text)throw new RangeError("Every schema needs a 'text' type");for(let o in i.text.attrs)throw new RangeError("The text node type should not have attributes");return i}};class Jmt{constructor(t){this.hasDefault=Object.prototype.hasOwnProperty.call(t,"default"),this.default=t.default}get isRequired(){return!this.hasDefault}}class z_{constructor(t,r,i,a){this.name=t,this.rank=r,this.schema=i,this.spec=a,this.attrs=oK(a.attrs),this.excluded=null;let o=iK(this.attrs);this.instance=o?new On(this,o):null}create(t=null){return!t&&this.instance?this.instance:new On(this,aK(this.attrs,t))}static compile(t,r){let i=Object.create(null),a=0;return t.forEach((o,s)=>i[o]=new z_(o,a++,r,s)),i}removeFromSet(t){for(var r=0;r<t.length;r++)t[r].type==this&&(t=t.slice(0,r).concat(t.slice(r+1)),r--);return t}isInSet(t){for(let r=0;r<t.length;r++)if(t[r].type==this)return t[r]}excludes(t){return this.excluded.indexOf(t)>-1}}class Xmt{constructor(t){this.cached=Object.create(null),this.spec={nodes:li.from(t.nodes),marks:li.from(t.marks||{}),topNode:t.topNode},this.nodes=sK.compile(this.spec.nodes,this),this.marks=z_.compile(this.spec.marks,this);let r=Object.create(null);for(let i in this.nodes){if(i in this.marks)throw new RangeError(i+" can not be both a node and a mark");let a=this.nodes[i],o=a.spec.content||"",s=a.spec.marks;a.contentMatch=r[o]||(r[o]=yd.parse(o,this.nodes)),a.inlineContent=a.contentMatch.inlineContent,a.markSet=s=="_"?null:s?lK(this,s.split(" ")):s==""||!a.inlineContent?[]:null}for(let i in this.marks){let a=this.marks[i],o=a.spec.excludes;a.excluded=o==null?[a]:o==""?[]:lK(this,o.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(t,r=null,i,a){if(typeof t=="string")t=this.nodeType(t);else if(t instanceof sK){if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}else throw new RangeError("Invalid node type: "+t);return t.createChecked(r,i,a)}text(t,r){let i=this.nodes.text;return new j_(i,i.defaultAttrs,t,On.setFrom(r))}mark(t,r){return typeof t=="string"&&(t=this.marks[t]),t.create(r)}nodeFromJSON(t){return vd.fromJSON(this,t)}markFromJSON(t){return On.fromJSON(this,t)}nodeType(t){let r=this.nodes[t];if(!r)throw new RangeError("Unknown node type: "+t);return r}}function lK(n,t){let r=[];for(let i=0;i<t.length;i++){let a=t[i],o=n.marks[a],s=o;if(o)r.push(o);else for(let c in n.marks){let l=n.marks[c];(a=="_"||l.spec.group&&l.spec.group.split(" ").indexOf(a)>-1)&&r.push(s=l)}if(!s)throw new SyntaxError("Unknown mark type: '"+t[i]+"'")}return r}let nT=class V9{constructor(t,r){this.schema=t,this.rules=r,this.tags=[],this.styles=[],r.forEach(i=>{i.tag?this.tags.push(i):i.style&&this.styles.push(i)}),this.normalizeLists=!this.tags.some(i=>{if(!/^(ul|ol)\b/.test(i.tag)||!i.node)return!1;let a=t.nodes[i.node];return a.contentMatch.matchType(a)})}parse(t,r={}){let i=new pK(this,r,!1);return i.addAll(t,r.from,r.to),i.finish()}parseSlice(t,r={}){let i=new pK(this,r,!0);return i.addAll(t,r.from,r.to),rt.maxOpen(i.finish())}matchTag(t,r,i){for(let a=i?this.tags.indexOf(i)+1:0;a<this.tags.length;a++){let o=this.tags[a];if(tgt(t,o.tag)&&(o.namespace===void 0||t.namespaceURI==o.namespace)&&(!o.context||r.matchesContext(o.context))){if(o.getAttrs){let s=o.getAttrs(t);if(s===!1)continue;o.attrs=s||void 0}return o}}}matchStyle(t,r,i,a){for(let o=a?this.styles.indexOf(a)+1:0;o<this.styles.length;o++){let s=this.styles[o],c=s.style;if(!(c.indexOf(t)!=0||s.context&&!i.matchesContext(s.context)||c.length>t.length&&(c.charCodeAt(t.length)!=61||c.slice(t.length+1)!=r))){if(s.getAttrs){let l=s.getAttrs(r);if(l===!1)continue;s.attrs=l||void 0}return s}}}static schemaRules(t){let r=[];function i(a){let o=a.priority==null?50:a.priority,s=0;for(;s<r.length;s++){let c=r[s];if((c.priority==null?50:c.priority)<o)break}r.splice(s,0,a)}for(let a in t.marks){let o=t.marks[a].spec.parseDOM;o&&o.forEach(s=>{i(s=fK(s)),s.mark=a})}for(let a in t.nodes){let o=t.nodes[a].spec.parseDOM;o&&o.forEach(s=>{i(s=fK(s)),s.node=a})}return r}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new V9(t,V9.schemaRules(t)))}};const cK={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},Qmt={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},uK={ol:!0,ul:!0},V_=1,U_=2,w1=4;function dK(n,t,r){return t!=null?(t?V_:0)|(t==="full"?U_:0):n&&n.whitespace=="pre"?V_|U_:r&~w1}class H_{constructor(t,r,i,a,o,s,c){this.type=t,this.attrs=r,this.marks=i,this.pendingMarks=a,this.solid=o,this.options=c,this.content=[],this.activeMarks=On.none,this.stashMarks=[],this.match=s||(c&w1?null:t.contentMatch)}findWrapping(t){if(!this.match){if(!this.type)return[];let r=this.type.contentMatch.fillBefore(qe.from(t));if(r)this.match=this.type.contentMatch.matchFragment(r);else{let i=this.type.contentMatch,a;return(a=i.findWrapping(t.type))?(this.match=i,a):null}}return this.match.findWrapping(t.type)}finish(t){if(!(this.options&V_)){let i=this.content[this.content.length-1],a;if(i&&i.isText&&(a=/[ \t\r\n\u000c]+$/.exec(i.text))){let o=i;i.text.length==a[0].length?this.content.pop():this.content[this.content.length-1]=o.withText(o.text.slice(0,o.text.length-a[0].length))}}let r=qe.from(this.content);return!t&&this.match&&(r=r.append(this.match.fillBefore(qe.empty,!0))),this.type?this.type.create(this.attrs,r,this.marks):r}popFromStashMark(t){for(let r=this.stashMarks.length-1;r>=0;r--)if(t.eq(this.stashMarks[r]))return this.stashMarks.splice(r,1)[0]}applyPending(t){for(let r=0,i=this.pendingMarks;r<i.length;r++){let a=i[r];(this.type?this.type.allowsMarkType(a.type):rgt(a.type,t))&&!a.isInSet(this.activeMarks)&&(this.activeMarks=a.addToSet(this.activeMarks),this.pendingMarks=a.removeFromSet(this.pendingMarks))}}inlineContext(t){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:t.parentNode&&!cK.hasOwnProperty(t.parentNode.nodeName.toLowerCase())}}class pK{constructor(t,r,i){this.parser=t,this.options=r,this.isOpen=i,this.open=0;let a=r.topNode,o,s=dK(null,r.preserveWhitespace,0)|(i?w1:0);a?o=new H_(a.type,a.attrs,On.none,On.none,!0,r.topMatch||a.type.contentMatch,s):i?o=new H_(null,null,On.none,On.none,!0,null,s):o=new H_(t.schema.topNodeType,null,On.none,On.none,!0,null,s),this.nodes=[o],this.find=r.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(t){if(t.nodeType==3)this.addTextNode(t);else if(t.nodeType==1){let r=t.getAttribute("style"),i=r?this.readStyles(ngt(r)):null,a=this.top;if(i!=null)for(let o=0;o<i.length;o++)this.addPendingMark(i[o]);if(this.addElement(t),i!=null)for(let o=0;o<i.length;o++)this.removePendingMark(i[o],a)}}addTextNode(t){let r=t.nodeValue,i=this.top;if(i.options&U_||i.inlineContext(t)||/[^ \t\r\n\u000c]/.test(r)){if(i.options&V_)i.options&U_?r=r.replace(/\r\n?/g,`
|