@witty-works/editor 2.2.0 → 2.2.1

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.
@@ -1,4 +1,4 @@
1
- /*! @witty-works/editor 2.2.0 (4f8dc61d) | MIT | https://witty.works | third-party licenses: witty-editor.js.LICENSE.txt */
1
+ /*! @witty-works/editor 2.2.1 (c4750fa3) | MIT | https://witty.works | third-party licenses: witty-editor.js.LICENSE.txt */
2
2
  (function(){try{if(typeof document<`u`){var e=document.createElement(`style`);e.appendChild(document.createTextNode(`.witty-works-button{cursor:pointer!important;box-shadow:none!important;font:inherit!important;color:inherit!important;text-align:inherit!important;text-transform:none!important;line-height:inherit!important;background-color:#0000!important;border:none!important;outline:none!important;margin:0!important;padding:0!important}#witty-works-ext-popover{display:"flex";box-sizing:border-box;z-index:2147483647;background-color:#fff;border-radius:5px;min-width:272px;padding:0 8px;box-shadow:1px 0 18px 7px #3232321a}#witty-works-ext-popover-content{flex-direction:column;display:flex}.witty-works-ext-wittyworks-popover-alternative-btn-container{flex-direction:row;align-items:center;display:flex;margin-bottom:.5em!important}.witty-works-ext-wittyworks-popover-alternative-btn-container:hover .witty-works-ext-wittyworks-popover-alternative-btn{background-color:#5fca7d4d}.witty-works-ext-wittyworks-popover-alternative-btn-container:hover .witty-works-ext-wittyworks-popover-alternative-context{color:#365e3b}.witty-works-ext-wittyworks-popover-alternative-btn{cursor:pointer;font:inherit;text-align:left;background-color:#f1fff3;border:none;border-radius:4px;padding:3px 8px;display:table}.witty-works-ext-wittyworks-popover-alternative-btn.witty-works-ext-remove-text{text-decoration:line-through!important}button.witty-works-ext-dropdown-select{background:0 0}#witty-works-ext-popover button:focus-visible,#witty-works-ext-popover a:focus-visible{outline-offset:1px;outline:2px solid #9489db!important}.witty-works-ext-ignore-color-transformer{filter:invert(38%)sepia(2%)saturate(0%)hue-rotate(73deg)brightness()contrast(89%)}.witty-works-ext-ignore-color-transformer:hover{filter:invert(39%)sepia(86%)saturate(747%)hue-rotate(323deg)brightness(109%)contrast(80%);color:#8b1b1b;cursor:pointer}.witty-works-ext-lato-small-paragraph-title-h4{color:#000;font-family:Lato,Arial,Helvetica,sans-serif;font-size:22px;font-style:normal;font-weight:600;line-height:28px}.witty-works-ext-lato-popover-text{color:#000;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:20px}.witty-works-ext-lato-popover-text-green{color:#365e3b;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:20px}.witty-works-ext-lato-popover-text-gray{color:#656565;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:20px}.witty-works-ext-lato-popover-text-light-gray{color:#ddd;stroke:#ddd;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:20px}.witty-works-ext-lato-popup-title{color:#000;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:700;line-height:20px}.witty-works-ext-lato-popup-text{color:#000;font-family:Lato,Arial,Helvetica,sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:20px}.witty-works-ext-lato-popup-text-purple{color:#9489db;font-family:Lato,Arial,Helvetica,sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:20px;text-decoration-line:underline}.witty-works-ext-button{cursor:pointer;border:none;gap:10px;margin-right:1em;padding:10px 15px;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:14px;display:flex}.witty-works-ext-primary-button-red{color:#fff;background:#f06464;border-radius:8px}.witty-works-ext-primary-button-purple{color:#fff;background:#9489db;border-radius:8px}.witty-works-ext-secondary-button-purple{color:#8b1b1b;background:#fff;border:1px solid #8b1b1b;border-radius:8px}.witty-works-ext-secondary-button-red{color:#f06464;border:1px solid #f06464;border-radius:8px;padding:.4em}.witty-works-ext-ignore-button{padding:2px 6px}.witty-works-ext-strong-gradient-background{background:linear-gradient(114.59deg,#f06464 1.6%,#f277d0 32.79%,#9489db 71.64%,#37d1e5 101.91%,#5acfb9 131.52%)}.witty-works-ext-light-gray-background{background:#eee}.witty-works-ext-dark-gray-background{background:#ddd}.witty-works-ext-section{flex-direction:column;justify-content:space-around;padding-bottom:0;display:flex;padding:1em!important}.witty-works-ext-ignore-section{flex-direction:row;align-items:center;padding-bottom:0;font-size:12px;display:flex;white-space:nowrap!important;justify-content:flex-start!important;margin-right:.5em!important;padding:0 0 1em .3em!important}.witty-works-ext-wittyworks-container{align-items:left;flex-direction:column;padding-bottom:.5em;display:flex}.witty-works-ext-container-rounded{border-radius:8px}.witty-works-ext-container-row{align-items:center;display:flex;flex-direction:row!important}.witty-works-ext-rephrasing ins{color:#00f!important}.witty-works-ext-rephrasing del{color:red!important}.witty-works-ext-justify-start{justify-content:flex-start!important}.witty-works-ext-justify-end{justify-content:flex-end!important}.witty-works-ext-justify-space-between{justify-content:space-between!important}.witty-works-ext-center{flex-direction:column;justify-content:center;align-items:center;display:flex}.witty-works-ext-full-padding{padding:1em}.witty-works-ext-left{flex-direction:column;justify-content:center;align-items:flex-start;display:flex}.witty-works-ext-margin-right{display:flex;margin-right:.5em!important}.witty-works-ext-margin-left{margin-left:.5em!important}.witty-works-ext-margin-top{margin-top:1em!important}.witty-works-ext-margin-top-half{margin-top:.5em!important}.witty-works-ext-margin-bottom{margin-bottom:1em!important}.witty-works-ext-body{color:#000;font-family:Lato,Arial,Helvetica,sans-serif}#witty-works-ext-popup-root{flex-direction:column;min-width:300px;display:flex}.witty-works-ext-header{justify-content:space-between;padding:1em 1em 1.3em;display:flex}.witty-works-ext-header svg{cursor:pointer}.witty-works-ext-separator{background-color:#f1f2f2;border:0;width:calc(100% + 16px);height:1px;margin-left:-8px;overflow:hidden}.witty-works-ext-cursor-pointer{cursor:pointer}.witty-works-ext-margin-auto{margin-top:auto;margin-bottom:auto}.witty-works-ext-learning-bite-dig-deeper{background-color:#fff;border:none;justify-content:space-between;align-items:center;min-width:800px;min-height:320px;margin:1em 1em .4em;display:flex}.witty-works-ext-dropdown-select{cursor:pointer;color:#8b1b1b;border:1px solid #8b1b1b;border-radius:8px;gap:10px;margin-right:1em;padding:10px 15px;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:14px;display:flex}.witty-works-dig-deeper{cursor:pointer;color:#fff;background-color:#8b1b1b;border-radius:8px;gap:10px;max-width:fit-content;margin-top:20px;margin-right:1em;padding:10px 15px;font-family:Lato,Arial,Helvetica,sans-serif;font-size:16px;font-style:normal;font-weight:400;line-height:14px;display:flex}.witty-preferences{color:#1a1a1a;font-family:Lato,Arial,Helvetica,sans-serif;font-size:15px;line-height:1.5}.witty-preferences section+section{border-top:1px solid #e6e6e6;margin-top:1.6em;padding-top:1.2em}.witty-preferences h2{margin:0 0 .6em;font-size:17px}.witty-preferences label{margin-top:1.2em;margin-bottom:.3em;font-weight:600;display:block}.witty-preferences input[type=checkbox]{width:auto;margin:0}.witty-preferences label:has(input[type=checkbox]){align-items:center;margin-top:.5em;font-weight:400;display:flex}.witty-options-muted{color:#666;font-size:.92em}.witty-category-group{margin-top:1.4em}.witty-category-group h3{color:#4a4a4a;text-transform:uppercase;letter-spacing:.04em;margin:0 0 .4em;font-size:14px}.witty-category{align-items:center;gap:.7em;padding:.32em 0;display:flex}.witty-category-label{flex:1}.witty-category-level{color:#666;text-align:right;min-width:5.5em;font-size:.88em}.witty-category-toggle{cursor:pointer;background:#ccc;border:0;border-radius:11px;flex:none;width:46px;height:22px;padding:0;transition:background .12s ease-in-out;position:relative}.witty-category-toggle .witty-category-knob{background:#fff;border-radius:50%;width:16px;height:16px;transition:left .12s ease-in-out;position:absolute;top:3px;left:3px}.witty-category-toggle.is-on{background:#5fca7d}.witty-category-toggle.is-on .witty-category-knob{left:27px}.witty-category-toggle.is-middle{background:#a8dfb8}.witty-category-toggle.is-middle .witty-category-knob{left:15px}.witty-category-toggle.is-locked{cursor:not-allowed;opacity:.55}.witty-category-toggle:focus-visible{outline-offset:2px;outline:2px solid #55b8e9}.witty-format-field{margin-top:1.2em}.witty-format-field label{margin-top:0}.witty-format-field p{margin:.2em 0 .5em}.witty-format-field select{box-sizing:border-box;width:100%;font:inherit;background:#fff;border:1px solid #ccc;border-radius:4px;padding:8px 10px}/*$vite$:1*/`)),document.head.appendChild(e)}}catch(e){console.error(`vite-plugin-css-injected-by-js`,e)}})();
3
3
  var WittyEditor=(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:`Module`});var t=Object.create,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.getPrototypeOf,o=Object.prototype.hasOwnProperty,s=(e,t,n)=>()=>{if(n)throw n[0];try{return e&&(t=e(e=0)),t}catch(e){throw n=[e],e}},c=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),l=(e,t)=>{let r={};for(var i in e)n(r,i,{get:e[i],enumerable:!0});return t||n(r,Symbol.toStringTag,{value:`Module`}),r},u=(e,t,a,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=i(t),l=0,u=c.length,d;l<u;l++)d=c[l],!o.call(e,d)&&d!==a&&n(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(s=r(t,d))||s.enumerable});return e},d=(e,r,i)=>(i=e==null?{}:t(a(e)),u(r||!e||!e.__esModule||!o.call(e,`default`)?n(i,`default`,{value:e,enumerable:!0}):i,e)),f=e=>o.call(e,`module.exports`)?e[`module.exports`]:u(n({},`__esModule`,{value:!0}),e),p=Object.defineProperty,m=(e,t)=>{let n={};for(var r in e)p(n,r,{get:e[r],enumerable:!0});return t||p(n,Symbol.toStringTag,{value:`Module`}),n};function h(e){this.content=e}h.prototype={constructor:h,find:function(e){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===e)return t;return-1},get:function(e){var t=this.find(e);return t==-1?void 0:this.content[t+1]},update:function(e,t,n){var r=n&&n!=e?this.remove(n):this,i=r.find(e),a=r.content.slice();return i==-1?a.push(n||e,t):(a[i+1]=t,n&&(a[i]=n)),new h(a)},remove:function(e){var t=this.find(e);if(t==-1)return this;var n=this.content.slice();return n.splice(t,2),new h(n)},addToStart:function(e,t){return new h([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new h(n)},addBefore:function(e,t,n){var r=this.remove(t),i=r.content.slice(),a=r.find(e);return i.splice(a==-1?i.length:a,0,t,n),new h(i)},forEach:function(e){for(var t=0;t<this.content.length;t+=2)e(this.content[t],this.content[t+1])},prepend:function(e){return e=h.from(e),e.size?new h(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=h.from(e),e.size?new h(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=h.from(e);for(var n=0;n<e.content.length;n+=2)t=t.remove(e.content[n]);return t},toObject:function(){var e={};return this.forEach(function(t,n){e[t]=n}),e},get size(){return this.content.length>>1}},h.from=function(e){if(e instanceof h)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new h(t)};function g(e,t,n){for(let r=0;;r++){if(r==e.childCount||r==t.childCount)return e.childCount==t.childCount?null:n;let i=e.child(r),a=t.child(r);if(i==a){n+=i.nodeSize;continue}if(!i.sameMarkup(a))return n;if(i.isText&&i.text!=a.text){let e=i.text,t=a.text,r=0;for(;e[r]==t[r];r++)n++;return r&&r<e.length&&r<t.length&&y(e.charCodeAt(r-1))&&v(e.charCodeAt(r))&&n--,n}if(i.content.size||a.content.size){let e=g(i.content,a.content,n+1);if(e!=null)return e}n+=i.nodeSize}}function _(e,t,n,r){for(let i=e.childCount,a=t.childCount;;){if(i==0||a==0)return i==a?null:{a:n,b:r};let o=e.child(--i),s=t.child(--a),c=o.nodeSize;if(o==s){n-=c,r-=c;continue}if(!o.sameMarkup(s))return{a:n,b:r};if(o.isText&&o.text!=s.text){let e=o.text,t=s.text,i=e.length,a=t.length;for(;i>0&&a>0&&e[i-1]==t[a-1];)i--,a--,n--,r--;return i&&a&&i<e.length&&y(e.charCodeAt(i-1))&&v(e.charCodeAt(i))&&(n++,r++),{a:n,b:r}}if(o.content.size||s.content.size){let e=_(o.content,s.content,n-1,r-1);if(e)return e}n-=c,r-=c}}function v(e){return e>=56320&&e<57344}function y(e){return e>=55296&&e<56320}var b=class e{constructor(e,t){if(this.content=e,this.size=t||0,t==null)for(let t=0;t<e.length;t++)this.size+=e[t].nodeSize}nodesBetween(e,t,n,r=0,i){for(let a=0,o=0;o<t;a++){let s=this.content[a],c=o+s.nodeSize;if(c>e&&n(s,r+o,i||null,a)!==!1&&s.content.size){let i=o+1;s.nodesBetween(Math.max(0,e-i),Math.min(s.content.size,t-i),n,r+i)}o=c}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,t,n,r){let i=``,a=!0;return this.nodesBetween(e,t,(o,s)=>{let c=o.isText?o.text.slice(Math.max(e,s)-s,t-s):o.isLeaf?r?typeof r==`function`?r(o):r:o.type.spec.leafText?o.type.spec.leafText(o):``:``;o.isBlock&&(o.isLeaf&&c||o.isTextblock)&&n&&(a?a=!1:i+=n),i+=c},0),i}append(t){if(!t.size)return this;if(!this.size)return t;let n=this.lastChild,r=t.firstChild,i=this.content.slice(),a=0;for(n.isText&&n.sameMarkup(r)&&(i[i.length-1]=n.withText(n.text+r.text),a=1);a<t.content.length;a++)i.push(t.content[a]);return new e(i,this.size+t.size)}cut(t,n=this.size){if(t==0&&n==this.size)return this;let r=[],i=0;if(n>t)for(let e=0,a=0;a<n;e++){let o=this.content[e],s=a+o.nodeSize;s>t&&((a<t||s>n)&&(o=o.isText?o.cut(Math.max(0,t-a),Math.min(o.text.length,n-a)):o.cut(Math.max(0,t-a-1),Math.min(o.content.size,n-a-1))),r.push(o),i+=o.nodeSize),a=s}return new e(r,i)}cutByIndex(t,n){return t==n?e.empty:t==0&&n==this.content.length?this:new e(this.content.slice(t,n))}replaceChild(t,n){let r=this.content[t];if(r==n)return this;let i=this.content.slice(),a=this.size+n.nodeSize-r.nodeSize;return i[t]=n,new e(i,a)}addToStart(t){return new e([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new e(this.content.concat(t),this.size+t.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let t=0;t<this.content.length;t++)if(!this.content[t].eq(e.content[t]))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(e){let t=this.content[e];if(!t)throw RangeError(`Index `+e+` out of range for `+this);return t}maybeChild(e){return this.content[e]||null}forEach(e){for(let t=0,n=0;t<this.content.length;t++){let r=this.content[t];e(r,n,t),n+=r.nodeSize}}findDiffStart(e,t=0){return g(this,e,t)}findDiffEnd(e,t=this.size,n=e.size){return _(this,e,t,n)}findIndex(e){if(e==0)return S(0,e);if(e==this.size)return S(this.content.length,e);if(e>this.size||e<0)throw RangeError(`Position ${e} outside of fragment (${this})`);for(let t=0,n=0;;t++){let r=this.child(t),i=n+r.nodeSize;if(i>=e)return i==e?S(t+1,i):S(t,n);n=i}}toString(){return`<`+this.toStringInner()+`>`}toStringInner(){return this.content.join(`, `)}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(t,n){if(!n)return e.empty;if(!Array.isArray(n))throw RangeError(`Invalid input for Fragment.fromJSON`);return e.fromArray(n.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return e.empty;let n,r=0;for(let e=0;e<t.length;e++){let i=t[e];r+=i.nodeSize,e&&i.isText&&t[e-1].sameMarkup(i)?(n||=t.slice(0,e),n[n.length-1]=i.withText(n[n.length-1].text+i.text)):n&&n.push(i)}return new e(n||t,r)}static from(t){if(!t)return e.empty;if(t instanceof e)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new e([t],t.nodeSize);throw RangeError(`Can not convert `+t+` to a Fragment`+(t.nodesBetween?` (looks like multiple versions of prosemirror-model were loaded)`:``))}};b.empty=new b([],0);var x={index:0,offset:0};function S(e,t){return x.index=e,x.offset=t,x}function C(e,t){if(e===t)return!0;if(!(e&&typeof e==`object`)||!(t&&typeof t==`object`))return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!C(e[n],t[n]))return!1}else{for(let n in e)if(!(n in t)||!C(e[n],t[n]))return!1;for(let n in t)if(!(n in e))return!1}return!0}var w=class e{constructor(e,t){this.type=e,this.attrs=t}addToSet(e){let t,n=!1;for(let r=0;r<e.length;r++){let i=e[r];if(this.eq(i))return e;if(this.type.excludes(i.type))t||=e.slice(0,r);else if(i.type.excludes(this.type))return e;else!n&&i.type.rank>this.type.rank&&(t||=e.slice(0,r),t.push(this),n=!0),t&&t.push(i)}return t||=e.slice(),n||t.push(this),t}removeFromSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return e.slice(0,t).concat(e.slice(t+1));return e}isInSet(e){for(let t=0;t<e.length;t++)if(this.eq(e[t]))return!0;return!1}eq(e){return this==e||this.type==e.type&&C(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,t){if(!t)throw RangeError(`Invalid input for Mark.fromJSON`);let n=e.marks[t.type];if(!n)throw RangeError(`There is no mark type ${t.type} in this schema`);return n.create(t.attrs)}static sameSet(e,t){if(e==t)return!0;if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].eq(t[n]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return e.none;if(t instanceof e)return[t];let n=t.slice();return n.sort((e,t)=>e.type.rank-t.type.rank),n}};w.none=[];var T=class extends Error{},E=class e{constructor(e,t,n){this.content=e,this.openStart=t,this.openEnd=n}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,n){let r=O(this.content,t+this.openStart,n,this.openStart+1,this.openEnd+1);return r&&new e(r,this.openStart,this.openEnd)}removeBetween(t,n){return new e(D(this.content,t+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+`(`+this.openStart+`,`+this.openEnd+`)`}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(t,n){if(!n)return e.empty;let r=n.openStart||0,i=n.openEnd||0;if(typeof r!=`number`||typeof i!=`number`)throw RangeError(`Invalid input for Slice.fromJSON`);return new e(b.fromJSON(t,n.content),r,i)}static maxOpen(t,n=!0){let r=0,i=0;for(let e=t.firstChild;e&&!e.isLeaf&&(n||!e.type.spec.isolating);e=e.firstChild)r++;for(let e=t.lastChild;e&&!e.isLeaf&&(n||!e.type.spec.isolating);e=e.lastChild)i++;return new e(t,r,i)}};E.empty=new E(b.empty,0,0);function D(e,t,n){let{index:r,offset:i}=e.findIndex(t),a=e.maybeChild(r),{index:o,offset:s}=e.findIndex(n);if(i==t||a.isText){if(s!=n&&!e.child(o).isText)throw RangeError(`Removing non-flat range`);return e.cut(0,t).append(e.cut(n))}if(r!=o)throw RangeError(`Removing non-flat range`);return e.replaceChild(r,a.copy(D(a.content,t-i-1,n-i-1)))}function O(e,t,n,r,i,a){let{index:o,offset:s}=e.findIndex(t),c=e.maybeChild(o);if(s==t||c.isText)return a&&r<=0&&i<=0&&!a.canReplace(o,o,n)?null:e.cut(0,t).append(n).append(e.cut(t));let l=O(c.content,t-s-1,n,o==0?r-1:0,o==e.childCount-1?i-1:0,c);return l&&e.replaceChild(o,c.copy(l))}function ee(e,t,n){if(n.openStart>e.depth)throw new T(`Inserted content deeper than insertion position`);if(e.depth-n.openStart!=t.depth-n.openEnd)throw new T(`Inconsistent open depths`);return te(e,t,n,0)}function te(e,t,n,r){let i=e.index(r),a=e.node(r);if(i==t.index(r)&&r<e.depth-n.openStart){let o=te(e,t,n,r+1);return a.copy(a.content.replaceChild(i,o))}if(!n.content.size)return ie(a,oe(e,t,r));if(!n.openStart&&!n.openEnd&&e.depth==r&&t.depth==r){let r=e.parent,i=r.content;return ie(r,i.cut(0,e.parentOffset).append(n.content).append(i.cut(t.parentOffset)))}{let{start:i,end:o}=se(n,e);return ie(a,ae(e,i,o,t,r))}}function ne(e,t){if(!t.type.compatibleContent(e.type))throw new T(`Cannot join `+t.type.name+` onto `+e.type.name)}function re(e,t,n){let r=e.node(n);return ne(r,t.node(n)),r}function k(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function A(e,t,n,r){let i=(t||e).node(n),a=0,o=t?t.index(n):i.childCount;e&&(a=e.index(n),e.depth>n?a++:e.textOffset&&(k(e.nodeAfter,r),a++));for(let e=a;e<o;e++)k(i.child(e),r);t&&t.depth==n&&t.textOffset&&k(t.nodeBefore,r)}function ie(e,t){if(!e.type.validContent(t))throw new T(`Invalid content for node `+e.type.name);return e.copy(t)}function ae(e,t,n,r,i){let a=e.depth>i&&re(e,t,i+1),o=r.depth>i&&re(n,r,i+1),s=[];return A(null,e,i,s),a&&o&&t.index(i)==n.index(i)?(ne(a,o),k(ie(a,ae(e,t,n,r,i+1)),s)):(a&&k(ie(a,oe(e,t,i+1)),s),A(t,n,i,s),o&&k(ie(o,oe(n,r,i+1)),s)),A(r,null,i,s),new b(s)}function oe(e,t,n){let r=[];return A(null,e,n,r),e.depth>n&&k(ie(re(e,t,n+1),oe(e,t,n+1)),r),A(t,null,n,r),new b(r)}function se(e,t){let n=t.depth-e.openStart,r=t.node(n).copy(e.content);for(let e=n-1;e>=0;e--)r=t.node(e).copy(b.from(r));return{start:r.resolveNoCache(e.openStart+n),end:r.resolveNoCache(r.content.size-e.openEnd-n)}}var ce=class e{constructor(e,t,n){this.pos=e,this.path=t,this.parentOffset=n,this.depth=t.length/3-1}resolveDepth(e){return e==null?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[this.resolveDepth(e)*3]}index(e){return this.path[this.resolveDepth(e)*3+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e==this.depth&&!this.textOffset?0:1)}start(e){return e=this.resolveDepth(e),e==0?0:this.path[e*3-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(e=this.resolveDepth(e),!e)throw RangeError(`There is no position before the top-level node`);return e==this.depth+1?this.pos:this.path[e*3-1]}after(e){if(e=this.resolveDepth(e),!e)throw RangeError(`There is no position after the top-level node`);return e==this.depth+1?this.pos:this.path[e*3-1]+this.path[e*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,t=this.index(this.depth);if(t==e.childCount)return null;let n=this.pos-this.path[this.path.length-1],r=e.child(t);return n?e.child(t).cut(n):r}get nodeBefore(){let e=this.index(this.depth),t=this.pos-this.path[this.path.length-1];return t?this.parent.child(e).cut(0,t):e==0?null:this.parent.child(e-1)}posAtIndex(e,t){t=this.resolveDepth(t);let n=this.path[t*3],r=t==0?0:this.path[t*3-1]+1;for(let t=0;t<e;t++)r+=n.child(t).nodeSize;return r}marks(){let e=this.parent,t=this.index();if(e.content.size==0)return w.none;if(this.textOffset)return e.child(t).marks;let n=e.maybeChild(t-1),r=e.maybeChild(t);if(!n){let e=n;n=r,r=e}let i=n.marks;for(var a=0;a<i.length;a++)i[a].type.spec.inclusive===!1&&(!r||!i[a].isInSet(r.marks))&&(i=i[a--].removeFromSet(i));return i}marksAcross(e){let t=this.parent.maybeChild(this.index());if(!t||!t.isInline)return null;let n=t.marks,r=e.parent.maybeChild(e.index());for(var i=0;i<n.length;i++)n[i].type.spec.inclusive===!1&&(!r||!n[i].isInSet(r.marks))&&(n=n[i--].removeFromSet(n));return n}sharedDepth(e){for(let t=this.depth;t>0;t--)if(this.start(t)<=e&&this.end(t)>=e)return t;return 0}blockRange(e=this,t){if(e.pos<this.pos)return e.blockRange(this);for(let n=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);n>=0;n--)if(e.pos<=this.end(n)&&(!t||t(this.node(n))))return new fe(this,e,n);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e=``;for(let t=1;t<=this.depth;t++)e+=(e?`/`:``)+this.node(t).type.name+`_`+this.index(t-1);return e+`:`+this.parentOffset}static resolve(t,n){if(!(n>=0&&n<=t.content.size))throw RangeError(`Position `+n+` out of range`);let r=[],i=0,a=n;for(let e=t;;){let{index:t,offset:n}=e.content.findIndex(a),o=a-n;if(r.push(e,t,i+n),!o||(e=e.child(t),e.isText))break;a=o-1,i+=n+1}return new e(n,r,a)}static resolveCached(t,n){let r=de.get(t);if(r)for(let e=0;e<r.elts.length;e++){let t=r.elts[e];if(t.pos==n)return t}else de.set(t,r=new le);let i=r.elts[r.i]=e.resolve(t,n);return r.i=(r.i+1)%ue,i}},le=class{constructor(){this.elts=[],this.i=0}},ue=12,de=new WeakMap,fe=class{constructor(e,t,n){this.$from=e,this.$to=t,this.depth=n}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)}},pe=Object.create(null),me=class e{constructor(e,t,n,r=w.none){this.type=e,this.attrs=t,this.marks=r,this.content=n||b.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,t,n,r=0){this.content.nodesBetween(e,t,n,r,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,``)}textBetween(e,t,n,r){return this.content.textBetween(e,t,n,r)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,t,n){return this.type==e&&C(this.attrs,t||e.defaultAttrs||pe)&&w.sameSet(this.marks,n||w.none)}copy(t=null){return t==this.content?this:new e(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new e(this.type,this.attrs,this.content,t)}cut(e,t=this.content.size){return e==0&&t==this.content.size?this:this.copy(this.content.cut(e,t))}slice(e,t=this.content.size,n=!1){if(e==t)return E.empty;let r=this.resolve(e),i=this.resolve(t),a=n?0:r.sharedDepth(t),o=r.start(a);return new E(r.node(a).content.cut(r.pos-o,i.pos-o),r.depth-a,i.depth-a)}replace(e,t,n){return ee(this.resolve(e),this.resolve(t),n)}nodeAt(e){for(let t=this;;){let{index:n,offset:r}=t.content.findIndex(e);if(t=t.maybeChild(n),!t)return null;if(r==e||t.isText)return t;e-=r+1}}childAfter(e){let{index:t,offset:n}=this.content.findIndex(e);return{node:this.content.maybeChild(t),index:t,offset:n}}childBefore(e){if(e==0)return{node:null,index:0,offset:0};let{index:t,offset:n}=this.content.findIndex(e);if(n<e)return{node:this.content.child(t),index:t,offset:n};let r=this.content.child(t-1);return{node:r,index:t-1,offset:n-r.nodeSize}}resolve(e){return ce.resolveCached(this,e)}resolveNoCache(e){return ce.resolve(this,e)}rangeHasMark(e,t,n){let r=!1;return t>e&&this.nodesBetween(e,t,e=>(n.isInSet(e.marks)&&(r=!0),!r)),r}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 e=this.type.name;return this.content.size&&(e+=`(`+this.content.toStringInner()+`)`),ge(this.marks,e)}contentMatchAt(e){let t=this.type.contentMatch.matchFragment(this.content,0,e);if(!t)throw Error(`Called contentMatchAt on a node with invalid content`);return t}canReplace(e,t,n=b.empty,r=0,i=n.childCount){let a=this.contentMatchAt(e).matchFragment(n,r,i),o=a&&a.matchFragment(this.content,t);if(!o||!o.validEnd)return!1;for(let e=r;e<i;e++)if(!this.type.allowsMarks(n.child(e).marks))return!1;return!0}canReplaceWith(e,t,n,r){if(r&&!this.type.allowsMarks(r))return!1;let i=this.contentMatchAt(e).matchType(n),a=i&&i.matchFragment(this.content,t);return a?a.validEnd:!1}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),_e(this.type.attrs,this.attrs,`node`,this.type.name);let e=w.none;for(let t=0;t<this.marks.length;t++){let n=this.marks[t];_e(n.type.attrs,n.attrs,`mark`,n.type.name),e=n.addToSet(e)}if(!w.sameSet(e,this.marks))throw RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(e=>e.type.name)}`);this.content.forEach(e=>e.check())}toJSON(){let e={type:this.type.name};for(let t in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(e=>e.toJSON())),e}static fromJSON(e,t){if(!t)throw RangeError(`Invalid input for Node.fromJSON`);let n;if(t.marks){if(!Array.isArray(t.marks))throw RangeError(`Invalid mark data for Node.fromJSON`);n=t.marks.map(e.markFromJSON)}if(t.type==`text`){if(typeof t.text!=`string`)throw RangeError(`Invalid text node in JSON`);return e.text(t.text,n)}let r=b.fromJSON(e,t.content);return e.nodeType(t.type).create(t.attrs,r,n)}};me.prototype.text=void 0;var he=class e extends me{constructor(e,t,n,r){if(super(e,t,null,r),!n)throw RangeError(`Empty text nodes are not allowed`);this.text=n}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):ge(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(e,t){return this.text.slice(e,t)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new e(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new e(this.type,this.attrs,t,this.marks)}cut(e=0,t=this.text.length){return e==0&&t==this.text.length?this:this.withText(this.text.slice(e,t))}eq(e){return this.sameMarkup(e)&&this.text==e.text}toJSON(){let e=super.toJSON();return e.text=this.text,e}};function ge(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+`(`+t+`)`;return t}function _e(e,t,n,r){for(let i in t)if(!(i in e))throw RangeError(`Unsupported attribute ${i} for ${n} of type ${r}`);for(let n in e)e[n].validate&&e[n].validate(t[n])}var ve=class e{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(t,n){let r=new ye(t,n);if(r.next==null)return e.empty;let i=be(r);r.next&&r.err(`Unexpected trailing text`);let a=Ae(De(i));return je(a,r),a}matchType(e){for(let t=0;t<this.next.length;t++)if(this.next[t].type==e)return this.next[t].next;return null}matchFragment(e,t=0,n=e.childCount){let r=this;for(let i=t;r&&i<n;i++)r=r.matchType(e.child(i).type);return r}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:t}=this.next[e];if(!(t.isText||t.hasRequiredAttrs()))return t}return null}compatible(e){for(let t=0;t<this.next.length;t++)for(let n=0;n<e.next.length;n++)if(this.next[t].type==e.next[n].type)return!0;return!1}fillBefore(e,t=!1,n=0){let r=[this];function i(a,o){let s=a.matchFragment(e,n);if(s&&(!t||s.validEnd))return b.from(o.map(e=>e.createAndFill()));for(let e=0;e<a.next.length;e++){let{type:t,next:n}=a.next[e];if(!(t.isText||t.hasRequiredAttrs())&&r.indexOf(n)==-1){r.push(n);let e=i(n,o.concat(t));if(e)return e}}return null}return i(this,[])}findWrapping(e){for(let t=0;t<this.wrapCache.length;t+=2)if(this.wrapCache[t]==e)return this.wrapCache[t+1];let t=this.computeWrapping(e);return this.wrapCache.push(e,t),t}computeWrapping(e){let t=Object.create(null),n=[{match:this,type:null,via:null}];for(;n.length;){let r=n.shift(),i=r.match;if(i.matchType(e)){let e=[];for(let t=r;t.type;t=t.via)e.push(t.type);return e.reverse()}for(let e=0;e<i.next.length;e++){let{type:a,next:o}=i.next[e];!a.isLeaf&&!a.hasRequiredAttrs()&&!(a.name in t)&&(!r.type||o.validEnd)&&(n.push({match:a.contentMatch,type:a,via:r}),t[a.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];function t(n){e.push(n);for(let r=0;r<n.next.length;r++)e.indexOf(n.next[r].next)==-1&&t(n.next[r].next)}return t(this),e.map((t,n)=>{let r=n+(t.validEnd?`*`:` `)+` `;for(let n=0;n<t.next.length;n++)r+=(n?`, `:``)+t.next[n].type.name+`->`+e.indexOf(t.next[n].next);return r}).join(`
4
4
  `)}};ve.empty=new ve(!0);var ye=class{constructor(e,t){this.string=e,this.nodeTypes=t,this.inline=null,this.pos=0,this.tokens=e.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(e){return this.next==e&&(this.pos++||!0)}err(e){throw SyntaxError(e+` (in content expression '`+this.string+`')`)}};function be(e){let t=[];do t.push(xe(e));while(e.eat(`|`));return t.length==1?t[0]:{type:`choice`,exprs:t}}function xe(e){let t=[];do t.push(Se(e));while(e.next&&e.next!=`)`&&e.next!=`|`);return t.length==1?t[0]:{type:`seq`,exprs:t}}function Se(e){let t=Ee(e);for(;;)if(e.eat(`+`))t={type:`plus`,expr:t};else if(e.eat(`*`))t={type:`star`,expr:t};else if(e.eat(`?`))t={type:`opt`,expr:t};else if(e.eat(`{`))t=we(e,t);else break;return t}function Ce(e){/\D/.test(e.next)&&e.err(`Expected number, got '`+e.next+`'`);let t=Number(e.next);return e.pos++,t}function we(e,t){let n=Ce(e),r=n;return e.eat(`,`)&&(r=e.next==`}`?-1:Ce(e)),e.eat(`}`)||e.err(`Unclosed braced range`),{type:`range`,min:n,max:r,expr:t}}function Te(e,t){let n=e.nodeTypes,r=n[t];if(r)return[r];let i=[];for(let e in n){let r=n[e];r.isInGroup(t)&&i.push(r)}return i.length==0&&e.err(`No node type or group '`+t+`' found`),i}function Ee(e){if(e.eat(`(`)){let t=be(e);return e.eat(`)`)||e.err(`Missing closing paren`),t}if(/\W/.test(e.next))e.err(`Unexpected token '`+e.next+`'`);else{let t=Te(e,e.next).map(t=>(e.inline==null?e.inline=t.isInline:e.inline!=t.isInline&&e.err(`Mixing inline and block content`),{type:`name`,value:t}));return e.pos++,t.length==1?t[0]:{type:`choice`,exprs:t}}}function De(e){let t=[[]];return i(a(e,0),n()),t;function n(){return t.push([])-1}function r(e,n,r){let i={term:r,to:n};return t[e].push(i),i}function i(e,t){e.forEach(e=>e.to=t)}function a(e,t){if(e.type==`choice`)return e.exprs.reduce((e,n)=>e.concat(a(n,t)),[]);if(e.type==`seq`)for(let r=0;;r++){let o=a(e.exprs[r],t);if(r==e.exprs.length-1)return o;i(o,t=n())}else if(e.type==`star`){let o=n();return r(t,o),i(a(e.expr,o),o),[r(o)]}else if(e.type==`plus`){let o=n();return i(a(e.expr,t),o),i(a(e.expr,o),o),[r(o)]}else if(e.type==`opt`)return[r(t)].concat(a(e.expr,t));else if(e.type==`range`){let o=t;for(let t=0;t<e.min;t++){let t=n();i(a(e.expr,o),t),o=t}if(e.max==-1)i(a(e.expr,o),o);else for(let t=e.min;t<e.max;t++){let t=n();r(o,t),i(a(e.expr,o),t),o=t}return[r(o)]}else if(e.type==`name`)return[r(t,void 0,e.value)];else throw Error(`Unknown expr type`)}}function Oe(e,t){return t-e}function ke(e,t){let n=[];return r(t),n.sort(Oe);function r(t){let i=e[t];if(i.length==1&&!i[0].term)return r(i[0].to);n.push(t);for(let e=0;e<i.length;e++){let{term:t,to:a}=i[e];!t&&n.indexOf(a)==-1&&r(a)}}}function Ae(e){let t=Object.create(null);return n(ke(e,0));function n(r){let i=[];r.forEach(t=>{e[t].forEach(({term:t,to:n})=>{if(!t)return;let r;for(let e=0;e<i.length;e++)i[e][0]==t&&(r=i[e][1]);ke(e,n).forEach(e=>{r||i.push([t,r=[]]),r.indexOf(e)==-1&&r.push(e)})})});let a=t[r.join(`,`)]=new ve(r.indexOf(e.length-1)>-1);for(let e=0;e<i.length;e++){let r=i[e][1].sort(Oe);a.next.push({type:i[e][0],next:t[r.join(`,`)]||n(r)})}return a}}function je(e,t){for(let n=0,r=[e];n<r.length;n++){let e=r[n],i=!e.validEnd,a=[];for(let t=0;t<e.next.length;t++){let{type:n,next:o}=e.next[t];a.push(n.name),i&&!(n.isText||n.hasRequiredAttrs())&&(i=!1),r.indexOf(o)==-1&&r.push(o)}i&&t.err(`Only non-generatable nodes (`+a.join(`, `)+`) in a required position (see https://prosemirror.net/docs/guide/#generatable)`)}}function Me(e){let t=Object.create(null);for(let n in e){let r=e[n];if(!r.hasDefault)return null;t[n]=r.default}return t}function Ne(e,t){let n=Object.create(null);for(let r in e){let i=e[r],a=t&&t[r];if(a===void 0){if(i.hasDefault)a=i.default;else throw RangeError(`No value supplied for attribute `+r)}else i.validate&&i.validate(a);n[r]=a}return n}function Pe(e,t){let n=Object.create(null);if(t)for(let r in t)n[r]=new Le(e,r,t[r]);return n}var Fe=class e{constructor(e,t,n){this.name=e,this.schema=t,this.spec=n,this.markSet=null,this.groups=n.group?n.group.split(` `):[],this.attrs=Pe(e,n.attrs),this.defaultAttrs=Me(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(n.inline||e==`text`),this.isText=e==`text`}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==ve.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(e){return this.groups.indexOf(e)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?`pre`:`normal`)}hasRequiredAttrs(){for(let e in this.attrs)if(this.attrs[e].isRequired)return!0;return!1}compatibleContent(e){return this==e||this.contentMatch.compatible(e.contentMatch)}computeAttrs(e){return!e&&this.defaultAttrs?this.defaultAttrs:Ne(this.attrs,e)}create(e=null,t,n){if(this.isText)throw Error(`NodeType.create can't construct text nodes`);return new me(this,this.computeAttrs(e),b.from(t),w.setFrom(n))}createChecked(e=null,t,n){return t=b.from(t),this.checkContent(t),new me(this,this.computeAttrs(e),t,w.setFrom(n))}createAndFill(e=null,t,n){if(e=this.computeAttrs(e),t=b.from(t),t.size){let e=this.contentMatch.fillBefore(t);if(!e)return null;t=e.append(t)}let r=this.contentMatch.matchFragment(t),i=r&&r.fillBefore(b.empty,!0);return i?new me(this,e,t.append(i),w.setFrom(n)):null}validContent(e){let t=this.contentMatch.matchFragment(e);if(!t||!t.validEnd)return!1;for(let t=0;t<e.childCount;t++)if(!this.allowsMarks(e.child(t).marks))return!1;return!0}checkContent(e){if(!this.validContent(e))throw RangeError(`Invalid content for node ${this.name}: ${e.toString().slice(0,50)}`)}checkAttrs(e){}allowsMarkType(e){return this.markSet==null||this.markSet.indexOf(e)>-1}allowsMarks(e){if(this.markSet==null)return!0;for(let t=0;t<e.length;t++)if(!this.allowsMarkType(e[t].type))return!1;return!0}allowedMarks(e){if(this.markSet==null)return e;let t;for(let n=0;n<e.length;n++)this.allowsMarkType(e[n].type)?t&&t.push(e[n]):t||=e.slice(0,n);return t?t.length?t:w.none:e}static compile(t,n){let r=Object.create(null);t.forEach((t,i)=>r[t]=new e(t,n,i));let i=n.spec.topNode||`doc`;if(!r[i])throw RangeError(`Schema is missing its top node type ('`+i+`')`);if(!r.text)throw RangeError(`Every schema needs a 'text' type`);for(let e in r.text.attrs)throw RangeError(`The text node type should not have attributes`);return r}};function Ie(e,t,n){let r=n.split(`|`);return n=>{let i=n===null?`null`:typeof n;if(r.indexOf(i)<0)throw RangeError(`Expected value of type ${r} for attribute ${t} on type ${e}, got ${i}`)}}var Le=class{constructor(e,t,n){this.hasDefault=Object.prototype.hasOwnProperty.call(n,`default`),this.default=n.default,this.validate=typeof n.validate==`string`?Ie(e,t,n.validate):n.validate}get isRequired(){return!this.hasDefault}},Re=class e{constructor(e,t,n,r){this.name=e,this.rank=t,this.schema=n,this.spec=r,this.attrs=Pe(e,r.attrs),this.excluded=null;let i=Me(this.attrs);this.instance=i?new w(this,i):null}create(e=null){return!e&&this.instance?this.instance:new w(this,Ne(this.attrs,e))}static compile(t,n){let r=Object.create(null),i=0;return t.forEach((t,a)=>r[t]=new e(t,i++,n,a)),r}removeFromSet(e){for(var t=0;t<e.length;t++)e[t].type==this&&(e=e.slice(0,t).concat(e.slice(t+1)),t--);return e}isInSet(e){for(let t=0;t<e.length;t++)if(e[t].type==this)return e[t]}excludes(e){return this.excluded.indexOf(e)>-1}},ze=class{constructor(e){this.linebreakReplacement=null,this.cached=Object.create(null);let t=this.spec={};for(let n in e)t[n]=e[n];t.nodes=h.from(e.nodes),t.marks=h.from(e.marks||{}),this.nodes=Fe.compile(this.spec.nodes,this),this.marks=Re.compile(this.spec.marks,this);let n=Object.create(null);for(let e in this.nodes){if(e in this.marks)throw RangeError(e+` can not be both a node and a mark`);let t=this.nodes[e],r=t.spec.content||``,i=t.spec.marks;if(t.contentMatch=n[r]||(n[r]=ve.parse(r,this.nodes)),t.inlineContent=t.contentMatch.inlineContent,t.spec.linebreakReplacement){if(this.linebreakReplacement)throw RangeError(`Multiple linebreak nodes defined`);if(!t.isInline||!t.isLeaf)throw RangeError(`Linebreak replacement nodes must be inline leaf nodes`);this.linebreakReplacement=t}t.markSet=i==`_`?null:i?Be(this,i.split(` `)):i==``||!t.inlineContent?[]:null}for(let e in this.marks){let t=this.marks[e],n=t.spec.excludes;t.excluded=n==null?[t]:n==``?[]:Be(this,n.split(` `))}this.nodeFromJSON=e=>me.fromJSON(this,e),this.markFromJSON=e=>w.fromJSON(this,e),this.topNodeType=this.nodes[this.spec.topNode||`doc`],this.cached.wrappings=Object.create(null)}node(e,t=null,n,r){if(typeof e==`string`)e=this.nodeType(e);else if(!(e instanceof Fe))throw RangeError(`Invalid node type: `+e);else if(e.schema!=this)throw RangeError(`Node type from different schema used (`+e.name+`)`);return e.createChecked(t,n,r)}text(e,t){let n=this.nodes.text;return new he(n,n.defaultAttrs,e,w.setFrom(t))}mark(e,t){return typeof e==`string`&&(e=this.marks[e]),e.create(t)}nodeType(e){let t=this.nodes[e];if(!t)throw RangeError(`Unknown node type: `+e);return t}};function Be(e,t){let n=[];for(let r=0;r<t.length;r++){let i=t[r],a=e.marks[i],o=a;if(a)n.push(a);else for(let t in e.marks){let r=e.marks[t];(i==`_`||r.spec.group&&r.spec.group.split(` `).indexOf(i)>-1)&&n.push(o=r)}if(!o)throw SyntaxError(`Unknown mark type: '`+t[r]+`'`)}return n}function Ve(e){return e.tag!=null}function He(e){return e.style!=null}var Ue=class e{constructor(e,t){this.schema=e,this.rules=t,this.tags=[],this.styles=[];let n=this.matchedStyles=[];t.forEach(e=>{if(Ve(e))this.tags.push(e);else if(He(e)){let t=/[^=]*/.exec(e.style)[0];n.indexOf(t)<0&&n.push(t),this.styles.push(e)}}),this.normalizeLists=!this.tags.some(t=>{if(!/^(ul|ol)\b/.test(t.tag)||!t.node)return!1;let n=e.nodes[t.node];return n.contentMatch.matchType(n)})}parse(e,t={}){let n=new Qe(this,t,!1);return n.addAll(e,w.none,t.from,t.to),n.finish()}parseSlice(e,t={}){let n=new Qe(this,t,!0);return n.addAll(e,w.none,t.from,t.to),E.maxOpen(n.finish())}matchTag(e,t,n){for(let r=n?this.tags.indexOf(n)+1:0;r<this.tags.length;r++){let n=this.tags[r];if(et(e,n.tag)&&(n.namespace===void 0||e.namespaceURI==n.namespace)&&(!n.context||t.matchesContext(n.context))){if(n.getAttrs){let t=n.getAttrs(e);if(t===!1)continue;n.attrs=t||void 0}return n}}}matchStyle(e,t,n,r){for(let i=r?this.styles.indexOf(r)+1:0;i<this.styles.length;i++){let r=this.styles[i],a=r.style;if(!(a.indexOf(e)!=0||r.context&&!n.matchesContext(r.context)||a.length>e.length&&(a.charCodeAt(e.length)!=61||a.slice(e.length+1)!=t))){if(r.getAttrs){let e=r.getAttrs(t);if(e===!1)continue;r.attrs=e||void 0}return r}}}static schemaRules(e){let t=[];function n(e){let n=e.priority==null?50:e.priority,r=0;for(;r<t.length;r++){let e=t[r];if((e.priority==null?50:e.priority)<n)break}t.splice(r,0,e)}for(let t in e.marks){let r=e.marks[t].spec.parseDOM;r&&r.forEach(e=>{n(e=tt(e)),e.mark||e.ignore||e.clearMark||(e.mark=t)})}for(let t in e.nodes){let r=e.nodes[t].spec.parseDOM;r&&r.forEach(e=>{n(e=tt(e)),e.node||e.ignore||e.mark||(e.node=t)})}return t}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new e(t,e.schemaRules(t)))}},We={address:!0,article:!0,aside:!0,blockquote:!0,body:!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},Ge={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},Ke={ol:!0,ul:!0},qe=1,Je=2,Ye=4;function Xe(e,t,n){return t==null?e&&e.whitespace==`pre`?3:n&-5:(t?qe:0)|(t===`full`?Je:0)}var Ze=class{constructor(e,t,n,r,i,a){this.type=e,this.attrs=t,this.marks=n,this.solid=r,this.options=a,this.content=[],this.activeMarks=w.none,this.match=i||(a&Ye?null:e.contentMatch)}findWrapping(e){if(!this.match){if(!this.type)return[];let t=this.type.contentMatch.fillBefore(b.from(e));if(t)this.match=this.type.contentMatch.matchFragment(t);else{let t=this.type.contentMatch,n;return(n=t.findWrapping(e.type))?(this.match=t,n):null}}return this.match.findWrapping(e.type)}finish(e){if(!(this.options&qe)){let e=this.content[this.content.length-1],t;if(e&&e.isText&&(t=/[ \t\r\n\u000c]+$/.exec(e.text))){let n=e;e.text.length==t[0].length?this.content.pop():this.content[this.content.length-1]=n.withText(n.text.slice(0,n.text.length-t[0].length))}}let t=b.from(this.content);return!e&&this.match&&(t=t.append(this.match.fillBefore(b.empty,!0))),this.type?this.type.create(this.attrs,t,this.marks):t}inlineContext(e){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:e.parentNode&&!We.hasOwnProperty(e.parentNode.nodeName.toLowerCase())}},Qe=class{constructor(e,t,n){this.parser=e,this.options=t,this.isOpen=n,this.open=0,this.localPreserveWS=!1;let r=t.topNode,i,a=Xe(null,t.preserveWhitespace,0)|(n?Ye:0);i=r?new Ze(r.type,r.attrs,w.none,!0,t.topMatch||r.type.contentMatch,a):n?new Ze(null,null,w.none,!0,null,a):new Ze(e.schema.topNodeType,null,w.none,!0,null,a),this.nodes=[i],this.find=t.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(e,t){e.nodeType==3?this.addTextNode(e,t):e.nodeType==1&&this.addElement(e,t)}addTextNode(e,t){let n=e.nodeValue,r=this.top,i=r.options&Je?`full`:this.localPreserveWS||(r.options&qe)>0,{schema:a}=this.parser;if(i===`full`||r.inlineContext(e)||/[^ \t\r\n\u000c]/.test(n)){if(!i){if(n=n.replace(/[ \t\r\n\u000c]+/g,` `),/^[ \t\r\n\u000c]/.test(n)&&this.open==this.nodes.length-1){let t=r.content[r.content.length-1],i=e.previousSibling;(!t||i&&i.nodeName==`BR`||t.isText&&/[ \t\r\n\u000c]$/.test(t.text))&&(n=n.slice(1))}}else if(i===`full`)n=n.replace(/\r\n?/g,`
@@ -128,13 +128,13 @@ img.ProseMirror-separator {
128
128
  `):``,markdownTokenizer:{name:`orderedList`,level:`block`,start:()=>-1,tokenize:(e,t,n)=>{let r=e.split(`
129
129
  `),[i,a]=gg(r);if(i.length===0)return;let o=yg(i,i[0].indent,n);if(o.length!==0)return{type:`list`,ordered:!0,start:i[0]?.number||1,typeMarker:i[0]?.type,items:o,raw:r.slice(0,a).join(`
130
130
  `)}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleOrderedList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(xg,this.editor.getAttributes(Sg)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addProseMirrorPlugins(){return[new Gn({props:{handlePaste:(e,t)=>{if((t.clipboardData?.getData(`text/html`))?.trim())return!1;let n=t.clipboardData?.getData(`text/plain`);if(!n)return!1;let r=vg(n);if(!r)return!1;try{let t=e.state.schema.nodeFromJSON(r),n=e.state.tr.replaceSelectionWith(t);return e.dispatch(n),!0}catch{return!1}}}})]},addInputRules(){let e=(e,t)=>(!t.attrs.type||t.attrs.type===`1`)&&t.childCount+t.attrs.start===+e[1],t=Cf({find:Cg,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:e});return(this.options.keepMarks||this.options.keepAttributes)&&(t=Cf({find:Cg,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(Sg)}),joinPredicate:e,editor:this.editor})),[t]}}),Eg=/^\s*(\[([( |x])?\])\s$/,Dg=`position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0`,Og=(e,t,n)=>{var r;return(n==null||(r=n.checkboxLabel)==null?void 0:r.call(n,e,t))||`Task item checkbox for ${e.textContent||`empty task item`}`},kg=wf.create({name:`taskItem`,addOptions(){return{nested:!1,HTMLAttributes:{},taskListTypeName:`taskList`,a11y:void 0}},content(){return this.options.nested?`paragraph block*`:`paragraph+`},defining:!0,addAttributes(){return{checked:{default:!1,keepOnSplit:!1,parseHTML:e=>{let t=e.getAttribute(`data-checked`);return t===``||t===`true`},renderHTML:e=>({"data-checked":e.checked})}}},parseHTML(){return[{tag:`li[data-type="${this.name}"]`,priority:51,contentElement:e=>e.querySelector(`div`)??e}]},renderHTML({node:e,HTMLAttributes:t}){return[`li`,Ql(this.options.HTMLAttributes,t,{"data-type":this.name}),[`label`,[`input`,{type:`checkbox`,checked:e.attrs.checked?`checked`:null}],[`span`]],[`div`,0]]},parseMarkdown:(e,t)=>{let n=[];if(e.tokens&&e.tokens.length>0?n.push(t.createNode(`paragraph`,{},t.parseInline(e.tokens))):e.text?n.push(t.createNode(`paragraph`,{},[t.createNode(`text`,{text:e.text})])):n.push(t.createNode(`paragraph`,{},[])),e.nestedTokens&&e.nestedTokens.length>0){let r=t.parseChildren(e.nestedTokens);n.push(...r)}return t.createNode(`taskItem`,{checked:e.checked||!1},n)},renderMarkdown:(e,t)=>Bd(e,t,`- [${e.attrs?.checked?`x`:` `}] `),addExtensions(){return this.options.nested?[Ph(this.name,[this.options.taskListTypeName])]:[]},addKeyboardShortcuts(){let e={Enter:()=>this.editor.commands.splitListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)};return this.options.nested?{...e,Tab:()=>this.editor.commands.sinkListItem(this.name)}:e},addNodeView(){return({node:e,HTMLAttributes:t,getPos:n,editor:r})=>{let i=document.createElement(`li`),a=document.createElement(`label`),o=document.createElement(`span`),s=document.createElement(`input`),c=document.createElement(`div`);o.style.cssText=Dg;let l=e=>{let t=Og(e,e.attrs.checked,this.options.a11y);s.setAttribute(`aria-label`,t),o.textContent=t};l(e),a.contentEditable=`false`,s.type=`checkbox`,s.addEventListener(`mousedown`,e=>e.preventDefault()),s.addEventListener(`change`,t=>{if(!r.isEditable&&!this.options.onReadOnlyChecked){s.checked=!s.checked;return}let{checked:i}=t.target;r.isEditable&&typeof n==`function`&&r.chain().focus(void 0,{scrollIntoView:!1}).command(({tr:e})=>{let t=n();if(typeof t!=`number`)return!1;let r=e.doc.nodeAt(t);return e.setNodeMarkup(t,void 0,{...r?.attrs,checked:i}),!0}).run(),!r.isEditable&&this.options.onReadOnlyChecked&&(this.options.onReadOnlyChecked(e,i)||(s.checked=!s.checked))}),Object.entries(this.options.HTMLAttributes).forEach(([e,t])=>{i.setAttribute(e,t)}),i.dataset.checked=e.attrs.checked,s.checked=e.attrs.checked,a.append(s,o),i.append(a,c),Object.entries(t).forEach(([e,t])=>{i.setAttribute(e,t)});let u=new Set(Object.keys(t));return{dom:i,contentDOM:c,update:e=>{if(e.type!==this.type)return!1;i.dataset.checked=e.attrs.checked,s.checked=e.attrs.checked,l(e);let t=r.extensionManager.attributes,n=$l(e,t),a=new Set(Object.keys(n)),o=this.options.HTMLAttributes;return u.forEach(e=>{a.has(e)||(e in o?i.setAttribute(e,o[e]):i.removeAttribute(e))}),Object.entries(n).forEach(([e,t])=>{t==null?e in o?i.setAttribute(e,o[e]):i.removeAttribute(e):i.setAttribute(e,t)}),u=a,!0}}}},addInputRules(){return[Cf({find:Eg,type:this.type,getAttributes:e=>({checked:e[e.length-1]===`x`})})]}}),Ag=wf.create({name:`taskList`,addOptions(){return{itemTypeName:`taskItem`,HTMLAttributes:{}}},group:`block list`,content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:`ul[data-type="${this.name}"]`,priority:51}]},renderHTML({HTMLAttributes:e}){return[`ul`,Ql(this.options.HTMLAttributes,e,{"data-type":this.name}),0]},parseMarkdown:(e,t)=>t.createNode(`taskList`,{},t.parseChildren(e.items||[])),renderMarkdown:(e,t)=>e.content?t.renderChildren(e.content,`
131
- `):``,markdownTokenizer:{name:`taskList`,level:`block`,start(e){let t=e.match(/^\s*[-+*]\s+\[([ xX])\]\s+/)?.index;return t===void 0?-1:t},tokenize(e,t,n){let r=e=>{let t=Ld(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(t){let r={type:`taskList`,raw:t.raw,items:t.items},i=e.slice(t.raw.length);return i.trim()?[r,...n.blockTokens(i)]:[r]}return n.blockTokens(e)},i=Ld(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(i)return{type:`taskList`,raw:i.raw,items:i.items}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleTaskList:()=>({commands:e})=>e.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}});nf.create({name:`listKit`,addExtensions(){let e=[];return this.options.bulletList!==!1&&e.push(Ah.configure(this.options.bulletList)),this.options.listItem!==!1&&e.push($h.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(cg.configure(this.options.listKeymap)),this.options.orderedList!==!1&&e.push(Tg.configure(this.options.orderedList)),this.options.taskItem!==!1&&e.push(kg.configure(this.options.taskItem)),this.options.taskList!==!1&&e.push(Ag.configure(this.options.taskList)),e}});var jg=`&nbsp;`,Mg=`\xA0`,Ng=wf.create({name:`paragraph`,priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:`block`,content:`inline*`,parseHTML(){return[{tag:`p`}]},renderHTML({HTMLAttributes:e}){return[`p`,Ql(this.options.HTMLAttributes,e),0]},parseMarkdown:(e,t)=>{let n=e.tokens||[];if(n.length===1&&n[0].type===`image`)return t.parseChildren([n[0]]);let r=t.parseInline(n);return n.length===1&&n[0].type===`text`&&(n[0].raw===jg||n[0].text===jg||n[0].raw===Mg||n[0].text===Mg)&&r.length===1&&r[0].type===`text`&&(r[0].text===jg||r[0].text===Mg)?t.createNode(`paragraph`,void 0,[]):t.createNode(`paragraph`,void 0,r)},renderMarkdown:(e,t,n)=>{if(!e)return``;let r=Array.isArray(e.content)?e.content:[];if(r.length===0){var i,a;let e=Array.isArray(n==null||(i=n.previousNode)==null?void 0:i.content)?n.previousNode.content:[];return(n==null||(a=n.previousNode)==null?void 0:a.type)===`paragraph`&&e.length===0?jg:``}return t.renderChildren(r)},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),Pg=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,Fg=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,Ig=Jd.create({name:`strike`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`s`},{tag:`del`},{tag:`strike`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`line-through`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`s`,Ql(this.options.HTMLAttributes,e),0]},markdownTokenName:`del`,parseMarkdown:(e,t)=>t.applyMark(`strike`,t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`~~${t.renderChildren(e)}~~`,addCommands(){return{setStrike:()=>({commands:e})=>e.setMark(this.name),toggleStrike:()=>({commands:e})=>e.toggleMark(this.name),unsetStrike:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[bf({find:Pg,type:this.type})]},addPasteRules(){return[Tf({find:Fg,type:this.type})]}}),Lg=wf.create({name:`text`,group:`inline`,parseMarkdown:e=>({type:`text`,text:e.text||``}),renderMarkdown:e=>e.text||``}),Rg=Jd.create({name:`underline`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`u`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`underline`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`u`,Ql(this.options.HTMLAttributes,e),0]},parseMarkdown(e,t){return t.applyMark(this.name||`underline`,t.parseInline(e.tokens||[]))},renderMarkdown(e,t){return`++${t.renderChildren(e)}++`},markdownTokenizer:{name:`underline`,level:`inline`,start(e){return e.indexOf(`++`)},tokenize(e,t,n){let r=/^(\+\+)([\s\S]+?)(\+\+)/.exec(e);if(!r)return;let i=r[2].trim();return{type:`underline`,raw:r[0],text:i,tokens:n.inlineTokens(i)}}},addCommands(){return{setUnderline:()=>({commands:e})=>e.setMark(this.name),toggleUnderline:()=>({commands:e})=>e.toggleMark(this.name),unsetUnderline:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}});function zg(e={}){return new Gn({view(t){return new Bg(t,e)}})}var Bg=class{constructor(e,t){this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.lastDragEvent=null,this.width=t.width??1,this.color=t.color===!1?void 0:t.color||`black`,this.class=t.class,this.handlers=[`dragover`,`dragend`,`drop`,`dragleave`].map(t=>{let n=e=>{this[t](e)};return e.dom.addEventListener(t,n),{name:t,handler:n}})}destroy(){this.handlers.forEach(({name:e,handler:t})=>this.editorView.dom.removeEventListener(e,t))}update(e,t){if(this.cursorPos!=null&&t.doc!=e.state.doc){if(this.lastDragEvent){let e=this.computeTarget(this.lastDragEvent);e==this.cursorPos?this.updateOverlay():this.setCursor(e)}else this.updateOverlay()}}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,e==null?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e=this.editorView.state.doc.resolve(this.cursorPos),t=!e.parent.inlineContent,n,r=this.editorView.dom,i=r.getBoundingClientRect(),a=i.width/r.offsetWidth,o=i.height/r.offsetHeight;if(t){let t=e.nodeBefore,r=e.nodeAfter;if(t||r){let e=this.editorView.nodeDOM(this.cursorPos-(t?t.nodeSize:0));if(e){let i=e.getBoundingClientRect(),a=t?i.bottom:i.top;t&&r&&(a=(a+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2);let s=this.width/2*o;n={left:i.left,right:i.right,top:a-s,bottom:a+s}}}}if(!n){let e=this.editorView.coordsAtPos(this.cursorPos),t=this.width/2*a;n={left:e.left-t,right:e.left+t,top:e.top,bottom:e.bottom}}let s=this.editorView.dom.offsetParent;this.element||(this.element=s.appendChild(document.createElement(`div`)),this.class&&(this.element.className=this.class),this.element.style.cssText=`position: absolute; z-index: 50; pointer-events: none;`,this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle(`prosemirror-dropcursor-block`,t),this.element.classList.toggle(`prosemirror-dropcursor-inline`,!t);let c,l;if(!s||s==document.body&&getComputedStyle(s).position==`static`)c=-pageXOffset,l=-pageYOffset;else{let e=s.getBoundingClientRect(),t=e.width/s.offsetWidth,n=e.height/s.offsetHeight;c=e.left-s.scrollLeft*t,l=e.top-s.scrollTop*n}this.element.style.left=(n.left-c)/a+`px`,this.element.style.top=(n.top-l)/o+`px`,this.element.style.width=(n.right-n.left)/a+`px`,this.element.style.height=(n.bottom-n.top)/o+`px`}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}computeTarget(e){let t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),n=t&&t.inside>=0&&this.editorView.state.doc.nodeAt(t.inside),r=n&&n.type.spec.disableDropCursor,i=typeof r==`function`?r(this.editorView,t,e):r;if(!t||i)return null;let a=t.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let e=rn(this.editorView.state.doc,a,this.editorView.dragging.slice);e!=null&&(a=e)}return a}dragover(e){if(!this.editorView.editable)return;this.lastDragEvent=e;let t=this.computeTarget(e);t!=null&&(this.setCursor(t),this.scheduleRemoval(5e3))}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)}},Vg=class e extends j{constructor(e){super(e,e)}map(t,n){let r=t.resolve(n.map(this.head));return e.valid(r)?new e(r):j.near(r)}content(){return E.empty}eq(t){return t instanceof e&&t.head==this.head}toJSON(){return{type:`gapcursor`,pos:this.head}}static fromJSON(t,n){if(typeof n.pos!=`number`)throw RangeError(`Invalid input for GapCursor.fromJSON`);return new e(t.resolve(n.pos))}getBookmark(){return new Hg(this.anchor)}static valid(e){let t=e.parent;if(t.inlineContent||!Wg(e)||!Gg(e))return!1;let n=t.type.spec.allowGapCursor;if(n!=null)return n;let r=t.contentMatchAt(e.index()).defaultType;return r&&r.isTextblock}static findGapCursorFrom(t,n,r=!1){search:for(;;){if(!r&&e.valid(t))return t;let i=t.pos,a=null;for(let r=t.depth;;r--){let o=t.node(r);if(n>0?t.indexAfter(r)<o.childCount:t.index(r)>0){a=o.child(n>0?t.indexAfter(r):t.index(r)-1);break}if(r==0)return null;i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}for(;;){let o=n>0?a.firstChild:a.lastChild;if(!o){if(a.isAtom&&!a.isText&&!N.isSelectable(a)){t=t.doc.resolve(i+a.nodeSize*n),r=!1;continue search}break}a=o,i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}return null}}};Vg.prototype.visible=!1,Vg.findFrom=Vg.findGapCursorFrom,j.jsonID(`gapcursor`,Vg);var Hg=class e{constructor(e){this.pos=e}map(t){return new e(t.map(this.pos))}resolve(e){let t=e.resolve(this.pos);return Vg.valid(t)?new Vg(t):j.near(t)}};function Ug(e){return e.isAtom||e.spec.isolating||e.spec.createGapCursor}function Wg(e){for(let t=e.depth;t>=0;t--){let n=e.index(t),r=e.node(t);if(n==0){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n-1);;e=e.lastChild){if(e.childCount==0&&!e.inlineContent||Ug(e.type))return!0;if(e.inlineContent)return!1}}return!0}function Gg(e){for(let t=e.depth;t>=0;t--){let n=e.indexAfter(t),r=e.node(t);if(n==r.childCount){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n);;e=e.firstChild){if(e.childCount==0&&!e.inlineContent||Ug(e.type))return!0;if(e.inlineContent)return!1}}return!0}function Kg(){return new Gn({props:{decorations:Zg,createSelectionBetween(e,t,n){return t.pos==n.pos&&Vg.valid(n)?new Vg(n):null},handleClick:Yg,handleKeyDown:qg,handleDOMEvents:{beforeinput:Xg}}})}var qg=Sc({ArrowLeft:Jg(`horiz`,-1),ArrowRight:Jg(`horiz`,1),ArrowUp:Jg(`vert`,-1),ArrowDown:Jg(`vert`,1)});function Jg(e,t){let n=e==`vert`?t>0?`down`:`up`:t>0?`right`:`left`;return function(e,r,i){let a=e.selection,o=t>0?a.$to:a.$from,s=a.empty;if(a instanceof M){if(!i.endOfTextblock(n)||o.depth==0)return!1;s=!1,o=e.doc.resolve(t>0?o.after():o.before())}let c=Vg.findGapCursorFrom(o,t,s);return c?(r&&r(e.tr.setSelection(new Vg(c))),!0):!1}}function Yg(e,t,n){if(!e||!e.editable)return!1;let r=e.state.doc.resolve(t);if(!Vg.valid(r))return!1;let i=e.posAtCoords({left:n.clientX,top:n.clientY});return i&&i.inside>-1&&N.isSelectable(e.state.doc.nodeAt(i.inside))?!1:(e.dispatch(e.state.tr.setSelection(new Vg(r))),!0)}function Xg(e,t){if(t.inputType!=`insertCompositionText`||!(e.state.selection instanceof Vg))return!1;let{$from:n}=e.state.selection,r=n.parent.contentMatchAt(n.index()).findWrapping(e.state.schema.nodes.text);if(!r)return!1;let i=b.empty;for(let e=r.length-1;e>=0;e--)i=b.from(r[e].createAndFill(null,i));let a=e.state.tr.replace(n.pos,n.pos,new E(i,0,0));return a.setSelection(M.near(a.doc.resolve(n.pos+1))),e.dispatch(a),!1}function Zg(e){if(!(e.selection instanceof Vg))return null;let t=document.createElement(`div`);return t.className=`ProseMirror-gapcursor`,xs.create(e.doc,[vs.widget(e.selection.head,t,{key:`gapcursor`})])}var Qg=200,$g=function(){};$g.prototype.append=function(e){return e.length?(e=$g.from(e),!this.length&&e||e.length<Qg&&this.leafAppend(e)||this.length<Qg&&e.leafPrepend(this)||this.appendInner(e)):this},$g.prototype.prepend=function(e){return e.length?$g.from(e).append(this):this},$g.prototype.appendInner=function(e){return new t_(this,e)},$g.prototype.slice=function(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.length),e>=t?$g.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},$g.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},$g.prototype.forEach=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},$g.prototype.map=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length);var r=[];return this.forEach(function(t,n){return r.push(e(t,n))},t,n),r},$g.from=function(e){return e instanceof $g?e:e&&e.length?new e_(e):$g.empty};var e_=function(e){function t(t){e.call(this),this.values=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return e==0&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,r){for(var i=t;i<n;i++)if(e(this.values[i],r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){for(var i=t-1;i>=n;i--)if(e(this.values[i],r+i)===!1)return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=Qg)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=Qg)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}($g);$g.empty=new e_([]);var t_=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return e<this.left.length?this.left.get(e):this.right.get(e-this.left.length)},t.prototype.forEachInner=function(e,t,n,r){var i=this.left.length;if(t<i&&this.left.forEachInner(e,t,Math.min(n,i),r)===!1||n>i&&this.right.forEachInner(e,Math.max(t-i,0),Math.min(this.length,n)-i,r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){var i=this.left.length;if(t>i&&this.right.forEachInvertedInner(e,t-i,Math.max(n,i)-i,r+i)===!1||n<i&&this.left.forEachInvertedInner(e,Math.min(t,i),n,r)===!1)return!1},t.prototype.sliceInner=function(e,t){if(e==0&&t==this.length)return this;var n=this.left.length;return t<=n?this.left.slice(e,t):e>=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}($g),n_=500,r_=class e{constructor(e,t){this.items=e,this.eventCount=t}popEvent(t,n){if(this.eventCount==0)return null;let r=this.items.length;for(;;r--)if(this.items.get(r-1).selection){--r;break}let i,a;n&&(i=this.remapping(r,this.items.length),a=i.maps.length);let o=t.tr,s,c,l=[],u=[];return this.items.forEach((t,n)=>{if(!t.step){i||(i=this.remapping(r,n+1),a=i.maps.length),a--,u.push(t);return}if(i){u.push(new a_(t.map));let e=t.step.map(i.slice(a)),n;e&&o.maybeStep(e).doc&&(n=o.mapping.maps[o.mapping.maps.length-1],l.push(new a_(n,void 0,void 0,l.length+u.length))),a--,n&&i.appendMap(n,a)}else o.maybeStep(t.step);if(t.selection)return s=i?t.selection.map(i.slice(a)):t.selection,c=new e(this.items.slice(0,r).append(u.reverse().concat(l)),this.eventCount-1),!1},this.items.length,0),{remaining:c,transform:o,selection:s}}addTransform(t,n,r,i){let a=[],o=this.eventCount,s=this.items,c=!i&&s.length?s.get(s.length-1):null;for(let e=0;e<t.steps.length;e++){let r=t.steps[e].invert(t.docs[e]),l=new a_(t.mapping.maps[e],r,n),u;(u=c&&c.merge(l))&&(l=u,e?a.pop():s=s.slice(0,s.length-1)),a.push(l),n&&=(o++,void 0),i||(c=l)}let l=o-r.depth;return l>s_&&(s=i_(s,l),o-=l),new e(s.append(a),o)}remapping(e,t){let n=new xt;return this.items.forEach((t,r)=>{let i=t.mirrorOffset!=null&&r-t.mirrorOffset>=e?n.maps.length-t.mirrorOffset:void 0;n.appendMap(t.map,i)},e,t),n}addMaps(t){return this.eventCount==0?this:new e(this.items.append(t.map(e=>new a_(e))),this.eventCount)}rebased(t,n){if(!this.eventCount)return this;let r=[],i=Math.max(0,this.items.length-n),a=t.mapping,o=t.steps.length,s=this.eventCount;this.items.forEach(e=>{e.selection&&s--},i);let c=n;this.items.forEach(e=>{let n=a.getMirror(--c);if(n==null)return;o=Math.min(o,n);let i=a.maps[n];if(e.step){let o=t.steps[n].invert(t.docs[n]),l=e.selection&&e.selection.map(a.slice(c+1,n));l&&s++,r.push(new a_(i,o,l))}else r.push(new a_(i))},i);let l=[];for(let e=n;e<o;e++)l.push(new a_(a.maps[e]));let u=this.items.slice(0,i).append(l).append(r),d=new e(u,s);return d.emptyItemCount()>n_&&(d=d.compress(this.items.length-r.length)),d}emptyItemCount(){let e=0;return this.items.forEach(t=>{t.step||e++}),e}compress(t=this.items.length){let n=this.remapping(0,t),r=n.maps.length,i=[],a=0;return this.items.forEach((e,o)=>{if(o>=t)i.push(e),e.selection&&a++;else if(e.step){let t=e.step.map(n.slice(r)),o=t&&t.getMap();if(r--,o&&n.appendMap(o,r),t){let s=e.selection&&e.selection.map(n.slice(r));s&&a++;let c=new a_(o.invert(),t,s),l,u=i.length-1;(l=i.length&&i[u].merge(c))?i[u]=l:i.push(c)}}else e.map&&r--},this.items.length,0),new e($g.from(i.reverse()),a)}};r_.empty=new r_($g.empty,0);function i_(e,t){let n;return e.forEach((e,r)=>{if(e.selection&&t--==0)return n=r,!1}),e.slice(n)}var a_=class e{constructor(e,t,n,r){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=r}merge(t){if(this.step&&t.step&&!t.selection){let n=t.step.merge(this.step);if(n)return new e(n.getMap().invert(),n,this.selection)}}},o_=class{constructor(e,t,n,r,i){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=r,this.prevComposition=i}},s_=20;function c_(e,t,n,r){let i=n.getMeta(g_),a;if(i)return i.historyState;n.getMeta(__)&&(e=new o_(e.done,e.undone,null,0,-1));let o=n.getMeta(`appendedTransaction`);if(n.steps.length==0)return e;if(o&&o.getMeta(g_))return o.getMeta(g_).redo?new o_(e.done.addTransform(n,void 0,r,h_(t)),e.undone,u_(n.mapping.maps),e.prevTime,e.prevComposition):new o_(e.done,e.undone.addTransform(n,void 0,r,h_(t)),null,e.prevTime,e.prevComposition);if(n.getMeta(`addToHistory`)!==!1&&!(o&&o.getMeta(`addToHistory`)===!1)){let i=n.getMeta(`composition`),a=e.prevTime==0||!o&&e.prevComposition!=i&&(e.prevTime<(n.time||0)-r.newGroupDelay||!l_(n,e.prevRanges)),s=o?d_(e.prevRanges,n.mapping):u_(n.mapping.maps);return new o_(e.done.addTransform(n,a?t.selection.getBookmark():void 0,r,h_(t)),r_.empty,s,n.time,i??e.prevComposition)}return(a=n.getMeta(`rebased`))?new o_(e.done.rebased(n,a),e.undone.rebased(n,a),d_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition):new o_(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),d_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition)}function l_(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((e,r)=>{for(let i=0;i<t.length;i+=2)e<=t[i+1]&&r>=t[i]&&(n=!0)}),n}function u_(e){let t=[];for(let n=e.length-1;n>=0&&t.length==0;n--)e[n].forEach((e,n,r,i)=>t.push(r,i));return t}function d_(e,t){if(!e)return null;let n=[];for(let r=0;r<e.length;r+=2){let i=t.map(e[r],1),a=t.map(e[r+1],-1);i<=a&&n.push(i,a)}return n}function f_(e,t,n){let r=h_(t),i=g_.get(t).spec.config,a=(n?e.undone:e.done).popEvent(t,r);if(!a)return null;let o=a.selection.resolve(a.transform.doc),s=(n?e.done:e.undone).addTransform(a.transform,t.selection.getBookmark(),i,r),c=new o_(n?s:a.remaining,n?a.remaining:s,null,0,-1);return a.transform.setSelection(o).setMeta(g_,{redo:n,historyState:c})}var p_=!1,m_=null;function h_(e){let t=e.plugins;if(m_!=t){p_=!1,m_=t;for(let e=0;e<t.length;e++)if(t[e].spec.historyPreserveItems){p_=!0;break}}return p_}var g_=new Jn(`history`),__=new Jn(`closeHistory`);function v_(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new Gn({key:g_,state:{init(){return new o_(r_.empty,r_.empty,null,0,-1)},apply(t,n,r){return c_(n,r,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(e,t){let n=t.inputType,r=n==`historyUndo`?b_:n==`historyRedo`?x_:null;return!r||!e.editable?!1:(t.preventDefault(),r(e.state,e.dispatch))}}}})}function y_(e,t){return(n,r)=>{let i=g_.getState(n);if(!i||(e?i.undone:i.done).eventCount==0)return!1;if(r){let a=f_(i,n,e);a&&r(t?a.scrollIntoView():a)}return!0}}var b_=y_(!1,!0),x_=y_(!0,!0);nf.create({name:`characterCount`,addOptions(){return{limit:null,autoTrim:!0,mode:`textSize`,textCounter:e=>e.length,wordCounter:e=>e.split(` `).filter(e=>e!==``).length}},addStorage(){return{characters:()=>0,words:()=>0}},onBeforeCreate(){this.storage.characters=e=>{let t=e?.node||this.editor.state.doc;if((e?.mode||this.options.mode)===`textSize`){let e=t.textBetween(0,t.content.size,void 0,` `);return this.options.textCounter(e)}return t.nodeSize},this.storage.words=e=>{let t=e?.node||this.editor.state.doc,n=t.textBetween(0,t.content.size,` `,` `);return this.options.wordCounter(n)}},addProseMirrorPlugins(){let e=!1;return[new Gn({key:new Jn(`characterCount`),appendTransaction:(t,n,r)=>{if(e)return;let i=this.options.limit,a=this.options.autoTrim;if(i==null||i===0||a===!1){e=!0;return}let o=this.storage.characters({node:r.doc});if(o>i){let t=o-i;console.warn(`[CharacterCount] Initial content exceeded limit of ${i} characters. Content was automatically trimmed.`);let n=r.tr.deleteRange(0,t);return e=!0,n}e=!0},filterTransaction:(e,t)=>{let n=this.options.limit;if(!e.docChanged||n===0||n==null)return!0;let r=this.storage.characters({node:t.doc}),i=this.storage.characters({node:e.doc});if(i<=n||r>n&&i>n&&i<=r)return!0;if(r>n&&i>n&&i>r||!e.getMeta(`paste`))return!1;let a=e.selection.$head.pos,o=a-(i-n),s=a;return e.deleteRange(o,s),!(this.storage.characters({node:e.doc})>n)}})]}});var S_=nf.create({name:`dropCursor`,addOptions(){return{color:`currentColor`,width:1,class:void 0}},addProseMirrorPlugins(){return[zg(this.options)]}});nf.create({name:`focus`,addOptions(){return{className:`has-focus`,mode:`all`}},addProseMirrorPlugins(){return[new Gn({key:new Jn(`focus`),props:{decorations:({doc:e,selection:t})=>{let{isEditable:n,isFocused:r}=this.editor,{anchor:i}=t,a=[];if(!n||!r)return xs.create(e,[]);let o=0;this.options.mode===`deepest`&&e.descendants((e,t)=>{if(!e.isText){if(!(i>=t&&i<=t+e.nodeSize-1))return!1;o+=1}});let s=0;return e.descendants((e,t)=>{if(e.isText||!(i>=t&&i<=t+e.nodeSize-1))return!1;if(s+=1,this.options.mode===`deepest`&&o-s>0||this.options.mode===`shallowest`&&s>1)return this.options.mode===`deepest`;a.push(vs.node(t,t+e.nodeSize,{class:this.options.className}))}),xs.create(e,a)}}})]}});var C_=nf.create({name:`gapCursor`,addProseMirrorPlugins(){return[Kg()]},extendNodeSchema(e){return{allowGapCursor:z(I(e,`allowGapCursor`,{name:e.name,options:e.options,storage:e.storage}))??null}}}),w_=`placeholder`,T_=new Jn(`tiptap__placeholder`);function E_(e){let{editor:t,placeholder:n,dataAttribute:r,pos:i,node:a,isEmptyDoc:o,hasAnchor:s,classes:{emptyNode:c,emptyEditor:l}}=e,u=[c];return o&&u.push(l),vs.node(i,i+a.nodeSize,{class:u.join(` `),[r]:typeof n==`function`?n({editor:t,node:a,pos:i,hasAnchor:s}):n})}function D_(e,t){return typeof e==`function`?e(t):e}function O_({editor:e,options:t,dataAttribute:n,doc:r,selection:i,from:a,to:o}){let{anchor:s}=i,c=[],l=e.isEmpty;return r.nodesBetween(a,o,(r,i)=>{let a=s>=i&&s<=i+r.nodeSize,o=!r.isLeaf&&Ou(r);return r.type.isTextblock&&(a||!t.showOnlyCurrent)&&o&&c.push(E_({editor:e,isEmptyDoc:l,dataAttribute:n,hasAnchor:a,placeholder:t.placeholder,classes:{emptyEditor:t.emptyEditorClass,emptyNode:D_(t.emptyNodeClass,{editor:e,node:r,pos:i,hasAnchor:a})},node:r,pos:i})),t.includeChildren}),c}function k_({editor:e,options:t,dataAttribute:n,doc:r,selection:i}){if(!e.isEditable&&t.showOnlyWhenEditable)return null;let{anchor:a}=i,o=[],s=e.isEmpty;if(t.showOnlyCurrent&&!t.includeChildren){let i=r.resolve(a),c=i.depth>0?i.node(1):i.nodeAfter,l=i.depth>0?i.before(1):a;if(c&&c.type.isTextblock&&Ou(c)){let r=a>=l&&a<=l+c.nodeSize;o.push(E_({editor:e,isEmptyDoc:s,dataAttribute:n,hasAnchor:r,placeholder:t.placeholder,classes:{emptyEditor:t.emptyEditorClass,emptyNode:D_(t.emptyNodeClass,{editor:e,node:c,pos:l,hasAnchor:r})},node:c,pos:l}))}}else o.push(...O_({editor:e,options:t,dataAttribute:n,doc:r,selection:i,from:0,to:r.content.size}));return xs.create(r,o)}function A_(e,t){let n=e.resolve(t);if(n.depth===0){let e=n.nodeAfter??n.nodeBefore;if(!e)return{from:t,to:t};let r=n.nodeAfter?t:t-e.nodeSize;return{from:r,to:r+e.nodeSize}}let r=n.before(1);return{from:r,to:r+n.node(1).nodeSize}}function j_(e,t){return{from:Math.max(0,t.from-1),to:Math.min(e.content.size,t.to-1)}}function M_(e,t,n){let r=[];return e.forEach((e,i)=>{let a=i,o=a+e.nodeSize,s=a+1,c=o+1;s<n&&c>t&&r.push({from:a,to:o})}),r}function N_(e){if(e.length===0)return[];let t=[...e].sort((e,t)=>e.from-t.from),n=[{...t[0]}];for(let e=1;e<t.length;e+=1){let r=n[n.length-1],i=t[e];i.from<=r.to?r.to=Math.max(r.to,i.to):n.push({...i})}return n}function P_(e,t){let n=M_(e,t.from,t.to);return n.push(j_(e,A_(e,t.from))),t.to>t.from?n.push(j_(e,A_(e,Math.min(t.to,e.content.size+1)-1))):t.from<e.content.size+1&&n.push(j_(e,A_(e,Math.min(t.from+1,e.content.size)))),n}function F_(e,t,n){let r=[];if(e.docChanged){let t=hu(e);for(let e of t)r.push(...P_(n.doc,e.newRange))}return e.selectionSet&&(r.push(j_(n.doc,A_(n.doc,e.mapping.map(t.selection.anchor)))),r.push(j_(n.doc,A_(n.doc,n.selection.anchor)))),N_(r)}function I_(e,t,n){let r=Math.max(0,Math.min(e,n.content.size));return{from:r,to:Math.max(r,Math.min(t,n.content.size))}}function L_({decorations:e,ranges:t,editor:n,options:r,dataAttribute:i,doc:a,selection:o}){let s=e;for(let e of t){let{from:t,to:c}=I_(e.from,e.to,a),l=s.find(t,c).filter(e=>e.from>=t&&e.to<=c);l.length&&(s=s.remove(l));let u=O_({editor:n,options:r,dataAttribute:i,doc:a,selection:o,from:t,to:c});u.length&&(s=s.add(a,u))}return s}function R_({editor:e,options:t,dataAttribute:n}){return{init(r,i){return k_({editor:e,options:t,dataAttribute:n,doc:i.doc,selection:i.selection})??xs.empty},apply(r,i,a,o){return!r.docChanged&&!r.selectionSet?i:L_({decorations:i.map(r.mapping,r.doc),ranges:F_(r,a,o),editor:e,options:t,dataAttribute:n,doc:o.doc,selection:o.selection})}}}function z_(e){return e.replace(/\s+/g,`-`).replace(/[^a-zA-Z0-9-]/g,``).replace(/^[0-9-]+/,``).replace(/^-+/,``).toLowerCase()}function B_({editor:e,options:t}){let n=t.dataAttribute?`data-${z_(t.dataAttribute)}`:`data-${w_}`,r=t.showOnlyCurrent&&!t.includeChildren;return new Gn({key:T_,...r?{}:{state:R_({editor:e,options:t,dataAttribute:n})},props:{decorations:r?({doc:r,selection:i})=>k_({editor:e,options:t,dataAttribute:n,doc:r,selection:i}):n=>t.showOnlyWhenEditable&&!e.isEditable?xs.empty:T_.getState(n)??xs.empty}})}nf.create({name:`placeholder`,addOptions(){return{emptyEditorClass:`is-editor-empty`,emptyNodeClass:`is-empty`,dataAttribute:w_,placeholder:`Write something …`,showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){return[B_({editor:this.editor,options:this.options})]}});function V_(e,t){return!e.selection.empty&&!ku(e.selection)&&t.isEditable}function H_(e,t){return V_(e,t)&&!t.isFocused&&!t.view.dragging}function U_(){var e;(e=window.getSelection())==null||e.removeAllRanges()}function W_(e){e.focus()}nf.create({name:`selection`,addOptions(){return{className:`selection`}},addProseMirrorPlugins(){let{editor:e,options:t}=this;return[new Gn({key:new Jn(`selection`),props:{decorations(n){return H_(n,e)?xs.create(n.doc,[vs.inline(n.selection.from,n.selection.to,{class:t.className})]):null},handleDOMEvents:{blur(t){return V_(t.state,e)&&U_(),!1},focus(t){return V_(t.state,e)&&requestAnimationFrame(()=>{!e.isDestroyed&&t.hasFocus()&&W_(t)}),!1}}}})]}});function G_({types:e,node:t}){return t&&Array.isArray(e)&&e.includes(t.type)||t?.type===e}var K_=nf.create({name:`trailingNode`,addOptions(){return{node:void 0,notAfter:[]}},addProseMirrorPlugins(){let e=new Jn(this.name),t=this.options.node||this.editor.schema.topNodeType.contentMatch.defaultType?.name||`paragraph`,n=Object.entries(this.editor.schema.nodes).map(([,e])=>e).filter(e=>(this.options.notAfter||[]).concat(t).includes(e.name));return[new Gn({key:e,appendTransaction:(n,r,i)=>{let{doc:a,tr:o,schema:s}=i,c=e.getState(i),l=a.content.size,u=s.nodes[t];if(!n.some(e=>e.getMeta(`skipTrailingNode`))&&c)return o.insert(l,u.create())},state:{init:(e,t)=>{let r=t.tr.doc.lastChild;return!G_({node:r,types:n})},apply:(e,t)=>{if(!e.docChanged||e.getMeta(`__uniqueIDTransaction`))return t;let r=e.doc.lastChild;return!G_({node:r,types:n})}}})]}}),q_=nf.create({name:`undoRedo`,addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:e,dispatch:t})=>b_(e,t),redo:()=>({state:e,dispatch:t})=>x_(e,t)}},addProseMirrorPlugins(){return[v_(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-я":()=>this.editor.commands.undo(),"Shift-Mod-я":()=>this.editor.commands.redo()}}}),J_=nf.create({name:`starterKit`,addExtensions(){let e=[];return this.options.bold!==!1&&e.push(Bf.configure(this.options.bold)),this.options.blockquote!==!1&&e.push(Ff.configure(this.options.blockquote)),this.options.bulletList!==!1&&e.push(Ah.configure(this.options.bulletList)),this.options.code!==!1&&e.push(Uf.configure(this.options.code)),this.options.codeBlock!==!1&&e.push(qf.configure(this.options.codeBlock)),this.options.document!==!1&&e.push(Jf.configure(this.options.document)),this.options.dropcursor!==!1&&e.push(S_.configure(this.options.dropcursor)),this.options.gapcursor!==!1&&e.push(C_.configure(this.options.gapcursor)),this.options.hardBreak!==!1&&e.push(Yf.configure(this.options.hardBreak)),this.options.heading!==!1&&e.push(Xf.configure(this.options.heading)),this.options.undoRedo!==!1&&e.push(q_.configure(this.options.undoRedo)),this.options.horizontalRule!==!1&&e.push(Zf.configure(this.options.horizontalRule)),this.options.italic!==!1&&e.push(np.configure(this.options.italic)),this.options.listItem!==!1&&e.push($h.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(cg.configure(this.options?.listKeymap)),this.options.link!==!1&&e.push(Eh.configure(this.options?.link)),this.options.orderedList!==!1&&e.push(Tg.configure(this.options.orderedList)),this.options.paragraph!==!1&&e.push(Ng.configure(this.options.paragraph)),this.options.strike!==!1&&e.push(Ig.configure(this.options.strike)),this.options.text!==!1&&e.push(Lg.configure(this.options.text)),this.options.underline!==!1&&e.push(Rg.configure(this.options?.underline)),this.options.trailingNode!==!1&&e.push(K_.configure(this.options?.trailingNode)),e}}),Y_={DISABLED_SITES:[`cloud.microsoft`,`deepl.com`,`productboard.com`,`openai.com`,`chatgpt.com`],CHROME_AND_FIREFOX_SITES:[`chrome:`,`chrome-extension:`,`about:`,`moz-extension:`],EXPOSE_WITTY_ID_ALLOW_LIST:{dev:[`lndo.site`,`platformsh.site`,`witty.works`],prod:[`witty.works`]},BASE_URLS:{Prod:{api:`https://default.api.witty.works/`,dashboard:`https://dashboard.witty.works/`,posthog_url:`https://eu.posthog.com`,posthog_key:`phc_i1tlvuh1iecIOSEr0QmTEIklrsSJGhULpUwUlf8fkkl`,oauth_client_id:``},Dev:{api:`https://dev-54ta5gq-jyeciedibdzvq.fr-4.platformsh.site/`,dashboard:`https://dev-54ta5gq-56xlfiudba6c2.fr-4.platformsh.site/`,posthog_url:`https://app.posthog.com`,posthog_key:`phc_QiISRw0yFAsndXqYD0HmfGvHaOBMxb57ZRIxlimvR64`,oauth_client_id:``},Local:{api:`http://127.0.0.1:8000/`,dashboard:`https://dashboard.lndo.site/`,posthog_url:`https://app.posthog.com`,posthog_key:`phc_QiISRw0yFAsndXqYD0HmfGvHaOBMxb57ZRIxlimvR64`,oauth_client_id:`1`}},ORTHOGRAPHY:!0,SENTRY_DSN:``,SENTRY_SAMPLE_RATE:0,SENTRY_TRACE_RATE:0,API_DELAY:2e3,REPHRASE_ENABLED:!1,MAX_CHAR_LENGTH_REQUEST:2e3,MAX_CHAR_LENGTH_TOTAL:2e3,MIN_CHAR_LENGTH:50,MAX_POSTHOG_LOG_EVENTS:5e3,POSTHOG_ENABLED:!1},X_=`2.2.0`,Z_={...Y_.BASE_URLS},Q_=Object.keys(Z_);Q_.includes(`Prod`)||Q_[0];var $_=`https://www.witty.works/en/help/`;`${$_}`,`${$_}`,`${$_}`,`${$_}`,`${$_}`;var ev=[`gendered_roles_format`,`german_gender_ending`,`french_gender_separator`],tv=function(e){return e[e.Off=0]=`Off`,e[e.Basic=1]=`Basic`,e[e.Advanced=2]=`Advanced`,e}({}),nv=(e,t,n)=>n.includes(e)?0:t&&n.includes(t)?1:t?2:1,rv=(e,t,n,r)=>{let i=r.filter(n=>n!==e&&n!==t);return n===0?(i.push(e),t&&i.push(t)):n===1&&t&&i.push(t),i},iv={inclusive:{hover:`#BCD485`,default:`#D3E4AC`,highlight:`#BCD485`},corporate:{hover:`#6f9FED`,default:`#A1BEED`,highlight:`#6f9FED`},style:{hover:`#F6EC6B`,default:`#FFFFD3`,highlight:`#F6EC6B`},bias:{hover:`#EB9F46`,default:`#F8E7CB`,highlight:`#EB9F46`},severe:{hover:`#E6635A`,default:`#F7D4D4`,highlight:`#E6635A`}},av=(e,t)=>t===`corporate_rules`?`corporate`:e?e<1.5?`severe`:e>2.5?`style`:`bias`:`inclusive`,ov=(e,t)=>iv[av(e,t)];Y_.EXPOSE_WITTY_ID_ALLOW_LIST?.prod;var U=e=>typeof e==`string`,sv=()=>{let e,t,n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n},cv=e=>e==null?``:String(e),lv=(e,t,n)=>{e.forEach(e=>{t[e]&&(n[e]=t[e])})},uv=/###/g,dv=e=>e&&e.includes(`###`)?e.replace(uv,`.`):e,fv=e=>!e||U(e),pv=(e,t,n)=>{let r=U(t)?t.split(`.`):t,i=0;for(;i<r.length-1;){if(fv(e))return{};let t=dv(r[i]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++i}return fv(e)?{}:{obj:e,k:dv(r[i])}},mv=(e,t,n)=>{let{obj:r,k:i}=pv(e,t,Object);if(r!==void 0||t.length===1){r[i]=n;return}let a=t[t.length-1],o=t.slice(0,t.length-1),s=pv(e,o,Object);for(;s.obj===void 0&&o.length;)a=`${o[o.length-1]}.${a}`,o=o.slice(0,o.length-1),s=pv(e,o,Object),s?.obj&&s.obj[`${s.k}.${a}`]!==void 0&&(s.obj=void 0);s.obj[`${s.k}.${a}`]=n},hv=(e,t,n,r)=>{let{obj:i,k:a}=pv(e,t,Object);i[a]=i[a]||[],i[a].push(n)},gv=(e,t)=>{let{obj:n,k:r}=pv(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},_v=(e,t,n)=>{let r=gv(e,n);return r===void 0?gv(t,n):r},vv=(e,t,n)=>{for(let r in t)r!==`__proto__`&&r!==`constructor`&&(Object.prototype.hasOwnProperty.call(e,r)?U(e[r])||e[r]instanceof String||U(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):vv(e[r],t[r],n):e[r]=t[r]);return e},yv=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,`\\$&`),bv={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`,"/":`&#x2F;`},xv=e=>U(e)?e.replace(/[&<>"'\/]/g,e=>bv[e]):e,Sv=class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){let t=this.regExpMap.get(e);if(t!==void 0)return t;let n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}},Cv=[` `,`,`,`?`,`!`,`;`],wv=new Sv(20),Tv=(e,t,n)=>{t||=``,n||=``;let r=Cv.filter(e=>!t.includes(e)&&!n.includes(e));if(r.length===0)return!0;let i=wv.getRegExp(`(${r.map(e=>e===`?`?`\\?`:e).join(`|`)})`),a=!i.test(e);if(!a){let t=e.indexOf(n);t>0&&!i.test(e.substring(0,t))&&(a=!0)}return a},Ev=(e,t,n=`.`)=>{if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;let r=t.split(n),i=e;for(let e=0;e<r.length;){if(!i||typeof i!=`object`)return;let t,a=``;for(let o=e;o<r.length;++o)if(o!==e&&(a+=n),a+=r[o],t=i[a],t!==void 0){if([`string`,`number`,`boolean`].includes(typeof t)&&o<r.length-1)continue;e+=o-e+1;break}i=t}return i},Dv=e=>e?.replace(/_/g,`-`),Ov={type:`logger`,log(e){this.output(`log`,e)},warn(e){this.output(`warn`,e)},error(e){this.output(`error`,e)},output(e,t){console?.[e]?.apply?.(console,t)}},kv=new class e{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||`i18next:`,this.logger=e||Ov,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,`log`,``,!0)}warn(...e){return this.forward(e,`warn`,``,!0)}error(...e){return this.forward(e,`error`,``)}deprecate(...e){return this.forward(e,`warn`,`WARNING DEPRECATED: `,!0)}forward(e,t,n,r){return r&&!this.debug?null:(e=e.map(e=>U(e)?e.replace(/[\r\n\x00-\x1F\x7F]/g,` `):e),U(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(t){return new e(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t||=this.options,t.prefix=t.prefix||this.prefix,new e(this.logger,t)}},Av=class{constructor(){this.observers={}}on(e,t){return e.split(` `).forEach(e=>{this.observers[e]||(this.observers[e]=new Map);let n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)}),this}off(e,t){if(this.observers[e]){if(!t){delete this.observers[e];return}this.observers[e].delete(t)}}once(e,t){let n=(...r)=>{t(...r),this.off(e,n)};return this.on(e,n),this}emit(e,...t){this.observers[e]&&Array.from(this.observers[e].entries()).forEach(([e,n])=>{for(let r=0;r<n;r++)e(...t)}),this.observers[`*`]&&Array.from(this.observers[`*`].entries()).forEach(([n,r])=>{for(let i=0;i<r;i++)n(e,...t)})}},jv=class extends Av{constructor(e,t={ns:[`translation`],defaultNS:`translation`}){super(),this.data=e||{},this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator=`.`),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.includes(e)||this.options.ns.push(e)}removeNamespaces(e){let t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n,r={}){let i=r.keySeparator===void 0?this.options.keySeparator:r.keySeparator,a=r.ignoreJSONStructure===void 0?this.options.ignoreJSONStructure:r.ignoreJSONStructure,o;e.includes(`.`)?o=e.split(`.`):(o=[e,t],n&&(Array.isArray(n)?o.push(...n):U(n)&&i?o.push(...n.split(i)):o.push(n)));let s=gv(this.data,o);return!s&&!t&&!n&&e.includes(`.`)&&(e=o[0],t=o[1],n=o.slice(2).join(`.`)),s||!a||!U(n)?s:Ev(this.data?.[e]?.[t],n,i)}addResource(e,t,n,r,i={silent:!1}){let a=i.keySeparator===void 0?this.options.keySeparator:i.keySeparator,o=[e,t];n&&(o=o.concat(a?n.split(a):n)),e.includes(`.`)&&(o=e.split(`.`),r=t,t=o[1]),this.addNamespaces(t),mv(this.data,o,r),i.silent||this.emit(`added`,e,t,n,r)}addResources(e,t,n,r={silent:!1}){for(let r in n)(U(n[r])||Array.isArray(n[r]))&&this.addResource(e,t,r,n[r],{silent:!0});r.silent||this.emit(`added`,e,t,n)}addResourceBundle(e,t,n,r,i,a={silent:!1,skipCopy:!1}){let o=[e,t];e.includes(`.`)&&(o=e.split(`.`),r=n,n=t,t=o[1]),this.addNamespaces(t);let s=gv(this.data,o)||{};a.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?vv(s,n,i):s={...s,...n},mv(this.data,o,s),a.silent||this.emit(`added`,e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit(`removed`,e,t)}hasResourceBundle(e,t){return this.getResource(e,t)!==void 0}getResourceBundle(e,t){return t||=this.options.defaultNS,this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){let t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}},Mv={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,i){return e.forEach(e=>{t=this.processors[e]?.process(t,n,r,i)??t}),t}},Nv=Symbol(`i18next/PATH_KEY`);function Pv(){let e=[],t=Object.create(null),n;return t.get=(r,i)=>(n?.revoke?.(),i===Nv?e:(e.push(i),n=Proxy.revocable(r,t),n.proxy)),Proxy.revocable(Object.create(null),t).proxy}function Fv(e,t){let{[Nv]:n}=e(Pv()),r=t?.keySeparator??`.`,i=t?.nsSeparator??`:`,a=t?.enableSelector===`strict`;if(n.length>1&&i){let e=t?.ns,o=a?Array.isArray(e)?e:e?[e]:null:Array.isArray(e)?e:null;if(o&&(a?o:o.length>1?o.slice(1):[]).includes(n[0]))return`${n[0]}${i}${n.slice(1).join(r)}`}return n.join(r)}var Iv=e=>!U(e)&&typeof e!=`boolean`&&typeof e!=`number`,Lv=class e extends Av{constructor(e,t={}){super(),lv([`resourceStore`,`languageUtils`,`pluralResolver`,`interpolator`,`backendConnector`,`i18nFormat`,`utils`],e,this),this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator=`.`),this.logger=kv.create(`translator`),this.checkedLoadedFor={}}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){let n={...t};if(e==null)return!1;let r=this.resolve(e,n);if(r?.res===void 0)return!1;let i=Iv(r.res);return!(n.returnObjects===!1&&i)}extractFromKey(e,t){let n=t.nsSeparator===void 0?this.options.nsSeparator:t.nsSeparator;n===void 0&&(n=`:`);let r=t.keySeparator===void 0?this.options.keySeparator:t.keySeparator,i=t.ns||this.options.defaultNS||[],a=n&&e.includes(n),o=!this.options.userDefinedKeySeparator&&!t.keySeparator&&!this.options.userDefinedNsSeparator&&!t.nsSeparator&&!Tv(e,n,r);if(a&&!o){let t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:U(i)?[i]:i};let a=e.split(n);(n!==r||n===r&&this.options.ns.includes(a[0]))&&(i=a.shift()),e=a.join(r)}return{key:e,namespaces:U(i)?[i]:i}}translate(t,n,r){let i=typeof n==`object`?{...n}:n;if(typeof i!=`object`&&this.options.overloadTranslationOptionHandler&&(i=this.options.overloadTranslationOptionHandler(arguments)),typeof i==`object`&&(i={...i}),i||={},t==null)return``;typeof t==`function`&&(t=Fv(t,{...this.options,...i})),Array.isArray(t)||(t=[String(t)]),t=t.map(e=>typeof e==`function`?Fv(e,{...this.options,...i}):String(e));let a=i.returnDetails===void 0?this.options.returnDetails:i.returnDetails,o=i.keySeparator===void 0?this.options.keySeparator:i.keySeparator,{key:s,namespaces:c}=this.extractFromKey(t[t.length-1],i),l=c[c.length-1],u=i.nsSeparator===void 0?this.options.nsSeparator:i.nsSeparator;u===void 0&&(u=`:`);let d=i.lng||this.language,f=i.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(d?.toLowerCase()===`cimode`)return f?a?{res:`${l}${u}${s}`,usedKey:s,exactUsedKey:s,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(i)}:`${l}${u}${s}`:a?{res:s,usedKey:s,exactUsedKey:s,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(i)}:s;let p=this.resolve(t,i),m=p?.res,h=p?.usedKey||s,g=p?.exactUsedKey||s,_=[`[object Number]`,`[object Function]`,`[object RegExp]`],v=i.joinArrays===void 0?this.options.joinArrays:i.joinArrays,y=!this.i18nFormat||this.i18nFormat.handleAsObject,b=i.count!==void 0&&!U(i.count),x=e.hasDefaultValue(i),S=b?this.pluralResolver.getSuffix(d,i.count,i):``,C=i.ordinal&&b?this.pluralResolver.getSuffix(d,i.count,{ordinal:!1}):``,w=b&&!i.ordinal&&i.count===0,T=w&&i[`defaultValue${this.options.pluralSeparator}zero`]||i[`defaultValue${S}`]||i[`defaultValue${C}`]||i.defaultValue,E=m;y&&!m&&x&&(E=T);let D=Iv(E),O=Object.prototype.toString.apply(E);if(y&&E&&D&&!_.includes(O)&&!(U(v)&&Array.isArray(E))){if(!i.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn(`accessing an object - but returnObjects options is not enabled!`);let e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(h,E,{...i,ns:c}):`key '${s} (${this.language})' returned an object instead of string.`;return a?(p.res=e,p.usedParams=this.getUsedParamsDetails(i),p):e}if(o){let e=Array.isArray(E),t=e?[]:{},n=e?g:h;for(let e in E)if(Object.prototype.hasOwnProperty.call(E,e)){let r=`${n}${o}${e}`;t[e]=x&&!m?this.translate(r,{...i,defaultValue:Iv(T)?T[e]:void 0,joinArrays:!1,ns:c}):this.translate(r,{...i,joinArrays:!1,ns:c}),t[e]===r&&(t[e]=E[e])}m=t}}else if(y&&U(v)&&Array.isArray(m))m=m.join(v),m&&=this.extendTranslation(m,t,i,r);else{let e=!1,n=!1;!this.isValidLookup(m)&&x&&(e=!0,m=T),this.isValidLookup(m)||(n=!0,m=s);let a=(i.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&n?void 0:m,c=x&&T!==m&&this.options.updateMissing;if(n||e||c){if(this.logger.log(c?`updateKey`:`missingKey`,d,l,b&&!c?`${s}${this.pluralResolver.getSuffix(d,i.count,i)}`:s,c?T:m),o){let e=this.resolve(s,{...i,keySeparator:!1});e&&e.res&&this.logger.warn(`Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.`)}let e=[],t=this.languageUtils.getFallbackCodes(this.options.fallbackLng,i.lng||this.language);if(this.options.saveMissingTo===`fallback`&&t&&t[0])for(let n=0;n<t.length;n++)e.push(t[n]);else this.options.saveMissingTo===`all`?e=this.languageUtils.toResolveHierarchy(i.lng||this.language):e.push(i.lng||this.language);let n=(e,t,n)=>{let r=x&&n!==m?n:a;this.options.missingKeyHandler?this.options.missingKeyHandler(e,l,t,r,c,i):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,l,t,r,c,i),this.emit(`missingKey`,e,l,t,m)};this.options.saveMissing&&(this.options.saveMissingPlurals&&b?e.forEach(e=>{let t=this.pluralResolver.getSuffixes(e,i);w&&i[`defaultValue${this.options.pluralSeparator}zero`]&&!t.includes(`${this.options.pluralSeparator}zero`)&&t.push(`${this.options.pluralSeparator}zero`),t.forEach(t=>{n([e],s+t,i[`defaultValue${t}`]||T)})}):n(e,s,T))}m=this.extendTranslation(m,t,i,p,r),n&&m===s&&this.options.appendNamespaceToMissingKey&&(m=`${l}${u}${s}`),(n||e)&&this.options.parseMissingKeyHandler&&(m=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}${u}${s}`:s,e?m:void 0,i))}return a?(p.res=m,p.usedParams=this.getUsedParamsDetails(i),p):m}extendTranslation(e,t,n,r,i){if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});let a=U(e)&&(n?.interpolation?.skipOnVariables===void 0?this.options.interpolation.skipOnVariables:n.interpolation.skipOnVariables),o;if(a){let t=e.match(this.interpolator.nestingRegexp);o=t&&t.length}let s=n.replace&&!U(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(s={...this.options.interpolation.defaultVariables,...s}),e=this.interpolator.interpolate(e,s,n.lng||this.language||r.usedLng,n),a){let t=e.match(this.interpolator.nestingRegexp),r=t&&t.length;o<r&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),n.nest!==!1&&(e=this.interpolator.nest(e,(...e)=>i?.[0]===e[0]&&!n.context?(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: ${t[0]}`),null):this.translate(...e,t),n)),n.interpolation&&this.interpolator.reset()}let a=n.postProcess||this.options.postProcess,o=U(a)?[a]:a;return e!=null&&o?.length&&n.applyPostProcessor!==!1&&(e=Mv.handle(o,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e,t={}){let n,r,i,a,o;return U(e)&&(e=[e]),Array.isArray(e)&&(e=e.map(e=>typeof e==`function`?Fv(e,{...this.options,...t}):e)),e.forEach(e=>{if(this.isValidLookup(n))return;let s=this.extractFromKey(e,t),c=s.key;r=c;let l=s.namespaces;this.options.fallbackNS&&(l=l.concat(this.options.fallbackNS));let u=t.count!==void 0&&!U(t.count),d=u&&!t.ordinal&&t.count===0,f=t.context!==void 0&&(U(t.context)||typeof t.context==`number`)&&t.context!==``,p=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);l.forEach(e=>{this.isValidLookup(n)||(o=e,!this.checkedLoadedFor[`${p[0]}-${e}`]&&this.utils?.hasLoadedNamespace&&!this.utils?.hasLoadedNamespace(o)&&(this.checkedLoadedFor[`${p[0]}-${e}`]=!0,this.logger.warn(`key "${r}" for languages "${p.join(`, `)}" won't get resolved as namespace "${o}" was not yet loaded`,`This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`)),p.forEach(r=>{if(this.isValidLookup(n))return;a=r;let o=[c];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(o,c,r,e,t);else{let e;u&&(e=this.pluralResolver.getSuffix(r,t.count,t));let n=`${this.options.pluralSeparator}zero`,i=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(u&&(t.ordinal&&e.startsWith(i)&&o.push(c+e.replace(i,this.options.pluralSeparator)),o.push(c+e),d&&o.push(c+n)),f){let r=`${c}${this.options.contextSeparator||`_`}${t.context}`;o.push(r),u&&(t.ordinal&&e.startsWith(i)&&o.push(r+e.replace(i,this.options.pluralSeparator)),o.push(r+e),d&&o.push(r+n))}}let s;for(;s=o.pop();)this.isValidLookup(n)||(i=s,n=this.getResource(r,e,s,t))}))})}),{res:n,usedKey:r,exactUsedKey:i,usedLng:a,usedNS:o}}isValidLookup(e){return e!==void 0&&!(!this.options.returnNull&&e===null)&&!(!this.options.returnEmptyString&&e===``)}getResource(e,t,n,r={}){return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(e={}){let t=[`defaultValue`,`ordinal`,`context`,`replace`,`lng`,`lngs`,`fallbackLng`,`ns`,`keySeparator`,`nsSeparator`,`returnObjects`,`returnDetails`,`joinArrays`,`postProcess`,`interpolation`],n=e.replace&&!U(e.replace),r=n?e.replace:e;if(n&&e.count!==void 0&&(r={...r,count:e.count}),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(let e of t)delete r[e]}return r}static hasDefaultValue(e){for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&t.startsWith(`defaultValue`)&&e[t]!==void 0)return!0;return!1}},Rv=class{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=kv.create(`languageUtils`)}getScriptPartFromCode(e){if(e=Dv(e),!e||!e.includes(`-`))return null;let t=e.split(`-`);return t.length===2||(t.pop(),t[t.length-1].toLowerCase()===`x`)?null:this.formatLanguageCode(t.join(`-`))}getLanguagePartFromCode(e){if(e=Dv(e),!e||!e.includes(`-`))return e;let t=e.split(`-`);return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(U(e)&&e.includes(`-`)){let t;try{t=Intl.getCanonicalLocales(e)[0]}catch{}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return(this.options.load===`languageOnly`||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.includes(e)}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;let n=this.formatLanguageCode(e);(!this.options.supportedLngs||this.isSupportedCode(n))&&(t=n)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;let n=this.getScriptPartFromCode(e);if(this.isSupportedCode(n))return t=n;let r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(e=>e===r?!0:!e.includes(`-`)&&!r.includes(`-`)?!1:!!(e.includes(`-`)&&!r.includes(`-`)&&e.slice(0,e.indexOf(`-`))===r||e.startsWith(r)&&r.length>1))}),t||=this.getFallbackCodes(this.options.fallbackLng)[0],t}getFallbackCodes(e,t){if(!e)return[];if(typeof e==`function`&&(e=e(t)),U(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||=e[this.getScriptPartFromCode(t)],n||=e[this.formatLanguageCode(t)],n||=e[this.getLanguagePartFromCode(t)],n||=e.default,n||[]}toResolveHierarchy(e,t){let n=this.getFallbackCodes((t===!1?[]:t)||this.options.fallbackLng||[],e),r=[],i=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return U(e)&&(e.includes(`-`)||e.includes(`_`))?(this.options.load!==`languageOnly`&&i(this.formatLanguageCode(e)),this.options.load!==`languageOnly`&&this.options.load!==`currentOnly`&&i(this.getScriptPartFromCode(e)),this.options.load!==`currentOnly`&&i(this.getLanguagePartFromCode(e))):U(e)&&i(this.formatLanguageCode(e)),n.forEach(e=>{r.includes(e)||i(this.formatLanguageCode(e))}),r}},zv={zero:0,one:1,two:2,few:3,many:4,other:5},Bv={select:e=>e===1?`one`:`other`,resolvedOptions:()=>({pluralCategories:[`one`,`other`]})},Vv=class{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=kv.create(`pluralResolver`),this.pluralRulesCache={}}clearCache(){this.pluralRulesCache={}}getRule(e,t={}){let n=Dv(e===`dev`?`en`:e),r=t.ordinal?`ordinal`:`cardinal`,i=JSON.stringify({cleanedCode:n,type:r});if(i in this.pluralRulesCache)return this.pluralRulesCache[i];let a;try{a=new Intl.PluralRules(n,{type:r})}catch{if(typeof Intl>`u`)return this.logger.error(`No Intl support, please use an Intl polyfill!`),Bv;if(!e.match(/-|_/))return Bv;let n=this.languageUtils.getLanguagePartFromCode(e);a=this.getRule(n,t)}return this.pluralRulesCache[i]=a,a}needsPlural(e,t={}){let n=this.getRule(e,t);return n||=this.getRule(`dev`,t),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t,n={}){return this.getSuffixes(e,n).map(e=>`${t}${e}`)}getSuffixes(e,t={}){let n=this.getRule(e,t);return n||=this.getRule(`dev`,t),n?n.resolvedOptions().pluralCategories.sort((e,t)=>zv[e]-zv[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:``}${e}`):[]}getSuffix(e,t,n={}){let r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:``}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix(`dev`,t,n))}},Hv=(e,t,n,r=`.`,i=!0)=>{let a=_v(e,t,n);return!a&&i&&U(n)&&(a=Ev(e,n,r),a===void 0&&(a=Ev(t,n,r))),a},Uv=e=>e.replace(/\$/g,`$$$$`),Wv=class{constructor(e={}){this.logger=kv.create(`interpolator`),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||={escapeValue:!0};let{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:i,prefixEscaped:a,suffix:o,suffixEscaped:s,formatSeparator:c,unescapeSuffix:l,unescapePrefix:u,nestingPrefix:d,nestingPrefixEscaped:f,nestingSuffix:p,nestingSuffixEscaped:m,nestingOptionsSeparator:h,maxReplaces:g,alwaysFormat:_}=e.interpolation;this.escape=t===void 0?xv:t,this.escapeValue=n===void 0||n,this.useRawValueToEscape=r!==void 0&&r,this.prefix=i?yv(i):a||`{{`,this.suffix=o?yv(o):s||`}}`,this.formatSeparator=c||`,`,this.unescapePrefix=l?``:u?yv(u):`-`,this.unescapeSuffix=this.unescapePrefix?``:l?yv(l):``,this.nestingPrefix=d?yv(d):f||yv(`$t(`),this.nestingSuffix=p?yv(p):m||yv(`)`),this.nestingOptionsSeparator=h||`,`,this.maxReplaces=g||1e3,this.alwaysFormat=_!==void 0&&_,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){let e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,`g`);this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let i,a,o,s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=e=>{if(!e.includes(this.formatSeparator)){let i=Hv(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(i,void 0,n,{...r,...t,interpolationkey:e}):i}let i=e.split(this.formatSeparator),a=i.shift().trim(),o=i.join(this.formatSeparator).trim();return this.format(Hv(t,s,a,this.options.keySeparator,this.options.ignoreJSONStructure),o,n,{...r,...t,interpolationkey:a})};this.resetRegExp(),!this.escapeValue&&typeof e==`string`&&/\$t\([^)]*\{[^}]*\{\{/.test(e)&&this.logger.warn(`nesting options string contains interpolated variables with escapeValue: false — if any of those values are attacker-controlled they can inject additional nesting options (e.g. redirect lng/ns). Sanitise untrusted input before passing it to t(), or keep escapeValue: true.`);let l=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,u=r?.interpolation?.skipOnVariables===void 0?this.options.interpolation.skipOnVariables:r.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>e},{regex:this.regexp,safeValue:e=>this.escapeValue?this.escape(e):e}].forEach(t=>{for(o=0;i=t.regex.exec(e);){let n=i[1].trim();if(a=c(n),a===void 0){if(typeof l==`function`){let t=l(e,i,r);a=U(t)?t:``}else if(r&&Object.prototype.hasOwnProperty.call(r,n))a=``;else if(u){a=i[0];continue}else this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),a=``}else!U(a)&&!this.useRawValueToEscape&&(a=cv(a));let s=t.safeValue(a);if(e=e.replace(i[0],Uv(s)),u?(t.regex.lastIndex+=s.length,t.regex.lastIndex-=i[0].length):t.regex.lastIndex=0,o++,o>=this.maxReplaces)break}}),e}nest(e,t,n={}){let r,i,a,o=(e,t)=>{let n=this.nestingOptionsSeparator;if(!e.includes(n))return e;let r=e.split(RegExp(`${yv(n)}[ ]*{`)),i=`{${r[1]}`;e=r[0],i=this.interpolate(i,a);let o=i.match(/'/g),s=i.match(/"/g);((o?.length??0)%2==0&&!s||(s?.length??0)%2!=0)&&(i=i.replace(/'/g,`"`));try{a=JSON.parse(i),t&&(a={...t,...a})}catch(t){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,t),`${e}${n}${i}`}return a.defaultValue&&a.defaultValue.includes(this.prefix)&&delete a.defaultValue,e};for(;r=this.nestingRegexp.exec(e);){let s=[];a={...n},a=a.replace&&!U(a.replace)?a.replace:a,a.applyPostProcessor=!1,delete a.defaultValue;let c=/{.*}/s.test(r[1])?r[1].lastIndexOf(`}`)+1:r[1].indexOf(this.formatSeparator);if(c!==-1&&(s=r[1].slice(c).split(this.formatSeparator).map(e=>e.trim()).filter(Boolean),r[1]=r[1].slice(0,c)),i=t(o.call(this,r[1].trim(),a),a),i&&r[0]===e&&!U(i))return i;U(i)||(i=cv(i)),i||=(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),``),s.length&&(i=s.reduce((e,t)=>this.format(e,t,n.lng,{...n,interpolationkey:r[1].trim()}),i.trim())),e=e.replace(r[0],i),this.regexp.lastIndex=0}return e}},Gv=e=>{let t=e.toLowerCase().trim(),n={};if(e.includes(`(`)){let r=e.split(`(`);t=r[0].toLowerCase().trim();let i=r[1].slice(0,-1);t===`currency`&&!i.includes(`:`)?n.currency||=i.trim():t===`relativetime`&&!i.includes(`:`)?n.range||=i.trim():i.split(`;`).forEach(e=>{if(e){let[t,...r]=e.split(`:`),i=r.join(`:`).trim().replace(/^'+|'+$/g,``),a=t.trim();n[a]||(n[a]=i),i===`false`&&(n[a]=!1),i===`true`&&(n[a]=!0),isNaN(i)||(n[a]=parseInt(i,10))}})}return{formatName:t,formatOptions:n}},Kv=e=>{let t={};return(n,r,i)=>{let a=i;i&&i.interpolationkey&&i.formatParams&&i.formatParams[i.interpolationkey]&&i[i.interpolationkey]&&(a={...a,[i.interpolationkey]:void 0});let o=r+JSON.stringify(a),s=t[o];return s||(s=e(Dv(r),i),t[o]=s),s(n)}},qv=e=>(t,n,r)=>e(Dv(n),r)(t),Jv=class{constructor(e={}){this.logger=kv.create(`formatter`),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||`,`;let n=t.cacheInBuiltFormats?Kv:qv;this.formats={number:n((e,t)=>{let n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)}),currency:n((e,t)=>{let n=new Intl.NumberFormat(e,{...t,style:`currency`});return e=>n.format(e)}),datetime:n((e,t)=>{let n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)}),relativetime:n((e,t)=>{let n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||`day`)}),list:n((e,t)=>{let n=new Intl.ListFormat(e,{...t});return e=>n.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Kv(t)}format(e,t,n,r={}){if(!t||e==null)return e;let i=t.split(this.formatSeparator),a=[];for(let e=0;e<i.length;e++){let t=i[e];for(;t.indexOf(`(`)>-1&&!t.includes(`)`)&&e+1<i.length;)t=`${t}${this.formatSeparator}${i[++e]}`;a.push(t)}return a.reduce((e,t)=>{let{formatName:i,formatOptions:a}=Gv(t);if(this.formats[i]){let t=e;try{let o=r?.formatParams?.[r.interpolationkey]||{},s=o.locale||o.lng||r.locale||r.lng||n;t=this.formats[i](e,s,{...a,...r,...o})}catch(e){this.logger.warn(e)}return t}return this.logger.warn(`there was no format function for ${i}`),e},e)}},Yv=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)},Xv=class extends Av{constructor(e,t,n,r={}){super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=kv.create(`backendConnector`),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){let i={},a={},o={},s={};return e.forEach(e=>{let r=!0;t.forEach(t=>{let o=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[o]=2:this.state[o]<0||(this.state[o]===1?a[o]===void 0&&(a[o]=!0):(this.state[o]=1,r=!1,a[o]===void 0&&(a[o]=!0),i[o]===void 0&&(i[o]=!0),s[t]===void 0&&(s[t]=!0)))}),r||(o[e]=!0)}),(Object.keys(i).length||Object.keys(a).length)&&this.queue.push({pending:a,pendingCount:Object.keys(a).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(i),pending:Object.keys(a),toLoadLanguages:Object.keys(o),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){let r=e.split(`|`),i=r[0],a=r[1];t&&this.emit(`failedLoading`,i,a,t),!t&&n&&this.store.addResourceBundle(i,a,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);let o={};this.queue.forEach(n=>{hv(n.loaded,[i],a),Yv(n,e),t&&n.errors.push(t),n.pendingCount===0&&!n.done&&(Object.keys(n.loaded).forEach(e=>{o[e]||(o[e]={});let t=n.loaded[e];t.length&&t.forEach(t=>{o[e][t]===void 0&&(o[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit(`loaded`,o),this.queue=this.queue.filter(e=>!e.done)}read(e,t,n,r=0,i=this.retryTimeout,a){if(!e.length)return a(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:i,callback:a});return}this.readingCalls++;let o=(o,s)=>{if(this.readingCalls--,this.waitingReads.length>0){let e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}if(o&&s&&r<this.maxRetries){setTimeout(()=>{this.read(e,t,n,r+1,i*2,a)},i);return}a(o,s)},s=this.backend[n].bind(this.backend);if(s.length===2){try{let n=s(e,t);n&&typeof n.then==`function`?n.then(e=>o(null,e)).catch(o):o(null,n)}catch(e){o(e)}return}return s(e,t,o)}prepareLoading(e,t,n={},r){if(!this.backend)return this.logger.warn(`No backend was added via i18next.use. Will not load resources.`),r&&r();U(e)&&(e=this.languageUtils.toResolveHierarchy(e)),U(t)&&(t=[t]);let i=this.queueLoad(e,t,n,r);if(!i.toLoad.length)return i.pending.length||r(),null;i.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e,t=``){let n=e.split(`|`),r=n[0],i=n[1];this.read(r,i,`read`,void 0,void 0,(n,a)=>{n&&this.logger.warn(`${t}loading namespace ${i} for language ${r} failed`,n),!n&&a&&this.logger.log(`${t}loaded namespace ${i} for language ${r}`,a),this.loaded(e,n,a)})}saveMissing(e,t,n,r,i,a={},o=()=>{}){if(this.services?.utils?.hasLoadedNamespace&&!this.services?.utils?.hasLoadedNamespace(t)){this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,`This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`);return}if(n!=null&&n!==``){if(this.backend?.create){let s={...a,isUpdate:i},c=this.backend.create.bind(this.backend);if(c.length<6)try{let i;i=c.length===5?c(e,t,n,r,s):c(e,t,n,r),i&&typeof i.then==`function`?i.then(e=>o(null,e)).catch(o):o(null,i)}catch(e){o(e)}else c(e,t,n,r,o,s)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}},Zv=()=>({debug:!1,initAsync:!0,ns:[`translation`],defaultNS:[`translation`],fallbackLng:[`dev`],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:`all`,preload:!1,keySeparator:`.`,nsSeparator:`:`,pluralSeparator:`_`,contextSeparator:`_`,enableSelector:!1,partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:`fallback`,saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]==`object`&&(t=e[1]),U(e[1])&&(t.defaultValue=e[1]),U(e[2])&&(t.tDescription=e[2]),typeof e[2]==`object`||typeof e[3]==`object`){let n=e[3]||e[2];Object.keys(n).forEach(e=>{t[e]=n[e]})}return t},interpolation:{escapeValue:!0,prefix:`{{`,suffix:`}}`,formatSeparator:`,`,unescapePrefix:`-`,nestingPrefix:`$t(`,nestingSuffix:`)`,nestingOptionsSeparator:`,`,maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Qv=e=>(U(e.ns)&&(e.ns=[e.ns]),U(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),U(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&!e.supportedLngs.includes(`cimode`)&&(e.supportedLngs=e.supportedLngs.concat([`cimode`])),e),$v=()=>{},ey=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(t=>{typeof e[t]==`function`&&(e[t]=e[t].bind(e))})},ty=class e extends Av{constructor(e={},t){if(super(),this.options=Qv(e),this.services={},this.logger=kv,this.modules={external:[]},ey(this),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(e={},t){this.isInitializing=!0,typeof e==`function`&&(t=e,e={}),e.defaultNS==null&&e.ns&&(U(e.ns)?e.defaultNS=e.ns:e.ns.includes(`translation`)||(e.defaultNS=e.ns[0]));let n=Zv();this.options={...n,...this.options,...Qv(e)},this.options.interpolation={...n.interpolation,...this.options.interpolation},e.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=e.keySeparator),e.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=e.nsSeparator),typeof this.options.overloadTranslationOptionHandler!=`function`&&(this.options.overloadTranslationOptionHandler=n.overloadTranslationOptionHandler);let r=e=>e?typeof e==`function`?new e:e:null;if(!this.options.isClone){this.modules.logger?kv.init(r(this.modules.logger),this.options):kv.init(null,this.options);let e;e=this.modules.formatter?this.modules.formatter:Jv;let t=new Rv(this.options);this.store=new jv(this.options.resources,this.options);let n=this.services;n.logger=kv,n.resourceStore=this.store,n.languageUtils=t,n.pluralResolver=new Vv(t,{prepend:this.options.pluralSeparator}),e&&(n.formatter=r(e),n.formatter.init&&n.formatter.init(n,this.options),this.options.interpolation.format=n.formatter.format.bind(n.formatter)),n.interpolator=new Wv(this.options),n.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},n.backendConnector=new Xv(r(this.modules.backend),n.resourceStore,n,this.options),n.backendConnector.on(`*`,(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(n.languageDetector=r(this.modules.languageDetector),n.languageDetector.init&&n.languageDetector.init(n,this.options.detection,this.options)),this.modules.i18nFormat&&(n.i18nFormat=r(this.modules.i18nFormat),n.i18nFormat.init&&n.i18nFormat.init(this)),this.translator=new Lv(this.services,this.options),this.translator.on(`*`,(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,t||=$v,this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){let e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&e[0]!==`dev`&&(this.options.lng=e[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn(`init: no languageDetector is used and no lng is defined`),[`getResource`,`hasResourceBundle`,`getResourceBundle`,`getDataByLanguage`].forEach(e=>{this[e]=(...t)=>this.store[e](...t)}),[`addResource`,`addResources`,`addResourceBundle`,`removeResourceBundle`].forEach(e=>{this[e]=(...t)=>(this.store[e](...t),this)});let i=sv(),a=()=>{let e=(e,n)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn(`init: i18next is already initialized. You should call init just once!`),this.isInitialized=!0,this.options.isClone||this.logger.log(`initialized`,this.options),this.emit(`initialized`,this.options),i.resolve(n),t(e,n)};if((this.languages||this.isLanguageChangingTo)&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?a():setTimeout(a,0),i}loadResources(e,t=$v){let n=t,r=U(e)?e:this.language;if(typeof e==`function`&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(r?.toLowerCase()===`cimode`&&(!this.options.preload||this.options.preload.length===0))return n();let e=[],t=t=>{t&&t!==`cimode`&&this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{t!==`cimode`&&(e.includes(t)||e.push(t))})};r?t(r):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>t(e)),this.options.preload?.forEach?.(e=>t(e)),this.services.backendConnector.load(e,this.options.ns,e=>{!e&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),n(e)})}else n(null)}reloadResources(e,t,n){let r=sv();return typeof e==`function`&&(n=e,e=void 0),typeof t==`function`&&(n=t,t=void 0),e||=this.languages,t||=this.options.ns,n||=$v,this.services.backendConnector.reload(e,t,e=>{r.resolve(),n(e)}),r}use(e){if(!e)throw Error(`You are passing an undefined module! Please check the object you are passing to i18next.use()`);if(!e.type)throw Error(`You are passing a wrong module! Please check the object you are passing to i18next.use()`);return e.type===`backend`&&(this.modules.backend=e),(e.type===`logger`||e.log&&e.warn&&e.error)&&(this.modules.logger=e),e.type===`languageDetector`&&(this.modules.languageDetector=e),e.type===`i18nFormat`&&(this.modules.i18nFormat=e),e.type===`postProcessor`&&Mv.addPostProcessor(e),e.type===`formatter`&&(this.modules.formatter=e),e.type===`3rdParty`&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&![`cimode`,`dev`].includes(e)){for(let e=0;e<this.languages.length;e++){let t=this.languages[e];if(![`cimode`,`dev`].includes(t)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}!this.resolvedLanguage&&!this.languages.includes(e)&&this.store.hasLanguageSomeTranslations(e)&&(this.resolvedLanguage=e,this.languages.unshift(e))}}changeLanguage(e,t){this.isLanguageChangingTo=e;let n=sv();this.emit(`languageChanging`,e);let r=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(i,a)=>{a?this.isLanguageChangingTo===e&&(r(a),this.translator.changeLanguage(a),this.isLanguageChangingTo=void 0,this.emit(`languageChanged`,a),this.logger.log(`languageChanged`,a)):this.isLanguageChangingTo=void 0,n.resolve((...e)=>this.t(...e)),t&&t(i,(...e)=>this.t(...e))},a=t=>{!e&&!t&&this.services.languageDetector&&(t=[]);let n=U(t)?t:t&&t[0],a=this.store.hasLanguageSomeTranslations(n)?n:this.services.languageUtils.getBestMatchFromCodes(U(t)?[t]:t);a&&(this.language||r(a),this.translator.language||this.translator.changeLanguage(a),this.services.languageDetector?.cacheUserLanguage?.(a)),this.loadResources(a,e=>{i(e,a)})};return!e&&this.services.languageDetector&&!this.services.languageDetector.async?a(this.services.languageDetector.detect()):!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e),n}getFixedT(e,t,n,r){let i=r?.scopeNs,a=(e,t,...r)=>{let o;o=typeof t==`object`?{...t}:this.options.overloadTranslationOptionHandler([e,t].concat(r)),o.lng=o.lng||a.lng,o.lngs=o.lngs||a.lngs;let s=o.ns!==void 0&&o.ns!==null;o.ns=o.ns||a.ns,o.keyPrefix!==``&&(o.keyPrefix=o.keyPrefix||n||a.keyPrefix);let c={...this.options,...o};Array.isArray(i)&&!s&&(c.ns=i),typeof o.keyPrefix==`function`&&(o.keyPrefix=Fv(o.keyPrefix,c));let l=this.options.keySeparator||`.`,u;return o.keyPrefix&&Array.isArray(e)?u=e.map(e=>(typeof e==`function`&&(e=Fv(e,c)),`${o.keyPrefix}${l}${e}`)):(typeof e==`function`&&(e=Fv(e,c)),u=o.keyPrefix?`${o.keyPrefix}${l}${e}`:e),this.t(u,o)};return U(e)?a.lng=e:a.lngs=e,a.ns=t,a.keyPrefix=n,a}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn(`hasLoadedNamespace: i18next was not initialized`,this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn(`hasLoadedNamespace: i18n.languages were undefined or empty`,this.languages),!1;let n=t.lng||this.resolvedLanguage||this.languages[0],r=this.options?this.options.fallbackLng:!1,i=this.languages[this.languages.length-1];if(n.toLowerCase()===`cimode`)return!0;let a=(e,t)=>{let n=this.services.backendConnector.state[`${e}|${t}`];return n===-1||n===0||n===2};if(t.precheck){let e=t.precheck(this,a);if(e!==void 0)return e}return!!(this.hasResourceBundle(n,e)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||a(n,e)&&(!r||a(i,e)))}loadNamespaces(e,t){let n=sv();return this.options.ns?(U(e)&&(e=[e]),e.forEach(e=>{this.options.ns.includes(e)||this.options.ns.push(e)}),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){let n=sv();U(e)&&(e=[e]);let r=this.options.preload||[],i=e.filter(e=>!r.includes(e)&&this.services.languageUtils.isSupportedCode(e));return i.length?(this.options.preload=r.concat(i),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language),!e)return`rtl`;try{let t=new Intl.Locale(e);if(t&&t.getTextInfo){let e=t.getTextInfo();if(e&&e.direction)return e.direction}}catch{}let t=`ar.shu.sqr.ssh.xaa.yhd.yud.aao.abh.abv.acm.acq.acw.acx.acy.adf.ads.aeb.aec.afb.ajp.apc.apd.arb.arq.ars.ary.arz.auz.avl.ayh.ayl.ayn.ayp.bbz.pga.he.iw.ps.pbt.pbu.pst.prp.prd.ug.ur.ydd.yds.yih.ji.yi.hbo.men.xmn.fa.jpr.peo.pes.prs.dv.sam.ckb`.split(`.`),n=this.services?.languageUtils||new Rv(Zv());return e.toLowerCase().indexOf(`-latn`)>1?`ltr`:t.includes(n.getLanguagePartFromCode(e))||e.toLowerCase().indexOf(`-arab`)>1?`rtl`:`ltr`}static createInstance(t={},n){let r=new e(t,n);return r.createInstance=e.createInstance,r}cloneInstance(t={},n=$v){let r=t.forkResourceStore;r&&delete t.forkResourceStore;let i={...this.options,...t,isClone:!0},a=new e(i);if((t.debug!==void 0||t.prefix!==void 0)&&(a.logger=a.logger.clone(t)),[`store`,`services`,`language`].forEach(e=>{a[e]=this[e]}),a.services={...this.services},a.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},r&&(a.store=new jv(Object.keys(this.store.data).reduce((e,t)=>(e[t]={...this.store.data[t]},e[t]=Object.keys(e[t]).reduce((n,r)=>(n[r]={...e[t][r]},n),e[t]),e),{}),i),a.services.resourceStore=a.store),t.interpolation){let e={...Zv().interpolation,...this.options.interpolation,...t.interpolation},n={...i,interpolation:e};a.services.interpolator=new Wv(n)}return a.translator=new Lv(a.services,i),a.translator.on(`*`,(e,...t)=>{a.emit(e,...t)}),a.init(i,n),a.translator.options=i,a.translator.backendConnector.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},a}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}.createInstance();ty.createInstance,ty.dir,ty.init,ty.loadResources,ty.reloadResources,ty.use,ty.changeLanguage,ty.getFixedT,ty.t,ty.exists,ty.setDefaultNamespace,ty.hasLoadedNamespace,ty.loadNamespaces,ty.loadLanguages;var ny=c((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ee(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var te=/\/+/g;function ne(e,t){return typeof e==`object`&&e&&e.key!=null?ee(``+e.key):t.toString(36)}function re(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function k(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,k(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+ne(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(te,`$&/`)+`/`),k(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(te,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+ne(a,u),c+=k(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+ne(a,u++),c+=k(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return k(re(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function A(e,t,n){if(e==null)return e;var r=[],i=0;return k(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function ie(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var ae=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},oe={map:A,forEach:function(e,t,n){A(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return A(e,function(){t++}),t},toArray:function(e){return A(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=oe,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:ie}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,ae)}catch(e){ae(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.8`})),ry=c(((e,t)=>{t.exports=ny()})),iy=(e,t,n,r)=>{let i=[n,{code:t,...r||{}}];if(e?.services?.logger?.forward)return e.services.logger.forward(i,`warn`,`react-i18next::`,!0);dy(i[0])&&(i[0]=`react-i18next:: ${i[0]}`),e?.services?.logger?.warn?e.services.logger.warn(...i):console?.warn&&console.warn(...i)},ay={},oy=(e,t,n,r)=>{dy(n)&&ay[n]||(dy(n)&&(ay[n]=new Date),iy(e,t,n,r))},sy=(e,t)=>()=>{if(e.isInitialized)t();else{let n=()=>{setTimeout(()=>{e.off(`initialized`,n)},0),t()};e.on(`initialized`,n)}},cy=(e,t,n)=>{e.loadNamespaces(t,sy(e,n))},ly=(e,t,n,r)=>{if(dy(n)&&(n=[n]),e.options.preload&&e.options.preload.indexOf(t)>-1)return cy(e,n,r);n.forEach(t=>{e.options.ns.indexOf(t)<0&&e.options.ns.push(t)}),e.loadLanguages(t,sy(e,r))},uy=(e,t,n={})=>!t.languages||!t.languages.length?(oy(t,`NO_LANGUAGES`,`i18n.languages were undefined or empty`,{languages:t.languages}),!0):t.hasLoadedNamespace(e,{lng:n.lng,precheck:(t,r)=>{if(n.bindI18n&&n.bindI18n.indexOf(`languageChanging`)>-1&&t.services.backendConnector.backend&&t.isLanguageChangingTo&&!r(t.isLanguageChangingTo,e))return!1}}),dy=e=>typeof e==`string`,fy=e=>typeof e==`object`&&!!e,py=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,my={"&amp;":`&`,"&#38;":`&`,"&lt;":`<`,"&#60;":`<`,"&gt;":`>`,"&#62;":`>`,"&apos;":`'`,"&#39;":`'`,"&quot;":`"`,"&#34;":`"`,"&nbsp;":` `,"&#160;":` `,"&copy;":`©`,"&#169;":`©`,"&reg;":`®`,"&#174;":`®`,"&hellip;":`…`,"&#8230;":`…`,"&#x2F;":`/`,"&#47;":`/`},hy=e=>my[e],gy={bindI18n:`languageChanged`,bindI18nStore:``,transEmptyNodeValue:``,transSupportBasicHtmlNodes:!0,transWrapTextNodes:``,transKeepBasicHtmlNodesFor:[`br`,`strong`,`i`,`p`],useSuspense:!0,unescape:e=>e.replace(py,hy),transDefaultProps:void 0},_y=(e={})=>{gy={...gy,...e}},vy=()=>gy,yy,by=e=>{yy=e},xy=()=>yy,Sy={type:`3rdParty`,init(e){_y(e.options.react),by(e)}},W=d(ry()),Cy=(0,W.createContext)(),wy=class{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(e=>{this.usedNamespaces[e]||(this.usedNamespaces[e]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}},Ty=c((e=>{var t=ry();function n(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var r=typeof Object.is==`function`?Object.is:n,i=t.useState,a=t.useEffect,o=t.useLayoutEffect,s=t.useDebugValue;function c(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),c=r[0].inst,u=r[1];return o(function(){c.value=n,c.getSnapshot=t,l(c)&&u({inst:c})},[e,n,t]),a(function(){return l(c)&&u({inst:c}),e(function(){l(c)&&u({inst:c})})},[e]),s(n),n}function l(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!r(e,n)}catch{return!0}}function u(e,t){return t()}var d=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?u:c;e.useSyncExternalStore=t.useSyncExternalStore===void 0?d:t.useSyncExternalStore})),Ey=c(((e,t)=>{t.exports=Ty()}))(),Dy={t:(e,t)=>{if(dy(t))return t;if(fy(t)&&dy(t.defaultValue))return t.defaultValue;if(typeof e==`function`)return``;if(Array.isArray(e)){let t=e[e.length-1];return typeof t==`function`?``:t}return e},ready:!1},Oy=()=>()=>{},ky=(e,t={})=>{let{i18n:n}=t,{i18n:r,defaultNS:i}=(0,W.useContext)(Cy)||{},a=n||r||xy();a&&!a.reportNamespaces&&(a.reportNamespaces=new wy),a||oy(a,`NO_I18NEXT_INSTANCE`,`useTranslation: You will need to pass in an i18next instance by using initReactI18next or by passing it via props or context. In monorepo setups, make sure there is only one instance of react-i18next.`);let o=(0,W.useMemo)(()=>({...vy(),...a?.options?.react,...t}),[a,t]),{useSuspense:s,keyPrefix:c}=o,l=e||i||a?.options?.defaultNS,u=dy(l)?[l]:l||[`translation`],d=(0,W.useMemo)(()=>u,u);a?.reportNamespaces?.addUsedNamespaces?.(d);let f=(0,W.useRef)(0),p=(0,W.useCallback)(e=>{if(!a)return Oy;let{bindI18n:t,bindI18nStore:n}=o,r=()=>{f.current+=1,e()};return t&&a.on(t,r),n&&a.store.on(n,r),()=>{t&&t.split(` `).forEach(e=>a.off(e,r)),n&&n.split(` `).forEach(e=>a.store.off(e,r))}},[a,o]),m=(0,W.useRef)(),h=(0,W.useCallback)(()=>{if(!a)return Dy;let e=!!(a.isInitialized||a.initializedStoreOnce)&&d.every(e=>uy(e,a,o)),n=t.lng||a.language,r=f.current,i=m.current;if(i&&i.ready===e&&i.lng===n&&i.keyPrefix===c&&i.revision===r)return i;let s={t:a.getFixedT(n,o.nsMode===`fallback`?d:d[0],c,{scopeNs:d}),ready:e,lng:n,keyPrefix:c,revision:r};return m.current=s,s},[a,d,c,o,t.lng]),[g,_]=(0,W.useState)(0),{t:v,ready:y}=(0,Ey.useSyncExternalStore)(p,h,h);(0,W.useEffect)(()=>{if(a&&!y&&!s){let e=()=>_(e=>e+1);t.lng?ly(a,t.lng,d,e):cy(a,d,e)}},[a,t.lng,d,y,s,g]);let b=a||{},x=(0,W.useRef)(null),S=(0,W.useRef)(),C=e=>{let t=Object.getOwnPropertyDescriptors(e);t.__original&&delete t.__original;let n=Object.create(Object.getPrototypeOf(e),t);if(!Object.prototype.hasOwnProperty.call(n,`__original`))try{Object.defineProperty(n,"__original",{value:e,writable:!1,enumerable:!1,configurable:!1})}catch{}return n},w=(0,W.useMemo)(()=>{let e=b,t=e?.language,n=e;e&&(x.current&&x.current.__original===e&&S.current===t?n=x.current:(n=C(e),x.current=n,S.current=t));let r=!y&&!s?(...e)=>(oy(a,`USE_T_BEFORE_READY`,`useTranslation: t was called before ready. When using useSuspense: false, make sure to check the ready flag before using t.`),v(...e)):v,i=[r,n,y];return i.t=r,i.i18n=n,i.ready=y,i},[v,b,y,b.resolvedLanguage,b.language,b.languages]);if(a&&s&&!y){let e=!1;try{e=!1}catch{}throw e&&oy(a,`SUSPENDED_WHILE_LOADING`,`useTranslation: suspended while translations are loading (useSuspense is true by default). Add a <Suspense> boundary above this component, or set react.useSuspense: false in the i18next init options. https://react.i18next.com/latest/usetranslation-hook`),new Promise(e=>{let n=()=>e();t.lng?ly(a,t.lng,d,n):cy(a,d,n)})}return w},{slice:Ay,forEach:jy}=[];function My(e){return jy.call(Ay.call(arguments,1),t=>{if(t)for(let n in t)e[n]===void 0&&(e[n]=t[n])}),e}function Ny(e){return typeof e==`string`&&[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(t=>t.test(e))}var Py=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,Fy=function(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:`/`},r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){let e=n.maxAge-0;if(Number.isNaN(e))throw Error(`maxAge should be a Number`);r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!Py.test(n.domain))throw TypeError(`option domain is invalid`);r+=`; Domain=${n.domain}`}if(n.path){if(!Py.test(n.path))throw TypeError(`option path is invalid`);r+=`; Path=${n.path}`}if(n.expires){if(typeof n.expires.toUTCString!=`function`)throw TypeError(`option expires is invalid`);r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+=`; HttpOnly`),n.secure&&(r+=`; Secure`),n.sameSite)switch(typeof n.sameSite==`string`?n.sameSite.toLowerCase():n.sameSite){case!0:r+=`; SameSite=Strict`;break;case`lax`:r+=`; SameSite=Lax`;break;case`strict`:r+=`; SameSite=Strict`;break;case`none`:r+=`; SameSite=None`;break;default:throw TypeError(`option sameSite is invalid`)}return n.partitioned&&(r+=`; Partitioned`),r},Iy={create(e,t,n,r){let i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:`/`,sameSite:`strict`};n&&(i.expires=new Date,i.expires.setTime(i.expires.getTime()+n*60*1e3)),r&&(i.domain=r),document.cookie=Fy(e,t,i)},read(e){let t=`${e}=`,n=document.cookie.split(`;`);for(let e=0;e<n.length;e++){let r=n[e];for(;r.charAt(0)===` `;)r=r.substring(1,r.length);if(r.indexOf(t)===0)return r.substring(t.length,r.length)}return null},remove(e,t){this.create(e,``,-1,t)}},Ly={name:`cookie`,lookup(e){let{lookupCookie:t}=e;if(t&&typeof document<`u`)return Iy.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:i,cookieOptions:a}=t;n&&typeof document<`u`&&Iy.create(n,e,r,i,a)}},Ry={name:`querystring`,lookup(e){let{lookupQuerystring:t}=e,n;if(typeof window<`u`){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf(`?`)>-1&&(e=window.location.hash.substring(window.location.hash.indexOf(`?`)));let r=e.substring(1).split(`&`);for(let e=0;e<r.length;e++){let i=r[e].indexOf(`=`);i>0&&r[e].substring(0,i)===t&&(n=r[e].substring(i+1))}}return n}},zy={name:`hash`,lookup(e){let{lookupHash:t,lookupFromHashIndex:n}=e,r;if(typeof window<`u`){let{hash:e}=window.location;if(e&&e.length>2){let i=e.substring(1);if(t){let e=i.split(`&`);for(let n=0;n<e.length;n++){let i=e[n].indexOf(`=`);i>0&&e[n].substring(0,i)===t&&(r=e[n].substring(i+1))}}if(r)return r;if(!r&&n>-1){let t=e.match(/\/([a-zA-Z-]*)/g);return Array.isArray(t)?t[typeof n==`number`?n:0]?.replace(`/`,``):void 0}}}return r}},By=null,Vy=()=>{if(By!==null)return By;try{if(By=typeof window<`u`&&window.localStorage!==null,!By)return!1;let e=`i18next.translate.boo`;window.localStorage.setItem(e,`foo`),window.localStorage.removeItem(e)}catch{By=!1}return By},Hy={name:`localStorage`,lookup(e){let{lookupLocalStorage:t}=e;if(t&&Vy())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&Vy()&&window.localStorage.setItem(n,e)}},Uy=null,Wy=()=>{if(Uy!==null)return Uy;try{if(Uy=typeof window<`u`&&window.sessionStorage!==null,!Uy)return!1;let e=`i18next.translate.boo`;window.sessionStorage.setItem(e,`foo`),window.sessionStorage.removeItem(e)}catch{Uy=!1}return Uy},Gy={name:`sessionStorage`,lookup(e){let{lookupSessionStorage:t}=e;if(t&&Wy())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&Wy()&&window.sessionStorage.setItem(n,e)}},Ky={name:`navigator`,lookup(e){let t=[];if(typeof navigator<`u`){let{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let n=0;n<e.length;n++)t.push(e[n]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},qy={name:`htmlTag`,lookup(e){let{htmlTag:t}=e,n,r=t||(typeof document<`u`?document.documentElement:null);return r&&typeof r.getAttribute==`function`&&(n=r.getAttribute(`lang`)),n}},Jy={name:`path`,lookup(e){let{lookupFromPathIndex:t}=e;if(typeof window>`u`)return;let n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(Array.isArray(n))return n[typeof t==`number`?t:0]?.replace(`/`,``)}},Yy={name:`subdomain`,lookup(e){let{lookupFromSubdomainIndex:t}=e,n=typeof t==`number`?t+1:1,r=typeof window<`u`&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}},Xy=!1;try{document.cookie,Xy=!0}catch{}var Zy=[`querystring`,`cookie`,`localStorage`,`sessionStorage`,`navigator`,`htmlTag`];Xy||Zy.splice(1,1);var Qy=()=>({order:Zy,lookupQuerystring:`lng`,lookupCookie:`i18next`,lookupLocalStorage:`i18nextLng`,lookupSessionStorage:`i18nextLng`,caches:[`localStorage`],excludeCacheFor:[`cimode`],convertDetectedLanguage:e=>e}),$y=class{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type=`languageDetector`,this.detectors={},this.init(e,t)}init(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=e,this.options=My(t,this.options||{},Qy()),typeof this.options.convertDetectedLanguage==`string`&&this.options.convertDetectedLanguage.indexOf(`15897`)>-1&&(this.options.convertDetectedLanguage=e=>e.replace(`-`,`_`)),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=n,this.addDetector(Ly),this.addDetector(Ry),this.addDetector(Hy),this.addDetector(Gy),this.addDetector(Ky),this.addDetector(qy),this.addDetector(Jy),this.addDetector(Yy),this.addDetector(zy)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,t=[];return e.forEach(e=>{if(this.detectors[e]){let n=this.detectors[e].lookup(this.options);n&&typeof n==`string`&&(n=[n]),n&&(t=t.concat(n))}}),t=t.filter(e=>e!=null&&!Ny(e)).map(e=>this.options.convertDetectedLanguage(e)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?t:t.length>0?t[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach(t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)}))}};$y.type=`languageDetector`;var eb={pages:{popup:`pages.popup`},common:`common`,popover:`popover`,errors:`errors`,iconController:`iconController`,notifications:`notifications`,options:`options`,editor:`editor`},tb={de:`de`,en:`en`,fr:`fr`},nb={[eb.editor]:{toolbar:`Formatierung`,bold:`Fett`,italic:`Kursiv`,underline:`Unterstrichen`,heading:`Überschrift`,bulletList:`Aufzählung`,orderedList:`Nummerierte Liste`,quote:`Zitat`,undo:`Rückgängig`,redo:`Wiederholen`,settings:`Witty-Einstellungen`,closeSettings:`Einstellungen schliessen`,settingsLoading:`Einstellungen werden geladen …`,statusChecking:`Witty prüft den Text …`,statusAlerts_one:`{{count}} Hinweis`,statusAlerts_other:`{{count}} Hinweise`,statusNoAlerts:`Keine Hinweise`,statusUnauthorized:`API-Schlüssel fehlt oder wurde nicht akzeptiert`,statusFailed:`Prüfung fehlgeschlagen`,shortcutHint:`Mit Alt+Umschalt+W öffnest du den Hinweis an der Cursorposition.`,limitReached:`Nur ein Teil dieses Textes wurde geprüft.`,menu:`Witty-Menü`,menuSettings:`Einstellungen …`,menuSwitchGender:`Gender-Form wechseln …`,menuHelp:`Hilfe`,menuAbout:`Über Witty`,switchTitle:`Gender-Form wechseln`,switchIntro:`Schreibt alle gegenderten Formen im Text in die gewählte Form um. Mit Rückgängig machst du das in einem Schritt rückgängig.`,switchCurrent:`aktuell`,switching:`Der Text wird geprüft und umgeschrieben …`,switched_one:`{{count}} Form auf {{format}} umgestellt.`,switched_other:`{{count}} Formen auf {{format}} umgestellt.`,switchNothing:`Nichts umzustellen: Der Text verwendet bereits {{format}}.`,switchDisabled:`Das Wechseln der Gender-Form ist für dieses Konto ausgeschaltet.`,switchUnsupported:`Der Server unterstützt das Wechseln der Gender-Form noch nicht.`,switchInklusivum:`In das Inklusivum kann noch nicht gewechselt werden.`},[eb.options]:{languageHeadline:`Sprache und Gender-Formen`,genderedRolesFormat:`Generisches Maskulinum`,genderedRolesFormatHint:`Wie soll Witty mit dem generischen Maskulinum in gegenderten Sprachen umgehen?`,germanGenderEnding:`Deutsche Gender-Endung`,germanGenderEndingHint:`Witty empfiehlt den Gendestern.`,frenchGenderSeparator:`Französisches Gender-Trennzeichen`,frenchGenderSeparatorHint:`Witty empfiehlt den Point médian.`,useApiDefault:`Standard des Servers`,levelOff:`Aus`,levelBasic:`Basis`,levelAdvanced:`Erweitert`,levelLocked:`Immer aktiv`,categoriesFailed:`Kategorien konnten nicht geladen werden.`,helpOwnServer:`Eigenen Server einrichten`,helpWithoutDashboard:`Witty ohne Dashboard betreiben`,helpCentre:`Hilfe-Center`,settingsHeadline:`Witty Einstellungen`,connectionHeadline:`Verbindung`,modeAccount:`Konto (Anmeldung über Dashboard)`,modeApiKey:`API-Schlüssel (ohne Dashboard)`,apiKey:`API-Schlüssel`,apiKeyHint:`Wird als x-key an die NLP-API gesendet. Ein Dashboard wird nicht benötigt.`,apiKeyRequired:`API-Schlüssel ist erforderlich.`,customisationHeadline:`Anpassungen`,orthography:`Rechtschreibprüfung`,llmAlternatives:`KI-Vorschläge`,categoriesHeadline:`Kategorien`,categoriesIntro:`Abgewählte Kategorien werden nicht mehr hervorgehoben.`,orgOverrideNote:`Im Konto-Modus können diese Werte von den Vorgaben deiner Organisation überschrieben werden.`,endpointHeadline:`Eigener Server`,endpointIntro:`Zeigt Witty auf deine eigene Installation. Nur ändern, wenn du weisst, was du tust.`,endpointWarning:`Achtung: Der eingetragene Server erhält jeden Text, den du in Eingabefeldern schreibst. Trage nur eine Installation ein, der du vertraust.`,dashboardUrl:`Dashboard-URL`,apiUrl:`NLP-API-URL`,oauthClientId:`OAuth Client ID`,redirectUriHint:`Registriere diese Redirect-URI im OAuth-Client deines Dashboards:`,save:`Speichern und abmelden`,reset:`Auf Standard zurücksetzen`,saved:`Gespeichert. Du wurdest abgemeldet — bitte erneut anmelden.`,resetDone:`Auf Standard zurückgesetzt. Du wurdest abgemeldet.`,invalidUrl:`Bitte eine https-URL angeben (http nur für localhost).`,clientIdRequired:`OAuth Client ID ist erforderlich.`,signOutNotice:`Beim Wechsel des Servers wirst du abgemeldet: Tokens gelten immer nur für einen Server.`,currentEndpoint:`Aktuell verwendet`},[eb.common]:{buttons:{ok:`Akzeptieren`,cancel:`Abbrechen`},languages:{en_US:`Englisch (🇺🇸 USA)`,en_GB:`Englisch (🇬🇧 Vereinigtes Königreich)`,de_DE:`Deutsch (🇩🇪 Deutschland)`,de_AT:`Deutsch (🇦🇹 Österreich)`,de_CH:`Deutsch (🇨🇭 Schweiz)`,fr_FR:`Französisch (🇫🇷 Frankreich)`,fr_CH:`Französisch (🇨🇭 Schweiz)`}},[eb.pages.popup]:{helpCentre:`Hilfe-Center`,helpSignInFailed:`Hilfe zur Fehlersuche`,extensionSettings:`Erweiterungseinstellungen`,extensionSettingsHint:`Eigener Server, API-Schlüssel und Kategorien`,enableWitty:`Witty aktivieren`,websiteSettings:`Einstellungen für {{domain}}`,developmentSettings:`Entwicklungs-Einstellungen`,spellChecking:`Grammatik & Rechtschreibung`,thanks:`Danke für deinen Beitrag!`,noSupport:`Es tut uns leid! Witty unterstützt diese Webseite noch nicht offiziell.`,vote:`Stimme für diese Webseite ab`,editor:`Nutze stattdessen den Witty Editor`,goToDashboard:`Zum Witty Editor`,overrideRecomendedSites:`Witty hier dennoch aktivieren`,backToRecomendedSites:`Witty nur auf unterstützten Webseiten aktiv`,signedOutText:`Dir entgeht was`,loginToUnlock:`Jetzt anmelden!`,biasDetection:`Erkennung von über 30 Diversitätskategorieren`,inclusiveAlternatives:`Inklusive Alternativvorschläge`,teamFeatures:`Teamfunktionen, inkl. eines geteilten Wörterbuches`,signIn:`Anmelden`,signOut:`Abmelden`,haveAccount:`Hast du schon ein Konto?`,dontHaveAccount:`Hast du noch kein Konto?`,signUp:`Registrieren`,doesWittyWork:`Funktioniert Witty hier?`,doesWittyWorkExplanation:`Lass es uns wissen.`,tryAgain:`Erneut versuchen`,understood:`Verstanden`,websiteSettingsDeactivated:`Du hast uns mitgeteilt, dass Witty auf {{Domain}} nicht funktioniert.`,tryAgainOnThisWebsite:`Erneut auf dieser Website versuchen`,enableWittyFailed:`Currently unable to sync with the Witty Dashboard, try again later.`,lockedInfo:`Diese Funktion wurde von deiner*m Team-Admin gesetzt.`,loggedInTo:`Logged in to`,popupsBlocked:`Popups sind blockiert`,popupsBlockedText:`Um dich anzumelden, kopiere bitte den Link in die Adressleiste deines Browsers.`,copyLink:`Link kopieren`,copiedConfirmation:`URL Kopiert`,signInFailed:`Anmeldung fehlgeschlagen`,signInFailedText:`Die Anmeldung konnte nicht abgeschlossen werden. Bitte versuche es erneut.`,hrFeatures:`Job Ads Add-On`,beta:`Beta`,apiKeyConfiguredNotice:`API Key konfiguriert — keine Anmeldung erforderlich.`,apiKeyAuthFailed:`API Key Authentifizierung fehlgeschlagen ({{status}}): {{message}} — überprüfe den API Key oder Endpunkt.`},[eb.popover]:{insteadTry:`Wie wär's mit ...`,learnMore:`Warum`,leanrMoreExtendedText:`Warum das so ist`,ignoreTerm:`Weniger unterstreichen?`,visitSource:`Quelle`,alertOftotal:`von`,removeSpaces:`Extra Leerzeichen entfernen`,loginToUnlock:`Jetzt anmelden!`,signedOutText:`Dir entgeht was`,biasDetection:`Erkennung von über 30 Diversitätskategorieren`,inclusiveAlternatives:`Inklusive Alternativvorschläge`,teamFeatures:`Teamfunktionen, inkl. eines geteilten Wörterbuches`,signIn:`Anmelden`,haveAccount:`Hast du schon ein Konto?`,dontHaveAccount:`Hast du noch kein Konto?`,signUp:`Registrieren`,popupsBlocked:`Popups sind blockiert`,popupsBlockedText:`Um dich anzumelden, kopiere bitte den Link in die Adressleiste deines Browsers.`,copyLink:`Link kopieren`,copiedConfirmation:`URL Kopiert`,signInFailed:`Anmeldung fehlgeschlagen`,signInFailedText:`Die Anmeldung konnte nicht abgeschlossen werden. Bitte versuche es erneut.`,missingOut:`Du verpasst etwas`,bulletPointOne:`Warum ein Begriff unterstrichen wird`,bulletPointTwo:`Inklusive Alternativen`,inclusiveBulletPointOne:`Warum dieser Begriff inklusiv ist`,inclusiveBulletPointTwo:`Weitere inklusive Begriffe`,wittyLogo:`Witty`,new:`neu`,video:`Ein Erklärungsvideo ist verfügbar`,openNewWindow:`Öffnet in einem neuen Fenster`,next:`Nächstes Ergebnis`,previous:`Vorheriges Ergebnis`,close:`Witty schliessen`,suggestionsDialog:`Witty Vorschläge`,removeText:`Entfernen:`,ignoreOnce:`Einmal ignorieren`,ignorePermanently:`Für immer ignorieren`,failedRequestText:`Bitte erneut probieren`,apiKeyConfiguredNotice:`API Key konfiguriert — keine Anmeldung erforderlich.`,lockedByAdmin:``},[eb.iconController]:{totalMaxCharLengthReachedNotificationHeadline:`Lange Texte`,totalMaxCharLengthReachedNotificationText:`Witty prüft {{limit}} Zeichen auf einmal. Dein Text hat {{total}} Zeichen — markiere weitere Abschnitte, um sie zu prüfen.`},[eb.notifications]:{pinNotificationHeadline:`Pin Witty`,pinNotificationText:`Bitte Witty an die Symbolleiste pinnen.`,totalMaxCharLengthReachedNotificationHeadline:`Lange Texte`,totalMaxCharLengthReachedNotificationText:`Witty prüft {{limit}} Zeichen auf einmal. Dein Text hat {{total}} Zeichen — markiere weitere Abschnitte, um sie zu prüfen.`,updateNotificationHeadline:`Witty wurde aktualisiert`,updateNotificationText:`Witty wurde auf die neuste Version aktualisiert.`,updateNotificationButton:`Änderungen`,minVersionNotInstalledNotificationHeadline:`Du must Witty aktualisieren`,minVersionNotInstalledNotificationText:`Um Witty weiterhin nutzen zu können, müsst Du Witty auf eine neuere Version aktualisieren.`,minVersionNotInstalledNotificationButton:`Aktualisieren`}},rb={[eb.editor]:{toolbar:`Formatting`,bold:`Bold`,italic:`Italic`,underline:`Underline`,heading:`Heading`,bulletList:`Bulleted list`,orderedList:`Numbered list`,quote:`Quote`,undo:`Undo`,redo:`Redo`,settings:`Witty settings`,closeSettings:`Close settings`,settingsLoading:`Loading settings…`,statusChecking:`Witty is checking the text…`,statusAlerts_one:`{{count}} suggestion`,statusAlerts_other:`{{count}} suggestions`,statusNoAlerts:`No suggestions`,statusUnauthorized:`API key missing or not accepted`,statusFailed:`Checking failed`,shortcutHint:`Press Alt+Shift+W to open the suggestion at the cursor.`,limitReached:`Only part of this text was checked.`,menu:`Witty menu`,menuSettings:`Settings…`,menuSwitchGender:`Switch gender format…`,menuHelp:`Help`,menuAbout:`About Witty`,switchTitle:`Switch gender format`,switchIntro:`Rewrites every gendered form in the text into the format you choose. Undo reverses it in one step.`,switchCurrent:`current`,switching:`Checking and rewriting the text…`,switched_one:`Switched {{count}} form to {{format}}.`,switched_other:`Switched {{count}} forms to {{format}}.`,switchNothing:`Nothing to switch: the text already uses {{format}}.`,switchDisabled:`Switching the gender format is turned off for this account.`,switchUnsupported:`The server doesn't support switching the gender format yet.`,switchInklusivum:`Switching to the Inklusivum isn't available yet.`},[eb.options]:{languageHeadline:`Language and gender forms`,genderedRolesFormat:`Generic masculine`,genderedRolesFormatHint:`How should Witty handle the generic masculine in gendered languages like German or French?`,germanGenderEnding:`German gender ending`,germanGenderEndingHint:`Witty recommends the genderstar.`,frenchGenderSeparator:`French gender separator`,frenchGenderSeparatorHint:`Witty recommends the point médian.`,useApiDefault:`Server default`,levelOff:`Off`,levelBasic:`Basic`,levelAdvanced:`Advanced`,levelLocked:`Always on`,categoriesFailed:`Could not load categories.`,helpOwnServer:`Connect Witty to your own server`,helpWithoutDashboard:`Run Witty without the dashboard`,helpCentre:`Help Center`,settingsHeadline:`Witty settings`,connectionHeadline:`Connection`,modeAccount:`Account (sign in via dashboard)`,modeApiKey:`API key (no dashboard)`,apiKey:`API key`,apiKeyHint:`Sent as x-key to the NLP API. No dashboard required.`,apiKeyRequired:`An API key is required.`,customisationHeadline:`Customisation`,orthography:`Spell checking`,llmAlternatives:`AI suggestions`,categoriesHeadline:`Categories`,categoriesIntro:`Categories you switch off are no longer highlighted.`,orgOverrideNote:`In account mode your organisation settings may override these.`,endpointHeadline:`Custom server`,endpointIntro:`Point Witty at your own deployment. Only change this if you know what you are doing.`,endpointWarning:`Warning: the server you enter receives every text you write in input fields. Only enter a deployment you trust.`,dashboardUrl:`Dashboard URL`,apiUrl:`NLP API URL`,oauthClientId:`OAuth client ID`,redirectUriHint:`Register this redirect URI on your dashboard OAuth client:`,save:`Save and sign out`,reset:`Reset to default`,saved:`Saved. You have been signed out — please sign in again.`,resetDone:`Reset to default. You have been signed out.`,invalidUrl:`Enter an https URL (http is allowed for localhost only).`,clientIdRequired:`OAuth client ID is required.`,signOutNotice:`Changing server signs you out: tokens are only ever valid for one server.`,currentEndpoint:`Currently using`},[eb.common]:{buttons:{ok:`Ok`,cancel:`Cancel`},languages:{en_GB:`English (🇬🇧 Great Britain)`,en_US:`English (🇺🇸 USA)`,de_DE:`German (🇩🇪 Germany)`,de_AT:`German (🇦🇹 Austrian)`,de_CH:`German (🇨🇭 Switzerland)`,fr_FR:`French (🇫🇷 France)`,fr_CH:`French (🇨🇭 Switzerland)`}},[eb.pages.popup]:{helpCentre:`Help Center`,helpSignInFailed:`Troubleshooting help`,extensionSettings:`Extension settings`,extensionSettingsHint:`Custom server, API key and categories`,enableWitty:`Enable Witty`,websiteSettings:`Settings for {{domain}}`,developmentSettings:`Development Settings`,spellChecking:`Check grammar & spelling`,thanks:`Thanks for your feedback!`,noSupport:`We’re sorry! Witty doesn’t yet officially support this website.`,vote:`Vote for this website`,editor:`Use the Witty Editor instead`,goToDashboard:`Go to Witty Editor`,overrideRecomendedSites:`Try Witty here anyway`,backToRecomendedSites:`Use Witty only on supported websites`,loginToUnlock:`Log in now!`,signedOutText:`You are missing out`,biasDetection:`Bias detection in 30+ diversity dimensions`,inclusiveAlternatives:`Alternatives for inclusive writing`,teamFeatures:`Team features, incl. shared dictionaries`,signIn:`Sign In`,signOut:`Sign out`,haveAccount:`Already have an account?`,dontHaveAccount:`Don’t have an account?`,signUp:`Sign up`,doesWittyWork:`Does Witty work here?`,doesWittyWorkExplanation:`Please help us to find out.`,tryAgain:`Try again`,understood:`Understood`,websiteSettingsDeactivated:`You reported that Witty does not work on {{domain}}`,tryAgainOnThisWebsite:`Try again on this website`,enableWittyFailed:`Die Synchronisierung mit Witty Dashboard ist aktuell nicht möglich, versuchen Sie es später noch einmal.`,lockedInfo:`This feature has been locked by your team admin.`,loggedInTo:`Logged in to`,popupsBlocked:`Popups are blocked`,popupsBlockedText:`To log in, please copy and paste the link into your browser's URL bar.`,copyLink:`Copy Link`,copiedConfirmation:`link Copied`,signInFailed:`Sign-in failed`,signInFailedText:`We could not complete the sign-in. Please try again.`,hrFeatures:`Job Ads Add-On`,beta:`Beta`,apiKeyConfiguredNotice:`API key configured — no sign-in required.`,apiKeyAuthFailed:`API key authentication failed ({{status}}): {{message}} — check your API key or endpoint.`},[eb.popover]:{insteadTry:`Try instead ...`,learnMore:`Why`,leanrMoreExtendedText:`Dig deeper`,ignoreTerm:`Highlight less?`,visitSource:`Source`,alertOftotal:`of`,removeSpaces:`(Remove extra spaces)`,loginToUnlock:`Log in now!`,signedOutText:`You are missing out`,biasDetection:`Bias detection in 30+ diversity dimensions`,inclusiveAlternatives:`Alternatives for inclusive writing`,teamFeatures:`Team features, incl. shared dictionaries`,signIn:`Sign In`,haveAccount:`Already have an account?`,dontHaveAccount:`Don’t have an account?`,signUp:`Sign up`,popupsBlocked:`Popups are blocked`,popupsBlockedText:`Please copy and paste the link into your browser URL bar.`,copyLink:`Copy Link`,copiedConfirmation:`link Copied`,signInFailed:`Sign-in failed`,signInFailedText:`We could not complete the sign-in. Please try again.`,missingOut:`You are missing out`,bulletPointOne:`Why this term is biased`,bulletPointTwo:`Inclusive alternatives for this term`,inclusiveBulletPointOne:`Why this term is inclusive`,inclusiveBulletPointTwo:`More inclusive terms`,wittyLogo:`Witty`,new:`new`,video:`A video is available for more learning`,openNewWindow:`Opens in a new window`,next:`Next result`,previous:`Previous result`,close:`Close Witty`,suggestionsDialog:`Witty suggestions`,removeText:`Remove:`,ignoreOnce:`Ignore once`,ignorePermanently:`Ignore permanently`,failedRequestText:`Failed, please try again`,apiKeyConfiguredNotice:`API key configured — no sign-in required.`,lockedByAdmin:``},[eb.errors]:{errorMessageGenericTitle:`Ouch! Something went wrong!`,reloadWebsite:`Please reload the website`},[eb.iconController]:{totalMaxCharLengthReachedNotificationHeadline:`Long texts`,totalMaxCharLengthReachedNotificationText:`Witty checks {{limit}} characters at a time. Your text has {{total}} characters — select further sections to check them.`},[eb.notifications]:{pinNotificationHeadline:`Pin Witty`,pinNotificationText:`Remember to pin Witty to your browser toolbar.`,totalMaxCharLengthReachedNotificationHeadline:`Long texts`,totalMaxCharLengthReachedNotificationText:`Witty checks {{limit}} characters at a time. Your text has {{total}} characters — select further sections to check them.`,updateNotificationHeadline:`Witty was updated`,updateNotificationText:`Witty was updated to the latest version.`,updateNotificationButton:`View changes`,minVersionNotInstalledNotificationHeadline:`You need to update Witty`,minVersionNotInstalledNotificationText:`In order to continue using Witty, you need to update Witty to a newer version.`,minVersionNotInstalledNotificationButton:`How to update`}},ib={[eb.editor]:{toolbar:`Mise en forme`,bold:`Gras`,italic:`Italique`,underline:`Souligné`,heading:`Titre`,bulletList:`Liste à puces`,orderedList:`Liste numérotée`,quote:`Citation`,undo:`Annuler`,redo:`Rétablir`,settings:`Paramètres Witty`,closeSettings:`Fermer les paramètres`,settingsLoading:`Chargement des paramètres…`,statusChecking:`Witty vérifie le texte…`,statusAlerts_one:`{{count}} suggestion`,statusAlerts_other:`{{count}} suggestions`,statusNoAlerts:`Aucune suggestion`,statusUnauthorized:`Clé API manquante ou refusée`,statusFailed:`La vérification a échoué`,shortcutHint:`Appuyez sur Alt+Maj+W pour ouvrir la suggestion à la position du curseur.`,limitReached:`Seule une partie de ce texte a été vérifiée.`,menu:`Menu Witty`,menuSettings:`Paramètres…`,menuSwitchGender:`Changer la forme inclusive…`,menuHelp:`Aide`,menuAbout:`À propos de Witty`,switchTitle:`Changer la forme inclusive`,switchIntro:`Réécrit toutes les formes genrées du texte dans la forme choisie. Annuler rétablit le texte en une seule étape.`,switchCurrent:`actuelle`,switching:`Vérification et réécriture du texte…`,switched_one:`{{count}} forme passée en {{format}}.`,switched_other:`{{count}} formes passées en {{format}}.`,switchNothing:`Rien à changer : le texte utilise déjà {{format}}.`,switchDisabled:`Le changement de forme inclusive est désactivé pour ce compte.`,switchUnsupported:`Le serveur ne permet pas encore de changer la forme inclusive.`,switchInklusivum:`Le passage à l'Inklusivum n'est pas encore disponible.`},[eb.options]:{languageHeadline:`Langue et formes de genre`,genderedRolesFormat:`Masculin générique`,genderedRolesFormatHint:`Comment Witty doit-il traiter le masculin générique dans les langues genrées ?`,germanGenderEnding:`Terminaison de genre allemande`,germanGenderEndingHint:`Witty recommande le genderstar.`,frenchGenderSeparator:`Séparateur de genre français`,frenchGenderSeparatorHint:`Witty recommande le point médian.`,useApiDefault:`Valeur par défaut du serveur`,levelOff:`Désactivé`,levelBasic:`Base`,levelAdvanced:`Avancé`,levelLocked:`Toujours actif`,categoriesFailed:`Impossible de charger les catégories.`,helpOwnServer:`Connecter Witty à votre propre serveur`,helpWithoutDashboard:`Utiliser Witty sans tableau de bord`,helpCentre:`Centre d’aide`,settingsHeadline:`Paramètres Witty`,connectionHeadline:`Connexion`,modeAccount:`Compte (connexion via le tableau de bord)`,modeApiKey:`Clé API (sans tableau de bord)`,apiKey:`Clé API`,apiKeyHint:`Envoyée comme x-key à l'API NLP. Aucun tableau de bord requis.`,apiKeyRequired:`Une clé API est requise.`,customisationHeadline:`Personnalisation`,orthography:`Correction orthographique`,llmAlternatives:`Suggestions IA`,categoriesHeadline:`Catégories`,categoriesIntro:`Les catégories désactivées ne sont plus mises en évidence.`,orgOverrideNote:`En mode compte, les paramètres de votre organisation peuvent les remplacer.`,endpointHeadline:`Serveur personnalisé`,endpointIntro:`Pointez Witty vers votre propre installation. Ne modifiez ceci que si vous savez ce que vous faites.`,endpointWarning:`Attention : le serveur indiqué reçoit tout texte que vous saisissez dans les champs. N'indiquez qu'une installation de confiance.`,dashboardUrl:`URL du tableau de bord`,apiUrl:`URL de l'API NLP`,oauthClientId:`ID client OAuth`,redirectUriHint:`Enregistrez cette URI de redirection sur le client OAuth de votre tableau de bord :`,save:`Enregistrer et se déconnecter`,reset:`Réinitialiser`,saved:`Enregistré. Vous avez été déconnecté·e — veuillez vous reconnecter.`,resetDone:`Réinitialisé. Vous avez été déconnecté·e.`,invalidUrl:`Indiquez une URL https (http uniquement pour localhost).`,clientIdRequired:`L'ID client OAuth est requis.`,signOutNotice:`Changer de serveur vous déconnecte : les jetons ne sont valables que pour un seul serveur.`,currentEndpoint:`Actuellement utilisé`},[eb.common]:{buttons:{ok:`Ok`,cancel:`Annuler`},languages:{en_US:`Anglais (🇺🇸 USA)`,en_GB:`Anglais (🇬🇧 Royaume-Uni)`,de_DE:`Allemand (🇩🇪 Allemagne)`,de_AT:`Allemand (🇦🇹 Autriche)`,de_CH:`Allemand (🇨🇭 Suisse)`,fr_FR:`Français (🇫🇷 France)`,fr_CH:`Français (🇨🇭 Suisse)`}},[eb.pages.popup]:{helpCentre:`Centre d’aide`,helpSignInFailed:`Aide au dépannage`,extensionSettings:`Paramètres de l’extension`,extensionSettingsHint:`Serveur personnalisé, clé API et catégories`,enableWitty:`Activer Witty`,websiteSettings:`Paramètres pour {{domain}}`,developmentSettings:`Paramètres de développement`,spellChecking:`Vérifier la grammaire et l'orthographe`,thanks:`Merci pour votre retour !`,noSupport:`Nous sommes désolés ! Witty ne prend pas encore officiellement en charge ce site web.`,vote:`Votez pour ce site web`,editor:`Utiliser l'éditeur Witty à la place`,goToDashboard:`Aller à l'éditeur Witty`,overrideRecomendedSites:`Essayer Witty ici quand même`,backToRecomendedSites:`Utiliser Witty uniquement sur les sites pris en charge`,loginToUnlock:`Connectez-vous maintenant !`,signedOutText:`Vous manquez quelque chose`,biasDetection:`Détection des biais dans plus de 30 dimensions de diversité`,inclusiveAlternatives:`Alternatives pour une écriture inclusive`,teamFeatures:`Fonctionnalités d'équipe, y compris des dictionnaires partagés`,signIn:`Se connecter`,signOut:`Se déconnecter`,haveAccount:`Vous avez déjà un compte ?`,dontHaveAccount:`Vous n'avez pas de compte ?`,signUp:`S'inscrire`,doesWittyWork:`Witty fonctionne-t-il ici ?`,doesWittyWorkExplanation:`Aidez-nous à le découvrir, s'il vous plaît.`,tryAgain:`Réessayer`,understood:`Compris`,websiteSettingsDeactivated:`Vous avez signalé que Witty ne fonctionne pas sur {{domain}}`,tryAgainOnThisWebsite:`Réessayez sur ce site web`,enableWittyFailed:`La synchronisation avec le tableau de bord Witty est actuellement impossible, veuillez réessayer plus tard.`,lockedInfo:`Cette fonctionnalité a été verrouillée par votre·e administrateur·trice d'équipe.`,loggedInTo:`Connecté·e à`,popupsBlocked:`Les pop-ups sont bloqués`,popupsBlockedText:`Pour vous connecter, veuillez copier et coller le lien dans la barre d'URL de votre navigateur.`,copyLink:`Copier le lien`,copiedConfirmation:`Lien copié`,signInFailed:`Échec de la connexion`,signInFailedText:`La connexion n'a pas pu aboutir. Veuillez réessayer.`,hrFeatures:`Add-on pour les offres d'emploi`,beta:`Bêta`,apiKeyConfiguredNotice:`Clé API configurée — aucune connexion requise.`,apiKeyAuthFailed:`Échec de l'authentification de la clé API ({{status}}) : {{message}} — vérifiez votre clé API ou le point de terminaison.`},[eb.popover]:{insteadTry:`Essayez plutôt ...`,learnMore:`Pourquoi`,leanrMoreExtendedText:`En savoir plus`,ignoreTerm:`Mettre moins en évidence ?`,visitSource:`Source`,alertOftotal:`de`,removeSpaces:`(Retirer les espaces supplémentaires)`,loginToUnlock:`Connectez-vous maintenant !`,signedOutText:`Vous manquez quelque chose`,biasDetection:`Détection des biais dans plus de 30 dimensions de diversité`,inclusiveAlternatives:`Alternatives pour une écriture inclusive`,teamFeatures:`Fonctionnalités d'équipe, y compris des dictionnaires partagés`,signIn:`Se connecter`,haveAccount:`Vous avez déjà un compte ?`,dontHaveAccount:`Vous n'avez pas de compte ?`,signUp:`S'inscrire`,popupsBlocked:`Les pop-ups sont bloqués`,popupsBlockedText:`Veuillez copier et coller le lien dans la barre d'URL de votre navigateur.`,copyLink:`Copier le lien`,copiedConfirmation:`Lien copié`,signInFailed:`Échec de la connexion`,signInFailedText:`La connexion n'a pas pu aboutir. Veuillez réessayer.`,missingOut:`Vous manquez quelque chose`,bulletPointOne:`Pourquoi ce terme est biaisé`,bulletPointTwo:`Alternatives inclusives pour ce terme`,inclusiveBulletPointOne:`Pourquoi ce terme est inclusif`,inclusiveBulletPointTwo:`Termes plus inclusifs`,wittyLogo:`Witty`,new:`nouveau·elle`,video:`Une vidéo d'explication est disponible`,openNewWindow:`Ouverture dans une nouvelle fenêtre`,next:`Résultat suivant`,previous:`Résultat précédent`,close:`Fermer Witty`,suggestionsDialog:`Suggestions Witty`,removeText:`Supprimer :`,ignoreOnce:`Ignorer une fois`,ignorePermanently:`Ignorer définitivement`,failedRequestText:`Échec, veuillez réessayer`,apiKeyConfiguredNotice:`Clé API configurée — aucune connexion requise.`,lockedByAdmin:``},[eb.errors]:{errorMessageGenericTitle:`Oups ! Quelque chose a mal tourné !`,reloadWebsite:`Veuillez recharger le site web`},[eb.iconController]:{totalMaxCharLengthReachedNotificationHeadline:`Textes longs`,totalMaxCharLengthReachedNotificationText:`Witty vérifie {{limit}} caractères à la fois. Votre texte compte {{total}} caractères — sélectionnez d'autres sections pour les vérifier.`},[eb.notifications]:{pinNotificationHeadline:`Épingler Witty`,pinNotificationText:`N'oubliez pas d'épingler Witty dans la barre d'outils de votre navigateur.`,totalMaxCharLengthReachedNotificationHeadline:`Textes longs`,totalMaxCharLengthReachedNotificationText:`Witty vérifie {{limit}} caractères à la fois. Votre texte compte {{total}} caractères — sélectionnez d'autres sections pour les vérifier.`,updateNotificationHeadline:`Witty a été mis à jour`,updateNotificationText:`Witty a été mis à jour vers la dernière version.`,updateNotificationButton:`Voir les changements`,minVersionNotInstalledNotificationHeadline:`Vous devez mettre à jour Witty`,minVersionNotInstalledNotificationText:`Pour continuer à utiliser Witty, vous devez mettre à jour Witty vers une version plus récente.`,minVersionNotInstalledNotificationButton:`Comment mettre à jour`}},ab={[tb.en]:rb,[tb.de]:nb,[tb.fr]:ib};delete ab.fr;var ob=()=>{ty.isInitialized||ty.use($y).use(Sy).init({detection:{order:[`navigator`]},resources:ab,fallbackLng:`en`})},sb=`v2.4/check`,cb=`v1.0/rephrase`,lb=`v2.0/config-options`,ub=e=>`v2.0/categories?locale=${encodeURIComponent(e)}`,db={Accept:`application/json`,"Content-Type":`application/json`},fb=e=>e.apiKey?{"x-key":e.apiKey}:e.token?{Authorization:`Bearer ${e.token}`}:{},pb=e=>{let{text:t,lang:n=`auto`,id:r,client:i,config:a}=e;return{text:t,lang:n,id:r,client:i,...a===void 0?{}:{config:a},...e.configHash===void 0?{}:{config_hash:e.configHash},...e.organizationConfigHash===void 0?{}:{organization_config_hash:e.organizationConfigHash}}},mb=(e,t)=>({sentence:e.raw,text:t.data.text,start:t.absOffset-e.range[0],gender_separator:t.data.gender_separator,alternatives:t.data.alternatives.filter(e=>!e.remove),lang:t.data.language||`en`}),hb=3e3,gb=e=>{if(!e)return;let t=Object.entries(e).filter(([,e])=>e!==void 0);return t.length?Object.fromEntries(t):void 0},_b=(e,t)=>{if(e?.startsWith(`de`))return t?.german_gender_ending;if(e?.startsWith(`fr`))return t?.french_gender_separator},vb=class extends Error{status;constructor(e,t){super(`check failed: HTTP ${e}${t?`: ${t}`:``}`),this.status=e,this.name=`CheckHttpError`}},yb=async e=>{try{let{detail:t}=await e.json();if(typeof t==`string`)return t;if(Array.isArray(t))return t.map(({loc:e,msg:t})=>[e?.slice(1).join(`.`),t].filter(Boolean).join(`: `)).join(`; `)}catch{}},bb=({endpoint:e,headers:t,lang:n=`auto`,client:r=`witty-editor:${X_}`,id:i=`witty-editor`,config:a})=>async(o,s)=>{let c=gb(a?.()),l=await fetch(`${e}${sb}`,{method:`POST`,signal:s,headers:{...db,...t?await t():{}},body:JSON.stringify(pb({text:o,lang:n,id:i,client:r,config:c}))});if(!l.ok)throw new vb(l.status,await yb(l));return await l.json()};function xb(e){if(e.type===`Sentence`)return e;if(`children`in e&&Array.isArray(e.children))return e.children.find(e=>e.type===`Sentence`)}var Sb=(e,t,n,r)=>`${e}-${t}-${n}-${r}`,Cb=(e,t)=>{if(e===` `)return{text:``,scope:`alert`};let n=e.replace(/\(\(/g,`[`).replace(/\)\)/g,`]`),r=t?.get(n);return r?{text:r,scope:`sentence`}:{text:n,scope:`alert`}},wb;(function(e){e.Document=`Document`,e.DocumentExit=`Document:exit`,e.Paragraph=`Paragraph`,e.ParagraphExit=`Paragraph:exit`,e.BlockQuote=`BlockQuote`,e.BlockQuoteExit=`BlockQuote:exit`,e.ListItem=`ListItem`,e.ListItemExit=`ListItem:exit`,e.List=`List`,e.ListExit=`List:exit`,e.Header=`Header`,e.HeaderExit=`Header:exit`,e.CodeBlock=`CodeBlock`,e.CodeBlockExit=`CodeBlock:exit`,e.HtmlBlock=`HtmlBlock`,e.HtmlBlockExit=`HtmlBlock:exit`,e.HorizontalRule=`HorizontalRule`,e.HorizontalRuleExit=`HorizontalRule:exit`,e.Comment=`Comment`,e.CommentExit=`Comment:exit`,e.ReferenceDef=`ReferenceDef`,e.ReferenceDefExit=`ReferenceDef:exit`,e.Str=`Str`,e.StrExit=`Str:exit`,e.Break=`Break`,e.BreakExit=`Break:exit`,e.Emphasis=`Emphasis`,e.EmphasisExit=`Emphasis:exit`,e.Strong=`Strong`,e.StrongExit=`Strong:exit`,e.Html=`Html`,e.HtmlExit=`Html:exit`,e.Link=`Link`,e.LinkExit=`Link:exit`,e.Image=`Image`,e.ImageExit=`Image:exit`,e.Code=`Code`,e.CodeExit=`Code:exit`,e.Delete=`Delete`,e.DeleteExit=`Delete:exit`,e.Table=`Table`,e.TableExit=`Table:exit`,e.TableRow=`TableRow`,e.TableRowExit=`TableRow:exit`,e.TableCell=`TableCell`,e.TableCellExit=`TableCell:exit`})(wb||={});var Tb=c((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.binarySearch=e.upperBound=e.lowerBound=e.compare=void 0;function t(e,t){return e<t}e.compare=t;function n(e,n,r=t){let i=e.length,a=0;for(;i;){let t=i>>>1,o=a+t;r(n,e[o])?i=t:(a=o+1,i-=t+1)}return a}e.upperBound=n;function r(e,n,r=t){let i=e.length,a=0;for(;i;){let t=i>>>1,o=a+t;r(e[o],n)?(a=o+1,i-=t+1):i=t}return a}e.lowerBound=r;function i(e,n,i=t){let a=r(e,n,i);return a!==e.length&&!i(n,e[a])}e.binarySearch=i})),Eb=c((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.StructuredSource=void 0;var t=Tb();e.StructuredSource=class{constructor(e){this.indice=[0];let t=/[\r\n\u2028\u2029]/g,n=e.length;for(t.lastIndex=0;;){let r=t.exec(e);if(!r)break;let i=r.index;e.charCodeAt(i)===13&&e.charCodeAt(i+1)===10&&(i+=1);let a=i+1;if(n<a)break;this.indice.push(a),t.lastIndex=a}}get line(){return this.indice.length}locationToRange(e){return[this.positionToIndex(e.start),this.positionToIndex(e.end)]}rangeToLocation(e){return{start:this.indexToPosition(e[0]),end:this.indexToPosition(e[1])}}positionToIndex(e){return this.indice[e.line-1]+e.column}indexToPosition(e){let n=(0,t.upperBound)(this.indice,e);return{line:n,column:e-this.indice[n-1]}}}}))(),Db=(e,t)=>{for(let n=e.length-1;n>=0;n--)if(t(e[n],n,e))return n;return-1},Ob=class{index=0;source;textCharacters;sourceNode;contexts=[];consumedContexts=[];contextRanges=[];firstChildPadding;startOffset;constructor(e){if(typeof e==`string`)this.textCharacters=e.split(``),this.source=new Eb.StructuredSource(e),this.startOffset=0,this.firstChildPadding=0;else{this.sourceNode=e,this.startOffset=this.sourceNode.range[0],this.index=this.startOffset;let t=Array.from(Array(this.sourceNode.loc.start.line-1)).fill(`
131
+ `):``,markdownTokenizer:{name:`taskList`,level:`block`,start(e){let t=e.match(/^\s*[-+*]\s+\[([ xX])\]\s+/)?.index;return t===void 0?-1:t},tokenize(e,t,n){let r=e=>{let t=Ld(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(t){let r={type:`taskList`,raw:t.raw,items:t.items},i=e.slice(t.raw.length);return i.trim()?[r,...n.blockTokens(i)]:[r]}return n.blockTokens(e)},i=Ld(e,{itemPattern:/^(\s*)([-+*])\s+\[([ xX])\]\s+(.*)$/,extractItemData:e=>({indentLevel:e[1].length,mainContent:e[4],checked:e[3].toLowerCase()===`x`}),createToken:(e,t)=>({type:`taskItem`,raw:``,mainContent:e.mainContent,indentLevel:e.indentLevel,checked:e.checked,text:e.mainContent,tokens:n.inlineTokens(e.mainContent),nestedTokens:t}),customNestedParser:r},n);if(i)return{type:`taskList`,raw:i.raw,items:i.items}}},markdownOptions:{indentsContent:!0},addCommands(){return{toggleTaskList:()=>({commands:e})=>e.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}});nf.create({name:`listKit`,addExtensions(){let e=[];return this.options.bulletList!==!1&&e.push(Ah.configure(this.options.bulletList)),this.options.listItem!==!1&&e.push($h.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(cg.configure(this.options.listKeymap)),this.options.orderedList!==!1&&e.push(Tg.configure(this.options.orderedList)),this.options.taskItem!==!1&&e.push(kg.configure(this.options.taskItem)),this.options.taskList!==!1&&e.push(Ag.configure(this.options.taskList)),e}});var jg=`&nbsp;`,Mg=`\xA0`,Ng=wf.create({name:`paragraph`,priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:`block`,content:`inline*`,parseHTML(){return[{tag:`p`}]},renderHTML({HTMLAttributes:e}){return[`p`,Ql(this.options.HTMLAttributes,e),0]},parseMarkdown:(e,t)=>{let n=e.tokens||[];if(n.length===1&&n[0].type===`image`)return t.parseChildren([n[0]]);let r=t.parseInline(n);return n.length===1&&n[0].type===`text`&&(n[0].raw===jg||n[0].text===jg||n[0].raw===Mg||n[0].text===Mg)&&r.length===1&&r[0].type===`text`&&(r[0].text===jg||r[0].text===Mg)?t.createNode(`paragraph`,void 0,[]):t.createNode(`paragraph`,void 0,r)},renderMarkdown:(e,t,n)=>{if(!e)return``;let r=Array.isArray(e.content)?e.content:[];if(r.length===0){var i,a;let e=Array.isArray(n==null||(i=n.previousNode)==null?void 0:i.content)?n.previousNode.content:[];return(n==null||(a=n.previousNode)==null?void 0:a.type)===`paragraph`&&e.length===0?jg:``}return t.renderChildren(r)},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),Pg=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,Fg=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,Ig=Jd.create({name:`strike`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`s`},{tag:`del`},{tag:`strike`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`line-through`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`s`,Ql(this.options.HTMLAttributes,e),0]},markdownTokenName:`del`,parseMarkdown:(e,t)=>t.applyMark(`strike`,t.parseInline(e.tokens||[])),renderMarkdown:(e,t)=>`~~${t.renderChildren(e)}~~`,addCommands(){return{setStrike:()=>({commands:e})=>e.setMark(this.name),toggleStrike:()=>({commands:e})=>e.toggleMark(this.name),unsetStrike:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[bf({find:Pg,type:this.type})]},addPasteRules(){return[Tf({find:Fg,type:this.type})]}}),Lg=wf.create({name:`text`,group:`inline`,parseMarkdown:e=>({type:`text`,text:e.text||``}),renderMarkdown:e=>e.text||``}),Rg=Jd.create({name:`underline`,addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:`u`},{style:`text-decoration`,consuming:!1,getAttrs:e=>e.includes(`underline`)?{}:!1}]},renderHTML({HTMLAttributes:e}){return[`u`,Ql(this.options.HTMLAttributes,e),0]},parseMarkdown(e,t){return t.applyMark(this.name||`underline`,t.parseInline(e.tokens||[]))},renderMarkdown(e,t){return`++${t.renderChildren(e)}++`},markdownTokenizer:{name:`underline`,level:`inline`,start(e){return e.indexOf(`++`)},tokenize(e,t,n){let r=/^(\+\+)([\s\S]+?)(\+\+)/.exec(e);if(!r)return;let i=r[2].trim();return{type:`underline`,raw:r[0],text:i,tokens:n.inlineTokens(i)}}},addCommands(){return{setUnderline:()=>({commands:e})=>e.setMark(this.name),toggleUnderline:()=>({commands:e})=>e.toggleMark(this.name),unsetUnderline:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}});function zg(e={}){return new Gn({view(t){return new Bg(t,e)}})}var Bg=class{constructor(e,t){this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.lastDragEvent=null,this.width=t.width??1,this.color=t.color===!1?void 0:t.color||`black`,this.class=t.class,this.handlers=[`dragover`,`dragend`,`drop`,`dragleave`].map(t=>{let n=e=>{this[t](e)};return e.dom.addEventListener(t,n),{name:t,handler:n}})}destroy(){this.handlers.forEach(({name:e,handler:t})=>this.editorView.dom.removeEventListener(e,t))}update(e,t){if(this.cursorPos!=null&&t.doc!=e.state.doc){if(this.lastDragEvent){let e=this.computeTarget(this.lastDragEvent);e==this.cursorPos?this.updateOverlay():this.setCursor(e)}else this.updateOverlay()}}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,e==null?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e=this.editorView.state.doc.resolve(this.cursorPos),t=!e.parent.inlineContent,n,r=this.editorView.dom,i=r.getBoundingClientRect(),a=i.width/r.offsetWidth,o=i.height/r.offsetHeight;if(t){let t=e.nodeBefore,r=e.nodeAfter;if(t||r){let e=this.editorView.nodeDOM(this.cursorPos-(t?t.nodeSize:0));if(e){let i=e.getBoundingClientRect(),a=t?i.bottom:i.top;t&&r&&(a=(a+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2);let s=this.width/2*o;n={left:i.left,right:i.right,top:a-s,bottom:a+s}}}}if(!n){let e=this.editorView.coordsAtPos(this.cursorPos),t=this.width/2*a;n={left:e.left-t,right:e.left+t,top:e.top,bottom:e.bottom}}let s=this.editorView.dom.offsetParent;this.element||(this.element=s.appendChild(document.createElement(`div`)),this.class&&(this.element.className=this.class),this.element.style.cssText=`position: absolute; z-index: 50; pointer-events: none;`,this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle(`prosemirror-dropcursor-block`,t),this.element.classList.toggle(`prosemirror-dropcursor-inline`,!t);let c,l;if(!s||s==document.body&&getComputedStyle(s).position==`static`)c=-pageXOffset,l=-pageYOffset;else{let e=s.getBoundingClientRect(),t=e.width/s.offsetWidth,n=e.height/s.offsetHeight;c=e.left-s.scrollLeft*t,l=e.top-s.scrollTop*n}this.element.style.left=(n.left-c)/a+`px`,this.element.style.top=(n.top-l)/o+`px`,this.element.style.width=(n.right-n.left)/a+`px`,this.element.style.height=(n.bottom-n.top)/o+`px`}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}computeTarget(e){let t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),n=t&&t.inside>=0&&this.editorView.state.doc.nodeAt(t.inside),r=n&&n.type.spec.disableDropCursor,i=typeof r==`function`?r(this.editorView,t,e):r;if(!t||i)return null;let a=t.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let e=rn(this.editorView.state.doc,a,this.editorView.dragging.slice);e!=null&&(a=e)}return a}dragover(e){if(!this.editorView.editable)return;this.lastDragEvent=e;let t=this.computeTarget(e);t!=null&&(this.setCursor(t),this.scheduleRemoval(5e3))}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)}},Vg=class e extends j{constructor(e){super(e,e)}map(t,n){let r=t.resolve(n.map(this.head));return e.valid(r)?new e(r):j.near(r)}content(){return E.empty}eq(t){return t instanceof e&&t.head==this.head}toJSON(){return{type:`gapcursor`,pos:this.head}}static fromJSON(t,n){if(typeof n.pos!=`number`)throw RangeError(`Invalid input for GapCursor.fromJSON`);return new e(t.resolve(n.pos))}getBookmark(){return new Hg(this.anchor)}static valid(e){let t=e.parent;if(t.inlineContent||!Wg(e)||!Gg(e))return!1;let n=t.type.spec.allowGapCursor;if(n!=null)return n;let r=t.contentMatchAt(e.index()).defaultType;return r&&r.isTextblock}static findGapCursorFrom(t,n,r=!1){search:for(;;){if(!r&&e.valid(t))return t;let i=t.pos,a=null;for(let r=t.depth;;r--){let o=t.node(r);if(n>0?t.indexAfter(r)<o.childCount:t.index(r)>0){a=o.child(n>0?t.indexAfter(r):t.index(r)-1);break}if(r==0)return null;i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}for(;;){let o=n>0?a.firstChild:a.lastChild;if(!o){if(a.isAtom&&!a.isText&&!N.isSelectable(a)){t=t.doc.resolve(i+a.nodeSize*n),r=!1;continue search}break}a=o,i+=n;let s=t.doc.resolve(i);if(e.valid(s))return s}return null}}};Vg.prototype.visible=!1,Vg.findFrom=Vg.findGapCursorFrom,j.jsonID(`gapcursor`,Vg);var Hg=class e{constructor(e){this.pos=e}map(t){return new e(t.map(this.pos))}resolve(e){let t=e.resolve(this.pos);return Vg.valid(t)?new Vg(t):j.near(t)}};function Ug(e){return e.isAtom||e.spec.isolating||e.spec.createGapCursor}function Wg(e){for(let t=e.depth;t>=0;t--){let n=e.index(t),r=e.node(t);if(n==0){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n-1);;e=e.lastChild){if(e.childCount==0&&!e.inlineContent||Ug(e.type))return!0;if(e.inlineContent)return!1}}return!0}function Gg(e){for(let t=e.depth;t>=0;t--){let n=e.indexAfter(t),r=e.node(t);if(n==r.childCount){if(r.type.spec.isolating)return!0;continue}for(let e=r.child(n);;e=e.firstChild){if(e.childCount==0&&!e.inlineContent||Ug(e.type))return!0;if(e.inlineContent)return!1}}return!0}function Kg(){return new Gn({props:{decorations:Zg,createSelectionBetween(e,t,n){return t.pos==n.pos&&Vg.valid(n)?new Vg(n):null},handleClick:Yg,handleKeyDown:qg,handleDOMEvents:{beforeinput:Xg}}})}var qg=Sc({ArrowLeft:Jg(`horiz`,-1),ArrowRight:Jg(`horiz`,1),ArrowUp:Jg(`vert`,-1),ArrowDown:Jg(`vert`,1)});function Jg(e,t){let n=e==`vert`?t>0?`down`:`up`:t>0?`right`:`left`;return function(e,r,i){let a=e.selection,o=t>0?a.$to:a.$from,s=a.empty;if(a instanceof M){if(!i.endOfTextblock(n)||o.depth==0)return!1;s=!1,o=e.doc.resolve(t>0?o.after():o.before())}let c=Vg.findGapCursorFrom(o,t,s);return c?(r&&r(e.tr.setSelection(new Vg(c))),!0):!1}}function Yg(e,t,n){if(!e||!e.editable)return!1;let r=e.state.doc.resolve(t);if(!Vg.valid(r))return!1;let i=e.posAtCoords({left:n.clientX,top:n.clientY});return i&&i.inside>-1&&N.isSelectable(e.state.doc.nodeAt(i.inside))?!1:(e.dispatch(e.state.tr.setSelection(new Vg(r))),!0)}function Xg(e,t){if(t.inputType!=`insertCompositionText`||!(e.state.selection instanceof Vg))return!1;let{$from:n}=e.state.selection,r=n.parent.contentMatchAt(n.index()).findWrapping(e.state.schema.nodes.text);if(!r)return!1;let i=b.empty;for(let e=r.length-1;e>=0;e--)i=b.from(r[e].createAndFill(null,i));let a=e.state.tr.replace(n.pos,n.pos,new E(i,0,0));return a.setSelection(M.near(a.doc.resolve(n.pos+1))),e.dispatch(a),!1}function Zg(e){if(!(e.selection instanceof Vg))return null;let t=document.createElement(`div`);return t.className=`ProseMirror-gapcursor`,xs.create(e.doc,[vs.widget(e.selection.head,t,{key:`gapcursor`})])}var Qg=200,$g=function(){};$g.prototype.append=function(e){return e.length?(e=$g.from(e),!this.length&&e||e.length<Qg&&this.leafAppend(e)||this.length<Qg&&e.leafPrepend(this)||this.appendInner(e)):this},$g.prototype.prepend=function(e){return e.length?$g.from(e).append(this):this},$g.prototype.appendInner=function(e){return new t_(this,e)},$g.prototype.slice=function(e,t){return e===void 0&&(e=0),t===void 0&&(t=this.length),e>=t?$g.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},$g.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},$g.prototype.forEach=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},$g.prototype.map=function(e,t,n){t===void 0&&(t=0),n===void 0&&(n=this.length);var r=[];return this.forEach(function(t,n){return r.push(e(t,n))},t,n),r},$g.from=function(e){return e instanceof $g?e:e&&e.length?new e_(e):$g.empty};var e_=function(e){function t(t){e.call(this),this.values=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return e==0&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,r){for(var i=t;i<n;i++)if(e(this.values[i],r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){for(var i=t-1;i>=n;i--)if(e(this.values[i],r+i)===!1)return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=Qg)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=Qg)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}($g);$g.empty=new e_([]);var t_=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return e<this.left.length?this.left.get(e):this.right.get(e-this.left.length)},t.prototype.forEachInner=function(e,t,n,r){var i=this.left.length;if(t<i&&this.left.forEachInner(e,t,Math.min(n,i),r)===!1||n>i&&this.right.forEachInner(e,Math.max(t-i,0),Math.min(this.length,n)-i,r+i)===!1)return!1},t.prototype.forEachInvertedInner=function(e,t,n,r){var i=this.left.length;if(t>i&&this.right.forEachInvertedInner(e,t-i,Math.max(n,i)-i,r+i)===!1||n<i&&this.left.forEachInvertedInner(e,Math.min(t,i),n,r)===!1)return!1},t.prototype.sliceInner=function(e,t){if(e==0&&t==this.length)return this;var n=this.left.length;return t<=n?this.left.slice(e,t):e>=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}($g),n_=500,r_=class e{constructor(e,t){this.items=e,this.eventCount=t}popEvent(t,n){if(this.eventCount==0)return null;let r=this.items.length;for(;;r--)if(this.items.get(r-1).selection){--r;break}let i,a;n&&(i=this.remapping(r,this.items.length),a=i.maps.length);let o=t.tr,s,c,l=[],u=[];return this.items.forEach((t,n)=>{if(!t.step){i||(i=this.remapping(r,n+1),a=i.maps.length),a--,u.push(t);return}if(i){u.push(new a_(t.map));let e=t.step.map(i.slice(a)),n;e&&o.maybeStep(e).doc&&(n=o.mapping.maps[o.mapping.maps.length-1],l.push(new a_(n,void 0,void 0,l.length+u.length))),a--,n&&i.appendMap(n,a)}else o.maybeStep(t.step);if(t.selection)return s=i?t.selection.map(i.slice(a)):t.selection,c=new e(this.items.slice(0,r).append(u.reverse().concat(l)),this.eventCount-1),!1},this.items.length,0),{remaining:c,transform:o,selection:s}}addTransform(t,n,r,i){let a=[],o=this.eventCount,s=this.items,c=!i&&s.length?s.get(s.length-1):null;for(let e=0;e<t.steps.length;e++){let r=t.steps[e].invert(t.docs[e]),l=new a_(t.mapping.maps[e],r,n),u;(u=c&&c.merge(l))&&(l=u,e?a.pop():s=s.slice(0,s.length-1)),a.push(l),n&&=(o++,void 0),i||(c=l)}let l=o-r.depth;return l>s_&&(s=i_(s,l),o-=l),new e(s.append(a),o)}remapping(e,t){let n=new xt;return this.items.forEach((t,r)=>{let i=t.mirrorOffset!=null&&r-t.mirrorOffset>=e?n.maps.length-t.mirrorOffset:void 0;n.appendMap(t.map,i)},e,t),n}addMaps(t){return this.eventCount==0?this:new e(this.items.append(t.map(e=>new a_(e))),this.eventCount)}rebased(t,n){if(!this.eventCount)return this;let r=[],i=Math.max(0,this.items.length-n),a=t.mapping,o=t.steps.length,s=this.eventCount;this.items.forEach(e=>{e.selection&&s--},i);let c=n;this.items.forEach(e=>{let n=a.getMirror(--c);if(n==null)return;o=Math.min(o,n);let i=a.maps[n];if(e.step){let o=t.steps[n].invert(t.docs[n]),l=e.selection&&e.selection.map(a.slice(c+1,n));l&&s++,r.push(new a_(i,o,l))}else r.push(new a_(i))},i);let l=[];for(let e=n;e<o;e++)l.push(new a_(a.maps[e]));let u=this.items.slice(0,i).append(l).append(r),d=new e(u,s);return d.emptyItemCount()>n_&&(d=d.compress(this.items.length-r.length)),d}emptyItemCount(){let e=0;return this.items.forEach(t=>{t.step||e++}),e}compress(t=this.items.length){let n=this.remapping(0,t),r=n.maps.length,i=[],a=0;return this.items.forEach((e,o)=>{if(o>=t)i.push(e),e.selection&&a++;else if(e.step){let t=e.step.map(n.slice(r)),o=t&&t.getMap();if(r--,o&&n.appendMap(o,r),t){let s=e.selection&&e.selection.map(n.slice(r));s&&a++;let c=new a_(o.invert(),t,s),l,u=i.length-1;(l=i.length&&i[u].merge(c))?i[u]=l:i.push(c)}}else e.map&&r--},this.items.length,0),new e($g.from(i.reverse()),a)}};r_.empty=new r_($g.empty,0);function i_(e,t){let n;return e.forEach((e,r)=>{if(e.selection&&t--==0)return n=r,!1}),e.slice(n)}var a_=class e{constructor(e,t,n,r){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=r}merge(t){if(this.step&&t.step&&!t.selection){let n=t.step.merge(this.step);if(n)return new e(n.getMap().invert(),n,this.selection)}}},o_=class{constructor(e,t,n,r,i){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=r,this.prevComposition=i}},s_=20;function c_(e,t,n,r){let i=n.getMeta(g_),a;if(i)return i.historyState;n.getMeta(__)&&(e=new o_(e.done,e.undone,null,0,-1));let o=n.getMeta(`appendedTransaction`);if(n.steps.length==0)return e;if(o&&o.getMeta(g_))return o.getMeta(g_).redo?new o_(e.done.addTransform(n,void 0,r,h_(t)),e.undone,u_(n.mapping.maps),e.prevTime,e.prevComposition):new o_(e.done,e.undone.addTransform(n,void 0,r,h_(t)),null,e.prevTime,e.prevComposition);if(n.getMeta(`addToHistory`)!==!1&&!(o&&o.getMeta(`addToHistory`)===!1)){let i=n.getMeta(`composition`),a=e.prevTime==0||!o&&e.prevComposition!=i&&(e.prevTime<(n.time||0)-r.newGroupDelay||!l_(n,e.prevRanges)),s=o?d_(e.prevRanges,n.mapping):u_(n.mapping.maps);return new o_(e.done.addTransform(n,a?t.selection.getBookmark():void 0,r,h_(t)),r_.empty,s,n.time,i??e.prevComposition)}return(a=n.getMeta(`rebased`))?new o_(e.done.rebased(n,a),e.undone.rebased(n,a),d_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition):new o_(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),d_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition)}function l_(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((e,r)=>{for(let i=0;i<t.length;i+=2)e<=t[i+1]&&r>=t[i]&&(n=!0)}),n}function u_(e){let t=[];for(let n=e.length-1;n>=0&&t.length==0;n--)e[n].forEach((e,n,r,i)=>t.push(r,i));return t}function d_(e,t){if(!e)return null;let n=[];for(let r=0;r<e.length;r+=2){let i=t.map(e[r],1),a=t.map(e[r+1],-1);i<=a&&n.push(i,a)}return n}function f_(e,t,n){let r=h_(t),i=g_.get(t).spec.config,a=(n?e.undone:e.done).popEvent(t,r);if(!a)return null;let o=a.selection.resolve(a.transform.doc),s=(n?e.done:e.undone).addTransform(a.transform,t.selection.getBookmark(),i,r),c=new o_(n?s:a.remaining,n?a.remaining:s,null,0,-1);return a.transform.setSelection(o).setMeta(g_,{redo:n,historyState:c})}var p_=!1,m_=null;function h_(e){let t=e.plugins;if(m_!=t){p_=!1,m_=t;for(let e=0;e<t.length;e++)if(t[e].spec.historyPreserveItems){p_=!0;break}}return p_}var g_=new Jn(`history`),__=new Jn(`closeHistory`);function v_(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new Gn({key:g_,state:{init(){return new o_(r_.empty,r_.empty,null,0,-1)},apply(t,n,r){return c_(n,r,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(e,t){let n=t.inputType,r=n==`historyUndo`?b_:n==`historyRedo`?x_:null;return!r||!e.editable?!1:(t.preventDefault(),r(e.state,e.dispatch))}}}})}function y_(e,t){return(n,r)=>{let i=g_.getState(n);if(!i||(e?i.undone:i.done).eventCount==0)return!1;if(r){let a=f_(i,n,e);a&&r(t?a.scrollIntoView():a)}return!0}}var b_=y_(!1,!0),x_=y_(!0,!0);nf.create({name:`characterCount`,addOptions(){return{limit:null,autoTrim:!0,mode:`textSize`,textCounter:e=>e.length,wordCounter:e=>e.split(` `).filter(e=>e!==``).length}},addStorage(){return{characters:()=>0,words:()=>0}},onBeforeCreate(){this.storage.characters=e=>{let t=e?.node||this.editor.state.doc;if((e?.mode||this.options.mode)===`textSize`){let e=t.textBetween(0,t.content.size,void 0,` `);return this.options.textCounter(e)}return t.nodeSize},this.storage.words=e=>{let t=e?.node||this.editor.state.doc,n=t.textBetween(0,t.content.size,` `,` `);return this.options.wordCounter(n)}},addProseMirrorPlugins(){let e=!1;return[new Gn({key:new Jn(`characterCount`),appendTransaction:(t,n,r)=>{if(e)return;let i=this.options.limit,a=this.options.autoTrim;if(i==null||i===0||a===!1){e=!0;return}let o=this.storage.characters({node:r.doc});if(o>i){let t=o-i;console.warn(`[CharacterCount] Initial content exceeded limit of ${i} characters. Content was automatically trimmed.`);let n=r.tr.deleteRange(0,t);return e=!0,n}e=!0},filterTransaction:(e,t)=>{let n=this.options.limit;if(!e.docChanged||n===0||n==null)return!0;let r=this.storage.characters({node:t.doc}),i=this.storage.characters({node:e.doc});if(i<=n||r>n&&i>n&&i<=r)return!0;if(r>n&&i>n&&i>r||!e.getMeta(`paste`))return!1;let a=e.selection.$head.pos,o=a-(i-n),s=a;return e.deleteRange(o,s),!(this.storage.characters({node:e.doc})>n)}})]}});var S_=nf.create({name:`dropCursor`,addOptions(){return{color:`currentColor`,width:1,class:void 0}},addProseMirrorPlugins(){return[zg(this.options)]}});nf.create({name:`focus`,addOptions(){return{className:`has-focus`,mode:`all`}},addProseMirrorPlugins(){return[new Gn({key:new Jn(`focus`),props:{decorations:({doc:e,selection:t})=>{let{isEditable:n,isFocused:r}=this.editor,{anchor:i}=t,a=[];if(!n||!r)return xs.create(e,[]);let o=0;this.options.mode===`deepest`&&e.descendants((e,t)=>{if(!e.isText){if(!(i>=t&&i<=t+e.nodeSize-1))return!1;o+=1}});let s=0;return e.descendants((e,t)=>{if(e.isText||!(i>=t&&i<=t+e.nodeSize-1))return!1;if(s+=1,this.options.mode===`deepest`&&o-s>0||this.options.mode===`shallowest`&&s>1)return this.options.mode===`deepest`;a.push(vs.node(t,t+e.nodeSize,{class:this.options.className}))}),xs.create(e,a)}}})]}});var C_=nf.create({name:`gapCursor`,addProseMirrorPlugins(){return[Kg()]},extendNodeSchema(e){return{allowGapCursor:z(I(e,`allowGapCursor`,{name:e.name,options:e.options,storage:e.storage}))??null}}}),w_=`placeholder`,T_=new Jn(`tiptap__placeholder`);function E_(e){let{editor:t,placeholder:n,dataAttribute:r,pos:i,node:a,isEmptyDoc:o,hasAnchor:s,classes:{emptyNode:c,emptyEditor:l}}=e,u=[c];return o&&u.push(l),vs.node(i,i+a.nodeSize,{class:u.join(` `),[r]:typeof n==`function`?n({editor:t,node:a,pos:i,hasAnchor:s}):n})}function D_(e,t){return typeof e==`function`?e(t):e}function O_({editor:e,options:t,dataAttribute:n,doc:r,selection:i,from:a,to:o}){let{anchor:s}=i,c=[],l=e.isEmpty;return r.nodesBetween(a,o,(r,i)=>{let a=s>=i&&s<=i+r.nodeSize,o=!r.isLeaf&&Ou(r);return r.type.isTextblock&&(a||!t.showOnlyCurrent)&&o&&c.push(E_({editor:e,isEmptyDoc:l,dataAttribute:n,hasAnchor:a,placeholder:t.placeholder,classes:{emptyEditor:t.emptyEditorClass,emptyNode:D_(t.emptyNodeClass,{editor:e,node:r,pos:i,hasAnchor:a})},node:r,pos:i})),t.includeChildren}),c}function k_({editor:e,options:t,dataAttribute:n,doc:r,selection:i}){if(!e.isEditable&&t.showOnlyWhenEditable)return null;let{anchor:a}=i,o=[],s=e.isEmpty;if(t.showOnlyCurrent&&!t.includeChildren){let i=r.resolve(a),c=i.depth>0?i.node(1):i.nodeAfter,l=i.depth>0?i.before(1):a;if(c&&c.type.isTextblock&&Ou(c)){let r=a>=l&&a<=l+c.nodeSize;o.push(E_({editor:e,isEmptyDoc:s,dataAttribute:n,hasAnchor:r,placeholder:t.placeholder,classes:{emptyEditor:t.emptyEditorClass,emptyNode:D_(t.emptyNodeClass,{editor:e,node:c,pos:l,hasAnchor:r})},node:c,pos:l}))}}else o.push(...O_({editor:e,options:t,dataAttribute:n,doc:r,selection:i,from:0,to:r.content.size}));return xs.create(r,o)}function A_(e,t){let n=e.resolve(t);if(n.depth===0){let e=n.nodeAfter??n.nodeBefore;if(!e)return{from:t,to:t};let r=n.nodeAfter?t:t-e.nodeSize;return{from:r,to:r+e.nodeSize}}let r=n.before(1);return{from:r,to:r+n.node(1).nodeSize}}function j_(e,t){return{from:Math.max(0,t.from-1),to:Math.min(e.content.size,t.to-1)}}function M_(e,t,n){let r=[];return e.forEach((e,i)=>{let a=i,o=a+e.nodeSize,s=a+1,c=o+1;s<n&&c>t&&r.push({from:a,to:o})}),r}function N_(e){if(e.length===0)return[];let t=[...e].sort((e,t)=>e.from-t.from),n=[{...t[0]}];for(let e=1;e<t.length;e+=1){let r=n[n.length-1],i=t[e];i.from<=r.to?r.to=Math.max(r.to,i.to):n.push({...i})}return n}function P_(e,t){let n=M_(e,t.from,t.to);return n.push(j_(e,A_(e,t.from))),t.to>t.from?n.push(j_(e,A_(e,Math.min(t.to,e.content.size+1)-1))):t.from<e.content.size+1&&n.push(j_(e,A_(e,Math.min(t.from+1,e.content.size)))),n}function F_(e,t,n){let r=[];if(e.docChanged){let t=hu(e);for(let e of t)r.push(...P_(n.doc,e.newRange))}return e.selectionSet&&(r.push(j_(n.doc,A_(n.doc,e.mapping.map(t.selection.anchor)))),r.push(j_(n.doc,A_(n.doc,n.selection.anchor)))),N_(r)}function I_(e,t,n){let r=Math.max(0,Math.min(e,n.content.size));return{from:r,to:Math.max(r,Math.min(t,n.content.size))}}function L_({decorations:e,ranges:t,editor:n,options:r,dataAttribute:i,doc:a,selection:o}){let s=e;for(let e of t){let{from:t,to:c}=I_(e.from,e.to,a),l=s.find(t,c).filter(e=>e.from>=t&&e.to<=c);l.length&&(s=s.remove(l));let u=O_({editor:n,options:r,dataAttribute:i,doc:a,selection:o,from:t,to:c});u.length&&(s=s.add(a,u))}return s}function R_({editor:e,options:t,dataAttribute:n}){return{init(r,i){return k_({editor:e,options:t,dataAttribute:n,doc:i.doc,selection:i.selection})??xs.empty},apply(r,i,a,o){return!r.docChanged&&!r.selectionSet?i:L_({decorations:i.map(r.mapping,r.doc),ranges:F_(r,a,o),editor:e,options:t,dataAttribute:n,doc:o.doc,selection:o.selection})}}}function z_(e){return e.replace(/\s+/g,`-`).replace(/[^a-zA-Z0-9-]/g,``).replace(/^[0-9-]+/,``).replace(/^-+/,``).toLowerCase()}function B_({editor:e,options:t}){let n=t.dataAttribute?`data-${z_(t.dataAttribute)}`:`data-${w_}`,r=t.showOnlyCurrent&&!t.includeChildren;return new Gn({key:T_,...r?{}:{state:R_({editor:e,options:t,dataAttribute:n})},props:{decorations:r?({doc:r,selection:i})=>k_({editor:e,options:t,dataAttribute:n,doc:r,selection:i}):n=>t.showOnlyWhenEditable&&!e.isEditable?xs.empty:T_.getState(n)??xs.empty}})}nf.create({name:`placeholder`,addOptions(){return{emptyEditorClass:`is-editor-empty`,emptyNodeClass:`is-empty`,dataAttribute:w_,placeholder:`Write something …`,showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){return[B_({editor:this.editor,options:this.options})]}});function V_(e,t){return!e.selection.empty&&!ku(e.selection)&&t.isEditable}function H_(e,t){return V_(e,t)&&!t.isFocused&&!t.view.dragging}function U_(){var e;(e=window.getSelection())==null||e.removeAllRanges()}function W_(e){e.focus()}nf.create({name:`selection`,addOptions(){return{className:`selection`}},addProseMirrorPlugins(){let{editor:e,options:t}=this;return[new Gn({key:new Jn(`selection`),props:{decorations(n){return H_(n,e)?xs.create(n.doc,[vs.inline(n.selection.from,n.selection.to,{class:t.className})]):null},handleDOMEvents:{blur(t){return V_(t.state,e)&&U_(),!1},focus(t){return V_(t.state,e)&&requestAnimationFrame(()=>{!e.isDestroyed&&t.hasFocus()&&W_(t)}),!1}}}})]}});function G_({types:e,node:t}){return t&&Array.isArray(e)&&e.includes(t.type)||t?.type===e}var K_=nf.create({name:`trailingNode`,addOptions(){return{node:void 0,notAfter:[]}},addProseMirrorPlugins(){let e=new Jn(this.name),t=this.options.node||this.editor.schema.topNodeType.contentMatch.defaultType?.name||`paragraph`,n=Object.entries(this.editor.schema.nodes).map(([,e])=>e).filter(e=>(this.options.notAfter||[]).concat(t).includes(e.name));return[new Gn({key:e,appendTransaction:(n,r,i)=>{let{doc:a,tr:o,schema:s}=i,c=e.getState(i),l=a.content.size,u=s.nodes[t];if(!n.some(e=>e.getMeta(`skipTrailingNode`))&&c)return o.insert(l,u.create())},state:{init:(e,t)=>{let r=t.tr.doc.lastChild;return!G_({node:r,types:n})},apply:(e,t)=>{if(!e.docChanged||e.getMeta(`__uniqueIDTransaction`))return t;let r=e.doc.lastChild;return!G_({node:r,types:n})}}})]}}),q_=nf.create({name:`undoRedo`,addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:e,dispatch:t})=>b_(e,t),redo:()=>({state:e,dispatch:t})=>x_(e,t)}},addProseMirrorPlugins(){return[v_(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-я":()=>this.editor.commands.undo(),"Shift-Mod-я":()=>this.editor.commands.redo()}}}),J_=nf.create({name:`starterKit`,addExtensions(){let e=[];return this.options.bold!==!1&&e.push(Bf.configure(this.options.bold)),this.options.blockquote!==!1&&e.push(Ff.configure(this.options.blockquote)),this.options.bulletList!==!1&&e.push(Ah.configure(this.options.bulletList)),this.options.code!==!1&&e.push(Uf.configure(this.options.code)),this.options.codeBlock!==!1&&e.push(qf.configure(this.options.codeBlock)),this.options.document!==!1&&e.push(Jf.configure(this.options.document)),this.options.dropcursor!==!1&&e.push(S_.configure(this.options.dropcursor)),this.options.gapcursor!==!1&&e.push(C_.configure(this.options.gapcursor)),this.options.hardBreak!==!1&&e.push(Yf.configure(this.options.hardBreak)),this.options.heading!==!1&&e.push(Xf.configure(this.options.heading)),this.options.undoRedo!==!1&&e.push(q_.configure(this.options.undoRedo)),this.options.horizontalRule!==!1&&e.push(Zf.configure(this.options.horizontalRule)),this.options.italic!==!1&&e.push(np.configure(this.options.italic)),this.options.listItem!==!1&&e.push($h.configure(this.options.listItem)),this.options.listKeymap!==!1&&e.push(cg.configure(this.options?.listKeymap)),this.options.link!==!1&&e.push(Eh.configure(this.options?.link)),this.options.orderedList!==!1&&e.push(Tg.configure(this.options.orderedList)),this.options.paragraph!==!1&&e.push(Ng.configure(this.options.paragraph)),this.options.strike!==!1&&e.push(Ig.configure(this.options.strike)),this.options.text!==!1&&e.push(Lg.configure(this.options.text)),this.options.underline!==!1&&e.push(Rg.configure(this.options?.underline)),this.options.trailingNode!==!1&&e.push(K_.configure(this.options?.trailingNode)),e}}),Y_={DISABLED_SITES:[`cloud.microsoft`,`deepl.com`,`productboard.com`,`openai.com`,`chatgpt.com`],CHROME_AND_FIREFOX_SITES:[`chrome:`,`chrome-extension:`,`about:`,`moz-extension:`],EXPOSE_WITTY_ID_ALLOW_LIST:{dev:[`lndo.site`,`platformsh.site`,`witty.works`],prod:[`witty.works`]},BASE_URLS:{Prod:{api:`https://default.api.witty.works/`,dashboard:`https://dashboard.witty.works/`,posthog_url:`https://eu.posthog.com`,posthog_key:`phc_i1tlvuh1iecIOSEr0QmTEIklrsSJGhULpUwUlf8fkkl`,oauth_client_id:``},Dev:{api:`https://dev-54ta5gq-jyeciedibdzvq.fr-4.platformsh.site/`,dashboard:`https://dev-54ta5gq-56xlfiudba6c2.fr-4.platformsh.site/`,posthog_url:`https://app.posthog.com`,posthog_key:`phc_QiISRw0yFAsndXqYD0HmfGvHaOBMxb57ZRIxlimvR64`,oauth_client_id:``},Local:{api:`http://127.0.0.1:8000/`,dashboard:`https://dashboard.lndo.site/`,posthog_url:`https://app.posthog.com`,posthog_key:`phc_QiISRw0yFAsndXqYD0HmfGvHaOBMxb57ZRIxlimvR64`,oauth_client_id:`1`}},ORTHOGRAPHY:!0,SENTRY_DSN:``,SENTRY_SAMPLE_RATE:0,SENTRY_TRACE_RATE:0,API_DELAY:2e3,REPHRASE_ENABLED:!1,MAX_CHAR_LENGTH_REQUEST:2e3,MAX_CHAR_LENGTH_TOTAL:2e3,MIN_CHAR_LENGTH:50,MAX_POSTHOG_LOG_EVENTS:5e3,POSTHOG_ENABLED:!1},X_=`2.2.1`,Z_={...Y_.BASE_URLS},Q_=Object.keys(Z_);Q_.includes(`Prod`)||Q_[0];var $_=`https://www.witty.works/en/help/`;`${$_}`,`${$_}`,`${$_}`,`${$_}`,`${$_}`;var ev=[`gendered_roles_format`,`german_gender_ending`,`french_gender_separator`],tv=function(e){return e[e.Off=0]=`Off`,e[e.Basic=1]=`Basic`,e[e.Advanced=2]=`Advanced`,e}({}),nv=(e,t,n)=>n.includes(e)?0:t&&n.includes(t)?1:t?2:1,rv=(e,t,n,r)=>{let i=r.filter(n=>n!==e&&n!==t);return n===0?(i.push(e),t&&i.push(t)):n===1&&t&&i.push(t),i},iv={inclusive:{hover:`#BCD485`,default:`#D3E4AC`,highlight:`#BCD485`},corporate:{hover:`#6f9FED`,default:`#A1BEED`,highlight:`#6f9FED`},style:{hover:`#F6EC6B`,default:`#FFFFD3`,highlight:`#F6EC6B`},bias:{hover:`#EB9F46`,default:`#F8E7CB`,highlight:`#EB9F46`},severe:{hover:`#E6635A`,default:`#F7D4D4`,highlight:`#E6635A`}},av=(e,t)=>t===`corporate_rules`?`corporate`:e?e<1.5?`severe`:e>2.5?`style`:`bias`:`inclusive`,ov=(e,t)=>iv[av(e,t)];Y_.EXPOSE_WITTY_ID_ALLOW_LIST?.prod;var U=e=>typeof e==`string`,sv=()=>{let e,t,n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n},cv=e=>e==null?``:String(e),lv=(e,t,n)=>{e.forEach(e=>{t[e]&&(n[e]=t[e])})},uv=/###/g,dv=e=>e&&e.includes(`###`)?e.replace(uv,`.`):e,fv=e=>!e||U(e),pv=(e,t,n)=>{let r=U(t)?t.split(`.`):t,i=0;for(;i<r.length-1;){if(fv(e))return{};let t=dv(r[i]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++i}return fv(e)?{}:{obj:e,k:dv(r[i])}},mv=(e,t,n)=>{let{obj:r,k:i}=pv(e,t,Object);if(r!==void 0||t.length===1){r[i]=n;return}let a=t[t.length-1],o=t.slice(0,t.length-1),s=pv(e,o,Object);for(;s.obj===void 0&&o.length;)a=`${o[o.length-1]}.${a}`,o=o.slice(0,o.length-1),s=pv(e,o,Object),s?.obj&&s.obj[`${s.k}.${a}`]!==void 0&&(s.obj=void 0);s.obj[`${s.k}.${a}`]=n},hv=(e,t,n,r)=>{let{obj:i,k:a}=pv(e,t,Object);i[a]=i[a]||[],i[a].push(n)},gv=(e,t)=>{let{obj:n,k:r}=pv(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},_v=(e,t,n)=>{let r=gv(e,n);return r===void 0?gv(t,n):r},vv=(e,t,n)=>{for(let r in t)r!==`__proto__`&&r!==`constructor`&&(Object.prototype.hasOwnProperty.call(e,r)?U(e[r])||e[r]instanceof String||U(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):vv(e[r],t[r],n):e[r]=t[r]);return e},yv=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,`\\$&`),bv={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`,"/":`&#x2F;`},xv=e=>U(e)?e.replace(/[&<>"'\/]/g,e=>bv[e]):e,Sv=class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){let t=this.regExpMap.get(e);if(t!==void 0)return t;let n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}},Cv=[` `,`,`,`?`,`!`,`;`],wv=new Sv(20),Tv=(e,t,n)=>{t||=``,n||=``;let r=Cv.filter(e=>!t.includes(e)&&!n.includes(e));if(r.length===0)return!0;let i=wv.getRegExp(`(${r.map(e=>e===`?`?`\\?`:e).join(`|`)})`),a=!i.test(e);if(!a){let t=e.indexOf(n);t>0&&!i.test(e.substring(0,t))&&(a=!0)}return a},Ev=(e,t,n=`.`)=>{if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;let r=t.split(n),i=e;for(let e=0;e<r.length;){if(!i||typeof i!=`object`)return;let t,a=``;for(let o=e;o<r.length;++o)if(o!==e&&(a+=n),a+=r[o],t=i[a],t!==void 0){if([`string`,`number`,`boolean`].includes(typeof t)&&o<r.length-1)continue;e+=o-e+1;break}i=t}return i},Dv=e=>e?.replace(/_/g,`-`),Ov={type:`logger`,log(e){this.output(`log`,e)},warn(e){this.output(`warn`,e)},error(e){this.output(`error`,e)},output(e,t){console?.[e]?.apply?.(console,t)}},kv=new class e{constructor(e,t={}){this.init(e,t)}init(e,t={}){this.prefix=t.prefix||`i18next:`,this.logger=e||Ov,this.options=t,this.debug=t.debug}log(...e){return this.forward(e,`log`,``,!0)}warn(...e){return this.forward(e,`warn`,``,!0)}error(...e){return this.forward(e,`error`,``)}deprecate(...e){return this.forward(e,`warn`,`WARNING DEPRECATED: `,!0)}forward(e,t,n,r){return r&&!this.debug?null:(e=e.map(e=>U(e)?e.replace(/[\r\n\x00-\x1F\x7F]/g,` `):e),U(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(t){return new e(this.logger,{prefix:`${this.prefix}:${t}:`,...this.options})}clone(t){return t||=this.options,t.prefix=t.prefix||this.prefix,new e(this.logger,t)}},Av=class{constructor(){this.observers={}}on(e,t){return e.split(` `).forEach(e=>{this.observers[e]||(this.observers[e]=new Map);let n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)}),this}off(e,t){if(this.observers[e]){if(!t){delete this.observers[e];return}this.observers[e].delete(t)}}once(e,t){let n=(...r)=>{t(...r),this.off(e,n)};return this.on(e,n),this}emit(e,...t){this.observers[e]&&Array.from(this.observers[e].entries()).forEach(([e,n])=>{for(let r=0;r<n;r++)e(...t)}),this.observers[`*`]&&Array.from(this.observers[`*`].entries()).forEach(([n,r])=>{for(let i=0;i<r;i++)n(e,...t)})}},jv=class extends Av{constructor(e,t={ns:[`translation`],defaultNS:`translation`}){super(),this.data=e||{},this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator=`.`),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.includes(e)||this.options.ns.push(e)}removeNamespaces(e){let t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n,r={}){let i=r.keySeparator===void 0?this.options.keySeparator:r.keySeparator,a=r.ignoreJSONStructure===void 0?this.options.ignoreJSONStructure:r.ignoreJSONStructure,o;e.includes(`.`)?o=e.split(`.`):(o=[e,t],n&&(Array.isArray(n)?o.push(...n):U(n)&&i?o.push(...n.split(i)):o.push(n)));let s=gv(this.data,o);return!s&&!t&&!n&&e.includes(`.`)&&(e=o[0],t=o[1],n=o.slice(2).join(`.`)),s||!a||!U(n)?s:Ev(this.data?.[e]?.[t],n,i)}addResource(e,t,n,r,i={silent:!1}){let a=i.keySeparator===void 0?this.options.keySeparator:i.keySeparator,o=[e,t];n&&(o=o.concat(a?n.split(a):n)),e.includes(`.`)&&(o=e.split(`.`),r=t,t=o[1]),this.addNamespaces(t),mv(this.data,o,r),i.silent||this.emit(`added`,e,t,n,r)}addResources(e,t,n,r={silent:!1}){for(let r in n)(U(n[r])||Array.isArray(n[r]))&&this.addResource(e,t,r,n[r],{silent:!0});r.silent||this.emit(`added`,e,t,n)}addResourceBundle(e,t,n,r,i,a={silent:!1,skipCopy:!1}){let o=[e,t];e.includes(`.`)&&(o=e.split(`.`),r=n,n=t,t=o[1]),this.addNamespaces(t);let s=gv(this.data,o)||{};a.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?vv(s,n,i):s={...s,...n},mv(this.data,o,s),a.silent||this.emit(`added`,e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit(`removed`,e,t)}hasResourceBundle(e,t){return this.getResource(e,t)!==void 0}getResourceBundle(e,t){return t||=this.options.defaultNS,this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){let t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}},Mv={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,i){return e.forEach(e=>{t=this.processors[e]?.process(t,n,r,i)??t}),t}},Nv=Symbol(`i18next/PATH_KEY`);function Pv(){let e=[],t=Object.create(null),n;return t.get=(r,i)=>(n?.revoke?.(),i===Nv?e:(e.push(i),n=Proxy.revocable(r,t),n.proxy)),Proxy.revocable(Object.create(null),t).proxy}function Fv(e,t){let{[Nv]:n}=e(Pv()),r=t?.keySeparator??`.`,i=t?.nsSeparator??`:`,a=t?.enableSelector===`strict`;if(n.length>1&&i){let e=t?.ns,o=a?Array.isArray(e)?e:e?[e]:null:Array.isArray(e)?e:null;if(o&&(a?o:o.length>1?o.slice(1):[]).includes(n[0]))return`${n[0]}${i}${n.slice(1).join(r)}`}return n.join(r)}var Iv=e=>!U(e)&&typeof e!=`boolean`&&typeof e!=`number`,Lv=class e extends Av{constructor(e,t={}){super(),lv([`resourceStore`,`languageUtils`,`pluralResolver`,`interpolator`,`backendConnector`,`i18nFormat`,`utils`],e,this),this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator=`.`),this.logger=kv.create(`translator`),this.checkedLoadedFor={}}changeLanguage(e){e&&(this.language=e)}exists(e,t={interpolation:{}}){let n={...t};if(e==null)return!1;let r=this.resolve(e,n);if(r?.res===void 0)return!1;let i=Iv(r.res);return!(n.returnObjects===!1&&i)}extractFromKey(e,t){let n=t.nsSeparator===void 0?this.options.nsSeparator:t.nsSeparator;n===void 0&&(n=`:`);let r=t.keySeparator===void 0?this.options.keySeparator:t.keySeparator,i=t.ns||this.options.defaultNS||[],a=n&&e.includes(n),o=!this.options.userDefinedKeySeparator&&!t.keySeparator&&!this.options.userDefinedNsSeparator&&!t.nsSeparator&&!Tv(e,n,r);if(a&&!o){let t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:U(i)?[i]:i};let a=e.split(n);(n!==r||n===r&&this.options.ns.includes(a[0]))&&(i=a.shift()),e=a.join(r)}return{key:e,namespaces:U(i)?[i]:i}}translate(t,n,r){let i=typeof n==`object`?{...n}:n;if(typeof i!=`object`&&this.options.overloadTranslationOptionHandler&&(i=this.options.overloadTranslationOptionHandler(arguments)),typeof i==`object`&&(i={...i}),i||={},t==null)return``;typeof t==`function`&&(t=Fv(t,{...this.options,...i})),Array.isArray(t)||(t=[String(t)]),t=t.map(e=>typeof e==`function`?Fv(e,{...this.options,...i}):String(e));let a=i.returnDetails===void 0?this.options.returnDetails:i.returnDetails,o=i.keySeparator===void 0?this.options.keySeparator:i.keySeparator,{key:s,namespaces:c}=this.extractFromKey(t[t.length-1],i),l=c[c.length-1],u=i.nsSeparator===void 0?this.options.nsSeparator:i.nsSeparator;u===void 0&&(u=`:`);let d=i.lng||this.language,f=i.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(d?.toLowerCase()===`cimode`)return f?a?{res:`${l}${u}${s}`,usedKey:s,exactUsedKey:s,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(i)}:`${l}${u}${s}`:a?{res:s,usedKey:s,exactUsedKey:s,usedLng:d,usedNS:l,usedParams:this.getUsedParamsDetails(i)}:s;let p=this.resolve(t,i),m=p?.res,h=p?.usedKey||s,g=p?.exactUsedKey||s,_=[`[object Number]`,`[object Function]`,`[object RegExp]`],v=i.joinArrays===void 0?this.options.joinArrays:i.joinArrays,y=!this.i18nFormat||this.i18nFormat.handleAsObject,b=i.count!==void 0&&!U(i.count),x=e.hasDefaultValue(i),S=b?this.pluralResolver.getSuffix(d,i.count,i):``,C=i.ordinal&&b?this.pluralResolver.getSuffix(d,i.count,{ordinal:!1}):``,w=b&&!i.ordinal&&i.count===0,T=w&&i[`defaultValue${this.options.pluralSeparator}zero`]||i[`defaultValue${S}`]||i[`defaultValue${C}`]||i.defaultValue,E=m;y&&!m&&x&&(E=T);let D=Iv(E),O=Object.prototype.toString.apply(E);if(y&&E&&D&&!_.includes(O)&&!(U(v)&&Array.isArray(E))){if(!i.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn(`accessing an object - but returnObjects options is not enabled!`);let e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(h,E,{...i,ns:c}):`key '${s} (${this.language})' returned an object instead of string.`;return a?(p.res=e,p.usedParams=this.getUsedParamsDetails(i),p):e}if(o){let e=Array.isArray(E),t=e?[]:{},n=e?g:h;for(let e in E)if(Object.prototype.hasOwnProperty.call(E,e)){let r=`${n}${o}${e}`;t[e]=x&&!m?this.translate(r,{...i,defaultValue:Iv(T)?T[e]:void 0,joinArrays:!1,ns:c}):this.translate(r,{...i,joinArrays:!1,ns:c}),t[e]===r&&(t[e]=E[e])}m=t}}else if(y&&U(v)&&Array.isArray(m))m=m.join(v),m&&=this.extendTranslation(m,t,i,r);else{let e=!1,n=!1;!this.isValidLookup(m)&&x&&(e=!0,m=T),this.isValidLookup(m)||(n=!0,m=s);let a=(i.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&n?void 0:m,c=x&&T!==m&&this.options.updateMissing;if(n||e||c){if(this.logger.log(c?`updateKey`:`missingKey`,d,l,b&&!c?`${s}${this.pluralResolver.getSuffix(d,i.count,i)}`:s,c?T:m),o){let e=this.resolve(s,{...i,keySeparator:!1});e&&e.res&&this.logger.warn(`Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.`)}let e=[],t=this.languageUtils.getFallbackCodes(this.options.fallbackLng,i.lng||this.language);if(this.options.saveMissingTo===`fallback`&&t&&t[0])for(let n=0;n<t.length;n++)e.push(t[n]);else this.options.saveMissingTo===`all`?e=this.languageUtils.toResolveHierarchy(i.lng||this.language):e.push(i.lng||this.language);let n=(e,t,n)=>{let r=x&&n!==m?n:a;this.options.missingKeyHandler?this.options.missingKeyHandler(e,l,t,r,c,i):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,l,t,r,c,i),this.emit(`missingKey`,e,l,t,m)};this.options.saveMissing&&(this.options.saveMissingPlurals&&b?e.forEach(e=>{let t=this.pluralResolver.getSuffixes(e,i);w&&i[`defaultValue${this.options.pluralSeparator}zero`]&&!t.includes(`${this.options.pluralSeparator}zero`)&&t.push(`${this.options.pluralSeparator}zero`),t.forEach(t=>{n([e],s+t,i[`defaultValue${t}`]||T)})}):n(e,s,T))}m=this.extendTranslation(m,t,i,p,r),n&&m===s&&this.options.appendNamespaceToMissingKey&&(m=`${l}${u}${s}`),(n||e)&&this.options.parseMissingKeyHandler&&(m=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}${u}${s}`:s,e?m:void 0,i))}return a?(p.res=m,p.usedParams=this.getUsedParamsDetails(i),p):m}extendTranslation(e,t,n,r,i){if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});let a=U(e)&&(n?.interpolation?.skipOnVariables===void 0?this.options.interpolation.skipOnVariables:n.interpolation.skipOnVariables),o;if(a){let t=e.match(this.interpolator.nestingRegexp);o=t&&t.length}let s=n.replace&&!U(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(s={...this.options.interpolation.defaultVariables,...s}),e=this.interpolator.interpolate(e,s,n.lng||this.language||r.usedLng,n),a){let t=e.match(this.interpolator.nestingRegexp),r=t&&t.length;o<r&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),n.nest!==!1&&(e=this.interpolator.nest(e,(...e)=>i?.[0]===e[0]&&!n.context?(this.logger.warn(`It seems you are nesting recursively key: ${e[0]} in key: ${t[0]}`),null):this.translate(...e,t),n)),n.interpolation&&this.interpolator.reset()}let a=n.postProcess||this.options.postProcess,o=U(a)?[a]:a;return e!=null&&o?.length&&n.applyPostProcessor!==!1&&(e=Mv.handle(o,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e,t={}){let n,r,i,a,o;return U(e)&&(e=[e]),Array.isArray(e)&&(e=e.map(e=>typeof e==`function`?Fv(e,{...this.options,...t}):e)),e.forEach(e=>{if(this.isValidLookup(n))return;let s=this.extractFromKey(e,t),c=s.key;r=c;let l=s.namespaces;this.options.fallbackNS&&(l=l.concat(this.options.fallbackNS));let u=t.count!==void 0&&!U(t.count),d=u&&!t.ordinal&&t.count===0,f=t.context!==void 0&&(U(t.context)||typeof t.context==`number`)&&t.context!==``,p=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);l.forEach(e=>{this.isValidLookup(n)||(o=e,!this.checkedLoadedFor[`${p[0]}-${e}`]&&this.utils?.hasLoadedNamespace&&!this.utils?.hasLoadedNamespace(o)&&(this.checkedLoadedFor[`${p[0]}-${e}`]=!0,this.logger.warn(`key "${r}" for languages "${p.join(`, `)}" won't get resolved as namespace "${o}" was not yet loaded`,`This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`)),p.forEach(r=>{if(this.isValidLookup(n))return;a=r;let o=[c];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(o,c,r,e,t);else{let e;u&&(e=this.pluralResolver.getSuffix(r,t.count,t));let n=`${this.options.pluralSeparator}zero`,i=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(u&&(t.ordinal&&e.startsWith(i)&&o.push(c+e.replace(i,this.options.pluralSeparator)),o.push(c+e),d&&o.push(c+n)),f){let r=`${c}${this.options.contextSeparator||`_`}${t.context}`;o.push(r),u&&(t.ordinal&&e.startsWith(i)&&o.push(r+e.replace(i,this.options.pluralSeparator)),o.push(r+e),d&&o.push(r+n))}}let s;for(;s=o.pop();)this.isValidLookup(n)||(i=s,n=this.getResource(r,e,s,t))}))})}),{res:n,usedKey:r,exactUsedKey:i,usedLng:a,usedNS:o}}isValidLookup(e){return e!==void 0&&!(!this.options.returnNull&&e===null)&&!(!this.options.returnEmptyString&&e===``)}getResource(e,t,n,r={}){return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(e={}){let t=[`defaultValue`,`ordinal`,`context`,`replace`,`lng`,`lngs`,`fallbackLng`,`ns`,`keySeparator`,`nsSeparator`,`returnObjects`,`returnDetails`,`joinArrays`,`postProcess`,`interpolation`],n=e.replace&&!U(e.replace),r=n?e.replace:e;if(n&&e.count!==void 0&&(r={...r,count:e.count}),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(let e of t)delete r[e]}return r}static hasDefaultValue(e){for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&t.startsWith(`defaultValue`)&&e[t]!==void 0)return!0;return!1}},Rv=class{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=kv.create(`languageUtils`)}getScriptPartFromCode(e){if(e=Dv(e),!e||!e.includes(`-`))return null;let t=e.split(`-`);return t.length===2||(t.pop(),t[t.length-1].toLowerCase()===`x`)?null:this.formatLanguageCode(t.join(`-`))}getLanguagePartFromCode(e){if(e=Dv(e),!e||!e.includes(`-`))return e;let t=e.split(`-`);return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(U(e)&&e.includes(`-`)){let t;try{t=Intl.getCanonicalLocales(e)[0]}catch{}return t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return(this.options.load===`languageOnly`||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.includes(e)}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;let n=this.formatLanguageCode(e);(!this.options.supportedLngs||this.isSupportedCode(n))&&(t=n)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;let n=this.getScriptPartFromCode(e);if(this.isSupportedCode(n))return t=n;let r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(e=>e===r?!0:!e.includes(`-`)&&!r.includes(`-`)?!1:!!(e.includes(`-`)&&!r.includes(`-`)&&e.slice(0,e.indexOf(`-`))===r||e.startsWith(r)&&r.length>1))}),t||=this.getFallbackCodes(this.options.fallbackLng)[0],t}getFallbackCodes(e,t){if(!e)return[];if(typeof e==`function`&&(e=e(t)),U(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||=e[this.getScriptPartFromCode(t)],n||=e[this.formatLanguageCode(t)],n||=e[this.getLanguagePartFromCode(t)],n||=e.default,n||[]}toResolveHierarchy(e,t){let n=this.getFallbackCodes((t===!1?[]:t)||this.options.fallbackLng||[],e),r=[],i=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return U(e)&&(e.includes(`-`)||e.includes(`_`))?(this.options.load!==`languageOnly`&&i(this.formatLanguageCode(e)),this.options.load!==`languageOnly`&&this.options.load!==`currentOnly`&&i(this.getScriptPartFromCode(e)),this.options.load!==`currentOnly`&&i(this.getLanguagePartFromCode(e))):U(e)&&i(this.formatLanguageCode(e)),n.forEach(e=>{r.includes(e)||i(this.formatLanguageCode(e))}),r}},zv={zero:0,one:1,two:2,few:3,many:4,other:5},Bv={select:e=>e===1?`one`:`other`,resolvedOptions:()=>({pluralCategories:[`one`,`other`]})},Vv=class{constructor(e,t={}){this.languageUtils=e,this.options=t,this.logger=kv.create(`pluralResolver`),this.pluralRulesCache={}}clearCache(){this.pluralRulesCache={}}getRule(e,t={}){let n=Dv(e===`dev`?`en`:e),r=t.ordinal?`ordinal`:`cardinal`,i=JSON.stringify({cleanedCode:n,type:r});if(i in this.pluralRulesCache)return this.pluralRulesCache[i];let a;try{a=new Intl.PluralRules(n,{type:r})}catch{if(typeof Intl>`u`)return this.logger.error(`No Intl support, please use an Intl polyfill!`),Bv;if(!e.match(/-|_/))return Bv;let n=this.languageUtils.getLanguagePartFromCode(e);a=this.getRule(n,t)}return this.pluralRulesCache[i]=a,a}needsPlural(e,t={}){let n=this.getRule(e,t);return n||=this.getRule(`dev`,t),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t,n={}){return this.getSuffixes(e,n).map(e=>`${t}${e}`)}getSuffixes(e,t={}){let n=this.getRule(e,t);return n||=this.getRule(`dev`,t),n?n.resolvedOptions().pluralCategories.sort((e,t)=>zv[e]-zv[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:``}${e}`):[]}getSuffix(e,t,n={}){let r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:``}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix(`dev`,t,n))}},Hv=(e,t,n,r=`.`,i=!0)=>{let a=_v(e,t,n);return!a&&i&&U(n)&&(a=Ev(e,n,r),a===void 0&&(a=Ev(t,n,r))),a},Uv=e=>e.replace(/\$/g,`$$$$`),Wv=class{constructor(e={}){this.logger=kv.create(`interpolator`),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(e={}){e.interpolation||={escapeValue:!0};let{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:i,prefixEscaped:a,suffix:o,suffixEscaped:s,formatSeparator:c,unescapeSuffix:l,unescapePrefix:u,nestingPrefix:d,nestingPrefixEscaped:f,nestingSuffix:p,nestingSuffixEscaped:m,nestingOptionsSeparator:h,maxReplaces:g,alwaysFormat:_}=e.interpolation;this.escape=t===void 0?xv:t,this.escapeValue=n===void 0||n,this.useRawValueToEscape=r!==void 0&&r,this.prefix=i?yv(i):a||`{{`,this.suffix=o?yv(o):s||`}}`,this.formatSeparator=c||`,`,this.unescapePrefix=l?``:u?yv(u):`-`,this.unescapeSuffix=this.unescapePrefix?``:l?yv(l):``,this.nestingPrefix=d?yv(d):f||yv(`$t(`),this.nestingSuffix=p?yv(p):m||yv(`)`),this.nestingOptionsSeparator=h||`,`,this.maxReplaces=g||1e3,this.alwaysFormat=_!==void 0&&_,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){let e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,`g`);this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}((?:[^()"']+|"[^"]*"|'[^']*'|\\((?:[^()]|"[^"]*"|'[^']*')*\\))*?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let i,a,o,s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=e=>{if(!e.includes(this.formatSeparator)){let i=Hv(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(i,void 0,n,{...r,...t,interpolationkey:e}):i}let i=e.split(this.formatSeparator),a=i.shift().trim(),o=i.join(this.formatSeparator).trim();return this.format(Hv(t,s,a,this.options.keySeparator,this.options.ignoreJSONStructure),o,n,{...r,...t,interpolationkey:a})};this.resetRegExp(),!this.escapeValue&&typeof e==`string`&&/\$t\([^)]*\{[^}]*\{\{/.test(e)&&this.logger.warn(`nesting options string contains interpolated variables with escapeValue: false — if any of those values are attacker-controlled they can inject additional nesting options (e.g. redirect lng/ns). Sanitise untrusted input before passing it to t(), or keep escapeValue: true.`);let l=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,u=r?.interpolation?.skipOnVariables===void 0?this.options.interpolation.skipOnVariables:r.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>e},{regex:this.regexp,safeValue:e=>this.escapeValue?this.escape(e):e}].forEach(t=>{for(o=0;i=t.regex.exec(e);){let n=i[1].trim();if(a=c(n),a===void 0){if(typeof l==`function`){let t=l(e,i,r);a=U(t)?t:``}else if(r&&Object.prototype.hasOwnProperty.call(r,n))a=``;else if(u){a=i[0];continue}else this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),a=``}else!U(a)&&!this.useRawValueToEscape&&(a=cv(a));let s=t.safeValue(a);if(e=e.replace(i[0],Uv(s)),u?(t.regex.lastIndex+=s.length,t.regex.lastIndex-=i[0].length):t.regex.lastIndex=0,o++,o>=this.maxReplaces)break}}),e}nest(e,t,n={}){let r,i,a,o=(e,t)=>{let n=this.nestingOptionsSeparator;if(!e.includes(n))return e;let r=e.split(RegExp(`${yv(n)}[ ]*{`)),i=`{${r[1]}`;e=r[0],i=this.interpolate(i,a);let o=i.match(/'/g),s=i.match(/"/g);((o?.length??0)%2==0&&!s||(s?.length??0)%2!=0)&&(i=i.replace(/'/g,`"`));try{a=JSON.parse(i),t&&(a={...t,...a})}catch(t){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,t),`${e}${n}${i}`}return a.defaultValue&&a.defaultValue.includes(this.prefix)&&delete a.defaultValue,e};for(;r=this.nestingRegexp.exec(e);){let s=[];a={...n},a=a.replace&&!U(a.replace)?a.replace:a,a.applyPostProcessor=!1,delete a.defaultValue;let c=/{.*}/s.test(r[1])?r[1].lastIndexOf(`}`)+1:r[1].indexOf(this.formatSeparator);if(c!==-1&&(s=r[1].slice(c).split(this.formatSeparator).map(e=>e.trim()).filter(Boolean),r[1]=r[1].slice(0,c)),i=t(o.call(this,r[1].trim(),a),a),i&&r[0]===e&&!U(i))return i;U(i)||(i=cv(i)),i||=(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),``),s.length&&(i=s.reduce((e,t)=>this.format(e,t,n.lng,{...n,interpolationkey:r[1].trim()}),i.trim())),e=e.replace(r[0],i),this.regexp.lastIndex=0}return e}},Gv=e=>{let t=e.toLowerCase().trim(),n={};if(e.includes(`(`)){let r=e.split(`(`);t=r[0].toLowerCase().trim();let i=r[1].slice(0,-1);t===`currency`&&!i.includes(`:`)?n.currency||=i.trim():t===`relativetime`&&!i.includes(`:`)?n.range||=i.trim():i.split(`;`).forEach(e=>{if(e){let[t,...r]=e.split(`:`),i=r.join(`:`).trim().replace(/^'+|'+$/g,``),a=t.trim();n[a]||(n[a]=i),i===`false`&&(n[a]=!1),i===`true`&&(n[a]=!0),isNaN(i)||(n[a]=parseInt(i,10))}})}return{formatName:t,formatOptions:n}},Kv=e=>{let t={};return(n,r,i)=>{let a=i;i&&i.interpolationkey&&i.formatParams&&i.formatParams[i.interpolationkey]&&i[i.interpolationkey]&&(a={...a,[i.interpolationkey]:void 0});let o=r+JSON.stringify(a),s=t[o];return s||(s=e(Dv(r),i),t[o]=s),s(n)}},qv=e=>(t,n,r)=>e(Dv(n),r)(t),Jv=class{constructor(e={}){this.logger=kv.create(`formatter`),this.options=e,this.init(e)}init(e,t={interpolation:{}}){this.formatSeparator=t.interpolation.formatSeparator||`,`;let n=t.cacheInBuiltFormats?Kv:qv;this.formats={number:n((e,t)=>{let n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)}),currency:n((e,t)=>{let n=new Intl.NumberFormat(e,{...t,style:`currency`});return e=>n.format(e)}),datetime:n((e,t)=>{let n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)}),relativetime:n((e,t)=>{let n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||`day`)}),list:n((e,t)=>{let n=new Intl.ListFormat(e,{...t});return e=>n.format(e)})}}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Kv(t)}format(e,t,n,r={}){if(!t||e==null)return e;let i=t.split(this.formatSeparator),a=[];for(let e=0;e<i.length;e++){let t=i[e];for(;t.indexOf(`(`)>-1&&!t.includes(`)`)&&e+1<i.length;)t=`${t}${this.formatSeparator}${i[++e]}`;a.push(t)}return a.reduce((e,t)=>{let{formatName:i,formatOptions:a}=Gv(t);if(this.formats[i]){let t=e;try{let o=r?.formatParams?.[r.interpolationkey]||{},s=o.locale||o.lng||r.locale||r.lng||n;t=this.formats[i](e,s,{...a,...r,...o})}catch(e){this.logger.warn(e)}return t}return this.logger.warn(`there was no format function for ${i}`),e},e)}},Yv=(e,t)=>{e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)},Xv=class extends Av{constructor(e,t,n,r={}){super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=kv.create(`backendConnector`),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){let i={},a={},o={},s={};return e.forEach(e=>{let r=!0;t.forEach(t=>{let o=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[o]=2:this.state[o]<0||(this.state[o]===1?a[o]===void 0&&(a[o]=!0):(this.state[o]=1,r=!1,a[o]===void 0&&(a[o]=!0),i[o]===void 0&&(i[o]=!0),s[t]===void 0&&(s[t]=!0)))}),r||(o[e]=!0)}),(Object.keys(i).length||Object.keys(a).length)&&this.queue.push({pending:a,pendingCount:Object.keys(a).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(i),pending:Object.keys(a),toLoadLanguages:Object.keys(o),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){let r=e.split(`|`),i=r[0],a=r[1];t&&this.emit(`failedLoading`,i,a,t),!t&&n&&this.store.addResourceBundle(i,a,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);let o={};this.queue.forEach(n=>{hv(n.loaded,[i],a),Yv(n,e),t&&n.errors.push(t),n.pendingCount===0&&!n.done&&(Object.keys(n.loaded).forEach(e=>{o[e]||(o[e]={});let t=n.loaded[e];t.length&&t.forEach(t=>{o[e][t]===void 0&&(o[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit(`loaded`,o),this.queue=this.queue.filter(e=>!e.done)}read(e,t,n,r=0,i=this.retryTimeout,a){if(!e.length)return a(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:i,callback:a});return}this.readingCalls++;let o=(o,s)=>{if(this.readingCalls--,this.waitingReads.length>0){let e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}if(o&&s&&r<this.maxRetries){setTimeout(()=>{this.read(e,t,n,r+1,i*2,a)},i);return}a(o,s)},s=this.backend[n].bind(this.backend);if(s.length===2){try{let n=s(e,t);n&&typeof n.then==`function`?n.then(e=>o(null,e)).catch(o):o(null,n)}catch(e){o(e)}return}return s(e,t,o)}prepareLoading(e,t,n={},r){if(!this.backend)return this.logger.warn(`No backend was added via i18next.use. Will not load resources.`),r&&r();U(e)&&(e=this.languageUtils.toResolveHierarchy(e)),U(t)&&(t=[t]);let i=this.queueLoad(e,t,n,r);if(!i.toLoad.length)return i.pending.length||r(),null;i.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e,t=``){let n=e.split(`|`),r=n[0],i=n[1];this.read(r,i,`read`,void 0,void 0,(n,a)=>{n&&this.logger.warn(`${t}loading namespace ${i} for language ${r} failed`,n),!n&&a&&this.logger.log(`${t}loaded namespace ${i} for language ${r}`,a),this.loaded(e,n,a)})}saveMissing(e,t,n,r,i,a={},o=()=>{}){if(this.services?.utils?.hasLoadedNamespace&&!this.services?.utils?.hasLoadedNamespace(t)){this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,`This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`);return}if(n!=null&&n!==``){if(this.backend?.create){let s={...a,isUpdate:i},c=this.backend.create.bind(this.backend);if(c.length<6)try{let i;i=c.length===5?c(e,t,n,r,s):c(e,t,n,r),i&&typeof i.then==`function`?i.then(e=>o(null,e)).catch(o):o(null,i)}catch(e){o(e)}else c(e,t,n,r,o,s)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}},Zv=()=>({debug:!1,initAsync:!0,ns:[`translation`],defaultNS:[`translation`],fallbackLng:[`dev`],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:`all`,preload:!1,keySeparator:`.`,nsSeparator:`:`,pluralSeparator:`_`,contextSeparator:`_`,enableSelector:!1,partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:`fallback`,saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if(typeof e[1]==`object`&&(t=e[1]),U(e[1])&&(t.defaultValue=e[1]),U(e[2])&&(t.tDescription=e[2]),typeof e[2]==`object`||typeof e[3]==`object`){let n=e[3]||e[2];Object.keys(n).forEach(e=>{t[e]=n[e]})}return t},interpolation:{escapeValue:!0,prefix:`{{`,suffix:`}}`,formatSeparator:`,`,unescapePrefix:`-`,nestingPrefix:`$t(`,nestingSuffix:`)`,nestingOptionsSeparator:`,`,maxReplaces:1e3,skipOnVariables:!0},cacheInBuiltFormats:!0}),Qv=e=>(U(e.ns)&&(e.ns=[e.ns]),U(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),U(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&!e.supportedLngs.includes(`cimode`)&&(e.supportedLngs=e.supportedLngs.concat([`cimode`])),e),$v=()=>{},ey=e=>{Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(t=>{typeof e[t]==`function`&&(e[t]=e[t].bind(e))})},ty=class e extends Av{constructor(e={},t){if(super(),this.options=Qv(e),this.services={},this.logger=kv,this.modules={external:[]},ey(this),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(e={},t){this.isInitializing=!0,typeof e==`function`&&(t=e,e={}),e.defaultNS==null&&e.ns&&(U(e.ns)?e.defaultNS=e.ns:e.ns.includes(`translation`)||(e.defaultNS=e.ns[0]));let n=Zv();this.options={...n,...this.options,...Qv(e)},this.options.interpolation={...n.interpolation,...this.options.interpolation},e.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=e.keySeparator),e.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=e.nsSeparator),typeof this.options.overloadTranslationOptionHandler!=`function`&&(this.options.overloadTranslationOptionHandler=n.overloadTranslationOptionHandler);let r=e=>e?typeof e==`function`?new e:e:null;if(!this.options.isClone){this.modules.logger?kv.init(r(this.modules.logger),this.options):kv.init(null,this.options);let e;e=this.modules.formatter?this.modules.formatter:Jv;let t=new Rv(this.options);this.store=new jv(this.options.resources,this.options);let n=this.services;n.logger=kv,n.resourceStore=this.store,n.languageUtils=t,n.pluralResolver=new Vv(t,{prepend:this.options.pluralSeparator}),e&&(n.formatter=r(e),n.formatter.init&&n.formatter.init(n,this.options),this.options.interpolation.format=n.formatter.format.bind(n.formatter)),n.interpolator=new Wv(this.options),n.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},n.backendConnector=new Xv(r(this.modules.backend),n.resourceStore,n,this.options),n.backendConnector.on(`*`,(e,...t)=>{this.emit(e,...t)}),this.modules.languageDetector&&(n.languageDetector=r(this.modules.languageDetector),n.languageDetector.init&&n.languageDetector.init(n,this.options.detection,this.options)),this.modules.i18nFormat&&(n.i18nFormat=r(this.modules.i18nFormat),n.i18nFormat.init&&n.i18nFormat.init(this)),this.translator=new Lv(this.services,this.options),this.translator.on(`*`,(e,...t)=>{this.emit(e,...t)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,t||=$v,this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){let e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&e[0]!==`dev`&&(this.options.lng=e[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn(`init: no languageDetector is used and no lng is defined`),[`getResource`,`hasResourceBundle`,`getResourceBundle`,`getDataByLanguage`].forEach(e=>{this[e]=(...t)=>this.store[e](...t)}),[`addResource`,`addResources`,`addResourceBundle`,`removeResourceBundle`].forEach(e=>{this[e]=(...t)=>(this.store[e](...t),this)});let i=sv(),a=()=>{let e=(e,n)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn(`init: i18next is already initialized. You should call init just once!`),this.isInitialized=!0,this.options.isClone||this.logger.log(`initialized`,this.options),this.emit(`initialized`,this.options),i.resolve(n),t(e,n)};if((this.languages||this.isLanguageChangingTo)&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?a():setTimeout(a,0),i}loadResources(e,t=$v){let n=t,r=U(e)?e:this.language;if(typeof e==`function`&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(r?.toLowerCase()===`cimode`&&(!this.options.preload||this.options.preload.length===0))return n();let e=[],t=t=>{t&&t!==`cimode`&&this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{t!==`cimode`&&(e.includes(t)||e.push(t))})};r?t(r):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>t(e)),this.options.preload?.forEach?.(e=>t(e)),this.services.backendConnector.load(e,this.options.ns,e=>{!e&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),n(e)})}else n(null)}reloadResources(e,t,n){let r=sv();return typeof e==`function`&&(n=e,e=void 0),typeof t==`function`&&(n=t,t=void 0),e||=this.languages,t||=this.options.ns,n||=$v,this.services.backendConnector.reload(e,t,e=>{r.resolve(),n(e)}),r}use(e){if(!e)throw Error(`You are passing an undefined module! Please check the object you are passing to i18next.use()`);if(!e.type)throw Error(`You are passing a wrong module! Please check the object you are passing to i18next.use()`);return e.type===`backend`&&(this.modules.backend=e),(e.type===`logger`||e.log&&e.warn&&e.error)&&(this.modules.logger=e),e.type===`languageDetector`&&(this.modules.languageDetector=e),e.type===`i18nFormat`&&(this.modules.i18nFormat=e),e.type===`postProcessor`&&Mv.addPostProcessor(e),e.type===`formatter`&&(this.modules.formatter=e),e.type===`3rdParty`&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&![`cimode`,`dev`].includes(e)){for(let e=0;e<this.languages.length;e++){let t=this.languages[e];if(![`cimode`,`dev`].includes(t)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}!this.resolvedLanguage&&!this.languages.includes(e)&&this.store.hasLanguageSomeTranslations(e)&&(this.resolvedLanguage=e,this.languages.unshift(e))}}changeLanguage(e,t){this.isLanguageChangingTo=e;let n=sv();this.emit(`languageChanging`,e);let r=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(i,a)=>{a?this.isLanguageChangingTo===e&&(r(a),this.translator.changeLanguage(a),this.isLanguageChangingTo=void 0,this.emit(`languageChanged`,a),this.logger.log(`languageChanged`,a)):this.isLanguageChangingTo=void 0,n.resolve((...e)=>this.t(...e)),t&&t(i,(...e)=>this.t(...e))},a=t=>{!e&&!t&&this.services.languageDetector&&(t=[]);let n=U(t)?t:t&&t[0],a=this.store.hasLanguageSomeTranslations(n)?n:this.services.languageUtils.getBestMatchFromCodes(U(t)?[t]:t);a&&(this.language||r(a),this.translator.language||this.translator.changeLanguage(a),this.services.languageDetector?.cacheUserLanguage?.(a)),this.loadResources(a,e=>{i(e,a)})};return!e&&this.services.languageDetector&&!this.services.languageDetector.async?a(this.services.languageDetector.detect()):!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e),n}getFixedT(e,t,n,r){let i=r?.scopeNs,a=(e,t,...r)=>{let o;o=typeof t==`object`?{...t}:this.options.overloadTranslationOptionHandler([e,t].concat(r)),o.lng=o.lng||a.lng,o.lngs=o.lngs||a.lngs;let s=o.ns!==void 0&&o.ns!==null;o.ns=o.ns||a.ns,o.keyPrefix!==``&&(o.keyPrefix=o.keyPrefix||n||a.keyPrefix);let c={...this.options,...o};Array.isArray(i)&&!s&&(c.ns=i),typeof o.keyPrefix==`function`&&(o.keyPrefix=Fv(o.keyPrefix,c));let l=this.options.keySeparator||`.`,u;return o.keyPrefix&&Array.isArray(e)?u=e.map(e=>(typeof e==`function`&&(e=Fv(e,c)),`${o.keyPrefix}${l}${e}`)):(typeof e==`function`&&(e=Fv(e,c)),u=o.keyPrefix?`${o.keyPrefix}${l}${e}`:e),this.t(u,o)};return U(e)?a.lng=e:a.lngs=e,a.ns=t,a.keyPrefix=n,a}t(...e){return this.translator?.translate(...e)}exists(...e){return this.translator?.exists(...e)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e,t={}){if(!this.isInitialized)return this.logger.warn(`hasLoadedNamespace: i18next was not initialized`,this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn(`hasLoadedNamespace: i18n.languages were undefined or empty`,this.languages),!1;let n=t.lng||this.resolvedLanguage||this.languages[0],r=this.options?this.options.fallbackLng:!1,i=this.languages[this.languages.length-1];if(n.toLowerCase()===`cimode`)return!0;let a=(e,t)=>{let n=this.services.backendConnector.state[`${e}|${t}`];return n===-1||n===0||n===2};if(t.precheck){let e=t.precheck(this,a);if(e!==void 0)return e}return!!(this.hasResourceBundle(n,e)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||a(n,e)&&(!r||a(i,e)))}loadNamespaces(e,t){let n=sv();return this.options.ns?(U(e)&&(e=[e]),e.forEach(e=>{this.options.ns.includes(e)||this.options.ns.push(e)}),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){let n=sv();U(e)&&(e=[e]);let r=this.options.preload||[],i=e.filter(e=>!r.includes(e)&&this.services.languageUtils.isSupportedCode(e));return i.length?(this.options.preload=r.concat(i),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language),!e)return`rtl`;try{let t=new Intl.Locale(e);if(t&&t.getTextInfo){let e=t.getTextInfo();if(e&&e.direction)return e.direction}}catch{}let t=`ar.shu.sqr.ssh.xaa.yhd.yud.aao.abh.abv.acm.acq.acw.acx.acy.adf.ads.aeb.aec.afb.ajp.apc.apd.arb.arq.ars.ary.arz.auz.avl.ayh.ayl.ayn.ayp.bbz.pga.he.iw.ps.pbt.pbu.pst.prp.prd.ug.ur.ydd.yds.yih.ji.yi.hbo.men.xmn.fa.jpr.peo.pes.prs.dv.sam.ckb`.split(`.`),n=this.services?.languageUtils||new Rv(Zv());return e.toLowerCase().indexOf(`-latn`)>1?`ltr`:t.includes(n.getLanguagePartFromCode(e))||e.toLowerCase().indexOf(`-arab`)>1?`rtl`:`ltr`}static createInstance(t={},n){let r=new e(t,n);return r.createInstance=e.createInstance,r}cloneInstance(t={},n=$v){let r=t.forkResourceStore;r&&delete t.forkResourceStore;let i={...this.options,...t,isClone:!0},a=new e(i);if((t.debug!==void 0||t.prefix!==void 0)&&(a.logger=a.logger.clone(t)),[`store`,`services`,`language`].forEach(e=>{a[e]=this[e]}),a.services={...this.services},a.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},r&&(a.store=new jv(Object.keys(this.store.data).reduce((e,t)=>(e[t]={...this.store.data[t]},e[t]=Object.keys(e[t]).reduce((n,r)=>(n[r]={...e[t][r]},n),e[t]),e),{}),i),a.services.resourceStore=a.store),t.interpolation){let e={...Zv().interpolation,...this.options.interpolation,...t.interpolation},n={...i,interpolation:e};a.services.interpolator=new Wv(n)}return a.translator=new Lv(a.services,i),a.translator.on(`*`,(e,...t)=>{a.emit(e,...t)}),a.init(i,n),a.translator.options=i,a.translator.backendConnector.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},a}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}.createInstance();ty.createInstance,ty.dir,ty.init,ty.loadResources,ty.reloadResources,ty.use,ty.changeLanguage,ty.getFixedT,ty.t,ty.exists,ty.setDefaultNamespace,ty.hasLoadedNamespace,ty.loadNamespaces,ty.loadLanguages;var ny=c((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function ee(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var te=/\/+/g;function ne(e,t){return typeof e==`object`&&e&&e.key!=null?ee(``+e.key):t.toString(36)}function re(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function k(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,k(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+ne(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(te,`$&/`)+`/`),k(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(te,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+ne(a,u),c+=k(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+ne(a,u++),c+=k(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return k(re(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function A(e,t,n){if(e==null)return e;var r=[],i=0;return k(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function ie(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var ae=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},oe={map:A,forEach:function(e,t,n){A(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return A(e,function(){t++}),t},toArray:function(e){return A(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=oe,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:ie}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,ae)}catch(e){ae(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()},e.version=`19.2.8`})),ry=c(((e,t)=>{t.exports=ny()})),iy=(e,t,n,r)=>{let i=[n,{code:t,...r||{}}];if(e?.services?.logger?.forward)return e.services.logger.forward(i,`warn`,`react-i18next::`,!0);dy(i[0])&&(i[0]=`react-i18next:: ${i[0]}`),e?.services?.logger?.warn?e.services.logger.warn(...i):console?.warn&&console.warn(...i)},ay={},oy=(e,t,n,r)=>{dy(n)&&ay[n]||(dy(n)&&(ay[n]=new Date),iy(e,t,n,r))},sy=(e,t)=>()=>{if(e.isInitialized)t();else{let n=()=>{setTimeout(()=>{e.off(`initialized`,n)},0),t()};e.on(`initialized`,n)}},cy=(e,t,n)=>{e.loadNamespaces(t,sy(e,n))},ly=(e,t,n,r)=>{if(dy(n)&&(n=[n]),e.options.preload&&e.options.preload.indexOf(t)>-1)return cy(e,n,r);n.forEach(t=>{e.options.ns.indexOf(t)<0&&e.options.ns.push(t)}),e.loadLanguages(t,sy(e,r))},uy=(e,t,n={})=>!t.languages||!t.languages.length?(oy(t,`NO_LANGUAGES`,`i18n.languages were undefined or empty`,{languages:t.languages}),!0):t.hasLoadedNamespace(e,{lng:n.lng,precheck:(t,r)=>{if(n.bindI18n&&n.bindI18n.indexOf(`languageChanging`)>-1&&t.services.backendConnector.backend&&t.isLanguageChangingTo&&!r(t.isLanguageChangingTo,e))return!1}}),dy=e=>typeof e==`string`,fy=e=>typeof e==`object`&&!!e,py=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,my={"&amp;":`&`,"&#38;":`&`,"&lt;":`<`,"&#60;":`<`,"&gt;":`>`,"&#62;":`>`,"&apos;":`'`,"&#39;":`'`,"&quot;":`"`,"&#34;":`"`,"&nbsp;":` `,"&#160;":` `,"&copy;":`©`,"&#169;":`©`,"&reg;":`®`,"&#174;":`®`,"&hellip;":`…`,"&#8230;":`…`,"&#x2F;":`/`,"&#47;":`/`},hy=e=>my[e],gy={bindI18n:`languageChanged`,bindI18nStore:``,transEmptyNodeValue:``,transSupportBasicHtmlNodes:!0,transWrapTextNodes:``,transKeepBasicHtmlNodesFor:[`br`,`strong`,`i`,`p`],useSuspense:!0,unescape:e=>e.replace(py,hy),transDefaultProps:void 0},_y=(e={})=>{gy={...gy,...e}},vy=()=>gy,yy,by=e=>{yy=e},xy=()=>yy,Sy={type:`3rdParty`,init(e){_y(e.options.react),by(e)}},W=d(ry()),Cy=(0,W.createContext)(),wy=class{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(e=>{this.usedNamespaces[e]||(this.usedNamespaces[e]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}},Ty=c((e=>{var t=ry();function n(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var r=typeof Object.is==`function`?Object.is:n,i=t.useState,a=t.useEffect,o=t.useLayoutEffect,s=t.useDebugValue;function c(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),c=r[0].inst,u=r[1];return o(function(){c.value=n,c.getSnapshot=t,l(c)&&u({inst:c})},[e,n,t]),a(function(){return l(c)&&u({inst:c}),e(function(){l(c)&&u({inst:c})})},[e]),s(n),n}function l(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!r(e,n)}catch{return!0}}function u(e,t){return t()}var d=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?u:c;e.useSyncExternalStore=t.useSyncExternalStore===void 0?d:t.useSyncExternalStore})),Ey=c(((e,t)=>{t.exports=Ty()}))(),Dy={t:(e,t)=>{if(dy(t))return t;if(fy(t)&&dy(t.defaultValue))return t.defaultValue;if(typeof e==`function`)return``;if(Array.isArray(e)){let t=e[e.length-1];return typeof t==`function`?``:t}return e},ready:!1},Oy=()=>()=>{},ky=(e,t={})=>{let{i18n:n}=t,{i18n:r,defaultNS:i}=(0,W.useContext)(Cy)||{},a=n||r||xy();a&&!a.reportNamespaces&&(a.reportNamespaces=new wy),a||oy(a,`NO_I18NEXT_INSTANCE`,`useTranslation: You will need to pass in an i18next instance by using initReactI18next or by passing it via props or context. In monorepo setups, make sure there is only one instance of react-i18next.`);let o=(0,W.useMemo)(()=>({...vy(),...a?.options?.react,...t}),[a,t]),{useSuspense:s,keyPrefix:c}=o,l=e||i||a?.options?.defaultNS,u=dy(l)?[l]:l||[`translation`],d=(0,W.useMemo)(()=>u,u);a?.reportNamespaces?.addUsedNamespaces?.(d);let f=(0,W.useRef)(0),p=(0,W.useCallback)(e=>{if(!a)return Oy;let{bindI18n:t,bindI18nStore:n}=o,r=()=>{f.current+=1,e()};return t&&a.on(t,r),n&&a.store.on(n,r),()=>{t&&t.split(` `).forEach(e=>a.off(e,r)),n&&n.split(` `).forEach(e=>a.store.off(e,r))}},[a,o]),m=(0,W.useRef)(),h=(0,W.useCallback)(()=>{if(!a)return Dy;let e=!!(a.isInitialized||a.initializedStoreOnce)&&d.every(e=>uy(e,a,o)),n=t.lng||a.language,r=f.current,i=m.current;if(i&&i.ready===e&&i.lng===n&&i.keyPrefix===c&&i.revision===r)return i;let s={t:a.getFixedT(n,o.nsMode===`fallback`?d:d[0],c,{scopeNs:d}),ready:e,lng:n,keyPrefix:c,revision:r};return m.current=s,s},[a,d,c,o,t.lng]),[g,_]=(0,W.useState)(0),{t:v,ready:y}=(0,Ey.useSyncExternalStore)(p,h,h);(0,W.useEffect)(()=>{if(a&&!y&&!s){let e=()=>_(e=>e+1);t.lng?ly(a,t.lng,d,e):cy(a,d,e)}},[a,t.lng,d,y,s,g]);let b=a||{},x=(0,W.useRef)(null),S=(0,W.useRef)(),C=e=>{let t=Object.getOwnPropertyDescriptors(e);t.__original&&delete t.__original;let n=Object.create(Object.getPrototypeOf(e),t);if(!Object.prototype.hasOwnProperty.call(n,`__original`))try{Object.defineProperty(n,"__original",{value:e,writable:!1,enumerable:!1,configurable:!1})}catch{}return n},w=(0,W.useMemo)(()=>{let e=b,t=e?.language,n=e;e&&(x.current&&x.current.__original===e&&S.current===t?n=x.current:(n=C(e),x.current=n,S.current=t));let r=!y&&!s?(...e)=>(oy(a,`USE_T_BEFORE_READY`,`useTranslation: t was called before ready. When using useSuspense: false, make sure to check the ready flag before using t.`),v(...e)):v,i=[r,n,y];return i.t=r,i.i18n=n,i.ready=y,i},[v,b,y,b.resolvedLanguage,b.language,b.languages]);if(a&&s&&!y){let e=!1;try{e=!1}catch{}throw e&&oy(a,`SUSPENDED_WHILE_LOADING`,`useTranslation: suspended while translations are loading (useSuspense is true by default). Add a <Suspense> boundary above this component, or set react.useSuspense: false in the i18next init options. https://react.i18next.com/latest/usetranslation-hook`),new Promise(e=>{let n=()=>e();t.lng?ly(a,t.lng,d,n):cy(a,d,n)})}return w},{slice:Ay,forEach:jy}=[];function My(e){return jy.call(Ay.call(arguments,1),t=>{if(t)for(let n in t)e[n]===void 0&&(e[n]=t[n])}),e}function Ny(e){return typeof e==`string`&&[/<\s*script.*?>/i,/<\s*\/\s*script\s*>/i,/<\s*img.*?on\w+\s*=/i,/<\s*\w+\s*on\w+\s*=.*?>/i,/javascript\s*:/i,/vbscript\s*:/i,/expression\s*\(/i,/eval\s*\(/i,/alert\s*\(/i,/document\.cookie/i,/document\.write\s*\(/i,/window\.location/i,/innerHTML/i].some(t=>t.test(e))}var Py=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,Fy=function(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{path:`/`},r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){let e=n.maxAge-0;if(Number.isNaN(e))throw Error(`maxAge should be a Number`);r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!Py.test(n.domain))throw TypeError(`option domain is invalid`);r+=`; Domain=${n.domain}`}if(n.path){if(!Py.test(n.path))throw TypeError(`option path is invalid`);r+=`; Path=${n.path}`}if(n.expires){if(typeof n.expires.toUTCString!=`function`)throw TypeError(`option expires is invalid`);r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+=`; HttpOnly`),n.secure&&(r+=`; Secure`),n.sameSite)switch(typeof n.sameSite==`string`?n.sameSite.toLowerCase():n.sameSite){case!0:r+=`; SameSite=Strict`;break;case`lax`:r+=`; SameSite=Lax`;break;case`strict`:r+=`; SameSite=Strict`;break;case`none`:r+=`; SameSite=None`;break;default:throw TypeError(`option sameSite is invalid`)}return n.partitioned&&(r+=`; Partitioned`),r},Iy={create(e,t,n,r){let i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:`/`,sameSite:`strict`};n&&(i.expires=new Date,i.expires.setTime(i.expires.getTime()+n*60*1e3)),r&&(i.domain=r),document.cookie=Fy(e,t,i)},read(e){let t=`${e}=`,n=document.cookie.split(`;`);for(let e=0;e<n.length;e++){let r=n[e];for(;r.charAt(0)===` `;)r=r.substring(1,r.length);if(r.indexOf(t)===0)return r.substring(t.length,r.length)}return null},remove(e,t){this.create(e,``,-1,t)}},Ly={name:`cookie`,lookup(e){let{lookupCookie:t}=e;if(t&&typeof document<`u`)return Iy.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:i,cookieOptions:a}=t;n&&typeof document<`u`&&Iy.create(n,e,r,i,a)}},Ry={name:`querystring`,lookup(e){let{lookupQuerystring:t}=e,n;if(typeof window<`u`){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf(`?`)>-1&&(e=window.location.hash.substring(window.location.hash.indexOf(`?`)));let r=e.substring(1).split(`&`);for(let e=0;e<r.length;e++){let i=r[e].indexOf(`=`);i>0&&r[e].substring(0,i)===t&&(n=r[e].substring(i+1))}}return n}},zy={name:`hash`,lookup(e){let{lookupHash:t,lookupFromHashIndex:n}=e,r;if(typeof window<`u`){let{hash:e}=window.location;if(e&&e.length>2){let i=e.substring(1);if(t){let e=i.split(`&`);for(let n=0;n<e.length;n++){let i=e[n].indexOf(`=`);i>0&&e[n].substring(0,i)===t&&(r=e[n].substring(i+1))}}if(r)return r;if(!r&&n>-1){let t=e.match(/\/([a-zA-Z-]*)/g);return Array.isArray(t)?t[typeof n==`number`?n:0]?.replace(`/`,``):void 0}}}return r}},By=null,Vy=()=>{if(By!==null)return By;try{if(By=typeof window<`u`&&window.localStorage!==null,!By)return!1;let e=`i18next.translate.boo`;window.localStorage.setItem(e,`foo`),window.localStorage.removeItem(e)}catch{By=!1}return By},Hy={name:`localStorage`,lookup(e){let{lookupLocalStorage:t}=e;if(t&&Vy())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&Vy()&&window.localStorage.setItem(n,e)}},Uy=null,Wy=()=>{if(Uy!==null)return Uy;try{if(Uy=typeof window<`u`&&window.sessionStorage!==null,!Uy)return!1;let e=`i18next.translate.boo`;window.sessionStorage.setItem(e,`foo`),window.sessionStorage.removeItem(e)}catch{Uy=!1}return Uy},Gy={name:`sessionStorage`,lookup(e){let{lookupSessionStorage:t}=e;if(t&&Wy())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&Wy()&&window.sessionStorage.setItem(n,e)}},Ky={name:`navigator`,lookup(e){let t=[];if(typeof navigator<`u`){let{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let n=0;n<e.length;n++)t.push(e[n]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},qy={name:`htmlTag`,lookup(e){let{htmlTag:t}=e,n,r=t||(typeof document<`u`?document.documentElement:null);return r&&typeof r.getAttribute==`function`&&(n=r.getAttribute(`lang`)),n}},Jy={name:`path`,lookup(e){let{lookupFromPathIndex:t}=e;if(typeof window>`u`)return;let n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(Array.isArray(n))return n[typeof t==`number`?t:0]?.replace(`/`,``)}},Yy={name:`subdomain`,lookup(e){let{lookupFromSubdomainIndex:t}=e,n=typeof t==`number`?t+1:1,r=typeof window<`u`&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}},Xy=!1;try{document.cookie,Xy=!0}catch{}var Zy=[`querystring`,`cookie`,`localStorage`,`sessionStorage`,`navigator`,`htmlTag`];Xy||Zy.splice(1,1);var Qy=()=>({order:Zy,lookupQuerystring:`lng`,lookupCookie:`i18next`,lookupLocalStorage:`i18nextLng`,lookupSessionStorage:`i18nextLng`,caches:[`localStorage`],excludeCacheFor:[`cimode`],convertDetectedLanguage:e=>e}),$y=class{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type=`languageDetector`,this.detectors={},this.init(e,t)}init(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{languageUtils:{}},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=e,this.options=My(t,this.options||{},Qy()),typeof this.options.convertDetectedLanguage==`string`&&this.options.convertDetectedLanguage.indexOf(`15897`)>-1&&(this.options.convertDetectedLanguage=e=>e.replace(`-`,`_`)),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=n,this.addDetector(Ly),this.addDetector(Ry),this.addDetector(Hy),this.addDetector(Gy),this.addDetector(Ky),this.addDetector(qy),this.addDetector(Jy),this.addDetector(Yy),this.addDetector(zy)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.options.order,t=[];return e.forEach(e=>{if(this.detectors[e]){let n=this.detectors[e].lookup(this.options);n&&typeof n==`string`&&(n=[n]),n&&(t=t.concat(n))}}),t=t.filter(e=>e!=null&&!Ny(e)).map(e=>this.options.convertDetectedLanguage(e)),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?t:t.length>0?t[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach(t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)}))}};$y.type=`languageDetector`;var eb={pages:{popup:`pages.popup`},common:`common`,popover:`popover`,errors:`errors`,iconController:`iconController`,notifications:`notifications`,options:`options`,editor:`editor`},tb={de:`de`,en:`en`,fr:`fr`},nb={[eb.editor]:{toolbar:`Formatierung`,bold:`Fett`,italic:`Kursiv`,underline:`Unterstrichen`,heading:`Überschrift`,bulletList:`Aufzählung`,orderedList:`Nummerierte Liste`,quote:`Zitat`,undo:`Rückgängig`,redo:`Wiederholen`,settings:`Witty-Einstellungen`,closeSettings:`Einstellungen schliessen`,settingsLoading:`Einstellungen werden geladen …`,statusChecking:`Witty prüft den Text …`,statusAlerts_one:`{{count}} Hinweis`,statusAlerts_other:`{{count}} Hinweise`,statusNoAlerts:`Keine Hinweise`,statusUnauthorized:`API-Schlüssel fehlt oder wurde nicht akzeptiert`,statusFailed:`Prüfung fehlgeschlagen`,shortcutHint:`Mit Alt+Umschalt+W öffnest du den Hinweis an der Cursorposition.`,limitReached:`Nur ein Teil dieses Textes wurde geprüft.`,menu:`Witty-Menü`,menuSettings:`Einstellungen …`,menuSwitchGender:`Gender-Form wechseln …`,menuHelp:`Hilfe`,menuAbout:`Über Witty`,switchTitle:`Gender-Form wechseln`,switchIntro:`Schreibt alle gegenderten Formen im Text in die gewählte Form um. Mit Rückgängig machst du das in einem Schritt rückgängig.`,switchCurrent:`aktuell`,switching:`Der Text wird geprüft und umgeschrieben …`,switched_one:`{{count}} Form auf {{format}} umgestellt.`,switched_other:`{{count}} Formen auf {{format}} umgestellt.`,switchNothing:`Nichts umzustellen: Der Text verwendet bereits {{format}}.`,switchDisabled:`Das Wechseln der Gender-Form ist für dieses Konto ausgeschaltet.`,switchUnsupported:`Der Server unterstützt das Wechseln der Gender-Form noch nicht.`,switchInklusivum:`In das Inklusivum kann noch nicht gewechselt werden.`,switchForced:`Deine Organisation legt die Gender-Form auf {{format}} fest. Der Text wurde nicht geändert.`},[eb.options]:{languageHeadline:`Sprache und Gender-Formen`,genderedRolesFormat:`Generisches Maskulinum`,genderedRolesFormatHint:`Wie soll Witty mit dem generischen Maskulinum in gegenderten Sprachen umgehen?`,germanGenderEnding:`Deutsche Gender-Endung`,germanGenderEndingHint:`Witty empfiehlt den Gendestern.`,frenchGenderSeparator:`Französisches Gender-Trennzeichen`,frenchGenderSeparatorHint:`Witty empfiehlt den Point médian.`,useApiDefault:`Standard des Servers`,levelOff:`Aus`,levelBasic:`Basis`,levelAdvanced:`Erweitert`,levelLocked:`Immer aktiv`,categoriesFailed:`Kategorien konnten nicht geladen werden.`,helpOwnServer:`Eigenen Server einrichten`,helpWithoutDashboard:`Witty ohne Dashboard betreiben`,helpCentre:`Hilfe-Center`,settingsHeadline:`Witty Einstellungen`,connectionHeadline:`Verbindung`,modeAccount:`Konto (Anmeldung über Dashboard)`,modeApiKey:`API-Schlüssel (ohne Dashboard)`,apiKey:`API-Schlüssel`,apiKeyHint:`Wird als x-key an die NLP-API gesendet. Ein Dashboard wird nicht benötigt.`,apiKeyRequired:`API-Schlüssel ist erforderlich.`,customisationHeadline:`Anpassungen`,orthography:`Rechtschreibprüfung`,llmAlternatives:`KI-Vorschläge`,categoriesHeadline:`Kategorien`,categoriesIntro:`Abgewählte Kategorien werden nicht mehr hervorgehoben.`,orgOverrideNote:`Im Konto-Modus können diese Werte von den Vorgaben deiner Organisation überschrieben werden.`,endpointHeadline:`Eigener Server`,endpointIntro:`Zeigt Witty auf deine eigene Installation. Nur ändern, wenn du weisst, was du tust.`,endpointWarning:`Achtung: Der eingetragene Server erhält jeden Text, den du in Eingabefeldern schreibst. Trage nur eine Installation ein, der du vertraust.`,dashboardUrl:`Dashboard-URL`,apiUrl:`NLP-API-URL`,oauthClientId:`OAuth Client ID`,redirectUriHint:`Registriere diese Redirect-URI im OAuth-Client deines Dashboards:`,save:`Speichern und abmelden`,reset:`Auf Standard zurücksetzen`,saved:`Gespeichert. Du wurdest abgemeldet — bitte erneut anmelden.`,resetDone:`Auf Standard zurückgesetzt. Du wurdest abgemeldet.`,invalidUrl:`Bitte eine https-URL angeben (http nur für localhost).`,clientIdRequired:`OAuth Client ID ist erforderlich.`,signOutNotice:`Beim Wechsel des Servers wirst du abgemeldet: Tokens gelten immer nur für einen Server.`,currentEndpoint:`Aktuell verwendet`},[eb.common]:{buttons:{ok:`Akzeptieren`,cancel:`Abbrechen`},languages:{en_US:`Englisch (🇺🇸 USA)`,en_GB:`Englisch (🇬🇧 Vereinigtes Königreich)`,de_DE:`Deutsch (🇩🇪 Deutschland)`,de_AT:`Deutsch (🇦🇹 Österreich)`,de_CH:`Deutsch (🇨🇭 Schweiz)`,fr_FR:`Französisch (🇫🇷 Frankreich)`,fr_CH:`Französisch (🇨🇭 Schweiz)`}},[eb.pages.popup]:{helpCentre:`Hilfe-Center`,helpSignInFailed:`Hilfe zur Fehlersuche`,extensionSettings:`Erweiterungseinstellungen`,extensionSettingsHint:`Eigener Server, API-Schlüssel und Kategorien`,enableWitty:`Witty aktivieren`,websiteSettings:`Einstellungen für {{domain}}`,developmentSettings:`Entwicklungs-Einstellungen`,spellChecking:`Grammatik & Rechtschreibung`,thanks:`Danke für deinen Beitrag!`,noSupport:`Es tut uns leid! Witty unterstützt diese Webseite noch nicht offiziell.`,vote:`Stimme für diese Webseite ab`,editor:`Nutze stattdessen den Witty Editor`,goToDashboard:`Zum Witty Editor`,overrideRecomendedSites:`Witty hier dennoch aktivieren`,backToRecomendedSites:`Witty nur auf unterstützten Webseiten aktiv`,signedOutText:`Dir entgeht was`,loginToUnlock:`Jetzt anmelden!`,biasDetection:`Erkennung von über 30 Diversitätskategorieren`,inclusiveAlternatives:`Inklusive Alternativvorschläge`,teamFeatures:`Teamfunktionen, inkl. eines geteilten Wörterbuches`,signIn:`Anmelden`,signOut:`Abmelden`,haveAccount:`Hast du schon ein Konto?`,dontHaveAccount:`Hast du noch kein Konto?`,signUp:`Registrieren`,doesWittyWork:`Funktioniert Witty hier?`,doesWittyWorkExplanation:`Lass es uns wissen.`,tryAgain:`Erneut versuchen`,understood:`Verstanden`,websiteSettingsDeactivated:`Du hast uns mitgeteilt, dass Witty auf {{Domain}} nicht funktioniert.`,tryAgainOnThisWebsite:`Erneut auf dieser Website versuchen`,enableWittyFailed:`Currently unable to sync with the Witty Dashboard, try again later.`,lockedInfo:`Diese Funktion wurde von deiner*m Team-Admin gesetzt.`,loggedInTo:`Logged in to`,popupsBlocked:`Popups sind blockiert`,popupsBlockedText:`Um dich anzumelden, kopiere bitte den Link in die Adressleiste deines Browsers.`,copyLink:`Link kopieren`,copiedConfirmation:`URL Kopiert`,signInFailed:`Anmeldung fehlgeschlagen`,signInFailedText:`Die Anmeldung konnte nicht abgeschlossen werden. Bitte versuche es erneut.`,hrFeatures:`Job Ads Add-On`,beta:`Beta`,apiKeyConfiguredNotice:`API Key konfiguriert — keine Anmeldung erforderlich.`,apiKeyAuthFailed:`API Key Authentifizierung fehlgeschlagen ({{status}}): {{message}} — überprüfe den API Key oder Endpunkt.`},[eb.popover]:{insteadTry:`Wie wär's mit ...`,learnMore:`Warum`,leanrMoreExtendedText:`Warum das so ist`,ignoreTerm:`Weniger unterstreichen?`,visitSource:`Quelle`,alertOftotal:`von`,removeSpaces:`Extra Leerzeichen entfernen`,loginToUnlock:`Jetzt anmelden!`,signedOutText:`Dir entgeht was`,biasDetection:`Erkennung von über 30 Diversitätskategorieren`,inclusiveAlternatives:`Inklusive Alternativvorschläge`,teamFeatures:`Teamfunktionen, inkl. eines geteilten Wörterbuches`,signIn:`Anmelden`,haveAccount:`Hast du schon ein Konto?`,dontHaveAccount:`Hast du noch kein Konto?`,signUp:`Registrieren`,popupsBlocked:`Popups sind blockiert`,popupsBlockedText:`Um dich anzumelden, kopiere bitte den Link in die Adressleiste deines Browsers.`,copyLink:`Link kopieren`,copiedConfirmation:`URL Kopiert`,signInFailed:`Anmeldung fehlgeschlagen`,signInFailedText:`Die Anmeldung konnte nicht abgeschlossen werden. Bitte versuche es erneut.`,missingOut:`Du verpasst etwas`,bulletPointOne:`Warum ein Begriff unterstrichen wird`,bulletPointTwo:`Inklusive Alternativen`,inclusiveBulletPointOne:`Warum dieser Begriff inklusiv ist`,inclusiveBulletPointTwo:`Weitere inklusive Begriffe`,wittyLogo:`Witty`,new:`neu`,video:`Ein Erklärungsvideo ist verfügbar`,openNewWindow:`Öffnet in einem neuen Fenster`,next:`Nächstes Ergebnis`,previous:`Vorheriges Ergebnis`,close:`Witty schliessen`,suggestionsDialog:`Witty Vorschläge`,removeText:`Entfernen:`,ignoreOnce:`Einmal ignorieren`,ignorePermanently:`Für immer ignorieren`,failedRequestText:`Bitte erneut probieren`,apiKeyConfiguredNotice:`API Key konfiguriert — keine Anmeldung erforderlich.`,lockedByAdmin:``},[eb.iconController]:{totalMaxCharLengthReachedNotificationHeadline:`Lange Texte`,totalMaxCharLengthReachedNotificationText:`Witty prüft {{limit}} Zeichen auf einmal. Dein Text hat {{total}} Zeichen — markiere weitere Abschnitte, um sie zu prüfen.`},[eb.notifications]:{pinNotificationHeadline:`Pin Witty`,pinNotificationText:`Bitte Witty an die Symbolleiste pinnen.`,totalMaxCharLengthReachedNotificationHeadline:`Lange Texte`,totalMaxCharLengthReachedNotificationText:`Witty prüft {{limit}} Zeichen auf einmal. Dein Text hat {{total}} Zeichen — markiere weitere Abschnitte, um sie zu prüfen.`,updateNotificationHeadline:`Witty wurde aktualisiert`,updateNotificationText:`Witty wurde auf die neuste Version aktualisiert.`,updateNotificationButton:`Änderungen`,minVersionNotInstalledNotificationHeadline:`Du must Witty aktualisieren`,minVersionNotInstalledNotificationText:`Um Witty weiterhin nutzen zu können, müsst Du Witty auf eine neuere Version aktualisieren.`,minVersionNotInstalledNotificationButton:`Aktualisieren`}},rb={[eb.editor]:{toolbar:`Formatting`,bold:`Bold`,italic:`Italic`,underline:`Underline`,heading:`Heading`,bulletList:`Bulleted list`,orderedList:`Numbered list`,quote:`Quote`,undo:`Undo`,redo:`Redo`,settings:`Witty settings`,closeSettings:`Close settings`,settingsLoading:`Loading settings…`,statusChecking:`Witty is checking the text…`,statusAlerts_one:`{{count}} suggestion`,statusAlerts_other:`{{count}} suggestions`,statusNoAlerts:`No suggestions`,statusUnauthorized:`API key missing or not accepted`,statusFailed:`Checking failed`,shortcutHint:`Press Alt+Shift+W to open the suggestion at the cursor.`,limitReached:`Only part of this text was checked.`,menu:`Witty menu`,menuSettings:`Settings…`,menuSwitchGender:`Switch gender format…`,menuHelp:`Help`,menuAbout:`About Witty`,switchTitle:`Switch gender format`,switchIntro:`Rewrites every gendered form in the text into the format you choose. Undo reverses it in one step.`,switchCurrent:`current`,switching:`Checking and rewriting the text…`,switched_one:`Switched {{count}} form to {{format}}.`,switched_other:`Switched {{count}} forms to {{format}}.`,switchNothing:`Nothing to switch: the text already uses {{format}}.`,switchDisabled:`Switching the gender format is turned off for this account.`,switchUnsupported:`The server doesn't support switching the gender format yet.`,switchInklusivum:`Switching to the Inklusivum isn't available yet.`,switchForced:`Your organisation sets the gender format to {{format}}. The text was not changed.`},[eb.options]:{languageHeadline:`Language and gender forms`,genderedRolesFormat:`Generic masculine`,genderedRolesFormatHint:`How should Witty handle the generic masculine in gendered languages like German or French?`,germanGenderEnding:`German gender ending`,germanGenderEndingHint:`Witty recommends the genderstar.`,frenchGenderSeparator:`French gender separator`,frenchGenderSeparatorHint:`Witty recommends the point médian.`,useApiDefault:`Server default`,levelOff:`Off`,levelBasic:`Basic`,levelAdvanced:`Advanced`,levelLocked:`Always on`,categoriesFailed:`Could not load categories.`,helpOwnServer:`Connect Witty to your own server`,helpWithoutDashboard:`Run Witty without the dashboard`,helpCentre:`Help Center`,settingsHeadline:`Witty settings`,connectionHeadline:`Connection`,modeAccount:`Account (sign in via dashboard)`,modeApiKey:`API key (no dashboard)`,apiKey:`API key`,apiKeyHint:`Sent as x-key to the NLP API. No dashboard required.`,apiKeyRequired:`An API key is required.`,customisationHeadline:`Customisation`,orthography:`Spell checking`,llmAlternatives:`AI suggestions`,categoriesHeadline:`Categories`,categoriesIntro:`Categories you switch off are no longer highlighted.`,orgOverrideNote:`In account mode your organisation settings may override these.`,endpointHeadline:`Custom server`,endpointIntro:`Point Witty at your own deployment. Only change this if you know what you are doing.`,endpointWarning:`Warning: the server you enter receives every text you write in input fields. Only enter a deployment you trust.`,dashboardUrl:`Dashboard URL`,apiUrl:`NLP API URL`,oauthClientId:`OAuth client ID`,redirectUriHint:`Register this redirect URI on your dashboard OAuth client:`,save:`Save and sign out`,reset:`Reset to default`,saved:`Saved. You have been signed out — please sign in again.`,resetDone:`Reset to default. You have been signed out.`,invalidUrl:`Enter an https URL (http is allowed for localhost only).`,clientIdRequired:`OAuth client ID is required.`,signOutNotice:`Changing server signs you out: tokens are only ever valid for one server.`,currentEndpoint:`Currently using`},[eb.common]:{buttons:{ok:`Ok`,cancel:`Cancel`},languages:{en_GB:`English (🇬🇧 Great Britain)`,en_US:`English (🇺🇸 USA)`,de_DE:`German (🇩🇪 Germany)`,de_AT:`German (🇦🇹 Austrian)`,de_CH:`German (🇨🇭 Switzerland)`,fr_FR:`French (🇫🇷 France)`,fr_CH:`French (🇨🇭 Switzerland)`}},[eb.pages.popup]:{helpCentre:`Help Center`,helpSignInFailed:`Troubleshooting help`,extensionSettings:`Extension settings`,extensionSettingsHint:`Custom server, API key and categories`,enableWitty:`Enable Witty`,websiteSettings:`Settings for {{domain}}`,developmentSettings:`Development Settings`,spellChecking:`Check grammar & spelling`,thanks:`Thanks for your feedback!`,noSupport:`We’re sorry! Witty doesn’t yet officially support this website.`,vote:`Vote for this website`,editor:`Use the Witty Editor instead`,goToDashboard:`Go to Witty Editor`,overrideRecomendedSites:`Try Witty here anyway`,backToRecomendedSites:`Use Witty only on supported websites`,loginToUnlock:`Log in now!`,signedOutText:`You are missing out`,biasDetection:`Bias detection in 30+ diversity dimensions`,inclusiveAlternatives:`Alternatives for inclusive writing`,teamFeatures:`Team features, incl. shared dictionaries`,signIn:`Sign In`,signOut:`Sign out`,haveAccount:`Already have an account?`,dontHaveAccount:`Don’t have an account?`,signUp:`Sign up`,doesWittyWork:`Does Witty work here?`,doesWittyWorkExplanation:`Please help us to find out.`,tryAgain:`Try again`,understood:`Understood`,websiteSettingsDeactivated:`You reported that Witty does not work on {{domain}}`,tryAgainOnThisWebsite:`Try again on this website`,enableWittyFailed:`Die Synchronisierung mit Witty Dashboard ist aktuell nicht möglich, versuchen Sie es später noch einmal.`,lockedInfo:`This feature has been locked by your team admin.`,loggedInTo:`Logged in to`,popupsBlocked:`Popups are blocked`,popupsBlockedText:`To log in, please copy and paste the link into your browser's URL bar.`,copyLink:`Copy Link`,copiedConfirmation:`link Copied`,signInFailed:`Sign-in failed`,signInFailedText:`We could not complete the sign-in. Please try again.`,hrFeatures:`Job Ads Add-On`,beta:`Beta`,apiKeyConfiguredNotice:`API key configured — no sign-in required.`,apiKeyAuthFailed:`API key authentication failed ({{status}}): {{message}} — check your API key or endpoint.`},[eb.popover]:{insteadTry:`Try instead ...`,learnMore:`Why`,leanrMoreExtendedText:`Dig deeper`,ignoreTerm:`Highlight less?`,visitSource:`Source`,alertOftotal:`of`,removeSpaces:`(Remove extra spaces)`,loginToUnlock:`Log in now!`,signedOutText:`You are missing out`,biasDetection:`Bias detection in 30+ diversity dimensions`,inclusiveAlternatives:`Alternatives for inclusive writing`,teamFeatures:`Team features, incl. shared dictionaries`,signIn:`Sign In`,haveAccount:`Already have an account?`,dontHaveAccount:`Don’t have an account?`,signUp:`Sign up`,popupsBlocked:`Popups are blocked`,popupsBlockedText:`Please copy and paste the link into your browser URL bar.`,copyLink:`Copy Link`,copiedConfirmation:`link Copied`,signInFailed:`Sign-in failed`,signInFailedText:`We could not complete the sign-in. Please try again.`,missingOut:`You are missing out`,bulletPointOne:`Why this term is biased`,bulletPointTwo:`Inclusive alternatives for this term`,inclusiveBulletPointOne:`Why this term is inclusive`,inclusiveBulletPointTwo:`More inclusive terms`,wittyLogo:`Witty`,new:`new`,video:`A video is available for more learning`,openNewWindow:`Opens in a new window`,next:`Next result`,previous:`Previous result`,close:`Close Witty`,suggestionsDialog:`Witty suggestions`,removeText:`Remove:`,ignoreOnce:`Ignore once`,ignorePermanently:`Ignore permanently`,failedRequestText:`Failed, please try again`,apiKeyConfiguredNotice:`API key configured — no sign-in required.`,lockedByAdmin:``},[eb.errors]:{errorMessageGenericTitle:`Ouch! Something went wrong!`,reloadWebsite:`Please reload the website`},[eb.iconController]:{totalMaxCharLengthReachedNotificationHeadline:`Long texts`,totalMaxCharLengthReachedNotificationText:`Witty checks {{limit}} characters at a time. Your text has {{total}} characters — select further sections to check them.`},[eb.notifications]:{pinNotificationHeadline:`Pin Witty`,pinNotificationText:`Remember to pin Witty to your browser toolbar.`,totalMaxCharLengthReachedNotificationHeadline:`Long texts`,totalMaxCharLengthReachedNotificationText:`Witty checks {{limit}} characters at a time. Your text has {{total}} characters — select further sections to check them.`,updateNotificationHeadline:`Witty was updated`,updateNotificationText:`Witty was updated to the latest version.`,updateNotificationButton:`View changes`,minVersionNotInstalledNotificationHeadline:`You need to update Witty`,minVersionNotInstalledNotificationText:`In order to continue using Witty, you need to update Witty to a newer version.`,minVersionNotInstalledNotificationButton:`How to update`}},ib={[eb.editor]:{toolbar:`Mise en forme`,bold:`Gras`,italic:`Italique`,underline:`Souligné`,heading:`Titre`,bulletList:`Liste à puces`,orderedList:`Liste numérotée`,quote:`Citation`,undo:`Annuler`,redo:`Rétablir`,settings:`Paramètres Witty`,closeSettings:`Fermer les paramètres`,settingsLoading:`Chargement des paramètres…`,statusChecking:`Witty vérifie le texte…`,statusAlerts_one:`{{count}} suggestion`,statusAlerts_other:`{{count}} suggestions`,statusNoAlerts:`Aucune suggestion`,statusUnauthorized:`Clé API manquante ou refusée`,statusFailed:`La vérification a échoué`,shortcutHint:`Appuyez sur Alt+Maj+W pour ouvrir la suggestion à la position du curseur.`,limitReached:`Seule une partie de ce texte a été vérifiée.`,menu:`Menu Witty`,menuSettings:`Paramètres…`,menuSwitchGender:`Changer la forme inclusive…`,menuHelp:`Aide`,menuAbout:`À propos de Witty`,switchTitle:`Changer la forme inclusive`,switchIntro:`Réécrit toutes les formes genrées du texte dans la forme choisie. Annuler rétablit le texte en une seule étape.`,switchCurrent:`actuelle`,switching:`Vérification et réécriture du texte…`,switched_one:`{{count}} forme passée en {{format}}.`,switched_other:`{{count}} formes passées en {{format}}.`,switchNothing:`Rien à changer : le texte utilise déjà {{format}}.`,switchDisabled:`Le changement de forme inclusive est désactivé pour ce compte.`,switchUnsupported:`Le serveur ne permet pas encore de changer la forme inclusive.`,switchInklusivum:`Le passage à l'Inklusivum n'est pas encore disponible.`,switchForced:`Votre organisation impose la forme inclusive {{format}}. Le texte n'a pas été modifié.`},[eb.options]:{languageHeadline:`Langue et formes de genre`,genderedRolesFormat:`Masculin générique`,genderedRolesFormatHint:`Comment Witty doit-il traiter le masculin générique dans les langues genrées ?`,germanGenderEnding:`Terminaison de genre allemande`,germanGenderEndingHint:`Witty recommande le genderstar.`,frenchGenderSeparator:`Séparateur de genre français`,frenchGenderSeparatorHint:`Witty recommande le point médian.`,useApiDefault:`Valeur par défaut du serveur`,levelOff:`Désactivé`,levelBasic:`Base`,levelAdvanced:`Avancé`,levelLocked:`Toujours actif`,categoriesFailed:`Impossible de charger les catégories.`,helpOwnServer:`Connecter Witty à votre propre serveur`,helpWithoutDashboard:`Utiliser Witty sans tableau de bord`,helpCentre:`Centre d’aide`,settingsHeadline:`Paramètres Witty`,connectionHeadline:`Connexion`,modeAccount:`Compte (connexion via le tableau de bord)`,modeApiKey:`Clé API (sans tableau de bord)`,apiKey:`Clé API`,apiKeyHint:`Envoyée comme x-key à l'API NLP. Aucun tableau de bord requis.`,apiKeyRequired:`Une clé API est requise.`,customisationHeadline:`Personnalisation`,orthography:`Correction orthographique`,llmAlternatives:`Suggestions IA`,categoriesHeadline:`Catégories`,categoriesIntro:`Les catégories désactivées ne sont plus mises en évidence.`,orgOverrideNote:`En mode compte, les paramètres de votre organisation peuvent les remplacer.`,endpointHeadline:`Serveur personnalisé`,endpointIntro:`Pointez Witty vers votre propre installation. Ne modifiez ceci que si vous savez ce que vous faites.`,endpointWarning:`Attention : le serveur indiqué reçoit tout texte que vous saisissez dans les champs. N'indiquez qu'une installation de confiance.`,dashboardUrl:`URL du tableau de bord`,apiUrl:`URL de l'API NLP`,oauthClientId:`ID client OAuth`,redirectUriHint:`Enregistrez cette URI de redirection sur le client OAuth de votre tableau de bord :`,save:`Enregistrer et se déconnecter`,reset:`Réinitialiser`,saved:`Enregistré. Vous avez été déconnecté·e — veuillez vous reconnecter.`,resetDone:`Réinitialisé. Vous avez été déconnecté·e.`,invalidUrl:`Indiquez une URL https (http uniquement pour localhost).`,clientIdRequired:`L'ID client OAuth est requis.`,signOutNotice:`Changer de serveur vous déconnecte : les jetons ne sont valables que pour un seul serveur.`,currentEndpoint:`Actuellement utilisé`},[eb.common]:{buttons:{ok:`Ok`,cancel:`Annuler`},languages:{en_US:`Anglais (🇺🇸 USA)`,en_GB:`Anglais (🇬🇧 Royaume-Uni)`,de_DE:`Allemand (🇩🇪 Allemagne)`,de_AT:`Allemand (🇦🇹 Autriche)`,de_CH:`Allemand (🇨🇭 Suisse)`,fr_FR:`Français (🇫🇷 France)`,fr_CH:`Français (🇨🇭 Suisse)`}},[eb.pages.popup]:{helpCentre:`Centre d’aide`,helpSignInFailed:`Aide au dépannage`,extensionSettings:`Paramètres de l’extension`,extensionSettingsHint:`Serveur personnalisé, clé API et catégories`,enableWitty:`Activer Witty`,websiteSettings:`Paramètres pour {{domain}}`,developmentSettings:`Paramètres de développement`,spellChecking:`Vérifier la grammaire et l'orthographe`,thanks:`Merci pour votre retour !`,noSupport:`Nous sommes désolés ! Witty ne prend pas encore officiellement en charge ce site web.`,vote:`Votez pour ce site web`,editor:`Utiliser l'éditeur Witty à la place`,goToDashboard:`Aller à l'éditeur Witty`,overrideRecomendedSites:`Essayer Witty ici quand même`,backToRecomendedSites:`Utiliser Witty uniquement sur les sites pris en charge`,loginToUnlock:`Connectez-vous maintenant !`,signedOutText:`Vous manquez quelque chose`,biasDetection:`Détection des biais dans plus de 30 dimensions de diversité`,inclusiveAlternatives:`Alternatives pour une écriture inclusive`,teamFeatures:`Fonctionnalités d'équipe, y compris des dictionnaires partagés`,signIn:`Se connecter`,signOut:`Se déconnecter`,haveAccount:`Vous avez déjà un compte ?`,dontHaveAccount:`Vous n'avez pas de compte ?`,signUp:`S'inscrire`,doesWittyWork:`Witty fonctionne-t-il ici ?`,doesWittyWorkExplanation:`Aidez-nous à le découvrir, s'il vous plaît.`,tryAgain:`Réessayer`,understood:`Compris`,websiteSettingsDeactivated:`Vous avez signalé que Witty ne fonctionne pas sur {{domain}}`,tryAgainOnThisWebsite:`Réessayez sur ce site web`,enableWittyFailed:`La synchronisation avec le tableau de bord Witty est actuellement impossible, veuillez réessayer plus tard.`,lockedInfo:`Cette fonctionnalité a été verrouillée par votre·e administrateur·trice d'équipe.`,loggedInTo:`Connecté·e à`,popupsBlocked:`Les pop-ups sont bloqués`,popupsBlockedText:`Pour vous connecter, veuillez copier et coller le lien dans la barre d'URL de votre navigateur.`,copyLink:`Copier le lien`,copiedConfirmation:`Lien copié`,signInFailed:`Échec de la connexion`,signInFailedText:`La connexion n'a pas pu aboutir. Veuillez réessayer.`,hrFeatures:`Add-on pour les offres d'emploi`,beta:`Bêta`,apiKeyConfiguredNotice:`Clé API configurée — aucune connexion requise.`,apiKeyAuthFailed:`Échec de l'authentification de la clé API ({{status}}) : {{message}} — vérifiez votre clé API ou le point de terminaison.`},[eb.popover]:{insteadTry:`Essayez plutôt ...`,learnMore:`Pourquoi`,leanrMoreExtendedText:`En savoir plus`,ignoreTerm:`Mettre moins en évidence ?`,visitSource:`Source`,alertOftotal:`de`,removeSpaces:`(Retirer les espaces supplémentaires)`,loginToUnlock:`Connectez-vous maintenant !`,signedOutText:`Vous manquez quelque chose`,biasDetection:`Détection des biais dans plus de 30 dimensions de diversité`,inclusiveAlternatives:`Alternatives pour une écriture inclusive`,teamFeatures:`Fonctionnalités d'équipe, y compris des dictionnaires partagés`,signIn:`Se connecter`,haveAccount:`Vous avez déjà un compte ?`,dontHaveAccount:`Vous n'avez pas de compte ?`,signUp:`S'inscrire`,popupsBlocked:`Les pop-ups sont bloqués`,popupsBlockedText:`Veuillez copier et coller le lien dans la barre d'URL de votre navigateur.`,copyLink:`Copier le lien`,copiedConfirmation:`Lien copié`,signInFailed:`Échec de la connexion`,signInFailedText:`La connexion n'a pas pu aboutir. Veuillez réessayer.`,missingOut:`Vous manquez quelque chose`,bulletPointOne:`Pourquoi ce terme est biaisé`,bulletPointTwo:`Alternatives inclusives pour ce terme`,inclusiveBulletPointOne:`Pourquoi ce terme est inclusif`,inclusiveBulletPointTwo:`Termes plus inclusifs`,wittyLogo:`Witty`,new:`nouveau·elle`,video:`Une vidéo d'explication est disponible`,openNewWindow:`Ouverture dans une nouvelle fenêtre`,next:`Résultat suivant`,previous:`Résultat précédent`,close:`Fermer Witty`,suggestionsDialog:`Suggestions Witty`,removeText:`Supprimer :`,ignoreOnce:`Ignorer une fois`,ignorePermanently:`Ignorer définitivement`,failedRequestText:`Échec, veuillez réessayer`,apiKeyConfiguredNotice:`Clé API configurée — aucune connexion requise.`,lockedByAdmin:``},[eb.errors]:{errorMessageGenericTitle:`Oups ! Quelque chose a mal tourné !`,reloadWebsite:`Veuillez recharger le site web`},[eb.iconController]:{totalMaxCharLengthReachedNotificationHeadline:`Textes longs`,totalMaxCharLengthReachedNotificationText:`Witty vérifie {{limit}} caractères à la fois. Votre texte compte {{total}} caractères — sélectionnez d'autres sections pour les vérifier.`},[eb.notifications]:{pinNotificationHeadline:`Épingler Witty`,pinNotificationText:`N'oubliez pas d'épingler Witty dans la barre d'outils de votre navigateur.`,totalMaxCharLengthReachedNotificationHeadline:`Textes longs`,totalMaxCharLengthReachedNotificationText:`Witty vérifie {{limit}} caractères à la fois. Votre texte compte {{total}} caractères — sélectionnez d'autres sections pour les vérifier.`,updateNotificationHeadline:`Witty a été mis à jour`,updateNotificationText:`Witty a été mis à jour vers la dernière version.`,updateNotificationButton:`Voir les changements`,minVersionNotInstalledNotificationHeadline:`Vous devez mettre à jour Witty`,minVersionNotInstalledNotificationText:`Pour continuer à utiliser Witty, vous devez mettre à jour Witty vers une version plus récente.`,minVersionNotInstalledNotificationButton:`Comment mettre à jour`}},ab={[tb.en]:rb,[tb.de]:nb,[tb.fr]:ib};delete ab.fr;var ob=()=>{ty.isInitialized||ty.use($y).use(Sy).init({detection:{order:[`navigator`]},resources:ab,fallbackLng:`en`})},sb=`v2.4/check`,cb=`v1.0/rephrase`,lb=`v2.0/config-options`,ub=e=>`v2.0/categories?locale=${encodeURIComponent(e)}`,db={Accept:`application/json`,"Content-Type":`application/json`},fb=e=>e.apiKey?{"x-key":e.apiKey}:e.token?{Authorization:`Bearer ${e.token}`}:{},pb=e=>{let{text:t,lang:n=`auto`,id:r,client:i,config:a}=e;return{text:t,lang:n,id:r,client:i,...a===void 0?{}:{config:a},...e.configHash===void 0?{}:{config_hash:e.configHash},...e.organizationConfigHash===void 0?{}:{organization_config_hash:e.organizationConfigHash}}},mb=(e,t)=>({sentence:e.raw,text:t.data.text,start:t.absOffset-e.range[0],gender_separator:t.data.gender_separator,alternatives:t.data.alternatives.filter(e=>!e.remove),lang:t.data.language||`en`}),hb=3e3,gb=e=>{if(!e)return;let t=Object.entries(e).filter(([,e])=>e!==void 0);return t.length?Object.fromEntries(t):void 0},_b=(e,t)=>{if(e?.startsWith(`de`))return t?.german_gender_ending;if(e?.startsWith(`fr`))return t?.french_gender_separator},vb=class extends Error{status;constructor(e,t){super(`check failed: HTTP ${e}${t?`: ${t}`:``}`),this.status=e,this.name=`CheckHttpError`}},yb=async e=>{try{let{detail:t}=await e.json();if(typeof t==`string`)return t;if(Array.isArray(t))return t.map(({loc:e,msg:t})=>[e?.slice(1).join(`.`),t].filter(Boolean).join(`: `)).join(`; `)}catch{}},bb=({endpoint:e,headers:t,lang:n=`auto`,client:r=`witty-editor:${X_}`,id:i=`witty-editor`,config:a})=>async(o,s)=>{let c=gb(a?.()),l=await fetch(`${e}${sb}`,{method:`POST`,signal:s,headers:{...db,...t?await t():{}},body:JSON.stringify(pb({text:o,lang:n,id:i,client:r,config:c}))});if(!l.ok)throw new vb(l.status,await yb(l));return await l.json()};function xb(e){if(e.type===`Sentence`)return e;if(`children`in e&&Array.isArray(e.children))return e.children.find(e=>e.type===`Sentence`)}var Sb=(e,t,n,r)=>`${e}-${t}-${n}-${r}`,Cb=(e,t)=>{if(e===` `)return{text:``,scope:`alert`};let n=e.replace(/\(\(/g,`[`).replace(/\)\)/g,`]`),r=t?.get(n);return r?{text:r,scope:`sentence`}:{text:n,scope:`alert`}},wb;(function(e){e.Document=`Document`,e.DocumentExit=`Document:exit`,e.Paragraph=`Paragraph`,e.ParagraphExit=`Paragraph:exit`,e.BlockQuote=`BlockQuote`,e.BlockQuoteExit=`BlockQuote:exit`,e.ListItem=`ListItem`,e.ListItemExit=`ListItem:exit`,e.List=`List`,e.ListExit=`List:exit`,e.Header=`Header`,e.HeaderExit=`Header:exit`,e.CodeBlock=`CodeBlock`,e.CodeBlockExit=`CodeBlock:exit`,e.HtmlBlock=`HtmlBlock`,e.HtmlBlockExit=`HtmlBlock:exit`,e.HorizontalRule=`HorizontalRule`,e.HorizontalRuleExit=`HorizontalRule:exit`,e.Comment=`Comment`,e.CommentExit=`Comment:exit`,e.ReferenceDef=`ReferenceDef`,e.ReferenceDefExit=`ReferenceDef:exit`,e.Str=`Str`,e.StrExit=`Str:exit`,e.Break=`Break`,e.BreakExit=`Break:exit`,e.Emphasis=`Emphasis`,e.EmphasisExit=`Emphasis:exit`,e.Strong=`Strong`,e.StrongExit=`Strong:exit`,e.Html=`Html`,e.HtmlExit=`Html:exit`,e.Link=`Link`,e.LinkExit=`Link:exit`,e.Image=`Image`,e.ImageExit=`Image:exit`,e.Code=`Code`,e.CodeExit=`Code:exit`,e.Delete=`Delete`,e.DeleteExit=`Delete:exit`,e.Table=`Table`,e.TableExit=`Table:exit`,e.TableRow=`TableRow`,e.TableRowExit=`TableRow:exit`,e.TableCell=`TableCell`,e.TableCellExit=`TableCell:exit`})(wb||={});var Tb=c((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.binarySearch=e.upperBound=e.lowerBound=e.compare=void 0;function t(e,t){return e<t}e.compare=t;function n(e,n,r=t){let i=e.length,a=0;for(;i;){let t=i>>>1,o=a+t;r(n,e[o])?i=t:(a=o+1,i-=t+1)}return a}e.upperBound=n;function r(e,n,r=t){let i=e.length,a=0;for(;i;){let t=i>>>1,o=a+t;r(e[o],n)?(a=o+1,i-=t+1):i=t}return a}e.lowerBound=r;function i(e,n,i=t){let a=r(e,n,i);return a!==e.length&&!i(n,e[a])}e.binarySearch=i})),Eb=c((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.StructuredSource=void 0;var t=Tb();e.StructuredSource=class{constructor(e){this.indice=[0];let t=/[\r\n\u2028\u2029]/g,n=e.length;for(t.lastIndex=0;;){let r=t.exec(e);if(!r)break;let i=r.index;e.charCodeAt(i)===13&&e.charCodeAt(i+1)===10&&(i+=1);let a=i+1;if(n<a)break;this.indice.push(a),t.lastIndex=a}}get line(){return this.indice.length}locationToRange(e){return[this.positionToIndex(e.start),this.positionToIndex(e.end)]}rangeToLocation(e){return{start:this.indexToPosition(e[0]),end:this.indexToPosition(e[1])}}positionToIndex(e){return this.indice[e.line-1]+e.column}indexToPosition(e){let n=(0,t.upperBound)(this.indice,e);return{line:n,column:e-this.indice[n-1]}}}}))(),Db=(e,t)=>{for(let n=e.length-1;n>=0;n--)if(t(e[n],n,e))return n;return-1},Ob=class{index=0;source;textCharacters;sourceNode;contexts=[];consumedContexts=[];contextRanges=[];firstChildPadding;startOffset;constructor(e){if(typeof e==`string`)this.textCharacters=e.split(``),this.source=new Eb.StructuredSource(e),this.startOffset=0,this.firstChildPadding=0;else{this.sourceNode=e,this.startOffset=this.sourceNode.range[0],this.index=this.startOffset;let t=Array.from(Array(this.sourceNode.loc.start.line-1)).fill(`
132
132
  `),n=Array.from(Array(this.startOffset-t.length)).fill(`∯`),r=e.raw.split(``);this.textCharacters=[...t,...n,...r],this.source=new Eb.StructuredSource(this.textCharacters.join(``)),this.firstChildPadding=this.sourceNode.children[0]?this.sourceNode.children[0].range[0]-this.startOffset:0}}get length(){return this.textCharacters.length}markContextRange(e){this.contextRanges.push(e)}isInContextRange(){let e=this.offset;return this.contextRanges.some(t=>t[0]<=e&&e<t[1])}enterContext(e){this.contexts.push([e,this.index])}isInContext(e){return e?this.contexts.some(t=>t[0].key===e.key):this.contexts.length>0}leaveContext(e){let t=Db(this.contexts,t=>t[0].key===e.key);if(t!==-1){let e=this.contexts[t];this.contexts.splice(t,1);let n=[e[1],this.index];this.consumedContexts.push({pairMark:e[0],range:[e[1],this.index],loc:this.source.rangeToLocation(n)})}}get offset(){return this.index+this.firstChildPadding}now(){let e=this.offset,t=this.source.indexToPosition(e);return{line:t.line,column:t.column,offset:e}}get hasEnd(){return this.read()===!1}read(e=0){let t=this.offset+e;return t<this.startOffset?!1:0<=t&&t<this.textCharacters.length&&this.textCharacters[t]}readNode(e=0){if(!this.sourceNode)return!1;let t=this.offset+e;if(t<this.startOffset)return!1;let n=this.sourceNode.children.filter(e=>e.range[0]<=t&&t<e.range[1]);return n.length>0&&n[n.length-1]}peek(){this.index+=1}peekNode(e){this.index+=e.range[1]-e.range[0]}seekNext(e){let t=this.now();e.seek(this);let n=this.now();return{value:this.sliceRange(t.offset,n.offset),startPosition:t,endPosition:n}}sliceRange(e,t){return this.textCharacters.slice(e,t).join(``)}},kb=class{test(e){let t=e.read();return t?/[\r\n]/.test(t):!1}seek(e){for(;this.test(e);)e.peek()}},Ab=class{test(e){let t=e.read();return t?/[^\S\n\r]/.test(t):!1}seek(e){for(;this.test(e);)e.peek()}},jb={separatorCharacters:[`.`,`.`,`。`,`?`,`!`,`?`,`!`]},Mb=class{options;separatorCharacters;constructor(e){this.options=e,this.separatorCharacters=e&&e.separatorCharacters?e.separatorCharacters:jb.separatorCharacters}test(e){if(e.isInContext()||e.isInContextRange())return!1;let t=e.read(),n=e.read(1);return!t||!this.separatorCharacters.includes(t)?!1:t!==`.`||!n||/[\s\t\r\n]/.test(n)}seek(e){for(;this.test(e);)e.peek()}},Nb=typeof process==`object`&&process?.env?.DEBUG===`sentence-splitter`;function Pb(e,t){Nb&&console.log(`sentence-splitter: `+e,t)}function Fb(...e){Nb&&console.log(`sentence-splitter: `,...e.map(e=>typeof e==`string`?e.replace(/\n/g,`\\n`):e))}var Ib=class{parsers;markers;constructor(e){this.parsers=e.parsers,this.markers=e.markers}test(e){return!e.hasEnd&&this.parsers.every(t=>!t.test(e))}seek(e){let t=e.readNode();if(!t){for(;this.test(e);)this.markers.forEach(t=>t.mark(e)),e.peek();return}let n=()=>{let n=e.offset;return t.range[0]<=n&&n<t.range[1]};for(;n()&&this.test(e);)Pb(e.offset,e.read()),this.markers.forEach(t=>t.mark(e)),e.peek()}},Lb={ABBREVIATIONS:`Adj.,Adm.,Adv.,Al.,Ala.,Alta.,Apr.,Arc.,Ariz.,Ark.,Art.,Assn.,Asst.,Attys.,Aug.,Ave.,Bart.,Bld.,Bldg.,Blvd.,Brig.,Bros.,Btw.,Cal.,Calif.,Capt.,Cl.,Cmdr.,Co.,Col.,Colo.,Comdr.,Con.,Conn.,Corp.,Cpl.,Cres.,Ct.,D.phil.,Dak.,Dec.,Del.,Dept.,Det.,Dist.,Dr.,Dr.phil.,Dr.philos.,Drs.,E.g.,Ens.,Esp.,Esq.,Etc.,Exp.,Expy.,Ext.,Feb.,Fed.,Fla.,Ft.,Fwy.,Fy.,Ga.,Gen.,Gov.,Hon.,Hosp.,Hr.,Hway.,Hwy.,I.e.,Ia.,Id.,Ida.,Ill.,Inc.,Ind.,Ing.,Insp.,Is.,Jan.,Jr.,Jul.,Jun.,Kan.,Kans.,Ken.,Ky.,La.,Lt.,Ltd.,Maj.,Man.,Mar.,Mass.,May.,Md.,Me.,Med.,Messrs.,Mex.,Mfg.,Mich.,Min.,Minn.,Miss.,Mlle.,Mm.,Mme.,Mo.,Mont.,Mr.,Mrs.,Ms.,Msgr.,Mssrs.,Mt.,Mtn.,Neb.,Nebr.,Nev.,No.,Nos.,Nov.,Nr.,Oct.,Ok.,Okla.,Ont.,Op.,Ord.,Ore.,P.,Pa.,Pd.,Pde.,Penn.,Penna.,Pfc.,Ph.,Ph.d.,Pl.,Plz.,Pp.,Prof.,Pvt.,Que.,Rd.,Rs.,Ref.,Rep.,Reps.,Res.,Rev.,Rt.,Sask.,Sec.,Sen.,Sens.,Sep.,Sept.,Sfc.,Sgt.,Sr.,St.,Supt.,Surg.,Tce.,Tenn.,Tex.,Univ.,Usafa.,U.S.,Ut.,Va.,V.,Ver.,Vs.,Vt.,Wash.,Wis.,Wisc.,Wy.,Wyo.,Yuk.`.split(`,`),PREPOSITIVE_ABBREVIATIONS:`Adm.,Attys.,Brig.,Capt.,Cmdr.,Col.,Cpl.,Det.,Dr.,Gen.,Gov.,Ing.,Lt.,Maj.,Mr.,Mrs.,Ms.,Mt.,Messrs.,Mssrs.,Prof.,Ph.,Rep.,Reps.,Rev.,Sen.,Sens.,Sgt.,St.,Supt.,V.,Vs.`.split(`,`),EXCLAMATION_WORDS:[`!Xũ`,`!Kung`,`ǃʼOǃKung`,`!Xuun`,`!Kung-Ekoka`,`ǃHu`,`ǃKhung`,`ǃKu`,`ǃung`,`ǃXo`,`ǃXû`,`ǃXung`,`ǃXũ`,`!Xun`,`Yahoo!`,`Y!J`,`Yum!`]},Rb=e=>!e||e.length===0?!1:/^\p{Uppercase_Letter}/u.test(e),zb=(e,t)=>e.toLowerCase()===t.toLowerCase(),Bb=e=>/[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}]/u.test(e),Vb={language:Lb},Hb=class{options;lang;constructor(e){this.options=e,this.lang=e&&e.language?e.language:Vb.language}getWord(e,t=0){let n=/\s/,r=e.read(-1);if(r&&!n.test(r)&&!Bb(r))return``;let i=``,a=t,o=``;for(;(o=e.read(a))&&!(n.test(o)||Bb(o));)i+=o,a++;return i}getPrevWord(e){let t=/\s/,n=-1,r=``;for(;(r=e.read(n))&&t.test(r);)n--;for(;(r=e.read(n))&&!t.test(r);)n--;return this.getWord(e,n+1)}mark(e){if(e.isInContextRange())return;let t=this.getWord(e);if(t.length===0)return;if(/^([a-zA-Z]\.){3,}$/.test(t)||this.lang.EXCLAMATION_WORDS.some(e=>zb(e,t)))return e.markContextRange([e.offset,e.offset+t.length]);let n=this.lang.PREPOSITIVE_ABBREVIATIONS.some(e=>zb(e,t)),r=/^\d+\.$/.test(t);if(n||r)return e.markContextRange([e.offset,e.offset+t.length]);let i=this.lang.ABBREVIATIONS.some(e=>zb(e,t)),a=this.getPrevWord(e),o=this.getWord(e,t.length+1);(Rb(a)&&/^\p{Uppercase_Letter}\./u.test(t)&&Rb(o)||i&&!Rb(o))&&e.markContextRange([e.offset,e.offset+t.length])}},Ub=[{key:`double quote`,start:`"`,end:`"`},{key:`angled bracket`,start:`[`,end:`]`},{key:`round bracket`,start:`(`,end:`)`},{key:`curly brace`,start:`{`,end:`}`},{key:`かぎ括弧`,start:`「`,end:`」`},{key:`丸括弧`,start:`(`,end:`)`},{key:`二重かぎ括弧`,start:`『`,end:`』`},{key:`波括弧`,start:`{`,end:`}`},{key:`角括弧`,start:`[`,end:`]`},{key:`重角括弧`,start:`〚`,end:`〛`},{key:`隅付き括弧`,start:`【`,end:`】`},{key:`二重隅付き括弧`,start:`《`,end:`》`}],Wb=class{PAIR_MARKS_KEY_Map=new Map(Ub.flatMap(e=>[[e.start,e],[e.end,e]]));mark(e){let t=e.read();if(!t)return;let n=this.PAIR_MARKS_KEY_Map.get(t);n&&(e.isInContext(n)?n.end===t&&(Fb(`PairMaker -> leaveContext: ${t} `),e.leaveContext(n)):n.start===t&&(Fb(`PairMaker -> enterContext: ${t} `),e.enterContext(n)))}},Gb={WhiteSpace:`WhiteSpace`,Punctuation:`Punctuation`,Sentence:`Sentence`,Str:`Str`,PairMark:`PairMark`},Kb=class{sentenceNodeList=[];results=[];source;constructor(e){this.source=new Ob(e)}get current(){return this.sentenceNodeList[this.sentenceNodeList.length-1]}pushNodeToCurrent(e){let t=this.current;t?t.children.push(e):this.results.push(e)}open(e){this.sentenceNodeList.push(e)}isOpened(){return this.sentenceNodeList.length>0}nextLine(e){let{value:t,startPosition:n,endPosition:r}=this.source.seekNext(e);return this.pushNodeToCurrent(Yb(t,n,r)),r}nextSpace(e){let{value:t,startPosition:n,endPosition:r}=this.source.seekNext(e);this.pushNodeToCurrent(Yb(t,n,r))}nextValue(e){let{value:t,startPosition:n,endPosition:r}=this.source.seekNext(e);this.pushNodeToCurrent(Zb(t,n,r))}close(e){let{value:t,startPosition:n,endPosition:r}=this.source.seekNext(e);n.offset!==r.offset&&!/^\s+$/.test(t)&&this.pushNodeToCurrent(Xb(t,n,r));let i=this.sentenceNodeList.pop();if(!i||i.children.length===0)return;let a=i.children[0],o=this.source.now(),s=this.source.sliceRange(a.range[0],o.offset),c=this.source.consumedContexts.sort((e,t)=>e.range[0]-t.range[0]).map(e=>({type:`PairMark`,pairMark:e.pairMark,range:e.range,loc:e.loc}));this.results.push({...i,loc:{start:a.loc.start,end:{line:o.line,column:o.column}},range:[a.range[0],o.offset],raw:s,contexts:c})}toList(){return this.results}},qb=(e={})=>{let t=new kb,n=new Ab,r=new Mb(e.SeparatorParser),i=new Hb(e.AbbrMarker),a=new Wb;return{newLine:t,space:n,separator:r,abbrMarker:i,anyValueParser:new Ib({parsers:[t,r],markers:[i,a]})}};function Jb(e,t){let{newLine:n,space:r,separator:i,anyValueParser:a}=qb(t),o=new Kb(e),s=o.source;for(;!s.hasEnd;)n.test(s)?o.nextLine(n):r.test(s)?o.nextSpace(r):i.test(s)?o.close(i):(o.isOpened()||o.open(Qb()),o.nextValue(a));return o.close(r),o.toList()}function Yb(e,t,n){return{type:Gb.WhiteSpace,raw:e,value:e,loc:{start:{line:t.line,column:t.column},end:{line:n.line,column:n.column}},range:[t.offset,n.offset]}}function Xb(e,t,n){return{type:Gb.Punctuation,raw:e,value:e,loc:{start:{line:t.line,column:t.column},end:{line:n.line,column:n.column}},range:[t.offset,n.offset]}}function Zb(e,t,n){return{type:Gb.Str,raw:e,value:e,loc:{start:{line:t.line,column:t.column},end:{line:n.line,column:n.column}},range:[t.offset,n.offset]}}function Qb(){return{type:Gb.Sentence,raw:``,loc:{start:{column:NaN,line:NaN},end:{column:NaN,line:NaN}},range:[NaN,NaN],children:[],contexts:[]}}var $b=(e,t)=>{let{results:n}=e,r=Jb(t).filter(e=>e.type===Gb.Sentence),i=[];return r.forEach(t=>{let r=t.range[0],a=t.range[1],o=[];n.forEach(n=>{if(n.start>=r&&n.end<=a){let r=n.start-t.range[0],i=n.end-t.range[0],a=xb(t);a&&o.push({id:Sb(n.text,n.category,n.start,n.end),startOffset:r,absOffset:n.start,endOffset:i,popOverIsOpen:!1,data:{language:n.language||e.language,gender_separator:e.gender_separator,category:n.category,subcategory:n.subcategory,context:n.context,fullSentence:a,text:n.text,text_id:n.text_id,label:n.label,explanation:n.explanation,alternatives:n.alternatives,gravity:n.gravity,limit_reached:n.limit_reached,source:n.source,bulk:n.bulk}})}}),i.push({sentence:t.raw,alerts:o})}),i},ex=/\n\n/g,tx=e=>{let t=[],n=0,r=[];for(let t of e.matchAll(ex))r.push([n,t.index]),n=t.index+t[0].length;r.push([n,e.length]);for(let[n,i]of r){let r=e.slice(n,i);for(let e of Jb(r))e.type===Gb.Sentence&&t.push({start:n+e.range[0],end:n+e.range[1],text:e.raw})}return t},nx=(e,t,n)=>{if(!t.length)return null;let r=``,i=[],a=-1;for(let o of t){let t=a!==-1&&!/\S/.test(e.slice(a,o.start)),s=i.length?t?e.slice(a,o.start):`
133
133
 
134
134
  `:``,c=s.length+o.text.length;if(i.length&&r.length+c>n)break;r+=s,i.push({sentence:o,offset:r.length}),r+=o.text,a=o.end}return{text:r,parts:i}},rx=(e,t)=>{let n=new Map(e.parts.map(e=>[e.sentence,[]]));for(let r of t){let t=e.parts.find(({sentence:e,offset:t})=>r.start>=t&&r.end<=t+e.text.length);t&&n.get(t.sentence)?.push({...r,start:r.start-t.offset,end:r.end-t.offset})}return n},ix=class{capacity;entries=new Map;scope=``;constructor(e=5e3){this.capacity=e}useScope(e){e!==this.scope&&(this.scope=e,this.entries.clear())}clear(){this.entries.clear()}get(e){let t=this.entries.get(e.text);return t&&(this.entries.delete(e.text),this.entries.set(e.text,t)),t}set(e,t){for(this.entries.delete(e.text),this.entries.set(e.text,t);this.entries.size>this.capacity;)this.entries.delete(this.entries.keys().next().value)}},ax=class e{value;static MINIMUM=100;constructor(e){this.value=e}shrink(){return this.value<=e.MINIMUM?!1:(this.value=Math.max(e.MINIMUM,Math.floor(this.value/2)),!0)}},ox=`
135
135
 
136
136
  `,sx=`
137
- `,cx=``,lx=new Set([`codeBlock`]),ux=new Set([`code`]),dx=e=>{let t=``,n=[],r=!1,i=(e,r)=>{if(e){if(r!==null){let i=n[n.length-1];i&&i.textEnd===t.length&&i.pos+(i.textEnd-i.textStart)===r?i.textEnd+=e.length:n.push({textStart:t.length,textEnd:t.length+e.length,pos:r})}t+=e}},a=()=>{t.endsWith(cx)||i(cx,null)};return e.descendants((e,t)=>lx.has(e.type.name)?!1:e.isTextblock?(r&&i(ox,null),r=!0,!0):e.isText?(e.marks.some(e=>ux.has(e.type.name))?a():i(e.text??``,t),!1):e.type.name===`hardBreak`?(i(sx,null),!1):e.isInline&&e.isAtom?(a(),!1):!0),{text:t,segments:n}},fx=(e,t)=>{let n=0,r=e.segments.length-1;for(;n<=r;){let i=n+r>>1,a=e.segments[i];if(t<a.textStart)r=i-1;else if(t>=a.textEnd)n=i+1;else return a}},px=(e,t,n)=>{if(t<0||n<=t||n>e.text.length)return null;let r=fx(e,t);return!r||n>r.textEnd?null:{from:r.pos+(t-r.textStart),to:r.pos+(n-r.textStart)}},mx=new Jn(`wittyCheck`),hx=({data:e},t,n)=>`${e.category}:${e.text}:${t}:${n}`,gx=({data:e},t)=>[`witty-alert`,`witty-alert--${av(e.gravity,e.subcategory)}`,e.category===`orthography`&&`witty-alert--dotted`,t&&`witty-alert--selected`].filter(Boolean).join(` `),_x=(e,t)=>vs.inline(e.from,e.to,{class:gx(e.detail,e.id===t),"data-alert-id":e.id},{alert:e}),vx=e=>({...e.spec.alert,from:e.from,to:e.to}),yx=(e,t,n)=>xs.create(t,e.find().map(e=>_x(vx(e),n))),bx=e=>mx.getState(e)?.limitReached??!1,xx=e=>(mx.getState(e)?.decorations.find()??[]).map(vx),Sx=e=>{let t=[];return e.mapping.maps.forEach((n,r)=>{let i=e.mapping.slice(r+1);n.forEach((e,n,r,a)=>{t.push([i.map(r,-1),i.map(a,1)])})}),t},Cx=0,wx=(e,t,n,r,i)=>{let a=new Map;for(let e of r.find()){let t=e.spec.alert;a.set(hx(t.detail,e.from,e.to),t.id)}let o=[];for(let r of e){let e=t.map(r.from,1),s=t.map(r.to,-1);if(n.textBetween(e,s)!==r.detail.data.text)continue;let c=hx(r.detail,e,s),l=a.get(c)??`alert-${Cx+=1}`;o.push(_x({...r,id:l,from:e,to:s},i))}return xs.create(n,o)},Tx=(e,t)=>{let n=e.getMeta(mx);if(n?.type===`recheck`)return{...t,recheckRequests:t.recheckRequests+1};if(n?.type===`select`)return{...t,selectedId:n.id,decorations:yx(t.decorations,e.doc,n.id)};if(n?.type===`dismiss`)return{...t,decorations:t.decorations.remove(t.decorations.find().filter(e=>vx(e).detail.data.text===n.text))};if(n?.type===`start`)return{...t,pending:{id:n.id,mapping:new xt}};if(n?.type===`results`)return t.pending?.id===n.id?{...t,decorations:wx(n.alerts,t.pending.mapping,e.doc,t.decorations,t.selectedId),pending:null,limitReached:n.limitReached}:t;if(!e.docChanged)return t;let r=t.decorations.map(e.mapping,e.doc);for(let[t,n]of Sx(e)){let e=r.find(t,n).filter(e=>e.from<n&&e.to>t);e.length&&(r=r.remove(e))}return{...t,decorations:r,pending:t.pending&&{id:t.pending.id,mapping:new xt([...t.pending.mapping.maps,...e.mapping.maps])}}},Ex=class{view;options;timer;inFlight;checkId=0;deferredByComposition=!1;destroyed=!1;cache=new ix;budget;language=``;constructor(e,t){this.view=e,this.options=t,this.budget=new ax(t.maxRequestLength??1e3),this.schedule()}update(e,t){let n=mx.getState(e.state)?.recheckRequests!==mx.getState(t)?.recheckRequests;n&&this.cache.clear(),(n||e.state.doc!==t.doc)&&this.schedule()}compositionEnded(){this.deferredByComposition&&(this.deferredByComposition=!1,this.schedule())}schedule(){clearTimeout(this.timer),this.timer=setTimeout(()=>this.run(),this.options.delay)}run(){if(this.destroyed)return;if(this.view.composing){this.deferredByComposition=!0;return}this.inFlight?.abort();let e=new AbortController;this.inFlight=e;let t=this.checkId+=1,{doc:n}=this.view.state,r=dx(n);this.cache.useScope(this.options.cacheScope?.()??``);let i=this.options.maxTextLength??2e4,a=tx(r.text),o=a.filter(({end:e})=>e<=i),s=o.length<a.length,c=nx(r.text,o.filter(e=>!this.cache.get(e)),this.budget.value);this.view.dispatch(this.view.state.tr.setMeta(mx,{type:`start`,id:t}).setMeta(`addToHistory`,!1)),(c?this.options.check(c.text,e.signal):Promise.resolve(null)).then(n=>{if(e.signal.aborted||this.destroyed)return;if(n&&c){n.language&&(this.language=n.language);let e=!!n.limit_reached;if(!(e&&c.parts.length>1&&this.budget.shrink())){let t=rx(c,n.results??[]);for(let[r,i]of t)this.cache.set(r,{results:i.map(e=>({...e,language:e.language||n.language})),partial:e})}}let i=[],a=!1,l=!1;for(let e of o){let t=this.cache.get(e);if(!t){l=!0;continue}a||=t.partial;for(let n of t.results)i.push({...n,start:n.start+e.start,end:n.end+e.start})}let u=[];for(let{alerts:e}of $b({...n??{},results:i,language:this.language,limit_reached:a},r.text))for(let t of e){if(this.options.isIgnored?.(t))continue;let e=t.absOffset,n=e+t.data.text.length,i=px(r,e,n),a={...t,startOffset:e,endOffset:n};i&&u.push({...i,detail:a})}this.view.dispatch(this.view.state.tr.setMeta(mx,{type:`results`,id:t,alerts:u,limitReached:s||a,complete:!l}).setMeta(`addToHistory`,!1)),l&&(clearTimeout(this.timer),this.timer=setTimeout(()=>this.run(),0))}).catch(t=>{e.signal.aborted||this.destroyed||this.options.onError?.(t)})}destroy(){this.destroyed=!0,clearTimeout(this.timer),this.inFlight?.abort()}},Dx=e=>{let t;return new Gn({key:mx,state:{init:()=>({decorations:xs.empty,pending:null,recheckRequests:0,selectedId:null,limitReached:!1}),apply:Tx},props:{decorations:e=>mx.getState(e)?.decorations,handleDOMEvents:{compositionend:()=>(setTimeout(()=>t?.compositionEnded()),!1)}},view:n=>(t=new Ex(n,e),t)})},Ox=e=>e.dispatch(e.state.tr.setMeta(mx,{type:`recheck`}).setMeta(`addToHistory`,!1)),kx=(e,t)=>e.dispatch(e.state.tr.setMeta(mx,{type:`select`,id:t}).setMeta(`addToHistory`,!1)),Ax=(e,t)=>e.dispatch(e.state.tr.setMeta(mx,{type:`dismiss`,text:t}).setMeta(`addToHistory`,!1)),jx=nf.create({name:`wittyCheck`,addOptions(){return{check:()=>Promise.reject(Error(`WittyCheck: no checker`)),delay:500}},addProseMirrorPlugins(){return[Dx(this.options)]}}),Mx=`gender_format`,Nx=[`/in`,`/-in`,`_in`,`*in`,`:in`,`(-)`,`()`,`In`],Px=`de-e`,Fx=`gendered_denominations_ending_advanced`,Ix=(e,t)=>{let n=e.disabled_categories??[],r=n.filter(e=>e!==Fx&&e!==Fx.replace(/_advanced$/,``)),i=r.length!==n.length||e.gendered_roles_format===`none`||e.gendered_roles_format===`binary_gender`;return{config:{...e,german_gender_ending:t,...e.disabled_categories?{disabled_categories:r}:{},gendered_roles_format:`inclusive_gender`},needed:i}},Lx=(e,t=Mx)=>e.filter(({detail:e})=>e.data.bulk===t&&e.data.alternatives?.length===1&&typeof e.data.alternatives[0].text==`string`),Rx=(e,t)=>{let n=e.tr;for(let e of[...t].sort((e,t)=>t.from-e.from))n.insertText(e.detail.data.alternatives[0].text,e.from,e.to);return n},zx=/\p{Ll}(?:([*_:]|\/-?)in(?:nen)?|(In)(?:nen)?|\((-?)in(?:nen)?\))(?!\p{L})/gu,Bx=e=>{let[,t,n,r]=e;return n?`In`:r===void 0?`${t}in`:r?`(-)`:`()`},Vx=(e,t)=>[...e.matchAll(zx)].some(e=>Bx(e)!==t),Hx=(e,t,n)=>{let r=n.filter(({detail:e})=>e.data.subcategory===Fx);return r.some(({detail:e})=>!e.data.bulk)?`unsupported`:!r.length&&Vx(e,t)?`disabled`:`nothing`},Ux=c((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&ne(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ne(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var ee=new MessageChannel,te=ee.port2;ee.port1.onmessage=D,O=function(){te.postMessage(null)}}else O=function(){_(D,0)};function ne(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,ne(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Wx=c(((e,t)=>{t.exports=Ux()})),Gx=c((e=>{var t=ry();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)}},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()},e.version=`19.2.8`})),Kx=c(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Gx()})),qx=c((e=>{var t=Wx(),n=ry(),r=Kx();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function u(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function d(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=d(e),t!==null)return t;e=e.sibling}return null}var f=Object.assign,p=Symbol.for(`react.element`),m=Symbol.for(`react.transitional.element`),h=Symbol.for(`react.portal`),g=Symbol.for(`react.fragment`),_=Symbol.for(`react.strict_mode`),v=Symbol.for(`react.profiler`),y=Symbol.for(`react.consumer`),b=Symbol.for(`react.context`),x=Symbol.for(`react.forward_ref`),S=Symbol.for(`react.suspense`),C=Symbol.for(`react.suspense_list`),w=Symbol.for(`react.memo`),T=Symbol.for(`react.lazy`),E=Symbol.for(`react.activity`),D=Symbol.for(`react.memo_cache_sentinel`),O=Symbol.iterator;function ee(e){return typeof e!=`object`||!e?null:(e=O&&e[O]||e[`@@iterator`],typeof e==`function`?e:null)}var te=Symbol.for(`react.client.reference`);function ne(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===te?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case g:return`Fragment`;case v:return`Profiler`;case _:return`StrictMode`;case S:return`Suspense`;case C:return`SuspenseList`;case E:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case h:return`Portal`;case b:return e.displayName||`Context`;case y:return(e._context.displayName||`Context`)+`.Consumer`;case x:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case w:return t=e.displayName||null,t===null?ne(e.type)||`Memo`:t;case T:t=e._payload,e=e._init;try{return ne(e(t))}catch{}}return null}var re=Array.isArray,k=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,A=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ie={pending:!1,data:null,method:null,action:null},ae=[],oe=-1;function se(e){return{current:e}}function ce(e){0>oe||(e.current=ae[oe],ae[oe]=null,oe--)}function le(e,t){oe++,ae[oe]=e.current,e.current=t}var ue=se(null),de=se(null),fe=se(null),pe=se(null);function me(e,t){switch(le(fe,t),le(de,e),le(ue,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Qd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Qd(t),e=$d(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}ce(ue),le(ue,e)}function he(){ce(ue),ce(de),ce(fe)}function ge(e){e.memoizedState!==null&&le(pe,e);var t=ue.current,n=$d(t,e.type);t!==n&&(le(de,e),le(ue,n))}function _e(e){de.current===e&&(ce(ue),ce(de)),pe.current===e&&(ce(pe),lp._currentValue=ie)}var ve,ye;function be(e){if(ve===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);ve=t&&t[1]||``,ye=-1<e.stack.indexOf(`
137
+ `,cx=``,lx=new Set([`codeBlock`]),ux=new Set([`code`]),dx=e=>{let t=``,n=[],r=!1,i=(e,r)=>{if(e){if(r!==null){let i=n[n.length-1];i&&i.textEnd===t.length&&i.pos+(i.textEnd-i.textStart)===r?i.textEnd+=e.length:n.push({textStart:t.length,textEnd:t.length+e.length,pos:r})}t+=e}},a=()=>{t.endsWith(cx)||i(cx,null)};return e.descendants((e,t)=>lx.has(e.type.name)?!1:e.isTextblock?(r&&i(ox,null),r=!0,!0):e.isText?(e.marks.some(e=>ux.has(e.type.name))?a():i(e.text??``,t),!1):e.type.name===`hardBreak`?(i(sx,null),!1):e.isInline&&e.isAtom?(a(),!1):!0),{text:t,segments:n}},fx=(e,t)=>{let n=0,r=e.segments.length-1;for(;n<=r;){let i=n+r>>1,a=e.segments[i];if(t<a.textStart)r=i-1;else if(t>=a.textEnd)n=i+1;else return a}},px=(e,t,n)=>{if(t<0||n<=t||n>e.text.length)return null;let r=fx(e,t);return!r||n>r.textEnd?null:{from:r.pos+(t-r.textStart),to:r.pos+(n-r.textStart)}},mx=new Jn(`wittyCheck`),hx=({data:e},t,n)=>`${e.category}:${e.text}:${t}:${n}`,gx=({data:e},t)=>[`witty-alert`,`witty-alert--${av(e.gravity,e.subcategory)}`,e.category===`orthography`&&`witty-alert--dotted`,t&&`witty-alert--selected`].filter(Boolean).join(` `),_x=(e,t)=>vs.inline(e.from,e.to,{class:gx(e.detail,e.id===t),"data-alert-id":e.id},{alert:e}),vx=e=>({...e.spec.alert,from:e.from,to:e.to}),yx=(e,t,n)=>xs.create(t,e.find().map(e=>_x(vx(e),n))),bx=e=>mx.getState(e)?.limitReached??!1,xx=e=>(mx.getState(e)?.decorations.find()??[]).map(vx),Sx=e=>{let t=[];return e.mapping.maps.forEach((n,r)=>{let i=e.mapping.slice(r+1);n.forEach((e,n,r,a)=>{t.push([i.map(r,-1),i.map(a,1)])})}),t},Cx=0,wx=(e,t,n,r,i)=>{let a=new Map;for(let e of r.find()){let t=e.spec.alert;a.set(hx(t.detail,e.from,e.to),t.id)}let o=[];for(let r of e){let e=t.map(r.from,1),s=t.map(r.to,-1);if(n.textBetween(e,s)!==r.detail.data.text)continue;let c=hx(r.detail,e,s),l=a.get(c)??`alert-${Cx+=1}`;o.push(_x({...r,id:l,from:e,to:s},i))}return xs.create(n,o)},Tx=(e,t)=>{let n=e.getMeta(mx);if(n?.type===`recheck`)return{...t,recheckRequests:t.recheckRequests+1};if(n?.type===`select`)return{...t,selectedId:n.id,decorations:yx(t.decorations,e.doc,n.id)};if(n?.type===`dismiss`)return{...t,decorations:t.decorations.remove(t.decorations.find().filter(e=>vx(e).detail.data.text===n.text))};if(n?.type===`start`)return{...t,pending:{id:n.id,mapping:new xt}};if(n?.type===`results`)return t.pending?.id===n.id?{...t,decorations:wx(n.alerts,t.pending.mapping,e.doc,t.decorations,t.selectedId),pending:null,limitReached:n.limitReached}:t;if(!e.docChanged)return t;let r=t.decorations.map(e.mapping,e.doc);for(let[t,n]of Sx(e)){let e=r.find(t,n).filter(e=>e.from<n&&e.to>t);e.length&&(r=r.remove(e))}return{...t,decorations:r,pending:t.pending&&{id:t.pending.id,mapping:new xt([...t.pending.mapping.maps,...e.mapping.maps])}}},Ex=class{view;options;timer;inFlight;checkId=0;deferredByComposition=!1;destroyed=!1;cache=new ix;budget;language=``;constructor(e,t){this.view=e,this.options=t,this.budget=new ax(t.maxRequestLength??1e3),this.schedule()}update(e,t){let n=mx.getState(e.state)?.recheckRequests!==mx.getState(t)?.recheckRequests;n&&this.cache.clear(),(n||e.state.doc!==t.doc)&&this.schedule()}compositionEnded(){this.deferredByComposition&&(this.deferredByComposition=!1,this.schedule())}schedule(){clearTimeout(this.timer),this.timer=setTimeout(()=>this.run(),this.options.delay)}run(){if(this.destroyed)return;if(this.view.composing){this.deferredByComposition=!0;return}this.inFlight?.abort();let e=new AbortController;this.inFlight=e;let t=this.checkId+=1,{doc:n}=this.view.state,r=dx(n);this.cache.useScope(this.options.cacheScope?.()??``);let i=this.options.maxTextLength??2e4,a=tx(r.text),o=a.filter(({end:e})=>e<=i),s=o.length<a.length,c=nx(r.text,o.filter(e=>!this.cache.get(e)),this.budget.value);this.view.dispatch(this.view.state.tr.setMeta(mx,{type:`start`,id:t}).setMeta(`addToHistory`,!1)),(c?this.options.check(c.text,e.signal):Promise.resolve(null)).then(n=>{if(e.signal.aborted||this.destroyed)return;if(n&&c){n.language&&(this.language=n.language);let e=!!n.limit_reached;if(!(e&&c.parts.length>1&&this.budget.shrink())){let t=rx(c,n.results??[]);for(let[r,i]of t)this.cache.set(r,{results:i.map(e=>({...e,language:e.language||n.language})),partial:e})}}let i=[],a=!1,l=!1;for(let e of o){let t=this.cache.get(e);if(!t){l=!0;continue}a||=t.partial;for(let n of t.results)i.push({...n,start:n.start+e.start,end:n.end+e.start})}let u=[];for(let{alerts:e}of $b({...n??{},results:i,language:this.language,limit_reached:a},r.text))for(let t of e){if(this.options.isIgnored?.(t))continue;let e=t.absOffset,n=e+t.data.text.length,i=px(r,e,n),a={...t,startOffset:e,endOffset:n};i&&u.push({...i,detail:a})}this.view.dispatch(this.view.state.tr.setMeta(mx,{type:`results`,id:t,alerts:u,limitReached:s||a,complete:!l}).setMeta(`addToHistory`,!1)),l&&(clearTimeout(this.timer),this.timer=setTimeout(()=>this.run(),0))}).catch(t=>{e.signal.aborted||this.destroyed||this.options.onError?.(t)})}destroy(){this.destroyed=!0,clearTimeout(this.timer),this.inFlight?.abort()}},Dx=e=>{let t;return new Gn({key:mx,state:{init:()=>({decorations:xs.empty,pending:null,recheckRequests:0,selectedId:null,limitReached:!1}),apply:Tx},props:{decorations:e=>mx.getState(e)?.decorations,handleDOMEvents:{compositionend:()=>(setTimeout(()=>t?.compositionEnded()),!1)}},view:n=>(t=new Ex(n,e),t)})},Ox=e=>e.dispatch(e.state.tr.setMeta(mx,{type:`recheck`}).setMeta(`addToHistory`,!1)),kx=(e,t)=>e.dispatch(e.state.tr.setMeta(mx,{type:`select`,id:t}).setMeta(`addToHistory`,!1)),Ax=(e,t)=>e.dispatch(e.state.tr.setMeta(mx,{type:`dismiss`,text:t}).setMeta(`addToHistory`,!1)),jx=nf.create({name:`wittyCheck`,addOptions(){return{check:()=>Promise.reject(Error(`WittyCheck: no checker`)),delay:500}},addProseMirrorPlugins(){return[Dx(this.options)]}}),Mx=`gender_format`,Nx=[`/in`,`/-in`,`_in`,`*in`,`:in`,`(-)`,`()`,`In`],Px=`de-e`,Fx=`gendered_denominations_ending_advanced`,Ix=(e,t)=>{let n=e.disabled_categories??[],r=n.filter(e=>e!==Fx&&e!==Fx.replace(/_advanced$/,``)),i=r.length!==n.length||e.gendered_roles_format===`none`||e.gendered_roles_format===`binary_gender`;return{config:{...e,german_gender_ending:t,...e.disabled_categories?{disabled_categories:r}:{},gendered_roles_format:`inclusive_gender`},needed:i}},Lx=(e,t=Mx)=>e.filter(({detail:e})=>e.data.bulk===t&&e.data.alternatives?.length===1&&typeof e.data.alternatives[0].text==`string`),Rx=(e,t)=>{let n=e.tr;for(let e of[...t].sort((e,t)=>t.from-e.from))n.insertText(e.detail.data.alternatives[0].text,e.from,e.to);return n},zx=/\p{Ll}(?:([*_:]|\/-?)in(?:nen)?|(In)(?:nen)?|\((-?)in(?:nen)?\))(?!\p{L})/gu,Bx=e=>{let[,t,n,r]=e;return n?`In`:r===void 0?`${t}in`:r?`(-)`:`()`},Vx=(e,t)=>[...e.matchAll(zx)].some(e=>Bx(e)!==t),Hx=(e,t,n)=>{let r=n.filter(({detail:e})=>e.data.subcategory===Fx);return r.some(({detail:e})=>!e.data.bulk)?`unsupported`:!r.length&&Vx(e,t)?`disabled`:`nothing`},Ux=(e,t,n,r)=>{let i=e.separators.find(e=>e!==t);if(i)return{outcome:`forced`,applied:i};let a=Lx(r);if(a.length)return{outcome:`switched`,apply:a};let o=e.bulkActions.filter(e=>e!==void 0);return o.length?{outcome:o.some(e=>e.includes(`gender_format`))?`nothing`:`disabled`}:{outcome:Hx(n,t,r)}},Wx=c((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&ne(x,t.startTime-e)}}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ne(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var ee=new MessageChannel,te=ee.port2;ee.port1.onmessage=D,O=function(){te.postMessage(null)}}else O=function(){_(D,0)};function ne(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,ne(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Gx=c(((e,t)=>{t.exports=Wx()})),Kx=c((e=>{var t=ry();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)}},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()},e.version=`19.2.8`})),qx=c(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Kx()})),Jx=c((e=>{var t=Gx(),n=ry(),r=qx();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function u(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function d(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=d(e),t!==null)return t;e=e.sibling}return null}var f=Object.assign,p=Symbol.for(`react.element`),m=Symbol.for(`react.transitional.element`),h=Symbol.for(`react.portal`),g=Symbol.for(`react.fragment`),_=Symbol.for(`react.strict_mode`),v=Symbol.for(`react.profiler`),y=Symbol.for(`react.consumer`),b=Symbol.for(`react.context`),x=Symbol.for(`react.forward_ref`),S=Symbol.for(`react.suspense`),C=Symbol.for(`react.suspense_list`),w=Symbol.for(`react.memo`),T=Symbol.for(`react.lazy`),E=Symbol.for(`react.activity`),D=Symbol.for(`react.memo_cache_sentinel`),O=Symbol.iterator;function ee(e){return typeof e!=`object`||!e?null:(e=O&&e[O]||e[`@@iterator`],typeof e==`function`?e:null)}var te=Symbol.for(`react.client.reference`);function ne(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===te?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case g:return`Fragment`;case v:return`Profiler`;case _:return`StrictMode`;case S:return`Suspense`;case C:return`SuspenseList`;case E:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case h:return`Portal`;case b:return e.displayName||`Context`;case y:return(e._context.displayName||`Context`)+`.Consumer`;case x:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case w:return t=e.displayName||null,t===null?ne(e.type)||`Memo`:t;case T:t=e._payload,e=e._init;try{return ne(e(t))}catch{}}return null}var re=Array.isArray,k=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,A=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ie={pending:!1,data:null,method:null,action:null},ae=[],oe=-1;function se(e){return{current:e}}function ce(e){0>oe||(e.current=ae[oe],ae[oe]=null,oe--)}function le(e,t){oe++,ae[oe]=e.current,e.current=t}var ue=se(null),de=se(null),fe=se(null),pe=se(null);function me(e,t){switch(le(fe,t),le(de,e),le(ue,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Qd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Qd(t),e=$d(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}ce(ue),le(ue,e)}function he(){ce(ue),ce(de),ce(fe)}function ge(e){e.memoizedState!==null&&le(pe,e);var t=ue.current,n=$d(t,e.type);t!==n&&(le(de,e),le(ue,n))}function _e(e){de.current===e&&(ce(ue),ce(de)),pe.current===e&&(ce(pe),lp._currentValue=ie)}var ve,ye;function be(e){if(ve===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);ve=t&&t[1]||``,ye=-1<e.stack.indexOf(`
138
138
  at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
139
139
  `+ve+e+ye}var xe=!1;function Se(e,t){if(!e||xe)return``;xe=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
140
140
  `),l=s.split(`
@@ -142,14 +142,14 @@ img.ProseMirror-separator {
142
142
  `+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{xe=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?be(n):``}function Ce(e,t){switch(e.tag){case 26:case 27:case 5:return be(e.type);case 16:return be(`Lazy`);case 13:return e.child!==t&&t!==null?be(`Suspense Fallback`):be(`Suspense`);case 19:return be(`SuspenseList`);case 0:case 15:return Se(e.type,!1);case 11:return Se(e.type.render,!1);case 1:return Se(e.type,!0);case 31:return be(`Activity`);default:return``}}function we(e){try{var t=``,n=null;do t+=Ce(e,n),n=e,e=e.return;while(e);return t}catch(e){return`
143
143
  Error generating stack: `+e.message+`
144
144
  `+e.stack}}var Te=Object.prototype.hasOwnProperty,Ee=t.unstable_scheduleCallback,De=t.unstable_cancelCallback,Oe=t.unstable_shouldYield,ke=t.unstable_requestPaint,Ae=t.unstable_now,je=t.unstable_getCurrentPriorityLevel,Me=t.unstable_ImmediatePriority,Ne=t.unstable_UserBlockingPriority,Pe=t.unstable_NormalPriority,Fe=t.unstable_LowPriority,Ie=t.unstable_IdlePriority,Le=t.log,Re=t.unstable_setDisableYieldValue,ze=null,Be=null;function Ve(e){if(typeof Le==`function`&&Re(e),Be&&typeof Be.setStrictMode==`function`)try{Be.setStrictMode(ze,e)}catch{}}var He=Math.clz32?Math.clz32:Ge,Ue=Math.log,We=Math.LN2;function Ge(e){return e>>>=0,e===0?32:31-(Ue(e)/We|0)|0}var Ke=256,qe=262144,Je=4194304;function Ye(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Xe(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Ye(n))):i=Ye(o):i=Ye(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Ye(n))):i=Ye(o)):i=Ye(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Ze(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Qe(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function $e(){var e=Je;return Je<<=1,!(Je&62914560)&&(Je=4194304),e}function et(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function tt(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function nt(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-He(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&rt(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function rt(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-He(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function it(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-He(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function at(e,t){var n=t&-t;return n=n&42?1:ot(n),(n&(e.suspendedLanes|t))===0?n:0}function ot(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function st(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function ct(){var e=A.p;return e===0?(e=window.event,e===void 0?32:Cp(e.type)):e}function lt(e,t){var n=A.p;try{return A.p=e,t()}finally{A.p=n}}var ut=Math.random().toString(36).slice(2),dt=`__reactFiber$`+ut,ft=`__reactProps$`+ut,pt=`__reactContainer$`+ut,mt=`__reactEvents$`+ut,ht=`__reactListeners$`+ut,gt=`__reactHandles$`+ut,_t=`__reactResources$`+ut,vt=`__reactMarker$`+ut;function yt(e){delete e[dt],delete e[ft],delete e[mt],delete e[ht],delete e[gt]}function bt(e){var t=e[dt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[pt]||n[dt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Sf(e);e!==null;){if(n=e[dt])return n;e=Sf(e)}return t}e=n,n=e.parentNode}return null}function xt(e){if(e=e[dt]||e[pt]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function St(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function Ct(e){var t=e[_t];return t||=e[_t]={hoistableStyles:new Map,hoistableScripts:new Map},t}function wt(e){e[vt]=!0}var Tt=new Set,Et={};function Dt(e,t){Ot(e,t),Ot(e+`Capture`,t)}function Ot(e,t){for(Et[e]=t,e=0;e<t.length;e++)Tt.add(t[e])}var kt=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),At={},jt={};function Mt(e){return Te.call(jt,e)?!0:Te.call(At,e)?!1:kt.test(e)?jt[e]=!0:(At[e]=!0,!1)}function Nt(e,t,n){if(Mt(t)){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}}function Pt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Ft(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function It(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function Lt(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Rt(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function zt(e){if(!e._valueTracker){var t=Lt(e)?`checked`:`value`;e._valueTracker=Rt(e,t,``+e[t])}}function Bt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=Lt(e)?e.checked?`true`:`false`:e.value),e=r,e!==n&&(t.setValue(e),!0)}function Vt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Ht=/[\n"\\]/g;function Ut(e){return e.replace(Ht,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Wt(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+It(t)):e.value!==``+It(t)&&(e.value=``+It(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Kt(e,o,It(n)):Kt(e,o,It(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+It(s):e.removeAttribute(`name`)}function Gt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){zt(e);return}n=n==null?``:``+It(n),t=t==null?n:``+It(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),zt(e)}function Kt(e,t,n){t===`number`&&Vt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function qt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+It(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Jt(e,t,n){if(t!=null&&(t=``+It(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+It(n)}function Yt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(re(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}n=It(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),zt(e)}function Xt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Zt=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Qt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Zt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function $t(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&Qt(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&Qt(e,o,t[o])}function en(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var tn=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),nn=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function rn(e){return nn.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function an(){}var on=null;function sn(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var cn=null,ln=null;function un(e){var t=xt(e);if(t&&(e=t.stateNode)){var n=e[ft]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Wt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Ut(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[ft]||null;if(!a)throw Error(i(90));Wt(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&Bt(r)}break a;case`textarea`:Jt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&qt(e,!!n.multiple,t,!1)}}}var dn=!1;function fn(e,t,n){if(dn)return e(t,n);dn=!0;try{return e(t)}finally{if(dn=!1,(cn!==null||ln!==null)&&(ku(),cn&&(t=cn,e=ln,ln=cn=null,un(t),e)))for(t=0;t<e.length;t++)un(e[t])}}function pn(e,t){var n=e.stateNode;if(n===null)return null;var r=n[ft]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=e!==`button`&&e!==`input`&&e!==`select`&&e!==`textarea`),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var mn=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0,hn=!1;if(mn)try{var gn={};Object.defineProperty(gn,"passive",{get:function(){hn=!0}}),window.addEventListener(`test`,gn,gn),window.removeEventListener(`test`,gn,gn)}catch{hn=!1}var _n=null,vn=null,yn=null;function bn(){if(yn)return yn;var e,t=vn,n=t.length,r,i=`value`in _n?_n.value:_n.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return yn=i.slice(e,1<r?1-r:void 0)}function xn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Sn(){return!0}function Cn(){return!1}function wn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?Sn:Cn,this.isPropagationStopped=Cn,this}return f(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=Sn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=Sn)},persist:function(){},isPersistent:Sn}),t}var Tn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},j=wn(Tn),En=f({},Tn,{view:0,detail:0}),Dn=wn(En),On,M,kn,N=f({},En,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Bn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==kn&&(kn&&e.type===`mousemove`?(On=e.screenX-kn.screenX,M=e.screenY-kn.screenY):M=On=0,kn=e),On)},movementY:function(e){return`movementY`in e?e.movementY:M}}),An=wn(N),jn=wn(f({},N,{dataTransfer:0})),Mn=wn(f({},En,{relatedTarget:0})),Nn=wn(f({},Tn,{animationName:0,elapsedTime:0,pseudoElement:0})),Pn=wn(f({},Tn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),Fn=wn(f({},Tn,{data:0})),In={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},Ln={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Rn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function zn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Rn[e])?!!t[e]:!1}function Bn(){return zn}var Vn=wn(f({},En,{key:function(e){if(e.key){var t=In[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=xn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?Ln[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Bn,charCode:function(e){return e.type===`keypress`?xn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?xn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Hn=wn(f({},N,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Un=wn(f({},En,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Bn})),Wn=wn(f({},Tn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Gn=wn(f({},N,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Kn=wn(f({},Tn,{newState:0,oldState:0})),qn=[9,13,27,32],Jn=mn&&`CompositionEvent`in window,Yn=null;mn&&`documentMode`in document&&(Yn=document.documentMode);var Xn=mn&&`TextEvent`in window&&!Yn,Zn=mn&&(!Jn||Yn&&8<Yn&&11>=Yn),Qn=` `,$n=!1;function er(e,t){switch(e){case`keyup`:return qn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function tr(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var nr=!1;function rr(e,t){switch(e){case`compositionend`:return tr(t);case`keypress`:return t.which===32?($n=!0,Qn):null;case`textInput`:return e=t.data,e===Qn&&$n?null:e;default:return null}}function ir(e,t){if(nr)return e===`compositionend`||!Jn&&er(e,t)?(e=bn(),yn=vn=_n=null,nr=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return Zn&&t.locale!==`ko`?null:t.data;default:return null}}var ar={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function or(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!ar[e.type]:t===`textarea`}function sr(e,t,n,r){cn?ln?ln.push(r):ln=[r]:cn=r,t=Id(t,`onChange`),0<t.length&&(n=new j(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var cr=null,lr=null;function ur(e){kd(e,0)}function dr(e){if(Bt(St(e)))return e}function fr(e,t){if(e===`change`)return t}var pr=!1;if(mn){var mr;if(mn){var hr=`oninput`in document;if(!hr){var gr=document.createElement(`div`);gr.setAttribute(`oninput`,`return;`),hr=typeof gr.oninput==`function`}mr=hr}else mr=!1;pr=mr&&(!document.documentMode||9<document.documentMode)}function _r(){cr&&(cr.detachEvent(`onpropertychange`,vr),lr=cr=null)}function vr(e){if(e.propertyName===`value`&&dr(lr)){var t=[];sr(t,lr,e,sn(e)),fn(ur,t)}}function yr(e,t,n){e===`focusin`?(_r(),cr=t,lr=n,cr.attachEvent(`onpropertychange`,vr)):e===`focusout`&&_r()}function br(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return dr(lr)}function xr(e,t){if(e===`click`)return dr(t)}function Sr(e,t){if(e===`input`||e===`change`)return dr(t)}function Cr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var wr=typeof Object.is==`function`?Object.is:Cr;function Tr(e,t){if(wr(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Te.call(t,i)||!wr(e[i],t[i]))return!1}return!0}function Er(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Dr(e,t){var n=Er(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=Er(n)}}function Or(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Or(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function kr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Vt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Vt(e.document)}return t}function Ar(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var jr=mn&&`documentMode`in document&&11>=document.documentMode,Mr=null,Nr=null,Pr=null,Fr=!1;function Ir(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Fr||Mr==null||Mr!==Vt(r)||(r=Mr,`selectionStart`in r&&Ar(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Pr&&Tr(Pr,r)||(Pr=r,r=Id(Nr,`onSelect`),0<r.length&&(t=new j(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Mr)))}function Lr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Rr={animationend:Lr(`Animation`,`AnimationEnd`),animationiteration:Lr(`Animation`,`AnimationIteration`),animationstart:Lr(`Animation`,`AnimationStart`),transitionrun:Lr(`Transition`,`TransitionRun`),transitionstart:Lr(`Transition`,`TransitionStart`),transitioncancel:Lr(`Transition`,`TransitionCancel`),transitionend:Lr(`Transition`,`TransitionEnd`)},zr={},Br={};mn&&(Br=document.createElement(`div`).style,`AnimationEvent`in window||(delete Rr.animationend.animation,delete Rr.animationiteration.animation,delete Rr.animationstart.animation),`TransitionEvent`in window||delete Rr.transitionend.transition);function Vr(e){if(zr[e])return zr[e];if(!Rr[e])return e;var t=Rr[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Br)return zr[e]=t[n];return e}var Hr=Vr(`animationend`),Ur=Vr(`animationiteration`),Wr=Vr(`animationstart`),Gr=Vr(`transitionrun`),Kr=Vr(`transitionstart`),qr=Vr(`transitioncancel`),Jr=Vr(`transitionend`),Yr=new Map,Xr=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);Xr.push(`scrollEnd`);function Zr(e,t){Yr.set(e,t),Dt(t,[e])}var Qr=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},$r=[],ei=0,ti=0;function ni(){for(var e=ei,t=ti=ei=0;t<e;){var n=$r[t];$r[t++]=null;var r=$r[t];$r[t++]=null;var i=$r[t];$r[t++]=null;var a=$r[t];if($r[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&oi(n,i,a)}}function ri(e,t,n,r){$r[ei++]=e,$r[ei++]=t,$r[ei++]=n,$r[ei++]=r,ti|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function ii(e,t,n,r){return ri(e,t,n,r),si(e)}function ai(e,t){return ri(e,null,null,t),si(e)}function oi(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-He(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function si(e){if(50<bu)throw bu=0,xu=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var ci={};function li(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function ui(e,t,n,r){return new li(e,t,n,r)}function di(e){return e=e.prototype,!(!e||!e.isReactComponent)}function fi(e,t){var n=e.alternate;return n===null?(n=ui(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function pi(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function mi(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)di(e)&&(s=1);else if(typeof e==`string`)s=ep(e,n,ue.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case E:return e=ui(31,n,t,a),e.elementType=E,e.lanes=o,e;case g:return hi(n.children,a,o,t);case _:s=8,a|=24;break;case v:return e=ui(12,n,t,a|2),e.elementType=v,e.lanes=o,e;case S:return e=ui(13,n,t,a),e.elementType=S,e.lanes=o,e;case C:return e=ui(19,n,t,a),e.elementType=C,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case b:s=10;break a;case y:s=9;break a;case x:s=11;break a;case w:s=14;break a;case T:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=ui(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function hi(e,t,n,r){return e=ui(7,e,r,t),e.lanes=n,e}function gi(e,t,n){return e=ui(6,e,null,t),e.lanes=n,e}function _i(e){var t=ui(18,null,null,0);return t.stateNode=e,t}function vi(e,t,n){return t=ui(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var yi=new WeakMap;function bi(e,t){if(typeof e==`object`&&e){var n=yi.get(e);return n===void 0?(t={value:e,source:t,stack:we(t)},yi.set(e,t),t):n}return{value:e,source:t,stack:we(t)}}var xi=[],Si=0,Ci=null,wi=0,Ti=[],Ei=0,Di=null,Oi=1,ki=``;function Ai(e,t){xi[Si++]=wi,xi[Si++]=Ci,Ci=e,wi=t}function ji(e,t,n){Ti[Ei++]=Oi,Ti[Ei++]=ki,Ti[Ei++]=Di,Di=e;var r=Oi;e=ki;var i=32-He(r)-1;r&=~(1<<i),n+=1;var a=32-He(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Oi=1<<32-He(t)+i|n<<i|r,ki=a+e}else Oi=1<<a|n<<i|r,ki=e}function Mi(e){e.return!==null&&(Ai(e,1),ji(e,1,0))}function Ni(e){for(;e===Ci;)Ci=xi[--Si],xi[Si]=null,wi=xi[--Si],xi[Si]=null;for(;e===Di;)Di=Ti[--Ei],Ti[Ei]=null,ki=Ti[--Ei],Ti[Ei]=null,Oi=Ti[--Ei],Ti[Ei]=null}function Pi(e,t){Ti[Ei++]=Oi,Ti[Ei++]=ki,Ti[Ei++]=Di,Oi=t.id,ki=t.overflow,Di=e}var Fi=null,Ii=null,P=!1,Li=null,Ri=!1,zi=Error(i(519));function Bi(e){throw Ki(bi(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),zi}function Vi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[dt]=e,t[ft]=r,n){case`dialog`:B(`cancel`,t),B(`close`,t);break;case`iframe`:case`object`:case`embed`:B(`load`,t);break;case`video`:case`audio`:for(n=0;n<Dd.length;n++)B(Dd[n],t);break;case`source`:B(`error`,t);break;case`img`:case`image`:case`link`:B(`error`,t),B(`load`,t);break;case`details`:B(`toggle`,t);break;case`input`:B(`invalid`,t),Gt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:B(`invalid`,t);break;case`textarea`:B(`invalid`,t),Yt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||Hd(t.textContent,n)?(r.popover!=null&&(B(`beforetoggle`,t),B(`toggle`,t)),r.onScroll!=null&&B(`scroll`,t),r.onScrollEnd!=null&&B(`scrollend`,t),r.onClick!=null&&(t.onclick=an),t=!0):t=!1,t||Bi(e,!0)}function Hi(e){for(Fi=e.return;Fi;)switch(Fi.tag){case 5:case 31:case 13:Ri=!1;return;case 27:case 3:Ri=!0;return;default:Fi=Fi.return}}function Ui(e){if(e!==Fi)return!1;if(!P)return Hi(e),P=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=n===`form`||n===`button`||ef(e.type,e.memoizedProps)),n=!n),n&&Ii&&Bi(e),Hi(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Ii=xf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Ii=xf(e)}else t===27?(t=Ii,lf(e.type)?(e=bf,bf=null,Ii=e):Ii=t):Ii=Fi?yf(e.stateNode.nextSibling):null;return!0}function Wi(){Ii=Fi=null,P=!1}function Gi(){var e=Li;return e!==null&&(ou===null?ou=e:ou.push.apply(ou,e),Li=null),e}function Ki(e){Li===null?Li=[e]:Li.push(e)}var qi=se(null),Ji=null,Yi=null;function Xi(e,t,n){le(qi,t._currentValue),t._currentValue=n}function Zi(e){e._currentValue=qi.current,ce(qi)}function Qi(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function $i(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Qi(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),Qi(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function ea(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;wr(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===pe.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[lp]:e.push(lp))}a=a.return}e!==null&&$i(t,e,n,r),t.flags|=262144}function ta(e){for(e=e.firstContext;e!==null;){if(!wr(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function na(e){Ji=e,Yi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function ra(e){return aa(Ji,e)}function ia(e,t){return Ji===null&&na(e),aa(e,t)}function aa(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Yi===null){if(e===null)throw Error(i(308));Yi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Yi=Yi.next=t;return n}var oa=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},sa=t.unstable_scheduleCallback,ca=t.unstable_NormalPriority,la={$$typeof:b,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function ua(){return{controller:new oa,data:new Map,refCount:0}}function da(e){e.refCount--,e.refCount===0&&sa(ca,function(){e.controller.abort()})}var fa=null,pa=0,ma=0,ha=null;function ga(e,t){if(fa===null){var n=fa=[];pa=0,ma=xd(),ha={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return pa++,t.then(_a,_a),t}function _a(){if(--pa===0&&fa!==null){ha!==null&&(ha.status=`fulfilled`);var e=fa;fa=null,ma=0,ha=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function va(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var ya=k.S;k.S=function(e,t){lu=Ae(),typeof t==`object`&&t&&typeof t.then==`function`&&ga(e,t),ya!==null&&ya(e,t)};var ba=se(null);function xa(){var e=ba.current;return e===null?Kl.pooledCache:e}function Sa(e,t){t===null?le(ba,ba.current):le(ba,t.pool)}function Ca(){var e=xa();return e===null?null:{parent:la._currentValue,pool:e}}var wa=Error(i(460)),Ta=Error(i(474)),Ea=Error(i(542)),Da={then:function(){}};function Oa(e){return e=e.status,e===`fulfilled`||e===`rejected`}function ka(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(an,an),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Na(e),e;default:if(typeof t.status==`string`)t.then(an,an);else{if(e=Kl,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Na(e),e}throw ja=t,wa}}function Aa(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(ja=e,wa):e}}var ja=null;function Ma(){if(ja===null)throw Error(i(459));var e=ja;return ja=null,e}function Na(e){if(e===wa||e===Ea)throw Error(i(483))}var Pa=null,Fa=0;function Ia(e){var t=Fa;return Fa+=1,Pa===null&&(Pa=[]),ka(Pa,e,t)}function La(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Ra(e,t){throw t.$$typeof===p?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function za(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=fi(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=gi(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===g?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===T&&Aa(i)===t.type)?(t=a(t,n.props),La(t,n),t.return=e,t):(t=mi(n.type,n.key,n.props,null,e.mode,r),La(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=vi(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=hi(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=gi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case m:return n=mi(t.type,t.key,t.props,null,e.mode,n),La(n,t),n.return=e,n;case h:return t=vi(t,e.mode,n),t.return=e,t;case T:return t=Aa(t),f(e,t,n)}if(re(t)||ee(t))return t=hi(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,Ia(t),n);if(t.$$typeof===b)return f(e,ia(e,t),n);Ra(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case m:return n.key===i?l(e,t,n,r):null;case h:return n.key===i?u(e,t,n,r):null;case T:return n=Aa(n),p(e,t,n,r)}if(re(n)||ee(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,Ia(n),r);if(n.$$typeof===b)return p(e,t,ia(e,n),r);Ra(e,n)}return null}function _(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case m:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case h:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case T:return r=Aa(r),_(e,t,n,r,i)}if(re(r)||ee(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return _(e,t,n,Ia(r),i);if(r.$$typeof===b)return _(e,t,n,ia(t,r),i);Ra(t,r)}return null}function v(i,a,s,c){for(var l=null,u=null,d=a,m=a=0,h=null;d!==null&&m<s.length;m++){d.index>m?(h=d,d=null):h=d.sibling;var g=p(i,d,s[m],c);if(g===null){d===null&&(d=h);break}e&&d&&g.alternate===null&&t(i,d),a=o(g,a,m),u===null?l=g:u.sibling=g,u=g,d=h}if(m===s.length)return n(i,d),P&&Ai(i,m),l;if(d===null){for(;m<s.length;m++)d=f(i,s[m],c),d!==null&&(a=o(d,a,m),u===null?l=d:u.sibling=d,u=d);return P&&Ai(i,m),l}for(d=r(d);m<s.length;m++)h=_(d,i,m,s[m],c),h!==null&&(e&&h.alternate!==null&&d.delete(h.key===null?m:h.key),a=o(h,a,m),u===null?l=h:u.sibling=h,u=h);return e&&d.forEach(function(e){return t(i,e)}),P&&Ai(i,m),l}function y(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,m=s,h=s=0,g=null,v=c.next();m!==null&&!v.done;h++,v=c.next()){m.index>h?(g=m,m=null):g=m.sibling;var y=p(a,m,v.value,l);if(y===null){m===null&&(m=g);break}e&&m&&y.alternate===null&&t(a,m),s=o(y,s,h),d===null?u=y:d.sibling=y,d=y,m=g}if(v.done)return n(a,m),P&&Ai(a,h),u;if(m===null){for(;!v.done;h++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,h),d===null?u=v:d.sibling=v,d=v);return P&&Ai(a,h),u}for(m=r(m);!v.done;h++,v=c.next())v=_(m,a,h,v.value,l),v!==null&&(e&&v.alternate!==null&&m.delete(v.key===null?h:v.key),s=o(v,s,h),d===null?u=v:d.sibling=v,d=v);return e&&m.forEach(function(e){return t(a,e)}),P&&Ai(a,h),u}function x(e,r,o,c){if(typeof o==`object`&&o&&o.type===g&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case m:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===g){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===T&&Aa(l)===r.type){n(e,r.sibling),c=a(r,o.props),La(c,o),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}o.type===g?(c=hi(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=mi(o.type,o.key,o.props,null,e.mode,c),La(c,o),c.return=e,e=c)}return s(e);case h:a:{for(l=o.key;r!==null;){if(r.key===l){if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}n(e,r);break}t(e,r),r=r.sibling}c=vi(o,e.mode,c),c.return=e,e=c}return s(e);case T:return o=Aa(o),x(e,r,o,c)}if(re(o))return v(e,r,o,c);if(ee(o)){if(l=ee(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return x(e,r,Ia(o),c);if(o.$$typeof===b)return x(e,r,ia(e,o),c);Ra(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=gi(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Fa=0;var i=x(e,t,n,r);return Pa=null,i}catch(t){if(t===wa||t===Ea)throw t;var a=ui(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ba=za(!0),Va=za(!1),Ha=!1;function Ua(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Wa(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ga(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ka(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,L&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=si(e),oi(e,null,n),t}return ri(e,r,t,n),si(e)}function qa(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,it(e,n)}}function Ja(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Ya=!1;function Xa(){if(Ya){var e=ha;if(e!==null)throw e}}function Za(e,t,n,r){Ya=!1;var i=e.updateQueue;Ha=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var p=s.lane&-536870913,m=p!==s.lane;if(m?(z&p)===p:(r&p)===p){p!==0&&p===ma&&(Ya=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;p=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,p);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,p=typeof h==`function`?h.call(_,d,p):h,p==null)break a;d=f({},d,p);break a;case 2:Ha=!0}}p=s.callback,p!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[p]:m.push(p))}else m={lane:p,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=p;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),eu|=o,e.lanes=o,e.memoizedState=d}}function Qa(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function $a(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)Qa(n[e],t)}var eo=se(null),to=se(0);function no(e,t){e=Ql,le(to,e),le(eo,t),Ql=e|t.baseLanes}function ro(){le(to,Ql),le(eo,eo.current)}function io(){Ql=to.current,ce(eo),ce(to)}var ao=se(null),oo=null;function so(e){var t=e.alternate;le(po,po.current&1),le(ao,e),oo===null&&(t===null||eo.current!==null||t.memoizedState!==null)&&(oo=e)}function co(e){le(po,po.current),le(ao,e),oo===null&&(oo=e)}function lo(e){e.tag===22?(le(po,po.current),le(ao,e),oo===null&&(oo=e)):uo(e)}function uo(){le(po,po.current),le(ao,ao.current)}function fo(e){ce(ao),oo===e&&(oo=null),ce(po)}var po=se(0);function mo(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||gf(n)||_f(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var ho=0,F=null,go=null,_o=null,vo=!1,yo=!1,bo=!1,xo=0,So=0,Co=null,wo=0;function To(){throw Error(i(321))}function Eo(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!wr(e[n],t[n]))return!1;return!0}function Do(e,t,n,r,i,a){return ho=a,F=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,k.H=e===null||e.memoizedState===null?Gs:Ks,bo=!1,a=n(r,i),bo=!1,yo&&(a=ko(t,n,r,i)),Oo(e),a}function Oo(e){k.H=Ws;var t=go!==null&&go.next!==null;if(ho=0,_o=go=F=null,vo=!1,So=0,Co=null,t)throw Error(i(300));e===null||lc||(e=e.dependencies,e!==null&&ta(e)&&(lc=!0))}function ko(e,t,n,r){F=e;var a=0;do{if(yo&&(Co=null),So=0,yo=!1,25<=a)throw Error(i(301));if(a+=1,_o=go=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}k.H=qs,o=t(n,r)}while(yo);return o}function Ao(){var e=k.H,t=e.useState()[0];return t=typeof t.then==`function`?Lo(t):t,e=e.useState()[0],(go===null?null:go.memoizedState)!==e&&(F.flags|=1024),t}function jo(){var e=xo!==0;return xo=0,e}function Mo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function No(e){if(vo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}vo=!1}ho=0,_o=go=F=null,yo=!1,So=xo=0,Co=null}function Po(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return _o===null?F.memoizedState=_o=e:_o=_o.next=e,_o}function Fo(){if(go===null){var e=F.alternate;e=e===null?null:e.memoizedState}else e=go.next;var t=_o===null?F.memoizedState:_o.next;if(t!==null)_o=t,go=e;else{if(e===null)throw F.alternate===null?Error(i(467)):Error(i(310));go=e,e={memoizedState:go.memoizedState,baseState:go.baseState,baseQueue:go.baseQueue,queue:go.queue,next:null},_o===null?F.memoizedState=_o=e:_o=_o.next=e}return _o}function Io(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Lo(e){var t=So;return So+=1,Co===null&&(Co=[]),e=ka(Co,e,t),t=F,(_o===null?t.memoizedState:_o.next)===null&&(t=t.alternate,k.H=t===null||t.memoizedState===null?Gs:Ks),e}function Ro(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Lo(e);if(e.$$typeof===b)return ra(e)}throw Error(i(438,String(e)))}function zo(e){var t=null,n=F.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=F.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=Io(),F.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=D;return t.index++,n}function Bo(e,t){return typeof t==`function`?t(e):t}function Vo(e){return Ho(Fo(),go,e)}function Ho(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(ho&f)===f:(z&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===ma&&(d=!0);else if((ho&p)===p){u=u.next,p===ma&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,F.lanes|=p,eu|=p;f=u.action,bo&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,F.lanes|=f,eu|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!wr(o,e.memoizedState)&&(lc=!0,d&&(n=ha,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Uo(e){var t=Fo(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);wr(o,t.memoizedState)||(lc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Wo(e,t,n){var r=F,a=Fo(),o=P;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!wr((go||a).memoizedState,n);if(s&&(a.memoizedState=n,lc=!0),a=a.queue,gs(qo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||_o!==null&&_o.memoizedState.tag&1){if(r.flags|=2048,ds(9,{destroy:void 0},Ko.bind(null,r,a,n,t),null),Kl===null)throw Error(i(349));o||ho&127||Go(r,t,n)}return n}function Go(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=F.updateQueue,t===null?(t=Io(),F.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Ko(e,t,n,r){t.value=n,t.getSnapshot=r,Jo(t)&&Yo(e)}function qo(e,t,n){return n(function(){Jo(t)&&Yo(e)})}function Jo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!wr(e,n)}catch{return!0}}function Yo(e){var t=ai(e,2);t!==null&&wu(t,e,2)}function Xo(e){var t=Po();if(typeof e==`function`){var n=e;if(e=n(),bo){Ve(!0);try{n()}finally{Ve(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bo,lastRenderedState:e},t}function Zo(e,t,n,r){return e.baseState=n,Ho(e,go,typeof r==`function`?r:Bo)}function Qo(e,t,n,r,a){if(Vs(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};k.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,$o(t,o)):(o.next=n.next,t.pending=n.next=o)}}function $o(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=k.T,o={};k.T=o;try{var s=n(i,r),c=k.S;c!==null&&c(o,s),es(e,t,s)}catch(n){ns(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),k.T=a}}else try{a=n(i,r),es(e,t,a)}catch(n){ns(e,t,n)}}function es(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){ts(e,t,n)},function(n){return ns(e,t,n)}):ts(e,t,n)}function ts(e,t,n){t.status=`fulfilled`,t.value=n,rs(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,$o(e,n)))}function ns(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,rs(t),t=t.next;while(t!==r)}e.action=null}function rs(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function is(e,t){return t}function as(e,t){if(P){var n=Kl.formState;if(n!==null){a:{var r=F;if(P){if(Ii){b:{for(var i=Ii,a=Ri;i.nodeType!==8;){if(!a){i=null;break b}if(i=yf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Ii=yf(i.nextSibling),r=i.data===`F!`;break a}}Bi(r)}r=!1}r&&(t=n[0])}}return n=Po(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:is,lastRenderedState:t},n.queue=r,n=Rs.bind(null,F,r),r.dispatch=n,r=Xo(!1),a=Bs.bind(null,F,!1,r.queue),r=Po(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=Qo.bind(null,F,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function ss(e){return cs(Fo(),go,e)}function cs(e,t,n){if(t=Ho(e,t,is)[0],e=Vo(Bo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Lo(t)}catch(e){throw e===wa?Ea:e}else r=t;t=Fo();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(F.flags|=2048,ds(9,{destroy:void 0},ls.bind(null,i,n),null)),[r,a,e]}function ls(e,t){e.action=t}function us(e){var t=Fo(),n=go;if(n!==null)return cs(t,n,e);Fo(),t=t.memoizedState,n=Fo();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function ds(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=F.updateQueue,t===null&&(t=Io(),F.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function fs(){return Fo().memoizedState}function ps(e,t,n,r){var i=Po();F.flags|=e,i.memoizedState=ds(1|t,{destroy:void 0},n,r===void 0?null:r)}function ms(e,t,n,r){var i=Fo();r=r===void 0?null:r;var a=i.memoizedState.inst;go!==null&&r!==null&&Eo(r,go.memoizedState.deps)?i.memoizedState=ds(t,a,n,r):(F.flags|=e,i.memoizedState=ds(1|t,a,n,r))}function hs(e,t){ps(8390656,8,e,t)}function gs(e,t){ms(2048,8,e,t)}function _s(e){F.flags|=4;var t=F.updateQueue;if(t===null)t=Io(),F.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function vs(e){var t=Fo().memoizedState;return _s({ref:t,nextImpl:e}),function(){if(L&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function ys(e,t){return ms(4,2,e,t)}function bs(e,t){return ms(4,4,e,t)}function xs(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function Ss(e,t,n){n=n==null?null:n.concat([e]),ms(4,4,xs.bind(null,t,e),n)}function Cs(){}function ws(e,t){var n=Fo();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&Eo(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ts(e,t){var n=Fo();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&Eo(t,r[1]))return r[0];if(r=e(),bo){Ve(!0);try{e()}finally{Ve(!1)}}return n.memoizedState=[r,t],r}function Es(e,t,n){return n===void 0||ho&1073741824&&!(z&261930)?e.memoizedState=t:(e.memoizedState=n,e=Cu(),F.lanes|=e,eu|=e,n)}function Ds(e,t,n,r){return wr(n,t)?n:eo.current===null?!(ho&42)||ho&1073741824&&!(z&261930)?(lc=!0,e.memoizedState=n):(e=Cu(),F.lanes|=e,eu|=e,t):(e=Es(e,n,r),wr(e,t)||(lc=!0),e)}function Os(e,t,n,r,i){var a=A.p;A.p=a!==0&&8>a?a:8;var o=k.T,s={};k.T=s,Bs(e,!1,t,n);try{var c=i(),l=k.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?zs(e,t,va(c,r),Su(e)):zs(e,t,r,Su(e))}catch(n){zs(e,t,{then:function(){},status:`rejected`,reason:n},Su())}finally{A.p=a,o!==null&&s.types!==null&&(o.types=s.types),k.T=o}}function ks(){}function As(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=js(e).queue;Os(e,a,t,ie,n===null?ks:function(){return Ms(e),n(r)})}function js(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ie,baseState:ie,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bo,lastRenderedState:ie},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Bo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ms(e){var t=js(e);t.next===null&&(t=e.alternate.memoizedState),zs(e,t.next.queue,{},Su())}function Ns(){return ra(lp)}function Ps(){return Fo().memoizedState}function Fs(){return Fo().memoizedState}function Is(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=Su();e=Ga(n);var r=Ka(t,e,n);r!==null&&(wu(r,t,n),qa(r,t,n)),t={cache:ua()},e.payload=t;return}t=t.return}}function Ls(e,t,n){var r=Su();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Vs(e)?Hs(t,n):(n=ii(e,t,n,r),n!==null&&(wu(n,e,r),Us(n,t,r)))}function Rs(e,t,n){zs(e,t,n,Su())}function zs(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Vs(e))Hs(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,wr(s,o))return ri(e,t,i,0),Kl===null&&ni(),!1}catch{}if(n=ii(e,t,i,r),n!==null)return wu(n,e,r),Us(n,t,r),!0}return!1}function Bs(e,t,n,r){if(r={lane:2,revertLane:xd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Vs(e)){if(t)throw Error(i(479))}else t=ii(e,n,r,2),t!==null&&wu(t,e,2)}function Vs(e){var t=e.alternate;return e===F||t!==null&&t===F}function Hs(e,t){yo=vo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Us(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,it(e,n)}}var Ws={readContext:ra,use:Ro,useCallback:To,useContext:To,useEffect:To,useImperativeHandle:To,useLayoutEffect:To,useInsertionEffect:To,useMemo:To,useReducer:To,useRef:To,useState:To,useDebugValue:To,useDeferredValue:To,useTransition:To,useSyncExternalStore:To,useId:To,useHostTransitionStatus:To,useFormState:To,useActionState:To,useOptimistic:To,useMemoCache:To,useCacheRefresh:To};Ws.useEffectEvent=To;var Gs={readContext:ra,use:Ro,useCallback:function(e,t){return Po().memoizedState=[e,t===void 0?null:t],e},useContext:ra,useEffect:hs,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),ps(4194308,4,xs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ps(4194308,4,e,t)},useInsertionEffect:function(e,t){ps(4,2,e,t)},useMemo:function(e,t){var n=Po();t=t===void 0?null:t;var r=e();if(bo){Ve(!0);try{e()}finally{Ve(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Po();if(n!==void 0){var i=n(t);if(bo){Ve(!0);try{n(t)}finally{Ve(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Ls.bind(null,F,e),[r.memoizedState,e]},useRef:function(e){var t=Po();return e={current:e},t.memoizedState=e},useState:function(e){e=Xo(e);var t=e.queue,n=Rs.bind(null,F,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:Cs,useDeferredValue:function(e,t){return Es(Po(),e,t)},useTransition:function(){var e=Xo(!1);return e=Os.bind(null,F,e.queue,!0,!1),Po().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=F,a=Po();if(P){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Kl===null)throw Error(i(349));z&127||Go(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,hs(qo.bind(null,r,o,e),[e]),r.flags|=2048,ds(9,{destroy:void 0},Ko.bind(null,r,o,n,t),null),n},useId:function(){var e=Po(),t=Kl.identifierPrefix;if(P){var n=ki,r=Oi;n=(r&~(1<<32-He(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=xo++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=wo++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:Ns,useFormState:as,useActionState:as,useOptimistic:function(e){var t=Po();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Bs.bind(null,F,!0,n),n.dispatch=t,[e,t]},useMemoCache:zo,useCacheRefresh:function(){return Po().memoizedState=Is.bind(null,F)},useEffectEvent:function(e){var t=Po(),n={impl:e};return t.memoizedState=n,function(){if(L&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},Ks={readContext:ra,use:Ro,useCallback:ws,useContext:ra,useEffect:gs,useImperativeHandle:Ss,useInsertionEffect:ys,useLayoutEffect:bs,useMemo:Ts,useReducer:Vo,useRef:fs,useState:function(){return Vo(Bo)},useDebugValue:Cs,useDeferredValue:function(e,t){return Ds(Fo(),go.memoizedState,e,t)},useTransition:function(){var e=Vo(Bo)[0],t=Fo().memoizedState;return[typeof e==`boolean`?e:Lo(e),t]},useSyncExternalStore:Wo,useId:Ps,useHostTransitionStatus:Ns,useFormState:ss,useActionState:ss,useOptimistic:function(e,t){return Zo(Fo(),go,e,t)},useMemoCache:zo,useCacheRefresh:Fs};Ks.useEffectEvent=vs;var qs={readContext:ra,use:Ro,useCallback:ws,useContext:ra,useEffect:gs,useImperativeHandle:Ss,useInsertionEffect:ys,useLayoutEffect:bs,useMemo:Ts,useReducer:Uo,useRef:fs,useState:function(){return Uo(Bo)},useDebugValue:Cs,useDeferredValue:function(e,t){var n=Fo();return go===null?Es(n,e,t):Ds(n,go.memoizedState,e,t)},useTransition:function(){var e=Uo(Bo)[0],t=Fo().memoizedState;return[typeof e==`boolean`?e:Lo(e),t]},useSyncExternalStore:Wo,useId:Ps,useHostTransitionStatus:Ns,useFormState:us,useActionState:us,useOptimistic:function(e,t){var n=Fo();return go===null?(n.baseState=e,[e,n.queue.dispatch]):Zo(n,go,e,t)},useMemoCache:zo,useCacheRefresh:Fs};qs.useEffectEvent=vs;function Js(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:f({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Ys={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Su(),i=Ga(r);i.payload=t,n!=null&&(i.callback=n),t=Ka(e,i,r),t!==null&&(wu(t,e,r),qa(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Su(),i=Ga(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ka(e,i,r),t!==null&&(wu(t,e,r),qa(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Su(),r=Ga(n);r.tag=2,t!=null&&(r.callback=t),t=Ka(e,r,n),t!==null&&(wu(t,e,n),qa(t,e,n))}};function Xs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!Tr(n,r)||!Tr(i,a):!0}function Zs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Ys.enqueueReplaceState(t,t.state,null)}function Qs(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=f({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function $s(e){Qr(e)}function ec(e){console.error(e)}function tc(e){Qr(e)}function nc(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function rc(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function ic(e,t,n){return n=Ga(n),n.tag=3,n.payload={element:null},n.callback=function(){nc(e,t)},n}function ac(e){return e=Ga(e),e.tag=3,e}function oc(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){rc(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){rc(t,n,r),typeof i!=`function`&&(fu===null?fu=new Set([this]):fu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function sc(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&ea(t,n,a,!0),n=ao.current,n!==null){switch(n.tag){case 31:case 13:return oo===null?Iu():n.alternate===null&&$l===0&&($l=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Da?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),td(e,r,a)),!1;case 22:return n.flags|=65536,r===Da?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),td(e,r,a)),!1}throw Error(i(435,n.tag))}return td(e,r,a),Iu(),!1}if(P)return t=ao.current,t===null?(r!==zi&&(t=Error(i(423),{cause:r}),Ki(bi(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=bi(r,n),a=ic(e.stateNode,r,a),Ja(e,a),$l!==4&&($l=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==zi&&(e=Error(i(422),{cause:r}),Ki(bi(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=bi(o,n),au===null?au=[o]:au.push(o),$l!==4&&($l=2),t===null)return!0;r=bi(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=ic(n.stateNode,r,e),Ja(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(fu===null||!fu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=ac(a),oc(a,e,n,r),Ja(n,a),!1}n=n.return}while(n!==null);return!1}var cc=Error(i(461)),lc=!1;function uc(e,t,n,r){t.child=e===null?Va(t,null,n,r):Ba(t,e.child,n,r)}function dc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return na(t),r=Do(e,t,n,o,a,i),s=jo(),e!==null&&!lc?(Mo(e,t,i),Fc(e,t,i)):(P&&s&&Mi(t),t.flags|=1,uc(e,t,r,i),t.child)}function fc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!di(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,pc(e,t,a,r,i)):(e=mi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Ic(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?Tr:n,n(o,r)&&e.ref===t.ref)return Fc(e,t,i)}return t.flags|=1,e=fi(a,r),e.ref=t.ref,e.return=t,t.child=e}function pc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Tr(a,r)&&e.ref===t.ref){if(lc=!1,t.pendingProps=r=a,Ic(e,i))e.flags&131072&&(lc=!0);else return t.lanes=e.lanes,Fc(e,t,i)}}return xc(e,t,n,r,i)}function mc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return gc(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Sa(t,a===null?null:a.cachePool),a===null?ro():no(t,a),lo(t);else return r=t.lanes=536870912,gc(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Sa(t,null),ro(),uo(t)):(Sa(t,a.cachePool),no(t,a),uo(t),t.memoizedState=null);return uc(e,t,i,n),t.child}function hc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function gc(e,t,n,r,i){var a=xa();return a=a===null?null:{parent:la._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Sa(t,null),ro(),lo(t),e!==null&&ea(e,t,r,!0),t.childLanes=i,null}function _c(e,t){return t=Ac({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function vc(e,t,n){return Ba(t,e.child,null,n),e=_c(t,t.pendingProps),e.flags|=2,fo(t),t.memoizedState=null,e}function yc(e,t,n){var r=t.pendingProps,a=!!(t.flags&128);if(t.flags&=-129,e===null){if(P){if(r.mode===`hidden`)return e=_c(t,r),t.lanes=536870912,hc(null,e);if(co(t),(e=Ii)?(e=hf(e,Ri),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Di===null?null:{id:Oi,overflow:ki},retryLane:536870912,hydrationErrors:null},n=_i(e),n.return=t,t.child=n,Fi=t,Ii=null)):e=null,e===null)throw Bi(t);return t.lanes=536870912,null}return _c(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(co(t),a){if(t.flags&256)t.flags&=-257,t=vc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558))}else if(lc||ea(e,t,n,!1),a=(n&e.childLanes)!==0,lc||a){if(r=Kl,r!==null&&(s=at(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,ai(e,s),wu(r,e,s),cc;Iu(),t=vc(e,t,n)}else e=o.treeContext,Ii=yf(s.nextSibling),Fi=t,P=!0,Li=null,Ri=!1,e!==null&&Pi(t,e),t=_c(t,r),t.flags|=4096;return t}return e=fi(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function bc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function xc(e,t,n,r,i){return na(t),n=Do(e,t,n,r,void 0,i),r=jo(),e!==null&&!lc?(Mo(e,t,i),Fc(e,t,i)):(P&&r&&Mi(t),t.flags|=1,uc(e,t,n,i),t.child)}function Sc(e,t,n,r,i,a){return na(t),t.updateQueue=null,n=ko(t,r,n,i),Oo(e),r=jo(),e!==null&&!lc?(Mo(e,t,a),Fc(e,t,a)):(P&&r&&Mi(t),t.flags|=1,uc(e,t,n,a),t.child)}function Cc(e,t,n,r,i){if(na(t),t.stateNode===null){var a=ci,o=n.contextType;typeof o==`object`&&o&&(a=ra(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Ys,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Ua(t),o=n.contextType,a.context=typeof o==`object`&&o?ra(o):ci,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Js(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Ys.enqueueReplaceState(a,a.state,null),Za(t,r,a,i),Xa(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=Qs(n,s);a.props=c;var l=a.context,u=n.contextType;o=ci,typeof u==`object`&&u&&(o=ra(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Zs(t,a,r,o),Ha=!1;var f=t.memoizedState;a.state=f,Za(t,r,a,i),Xa(),l=t.memoizedState,s||f!==l||Ha?(typeof d==`function`&&(Js(t,n,d,r),l=t.memoizedState),(c=Ha||Xs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,Wa(e,t),o=t.memoizedProps,u=Qs(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ci,typeof l==`object`&&l&&(c=ra(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Zs(t,a,r,c),Ha=!1,f=t.memoizedState,a.state=f,Za(t,r,a,i),Xa();var p=t.memoizedState;o!==d||f!==p||Ha||e!==null&&e.dependencies!==null&&ta(e.dependencies)?(typeof s==`function`&&(Js(t,n,s,r),p=t.memoizedState),(u=Ha||Xs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&ta(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,bc(e,t),r=!!(t.flags&128),a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Ba(t,e.child,null,i),t.child=Ba(t,null,n,i)):uc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Fc(e,t,i),e}function wc(e,t,n,r){return Wi(),t.flags|=256,uc(e,t,n,r),t.child}var Tc={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Ec(e){return{baseLanes:e,cachePool:Ca()}}function Dc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=ru),e}function Oc(e,t,n){var r=t.pendingProps,a=!1,o=!!(t.flags&128),s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:!!(po.current&2)),s&&(a=!0,t.flags&=-129),s=!!(t.flags&32),t.flags&=-33,e===null){if(P){if(a?so(t):uo(t),(e=Ii)?(e=hf(e,Ri),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Di===null?null:{id:Oi,overflow:ki},retryLane:536870912,hydrationErrors:null},n=_i(e),n.return=t,t.child=n,Fi=t,Ii=null)):e=null,e===null)throw Bi(t);return _f(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(uo(t),a=t.mode,c=Ac({mode:`hidden`,children:c},a),r=hi(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=Ec(n),r.childLanes=Dc(e,s,n),t.memoizedState=Tc,hc(null,r)):(so(t),kc(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(so(t),t.flags&=-257,t=jc(e,t,n)):t.memoizedState===null?(uo(t),c=r.fallback,a=t.mode,r=Ac({mode:`visible`,children:r.children},a),c=hi(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Ba(t,e.child,null,n),r=t.child,r.memoizedState=Ec(n),r.childLanes=Dc(e,s,n),t.memoizedState=Tc,t=hc(null,r)):(uo(t),t.child=e.child,t.flags|=128,t=null);else if(so(t),_f(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Ki({value:r,source:null,stack:null}),t=jc(e,t,n)}else if(lc||ea(e,t,n,!1),s=(n&e.childLanes)!==0,lc||s){if(s=Kl,s!==null&&(r=at(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,ai(e,r),wu(s,e,r),cc;gf(c)||Iu(),t=jc(e,t,n)}else gf(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Ii=yf(c.nextSibling),Fi=t,P=!0,Li=null,Ri=!1,e!==null&&Pi(t,e),t=kc(t,r.children),t.flags|=4096);return t}return a?(uo(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=fi(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=hi(c,a,n,null),c.flags|=2):c=fi(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,hc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=Ec(n):(a=c.cachePool,a===null?a=Ca():(l=la._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=Dc(e,s,n),t.memoizedState=Tc,hc(e.child,r)):(so(t),n=e.child,e=n.sibling,n=fi(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function kc(e,t){return t=Ac({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function Ac(e,t){return e=ui(22,e,null,t),e.lanes=0,e}function jc(e,t,n){return Ba(t,e.child,null,n),e=kc(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Mc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Qi(e.return,t,n)}function Nc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Pc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=po.current,s=!!(o&2);if(s?(o=o&1|2,t.flags|=128):o&=1,le(po,o),uc(e,t,r,n),r=P?wi:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Mc(e,n,t);else if(e.tag===19)Mc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&mo(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Nc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&mo(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Nc(t,!0,n,null,a,r);break;case`together`:Nc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Fc(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),eu|=t.lanes,(n&t.childLanes)===0){if(e!==null){if(ea(e,t,n,!1),(n&t.childLanes)===0)return null}else return null}if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=fi(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=fi(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Ic(e,t){return(e.lanes&t)!==0||(e=e.dependencies,!!(e!==null&&ta(e)))}function Lc(e,t,n){switch(t.tag){case 3:me(t,t.stateNode.containerInfo),Xi(t,la,e.memoizedState.cache),Wi();break;case 27:case 5:ge(t);break;case 4:me(t,t.stateNode.containerInfo);break;case 10:Xi(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,co(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(so(t),e=Fc(e,t,n),e===null?null:e.sibling):Oc(e,t,n):(so(t),t.flags|=128,null);so(t);break;case 19:var i=!!(e.flags&128);if(r=(n&t.childLanes)!==0,r||=(ea(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Pc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),le(po,po.current),r)break;return null;case 22:return t.lanes=0,mc(e,t,n,t.pendingProps);case 24:Xi(t,la,e.memoizedState.cache)}return Fc(e,t,n)}function Rc(e,t,n){if(e!==null){if(e.memoizedProps!==t.pendingProps)lc=!0;else{if(!Ic(e,n)&&!(t.flags&128))return lc=!1,Lc(e,t,n);lc=!!(e.flags&131072)}}else lc=!1,P&&t.flags&1048576&&ji(t,wi,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=Aa(t.elementType),t.type=e,typeof e==`function`)di(e)?(r=Qs(e,r),t.tag=1,t=Cc(null,t,e,r,n)):(t.tag=0,t=xc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===x){t.tag=11,t=dc(null,t,e,r,n);break a}if(a===w){t.tag=14,t=fc(null,t,e,r,n);break a}}throw t=ne(e)||e,Error(i(306,t,``))}}return t;case 0:return xc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=Qs(r,t.pendingProps),Cc(e,t,r,a,n);case 3:a:{if(me(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,Wa(e,t),Za(t,r,null,n);var s=t.memoizedState;if(r=s.cache,Xi(t,la,r),r!==o.cache&&$i(t,[la],n,!0),Xa(),r=s.element,o.isDehydrated){if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=wc(e,t,r,n);break a}if(r!==a){a=bi(Error(i(424)),t),Ki(a),t=wc(e,t,r,n);break a}switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Ii=yf(e.firstChild),Fi=t,P=!0,Li=null,Ri=!0,n=Va(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Wi(),r===a){t=Fc(e,t,n);break a}uc(e,t,r,n)}t=t.child}return t;case 26:return bc(e,t),e===null?(n=Bf(t.type,null,t.pendingProps,null))?t.memoizedState=n:P||(n=t.type,e=t.pendingProps,r=Zd(fe.current).createElement(n),r[dt]=t,r[ft]=e,Gd(r,n,e),wt(r),t.stateNode=r):t.memoizedState=Bf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ge(t),e===null&&P&&(r=t.stateNode=Cf(t.type,t.pendingProps,fe.current),Fi=t,Ri=!0,a=Ii,lf(t.type)?(bf=a,Ii=yf(r.firstChild)):Ii=a),uc(e,t,t.pendingProps.children,n),bc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&P&&((a=r=Ii)&&(r=pf(r,t.type,t.pendingProps,Ri),r===null?a=!1:(t.stateNode=r,Fi=t,Ii=yf(r.firstChild),Ri=!1,a=!0)),a||Bi(t)),ge(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,ef(a,o)?r=null:s!==null&&ef(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Do(e,t,Ao,null,null,n),lp._currentValue=a),bc(e,t),uc(e,t,r,n),t.child;case 6:return e===null&&P&&((e=n=Ii)&&(n=mf(n,t.pendingProps,Ri),n===null?e=!1:(t.stateNode=n,Fi=t,Ii=null,e=!0)),e||Bi(t)),null;case 13:return Oc(e,t,n);case 4:return me(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ba(t,null,r,n):uc(e,t,r,n),t.child;case 11:return dc(e,t,t.type,t.pendingProps,n);case 7:return uc(e,t,t.pendingProps,n),t.child;case 8:return uc(e,t,t.pendingProps.children,n),t.child;case 12:return uc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Xi(t,t.type,r.value),uc(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,na(t),a=ra(a),r=r(a),t.flags|=1,uc(e,t,r,n),t.child;case 14:return fc(e,t,t.type,t.pendingProps,n);case 15:return pc(e,t,t.type,t.pendingProps,n);case 19:return Pc(e,t,n);case 31:return yc(e,t,n);case 22:return mc(e,t,n,t.pendingProps);case 24:return na(t),r=ra(la),e===null?(a=xa(),a===null&&(a=Kl,o=ua(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},Ua(t),Xi(t,la,a)):((e.lanes&n)!==0&&(Wa(e,t),Za(t,null,null,n),Xa()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,Xi(t,la,r),r!==a.cache&&$i(t,[la],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),Xi(t,la,r))),uc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function zc(e){e.flags|=4}function Bc(e,t,n,r,i){if((t=!!(e.mode&32))&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i){if(e.stateNode.complete)e.flags|=8192;else if(Nu())e.flags|=8192;else throw ja=Da,Ta}}else e.flags&=-16777217}function Vc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!tp(t)){if(Nu())e.flags|=8192;else throw ja=Da,Ta}}function Hc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:$e(),e.lanes|=t,iu|=t)}function Uc(e,t){if(!P)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Wc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Gc(e,t,n){var r=t.pendingProps;switch(Ni(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Wc(t),null;case 1:return Wc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),Zi(la),he(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ui(t)?zc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Gi())),Wc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(zc(t),o===null?(Wc(t),Bc(t,a,null,r,n)):(Wc(t),Vc(t,o))):o?o===e.memoizedState?(Wc(t),t.flags&=-16777217):(zc(t),Wc(t),Vc(t,o)):(e=e.memoizedProps,e!==r&&zc(t),Wc(t),Bc(t,a,e,r,n)),null;case 27:if(_e(t),n=fe.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&zc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Wc(t),null}e=ue.current,Ui(t)?Vi(t,e):(e=Cf(a,r,n),t.stateNode=e,zc(t))}return Wc(t),null;case 5:if(_e(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&zc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Wc(t),null}if(o=ue.current,Ui(t))Vi(t,o);else{var s=Zd(fe.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[dt]=t,o[ft]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Gd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&zc(t)}}return Wc(t),Bc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&zc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=fe.current,Ui(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Fi,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[dt]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Hd(e.nodeValue,n)),e||Bi(t,!0)}else e=Zd(e).createTextNode(r),e[dt]=t,t.stateNode=e}return Wc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Ui(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[dt]=t}else Wi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Wc(t),e=!1}else n=Gi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(fo(t),t):(fo(t),null);if(t.flags&128)throw Error(i(558))}return Wc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Ui(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[dt]=t}else Wi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Wc(t),a=!1}else a=Gi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(fo(t),t):(fo(t),null)}return fo(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Hc(t,t.updateQueue),Wc(t),null);case 4:return he(),e===null&&Md(t.stateNode.containerInfo),Wc(t),null;case 10:return Zi(t.type),Wc(t),null;case 19:if(ce(po),r=t.memoizedState,r===null)return Wc(t),null;if(a=!!(t.flags&128),o=r.rendering,o===null){if(a)Uc(r,!1);else{if($l!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=mo(e),o!==null){for(t.flags|=128,Uc(r,!1),e=o.updateQueue,t.updateQueue=e,Hc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)pi(n,e),n=n.sibling;return le(po,po.current&1|2),P&&Ai(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Ae()>uu&&(t.flags|=128,a=!0,Uc(r,!1),t.lanes=4194304)}}else{if(!a){if(e=mo(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Hc(t,e),Uc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!P)return Wc(t),null}else 2*Ae()-r.renderingStartTime>uu&&n!==536870912&&(t.flags|=128,a=!0,Uc(r,!1),t.lanes=4194304)}r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Wc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Ae(),e.sibling=null,n=po.current,le(po,a?n&1|2:n&1),P&&Ai(t,r.treeForkCount),e);case 22:case 23:return fo(t),io(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Wc(t),t.subtreeFlags&6&&(t.flags|=8192)):Wc(t),n=t.updateQueue,n!==null&&Hc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&ce(ba),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Zi(la),Wc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function Kc(e,t){switch(Ni(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Zi(la),he(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return _e(t),null;case 31:if(t.memoizedState!==null){if(fo(t),t.alternate===null)throw Error(i(340));Wi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(fo(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));Wi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ce(po),null;case 4:return he(),null;case 10:return Zi(t.type),null;case 22:case 23:return fo(t),io(),e!==null&&ce(ba),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Zi(la),null;case 25:return null;default:return null}}function qc(e,t){switch(Ni(t),t.tag){case 3:Zi(la),he();break;case 26:case 27:case 5:_e(t);break;case 4:he();break;case 31:t.memoizedState!==null&&fo(t);break;case 13:fo(t);break;case 19:ce(po);break;case 10:Zi(t.type);break;case 22:case 23:fo(t),io(),e!==null&&ce(ba);break;case 24:Zi(la)}}function Jc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){ed(t,t.return,e)}}function Yc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){ed(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){ed(t,t.return,e)}}function Xc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{$a(t,n)}catch(t){ed(e,e.return,t)}}}function Zc(e,t,n){n.props=Qs(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){ed(e,t,n)}}function Qc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){ed(e,t,n)}}function $c(e,t){var n=e.ref,r=e.refCleanup;if(n!==null){if(typeof r==`function`)try{r()}catch(n){ed(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){ed(e,t,n)}else n.current=null}}function el(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){ed(e,e.return,t)}}function tl(e,t,n){try{var r=e.stateNode;Kd(r,e.type,n,t),r[ft]=t}catch(t){ed(e,e.return,t)}}function nl(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&lf(e.type)||e.tag===4}function rl(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||nl(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&lf(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function il(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=an));else if(r!==4&&(r===27&&lf(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(il(e,t,n),e=e.sibling;e!==null;)il(e,t,n),e=e.sibling}function al(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&lf(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(al(e,t,n),e=e.sibling;e!==null;)al(e,t,n),e=e.sibling}function ol(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Gd(t,r,n),t[dt]=e,t[ft]=n}catch(t){ed(e,e.return,t)}}var sl=!1,cl=!1,ll=!1,ul=typeof WeakSet==`function`?WeakSet:Set,dl=null;function fl(e,t){if(e=e.containerInfo,Yd=vp,e=kr(e),Ar(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(Xd={focusedElem:e,selectionRange:n},vp=!1,dl=t;dl!==null;)if(t=dl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,dl=e;else for(;dl!==null;){switch(t=dl,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=Qs(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){ed(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)ff(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:ff(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,dl=e;break}dl=t.return}}function pl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:Ol(e,n),r&4&&Jc(5,n);break;case 1:if(Ol(e,n),r&4){if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){ed(n,n.return,e)}else{var i=Qs(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){ed(n,n.return,e)}}}r&64&&Xc(n),r&512&&Qc(n,n.return);break;case 3:if(Ol(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{$a(e,t)}catch(e){ed(n,n.return,e)}}break;case 27:t===null&&r&4&&ol(n);case 26:case 5:Ol(e,n),t===null&&r&4&&el(n),r&512&&Qc(n,n.return);break;case 12:Ol(e,n);break;case 31:Ol(e,n),r&4&&yl(e,n);break;case 13:Ol(e,n),r&4&&bl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=id.bind(null,n),vf(e,n))));break;case 22:if(r=n.memoizedState!==null||sl,!r){t=t!==null&&t.memoizedState!==null||cl,i=sl;var a=cl;sl=r,(cl=t)&&!a?Al(e,n,!!(n.subtreeFlags&8772)):Ol(e,n),sl=i,cl=a}break;case 30:break;default:Ol(e,n)}}function ml(e){var t=e.alternate;t!==null&&(e.alternate=null,ml(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&yt(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var hl=null,gl=!1;function _l(e,t,n){for(n=n.child;n!==null;)vl(e,t,n),n=n.sibling}function vl(e,t,n){if(Be&&typeof Be.onCommitFiberUnmount==`function`)try{Be.onCommitFiberUnmount(ze,n)}catch{}switch(n.tag){case 26:cl||$c(n,t),_l(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:cl||$c(n,t);var r=hl,i=gl;lf(n.type)&&(hl=n.stateNode,gl=!1),_l(e,t,n),wf(n.stateNode),hl=r,gl=i;break;case 5:cl||$c(n,t);case 6:if(r=hl,i=gl,hl=null,_l(e,t,n),hl=r,gl=i,hl!==null){if(gl)try{(hl.nodeType===9?hl.body:hl.nodeName===`HTML`?hl.ownerDocument.body:hl).removeChild(n.stateNode)}catch(e){ed(n,t,e)}else try{hl.removeChild(n.stateNode)}catch(e){ed(n,t,e)}}break;case 18:hl!==null&&(gl?(e=hl,uf(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Hp(e)):uf(hl,n.stateNode));break;case 4:r=hl,i=gl,hl=n.stateNode.containerInfo,gl=!0,_l(e,t,n),hl=r,gl=i;break;case 0:case 11:case 14:case 15:Yc(2,n,t),cl||Yc(4,n,t),_l(e,t,n);break;case 1:cl||($c(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Zc(n,t,r)),_l(e,t,n);break;case 21:_l(e,t,n);break;case 22:cl=(r=cl)||n.memoizedState!==null,_l(e,t,n),cl=r;break;default:_l(e,t,n)}}function yl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Hp(e)}catch(e){ed(t,t.return,e)}}}function bl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Hp(e)}catch(e){ed(t,t.return,e)}}function xl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new ul),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new ul),t;default:throw Error(i(435,e.tag))}}function Sl(e,t){var n=xl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=ad.bind(null,e,t);t.then(r,r)}})}function Cl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(lf(c.type)){hl=c.stateNode,gl=!1;break a}break;case 5:hl=c.stateNode,gl=!1;break a;case 3:case 4:hl=c.stateNode.containerInfo,gl=!0;break a}c=c.return}if(hl===null)throw Error(i(160));vl(o,s,a),hl=null,gl=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Tl(t,e),t=t.sibling}var wl=null;function Tl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Cl(t,e),El(e),r&4&&(Yc(3,e,e.return),Jc(3,e),Yc(5,e,e.return));break;case 1:Cl(t,e),El(e),r&512&&(cl||n===null||$c(n,n.return)),r&64&&sl&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=wl;if(Cl(t,e),El(e),r&512&&(cl||n===null||$c(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null){if(r===null){if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[vt]||o[dt]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Gd(o,r,n),o[dt]=e,wt(o),r=o;break a;case`link`:var s=Qf(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Gd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=Qf(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Gd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[dt]=e,wt(o),r=o}e.stateNode=r}else $f(a,e.type,e.stateNode)}else e.stateNode=qf(a,r,e.memoizedProps)}else o===r?r===null&&e.stateNode!==null&&tl(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?$f(a,e.type,e.stateNode):qf(a,r,e.memoizedProps))}break;case 27:Cl(t,e),El(e),r&512&&(cl||n===null||$c(n,n.return)),n!==null&&r&4&&tl(e,e.memoizedProps,n.memoizedProps);break;case 5:if(Cl(t,e),El(e),r&512&&(cl||n===null||$c(n,n.return)),e.flags&32){a=e.stateNode;try{Xt(a,``)}catch(t){ed(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,tl(e,a,n===null?a:n.memoizedProps)),r&1024&&(ll=!0);break;case 6:if(Cl(t,e),El(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){ed(e,e.return,t)}}break;case 3:if(Zf=null,a=wl,wl=Df(t.containerInfo),Cl(t,e),wl=a,El(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Hp(t.containerInfo)}catch(t){ed(e,e.return,t)}ll&&(ll=!1,Dl(e));break;case 4:r=wl,wl=Df(e.stateNode.containerInfo),Cl(t,e),El(e),wl=r;break;case 12:Cl(t,e),El(e);break;case 31:Cl(t,e),El(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Sl(e,r)));break;case 13:Cl(t,e),El(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(cu=Ae()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Sl(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=sl,d=cl;if(sl=u||a,cl=d||l,Cl(t,e),cl=d,sl=u,El(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||sl||cl||kl(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){ed(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){ed(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?df(m,!0):df(l.stateNode,!1)}catch(e){ed(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,Sl(e,n))));break;case 19:Cl(t,e),El(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,Sl(e,r)));break;case 30:break;case 21:break;default:Cl(t,e),El(e)}}function El(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(nl(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;al(e,rl(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Xt(o,``),n.flags&=-33),al(e,rl(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;il(e,rl(e),s);break;default:throw Error(i(161))}}catch(t){ed(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Dl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Dl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Ol(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)pl(e,t.alternate,t),t=t.sibling}function kl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Yc(4,t,t.return),kl(t);break;case 1:$c(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Zc(t,t.return,n),kl(t);break;case 27:wf(t.stateNode);case 26:case 5:$c(t,t.return),kl(t);break;case 22:t.memoizedState===null&&kl(t);break;case 30:kl(t);break;default:kl(t)}e=e.sibling}}function Al(e,t,n){for(n&&=!!(t.subtreeFlags&8772),t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:Al(i,a,n),Jc(4,a);break;case 1:if(Al(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){ed(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)Qa(c[i],s)}catch(e){ed(r,r.return,e)}}n&&o&64&&Xc(a),Qc(a,a.return);break;case 27:ol(a);case 26:case 5:Al(i,a,n),n&&r===null&&o&4&&el(a),Qc(a,a.return);break;case 12:Al(i,a,n);break;case 31:Al(i,a,n),n&&o&4&&yl(i,a);break;case 13:Al(i,a,n),n&&o&4&&bl(i,a);break;case 22:a.memoizedState===null&&Al(i,a,n),Qc(a,a.return);break;case 30:break;default:Al(i,a,n)}t=t.sibling}}function jl(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&da(n))}function Ml(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&da(e))}function Nl(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Pl(e,t,n,r),t=t.sibling}function Pl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:Nl(e,t,n,r),i&2048&&Jc(9,t);break;case 1:Nl(e,t,n,r);break;case 3:Nl(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&da(e)));break;case 12:if(i&2048){Nl(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){ed(t,t.return,e)}}else Nl(e,t,n,r);break;case 31:Nl(e,t,n,r);break;case 13:Nl(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?Nl(e,t,n,r):(a._visibility|=2,Fl(e,t,n,r,!!(t.subtreeFlags&10256)||!1)):a._visibility&2?Nl(e,t,n,r):Il(e,t),i&2048&&jl(o,t);break;case 24:Nl(e,t,n,r),i&2048&&Ml(t.alternate,t);break;default:Nl(e,t,n,r)}}function Fl(e,t,n,r,i){for(i&&=!!(t.subtreeFlags&10256)||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Fl(a,o,s,c,i),Jc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Fl(a,o,s,c,i)):u._visibility&2?Fl(a,o,s,c,i):Il(a,o),i&&l&2048&&jl(o.alternate,o);break;case 24:Fl(a,o,s,c,i),i&&l&2048&&Ml(o.alternate,o);break;default:Fl(a,o,s,c,i)}t=t.sibling}}function Il(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Il(n,r),i&2048&&jl(r.alternate,r);break;case 24:Il(n,r),i&2048&&Ml(r.alternate,r);break;default:Il(n,r)}t=t.sibling}}var Ll=8192;function Rl(e,t,n){if(e.subtreeFlags&Ll)for(e=e.child;e!==null;)zl(e,t,n),e=e.sibling}function zl(e,t,n){switch(e.tag){case 26:Rl(e,t,n),e.flags&Ll&&e.memoizedState!==null&&np(n,wl,e.memoizedState,e.memoizedProps);break;case 5:Rl(e,t,n);break;case 3:case 4:var r=wl;wl=Df(e.stateNode.containerInfo),Rl(e,t,n),wl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Ll,Ll=16777216,Rl(e,t,n),Ll=r):Rl(e,t,n));break;default:Rl(e,t,n)}}function Bl(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Vl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];dl=r,Wl(r,e)}Bl(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Hl(e),e=e.sibling}function Hl(e){switch(e.tag){case 0:case 11:case 15:Vl(e),e.flags&2048&&Yc(9,e,e.return);break;case 3:Vl(e);break;case 12:Vl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Ul(e)):Vl(e);break;default:Vl(e)}}function Ul(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];dl=r,Wl(r,e)}Bl(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Yc(8,t,t.return),Ul(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Ul(t));break;default:Ul(t)}e=e.sibling}}function Wl(e,t){for(;dl!==null;){var n=dl;switch(n.tag){case 0:case 11:case 15:Yc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:da(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,dl=r;else a:for(n=e;dl!==null;){r=dl;var i=r.sibling,a=r.return;if(ml(r),r===n){dl=null;break a}if(i!==null){i.return=a,dl=i;break a}dl=a}}}var Gl={getCacheForType:function(e){var t=ra(la),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return ra(la).controller.signal}},I=typeof WeakMap==`function`?WeakMap:Map,L=0,Kl=null,R=null,z=0,ql=0,Jl=null,Yl=!1,Xl=!1,Zl=!1,Ql=0,$l=0,eu=0,tu=0,nu=0,ru=0,iu=0,au=null,ou=null,su=!1,cu=0,lu=0,uu=1/0,du=null,fu=null,pu=0,mu=null,hu=null,gu=0,_u=0,vu=null,yu=null,bu=0,xu=null;function Su(){return L&2&&z!==0?z&-z:k.T===null?ct():xd()}function Cu(){if(ru===0){if(!(z&536870912)||P){var e=qe;qe<<=1,!(qe&3932160)&&(qe=262144),ru=e}else ru=536870912}return e=ao.current,e!==null&&(e.flags|=32),ru}function wu(e,t,n){(e===Kl&&(ql===2||ql===9)||e.cancelPendingCommit!==null)&&(ju(e,0),Ou(e,z,ru,!1)),tt(e,n),(!(L&2)||e!==Kl)&&(e===Kl&&(!(L&2)&&(tu|=n),$l===4&&Ou(e,z,ru,!1)),pd(e))}function Tu(e,t,n){if(L&6)throw Error(i(327));var r=!n&&!(t&127)&&(t&e.expiredLanes)===0||Ze(e,t),a=r?zu(e,t):Lu(e,t,!0),o=r;do{if(a===0){Xl&&!r&&Ou(e,t,0,!1);break}if(n=e.current.alternate,o&&!Du(n)){a=Lu(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=au;var l=c.current.memoizedState.isDehydrated;if(l&&(ju(c,s).flags|=256),s=Lu(c,s,!1),s!==2){if(Zl&&!l){c.errorRecoveryDisabledLanes|=o,tu|=o,a=4;break a}o=ou,ou=a,o!==null&&(ou===null?ou=o:ou.push.apply(ou,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){ju(e,0),Ou(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:Ou(r,t,ru,!Yl);break a;case 2:ou=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=cu+300-Ae(),10<a)){if(Ou(r,t,ru,!Yl),Xe(r,0,!0)!==0)break a;gu=t,r.timeoutHandle=rf(Eu.bind(null,r,n,ou,du,su,t,ru,tu,iu,Yl,o,`Throttled`,-0,0),a);break a}Eu(r,n,ou,du,su,t,ru,tu,iu,Yl,o,null,-0,0)}break}while(1);pd(e)}function Eu(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:an},zl(t,a,d);var m=(a&62914560)===a?cu-Ae():(a&4194048)===a?lu-Ae():0;if(m=ip(d,m),m!==null){gu=a,e.cancelPendingCommit=m(Ku.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),Ou(e,a,o,!l);return}}Ku(e,t,a,n,r,i,o,s,c)}function Du(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!wr(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ou(e,t,n,r){t&=~nu,t&=~tu,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-He(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&rt(e,n,t)}function ku(){return L&6?!0:(md(0,!1),!1)}function Au(){if(R!==null){if(ql===0)var e=R.return;else e=R,Yi=Ji=null,No(e),Pa=null,Fa=0,e=R;for(;e!==null;)qc(e.alternate,e),e=e.return;R=null}}function ju(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,af(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),gu=0,Au(),Kl=e,R=n=fi(e.current,null),z=t,ql=0,Jl=null,Yl=!1,Xl=Ze(e,t),Zl=!1,iu=ru=nu=tu=eu=$l=0,ou=au=null,su=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-He(r),a=1<<i;t|=e[i],r&=~a}return Ql=t,ni(),n}function Mu(e,t){F=null,k.H=Ws,t===wa||t===Ea?(t=Ma(),ql=3):t===Ta?(t=Ma(),ql=4):ql=t===cc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Jl=t,R===null&&($l=1,nc(e,bi(t,e.current)))}function Nu(){var e=ao.current;return e===null?!0:(z&4194048)===z?oo===null:(z&62914560)===z||z&536870912?e===oo:!1}function Pu(){var e=k.H;return k.H=Ws,e===null?Ws:e}function Fu(){var e=k.A;return k.A=Gl,e}function Iu(){$l=4,Yl||(z&4194048)!==z&&ao.current!==null||(Xl=!0),!(eu&134217727)&&!(tu&134217727)||Kl===null||Ou(Kl,z,ru,!1)}function Lu(e,t,n){var r=L;L|=2;var i=Pu(),a=Fu();(Kl!==e||z!==t)&&(du=null,ju(e,t)),t=!1;var o=$l;a:do try{if(ql!==0&&R!==null){var s=R,c=Jl;switch(ql){case 8:Au(),o=6;break a;case 3:case 2:case 9:case 6:ao.current===null&&(t=!0);var l=ql;if(ql=0,Jl=null,Uu(e,s,c,l),n&&Xl){o=0;break a}break;default:l=ql,ql=0,Jl=null,Uu(e,s,c,l)}}Ru(),o=$l;break}catch(t){Mu(e,t)}while(1);return t&&e.shellSuspendCounter++,Yi=Ji=null,L=r,k.H=i,k.A=a,R===null&&(Kl=null,z=0,ni()),o}function Ru(){for(;R!==null;)Vu(R)}function zu(e,t){var n=L;L|=2;var r=Pu(),a=Fu();Kl!==e||z!==t?(du=null,uu=Ae()+500,ju(e,t)):Xl=Ze(e,t);a:do try{if(ql!==0&&R!==null){t=R;var o=Jl;b:switch(ql){case 1:ql=0,Jl=null,Uu(e,t,o,1);break;case 2:case 9:if(Oa(o)){ql=0,Jl=null,Hu(t);break}t=function(){ql!==2&&ql!==9||Kl!==e||(ql=7),pd(e)},o.then(t,t);break a;case 3:ql=7;break a;case 4:ql=5;break a;case 7:Oa(o)?(ql=0,Jl=null,Hu(t)):(ql=0,Jl=null,Uu(e,t,o,7));break;case 5:var s=null;switch(R.tag){case 26:s=R.memoizedState;case 5:case 27:var c=R;if(s?tp(s):c.stateNode.complete){ql=0,Jl=null;var l=c.sibling;if(l!==null)R=l;else{var u=c.return;u===null?R=null:(R=u,Wu(u))}break b}}ql=0,Jl=null,Uu(e,t,o,5);break;case 6:ql=0,Jl=null,Uu(e,t,o,6);break;case 8:Au(),$l=6;break a;default:throw Error(i(462))}}Bu();break}catch(t){Mu(e,t)}while(1);return Yi=Ji=null,k.H=r,k.A=a,L=n,R===null?(Kl=null,z=0,ni(),$l):0}function Bu(){for(;R!==null&&!Oe();)Vu(R)}function Vu(e){var t=Rc(e.alternate,e,Ql);e.memoizedProps=e.pendingProps,t===null?Wu(e):R=t}function Hu(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Sc(n,t,t.pendingProps,t.type,void 0,z);break;case 11:t=Sc(n,t,t.pendingProps,t.type.render,t.ref,z);break;case 5:No(t);default:qc(n,t),t=R=pi(t,Ql),t=Rc(n,t,Ql)}e.memoizedProps=e.pendingProps,t===null?Wu(e):R=t}function Uu(e,t,n,r){Yi=Ji=null,No(t),Pa=null,Fa=0;var i=t.return;try{if(sc(e,i,t,n,z)){$l=1,nc(e,bi(n,e.current)),R=null;return}}catch(t){if(i!==null)throw R=i,t;$l=1,nc(e,bi(n,e.current)),R=null;return}t.flags&32768?(P||r===1?e=!0:Xl||z&536870912?e=!1:(Yl=e=!0,(r===2||r===9||r===3||r===6)&&(r=ao.current,r!==null&&r.tag===13&&(r.flags|=16384))),Gu(t,e)):Wu(t)}function Wu(e){var t=e;do{if(t.flags&32768){Gu(t,Yl);return}e=t.return;var n=Gc(t.alternate,t,Ql);if(n!==null){R=n;return}if(t=t.sibling,t!==null){R=t;return}R=t=e}while(t!==null);$l===0&&($l=5)}function Gu(e,t){do{var n=Kc(e.alternate,e);if(n!==null){n.flags&=32767,R=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){R=e;return}R=e=n}while(e!==null);$l=6,R=null}function Ku(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do Zu();while(pu!==0);if(L&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=ti,nt(e,n,o,s,c,l),e===Kl&&(R=Kl=null,z=0),hu=t,mu=e,gu=n,_u=o,vu=a,yu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,od(Pe,function(){return Qu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=!!(t.flags&13878),t.subtreeFlags&13878||r){r=k.T,k.T=null,a=A.p,A.p=2,s=L,L|=4;try{fl(e,t,n)}finally{L=s,A.p=a,k.T=r}}pu=1,qu(),Ju(),Yu()}}function qu(){if(pu===1){pu=0;var e=mu,t=hu,n=!!(t.flags&13878);if(t.subtreeFlags&13878||n){n=k.T,k.T=null;var r=A.p;A.p=2;var i=L;L|=4;try{Tl(t,e);var a=Xd,o=kr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Or(s.ownerDocument.documentElement,s)){if(c!==null&&Ar(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=Dr(s,h),v=Dr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}vp=!!Yd,Xd=Yd=null}finally{L=i,A.p=r,k.T=n}}e.current=t,pu=2}}function Ju(){if(pu===2){pu=0;var e=mu,t=hu,n=!!(t.flags&8772);if(t.subtreeFlags&8772||n){n=k.T,k.T=null;var r=A.p;A.p=2;var i=L;L|=4;try{pl(e,t.alternate,t)}finally{L=i,A.p=r,k.T=n}}pu=3}}function Yu(){if(pu===4||pu===3){pu=0,ke();var e=mu,t=hu,n=gu,r=yu;t.subtreeFlags&10256||t.flags&10256?pu=5:(pu=0,hu=mu=null,Xu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(fu=null),st(n),t=t.stateNode,Be&&typeof Be.onCommitFiberRoot==`function`)try{Be.onCommitFiberRoot(ze,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=k.T,i=A.p,A.p=2,k.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{k.T=t,A.p=i}}gu&3&&Zu(),pd(e),i=e.pendingLanes,n&261930&&i&42?e===xu?bu++:(bu=0,xu=e):bu=0,md(0,!1)}}function Xu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,da(t)))}function Zu(){return qu(),Ju(),Yu(),Qu()}function Qu(){if(pu!==5)return!1;var e=mu,t=_u;_u=0;var n=st(gu),r=k.T,a=A.p;try{A.p=32>n?32:n,k.T=null,n=vu,vu=null;var o=mu,s=gu;if(pu=0,hu=mu=null,gu=0,L&6)throw Error(i(331));var c=L;if(L|=4,Hl(o.current),Pl(o,o.current,s,n),L=c,md(0,!1),Be&&typeof Be.onPostCommitFiberRoot==`function`)try{Be.onPostCommitFiberRoot(ze,o)}catch{}return!0}finally{A.p=a,k.T=r,Xu(e,t)}}function $u(e,t,n){t=bi(n,t),t=ic(e.stateNode,t,2),e=Ka(e,t,2),e!==null&&(tt(e,2),pd(e))}function ed(e,t,n){if(e.tag===3)$u(e,e,n);else for(;t!==null;){if(t.tag===3){$u(t,e,n);break}if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(fu===null||!fu.has(r))){e=bi(n,e),n=ac(2),r=Ka(t,n,2),r!==null&&(oc(n,r,t,e),tt(r,2),pd(r));break}}t=t.return}}function td(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new I;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Zl=!0,i.add(n),e=nd.bind(null,e,t,n),t.then(e,e))}function nd(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Kl===e&&(z&n)===n&&($l===4||$l===3&&(z&62914560)===z&&300>Ae()-cu?!(L&2)&&ju(e,0):nu|=n,iu===z&&(iu=0)),pd(e)}function rd(e,t){t===0&&(t=$e()),e=ai(e,t),e!==null&&(tt(e,t),pd(e))}function id(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),rd(e,n)}function ad(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),rd(e,n)}function od(e,t){return Ee(e,t)}var sd=null,cd=null,ld=!1,ud=!1,dd=!1,fd=0;function pd(e){e!==cd&&e.next===null&&(cd===null?sd=cd=e:cd=cd.next=e),ud=!0,ld||(ld=!0,bd())}function md(e,t){if(!dd&&ud){dd=!0;do for(var n=!1,r=sd;r!==null;){if(!t){if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-He(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,yd(r,a))}else a=z,a=Xe(r,r===Kl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Ze(r,a)||(n=!0,yd(r,a))}r=r.next}while(n);dd=!1}}function hd(){gd()}function gd(){ud=ld=!1;var e=0;fd!==0&&nf()&&(e=fd);for(var t=Ae(),n=null,r=sd;r!==null;){var i=r.next,a=_d(r,t);a===0?(r.next=null,n===null?sd=i:n.next=i,i===null&&(cd=n)):(n=r,(e!==0||a&3)&&(ud=!0)),r=i}pu!==0&&pu!==5||md(e,!1),fd!==0&&(fd=0)}function _d(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-He(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Qe(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Kl,n=z,n=Xe(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(ql===2||ql===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&De(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Ze(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&De(r),st(n)){case 2:case 8:n=Ne;break;case 32:n=Pe;break;case 268435456:n=Ie;break;default:n=Pe}return r=vd.bind(null,e),n=Ee(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&De(r),e.callbackPriority=2,e.callbackNode=null,2}function vd(e,t){if(pu!==0&&pu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Zu()&&e.callbackNode!==n)return null;var r=z;return r=Xe(e,e===Kl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(Tu(e,r,t),_d(e,Ae()),e.callbackNode!=null&&e.callbackNode===n?vd.bind(null,e):null)}function yd(e,t){if(Zu())return null;Tu(e,t,!0)}function bd(){sf(function(){L&6?Ee(Me,hd):gd()})}function xd(){if(fd===0){var e=ma;e===0&&(e=Ke,Ke<<=1,!(Ke&261888)&&(Ke=256)),fd=e}return fd}function Sd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:rn(``+e)}function Cd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function wd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=Sd((i[ft]||null).action),o=r.submitter;o&&(t=(t=o[ft]||null)?Sd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new j(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(fd!==0){var e=o?Cd(i,o):new FormData(i);As(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?Cd(i,o):new FormData(i),As(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var Td=0;Td<Xr.length;Td++){var Ed=Xr[Td];Zr(Ed.toLowerCase(),`on`+(Ed[0].toUpperCase()+Ed.slice(1)))}Zr(Hr,`onAnimationEnd`),Zr(Ur,`onAnimationIteration`),Zr(Wr,`onAnimationStart`),Zr(`dblclick`,`onDoubleClick`),Zr(`focusin`,`onFocus`),Zr(`focusout`,`onBlur`),Zr(Gr,`onTransitionRun`),Zr(Kr,`onTransitionStart`),Zr(qr,`onTransitionCancel`),Zr(Jr,`onTransitionEnd`),Ot(`onMouseEnter`,[`mouseout`,`mouseover`]),Ot(`onMouseLeave`,[`mouseout`,`mouseover`]),Ot(`onPointerEnter`,[`pointerout`,`pointerover`]),Ot(`onPointerLeave`,[`pointerout`,`pointerover`]),Dt(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),Dt(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),Dt(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),Dt(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),Dt(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),Dt(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Dd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),Od=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Dd));function kd(e,t){t=!!(t&4);for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Qr(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){Qr(e)}i.currentTarget=null,a=c}}}}function B(e,t){var n=t[mt];n===void 0&&(n=t[mt]=new Set);var r=e+`__bubble`;n.has(r)||(Nd(t,e,2,!1),n.add(r))}function Ad(e,t,n){var r=0;t&&(r|=4),Nd(n,e,r,t)}var jd=`_reactListening`+Math.random().toString(36).slice(2);function Md(e){if(!e[jd]){e[jd]=!0,Tt.forEach(function(t){t!==`selectionchange`&&(Od.has(t)||Ad(t,!1,e),Ad(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[jd]||(t[jd]=!0,Ad(`selectionchange`,!1,t))}}function Nd(e,t,n,r){switch(Cp(t)){case 2:var i=V;break;case 8:i=yp;break;default:i=bp}n=i.bind(null,t,n,e),i=void 0,!hn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Pd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var c=r.stateNode.containerInfo;if(c===i)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===i)return;s=s.return}for(;c!==null;){if(s=bt(c),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){r=a=s;continue a}c=c.parentNode}}r=r.return}fn(function(){var r=a,i=sn(n),s=[];a:{var c=Yr.get(e);if(c!==void 0){var l=j,u=e;switch(e){case`keypress`:if(xn(n)===0)break a;case`keydown`:case`keyup`:l=Vn;break;case`focusin`:u=`focus`,l=Mn;break;case`focusout`:u=`blur`,l=Mn;break;case`beforeblur`:case`afterblur`:l=Mn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=An;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=jn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Un;break;case Hr:case Ur:case Wr:l=Nn;break;case Jr:l=Wn;break;case`scroll`:case`scrollend`:l=Dn;break;case`wheel`:l=Gn;break;case`copy`:case`cut`:case`paste`:l=Pn;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Hn;break;case`toggle`:case`beforetoggle`:l=Kn}var d=!!(t&4),f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=pn(m,p),g!=null&&d.push(Fd(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),s.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==on&&(u=n.relatedTarget||n.fromElement)&&(bt(u)||u[pt]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?bt(u):null,u!==null&&(f=o(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=An,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Hn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:St(l),h=u==null?c:St(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,bt(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Ld,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&Rd(s,c,l,d,!1),u!==null&&f!==null&&Rd(s,f,u,d,!0)}}a:{if(c=r?St(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=fr;else if(or(c)){if(pr)v=Sr;else{v=br;var y=yr}}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&en(r.elementType)&&(v=fr):v=xr;if(v&&=v(e,r)){sr(s,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&Kt(c,`number`,c.value)}switch(y=r?St(r):window,e){case`focusin`:(or(y)||y.contentEditable===`true`)&&(Mr=y,Nr=r,Pr=null);break;case`focusout`:Pr=Nr=Mr=null;break;case`mousedown`:Fr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Fr=!1,Ir(s,n,i);break;case`selectionchange`:if(jr)break;case`keydown`:case`keyup`:Ir(s,n,i)}var b;if(Jn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else nr?er(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&(Zn&&n.locale!==`ko`&&(nr||x!==`onCompositionStart`?x===`onCompositionEnd`&&nr&&(b=bn()):(_n=i,vn=`value`in _n?_n.value:_n.textContent,nr=!0)),y=Id(r,x),0<y.length&&(x=new Fn(x,e,null,n,i),s.push({event:x,listeners:y}),b?x.data=b:(b=tr(n),b!==null&&(x.data=b)))),(b=Xn?rr(e,n):ir(e,n))&&(x=Id(r,`onBeforeInput`),0<x.length&&(y=new Fn(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:y,listeners:x}),y.data=b)),wd(s,e,r,n,i)}kd(s,t)})}function Fd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Id(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=pn(e,n),i!=null&&r.unshift(Fd(e,i,a)),i=pn(e,t),i!=null&&r.push(Fd(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Ld(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Rd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=pn(n,a),l!=null&&o.unshift(Fd(n,l,c))):i||(l=pn(n,a),l!=null&&o.push(Fd(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var zd=/\r\n?/g,Bd=/\u0000|\uFFFD/g;function Vd(e){return(typeof e==`string`?e:``+e).replace(zd,`
145
- `).replace(Bd,``)}function Hd(e,t){return t=Vd(t),Vd(e)===t}function Ud(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Xt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Xt(e,``+r);break;case`className`:Pt(e,`class`,r);break;case`tabIndex`:Pt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Pt(e,n,r);break;case`style`:$t(e,r,o);break;case`data`:if(t!==`object`){Pt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=rn(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&Ud(e,t,`name`,a.name,a,null),Ud(e,t,`formEncType`,a.formEncType,a,null),Ud(e,t,`formMethod`,a.formMethod,a,null),Ud(e,t,`formTarget`,a.formTarget,a,null)):(Ud(e,t,`encType`,a.encType,a,null),Ud(e,t,`method`,a.method,a,null),Ud(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=rn(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=an);break;case`onScroll`:r!=null&&B(`scroll`,e);break;case`onScrollEnd`:r!=null&&B(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=rn(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:B(`beforetoggle`,e),B(`toggle`,e),Nt(e,`popover`,r);break;case`xlinkActuate`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Ft(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Ft(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Ft(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Nt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=tn.get(n)||n,Nt(e,n,r))}}function Wd(e,t,n,r,a,o){switch(n){case`style`:$t(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Xt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Xt(e,``+r);break;case`onScroll`:r!=null&&B(`scroll`,e);break;case`onScrollEnd`:r!=null&&B(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=an);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!Et.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[ft]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Nt(e,n,r)}}}function Gd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:B(`error`,e),B(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Ud(e,t,o,s,n,null)}}a&&Ud(e,t,`srcSet`,n.srcSet,n,null),r&&Ud(e,t,`src`,n.src,n,null);return;case`input`:B(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Ud(e,t,r,d,n,null)}}Gt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in B(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Ud(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&qt(e,!!r,n,!0):qt(e,!!r,t,!1);return;case`textarea`:for(s in B(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Ud(e,t,s,c,n,null)}Yt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Ud(e,t,l,r,n,null)}return;case`dialog`:B(`beforetoggle`,e),B(`toggle`,e),B(`cancel`,e),B(`close`,e);break;case`iframe`:case`object`:B(`load`,e);break;case`video`:case`audio`:for(r=0;r<Dd.length;r++)B(Dd[r],e);break;case`image`:B(`error`,e),B(`load`,e);break;case`details`:B(`toggle`,e);break;case`embed`:case`source`:case`link`:B(`error`,e),B(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Ud(e,t,u,r,n,null)}return;default:if(en(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Wd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Ud(e,t,c,r,n,null))}function Kd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Ud(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Ud(e,t,p,m,r,f)}}Wt(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Ud(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Ud(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?qt(e,!!n,n?[]:``,!1):qt(e,!!n,t,!0)):qt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Ud(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Ud(e,t,s,a,r,o)}Jt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Ud(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Ud(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Ud(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Ud(e,t,u,p,r,m)}return;default:if(en(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Wd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Wd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Ud(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Ud(e,t,f,p,r,m)}function qd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Jd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&qd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&qd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Yd=null,Xd=null;function Zd(e){return e.nodeType===9?e:e.ownerDocument}function Qd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function $d(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function ef(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var tf=null;function nf(){var e=window.event;return e&&e.type===`popstate`?e!==tf&&(tf=e,!0):(tf=null,!1)}var rf=typeof setTimeout==`function`?setTimeout:void 0,af=typeof clearTimeout==`function`?clearTimeout:void 0,of=typeof Promise==`function`?Promise:void 0,sf=typeof queueMicrotask==`function`?queueMicrotask:of===void 0?rf:function(e){return of.resolve(null).then(e).catch(cf)};function cf(e){setTimeout(function(){throw e})}function lf(e){return e===`head`}function uf(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Hp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)wf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,wf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[vt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&wf(e.ownerDocument.body)}n=i}while(n);Hp(t)}function df(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function ff(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ff(n),yt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function pf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[vt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=yf(e.nextSibling),e===null)break}return null}function mf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=yf(e.nextSibling),e===null))return null;return e}function hf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=yf(e.nextSibling),e===null))return null;return e}function gf(e){return e.data===`$?`||e.data===`$~`}function _f(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function vf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function yf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var bf=null;function xf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return yf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function Sf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function Cf(e,t,n){switch(t=Zd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function wf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);yt(e)}var Tf=new Map,Ef=new Set;function Df(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Of=A.d;A.d={f:kf,r:Af,D:Nf,C:Pf,L:Ff,m:If,X:Rf,S:Lf,M:zf};function kf(){var e=Of.f(),t=ku();return e||t}function Af(e){var t=xt(e);t!==null&&t.tag===5&&t.type===`form`?Ms(t):Of.r(e)}var jf=typeof document>`u`?null:document;function Mf(e,t,n){var r=jf;if(r&&typeof t==`string`&&t){var i=Ut(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),Ef.has(i)||(Ef.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Gd(t,`link`,e),wt(t),r.head.appendChild(t)))}}function Nf(e){Of.D(e),Mf(`dns-prefetch`,e,null)}function Pf(e,t){Of.C(e,t),Mf(`preconnect`,e,t)}function Ff(e,t,n){Of.L(e,t,n);var r=jf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ut(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ut(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ut(n.imageSizes)+`"]`)):i+=`[href="`+Ut(e)+`"]`;var a=i;switch(t){case`style`:a=Vf(e);break;case`script`:a=Gf(e)}Tf.has(a)||(e=f({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),Tf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Hf(a))||t===`script`&&r.querySelector(Kf(a))||(t=r.createElement(`link`),Gd(t,`link`,e),wt(t),r.head.appendChild(t)))}}function If(e,t){Of.m(e,t);var n=jf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ut(r)+`"][href="`+Ut(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Gf(e)}if(!Tf.has(a)&&(e=f({rel:`modulepreload`,href:e},t),Tf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Kf(a)))return}r=n.createElement(`link`),Gd(r,`link`,e),wt(r),n.head.appendChild(r)}}}function Lf(e,t,n){Of.S(e,t,n);var r=jf;if(r&&e){var i=Ct(r).hoistableStyles,a=Vf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Hf(a)))s.loading=5;else{e=f({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=Tf.get(a))&&Yf(e,n);var c=o=r.createElement(`link`);wt(c),Gd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Jf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Rf(e,t){Of.X(e,t);var n=jf;if(n&&e){var r=Ct(n).hoistableScripts,i=Gf(e),a=r.get(i);a||(a=n.querySelector(Kf(i)),a||(e=f({src:e,async:!0},t),(t=Tf.get(i))&&Xf(e,t),a=n.createElement(`script`),wt(a),Gd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function zf(e,t){Of.M(e,t);var n=jf;if(n&&e){var r=Ct(n).hoistableScripts,i=Gf(e),a=r.get(i);a||(a=n.querySelector(Kf(i)),a||(e=f({src:e,async:!0,type:`module`},t),(t=Tf.get(i))&&Xf(e,t),a=n.createElement(`script`),wt(a),Gd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Bf(e,t,n,r){var a=(a=fe.current)?Df(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Vf(n.href),n=Ct(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Vf(n.href);var o=Ct(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Hf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),Tf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Tf.set(e,n),o||Wf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Gf(n),n=Ct(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Vf(e){return`href="`+Ut(e)+`"`}function Hf(e){return`link[rel="stylesheet"][`+e+`]`}function Uf(e){return f({},e,{"data-precedence":e.precedence,precedence:null})}function Wf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Gd(t,`link`,n),wt(t),e.head.appendChild(t))}function Gf(e){return`[src="`+Ut(e)+`"]`}function Kf(e){return`script[async]`+e}function qf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ut(n.href)+`"]`);if(r)return t.instance=r,wt(r),r;var a=f({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),wt(r),Gd(r,`style`,a),Jf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Vf(n.href);var o=e.querySelector(Hf(a));if(o)return t.state.loading|=4,t.instance=o,wt(o),o;r=Uf(n),(a=Tf.get(a))&&Yf(r,a),o=(e.ownerDocument||e).createElement(`link`),wt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Gd(o,`link`,r),t.state.loading|=4,Jf(o,n.precedence,e),t.instance=o;case`script`:return o=Gf(n.src),(a=e.querySelector(Kf(o)))?(t.instance=a,wt(a),a):(r=n,(a=Tf.get(o))&&(r=f({},n),Xf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),wt(a),Gd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Jf(r,n.precedence,e));return t.instance}function Jf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Yf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Xf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Zf=null;function Qf(e,t,n){if(Zf===null){var r=new Map,i=Zf=new Map;i.set(n,r)}else i=Zf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[vt]||a[dt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function $f(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function ep(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function tp(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function np(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Vf(r.href),a=t.querySelector(Hf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=ap.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,wt(a);return}a=t.ownerDocument||t,r=Uf(r),(i=Tf.get(i))&&Yf(r,i),a=a.createElement(`link`),wt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Gd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=ap.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var rp=0;function ip(e,t){return e.stylesheets&&e.count===0&&sp(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&sp(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&rp===0&&(rp=62500*Jd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&sp(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>rp?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function ap(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)sp(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var op=null;function sp(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,op=new Map,t.forEach(cp,e),op=null,ap.call(e))}function cp(e,t){if(!(t.state.loading&4)){var n=op.get(e);if(n)var r=n.get(null);else{n=new Map,op.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=ap.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var lp={$$typeof:b,Provider:null,Consumer:null,_currentValue:ie,_currentValue2:ie,_threadCount:0};function up(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=et(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=et(0),this.hiddenUpdates=et(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function dp(e,t,n,r,i,a,o,s,c,l,u,d){return e=new up(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ui(3,null,null,t),e.current=a,a.stateNode=e,t=ua(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ua(a),e}function fp(e){return e?(e=ci,e):ci}function pp(e,t,n,r,i,a){i=fp(i),r.context===null?r.context=i:r.pendingContext=i,r=Ga(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ka(e,r,t),n!==null&&(wu(n,e,t),qa(n,e,t))}function mp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function hp(e,t){mp(e,t),(e=e.alternate)&&mp(e,t)}function gp(e){if(e.tag===13||e.tag===31){var t=ai(e,67108864);t!==null&&wu(t,e,67108864),hp(e,67108864)}}function _p(e){if(e.tag===13||e.tag===31){var t=Su();t=ot(t);var n=ai(e,t);n!==null&&wu(n,e,t),hp(e,t)}}var vp=!0;function V(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=2,bp(e,t,n,r)}finally{A.p=a,k.T=i}}function yp(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=8,bp(e,t,n,r)}finally{A.p=a,k.T=i}}function bp(e,t,n,r){if(vp){var i=H(r);if(i===null)Pd(e,t,r,xp,n),Mp(e,r);else if(Pp(i,e,t,n,r))r.stopPropagation();else if(Mp(e,r),t&4&&-1<jp.indexOf(e)){for(;i!==null;){var a=xt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Ye(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-He(o);s.entanglements[1]|=c,o&=~c}pd(a),!(L&6)&&(uu=Ae()+500,md(0,!1))}}break;case 31:case 13:s=ai(a,2),s!==null&&wu(s,a,2),ku(),hp(a,2)}if(a=H(r),a===null&&Pd(e,t,r,xp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Pd(e,t,r,null,n)}}function H(e){return e=sn(e),Sp(e)}var xp=null;function Sp(e){if(xp=null,e=bt(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return xp=e,null}function Cp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(je()){case Me:return 2;case Ne:return 8;case Pe:case Fe:return 32;case Ie:return 268435456;default:return 32}default:return 32}}var wp=!1,Tp=null,Ep=null,Dp=null,Op=new Map,kp=new Map,Ap=[],jp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Mp(e,t){switch(e){case`focusin`:case`focusout`:Tp=null;break;case`dragenter`:case`dragleave`:Ep=null;break;case`mouseover`:case`mouseout`:Dp=null;break;case`pointerover`:case`pointerout`:Op.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:kp.delete(t.pointerId)}}function Np(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=xt(t),t!==null&&gp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Pp(e,t,n,r,i){switch(t){case`focusin`:return Tp=Np(Tp,e,t,n,r,i),!0;case`dragenter`:return Ep=Np(Ep,e,t,n,r,i),!0;case`mouseover`:return Dp=Np(Dp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Op.set(a,Np(Op.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,kp.set(a,Np(kp.get(a)||null,e,t,n,r,i)),!0}return!1}function Fp(e){var t=bt(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,lt(e.priority,function(){_p(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,lt(e.priority,function(){_p(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Ip(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=H(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);on=r,n.target.dispatchEvent(r),on=null}else return t=xt(n),t!==null&&gp(t),e.blockedOn=n,!1;t.shift()}return!0}function Lp(e,t,n){Ip(e)&&n.delete(t)}function Rp(){wp=!1,Tp!==null&&Ip(Tp)&&(Tp=null),Ep!==null&&Ip(Ep)&&(Ep=null),Dp!==null&&Ip(Dp)&&(Dp=null),Op.forEach(Lp),kp.forEach(Lp)}function zp(e,n){e.blockedOn===n&&(e.blockedOn=null,wp||(wp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Rp)))}var Bp=null;function Vp(e){Bp!==e&&(Bp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Bp===e&&(Bp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(Sp(r||n)===null)continue;break}var a=xt(n);a!==null&&(e.splice(t,3),t-=3,As(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Hp(e){function t(t){return zp(t,e)}Tp!==null&&zp(Tp,e),Ep!==null&&zp(Ep,e),Dp!==null&&zp(Dp,e),Op.forEach(t),kp.forEach(t);for(var n=0;n<Ap.length;n++){var r=Ap[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Ap.length&&(n=Ap[0],n.blockedOn===null);)Fp(n),n.blockedOn===null&&Ap.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[ft]||null;if(typeof a==`function`)o||Vp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[ft]||null)s=o.formAction;else if(Sp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Vp(n)}}}function Up(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Wp(e){this._internalRoot=e}Gp.prototype.render=Wp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;pp(n,Su(),e,t,null,null)},Gp.prototype.unmount=Wp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;pp(e.current,2,null,e,null,null),ku(),t[pt]=null}};function Gp(e){this._internalRoot=e}Gp.prototype.unstable_scheduleHydration=function(e){if(e){var t=ct();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Ap.length&&t!==0&&t<Ap[n].priority;n++);Ap.splice(n,0,e),n===0&&Fp(e)}};var Kp=n.version;if(Kp!==`19.2.8`)throw Error(i(527,Kp,`19.2.8`));A.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:d(e),e=e===null?null:e.stateNode,e};var qp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:k,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Jp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Jp.isDisabled&&Jp.supportsFiber)try{ze=Jp.inject(qp),Be=Jp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=$s,s=ec,c=tc;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=dp(e,1,!1,null,null,n,r,null,o,s,c,Up),e[pt]=t.current,Md(e),new Wp(t)}})),Jx=c(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=qx()}))(),Yx=Math.min,Xx=Math.max,Zx=Math.round,Qx=e=>({x:e,y:e}),$x={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function eS(e,t,n){return Xx(e,Yx(t,n))}function tS(e,t){return typeof e==`function`?e(t):e}function nS(e){return e.split(`-`)[0]}function rS(e){return e.split(`-`)[1]}function iS(e){return e===`x`?`y`:`x`}function aS(e){return e===`y`?`height`:`width`}function oS(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function sS(e){return iS(oS(e))}function cS(e,t,n){n===void 0&&(n=!1);let r=rS(e),i=sS(e),a=aS(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=_S(o)),[o,_S(o)]}function lS(e){let t=_S(e);return[uS(e),t,uS(t)]}function uS(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var dS=[`left`,`right`],fS=[`right`,`left`],pS=[`top`,`bottom`],mS=[`bottom`,`top`];function hS(e,t,n){switch(e){case`top`:case`bottom`:return n?t?fS:dS:t?dS:fS;case`left`:case`right`:return t?pS:mS;default:return[]}}function gS(e,t,n,r){let i=rS(e),a=hS(nS(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(uS)))),a}function _S(e){let t=nS(e);return $x[t]+e.slice(t.length)}function vS(e){return{top:e.top??0,right:e.right??0,bottom:e.bottom??0,left:e.left??0}}function yS(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:vS(e)}function bS(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function xS(e,t,n){let{reference:r,floating:i}=e,a=oS(t),o=sS(t),s=aS(o),c=nS(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}let m=rS(t);return m&&(p[o]+=f*(m===`end`?1:-1)*(n&&l?-1:1)),p}async function SS(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=tS(t,e),p=yS(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=bS(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=bS(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var CS=50,wS=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:SS},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=xS(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<CS&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=xS(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},TS=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=tS(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=nS(r),_=oS(o),v=nS(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[_S(o)]:lS(o)),x=p!==`none`;!d&&x&&b.push(...gS(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),w=[],T=i.flip?.overflows||[];if(l&&w.push(C[g]),u){let e=cS(r,a,y);w.push(C[e[0]],C[e[1]])}if(T=[...T,{placement:r,overflows:w}],!w.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(u!==`alignment`||_===oS(t)||T.every(e=>oS(e.placement)!==_||e.overflows[0]>0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=T.filter(e=>{if(x){let t=oS(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o}if(r!==n)return{reset:{placement:n}}}return{}}}},ES=new Set([`left`,`top`]);async function DS(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=nS(n),s=rS(n),c=oS(n)===`y`,l=ES.has(o)?-1:1,u=a&&c?-1:1,d=tS(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var OS=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await DS(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},kS=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=tS(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=oS(i),p=iS(f),m=u[p],h=u[f],g=(e,t)=>eS(t+d[e===`y`?`top`:`left`],t,t-d[e===`y`?`bottom`:`right`]);o&&(m=g(p,m)),s&&(h=g(f,h));let _=c.fn({...t,[p]:m,[f]:h});return{..._,data:{x:_.x-n,y:_.y-r,enabled:{[p]:o,[f]:s}}}}}};function AS(){return typeof window<`u`}function jS(e){return PS(e)?(e.nodeName||``).toLowerCase():`#document`}function MS(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function NS(e){return((PS(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function PS(e){return AS()?e instanceof Node||e instanceof MS(e).Node:!1}function FS(e){return AS()?e instanceof Element||e instanceof MS(e).Element:!1}function IS(e){return AS()?e instanceof HTMLElement||e instanceof MS(e).HTMLElement:!1}function LS(e){return!AS()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof MS(e).ShadowRoot}function RS(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=YS(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function zS(e){return/^(table|td|th)$/.test(jS(e))}function BS(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var VS=/transform|translate|scale|rotate|perspective|filter/,HS=/paint|layout|strict|content/,US=e=>!!e&&e!==`none`,WS;function GS(e){let t=FS(e)?YS(e):e;return US(t.transform)||US(t.translate)||US(t.scale)||US(t.rotate)||US(t.perspective)||!qS()&&(US(t.backdropFilter)||US(t.filter))||VS.test(t.willChange||``)||HS.test(t.contain||``)}function KS(e){let t=ZS(e);for(;IS(t)&&!JS(t);){if(GS(t))return t;if(BS(t))return null;t=ZS(t)}return null}function qS(){return WS??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),WS}function JS(e){return/^(html|body|#document)$/.test(jS(e))}function YS(e){return MS(e).getComputedStyle(e)}function XS(e){return FS(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ZS(e){if(jS(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||LS(e)&&e.host||NS(e);return LS(t)?t.host:t}function QS(e){let t=ZS(e);return JS(t)?(e.ownerDocument||e).body:IS(t)&&RS(t)?t:QS(t)}function $S(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=QS(e),i=r===e.ownerDocument?.body,a=MS(r);if(i){let e=eC(a);return t.concat(a,a.visualViewport||[],RS(r)?r:[],e&&n?$S(e):[])}return t.concat(r,$S(r,[],n))}function eC(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function tC(e){let t=YS(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=IS(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Zx(n)!==a||Zx(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function nC(e){return FS(e)?e:e.contextElement}function rC(e){let t=nC(e);if(!IS(t))return Qx(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=tC(t),o=(a?Zx(n.width):n.width)/r,s=(a?Zx(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var iC=Qx(0);function aC(e){let t=MS(e);return!qS()||!t.visualViewport?iC:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function oC(e,t,n){return t===void 0&&(t=!1),!!n&&t&&n===MS(e)}function sC(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=nC(e),o=Qx(1);t&&(r?FS(r)&&(o=rC(r)):o=rC(e));let s=oC(a,n,r)?aC(a):Qx(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a&&r){let e=MS(a),t=FS(r)?MS(r):r,n=e,i=eC(n);for(;i&&t!==n;){let e=rC(i),t=i.getBoundingClientRect(),r=YS(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=MS(i),i=eC(n)}}return bS({width:u,height:d,x:c,y:l})}function cC(e,t){let n=XS(e).scrollLeft;return t?t.left+n:sC(NS(e)).left+n}function lC(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-cC(e,n),y:n.top+t.scrollTop}}function uC(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=NS(r),s=t?BS(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=Qx(1),u=Qx(0),d=IS(r);if((d||!a)&&((jS(r)!==`body`||RS(o))&&(c=XS(r)),d)){let e=sC(r);l=rC(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?lC(o,c):Qx(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function dC(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function fC(e){let t=XS(e),n=e.ownerDocument.body,r=Xx(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=Xx(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),a=-t.scrollLeft+cC(e),o=-t.scrollTop;return YS(n).direction===`rtl`&&(a+=Xx(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:a,y:o}}var pC=25;function mC(e,t,n){n===void 0&&(n=`viewport`);let r=n===`layoutViewport`,i=MS(e),a=NS(e),o=i.visualViewport,s=a.clientWidth,c=a.clientHeight,l=0,u=0;if(o){let e=!qS()||t===`fixed`;r?e||(l=-o.offsetLeft,u=-o.offsetTop):(s=o.width,c=o.height,e&&(l=o.offsetLeft,u=o.offsetTop))}if(cC(a)<=0){let e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r),o=getComputedStyle(a).scrollbarGutter===`stable both-edges`?i/2:i;o<=pC&&(s-=o)}return{width:s,height:c,x:l,y:u}}function hC(e,t){let n=sC(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=rC(e);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function gC(e,t,n){let r;if(t===`viewport`||t===`layoutViewport`)r=mC(e,n,t);else if(t===`document`)r=fC(NS(e));else if(FS(t))r=hC(t,n);else{let n=aC(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return bS(r)}function _C(e,t){let n=t.get(e);if(n)return n;let r=$S(e,[],!1).filter(e=>FS(e)&&jS(e)!==`body`),i=null,a=YS(e).position===`fixed`,o=a?ZS(e):e;for(;FS(o)&&!JS(o);){let e=YS(o),t=GS(o),n=i?i.position:a?`fixed`:``;!t&&(n===`fixed`||n===`absolute`&&e.position===`static`)?r=r.filter(e=>e!==o):i=e,o=ZS(o)}return t.set(e,r),r}function vC(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?BS(t)?[]:_C(t,this._c):[].concat(n),r],o=gC(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=gC(t,a[e],i);s=Xx(n.top,s),c=Yx(n.right,c),l=Yx(n.bottom,l),u=Xx(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function yC(e){let{width:t,height:n}=tC(e);return{width:t,height:n}}function bC(e,t,n){let r=IS(t),i=NS(t),a=n===`fixed`,o=sC(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=Qx(0);if((r||!a)&&((jS(t)!==`body`||RS(i))&&(s=XS(t)),r)){let e=sC(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}!r&&i&&(c.x=cC(i));let l=i&&!r&&!a?lC(i,s):Qx(0);return{x:o.left+s.scrollLeft-c.x-l.x,y:o.top+s.scrollTop-c.y-l.y,width:o.width,height:o.height}}function xC(e){return YS(e).position===`static`}function SC(e,t){if(!IS(e)||YS(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return NS(e)===n&&(n=n.ownerDocument.body),n}function CC(e,t){let n=MS(e);if(BS(e))return n;if(!IS(e)){let t=ZS(e);for(;t&&!JS(t);){if(FS(t)&&!xC(t))return t;t=ZS(t)}return n}let r=SC(e,t);for(;r&&zS(r)&&xC(r);)r=SC(r,t);return r&&JS(r)&&xC(r)&&!GS(r)?n:r||KS(e)||n}var wC=async function(e){let t=this.getOffsetParent||CC,n=this.getDimensions,r=await n(e.floating);return{reference:bC(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function TC(e){return YS(e).direction===`rtl`}var EC={convertOffsetParentRelativeRectToViewportRelativeRect:uC,getDocumentElement:NS,getClippingRect:vC,getOffsetParent:CC,getElementRects:wC,getClientRects:dC,getDimensions:yC,getScale:rC,isElement:FS,isRTL:TC},DC=OS,OC=kS,kC=TS,AC=(e,t,n)=>{let r=new Map,i=n??{},a={...EC,...i.platform,_c:r};return wS(e,t,{...i,platform:a})},jC=d(Kx(),1),MC=typeof document<`u`?W.useLayoutEffect:function(){};function NC(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!NC(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!NC(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function PC(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function FC(e,t){let n=PC(e);return Math.round(t*n)/n}function IC(e){let t=W.useRef(e);return MC(()=>{t.current=e}),t}function LC(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=W.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=W.useState(r);NC(f,r)||p(r);let[m,h]=W.useState(null),[g,_]=W.useState(null),v=W.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=W.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=W.useRef(null),C=W.useRef(null),w=W.useRef(u),T=c!=null,E=IC(c),D=IC(i),O=IC(l),ee=W.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};D.current&&(e.platform=D.current),AC(S.current,C.current,e).then(e=>{let t={...e,isPositioned:O.current!==!1};te.current&&!NC(w.current,t)&&(w.current=t,jC.flushSync(()=>{d(t)}))})},[f,t,n,D,O]);MC(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let te=W.useRef(!1);MC(()=>(te.current=!0,()=>{te.current=!1}),[]),MC(()=>{if(b&&(S.current=b),x&&(C.current=x),b&&x){if(E.current)return E.current(b,x,ee);ee()}},[b,x,ee,E,T]);let ne=W.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),re=W.useMemo(()=>({reference:b,floating:x}),[b,x]),k=W.useMemo(()=>{let e={position:n,left:0,top:0};if(!re.floating)return e;let t=FC(re.floating,u.x),r=FC(re.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...PC(re.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,re.floating,u.x,u.y]);return W.useMemo(()=>({...u,update:ee,refs:ne,elements:re,floatingStyles:k}),[u,ee,ne,re,k])}var RC=(e,t)=>{let n=DC(e);return{name:n.name,fn:n.fn,options:[e,t]}},zC=(e,t)=>{let n=OC(e);return{name:n.name,fn:n.fn,options:[e,t]}},BC=(e,t)=>{let n=kC(e);return{name:n.name,fn:n.fn,options:[e,t]}},VC=e=>{let[t,n]=W.useState(e),r=W.useRef(t);return[t,W.useCallback(function(e){r.current=typeof e==`function`?e(r.current):e,n(r.current)},[]),r]},HC=({analytics:e,element:t,data:n,prevData:r,hide:i,updateTextWithAlternative:a,addIgnoredTerm:o,movePopoverNextOrPrev:s,setLLMSuggestionsRequest:c,getLLMSuggestions:l,llmAlternativesEnabled:u,ignoreTermPermanently:d,onAlternativeAccepted:f})=>{let[p,m]=(0,W.useState)(null),[h,g,_]=VC(!1),[v,y]=(0,W.useState)(``),[b,x]=(0,W.useState)(``),[S,C]=(0,W.useState)(``),w=(0,W.useRef)(null);(0,W.useEffect)(()=>()=>{w.current!==null&&clearTimeout(w.current)},[]);let T=l({alert:n.alert}),E=(0,W.useRef)(null);(0,W.useEffect)(()=>{r&&r.alert.id===n.alert.id||E.current!==n.alert.id&&(E.current=n.alert.id,e.popoverLogs(n.alert,`popover_open`))},[n.alert.id]),(0,W.useEffect)(()=>{u&&n.alert.data.alternatives.length>0&&c({alert:n.alert})},[n.alert.id,u]);let D=(t=!1)=>{t&&e.popoverLogs(n.alert,`popover_close`),g(!1),i();let r=window.document.getElementsByTagName(`ww-popover`);Array.from(r).forEach(e=>{e.remove()})},O=(t,r)=>{t.preventDefault(),t.stopImmediatePropagation(),e.alternativeLog(n.alert,r),f(),a(r)};return{analytics:e,alternativeHovered:p,setAlternativeHovered:m,showLearningBite:h,setShowLearningBite:g,showLearningBiteRef:_,isLoading:v,isSuccess:b,isFailure:S,llmAlternativesResponse:T,hidePopover:D,clickAlternative:O,alternativeKeyDown:e=>n=>{(n.key===`Enter`||n.key===` `)&&(t.focus?.(),O(n.nativeEvent,e))},handleIgnoreClick:r=>()=>{e.ignoreLog(n.alert),r===`ignore_once`?(o(n.alert.data?.text),D()):r===`ignore_permanently`&&(y(r),x(``),C(``),d(n.alert.data?.text).then(()=>{y(``),o(n.alert.data?.text),x(r),w.current=window.setTimeout(()=>{let e=!!document.getElementById(`witty-works-ext-popover`)?.contains(document.activeElement);D(),e&&t.focus?.()},1e3)}).catch(()=>{y(``),C(r)}))},goToAdjacentAlert:e=>{s(e),g(!1)}}},UC=c((e=>{var t=Symbol.for(`react.transitional.element`);function n(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.jsx=n,e.jsxs=n})),G=c(((e,t)=>{t.exports=UC()}))(),WC=e=>(0,G.jsx)(`svg`,{width:15,height:14,viewBox:`0 0 15 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.6103 8.89864C7.80556 8.70338 8.12214 8.70338 8.31741 8.89864L13.1493 13.7305C13.3445 13.9258 13.6611 13.9258 13.8564 13.7305L14.5352 13.0517C14.7304 12.8565 14.7304 12.5399 14.5352 12.3446L9.7033 7.51275C9.50804 7.31749 9.50804 7.0009 9.7033 6.80564L14.8536 1.65535C15.0488 1.46009 15.0488 1.14351 14.8536 0.948248L14.1748 0.269463C13.9795 0.074201 13.663 0.0742007 13.4677 0.269463L8.31741 5.41975C8.12214 5.61501 7.80556 5.61501 7.6103 5.41975L2.46001 0.269463C2.26475 0.0742007 1.94817 0.074201 1.7529 0.269463L1.07412 0.948248C0.878858 1.14351 0.878858 1.46009 1.07412 1.65535L6.22441 6.80564C6.41967 7.0009 6.41967 7.31749 6.22441 7.51275L1.39254 12.3446C1.19727 12.5399 1.19727 12.8565 1.39254 13.0517L2.07132 13.7305C2.26658 13.9258 2.58317 13.9258 2.77843 13.7305L7.6103 8.89864Z`,fill:`#656565`})}),GC=e=>(0,G.jsxs)(`svg`,{width:25,height:14,viewBox:`0 0 25 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,xmlnsXlink:`http://www.w3.org/1999/xlink`,...e,children:[(0,G.jsx)(`rect`,{width:25,height:14,fill:`url(#pattern0)`}),(0,G.jsxs)(`defs`,{children:[(0,G.jsx)(`pattern`,{id:`pattern0`,patternContentUnits:`objectBoundingBox`,width:1,height:1,children:(0,G.jsx)(`use`,{xlinkHref:`#image0_554_760`,transform:`translate(0 -0.0197228) scale(0.0149254 0.0266525)`})}),(0,G.jsx)(`image`,{id:`image0_554_760`,width:67,height:39,xlinkHref:`data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEMAAAAnCAYAAABUr/U/AAAOXUlEQVRoBb1aaVBbV5bm3yx/OlM9NTM1P8bT1VVdNVM1mUnVVCbVhnhh8R5vsbHTsUN3XJlkpivt6p6qTjpO4thG7LsQAsRqwDbesI3BNhixb1rfE0JIbxF670GMtycksZmEb+oKRIQiEWzcoeqW3t3P+d75Luec+6KiQv6mUqgT3mSqz5tMyeGKT2Ga9qYaZrxphhlfun7Gl6Gf8WbpZyZzBmbduQOzT/P6Zh8X9M5OFPTMTSi75ybU3XMTxR1zYlGvxOUPHgjZbk3VmkLHtTIVI5eoGVmlZuSCYkbOK2XlLA0rp5excmoFJ+eWsrqCEkabU8Jos0tZbUY5r00v57WKSl57tprXnjnPa7+s4bWnLji1n1505vz+yuhrETfHOeMGn8I87lNQWLWkmOBL18OXpYc3exDenAF48vowWdALd2EP5KIuyMWdkEu0kMvaIFe0Qq66B7nmDp7W3AVb1F8SUYiQjqtKfkOlyjFdWsSgSM2gQM0it4RFVimLjDIOqRUckqsWfwuKV/alVXBQVHE4V83jq/M8vqzl8fkFJ/50yYk/Xnbidw2j+N0N162T152vrNgWp02v+JLN06uCsASSN9mMqUwdvNkD8Ob2w5PfC4+SANEFt7oT7pIOyKVayOVteFpxD3I1AaIZ7rrbcF9qxJNLjbAV9/7bCgEiVGpVDqNGxUBdxKBQzSKvmEV2KYtMDYfvlOWQU8L6SzBIBIizBIgaHl/WOXEqAES9Ex83uPDbm6P47U0X/vemk1qx/ZSCMq4FiOUx6Xp48/rhKSBAdGNS1YXJ4g64iTVolqyh8h7k83ch196GfLERk/W3MHm5AZPXri14Gq7VrxAgTKW+0B5dpmJQUsRApWaQX7yksIZFejmHlMrFt55WvggGASJ9yVqCgfiCAHHxO4v4uGEUHzW68FHjKP6n0YUPG0fx4W1Xrl+ERXr8ADVCqONVmOHJ74GnsBvuok5MlnRgslQLd9l9uCtaIFfdhbvmjh8I96VbcF++AffVawveG1fmPTcufzt5+7rwtL7+J2EwWG6qUjnGA/RQLtEjW7OSHmerOb+lZBGAgmhDLOJ0DY8AEJ/6qTGKkw2j+O8m11IhzwI+aHLhg6ZROYnQZUpBn1p+4yuUNs/7kik5XJlUULI7e9AnF/TMycruOVndNfdU3T73pFT77JGm7dmj8vvPHlW2Pnt4vuXZk0uN85PXr857Gi5/6228Outtangy1XLb5WtpOr6sechDnZI5SehRHESPnCV6ZGhYObWckxVVnJxSyTkzStn2tHK2PaWCbT9bzfvL6fN8++d1zvZTF5ztn1xytn9S72z/v6vO9hNNLt37zaPjJ5pdOHFH8Jf3m134zR0XkprFzVE+Ba0NBwaxmBAZX6gqX7/wz96blxc8jde83rs3H0y1NrFT7Xep6e62K5EWrFQ55AA9yMFIzgRCg2wNr400Z63tHzQxP//1XQG/ubdYku66kHRPwLstrtNR3mTz9XBgTCVTJ9a6wQ+N8zY3FPru3RKn2+7Ypjpb9b6ejvap/s7bXl3X5tC51YV2DaEHOTT99CCHpoZFZhm3kKnh1/2CkprFnUT591oFvNci4FirgGP3BbyjFZKips+ZE8OB4VVQ3lBBX7Q+2XLzjSntPXqqo7VvqrezZXqgu2Fa31c7azb+PnRNTaFjfpEeS4emnx4sMkvY66FjX6R+vEWQjrW6/CC8e1/Er9oEvNMm4JBW+g//ej6FeT4cID4FpXmRDcPNmepqL5/p72ia1vVenjMNVkzTJuXskDlthh9eftuVhcx1Qg+/TxHsN2jY+XBrPm/b8Vbhc6L8YhH9IBzRCkhsF8zLaxGlI4Dx7cxLOjt8g52xPn1/3SxlKJmlTTkzw5Zz84z9k1nOEUcEqVXyG0qLmIUAPQI+BXGu0kvZ/GVhX/Dh6K3xvz163+U5qhVxtE3AEa2II+0CDncIONgp7FuxLKFFOEC8KXTfioHrqMwMGc/MWan0ecb2xSxv/8Mzp+PDOdH1LsbH/7pCxWjD0SNdw8nr2HJ56tE2oZIon9gh4rAfBBGHOgXs7xI7lwcFHnznTCfDgqGg8DTVGh0Yt57fGSsVO8/YP511Oj6eGeXfnxsTEr958GB3910hcZkeQS438R0yypwn17Mnmbu/Y/xfDhMQOgQc6hSJJeBgp4QD3SLe6h0LH6NMKcxMKCCTKRQepVCP1isQmQ+G+YtnTuajb1z88W/Gxw/MT0xsg2diY3UZy32PHosu9/jL2PftdpfpYJcAUg50iTjQI2Ffj4Q9vUJtxPXnki2vepOphQAgHgUFOYXG41QaUhq17jdENn72QPyvbx482DP/+PFWPH78+q2ro2cIPYJd7swllzu1yrVuizzUKSTt75awv1vA/h4Re3sk7O0lQIie6C7330QEg3R4lpwwr4LCZAqNJ6k0HqbRkFLpuVUnrrETovhX8w/HYyDLr816PL8oVTNy2Ii0nDeucclVh+3tESeIFeztEfwgvNUrYk+fhB19YuqqE0kniWA9Cmqe0ONpKo1HqTS+9lsGDT7NcucHF1jDALgf/GzG7f5ZbZXzj2Ej0nJu4Vzt+h2s/Z1CEVH+rV4JARB29YnYOSBKaxBzcchjBZ3iXqLHRJoFY2k0hHQ/GAt85vqFBPCXAH5SrHLMB9PDH3CVcyAJmTULG2FgbOvE3+/pk6Z294nY3SeB/O7ql7CjX0TsoLg9wrTwzRNptEzoMZ5KQ0yjMZpuAZthwXDmkDX8jOdrVasYDaFHaESaUv5yHKzd3ULL7n4Ju/pF7BqQiDVgu05CwqA48HySRkVFfZ1O73xAzoo0Gq50C/gMCxwEjIwhmLKGdz73gkETNEp+Q3ERsxBI2AQiUpKbOFvJrdvr3d0rxe7sJ3SQsJ2AMChh26CIBP0YYgekXwSJsvZHV6rFSqzCmW4Bk2HBSMYQhjIJGNZ1OUJFakZL6BGcqiMJG0Ul91LioZ39oo0AQEqCTvSXeL2EWMNYxdq1DxlJzgdnmmWBy7DAnjkEa+YQLJlWAga6s60pIcPXVC0s5KKLipgFQg+/yx2UsDlTvX4Ha0eP8IcEPwgStukkxOtExBkkxBrHfK/bPD9dk5CRBg2nW64TetgyCBBDoLKsMGRb0ZdjndfmhCRTIy0S1K4qZpjCQBpvKSIl9Eiu4tbt2O0cfPgPCTrhKbGCQIk1jGGrQcIWo3QmSIwXf7RmDM0TetBZVhizrNBlD6MvZxhtubbnOvUL1M7E0IiUuNz+fGbd+h2sHQOumnj9oiXEGccQa5Cw1TiGTQaRe3HtQ2YasoZPEqswZ1mhz7aiP2cYPTnDaM+xLbTmjrwaMjxitVDNyMv0CEr3n6vmmYiT1tgRpxt9LUEvzMQZRL8lEBC2GCVsNo0hhg6JSte4ZsRhhqzhR4Qeg9nD6M0ZRmeODdpcG5ry7WtSJL+YO7nsUwTRI6WSW/jsJThY23Su3niDgFiD6Adhi2kMm00Sos1Sd0SlXrSjK9caHaBHN7GKXBvu59lwL28EV5UjPxi3KIuZ6eBLoEA2+3TN9x2sfSbtK0nGniPv9Q9+ekjfsmoWneizQ8cfjze4EGcUsNVvDRLeNEmIocYQY/z6X19U51XndeXa+gg9OpasoiVvBHfyR9CQb1/1X2JuCadZQY+lS6BzVdx8qFX4gdB3Pjxm6sCvTN14xzgwe6zTtm01wbYZnc44owtbjQK2EBDMi0D8khpb8+3dauuH7etR8hs6cmwLhB6teTbczR/B7fwR3My340KhPayzpFTyG5RqZj5wCRSISMmh+cV5/ntzkga7rySZ2/AdGH04MmiaCCtQVFTUdr0rJcHkRKzJhS1mAW+aRURTY9holmZepR78XaR5L6W9OW9E05a7SI/m/BHcyrfjeoEd9UrHAkndhW6Sr2G1wfQI3JGerebDRsG/1nfbgsE4auxDolGHgwPD6aFrbzQ++scEE+eJNzmx1eTCJkpEDC1hIz2GNyzSZ6Hj/yz15rwRL6FHY/4IbuTbcbXAjktKB0jqLnhDpYbfoCxmFwL5TP8dKfE0qzh8VhfewUrq02mCwThCwDDp8LbBPL9PK6+4JN5uYG8kmDjEmZ3YYnbhTVpEtEXCL4fGbMFy/FmfyYEZoMe1AjsuKx24UOhAjYpBYTG3nJDJ1bBMgB6BiJTQ46saflV3/j1913SAJotg6PG2yYi9OmtjQLF4I/ef280s4s0cYiknNlEuxFgWwdhoGUsMjPtRfq8WOFwNBXZcUTpwUelAXaED1eRKUM36U3VZpc7E0Ig08AnBqdrRVQO9pF7DyWUwTP04bNTjoMmI/UYau3X214mCO8wOxzYzizgzh820E2/SLsQMidg4JK2wzh8FjLpiLvpygX2hfskqzqsYVKoYkDvSwmJmWlnM+OmxGJGyIC63opIj30msyS95Vz849o6pG0eCwTBReMs0NLWDGnm8nbIjgWIRS3HYRMCwCIihXbPRRunffxQAQjepLmK0hB61hQ5UqRiUB31CEBqREnqcreYX/lTHr8ljPaQ3Rx819Cz4wTAtWsY+E4U95iHsNA9jG2VHPM1iC81hk4WAMYoYmq8JlfFHq1dUOF85r3LMEXpUqBgE35GGRqT+Q/Oi87lM+JDO2Jpo7sdhkx4HTEYQMHaZh7DDPIwEyoG4JTA20zwB5OsfTfFIG6nL2URCD/JhSbhLIEIPYhWna1c/NCOt/7bJ8OgQAcNsxF4CBmXFdmoRjHiaQSyxDJqbixlyruqYRVr/pbfnlrKJKjUzFyki/bKWs56ueP5wnwgap7f+034zPbSfgGEOBoPQhMEWmp3cbHU+X07zpSMQZsH0Mj4/Q8OyqeWs/2OSr87zfZ/Vrz8094NiGH5jO2W7v42yjSXQdjGOYnSxNJsWRowXbvp/SRXI2cTQoJkAAAAASUVORK5CYII=`})]})]}),KC=e=>(0,G.jsx)(`svg`,{width:10,height:16,viewBox:`0 0 10 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.09928 8L0.795978 1.6967L2.21019 0.282485L9.92771 8L2.21019 15.7175L0.795978 14.3033L7.09928 8Z`,fill:`#656565`})}),qC=e=>(0,G.jsx)(`svg`,{width:10,height:16,viewBox:`0 0 10 16`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`nonzero`,clipRule:`nonzero`,d:`M2.88607 8L9.18937 1.6967L7.77516 0.282485L0.057645 8L7.77516 15.7175L9.18937 14.3033L2.88607 8Z`,fill:`#656565`})}),JC=e=>(0,G.jsx)(`svg`,{width:21,height:14,viewBox:`0 0 21 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`M20.7821 1.17019C20.6468 1.09075 20.4797 1.08765 20.3417 1.16226L15.5234 3.77075V2.20562C15.522 0.988049 14.5268 0.00137851 13.2988 0H2.22458C0.996541 0.00137851 0.00139036 0.988049 0 2.20562V10.9144C0.00139036 12.1319 0.996541 13.1186 2.22458 13.12H13.2988C14.5268 13.1186 15.522 12.1319 15.5234 10.9144V9.37768L20.3418 11.9862C20.4797 12.0608 20.647 12.0579 20.7821 11.9784C20.9173 11.8988 21 11.7546 21 11.599V1.54945C21 1.39368 20.9171 1.24962 20.7821 1.17019ZM14.6332 10.9146C14.6325 11.6452 14.0353 12.2371 13.2984 12.2379H2.22458C1.48769 12.2371 0.8907 11.6452 0.889831 10.9146V2.20562C0.8907 1.47518 1.48769 0.88311 2.22458 0.882248H13.2988C14.0355 0.88311 14.6327 1.47518 14.6335 2.20562L14.6332 10.9146ZM20.1102 10.8556L15.5234 8.37257V4.77586L20.1102 2.29298V10.8556Z`,fill:`#F06464`})}),YC=e=>(0,G.jsx)(`svg`,{width:14.5,height:14.5,viewBox:`0 0 50 50`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`m37.5 22.5416c-.5526 0-1.0825.2195-1.4732.6102s-.6102.9206-.6102 1.4732v14.9583c0 .5525-.2195 1.0824-.6102 1.4731s-.9206.6102-1.4731.6102h-22.9167c-.55251 0-1.08241-.2195-1.47311-.6102s-.6102-.9206-.6102-1.4731v-22.9167c0-.5525.2195-1.0824.6102-1.4731s.9206-.6102 1.47311-.6102h14.9584c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102h-14.9584c-1.65758 0-3.24729.6585-4.41939 1.8306s-1.83058 2.7618-1.83058 4.4194v22.9167c0 1.6576.65848 3.2473 1.83058 4.4194s2.76181 1.8306 4.41939 1.8306h22.9167c1.6576 0 3.2473-.6585 4.4194-1.8306s1.8306-2.7618 1.8306-4.4194v-14.9583c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102zm8.1666-17.08331c-.2114-.50906-.6159-.91359-1.125-1.125-.2504-.10675-.5194-.16337-.7916-.16666h-12.5c-.5526 0-1.0825.21949-1.4732.61019s-.6102.9206-.6102 1.47314c0 .55253.2195 1.08244.6102 1.47314s.9206.61019 1.4732.61019h7.4791l-21.4583 21.43751c-.1953.1937-.3503.4241-.456.678-.1058.2538-.1603.5261-.1603.8012 0 .275.0545.5473.1603.8012.1057.2538.2607.4843.456.6779.1937.1953.4241.3503.678.456.2538.1058.5261.1603.8012.1603.275 0 .5473-.0545.8012-.1603.2538-.1057.4843-.2607.6779-.456l21.4375-21.4583v7.4792c0 .5525.2195 1.0824.6102 1.4731s.9206.6102 1.4732.6102c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731v-12.50004c-.0033-.27225-.0599-.5412-.1667-.79167z`,fill:`#ffffff`})}),XC=e=>(0,G.jsx)(`svg`,{width:14.5,height:14.5,viewBox:`0 0 50 50`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`m37.5 22.5416c-.5526 0-1.0825.2195-1.4732.6102s-.6102.9206-.6102 1.4732v14.9583c0 .5525-.2195 1.0824-.6102 1.4731s-.9206.6102-1.4731.6102h-22.9167c-.55251 0-1.08241-.2195-1.47311-.6102s-.6102-.9206-.6102-1.4731v-22.9167c0-.5525.2195-1.0824.6102-1.4731s.9206-.6102 1.47311-.6102h14.9584c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102h-14.9584c-1.65758 0-3.24729.6585-4.41939 1.8306s-1.83058 2.7618-1.83058 4.4194v22.9167c0 1.6576.65848 3.2473 1.83058 4.4194s2.76181 1.8306 4.41939 1.8306h22.9167c1.6576 0 3.2473-.6585 4.4194-1.8306s1.8306-2.7618 1.8306-4.4194v-14.9583c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102zm8.1666-17.08331c-.2114-.50906-.6159-.91359-1.125-1.125-.2504-.10675-.5194-.16337-.7916-.16666h-12.5c-.5526 0-1.0825.21949-1.4732.61019s-.6102.9206-.6102 1.47314c0 .55253.2195 1.08244.6102 1.47314s.9206.61019 1.4732.61019h7.4791l-21.4583 21.43751c-.1953.1937-.3503.4241-.456.678-.1058.2538-.1603.5261-.1603.8012 0 .275.0545.5473.1603.8012.1057.2538.2607.4843.456.6779.1937.1953.4241.3503.678.456.2538.1058.5261.1603.8012.1603.275 0 .5473-.0545.8012-.1603.2538-.1057.4843-.2607.6779-.456l21.4375-21.4583v7.4792c0 .5525.2195 1.0824.6102 1.4731s.9206.6102 1.4732.6102c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731v-12.50004c-.0033-.27225-.0599-.5412-.1667-.79167z`,fill:`#656565`})}),ZC=e=>(0,G.jsx)(`svg`,{width:16,height:10,viewBox:`0 0 16 10`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.79599 2.82817L13.996 9.23311L15.433 7.84208L7.84197 0.00011482L8.50898e-06 7.59114L1.39104 9.02816L7.79599 2.82817Z`,fill:`#f06464`})}),QC=e=>(0,G.jsx)(`svg`,{width:16,height:10,viewBox:`0 0 16 10`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.71753 6.60685L1.41423 0.303546L1.3929e-05 1.71776L7.71753 9.43527L15.435 1.71776L14.0208 0.303546L7.71753 6.60685Z`,fill:`#f06464`})}),$C=Object.defineProperty,ew=(e,t)=>{let n={};for(var r in e)$C(n,r,{get:e[r],enumerable:!0});return t||$C(n,Symbol.toStringTag,{value:`Module`}),n},tw=_w(),K=e=>fw(e,tw),nw=_w();K.write=e=>fw(e,nw);var rw=_w();K.onStart=e=>fw(e,rw);var iw=_w();K.onFrame=e=>fw(e,iw);var aw=_w();K.onFinish=e=>fw(e,aw);var ow=[];K.setTimeout=(e,t)=>{let n=K.now()+t,r=()=>{let e=ow.findIndex(e=>e.cancel==r);~e&&ow.splice(e,1),uw-=+!!~e},i={time:n,handler:e,cancel:r};return ow.splice(sw(n),0,i),uw+=1,pw(),i};var sw=e=>~(~ow.findIndex(t=>t.time>e)||~ow.length);K.cancel=e=>{rw.delete(e),iw.delete(e),aw.delete(e),tw.delete(e),nw.delete(e)},K.sync=e=>{dw=!0,K.batchedUpdates(e),dw=!1},K.throttle=e=>{let t;function n(){try{e(...t)}finally{t=null}}function r(...e){t=e,K.onStart(n)}return r.handler=e,r.cancel=()=>{rw.delete(n),t=null},r};var cw=typeof window<`u`?window.requestAnimationFrame:()=>{};K.use=e=>cw=e,K.now=typeof performance<`u`?()=>performance.now():Date.now,K.batchedUpdates=e=>e(),K.catch=console.error,K.frameLoop=`always`,K.onDemand=()=>{},K.advance=()=>{K.frameLoop===`demand`?gw():console.warn(`Cannot call the manual advancement of rafz whilst frameLoop is not set as demand`)};var lw=-1,uw=0,dw=!1;function fw(e,t){dw?(t.delete(e),e(0)):(t.add(e),pw(),K.frameLoop===`demand`&&K.onDemand())}function pw(){lw<0&&(lw=0,K.frameLoop!==`demand`&&cw(hw))}function mw(){lw=-1}function hw(){~lw&&(cw(hw),K.batchedUpdates(gw))}function gw(){let e=lw;lw=K.now();let t=sw(lw);if(t&&(vw(ow.splice(0,t),e=>e.handler()),uw-=t),!uw){mw();return}rw.flush(),tw.flush(e?Math.min(64,lw-e):16.667),iw.flush(),nw.flush(),aw.flush(),K.frameLoop===`demand`&&uw>0&&K.onDemand()}function _w(){let e=new Set,t=e;return{add(n){uw+=+(t==e&&!e.has(n)),e.add(n)},delete(n){return uw-=t==e&&e.has(n)?1:0,e.delete(n)},flush(n){t.size&&(e=new Set,uw-=t.size,vw(t,t=>t(n)&&e.add(t)),uw+=e.size,t=e)}}}function vw(e,t){e.forEach(e=>{try{t(e)}catch(e){K.catch(e)}})}function yw(){}var bw=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),q={arr:Array.isArray,obj:e=>!!e&&e.constructor.name===`Object`,fun:(e=>typeof e==`function`),str:e=>typeof e==`string`,num:e=>typeof e==`number`,und:e=>e===void 0};function xw(e,t){if(q.arr(e)){if(!q.arr(t)||e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}return e===t}var J=(e,t)=>e.forEach(t);function Sw(e,t,n){if(q.arr(e)){for(let r=0;r<e.length;r++)t.call(n,e[r],`${r}`);return}for(let r in e)e.hasOwnProperty(r)&&t.call(n,e[r],r)}var Cw=e=>q.und(e)?[]:q.arr(e)?e:[e];function ww(e,t){if(e.size){let n=Array.from(e);e.clear(),J(n,t)}}var Tw=(e,...t)=>ww(e,e=>e(...t)),Ew=()=>typeof window>`u`||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),Dw=ew({assign:()=>Nw,colors:()=>Aw,createStringInterpolator:()=>Ow,skipAnimation:()=>jw,to:()=>kw,willAdvance:()=>Mw}),Ow,kw,Aw=null,jw=!1,Mw=yw,Nw=e=>{e.to&&(kw=e.to),e.now&&(K.now=e.now),e.colors!==void 0&&(Aw=e.colors),e.skipAnimation!=null&&(jw=e.skipAnimation),e.createStringInterpolator&&(Ow=e.createStringInterpolator),e.requestAnimationFrame&&K.use(e.requestAnimationFrame),e.batchedUpdates&&(K.batchedUpdates=e.batchedUpdates),e.willAdvance&&(Mw=e.willAdvance),e.frameLoop&&(K.frameLoop=e.frameLoop),e.onDemand&&(K.onDemand=e.onDemand)},Pw=new Set,Fw=[],Iw=[],Lw=0,Rw={get idle(){return!Pw.size&&!Fw.length},start(e){Lw>e.priority?(Pw.add(e),K.onStart(zw)):(Bw(e),K(Hw))},advance:Hw,sort(e){if(Lw)K.onFrame(()=>Rw.sort(e));else{let t=Fw.indexOf(e);~t&&(Fw.splice(t,1),Vw(e))}},clear(){Fw=[],Pw.clear()}};function zw(){Pw.forEach(Bw),Pw.clear(),K(Hw)}function Bw(e){Fw.includes(e)||Vw(e)}function Vw(e){Fw.splice(Uw(Fw,t=>t.priority>e.priority),0,e)}function Hw(e){let t=Iw;for(let n=0;n<Fw.length;n++){let r=Fw[n];Lw=r.priority,r.idle||(Mw(r),r.advance(e),r.idle||t.push(r))}return Lw=0,Iw=Fw,Iw.length=0,Fw=t,Fw.length>0}function Uw(e,t){let n=e.findIndex(t);return n<0?e.length:n}var Ww=(e,t,n)=>Math.min(Math.max(n,e),t),Gw={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},Kw=`[-+]?\\d*\\.?\\d+`,qw=`[-+]?\\d*\\.?\\d+%`;function Jw(...e){return`\\(\\s*(`+e.join(`)\\s*,\\s*(`)+`)\\s*\\)`}var Yw=RegExp(`rgb`+Jw(Kw,Kw,Kw)),Xw=RegExp(`rgba`+Jw(Kw,Kw,Kw,Kw)),Zw=RegExp(`hsl`+Jw(Kw,qw,qw)),Qw=RegExp(`hsla`+Jw(Kw,qw,qw,Kw)),$w=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,eT=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,tT=/^#([0-9a-fA-F]{6})$/,nT=/^#([0-9a-fA-F]{8})$/;function rT(e){let t;return typeof e==`number`?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=tT.exec(e))?parseInt(t[1]+`ff`,16)>>>0:Aw&&Aw[e]!==void 0?Aw[e]:(t=Yw.exec(e))?(oT(t[1])<<24|oT(t[2])<<16|oT(t[3])<<8|255)>>>0:(t=Xw.exec(e))?(oT(t[1])<<24|oT(t[2])<<16|oT(t[3])<<8|cT(t[4]))>>>0:(t=$w.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+`ff`,16)>>>0:(t=nT.exec(e))?parseInt(t[1],16)>>>0:(t=eT.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=Zw.exec(e))?(aT(sT(t[1]),lT(t[2]),lT(t[3]))|255)>>>0:(t=Qw.exec(e))?(aT(sT(t[1]),lT(t[2]),lT(t[3]))|cT(t[4]))>>>0:null}function iT(e,t,n){return n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function aT(e,t,n){let r=n<.5?n*(1+t):n+t-n*t,i=2*n-r,a=iT(i,r,e+1/3),o=iT(i,r,e),s=iT(i,r,e-1/3);return Math.round(a*255)<<24|Math.round(o*255)<<16|Math.round(s*255)<<8}function oT(e){let t=parseInt(e,10);return t<0?0:t>255?255:t}function sT(e){return(parseFloat(e)%360+360)%360/360}function cT(e){let t=parseFloat(e);return t<0?0:t>1?255:Math.round(t*255)}function lT(e){let t=parseFloat(e);return t<0?0:t>100?1:t/100}function uT(e){let t=rT(e);return t===null?e:(t||=0,`rgba(${(t&4278190080)>>>24}, ${(t&16711680)>>>16}, ${(t&65280)>>>8}, ${(t&255)/255})`)}var dT=(e,t,n)=>{if(q.fun(e))return e;if(q.arr(e))return dT({range:e,output:t,extrapolate:n});if(q.str(e.output[0]))return Ow(e);let r=e,i=r.output,a=r.range||[0,1],o=r.extrapolateLeft||r.extrapolate||`extend`,s=r.extrapolateRight||r.extrapolate||`extend`,c=r.easing||(e=>e);return e=>{let t=pT(e,a);return fT(e,a[t],a[t+1],i[t],i[t+1],c,o,s,r.map)}};function fT(e,t,n,r,i,a,o,s,c){let l=c?c(e):e;if(l<t){if(o===`identity`)return l;o===`clamp`&&(l=t)}if(l>n){if(s===`identity`)return l;s===`clamp`&&(l=n)}return r===i?r:t===n?e<=t?r:i:(t===-1/0?l=-l:n===1/0?l-=t:l=(l-t)/(n-t),l=a(l),r===-1/0?l=-l:i===1/0?l+=r:l=l*(i-r)+r,l)}function pT(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}var mT=(e,t=`end`)=>n=>{n=t===`end`?Math.min(n,.999):Math.max(n,.001);let r=n*e;return Ww(0,1,(t===`end`?Math.floor(r):Math.ceil(r))/e)},hT=1.70158,gT=hT*1.525,_T=2.70158,vT=2*Math.PI/3,yT=2*Math.PI/4.5,bT=e=>{let t=7.5625,n=2.75;return e<1/n?t*e*e:e<2/n?t*(e-=1.5/n)*e+.75:e<2.5/n?t*(e-=2.25/n)*e+.9375:t*(e-=2.625/n)*e+.984375},xT={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>1-(1-e)*(1-e),easeInOutQuad:e=>e<.5?2*e*e:1-(-2*e+2)**2/2,easeInCubic:e=>e*e*e,easeOutCubic:e=>1-(1-e)**3,easeInOutCubic:e=>e<.5?4*e*e*e:1-(-2*e+2)**3/2,easeInQuart:e=>e*e*e*e,easeOutQuart:e=>1-(1-e)**4,easeInOutQuart:e=>e<.5?8*e*e*e*e:1-(-2*e+2)**4/2,easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>1-(1-e)**5,easeInOutQuint:e=>e<.5?16*e*e*e*e*e:1-(-2*e+2)**5/2,easeInSine:e=>1-Math.cos(e*Math.PI/2),easeOutSine:e=>Math.sin(e*Math.PI/2),easeInOutSine:e=>-(Math.cos(Math.PI*e)-1)/2,easeInExpo:e=>e===0?0:2**(10*e-10),easeOutExpo:e=>e===1?1:1-2**(-10*e),easeInOutExpo:e=>e===0?0:e===1?1:e<.5?2**(20*e-10)/2:(2-2**(-20*e+10))/2,easeInCirc:e=>1-Math.sqrt(1-e**2),easeOutCirc:e=>Math.sqrt(1-(e-1)**2),easeInOutCirc:e=>e<.5?(1-Math.sqrt(1-(2*e)**2))/2:(Math.sqrt(1-(-2*e+2)**2)+1)/2,easeInBack:e=>_T*e*e*e-hT*e*e,easeOutBack:e=>1+_T*(e-1)**3+hT*(e-1)**2,easeInOutBack:e=>e<.5?(2*e)**2*(7.189819*e-gT)/2:((2*e-2)**2*(3.5949095*(e*2-2)+gT)+2)/2,easeInElastic:e=>e===0?0:e===1?1:-(2**(10*e-10))*Math.sin((e*10-10.75)*vT),easeOutElastic:e=>e===0?0:e===1?1:2**(-10*e)*Math.sin((e*10-.75)*vT)+1,easeInOutElastic:e=>e===0?0:e===1?1:e<.5?-(2**(20*e-10)*Math.sin((20*e-11.125)*yT))/2:2**(-20*e+10)*Math.sin((20*e-11.125)*yT)/2+1,easeInBounce:e=>1-bT(1-e),easeOutBounce:bT,easeInOutBounce:e=>e<.5?(1-bT(1-2*e))/2:(1+bT(2*e-1))/2,steps:mT},ST=Symbol.for(`FluidValue.get`),CT=Symbol.for(`FluidValue.observers`),wT=e=>!!(e&&e[ST]),TT=e=>e&&e[ST]?e[ST]():e,ET=e=>e[CT]||null;function DT(e,t){e.eventObserved?e.eventObserved(t):e(t)}function OT(e,t){let n=e[CT];n&&n.forEach(e=>{DT(e,t)})}var kT=class{constructor(e){if(!e&&!(e=this.get))throw Error(`Unknown getter`);AT(this,e)}},AT=(e,t)=>NT(e,ST,t);function jT(e,t){if(e[ST]){let n=e[CT];n||NT(e,CT,n=new Set),n.has(t)||(n.add(t),e.observerAdded&&e.observerAdded(n.size,t))}return t}function MT(e,t){let n=e[CT];if(n&&n.has(t)){let r=n.size-1;r?n.delete(t):e[CT]=null,e.observerRemoved&&e.observerRemoved(r,t)}}var NT=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),PT=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,FT=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,IT=RegExp(`(${PT.source})(%|[a-z]+)`,`i`),LT=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,RT=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,zT=e=>{let[t,n]=BT(e);if(!t||Ew())return e;let r=window.getComputedStyle(document.documentElement).getPropertyValue(t);return r?r.trim():n&&n.startsWith(`--`)?window.getComputedStyle(document.documentElement).getPropertyValue(n)||e:n&&RT.test(n)?zT(n):n||e},BT=e=>{let t=RT.exec(e);if(!t)return[,];let[,n,r]=t;return[n,r]},VT,HT=(e,t,n,r,i)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(r)}, ${i})`,UT=e=>e.match(PT)??[],WT=e=>{VT||=Aw?RegExp(`(${Object.keys(Aw).join(`|`)})(?!\\w)`,`g`):/^\b$/;let t=e.output.map(e=>TT(e).replace(RT,zT).replace(FT,uT).replace(VT,uT)),n=t.map(e=>UT(e).map(Number)),r=n[0].map((e,t)=>n.map(e=>{if(!(t in e))throw Error(`The arity of each "output" value must be equal`);return e[t]})).map(t=>dT({...e,output:t})),i=e.range||[0,1],a=t.map(e=>UT(e)),o=a[0].map((e,t)=>{let n=a.map(e=>{let n=e[t],r=n.indexOf(`.`);return r===-1?0:n.length-r-1});return n.every(e=>e===n[0])&&n[0]>0?n[0]:null});return e=>{let n=i.indexOf(e);if(n!==-1)return t[n];let a=!IT.test(t[0])&&t.find(e=>IT.test(e))?.replace(PT,``),s=0;return t[0].replace(PT,()=>{let t=s++,n=r[t](e),i=o[t];return`${i==null?n:n.toFixed(i)}${a||``}`}).replace(LT,HT)}},GT=`react-spring: `,KT=e=>{let t=e,n=!1;if(typeof t!=`function`)throw TypeError(`${GT}once requires a function parameter`);return(...e)=>{n||=(t(...e),!0)}},qT=KT(console.warn);function JT(){qT(`${GT}The "interpolate" function is deprecated in v9 (use "to" instead)`)}var YT=KT(console.warn);function XT(){YT(`${GT}Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions`)}function ZT(e){return q.str(e)&&(e[0]==`#`||/\d/.test(e)||!Ew()&&RT.test(e)||e in(Aw||{}))}var QT=Ew()?W.useEffect:W.useLayoutEffect,$T=()=>{let e=(0,W.useRef)(!1);return QT(()=>(e.current=!0,()=>{e.current=!1}),[]),e};function eE(){let e=(0,W.useState)()[1],t=$T();return()=>{t.current&&e(Math.random())}}var tE=e=>(0,W.useEffect)(e,nE),nE=[];function rE(e){let t=(0,W.useRef)(void 0);return(0,W.useEffect)(()=>{t.current=e}),t.current}var iE=Symbol.for(`Animated:node`),aE=e=>!!e&&e[iE]===e,oE=e=>e&&e[iE],sE=(e,t)=>bw(e,iE,t),cE=e=>e&&e[iE]&&e[iE].getPayload(),lE=class{constructor(){sE(this,this)}getPayload(){return this.payload||[]}},uE=class e extends lE{constructor(e){super(),this._value=e,this.done=!0,this.durationProgress=0,q.num(this._value)&&(this.lastPosition=this._value)}static create(t){return new e(t)}getPayload(){return[this]}getValue(){return this._value}setValue(e,t){return q.num(e)&&(this.lastPosition=e,t&&(e=Math.round(e/t)*t,this.done&&(this.lastPosition=e))),this._value!==e&&(this._value=e,!0)}reset(){let{done:e}=this;this.done=!1,q.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,e&&(this.lastVelocity=null),this.v0=null)}},dE=class e extends uE{constructor(e){super(0),this._string=null,this._toString=dT({output:[e,e]})}static create(t){return new e(t)}getValue(){return this._string??=this._toString(this._value)}setValue(e){if(q.str(e)){if(e==this._string)return!1;this._string=e,this._value=1}else if(super.setValue(e))this._string=null;else return!1;return!0}reset(e){e&&(this._toString=dT({output:[this.getValue(),e]})),this._value=0,super.reset()}},fE={dependencies:null},pE=class extends lE{constructor(e){super(),this.source=e,this.setValue(e)}getValue(e){let t={};return Sw(this.source,(n,r)=>{aE(n)?t[r]=n.getValue(e):wT(n)?t[r]=TT(n):e||(t[r]=n)}),t}setValue(e){this.source=e,this.payload=this._makePayload(e)}reset(){this.payload&&J(this.payload,e=>e.reset())}_makePayload(e){if(e){let t=new Set;return Sw(e,this._addToPayload,t),Array.from(t)}}_addToPayload(e){fE.dependencies&&wT(e)&&fE.dependencies.add(e);let t=cE(e);t&&J(t,e=>this.add(e))}},mE=class e extends pE{constructor(e){super(e)}static create(t){return new e(t)}getValue(){return this.source.map(e=>e.getValue())}setValue(e){let t=this.getPayload();return e.length==t.length?t.map((t,n)=>t.setValue(e[n])).some(Boolean):(super.setValue(e.map(hE)),!0)}};function hE(e){return(ZT(e)?dE:uE).create(e)}function gE(e){let t=oE(e);return t?t.constructor:q.arr(e)?mE:ZT(e)?dE:uE}var _E=(e,t)=>{let n=!q.fun(e)||e.prototype&&e.prototype.isReactComponent;return(0,W.forwardRef)((r,i)=>{let a=(0,W.useRef)(null),o=n&&(0,W.useCallback)(e=>{a.current=bE(i,e)},[i]),[s,c]=yE(r,t),l=eE(),u=()=>{let e=a.current;(!n||e)&&(e?t.applyAnimatedValues(e,s.getValue(!0)):!1)===!1&&l()},d=new vE(u,c),f=(0,W.useRef)(void 0);QT(()=>(f.current=d,J(c,e=>jT(e,d)),()=>{f.current&&(J(f.current.deps,e=>MT(e,f.current)),K.cancel(f.current.update))})),(0,W.useEffect)(u,[]),tE(()=>()=>{let e=f.current;J(e.deps,t=>MT(t,e))});let p=t.getComponentProps(s.getValue());return W.createElement(e,{...p,ref:o})})},vE=class{constructor(e,t){this.update=e,this.deps=t}eventObserved(e){e.type==`change`&&K.write(this.update)}};function yE(e,t){let n=new Set;return fE.dependencies=n,e.style&&(e={...e,style:t.createAnimatedStyle(e.style)}),e=new pE(e),fE.dependencies=null,[e,n]}function bE(e,t){return e&&(q.fun(e)?e(t):e.current=t),t}var xE=Symbol.for(`AnimatedComponent`),SE=new WeakMap,CE=(e,{applyAnimatedValues:t=()=>!1,createAnimatedStyle:n=e=>new pE(e),getComponentProps:r=e=>e}={})=>{let i={applyAnimatedValues:t,createAnimatedStyle:n,getComponentProps:r},a=e=>{let t=wE(e)||`Anonymous`;if(q.str(e))e=a[e]||(a[e]=_E(e,i));else{let t=e[xE]??SE.get(e);if(!t){t=_E(e,i);try{e[xE]=t}catch{}SE.set(e,t)}e=t}return e.displayName=`Animated(${t})`,e};return Sw(e,(t,n)=>{q.arr(e)&&(n=wE(t)),a[n]=a(t)}),{animated:a}},wE=e=>q.str(e)?e:e&&q.str(e.displayName)?e.displayName:q.fun(e)&&e.name||null;function TE(e,...t){return q.fun(e)?e(...t):e}var EE=(e,t)=>e===!0||!!(t&&e&&(q.fun(e)?e(t):Cw(e).includes(t))),DE=(e,t)=>q.obj(e)?t&&e[t]:e,OE=(e,t)=>e.default===!0?e[t]:e.default?e.default[t]:void 0,kE=e=>e,AE=(e,t=kE)=>{let n=jE;e.default&&e.default!==!0&&(e=e.default,n=Object.keys(e));let r={};for(let i of n){let n=t(e[i],i);q.und(n)||(r[i]=n)}return r},jE=[`config`,`onProps`,`onStart`,`onChange`,`onPause`,`onResume`,`onRest`],ME={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function NE(e){let t={},n=0;if(Sw(e,(e,r)=>{ME[r]||(t[r]=e,n++)}),n)return t}function PE(e){let t=NE(e);if(t){let n={to:t};return Sw(e,(e,r)=>r in t||(n[r]=e)),n}return{...e}}function FE(e){let t=TT(e);return q.arr(t)?t.map(FE):ZT(t)?Dw.createStringInterpolator({range:[0,1],output:[t,t]})(1):t}function IE(e){for(let t in e)return!0;return!1}function LE(e){return q.fun(e)||q.arr(e)&&q.obj(e[0])}function RE(e,t){e.ref?.delete(e),t?.delete(e)}function zE(e,t){t&&e.ref!==t&&(e.ref?.delete(e),t.add(e),e.ref=t)}var BE={...{default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}}.default,mass:1,damping:1,easing:xT.linear,clamp:!1},VE=class{constructor(){this.velocity=0,Object.assign(this,BE)}};function HE(e,t,n){n&&(n={...n},UE(n,t),t={...n,...t}),UE(e,t),Object.assign(e,t);for(let t in BE)e[t]??(e[t]=BE[t]);let{frequency:r,damping:i}=e,{mass:a}=e;return q.und(r)||(r<.01&&(r=.01),i<0&&(i=0),e.tension=(2*Math.PI/r)**2*a,e.friction=4*Math.PI*i*a/r),e}function UE(e,t){if(!q.und(t.decay))e.duration=void 0;else{let n=!q.und(t.tension)||!q.und(t.friction);(n||!q.und(t.frequency)||!q.und(t.damping)||!q.und(t.mass))&&(e.duration=void 0,e.decay=void 0),n&&(e.frequency=void 0)}}var WE=[],GE=class{constructor(){this.changed=!1,this.values=WE,this.toValues=null,this.fromValues=WE,this.config=new VE,this.immediate=!1}};function KE(e,{key:t,props:n,defaultProps:r,state:i,actions:a}){return new Promise((o,s)=>{let c,l,u=EE(n.cancel??r?.cancel,t);if(u)p();else{q.und(n.pause)||(i.paused=EE(n.pause,t));let e=r?.pause;e!==!0&&(e=i.paused||EE(e,t)),c=TE(n.delay||0,t),e?(i.resumeQueue.add(f),a.pause()):(a.resume(),f())}function d(){i.resumeQueue.add(f),i.timeouts.delete(l),l.cancel(),c=l.time-K.now()}function f(){c>0&&!Dw.skipAnimation?(i.delayed=!0,l=K.setTimeout(p,c),i.pauseQueue.add(d),i.timeouts.add(l)):p()}function p(){i.delayed&&=!1,i.pauseQueue.delete(d),i.timeouts.delete(l),e<=(i.cancelId||0)&&(u=!0);try{a.start({...n,callId:e,cancel:u},o)}catch(e){s(e)}}})}var qE=(e,t)=>t.length==1?t[0]:t.some(e=>e.cancelled)?XE(e.get()):t.every(e=>e.noop)?JE(e.get()):YE(e.get(),t.every(e=>e.finished)),JE=e=>({value:e,noop:!0,finished:!0,cancelled:!1}),YE=(e,t,n=!1)=>({value:e,finished:t,cancelled:n}),XE=e=>({value:e,cancelled:!0,finished:!1});function ZE(e,t,n,r){let{callId:i,parentId:a,onRest:o}=t,{asyncTo:s,promise:c}=n;return!a&&e===s&&!t.reset?c:n.promise=(async()=>{n.asyncId=i,n.asyncTo=e;let l=AE(t,(e,t)=>t===`onRest`?void 0:e),u,d,f=new Promise((e,t)=>(u=e,d=t)),p=e=>{let t=i<=(n.cancelId||0)&&XE(r)||i!==n.asyncId&&YE(r,!1);if(t)throw e.result=t,d(e),e},m=0,h=(e,t)=>{let a=new $E,o=new eD;return(async()=>{p(a);let s=q.obj(e)?{...e}:{...t,to:e};if(s.parentId=i,Sw(l,(e,t)=>{q.und(s[t])&&(s[t]=e)}),Dw.skipAnimation){if(++m>1024)throw QE(n),o.result=YE(r,!1),d(o),o;return s.immediate=!0,await r.start(s)}let c=await r.start(s);return p(a),n.paused&&await new Promise(e=>{n.resumeQueue.add(e)}),c})()},g;try{let t;t=q.arr(e)?(async e=>{for(let t of e)await h(t)})(e):Promise.resolve(e(h,r.stop.bind(r))),await Promise.all([t.then(u),f]),g=YE(r.get(),!0,!1)}catch(e){if(e instanceof $E)g=e.result;else if(e instanceof eD)g=e.result;else throw e}finally{i==n.asyncId&&(n.asyncId=a,n.asyncTo=a?s:void 0,n.promise=a?c:void 0)}return q.fun(o)&&K.batchedUpdates(()=>{o(g,r,r.item)}),g})()}function QE(e,t){ww(e.timeouts,e=>e.cancel()),e.pauseQueue.clear(),e.resumeQueue.clear(),e.asyncId=e.asyncTo=e.promise=void 0,t&&(e.cancelId=t)}var $E=class extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise.")}},eD=class extends Error{constructor(){super(`SkipAnimationSignal`)}},tD=e=>e instanceof rD,nD=1,rD=class extends kT{constructor(...e){super(...e),this.id=nD++,this._priority=0}get priority(){return this._priority}set priority(e){this._priority!=e&&(this._priority=e,this._onPriorityChange(e))}get(){let e=oE(this);return e&&e.getValue()}to(...e){return Dw.to(this,e)}interpolate(...e){return JT(),Dw.to(this,e)}toJSON(){return this.get()}observerAdded(e){e==1&&this._attach()}observerRemoved(e){e==0&&this._detach()}_attach(){}_detach(){}_onChange(e,t=!1){OT(this,{type:`change`,parent:this,value:e,idle:t})}_onPriorityChange(e){this.idle||Rw.sort(this),OT(this,{type:`priority`,parent:this,priority:e})}},iD=Symbol.for(`SpringPhase`),aD=1,oD=2,sD=4,cD=e=>(e[iD]&aD)>0,lD=e=>(e[iD]&oD)>0,uD=e=>(e[iD]&sD)>0,dD=(e,t)=>t?e[iD]|=3:e[iD]&=-3,fD=(e,t)=>t?e[iD]|=sD:e[iD]&=-5,pD=class extends rD{constructor(e,t){if(super(),this.animation=new GE,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!q.und(e)||!q.und(t)){let n=q.obj(e)?{...e}:{...t,from:e};q.und(n.default)&&(n.default=!0),this.start(n)}}get idle(){return!(lD(this)||this._state.asyncTo)||uD(this)}get goal(){return TT(this.animation.to)}get velocity(){let e=oE(this);return e instanceof uE?e.lastVelocity||0:e.getPayload().map(e=>e.lastVelocity||0)}get hasAnimated(){return cD(this)}get isAnimating(){return lD(this)}get isPaused(){return uD(this)}get isDelayed(){return this._state.delayed}advance(e){let t=!0,n=!1,r=this.animation,{toValues:i}=r,{config:a}=r,o=cE(r.to);!o&&wT(r.to)&&(i=Cw(TT(r.to))),r.values.forEach((s,c)=>{if(s.done)return;let l=s.constructor==dE?1:o?o[c].lastPosition:i[c],u=r.immediate,d=l;if(!u){if(d=s.lastPosition,a.tension<=0){s.done=!0;return}let t=s.elapsedTime+=e,n=r.fromValues[c],i=s.v0==null?s.v0=q.arr(a.velocity)?a.velocity[c]:a.velocity:s.v0,o,f=a.precision||(n==l?.005:Math.max(Math.max(Math.abs(l),Math.abs(n),1)*2**-52,Math.min(1,Math.abs(l-n)*.001)));if(!q.und(a.duration)){let r=1;a.duration>0&&(this._memoizedDuration!==a.duration&&(this._memoizedDuration=a.duration,s.durationProgress>0&&(s.elapsedTime=a.duration*s.durationProgress,t=s.elapsedTime+=e)),r=(a.progress||0)+t/this._memoizedDuration,r=r>1?1:r<0?0:r,s.durationProgress=r),d=n+a.easing(r)*(l-n),o=(d-s.lastPosition)/e,u=r==1}else if(a.decay){let e=a.decay===!0?.998:a.decay,r=Math.exp(-(1-e)*t);d=n+i/(1-e)*(1-r),u=Math.abs(s.lastPosition-d)<=f,o=i*r}else{o=s.lastVelocity==null?i:s.lastVelocity;let t=a.restVelocity||f/10,r=a.clamp?0:a.bounce,c=!q.und(r),p=n==l?s.v0>0:n<l,m,h=!1,g=Math.ceil(e/1);for(let e=0;e<g&&(m=Math.abs(o)>t,!(!m&&(u=Math.abs(l-d)<=f,u)));++e){c&&(h=d==l||d>l==p,h&&(o=-o*r,d=l));let e=(-a.tension*1e-6*(d-l)+-a.friction*.001*o)/a.mass;o+=e*1,d+=o*1}}s.lastVelocity=o,Number.isNaN(d)&&(console.warn(`Got NaN while animating:`,this),u=!0)}o&&!o[c].done&&(u=!1),u?s.done=!0:t=!1,s.setValue(d,a.round)&&(n=!0)});let s=oE(this),c=s.getValue();if(t){let e=TT(r.to);(c!==e||n)&&!a.decay?(s.setValue(e),this._onChange(e)):n&&a.decay&&this._onChange(c),this._stop()}else n&&this._onChange(c)}set(e){return K.batchedUpdates(()=>{this._stop(),this._focus(e),this._set(e)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(lD(this)){let{to:e,config:t}=this.animation;K.batchedUpdates(()=>{this._onStart(),t.decay||this._set(e,!1),this._stop()})}return this}update(e){return(this.queue||=[]).push(e),this}start(e,t){let n;return q.und(e)?(n=this.queue||[],this.queue=[]):n=[q.obj(e)?e:{...t,to:e}],Promise.all(n.map(e=>this._update(e))).then(e=>qE(this,e))}stop(e){let{to:t}=this.animation;return q.und(t)||this._focus(this.get()),QE(this._state,e&&this._lastCallId),K.batchedUpdates(()=>this._stop(t,e)),this}reset(){this._update({reset:!0})}eventObserved(e){e.type==`change`?this._start():e.type==`priority`&&(this.priority=e.priority+1)}_prepareNode(e){let t=this.key||``,{to:n,from:r}=e;n=q.obj(n)?n[t]:n,(n==null||LE(n))&&(n=void 0),r=q.obj(r)?r[t]:r,r??=void 0;let i={to:n,from:r};return cD(this)||(e.reverse&&([n,r]=[r,n]),r=TT(r),q.und(r)?oE(this)||this._set(n):this._set(r)),i}_update({...e},t){let{key:n,defaultProps:r}=this;e.default&&Object.assign(r,AE(e,(e,t)=>/^on/.test(t)?DE(e,n):e)),yD(this,e,`onProps`),bD(this,`onProps`,e,this);let i=this._prepareNode(e);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");let a=this._state;return KE(++this._lastCallId,{key:n,props:e,defaultProps:r,state:a,actions:{pause:()=>{uD(this)||(fD(this,!0),Tw(a.pauseQueue),bD(this,`onPause`,YE(this,mD(this,this.animation.to)),this))},resume:()=>{uD(this)&&(fD(this,!1),lD(this)&&this._resume(),Tw(a.resumeQueue),bD(this,`onResume`,YE(this,mD(this,this.animation.to)),this))},start:this._merge.bind(this,i)}}).then(n=>{if(e.loop&&n.finished&&!(t&&n.noop)){let t=hD(e);if(t)return this._update(t,!0)}return n})}_merge(e,t,n){if(t.cancel)return this.stop(!0),n(XE(this));let r=!q.und(e.to),i=!q.und(e.from);if(r||i){if(t.callId>this._lastToId)this._lastToId=t.callId;else return n(XE(this))}let{key:a,defaultProps:o,animation:s}=this,{to:c,from:l}=s,{to:u=c,from:d=l}=e;i&&!r&&(!t.default||q.und(u))&&(u=d),t.reverse&&([u,d]=[d,u]);let f=!xw(d,l);f&&(s.from=d),d=TT(d);let p=!xw(u,c);p&&this._focus(u);let m=LE(t.to),{config:h}=s,{decay:g,velocity:_}=h;(r||i)&&!h.decay&&(h.velocity=0),t.config&&!m&&HE(h,TE(t.config,a),t.config===o.config?void 0:TE(o.config,a));let v=oE(this);if(!v||q.und(u))return n(YE(this,!0));let y=q.und(t.reset)?i&&!t.default:!q.und(d)&&EE(t.reset,a),b=y?d:this.get(),x=FE(u),S=q.num(x)||q.arr(x)||ZT(x),C=!m&&(!S||EE(o.immediate||t.immediate,a));if(p){let e=gE(u);if(e!==v.constructor){if(C)v=this._set(x);else throw Error(`Cannot animate between ${v.constructor.name} and ${e.name}, as the "to" prop suggests`)}}let w=v.constructor,T=wT(u),E=!1;if(!T){let e=y||!cD(this)&&f;(p||e)&&(E=xw(FE(b),x),T=!E),(!xw(s.immediate,C)&&!C||!xw(h.decay,g)||!xw(h.velocity,_))&&(T=!0)}if(E&&lD(this)&&(s.changed&&!y?T=!0:T||this._stop(c)),!m&&((T||wT(c))&&(s.values=v.getPayload(),s.toValues=wT(u)?null:w==dE?[1]:Cw(x)),s.immediate!=C&&(s.immediate=C,!C&&!y&&this._set(c)),T)){let{onRest:e}=s;J(vD,e=>yD(this,t,e));let r=YE(this,mD(this,c));Tw(this._pendingCalls,r),this._pendingCalls.add(n),s.changed&&K.batchedUpdates(()=>{s.changed=!y,e?.(r,this),y?TE(o.onRest,r):s.onStart?.(r,this)})}y&&this._set(b),m?n(ZE(t.to,t,this._state,this)):T?this._start():lD(this)&&!p?this._pendingCalls.add(n):n(JE(b))}_focus(e){let t=this.animation;e!==t.to&&(ET(this)&&this._detach(),t.to=e,ET(this)&&this._attach())}_attach(){let e=0,{to:t}=this.animation;wT(t)&&(jT(t,this),tD(t)&&(e=t.priority+1)),this.priority=e}_detach(){let{to:e}=this.animation;wT(e)&&MT(e,this)}_set(e,t=!0){let n=TT(e);if(!q.und(n)){let e=oE(this);if(!e||!xw(n,e.getValue())){let r=gE(n);!e||e.constructor!=r?sE(this,r.create(n)):e.setValue(n),e&&K.batchedUpdates(()=>{this._onChange(n,t)})}}return oE(this)}_onStart(){let e=this.animation;e.changed||(e.changed=!0,bD(this,`onStart`,YE(this,mD(this,e.to)),this))}_onChange(e,t){let n=YE(e,!1);t||(this._onStart(),TE(this.animation.onChange,n,this)),TE(this.defaultProps.onChange,n,this),super._onChange(e,t)}_start(){let e=this.animation;oE(this).reset(TT(e.to)),e.immediate||(e.fromValues=e.values.map(e=>e.lastPosition)),lD(this)||(dD(this,!0),uD(this)||this._resume())}_resume(){Dw.skipAnimation?this.finish():Rw.start(this)}_stop(e,t){if(lD(this)){dD(this,!1);let n=this.animation;J(n.values,e=>{e.done=!0}),n.toValues&&(n.onChange=n.onPause=n.onResume=void 0),OT(this,{type:`idle`,parent:this});let r=t?XE(this.get()):YE(this.get(),mD(this,e??n.to));Tw(this._pendingCalls,r),n.changed=!1,bD(this,`onRest`,r,this)}}};function mD(e,t){let n=FE(t);return xw(FE(e.get()),n)}function hD(e,t=e.loop,n=e.to){let r=TE(t);if(r){let i=r!==!0&&PE(r),a=(i||e).reverse,o=!i||i.reset;return gD({...e,loop:t,default:!1,pause:void 0,to:!a||LE(n)?n:void 0,from:o?e.from:void 0,reset:o,...i})}}function gD(e){let{to:t,from:n}=e=PE(e),r=new Set;return q.obj(t)&&_D(t,r),q.obj(n)&&_D(n,r),e.keys=r.size?Array.from(r):null,e}function _D(e,t){Sw(e,(e,n)=>e!=null&&t.add(n))}var vD=[`onStart`,`onRest`,`onChange`,`onPause`,`onResume`];function yD(e,t,n){e.animation[n]=t[n]===OE(t,n)?void 0:DE(t[n],e.key)}function bD(e,t,...n){e.animation[t]?.(...n),e.defaultProps[t]?.(...n)}var xD=[`onStart`,`onChange`,`onRest`],SD=1,CD=class{constructor(e,t){this.id=SD++,this.springs={},this.queue=[],this._lastAsyncId=0,this._lastLoopId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),t&&(this._flush=t),e&&this.start({default:!0,...e})}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(e=>e.idle&&!e.isDelayed&&!e.isPaused)}get item(){return this._item}set item(e){this._item=e}get(){let e={};return this.each((t,n)=>e[n]=t.get()),e}set(e){for(let t in e){let n=e[t];q.und(n)||this.springs[t].set(n)}}update(e){return e&&this.queue.push(gD(e)),this}start(e){let{queue:t}=this;return e?t=Cw(e).map(gD):this.queue=[],this._flush?this._flush(this,t):(AD(this,t),wD(this,t))}stop(e,t){if(e!==!!e&&(t=e),t){let n=this.springs;J(Cw(t),t=>n[t].stop(!!e))}else QE(this._state,this._lastAsyncId),this.each(t=>t.stop(!!e));return this}pause(e){if(q.und(e))this.start({pause:!0});else{let t=this.springs;J(Cw(e),e=>t[e].pause())}return this}resume(e){if(q.und(e))this.start({pause:!1});else{let t=this.springs;J(Cw(e),e=>t[e].resume())}return this}each(e){Sw(this.springs,e)}onLoopReset(e){let t=this._onLoopReset??=new Set;return t.add(e),()=>{t.delete(e)}}_onFrame(){let{onStart:e,onChange:t,onRest:n}=this._events,r=this._active.size>0,i=this._changed.size>0;(r&&!this._started||i&&!this._started)&&(this._started=!0,ww(e,([e,t])=>{t.value=this.get(),e(t,this,this._item)}));let a=!r&&this._started,o=i||a&&n.size?this.get():null;i&&t.size&&ww(t,([e,t])=>{t.value=o,e(t,this,this._item)}),a&&(this._started=!1,ww(n,([e,t])=>{t.value=o,e(t,this,this._item)}))}eventObserved(e){if(e.type==`change`)this._changed.add(e.parent),e.idle||this._active.add(e.parent);else if(e.type==`idle`)this._active.delete(e.parent);else return;K.onFrame(this._onFrame)}};function wD(e,t){return Promise.all(t.map(t=>TD(e,t))).then(t=>qE(e,t))}async function TD(e,t,n){let{keys:r,to:i,from:a,loop:o,onRest:s,onResolve:c}=t,l=q.obj(t.default)&&t.default;o&&(t.loop=!1);let u=t,d=!n&&!u.parentId&&`loop`in t?++e._lastLoopId:n?u.loopId:e._lastLoopId;i===!1&&(t.to=null),a===!1&&(t.from=null);let f=q.arr(i)||q.fun(i)?i:void 0;f?(t.to=void 0,t.onRest=void 0,l&&(l.onRest=void 0)):J(xD,n=>{let r=t[n];if(q.fun(r)){let i=e._events[n];t[n]=(({finished:e,cancelled:t})=>{let n=i.get(r);n?(e||(n.finished=!1),t&&(n.cancelled=!0)):i.set(r,{value:null,finished:e||!1,cancelled:t||!1})}),l&&(l[n]=t[n])}});let p=e._state;t.pause===!p.paused?(p.paused=t.pause,Tw(t.pause?p.pauseQueue:p.resumeQueue)):p.paused&&(t.pause=!0);let m=(r||Object.keys(e.springs)).map(n=>e.springs[n].start(t)),h=t.cancel===!0||OE(t,`cancel`)===!0;(f||h&&p.asyncId)&&m.push(KE(++e._lastAsyncId,{props:t,state:p,actions:{pause:yw,resume:yw,start(t,n){h?(QE(p,e._lastAsyncId),n(XE(e))):(t.onRest=s,n(ZE(f,t,p,e)))}}})),p.paused&&await new Promise(e=>{p.resumeQueue.add(e)});let g=qE(e,await Promise.all(m));if(o&&g.finished&&!(n&&g.noop)&&d===e._lastLoopId){let n=hD(t,o,i);if(n)return n.loopId=d,e._onLoopReset?.forEach(e=>e()),AD(e,[n]),TD(e,n,!0)}return c&&K.batchedUpdates(()=>c(g,e,e.item)),g}function ED(e,t){let n={...e.springs};return t&&J(Cw(t),e=>{q.und(e.keys)&&(e=gD(e)),q.obj(e.to)||(e={...e,to:void 0}),kD(n,e,e=>OD(e))}),DD(e,n),n}function DD(e,t){Sw(t,(t,n)=>{e.springs[n]||(e.springs[n]=t,jT(t,e))})}function OD(e,t){let n=new pD;return n.key=e,t&&jT(n,t),n}function kD(e,t,n){t.keys&&J(t.keys,r=>{(e[r]||(e[r]=n(r)))._prepareNode(t)})}function AD(e,t){J(t,t=>{kD(e.springs,t,t=>OD(t,e))})}var jD=W.createContext({pause:!1,immediate:!1}),MD=()=>{let e=[],t=function(t){XT();let r=[];return J(e,(e,i)=>{if(q.und(t))r.push(e.start());else{let a=n(t,e,i);a&&r.push(e.start(a))}}),r};t.current=e,t.add=function(t){e.includes(t)||e.push(t)},t.delete=function(t){let n=e.indexOf(t);~n&&e.splice(n,1)},t.pause=function(){return J(e,e=>e.pause(...arguments)),this},t.resume=function(){return J(e,e=>e.resume(...arguments)),this},t.set=function(t){J(e,(e,n)=>{let r=q.fun(t)?t(n,e):t;r&&e.set(r)})},t.start=function(t){let n=[];return J(e,(e,r)=>{if(q.und(t))n.push(e.start());else{let i=this._getProps(t,e,r);i&&n.push(e.start(i))}}),n},t.stop=function(){return J(e,e=>e.stop(...arguments)),this},t.update=function(t){return J(e,(e,n)=>e.update(this._getProps(t,e,n))),this};let n=function(e,t,n){return q.fun(e)?e(n,t):e};return t._getProps=n,t};function ND(e,t,n){let r=q.fun(t)&&t,{reset:i,sort:a,trail:o=0,reverse:s=!1,expires:c=!0,exitBeforeEnter:l=!1,onDestroyed:u,ref:d,config:f}=r?r():t,p=(0,W.useMemo)(()=>r||arguments.length==3?MD():void 0,[]),m=Cw(e),h=[],g=(0,W.useRef)(null),_=i?null:g.current;QT(()=>{g.current=h}),tE(()=>(J(h,e=>{p?.add(e.ctrl),e.ctrl.ref=void 0}),()=>{J(g.current,e=>{e.expired&&clearTimeout(e.expirationId),RE(e.ctrl,p),e.ctrl.stop(!0)})}));let v=FD(m,r?r():t,_),y=i&&g.current||[];QT(()=>J(y,({ctrl:e,item:t,key:n})=>{RE(e,p),TE(u,t,n)}));let b=[];if(_&&J(_,(e,t)=>{e.expired?(clearTimeout(e.expirationId),y.push(e)):(t=b[t]=v.indexOf(e.key),~t&&(h[t]=e))}),J(m,(e,t)=>{h[t]||(h[t]={key:v[t],item:e,phase:`mount`,ctrl:new CD},h[t].ctrl.item=e)}),b.length){let e=-1,{leave:n}=r?r():t;J(b,(t,r)=>{let i=_[r];~t?(e=h.indexOf(i),h[e]={...i,item:m[t]}):n&&h.splice(++e,0,i)})}q.fun(a)&&h.sort((e,t)=>a(e.item,t.item));let x=-o,S=[],C=eE(),w=AE(t),T=new Map,E=(0,W.useRef)(new Map),D=(0,W.useRef)(!1);if(J(h,(e,n)=>{let i=e.key,a=e.phase,s=r?r():t,u,p,m=TE(s.delay||0,i);if(a==`mount`)u=s.enter,p=`enter`;else{let e=v.indexOf(i)<0;if(a!=`leave`){if(e)u=s.leave,p=`leave`;else if(u=s.update)p=`update`;else return}else if(!e)u=s.enter,p=`enter`;else return}if(u=TE(u,e.item,n),u=q.obj(u)?PE(u):{to:u},!u.config){let t=f||w.config;u.config=TE(t,e.item,n,p)}x+=o;let h={...w,delay:m+x,ref:d,immediate:s.immediate,reset:!1,...u};if(p==`enter`&&q.und(h.from)){let i=r?r():t;h.from=TE(q.und(i.initial)||_?i.from:i.initial,e.item,n)}let{onResolve:y}=h;h.onResolve=e=>{TE(y,e);let t=g.current,n=t.find(e=>e.key===i);if(n&&!(e.cancelled&&n.phase!=`update`)&&n.ctrl.idle){let e=t.every(e=>e.ctrl.idle);if(n.phase==`leave`){E.current.delete(n);let t=TE(c,n.item);if(t!==!1){let r=t===!0?0:t;if(n.expired=!0,!e&&r>0){r<=2147483647&&(n.expirationId=setTimeout(C,r));return}}}e&&t.some(e=>e.expired)&&(l&&(D.current=!0),C())}};let b=ED(e.ctrl,h);S.push({payload:h,propsDelay:m}),p===`leave`&&l?E.current.set(e,{phase:p,springs:b,payload:h}):T.set(e,{phase:p,springs:b,payload:h})}),s&&o){let e=S.length;J(S,({payload:t,propsDelay:n},r)=>{t.delay=n+(e-1-r)*o})}let O=(0,W.useContext)(jD),ee=O!==rE(O)&&IE(O);QT(()=>{ee&&J(h,e=>{e.ctrl.start({default:O})})},[O]),J(T,(e,t)=>{if(E.current.size){let e=h.findIndex(e=>e.key===t.key);h.splice(e,1)}}),QT(()=>{J(E.current.size?E.current:T,({phase:e,payload:t},n)=>{let{ctrl:r}=n;n.phase=e,p?.add(r),ee&&e==`enter`&&r.start({default:O}),t&&(zE(r,t.ref),r.ref&&!D.current?r.update(t):(r.start(t),D.current&&=!1))})},i?void 0:n);let te=e=>W.createElement(W.Fragment,null,h.map((t,n)=>{let r=T.get(t)||E.current.get(t),{springs:i}=r||t.ctrl,a=r?{...t,phase:r.phase}:t,o=e({...i},t.item,a,n),s=q.str(t.key)||q.num(t.key)?t.key:t.ctrl.id,c=o?.props??{},l=c?.ref;return o&&o.type?W.createElement(o.type,{...c,key:s,ref:l}):o}));return p?[te,p]:te}var PD=1;function FD(e,{key:t,keys:n=t},r){if(n===null){let t=new Set;return e.map(e=>{let n=r&&r.find(n=>n.item===e&&n.phase!==`leave`&&!t.has(n));return n?(t.add(n),n.key):PD++})}return q.und(n)?e:q.fun(n)?e.map(n):Cw(n)}var ID=class extends rD{constructor(e,t){super(),this.source=e,this.idle=!0,this._active=new Set,this.calc=dT(...t);let n=this._get(),r=gE(n);sE(this,r.create(n))}advance(e){let t=this._get();xw(t,this.get())||(oE(this).setValue(t),this._onChange(t,this.idle)),!this.idle&&RD(this._active)&&zD(this)}_get(){let e=q.arr(this.source)?this.source.map(TT):Cw(TT(this.source));return this.calc(...e)}_start(){this.idle&&!RD(this._active)&&(this.idle=!1,J(cE(this),e=>{e.done=!1}),Dw.skipAnimation?(K.batchedUpdates(()=>this.advance()),zD(this)):Rw.start(this))}_attach(){let e=1;J(Cw(this.source),t=>{wT(t)&&jT(t,this),tD(t)&&(t.idle||this._active.add(t),e=Math.max(e,t.priority+1))}),this.priority=e,this._start()}_detach(){J(Cw(this.source),e=>{wT(e)&&MT(e,this)}),this._active.clear(),zD(this)}eventObserved(e){e.type==`change`?e.idle?this.advance():(this._active.add(e.parent),this._start()):e.type==`idle`?this._active.delete(e.parent):e.type==`priority`&&(this.priority=Cw(this.source).reduce((e,t)=>Math.max(e,(tD(t)?t.priority:0)+1),0))}};function LD(e){return e.idle!==!1}function RD(e){return!e.size||Array.from(e).every(LD)}function zD(e){e.idle||(e.idle=!0,J(cE(e),e=>{e.done=!0}),OT(e,{type:`idle`,parent:e}))}Dw.assign({createStringInterpolator:WT,to:(e,t)=>new ID(e,t)}),Rw.advance;var BD=/^--/;function VD(e,t){return t==null||typeof t==`boolean`||t===``?``:typeof t==`number`&&t!==0&&!BD.test(e)&&!(WD.hasOwnProperty(e)&&WD[e])?t+`px`:(``+t).trim()}var HD={};function UD(e,t){if(!e.nodeType||!e.setAttribute||!e.removeAttribute)return!1;let n=e.nodeName===`filter`||e.parentNode&&e.parentNode.nodeName===`filter`,{className:r,style:i,children:a,scrollTop:o,scrollLeft:s,viewBox:c,...l}=t,u=Object.values(l),d=Object.keys(l).map(t=>n||e.hasAttribute(t)?t:HD[t]||(HD[t]=t.replace(/([A-Z])/g,e=>`-`+e.toLowerCase())));t.hasOwnProperty(`children`)&&(e.textContent=a);for(let t in i)if(i.hasOwnProperty(t)){let n=VD(t,i[t]);BD.test(t)?e.style.setProperty(t,n):e.style[t]=n}d.forEach((t,n)=>{let r=u[n];r===void 0?e.removeAttribute(t):e.setAttribute(t,r)}),t.hasOwnProperty(`className`)&&(r===void 0?e.removeAttribute(`class`):e.className=r),o!==void 0&&(e.scrollTop=o),s!==void 0&&(e.scrollLeft=s),t.hasOwnProperty(`viewBox`)&&(c===void 0?e.removeAttribute(`viewBox`):e.setAttribute(`viewBox`,c))}var WD={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},GD=(e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1),KD=[`Webkit`,`Ms`,`Moz`,`O`];WD=Object.keys(WD).reduce((e,t)=>(KD.forEach(n=>e[GD(n,t)]=e[t]),e),WD);var qD=/^(matrix3d|matrix|translate3d|translate[XYZ]?|scale3d|scale[XYZ]?|rotate3d|rotate[XYZ]?|skew[XY]?)$/,JD=/^(translate)/,YD=/^(rotate|skew)/,XD=(e,t)=>q.num(e)&&e!==0?e+t:e,ZD=(e,t)=>q.arr(e)?e.every(e=>ZD(e,t)):q.num(e)?e===t:parseFloat(e)===t,QD=class extends pE{constructor({x:e,y:t,z:n,...r}){let i=[],a=[];(e||t||n)&&(i.push([e||0,t||0,n||0]),a.push(e=>[`translate3d(${e.map(e=>XD(e,`px`)).join(`,`)})`,ZD(e,0)])),Sw(r,(e,t)=>{if(t===`transform`)i.push([e||``]),a.push(e=>[e,e===``]);else if(qD.test(t)){if(delete r[t],q.und(e))return;let n=JD.test(t)?`px`:YD.test(t)?`deg`:``;i.push(Cw(e)),a.push(t===`rotate3d`?([e,t,r,i])=>[`rotate3d(${e},${t},${r},${XD(i,n)})`,ZD(i,0)]:e=>[`${t}(${e.map(e=>XD(e,n)).join(`,`)})`,ZD(e,+!!t.startsWith(`scale`))])}}),i.length&&(r.transform=new $D(i,a)),super(r)}},$D=class extends kT{constructor(e,t){super(),this.inputs=e,this.transforms=t,this._value=null}get(){return this._value||=this._get()}_get(){let e=``,t=!0;return J(this.inputs,(n,r)=>{let i=TT(n[0]),[a,o]=this.transforms[r](q.arr(i)?i:n.map(TT));e+=` `+a,t&&=o}),t?`none`:e}observerAdded(e){e==1&&J(this.inputs,e=>J(e,e=>wT(e)&&jT(e,this)))}observerRemoved(e){e==0&&J(this.inputs,e=>J(e,e=>wT(e)&&MT(e,this)))}eventObserved(e){e.type==`change`&&(this._value=null),OT(this,e)}},eO=`a.abbr.address.area.article.aside.audio.b.base.bdi.bdo.big.blockquote.body.br.button.canvas.caption.cite.code.col.colgroup.data.datalist.dd.del.details.dfn.dialog.div.dl.dt.em.embed.fieldset.figcaption.figure.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.iframe.img.input.ins.kbd.keygen.label.legend.li.link.main.map.mark.menu.menuitem.meta.meter.nav.noscript.object.ol.optgroup.option.output.p.param.picture.pre.progress.q.rp.rt.ruby.s.samp.script.section.select.small.source.span.strong.style.sub.summary.sup.table.tbody.td.textarea.tfoot.th.thead.time.title.tr.track.u.ul.var.video.wbr.circle.clipPath.defs.ellipse.foreignObject.g.image.line.linearGradient.mask.path.pattern.polygon.polyline.radialGradient.rect.stop.svg.text.tspan`.split(`.`);Dw.assign({batchedUpdates:jC.unstable_batchedUpdates,createStringInterpolator:WT,colors:Gw});var tO=CE(eO,{applyAnimatedValues:UD,createAnimatedStyle:e=>new QD(e),getComponentProps:({scrollTop:e,scrollLeft:t,...n})=>n}).animated,nO=e=>(0,G.jsx)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`})}),rO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`})]}),iO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M2.25638 6.33803C1.50583 4.83684 2.49311 3 4.05053 3V4.7747C3.72017 4.7747 3.51074 5.16433 3.66995 5.48277L2.25638 6.33803Z`,fill:`#9489DB`})]}),aO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`})]}),oO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3ZM8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317Z`,fill:`#9489DB`})]}),sO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M15.7489 3C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M20.9495 4.7747H15.7489V3H20.9495C22.5069 3 23.4942 4.83684 22.7436 6.33803L21.3301 5.48277C21.4893 5.16433 21.2798 4.7747 20.9495 4.7747Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`})]}),cO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M17.9964 15.833L22.7436 6.33803L21.3301 5.48277L16.5828 14.9778L17.9964 15.833Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M2.25638 6.33803C1.50583 4.83684 2.49311 3 4.05053 3V4.7747C3.72017 4.7747 3.51074 5.16433 3.66995 5.48277L2.25638 6.33803ZM6.93059 15.687L8.34416 14.8317C8.51289 15.1692 8.95664 15.1596 9.11322 14.8151L10.519 15.687C9.75015 17.2339 7.71306 17.252 6.93059 15.687ZM15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747H20.9495C21.2798 4.7747 21.4893 5.16433 21.3301 5.48277L22.7436 6.33803C23.4942 4.83684 22.5069 3 20.9495 3H15.7489C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882Z`,fill:`#9489DB`})]}),lO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M14.4244 15.865C15.2179 17.3926 17.2257 17.3746 17.9964 15.833L16.5828 14.9778C16.4193 15.3047 15.9934 15.3086 15.8251 14.9846L14.4244 15.865Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.0406 13.2011L14.4244 15.865L15.8251 14.9846L14.4413 12.3206L13.0406 13.2011Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.3408 11.9904C12.954 12.2335 12.8196 12.7756 13.0406 13.2011L14.4413 12.3206C14.2203 11.8951 13.7276 11.7473 13.3408 11.9904Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M15.7489 3C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M20.9495 3H15.7489V4.7747H20.9495V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M22.7436 6.33803C23.4942 4.83684 22.5069 3 20.9495 3V4.7747C21.2798 4.7747 21.4893 5.16433 21.3301 5.48277L22.7436 6.33803Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M17.9964 15.833L22.7436 6.33803L21.3301 5.48277L16.5828 14.9778L17.9964 15.833Z`,fill:`#9489DB`})]}),uO=()=>{let e=[W.createElement(nO,null),W.createElement(rO,null),W.createElement(iO,null),W.createElement(aO,null),W.createElement(oO,null),W.createElement(sO,null),W.createElement(cO,null),W.createElement(lO,null)],[t,n]=(0,W.useState)(!0),[r,i]=(0,W.useState)(!0);(0,W.useEffect)(()=>()=>{i(!1)},[]);let a=ND(e,{loop:t,from:{opacity:0},enter:{opacity:1},trail:100,config:{duration:1500},onRest:()=>r&&n(!t)})((e,t)=>W.createElement(tO.div,{style:{...e,gridRowStart:1,gridColumnStart:1}},t));return W.createElement(`div`,{style:{display:`grid`,gridTemplateColumns:`1fr`}},a)},dO=e=>(0,G.jsx)(`svg`,{width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24ZM18.8485 9.24853C19.3172 8.7799 19.3172 8.0201 18.8485 7.55147C18.3799 7.08284 17.6201 7.08284 17.1515 7.55147L9.6 15.1029L6.84853 12.3515C6.3799 11.8828 5.6201 11.8828 5.15147 12.3515C4.68284 12.8201 4.68284 13.5799 5.15147 14.0485L9.6 18.4971L18.8485 9.24853Z`,fill:`#5FCA7D`})}),fO=e=>(0,G.jsx)(`svg`,{width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M21.4286 12C21.4286 17.2073 17.2073 21.4286 12 21.4286C6.79274 21.4286 2.57143 17.2073 2.57143 12C2.57143 6.79274 6.79274 2.57143 12 2.57143C17.2073 2.57143 21.4286 6.79274 21.4286 12ZM24 12C24 18.6274 18.6274 24 12 24C5.37258 24 0 18.6274 0 12C0 5.37258 5.37258 0 12 0C18.6274 0 24 5.37258 24 12ZM7.37141 8.66656L10.7049 12.0001L7.37144 15.3336L8.58362 16.5458L11.9171 13.2123L15.2506 16.5458L16.4628 15.3336L13.1293 12.0001L16.4628 8.66656L15.2506 7.45438L11.9171 10.7879L8.58359 7.45438L7.37141 8.66656Z`,fill:`#E6635A`})}),pO=e=>(0,G.jsx)(`svg`,{width:14,height:14,viewBox:`0 0 14 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M12.5 7C12.5 10.0376 10.0376 12.5 7 12.5C3.96243 12.5 1.5 10.0376 1.5 7C1.5 3.96243 3.96243 1.5 7 1.5C10.0376 1.5 12.5 3.96243 12.5 7ZM14 7C14 10.866 10.866 14 7 14C3.13401 14 0 10.866 0 7C0 3.13401 3.13401 0 7 0C10.866 0 14 3.13401 14 7ZM4.3 5.05546L6.24455 7.00002L4.30002 8.94455L5.00712 9.65166L6.95166 7.70712L8.89619 9.65166L9.6033 8.94455L7.65877 7.00002L9.60332 5.05546L8.89621 4.34836L6.95166 6.29291L5.00711 4.34836L4.3 5.05546Z`,fill:`#E6635A`})}),mO=document,hO=()=>mO,{min:gO,max:_O}=Math,vO=(e,t=0,n=1)=>gO(_O(t,e),n),yO=e=>{e._clipped=!1,e._unclipped=e.slice(0);for(let t=0;t<=3;t++)t<3?((e[t]<0||e[t]>255)&&(e._clipped=!0),e[t]=vO(e[t],0,255)):t===3&&(e[t]=vO(e[t],0,1));return e},bO={};for(let e of[`Boolean`,`Number`,`String`,`Function`,`Array`,`Date`,`RegExp`,`Undefined`,`Null`])bO[`[object ${e}]`]=e.toLowerCase();function Y(e){return bO[Object.prototype.toString.call(e)]||`object`}var X=(e,t=null)=>e.length>=3?Array.prototype.slice.call(e):Y(e[0])==`object`&&t?t.split(``).filter(t=>e[0][t]!==void 0).map(t=>e[0][t]):e[0].slice(0),xO=e=>{if(e.length<2)return null;let t=e.length-1;return Y(e[t])==`string`?e[t].toLowerCase():null},{PI:SO,min:CO,max:wO}=Math,TO=e=>Math.round(e*100)/100,EO=e=>Math.round(e*100)/100,DO=SO*2,OO=SO/3,kO=SO/180,AO=180/SO;function jO(e){return[...e.slice(0,3).reverse(),...e.slice(3)]}var Z={format:{},autodetect:[]},Q=class{constructor(...e){let t=this;if(Y(e[0])===`object`&&e[0].constructor&&e[0].constructor===this.constructor)return e[0];let n=xO(e),r=!1;if(!n){r=!0,Z.sorted||=(Z.autodetect=Z.autodetect.sort((e,t)=>t.p-e.p),!0);for(let t of Z.autodetect)if(n=t.test(...e),n)break}if(Z.format[n])t._rgb=yO(Z.format[n].apply(null,r?e:e.slice(0,-1)));else throw Error(`unknown format: `+e);t._rgb.length===3&&t._rgb.push(1)}toString(){return Y(this.hex)==`function`?this.hex():`[${this._rgb.join(`,`)}]`}},MO=`3.2.0`,$=(...e)=>new Q(...e);$.version=MO;var NO={aliceblue:`#f0f8ff`,antiquewhite:`#faebd7`,aqua:`#00ffff`,aquamarine:`#7fffd4`,azure:`#f0ffff`,beige:`#f5f5dc`,bisque:`#ffe4c4`,black:`#000000`,blanchedalmond:`#ffebcd`,blue:`#0000ff`,blueviolet:`#8a2be2`,brown:`#a52a2a`,burlywood:`#deb887`,cadetblue:`#5f9ea0`,chartreuse:`#7fff00`,chocolate:`#d2691e`,coral:`#ff7f50`,cornflowerblue:`#6495ed`,cornsilk:`#fff8dc`,crimson:`#dc143c`,cyan:`#00ffff`,darkblue:`#00008b`,darkcyan:`#008b8b`,darkgoldenrod:`#b8860b`,darkgray:`#a9a9a9`,darkgreen:`#006400`,darkgrey:`#a9a9a9`,darkkhaki:`#bdb76b`,darkmagenta:`#8b008b`,darkolivegreen:`#556b2f`,darkorange:`#ff8c00`,darkorchid:`#9932cc`,darkred:`#8b0000`,darksalmon:`#e9967a`,darkseagreen:`#8fbc8f`,darkslateblue:`#483d8b`,darkslategray:`#2f4f4f`,darkslategrey:`#2f4f4f`,darkturquoise:`#00ced1`,darkviolet:`#9400d3`,deeppink:`#ff1493`,deepskyblue:`#00bfff`,dimgray:`#696969`,dimgrey:`#696969`,dodgerblue:`#1e90ff`,firebrick:`#b22222`,floralwhite:`#fffaf0`,forestgreen:`#228b22`,fuchsia:`#ff00ff`,gainsboro:`#dcdcdc`,ghostwhite:`#f8f8ff`,gold:`#ffd700`,goldenrod:`#daa520`,gray:`#808080`,green:`#008000`,greenyellow:`#adff2f`,grey:`#808080`,honeydew:`#f0fff0`,hotpink:`#ff69b4`,indianred:`#cd5c5c`,indigo:`#4b0082`,ivory:`#fffff0`,khaki:`#f0e68c`,laserlemon:`#ffff54`,lavender:`#e6e6fa`,lavenderblush:`#fff0f5`,lawngreen:`#7cfc00`,lemonchiffon:`#fffacd`,lightblue:`#add8e6`,lightcoral:`#f08080`,lightcyan:`#e0ffff`,lightgoldenrod:`#fafad2`,lightgoldenrodyellow:`#fafad2`,lightgray:`#d3d3d3`,lightgreen:`#90ee90`,lightgrey:`#d3d3d3`,lightpink:`#ffb6c1`,lightsalmon:`#ffa07a`,lightseagreen:`#20b2aa`,lightskyblue:`#87cefa`,lightslategray:`#778899`,lightslategrey:`#778899`,lightsteelblue:`#b0c4de`,lightyellow:`#ffffe0`,lime:`#00ff00`,limegreen:`#32cd32`,linen:`#faf0e6`,magenta:`#ff00ff`,maroon:`#800000`,maroon2:`#7f0000`,maroon3:`#b03060`,mediumaquamarine:`#66cdaa`,mediumblue:`#0000cd`,mediumorchid:`#ba55d3`,mediumpurple:`#9370db`,mediumseagreen:`#3cb371`,mediumslateblue:`#7b68ee`,mediumspringgreen:`#00fa9a`,mediumturquoise:`#48d1cc`,mediumvioletred:`#c71585`,midnightblue:`#191970`,mintcream:`#f5fffa`,mistyrose:`#ffe4e1`,moccasin:`#ffe4b5`,navajowhite:`#ffdead`,navy:`#000080`,oldlace:`#fdf5e6`,olive:`#808000`,olivedrab:`#6b8e23`,orange:`#ffa500`,orangered:`#ff4500`,orchid:`#da70d6`,palegoldenrod:`#eee8aa`,palegreen:`#98fb98`,paleturquoise:`#afeeee`,palevioletred:`#db7093`,papayawhip:`#ffefd5`,peachpuff:`#ffdab9`,peru:`#cd853f`,pink:`#ffc0cb`,plum:`#dda0dd`,powderblue:`#b0e0e6`,purple:`#800080`,purple2:`#7f007f`,purple3:`#a020f0`,rebeccapurple:`#663399`,red:`#ff0000`,rosybrown:`#bc8f8f`,royalblue:`#4169e1`,saddlebrown:`#8b4513`,salmon:`#fa8072`,sandybrown:`#f4a460`,seagreen:`#2e8b57`,seashell:`#fff5ee`,sienna:`#a0522d`,silver:`#c0c0c0`,skyblue:`#87ceeb`,slateblue:`#6a5acd`,slategray:`#708090`,slategrey:`#708090`,snow:`#fffafa`,springgreen:`#00ff7f`,steelblue:`#4682b4`,tan:`#d2b48c`,teal:`#008080`,thistle:`#d8bfd8`,tomato:`#ff6347`,turquoise:`#40e0d0`,violet:`#ee82ee`,wheat:`#f5deb3`,white:`#ffffff`,whitesmoke:`#f5f5f5`,yellow:`#ffff00`,yellowgreen:`#9acd32`},PO=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,FO=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,IO=e=>{if(e.match(PO)){(e.length===4||e.length===7)&&(e=e.substr(1)),e.length===3&&(e=e.split(``),e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]);let t=parseInt(e,16);return[t>>16,t>>8&255,t&255,1]}if(e.match(FO)){(e.length===5||e.length===9)&&(e=e.substr(1)),e.length===4&&(e=e.split(``),e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]);let t=parseInt(e,16);return[t>>24&255,t>>16&255,t>>8&255,Math.round((t&255)/255*100)/100]}throw Error(`unknown hex color: ${e}`)},{round:LO}=Math,RO=(...e)=>{let[t,n,r,i]=X(e,`rgba`),a=xO(e)||`auto`;i===void 0&&(i=1),a===`auto`&&(a=i<1?`rgba`:`rgb`),t=LO(t),n=LO(n),r=LO(r);let o=`000000`+(t<<16|n<<8|r).toString(16);o=o.substr(o.length-6);let s=`0`+LO(i*255).toString(16);switch(s=s.substr(s.length-2),a.toLowerCase()){case`rgba`:return`#${o}${s}`;case`argb`:return`#${s}${o}`;default:return`#${o}`}};Q.prototype.name=function(){let e=RO(this._rgb,`rgb`);for(let t of Object.keys(NO))if(NO[t]===e)return t.toLowerCase();return e},Z.format.named=e=>{if(e=e.toLowerCase(),NO[e])return IO(NO[e]);throw Error(`unknown color name: `+e)},Z.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&Y(e)===`string`&&NO[e.toLowerCase()])return`named`}}),Q.prototype.alpha=function(e,t=!1){return e!==void 0&&Y(e)===`number`?t?(this._rgb[3]=e,this):new Q([this._rgb[0],this._rgb[1],this._rgb[2],e],`rgb`):this._rgb[3]},Q.prototype.clipped=function(){return this._rgb._clipped||!1};var zO={Kn:18,labWhitePoint:`d65`,Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452,kE:216/24389,kKE:8,kK:24389/27,RefWhiteRGB:{X:.95047,Y:1,Z:1.08883},MtxRGB2XYZ:{m00:.4124564390896922,m01:.21267285140562253,m02:.0193338955823293,m10:.357576077643909,m11:.715152155287818,m12:.11919202588130297,m20:.18043748326639894,m21:.07217499330655958,m22:.9503040785363679},MtxXYZ2RGB:{m00:3.2404541621141045,m01:-.9692660305051868,m02:.055643430959114726,m10:-1.5371385127977166,m11:1.8760108454466942,m12:-.2040259135167538,m20:-.498531409556016,m21:.041556017530349834,m22:1.0572251882231791},As:.9414285350000001,Bs:1.040417467,Cs:1.089532651,MtxAdaptMa:{m00:.8951,m01:-.7502,m02:.0389,m10:.2664,m11:1.7135,m12:-.0685,m20:-.1614,m21:.0367,m22:1.0296},MtxAdaptMaI:{m00:.9869929054667123,m01:.43230526972339456,m02:-.008528664575177328,m10:-.14705425642099013,m11:.5183602715367776,m12:.04004282165408487,m20:.15996265166373125,m21:.0492912282128556,m22:.9684866957875502}},BO=new Map([[`a`,[1.0985,.35585]],[`b`,[1.0985,.35585]],[`c`,[.98074,1.18232]],[`d50`,[.96422,.82521]],[`d55`,[.95682,.92149]],[`d65`,[.95047,1.08883]],[`e`,[1,1,1]],[`f2`,[.99186,.67393]],[`f7`,[.95041,1.08747]],[`f11`,[1.00962,.6435]],[`icc`,[.96422,.82521]]]);function VO(e){let t=BO.get(String(e).toLowerCase());if(!t)throw Error(`unknown Lab illuminant `+e);zO.labWhitePoint=e,zO.Xn=t[0],zO.Zn=t[1]}function HO(){return zO.labWhitePoint}var UO=(...e)=>{e=X(e,`lab`);let[t,n,r]=e,[i,a,o]=WO(t,n,r),[s,c,l]=KO(i,a,o);return[s,c,l,e.length>3?e[3]:1]},WO=(e,t,n)=>{let{kE:r,kK:i,kKE:a,Xn:o,Yn:s,Zn:c}=zO,l=(e+16)/116,u=.002*t+l,d=l-.005*n,f=u*u*u,p=d*d*d,m=f>r?f:(116*u-16)/i,h=e>a?((e+16)/116)**3:e/i,g=p>r?p:(116*d-16)/i;return[m*o,h*s,g*c]},GO=e=>{let t=Math.sign(e);return e=Math.abs(e),(e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055)*t},KO=(e,t,n)=>{let{MtxAdaptMa:r,MtxAdaptMaI:i,MtxXYZ2RGB:a,RefWhiteRGB:o,Xn:s,Yn:c,Zn:l}=zO,u=s*r.m00+c*r.m10+l*r.m20,d=s*r.m01+c*r.m11+l*r.m21,f=s*r.m02+c*r.m12+l*r.m22,p=o.X*r.m00+o.Y*r.m10+o.Z*r.m20,m=o.X*r.m01+o.Y*r.m11+o.Z*r.m21,h=o.X*r.m02+o.Y*r.m12+o.Z*r.m22,g=(e*r.m00+t*r.m10+n*r.m20)*(p/u),_=(e*r.m01+t*r.m11+n*r.m21)*(m/d),v=(e*r.m02+t*r.m12+n*r.m22)*(h/f),y=g*i.m00+_*i.m10+v*i.m20,b=g*i.m01+_*i.m11+v*i.m21,x=g*i.m02+_*i.m12+v*i.m22,S=GO(y*a.m00+b*a.m10+x*a.m20),C=GO(y*a.m01+b*a.m11+x*a.m21),w=GO(y*a.m02+b*a.m12+x*a.m22);return[S*255,C*255,w*255]},qO=(...e)=>{let[t,n,r,...i]=X(e,`rgb`),[a,o,s]=XO(t,n,r),[c,l,u]=JO(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]};function JO(e,t,n){let{Xn:r,Yn:i,Zn:a,kE:o,kK:s}=zO,c=e/r,l=t/i,u=n/a,d=c>o?c**(1/3):(s*c+16)/116,f=l>o?l**(1/3):(s*l+16)/116,p=u>o?u**(1/3):(s*u+16)/116;return[116*f-16,500*(d-f),200*(f-p)]}function YO(e){let t=Math.sign(e);return e=Math.abs(e),(e<=.04045?e/12.92:((e+.055)/1.055)**2.4)*t}var XO=(e,t,n)=>{e=YO(e/255),t=YO(t/255),n=YO(n/255);let{MtxRGB2XYZ:r,MtxAdaptMa:i,MtxAdaptMaI:a,Xn:o,Yn:s,Zn:c,As:l,Bs:u,Cs:d}=zO,f=e*r.m00+t*r.m10+n*r.m20,p=e*r.m01+t*r.m11+n*r.m21,m=e*r.m02+t*r.m12+n*r.m22,h=o*i.m00+s*i.m10+c*i.m20,g=o*i.m01+s*i.m11+c*i.m21,_=o*i.m02+s*i.m12+c*i.m22,v=f*i.m00+p*i.m10+m*i.m20,y=f*i.m01+p*i.m11+m*i.m21,b=f*i.m02+p*i.m12+m*i.m22;return v*=h/l,y*=g/u,b*=_/d,f=v*a.m00+y*a.m10+b*a.m20,p=v*a.m01+y*a.m11+b*a.m21,m=v*a.m02+y*a.m12+b*a.m22,[f,p,m]};Q.prototype.lab=function(){return qO(this._rgb)},Object.assign($,{lab:(...e)=>new Q(...e,`lab`),getLabWhitePoint:HO,setLabWhitePoint:VO}),Z.format.lab=UO,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`lab`),Y(e)===`array`&&e.length===3)return`lab`}}),Q.prototype.darken=function(e=1){let t=this,n=t.lab();return n[0]-=zO.Kn*e,new Q(n,`lab`).alpha(t.alpha(),!0)},Q.prototype.brighten=function(e=1){return this.darken(-e)},Q.prototype.darker=Q.prototype.darken,Q.prototype.brighter=Q.prototype.brighten,Q.prototype.get=function(e){let[t,n]=e.split(`.`),r=this[t]();if(n){let e=t.indexOf(n)-(t.substr(0,2)===`ok`?2:0);if(e>-1)return r[e];throw Error(`unknown channel ${n} in mode ${t}`)}return r};var{pow:ZO}=Math,QO=1e-7,$O=20;Q.prototype.luminance=function(e,t=`rgb`){if(e!==void 0&&Y(e)===`number`){if(e===0)return new Q([0,0,0,this._rgb[3]],`rgb`);if(e===1)return new Q([255,255,255,this._rgb[3]],`rgb`);let n=this.luminance(),r=$O,i=(n,a)=>{let o=n.interpolate(a,.5,t),s=o.luminance();return Math.abs(e-s)<QO||!r--?o:s>e?i(n,o):i(o,a)};return new Q([...(n>e?i(new Q([0,0,0]),this):i(this,new Q([255,255,255]))).rgb(),this._rgb[3]])}return ek(...this._rgb.slice(0,3))};var ek=(e,t,n)=>(e=tk(e),t=tk(t),n=tk(n),.2126*e+.7152*t+.0722*n),tk=e=>(e/=255,e<=.03928?e/12.92:ZO((e+.055)/1.055,2.4)),nk={},rk=(e,t,n=.5,...r)=>{let i=r[0]||`lrgb`;if(!nk[i]&&!r.length&&(i=Object.keys(nk)[0]),!nk[i])throw Error(`interpolation mode ${i} is not defined`);return Y(e)!==`object`&&(e=new Q(e)),Y(t)!==`object`&&(t=new Q(t)),nk[i](e,t,n).alpha(e.alpha()+n*(t.alpha()-e.alpha()))};Q.prototype.mix=Q.prototype.interpolate=function(e,t=.5,...n){return rk(this,e,t,...n)},Q.prototype.premultiply=function(e=!1){let t=this._rgb,n=t[3];return e?(this._rgb=[t[0]*n,t[1]*n,t[2]*n,n],this):new Q([t[0]*n,t[1]*n,t[2]*n,n],`rgb`)};var{sin:ik,cos:ak}=Math,ok=(...e)=>{let[t,n,r]=X(e,`lch`);return isNaN(r)&&(r=0),r*=kO,[t,ak(r)*n,ik(r)*n]},sk=(...e)=>{e=X(e,`lch`);let[t,n,r]=e,[i,a,o]=ok(t,n,r),[s,c,l]=UO(i,a,o);return[s,c,l,e.length>3?e[3]:1]},ck=(...e)=>sk(...jO(X(e,`hcl`))),{sqrt:lk,atan2:uk,round:dk}=Math,fk=(...e)=>{let[t,n,r]=X(e,`lab`),i=lk(n*n+r*r),a=(uk(r,n)*AO+360)%360;return dk(i*1e4)===0&&(a=NaN),[t,i,a]},pk=(...e)=>{let[t,n,r,...i]=X(e,`rgb`),[a,o,s]=qO(t,n,r),[c,l,u]=fk(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]};Q.prototype.lch=function(){return pk(this._rgb)},Q.prototype.hcl=function(){return jO(pk(this._rgb))},Object.assign($,{lch:(...e)=>new Q(...e,`lch`),hcl:(...e)=>new Q(...e,`hcl`)}),Z.format.lch=sk,Z.format.hcl=ck,[`lch`,`hcl`].forEach(e=>Z.autodetect.push({p:2,test:(...t)=>{if(t=X(t,e),Y(t)===`array`&&t.length===3)return e}})),Q.prototype.saturate=function(e=1){let t=this,n=t.lch();return n[1]+=zO.Kn*e,n[1]<0&&(n[1]=0),new Q(n,`lch`).alpha(t.alpha(),!0)},Q.prototype.desaturate=function(e=1){return this.saturate(-e)},Q.prototype.set=function(e,t,n=!1){let[r,i]=e.split(`.`),a=this[r]();if(i){let e=r.indexOf(i)-(r.substr(0,2)===`ok`?2:0);if(e>-1){if(Y(t)==`string`)switch(t.charAt(0)){case`+`:a[e]+=+t;break;case`-`:a[e]+=+t;break;case`*`:a[e]*=+t.substr(1);break;case`/`:a[e]/=+t.substr(1);break;default:a[e]=+t}else if(Y(t)===`number`)a[e]=t;else throw Error(`unsupported value for Color.set`);let i=new Q(a,r);return n?(this._rgb=i._rgb,this):i}throw Error(`unknown channel ${i} in mode ${r}`)}return a},Q.prototype.tint=function(e=.5,...t){return rk(this,`white`,e,...t)},Q.prototype.shade=function(e=.5,...t){return rk(this,`black`,e,...t)},nk.rgb=(e,t,n)=>{let r=e._rgb,i=t._rgb;return new Q(r[0]+n*(i[0]-r[0]),r[1]+n*(i[1]-r[1]),r[2]+n*(i[2]-r[2]),`rgb`)};var{sqrt:mk,pow:hk}=Math;nk.lrgb=(e,t,n)=>{let[r,i,a]=e._rgb,[o,s,c]=t._rgb;return new Q(mk(hk(r,2)*(1-n)+hk(o,2)*n),mk(hk(i,2)*(1-n)+hk(s,2)*n),mk(hk(a,2)*(1-n)+hk(c,2)*n),`rgb`)},nk.lab=(e,t,n)=>{let r=e.lab(),i=t.lab();return new Q(r[0]+n*(i[0]-r[0]),r[1]+n*(i[1]-r[1]),r[2]+n*(i[2]-r[2]),`lab`)};var gk=(e,t,n,r)=>{let i,a;r===`hsl`?(i=e.hsl(),a=t.hsl()):r===`hsv`?(i=e.hsv(),a=t.hsv()):r===`hcg`?(i=e.hcg(),a=t.hcg()):r===`hsi`?(i=e.hsi(),a=t.hsi()):r===`lch`||r===`hcl`?(r=`hcl`,i=e.hcl(),a=t.hcl()):r===`oklch`&&(i=e.oklch().reverse(),a=t.oklch().reverse());let o,s,c,l,u,d;(r.substr(0,1)===`h`||r===`oklch`)&&([o,c,u]=i,[s,l,d]=a);let f,p,m,h;return!isNaN(o)&&!isNaN(s)?(h=s>o&&s-o>180?s-(o+360):s<o&&o-s>180?s+360-o:s-o,p=o+n*h):isNaN(o)?isNaN(s)?p=NaN:(p=s,(u==1||u==0)&&r!=`hsv`&&(f=l)):(p=o,(d==1||d==0)&&r!=`hsv`&&(f=c)),f===void 0&&(f=c+n*(l-c)),m=u+n*(d-u),r===`oklch`?new Q([m,f,p],r):new Q([p,f,m],r)},_k=(e,t,n)=>gk(e,t,n,`lch`);nk.lch=_k,nk.hcl=_k;var vk=e=>{if(Y(e)==`number`&&e>=0&&e<=16777215)return[e>>16,e>>8&255,e&255,1];throw Error(`unknown num color: `+e)},yk=(...e)=>{let[t,n,r]=X(e,`rgb`);return(t<<16)+(n<<8)+r};Q.prototype.num=function(){return yk(this._rgb)},Object.assign($,{num:(...e)=>new Q(...e,`num`)}),Z.format.num=vk,Z.autodetect.push({p:5,test:(...e)=>{if(e.length===1&&Y(e[0])===`number`&&e[0]>=0&&e[0]<=16777215)return`num`}}),nk.num=(e,t,n)=>{let r=e.num();return new Q(r+n*(t.num()-r),`num`)};var{floor:bk}=Math,xk=(...e)=>{e=X(e,`hcg`);let[t,n,r]=e,i,a,o;r*=255;let s=n*255;if(n===0)i=a=o=r;else{t===360&&(t=0),t>360&&(t-=360),t<0&&(t+=360),t/=60;let e=bk(t),c=t-e,l=r*(1-n),u=l+s*(1-c),d=l+s*c,f=l+s;switch(e){case 0:[i,a,o]=[f,d,l];break;case 1:[i,a,o]=[u,f,l];break;case 2:[i,a,o]=[l,f,d];break;case 3:[i,a,o]=[l,u,f];break;case 4:[i,a,o]=[d,l,f];break;case 5:[i,a,o]=[f,l,u]}}return[i,a,o,e.length>3?e[3]:1]},Sk=(...e)=>{let[t,n,r]=X(e,`rgb`),i=CO(t,n,r),a=wO(t,n,r),o=a-i,s=o*100/255,c=i/(255-o)*100,l;return o===0?l=NaN:(t===a&&(l=(n-r)/o),n===a&&(l=2+(r-t)/o),r===a&&(l=4+(t-n)/o),l*=60,l<0&&(l+=360)),[l,s,c]};Q.prototype.hcg=function(){return Sk(this._rgb)},$.hcg=(...e)=>new Q(...e,`hcg`),Z.format.hcg=xk,Z.autodetect.push({p:1,test:(...e)=>{if(e=X(e,`hcg`),Y(e)===`array`&&e.length===3)return`hcg`}}),nk.hcg=(e,t,n)=>gk(e,t,n,`hcg`);var{cos:Ck}=Math,wk=(...e)=>{e=X(e,`hsi`);let[t,n,r]=e,i,a,o;return isNaN(t)&&(t=0),isNaN(n)&&(n=0),t>360&&(t-=360),t<0&&(t+=360),t/=360,t<1/3?(o=(1-n)/3,i=(1+n*Ck(DO*t)/Ck(OO-DO*t))/3,a=1-(o+i)):t<2/3?(t-=1/3,i=(1-n)/3,a=(1+n*Ck(DO*t)/Ck(OO-DO*t))/3,o=1-(i+a)):(t-=2/3,a=(1-n)/3,o=(1+n*Ck(DO*t)/Ck(OO-DO*t))/3,i=1-(a+o)),i=vO(r*i*3),a=vO(r*a*3),o=vO(r*o*3),[i*255,a*255,o*255,e.length>3?e[3]:1]},{min:Tk,sqrt:Ek,acos:Dk}=Math,Ok=(...e)=>{let[t,n,r]=X(e,`rgb`);t/=255,n/=255,r/=255;let i,a=Tk(t,n,r),o=(t+n+r)/3,s=o>0?1-a/o:0;return s===0?i=NaN:(i=(t-n+(t-r))/2,i/=Ek((t-n)*(t-n)+(t-r)*(n-r)),i=Dk(i),r>n&&(i=DO-i),i/=DO),[i*360,s,o]};Q.prototype.hsi=function(){return Ok(this._rgb)},$.hsi=(...e)=>new Q(...e,`hsi`),Z.format.hsi=wk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`hsi`),Y(e)===`array`&&e.length===3)return`hsi`}}),nk.hsi=(e,t,n)=>gk(e,t,n,`hsi`);var kk=(...e)=>{e=X(e,`hsl`);let[t,n,r]=e,i,a,o;if(n===0)i=a=o=r*255;else{let e=[0,0,0],s=[0,0,0],c=r<.5?r*(1+n):r+n-r*n,l=2*r-c,u=t/360;e[0]=u+1/3,e[1]=u,e[2]=u-1/3;for(let t=0;t<3;t++)e[t]<0&&(e[t]+=1),e[t]>1&&--e[t],6*e[t]<1?s[t]=l+(c-l)*6*e[t]:2*e[t]<1?s[t]=c:3*e[t]<2?s[t]=l+(c-l)*(2/3-e[t])*6:s[t]=l;[i,a,o]=[s[0]*255,s[1]*255,s[2]*255]}return e.length>3?[i,a,o,e[3]]:[i,a,o,1]},Ak=(...e)=>{e=X(e,`rgba`);let[t,n,r]=e;t/=255,n/=255,r/=255;let i=CO(t,n,r),a=wO(t,n,r),o=(a+i)/2,s,c;return a===i?(s=0,c=NaN):s=o<.5?(a-i)/(a+i):(a-i)/(2-a-i),t==a?c=(n-r)/(a-i):n==a?c=2+(r-t)/(a-i):r==a&&(c=4+(t-n)/(a-i)),c*=60,c<0&&(c+=360),e.length>3&&e[3]!==void 0?[c,s,o,e[3]]:[c,s,o]};Q.prototype.hsl=function(){return Ak(this._rgb)},$.hsl=(...e)=>new Q(...e,`hsl`),Z.format.hsl=kk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`hsl`),Y(e)===`array`&&e.length===3)return`hsl`}}),nk.hsl=(e,t,n)=>gk(e,t,n,`hsl`);var{floor:jk}=Math,Mk=(...e)=>{e=X(e,`hsv`);let[t,n,r]=e,i,a,o;if(r*=255,n===0)i=a=o=r;else{t===360&&(t=0),t>360&&(t-=360),t<0&&(t+=360),t/=60;let e=jk(t),s=t-e,c=r*(1-n),l=r*(1-n*s),u=r*(1-n*(1-s));switch(e){case 0:[i,a,o]=[r,u,c];break;case 1:[i,a,o]=[l,r,c];break;case 2:[i,a,o]=[c,r,u];break;case 3:[i,a,o]=[c,l,r];break;case 4:[i,a,o]=[u,c,r];break;case 5:[i,a,o]=[r,c,l]}}return[i,a,o,e.length>3?e[3]:1]},{min:Nk,max:Pk}=Math,Fk=(...e)=>{e=X(e,`rgb`);let[t,n,r]=e,i=Nk(t,n,r),a=Pk(t,n,r),o=a-i,s,c,l;return l=a/255,a===0?(s=NaN,c=0):(c=o/a,t===a&&(s=(n-r)/o),n===a&&(s=2+(r-t)/o),r===a&&(s=4+(t-n)/o),s*=60,s<0&&(s+=360)),[s,c,l]};Q.prototype.hsv=function(){return Fk(this._rgb)},$.hsv=(...e)=>new Q(...e,`hsv`),Z.format.hsv=Mk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`hsv`),Y(e)===`array`&&e.length===3)return`hsv`}}),nk.hsv=(e,t,n)=>gk(e,t,n,`hsv`);function Ik(e,t){let n=e.length;Array.isArray(e[0])||(e=[e]),Array.isArray(t[0])||(t=t.map(e=>[e]));let r=t[0].length,i=t[0].map((e,n)=>t.map(e=>e[n])),a=e.map(e=>i.map(t=>Array.isArray(e)?e.reduce((e,n,r)=>e+n*(t[r]||0),0):t.reduce((t,n)=>t+n*e,0)));return n===1&&(a=a[0]),r===1?a.map(e=>e[0]):a}var Lk=(...e)=>{e=X(e,`lab`);let[t,n,r,...i]=e,[a,o,s]=Rk([t,n,r]),[c,l,u]=KO(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]};function Rk(e){return Ik([[1.2268798758459243,-.5578149944602171,.2813910456659647],[-.0405757452148008,1.112286803280317,-.0717110580655164],[-.0763729366746601,-.4214933324022432,1.5869240198367816]],Ik([[1,.3963377773761749,.2158037573099136],[1,-.1055613458156586,-.0638541728258133],[1,-.0894841775298119,-1.2914855480194092]],e).map(e=>e**3))}var zk=(...e)=>{let[t,n,r,...i]=X(e,`rgb`);return[...Bk(XO(t,n,r)),...i.length>0&&i[0]<1?[i[0]]:[]]};function Bk(e){return Ik([[.210454268309314,.7936177747023054,-.0040720430116193],[1.9779985324311684,-2.42859224204858,.450593709617411],[.0259040424655478,.7827717124575296,-.8086757549230774]],Ik([[.819022437996703,.3619062600528904,-.1288737815209879],[.0329836539323885,.9292868615863434,.0361446663506424],[.0481771893596242,.2642395317527308,.6335478284694309]],e).map(e=>Math.cbrt(e)))}Q.prototype.oklab=function(){return zk(this._rgb)},Object.assign($,{oklab:(...e)=>new Q(...e,`oklab`)}),Z.format.oklab=Lk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`oklab`),Y(e)===`array`&&e.length===3)return`oklab`}}),nk.oklab=(e,t,n)=>{let r=e.oklab(),i=t.oklab();return new Q(r[0]+n*(i[0]-r[0]),r[1]+n*(i[1]-r[1]),r[2]+n*(i[2]-r[2]),`oklab`)},nk.oklch=(e,t,n)=>gk(e,t,n,`oklch`);var{pow:Vk,sqrt:Hk,PI:Uk,cos:Wk,sin:Gk,atan2:Kk}=Math,qk=(e,t=`lrgb`,n=null)=>{let r=e.length;n||=Array.from(Array(r)).map(()=>1);let i=r/n.reduce(function(e,t){return e+t});if(n.forEach((e,t)=>{n[t]*=i}),e=e.map(e=>new Q(e)),t===`lrgb`)return Jk(e,n);let a=e.shift(),o=a.get(t),s=[],c=0,l=0;for(let e=0;e<o.length;e++)if(o[e]=(o[e]||0)*n[0],s.push(isNaN(o[e])?0:n[0]),t.charAt(e)===`h`&&!isNaN(o[e])){let t=o[e]/180*Uk;c+=Wk(t)*n[0],l+=Gk(t)*n[0]}let u=a.alpha()*n[0];e.forEach((e,r)=>{let i=e.get(t);u+=e.alpha()*n[r+1];for(let e=0;e<o.length;e++)if(!isNaN(i[e])){if(s[e]+=n[r+1],t.charAt(e)===`h`){let t=i[e]/180*Uk;c+=Wk(t)*n[r+1],l+=Gk(t)*n[r+1]}else o[e]+=i[e]*n[r+1]}});for(let e=0;e<o.length;e++)if(t.charAt(e)===`h`){let t=Kk(l/s[e],c/s[e])/Uk*180;for(;t<0;)t+=360;for(;t>=360;)t-=360;o[e]=t}else o[e]=o[e]/s[e];return u/=r,new Q(o,t).alpha(u>.99999?1:u,!0)},Jk=(e,t)=>{let n=e.length,r=[0,0,0,0];for(let i=0;i<e.length;i++){let a=e[i],o=t[i]/n,s=a._rgb;r[0]+=Vk(s[0],2)*o,r[1]+=Vk(s[1],2)*o,r[2]+=Vk(s[2],2)*o,r[3]+=s[3]*o}return r[0]=Hk(r[0]),r[1]=Hk(r[1]),r[2]=Hk(r[2]),r[3]>.9999999&&(r[3]=1),new Q(yO(r))},{pow:Yk}=Math;function Xk(e){let t=`rgb`,n=$(`#ccc`),r=0,i=[0,1],a=[0,1],o=[],s=[0,0],c=!1,l=[],u=!1,d=0,f=1,p=!1,m={},h=!0,g=1,_=function(e){if(e||=[`#fff`,`#000`],e&&Y(e)===`string`&&$.brewer&&$.brewer[e.toLowerCase()]&&(e=$.brewer[e.toLowerCase()]),Y(e)===`array`){e.length===1&&(e=[e[0],e[0]]),e=e.slice(0);for(let t=0;t<e.length;t++)e[t]=$(e[t]);o.length=0;for(let t=0;t<e.length;t++)o.push(t/(e.length-1))}return S(),l=e},v=function(e){if(c!=null){let t=c.length-1,n=0;for(;n<t&&e>=c[n];)n++;return n-1}return 0},y=e=>e,b=e=>e,x=function(e,r){let i,a;if(r??=!1,isNaN(e)||e===null)return n;a=r?e:c&&c.length>2?v(e)/(c.length-2):f===d?1:(e-d)/(f-d),a=b(a),r||(a=y(a)),g!==1&&(a=Yk(a,g)),a=s[0]+a*(1-s[0]-s[1]),a=vO(a,0,1);let u=Math.floor(a*1e4);if(h&&m[u])i=m[u];else{if(Y(l)===`array`)for(let e=0;e<o.length;e++){let n=o[e];if(a<=n){i=l[e];break}if(a>=n&&e===o.length-1){i=l[e];break}if(a>n&&a<o[e+1]){a=(a-n)/(o[e+1]-n),i=$.interpolate(l[e],l[e+1],a,t);break}}else Y(l)===`function`&&(i=l(a));h&&(m[u]=i)}return i};var S=()=>m={};_(e);let C=function(e){let t=$(x(e));return u&&t[u]?t[u]():t};return C.classes=function(e){if(e!=null){if(Y(e)===`array`)c=e,i=[e[0],e[e.length-1]];else{let t=$.analyze(i);c=e===0?[t.min,t.max]:$.limits(t,`e`,e)}return C}return c},C.domain=function(e){if(!arguments.length)return a;a=e.slice(0),d=e[0],f=e[e.length-1],o=[];let t=l.length;if(e.length===t&&d!==f)for(let t of Array.from(e))o.push((t-d)/(f-d));else{for(let e=0;e<t;e++)o.push(e/(t-1));if(e.length>2){let t=e.map((t,n)=>n/(e.length-1)),n=e.map(e=>(e-d)/(f-d));n.every((e,n)=>t[n]===e)||(b=e=>{if(e<=0||e>=1)return e;let r=0;for(;e>=n[r+1];)r++;let i=(e-n[r])/(n[r+1]-n[r]);return t[r]+i*(t[r+1]-t[r])})}}return i=[d,f],C},C.mode=function(e){return arguments.length?(t=e,S(),C):t},C.range=function(e,t){return _(e,t),C},C.out=function(e){return u=e,C},C.spread=function(e){return arguments.length?(r=e,C):r},C.correctLightness=function(e){return e??=!0,p=e,S(),y=p?function(e){let t=x(0,!0).lab()[0],n=x(1,!0).lab()[0],r=t>n,i=x(e,!0).lab()[0],a=t+(n-t)*e,o=i-a,s=0,c=1,l=20;for(;Math.abs(o)>.01&&l-->0;)(function(){return r&&(o*=-1),o<0?(s=e,e+=(c-e)*.5):(c=e,e+=(s-e)*.5),i=x(e,!0).lab()[0],o=i-a})();return e}:e=>e,C},C.padding=function(e){return e==null?s:(Y(e)===`number`&&(e=[e,e]),s=e,C)},C.colors=function(t,n){arguments.length<2&&(n=`hex`);let r=[];if(arguments.length===0)r=l.slice(0);else if(t===1)r=[C(.5)];else if(t>1){let e=i[0],n=i[1]-e;r=Zk(0,t,!1).map(r=>C(e+r/(t-1)*n))}else{e=[];let t=[];if(c&&c.length>2)for(let e=1,n=c.length,r=1<=n;r?e<n:e>n;r?e++:e--)t.push((c[e-1]+c[e])*.5);else t=i;r=t.map(e=>C(e))}return $[n]&&(r=r.map(e=>e[n]())),r},C.cache=function(e){return e==null?h:(h=e,C)},C.gamma=function(e){return e==null?g:(g=e,C)},C.nodata=function(e){return e==null?n:(n=$(e),C)},C}function Zk(e,t,n){let r=[],i=e<t,a=n?i?t+1:t-1:t;for(let t=e;i?t<a:t>a;i?t++:t--)r.push(t);return r}var Qk=function(e){let t=[1,1];for(let n=1;n<e;n++){let e=[1];for(let n=1;n<=t.length;n++)e[n]=(t[n]||0)+t[n-1];t=e}return t},$k=function(e){let t,n,r,i;if(e=e.map(e=>new Q(e)),e.length===2)[n,r]=e.map(e=>e.lab()),t=function(e){return new Q([0,1,2].map(t=>n[t]+e*(r[t]-n[t])),`lab`)};else if(e.length===3)[n,r,i]=e.map(e=>e.lab()),t=function(e){return new Q([0,1,2].map(t=>(1-e)*(1-e)*n[t]+2*(1-e)*e*r[t]+e*e*i[t]),`lab`)};else if(e.length===4){let a;[n,r,i,a]=e.map(e=>e.lab()),t=function(e){return new Q([0,1,2].map(t=>(1-e)*(1-e)*(1-e)*n[t]+3*(1-e)*(1-e)*e*r[t]+3*(1-e)*e*e*i[t]+e*e*e*a[t]),`lab`)}}else if(e.length>=5){let n,r,i;n=e.map(e=>e.lab()),i=e.length-1,r=Qk(i),t=function(e){let t=1-e;return new Q([0,1,2].map(a=>n.reduce((n,o,s)=>n+r[s]*t**(i-s)*e**s*o[a],0)),`lab`)}}else throw RangeError(`No point in running bezier with only one color.`);return t},eA=e=>{let t=$k(e);return t.scale=()=>Xk(t),t},{round:tA}=Math;Q.prototype.rgb=function(e=!0){return e===!1?this._rgb.slice(0,3):this._rgb.slice(0,3).map(tA)},Q.prototype.rgba=function(e=!0){return this._rgb.slice(0,4).map((t,n)=>n<3?e===!1?t:tA(t):t)},Object.assign($,{rgb:(...e)=>new Q(...e,`rgb`)}),Z.format.rgb=(...e)=>{let t=X(e,`rgba`);return t[3]===void 0&&(t[3]=1),t},Z.autodetect.push({p:3,test:(...e)=>{if(e=X(e,`rgba`),Y(e)===`array`&&(e.length===3||e.length===4&&Y(e[3])==`number`&&e[3]>=0&&e[3]<=1))return`rgb`}});var nA=(e,t,n)=>{if(!nA[n])throw Error(`unknown blend mode `+n);return nA[n](e,t)},rA=e=>(t,n)=>{let r=$(n).rgb(),i=$(t).rgb();return $.rgb(e(r,i))},iA=e=>(t,n)=>{let r=[];return r[0]=e(t[0],n[0]),r[1]=e(t[1],n[1]),r[2]=e(t[2],n[2]),r};nA.normal=rA(iA(e=>e)),nA.multiply=rA(iA((e,t)=>e*t/255)),nA.screen=rA(iA((e,t)=>255*(1-(1-e/255)*(1-t/255)))),nA.overlay=rA(iA((e,t)=>t<128?2*e*t/255:255*(1-2*(1-e/255)*(1-t/255)))),nA.darken=rA(iA((e,t)=>e>t?t:e)),nA.lighten=rA(iA((e,t)=>e>t?e:t)),nA.dodge=rA(iA((e,t)=>e===255?255:(e=t/255*255/(1-e/255),e>255?255:e))),nA.burn=rA(iA((e,t)=>255*(1-(1-t/255)/(e/255))));var{pow:aA,sin:oA,cos:sA}=Math;function cA(e=300,t=-1.5,n=1,r=1,i=[0,1]){let a=0,o;Y(i)===`array`?o=i[1]-i[0]:(o=0,i=[i,i]);let s=function(s){let c=DO*((e+120)/360+t*s),l=aA(i[0]+o*s,r),u=(a===0?n:n[0]+s*a)*l*(1-l)/2,d=sA(c),f=oA(c),p=l+u*(-.14861*d+1.78277*f),m=l+u*(-.29227*d-.90649*f),h=l+1.97294*d*u;return $(yO([p*255,m*255,h*255,1]))};return s.start=function(t){return t==null?e:(e=t,s)},s.rotations=function(e){return e==null?t:(t=e,s)},s.gamma=function(e){return e==null?r:(r=e,s)},s.hue=function(e){return e==null?n:(n=e,Y(n)===`array`?(a=n[1]-n[0],a===0&&(n=n[1])):a=0,s)},s.lightness=function(e){return e==null?i:(Y(e)===`array`?(i=e,o=e[1]-e[0]):(i=[e,e],o=0),s)},s.scale=()=>$.scale(s),s.hue(n),s}var lA=`0123456789abcdef`,{floor:uA,random:dA}=Math,fA=(e=dA)=>{let t=`#`;for(let n=0;n<6;n++)t+=lA.charAt(uA(e()*16));return new Q(t,`hex`)},{log:pA,pow:mA,floor:hA,abs:gA}=Math;function _A(e,t=null){let n={min:Number.MAX_VALUE,max:Number.MAX_VALUE*-1,sum:0,values:[],count:0};return Y(e)===`object`&&(e=Object.values(e)),e.forEach(e=>{t&&Y(e)===`object`&&(e=e[t]),e!=null&&!isNaN(e)&&(n.values.push(e),n.sum+=e,e<n.min&&(n.min=e),e>n.max&&(n.max=e),n.count+=1)}),n.domain=[n.min,n.max],n.limits=(e,t)=>vA(n,e,t),n}function vA(e,t=`equal`,n=7){Y(e)==`array`&&(e=_A(e));let{min:r,max:i}=e,a=e.values.sort((e,t)=>e-t);if(n===1)return[r,i];let o=[];if(t.substr(0,1)===`c`&&(o.push(r),o.push(i)),t.substr(0,1)===`e`){o.push(r);for(let e=1;e<n;e++)o.push(r+e/n*(i-r));o.push(i)}else if(t.substr(0,1)===`l`){if(r<=0)throw Error(`Logarithmic scales are only possible for values > 0`);let e=Math.LOG10E*pA(r),t=Math.LOG10E*pA(i);o.push(r);for(let r=1;r<n;r++)o.push(mA(10,e+r/n*(t-e)));o.push(i)}else if(t.substr(0,1)===`q`){o.push(r);for(let e=1;e<n;e++){let t=(a.length-1)*e/n,r=hA(t);if(r===t)o.push(a[r]);else{let e=t-r;o.push(a[r]*(1-e)+a[r+1]*e)}}o.push(i)}else if(t.substr(0,1)===`k`){let e,t=a.length,s=Array(t),c=Array(n),l=!0,u=0,d=null;d=[],d.push(r);for(let e=1;e<n;e++)d.push(r+e/n*(i-r));for(d.push(i);l;){for(let e=0;e<n;e++)c[e]=0;for(let e=0;e<t;e++){let t=a[e],r=Number.MAX_VALUE,i;for(let a=0;a<n;a++){let n=gA(d[a]-t);n<r&&(r=n,i=a),c[i]++,s[e]=i}}let r=Array(n);for(let e=0;e<n;e++)r[e]=null;for(let n=0;n<t;n++)e=s[n],r[e]===null?r[e]=a[n]:r[e]+=a[n];for(let e=0;e<n;e++)r[e]*=1/c[e];l=!1;for(let e=0;e<n;e++)if(r[e]!==d[e]){l=!0;break}d=r,u++,u>200&&(l=!1)}let f={};for(let e=0;e<n;e++)f[e]=[];for(let n=0;n<t;n++)e=s[n],f[e].push(a[n]);let p=[];for(let e=0;e<n;e++)p.push(f[e][0]),p.push(f[e][f[e].length-1]);p=p.sort((e,t)=>e-t),o.push(p[0]);for(let e=1;e<p.length;e+=2){let t=p[e];!isNaN(t)&&o.indexOf(t)===-1&&o.push(t)}}return o}var yA=(e,t)=>{e=new Q(e),t=new Q(t);let n=e.luminance(),r=t.luminance();return n>r?(n+.05)/(r+.05):(r+.05)/(n+.05)},bA=.027,xA=5e-4,SA=.1,CA=1.14,wA=.022,TA=1.414,EA=(e,t)=>{e=new Q(e),t=new Q(t),e.alpha()<1&&(e=rk(t,e,e.alpha(),`rgb`));let n=DA(...e.rgb()),r=DA(...t.rgb()),i=n>=wA?n:n+(wA-n)**+TA,a=r>=wA?r:r+(wA-r)**+TA,o=a**.56-i**.57,s=a**.65-i**.62,c=Math.abs(a-i)<xA?0:i<a?o*CA:s*CA;return(Math.abs(c)<SA?0:c>0?c-bA:c+bA)*100};function DA(e,t,n){return .2126729*(e/255)**2.4+.7151522*(t/255)**2.4+.072175*(n/255)**2.4}var{sqrt:OA,pow:kA,min:AA,max:jA,atan2:MA,abs:NA,cos:PA,sin:FA,exp:IA,PI:LA}=Math;function RA(e,t,n=1,r=1,i=1){var a=function(e){return 360*e/(2*LA)},o=function(e){return 2*LA*e/360};e=new Q(e),t=new Q(t);let[s,c,l]=Array.from(e.lab()),[u,d,f]=Array.from(t.lab()),p=(s+u)/2,m=(OA(kA(c,2)+kA(l,2))+OA(kA(d,2)+kA(f,2)))/2,h=.5*(1-OA(kA(m,7)/(kA(m,7)+kA(25,7)))),g=c*(1+h),_=d*(1+h),v=OA(kA(g,2)+kA(l,2)),y=OA(kA(_,2)+kA(f,2)),b=(v+y)/2,x=a(MA(l,g)),S=a(MA(f,_)),C=x>=0?x:x+360,w=S>=0?S:S+360,T=NA(C-w)>180?(C+w+360)/2:(C+w)/2,E=1-.17*PA(o(T-30))+.24*PA(o(2*T))+.32*PA(o(3*T+6))-.2*PA(o(4*T-63)),D=w-C;D=NA(D)<=180?D:w<=C?D+360:D-360,D=2*OA(v*y)*FA(o(D)/2);let O=u-s,ee=y-v,te=1+.015*kA(p-50,2)/OA(20+kA(p-50,2)),ne=1+.045*b,re=1+.015*b*E,k=30*IA(-kA((T-275)/25,2)),A=-(2*OA(kA(b,7)/(kA(b,7)+kA(25,7))))*FA(2*o(k));return jA(0,AA(100,OA(kA(O/(n*te),2)+kA(ee/(r*ne),2)+kA(D/(i*re),2)+A*(ee/(r*ne))*(D/(i*re)))))}function zA(e,t,n=`lab`){e=new Q(e),t=new Q(t);let r=e.get(n),i=t.get(n),a=0;for(let e in r){let t=(r[e]||0)-(i[e]||0);a+=t*t}return Math.sqrt(a)}var BA=(...e)=>{try{return new Q(...e),!0}catch{return!1}},VA={cool(){return Xk([$.hsl(180,1,.9),$.hsl(250,.7,.4)])},hot(){return Xk([`#000`,`#f00`,`#ff0`,`#fff`],[0,.25,.75,1]).mode(`rgb`)}},HA={OrRd:[`#fff7ec`,`#fee8c8`,`#fdd49e`,`#fdbb84`,`#fc8d59`,`#ef6548`,`#d7301f`,`#b30000`,`#7f0000`],PuBu:[`#fff7fb`,`#ece7f2`,`#d0d1e6`,`#a6bddb`,`#74a9cf`,`#3690c0`,`#0570b0`,`#045a8d`,`#023858`],BuPu:[`#f7fcfd`,`#e0ecf4`,`#bfd3e6`,`#9ebcda`,`#8c96c6`,`#8c6bb1`,`#88419d`,`#810f7c`,`#4d004b`],Oranges:[`#fff5eb`,`#fee6ce`,`#fdd0a2`,`#fdae6b`,`#fd8d3c`,`#f16913`,`#d94801`,`#a63603`,`#7f2704`],BuGn:[`#f7fcfd`,`#e5f5f9`,`#ccece6`,`#99d8c9`,`#66c2a4`,`#41ae76`,`#238b45`,`#006d2c`,`#00441b`],YlOrBr:[`#ffffe5`,`#fff7bc`,`#fee391`,`#fec44f`,`#fe9929`,`#ec7014`,`#cc4c02`,`#993404`,`#662506`],YlGn:[`#ffffe5`,`#f7fcb9`,`#d9f0a3`,`#addd8e`,`#78c679`,`#41ab5d`,`#238443`,`#006837`,`#004529`],Reds:[`#fff5f0`,`#fee0d2`,`#fcbba1`,`#fc9272`,`#fb6a4a`,`#ef3b2c`,`#cb181d`,`#a50f15`,`#67000d`],RdPu:[`#fff7f3`,`#fde0dd`,`#fcc5c0`,`#fa9fb5`,`#f768a1`,`#dd3497`,`#ae017e`,`#7a0177`,`#49006a`],Greens:[`#f7fcf5`,`#e5f5e0`,`#c7e9c0`,`#a1d99b`,`#74c476`,`#41ab5d`,`#238b45`,`#006d2c`,`#00441b`],YlGnBu:[`#ffffd9`,`#edf8b1`,`#c7e9b4`,`#7fcdbb`,`#41b6c4`,`#1d91c0`,`#225ea8`,`#253494`,`#081d58`],Purples:[`#fcfbfd`,`#efedf5`,`#dadaeb`,`#bcbddc`,`#9e9ac8`,`#807dba`,`#6a51a3`,`#54278f`,`#3f007d`],GnBu:[`#f7fcf0`,`#e0f3db`,`#ccebc5`,`#a8ddb5`,`#7bccc4`,`#4eb3d3`,`#2b8cbe`,`#0868ac`,`#084081`],Greys:[`#ffffff`,`#f0f0f0`,`#d9d9d9`,`#bdbdbd`,`#969696`,`#737373`,`#525252`,`#252525`,`#000000`],YlOrRd:[`#ffffcc`,`#ffeda0`,`#fed976`,`#feb24c`,`#fd8d3c`,`#fc4e2a`,`#e31a1c`,`#bd0026`,`#800026`],PuRd:[`#f7f4f9`,`#e7e1ef`,`#d4b9da`,`#c994c7`,`#df65b0`,`#e7298a`,`#ce1256`,`#980043`,`#67001f`],Blues:[`#f7fbff`,`#deebf7`,`#c6dbef`,`#9ecae1`,`#6baed6`,`#4292c6`,`#2171b5`,`#08519c`,`#08306b`],PuBuGn:[`#fff7fb`,`#ece2f0`,`#d0d1e6`,`#a6bddb`,`#67a9cf`,`#3690c0`,`#02818a`,`#016c59`,`#014636`],Viridis:[`#440154`,`#482777`,`#3f4a8a`,`#31678e`,`#26838f`,`#1f9d8a`,`#6cce5a`,`#b6de2b`,`#fee825`],Spectral:[`#9e0142`,`#d53e4f`,`#f46d43`,`#fdae61`,`#fee08b`,`#ffffbf`,`#e6f598`,`#abdda4`,`#66c2a5`,`#3288bd`,`#5e4fa2`],RdYlGn:[`#a50026`,`#d73027`,`#f46d43`,`#fdae61`,`#fee08b`,`#ffffbf`,`#d9ef8b`,`#a6d96a`,`#66bd63`,`#1a9850`,`#006837`],RdBu:[`#67001f`,`#b2182b`,`#d6604d`,`#f4a582`,`#fddbc7`,`#f7f7f7`,`#d1e5f0`,`#92c5de`,`#4393c3`,`#2166ac`,`#053061`],PiYG:[`#8e0152`,`#c51b7d`,`#de77ae`,`#f1b6da`,`#fde0ef`,`#f7f7f7`,`#e6f5d0`,`#b8e186`,`#7fbc41`,`#4d9221`,`#276419`],PRGn:[`#40004b`,`#762a83`,`#9970ab`,`#c2a5cf`,`#e7d4e8`,`#f7f7f7`,`#d9f0d3`,`#a6dba0`,`#5aae61`,`#1b7837`,`#00441b`],RdYlBu:[`#a50026`,`#d73027`,`#f46d43`,`#fdae61`,`#fee090`,`#ffffbf`,`#e0f3f8`,`#abd9e9`,`#74add1`,`#4575b4`,`#313695`],BrBG:[`#543005`,`#8c510a`,`#bf812d`,`#dfc27d`,`#f6e8c3`,`#f5f5f5`,`#c7eae5`,`#80cdc1`,`#35978f`,`#01665e`,`#003c30`],RdGy:[`#67001f`,`#b2182b`,`#d6604d`,`#f4a582`,`#fddbc7`,`#ffffff`,`#e0e0e0`,`#bababa`,`#878787`,`#4d4d4d`,`#1a1a1a`],PuOr:[`#7f3b08`,`#b35806`,`#e08214`,`#fdb863`,`#fee0b6`,`#f7f7f7`,`#d8daeb`,`#b2abd2`,`#8073ac`,`#542788`,`#2d004b`],Set2:[`#66c2a5`,`#fc8d62`,`#8da0cb`,`#e78ac3`,`#a6d854`,`#ffd92f`,`#e5c494`,`#b3b3b3`],Accent:[`#7fc97f`,`#beaed4`,`#fdc086`,`#ffff99`,`#386cb0`,`#f0027f`,`#bf5b17`,`#666666`],Set1:[`#e41a1c`,`#377eb8`,`#4daf4a`,`#984ea3`,`#ff7f00`,`#ffff33`,`#a65628`,`#f781bf`,`#999999`],Set3:[`#8dd3c7`,`#ffffb3`,`#bebada`,`#fb8072`,`#80b1d3`,`#fdb462`,`#b3de69`,`#fccde5`,`#d9d9d9`,`#bc80bd`,`#ccebc5`,`#ffed6f`],Dark2:[`#1b9e77`,`#d95f02`,`#7570b3`,`#e7298a`,`#66a61e`,`#e6ab02`,`#a6761d`,`#666666`],Paired:[`#a6cee3`,`#1f78b4`,`#b2df8a`,`#33a02c`,`#fb9a99`,`#e31a1c`,`#fdbf6f`,`#ff7f00`,`#cab2d6`,`#6a3d9a`,`#ffff99`,`#b15928`],Pastel2:[`#b3e2cd`,`#fdcdac`,`#cbd5e8`,`#f4cae4`,`#e6f5c9`,`#fff2ae`,`#f1e2cc`,`#cccccc`],Pastel1:[`#fbb4ae`,`#b3cde3`,`#ccebc5`,`#decbe4`,`#fed9a6`,`#ffffcc`,`#e5d8bd`,`#fddaec`,`#f2f2f2`]},UA=Object.keys(HA),WA=new Map(UA.map(e=>[e.toLowerCase(),e])),GA=typeof Proxy==`function`?new Proxy(HA,{get(e,t){let n=t.toLowerCase();if(WA.has(n))return e[WA.get(n)]},getOwnPropertyNames(){return Object.getOwnPropertyNames(UA)}}):HA,KA=(...e)=>{e=X(e,`cmyk`);let[t,n,r,i]=e,a=e.length>4?e[4]:1;return i===1?[0,0,0,a]:[t>=1?0:255*(1-t)*(1-i),n>=1?0:255*(1-n)*(1-i),r>=1?0:255*(1-r)*(1-i),a]},{max:qA}=Math,JA=(...e)=>{let[t,n,r]=X(e,`rgb`);t/=255,n/=255,r/=255;let i=1-qA(t,qA(n,r)),a=i<1?1/(1-i):0;return[(1-t-i)*a,(1-n-i)*a,(1-r-i)*a,i]};Q.prototype.cmyk=function(){return JA(this._rgb)},Object.assign($,{cmyk:(...e)=>new Q(...e,`cmyk`)}),Z.format.cmyk=KA,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`cmyk`),Y(e)===`array`&&e.length===4)return`cmyk`}});var YA=(...e)=>{let t=X(e,`hsla`),n=xO(e)||`lsa`;return t[0]=TO(t[0]||0)+`deg`,t[1]=TO(t[1]*100)+`%`,t[2]=TO(t[2]*100)+`%`,n===`hsla`||t.length>3&&t[3]<1?(t[3]=`/ `+(t.length>3?t[3]:1),n=`hsla`):t.length=3,`${n.substr(0,3)}(${t.join(` `)})`},XA=(...e)=>{let t=X(e,`lab`),n=xO(e)||`lab`;return t[0]=TO(t[0])+`%`,t[1]=TO(t[1]),t[2]=TO(t[2]),n===`laba`||t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`lab(${t.join(` `)})`},ZA=(...e)=>{let t=X(e,`lch`),n=xO(e)||`lab`;return t[0]=TO(t[0])+`%`,t[1]=TO(t[1]),t[2]=isNaN(t[2])?`none`:TO(t[2])+`deg`,n===`lcha`||t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`lch(${t.join(` `)})`},QA=(...e)=>{let t=X(e,`lab`);return t[0]=TO(t[0]*100)+`%`,t[1]=EO(t[1]),t[2]=EO(t[2]),t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`oklab(${t.join(` `)})`},$A=(...e)=>{let[t,n,r,...i]=X(e,`rgb`),[a,o,s]=zk(t,n,r),[c,l,u]=fk(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]},ej=(...e)=>{let t=X(e,`lch`);return t[0]=TO(t[0]*100)+`%`,t[1]=EO(t[1]),t[2]=isNaN(t[2])?`none`:TO(t[2])+`deg`,t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`oklch(${t.join(` `)})`},{round:tj}=Math,nj=(...e)=>{let t=X(e,`rgba`),n=xO(e)||`rgb`;if(n.substr(0,3)===`hsl`)return YA(Ak(t),n);if(n.substr(0,3)===`lab`){let e=HO();VO(`d50`);let r=XA(qO(t),n);return VO(e),r}if(n.substr(0,3)===`lch`){let e=HO();VO(`d50`);let r=ZA(pk(t),n);return VO(e),r}return n.substr(0,5)===`oklab`?QA(zk(t)):n.substr(0,5)===`oklch`?ej($A(t)):(t[0]=tj(t[0]),t[1]=tj(t[1]),t[2]=tj(t[2]),(n===`rgba`||t.length>3&&t[3]<1)&&(t[3]=`/ `+(t.length>3?t[3]:1),n=`rgba`),`${n.substr(0,3)}(${t.slice(0,n===`rgb`?3:4).join(` `)})`)},rj=(...e)=>{e=X(e,`lch`);let[t,n,r,...i]=e,[a,o,s]=ok(t,n,r),[c,l,u]=Lk(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]},ij=`((?:-?\\d+)|(?:-?\\d+(?:\\.\\d+)?)%|none)`,aj=`((?:-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)%?)|none)`,oj=`((?:-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)%)|none)`,sj=`\\s*`,cj=`\\s+`,lj=`\\s*,\\s*`,uj=`((?:-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:deg)?)|none)`,dj=`\\s*(?:\\/\\s*((?:[01]|[01]?\\.\\d+)|\\d+(?:\\.\\d+)?%))?`,fj=RegExp(`^rgba?\\(`+sj+[ij,ij,ij].join(cj)+dj+`\\)$`),pj=RegExp(`^rgb\\(`+sj+[ij,ij,ij].join(lj)+sj+`\\)$`),mj=RegExp(`^rgba\\(`+sj+[ij,ij,ij,aj].join(lj)+sj+`\\)$`),hj=RegExp(`^hsla?\\(`+sj+[uj,oj,oj].join(cj)+dj+`\\)$`),gj=RegExp(`^hsl?\\(`+sj+[uj,oj,oj].join(lj)+sj+`\\)$`),_j=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,vj=RegExp(`^lab\\(`+sj+[aj,aj,aj].join(cj)+dj+`\\)$`),yj=RegExp(`^lch\\(`+sj+[aj,aj,uj].join(cj)+dj+`\\)$`),bj=RegExp(`^oklab\\(`+sj+[aj,aj,aj].join(cj)+dj+`\\)$`),xj=RegExp(`^oklch\\(`+sj+[aj,aj,uj].join(cj)+dj+`\\)$`),{round:Sj}=Math,Cj=e=>e.map((e,t)=>t<=2?vO(Sj(e),0,255):e),wj=(e,t=0,n=100,r=!1)=>(typeof e==`string`&&e.endsWith(`%`)&&(e=parseFloat(e.substring(0,e.length-1))/100,e=r?t+(e+1)*.5*(n-t):t+e*(n-t)),+e),Tj=(e,t)=>e===`none`?t:e,Ej=e=>{if(e=e.toLowerCase().trim(),e===`transparent`)return[0,0,0,0];let t;if(Z.format.named)try{return Z.format.named(e)}catch{}if((t=e.match(fj))||(t=e.match(pj))){let e=t.slice(1,4);for(let t=0;t<3;t++)e[t]=+wj(Tj(e[t],0),0,255);e=Cj(e);let n=t[4]===void 0?1:+wj(t[4],0,1);return e[3]=n,e}if(t=e.match(mj)){let e=t.slice(1,5);for(let t=0;t<4;t++)e[t]=+wj(e[t],0,255);return e}if((t=e.match(hj))||(t=e.match(gj))){let e=t.slice(1,4);e[0]=+Tj(e[0].replace(`deg`,``),0),e[1]=wj(Tj(e[1],0),0,100)*.01,e[2]=wj(Tj(e[2],0),0,100)*.01;let n=Cj(kk(e));return n[3]=t[4]===void 0?1:+wj(t[4],0,1),n}if(t=e.match(_j)){let e=t.slice(1,4);e[1]*=.01,e[2]*=.01;let n=kk(e);for(let e=0;e<3;e++)n[e]=Sj(n[e]);return n[3]=+t[4],n}if(t=e.match(vj)){let e=t.slice(1,4);e[0]=wj(Tj(e[0],0),0,100),e[1]=wj(Tj(e[1],0),-125,125,!0),e[2]=wj(Tj(e[2],0),-125,125,!0);let n=HO();VO(`d50`);let r=Cj(UO(e));return VO(n),r[3]=t[4]===void 0?1:+wj(t[4],0,1),r}if(t=e.match(yj)){let e=t.slice(1,4);e[0]=wj(e[0],0,100),e[1]=wj(Tj(e[1],0),0,150,!1),e[2]=+Tj(e[2].replace(`deg`,``),0);let n=HO();VO(`d50`);let r=Cj(sk(e));return VO(n),r[3]=t[4]===void 0?1:+wj(t[4],0,1),r}if(t=e.match(bj)){let e=t.slice(1,4);e[0]=wj(Tj(e[0],0),0,1),e[1]=wj(Tj(e[1],0),-.4,.4,!0),e[2]=wj(Tj(e[2],0),-.4,.4,!0);let n=Cj(Lk(e));return n[3]=t[4]===void 0?1:+wj(t[4],0,1),n}if(t=e.match(xj)){let e=t.slice(1,4);e[0]=wj(Tj(e[0],0),0,1),e[1]=wj(Tj(e[1],0),0,.4,!1),e[2]=+Tj(e[2].replace(`deg`,``),0);let n=Cj(rj(e));return n[3]=t[4]===void 0?1:+wj(t[4],0,1),n}};Ej.test=e=>fj.test(e)||hj.test(e)||vj.test(e)||yj.test(e)||bj.test(e)||xj.test(e)||pj.test(e)||mj.test(e)||gj.test(e)||_j.test(e)||e===`transparent`,Q.prototype.css=function(e){return nj(this._rgb,e)},$.css=(...e)=>new Q(...e,`css`),Z.format.css=Ej,Z.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&Y(e)===`string`&&Ej.test(e))return`css`}}),Z.format.gl=(...e)=>{let t=X(e,`rgba`);return t[0]*=255,t[1]*=255,t[2]*=255,t},$.gl=(...e)=>new Q(...e,`gl`),Q.prototype.gl=function(){let e=this._rgb;return[e[0]/255,e[1]/255,e[2]/255,e[3]]},Q.prototype.hex=function(e){return RO(this._rgb,e)},$.hex=(...e)=>new Q(...e,`hex`),Z.format.hex=IO,Z.autodetect.push({p:4,test:(e,...t)=>{if(!t.length&&Y(e)===`string`&&[3,4,5,6,7,8,9].indexOf(e.length)>=0)return`hex`}});var{log:Dj}=Math,Oj=e=>{let t=e/100,n,r,i;return t<66?(n=255,r=t<6?0:-155.25485562709179-.44596950469579133*(r=t-2)+104.49216199393888*Dj(r),i=t<20?0:-254.76935184120902+.8274096064007395*(i=t-10)+115.67994401066147*Dj(i)):(n=351.97690566805693+.114206453784165*(n=t-55)-40.25366309332127*Dj(n),r=325.4494125711974+.07943456536662342*(r=t-50)-28.0852963507957*Dj(r),i=255),[n,r,i,1]},{round:kj}=Math,Aj=(...e)=>{let t=X(e,`rgb`),n=t[0],r=t[2],i=1e3,a=4e4,o;for(;a-i>.4;){o=(a+i)*.5;let e=Oj(o);e[2]/e[0]>=r/n?a=o:i=o}return kj(o)};Q.prototype.temp=Q.prototype.kelvin=Q.prototype.temperature=function(){return Aj(this._rgb)};var jj=(...e)=>new Q(...e,`temp`);Object.assign($,{temp:jj,kelvin:jj,temperature:jj}),Z.format.temp=Z.format.kelvin=Z.format.temperature=Oj,Q.prototype.oklch=function(){return $A(this._rgb)},Object.assign($,{oklch:(...e)=>new Q(...e,`oklch`)}),Z.format.oklch=rj,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`oklch`),Y(e)===`array`&&e.length===3)return`oklch`}}),Object.assign($,{analyze:_A,average:qk,bezier:eA,blend:nA,brewer:GA,Color:Q,colors:NO,contrast:yA,contrastAPCA:EA,cubehelix:cA,deltaE:RA,distance:zA,input:Z,interpolate:rk,limits:vA,mix:rk,random:fA,scale:Xk,scales:VA,valid:BA});var Mj=()=>window.location.hostname.includes(`greenhouse`),Nj=()=>window.location.hostname.includes(`typo3`),Pj=e=>Nj()||Mj()||Fj(e),Fj=e=>!!e.ownerDocument.defaultView?.frameElement,Ij=e=>{let t=getComputedStyle(e),n=t.position===`absolute`,r=/(auto|scroll)/;if(t.position===`fixed`)return document.body;for(let i=e;i=i.parentElement;)if(t=getComputedStyle(i),!(n&&t.position===`static`)&&r.test(t.overflow+t.overflowY+t.overflowX))return i;return document.body},Lj=c((e=>{e.CASE_SENSITIVE_TAG_NAMES_MAP=`animateMotion.animateTransform.clipPath.feBlend.feColorMatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feDropShadow.feFlood.feFuncA.feFuncB.feFuncG.feFuncR.feGaussianBlur.feImage.feMerge.feMergeNode.feMorphology.feOffset.fePointLight.feSpecularLighting.feSpotLight.feTile.feTurbulence.foreignObject.linearGradient.radialGradient.textPath`.split(`.`).reduce((e,t)=>(e[t.toLowerCase()]=t,e),{})}));function Rj(e){return e.type===zj.Tag||e.type===zj.Script||e.type===zj.Style}var zj,Bj=s((()=>{(function(e){e.Root=`root`,e.Text=`text`,e.Directive=`directive`,e.Comment=`comment`,e.Script=`script`,e.Style=`style`,e.Tag=`tag`,e.CDATA=`cdata`,e.Doctype=`doctype`})(zj||={}),zj.Root,zj.Text,zj.Directive,zj.Comment,zj.Script,zj.Style,zj.Tag,zj.CDATA,zj.Doctype}));function Vj(e){return Rj(e)}function Hj(e){return e.type===zj.CDATA}function Uj(e){return e.type===zj.Text}function Wj(e){return e.type===zj.Comment}function Gj(e){return e.type===zj.Directive}function Kj(e){return e.type===zj.Root}function qj(e){return Object.hasOwn(e,`children`)}function Jj(e,t=!1){let n;if(Uj(e))n=new Qj(e.data);else if(Wj(e))n=new $j(e.data);else if(Vj(e)){let r=t?Yj(e.children):[],i=new iM(e.name,{...e.attribs},r);for(let e of r)e.parent=i;e.namespace!=null&&(i.namespace=e.namespace),e[`x-attribsNamespace`]&&(i[`x-attribsNamespace`]={...e[`x-attribsNamespace`]}),e[`x-attribsPrefix`]&&(i[`x-attribsPrefix`]={...e[`x-attribsPrefix`]}),n=i}else if(Hj(e)){let r=t?Yj(e.children):[],i=new nM(r);for(let e of r)e.parent=i;n=i}else if(Kj(e)){let r=t?Yj(e.children):[],i=new rM(r);for(let e of r)e.parent=i;e[`x-mode`]&&(i[`x-mode`]=e[`x-mode`]),n=i}else if(Gj(e)){let t=new eM(e.name,e.data);e[`x-name`]!=null&&(t[`x-name`]=e[`x-name`],t[`x-publicId`]=e[`x-publicId`],t[`x-systemId`]=e[`x-systemId`]),n=t}else throw Error(`Not implemented yet: ${e.type}`);return n.startIndex=e.startIndex,n.endIndex=e.endIndex,e.sourceCodeLocation!=null&&(n.sourceCodeLocation=e.sourceCodeLocation),n}function Yj(e){let t=e.map(e=>Jj(e,!0));for(let e=1;e<t.length;e++)t[e].prev=t[e-1],t[e-1].next=t[e];return t}var Xj,Zj,Qj,$j,eM,tM,nM,rM,iM,aM=s((()=>{Bj(),Xj=class{parent=null;prev=null;next=null;startIndex=null;endIndex=null;get parentNode(){return this.parent}set parentNode(e){this.parent=e}get previousSibling(){return this.prev}set previousSibling(e){this.prev=e}get nextSibling(){return this.next}set nextSibling(e){this.next=e}cloneNode(e=!1){return Jj(this,e)}},Zj=class extends Xj{data;constructor(e){super(),this.data=e}get nodeValue(){return this.data}set nodeValue(e){this.data=e}},Qj=class extends Zj{type=zj.Text;get nodeType(){return 3}},$j=class extends Zj{type=zj.Comment;get nodeType(){return 8}},eM=class extends Zj{type=zj.Directive;name;constructor(e,t){super(t),this.name=e}get nodeType(){return 1}"x-name";"x-publicId";"x-systemId"},tM=class extends Xj{children;constructor(e){super(),this.children=e}get firstChild(){return this.children[0]??null}get lastChild(){return this.children.length>0?this.children[this.children.length-1]:null}get childNodes(){return this.children}set childNodes(e){this.children=e}},nM=class extends tM{type=zj.CDATA;get nodeType(){return 4}},rM=class extends tM{type=zj.Root;get nodeType(){return 9}},iM=class extends tM{name;attribs;type;constructor(e,t,n=[],r=e===`script`?zj.Script:e===`style`?zj.Style:zj.Tag){super(n),this.name=e,this.attribs=t,this.type=r}get nodeType(){return 1}get tagName(){return this.name}set tagName(e){this.name=e}get attributes(){return Object.keys(this.attribs).map(e=>({name:e,value:this.attribs[e],namespace:this[`x-attribsNamespace`]?.[e],prefix:this[`x-attribsPrefix`]?.[e]}))}namespace;"x-attribsNamespace";"x-attribsPrefix"}})),oM=l({CDATA:()=>nM,Comment:()=>$j,DataNode:()=>Zj,Document:()=>rM,DomHandler:()=>cM,Element:()=>iM,Node:()=>Xj,NodeWithChildren:()=>tM,ProcessingInstruction:()=>eM,Text:()=>Qj,cloneNode:()=>Jj,default:()=>cM,hasChildren:()=>qj,isCDATA:()=>Hj,isComment:()=>Wj,isDirective:()=>Gj,isDocument:()=>Kj,isTag:()=>Vj,isText:()=>Uj}),sM,cM,lM=s((()=>{Bj(),aM(),aM(),sM={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},cM=class{dom=[];root=new rM(this.dom);callback;options;elementCB;done=!1;tagStack=[this.root];lastNode=null;parser=null;constructor(e,t,n){typeof t==`function`&&(n=t,t=sM),typeof e==`object`&&(t=e,e=void 0),this.callback=e??null,this.options=t??sM,this.elementCB=n??null}onparserinit(e){this.parser=e}onreset(){this.dom=[],this.root=new rM(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null}onend(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))}onerror(e){this.handleCallback(e)}onclosetag(){this.lastNode=null;let e=this.tagStack.pop();this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)}onopentag(e,t){let n=this.options.xmlMode?zj.Tag:void 0,r=new iM(e,t,void 0,n);this.addNode(r),this.tagStack.push(r)}ontext(e){let{lastNode:t}=this;if(t&&t.type===zj.Text)t.data+=e,this.options.withEndIndices&&this.parser&&(t.endIndex=this.parser.endIndex);else{let t=new Qj(e);this.addNode(t),this.lastNode=t}}oncomment(e){if(this.lastNode&&this.lastNode.type===zj.Comment){this.lastNode.data+=e;return}let t=new $j(e);this.addNode(t),this.lastNode=t}oncommentend(){this.lastNode=null}oncdatastart(){let e=new Qj(``),t=new nM([e]);this.addNode(t),e.parent=t,this.lastNode=e}oncdataend(){this.lastNode=null}onprocessinginstruction(e,t){let n=new eM(e,t);this.addNode(n)}handleCallback(e){if(typeof this.callback==`function`)this.callback(e,this.dom);else if(e)throw e}addNode(e){let t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&this.parser&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null}}})),uM=c((e=>{var t=Lj(),n=(lM(),f(oM)),r=`\r`,i=new RegExp(r,`g`),a=`__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_${Date.now().toString()}__`,o=new RegExp(a,`g`);function s(e){return t.CASE_SENSITIVE_TAG_NAMES_MAP[e]}function c(e){let t={},n=0,r=e.length;for(;n<r;n++){let r=e[n];t[r.name]=r.value}return t}function l(e){return e=e.toLowerCase(),s(e)||e}function u(e,t){let n=`<`+t,r=e.toLowerCase().indexOf(n);if(r===-1)return!1;let i=e[r+n.length];return i===`>`||i===` `||i===` `||i===`
146
- `||i===`\r`||i===`/`}function d(e){return e.replace(i,a)}function p(e){return e.replace(o,r)}function m(e,t=null,r){let i=[],a,o=0,s=e.length;for(;o<s;o++){let r=e[o];switch(r.nodeType){case 1:{let e=l(r.nodeName);a=new n.Element(e,c(r.attributes)),a.children=m(e===`template`?r.content.childNodes:r.childNodes,a);break}case 3:a=new n.Text(p(r.nodeValue??``));break;case 8:a=new n.Comment(r.nodeValue??``);break;default:continue}let s=i[o-1]??null;s&&(s.next=a),a.parent=t,a.prev=s,a.next=null,i.push(a)}return r&&(a=new n.ProcessingInstruction(r.substring(0,r.indexOf(` `)).toLowerCase(),r),a.next=i[0]??null,a.parent=t,i.unshift(a),i[1]&&(i[1].prev=i[0])),i}e.escapeSpecialCharacters=d,e.formatDOM=m,e.hasOpenTag=u})),dM=c((e=>{var t=uM(),n=`html`,r=`head`,i=`body`,a=/<([a-zA-Z]+[0-9]?)/;function o(e,t){return t?t.createHTML(e):e}var s=(e,t,n)=>{throw Error("This browser does not support `document.implementation.createHTMLDocument`")},c=(e,t,n)=>{throw Error("This browser does not support `DOMParser.prototype.parseFromString`")},l=typeof window==`object`&&window.DOMParser;if(typeof l==`function`){let e=new l;c=(t,n,r)=>(n&&(t=`<${n}>${t}</${n}>`),e.parseFromString(t,`text/html`)),s=c}if(typeof document==`object`&&document.implementation){let e=document.implementation.createHTMLDocument();s=function(t,n,r){if(n){let i=e.documentElement.querySelector(n);return i&&(i.innerHTML=o(t,r)),e}return e.documentElement.innerHTML=o(t,r),e}}var u=typeof document==`object`&&document.createElement(`template`),d;u&&u.content&&(d=(e,t)=>(u.innerHTML=o(e,t),u.content.childNodes));var f=()=>document.createDocumentFragment().childNodes;function p(e,o){e=t.escapeSpecialCharacters(e);let l=a.exec(e)?.[1]?.toLowerCase();switch(l){case n:{let a=c(e);if(!t.hasOpenTag(e,r)){let e=a.querySelector(r);e?.parentNode?.removeChild(e)}if(!t.hasOpenTag(e,i)){let e=a.querySelector(i);e?.parentNode?.removeChild(e)}return a.querySelectorAll(n)}case r:case i:{let n=s(e,void 0,o).querySelectorAll(l);return t.hasOpenTag(e,i)&&t.hasOpenTag(e,r)?n[0].parentNode?.childNodes??f():n}default:return d?d(e,o):s(e,i,o).querySelector(i)?.childNodes??f()}}e.default=p})),fM=c((e=>{Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});var t=uM(),n=dM(),r=/<(![a-zA-Z\s]+)>/;function i(e,i){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];let a=r.exec(e),o=a?a[1]:void 0;return t.formatDOM(n.default(e,i?.trustedTypePolicy),null,o)}e.default=i})),pM=c((e=>{e.SAME=0,e.CAMELCASE=1,e.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":`acceptCharset`,accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:`className`,classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:`htmlFor`,form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":`httpEquiv`,icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":`accentHeight`,accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":`alignmentBaseline`,allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":`arabicForm`,ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":`baselineShift`,baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":`capHeight`,clip:0,clipPath:1,"clip-path":`clipPath`,clipPathUnits:1,clipRule:1,"clip-rule":`clipRule`,color:0,colorInterpolation:1,"color-interpolation":`colorInterpolation`,colorInterpolationFilters:1,"color-interpolation-filters":`colorInterpolationFilters`,colorProfile:1,"color-profile":`colorProfile`,colorRendering:1,"color-rendering":`colorRendering`,contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":`dominantBaseline`,dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":`enableBackground`,end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":`fillOpacity`,fillRule:1,"fill-rule":`fillRule`,filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":`floodOpacity`,floodColor:1,"flood-color":`floodColor`,focusable:0,fontFamily:1,"font-family":`fontFamily`,fontSize:1,"font-size":`fontSize`,fontSizeAdjust:1,"font-size-adjust":`fontSizeAdjust`,fontStretch:1,"font-stretch":`fontStretch`,fontStyle:1,"font-style":`fontStyle`,fontVariant:1,"font-variant":`fontVariant`,fontWeight:1,"font-weight":`fontWeight`,format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":`glyphName`,glyphOrientationHorizontal:1,"glyph-orientation-horizontal":`glyphOrientationHorizontal`,glyphOrientationVertical:1,"glyph-orientation-vertical":`glyphOrientationVertical`,glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":`horizAdvX`,horizOriginX:1,"horiz-origin-x":`horizOriginX`,ideographic:0,imageRendering:1,"image-rendering":`imageRendering`,in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":`letterSpacing`,lightingColor:1,"lighting-color":`lightingColor`,limitingConeAngle:1,local:0,markerEnd:1,"marker-end":`markerEnd`,markerHeight:1,markerMid:1,"marker-mid":`markerMid`,markerStart:1,"marker-start":`markerStart`,markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":`overlinePosition`,overlineThickness:1,"overline-thickness":`overlineThickness`,paintOrder:1,"paint-order":`paintOrder`,panose1:0,"panose-1":`panose1`,pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":`pointerEvents`,points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":`renderingIntent`,repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":`shapeRendering`,slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":`stopColor`,stopOpacity:1,"stop-opacity":`stopOpacity`,strikethroughPosition:1,"strikethrough-position":`strikethroughPosition`,strikethroughThickness:1,"strikethrough-thickness":`strikethroughThickness`,string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":`strokeDasharray`,strokeDashoffset:1,"stroke-dashoffset":`strokeDashoffset`,strokeLinecap:1,"stroke-linecap":`strokeLinecap`,strokeLinejoin:1,"stroke-linejoin":`strokeLinejoin`,strokeMiterlimit:1,"stroke-miterlimit":`strokeMiterlimit`,strokeWidth:1,"stroke-width":`strokeWidth`,strokeOpacity:1,"stroke-opacity":`strokeOpacity`,suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":`textAnchor`,textDecoration:1,"text-decoration":`textDecoration`,textLength:1,textRendering:1,"text-rendering":`textRendering`,to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":`underlinePosition`,underlineThickness:1,"underline-thickness":`underlineThickness`,unicode:0,unicodeBidi:1,"unicode-bidi":`unicodeBidi`,unicodeRange:1,"unicode-range":`unicodeRange`,unitsPerEm:1,"units-per-em":`unitsPerEm`,unselectable:0,vAlphabetic:1,"v-alphabetic":`vAlphabetic`,values:0,vectorEffect:1,"vector-effect":`vectorEffect`,version:0,vertAdvY:1,"vert-adv-y":`vertAdvY`,vertOriginX:1,"vert-origin-x":`vertOriginX`,vertOriginY:1,"vert-origin-y":`vertOriginY`,vHanging:1,"v-hanging":`vHanging`,vIdeographic:1,"v-ideographic":`vIdeographic`,viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":`vMathematical`,vocab:0,widths:0,wordSpacing:1,"word-spacing":`wordSpacing`,writingMode:1,"writing-mode":`writingMode`,x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":`xHeight`,xlinkActuate:1,"xlink:actuate":`xlinkActuate`,xlinkArcrole:1,"xlink:arcrole":`xlinkArcrole`,xlinkHref:1,"xlink:href":`xlinkHref`,xlinkRole:1,"xlink:role":`xlinkRole`,xlinkShow:1,"xlink:show":`xlinkShow`,xlinkTitle:1,"xlink:title":`xlinkTitle`,xlinkType:1,"xlink:type":`xlinkType`,xmlBase:1,"xml:base":`xmlBase`,xmlLang:1,"xml:lang":`xmlLang`,xmlns:0,"xml:space":`xmlSpace`,xmlnsXlink:1,"xmlns:xlink":`xmlnsXlink`,xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1}})),mM=c((e=>{var t=0,n=1,r=2,i=3,a=4,o=5,s=6;function c(e){return u.hasOwnProperty(e)?u[e]:null}function l(e,t,n,o,s,c,l){this.acceptsBooleans=t===r||t===i||t===a,this.attributeName=o,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=c,this.removeEmptyString=l}var u={};[`children`,`dangerouslySetInnerHTML`,`defaultValue`,`defaultChecked`,`innerHTML`,`suppressContentEditableWarning`,`suppressHydrationWarning`,`style`].forEach(e=>{u[e]=new l(e,t,!1,e,null,!1,!1)}),[[`acceptCharset`,`accept-charset`],[`className`,`class`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`]].forEach(([e,t])=>{u[e]=new l(e,n,!1,t,null,!1,!1)}),[`contentEditable`,`draggable`,`spellCheck`,`value`].forEach(e=>{u[e]=new l(e,r,!1,e.toLowerCase(),null,!1,!1)}),[`autoReverse`,`externalResourcesRequired`,`focusable`,`preserveAlpha`].forEach(e=>{u[e]=new l(e,r,!1,e,null,!1,!1)}),[`allowFullScreen`,`async`,`autoFocus`,`autoPlay`,`controls`,`default`,`defer`,`disabled`,`disablePictureInPicture`,`disableRemotePlayback`,`formNoValidate`,`hidden`,`loop`,`noModule`,`noValidate`,`open`,`playsInline`,`readOnly`,`required`,`reversed`,`scoped`,`seamless`,`itemScope`].forEach(e=>{u[e]=new l(e,i,!1,e.toLowerCase(),null,!1,!1)}),[`checked`,`multiple`,`muted`,`selected`].forEach(e=>{u[e]=new l(e,i,!0,e,null,!1,!1)}),[`capture`,`download`].forEach(e=>{u[e]=new l(e,a,!1,e,null,!1,!1)}),[`cols`,`rows`,`size`,`span`].forEach(e=>{u[e]=new l(e,s,!1,e,null,!1,!1)}),[`rowSpan`,`start`].forEach(e=>{u[e]=new l(e,o,!1,e.toLowerCase(),null,!1,!1)});var d=/[\-\:]([a-z])/g,f=e=>e[1].toUpperCase();`accent-height.alignment-baseline.arabic-form.baseline-shift.cap-height.clip-path.clip-rule.color-interpolation.color-interpolation-filters.color-profile.color-rendering.dominant-baseline.enable-background.fill-opacity.fill-rule.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.glyph-name.glyph-orientation-horizontal.glyph-orientation-vertical.horiz-adv-x.horiz-origin-x.image-rendering.letter-spacing.lighting-color.marker-end.marker-mid.marker-start.overline-position.overline-thickness.paint-order.panose-1.pointer-events.rendering-intent.shape-rendering.stop-color.stop-opacity.strikethrough-position.strikethrough-thickness.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke-width.text-anchor.text-decoration.text-rendering.underline-position.underline-thickness.unicode-bidi.unicode-range.units-per-em.v-alphabetic.v-hanging.v-ideographic.v-mathematical.vector-effect.vert-adv-y.vert-origin-x.vert-origin-y.word-spacing.writing-mode.xmlns:xlink.x-height`.split(`.`).forEach(e=>{let t=e.replace(d,f);u[t]=new l(t,n,!1,e,null,!1,!1)}),[`xlink:actuate`,`xlink:arcrole`,`xlink:role`,`xlink:show`,`xlink:title`,`xlink:type`].forEach(e=>{let t=e.replace(d,f);u[t]=new l(t,n,!1,e,`http://www.w3.org/1999/xlink`,!1,!1)}),[`xml:base`,`xml:lang`,`xml:space`].forEach(e=>{let t=e.replace(d,f);u[t]=new l(t,n,!1,e,`http://www.w3.org/XML/1998/namespace`,!1,!1)}),[`tabIndex`,`crossOrigin`].forEach(e=>{u[e]=new l(e,n,!1,e.toLowerCase(),null,!1,!1)});var p=`xlinkHref`;u[p]=new l(`xlinkHref`,n,!1,`xlink:href`,`http://www.w3.org/1999/xlink`,!0,!1),[`src`,`href`,`action`,`formAction`].forEach(e=>{u[e]=new l(e,n,!1,e.toLowerCase(),null,!0,!0)});var{CAMELCASE:m,SAME:h,possibleStandardNames:g}=pM(),_=RegExp.prototype.test.bind(RegExp(`^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`)),v=Object.keys(g).reduce((e,t)=>{let n=g[t];return n===h?e[t]=t:n===m?e[t.toLowerCase()]=t:e[t]=n,e},{});e.BOOLEAN=i,e.BOOLEANISH_STRING=r,e.NUMERIC=o,e.OVERLOADED_BOOLEAN=a,e.POSITIVE_NUMERIC=s,e.RESERVED=t,e.STRING=n,e.getPropertyInfo=c,e.isCustomAttribute=_,e.possibleStandardNames=v})),hM=c(((e,t)=>{var n=/\/\*(?:[^*]|\*(?!\/))*\*\//g,r=/\n/g,i=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\.|[^'\\])*'|"(?:\\.|[^"\\])*"|url\((?:'(?:\\.|[^'\\])*'|"(?:\\.|[^"\\])*"|[^)]*)\)|[^};])+)/,c=/^[;\s]*/;function l(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,u=1;function d(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(`
147
- `);u=~n?e.length-n:u+e.length}function f(){var e={line:l,column:u};return function(t){return t.position=new p(e),g(),t}}function p(e){this.start=e,this.end={line:l,column:u},this.source=t.source}p.prototype.content=e;function m(n){var r=Error(t.source+`:`+l+`:`+u+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=u,r.source=e,!t.silent)throw r}function h(t){var n=t.exec(e);if(n){var r=n[0];return d(r),e=e.slice(r.length),n}}function g(){h(i)}function _(e){for(var t;t=v();)e.push(t);return e}function v(){var t=f();if(e.charAt(0)==`/`&&e.charAt(1)==`*`){for(var n=2;e.charAt(n)!=``&&(e.charAt(n)!=`*`||e.charAt(n+1)!=`/`);)++n;if(n+=2,e.charAt(n-1)===``)return m(`End of comment missing`);var r=e.slice(2,n-2);return u+=2,d(r),e=e.slice(n),u+=2,t({type:`comment`,comment:r})}}function y(){var e=f(),t=h(a);if(t){if(v(),!h(o))return m(`property missing ':'`);var r=h(s),i=e({type:`declaration`,property:t[0].replace(n,``).trim(),value:r?r[0].replace(n,``).trim():``});return h(c),i}}function b(){var e=[];_(e);for(var t;t=y();)e.push(t),_(e);return e}return g(),b()}t.exports=l})),gM=c(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,c=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=a(t),l=0,u=c.length,d;l<u;l++)d=c[l],!s.call(e,d)&&d!==n&&r(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(o=i(t,d))||o.enumerable});return e},l=(e,t,i)=>(i=e==null?{}:n(o(e)),c(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),u=hM();u=l(u);function d(e,t){let n=null;if(!e||typeof e!=`string`)return n;let r=(0,u.default)(e),i=typeof t==`function`;return r.forEach(e=>{if(e.type!==`declaration`)return;let{property:r,value:a}=e;i?t(r,a,e):a&&(n??={},n[r]=a)}),n}t.exports=d})),_M=c(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,c=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=a(t),l=0,u=c.length,d;l<u;l++)d=c[l],!s.call(e,d)&&d!==n&&r(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(o=i(t,d))||o.enumerable});return e},l=(e,t,i)=>(i=e==null?{}:n(o(e)),c(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),u=gM();u=l(u);var d=/^--[a-zA-Z0-9_-]+$/,f=/-([a-z])/g,p=/^[^-]+$/,m=/^-(webkit|moz|ms|o|khtml)-/,h=/^-(ms)-/,g=e=>!e||p.test(e)||d.test(e),_=(e,t)=>t.toUpperCase(),v=(e,t)=>`${t}-`,y=(e,t={})=>g(e)?e:(e=e.toLowerCase(),e=t.reactCompat?e.replace(h,v):e.replace(m,v),e.replace(f,_));function b(e,t){let n={};return!e||typeof e!=`string`||(0,u.default)(e,(e,r)=>{e&&r&&(n[y(e,t)]=r)}),n}t.exports=b})),vM=c((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.returnFirstArg=e.canTextBeChildOfNode=e.ELEMENTS_WITH_NO_TEXT_CHILDREN=e.PRESERVE_CUSTOM_ATTRIBUTES=void 0,e.isCustomComponent=a,e.setStyleProp=s;var n=ry(),r=t(_M()),i=new Set([`annotation-xml`,`color-profile`,`font-face`,`font-face-src`,`font-face-uri`,`font-face-format`,`font-face-name`,`missing-glyph`]);function a(e,t){return e.includes(`-`)?!i.has(e):!!(t&&typeof t.is==`string`)}var o={reactCompat:!0};function s(e,t){if(typeof e==`string`){if(!e.trim()){t.style={};return}try{t.style=(0,r.default)(e,o)}catch{t.style={}}}}e.PRESERVE_CUSTOM_ATTRIBUTES=Number(n.version.split(`.`)[0])>=16,e.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set([`tr`,`tbody`,`thead`,`tfoot`,`colgroup`,`table`,`head`,`html`,`frameset`]),e.canTextBeChildOfNode=t=>!e.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(t.name),e.returnFirstArg=e=>e})),yM=c((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var t=mM(),n=vM(),r=[`checked`,`value`],i=[`input`,`select`,`textarea`],a={reset:!0,submit:!0};function o(e={},o){let c={},l=!!(e.type&&a[e.type]);for(let a in e){let u=e[a];if((0,t.isCustomAttribute)(a)){c[a]=u;continue}let d=a.toLowerCase(),f=s(d);if(f){let e=(0,t.getPropertyInfo)(f);switch(r.includes(f)&&i.includes(o)&&!l&&(f=s(`default`+d)),c[f]=u,e?.type){case t.BOOLEAN:c[f]=!0;break;case t.OVERLOADED_BOOLEAN:u===``&&(c[f]=!0)}continue}n.PRESERVE_CUSTOM_ATTRIBUTES&&(c[a]=u)}return(0,n.setStyleProp)(e.style,c),c}function s(e){return t.possibleStandardNames[e]}}));function bM(e){return e.type===xM.Tag||e.type===xM.Script||e.type===xM.Style}var xM,SM=s((()=>{(function(e){e.Root=`root`,e.Text=`text`,e.Directive=`directive`,e.Comment=`comment`,e.Script=`script`,e.Style=`style`,e.Tag=`tag`,e.CDATA=`cdata`,e.Doctype=`doctype`})(xM||={}),xM.Root,xM.Text,xM.Directive,xM.Comment,xM.Script,xM.Style,xM.Tag,xM.CDATA,xM.Doctype}));function CM(e){return bM(e)}function wM(e){return e.type===xM.CDATA}function TM(e){return e.type===xM.Text}function EM(e){return e.type===xM.Comment}function DM(e){return e.type===xM.Directive}function OM(e){return e.type===xM.Root}function kM(e){return Object.hasOwn(e,`children`)}function AM(e,t=!1){let n;if(TM(e))n=new PM(e.data);else if(EM(e))n=new FM(e.data);else if(CM(e)){let r=t?jM(e.children):[],i=new BM(e.name,{...e.attribs},r);for(let e of r)e.parent=i;e.namespace!=null&&(i.namespace=e.namespace),e[`x-attribsNamespace`]&&(i[`x-attribsNamespace`]={...e[`x-attribsNamespace`]}),e[`x-attribsPrefix`]&&(i[`x-attribsPrefix`]={...e[`x-attribsPrefix`]}),n=i}else if(wM(e)){let r=t?jM(e.children):[],i=new RM(r);for(let e of r)e.parent=i;n=i}else if(OM(e)){let r=t?jM(e.children):[],i=new zM(r);for(let e of r)e.parent=i;e[`x-mode`]&&(i[`x-mode`]=e[`x-mode`]),n=i}else if(DM(e)){let t=new IM(e.name,e.data);e[`x-name`]!=null&&(t[`x-name`]=e[`x-name`],t[`x-publicId`]=e[`x-publicId`],t[`x-systemId`]=e[`x-systemId`]),n=t}else throw Error(`Not implemented yet: ${e.type}`);return n.startIndex=e.startIndex,n.endIndex=e.endIndex,e.sourceCodeLocation!=null&&(n.sourceCodeLocation=e.sourceCodeLocation),n}function jM(e){let t=e.map(e=>AM(e,!0));for(let e=1;e<t.length;e++)t[e].prev=t[e-1],t[e-1].next=t[e];return t}var MM,NM,PM,FM,IM,LM,RM,zM,BM,VM=s((()=>{SM(),MM=class{parent=null;prev=null;next=null;startIndex=null;endIndex=null;get parentNode(){return this.parent}set parentNode(e){this.parent=e}get previousSibling(){return this.prev}set previousSibling(e){this.prev=e}get nextSibling(){return this.next}set nextSibling(e){this.next=e}cloneNode(e=!1){return AM(this,e)}},NM=class extends MM{data;constructor(e){super(),this.data=e}get nodeValue(){return this.data}set nodeValue(e){this.data=e}},PM=class extends NM{type=xM.Text;get nodeType(){return 3}},FM=class extends NM{type=xM.Comment;get nodeType(){return 8}},IM=class extends NM{type=xM.Directive;name;constructor(e,t){super(t),this.name=e}get nodeType(){return 1}"x-name";"x-publicId";"x-systemId"},LM=class extends MM{children;constructor(e){super(),this.children=e}get firstChild(){return this.children[0]??null}get lastChild(){return this.children.length>0?this.children[this.children.length-1]:null}get childNodes(){return this.children}set childNodes(e){this.children=e}},RM=class extends LM{type=xM.CDATA;get nodeType(){return 4}},zM=class extends LM{type=xM.Root;get nodeType(){return 9}},BM=class extends LM{name;attribs;type;constructor(e,t,n=[],r=e===`script`?xM.Script:e===`style`?xM.Style:xM.Tag){super(n),this.name=e,this.attribs=t,this.type=r}get nodeType(){return 1}get tagName(){return this.name}set tagName(e){this.name=e}get attributes(){return Object.keys(this.attribs).map(e=>({name:e,value:this.attribs[e],namespace:this[`x-attribsNamespace`]?.[e],prefix:this[`x-attribsPrefix`]?.[e]}))}namespace;"x-attribsNamespace";"x-attribsPrefix"}})),HM=l({CDATA:()=>RM,Comment:()=>FM,DataNode:()=>NM,Document:()=>zM,DomHandler:()=>WM,Element:()=>BM,Node:()=>MM,NodeWithChildren:()=>LM,ProcessingInstruction:()=>IM,Text:()=>PM,cloneNode:()=>AM,default:()=>WM,hasChildren:()=>kM,isCDATA:()=>wM,isComment:()=>EM,isDirective:()=>DM,isDocument:()=>OM,isTag:()=>CM,isText:()=>TM}),UM,WM,GM=s((()=>{SM(),VM(),VM(),UM={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},WM=class{dom=[];root=new zM(this.dom);callback;options;elementCB;done=!1;tagStack=[this.root];lastNode=null;parser=null;constructor(e,t,n){typeof t==`function`&&(n=t,t=UM),typeof e==`object`&&(t=e,e=void 0),this.callback=e??null,this.options=t??UM,this.elementCB=n??null}onparserinit(e){this.parser=e}onreset(){this.dom=[],this.root=new zM(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null}onend(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))}onerror(e){this.handleCallback(e)}onclosetag(){this.lastNode=null;let e=this.tagStack.pop();this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)}onopentag(e,t){let n=this.options.xmlMode?xM.Tag:void 0,r=new BM(e,t,void 0,n);this.addNode(r),this.tagStack.push(r)}ontext(e){let{lastNode:t}=this;if(t&&t.type===xM.Text)t.data+=e,this.options.withEndIndices&&this.parser&&(t.endIndex=this.parser.endIndex);else{let t=new PM(e);this.addNode(t),this.lastNode=t}}oncomment(e){if(this.lastNode&&this.lastNode.type===xM.Comment){this.lastNode.data+=e;return}let t=new FM(e);this.addNode(t),this.lastNode=t}oncommentend(){this.lastNode=null}oncdatastart(){let e=new PM(``),t=new RM([e]);this.addNode(t),e.parent=t,this.lastNode=e}oncdataend(){this.lastNode=null}onprocessinginstruction(e,t){let n=new IM(e,t);this.addNode(n)}handleCallback(e){if(typeof this.callback==`function`)this.callback(e,this.dom);else if(e)throw e}addNode(e){let t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&this.parser&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null}}})),KM=c((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=(GM(),f(HM)),r=ry(),i=t(yM()),a=vM(),o={cloneElement:r.cloneElement,createElement:r.createElement,isValidElement:r.isValidElement};function s(e,t={}){let n=[],r=typeof t.replace==`function`,u=t.transform??a.returnFirstArg,{cloneElement:d,createElement:f,isValidElement:p}=t.library??o,m=e.length;c(e);for(let o=0;o<m;o++){let c=e[o];if(r){let e=t.replace?.call(t,c,o);if(p(e)){m>1&&(e=d(e,{key:e.key??o})),n.push(u(e,c,o));continue}}if(c.type===`text`){let e=!c.data.trim().length;if(e&&c.parent&&!(0,a.canTextBeChildOfNode)(c.parent)||t.trim&&e)continue;n.push(u(c.data,c,o));continue}let h=c,g={};l(h)?((0,a.setStyleProp)(h.attribs.style,h.attribs),g=h.attribs):h.attribs&&(g=(0,i.default)(h.attribs,h.name));let _;switch(c.type){case`script`:case`style`:c.children[0]&&(g.dangerouslySetInnerHTML={__html:c.children[0].data});break;case`tag`:c.name===`textarea`&&c.children[0]?g.defaultValue=c.children[0].data:c.children?.length&&(_=s(c.children,t));break;default:continue}m>1&&(g.key=o),n.push(u(f(c.name,g,_),c,o))}return n.length===1?n[0]:n}function c(e){for(let t of e)(t.type===`tag`||t.type===`script`||t.type===`style`)&&(Object.setPrototypeOf(t,n.Element.prototype),c(t.children))}function l(e){return a.PRESERVE_CUSTOM_ATTRIBUTES&&e.type===`tag`&&(0,a.isCustomComponent)(e.name,e.attribs)}})),qM=d(c((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.htmlToDOM=e.domToReact=e.attributesToProps=e.Text=e.ProcessingInstruction=e.Element=e.Comment=void 0,e.default=o;var n=t(fM());e.htmlToDOM=n.default,e.attributesToProps=t(yM()).default;var r=t(KM());e.domToReact=r.default;var i=(GM(),f(HM));Object.defineProperty(e,"Comment",{enumerable:!0,get:function(){return i.Comment}}),Object.defineProperty(e,"Element",{enumerable:!0,get:function(){return i.Element}}),Object.defineProperty(e,"ProcessingInstruction",{enumerable:!0,get:function(){return i.ProcessingInstruction}}),Object.defineProperty(e,"Text",{enumerable:!0,get:function(){return i.Text}});var a={lowerCaseAttributeNames:!1};function o(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];let i=Object.assign(Object.assign({},t?.htmlparser2??a),{trustedTypePolicy:t?.trustedTypePolicy});return(0,r.default)((0,n.default)(e,i),t)}}))(),1),JM=qM.default.default||qM.default,YM=class{diff(e,t,n={}){let r;typeof n==`function`?(r=n,n={}):`callback`in n&&(r=n.callback);let i=this.castInput(e,n),a=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),s=this.removeEmpty(this.tokenize(a,n));return this.diffWithOptionsObj(o,s,n,r)}diffWithOptionsObj(e,t,n,r){let i=e=>{if(e=this.postProcess(e,n),r){setTimeout(function(){r(e)},0);return}return e},a=t.length,o=e.length,s=1,c=a+o;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let l=n.timeout??1/0,u=Date.now()+l,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=o&&f+1>=a)return i(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,m=1/0,h=()=>{for(let r=Math.max(p,-s);r<=Math.min(m,s);r+=2){let s,c=d[r-1],l=d[r+1];c&&(d[r-1]=void 0);let u=!1;if(l){let e=l.oldPos-r;u=l&&0<=e&&e<a}let h=c&&c.oldPos+1<o;if(!u&&!h){d[r]=void 0;continue}if(s=!h||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,n):this.addToPath(c,!1,!0,1,n),f=this.extractCommon(s,t,e,r,n),s.oldPos+1>=o&&f+1>=a)return i(this.buildValues(s.lastComponent,t,e))||!0;d[r]=s,s.oldPos+1>=o&&(m=Math.min(m,r-1)),f+1>=a&&(p=Math.max(p,r+1))}s++};if(r)(function e(){setTimeout(function(){if(s>c||Date.now()>u)return r(void 0);h()||e()},0)})();else for(;s<=c&&Date.now()<=u;){let e=h();if(e)return e}}addToPath(e,t,n,r,i){let a=e.lastComponent;return a&&!i.oneChangePerToken&&a.added===t&&a.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:a.count+1,added:t,removed:n,previousComponent:a.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:a}}}extractCommon(e,t,n,r,i){let a=t.length,o=n.length,s=e.oldPos,c=s-r,l=0;for(;c+1<a&&s+1<o&&this.equals(n[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){let t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join(``)}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){let r=[],i;for(;e;)r.push(e),i=e.previousComponent,delete e.previousComponent,e=i;r.reverse();let a=r.length,o=0,s=0,c=0;for(;o<a;o++){let e=r[o];if(e.removed)e.value=this.join(n.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(s,s+e.count);r=r.map(function(e,t){let r=n[c+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return r}};new class extends YM{};function XM(e,t){let n=0;for(;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function ZM(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return``;for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function QM(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function $M(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function eN(e,t){return QM(e,t,``)}function tN(e,t){return $M(e,t,``)}function nN(e,t){return t.slice(0,rN(e,t))}function rN(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);let i=Array(r),a=0;i[0]=0;for(let e=1;e<r;e++){for(t[e]==t[a]?i[e]=i[a]:i[e]=a;a>0&&t[e]!=t[a];)a=i[a];t[e]==t[a]&&a++}a=0;for(let r=n;r<e.length;r++){for(;a>0&&e[r]!=t[a];)a=i[a];e[r]==t[a]&&a++}return a}function iN(e,t){let n=[];for(let r of Array.from(t.segment(e))){let e=r.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}return n}function aN(e,t){if(t)return sN(e,t)[1];let n;for(n=e.length-1;n>=0&&e[n].match(/\s/);n--);return e.substring(n+1)}function oN(e,t){if(t)return sN(e,t)[0];let n=e.match(/^\s*/);return n?n[0]:``}function sN(e,t){if(!t)return[oN(e),aN(e)];if(t.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);let n=iN(e,t),r=n[0],i=n[n.length-1];return[/\s/.test(r)?r:``,/\s/.test(i)?i:``]}var cN=`a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}`,lN=RegExp(`[${cN}]+|\\s+|[^${cN}]`,`ug`),uN=new class extends YM{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){let r=t.intlSegmenter;if(r.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);n=iN(e,r)}else n=e.match(lN)||[];let r=[],i=null;return n.forEach(e=>{/\s/.test(e)?i==null?r.push(e):r.push(r.pop()+e):i!=null&&/\s/.test(i)?r[r.length-1]==i?r.push(r.pop()+e):r.push(i+e):r.push(e),i=e}),r}join(e){return e.map((e,t)=>t==0?e:e.replace(/^\s+/,``)).join(``)}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,i=null;return e.forEach(e=>{e.added?r=e:e.removed?i=e:((r||i)&&fN(n,i,r,e,t.intlSegmenter),n=e,r=null,i=null)}),(r||i)&&fN(n,i,r,null,t.intlSegmenter),e}};function dN(e,t,n){return n?.ignoreWhitespace!=null&&!n.ignoreWhitespace?mN(e,t,n):uN.diff(e,t,n)}function fN(e,t,n,r,i){if(t&&n){let[a,o]=sN(t.value,i),[s,c]=sN(n.value,i);if(e){let r=XM(a,s);e.value=$M(e.value,s,r),t.value=eN(t.value,r),n.value=eN(n.value,r)}if(r){let e=ZM(o,c);r.value=QM(r.value,c,e),t.value=tN(t.value,e),n.value=tN(n.value,e)}}else if(n){if(e){let e=oN(n.value,i);n.value=n.value.substring(e.length)}if(r){let e=oN(r.value,i);r.value=r.value.substring(e.length)}}else if(e&&r){let n=oN(r.value,i),[a,o]=sN(t.value,i),s=XM(n,a);t.value=eN(t.value,s);let c=ZM(eN(n,s),o);t.value=tN(t.value,c),r.value=QM(r.value,n,c),e.value=$M(e.value,n,n.slice(0,n.length-c.length))}else if(r){let e=oN(r.value,i),n=nN(aN(t.value,i),e);t.value=tN(t.value,n)}else if(e){let n=nN(aN(e.value,i),oN(t.value,i));t.value=eN(t.value,n)}}var pN=new class extends YM{tokenize(e){let t=RegExp(`(\\r?\\n)|[${cN}]+|[^\\S\\n\\r]+|[^${cN}]`,`ug`);return e.match(t)||[]}};function mN(e,t,n){return pN.diff(e,t,n)}new class extends YM{constructor(){super(...arguments),this.tokenize=hN}equals(e,t,n){return n.ignoreWhitespace?((!n.newlineIsToken||!e.includes(`
145
+ `).replace(Bd,``)}function Hd(e,t){return t=Vd(t),Vd(e)===t}function Ud(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Xt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Xt(e,``+r);break;case`className`:Pt(e,`class`,r);break;case`tabIndex`:Pt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Pt(e,n,r);break;case`style`:$t(e,r,o);break;case`data`:if(t!==`object`){Pt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=rn(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}if(typeof o==`function`&&(n===`formAction`?(t!==`input`&&Ud(e,t,`name`,a.name,a,null),Ud(e,t,`formEncType`,a.formEncType,a,null),Ud(e,t,`formMethod`,a.formMethod,a,null),Ud(e,t,`formTarget`,a.formTarget,a,null)):(Ud(e,t,`encType`,a.encType,a,null),Ud(e,t,`method`,a.method,a,null),Ud(e,t,`target`,a.target,a,null))),r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=rn(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=an);break;case`onScroll`:r!=null&&B(`scroll`,e);break;case`onScrollEnd`:r!=null&&B(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=rn(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:B(`beforetoggle`,e),B(`toggle`,e),Nt(e,`popover`,r);break;case`xlinkActuate`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Ft(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Ft(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Ft(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Ft(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Nt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=tn.get(n)||n,Nt(e,n,r))}}function Wd(e,t,n,r,a,o){switch(n){case`style`:$t(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Xt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Xt(e,``+r);break;case`onScroll`:r!=null&&B(`scroll`,e);break;case`onScrollEnd`:r!=null&&B(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=an);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!Et.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[ft]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Nt(e,n,r)}}}function Gd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:B(`error`,e),B(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Ud(e,t,o,s,n,null)}}a&&Ud(e,t,`srcSet`,n.srcSet,n,null),r&&Ud(e,t,`src`,n.src,n,null);return;case`input`:B(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Ud(e,t,r,d,n,null)}}Gt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in B(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Ud(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&qt(e,!!r,n,!0):qt(e,!!r,t,!1);return;case`textarea`:for(s in B(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Ud(e,t,s,c,n,null)}Yt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Ud(e,t,l,r,n,null)}return;case`dialog`:B(`beforetoggle`,e),B(`toggle`,e),B(`cancel`,e),B(`close`,e);break;case`iframe`:case`object`:B(`load`,e);break;case`video`:case`audio`:for(r=0;r<Dd.length;r++)B(Dd[r],e);break;case`image`:B(`error`,e),B(`load`,e);break;case`details`:B(`toggle`,e);break;case`embed`:case`source`:case`link`:B(`error`,e),B(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Ud(e,t,u,r,n,null)}return;default:if(en(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Wd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Ud(e,t,c,r,n,null))}function Kd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Ud(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Ud(e,t,p,m,r,f)}}Wt(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Ud(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Ud(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?qt(e,!!n,n?[]:``,!1):qt(e,!!n,t,!0)):qt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Ud(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Ud(e,t,s,a,r,o)}Jt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Ud(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Ud(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Ud(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Ud(e,t,u,p,r,m)}return;default:if(en(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Wd(e,t,_,void 0,r,p);for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Wd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Ud(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Ud(e,t,f,p,r,m)}function qd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Jd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&qd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&qd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Yd=null,Xd=null;function Zd(e){return e.nodeType===9?e:e.ownerDocument}function Qd(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function $d(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function ef(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var tf=null;function nf(){var e=window.event;return e&&e.type===`popstate`?e!==tf&&(tf=e,!0):(tf=null,!1)}var rf=typeof setTimeout==`function`?setTimeout:void 0,af=typeof clearTimeout==`function`?clearTimeout:void 0,of=typeof Promise==`function`?Promise:void 0,sf=typeof queueMicrotask==`function`?queueMicrotask:of===void 0?rf:function(e){return of.resolve(null).then(e).catch(cf)};function cf(e){setTimeout(function(){throw e})}function lf(e){return e===`head`}function uf(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8){if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Hp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)wf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,wf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[vt]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&wf(e.ownerDocument.body)}n=i}while(n);Hp(t)}function df(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8){if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++}n=r}while(n)}function ff(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:ff(n),yt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function pf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r){if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e}else if(!e[vt])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=yf(e.nextSibling),e===null)break}return null}function mf(e,t,n){if(t===``)return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=yf(e.nextSibling),e===null))return null;return e}function hf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=yf(e.nextSibling),e===null))return null;return e}function gf(e){return e.data===`$?`||e.data===`$~`}function _f(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function vf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function yf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var bf=null;function xf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return yf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function Sf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function Cf(e,t,n){switch(t=Zd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function wf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);yt(e)}var Tf=new Map,Ef=new Set;function Df(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Of=A.d;A.d={f:kf,r:Af,D:Nf,C:Pf,L:Ff,m:If,X:Rf,S:Lf,M:zf};function kf(){var e=Of.f(),t=ku();return e||t}function Af(e){var t=xt(e);t!==null&&t.tag===5&&t.type===`form`?Ms(t):Of.r(e)}var jf=typeof document>`u`?null:document;function Mf(e,t,n){var r=jf;if(r&&typeof t==`string`&&t){var i=Ut(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),Ef.has(i)||(Ef.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Gd(t,`link`,e),wt(t),r.head.appendChild(t)))}}function Nf(e){Of.D(e),Mf(`dns-prefetch`,e,null)}function Pf(e,t){Of.C(e,t),Mf(`preconnect`,e,t)}function Ff(e,t,n){Of.L(e,t,n);var r=jf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ut(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ut(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ut(n.imageSizes)+`"]`)):i+=`[href="`+Ut(e)+`"]`;var a=i;switch(t){case`style`:a=Vf(e);break;case`script`:a=Gf(e)}Tf.has(a)||(e=f({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),Tf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Hf(a))||t===`script`&&r.querySelector(Kf(a))||(t=r.createElement(`link`),Gd(t,`link`,e),wt(t),r.head.appendChild(t)))}}function If(e,t){Of.m(e,t);var n=jf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ut(r)+`"][href="`+Ut(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Gf(e)}if(!Tf.has(a)&&(e=f({rel:`modulepreload`,href:e},t),Tf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Kf(a)))return}r=n.createElement(`link`),Gd(r,`link`,e),wt(r),n.head.appendChild(r)}}}function Lf(e,t,n){Of.S(e,t,n);var r=jf;if(r&&e){var i=Ct(r).hoistableStyles,a=Vf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Hf(a)))s.loading=5;else{e=f({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=Tf.get(a))&&Yf(e,n);var c=o=r.createElement(`link`);wt(c),Gd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Jf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Rf(e,t){Of.X(e,t);var n=jf;if(n&&e){var r=Ct(n).hoistableScripts,i=Gf(e),a=r.get(i);a||(a=n.querySelector(Kf(i)),a||(e=f({src:e,async:!0},t),(t=Tf.get(i))&&Xf(e,t),a=n.createElement(`script`),wt(a),Gd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function zf(e,t){Of.M(e,t);var n=jf;if(n&&e){var r=Ct(n).hoistableScripts,i=Gf(e),a=r.get(i);a||(a=n.querySelector(Kf(i)),a||(e=f({src:e,async:!0,type:`module`},t),(t=Tf.get(i))&&Xf(e,t),a=n.createElement(`script`),wt(a),Gd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Bf(e,t,n,r){var a=(a=fe.current)?Df(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Vf(n.href),n=Ct(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Vf(n.href);var o=Ct(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Hf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),Tf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Tf.set(e,n),o||Wf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Gf(n),n=Ct(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Vf(e){return`href="`+Ut(e)+`"`}function Hf(e){return`link[rel="stylesheet"][`+e+`]`}function Uf(e){return f({},e,{"data-precedence":e.precedence,precedence:null})}function Wf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Gd(t,`link`,n),wt(t),e.head.appendChild(t))}function Gf(e){return`[src="`+Ut(e)+`"]`}function Kf(e){return`script[async]`+e}function qf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ut(n.href)+`"]`);if(r)return t.instance=r,wt(r),r;var a=f({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),wt(r),Gd(r,`style`,a),Jf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Vf(n.href);var o=e.querySelector(Hf(a));if(o)return t.state.loading|=4,t.instance=o,wt(o),o;r=Uf(n),(a=Tf.get(a))&&Yf(r,a),o=(e.ownerDocument||e).createElement(`link`),wt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Gd(o,`link`,r),t.state.loading|=4,Jf(o,n.precedence,e),t.instance=o;case`script`:return o=Gf(n.src),(a=e.querySelector(Kf(o)))?(t.instance=a,wt(a),a):(r=n,(a=Tf.get(o))&&(r=f({},n),Xf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),wt(a),Gd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Jf(r,n.precedence,e));return t.instance}function Jf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Yf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Xf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Zf=null;function Qf(e,t,n){if(Zf===null){var r=new Map,i=Zf=new Map;i.set(n,r)}else i=Zf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[vt]||a[dt]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function $f(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function ep(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function tp(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function np(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Vf(r.href),a=t.querySelector(Hf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=ap.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,wt(a);return}a=t.ownerDocument||t,r=Uf(r),(i=Tf.get(i))&&Yf(r,i),a=a.createElement(`link`),wt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Gd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=ap.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var rp=0;function ip(e,t){return e.stylesheets&&e.count===0&&sp(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&sp(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&rp===0&&(rp=62500*Jd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&sp(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>rp?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function ap(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)sp(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var op=null;function sp(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,op=new Map,t.forEach(cp,e),op=null,ap.call(e))}function cp(e,t){if(!(t.state.loading&4)){var n=op.get(e);if(n)var r=n.get(null);else{n=new Map,op.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=ap.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var lp={$$typeof:b,Provider:null,Consumer:null,_currentValue:ie,_currentValue2:ie,_threadCount:0};function up(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=et(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=et(0),this.hiddenUpdates=et(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function dp(e,t,n,r,i,a,o,s,c,l,u,d){return e=new up(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=ui(3,null,null,t),e.current=a,a.stateNode=e,t=ua(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ua(a),e}function fp(e){return e?(e=ci,e):ci}function pp(e,t,n,r,i,a){i=fp(i),r.context===null?r.context=i:r.pendingContext=i,r=Ga(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ka(e,r,t),n!==null&&(wu(n,e,t),qa(n,e,t))}function mp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function hp(e,t){mp(e,t),(e=e.alternate)&&mp(e,t)}function gp(e){if(e.tag===13||e.tag===31){var t=ai(e,67108864);t!==null&&wu(t,e,67108864),hp(e,67108864)}}function _p(e){if(e.tag===13||e.tag===31){var t=Su();t=ot(t);var n=ai(e,t);n!==null&&wu(n,e,t),hp(e,t)}}var vp=!0;function V(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=2,bp(e,t,n,r)}finally{A.p=a,k.T=i}}function yp(e,t,n,r){var i=k.T;k.T=null;var a=A.p;try{A.p=8,bp(e,t,n,r)}finally{A.p=a,k.T=i}}function bp(e,t,n,r){if(vp){var i=H(r);if(i===null)Pd(e,t,r,xp,n),Mp(e,r);else if(Pp(i,e,t,n,r))r.stopPropagation();else if(Mp(e,r),t&4&&-1<jp.indexOf(e)){for(;i!==null;){var a=xt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Ye(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-He(o);s.entanglements[1]|=c,o&=~c}pd(a),!(L&6)&&(uu=Ae()+500,md(0,!1))}}break;case 31:case 13:s=ai(a,2),s!==null&&wu(s,a,2),ku(),hp(a,2)}if(a=H(r),a===null&&Pd(e,t,r,xp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Pd(e,t,r,null,n)}}function H(e){return e=sn(e),Sp(e)}var xp=null;function Sp(e){if(xp=null,e=bt(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return xp=e,null}function Cp(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(je()){case Me:return 2;case Ne:return 8;case Pe:case Fe:return 32;case Ie:return 268435456;default:return 32}default:return 32}}var wp=!1,Tp=null,Ep=null,Dp=null,Op=new Map,kp=new Map,Ap=[],jp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Mp(e,t){switch(e){case`focusin`:case`focusout`:Tp=null;break;case`dragenter`:case`dragleave`:Ep=null;break;case`mouseover`:case`mouseout`:Dp=null;break;case`pointerover`:case`pointerout`:Op.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:kp.delete(t.pointerId)}}function Np(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=xt(t),t!==null&&gp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Pp(e,t,n,r,i){switch(t){case`focusin`:return Tp=Np(Tp,e,t,n,r,i),!0;case`dragenter`:return Ep=Np(Ep,e,t,n,r,i),!0;case`mouseover`:return Dp=Np(Dp,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return Op.set(a,Np(Op.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,kp.set(a,Np(kp.get(a)||null,e,t,n,r,i)),!0}return!1}function Fp(e){var t=bt(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,lt(e.priority,function(){_p(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,lt(e.priority,function(){_p(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Ip(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=H(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);on=r,n.target.dispatchEvent(r),on=null}else return t=xt(n),t!==null&&gp(t),e.blockedOn=n,!1;t.shift()}return!0}function Lp(e,t,n){Ip(e)&&n.delete(t)}function Rp(){wp=!1,Tp!==null&&Ip(Tp)&&(Tp=null),Ep!==null&&Ip(Ep)&&(Ep=null),Dp!==null&&Ip(Dp)&&(Dp=null),Op.forEach(Lp),kp.forEach(Lp)}function zp(e,n){e.blockedOn===n&&(e.blockedOn=null,wp||(wp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,Rp)))}var Bp=null;function Vp(e){Bp!==e&&(Bp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Bp===e&&(Bp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(Sp(r||n)===null)continue;break}var a=xt(n);a!==null&&(e.splice(t,3),t-=3,As(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Hp(e){function t(t){return zp(t,e)}Tp!==null&&zp(Tp,e),Ep!==null&&zp(Ep,e),Dp!==null&&zp(Dp,e),Op.forEach(t),kp.forEach(t);for(var n=0;n<Ap.length;n++){var r=Ap[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Ap.length&&(n=Ap[0],n.blockedOn===null);)Fp(n),n.blockedOn===null&&Ap.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[ft]||null;if(typeof a==`function`)o||Vp(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[ft]||null)s=o.formAction;else if(Sp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Vp(n)}}}function Up(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Wp(e){this._internalRoot=e}Gp.prototype.render=Wp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;pp(n,Su(),e,t,null,null)},Gp.prototype.unmount=Wp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;pp(e.current,2,null,e,null,null),ku(),t[pt]=null}};function Gp(e){this._internalRoot=e}Gp.prototype.unstable_scheduleHydration=function(e){if(e){var t=ct();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Ap.length&&t!==0&&t<Ap[n].priority;n++);Ap.splice(n,0,e),n===0&&Fp(e)}};var Kp=n.version;if(Kp!==`19.2.8`)throw Error(i(527,Kp,`19.2.8`));A.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=u(t),e=e===null?null:d(e),e=e===null?null:e.stateNode,e};var qp={bundleType:0,version:`19.2.8`,rendererPackageName:`react-dom`,currentDispatcherRef:k,reconcilerVersion:`19.2.8`};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Jp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Jp.isDisabled&&Jp.supportsFiber)try{ze=Jp.inject(qp),Be=Jp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=$s,s=ec,c=tc;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=dp(e,1,!1,null,null,n,r,null,o,s,c,Up),e[pt]=t.current,Md(e),new Wp(t)}})),Yx=c(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=Jx()}))(),Xx=Math.min,Zx=Math.max,Qx=Math.round,$x=e=>({x:e,y:e}),eS={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function tS(e,t,n){return Zx(e,Xx(t,n))}function nS(e,t){return typeof e==`function`?e(t):e}function rS(e){return e.split(`-`)[0]}function iS(e){return e.split(`-`)[1]}function aS(e){return e===`x`?`y`:`x`}function oS(e){return e===`y`?`height`:`width`}function sS(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function cS(e){return aS(sS(e))}function lS(e,t,n){n===void 0&&(n=!1);let r=iS(e),i=cS(e),a=oS(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=vS(o)),[o,vS(o)]}function uS(e){let t=vS(e);return[dS(e),t,dS(t)]}function dS(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var fS=[`left`,`right`],pS=[`right`,`left`],mS=[`top`,`bottom`],hS=[`bottom`,`top`];function gS(e,t,n){switch(e){case`top`:case`bottom`:return n?t?pS:fS:t?fS:pS;case`left`:case`right`:return t?mS:hS;default:return[]}}function _S(e,t,n,r){let i=iS(e),a=gS(rS(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(dS)))),a}function vS(e){let t=rS(e);return eS[t]+e.slice(t.length)}function yS(e){return{top:e.top??0,right:e.right??0,bottom:e.bottom??0,left:e.left??0}}function bS(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:yS(e)}function xS(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function SS(e,t,n){let{reference:r,floating:i}=e,a=sS(t),o=cS(t),s=oS(o),c=rS(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}let m=iS(t);return m&&(p[o]+=f*(m===`end`?1:-1)*(n&&l?-1:1)),p}async function CS(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=nS(t,e),p=bS(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=xS(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=xS(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var wS=50,TS=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:CS},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=SS(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<wS&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=SS(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},ES=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=nS(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=rS(r),_=sS(o),v=rS(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[vS(o)]:uS(o)),x=p!==`none`;!d&&x&&b.push(..._S(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),w=[],T=i.flip?.overflows||[];if(l&&w.push(C[g]),u){let e=lS(r,a,y);w.push(C[e[0]],C[e[1]])}if(T=[...T,{placement:r,overflows:w}],!w.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(u!==`alignment`||_===sS(t)||T.every(e=>sS(e.placement)!==_||e.overflows[0]>0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=T.filter(e=>{if(x){let t=sS(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o}if(r!==n)return{reset:{placement:n}}}return{}}}},DS=new Set([`left`,`top`]);async function OS(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=rS(n),s=iS(n),c=sS(n)===`y`,l=DS.has(o)?-1:1,u=a&&c?-1:1,d=nS(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var kS=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await OS(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},AS=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=nS(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=sS(i),p=aS(f),m=u[p],h=u[f],g=(e,t)=>tS(t+d[e===`y`?`top`:`left`],t,t-d[e===`y`?`bottom`:`right`]);o&&(m=g(p,m)),s&&(h=g(f,h));let _=c.fn({...t,[p]:m,[f]:h});return{..._,data:{x:_.x-n,y:_.y-r,enabled:{[p]:o,[f]:s}}}}}};function jS(){return typeof window<`u`}function MS(e){return FS(e)?(e.nodeName||``).toLowerCase():`#document`}function NS(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function PS(e){return((FS(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function FS(e){return jS()?e instanceof Node||e instanceof NS(e).Node:!1}function IS(e){return jS()?e instanceof Element||e instanceof NS(e).Element:!1}function LS(e){return jS()?e instanceof HTMLElement||e instanceof NS(e).HTMLElement:!1}function RS(e){return!jS()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof NS(e).ShadowRoot}function zS(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=XS(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function BS(e){return/^(table|td|th)$/.test(MS(e))}function VS(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var HS=/transform|translate|scale|rotate|perspective|filter/,US=/paint|layout|strict|content/,WS=e=>!!e&&e!==`none`,GS;function KS(e){let t=IS(e)?XS(e):e;return WS(t.transform)||WS(t.translate)||WS(t.scale)||WS(t.rotate)||WS(t.perspective)||!JS()&&(WS(t.backdropFilter)||WS(t.filter))||HS.test(t.willChange||``)||US.test(t.contain||``)}function qS(e){let t=QS(e);for(;LS(t)&&!YS(t);){if(KS(t))return t;if(VS(t))return null;t=QS(t)}return null}function JS(){return GS??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),GS}function YS(e){return/^(html|body|#document)$/.test(MS(e))}function XS(e){return NS(e).getComputedStyle(e)}function ZS(e){return IS(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function QS(e){if(MS(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||RS(e)&&e.host||PS(e);return RS(t)?t.host:t}function $S(e){let t=QS(e);return YS(t)?(e.ownerDocument||e).body:LS(t)&&zS(t)?t:$S(t)}function eC(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=$S(e),i=r===e.ownerDocument?.body,a=NS(r);if(i){let e=tC(a);return t.concat(a,a.visualViewport||[],zS(r)?r:[],e&&n?eC(e):[])}return t.concat(r,eC(r,[],n))}function tC(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function nC(e){let t=XS(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=LS(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Qx(n)!==a||Qx(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function rC(e){return IS(e)?e:e.contextElement}function iC(e){let t=rC(e);if(!LS(t))return $x(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=nC(t),o=(a?Qx(n.width):n.width)/r,s=(a?Qx(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var aC=$x(0);function oC(e){let t=NS(e);return!JS()||!t.visualViewport?aC:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function sC(e,t,n){return t===void 0&&(t=!1),!!n&&t&&n===NS(e)}function cC(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=rC(e),o=$x(1);t&&(r?IS(r)&&(o=iC(r)):o=iC(e));let s=sC(a,n,r)?oC(a):$x(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a&&r){let e=NS(a),t=IS(r)?NS(r):r,n=e,i=tC(n);for(;i&&t!==n;){let e=iC(i),t=i.getBoundingClientRect(),r=XS(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=NS(i),i=tC(n)}}return xS({width:u,height:d,x:c,y:l})}function lC(e,t){let n=ZS(e).scrollLeft;return t?t.left+n:cC(PS(e)).left+n}function uC(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-lC(e,n),y:n.top+t.scrollTop}}function dC(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=PS(r),s=t?VS(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=$x(1),u=$x(0),d=LS(r);if((d||!a)&&((MS(r)!==`body`||zS(o))&&(c=ZS(r)),d)){let e=cC(r);l=iC(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?uC(o,c):$x(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function fC(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function pC(e){let t=ZS(e),n=e.ownerDocument.body,r=Zx(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=Zx(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),a=-t.scrollLeft+lC(e),o=-t.scrollTop;return XS(n).direction===`rtl`&&(a+=Zx(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:a,y:o}}var mC=25;function hC(e,t,n){n===void 0&&(n=`viewport`);let r=n===`layoutViewport`,i=NS(e),a=PS(e),o=i.visualViewport,s=a.clientWidth,c=a.clientHeight,l=0,u=0;if(o){let e=!JS()||t===`fixed`;r?e||(l=-o.offsetLeft,u=-o.offsetTop):(s=o.width,c=o.height,e&&(l=o.offsetLeft,u=o.offsetTop))}if(lC(a)<=0){let e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r),o=getComputedStyle(a).scrollbarGutter===`stable both-edges`?i/2:i;o<=mC&&(s-=o)}return{width:s,height:c,x:l,y:u}}function gC(e,t){let n=cC(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=iC(e);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function _C(e,t,n){let r;if(t===`viewport`||t===`layoutViewport`)r=hC(e,n,t);else if(t===`document`)r=pC(PS(e));else if(IS(t))r=gC(t,n);else{let n=oC(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return xS(r)}function vC(e,t){let n=t.get(e);if(n)return n;let r=eC(e,[],!1).filter(e=>IS(e)&&MS(e)!==`body`),i=null,a=XS(e).position===`fixed`,o=a?QS(e):e;for(;IS(o)&&!YS(o);){let e=XS(o),t=KS(o),n=i?i.position:a?`fixed`:``;!t&&(n===`fixed`||n===`absolute`&&e.position===`static`)?r=r.filter(e=>e!==o):i=e,o=QS(o)}return t.set(e,r),r}function yC(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?VS(t)?[]:vC(t,this._c):[].concat(n),r],o=_C(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=_C(t,a[e],i);s=Zx(n.top,s),c=Xx(n.right,c),l=Xx(n.bottom,l),u=Zx(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function bC(e){let{width:t,height:n}=nC(e);return{width:t,height:n}}function xC(e,t,n){let r=LS(t),i=PS(t),a=n===`fixed`,o=cC(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=$x(0);if((r||!a)&&((MS(t)!==`body`||zS(i))&&(s=ZS(t)),r)){let e=cC(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}!r&&i&&(c.x=lC(i));let l=i&&!r&&!a?uC(i,s):$x(0);return{x:o.left+s.scrollLeft-c.x-l.x,y:o.top+s.scrollTop-c.y-l.y,width:o.width,height:o.height}}function SC(e){return XS(e).position===`static`}function CC(e,t){if(!LS(e)||XS(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return PS(e)===n&&(n=n.ownerDocument.body),n}function wC(e,t){let n=NS(e);if(VS(e))return n;if(!LS(e)){let t=QS(e);for(;t&&!YS(t);){if(IS(t)&&!SC(t))return t;t=QS(t)}return n}let r=CC(e,t);for(;r&&BS(r)&&SC(r);)r=CC(r,t);return r&&YS(r)&&SC(r)&&!KS(r)?n:r||qS(e)||n}var TC=async function(e){let t=this.getOffsetParent||wC,n=this.getDimensions,r=await n(e.floating);return{reference:xC(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function EC(e){return XS(e).direction===`rtl`}var DC={convertOffsetParentRelativeRectToViewportRelativeRect:dC,getDocumentElement:PS,getClippingRect:yC,getOffsetParent:wC,getElementRects:TC,getClientRects:fC,getDimensions:bC,getScale:iC,isElement:IS,isRTL:EC},OC=kS,kC=AS,AC=ES,jC=(e,t,n)=>{let r=new Map,i=n??{},a={...DC,...i.platform,_c:r};return TS(e,t,{...i,platform:a})},MC=d(qx(),1),NC=typeof document<`u`?W.useLayoutEffect:function(){};function PC(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!PC(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!PC(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function FC(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function IC(e,t){let n=FC(e);return Math.round(t*n)/n}function LC(e){let t=W.useRef(e);return NC(()=>{t.current=e}),t}function RC(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=W.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=W.useState(r);PC(f,r)||p(r);let[m,h]=W.useState(null),[g,_]=W.useState(null),v=W.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=W.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=W.useRef(null),C=W.useRef(null),w=W.useRef(u),T=c!=null,E=LC(c),D=LC(i),O=LC(l),ee=W.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};D.current&&(e.platform=D.current),jC(S.current,C.current,e).then(e=>{let t={...e,isPositioned:O.current!==!1};te.current&&!PC(w.current,t)&&(w.current=t,MC.flushSync(()=>{d(t)}))})},[f,t,n,D,O]);NC(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let te=W.useRef(!1);NC(()=>(te.current=!0,()=>{te.current=!1}),[]),NC(()=>{if(b&&(S.current=b),x&&(C.current=x),b&&x){if(E.current)return E.current(b,x,ee);ee()}},[b,x,ee,E,T]);let ne=W.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),re=W.useMemo(()=>({reference:b,floating:x}),[b,x]),k=W.useMemo(()=>{let e={position:n,left:0,top:0};if(!re.floating)return e;let t=IC(re.floating,u.x),r=IC(re.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...FC(re.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,re.floating,u.x,u.y]);return W.useMemo(()=>({...u,update:ee,refs:ne,elements:re,floatingStyles:k}),[u,ee,ne,re,k])}var zC=(e,t)=>{let n=OC(e);return{name:n.name,fn:n.fn,options:[e,t]}},BC=(e,t)=>{let n=kC(e);return{name:n.name,fn:n.fn,options:[e,t]}},VC=(e,t)=>{let n=AC(e);return{name:n.name,fn:n.fn,options:[e,t]}},HC=e=>{let[t,n]=W.useState(e),r=W.useRef(t);return[t,W.useCallback(function(e){r.current=typeof e==`function`?e(r.current):e,n(r.current)},[]),r]},UC=({analytics:e,element:t,data:n,prevData:r,hide:i,updateTextWithAlternative:a,addIgnoredTerm:o,movePopoverNextOrPrev:s,setLLMSuggestionsRequest:c,getLLMSuggestions:l,llmAlternativesEnabled:u,ignoreTermPermanently:d,onAlternativeAccepted:f})=>{let[p,m]=(0,W.useState)(null),[h,g,_]=HC(!1),[v,y]=(0,W.useState)(``),[b,x]=(0,W.useState)(``),[S,C]=(0,W.useState)(``),w=(0,W.useRef)(null);(0,W.useEffect)(()=>()=>{w.current!==null&&clearTimeout(w.current)},[]);let T=l({alert:n.alert}),E=(0,W.useRef)(null);(0,W.useEffect)(()=>{r&&r.alert.id===n.alert.id||E.current!==n.alert.id&&(E.current=n.alert.id,e.popoverLogs(n.alert,`popover_open`))},[n.alert.id]),(0,W.useEffect)(()=>{u&&n.alert.data.alternatives.length>0&&c({alert:n.alert})},[n.alert.id,u]);let D=(t=!1)=>{t&&e.popoverLogs(n.alert,`popover_close`),g(!1),i();let r=window.document.getElementsByTagName(`ww-popover`);Array.from(r).forEach(e=>{e.remove()})},O=(t,r)=>{t.preventDefault(),t.stopImmediatePropagation(),e.alternativeLog(n.alert,r),f(),a(r)};return{analytics:e,alternativeHovered:p,setAlternativeHovered:m,showLearningBite:h,setShowLearningBite:g,showLearningBiteRef:_,isLoading:v,isSuccess:b,isFailure:S,llmAlternativesResponse:T,hidePopover:D,clickAlternative:O,alternativeKeyDown:e=>n=>{(n.key===`Enter`||n.key===` `)&&(t.focus?.(),O(n.nativeEvent,e))},handleIgnoreClick:r=>()=>{e.ignoreLog(n.alert),r===`ignore_once`?(o(n.alert.data?.text),D()):r===`ignore_permanently`&&(y(r),x(``),C(``),d(n.alert.data?.text).then(()=>{y(``),o(n.alert.data?.text),x(r),w.current=window.setTimeout(()=>{let e=!!document.getElementById(`witty-works-ext-popover`)?.contains(document.activeElement);D(),e&&t.focus?.()},1e3)}).catch(()=>{y(``),C(r)}))},goToAdjacentAlert:e=>{s(e),g(!1)}}},WC=c((e=>{var t=Symbol.for(`react.transitional.element`);function n(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.jsx=n,e.jsxs=n})),G=c(((e,t)=>{t.exports=WC()}))(),GC=e=>(0,G.jsx)(`svg`,{width:15,height:14,viewBox:`0 0 15 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.6103 8.89864C7.80556 8.70338 8.12214 8.70338 8.31741 8.89864L13.1493 13.7305C13.3445 13.9258 13.6611 13.9258 13.8564 13.7305L14.5352 13.0517C14.7304 12.8565 14.7304 12.5399 14.5352 12.3446L9.7033 7.51275C9.50804 7.31749 9.50804 7.0009 9.7033 6.80564L14.8536 1.65535C15.0488 1.46009 15.0488 1.14351 14.8536 0.948248L14.1748 0.269463C13.9795 0.074201 13.663 0.0742007 13.4677 0.269463L8.31741 5.41975C8.12214 5.61501 7.80556 5.61501 7.6103 5.41975L2.46001 0.269463C2.26475 0.0742007 1.94817 0.074201 1.7529 0.269463L1.07412 0.948248C0.878858 1.14351 0.878858 1.46009 1.07412 1.65535L6.22441 6.80564C6.41967 7.0009 6.41967 7.31749 6.22441 7.51275L1.39254 12.3446C1.19727 12.5399 1.19727 12.8565 1.39254 13.0517L2.07132 13.7305C2.26658 13.9258 2.58317 13.9258 2.77843 13.7305L7.6103 8.89864Z`,fill:`#656565`})}),KC=e=>(0,G.jsxs)(`svg`,{width:25,height:14,viewBox:`0 0 25 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,xmlnsXlink:`http://www.w3.org/1999/xlink`,...e,children:[(0,G.jsx)(`rect`,{width:25,height:14,fill:`url(#pattern0)`}),(0,G.jsxs)(`defs`,{children:[(0,G.jsx)(`pattern`,{id:`pattern0`,patternContentUnits:`objectBoundingBox`,width:1,height:1,children:(0,G.jsx)(`use`,{xlinkHref:`#image0_554_760`,transform:`translate(0 -0.0197228) scale(0.0149254 0.0266525)`})}),(0,G.jsx)(`image`,{id:`image0_554_760`,width:67,height:39,xlinkHref:`data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEMAAAAnCAYAAABUr/U/AAAOXUlEQVRoBb1aaVBbV5bm3yx/OlM9NTM1P8bT1VVdNVM1mUnVVCbVhnhh8R5vsbHTsUN3XJlkpivt6p6qTjpO4thG7LsQAsRqwDbesI3BNhixb1rfE0JIbxF670GMtycksZmEb+oKRIQiEWzcoeqW3t3P+d75Luec+6KiQv6mUqgT3mSqz5tMyeGKT2Ga9qYaZrxphhlfun7Gl6Gf8WbpZyZzBmbduQOzT/P6Zh8X9M5OFPTMTSi75ybU3XMTxR1zYlGvxOUPHgjZbk3VmkLHtTIVI5eoGVmlZuSCYkbOK2XlLA0rp5excmoFJ+eWsrqCEkabU8Jos0tZbUY5r00v57WKSl57tprXnjnPa7+s4bWnLji1n1505vz+yuhrETfHOeMGn8I87lNQWLWkmOBL18OXpYc3exDenAF48vowWdALd2EP5KIuyMWdkEu0kMvaIFe0Qq66B7nmDp7W3AVb1F8SUYiQjqtKfkOlyjFdWsSgSM2gQM0it4RFVimLjDIOqRUckqsWfwuKV/alVXBQVHE4V83jq/M8vqzl8fkFJ/50yYk/Xnbidw2j+N0N162T152vrNgWp02v+JLN06uCsASSN9mMqUwdvNkD8Ob2w5PfC4+SANEFt7oT7pIOyKVayOVteFpxD3I1AaIZ7rrbcF9qxJNLjbAV9/7bCgEiVGpVDqNGxUBdxKBQzSKvmEV2KYtMDYfvlOWQU8L6SzBIBIizBIgaHl/WOXEqAES9Ex83uPDbm6P47U0X/vemk1qx/ZSCMq4FiOUx6Xp48/rhKSBAdGNS1YXJ4g64iTVolqyh8h7k83ch196GfLERk/W3MHm5AZPXri14Gq7VrxAgTKW+0B5dpmJQUsRApWaQX7yksIZFejmHlMrFt55WvggGASJ9yVqCgfiCAHHxO4v4uGEUHzW68FHjKP6n0YUPG0fx4W1Xrl+ERXr8ADVCqONVmOHJ74GnsBvuok5MlnRgslQLd9l9uCtaIFfdhbvmjh8I96VbcF++AffVawveG1fmPTcufzt5+7rwtL7+J2EwWG6qUjnGA/RQLtEjW7OSHmerOb+lZBGAgmhDLOJ0DY8AEJ/6qTGKkw2j+O8m11IhzwI+aHLhg6ZROYnQZUpBn1p+4yuUNs/7kik5XJlUULI7e9AnF/TMycruOVndNfdU3T73pFT77JGm7dmj8vvPHlW2Pnt4vuXZk0uN85PXr857Gi5/6228Outtangy1XLb5WtpOr6sechDnZI5SehRHESPnCV6ZGhYObWckxVVnJxSyTkzStn2tHK2PaWCbT9bzfvL6fN8++d1zvZTF5ztn1xytn9S72z/v6vO9hNNLt37zaPjJ5pdOHFH8Jf3m134zR0XkprFzVE+Ba0NBwaxmBAZX6gqX7/wz96blxc8jde83rs3H0y1NrFT7Xep6e62K5EWrFQ55AA9yMFIzgRCg2wNr400Z63tHzQxP//1XQG/ubdYku66kHRPwLstrtNR3mTz9XBgTCVTJ9a6wQ+N8zY3FPru3RKn2+7Ypjpb9b6ejvap/s7bXl3X5tC51YV2DaEHOTT99CCHpoZFZhm3kKnh1/2CkprFnUT591oFvNci4FirgGP3BbyjFZKips+ZE8OB4VVQ3lBBX7Q+2XLzjSntPXqqo7VvqrezZXqgu2Fa31c7azb+PnRNTaFjfpEeS4emnx4sMkvY66FjX6R+vEWQjrW6/CC8e1/Er9oEvNMm4JBW+g//ej6FeT4cID4FpXmRDcPNmepqL5/p72ia1vVenjMNVkzTJuXskDlthh9eftuVhcx1Qg+/TxHsN2jY+XBrPm/b8Vbhc6L8YhH9IBzRCkhsF8zLaxGlI4Dx7cxLOjt8g52xPn1/3SxlKJmlTTkzw5Zz84z9k1nOEUcEqVXyG0qLmIUAPQI+BXGu0kvZ/GVhX/Dh6K3xvz163+U5qhVxtE3AEa2II+0CDncIONgp7FuxLKFFOEC8KXTfioHrqMwMGc/MWan0ecb2xSxv/8Mzp+PDOdH1LsbH/7pCxWjD0SNdw8nr2HJ56tE2oZIon9gh4rAfBBGHOgXs7xI7lwcFHnznTCfDgqGg8DTVGh0Yt57fGSsVO8/YP511Oj6eGeXfnxsTEr958GB3910hcZkeQS438R0yypwn17Mnmbu/Y/xfDhMQOgQc6hSJJeBgp4QD3SLe6h0LH6NMKcxMKCCTKRQepVCP1isQmQ+G+YtnTuajb1z88W/Gxw/MT0xsg2diY3UZy32PHosu9/jL2PftdpfpYJcAUg50iTjQI2Ffj4Q9vUJtxPXnki2vepOphQAgHgUFOYXG41QaUhq17jdENn72QPyvbx482DP/+PFWPH78+q2ro2cIPYJd7swllzu1yrVuizzUKSTt75awv1vA/h4Re3sk7O0lQIie6C7330QEg3R4lpwwr4LCZAqNJ6k0HqbRkFLpuVUnrrETovhX8w/HYyDLr816PL8oVTNy2Ii0nDeucclVh+3tESeIFeztEfwgvNUrYk+fhB19YuqqE0kniWA9Cmqe0ONpKo1HqTS+9lsGDT7NcucHF1jDALgf/GzG7f5ZbZXzj2Ej0nJu4Vzt+h2s/Z1CEVH+rV4JARB29YnYOSBKaxBzcchjBZ3iXqLHRJoFY2k0hHQ/GAt85vqFBPCXAH5SrHLMB9PDH3CVcyAJmTULG2FgbOvE3+/pk6Z294nY3SeB/O7ql7CjX0TsoLg9wrTwzRNptEzoMZ5KQ0yjMZpuAZthwXDmkDX8jOdrVasYDaFHaESaUv5yHKzd3ULL7n4Ju/pF7BqQiDVgu05CwqA48HySRkVFfZ1O73xAzoo0Gq50C/gMCxwEjIwhmLKGdz73gkETNEp+Q3ERsxBI2AQiUpKbOFvJrdvr3d0rxe7sJ3SQsJ2AMChh26CIBP0YYgekXwSJsvZHV6rFSqzCmW4Bk2HBSMYQhjIJGNZ1OUJFakZL6BGcqiMJG0Ul91LioZ39oo0AQEqCTvSXeL2EWMNYxdq1DxlJzgdnmmWBy7DAnjkEa+YQLJlWAga6s60pIcPXVC0s5KKLipgFQg+/yx2UsDlTvX4Ha0eP8IcEPwgStukkxOtExBkkxBrHfK/bPD9dk5CRBg2nW64TetgyCBBDoLKsMGRb0ZdjndfmhCRTIy0S1K4qZpjCQBpvKSIl9Eiu4tbt2O0cfPgPCTrhKbGCQIk1jGGrQcIWo3QmSIwXf7RmDM0TetBZVhizrNBlD6MvZxhtubbnOvUL1M7E0IiUuNz+fGbd+h2sHQOumnj9oiXEGccQa5Cw1TiGTQaRe3HtQ2YasoZPEqswZ1mhz7aiP2cYPTnDaM+xLbTmjrwaMjxitVDNyMv0CEr3n6vmmYiT1tgRpxt9LUEvzMQZRL8lEBC2GCVsNo0hhg6JSte4ZsRhhqzhR4Qeg9nD6M0ZRmeODdpcG5ry7WtSJL+YO7nsUwTRI6WSW/jsJThY23Su3niDgFiD6Adhi2kMm00Sos1Sd0SlXrSjK9caHaBHN7GKXBvu59lwL28EV5UjPxi3KIuZ6eBLoEA2+3TN9x2sfSbtK0nGniPv9Q9+ekjfsmoWneizQ8cfjze4EGcUsNVvDRLeNEmIocYQY/z6X19U51XndeXa+gg9OpasoiVvBHfyR9CQb1/1X2JuCadZQY+lS6BzVdx8qFX4gdB3Pjxm6sCvTN14xzgwe6zTtm01wbYZnc44owtbjQK2EBDMi0D8khpb8+3dauuH7etR8hs6cmwLhB6teTbczR/B7fwR3My340KhPayzpFTyG5RqZj5wCRSISMmh+cV5/ntzkga7rySZ2/AdGH04MmiaCCtQVFTUdr0rJcHkRKzJhS1mAW+aRURTY9holmZepR78XaR5L6W9OW9E05a7SI/m/BHcyrfjeoEd9UrHAkndhW6Sr2G1wfQI3JGerebDRsG/1nfbgsE4auxDolGHgwPD6aFrbzQ++scEE+eJNzmx1eTCJkpEDC1hIz2GNyzSZ6Hj/yz15rwRL6FHY/4IbuTbcbXAjktKB0jqLnhDpYbfoCxmFwL5TP8dKfE0qzh8VhfewUrq02mCwThCwDDp8LbBPL9PK6+4JN5uYG8kmDjEmZ3YYnbhTVpEtEXCL4fGbMFy/FmfyYEZoMe1AjsuKx24UOhAjYpBYTG3nJDJ1bBMgB6BiJTQ46saflV3/j1913SAJotg6PG2yYi9OmtjQLF4I/ef280s4s0cYiknNlEuxFgWwdhoGUsMjPtRfq8WOFwNBXZcUTpwUelAXaED1eRKUM36U3VZpc7E0Ig08AnBqdrRVQO9pF7DyWUwTP04bNTjoMmI/UYau3X214mCO8wOxzYzizgzh820E2/SLsQMidg4JK2wzh8FjLpiLvpygX2hfskqzqsYVKoYkDvSwmJmWlnM+OmxGJGyIC63opIj30msyS95Vz849o6pG0eCwTBReMs0NLWDGnm8nbIjgWIRS3HYRMCwCIihXbPRRunffxQAQjepLmK0hB61hQ5UqRiUB31CEBqREnqcreYX/lTHr8ljPaQ3Rx819Cz4wTAtWsY+E4U95iHsNA9jG2VHPM1iC81hk4WAMYoYmq8JlfFHq1dUOF85r3LMEXpUqBgE35GGRqT+Q/Oi87lM+JDO2Jpo7sdhkx4HTEYQMHaZh7DDPIwEyoG4JTA20zwB5OsfTfFIG6nL2URCD/JhSbhLIEIPYhWna1c/NCOt/7bJ8OgQAcNsxF4CBmXFdmoRjHiaQSyxDJqbixlyruqYRVr/pbfnlrKJKjUzFyki/bKWs56ueP5wnwgap7f+034zPbSfgGEOBoPQhMEWmp3cbHU+X07zpSMQZsH0Mj4/Q8OyqeWs/2OSr87zfZ/Vrz8094NiGH5jO2W7v42yjSXQdjGOYnSxNJsWRowXbvp/SRXI2cTQoJkAAAAASUVORK5CYII=`})]})]}),qC=e=>(0,G.jsx)(`svg`,{width:10,height:16,viewBox:`0 0 10 16`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.09928 8L0.795978 1.6967L2.21019 0.282485L9.92771 8L2.21019 15.7175L0.795978 14.3033L7.09928 8Z`,fill:`#656565`})}),JC=e=>(0,G.jsx)(`svg`,{width:10,height:16,viewBox:`0 0 10 16`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`nonzero`,clipRule:`nonzero`,d:`M2.88607 8L9.18937 1.6967L7.77516 0.282485L0.057645 8L7.77516 15.7175L9.18937 14.3033L2.88607 8Z`,fill:`#656565`})}),YC=e=>(0,G.jsx)(`svg`,{width:21,height:14,viewBox:`0 0 21 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`M20.7821 1.17019C20.6468 1.09075 20.4797 1.08765 20.3417 1.16226L15.5234 3.77075V2.20562C15.522 0.988049 14.5268 0.00137851 13.2988 0H2.22458C0.996541 0.00137851 0.00139036 0.988049 0 2.20562V10.9144C0.00139036 12.1319 0.996541 13.1186 2.22458 13.12H13.2988C14.5268 13.1186 15.522 12.1319 15.5234 10.9144V9.37768L20.3418 11.9862C20.4797 12.0608 20.647 12.0579 20.7821 11.9784C20.9173 11.8988 21 11.7546 21 11.599V1.54945C21 1.39368 20.9171 1.24962 20.7821 1.17019ZM14.6332 10.9146C14.6325 11.6452 14.0353 12.2371 13.2984 12.2379H2.22458C1.48769 12.2371 0.8907 11.6452 0.889831 10.9146V2.20562C0.8907 1.47518 1.48769 0.88311 2.22458 0.882248H13.2988C14.0355 0.88311 14.6327 1.47518 14.6335 2.20562L14.6332 10.9146ZM20.1102 10.8556L15.5234 8.37257V4.77586L20.1102 2.29298V10.8556Z`,fill:`#F06464`})}),XC=e=>(0,G.jsx)(`svg`,{width:14.5,height:14.5,viewBox:`0 0 50 50`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`m37.5 22.5416c-.5526 0-1.0825.2195-1.4732.6102s-.6102.9206-.6102 1.4732v14.9583c0 .5525-.2195 1.0824-.6102 1.4731s-.9206.6102-1.4731.6102h-22.9167c-.55251 0-1.08241-.2195-1.47311-.6102s-.6102-.9206-.6102-1.4731v-22.9167c0-.5525.2195-1.0824.6102-1.4731s.9206-.6102 1.47311-.6102h14.9584c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102h-14.9584c-1.65758 0-3.24729.6585-4.41939 1.8306s-1.83058 2.7618-1.83058 4.4194v22.9167c0 1.6576.65848 3.2473 1.83058 4.4194s2.76181 1.8306 4.41939 1.8306h22.9167c1.6576 0 3.2473-.6585 4.4194-1.8306s1.8306-2.7618 1.8306-4.4194v-14.9583c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102zm8.1666-17.08331c-.2114-.50906-.6159-.91359-1.125-1.125-.2504-.10675-.5194-.16337-.7916-.16666h-12.5c-.5526 0-1.0825.21949-1.4732.61019s-.6102.9206-.6102 1.47314c0 .55253.2195 1.08244.6102 1.47314s.9206.61019 1.4732.61019h7.4791l-21.4583 21.43751c-.1953.1937-.3503.4241-.456.678-.1058.2538-.1603.5261-.1603.8012 0 .275.0545.5473.1603.8012.1057.2538.2607.4843.456.6779.1937.1953.4241.3503.678.456.2538.1058.5261.1603.8012.1603.275 0 .5473-.0545.8012-.1603.2538-.1057.4843-.2607.6779-.456l21.4375-21.4583v7.4792c0 .5525.2195 1.0824.6102 1.4731s.9206.6102 1.4732.6102c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731v-12.50004c-.0033-.27225-.0599-.5412-.1667-.79167z`,fill:`#ffffff`})}),ZC=e=>(0,G.jsx)(`svg`,{width:14.5,height:14.5,viewBox:`0 0 50 50`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`m37.5 22.5416c-.5526 0-1.0825.2195-1.4732.6102s-.6102.9206-.6102 1.4732v14.9583c0 .5525-.2195 1.0824-.6102 1.4731s-.9206.6102-1.4731.6102h-22.9167c-.55251 0-1.08241-.2195-1.47311-.6102s-.6102-.9206-.6102-1.4731v-22.9167c0-.5525.2195-1.0824.6102-1.4731s.9206-.6102 1.47311-.6102h14.9584c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102h-14.9584c-1.65758 0-3.24729.6585-4.41939 1.8306s-1.83058 2.7618-1.83058 4.4194v22.9167c0 1.6576.65848 3.2473 1.83058 4.4194s2.76181 1.8306 4.41939 1.8306h22.9167c1.6576 0 3.2473-.6585 4.4194-1.8306s1.8306-2.7618 1.8306-4.4194v-14.9583c0-.5526-.2195-1.0825-.6102-1.4732s-.9206-.6102-1.4731-.6102zm8.1666-17.08331c-.2114-.50906-.6159-.91359-1.125-1.125-.2504-.10675-.5194-.16337-.7916-.16666h-12.5c-.5526 0-1.0825.21949-1.4732.61019s-.6102.9206-.6102 1.47314c0 .55253.2195 1.08244.6102 1.47314s.9206.61019 1.4732.61019h7.4791l-21.4583 21.43751c-.1953.1937-.3503.4241-.456.678-.1058.2538-.1603.5261-.1603.8012 0 .275.0545.5473.1603.8012.1057.2538.2607.4843.456.6779.1937.1953.4241.3503.678.456.2538.1058.5261.1603.8012.1603.275 0 .5473-.0545.8012-.1603.2538-.1057.4843-.2607.6779-.456l21.4375-21.4583v7.4792c0 .5525.2195 1.0824.6102 1.4731s.9206.6102 1.4732.6102c.5525 0 1.0824-.2195 1.4731-.6102s.6102-.9206.6102-1.4731v-12.50004c-.0033-.27225-.0599-.5412-.1667-.79167z`,fill:`#656565`})}),QC=e=>(0,G.jsx)(`svg`,{width:16,height:10,viewBox:`0 0 16 10`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.79599 2.82817L13.996 9.23311L15.433 7.84208L7.84197 0.00011482L8.50898e-06 7.59114L1.39104 9.02816L7.79599 2.82817Z`,fill:`#f06464`})}),$C=e=>(0,G.jsx)(`svg`,{width:16,height:10,viewBox:`0 0 16 10`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M7.71753 6.60685L1.41423 0.303546L1.3929e-05 1.71776L7.71753 9.43527L15.435 1.71776L14.0208 0.303546L7.71753 6.60685Z`,fill:`#f06464`})}),ew=Object.defineProperty,tw=(e,t)=>{let n={};for(var r in e)ew(n,r,{get:e[r],enumerable:!0});return t||ew(n,Symbol.toStringTag,{value:`Module`}),n},nw=vw(),K=e=>pw(e,nw),rw=vw();K.write=e=>pw(e,rw);var iw=vw();K.onStart=e=>pw(e,iw);var aw=vw();K.onFrame=e=>pw(e,aw);var ow=vw();K.onFinish=e=>pw(e,ow);var sw=[];K.setTimeout=(e,t)=>{let n=K.now()+t,r=()=>{let e=sw.findIndex(e=>e.cancel==r);~e&&sw.splice(e,1),dw-=+!!~e},i={time:n,handler:e,cancel:r};return sw.splice(cw(n),0,i),dw+=1,mw(),i};var cw=e=>~(~sw.findIndex(t=>t.time>e)||~sw.length);K.cancel=e=>{iw.delete(e),aw.delete(e),ow.delete(e),nw.delete(e),rw.delete(e)},K.sync=e=>{fw=!0,K.batchedUpdates(e),fw=!1},K.throttle=e=>{let t;function n(){try{e(...t)}finally{t=null}}function r(...e){t=e,K.onStart(n)}return r.handler=e,r.cancel=()=>{iw.delete(n),t=null},r};var lw=typeof window<`u`?window.requestAnimationFrame:()=>{};K.use=e=>lw=e,K.now=typeof performance<`u`?()=>performance.now():Date.now,K.batchedUpdates=e=>e(),K.catch=console.error,K.frameLoop=`always`,K.onDemand=()=>{},K.advance=()=>{K.frameLoop===`demand`?_w():console.warn(`Cannot call the manual advancement of rafz whilst frameLoop is not set as demand`)};var uw=-1,dw=0,fw=!1;function pw(e,t){fw?(t.delete(e),e(0)):(t.add(e),mw(),K.frameLoop===`demand`&&K.onDemand())}function mw(){uw<0&&(uw=0,K.frameLoop!==`demand`&&lw(gw))}function hw(){uw=-1}function gw(){~uw&&(lw(gw),K.batchedUpdates(_w))}function _w(){let e=uw;uw=K.now();let t=cw(uw);if(t&&(yw(sw.splice(0,t),e=>e.handler()),dw-=t),!dw){hw();return}iw.flush(),nw.flush(e?Math.min(64,uw-e):16.667),aw.flush(),rw.flush(),ow.flush(),K.frameLoop===`demand`&&dw>0&&K.onDemand()}function vw(){let e=new Set,t=e;return{add(n){dw+=+(t==e&&!e.has(n)),e.add(n)},delete(n){return dw-=t==e&&e.has(n)?1:0,e.delete(n)},flush(n){t.size&&(e=new Set,dw-=t.size,yw(t,t=>t(n)&&e.add(t)),dw+=e.size,t=e)}}}function yw(e,t){e.forEach(e=>{try{t(e)}catch(e){K.catch(e)}})}function bw(){}var xw=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),q={arr:Array.isArray,obj:e=>!!e&&e.constructor.name===`Object`,fun:(e=>typeof e==`function`),str:e=>typeof e==`string`,num:e=>typeof e==`number`,und:e=>e===void 0};function Sw(e,t){if(q.arr(e)){if(!q.arr(t)||e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}return e===t}var J=(e,t)=>e.forEach(t);function Cw(e,t,n){if(q.arr(e)){for(let r=0;r<e.length;r++)t.call(n,e[r],`${r}`);return}for(let r in e)e.hasOwnProperty(r)&&t.call(n,e[r],r)}var ww=e=>q.und(e)?[]:q.arr(e)?e:[e];function Tw(e,t){if(e.size){let n=Array.from(e);e.clear(),J(n,t)}}var Ew=(e,...t)=>Tw(e,e=>e(...t)),Dw=()=>typeof window>`u`||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),Ow=tw({assign:()=>Pw,colors:()=>jw,createStringInterpolator:()=>kw,skipAnimation:()=>Mw,to:()=>Aw,willAdvance:()=>Nw}),kw,Aw,jw=null,Mw=!1,Nw=bw,Pw=e=>{e.to&&(Aw=e.to),e.now&&(K.now=e.now),e.colors!==void 0&&(jw=e.colors),e.skipAnimation!=null&&(Mw=e.skipAnimation),e.createStringInterpolator&&(kw=e.createStringInterpolator),e.requestAnimationFrame&&K.use(e.requestAnimationFrame),e.batchedUpdates&&(K.batchedUpdates=e.batchedUpdates),e.willAdvance&&(Nw=e.willAdvance),e.frameLoop&&(K.frameLoop=e.frameLoop),e.onDemand&&(K.onDemand=e.onDemand)},Fw=new Set,Iw=[],Lw=[],Rw=0,zw={get idle(){return!Fw.size&&!Iw.length},start(e){Rw>e.priority?(Fw.add(e),K.onStart(Bw)):(Vw(e),K(Uw))},advance:Uw,sort(e){if(Rw)K.onFrame(()=>zw.sort(e));else{let t=Iw.indexOf(e);~t&&(Iw.splice(t,1),Hw(e))}},clear(){Iw=[],Fw.clear()}};function Bw(){Fw.forEach(Vw),Fw.clear(),K(Uw)}function Vw(e){Iw.includes(e)||Hw(e)}function Hw(e){Iw.splice(Ww(Iw,t=>t.priority>e.priority),0,e)}function Uw(e){let t=Lw;for(let n=0;n<Iw.length;n++){let r=Iw[n];Rw=r.priority,r.idle||(Nw(r),r.advance(e),r.idle||t.push(r))}return Rw=0,Lw=Iw,Lw.length=0,Iw=t,Iw.length>0}function Ww(e,t){let n=e.findIndex(t);return n<0?e.length:n}var Gw=(e,t,n)=>Math.min(Math.max(n,e),t),Kw={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},qw=`[-+]?\\d*\\.?\\d+`,Jw=`[-+]?\\d*\\.?\\d+%`;function Yw(...e){return`\\(\\s*(`+e.join(`)\\s*,\\s*(`)+`)\\s*\\)`}var Xw=RegExp(`rgb`+Yw(qw,qw,qw)),Zw=RegExp(`rgba`+Yw(qw,qw,qw,qw)),Qw=RegExp(`hsl`+Yw(qw,Jw,Jw)),$w=RegExp(`hsla`+Yw(qw,Jw,Jw,qw)),eT=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,tT=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,nT=/^#([0-9a-fA-F]{6})$/,rT=/^#([0-9a-fA-F]{8})$/;function iT(e){let t;return typeof e==`number`?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=nT.exec(e))?parseInt(t[1]+`ff`,16)>>>0:jw&&jw[e]!==void 0?jw[e]:(t=Xw.exec(e))?(sT(t[1])<<24|sT(t[2])<<16|sT(t[3])<<8|255)>>>0:(t=Zw.exec(e))?(sT(t[1])<<24|sT(t[2])<<16|sT(t[3])<<8|lT(t[4]))>>>0:(t=eT.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+`ff`,16)>>>0:(t=rT.exec(e))?parseInt(t[1],16)>>>0:(t=tT.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=Qw.exec(e))?(oT(cT(t[1]),uT(t[2]),uT(t[3]))|255)>>>0:(t=$w.exec(e))?(oT(cT(t[1]),uT(t[2]),uT(t[3]))|lT(t[4]))>>>0:null}function aT(e,t,n){return n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function oT(e,t,n){let r=n<.5?n*(1+t):n+t-n*t,i=2*n-r,a=aT(i,r,e+1/3),o=aT(i,r,e),s=aT(i,r,e-1/3);return Math.round(a*255)<<24|Math.round(o*255)<<16|Math.round(s*255)<<8}function sT(e){let t=parseInt(e,10);return t<0?0:t>255?255:t}function cT(e){return(parseFloat(e)%360+360)%360/360}function lT(e){let t=parseFloat(e);return t<0?0:t>1?255:Math.round(t*255)}function uT(e){let t=parseFloat(e);return t<0?0:t>100?1:t/100}function dT(e){let t=iT(e);return t===null?e:(t||=0,`rgba(${(t&4278190080)>>>24}, ${(t&16711680)>>>16}, ${(t&65280)>>>8}, ${(t&255)/255})`)}var fT=(e,t,n)=>{if(q.fun(e))return e;if(q.arr(e))return fT({range:e,output:t,extrapolate:n});if(q.str(e.output[0]))return kw(e);let r=e,i=r.output,a=r.range||[0,1],o=r.extrapolateLeft||r.extrapolate||`extend`,s=r.extrapolateRight||r.extrapolate||`extend`,c=r.easing||(e=>e);return e=>{let t=mT(e,a);return pT(e,a[t],a[t+1],i[t],i[t+1],c,o,s,r.map)}};function pT(e,t,n,r,i,a,o,s,c){let l=c?c(e):e;if(l<t){if(o===`identity`)return l;o===`clamp`&&(l=t)}if(l>n){if(s===`identity`)return l;s===`clamp`&&(l=n)}return r===i?r:t===n?e<=t?r:i:(t===-1/0?l=-l:n===1/0?l-=t:l=(l-t)/(n-t),l=a(l),r===-1/0?l=-l:i===1/0?l+=r:l=l*(i-r)+r,l)}function mT(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}var hT=(e,t=`end`)=>n=>{n=t===`end`?Math.min(n,.999):Math.max(n,.001);let r=n*e;return Gw(0,1,(t===`end`?Math.floor(r):Math.ceil(r))/e)},gT=1.70158,_T=gT*1.525,vT=2.70158,yT=2*Math.PI/3,bT=2*Math.PI/4.5,xT=e=>{let t=7.5625,n=2.75;return e<1/n?t*e*e:e<2/n?t*(e-=1.5/n)*e+.75:e<2.5/n?t*(e-=2.25/n)*e+.9375:t*(e-=2.625/n)*e+.984375},ST={linear:e=>e,easeInQuad:e=>e*e,easeOutQuad:e=>1-(1-e)*(1-e),easeInOutQuad:e=>e<.5?2*e*e:1-(-2*e+2)**2/2,easeInCubic:e=>e*e*e,easeOutCubic:e=>1-(1-e)**3,easeInOutCubic:e=>e<.5?4*e*e*e:1-(-2*e+2)**3/2,easeInQuart:e=>e*e*e*e,easeOutQuart:e=>1-(1-e)**4,easeInOutQuart:e=>e<.5?8*e*e*e*e:1-(-2*e+2)**4/2,easeInQuint:e=>e*e*e*e*e,easeOutQuint:e=>1-(1-e)**5,easeInOutQuint:e=>e<.5?16*e*e*e*e*e:1-(-2*e+2)**5/2,easeInSine:e=>1-Math.cos(e*Math.PI/2),easeOutSine:e=>Math.sin(e*Math.PI/2),easeInOutSine:e=>-(Math.cos(Math.PI*e)-1)/2,easeInExpo:e=>e===0?0:2**(10*e-10),easeOutExpo:e=>e===1?1:1-2**(-10*e),easeInOutExpo:e=>e===0?0:e===1?1:e<.5?2**(20*e-10)/2:(2-2**(-20*e+10))/2,easeInCirc:e=>1-Math.sqrt(1-e**2),easeOutCirc:e=>Math.sqrt(1-(e-1)**2),easeInOutCirc:e=>e<.5?(1-Math.sqrt(1-(2*e)**2))/2:(Math.sqrt(1-(-2*e+2)**2)+1)/2,easeInBack:e=>vT*e*e*e-gT*e*e,easeOutBack:e=>1+vT*(e-1)**3+gT*(e-1)**2,easeInOutBack:e=>e<.5?(2*e)**2*(7.189819*e-_T)/2:((2*e-2)**2*(3.5949095*(e*2-2)+_T)+2)/2,easeInElastic:e=>e===0?0:e===1?1:-(2**(10*e-10))*Math.sin((e*10-10.75)*yT),easeOutElastic:e=>e===0?0:e===1?1:2**(-10*e)*Math.sin((e*10-.75)*yT)+1,easeInOutElastic:e=>e===0?0:e===1?1:e<.5?-(2**(20*e-10)*Math.sin((20*e-11.125)*bT))/2:2**(-20*e+10)*Math.sin((20*e-11.125)*bT)/2+1,easeInBounce:e=>1-xT(1-e),easeOutBounce:xT,easeInOutBounce:e=>e<.5?(1-xT(1-2*e))/2:(1+xT(2*e-1))/2,steps:hT},CT=Symbol.for(`FluidValue.get`),wT=Symbol.for(`FluidValue.observers`),TT=e=>!!(e&&e[CT]),ET=e=>e&&e[CT]?e[CT]():e,DT=e=>e[wT]||null;function OT(e,t){e.eventObserved?e.eventObserved(t):e(t)}function kT(e,t){let n=e[wT];n&&n.forEach(e=>{OT(e,t)})}var AT=class{constructor(e){if(!e&&!(e=this.get))throw Error(`Unknown getter`);jT(this,e)}},jT=(e,t)=>PT(e,CT,t);function MT(e,t){if(e[CT]){let n=e[wT];n||PT(e,wT,n=new Set),n.has(t)||(n.add(t),e.observerAdded&&e.observerAdded(n.size,t))}return t}function NT(e,t){let n=e[wT];if(n&&n.has(t)){let r=n.size-1;r?n.delete(t):e[wT]=null,e.observerRemoved&&e.observerRemoved(r,t)}}var PT=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0}),FT=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,IT=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,LT=RegExp(`(${FT.source})(%|[a-z]+)`,`i`),RT=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,zT=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,BT=e=>{let[t,n]=VT(e);if(!t||Dw())return e;let r=window.getComputedStyle(document.documentElement).getPropertyValue(t);return r?r.trim():n&&n.startsWith(`--`)?window.getComputedStyle(document.documentElement).getPropertyValue(n)||e:n&&zT.test(n)?BT(n):n||e},VT=e=>{let t=zT.exec(e);if(!t)return[,];let[,n,r]=t;return[n,r]},HT,UT=(e,t,n,r,i)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(r)}, ${i})`,WT=e=>e.match(FT)??[],GT=e=>{HT||=jw?RegExp(`(${Object.keys(jw).join(`|`)})(?!\\w)`,`g`):/^\b$/;let t=e.output.map(e=>ET(e).replace(zT,BT).replace(IT,dT).replace(HT,dT)),n=t.map(e=>WT(e).map(Number)),r=n[0].map((e,t)=>n.map(e=>{if(!(t in e))throw Error(`The arity of each "output" value must be equal`);return e[t]})).map(t=>fT({...e,output:t})),i=e.range||[0,1],a=t.map(e=>WT(e)),o=a[0].map((e,t)=>{let n=a.map(e=>{let n=e[t],r=n.indexOf(`.`);return r===-1?0:n.length-r-1});return n.every(e=>e===n[0])&&n[0]>0?n[0]:null});return e=>{let n=i.indexOf(e);if(n!==-1)return t[n];let a=!LT.test(t[0])&&t.find(e=>LT.test(e))?.replace(FT,``),s=0;return t[0].replace(FT,()=>{let t=s++,n=r[t](e),i=o[t];return`${i==null?n:n.toFixed(i)}${a||``}`}).replace(RT,UT)}},KT=`react-spring: `,qT=e=>{let t=e,n=!1;if(typeof t!=`function`)throw TypeError(`${KT}once requires a function parameter`);return(...e)=>{n||=(t(...e),!0)}},JT=qT(console.warn);function YT(){JT(`${KT}The "interpolate" function is deprecated in v9 (use "to" instead)`)}var XT=qT(console.warn);function ZT(){XT(`${KT}Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions`)}function QT(e){return q.str(e)&&(e[0]==`#`||/\d/.test(e)||!Dw()&&zT.test(e)||e in(jw||{}))}var $T=Dw()?W.useEffect:W.useLayoutEffect,eE=()=>{let e=(0,W.useRef)(!1);return $T(()=>(e.current=!0,()=>{e.current=!1}),[]),e};function tE(){let e=(0,W.useState)()[1],t=eE();return()=>{t.current&&e(Math.random())}}var nE=e=>(0,W.useEffect)(e,rE),rE=[];function iE(e){let t=(0,W.useRef)(void 0);return(0,W.useEffect)(()=>{t.current=e}),t.current}var aE=Symbol.for(`Animated:node`),oE=e=>!!e&&e[aE]===e,sE=e=>e&&e[aE],cE=(e,t)=>xw(e,aE,t),lE=e=>e&&e[aE]&&e[aE].getPayload(),uE=class{constructor(){cE(this,this)}getPayload(){return this.payload||[]}},dE=class e extends uE{constructor(e){super(),this._value=e,this.done=!0,this.durationProgress=0,q.num(this._value)&&(this.lastPosition=this._value)}static create(t){return new e(t)}getPayload(){return[this]}getValue(){return this._value}setValue(e,t){return q.num(e)&&(this.lastPosition=e,t&&(e=Math.round(e/t)*t,this.done&&(this.lastPosition=e))),this._value!==e&&(this._value=e,!0)}reset(){let{done:e}=this;this.done=!1,q.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,e&&(this.lastVelocity=null),this.v0=null)}},fE=class e extends dE{constructor(e){super(0),this._string=null,this._toString=fT({output:[e,e]})}static create(t){return new e(t)}getValue(){return this._string??=this._toString(this._value)}setValue(e){if(q.str(e)){if(e==this._string)return!1;this._string=e,this._value=1}else if(super.setValue(e))this._string=null;else return!1;return!0}reset(e){e&&(this._toString=fT({output:[this.getValue(),e]})),this._value=0,super.reset()}},pE={dependencies:null},mE=class extends uE{constructor(e){super(),this.source=e,this.setValue(e)}getValue(e){let t={};return Cw(this.source,(n,r)=>{oE(n)?t[r]=n.getValue(e):TT(n)?t[r]=ET(n):e||(t[r]=n)}),t}setValue(e){this.source=e,this.payload=this._makePayload(e)}reset(){this.payload&&J(this.payload,e=>e.reset())}_makePayload(e){if(e){let t=new Set;return Cw(e,this._addToPayload,t),Array.from(t)}}_addToPayload(e){pE.dependencies&&TT(e)&&pE.dependencies.add(e);let t=lE(e);t&&J(t,e=>this.add(e))}},hE=class e extends mE{constructor(e){super(e)}static create(t){return new e(t)}getValue(){return this.source.map(e=>e.getValue())}setValue(e){let t=this.getPayload();return e.length==t.length?t.map((t,n)=>t.setValue(e[n])).some(Boolean):(super.setValue(e.map(gE)),!0)}};function gE(e){return(QT(e)?fE:dE).create(e)}function _E(e){let t=sE(e);return t?t.constructor:q.arr(e)?hE:QT(e)?fE:dE}var vE=(e,t)=>{let n=!q.fun(e)||e.prototype&&e.prototype.isReactComponent;return(0,W.forwardRef)((r,i)=>{let a=(0,W.useRef)(null),o=n&&(0,W.useCallback)(e=>{a.current=xE(i,e)},[i]),[s,c]=bE(r,t),l=tE(),u=()=>{let e=a.current;(!n||e)&&(e?t.applyAnimatedValues(e,s.getValue(!0)):!1)===!1&&l()},d=new yE(u,c),f=(0,W.useRef)(void 0);$T(()=>(f.current=d,J(c,e=>MT(e,d)),()=>{f.current&&(J(f.current.deps,e=>NT(e,f.current)),K.cancel(f.current.update))})),(0,W.useEffect)(u,[]),nE(()=>()=>{let e=f.current;J(e.deps,t=>NT(t,e))});let p=t.getComponentProps(s.getValue());return W.createElement(e,{...p,ref:o})})},yE=class{constructor(e,t){this.update=e,this.deps=t}eventObserved(e){e.type==`change`&&K.write(this.update)}};function bE(e,t){let n=new Set;return pE.dependencies=n,e.style&&(e={...e,style:t.createAnimatedStyle(e.style)}),e=new mE(e),pE.dependencies=null,[e,n]}function xE(e,t){return e&&(q.fun(e)?e(t):e.current=t),t}var SE=Symbol.for(`AnimatedComponent`),CE=new WeakMap,wE=(e,{applyAnimatedValues:t=()=>!1,createAnimatedStyle:n=e=>new mE(e),getComponentProps:r=e=>e}={})=>{let i={applyAnimatedValues:t,createAnimatedStyle:n,getComponentProps:r},a=e=>{let t=TE(e)||`Anonymous`;if(q.str(e))e=a[e]||(a[e]=vE(e,i));else{let t=e[SE]??CE.get(e);if(!t){t=vE(e,i);try{e[SE]=t}catch{}CE.set(e,t)}e=t}return e.displayName=`Animated(${t})`,e};return Cw(e,(t,n)=>{q.arr(e)&&(n=TE(t)),a[n]=a(t)}),{animated:a}},TE=e=>q.str(e)?e:e&&q.str(e.displayName)?e.displayName:q.fun(e)&&e.name||null;function EE(e,...t){return q.fun(e)?e(...t):e}var DE=(e,t)=>e===!0||!!(t&&e&&(q.fun(e)?e(t):ww(e).includes(t))),OE=(e,t)=>q.obj(e)?t&&e[t]:e,kE=(e,t)=>e.default===!0?e[t]:e.default?e.default[t]:void 0,AE=e=>e,jE=(e,t=AE)=>{let n=ME;e.default&&e.default!==!0&&(e=e.default,n=Object.keys(e));let r={};for(let i of n){let n=t(e[i],i);q.und(n)||(r[i]=n)}return r},ME=[`config`,`onProps`,`onStart`,`onChange`,`onPause`,`onResume`,`onRest`],NE={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function PE(e){let t={},n=0;if(Cw(e,(e,r)=>{NE[r]||(t[r]=e,n++)}),n)return t}function FE(e){let t=PE(e);if(t){let n={to:t};return Cw(e,(e,r)=>r in t||(n[r]=e)),n}return{...e}}function IE(e){let t=ET(e);return q.arr(t)?t.map(IE):QT(t)?Ow.createStringInterpolator({range:[0,1],output:[t,t]})(1):t}function LE(e){for(let t in e)return!0;return!1}function RE(e){return q.fun(e)||q.arr(e)&&q.obj(e[0])}function zE(e,t){e.ref?.delete(e),t?.delete(e)}function BE(e,t){t&&e.ref!==t&&(e.ref?.delete(e),t.add(e),e.ref=t)}var VE={...{default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}}.default,mass:1,damping:1,easing:ST.linear,clamp:!1},HE=class{constructor(){this.velocity=0,Object.assign(this,VE)}};function UE(e,t,n){n&&(n={...n},WE(n,t),t={...n,...t}),WE(e,t),Object.assign(e,t);for(let t in VE)e[t]??(e[t]=VE[t]);let{frequency:r,damping:i}=e,{mass:a}=e;return q.und(r)||(r<.01&&(r=.01),i<0&&(i=0),e.tension=(2*Math.PI/r)**2*a,e.friction=4*Math.PI*i*a/r),e}function WE(e,t){if(!q.und(t.decay))e.duration=void 0;else{let n=!q.und(t.tension)||!q.und(t.friction);(n||!q.und(t.frequency)||!q.und(t.damping)||!q.und(t.mass))&&(e.duration=void 0,e.decay=void 0),n&&(e.frequency=void 0)}}var GE=[],KE=class{constructor(){this.changed=!1,this.values=GE,this.toValues=null,this.fromValues=GE,this.config=new HE,this.immediate=!1}};function qE(e,{key:t,props:n,defaultProps:r,state:i,actions:a}){return new Promise((o,s)=>{let c,l,u=DE(n.cancel??r?.cancel,t);if(u)p();else{q.und(n.pause)||(i.paused=DE(n.pause,t));let e=r?.pause;e!==!0&&(e=i.paused||DE(e,t)),c=EE(n.delay||0,t),e?(i.resumeQueue.add(f),a.pause()):(a.resume(),f())}function d(){i.resumeQueue.add(f),i.timeouts.delete(l),l.cancel(),c=l.time-K.now()}function f(){c>0&&!Ow.skipAnimation?(i.delayed=!0,l=K.setTimeout(p,c),i.pauseQueue.add(d),i.timeouts.add(l)):p()}function p(){i.delayed&&=!1,i.pauseQueue.delete(d),i.timeouts.delete(l),e<=(i.cancelId||0)&&(u=!0);try{a.start({...n,callId:e,cancel:u},o)}catch(e){s(e)}}})}var JE=(e,t)=>t.length==1?t[0]:t.some(e=>e.cancelled)?ZE(e.get()):t.every(e=>e.noop)?YE(e.get()):XE(e.get(),t.every(e=>e.finished)),YE=e=>({value:e,noop:!0,finished:!0,cancelled:!1}),XE=(e,t,n=!1)=>({value:e,finished:t,cancelled:n}),ZE=e=>({value:e,cancelled:!0,finished:!1});function QE(e,t,n,r){let{callId:i,parentId:a,onRest:o}=t,{asyncTo:s,promise:c}=n;return!a&&e===s&&!t.reset?c:n.promise=(async()=>{n.asyncId=i,n.asyncTo=e;let l=jE(t,(e,t)=>t===`onRest`?void 0:e),u,d,f=new Promise((e,t)=>(u=e,d=t)),p=e=>{let t=i<=(n.cancelId||0)&&ZE(r)||i!==n.asyncId&&XE(r,!1);if(t)throw e.result=t,d(e),e},m=0,h=(e,t)=>{let a=new eD,o=new tD;return(async()=>{p(a);let s=q.obj(e)?{...e}:{...t,to:e};if(s.parentId=i,Cw(l,(e,t)=>{q.und(s[t])&&(s[t]=e)}),Ow.skipAnimation){if(++m>1024)throw $E(n),o.result=XE(r,!1),d(o),o;return s.immediate=!0,await r.start(s)}let c=await r.start(s);return p(a),n.paused&&await new Promise(e=>{n.resumeQueue.add(e)}),c})()},g;try{let t;t=q.arr(e)?(async e=>{for(let t of e)await h(t)})(e):Promise.resolve(e(h,r.stop.bind(r))),await Promise.all([t.then(u),f]),g=XE(r.get(),!0,!1)}catch(e){if(e instanceof eD)g=e.result;else if(e instanceof tD)g=e.result;else throw e}finally{i==n.asyncId&&(n.asyncId=a,n.asyncTo=a?s:void 0,n.promise=a?c:void 0)}return q.fun(o)&&K.batchedUpdates(()=>{o(g,r,r.item)}),g})()}function $E(e,t){Tw(e.timeouts,e=>e.cancel()),e.pauseQueue.clear(),e.resumeQueue.clear(),e.asyncId=e.asyncTo=e.promise=void 0,t&&(e.cancelId=t)}var eD=class extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise.")}},tD=class extends Error{constructor(){super(`SkipAnimationSignal`)}},nD=e=>e instanceof iD,rD=1,iD=class extends AT{constructor(...e){super(...e),this.id=rD++,this._priority=0}get priority(){return this._priority}set priority(e){this._priority!=e&&(this._priority=e,this._onPriorityChange(e))}get(){let e=sE(this);return e&&e.getValue()}to(...e){return Ow.to(this,e)}interpolate(...e){return YT(),Ow.to(this,e)}toJSON(){return this.get()}observerAdded(e){e==1&&this._attach()}observerRemoved(e){e==0&&this._detach()}_attach(){}_detach(){}_onChange(e,t=!1){kT(this,{type:`change`,parent:this,value:e,idle:t})}_onPriorityChange(e){this.idle||zw.sort(this),kT(this,{type:`priority`,parent:this,priority:e})}},aD=Symbol.for(`SpringPhase`),oD=1,sD=2,cD=4,lD=e=>(e[aD]&oD)>0,uD=e=>(e[aD]&sD)>0,dD=e=>(e[aD]&cD)>0,fD=(e,t)=>t?e[aD]|=3:e[aD]&=-3,pD=(e,t)=>t?e[aD]|=cD:e[aD]&=-5,mD=class extends iD{constructor(e,t){if(super(),this.animation=new KE,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!q.und(e)||!q.und(t)){let n=q.obj(e)?{...e}:{...t,from:e};q.und(n.default)&&(n.default=!0),this.start(n)}}get idle(){return!(uD(this)||this._state.asyncTo)||dD(this)}get goal(){return ET(this.animation.to)}get velocity(){let e=sE(this);return e instanceof dE?e.lastVelocity||0:e.getPayload().map(e=>e.lastVelocity||0)}get hasAnimated(){return lD(this)}get isAnimating(){return uD(this)}get isPaused(){return dD(this)}get isDelayed(){return this._state.delayed}advance(e){let t=!0,n=!1,r=this.animation,{toValues:i}=r,{config:a}=r,o=lE(r.to);!o&&TT(r.to)&&(i=ww(ET(r.to))),r.values.forEach((s,c)=>{if(s.done)return;let l=s.constructor==fE?1:o?o[c].lastPosition:i[c],u=r.immediate,d=l;if(!u){if(d=s.lastPosition,a.tension<=0){s.done=!0;return}let t=s.elapsedTime+=e,n=r.fromValues[c],i=s.v0==null?s.v0=q.arr(a.velocity)?a.velocity[c]:a.velocity:s.v0,o,f=a.precision||(n==l?.005:Math.max(Math.max(Math.abs(l),Math.abs(n),1)*2**-52,Math.min(1,Math.abs(l-n)*.001)));if(!q.und(a.duration)){let r=1;a.duration>0&&(this._memoizedDuration!==a.duration&&(this._memoizedDuration=a.duration,s.durationProgress>0&&(s.elapsedTime=a.duration*s.durationProgress,t=s.elapsedTime+=e)),r=(a.progress||0)+t/this._memoizedDuration,r=r>1?1:r<0?0:r,s.durationProgress=r),d=n+a.easing(r)*(l-n),o=(d-s.lastPosition)/e,u=r==1}else if(a.decay){let e=a.decay===!0?.998:a.decay,r=Math.exp(-(1-e)*t);d=n+i/(1-e)*(1-r),u=Math.abs(s.lastPosition-d)<=f,o=i*r}else{o=s.lastVelocity==null?i:s.lastVelocity;let t=a.restVelocity||f/10,r=a.clamp?0:a.bounce,c=!q.und(r),p=n==l?s.v0>0:n<l,m,h=!1,g=Math.ceil(e/1);for(let e=0;e<g&&(m=Math.abs(o)>t,!(!m&&(u=Math.abs(l-d)<=f,u)));++e){c&&(h=d==l||d>l==p,h&&(o=-o*r,d=l));let e=(-a.tension*1e-6*(d-l)+-a.friction*.001*o)/a.mass;o+=e*1,d+=o*1}}s.lastVelocity=o,Number.isNaN(d)&&(console.warn(`Got NaN while animating:`,this),u=!0)}o&&!o[c].done&&(u=!1),u?s.done=!0:t=!1,s.setValue(d,a.round)&&(n=!0)});let s=sE(this),c=s.getValue();if(t){let e=ET(r.to);(c!==e||n)&&!a.decay?(s.setValue(e),this._onChange(e)):n&&a.decay&&this._onChange(c),this._stop()}else n&&this._onChange(c)}set(e){return K.batchedUpdates(()=>{this._stop(),this._focus(e),this._set(e)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(uD(this)){let{to:e,config:t}=this.animation;K.batchedUpdates(()=>{this._onStart(),t.decay||this._set(e,!1),this._stop()})}return this}update(e){return(this.queue||=[]).push(e),this}start(e,t){let n;return q.und(e)?(n=this.queue||[],this.queue=[]):n=[q.obj(e)?e:{...t,to:e}],Promise.all(n.map(e=>this._update(e))).then(e=>JE(this,e))}stop(e){let{to:t}=this.animation;return q.und(t)||this._focus(this.get()),$E(this._state,e&&this._lastCallId),K.batchedUpdates(()=>this._stop(t,e)),this}reset(){this._update({reset:!0})}eventObserved(e){e.type==`change`?this._start():e.type==`priority`&&(this.priority=e.priority+1)}_prepareNode(e){let t=this.key||``,{to:n,from:r}=e;n=q.obj(n)?n[t]:n,(n==null||RE(n))&&(n=void 0),r=q.obj(r)?r[t]:r,r??=void 0;let i={to:n,from:r};return lD(this)||(e.reverse&&([n,r]=[r,n]),r=ET(r),q.und(r)?sE(this)||this._set(n):this._set(r)),i}_update({...e},t){let{key:n,defaultProps:r}=this;e.default&&Object.assign(r,jE(e,(e,t)=>/^on/.test(t)?OE(e,n):e)),bD(this,e,`onProps`),xD(this,`onProps`,e,this);let i=this._prepareNode(e);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");let a=this._state;return qE(++this._lastCallId,{key:n,props:e,defaultProps:r,state:a,actions:{pause:()=>{dD(this)||(pD(this,!0),Ew(a.pauseQueue),xD(this,`onPause`,XE(this,hD(this,this.animation.to)),this))},resume:()=>{dD(this)&&(pD(this,!1),uD(this)&&this._resume(),Ew(a.resumeQueue),xD(this,`onResume`,XE(this,hD(this,this.animation.to)),this))},start:this._merge.bind(this,i)}}).then(n=>{if(e.loop&&n.finished&&!(t&&n.noop)){let t=gD(e);if(t)return this._update(t,!0)}return n})}_merge(e,t,n){if(t.cancel)return this.stop(!0),n(ZE(this));let r=!q.und(e.to),i=!q.und(e.from);if(r||i){if(t.callId>this._lastToId)this._lastToId=t.callId;else return n(ZE(this))}let{key:a,defaultProps:o,animation:s}=this,{to:c,from:l}=s,{to:u=c,from:d=l}=e;i&&!r&&(!t.default||q.und(u))&&(u=d),t.reverse&&([u,d]=[d,u]);let f=!Sw(d,l);f&&(s.from=d),d=ET(d);let p=!Sw(u,c);p&&this._focus(u);let m=RE(t.to),{config:h}=s,{decay:g,velocity:_}=h;(r||i)&&!h.decay&&(h.velocity=0),t.config&&!m&&UE(h,EE(t.config,a),t.config===o.config?void 0:EE(o.config,a));let v=sE(this);if(!v||q.und(u))return n(XE(this,!0));let y=q.und(t.reset)?i&&!t.default:!q.und(d)&&DE(t.reset,a),b=y?d:this.get(),x=IE(u),S=q.num(x)||q.arr(x)||QT(x),C=!m&&(!S||DE(o.immediate||t.immediate,a));if(p){let e=_E(u);if(e!==v.constructor){if(C)v=this._set(x);else throw Error(`Cannot animate between ${v.constructor.name} and ${e.name}, as the "to" prop suggests`)}}let w=v.constructor,T=TT(u),E=!1;if(!T){let e=y||!lD(this)&&f;(p||e)&&(E=Sw(IE(b),x),T=!E),(!Sw(s.immediate,C)&&!C||!Sw(h.decay,g)||!Sw(h.velocity,_))&&(T=!0)}if(E&&uD(this)&&(s.changed&&!y?T=!0:T||this._stop(c)),!m&&((T||TT(c))&&(s.values=v.getPayload(),s.toValues=TT(u)?null:w==fE?[1]:ww(x)),s.immediate!=C&&(s.immediate=C,!C&&!y&&this._set(c)),T)){let{onRest:e}=s;J(yD,e=>bD(this,t,e));let r=XE(this,hD(this,c));Ew(this._pendingCalls,r),this._pendingCalls.add(n),s.changed&&K.batchedUpdates(()=>{s.changed=!y,e?.(r,this),y?EE(o.onRest,r):s.onStart?.(r,this)})}y&&this._set(b),m?n(QE(t.to,t,this._state,this)):T?this._start():uD(this)&&!p?this._pendingCalls.add(n):n(YE(b))}_focus(e){let t=this.animation;e!==t.to&&(DT(this)&&this._detach(),t.to=e,DT(this)&&this._attach())}_attach(){let e=0,{to:t}=this.animation;TT(t)&&(MT(t,this),nD(t)&&(e=t.priority+1)),this.priority=e}_detach(){let{to:e}=this.animation;TT(e)&&NT(e,this)}_set(e,t=!0){let n=ET(e);if(!q.und(n)){let e=sE(this);if(!e||!Sw(n,e.getValue())){let r=_E(n);!e||e.constructor!=r?cE(this,r.create(n)):e.setValue(n),e&&K.batchedUpdates(()=>{this._onChange(n,t)})}}return sE(this)}_onStart(){let e=this.animation;e.changed||(e.changed=!0,xD(this,`onStart`,XE(this,hD(this,e.to)),this))}_onChange(e,t){let n=XE(e,!1);t||(this._onStart(),EE(this.animation.onChange,n,this)),EE(this.defaultProps.onChange,n,this),super._onChange(e,t)}_start(){let e=this.animation;sE(this).reset(ET(e.to)),e.immediate||(e.fromValues=e.values.map(e=>e.lastPosition)),uD(this)||(fD(this,!0),dD(this)||this._resume())}_resume(){Ow.skipAnimation?this.finish():zw.start(this)}_stop(e,t){if(uD(this)){fD(this,!1);let n=this.animation;J(n.values,e=>{e.done=!0}),n.toValues&&(n.onChange=n.onPause=n.onResume=void 0),kT(this,{type:`idle`,parent:this});let r=t?ZE(this.get()):XE(this.get(),hD(this,e??n.to));Ew(this._pendingCalls,r),n.changed=!1,xD(this,`onRest`,r,this)}}};function hD(e,t){let n=IE(t);return Sw(IE(e.get()),n)}function gD(e,t=e.loop,n=e.to){let r=EE(t);if(r){let i=r!==!0&&FE(r),a=(i||e).reverse,o=!i||i.reset;return _D({...e,loop:t,default:!1,pause:void 0,to:!a||RE(n)?n:void 0,from:o?e.from:void 0,reset:o,...i})}}function _D(e){let{to:t,from:n}=e=FE(e),r=new Set;return q.obj(t)&&vD(t,r),q.obj(n)&&vD(n,r),e.keys=r.size?Array.from(r):null,e}function vD(e,t){Cw(e,(e,n)=>e!=null&&t.add(n))}var yD=[`onStart`,`onRest`,`onChange`,`onPause`,`onResume`];function bD(e,t,n){e.animation[n]=t[n]===kE(t,n)?void 0:OE(t[n],e.key)}function xD(e,t,...n){e.animation[t]?.(...n),e.defaultProps[t]?.(...n)}var SD=[`onStart`,`onChange`,`onRest`],CD=1,wD=class{constructor(e,t){this.id=CD++,this.springs={},this.queue=[],this._lastAsyncId=0,this._lastLoopId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),t&&(this._flush=t),e&&this.start({default:!0,...e})}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(e=>e.idle&&!e.isDelayed&&!e.isPaused)}get item(){return this._item}set item(e){this._item=e}get(){let e={};return this.each((t,n)=>e[n]=t.get()),e}set(e){for(let t in e){let n=e[t];q.und(n)||this.springs[t].set(n)}}update(e){return e&&this.queue.push(_D(e)),this}start(e){let{queue:t}=this;return e?t=ww(e).map(_D):this.queue=[],this._flush?this._flush(this,t):(jD(this,t),TD(this,t))}stop(e,t){if(e!==!!e&&(t=e),t){let n=this.springs;J(ww(t),t=>n[t].stop(!!e))}else $E(this._state,this._lastAsyncId),this.each(t=>t.stop(!!e));return this}pause(e){if(q.und(e))this.start({pause:!0});else{let t=this.springs;J(ww(e),e=>t[e].pause())}return this}resume(e){if(q.und(e))this.start({pause:!1});else{let t=this.springs;J(ww(e),e=>t[e].resume())}return this}each(e){Cw(this.springs,e)}onLoopReset(e){let t=this._onLoopReset??=new Set;return t.add(e),()=>{t.delete(e)}}_onFrame(){let{onStart:e,onChange:t,onRest:n}=this._events,r=this._active.size>0,i=this._changed.size>0;(r&&!this._started||i&&!this._started)&&(this._started=!0,Tw(e,([e,t])=>{t.value=this.get(),e(t,this,this._item)}));let a=!r&&this._started,o=i||a&&n.size?this.get():null;i&&t.size&&Tw(t,([e,t])=>{t.value=o,e(t,this,this._item)}),a&&(this._started=!1,Tw(n,([e,t])=>{t.value=o,e(t,this,this._item)}))}eventObserved(e){if(e.type==`change`)this._changed.add(e.parent),e.idle||this._active.add(e.parent);else if(e.type==`idle`)this._active.delete(e.parent);else return;K.onFrame(this._onFrame)}};function TD(e,t){return Promise.all(t.map(t=>ED(e,t))).then(t=>JE(e,t))}async function ED(e,t,n){let{keys:r,to:i,from:a,loop:o,onRest:s,onResolve:c}=t,l=q.obj(t.default)&&t.default;o&&(t.loop=!1);let u=t,d=!n&&!u.parentId&&`loop`in t?++e._lastLoopId:n?u.loopId:e._lastLoopId;i===!1&&(t.to=null),a===!1&&(t.from=null);let f=q.arr(i)||q.fun(i)?i:void 0;f?(t.to=void 0,t.onRest=void 0,l&&(l.onRest=void 0)):J(SD,n=>{let r=t[n];if(q.fun(r)){let i=e._events[n];t[n]=(({finished:e,cancelled:t})=>{let n=i.get(r);n?(e||(n.finished=!1),t&&(n.cancelled=!0)):i.set(r,{value:null,finished:e||!1,cancelled:t||!1})}),l&&(l[n]=t[n])}});let p=e._state;t.pause===!p.paused?(p.paused=t.pause,Ew(t.pause?p.pauseQueue:p.resumeQueue)):p.paused&&(t.pause=!0);let m=(r||Object.keys(e.springs)).map(n=>e.springs[n].start(t)),h=t.cancel===!0||kE(t,`cancel`)===!0;(f||h&&p.asyncId)&&m.push(qE(++e._lastAsyncId,{props:t,state:p,actions:{pause:bw,resume:bw,start(t,n){h?($E(p,e._lastAsyncId),n(ZE(e))):(t.onRest=s,n(QE(f,t,p,e)))}}})),p.paused&&await new Promise(e=>{p.resumeQueue.add(e)});let g=JE(e,await Promise.all(m));if(o&&g.finished&&!(n&&g.noop)&&d===e._lastLoopId){let n=gD(t,o,i);if(n)return n.loopId=d,e._onLoopReset?.forEach(e=>e()),jD(e,[n]),ED(e,n,!0)}return c&&K.batchedUpdates(()=>c(g,e,e.item)),g}function DD(e,t){let n={...e.springs};return t&&J(ww(t),e=>{q.und(e.keys)&&(e=_D(e)),q.obj(e.to)||(e={...e,to:void 0}),AD(n,e,e=>kD(e))}),OD(e,n),n}function OD(e,t){Cw(t,(t,n)=>{e.springs[n]||(e.springs[n]=t,MT(t,e))})}function kD(e,t){let n=new mD;return n.key=e,t&&MT(n,t),n}function AD(e,t,n){t.keys&&J(t.keys,r=>{(e[r]||(e[r]=n(r)))._prepareNode(t)})}function jD(e,t){J(t,t=>{AD(e.springs,t,t=>kD(t,e))})}var MD=W.createContext({pause:!1,immediate:!1}),ND=()=>{let e=[],t=function(t){ZT();let r=[];return J(e,(e,i)=>{if(q.und(t))r.push(e.start());else{let a=n(t,e,i);a&&r.push(e.start(a))}}),r};t.current=e,t.add=function(t){e.includes(t)||e.push(t)},t.delete=function(t){let n=e.indexOf(t);~n&&e.splice(n,1)},t.pause=function(){return J(e,e=>e.pause(...arguments)),this},t.resume=function(){return J(e,e=>e.resume(...arguments)),this},t.set=function(t){J(e,(e,n)=>{let r=q.fun(t)?t(n,e):t;r&&e.set(r)})},t.start=function(t){let n=[];return J(e,(e,r)=>{if(q.und(t))n.push(e.start());else{let i=this._getProps(t,e,r);i&&n.push(e.start(i))}}),n},t.stop=function(){return J(e,e=>e.stop(...arguments)),this},t.update=function(t){return J(e,(e,n)=>e.update(this._getProps(t,e,n))),this};let n=function(e,t,n){return q.fun(e)?e(n,t):e};return t._getProps=n,t};function PD(e,t,n){let r=q.fun(t)&&t,{reset:i,sort:a,trail:o=0,reverse:s=!1,expires:c=!0,exitBeforeEnter:l=!1,onDestroyed:u,ref:d,config:f}=r?r():t,p=(0,W.useMemo)(()=>r||arguments.length==3?ND():void 0,[]),m=ww(e),h=[],g=(0,W.useRef)(null),_=i?null:g.current;$T(()=>{g.current=h}),nE(()=>(J(h,e=>{p?.add(e.ctrl),e.ctrl.ref=void 0}),()=>{J(g.current,e=>{e.expired&&clearTimeout(e.expirationId),zE(e.ctrl,p),e.ctrl.stop(!0)})}));let v=ID(m,r?r():t,_),y=i&&g.current||[];$T(()=>J(y,({ctrl:e,item:t,key:n})=>{zE(e,p),EE(u,t,n)}));let b=[];if(_&&J(_,(e,t)=>{e.expired?(clearTimeout(e.expirationId),y.push(e)):(t=b[t]=v.indexOf(e.key),~t&&(h[t]=e))}),J(m,(e,t)=>{h[t]||(h[t]={key:v[t],item:e,phase:`mount`,ctrl:new wD},h[t].ctrl.item=e)}),b.length){let e=-1,{leave:n}=r?r():t;J(b,(t,r)=>{let i=_[r];~t?(e=h.indexOf(i),h[e]={...i,item:m[t]}):n&&h.splice(++e,0,i)})}q.fun(a)&&h.sort((e,t)=>a(e.item,t.item));let x=-o,S=[],C=tE(),w=jE(t),T=new Map,E=(0,W.useRef)(new Map),D=(0,W.useRef)(!1);if(J(h,(e,n)=>{let i=e.key,a=e.phase,s=r?r():t,u,p,m=EE(s.delay||0,i);if(a==`mount`)u=s.enter,p=`enter`;else{let e=v.indexOf(i)<0;if(a!=`leave`){if(e)u=s.leave,p=`leave`;else if(u=s.update)p=`update`;else return}else if(!e)u=s.enter,p=`enter`;else return}if(u=EE(u,e.item,n),u=q.obj(u)?FE(u):{to:u},!u.config){let t=f||w.config;u.config=EE(t,e.item,n,p)}x+=o;let h={...w,delay:m+x,ref:d,immediate:s.immediate,reset:!1,...u};if(p==`enter`&&q.und(h.from)){let i=r?r():t;h.from=EE(q.und(i.initial)||_?i.from:i.initial,e.item,n)}let{onResolve:y}=h;h.onResolve=e=>{EE(y,e);let t=g.current,n=t.find(e=>e.key===i);if(n&&!(e.cancelled&&n.phase!=`update`)&&n.ctrl.idle){let e=t.every(e=>e.ctrl.idle);if(n.phase==`leave`){E.current.delete(n);let t=EE(c,n.item);if(t!==!1){let r=t===!0?0:t;if(n.expired=!0,!e&&r>0){r<=2147483647&&(n.expirationId=setTimeout(C,r));return}}}e&&t.some(e=>e.expired)&&(l&&(D.current=!0),C())}};let b=DD(e.ctrl,h);S.push({payload:h,propsDelay:m}),p===`leave`&&l?E.current.set(e,{phase:p,springs:b,payload:h}):T.set(e,{phase:p,springs:b,payload:h})}),s&&o){let e=S.length;J(S,({payload:t,propsDelay:n},r)=>{t.delay=n+(e-1-r)*o})}let O=(0,W.useContext)(MD),ee=O!==iE(O)&&LE(O);$T(()=>{ee&&J(h,e=>{e.ctrl.start({default:O})})},[O]),J(T,(e,t)=>{if(E.current.size){let e=h.findIndex(e=>e.key===t.key);h.splice(e,1)}}),$T(()=>{J(E.current.size?E.current:T,({phase:e,payload:t},n)=>{let{ctrl:r}=n;n.phase=e,p?.add(r),ee&&e==`enter`&&r.start({default:O}),t&&(BE(r,t.ref),r.ref&&!D.current?r.update(t):(r.start(t),D.current&&=!1))})},i?void 0:n);let te=e=>W.createElement(W.Fragment,null,h.map((t,n)=>{let r=T.get(t)||E.current.get(t),{springs:i}=r||t.ctrl,a=r?{...t,phase:r.phase}:t,o=e({...i},t.item,a,n),s=q.str(t.key)||q.num(t.key)?t.key:t.ctrl.id,c=o?.props??{},l=c?.ref;return o&&o.type?W.createElement(o.type,{...c,key:s,ref:l}):o}));return p?[te,p]:te}var FD=1;function ID(e,{key:t,keys:n=t},r){if(n===null){let t=new Set;return e.map(e=>{let n=r&&r.find(n=>n.item===e&&n.phase!==`leave`&&!t.has(n));return n?(t.add(n),n.key):FD++})}return q.und(n)?e:q.fun(n)?e.map(n):ww(n)}var LD=class extends iD{constructor(e,t){super(),this.source=e,this.idle=!0,this._active=new Set,this.calc=fT(...t);let n=this._get(),r=_E(n);cE(this,r.create(n))}advance(e){let t=this._get();Sw(t,this.get())||(sE(this).setValue(t),this._onChange(t,this.idle)),!this.idle&&zD(this._active)&&BD(this)}_get(){let e=q.arr(this.source)?this.source.map(ET):ww(ET(this.source));return this.calc(...e)}_start(){this.idle&&!zD(this._active)&&(this.idle=!1,J(lE(this),e=>{e.done=!1}),Ow.skipAnimation?(K.batchedUpdates(()=>this.advance()),BD(this)):zw.start(this))}_attach(){let e=1;J(ww(this.source),t=>{TT(t)&&MT(t,this),nD(t)&&(t.idle||this._active.add(t),e=Math.max(e,t.priority+1))}),this.priority=e,this._start()}_detach(){J(ww(this.source),e=>{TT(e)&&NT(e,this)}),this._active.clear(),BD(this)}eventObserved(e){e.type==`change`?e.idle?this.advance():(this._active.add(e.parent),this._start()):e.type==`idle`?this._active.delete(e.parent):e.type==`priority`&&(this.priority=ww(this.source).reduce((e,t)=>Math.max(e,(nD(t)?t.priority:0)+1),0))}};function RD(e){return e.idle!==!1}function zD(e){return!e.size||Array.from(e).every(RD)}function BD(e){e.idle||(e.idle=!0,J(lE(e),e=>{e.done=!0}),kT(e,{type:`idle`,parent:e}))}Ow.assign({createStringInterpolator:GT,to:(e,t)=>new LD(e,t)}),zw.advance;var VD=/^--/;function HD(e,t){return t==null||typeof t==`boolean`||t===``?``:typeof t==`number`&&t!==0&&!VD.test(e)&&!(GD.hasOwnProperty(e)&&GD[e])?t+`px`:(``+t).trim()}var UD={};function WD(e,t){if(!e.nodeType||!e.setAttribute||!e.removeAttribute)return!1;let n=e.nodeName===`filter`||e.parentNode&&e.parentNode.nodeName===`filter`,{className:r,style:i,children:a,scrollTop:o,scrollLeft:s,viewBox:c,...l}=t,u=Object.values(l),d=Object.keys(l).map(t=>n||e.hasAttribute(t)?t:UD[t]||(UD[t]=t.replace(/([A-Z])/g,e=>`-`+e.toLowerCase())));t.hasOwnProperty(`children`)&&(e.textContent=a);for(let t in i)if(i.hasOwnProperty(t)){let n=HD(t,i[t]);VD.test(t)?e.style.setProperty(t,n):e.style[t]=n}d.forEach((t,n)=>{let r=u[n];r===void 0?e.removeAttribute(t):e.setAttribute(t,r)}),t.hasOwnProperty(`className`)&&(r===void 0?e.removeAttribute(`class`):e.className=r),o!==void 0&&(e.scrollTop=o),s!==void 0&&(e.scrollLeft=s),t.hasOwnProperty(`viewBox`)&&(c===void 0?e.removeAttribute(`viewBox`):e.setAttribute(`viewBox`,c))}var GD={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},KD=(e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1),qD=[`Webkit`,`Ms`,`Moz`,`O`];GD=Object.keys(GD).reduce((e,t)=>(qD.forEach(n=>e[KD(n,t)]=e[t]),e),GD);var JD=/^(matrix3d|matrix|translate3d|translate[XYZ]?|scale3d|scale[XYZ]?|rotate3d|rotate[XYZ]?|skew[XY]?)$/,YD=/^(translate)/,XD=/^(rotate|skew)/,ZD=(e,t)=>q.num(e)&&e!==0?e+t:e,QD=(e,t)=>q.arr(e)?e.every(e=>QD(e,t)):q.num(e)?e===t:parseFloat(e)===t,$D=class extends mE{constructor({x:e,y:t,z:n,...r}){let i=[],a=[];(e||t||n)&&(i.push([e||0,t||0,n||0]),a.push(e=>[`translate3d(${e.map(e=>ZD(e,`px`)).join(`,`)})`,QD(e,0)])),Cw(r,(e,t)=>{if(t===`transform`)i.push([e||``]),a.push(e=>[e,e===``]);else if(JD.test(t)){if(delete r[t],q.und(e))return;let n=YD.test(t)?`px`:XD.test(t)?`deg`:``;i.push(ww(e)),a.push(t===`rotate3d`?([e,t,r,i])=>[`rotate3d(${e},${t},${r},${ZD(i,n)})`,QD(i,0)]:e=>[`${t}(${e.map(e=>ZD(e,n)).join(`,`)})`,QD(e,+!!t.startsWith(`scale`))])}}),i.length&&(r.transform=new eO(i,a)),super(r)}},eO=class extends AT{constructor(e,t){super(),this.inputs=e,this.transforms=t,this._value=null}get(){return this._value||=this._get()}_get(){let e=``,t=!0;return J(this.inputs,(n,r)=>{let i=ET(n[0]),[a,o]=this.transforms[r](q.arr(i)?i:n.map(ET));e+=` `+a,t&&=o}),t?`none`:e}observerAdded(e){e==1&&J(this.inputs,e=>J(e,e=>TT(e)&&MT(e,this)))}observerRemoved(e){e==0&&J(this.inputs,e=>J(e,e=>TT(e)&&NT(e,this)))}eventObserved(e){e.type==`change`&&(this._value=null),kT(this,e)}},tO=`a.abbr.address.area.article.aside.audio.b.base.bdi.bdo.big.blockquote.body.br.button.canvas.caption.cite.code.col.colgroup.data.datalist.dd.del.details.dfn.dialog.div.dl.dt.em.embed.fieldset.figcaption.figure.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.iframe.img.input.ins.kbd.keygen.label.legend.li.link.main.map.mark.menu.menuitem.meta.meter.nav.noscript.object.ol.optgroup.option.output.p.param.picture.pre.progress.q.rp.rt.ruby.s.samp.script.section.select.small.source.span.strong.style.sub.summary.sup.table.tbody.td.textarea.tfoot.th.thead.time.title.tr.track.u.ul.var.video.wbr.circle.clipPath.defs.ellipse.foreignObject.g.image.line.linearGradient.mask.path.pattern.polygon.polyline.radialGradient.rect.stop.svg.text.tspan`.split(`.`);Ow.assign({batchedUpdates:MC.unstable_batchedUpdates,createStringInterpolator:GT,colors:Kw});var nO=wE(tO,{applyAnimatedValues:WD,createAnimatedStyle:e=>new $D(e),getComponentProps:({scrollTop:e,scrollLeft:t,...n})=>n}).animated,rO=e=>(0,G.jsx)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`})}),iO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`})]}),aO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M2.25638 6.33803C1.50583 4.83684 2.49311 3 4.05053 3V4.7747C3.72017 4.7747 3.51074 5.16433 3.66995 5.48277L2.25638 6.33803Z`,fill:`#9489DB`})]}),oO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`})]}),sO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3ZM8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317Z`,fill:`#9489DB`})]}),cO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M15.7489 3C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M20.9495 4.7747H15.7489V3H20.9495C22.5069 3 23.4942 4.83684 22.7436 6.33803L21.3301 5.48277C21.4893 5.16433 21.2798 4.7747 20.9495 4.7747Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`})]}),lO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M17.9964 15.833L22.7436 6.33803L21.3301 5.48277L16.5828 14.9778L17.9964 15.833Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M2.25638 6.33803C1.50583 4.83684 2.49311 3 4.05053 3V4.7747C3.72017 4.7747 3.51074 5.16433 3.66995 5.48277L2.25638 6.33803ZM6.93059 15.687L8.34416 14.8317C8.51289 15.1692 8.95664 15.1596 9.11322 14.8151L10.519 15.687C9.75015 17.2339 7.71306 17.252 6.93059 15.687ZM15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747H20.9495C21.2798 4.7747 21.4893 5.16433 21.3301 5.48277L22.7436 6.33803C23.4942 4.83684 22.5069 3 20.9495 3H15.7489C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882Z`,fill:`#9489DB`})]}),uO=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M14.4244 15.865C15.2179 17.3926 17.2257 17.3746 17.9964 15.833L16.5828 14.9778C16.4193 15.3047 15.9934 15.3086 15.8251 14.9846L14.4244 15.865Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.0406 13.2011L14.4244 15.865L15.8251 14.9846L14.4413 12.3206L13.0406 13.2011Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.3408 11.9904C12.954 12.2335 12.8196 12.7756 13.0406 13.2011L14.4413 12.3206C14.2203 11.8951 13.7276 11.7473 13.3408 11.9904Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M15.7489 3C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M20.9495 3H15.7489V4.7747H20.9495V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M22.7436 6.33803C23.4942 4.83684 22.5069 3 20.9495 3V4.7747C21.2798 4.7747 21.4893 5.16433 21.3301 5.48277L22.7436 6.33803Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M17.9964 15.833L22.7436 6.33803L21.3301 5.48277L16.5828 14.9778L17.9964 15.833Z`,fill:`#9489DB`})]}),dO=()=>{let e=[W.createElement(rO,null),W.createElement(iO,null),W.createElement(aO,null),W.createElement(oO,null),W.createElement(sO,null),W.createElement(cO,null),W.createElement(lO,null),W.createElement(uO,null)],[t,n]=(0,W.useState)(!0),[r,i]=(0,W.useState)(!0);(0,W.useEffect)(()=>()=>{i(!1)},[]);let a=PD(e,{loop:t,from:{opacity:0},enter:{opacity:1},trail:100,config:{duration:1500},onRest:()=>r&&n(!t)})((e,t)=>W.createElement(nO.div,{style:{...e,gridRowStart:1,gridColumnStart:1}},t));return W.createElement(`div`,{style:{display:`grid`,gridTemplateColumns:`1fr`}},a)},fO=e=>(0,G.jsx)(`svg`,{width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24ZM18.8485 9.24853C19.3172 8.7799 19.3172 8.0201 18.8485 7.55147C18.3799 7.08284 17.6201 7.08284 17.1515 7.55147L9.6 15.1029L6.84853 12.3515C6.3799 11.8828 5.6201 11.8828 5.15147 12.3515C4.68284 12.8201 4.68284 13.5799 5.15147 14.0485L9.6 18.4971L18.8485 9.24853Z`,fill:`#5FCA7D`})}),pO=e=>(0,G.jsx)(`svg`,{width:24,height:24,viewBox:`0 0 24 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M21.4286 12C21.4286 17.2073 17.2073 21.4286 12 21.4286C6.79274 21.4286 2.57143 17.2073 2.57143 12C2.57143 6.79274 6.79274 2.57143 12 2.57143C17.2073 2.57143 21.4286 6.79274 21.4286 12ZM24 12C24 18.6274 18.6274 24 12 24C5.37258 24 0 18.6274 0 12C0 5.37258 5.37258 0 12 0C18.6274 0 24 5.37258 24 12ZM7.37141 8.66656L10.7049 12.0001L7.37144 15.3336L8.58362 16.5458L11.9171 13.2123L15.2506 16.5458L16.4628 15.3336L13.1293 12.0001L16.4628 8.66656L15.2506 7.45438L11.9171 10.7879L8.58359 7.45438L7.37141 8.66656Z`,fill:`#E6635A`})}),mO=e=>(0,G.jsx)(`svg`,{width:14,height:14,viewBox:`0 0 14 14`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:(0,G.jsx)(`path`,{fillRule:`evenodd`,clipRule:`evenodd`,d:`M12.5 7C12.5 10.0376 10.0376 12.5 7 12.5C3.96243 12.5 1.5 10.0376 1.5 7C1.5 3.96243 3.96243 1.5 7 1.5C10.0376 1.5 12.5 3.96243 12.5 7ZM14 7C14 10.866 10.866 14 7 14C3.13401 14 0 10.866 0 7C0 3.13401 3.13401 0 7 0C10.866 0 14 3.13401 14 7ZM4.3 5.05546L6.24455 7.00002L4.30002 8.94455L5.00712 9.65166L6.95166 7.70712L8.89619 9.65166L9.6033 8.94455L7.65877 7.00002L9.60332 5.05546L8.89621 4.34836L6.95166 6.29291L5.00711 4.34836L4.3 5.05546Z`,fill:`#E6635A`})}),hO=document,gO=()=>hO,{min:_O,max:vO}=Math,yO=(e,t=0,n=1)=>_O(vO(t,e),n),bO=e=>{e._clipped=!1,e._unclipped=e.slice(0);for(let t=0;t<=3;t++)t<3?((e[t]<0||e[t]>255)&&(e._clipped=!0),e[t]=yO(e[t],0,255)):t===3&&(e[t]=yO(e[t],0,1));return e},xO={};for(let e of[`Boolean`,`Number`,`String`,`Function`,`Array`,`Date`,`RegExp`,`Undefined`,`Null`])xO[`[object ${e}]`]=e.toLowerCase();function Y(e){return xO[Object.prototype.toString.call(e)]||`object`}var X=(e,t=null)=>e.length>=3?Array.prototype.slice.call(e):Y(e[0])==`object`&&t?t.split(``).filter(t=>e[0][t]!==void 0).map(t=>e[0][t]):e[0].slice(0),SO=e=>{if(e.length<2)return null;let t=e.length-1;return Y(e[t])==`string`?e[t].toLowerCase():null},{PI:CO,min:wO,max:TO}=Math,EO=e=>Math.round(e*100)/100,DO=e=>Math.round(e*100)/100,OO=CO*2,kO=CO/3,AO=CO/180,jO=180/CO;function MO(e){return[...e.slice(0,3).reverse(),...e.slice(3)]}var Z={format:{},autodetect:[]},Q=class{constructor(...e){let t=this;if(Y(e[0])===`object`&&e[0].constructor&&e[0].constructor===this.constructor)return e[0];let n=SO(e),r=!1;if(!n){r=!0,Z.sorted||=(Z.autodetect=Z.autodetect.sort((e,t)=>t.p-e.p),!0);for(let t of Z.autodetect)if(n=t.test(...e),n)break}if(Z.format[n])t._rgb=bO(Z.format[n].apply(null,r?e:e.slice(0,-1)));else throw Error(`unknown format: `+e);t._rgb.length===3&&t._rgb.push(1)}toString(){return Y(this.hex)==`function`?this.hex():`[${this._rgb.join(`,`)}]`}},NO=`3.2.0`,$=(...e)=>new Q(...e);$.version=NO;var PO={aliceblue:`#f0f8ff`,antiquewhite:`#faebd7`,aqua:`#00ffff`,aquamarine:`#7fffd4`,azure:`#f0ffff`,beige:`#f5f5dc`,bisque:`#ffe4c4`,black:`#000000`,blanchedalmond:`#ffebcd`,blue:`#0000ff`,blueviolet:`#8a2be2`,brown:`#a52a2a`,burlywood:`#deb887`,cadetblue:`#5f9ea0`,chartreuse:`#7fff00`,chocolate:`#d2691e`,coral:`#ff7f50`,cornflowerblue:`#6495ed`,cornsilk:`#fff8dc`,crimson:`#dc143c`,cyan:`#00ffff`,darkblue:`#00008b`,darkcyan:`#008b8b`,darkgoldenrod:`#b8860b`,darkgray:`#a9a9a9`,darkgreen:`#006400`,darkgrey:`#a9a9a9`,darkkhaki:`#bdb76b`,darkmagenta:`#8b008b`,darkolivegreen:`#556b2f`,darkorange:`#ff8c00`,darkorchid:`#9932cc`,darkred:`#8b0000`,darksalmon:`#e9967a`,darkseagreen:`#8fbc8f`,darkslateblue:`#483d8b`,darkslategray:`#2f4f4f`,darkslategrey:`#2f4f4f`,darkturquoise:`#00ced1`,darkviolet:`#9400d3`,deeppink:`#ff1493`,deepskyblue:`#00bfff`,dimgray:`#696969`,dimgrey:`#696969`,dodgerblue:`#1e90ff`,firebrick:`#b22222`,floralwhite:`#fffaf0`,forestgreen:`#228b22`,fuchsia:`#ff00ff`,gainsboro:`#dcdcdc`,ghostwhite:`#f8f8ff`,gold:`#ffd700`,goldenrod:`#daa520`,gray:`#808080`,green:`#008000`,greenyellow:`#adff2f`,grey:`#808080`,honeydew:`#f0fff0`,hotpink:`#ff69b4`,indianred:`#cd5c5c`,indigo:`#4b0082`,ivory:`#fffff0`,khaki:`#f0e68c`,laserlemon:`#ffff54`,lavender:`#e6e6fa`,lavenderblush:`#fff0f5`,lawngreen:`#7cfc00`,lemonchiffon:`#fffacd`,lightblue:`#add8e6`,lightcoral:`#f08080`,lightcyan:`#e0ffff`,lightgoldenrod:`#fafad2`,lightgoldenrodyellow:`#fafad2`,lightgray:`#d3d3d3`,lightgreen:`#90ee90`,lightgrey:`#d3d3d3`,lightpink:`#ffb6c1`,lightsalmon:`#ffa07a`,lightseagreen:`#20b2aa`,lightskyblue:`#87cefa`,lightslategray:`#778899`,lightslategrey:`#778899`,lightsteelblue:`#b0c4de`,lightyellow:`#ffffe0`,lime:`#00ff00`,limegreen:`#32cd32`,linen:`#faf0e6`,magenta:`#ff00ff`,maroon:`#800000`,maroon2:`#7f0000`,maroon3:`#b03060`,mediumaquamarine:`#66cdaa`,mediumblue:`#0000cd`,mediumorchid:`#ba55d3`,mediumpurple:`#9370db`,mediumseagreen:`#3cb371`,mediumslateblue:`#7b68ee`,mediumspringgreen:`#00fa9a`,mediumturquoise:`#48d1cc`,mediumvioletred:`#c71585`,midnightblue:`#191970`,mintcream:`#f5fffa`,mistyrose:`#ffe4e1`,moccasin:`#ffe4b5`,navajowhite:`#ffdead`,navy:`#000080`,oldlace:`#fdf5e6`,olive:`#808000`,olivedrab:`#6b8e23`,orange:`#ffa500`,orangered:`#ff4500`,orchid:`#da70d6`,palegoldenrod:`#eee8aa`,palegreen:`#98fb98`,paleturquoise:`#afeeee`,palevioletred:`#db7093`,papayawhip:`#ffefd5`,peachpuff:`#ffdab9`,peru:`#cd853f`,pink:`#ffc0cb`,plum:`#dda0dd`,powderblue:`#b0e0e6`,purple:`#800080`,purple2:`#7f007f`,purple3:`#a020f0`,rebeccapurple:`#663399`,red:`#ff0000`,rosybrown:`#bc8f8f`,royalblue:`#4169e1`,saddlebrown:`#8b4513`,salmon:`#fa8072`,sandybrown:`#f4a460`,seagreen:`#2e8b57`,seashell:`#fff5ee`,sienna:`#a0522d`,silver:`#c0c0c0`,skyblue:`#87ceeb`,slateblue:`#6a5acd`,slategray:`#708090`,slategrey:`#708090`,snow:`#fffafa`,springgreen:`#00ff7f`,steelblue:`#4682b4`,tan:`#d2b48c`,teal:`#008080`,thistle:`#d8bfd8`,tomato:`#ff6347`,turquoise:`#40e0d0`,violet:`#ee82ee`,wheat:`#f5deb3`,white:`#ffffff`,whitesmoke:`#f5f5f5`,yellow:`#ffff00`,yellowgreen:`#9acd32`},FO=/^#?([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$/,IO=/^#?([A-Fa-f0-9]{8}|[A-Fa-f0-9]{4})$/,LO=e=>{if(e.match(FO)){(e.length===4||e.length===7)&&(e=e.substr(1)),e.length===3&&(e=e.split(``),e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]);let t=parseInt(e,16);return[t>>16,t>>8&255,t&255,1]}if(e.match(IO)){(e.length===5||e.length===9)&&(e=e.substr(1)),e.length===4&&(e=e.split(``),e=e[0]+e[0]+e[1]+e[1]+e[2]+e[2]+e[3]+e[3]);let t=parseInt(e,16);return[t>>24&255,t>>16&255,t>>8&255,Math.round((t&255)/255*100)/100]}throw Error(`unknown hex color: ${e}`)},{round:RO}=Math,zO=(...e)=>{let[t,n,r,i]=X(e,`rgba`),a=SO(e)||`auto`;i===void 0&&(i=1),a===`auto`&&(a=i<1?`rgba`:`rgb`),t=RO(t),n=RO(n),r=RO(r);let o=`000000`+(t<<16|n<<8|r).toString(16);o=o.substr(o.length-6);let s=`0`+RO(i*255).toString(16);switch(s=s.substr(s.length-2),a.toLowerCase()){case`rgba`:return`#${o}${s}`;case`argb`:return`#${s}${o}`;default:return`#${o}`}};Q.prototype.name=function(){let e=zO(this._rgb,`rgb`);for(let t of Object.keys(PO))if(PO[t]===e)return t.toLowerCase();return e},Z.format.named=e=>{if(e=e.toLowerCase(),PO[e])return LO(PO[e]);throw Error(`unknown color name: `+e)},Z.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&Y(e)===`string`&&PO[e.toLowerCase()])return`named`}}),Q.prototype.alpha=function(e,t=!1){return e!==void 0&&Y(e)===`number`?t?(this._rgb[3]=e,this):new Q([this._rgb[0],this._rgb[1],this._rgb[2],e],`rgb`):this._rgb[3]},Q.prototype.clipped=function(){return this._rgb._clipped||!1};var BO={Kn:18,labWhitePoint:`d65`,Xn:.95047,Yn:1,Zn:1.08883,t0:.137931034,t1:.206896552,t2:.12841855,t3:.008856452,kE:216/24389,kKE:8,kK:24389/27,RefWhiteRGB:{X:.95047,Y:1,Z:1.08883},MtxRGB2XYZ:{m00:.4124564390896922,m01:.21267285140562253,m02:.0193338955823293,m10:.357576077643909,m11:.715152155287818,m12:.11919202588130297,m20:.18043748326639894,m21:.07217499330655958,m22:.9503040785363679},MtxXYZ2RGB:{m00:3.2404541621141045,m01:-.9692660305051868,m02:.055643430959114726,m10:-1.5371385127977166,m11:1.8760108454466942,m12:-.2040259135167538,m20:-.498531409556016,m21:.041556017530349834,m22:1.0572251882231791},As:.9414285350000001,Bs:1.040417467,Cs:1.089532651,MtxAdaptMa:{m00:.8951,m01:-.7502,m02:.0389,m10:.2664,m11:1.7135,m12:-.0685,m20:-.1614,m21:.0367,m22:1.0296},MtxAdaptMaI:{m00:.9869929054667123,m01:.43230526972339456,m02:-.008528664575177328,m10:-.14705425642099013,m11:.5183602715367776,m12:.04004282165408487,m20:.15996265166373125,m21:.0492912282128556,m22:.9684866957875502}},VO=new Map([[`a`,[1.0985,.35585]],[`b`,[1.0985,.35585]],[`c`,[.98074,1.18232]],[`d50`,[.96422,.82521]],[`d55`,[.95682,.92149]],[`d65`,[.95047,1.08883]],[`e`,[1,1,1]],[`f2`,[.99186,.67393]],[`f7`,[.95041,1.08747]],[`f11`,[1.00962,.6435]],[`icc`,[.96422,.82521]]]);function HO(e){let t=VO.get(String(e).toLowerCase());if(!t)throw Error(`unknown Lab illuminant `+e);BO.labWhitePoint=e,BO.Xn=t[0],BO.Zn=t[1]}function UO(){return BO.labWhitePoint}var WO=(...e)=>{e=X(e,`lab`);let[t,n,r]=e,[i,a,o]=GO(t,n,r),[s,c,l]=qO(i,a,o);return[s,c,l,e.length>3?e[3]:1]},GO=(e,t,n)=>{let{kE:r,kK:i,kKE:a,Xn:o,Yn:s,Zn:c}=BO,l=(e+16)/116,u=.002*t+l,d=l-.005*n,f=u*u*u,p=d*d*d,m=f>r?f:(116*u-16)/i,h=e>a?((e+16)/116)**3:e/i,g=p>r?p:(116*d-16)/i;return[m*o,h*s,g*c]},KO=e=>{let t=Math.sign(e);return e=Math.abs(e),(e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055)*t},qO=(e,t,n)=>{let{MtxAdaptMa:r,MtxAdaptMaI:i,MtxXYZ2RGB:a,RefWhiteRGB:o,Xn:s,Yn:c,Zn:l}=BO,u=s*r.m00+c*r.m10+l*r.m20,d=s*r.m01+c*r.m11+l*r.m21,f=s*r.m02+c*r.m12+l*r.m22,p=o.X*r.m00+o.Y*r.m10+o.Z*r.m20,m=o.X*r.m01+o.Y*r.m11+o.Z*r.m21,h=o.X*r.m02+o.Y*r.m12+o.Z*r.m22,g=(e*r.m00+t*r.m10+n*r.m20)*(p/u),_=(e*r.m01+t*r.m11+n*r.m21)*(m/d),v=(e*r.m02+t*r.m12+n*r.m22)*(h/f),y=g*i.m00+_*i.m10+v*i.m20,b=g*i.m01+_*i.m11+v*i.m21,x=g*i.m02+_*i.m12+v*i.m22,S=KO(y*a.m00+b*a.m10+x*a.m20),C=KO(y*a.m01+b*a.m11+x*a.m21),w=KO(y*a.m02+b*a.m12+x*a.m22);return[S*255,C*255,w*255]},JO=(...e)=>{let[t,n,r,...i]=X(e,`rgb`),[a,o,s]=ZO(t,n,r),[c,l,u]=YO(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]};function YO(e,t,n){let{Xn:r,Yn:i,Zn:a,kE:o,kK:s}=BO,c=e/r,l=t/i,u=n/a,d=c>o?c**(1/3):(s*c+16)/116,f=l>o?l**(1/3):(s*l+16)/116,p=u>o?u**(1/3):(s*u+16)/116;return[116*f-16,500*(d-f),200*(f-p)]}function XO(e){let t=Math.sign(e);return e=Math.abs(e),(e<=.04045?e/12.92:((e+.055)/1.055)**2.4)*t}var ZO=(e,t,n)=>{e=XO(e/255),t=XO(t/255),n=XO(n/255);let{MtxRGB2XYZ:r,MtxAdaptMa:i,MtxAdaptMaI:a,Xn:o,Yn:s,Zn:c,As:l,Bs:u,Cs:d}=BO,f=e*r.m00+t*r.m10+n*r.m20,p=e*r.m01+t*r.m11+n*r.m21,m=e*r.m02+t*r.m12+n*r.m22,h=o*i.m00+s*i.m10+c*i.m20,g=o*i.m01+s*i.m11+c*i.m21,_=o*i.m02+s*i.m12+c*i.m22,v=f*i.m00+p*i.m10+m*i.m20,y=f*i.m01+p*i.m11+m*i.m21,b=f*i.m02+p*i.m12+m*i.m22;return v*=h/l,y*=g/u,b*=_/d,f=v*a.m00+y*a.m10+b*a.m20,p=v*a.m01+y*a.m11+b*a.m21,m=v*a.m02+y*a.m12+b*a.m22,[f,p,m]};Q.prototype.lab=function(){return JO(this._rgb)},Object.assign($,{lab:(...e)=>new Q(...e,`lab`),getLabWhitePoint:UO,setLabWhitePoint:HO}),Z.format.lab=WO,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`lab`),Y(e)===`array`&&e.length===3)return`lab`}}),Q.prototype.darken=function(e=1){let t=this,n=t.lab();return n[0]-=BO.Kn*e,new Q(n,`lab`).alpha(t.alpha(),!0)},Q.prototype.brighten=function(e=1){return this.darken(-e)},Q.prototype.darker=Q.prototype.darken,Q.prototype.brighter=Q.prototype.brighten,Q.prototype.get=function(e){let[t,n]=e.split(`.`),r=this[t]();if(n){let e=t.indexOf(n)-(t.substr(0,2)===`ok`?2:0);if(e>-1)return r[e];throw Error(`unknown channel ${n} in mode ${t}`)}return r};var{pow:QO}=Math,$O=1e-7,ek=20;Q.prototype.luminance=function(e,t=`rgb`){if(e!==void 0&&Y(e)===`number`){if(e===0)return new Q([0,0,0,this._rgb[3]],`rgb`);if(e===1)return new Q([255,255,255,this._rgb[3]],`rgb`);let n=this.luminance(),r=ek,i=(n,a)=>{let o=n.interpolate(a,.5,t),s=o.luminance();return Math.abs(e-s)<$O||!r--?o:s>e?i(n,o):i(o,a)};return new Q([...(n>e?i(new Q([0,0,0]),this):i(this,new Q([255,255,255]))).rgb(),this._rgb[3]])}return tk(...this._rgb.slice(0,3))};var tk=(e,t,n)=>(e=nk(e),t=nk(t),n=nk(n),.2126*e+.7152*t+.0722*n),nk=e=>(e/=255,e<=.03928?e/12.92:QO((e+.055)/1.055,2.4)),rk={},ik=(e,t,n=.5,...r)=>{let i=r[0]||`lrgb`;if(!rk[i]&&!r.length&&(i=Object.keys(rk)[0]),!rk[i])throw Error(`interpolation mode ${i} is not defined`);return Y(e)!==`object`&&(e=new Q(e)),Y(t)!==`object`&&(t=new Q(t)),rk[i](e,t,n).alpha(e.alpha()+n*(t.alpha()-e.alpha()))};Q.prototype.mix=Q.prototype.interpolate=function(e,t=.5,...n){return ik(this,e,t,...n)},Q.prototype.premultiply=function(e=!1){let t=this._rgb,n=t[3];return e?(this._rgb=[t[0]*n,t[1]*n,t[2]*n,n],this):new Q([t[0]*n,t[1]*n,t[2]*n,n],`rgb`)};var{sin:ak,cos:ok}=Math,sk=(...e)=>{let[t,n,r]=X(e,`lch`);return isNaN(r)&&(r=0),r*=AO,[t,ok(r)*n,ak(r)*n]},ck=(...e)=>{e=X(e,`lch`);let[t,n,r]=e,[i,a,o]=sk(t,n,r),[s,c,l]=WO(i,a,o);return[s,c,l,e.length>3?e[3]:1]},lk=(...e)=>ck(...MO(X(e,`hcl`))),{sqrt:uk,atan2:dk,round:fk}=Math,pk=(...e)=>{let[t,n,r]=X(e,`lab`),i=uk(n*n+r*r),a=(dk(r,n)*jO+360)%360;return fk(i*1e4)===0&&(a=NaN),[t,i,a]},mk=(...e)=>{let[t,n,r,...i]=X(e,`rgb`),[a,o,s]=JO(t,n,r),[c,l,u]=pk(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]};Q.prototype.lch=function(){return mk(this._rgb)},Q.prototype.hcl=function(){return MO(mk(this._rgb))},Object.assign($,{lch:(...e)=>new Q(...e,`lch`),hcl:(...e)=>new Q(...e,`hcl`)}),Z.format.lch=ck,Z.format.hcl=lk,[`lch`,`hcl`].forEach(e=>Z.autodetect.push({p:2,test:(...t)=>{if(t=X(t,e),Y(t)===`array`&&t.length===3)return e}})),Q.prototype.saturate=function(e=1){let t=this,n=t.lch();return n[1]+=BO.Kn*e,n[1]<0&&(n[1]=0),new Q(n,`lch`).alpha(t.alpha(),!0)},Q.prototype.desaturate=function(e=1){return this.saturate(-e)},Q.prototype.set=function(e,t,n=!1){let[r,i]=e.split(`.`),a=this[r]();if(i){let e=r.indexOf(i)-(r.substr(0,2)===`ok`?2:0);if(e>-1){if(Y(t)==`string`)switch(t.charAt(0)){case`+`:a[e]+=+t;break;case`-`:a[e]+=+t;break;case`*`:a[e]*=+t.substr(1);break;case`/`:a[e]/=+t.substr(1);break;default:a[e]=+t}else if(Y(t)===`number`)a[e]=t;else throw Error(`unsupported value for Color.set`);let i=new Q(a,r);return n?(this._rgb=i._rgb,this):i}throw Error(`unknown channel ${i} in mode ${r}`)}return a},Q.prototype.tint=function(e=.5,...t){return ik(this,`white`,e,...t)},Q.prototype.shade=function(e=.5,...t){return ik(this,`black`,e,...t)},rk.rgb=(e,t,n)=>{let r=e._rgb,i=t._rgb;return new Q(r[0]+n*(i[0]-r[0]),r[1]+n*(i[1]-r[1]),r[2]+n*(i[2]-r[2]),`rgb`)};var{sqrt:hk,pow:gk}=Math;rk.lrgb=(e,t,n)=>{let[r,i,a]=e._rgb,[o,s,c]=t._rgb;return new Q(hk(gk(r,2)*(1-n)+gk(o,2)*n),hk(gk(i,2)*(1-n)+gk(s,2)*n),hk(gk(a,2)*(1-n)+gk(c,2)*n),`rgb`)},rk.lab=(e,t,n)=>{let r=e.lab(),i=t.lab();return new Q(r[0]+n*(i[0]-r[0]),r[1]+n*(i[1]-r[1]),r[2]+n*(i[2]-r[2]),`lab`)};var _k=(e,t,n,r)=>{let i,a;r===`hsl`?(i=e.hsl(),a=t.hsl()):r===`hsv`?(i=e.hsv(),a=t.hsv()):r===`hcg`?(i=e.hcg(),a=t.hcg()):r===`hsi`?(i=e.hsi(),a=t.hsi()):r===`lch`||r===`hcl`?(r=`hcl`,i=e.hcl(),a=t.hcl()):r===`oklch`&&(i=e.oklch().reverse(),a=t.oklch().reverse());let o,s,c,l,u,d;(r.substr(0,1)===`h`||r===`oklch`)&&([o,c,u]=i,[s,l,d]=a);let f,p,m,h;return!isNaN(o)&&!isNaN(s)?(h=s>o&&s-o>180?s-(o+360):s<o&&o-s>180?s+360-o:s-o,p=o+n*h):isNaN(o)?isNaN(s)?p=NaN:(p=s,(u==1||u==0)&&r!=`hsv`&&(f=l)):(p=o,(d==1||d==0)&&r!=`hsv`&&(f=c)),f===void 0&&(f=c+n*(l-c)),m=u+n*(d-u),r===`oklch`?new Q([m,f,p],r):new Q([p,f,m],r)},vk=(e,t,n)=>_k(e,t,n,`lch`);rk.lch=vk,rk.hcl=vk;var yk=e=>{if(Y(e)==`number`&&e>=0&&e<=16777215)return[e>>16,e>>8&255,e&255,1];throw Error(`unknown num color: `+e)},bk=(...e)=>{let[t,n,r]=X(e,`rgb`);return(t<<16)+(n<<8)+r};Q.prototype.num=function(){return bk(this._rgb)},Object.assign($,{num:(...e)=>new Q(...e,`num`)}),Z.format.num=yk,Z.autodetect.push({p:5,test:(...e)=>{if(e.length===1&&Y(e[0])===`number`&&e[0]>=0&&e[0]<=16777215)return`num`}}),rk.num=(e,t,n)=>{let r=e.num();return new Q(r+n*(t.num()-r),`num`)};var{floor:xk}=Math,Sk=(...e)=>{e=X(e,`hcg`);let[t,n,r]=e,i,a,o;r*=255;let s=n*255;if(n===0)i=a=o=r;else{t===360&&(t=0),t>360&&(t-=360),t<0&&(t+=360),t/=60;let e=xk(t),c=t-e,l=r*(1-n),u=l+s*(1-c),d=l+s*c,f=l+s;switch(e){case 0:[i,a,o]=[f,d,l];break;case 1:[i,a,o]=[u,f,l];break;case 2:[i,a,o]=[l,f,d];break;case 3:[i,a,o]=[l,u,f];break;case 4:[i,a,o]=[d,l,f];break;case 5:[i,a,o]=[f,l,u]}}return[i,a,o,e.length>3?e[3]:1]},Ck=(...e)=>{let[t,n,r]=X(e,`rgb`),i=wO(t,n,r),a=TO(t,n,r),o=a-i,s=o*100/255,c=i/(255-o)*100,l;return o===0?l=NaN:(t===a&&(l=(n-r)/o),n===a&&(l=2+(r-t)/o),r===a&&(l=4+(t-n)/o),l*=60,l<0&&(l+=360)),[l,s,c]};Q.prototype.hcg=function(){return Ck(this._rgb)},$.hcg=(...e)=>new Q(...e,`hcg`),Z.format.hcg=Sk,Z.autodetect.push({p:1,test:(...e)=>{if(e=X(e,`hcg`),Y(e)===`array`&&e.length===3)return`hcg`}}),rk.hcg=(e,t,n)=>_k(e,t,n,`hcg`);var{cos:wk}=Math,Tk=(...e)=>{e=X(e,`hsi`);let[t,n,r]=e,i,a,o;return isNaN(t)&&(t=0),isNaN(n)&&(n=0),t>360&&(t-=360),t<0&&(t+=360),t/=360,t<1/3?(o=(1-n)/3,i=(1+n*wk(OO*t)/wk(kO-OO*t))/3,a=1-(o+i)):t<2/3?(t-=1/3,i=(1-n)/3,a=(1+n*wk(OO*t)/wk(kO-OO*t))/3,o=1-(i+a)):(t-=2/3,a=(1-n)/3,o=(1+n*wk(OO*t)/wk(kO-OO*t))/3,i=1-(a+o)),i=yO(r*i*3),a=yO(r*a*3),o=yO(r*o*3),[i*255,a*255,o*255,e.length>3?e[3]:1]},{min:Ek,sqrt:Dk,acos:Ok}=Math,kk=(...e)=>{let[t,n,r]=X(e,`rgb`);t/=255,n/=255,r/=255;let i,a=Ek(t,n,r),o=(t+n+r)/3,s=o>0?1-a/o:0;return s===0?i=NaN:(i=(t-n+(t-r))/2,i/=Dk((t-n)*(t-n)+(t-r)*(n-r)),i=Ok(i),r>n&&(i=OO-i),i/=OO),[i*360,s,o]};Q.prototype.hsi=function(){return kk(this._rgb)},$.hsi=(...e)=>new Q(...e,`hsi`),Z.format.hsi=Tk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`hsi`),Y(e)===`array`&&e.length===3)return`hsi`}}),rk.hsi=(e,t,n)=>_k(e,t,n,`hsi`);var Ak=(...e)=>{e=X(e,`hsl`);let[t,n,r]=e,i,a,o;if(n===0)i=a=o=r*255;else{let e=[0,0,0],s=[0,0,0],c=r<.5?r*(1+n):r+n-r*n,l=2*r-c,u=t/360;e[0]=u+1/3,e[1]=u,e[2]=u-1/3;for(let t=0;t<3;t++)e[t]<0&&(e[t]+=1),e[t]>1&&--e[t],6*e[t]<1?s[t]=l+(c-l)*6*e[t]:2*e[t]<1?s[t]=c:3*e[t]<2?s[t]=l+(c-l)*(2/3-e[t])*6:s[t]=l;[i,a,o]=[s[0]*255,s[1]*255,s[2]*255]}return e.length>3?[i,a,o,e[3]]:[i,a,o,1]},jk=(...e)=>{e=X(e,`rgba`);let[t,n,r]=e;t/=255,n/=255,r/=255;let i=wO(t,n,r),a=TO(t,n,r),o=(a+i)/2,s,c;return a===i?(s=0,c=NaN):s=o<.5?(a-i)/(a+i):(a-i)/(2-a-i),t==a?c=(n-r)/(a-i):n==a?c=2+(r-t)/(a-i):r==a&&(c=4+(t-n)/(a-i)),c*=60,c<0&&(c+=360),e.length>3&&e[3]!==void 0?[c,s,o,e[3]]:[c,s,o]};Q.prototype.hsl=function(){return jk(this._rgb)},$.hsl=(...e)=>new Q(...e,`hsl`),Z.format.hsl=Ak,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`hsl`),Y(e)===`array`&&e.length===3)return`hsl`}}),rk.hsl=(e,t,n)=>_k(e,t,n,`hsl`);var{floor:Mk}=Math,Nk=(...e)=>{e=X(e,`hsv`);let[t,n,r]=e,i,a,o;if(r*=255,n===0)i=a=o=r;else{t===360&&(t=0),t>360&&(t-=360),t<0&&(t+=360),t/=60;let e=Mk(t),s=t-e,c=r*(1-n),l=r*(1-n*s),u=r*(1-n*(1-s));switch(e){case 0:[i,a,o]=[r,u,c];break;case 1:[i,a,o]=[l,r,c];break;case 2:[i,a,o]=[c,r,u];break;case 3:[i,a,o]=[c,l,r];break;case 4:[i,a,o]=[u,c,r];break;case 5:[i,a,o]=[r,c,l]}}return[i,a,o,e.length>3?e[3]:1]},{min:Pk,max:Fk}=Math,Ik=(...e)=>{e=X(e,`rgb`);let[t,n,r]=e,i=Pk(t,n,r),a=Fk(t,n,r),o=a-i,s,c,l;return l=a/255,a===0?(s=NaN,c=0):(c=o/a,t===a&&(s=(n-r)/o),n===a&&(s=2+(r-t)/o),r===a&&(s=4+(t-n)/o),s*=60,s<0&&(s+=360)),[s,c,l]};Q.prototype.hsv=function(){return Ik(this._rgb)},$.hsv=(...e)=>new Q(...e,`hsv`),Z.format.hsv=Nk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`hsv`),Y(e)===`array`&&e.length===3)return`hsv`}}),rk.hsv=(e,t,n)=>_k(e,t,n,`hsv`);function Lk(e,t){let n=e.length;Array.isArray(e[0])||(e=[e]),Array.isArray(t[0])||(t=t.map(e=>[e]));let r=t[0].length,i=t[0].map((e,n)=>t.map(e=>e[n])),a=e.map(e=>i.map(t=>Array.isArray(e)?e.reduce((e,n,r)=>e+n*(t[r]||0),0):t.reduce((t,n)=>t+n*e,0)));return n===1&&(a=a[0]),r===1?a.map(e=>e[0]):a}var Rk=(...e)=>{e=X(e,`lab`);let[t,n,r,...i]=e,[a,o,s]=zk([t,n,r]),[c,l,u]=qO(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]};function zk(e){return Lk([[1.2268798758459243,-.5578149944602171,.2813910456659647],[-.0405757452148008,1.112286803280317,-.0717110580655164],[-.0763729366746601,-.4214933324022432,1.5869240198367816]],Lk([[1,.3963377773761749,.2158037573099136],[1,-.1055613458156586,-.0638541728258133],[1,-.0894841775298119,-1.2914855480194092]],e).map(e=>e**3))}var Bk=(...e)=>{let[t,n,r,...i]=X(e,`rgb`);return[...Vk(ZO(t,n,r)),...i.length>0&&i[0]<1?[i[0]]:[]]};function Vk(e){return Lk([[.210454268309314,.7936177747023054,-.0040720430116193],[1.9779985324311684,-2.42859224204858,.450593709617411],[.0259040424655478,.7827717124575296,-.8086757549230774]],Lk([[.819022437996703,.3619062600528904,-.1288737815209879],[.0329836539323885,.9292868615863434,.0361446663506424],[.0481771893596242,.2642395317527308,.6335478284694309]],e).map(e=>Math.cbrt(e)))}Q.prototype.oklab=function(){return Bk(this._rgb)},Object.assign($,{oklab:(...e)=>new Q(...e,`oklab`)}),Z.format.oklab=Rk,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`oklab`),Y(e)===`array`&&e.length===3)return`oklab`}}),rk.oklab=(e,t,n)=>{let r=e.oklab(),i=t.oklab();return new Q(r[0]+n*(i[0]-r[0]),r[1]+n*(i[1]-r[1]),r[2]+n*(i[2]-r[2]),`oklab`)},rk.oklch=(e,t,n)=>_k(e,t,n,`oklch`);var{pow:Hk,sqrt:Uk,PI:Wk,cos:Gk,sin:Kk,atan2:qk}=Math,Jk=(e,t=`lrgb`,n=null)=>{let r=e.length;n||=Array.from(Array(r)).map(()=>1);let i=r/n.reduce(function(e,t){return e+t});if(n.forEach((e,t)=>{n[t]*=i}),e=e.map(e=>new Q(e)),t===`lrgb`)return Yk(e,n);let a=e.shift(),o=a.get(t),s=[],c=0,l=0;for(let e=0;e<o.length;e++)if(o[e]=(o[e]||0)*n[0],s.push(isNaN(o[e])?0:n[0]),t.charAt(e)===`h`&&!isNaN(o[e])){let t=o[e]/180*Wk;c+=Gk(t)*n[0],l+=Kk(t)*n[0]}let u=a.alpha()*n[0];e.forEach((e,r)=>{let i=e.get(t);u+=e.alpha()*n[r+1];for(let e=0;e<o.length;e++)if(!isNaN(i[e])){if(s[e]+=n[r+1],t.charAt(e)===`h`){let t=i[e]/180*Wk;c+=Gk(t)*n[r+1],l+=Kk(t)*n[r+1]}else o[e]+=i[e]*n[r+1]}});for(let e=0;e<o.length;e++)if(t.charAt(e)===`h`){let t=qk(l/s[e],c/s[e])/Wk*180;for(;t<0;)t+=360;for(;t>=360;)t-=360;o[e]=t}else o[e]=o[e]/s[e];return u/=r,new Q(o,t).alpha(u>.99999?1:u,!0)},Yk=(e,t)=>{let n=e.length,r=[0,0,0,0];for(let i=0;i<e.length;i++){let a=e[i],o=t[i]/n,s=a._rgb;r[0]+=Hk(s[0],2)*o,r[1]+=Hk(s[1],2)*o,r[2]+=Hk(s[2],2)*o,r[3]+=s[3]*o}return r[0]=Uk(r[0]),r[1]=Uk(r[1]),r[2]=Uk(r[2]),r[3]>.9999999&&(r[3]=1),new Q(bO(r))},{pow:Xk}=Math;function Zk(e){let t=`rgb`,n=$(`#ccc`),r=0,i=[0,1],a=[0,1],o=[],s=[0,0],c=!1,l=[],u=!1,d=0,f=1,p=!1,m={},h=!0,g=1,_=function(e){if(e||=[`#fff`,`#000`],e&&Y(e)===`string`&&$.brewer&&$.brewer[e.toLowerCase()]&&(e=$.brewer[e.toLowerCase()]),Y(e)===`array`){e.length===1&&(e=[e[0],e[0]]),e=e.slice(0);for(let t=0;t<e.length;t++)e[t]=$(e[t]);o.length=0;for(let t=0;t<e.length;t++)o.push(t/(e.length-1))}return S(),l=e},v=function(e){if(c!=null){let t=c.length-1,n=0;for(;n<t&&e>=c[n];)n++;return n-1}return 0},y=e=>e,b=e=>e,x=function(e,r){let i,a;if(r??=!1,isNaN(e)||e===null)return n;a=r?e:c&&c.length>2?v(e)/(c.length-2):f===d?1:(e-d)/(f-d),a=b(a),r||(a=y(a)),g!==1&&(a=Xk(a,g)),a=s[0]+a*(1-s[0]-s[1]),a=yO(a,0,1);let u=Math.floor(a*1e4);if(h&&m[u])i=m[u];else{if(Y(l)===`array`)for(let e=0;e<o.length;e++){let n=o[e];if(a<=n){i=l[e];break}if(a>=n&&e===o.length-1){i=l[e];break}if(a>n&&a<o[e+1]){a=(a-n)/(o[e+1]-n),i=$.interpolate(l[e],l[e+1],a,t);break}}else Y(l)===`function`&&(i=l(a));h&&(m[u]=i)}return i};var S=()=>m={};_(e);let C=function(e){let t=$(x(e));return u&&t[u]?t[u]():t};return C.classes=function(e){if(e!=null){if(Y(e)===`array`)c=e,i=[e[0],e[e.length-1]];else{let t=$.analyze(i);c=e===0?[t.min,t.max]:$.limits(t,`e`,e)}return C}return c},C.domain=function(e){if(!arguments.length)return a;a=e.slice(0),d=e[0],f=e[e.length-1],o=[];let t=l.length;if(e.length===t&&d!==f)for(let t of Array.from(e))o.push((t-d)/(f-d));else{for(let e=0;e<t;e++)o.push(e/(t-1));if(e.length>2){let t=e.map((t,n)=>n/(e.length-1)),n=e.map(e=>(e-d)/(f-d));n.every((e,n)=>t[n]===e)||(b=e=>{if(e<=0||e>=1)return e;let r=0;for(;e>=n[r+1];)r++;let i=(e-n[r])/(n[r+1]-n[r]);return t[r]+i*(t[r+1]-t[r])})}}return i=[d,f],C},C.mode=function(e){return arguments.length?(t=e,S(),C):t},C.range=function(e,t){return _(e,t),C},C.out=function(e){return u=e,C},C.spread=function(e){return arguments.length?(r=e,C):r},C.correctLightness=function(e){return e??=!0,p=e,S(),y=p?function(e){let t=x(0,!0).lab()[0],n=x(1,!0).lab()[0],r=t>n,i=x(e,!0).lab()[0],a=t+(n-t)*e,o=i-a,s=0,c=1,l=20;for(;Math.abs(o)>.01&&l-->0;)(function(){return r&&(o*=-1),o<0?(s=e,e+=(c-e)*.5):(c=e,e+=(s-e)*.5),i=x(e,!0).lab()[0],o=i-a})();return e}:e=>e,C},C.padding=function(e){return e==null?s:(Y(e)===`number`&&(e=[e,e]),s=e,C)},C.colors=function(t,n){arguments.length<2&&(n=`hex`);let r=[];if(arguments.length===0)r=l.slice(0);else if(t===1)r=[C(.5)];else if(t>1){let e=i[0],n=i[1]-e;r=Qk(0,t,!1).map(r=>C(e+r/(t-1)*n))}else{e=[];let t=[];if(c&&c.length>2)for(let e=1,n=c.length,r=1<=n;r?e<n:e>n;r?e++:e--)t.push((c[e-1]+c[e])*.5);else t=i;r=t.map(e=>C(e))}return $[n]&&(r=r.map(e=>e[n]())),r},C.cache=function(e){return e==null?h:(h=e,C)},C.gamma=function(e){return e==null?g:(g=e,C)},C.nodata=function(e){return e==null?n:(n=$(e),C)},C}function Qk(e,t,n){let r=[],i=e<t,a=n?i?t+1:t-1:t;for(let t=e;i?t<a:t>a;i?t++:t--)r.push(t);return r}var $k=function(e){let t=[1,1];for(let n=1;n<e;n++){let e=[1];for(let n=1;n<=t.length;n++)e[n]=(t[n]||0)+t[n-1];t=e}return t},eA=function(e){let t,n,r,i;if(e=e.map(e=>new Q(e)),e.length===2)[n,r]=e.map(e=>e.lab()),t=function(e){return new Q([0,1,2].map(t=>n[t]+e*(r[t]-n[t])),`lab`)};else if(e.length===3)[n,r,i]=e.map(e=>e.lab()),t=function(e){return new Q([0,1,2].map(t=>(1-e)*(1-e)*n[t]+2*(1-e)*e*r[t]+e*e*i[t]),`lab`)};else if(e.length===4){let a;[n,r,i,a]=e.map(e=>e.lab()),t=function(e){return new Q([0,1,2].map(t=>(1-e)*(1-e)*(1-e)*n[t]+3*(1-e)*(1-e)*e*r[t]+3*(1-e)*e*e*i[t]+e*e*e*a[t]),`lab`)}}else if(e.length>=5){let n,r,i;n=e.map(e=>e.lab()),i=e.length-1,r=$k(i),t=function(e){let t=1-e;return new Q([0,1,2].map(a=>n.reduce((n,o,s)=>n+r[s]*t**(i-s)*e**s*o[a],0)),`lab`)}}else throw RangeError(`No point in running bezier with only one color.`);return t},tA=e=>{let t=eA(e);return t.scale=()=>Zk(t),t},{round:nA}=Math;Q.prototype.rgb=function(e=!0){return e===!1?this._rgb.slice(0,3):this._rgb.slice(0,3).map(nA)},Q.prototype.rgba=function(e=!0){return this._rgb.slice(0,4).map((t,n)=>n<3?e===!1?t:nA(t):t)},Object.assign($,{rgb:(...e)=>new Q(...e,`rgb`)}),Z.format.rgb=(...e)=>{let t=X(e,`rgba`);return t[3]===void 0&&(t[3]=1),t},Z.autodetect.push({p:3,test:(...e)=>{if(e=X(e,`rgba`),Y(e)===`array`&&(e.length===3||e.length===4&&Y(e[3])==`number`&&e[3]>=0&&e[3]<=1))return`rgb`}});var rA=(e,t,n)=>{if(!rA[n])throw Error(`unknown blend mode `+n);return rA[n](e,t)},iA=e=>(t,n)=>{let r=$(n).rgb(),i=$(t).rgb();return $.rgb(e(r,i))},aA=e=>(t,n)=>{let r=[];return r[0]=e(t[0],n[0]),r[1]=e(t[1],n[1]),r[2]=e(t[2],n[2]),r};rA.normal=iA(aA(e=>e)),rA.multiply=iA(aA((e,t)=>e*t/255)),rA.screen=iA(aA((e,t)=>255*(1-(1-e/255)*(1-t/255)))),rA.overlay=iA(aA((e,t)=>t<128?2*e*t/255:255*(1-2*(1-e/255)*(1-t/255)))),rA.darken=iA(aA((e,t)=>e>t?t:e)),rA.lighten=iA(aA((e,t)=>e>t?e:t)),rA.dodge=iA(aA((e,t)=>e===255?255:(e=t/255*255/(1-e/255),e>255?255:e))),rA.burn=iA(aA((e,t)=>255*(1-(1-t/255)/(e/255))));var{pow:oA,sin:sA,cos:cA}=Math;function lA(e=300,t=-1.5,n=1,r=1,i=[0,1]){let a=0,o;Y(i)===`array`?o=i[1]-i[0]:(o=0,i=[i,i]);let s=function(s){let c=OO*((e+120)/360+t*s),l=oA(i[0]+o*s,r),u=(a===0?n:n[0]+s*a)*l*(1-l)/2,d=cA(c),f=sA(c),p=l+u*(-.14861*d+1.78277*f),m=l+u*(-.29227*d-.90649*f),h=l+1.97294*d*u;return $(bO([p*255,m*255,h*255,1]))};return s.start=function(t){return t==null?e:(e=t,s)},s.rotations=function(e){return e==null?t:(t=e,s)},s.gamma=function(e){return e==null?r:(r=e,s)},s.hue=function(e){return e==null?n:(n=e,Y(n)===`array`?(a=n[1]-n[0],a===0&&(n=n[1])):a=0,s)},s.lightness=function(e){return e==null?i:(Y(e)===`array`?(i=e,o=e[1]-e[0]):(i=[e,e],o=0),s)},s.scale=()=>$.scale(s),s.hue(n),s}var uA=`0123456789abcdef`,{floor:dA,random:fA}=Math,pA=(e=fA)=>{let t=`#`;for(let n=0;n<6;n++)t+=uA.charAt(dA(e()*16));return new Q(t,`hex`)},{log:mA,pow:hA,floor:gA,abs:_A}=Math;function vA(e,t=null){let n={min:Number.MAX_VALUE,max:Number.MAX_VALUE*-1,sum:0,values:[],count:0};return Y(e)===`object`&&(e=Object.values(e)),e.forEach(e=>{t&&Y(e)===`object`&&(e=e[t]),e!=null&&!isNaN(e)&&(n.values.push(e),n.sum+=e,e<n.min&&(n.min=e),e>n.max&&(n.max=e),n.count+=1)}),n.domain=[n.min,n.max],n.limits=(e,t)=>yA(n,e,t),n}function yA(e,t=`equal`,n=7){Y(e)==`array`&&(e=vA(e));let{min:r,max:i}=e,a=e.values.sort((e,t)=>e-t);if(n===1)return[r,i];let o=[];if(t.substr(0,1)===`c`&&(o.push(r),o.push(i)),t.substr(0,1)===`e`){o.push(r);for(let e=1;e<n;e++)o.push(r+e/n*(i-r));o.push(i)}else if(t.substr(0,1)===`l`){if(r<=0)throw Error(`Logarithmic scales are only possible for values > 0`);let e=Math.LOG10E*mA(r),t=Math.LOG10E*mA(i);o.push(r);for(let r=1;r<n;r++)o.push(hA(10,e+r/n*(t-e)));o.push(i)}else if(t.substr(0,1)===`q`){o.push(r);for(let e=1;e<n;e++){let t=(a.length-1)*e/n,r=gA(t);if(r===t)o.push(a[r]);else{let e=t-r;o.push(a[r]*(1-e)+a[r+1]*e)}}o.push(i)}else if(t.substr(0,1)===`k`){let e,t=a.length,s=Array(t),c=Array(n),l=!0,u=0,d=null;d=[],d.push(r);for(let e=1;e<n;e++)d.push(r+e/n*(i-r));for(d.push(i);l;){for(let e=0;e<n;e++)c[e]=0;for(let e=0;e<t;e++){let t=a[e],r=Number.MAX_VALUE,i;for(let a=0;a<n;a++){let n=_A(d[a]-t);n<r&&(r=n,i=a),c[i]++,s[e]=i}}let r=Array(n);for(let e=0;e<n;e++)r[e]=null;for(let n=0;n<t;n++)e=s[n],r[e]===null?r[e]=a[n]:r[e]+=a[n];for(let e=0;e<n;e++)r[e]*=1/c[e];l=!1;for(let e=0;e<n;e++)if(r[e]!==d[e]){l=!0;break}d=r,u++,u>200&&(l=!1)}let f={};for(let e=0;e<n;e++)f[e]=[];for(let n=0;n<t;n++)e=s[n],f[e].push(a[n]);let p=[];for(let e=0;e<n;e++)p.push(f[e][0]),p.push(f[e][f[e].length-1]);p=p.sort((e,t)=>e-t),o.push(p[0]);for(let e=1;e<p.length;e+=2){let t=p[e];!isNaN(t)&&o.indexOf(t)===-1&&o.push(t)}}return o}var bA=(e,t)=>{e=new Q(e),t=new Q(t);let n=e.luminance(),r=t.luminance();return n>r?(n+.05)/(r+.05):(r+.05)/(n+.05)},xA=.027,SA=5e-4,CA=.1,wA=1.14,TA=.022,EA=1.414,DA=(e,t)=>{e=new Q(e),t=new Q(t),e.alpha()<1&&(e=ik(t,e,e.alpha(),`rgb`));let n=OA(...e.rgb()),r=OA(...t.rgb()),i=n>=TA?n:n+(TA-n)**+EA,a=r>=TA?r:r+(TA-r)**+EA,o=a**.56-i**.57,s=a**.65-i**.62,c=Math.abs(a-i)<SA?0:i<a?o*wA:s*wA;return(Math.abs(c)<CA?0:c>0?c-xA:c+xA)*100};function OA(e,t,n){return .2126729*(e/255)**2.4+.7151522*(t/255)**2.4+.072175*(n/255)**2.4}var{sqrt:kA,pow:AA,min:jA,max:MA,atan2:NA,abs:PA,cos:FA,sin:IA,exp:LA,PI:RA}=Math;function zA(e,t,n=1,r=1,i=1){var a=function(e){return 360*e/(2*RA)},o=function(e){return 2*RA*e/360};e=new Q(e),t=new Q(t);let[s,c,l]=Array.from(e.lab()),[u,d,f]=Array.from(t.lab()),p=(s+u)/2,m=(kA(AA(c,2)+AA(l,2))+kA(AA(d,2)+AA(f,2)))/2,h=.5*(1-kA(AA(m,7)/(AA(m,7)+AA(25,7)))),g=c*(1+h),_=d*(1+h),v=kA(AA(g,2)+AA(l,2)),y=kA(AA(_,2)+AA(f,2)),b=(v+y)/2,x=a(NA(l,g)),S=a(NA(f,_)),C=x>=0?x:x+360,w=S>=0?S:S+360,T=PA(C-w)>180?(C+w+360)/2:(C+w)/2,E=1-.17*FA(o(T-30))+.24*FA(o(2*T))+.32*FA(o(3*T+6))-.2*FA(o(4*T-63)),D=w-C;D=PA(D)<=180?D:w<=C?D+360:D-360,D=2*kA(v*y)*IA(o(D)/2);let O=u-s,ee=y-v,te=1+.015*AA(p-50,2)/kA(20+AA(p-50,2)),ne=1+.045*b,re=1+.015*b*E,k=30*LA(-AA((T-275)/25,2)),A=-(2*kA(AA(b,7)/(AA(b,7)+AA(25,7))))*IA(2*o(k));return MA(0,jA(100,kA(AA(O/(n*te),2)+AA(ee/(r*ne),2)+AA(D/(i*re),2)+A*(ee/(r*ne))*(D/(i*re)))))}function BA(e,t,n=`lab`){e=new Q(e),t=new Q(t);let r=e.get(n),i=t.get(n),a=0;for(let e in r){let t=(r[e]||0)-(i[e]||0);a+=t*t}return Math.sqrt(a)}var VA=(...e)=>{try{return new Q(...e),!0}catch{return!1}},HA={cool(){return Zk([$.hsl(180,1,.9),$.hsl(250,.7,.4)])},hot(){return Zk([`#000`,`#f00`,`#ff0`,`#fff`],[0,.25,.75,1]).mode(`rgb`)}},UA={OrRd:[`#fff7ec`,`#fee8c8`,`#fdd49e`,`#fdbb84`,`#fc8d59`,`#ef6548`,`#d7301f`,`#b30000`,`#7f0000`],PuBu:[`#fff7fb`,`#ece7f2`,`#d0d1e6`,`#a6bddb`,`#74a9cf`,`#3690c0`,`#0570b0`,`#045a8d`,`#023858`],BuPu:[`#f7fcfd`,`#e0ecf4`,`#bfd3e6`,`#9ebcda`,`#8c96c6`,`#8c6bb1`,`#88419d`,`#810f7c`,`#4d004b`],Oranges:[`#fff5eb`,`#fee6ce`,`#fdd0a2`,`#fdae6b`,`#fd8d3c`,`#f16913`,`#d94801`,`#a63603`,`#7f2704`],BuGn:[`#f7fcfd`,`#e5f5f9`,`#ccece6`,`#99d8c9`,`#66c2a4`,`#41ae76`,`#238b45`,`#006d2c`,`#00441b`],YlOrBr:[`#ffffe5`,`#fff7bc`,`#fee391`,`#fec44f`,`#fe9929`,`#ec7014`,`#cc4c02`,`#993404`,`#662506`],YlGn:[`#ffffe5`,`#f7fcb9`,`#d9f0a3`,`#addd8e`,`#78c679`,`#41ab5d`,`#238443`,`#006837`,`#004529`],Reds:[`#fff5f0`,`#fee0d2`,`#fcbba1`,`#fc9272`,`#fb6a4a`,`#ef3b2c`,`#cb181d`,`#a50f15`,`#67000d`],RdPu:[`#fff7f3`,`#fde0dd`,`#fcc5c0`,`#fa9fb5`,`#f768a1`,`#dd3497`,`#ae017e`,`#7a0177`,`#49006a`],Greens:[`#f7fcf5`,`#e5f5e0`,`#c7e9c0`,`#a1d99b`,`#74c476`,`#41ab5d`,`#238b45`,`#006d2c`,`#00441b`],YlGnBu:[`#ffffd9`,`#edf8b1`,`#c7e9b4`,`#7fcdbb`,`#41b6c4`,`#1d91c0`,`#225ea8`,`#253494`,`#081d58`],Purples:[`#fcfbfd`,`#efedf5`,`#dadaeb`,`#bcbddc`,`#9e9ac8`,`#807dba`,`#6a51a3`,`#54278f`,`#3f007d`],GnBu:[`#f7fcf0`,`#e0f3db`,`#ccebc5`,`#a8ddb5`,`#7bccc4`,`#4eb3d3`,`#2b8cbe`,`#0868ac`,`#084081`],Greys:[`#ffffff`,`#f0f0f0`,`#d9d9d9`,`#bdbdbd`,`#969696`,`#737373`,`#525252`,`#252525`,`#000000`],YlOrRd:[`#ffffcc`,`#ffeda0`,`#fed976`,`#feb24c`,`#fd8d3c`,`#fc4e2a`,`#e31a1c`,`#bd0026`,`#800026`],PuRd:[`#f7f4f9`,`#e7e1ef`,`#d4b9da`,`#c994c7`,`#df65b0`,`#e7298a`,`#ce1256`,`#980043`,`#67001f`],Blues:[`#f7fbff`,`#deebf7`,`#c6dbef`,`#9ecae1`,`#6baed6`,`#4292c6`,`#2171b5`,`#08519c`,`#08306b`],PuBuGn:[`#fff7fb`,`#ece2f0`,`#d0d1e6`,`#a6bddb`,`#67a9cf`,`#3690c0`,`#02818a`,`#016c59`,`#014636`],Viridis:[`#440154`,`#482777`,`#3f4a8a`,`#31678e`,`#26838f`,`#1f9d8a`,`#6cce5a`,`#b6de2b`,`#fee825`],Spectral:[`#9e0142`,`#d53e4f`,`#f46d43`,`#fdae61`,`#fee08b`,`#ffffbf`,`#e6f598`,`#abdda4`,`#66c2a5`,`#3288bd`,`#5e4fa2`],RdYlGn:[`#a50026`,`#d73027`,`#f46d43`,`#fdae61`,`#fee08b`,`#ffffbf`,`#d9ef8b`,`#a6d96a`,`#66bd63`,`#1a9850`,`#006837`],RdBu:[`#67001f`,`#b2182b`,`#d6604d`,`#f4a582`,`#fddbc7`,`#f7f7f7`,`#d1e5f0`,`#92c5de`,`#4393c3`,`#2166ac`,`#053061`],PiYG:[`#8e0152`,`#c51b7d`,`#de77ae`,`#f1b6da`,`#fde0ef`,`#f7f7f7`,`#e6f5d0`,`#b8e186`,`#7fbc41`,`#4d9221`,`#276419`],PRGn:[`#40004b`,`#762a83`,`#9970ab`,`#c2a5cf`,`#e7d4e8`,`#f7f7f7`,`#d9f0d3`,`#a6dba0`,`#5aae61`,`#1b7837`,`#00441b`],RdYlBu:[`#a50026`,`#d73027`,`#f46d43`,`#fdae61`,`#fee090`,`#ffffbf`,`#e0f3f8`,`#abd9e9`,`#74add1`,`#4575b4`,`#313695`],BrBG:[`#543005`,`#8c510a`,`#bf812d`,`#dfc27d`,`#f6e8c3`,`#f5f5f5`,`#c7eae5`,`#80cdc1`,`#35978f`,`#01665e`,`#003c30`],RdGy:[`#67001f`,`#b2182b`,`#d6604d`,`#f4a582`,`#fddbc7`,`#ffffff`,`#e0e0e0`,`#bababa`,`#878787`,`#4d4d4d`,`#1a1a1a`],PuOr:[`#7f3b08`,`#b35806`,`#e08214`,`#fdb863`,`#fee0b6`,`#f7f7f7`,`#d8daeb`,`#b2abd2`,`#8073ac`,`#542788`,`#2d004b`],Set2:[`#66c2a5`,`#fc8d62`,`#8da0cb`,`#e78ac3`,`#a6d854`,`#ffd92f`,`#e5c494`,`#b3b3b3`],Accent:[`#7fc97f`,`#beaed4`,`#fdc086`,`#ffff99`,`#386cb0`,`#f0027f`,`#bf5b17`,`#666666`],Set1:[`#e41a1c`,`#377eb8`,`#4daf4a`,`#984ea3`,`#ff7f00`,`#ffff33`,`#a65628`,`#f781bf`,`#999999`],Set3:[`#8dd3c7`,`#ffffb3`,`#bebada`,`#fb8072`,`#80b1d3`,`#fdb462`,`#b3de69`,`#fccde5`,`#d9d9d9`,`#bc80bd`,`#ccebc5`,`#ffed6f`],Dark2:[`#1b9e77`,`#d95f02`,`#7570b3`,`#e7298a`,`#66a61e`,`#e6ab02`,`#a6761d`,`#666666`],Paired:[`#a6cee3`,`#1f78b4`,`#b2df8a`,`#33a02c`,`#fb9a99`,`#e31a1c`,`#fdbf6f`,`#ff7f00`,`#cab2d6`,`#6a3d9a`,`#ffff99`,`#b15928`],Pastel2:[`#b3e2cd`,`#fdcdac`,`#cbd5e8`,`#f4cae4`,`#e6f5c9`,`#fff2ae`,`#f1e2cc`,`#cccccc`],Pastel1:[`#fbb4ae`,`#b3cde3`,`#ccebc5`,`#decbe4`,`#fed9a6`,`#ffffcc`,`#e5d8bd`,`#fddaec`,`#f2f2f2`]},WA=Object.keys(UA),GA=new Map(WA.map(e=>[e.toLowerCase(),e])),KA=typeof Proxy==`function`?new Proxy(UA,{get(e,t){let n=t.toLowerCase();if(GA.has(n))return e[GA.get(n)]},getOwnPropertyNames(){return Object.getOwnPropertyNames(WA)}}):UA,qA=(...e)=>{e=X(e,`cmyk`);let[t,n,r,i]=e,a=e.length>4?e[4]:1;return i===1?[0,0,0,a]:[t>=1?0:255*(1-t)*(1-i),n>=1?0:255*(1-n)*(1-i),r>=1?0:255*(1-r)*(1-i),a]},{max:JA}=Math,YA=(...e)=>{let[t,n,r]=X(e,`rgb`);t/=255,n/=255,r/=255;let i=1-JA(t,JA(n,r)),a=i<1?1/(1-i):0;return[(1-t-i)*a,(1-n-i)*a,(1-r-i)*a,i]};Q.prototype.cmyk=function(){return YA(this._rgb)},Object.assign($,{cmyk:(...e)=>new Q(...e,`cmyk`)}),Z.format.cmyk=qA,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`cmyk`),Y(e)===`array`&&e.length===4)return`cmyk`}});var XA=(...e)=>{let t=X(e,`hsla`),n=SO(e)||`lsa`;return t[0]=EO(t[0]||0)+`deg`,t[1]=EO(t[1]*100)+`%`,t[2]=EO(t[2]*100)+`%`,n===`hsla`||t.length>3&&t[3]<1?(t[3]=`/ `+(t.length>3?t[3]:1),n=`hsla`):t.length=3,`${n.substr(0,3)}(${t.join(` `)})`},ZA=(...e)=>{let t=X(e,`lab`),n=SO(e)||`lab`;return t[0]=EO(t[0])+`%`,t[1]=EO(t[1]),t[2]=EO(t[2]),n===`laba`||t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`lab(${t.join(` `)})`},QA=(...e)=>{let t=X(e,`lch`),n=SO(e)||`lab`;return t[0]=EO(t[0])+`%`,t[1]=EO(t[1]),t[2]=isNaN(t[2])?`none`:EO(t[2])+`deg`,n===`lcha`||t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`lch(${t.join(` `)})`},$A=(...e)=>{let t=X(e,`lab`);return t[0]=EO(t[0]*100)+`%`,t[1]=DO(t[1]),t[2]=DO(t[2]),t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`oklab(${t.join(` `)})`},ej=(...e)=>{let[t,n,r,...i]=X(e,`rgb`),[a,o,s]=Bk(t,n,r),[c,l,u]=pk(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]},tj=(...e)=>{let t=X(e,`lch`);return t[0]=EO(t[0]*100)+`%`,t[1]=DO(t[1]),t[2]=isNaN(t[2])?`none`:EO(t[2])+`deg`,t.length>3&&t[3]<1?t[3]=`/ `+(t.length>3?t[3]:1):t.length=3,`oklch(${t.join(` `)})`},{round:nj}=Math,rj=(...e)=>{let t=X(e,`rgba`),n=SO(e)||`rgb`;if(n.substr(0,3)===`hsl`)return XA(jk(t),n);if(n.substr(0,3)===`lab`){let e=UO();HO(`d50`);let r=ZA(JO(t),n);return HO(e),r}if(n.substr(0,3)===`lch`){let e=UO();HO(`d50`);let r=QA(mk(t),n);return HO(e),r}return n.substr(0,5)===`oklab`?$A(Bk(t)):n.substr(0,5)===`oklch`?tj(ej(t)):(t[0]=nj(t[0]),t[1]=nj(t[1]),t[2]=nj(t[2]),(n===`rgba`||t.length>3&&t[3]<1)&&(t[3]=`/ `+(t.length>3?t[3]:1),n=`rgba`),`${n.substr(0,3)}(${t.slice(0,n===`rgb`?3:4).join(` `)})`)},ij=(...e)=>{e=X(e,`lch`);let[t,n,r,...i]=e,[a,o,s]=sk(t,n,r),[c,l,u]=Rk(a,o,s);return[c,l,u,...i.length>0&&i[0]<1?[i[0]]:[]]},aj=`((?:-?\\d+)|(?:-?\\d+(?:\\.\\d+)?)%|none)`,oj=`((?:-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)%?)|none)`,sj=`((?:-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)%)|none)`,cj=`\\s*`,lj=`\\s+`,uj=`\\s*,\\s*`,dj=`((?:-?(?:\\d+(?:\\.\\d*)?|\\.\\d+)(?:deg)?)|none)`,fj=`\\s*(?:\\/\\s*((?:[01]|[01]?\\.\\d+)|\\d+(?:\\.\\d+)?%))?`,pj=RegExp(`^rgba?\\(`+cj+[aj,aj,aj].join(lj)+fj+`\\)$`),mj=RegExp(`^rgb\\(`+cj+[aj,aj,aj].join(uj)+cj+`\\)$`),hj=RegExp(`^rgba\\(`+cj+[aj,aj,aj,oj].join(uj)+cj+`\\)$`),gj=RegExp(`^hsla?\\(`+cj+[dj,sj,sj].join(lj)+fj+`\\)$`),_j=RegExp(`^hsl?\\(`+cj+[dj,sj,sj].join(uj)+cj+`\\)$`),vj=/^hsla\(\s*(-?\d+(?:\.\d+)?),\s*(-?\d+(?:\.\d+)?)%\s*,\s*(-?\d+(?:\.\d+)?)%\s*,\s*([01]|[01]?\.\d+)\)$/,yj=RegExp(`^lab\\(`+cj+[oj,oj,oj].join(lj)+fj+`\\)$`),bj=RegExp(`^lch\\(`+cj+[oj,oj,dj].join(lj)+fj+`\\)$`),xj=RegExp(`^oklab\\(`+cj+[oj,oj,oj].join(lj)+fj+`\\)$`),Sj=RegExp(`^oklch\\(`+cj+[oj,oj,dj].join(lj)+fj+`\\)$`),{round:Cj}=Math,wj=e=>e.map((e,t)=>t<=2?yO(Cj(e),0,255):e),Tj=(e,t=0,n=100,r=!1)=>(typeof e==`string`&&e.endsWith(`%`)&&(e=parseFloat(e.substring(0,e.length-1))/100,e=r?t+(e+1)*.5*(n-t):t+e*(n-t)),+e),Ej=(e,t)=>e===`none`?t:e,Dj=e=>{if(e=e.toLowerCase().trim(),e===`transparent`)return[0,0,0,0];let t;if(Z.format.named)try{return Z.format.named(e)}catch{}if((t=e.match(pj))||(t=e.match(mj))){let e=t.slice(1,4);for(let t=0;t<3;t++)e[t]=+Tj(Ej(e[t],0),0,255);e=wj(e);let n=t[4]===void 0?1:+Tj(t[4],0,1);return e[3]=n,e}if(t=e.match(hj)){let e=t.slice(1,5);for(let t=0;t<4;t++)e[t]=+Tj(e[t],0,255);return e}if((t=e.match(gj))||(t=e.match(_j))){let e=t.slice(1,4);e[0]=+Ej(e[0].replace(`deg`,``),0),e[1]=Tj(Ej(e[1],0),0,100)*.01,e[2]=Tj(Ej(e[2],0),0,100)*.01;let n=wj(Ak(e));return n[3]=t[4]===void 0?1:+Tj(t[4],0,1),n}if(t=e.match(vj)){let e=t.slice(1,4);e[1]*=.01,e[2]*=.01;let n=Ak(e);for(let e=0;e<3;e++)n[e]=Cj(n[e]);return n[3]=+t[4],n}if(t=e.match(yj)){let e=t.slice(1,4);e[0]=Tj(Ej(e[0],0),0,100),e[1]=Tj(Ej(e[1],0),-125,125,!0),e[2]=Tj(Ej(e[2],0),-125,125,!0);let n=UO();HO(`d50`);let r=wj(WO(e));return HO(n),r[3]=t[4]===void 0?1:+Tj(t[4],0,1),r}if(t=e.match(bj)){let e=t.slice(1,4);e[0]=Tj(e[0],0,100),e[1]=Tj(Ej(e[1],0),0,150,!1),e[2]=+Ej(e[2].replace(`deg`,``),0);let n=UO();HO(`d50`);let r=wj(ck(e));return HO(n),r[3]=t[4]===void 0?1:+Tj(t[4],0,1),r}if(t=e.match(xj)){let e=t.slice(1,4);e[0]=Tj(Ej(e[0],0),0,1),e[1]=Tj(Ej(e[1],0),-.4,.4,!0),e[2]=Tj(Ej(e[2],0),-.4,.4,!0);let n=wj(Rk(e));return n[3]=t[4]===void 0?1:+Tj(t[4],0,1),n}if(t=e.match(Sj)){let e=t.slice(1,4);e[0]=Tj(Ej(e[0],0),0,1),e[1]=Tj(Ej(e[1],0),0,.4,!1),e[2]=+Ej(e[2].replace(`deg`,``),0);let n=wj(ij(e));return n[3]=t[4]===void 0?1:+Tj(t[4],0,1),n}};Dj.test=e=>pj.test(e)||gj.test(e)||yj.test(e)||bj.test(e)||xj.test(e)||Sj.test(e)||mj.test(e)||hj.test(e)||_j.test(e)||vj.test(e)||e===`transparent`,Q.prototype.css=function(e){return rj(this._rgb,e)},$.css=(...e)=>new Q(...e,`css`),Z.format.css=Dj,Z.autodetect.push({p:5,test:(e,...t)=>{if(!t.length&&Y(e)===`string`&&Dj.test(e))return`css`}}),Z.format.gl=(...e)=>{let t=X(e,`rgba`);return t[0]*=255,t[1]*=255,t[2]*=255,t},$.gl=(...e)=>new Q(...e,`gl`),Q.prototype.gl=function(){let e=this._rgb;return[e[0]/255,e[1]/255,e[2]/255,e[3]]},Q.prototype.hex=function(e){return zO(this._rgb,e)},$.hex=(...e)=>new Q(...e,`hex`),Z.format.hex=LO,Z.autodetect.push({p:4,test:(e,...t)=>{if(!t.length&&Y(e)===`string`&&[3,4,5,6,7,8,9].indexOf(e.length)>=0)return`hex`}});var{log:Oj}=Math,kj=e=>{let t=e/100,n,r,i;return t<66?(n=255,r=t<6?0:-155.25485562709179-.44596950469579133*(r=t-2)+104.49216199393888*Oj(r),i=t<20?0:-254.76935184120902+.8274096064007395*(i=t-10)+115.67994401066147*Oj(i)):(n=351.97690566805693+.114206453784165*(n=t-55)-40.25366309332127*Oj(n),r=325.4494125711974+.07943456536662342*(r=t-50)-28.0852963507957*Oj(r),i=255),[n,r,i,1]},{round:Aj}=Math,jj=(...e)=>{let t=X(e,`rgb`),n=t[0],r=t[2],i=1e3,a=4e4,o;for(;a-i>.4;){o=(a+i)*.5;let e=kj(o);e[2]/e[0]>=r/n?a=o:i=o}return Aj(o)};Q.prototype.temp=Q.prototype.kelvin=Q.prototype.temperature=function(){return jj(this._rgb)};var Mj=(...e)=>new Q(...e,`temp`);Object.assign($,{temp:Mj,kelvin:Mj,temperature:Mj}),Z.format.temp=Z.format.kelvin=Z.format.temperature=kj,Q.prototype.oklch=function(){return ej(this._rgb)},Object.assign($,{oklch:(...e)=>new Q(...e,`oklch`)}),Z.format.oklch=ij,Z.autodetect.push({p:2,test:(...e)=>{if(e=X(e,`oklch`),Y(e)===`array`&&e.length===3)return`oklch`}}),Object.assign($,{analyze:vA,average:Jk,bezier:tA,blend:rA,brewer:KA,Color:Q,colors:PO,contrast:bA,contrastAPCA:DA,cubehelix:lA,deltaE:zA,distance:BA,input:Z,interpolate:ik,limits:yA,mix:ik,random:pA,scale:Zk,scales:HA,valid:VA});var Nj=()=>window.location.hostname.includes(`greenhouse`),Pj=()=>window.location.hostname.includes(`typo3`),Fj=e=>Pj()||Nj()||Ij(e),Ij=e=>!!e.ownerDocument.defaultView?.frameElement,Lj=e=>{let t=getComputedStyle(e),n=t.position===`absolute`,r=/(auto|scroll)/;if(t.position===`fixed`)return document.body;for(let i=e;i=i.parentElement;)if(t=getComputedStyle(i),!(n&&t.position===`static`)&&r.test(t.overflow+t.overflowY+t.overflowX))return i;return document.body},Rj=c((e=>{e.CASE_SENSITIVE_TAG_NAMES_MAP=`animateMotion.animateTransform.clipPath.feBlend.feColorMatrix.feComponentTransfer.feComposite.feConvolveMatrix.feDiffuseLighting.feDisplacementMap.feDropShadow.feFlood.feFuncA.feFuncB.feFuncG.feFuncR.feGaussianBlur.feImage.feMerge.feMergeNode.feMorphology.feOffset.fePointLight.feSpecularLighting.feSpotLight.feTile.feTurbulence.foreignObject.linearGradient.radialGradient.textPath`.split(`.`).reduce((e,t)=>(e[t.toLowerCase()]=t,e),{})}));function zj(e){return e.type===Bj.Tag||e.type===Bj.Script||e.type===Bj.Style}var Bj,Vj=s((()=>{(function(e){e.Root=`root`,e.Text=`text`,e.Directive=`directive`,e.Comment=`comment`,e.Script=`script`,e.Style=`style`,e.Tag=`tag`,e.CDATA=`cdata`,e.Doctype=`doctype`})(Bj||={}),Bj.Root,Bj.Text,Bj.Directive,Bj.Comment,Bj.Script,Bj.Style,Bj.Tag,Bj.CDATA,Bj.Doctype}));function Hj(e){return zj(e)}function Uj(e){return e.type===Bj.CDATA}function Wj(e){return e.type===Bj.Text}function Gj(e){return e.type===Bj.Comment}function Kj(e){return e.type===Bj.Directive}function qj(e){return e.type===Bj.Root}function Jj(e){return Object.hasOwn(e,`children`)}function Yj(e,t=!1){let n;if(Wj(e))n=new $j(e.data);else if(Gj(e))n=new eM(e.data);else if(Hj(e)){let r=t?Xj(e.children):[],i=new aM(e.name,{...e.attribs},r);for(let e of r)e.parent=i;e.namespace!=null&&(i.namespace=e.namespace),e[`x-attribsNamespace`]&&(i[`x-attribsNamespace`]={...e[`x-attribsNamespace`]}),e[`x-attribsPrefix`]&&(i[`x-attribsPrefix`]={...e[`x-attribsPrefix`]}),n=i}else if(Uj(e)){let r=t?Xj(e.children):[],i=new rM(r);for(let e of r)e.parent=i;n=i}else if(qj(e)){let r=t?Xj(e.children):[],i=new iM(r);for(let e of r)e.parent=i;e[`x-mode`]&&(i[`x-mode`]=e[`x-mode`]),n=i}else if(Kj(e)){let t=new tM(e.name,e.data);e[`x-name`]!=null&&(t[`x-name`]=e[`x-name`],t[`x-publicId`]=e[`x-publicId`],t[`x-systemId`]=e[`x-systemId`]),n=t}else throw Error(`Not implemented yet: ${e.type}`);return n.startIndex=e.startIndex,n.endIndex=e.endIndex,e.sourceCodeLocation!=null&&(n.sourceCodeLocation=e.sourceCodeLocation),n}function Xj(e){let t=e.map(e=>Yj(e,!0));for(let e=1;e<t.length;e++)t[e].prev=t[e-1],t[e-1].next=t[e];return t}var Zj,Qj,$j,eM,tM,nM,rM,iM,aM,oM=s((()=>{Vj(),Zj=class{parent=null;prev=null;next=null;startIndex=null;endIndex=null;get parentNode(){return this.parent}set parentNode(e){this.parent=e}get previousSibling(){return this.prev}set previousSibling(e){this.prev=e}get nextSibling(){return this.next}set nextSibling(e){this.next=e}cloneNode(e=!1){return Yj(this,e)}},Qj=class extends Zj{data;constructor(e){super(),this.data=e}get nodeValue(){return this.data}set nodeValue(e){this.data=e}},$j=class extends Qj{type=Bj.Text;get nodeType(){return 3}},eM=class extends Qj{type=Bj.Comment;get nodeType(){return 8}},tM=class extends Qj{type=Bj.Directive;name;constructor(e,t){super(t),this.name=e}get nodeType(){return 1}"x-name";"x-publicId";"x-systemId"},nM=class extends Zj{children;constructor(e){super(),this.children=e}get firstChild(){return this.children[0]??null}get lastChild(){return this.children.length>0?this.children[this.children.length-1]:null}get childNodes(){return this.children}set childNodes(e){this.children=e}},rM=class extends nM{type=Bj.CDATA;get nodeType(){return 4}},iM=class extends nM{type=Bj.Root;get nodeType(){return 9}},aM=class extends nM{name;attribs;type;constructor(e,t,n=[],r=e===`script`?Bj.Script:e===`style`?Bj.Style:Bj.Tag){super(n),this.name=e,this.attribs=t,this.type=r}get nodeType(){return 1}get tagName(){return this.name}set tagName(e){this.name=e}get attributes(){return Object.keys(this.attribs).map(e=>({name:e,value:this.attribs[e],namespace:this[`x-attribsNamespace`]?.[e],prefix:this[`x-attribsPrefix`]?.[e]}))}namespace;"x-attribsNamespace";"x-attribsPrefix"}})),sM=l({CDATA:()=>rM,Comment:()=>eM,DataNode:()=>Qj,Document:()=>iM,DomHandler:()=>lM,Element:()=>aM,Node:()=>Zj,NodeWithChildren:()=>nM,ProcessingInstruction:()=>tM,Text:()=>$j,cloneNode:()=>Yj,default:()=>lM,hasChildren:()=>Jj,isCDATA:()=>Uj,isComment:()=>Gj,isDirective:()=>Kj,isDocument:()=>qj,isTag:()=>Hj,isText:()=>Wj}),cM,lM,uM=s((()=>{Vj(),oM(),oM(),cM={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},lM=class{dom=[];root=new iM(this.dom);callback;options;elementCB;done=!1;tagStack=[this.root];lastNode=null;parser=null;constructor(e,t,n){typeof t==`function`&&(n=t,t=cM),typeof e==`object`&&(t=e,e=void 0),this.callback=e??null,this.options=t??cM,this.elementCB=n??null}onparserinit(e){this.parser=e}onreset(){this.dom=[],this.root=new iM(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null}onend(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))}onerror(e){this.handleCallback(e)}onclosetag(){this.lastNode=null;let e=this.tagStack.pop();this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)}onopentag(e,t){let n=this.options.xmlMode?Bj.Tag:void 0,r=new aM(e,t,void 0,n);this.addNode(r),this.tagStack.push(r)}ontext(e){let{lastNode:t}=this;if(t&&t.type===Bj.Text)t.data+=e,this.options.withEndIndices&&this.parser&&(t.endIndex=this.parser.endIndex);else{let t=new $j(e);this.addNode(t),this.lastNode=t}}oncomment(e){if(this.lastNode&&this.lastNode.type===Bj.Comment){this.lastNode.data+=e;return}let t=new eM(e);this.addNode(t),this.lastNode=t}oncommentend(){this.lastNode=null}oncdatastart(){let e=new $j(``),t=new rM([e]);this.addNode(t),e.parent=t,this.lastNode=e}oncdataend(){this.lastNode=null}onprocessinginstruction(e,t){let n=new tM(e,t);this.addNode(n)}handleCallback(e){if(typeof this.callback==`function`)this.callback(e,this.dom);else if(e)throw e}addNode(e){let t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&this.parser&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null}}})),dM=c((e=>{var t=Rj(),n=(uM(),f(sM)),r=`\r`,i=new RegExp(r,`g`),a=`__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_${Date.now().toString()}__`,o=new RegExp(a,`g`);function s(e){return t.CASE_SENSITIVE_TAG_NAMES_MAP[e]}function c(e){let t={},n=0,r=e.length;for(;n<r;n++){let r=e[n];t[r.name]=r.value}return t}function l(e){return e=e.toLowerCase(),s(e)||e}function u(e,t){let n=`<`+t,r=e.toLowerCase().indexOf(n);if(r===-1)return!1;let i=e[r+n.length];return i===`>`||i===` `||i===` `||i===`
146
+ `||i===`\r`||i===`/`}function d(e){return e.replace(i,a)}function p(e){return e.replace(o,r)}function m(e,t=null,r){let i=[],a,o=0,s=e.length;for(;o<s;o++){let r=e[o];switch(r.nodeType){case 1:{let e=l(r.nodeName);a=new n.Element(e,c(r.attributes)),a.children=m(e===`template`?r.content.childNodes:r.childNodes,a);break}case 3:a=new n.Text(p(r.nodeValue??``));break;case 8:a=new n.Comment(r.nodeValue??``);break;default:continue}let s=i[o-1]??null;s&&(s.next=a),a.parent=t,a.prev=s,a.next=null,i.push(a)}return r&&(a=new n.ProcessingInstruction(r.substring(0,r.indexOf(` `)).toLowerCase(),r),a.next=i[0]??null,a.parent=t,i.unshift(a),i[1]&&(i[1].prev=i[0])),i}e.escapeSpecialCharacters=d,e.formatDOM=m,e.hasOpenTag=u})),fM=c((e=>{var t=dM(),n=`html`,r=`head`,i=`body`,a=/<([a-zA-Z]+[0-9]?)/;function o(e,t){return t?t.createHTML(e):e}var s=(e,t,n)=>{throw Error("This browser does not support `document.implementation.createHTMLDocument`")},c=(e,t,n)=>{throw Error("This browser does not support `DOMParser.prototype.parseFromString`")},l=typeof window==`object`&&window.DOMParser;if(typeof l==`function`){let e=new l;c=(t,n,r)=>(n&&(t=`<${n}>${t}</${n}>`),e.parseFromString(t,`text/html`)),s=c}if(typeof document==`object`&&document.implementation){let e=document.implementation.createHTMLDocument();s=function(t,n,r){if(n){let i=e.documentElement.querySelector(n);return i&&(i.innerHTML=o(t,r)),e}return e.documentElement.innerHTML=o(t,r),e}}var u=typeof document==`object`&&document.createElement(`template`),d;u&&u.content&&(d=(e,t)=>(u.innerHTML=o(e,t),u.content.childNodes));var f=()=>document.createDocumentFragment().childNodes;function p(e,o){e=t.escapeSpecialCharacters(e);let l=a.exec(e)?.[1]?.toLowerCase();switch(l){case n:{let a=c(e);if(!t.hasOpenTag(e,r)){let e=a.querySelector(r);e?.parentNode?.removeChild(e)}if(!t.hasOpenTag(e,i)){let e=a.querySelector(i);e?.parentNode?.removeChild(e)}return a.querySelectorAll(n)}case r:case i:{let n=s(e,void 0,o).querySelectorAll(l);return t.hasOpenTag(e,i)&&t.hasOpenTag(e,r)?n[0].parentNode?.childNodes??f():n}default:return d?d(e,o):s(e,i,o).querySelector(i)?.childNodes??f()}}e.default=p})),pM=c((e=>{Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:`Module`}});var t=dM(),n=fM(),r=/<(![a-zA-Z\s]+)>/;function i(e,i){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];let a=r.exec(e),o=a?a[1]:void 0;return t.formatDOM(n.default(e,i?.trustedTypePolicy),null,o)}e.default=i})),mM=c((e=>{e.SAME=0,e.CAMELCASE=1,e.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":`acceptCharset`,accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:`className`,classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:`htmlFor`,form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":`httpEquiv`,icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":`accentHeight`,accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":`alignmentBaseline`,allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":`arabicForm`,ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":`baselineShift`,baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":`capHeight`,clip:0,clipPath:1,"clip-path":`clipPath`,clipPathUnits:1,clipRule:1,"clip-rule":`clipRule`,color:0,colorInterpolation:1,"color-interpolation":`colorInterpolation`,colorInterpolationFilters:1,"color-interpolation-filters":`colorInterpolationFilters`,colorProfile:1,"color-profile":`colorProfile`,colorRendering:1,"color-rendering":`colorRendering`,contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":`dominantBaseline`,dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":`enableBackground`,end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":`fillOpacity`,fillRule:1,"fill-rule":`fillRule`,filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":`floodOpacity`,floodColor:1,"flood-color":`floodColor`,focusable:0,fontFamily:1,"font-family":`fontFamily`,fontSize:1,"font-size":`fontSize`,fontSizeAdjust:1,"font-size-adjust":`fontSizeAdjust`,fontStretch:1,"font-stretch":`fontStretch`,fontStyle:1,"font-style":`fontStyle`,fontVariant:1,"font-variant":`fontVariant`,fontWeight:1,"font-weight":`fontWeight`,format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":`glyphName`,glyphOrientationHorizontal:1,"glyph-orientation-horizontal":`glyphOrientationHorizontal`,glyphOrientationVertical:1,"glyph-orientation-vertical":`glyphOrientationVertical`,glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":`horizAdvX`,horizOriginX:1,"horiz-origin-x":`horizOriginX`,ideographic:0,imageRendering:1,"image-rendering":`imageRendering`,in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":`letterSpacing`,lightingColor:1,"lighting-color":`lightingColor`,limitingConeAngle:1,local:0,markerEnd:1,"marker-end":`markerEnd`,markerHeight:1,markerMid:1,"marker-mid":`markerMid`,markerStart:1,"marker-start":`markerStart`,markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":`overlinePosition`,overlineThickness:1,"overline-thickness":`overlineThickness`,paintOrder:1,"paint-order":`paintOrder`,panose1:0,"panose-1":`panose1`,pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":`pointerEvents`,points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":`renderingIntent`,repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":`shapeRendering`,slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":`stopColor`,stopOpacity:1,"stop-opacity":`stopOpacity`,strikethroughPosition:1,"strikethrough-position":`strikethroughPosition`,strikethroughThickness:1,"strikethrough-thickness":`strikethroughThickness`,string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":`strokeDasharray`,strokeDashoffset:1,"stroke-dashoffset":`strokeDashoffset`,strokeLinecap:1,"stroke-linecap":`strokeLinecap`,strokeLinejoin:1,"stroke-linejoin":`strokeLinejoin`,strokeMiterlimit:1,"stroke-miterlimit":`strokeMiterlimit`,strokeWidth:1,"stroke-width":`strokeWidth`,strokeOpacity:1,"stroke-opacity":`strokeOpacity`,suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":`textAnchor`,textDecoration:1,"text-decoration":`textDecoration`,textLength:1,textRendering:1,"text-rendering":`textRendering`,to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":`underlinePosition`,underlineThickness:1,"underline-thickness":`underlineThickness`,unicode:0,unicodeBidi:1,"unicode-bidi":`unicodeBidi`,unicodeRange:1,"unicode-range":`unicodeRange`,unitsPerEm:1,"units-per-em":`unitsPerEm`,unselectable:0,vAlphabetic:1,"v-alphabetic":`vAlphabetic`,values:0,vectorEffect:1,"vector-effect":`vectorEffect`,version:0,vertAdvY:1,"vert-adv-y":`vertAdvY`,vertOriginX:1,"vert-origin-x":`vertOriginX`,vertOriginY:1,"vert-origin-y":`vertOriginY`,vHanging:1,"v-hanging":`vHanging`,vIdeographic:1,"v-ideographic":`vIdeographic`,viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":`vMathematical`,vocab:0,widths:0,wordSpacing:1,"word-spacing":`wordSpacing`,writingMode:1,"writing-mode":`writingMode`,x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":`xHeight`,xlinkActuate:1,"xlink:actuate":`xlinkActuate`,xlinkArcrole:1,"xlink:arcrole":`xlinkArcrole`,xlinkHref:1,"xlink:href":`xlinkHref`,xlinkRole:1,"xlink:role":`xlinkRole`,xlinkShow:1,"xlink:show":`xlinkShow`,xlinkTitle:1,"xlink:title":`xlinkTitle`,xlinkType:1,"xlink:type":`xlinkType`,xmlBase:1,"xml:base":`xmlBase`,xmlLang:1,"xml:lang":`xmlLang`,xmlns:0,"xml:space":`xmlSpace`,xmlnsXlink:1,"xmlns:xlink":`xmlnsXlink`,xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1}})),hM=c((e=>{var t=0,n=1,r=2,i=3,a=4,o=5,s=6;function c(e){return u.hasOwnProperty(e)?u[e]:null}function l(e,t,n,o,s,c,l){this.acceptsBooleans=t===r||t===i||t===a,this.attributeName=o,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=c,this.removeEmptyString=l}var u={};[`children`,`dangerouslySetInnerHTML`,`defaultValue`,`defaultChecked`,`innerHTML`,`suppressContentEditableWarning`,`suppressHydrationWarning`,`style`].forEach(e=>{u[e]=new l(e,t,!1,e,null,!1,!1)}),[[`acceptCharset`,`accept-charset`],[`className`,`class`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`]].forEach(([e,t])=>{u[e]=new l(e,n,!1,t,null,!1,!1)}),[`contentEditable`,`draggable`,`spellCheck`,`value`].forEach(e=>{u[e]=new l(e,r,!1,e.toLowerCase(),null,!1,!1)}),[`autoReverse`,`externalResourcesRequired`,`focusable`,`preserveAlpha`].forEach(e=>{u[e]=new l(e,r,!1,e,null,!1,!1)}),[`allowFullScreen`,`async`,`autoFocus`,`autoPlay`,`controls`,`default`,`defer`,`disabled`,`disablePictureInPicture`,`disableRemotePlayback`,`formNoValidate`,`hidden`,`loop`,`noModule`,`noValidate`,`open`,`playsInline`,`readOnly`,`required`,`reversed`,`scoped`,`seamless`,`itemScope`].forEach(e=>{u[e]=new l(e,i,!1,e.toLowerCase(),null,!1,!1)}),[`checked`,`multiple`,`muted`,`selected`].forEach(e=>{u[e]=new l(e,i,!0,e,null,!1,!1)}),[`capture`,`download`].forEach(e=>{u[e]=new l(e,a,!1,e,null,!1,!1)}),[`cols`,`rows`,`size`,`span`].forEach(e=>{u[e]=new l(e,s,!1,e,null,!1,!1)}),[`rowSpan`,`start`].forEach(e=>{u[e]=new l(e,o,!1,e.toLowerCase(),null,!1,!1)});var d=/[\-\:]([a-z])/g,f=e=>e[1].toUpperCase();`accent-height.alignment-baseline.arabic-form.baseline-shift.cap-height.clip-path.clip-rule.color-interpolation.color-interpolation-filters.color-profile.color-rendering.dominant-baseline.enable-background.fill-opacity.fill-rule.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.glyph-name.glyph-orientation-horizontal.glyph-orientation-vertical.horiz-adv-x.horiz-origin-x.image-rendering.letter-spacing.lighting-color.marker-end.marker-mid.marker-start.overline-position.overline-thickness.paint-order.panose-1.pointer-events.rendering-intent.shape-rendering.stop-color.stop-opacity.strikethrough-position.strikethrough-thickness.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke-width.text-anchor.text-decoration.text-rendering.underline-position.underline-thickness.unicode-bidi.unicode-range.units-per-em.v-alphabetic.v-hanging.v-ideographic.v-mathematical.vector-effect.vert-adv-y.vert-origin-x.vert-origin-y.word-spacing.writing-mode.xmlns:xlink.x-height`.split(`.`).forEach(e=>{let t=e.replace(d,f);u[t]=new l(t,n,!1,e,null,!1,!1)}),[`xlink:actuate`,`xlink:arcrole`,`xlink:role`,`xlink:show`,`xlink:title`,`xlink:type`].forEach(e=>{let t=e.replace(d,f);u[t]=new l(t,n,!1,e,`http://www.w3.org/1999/xlink`,!1,!1)}),[`xml:base`,`xml:lang`,`xml:space`].forEach(e=>{let t=e.replace(d,f);u[t]=new l(t,n,!1,e,`http://www.w3.org/XML/1998/namespace`,!1,!1)}),[`tabIndex`,`crossOrigin`].forEach(e=>{u[e]=new l(e,n,!1,e.toLowerCase(),null,!1,!1)});var p=`xlinkHref`;u[p]=new l(`xlinkHref`,n,!1,`xlink:href`,`http://www.w3.org/1999/xlink`,!0,!1),[`src`,`href`,`action`,`formAction`].forEach(e=>{u[e]=new l(e,n,!1,e.toLowerCase(),null,!0,!0)});var{CAMELCASE:m,SAME:h,possibleStandardNames:g}=mM(),_=RegExp.prototype.test.bind(RegExp(`^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`)),v=Object.keys(g).reduce((e,t)=>{let n=g[t];return n===h?e[t]=t:n===m?e[t.toLowerCase()]=t:e[t]=n,e},{});e.BOOLEAN=i,e.BOOLEANISH_STRING=r,e.NUMERIC=o,e.OVERLOADED_BOOLEAN=a,e.POSITIVE_NUMERIC=s,e.RESERVED=t,e.STRING=n,e.getPropertyInfo=c,e.isCustomAttribute=_,e.possibleStandardNames=v})),gM=c(((e,t)=>{var n=/\/\*(?:[^*]|\*(?!\/))*\*\//g,r=/\n/g,i=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\.|[^'\\])*'|"(?:\\.|[^"\\])*"|url\((?:'(?:\\.|[^'\\])*'|"(?:\\.|[^"\\])*"|[^)]*)\)|[^};])+)/,c=/^[;\s]*/;function l(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,u=1;function d(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(`
147
+ `);u=~n?e.length-n:u+e.length}function f(){var e={line:l,column:u};return function(t){return t.position=new p(e),g(),t}}function p(e){this.start=e,this.end={line:l,column:u},this.source=t.source}p.prototype.content=e;function m(n){var r=Error(t.source+`:`+l+`:`+u+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=u,r.source=e,!t.silent)throw r}function h(t){var n=t.exec(e);if(n){var r=n[0];return d(r),e=e.slice(r.length),n}}function g(){h(i)}function _(e){for(var t;t=v();)e.push(t);return e}function v(){var t=f();if(e.charAt(0)==`/`&&e.charAt(1)==`*`){for(var n=2;e.charAt(n)!=``&&(e.charAt(n)!=`*`||e.charAt(n+1)!=`/`);)++n;if(n+=2,e.charAt(n-1)===``)return m(`End of comment missing`);var r=e.slice(2,n-2);return u+=2,d(r),e=e.slice(n),u+=2,t({type:`comment`,comment:r})}}function y(){var e=f(),t=h(a);if(t){if(v(),!h(o))return m(`property missing ':'`);var r=h(s),i=e({type:`declaration`,property:t[0].replace(n,``).trim(),value:r?r[0].replace(n,``).trim():``});return h(c),i}}function b(){var e=[];_(e);for(var t;t=y();)e.push(t),_(e);return e}return g(),b()}t.exports=l})),_M=c(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,c=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=a(t),l=0,u=c.length,d;l<u;l++)d=c[l],!s.call(e,d)&&d!==n&&r(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(o=i(t,d))||o.enumerable});return e},l=(e,t,i)=>(i=e==null?{}:n(o(e)),c(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),u=gM();u=l(u);function d(e,t){let n=null;if(!e||typeof e!=`string`)return n;let r=(0,u.default)(e),i=typeof t==`function`;return r.forEach(e=>{if(e.type!==`declaration`)return;let{property:r,value:a}=e;i?t(r,a,e):a&&(n??={},n[r]=a)}),n}t.exports=d})),vM=c(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,c=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var c=a(t),l=0,u=c.length,d;l<u;l++)d=c[l],!s.call(e,d)&&d!==n&&r(e,d,{get:(e=>t[e]).bind(null,d),enumerable:!(o=i(t,d))||o.enumerable});return e},l=(e,t,i)=>(i=e==null?{}:n(o(e)),c(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),u=_M();u=l(u);var d=/^--[a-zA-Z0-9_-]+$/,f=/-([a-z])/g,p=/^[^-]+$/,m=/^-(webkit|moz|ms|o|khtml)-/,h=/^-(ms)-/,g=e=>!e||p.test(e)||d.test(e),_=(e,t)=>t.toUpperCase(),v=(e,t)=>`${t}-`,y=(e,t={})=>g(e)?e:(e=e.toLowerCase(),e=t.reactCompat?e.replace(h,v):e.replace(m,v),e.replace(f,_));function b(e,t){let n={};return!e||typeof e!=`string`||(0,u.default)(e,(e,r)=>{e&&r&&(n[y(e,t)]=r)}),n}t.exports=b})),yM=c((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.returnFirstArg=e.canTextBeChildOfNode=e.ELEMENTS_WITH_NO_TEXT_CHILDREN=e.PRESERVE_CUSTOM_ATTRIBUTES=void 0,e.isCustomComponent=a,e.setStyleProp=s;var n=ry(),r=t(vM()),i=new Set([`annotation-xml`,`color-profile`,`font-face`,`font-face-src`,`font-face-uri`,`font-face-format`,`font-face-name`,`missing-glyph`]);function a(e,t){return e.includes(`-`)?!i.has(e):!!(t&&typeof t.is==`string`)}var o={reactCompat:!0};function s(e,t){if(typeof e==`string`){if(!e.trim()){t.style={};return}try{t.style=(0,r.default)(e,o)}catch{t.style={}}}}e.PRESERVE_CUSTOM_ATTRIBUTES=Number(n.version.split(`.`)[0])>=16,e.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set([`tr`,`tbody`,`thead`,`tfoot`,`colgroup`,`table`,`head`,`html`,`frameset`]),e.canTextBeChildOfNode=t=>!e.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(t.name),e.returnFirstArg=e=>e})),bM=c((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var t=hM(),n=yM(),r=[`checked`,`value`],i=[`input`,`select`,`textarea`],a={reset:!0,submit:!0};function o(e={},o){let c={},l=!!(e.type&&a[e.type]);for(let a in e){let u=e[a];if((0,t.isCustomAttribute)(a)){c[a]=u;continue}let d=a.toLowerCase(),f=s(d);if(f){let e=(0,t.getPropertyInfo)(f);switch(r.includes(f)&&i.includes(o)&&!l&&(f=s(`default`+d)),c[f]=u,e?.type){case t.BOOLEAN:c[f]=!0;break;case t.OVERLOADED_BOOLEAN:u===``&&(c[f]=!0)}continue}n.PRESERVE_CUSTOM_ATTRIBUTES&&(c[a]=u)}return(0,n.setStyleProp)(e.style,c),c}function s(e){return t.possibleStandardNames[e]}}));function xM(e){return e.type===SM.Tag||e.type===SM.Script||e.type===SM.Style}var SM,CM=s((()=>{(function(e){e.Root=`root`,e.Text=`text`,e.Directive=`directive`,e.Comment=`comment`,e.Script=`script`,e.Style=`style`,e.Tag=`tag`,e.CDATA=`cdata`,e.Doctype=`doctype`})(SM||={}),SM.Root,SM.Text,SM.Directive,SM.Comment,SM.Script,SM.Style,SM.Tag,SM.CDATA,SM.Doctype}));function wM(e){return xM(e)}function TM(e){return e.type===SM.CDATA}function EM(e){return e.type===SM.Text}function DM(e){return e.type===SM.Comment}function OM(e){return e.type===SM.Directive}function kM(e){return e.type===SM.Root}function AM(e){return Object.hasOwn(e,`children`)}function jM(e,t=!1){let n;if(EM(e))n=new FM(e.data);else if(DM(e))n=new IM(e.data);else if(wM(e)){let r=t?MM(e.children):[],i=new VM(e.name,{...e.attribs},r);for(let e of r)e.parent=i;e.namespace!=null&&(i.namespace=e.namespace),e[`x-attribsNamespace`]&&(i[`x-attribsNamespace`]={...e[`x-attribsNamespace`]}),e[`x-attribsPrefix`]&&(i[`x-attribsPrefix`]={...e[`x-attribsPrefix`]}),n=i}else if(TM(e)){let r=t?MM(e.children):[],i=new zM(r);for(let e of r)e.parent=i;n=i}else if(kM(e)){let r=t?MM(e.children):[],i=new BM(r);for(let e of r)e.parent=i;e[`x-mode`]&&(i[`x-mode`]=e[`x-mode`]),n=i}else if(OM(e)){let t=new LM(e.name,e.data);e[`x-name`]!=null&&(t[`x-name`]=e[`x-name`],t[`x-publicId`]=e[`x-publicId`],t[`x-systemId`]=e[`x-systemId`]),n=t}else throw Error(`Not implemented yet: ${e.type}`);return n.startIndex=e.startIndex,n.endIndex=e.endIndex,e.sourceCodeLocation!=null&&(n.sourceCodeLocation=e.sourceCodeLocation),n}function MM(e){let t=e.map(e=>jM(e,!0));for(let e=1;e<t.length;e++)t[e].prev=t[e-1],t[e-1].next=t[e];return t}var NM,PM,FM,IM,LM,RM,zM,BM,VM,HM=s((()=>{CM(),NM=class{parent=null;prev=null;next=null;startIndex=null;endIndex=null;get parentNode(){return this.parent}set parentNode(e){this.parent=e}get previousSibling(){return this.prev}set previousSibling(e){this.prev=e}get nextSibling(){return this.next}set nextSibling(e){this.next=e}cloneNode(e=!1){return jM(this,e)}},PM=class extends NM{data;constructor(e){super(),this.data=e}get nodeValue(){return this.data}set nodeValue(e){this.data=e}},FM=class extends PM{type=SM.Text;get nodeType(){return 3}},IM=class extends PM{type=SM.Comment;get nodeType(){return 8}},LM=class extends PM{type=SM.Directive;name;constructor(e,t){super(t),this.name=e}get nodeType(){return 1}"x-name";"x-publicId";"x-systemId"},RM=class extends NM{children;constructor(e){super(),this.children=e}get firstChild(){return this.children[0]??null}get lastChild(){return this.children.length>0?this.children[this.children.length-1]:null}get childNodes(){return this.children}set childNodes(e){this.children=e}},zM=class extends RM{type=SM.CDATA;get nodeType(){return 4}},BM=class extends RM{type=SM.Root;get nodeType(){return 9}},VM=class extends RM{name;attribs;type;constructor(e,t,n=[],r=e===`script`?SM.Script:e===`style`?SM.Style:SM.Tag){super(n),this.name=e,this.attribs=t,this.type=r}get nodeType(){return 1}get tagName(){return this.name}set tagName(e){this.name=e}get attributes(){return Object.keys(this.attribs).map(e=>({name:e,value:this.attribs[e],namespace:this[`x-attribsNamespace`]?.[e],prefix:this[`x-attribsPrefix`]?.[e]}))}namespace;"x-attribsNamespace";"x-attribsPrefix"}})),UM=l({CDATA:()=>zM,Comment:()=>IM,DataNode:()=>PM,Document:()=>BM,DomHandler:()=>GM,Element:()=>VM,Node:()=>NM,NodeWithChildren:()=>RM,ProcessingInstruction:()=>LM,Text:()=>FM,cloneNode:()=>jM,default:()=>GM,hasChildren:()=>AM,isCDATA:()=>TM,isComment:()=>DM,isDirective:()=>OM,isDocument:()=>kM,isTag:()=>wM,isText:()=>EM}),WM,GM,KM=s((()=>{CM(),HM(),HM(),WM={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},GM=class{dom=[];root=new BM(this.dom);callback;options;elementCB;done=!1;tagStack=[this.root];lastNode=null;parser=null;constructor(e,t,n){typeof t==`function`&&(n=t,t=WM),typeof e==`object`&&(t=e,e=void 0),this.callback=e??null,this.options=t??WM,this.elementCB=n??null}onparserinit(e){this.parser=e}onreset(){this.dom=[],this.root=new BM(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null}onend(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))}onerror(e){this.handleCallback(e)}onclosetag(){this.lastNode=null;let e=this.tagStack.pop();this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)}onopentag(e,t){let n=this.options.xmlMode?SM.Tag:void 0,r=new VM(e,t,void 0,n);this.addNode(r),this.tagStack.push(r)}ontext(e){let{lastNode:t}=this;if(t&&t.type===SM.Text)t.data+=e,this.options.withEndIndices&&this.parser&&(t.endIndex=this.parser.endIndex);else{let t=new FM(e);this.addNode(t),this.lastNode=t}}oncomment(e){if(this.lastNode&&this.lastNode.type===SM.Comment){this.lastNode.data+=e;return}let t=new IM(e);this.addNode(t),this.lastNode=t}oncommentend(){this.lastNode=null}oncdatastart(){let e=new FM(``),t=new zM([e]);this.addNode(t),e.parent=t,this.lastNode=e}oncdataend(){this.lastNode=null}onprocessinginstruction(e,t){let n=new LM(e,t);this.addNode(n)}handleCallback(e){if(typeof this.callback==`function`)this.callback(e,this.dom);else if(e)throw e}addNode(e){let t=this.tagStack[this.tagStack.length-1],n=t.children[t.children.length-1];this.options.withStartIndices&&this.parser&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&this.parser&&(e.endIndex=this.parser.endIndex),t.children.push(e),n&&(e.prev=n,n.next=e),e.parent=t,this.lastNode=null}}})),qM=c((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=(KM(),f(UM)),r=ry(),i=t(bM()),a=yM(),o={cloneElement:r.cloneElement,createElement:r.createElement,isValidElement:r.isValidElement};function s(e,t={}){let n=[],r=typeof t.replace==`function`,u=t.transform??a.returnFirstArg,{cloneElement:d,createElement:f,isValidElement:p}=t.library??o,m=e.length;c(e);for(let o=0;o<m;o++){let c=e[o];if(r){let e=t.replace?.call(t,c,o);if(p(e)){m>1&&(e=d(e,{key:e.key??o})),n.push(u(e,c,o));continue}}if(c.type===`text`){let e=!c.data.trim().length;if(e&&c.parent&&!(0,a.canTextBeChildOfNode)(c.parent)||t.trim&&e)continue;n.push(u(c.data,c,o));continue}let h=c,g={};l(h)?((0,a.setStyleProp)(h.attribs.style,h.attribs),g=h.attribs):h.attribs&&(g=(0,i.default)(h.attribs,h.name));let _;switch(c.type){case`script`:case`style`:c.children[0]&&(g.dangerouslySetInnerHTML={__html:c.children[0].data});break;case`tag`:c.name===`textarea`&&c.children[0]?g.defaultValue=c.children[0].data:c.children?.length&&(_=s(c.children,t));break;default:continue}m>1&&(g.key=o),n.push(u(f(c.name,g,_),c,o))}return n.length===1?n[0]:n}function c(e){for(let t of e)(t.type===`tag`||t.type===`script`||t.type===`style`)&&(Object.setPrototypeOf(t,n.Element.prototype),c(t.children))}function l(e){return a.PRESERVE_CUSTOM_ATTRIBUTES&&e.type===`tag`&&(0,a.isCustomComponent)(e.name,e.attribs)}})),JM=d(c((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.htmlToDOM=e.domToReact=e.attributesToProps=e.Text=e.ProcessingInstruction=e.Element=e.Comment=void 0,e.default=o;var n=t(pM());e.htmlToDOM=n.default,e.attributesToProps=t(bM()).default;var r=t(qM());e.domToReact=r.default;var i=(KM(),f(UM));Object.defineProperty(e,"Comment",{enumerable:!0,get:function(){return i.Comment}}),Object.defineProperty(e,"Element",{enumerable:!0,get:function(){return i.Element}}),Object.defineProperty(e,"ProcessingInstruction",{enumerable:!0,get:function(){return i.ProcessingInstruction}}),Object.defineProperty(e,"Text",{enumerable:!0,get:function(){return i.Text}});var a={lowerCaseAttributeNames:!1};function o(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];let i=Object.assign(Object.assign({},t?.htmlparser2??a),{trustedTypePolicy:t?.trustedTypePolicy});return(0,r.default)((0,n.default)(e,i),t)}}))(),1),YM=JM.default.default||JM.default,XM=class{diff(e,t,n={}){let r;typeof n==`function`?(r=n,n={}):`callback`in n&&(r=n.callback);let i=this.castInput(e,n),a=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),s=this.removeEmpty(this.tokenize(a,n));return this.diffWithOptionsObj(o,s,n,r)}diffWithOptionsObj(e,t,n,r){let i=e=>{if(e=this.postProcess(e,n),r){setTimeout(function(){r(e)},0);return}return e},a=t.length,o=e.length,s=1,c=a+o;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let l=n.timeout??1/0,u=Date.now()+l,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=o&&f+1>=a)return i(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,m=1/0,h=()=>{for(let r=Math.max(p,-s);r<=Math.min(m,s);r+=2){let s,c=d[r-1],l=d[r+1];c&&(d[r-1]=void 0);let u=!1;if(l){let e=l.oldPos-r;u=l&&0<=e&&e<a}let h=c&&c.oldPos+1<o;if(!u&&!h){d[r]=void 0;continue}if(s=!h||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,n):this.addToPath(c,!1,!0,1,n),f=this.extractCommon(s,t,e,r,n),s.oldPos+1>=o&&f+1>=a)return i(this.buildValues(s.lastComponent,t,e))||!0;d[r]=s,s.oldPos+1>=o&&(m=Math.min(m,r-1)),f+1>=a&&(p=Math.max(p,r+1))}s++};if(r)(function e(){setTimeout(function(){if(s>c||Date.now()>u)return r(void 0);h()||e()},0)})();else for(;s<=c&&Date.now()<=u;){let e=h();if(e)return e}}addToPath(e,t,n,r,i){let a=e.lastComponent;return a&&!i.oneChangePerToken&&a.added===t&&a.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:a.count+1,added:t,removed:n,previousComponent:a.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:a}}}extractCommon(e,t,n,r,i){let a=t.length,o=n.length,s=e.oldPos,c=s-r,l=0;for(;c+1<a&&s+1<o&&this.equals(n[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){let t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join(``)}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){let r=[],i;for(;e;)r.push(e),i=e.previousComponent,delete e.previousComponent,e=i;r.reverse();let a=r.length,o=0,s=0,c=0;for(;o<a;o++){let e=r[o];if(e.removed)e.value=this.join(n.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(s,s+e.count);r=r.map(function(e,t){let r=n[c+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return r}};new class extends XM{};function ZM(e,t){let n=0;for(;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function QM(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return``;for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function $M(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function eN(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function tN(e,t){return $M(e,t,``)}function nN(e,t){return eN(e,t,``)}function rN(e,t){return t.slice(0,iN(e,t))}function iN(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);let i=Array(r),a=0;i[0]=0;for(let e=1;e<r;e++){for(t[e]==t[a]?i[e]=i[a]:i[e]=a;a>0&&t[e]!=t[a];)a=i[a];t[e]==t[a]&&a++}a=0;for(let r=n;r<e.length;r++){for(;a>0&&e[r]!=t[a];)a=i[a];e[r]==t[a]&&a++}return a}function aN(e,t){let n=[];for(let r of Array.from(t.segment(e))){let e=r.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}return n}function oN(e,t){if(t)return cN(e,t)[1];let n;for(n=e.length-1;n>=0&&e[n].match(/\s/);n--);return e.substring(n+1)}function sN(e,t){if(t)return cN(e,t)[0];let n=e.match(/^\s*/);return n?n[0]:``}function cN(e,t){if(!t)return[sN(e),oN(e)];if(t.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);let n=aN(e,t),r=n[0],i=n[n.length-1];return[/\s/.test(r)?r:``,/\s/.test(i)?i:``]}var lN=`a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}`,uN=RegExp(`[${lN}]+|\\s+|[^${lN}]`,`ug`),dN=new class extends XM{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){let r=t.intlSegmenter;if(r.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);n=aN(e,r)}else n=e.match(uN)||[];let r=[],i=null;return n.forEach(e=>{/\s/.test(e)?i==null?r.push(e):r.push(r.pop()+e):i!=null&&/\s/.test(i)?r[r.length-1]==i?r.push(r.pop()+e):r.push(i+e):r.push(e),i=e}),r}join(e){return e.map((e,t)=>t==0?e:e.replace(/^\s+/,``)).join(``)}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,i=null;return e.forEach(e=>{e.added?r=e:e.removed?i=e:((r||i)&&pN(n,i,r,e,t.intlSegmenter),n=e,r=null,i=null)}),(r||i)&&pN(n,i,r,null,t.intlSegmenter),e}};function fN(e,t,n){return n?.ignoreWhitespace!=null&&!n.ignoreWhitespace?hN(e,t,n):dN.diff(e,t,n)}function pN(e,t,n,r,i){if(t&&n){let[a,o]=cN(t.value,i),[s,c]=cN(n.value,i);if(e){let r=ZM(a,s);e.value=eN(e.value,s,r),t.value=tN(t.value,r),n.value=tN(n.value,r)}if(r){let e=QM(o,c);r.value=$M(r.value,c,e),t.value=nN(t.value,e),n.value=nN(n.value,e)}}else if(n){if(e){let e=sN(n.value,i);n.value=n.value.substring(e.length)}if(r){let e=sN(r.value,i);r.value=r.value.substring(e.length)}}else if(e&&r){let n=sN(r.value,i),[a,o]=cN(t.value,i),s=ZM(n,a);t.value=tN(t.value,s);let c=QM(tN(n,s),o);t.value=nN(t.value,c),r.value=$M(r.value,n,c),e.value=eN(e.value,n,n.slice(0,n.length-c.length))}else if(r){let e=sN(r.value,i),n=rN(oN(t.value,i),e);t.value=nN(t.value,n)}else if(e){let n=rN(oN(e.value,i),sN(t.value,i));t.value=tN(t.value,n)}}var mN=new class extends XM{tokenize(e){let t=RegExp(`(\\r?\\n)|[${lN}]+|[^\\S\\n\\r]+|[^${lN}]`,`ug`);return e.match(t)||[]}};function hN(e,t,n){return mN.diff(e,t,n)}new class extends XM{constructor(){super(...arguments),this.tokenize=gN}equals(e,t,n){return n.ignoreWhitespace?((!n.newlineIsToken||!e.includes(`
148
148
  `))&&(e=e.trim()),(!n.newlineIsToken||!t.includes(`
149
149
  `))&&(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith(`
150
150
  `)&&(e=e.slice(0,-1)),t.endsWith(`
151
- `)&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function hN(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
152
- `));let n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){let i=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=i:n.push(i)}return n}function gN(e){return e==`.`||e==`!`||e==`?`}new class extends YM{tokenize(e){let t=[],n=0;for(let r=0;r<e.length;r++){if(r==e.length-1){t.push(e.slice(n));break}if(gN(e[r])&&e[r+1].match(/\s/)){for(t.push(e.slice(n,r+1)),r=n=r+1;e[r+1]?.match(/\s/);)r++;t.push(e.slice(n,r+1)),n=r+1}}return t}},new class extends YM{tokenize(e){return e.split(/([{}:;,]|\s+)/)}},new class extends YM{constructor(){super(...arguments),this.tokenize=hN}get useLongestToken(){return!0}castInput(e,t){let{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>t===void 0?n:t}=t;return typeof e==`string`?e:JSON.stringify(_N(e,null,null,r),null,` `)}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,`$1`),t.replace(/,([\r\n])/g,`$1`),n)}};function _N(e,t,n,r,i){t||=[],n||=[],r&&(e=r(i===void 0?``:i,e));let a=0;for(;a<t.length;a+=1)if(t[a]===e)return n[a];let o;if(Object.prototype.toString.call(e)===`[object Array]`){for(t.push(e),o=Array(e.length),n.push(o),a=0;a<e.length;a+=1)o[a]=_N(e[a],t,n,r,String(a));return t.pop(),n.pop(),o}if(e&&e.toJSON&&(e=e.toJSON()),typeof e==`object`&&e){t.push(e),o={},n.push(o);let i=[],s;for(s in e)Object.prototype.hasOwnProperty.call(e,s)&&i.push(s);for(i.sort(),a=0;a<i.length;a+=1)s=i[a],o[s]=_N(e[s],t,n,r,s);t.pop(),n.pop()}else o=e;return o}new class extends YM{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};var vN=e=>(new DOMParser().parseFromString(e,`text/html`).body.textContent??``).trim(),yN={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`},bN=e=>e.replace(/[&<>"']/g,e=>yN[e]),xN=(e,t,n)=>{let r=dN(t,n,{intlSegmenter:new Intl.Segmenter(e,{granularity:`word`})}),i,a=``,o=``,s=0,c=r.length-1;for(let e=0;e<r.length;e++)i=r[e],i.added||i.removed?(a===``?s=e:(a.endsWith(`</ins>`)||a.endsWith(`</del>`))&&(a+=` `),c=e,o=i.added?`ins`:`del`,i.value!==`undefined`&&(a+=`<${o}>${bN(i.value)}</${o}>`)):a!==``&&e<r.length-1&&(a+=bN(i.value));let l=120-vN(a).length;if(l>0){let e=``;if(s>0&&(e=r[0].value.substring(Math.max(0,r[0].value.length-Math.min(50,l)),r[0].value.length),e!=r[0].value&&(e=e.slice(e.indexOf(` `)),e=`...`+e),a=bN(e)+a),l-=e.length,c<r.length-1&&l){let e=r[r.length-1].value.substring(0,Math.min(50,l));e!=r[r.length-1].value&&(e=e.substring(0,e.lastIndexOf(` `)),e+=`...`),a+=bN(e)}}return a},SN=({analytics:e,element:t,data:n,prevData:r,hide:i,updateTextWithAlternative:a,addIgnoredTerm:o,movePopoverNextOrPrev:s,setLLMSuggestionsRequest:c,getLLMSuggestions:l,focusOnOpen:u,llmAlternativesEnabled:d,dashboardAvailable:f,ignoreTermPermanently:p,onAlternativeAccepted:m})=>{let h=document.documentElement||document.body,{t:g,i18n:_}=ky(eb.popover),{analytics:v,alternativeHovered:y,setAlternativeHovered:b,showLearningBite:x,setShowLearningBite:S,showLearningBiteRef:C,isLoading:w,isSuccess:T,isFailure:E,llmAlternativesResponse:D,hidePopover:O,clickAlternative:ee,alternativeKeyDown:te,handleIgnoreClick:ne,goToAdjacentAlert:re}=HC({analytics:e,element:t,data:n,prevData:r,hide:i,updateTextWithAlternative:a,addIgnoredTerm:o,movePopoverNextOrPrev:s,setLLMSuggestionsRequest:c,getLLMSuggestions:l,llmAlternativesEnabled:d,ignoreTermPermanently:p,onAlternativeAccepted:m});(0,W.useEffect)(()=>{_.changeLanguage(n.alert.data?.language)},[n.alert.data?.language]);let{x:k,y:A,strategy:ie,refs:ae}=LC({placement:`bottom-start`,middleware:[(e=>({name:`elementCords`,options:e,fn:({placement:n,rects:r})=>{let i={top:0,left:0,bottom:0,right:0};if(Pj(t)){let t=document.getElementsByTagName(`iframe`),n=Array.from(t).find(t=>{try{return(t.contentDocument||t.contentWindow?.document)?.contains(e.node)}catch(e){return console.error(`Failed to access iframe content: `,e),!1}});try{n?.getBoundingClientRect()&&(i=n?.getBoundingClientRect())}catch(e){console.error(`Failed to get iframe bounding rect: `,e)}}let a=e.position.x+i.left+h.scrollLeft,o=n.includes(`bottom`)?e.position.y+e.position.height+i.top+h.scrollTop:e.position.y-r.floating.height+i.top+h.scrollTop;return{x:C.current?a/2:a,y:o}}}))(n),BC(),RC(4),zC()]});(0,W.useEffect)(()=>{ae.setReference(t),C.current=x},[ae.setReference,x]),(0,W.useEffect)(()=>(Ij(t)?.addEventListener(`scroll`,oe),t?.addEventListener(`scroll`,oe),document?.addEventListener(`click`,se),document?.addEventListener(`input`,se),hO()?.addEventListener(`click`,se),hO()?.addEventListener(`input`,se),()=>{document.removeEventListener(`click`,se),document.removeEventListener(`input`,se),Ij(t)?.removeEventListener(`scroll`,oe),t.removeEventListener(`scroll`,oe),hO().removeEventListener(`click`,se),hO().removeEventListener(`input`,se)}),[ae.floating.current]),(0,W.useEffect)(()=>{u&&ae.floating.current?.focus()},[n.alert.id,u,ae.floating.current]),(0,W.useEffect)(()=>{let e=hO(),n=e=>{if(e.key!==`Escape`)return;e.preventDefault(),e.stopPropagation();let n=ae.floating.current?.contains(document.activeElement);O(!0),n&&t.focus?.()};return document.addEventListener(`keydown`,n,!0),e!==document&&e?.addEventListener(`keydown`,n,!0),()=>{document.removeEventListener(`keydown`,n,!0),e!==document&&e?.removeEventListener(`keydown`,n,!0)}},[ae.floating.current]);let oe=()=>{O()},se=e=>{let t=!ae.floating.current?.contains(e.target),r=hO().documentElement||hO().body,i=e.pageX+r.scrollLeft,a=e.pageY-r.scrollTop,o=i>=n.position.x&&i<=n.position.x+n.position.width&&a>=n.position.y&&a<=n.position.y+n.position.height;t&&!o&&O()},ce=e=>{let t=(e=!0)=>W.createElement(`div`,{key:`default-expl-${e?`visible`:`hidden`}`,style:{visibility:e?`visible`:`hidden`,gridArea:`1 / 1`}},n.alert.data?.explanation?.text,n.alert.data?.explanation?.context&&` (`+n.alert.data?.explanation?.context+`)`);if(!D||D.loading)return t(!0);let r=n.alert.data.alternatives.map((n,r)=>{let i=le(n);return W.createElement(`div`,{key:`explanation-${r}-${n.text||`alt`}`,style:{position:`relative`,top:0,gridArea:`1 / 1`,visibility:e&&e.text===n.text?`visible`:`hidden`}},i||t(!0))});return r.push(t(e===null)),r},le=e=>{let t=D?.data?.results?.get(e.text);if(!t){let r=n.alert.startOffset-n.alert.data.fullSentence.range[0],i=n.alert.endOffset-n.alert.data.fullSentence.range[0];t=n.alert.data.fullSentence.raw.substring(0,r)+e.text+n.alert.data.fullSentence.raw.substring(i)}return W.createElement(`div`,{dangerouslySetInnerHTML:{__html:xN(n.alert.data.language,n.alert.data.fullSentence.raw,t)}})},ue=e=>{if(e&&e.text===``)return W.createElement(`i`,null,g(`removeSpaces`));{let t=/\(\((.*?)\)\)/;if(RegExp(t).exec(e.text)){let n=e.text.split(t);return W.createElement(`span`,null,n[0],`\xA0`,`[`,W.createElement(`i`,null,n[1]),`]`,`\xA0`,n[2])}return e.text.length>25&&e.context?e.text.substring(0,25)+`...`:e.text.length>35?e.text.substring(0,35)+`...`:e.text}};return W.createElement(`div`,{id:`witty-works-ext-popover`,ref:ae.setFloating,role:`dialog`,"aria-label":g(`suggestionsDialog`),tabIndex:-1,style:{position:ie,top:`${A}px`,left:`${k}px`,maxWidth:`min(${x?850:350}px, calc(100vw - 16px))`},onMouseDown:e=>e.preventDefault()},W.createElement(`div`,{id:`witty-works-ext-popover-content`,className:`witty-works-ext-lato-popover-text`},W.createElement(`div`,{className:`witty-works-ext-section witty-works-ext-wittyworks-container witty-works-ext-container-row witty-works-ext-justify-space-between`},W.createElement(`a`,{className:`witty-works-ext-margin-right witty-works-ext-cursor-pointer`,href:`https://www.witty.works/`,target:`_blank`,rel:`noreferrer`,"aria-label":g(`wittyLogo`)},W.createElement(GC,{"aria-hidden":`true`})),W.createElement(`div`,{className:`witty-works-ext-container-row`},W.createElement(`button`,{className:`witty-works-ext-margin-right witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer witty-works-ext-margin-auto witty-works-button`,style:n.index===1?{display:`none`}:{},onClick:()=>{n.index!==1&&re(`previous`)},"aria-label":g(`previous`),title:g(`previous`)},W.createElement(qC,{alt:g(`previous`)})),W.createElement(`div`,{className:`witty-works-ext-margin-right witty-works-ext-lato-popover-text-gray witty-works-ext-margin-right`,role:`status`,"aria-live":`polite`,"aria-label":`${n.index} ${g(`alertOftotal`)} ${n.totalAlerts}`},`${n.index} ${g(`alertOftotal`)} ${n.totalAlerts}`),W.createElement(`button`,{className:`witty-works-ext-margin-right witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer witty-works-ext-margin-auto witty-works-button`,style:n.index===n.totalAlerts?{display:`none`}:{},onClick:()=>{n.index!==n.totalAlerts&&re(`next`)},"aria-label":g(`next`),title:g(`next`)},W.createElement(KC,{alt:g(`next`)}))),W.createElement(`button`,{className:`witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer witty-works-button`,onClick:()=>{O(!0)},"aria-label":g(`close`),title:g(`close`)},W.createElement(WC,{alt:g(`close`)}))),n.alert.data?.explanation?.text&&W.createElement(W.Fragment,null,W.createElement(`div`,{className:`witty-works-ext-separator`}),W.createElement(`div`,{className:`witty-works-ext-wittyworks-container witty-works-ext-container-rounded witty-works-ext-container-column witty-works-ext-full-padding witty-works-ext-justify-start witty-works-ext-margin-top`,style:{backgroundColor:ov(n.alert.data?.gravity,n.alert.data?.subcategory).default}},W.createElement(`div`,{className:`witty-works-ext-lato-popover-text witty-works-ext-justify-space-between`,style:{display:`flex`,flexDirection:x?`row`:`column`,alignItems:x?`center`:`flex-start`}},W.createElement(`div`,{className:`witty-works-ext-container-row witty-works-ext-justify-start`,style:{flex:1}},W.createElement(`div`,{style:{fontSize:`2em`,marginRight:`0.5em`,flexShrink:0,height:`100%`}},n.alert.data?.explanation?.icon_image?W.createElement(`img`,{src:n.alert.data?.explanation?.icon_image,alt:``,style:{width:`50px`}}):W.createElement(`span`,null,n.alert.data?.explanation?.icon)),W.createElement(`div`,{className:`witty-works-ext-rephrasing`,style:{flex:`0 1 252px`,minWidth:0,height:`100%`}},W.createElement(`b`,null,n.alert.data?.label.split(`:`).pop()),W.createElement(`br`,null),W.createElement(`div`,{style:{position:`relative`,display:`grid`}},ce(y)))),n.alert.data?.explanation?.url&&W.createElement(`div`,{className:`witty-works-ext-container-row witty-works-ext-justify-end witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer`,style:{marginTop:x?`0em`:`1em`}},W.createElement(`button`,{type:`button`,className:`witty-works-ext-dropdown-select witty-works-ext-container-row`,onClick:()=>{v.popoverLogs(n.alert,`learning_bites`),S(!x)},style:{cursor:n.alert.data?.explanation?.url?`pointer`:`default`},"aria-expanded":x,"aria-label":g(`leanrMoreExtendedText`),title:g(`leanrMoreExtendedText`)},g(`learnMore`),n.alert.data?.explanation?.content===`video`&&W.createElement(JC,{className:`witty-works-ext-margin-left`,style:{marginTop:`0.2em`},alt:g(`video`)}),W.createElement(`div`,{className:`witty-works-ext-margin-left`,style:{pointerEvents:`none`}},x?W.createElement(ZC,null):W.createElement(QC,null))),n.alert.data?.source?.url&&W.createElement(`a`,{className:`witty-works-ext-dropdown-select witty-works-ext-container-row`,href:n.alert.data.source.url,target:`_new`,"aria-label":g(`visitSource`),title:g(`visitSource`)},g(`visitSource`),W.createElement(XC,{className:`witty-works-ext-margin-left`,alt:g(`openNewWindow`)})))))),W.createElement(`div`,{style:{display:x?`flex`:`none`}},W.createElement(`div`,{className:`witty-works-ext-learning-bite-dig-deeper`},W.createElement(`div`,null,W.createElement(`div`,null,JM(n.alert.data?.explanation?.long_text??``)),W.createElement(`div`,null,n.alert.data?.explanation?.url&&W.createElement(`a`,{className:`witty-works-dig-deeper witty-works-ext-container-row`,href:n.alert.data.explanation.url,target:`_new`,"aria-label":g(`leanrMoreExtendedText`),title:g(`leanrMoreExtendedText`)},g(`leanrMoreExtendedText`),W.createElement(YC,{className:`witty-works-ext-margin-left`,alt:g(`openNewWindow`)})))),n.alert.data?.explanation?.video_url&&W.createElement(`video`,{width:`500`,style:{maxWidth:`100%`},controls:!0},W.createElement(`source`,{src:n.alert.data?.explanation?.video_url,type:`video/mp4`}),`Your browser does not support the video tag.`),!n.alert.data?.explanation?.video_url&&n.alert.data?.explanation?.image_url&&W.createElement(`img`,{style:{width:`500px`,maxWidth:`100%`},src:n.alert.data?.explanation?.image_url?.src,alt:n.alert.data?.explanation?.image_url?.alt}))),W.createElement(`div`,{className:`witty-works-ext-separator`,style:{marginBottom:`1em`,marginTop:`1em`}}),n.alert.data?.alternatives?.length>0&&!x&&W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-row`},W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-btn-container`},g(`insteadTry`)),W.createElement(`div`,null,n.alert.data?.alternatives.map((e,t)=>e.remove?W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-btn-container`,onMouseEnter:()=>{b(e)},onMouseLeave:()=>{b(null)},key:`${t}-${e.text||`alt`}-container`},W.createElement(`button`,{type:`button`,className:`witty-works-ext-wittyworks-popover-alternative-btn witty-works-ext-lato-popover-text-green witty-works-ext-remove-text witty-works-ext-margin-right`,key:`${t}-${e.text||`alt`}-remove-it`,onPointerDown:e=>ee(e.nativeEvent,` `),onKeyDown:te(` `),"aria-label":`${g(`removeText`)} ${n.alert.data?.text}`,title:g(`removeText`)},n.alert.data?.text),e.context&&W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-context`},e.context)):W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-btn-container`,key:`${t}-${e.text||`alt`}-container`,onMouseEnter:()=>{b(e)},onMouseLeave:()=>{b(null)}},W.createElement(`button`,{type:`button`,className:`witty-works-ext-wittyworks-popover-alternative-btn witty-works-ext-lato-popover-text-green witty-works-ext-margin-right`,onPointerDown:e=>ee(e.nativeEvent,n.alert.data?.alternatives[t]?.text),onKeyDown:te(n.alert.data?.alternatives[t]?.text),"aria-label":n.alert.data?.alternatives[t]?.text,title:n.alert.data?.alternatives[t]?.text},ue(e)),e&&e.context&&W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-context`,style:{color:`black`}},e.url?W.createElement(W.Fragment,null,e.context.startsWith(`💡`)?W.createElement(W.Fragment,null,W.createElement(`span`,{style:{whiteSpace:`nowrap`}},W.createElement(`span`,null,e.context.substring(0,3)),W.createElement(`a`,{href:e.url,target:`_blank`,style:{textDecoration:`underline`,color:`black`},rel:`noopener noreferrer`,"aria-label":e.context,title:e.context},e.context.substring(3)))):W.createElement(`a`,{href:e.url,target:`_blank`,style:{textDecoration:`underline`,color:`black`,whiteSpace:`nowrap`},rel:`noopener noreferrer`,"aria-label":e.context,title:e.context},e.context)):W.createElement(`span`,{style:{color:`black`,whiteSpace:`nowrap`}},e.context))))))),!x&&W.createElement(`div`,{className:`witty-works-ext-container-row`},W.createElement(`button`,{onClick:ne(`ignore_once`),className:`witty-works-ext-ignore-section witty-works-ext-ignore-color-transformer witty-works-ext-margin-top witty-works-button`,"aria-label":g(`ignoreOnce`),title:g(`ignoreOnce`)},W.createElement(`span`,{className:`witty-works-ext-margin-right witty-works-ext-cursor-pointer`},W.createElement(pO,{alt:g(`ignoreOnce`)})),W.createElement(`span`,{className:`witty-works-ext-lato-popover-text-gray`},g(`ignoreOnce`))),f&&n?.alert?.data?.text.length<=50&&W.createElement(`button`,{onClick:ne(`ignore_permanently`),className:`witty-works-ext-ignore-section witty-works-ext-ignore-color-transformer witty-works-ext-margin-top witty-works-button`,"aria-label":g(`ignorePermanently`),title:g(`ignorePermanently`)},W.createElement(`span`,{className:`witty-works-ext-margin-right witty-works-ext-cursor-pointer`},W.createElement(pO,{alt:g(`ignorePermanently`)})),W.createElement(`span`,{className:`witty-works-ext-lato-popover-text-gray witty-works-ext-margin-right`},g(`ignorePermanently`)),w===`ignore_permanently`&&W.createElement(uO,null),T===`ignore_permanently`&&W.createElement(dO,null),E===`ignore_permanently`&&W.createElement(W.Fragment,null,W.createElement(fO,null),` `,W.createElement(`span`,{className:`witty-works-ext-margin-left`},g(`failedRequestText`))))))},CN=e=>{let t=0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t=(t<<5)-t+r,t&=t}return t.toString()},wN=()=>({data:null,error:null,loading:!0}),TN=e=>`${CN(e.alert.data.fullSentence.raw)}::${e.alert.data.text}`,EN=(e,t)=>({data:e?{...e,results:new Map(Object.entries(e.results))}:null,error:t||null,loading:!1}),DN=(e,t,n,r)=>{let i=Cb(n,r),{from:a,to:o}=t;if(i.scope===`sentence`){let{detail:r}=t,s=r.data.fullSentence,c=t.from-(r.absOffset-s.range[0]),l=c+s.raw.length;c>=0&&l<=e.content.size&&e.textBetween(c,l)===s.raw?(a=c,o=l):i=Cb(n,null)}return n===` `&&a>0&&e.textBetween(a-1,a)===` `&&--a,{from:a,to:o,text:i.text}},ON={popoverLogs:()=>void 0,alternativeLog:()=>void 0,ignoreLog:()=>void 0},kN=class{view;options;container;root;openId=null;focusOnOpen=!1;prevData=null;llmCache=new Map;rewriteGeneration=0;destroyed=!1;constructor(e,t){this.view=e,this.options=t,this.container=document.createElement(`div`),this.container.className=`witty-editor-popover`,document.body.append(this.container),this.root=(0,Jx.createRoot)(this.container)}get isOpen(){return this.openId!==null}open(e,{viaKeyboard:t=!1}={}){this.destroyed||(this.focusOnOpen=t,this.openId=e,kx(this.view,e),this.render())}openAtSelection(){let{from:e}=this.view.state.selection,t=xx(this.view.state).find(t=>t.from<=e&&e<=t.to);return t?(this.open(t.id,{viaKeyboard:!0}),!0):!1}close(){this.openId!==null&&(this.openId=null,this.prevData=null,kx(this.view,null),this.root.render(null))}update(){if(this.openId!==null){if(!this.current()){this.close();return}this.render()}}resetRewrites(){this.llmCache.clear(),this.rewriteGeneration+=1}destroy(){this.destroyed=!0,this.openId=null,this.root.unmount(),this.container.remove()}current(){return xx(this.view.state).find(e=>e.id===this.openId)}render(){if(this.destroyed)return;let e=xx(this.view.state),t=e.findIndex(e=>e.id===this.openId),n=e[t];if(!n){this.close();return}let r=this.view.coordsAtPos(n.from),i=this.view.coordsAtPos(n.to),a={index:t+1,totalAlerts:e.length,alert:n.detail,position:new DOMRect(r.left,r.top,Math.max(i.right-r.left,1),r.bottom-r.top),node:this.view.domAtPos(n.from).node};this.root.render(W.createElement(SN,{analytics:ON,element:this.view.dom,data:a,prevData:this.prevData,hide:()=>this.close(),updateTextWithAlternative:e=>this.apply(n,e),addIgnoredTerm:e=>{this.options.ignored.add(e),Ax(this.view,e)},movePopoverNextOrPrev:e=>this.move(t,e),setLLMSuggestionsRequest:e=>this.requestRewrites(e),getLLMSuggestions:e=>this.llmCache.get(TN(e)),focusOnOpen:this.focusOnOpen,llmAlternativesEnabled:this.options.llmAlternatives(),dashboardAvailable:!1,ignoreTermPermanently:()=>Promise.reject(Error(`no dashboard to persist ignores to`)),onAlternativeAccepted:()=>void 0})),this.prevData=a}move(e,t){let n=xx(this.view.state)[e+(t===`previous`?-1:1)];n&&this.open(n.id,{viaKeyboard:this.focusOnOpen})}apply(e,t){this.close();let{state:n}=this.view,{from:r,to:i,text:a}=DN(n.doc,e,t,this.llmCache.get(TN({alert:e.detail}))?.data?.results),o=a?n.tr.insertText(a,r,i):n.tr.delete(r,i);this.view.dispatch(o.scrollIntoView()),this.view.focus()}rewriteBody(e){let t=mb(e.alert.data.fullSentence,e.alert),n=_b(e.alert.data.language,this.options.config());return n?{...t,gender_separator:n}:t}requestRewrites(e){let t=TN(e),n=this.llmCache.get(t);if(n&&!n.error)return;let r=this.rewriteGeneration;this.llmCache.set(t,wN()),this.render(),fetch(`${this.options.endpoint}${cb}`,{method:`POST`,headers:{...db,...this.options.headers()},body:JSON.stringify(this.rewriteBody(e)),signal:AbortSignal.timeout(this.options.llmTimeoutMs)}).then(async e=>{if(!e.ok)throw Error(`HTTP ${e.status}`);return EN(await e.json(),null)}).catch(e=>EN(null,{message:String(e)})).then(e=>{this.destroyed||r!==this.rewriteGeneration||(this.llmCache.set(t,e),this.openId!==null&&this.render())})}},AN=e=>{let t=e,n=new Set;return{get:()=>t,set(e){t={...t,...e},n.forEach(e=>e())},subscribe(e){return n.add(e),()=>{n.delete(e)}}}},jN=e=>AN(e),MN=e=>{let t={};for(let n of[`gendered_roles_format`,`german_gender_ending`,`french_gender_separator`]){let r=e[n];r&&(t[n]=r)}return t},NN=(e,t,n)=>{let r={...e};return n?r[t]=n:delete r[t],r},PN=(e,t,n)=>({...e,disabled_categories:rv(t.key,t.advanced_key,n,e.disabled_categories??[])}),FN=({categoryKey:e,label:t,value:n,hasAdvanced:r,locked:i=!1,onChange:a})=>{let{t:o}=ky(eb.options),s=[o(`levelOff`),o(`levelBasic`),o(`levelAdvanced`)][n];return W.createElement(`div`,{className:`witty-category`},W.createElement(`button`,{type:`button`,className:[`witty-category-toggle`,n>tv.Off?`is-on`:``,n===tv.Basic?`is-middle`:``,i?`is-locked`:``].filter(Boolean).join(` `),"data-category":e,"data-level":n,"aria-label":`${t}: ${s}`,"aria-disabled":i,title:i?o(`levelLocked`):s,onClick:()=>{i||a(n>=(r?tv.Advanced:tv.Basic)?tv.Off:n+1)}},W.createElement(`span`,{className:`witty-category-knob`})),W.createElement(`span`,{className:`witty-category-label`},t),W.createElement(`span`,{className:`witty-category-level`},s))},IN={gendered_roles_format:`genderedRolesFormat`,german_gender_ending:`germanGenderEnding`,french_gender_separator:`frenchGenderSeparator`},LN=({orthography:e,onOrthographyChange:t,llmAlternatives:n,onLlmAlternativesChange:r,configOptions:i,languageFormat:a,onFormatFieldChange:o,categories:s,categoryGroups:c,disabledCategories:l,onCategoryLevelChange:u,categoriesError:d=!1,idPrefix:f=``})=>{let{t:p}=ky(eb.options),m=(e,t)=>i[e]?.labels?.[t]||t;return W.createElement(W.Fragment,null,W.createElement(`section`,null,W.createElement(`h2`,null,p(`customisationHeadline`)),W.createElement(`p`,{className:`witty-options-muted`},p(`orgOverrideNote`)),W.createElement(`label`,null,W.createElement(`input`,{type:`checkbox`,id:`${f}opt-orthography`,checked:e,onChange:e=>t(e.target.checked)}),`\xA0`,p(`orthography`)),W.createElement(`label`,null,W.createElement(`input`,{type:`checkbox`,id:`${f}opt-llm-alternatives`,checked:n,onChange:e=>r(e.target.checked)}),`\xA0`,p(`llmAlternatives`))),Object.keys(i).length>0&&W.createElement(`section`,{id:`${f}language-format-section`},W.createElement(`h2`,null,p(`languageHeadline`)),W.createElement(`p`,{className:`witty-options-muted`},p(`orgOverrideNote`)),ev.filter(e=>i[e]).map(e=>{let t=i[e],n=IN[e];return W.createElement(`div`,{className:`witty-format-field`,key:e},W.createElement(`label`,{htmlFor:`${f}opt-${e}`},p(n)),W.createElement(`p`,{className:`witty-options-muted`},p(`${n}Hint`)),W.createElement(`select`,{id:`${f}opt-${e}`,"data-field":e,value:a[e]||``,onChange:t=>o(e,t.target.value)},W.createElement(`option`,{value:``},p(`useApiDefault`),t.default?` (${t.default})`:``),t.values.map(t=>W.createElement(`option`,{value:t,key:t},m(e,t)))))})),s.length>0&&W.createElement(`section`,{id:`${f}categories-section`},W.createElement(`h2`,null,p(`categoriesHeadline`)),W.createElement(`p`,{className:`witty-options-muted`},p(`categoriesIntro`)),c.map(e=>{let t=s.filter(t=>t.parent===e.key);return t.length?W.createElement(`div`,{className:`witty-category-group`,key:e.key},W.createElement(`h3`,null,e.label||e.key),t.map(e=>W.createElement(FN,{key:e.key,categoryKey:e.key,label:e.label||e.key,hasAdvanced:!!e.advanced_key,locked:e.proficiency_level===`openly_discriminating`,value:nv(e.key,e.advanced_key,l),onChange:t=>u(e,t)}))):null})),d&&W.createElement(`p`,{className:`witty-options-muted`},p(`categoriesFailed`)))},RN=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M14.4244 15.865C15.2179 17.3926 17.2257 17.3746 17.9964 15.833L16.5828 14.9778C16.4193 15.3047 15.9934 15.3086 15.8251 14.9846L14.4244 15.865Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.0406 13.2011L14.4244 15.865L15.8251 14.9846L14.4413 12.3206L13.0406 13.2011Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.3408 11.9904C12.954 12.2335 12.8196 12.7756 13.0406 13.2011L14.4413 12.3206C14.2203 11.8951 13.7276 11.7473 13.3408 11.9904Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M15.7489 3C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M20.9495 3H15.7489V4.7747H20.9495V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M22.7436 6.33803C23.4942 4.83684 22.5069 3 20.9495 3V4.7747C21.2798 4.7747 21.4893 5.16433 21.3301 5.48277L22.7436 6.33803Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M17.9964 15.833L22.7436 6.33803L21.3301 5.48277L16.5828 14.9778L17.9964 15.833Z`,fill:`#9489DB`})]}),zN=e=>(0,G.jsxs)(`svg`,{width:25,height:24,viewBox:`0 0 25 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M14.4244 18.865C15.2179 20.3926 17.2257 20.3746 17.9964 18.833L16.5828 17.9778C16.4193 18.3047 15.9934 18.3086 15.8251 17.9846L14.4244 18.865Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.0406 16.2011L14.4244 18.865L15.8251 17.9846L14.4413 15.3206L13.0406 16.2011Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.3408 14.9904C12.954 15.2335 12.8196 15.7756 13.0406 16.2011L14.4413 15.3206C14.2203 14.8951 13.7276 14.7473 13.3408 14.9904Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 7.41595C10.7681 6.56076 10.0151 6 9.17787 6V7.7747C9.17787 7.7747 9.51518 7.89365 9.58114 8.07505L10.5101 10.6298C10.6755 11.0848 11.145 11.3061 11.5586 11.1241C11.9722 10.9421 12.1734 10.4257 12.008 9.97068L11.079 7.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 6H4.05053V7.7747H9.17787V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 6C2.49311 6 1.50583 7.83684 2.25638 9.33803L3.66995 8.48277C3.51074 8.16433 3.72017 7.7747 4.05053 7.7747V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 17.8317L3.66995 8.48277L2.25638 9.33803L6.93059 18.687L8.34416 17.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 17.8151C8.95664 18.1596 8.51289 18.1692 8.34416 17.8317L6.93059 18.687C7.71306 20.252 9.75014 20.2339 10.519 18.687L9.11322 17.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 7.24516L9.11322 17.8151L10.519 18.687C10.5317 18.6613 10.5441 18.6353 10.5562 18.6088L15.3604 8.03882L13.9175 7.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M15.7489 6C14.9733 6 14.2643 6.48204 13.9175 7.24516L15.3604 8.03882C15.434 7.87695 15.5844 7.7747 15.7489 7.7747V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M20.9495 6H15.7489V7.7747H20.9495V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M22.7436 9.33803C23.4942 7.83684 22.5069 6 20.9495 6V7.7747C21.2798 7.7747 21.4893 8.16433 21.33 8.48277L22.7436 9.33803Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M17.9964 18.833L22.7436 9.33803L21.33 8.48277L16.5828 17.9778L17.9964 18.833Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M6.38 5.43V11.15C6.38 11.7633 6.34333 12.3733 6.27 12.98C6.19667 13.58 6.1 14.1933 5.98 14.82H3.88C3.76 14.1933 3.66333 13.58 3.59 12.98C3.51667 12.3733 3.48 11.7633 3.48 11.15V5.43H6.38ZM3.14 18.43C3.14 18.19 3.18333 17.9667 3.27 17.76C3.36333 17.5533 3.48667 17.3733 3.64 17.22C3.8 17.0667 3.98667 16.9467 4.2 16.86C4.41333 16.7667 4.64667 16.72 4.9 16.72C5.14667 16.72 5.37667 16.7667 5.59 16.86C5.80333 16.9467 5.99 17.0667 6.15 17.22C6.31 17.3733 6.43333 17.5533 6.52 17.76C6.61333 17.9667 6.66 18.19 6.66 18.43C6.66 18.67 6.61333 18.8967 6.52 19.11C6.43333 19.3167 6.31 19.4967 6.15 19.65C5.99 19.8033 5.80333 19.9233 5.59 20.01C5.37667 20.0967 5.14667 20.14 4.9 20.14C4.64667 20.14 4.41333 20.0967 4.2 20.01C3.98667 19.9233 3.8 19.8033 3.64 19.65C3.48667 19.4967 3.36333 19.3167 3.27 19.11C3.18333 18.8967 3.14 18.67 3.14 18.43Z`,fill:`#F06464`})]}),BN=`https://www.witty.works/en/help/how-do-i-use-the-witty-editor`,VN=`https://www.witty.works/`,HN=e=>{let t=(0,W.useRef)(0),n=(0,W.useCallback)(n=>{let r=()=>{t.current+=1,n()};return e.on(`transaction`,r),()=>{e.off(`transaction`,r)}},[e]);return(0,W.useSyncExternalStore)(n,()=>t.current)},UN=e=>(0,W.useSyncExternalStore)(e.subscribe,e.get),WN=async e=>{let t=async t=>{let n=await fetch(`${e.endpoint}${t}`,{headers:{...db,...e.headers()}});if(!n.ok)throw Error(String(n.status));return n.json()},[n,r]=await Promise.allSettled([t(ub(navigator.language||`en-US`)),t(lb)]),i=n.status===`fulfilled`?n.value:void 0;return{categories:i?.categories||[],categoryGroups:i?.groups||[],categoriesError:!i,configOptions:r.status===`fulfilled`&&r.value.options||{}}},GN=e=>{let t;return()=>(t??=WN(e).then(e=>(e.categoriesError&&(t=void 0),e)),t)},KN=(e,t)=>e?.configOptions.german_gender_ending?.labels?.[t]||t,qN=e=>{let[t,n]=(0,W.useState)(null);return(0,W.useEffect)(()=>{let t=!0;return e().then(e=>{t&&n(e)}),()=>{t=!1}},[e]),t},JN=({id:e,store:t,loadOptions:n,onClose:r})=>{let{t:i}=ky(eb.editor),a=UN(t),o=qN(n),{config:s}=a;return W.createElement(`div`,{id:e,className:`witty-editor-settings witty-preferences`,role:`region`,"aria-label":i(`settings`),onKeyDown:e=>{e.key===`Escape`&&(e.stopPropagation(),r())}},W.createElement(`button`,{type:`button`,className:`witty-editor-settings-close`,"aria-label":i(`closeSettings`),title:i(`closeSettings`),onClick:r},`×`),!o&&W.createElement(`p`,{"aria-live":`polite`},i(`settingsLoading`)),W.createElement(LN,{idPrefix:`${e}-`,orthography:a.orthography,onOrthographyChange:e=>t.set({orthography:e}),llmAlternatives:a.llmAlternatives,onLlmAlternativesChange:e=>t.set({llmAlternatives:e}),configOptions:o?.configOptions??{},languageFormat:MN(s),onFormatFieldChange:(e,n)=>t.set({config:NN(s,e,n)}),categories:o?.categories??[],categoryGroups:o?.categoryGroups??[],disabledCategories:s.disabled_categories??[],onCategoryLevelChange:(e,n)=>t.set({config:PN(s,e,n)}),categoriesError:o?.categoriesError}))},YN=({id:e,label:t,items:n,anchor:r,onClose:i})=>{let a=(0,W.useRef)([]),[o,s]=(0,W.useState)(0);(0,W.useEffect)(()=>{a.current[0]?.focus()},[]);let c=e=>{let t=(e+n.length)%n.length;s(t),a.current[t]?.focus()};return W.createElement(`div`,{id:e,className:`witty-editor-menu`,role:`menu`,tabIndex:-1,"aria-label":t,onKeyDown:e=>{e.stopPropagation();let t=a.current.indexOf(document.activeElement),r=t<0?o:t,s={ArrowDown:r+1,ArrowUp:r-1,Home:0,End:n.length-1};e.key in s?(e.preventDefault(),c(s[e.key])):e.key===`Escape`?(e.preventDefault(),i(!0)):e.key===`Tab`&&i(!1)},onBlur:e=>{let t=e.relatedTarget;(!t||!e.currentTarget.contains(t)&&t!==r())&&i(!1)}},n.map((e,t)=>{let n={ref:e=>{a.current[t]=e},role:`menuitem`,tabIndex:t===o?0:-1,className:`witty-editor-menu-item`,onFocus:()=>s(t),onMouseDown:e=>e.preventDefault()};return W.createElement(`div`,{key:e.key,role:`none`},e.href?W.createElement(`a`,{...n,href:e.href,target:`_blank`,rel:`noopener noreferrer`,onClick:()=>i(!1)},e.label):W.createElement(`button`,{...n,type:`button`,"aria-disabled":e.disabled||void 0,onClick:()=>!e.disabled&&e.run?.()},e.label,e.note&&W.createElement(`span`,{className:`witty-editor-menu-note`},e.note)))}))},XN=(e,t,n)=>{let r=KN(n,t.target),i={switched:e(`switched`,{count:t.count,format:r}),nothing:e(`switchNothing`,{format:r}),disabled:e(`switchDisabled`),unsupported:e(`switchUnsupported`),unavailable:e(`switchInklusivum`)}[t.outcome];return t.limitReached&&(t.outcome===`switched`||t.outcome===`nothing`)?`${i} ${e(`limitReached`)}`:i},ZN=({id:e,store:t,loadOptions:n,onSwitch:r,onClose:i})=>{let{t:a}=ky(eb.editor),o=UN(t),s=qN(n),[c,l]=(0,W.useState)(``),[u,d]=(0,W.useState)(!1),f=o.config.german_gender_ending,p=e=>{d(!0),l(a(`switching`)),r(e).then(e=>l(XN(a,e,s))).catch(()=>l(a(`statusFailed`))).finally(()=>d(!1))};return W.createElement(`div`,{id:e,className:`witty-editor-settings witty-editor-switch witty-preferences`,role:`region`,"aria-label":a(`switchTitle`),onKeyDown:e=>{e.key===`Escape`&&(e.stopPropagation(),i())}},W.createElement(`button`,{type:`button`,className:`witty-editor-settings-close`,"aria-label":a(`closeSettings`),title:a(`closeSettings`),onClick:i},`×`),W.createElement(`h2`,null,a(`switchTitle`)),W.createElement(`p`,{className:`witty-options-muted`},a(`switchIntro`)),W.createElement(`ul`,{className:`witty-editor-switch-formats`},Nx.map(e=>W.createElement(`li`,{key:e},W.createElement(`button`,{type:`button`,className:`witty-editor-switch-format`,"aria-disabled":u||void 0,"aria-current":e===f||void 0,onClick:()=>!u&&p(e)},KN(s,e),e===f&&` (${a(`switchCurrent`)})`))),W.createElement(`li`,null,W.createElement(`button`,{type:`button`,className:`witty-editor-switch-format`,"aria-disabled":`true`,"aria-describedby":`${e}-inklusivum`},KN(s,Px)),W.createElement(`span`,{id:`${e}-inklusivum`,className:`witty-options-muted`},` `,a(`switchInklusivum`)))),W.createElement(`p`,{className:`witty-editor-switch-result`,role:`status`,"aria-live":`polite`},c))},QN=e=>{let{t}=ky(eb.editor);switch(e.state){case`checking`:return{text:t(`statusChecking`),announce:``};case`idle`:{let n=e.alerts?t(`statusAlerts`,{count:e.alerts}):t(`statusNoAlerts`),r=e.limitReached?`${n}. ${t(`limitReached`)}`:n;return{text:r,announce:r}}case`unauthorized`:return{text:t(`statusUnauthorized`),announce:t(`statusUnauthorized`)};default:return{text:t(`statusFailed`),announce:t(`statusFailed`)}}},$N=()=>typeof matchMedia==`function`&&matchMedia(`(prefers-reduced-motion: reduce)`).matches,eP=({status:e})=>e.state===`checking`?$N()?W.createElement(RN,{"aria-hidden":`true`,style:{opacity:.5}}):W.createElement(uO,null):e.state===`idle`?W.createElement(RN,{"aria-hidden":`true`}):W.createElement(zN,{"aria-hidden":`true`}),tP=({editor:e,store:t,status:n,loadOptions:r,onSwitch:i,switchSupported:a})=>{let{t:o}=ky(eb.editor);HN(e);let{status:s,notice:c}=(0,W.useSyncExternalStore)(n.subscribe,n.get),l=QN(s),[u,d]=(0,W.useState)(0),[f,p]=(0,W.useState)(!1),[m,h]=(0,W.useState)(null),g=(0,W.useId)(),_=(0,W.useRef)([]),v=(0,W.useId)(),y=()=>e.chain().focus(),b=[{key:`bold`,label:o(`bold`),glyph:`B`,run:()=>y().toggleBold().run(),active:e.isActive(`bold`),enabled:e.can().toggleBold()},{key:`italic`,label:o(`italic`),glyph:`I`,run:()=>y().toggleItalic().run(),active:e.isActive(`italic`),enabled:e.can().toggleItalic()},{key:`underline`,label:o(`underline`),glyph:`U`,run:()=>y().toggleUnderline().run(),active:e.isActive(`underline`),enabled:e.can().toggleUnderline()},{key:`heading`,label:o(`heading`),glyph:`H`,run:()=>y().toggleHeading({level:2}).run(),active:e.isActive(`heading`,{level:2}),enabled:e.can().toggleHeading({level:2})},{key:`bulletList`,label:o(`bulletList`),glyph:`•`,run:()=>y().toggleBulletList().run(),active:e.isActive(`bulletList`),enabled:e.can().toggleBulletList()},{key:`orderedList`,label:o(`orderedList`),glyph:`1.`,run:()=>y().toggleOrderedList().run(),active:e.isActive(`orderedList`),enabled:e.can().toggleOrderedList()},{key:`quote`,label:o(`quote`),glyph:`❝`,run:()=>y().toggleBlockquote().run(),active:e.isActive(`blockquote`),enabled:e.can().toggleBlockquote()},{key:`undo`,label:o(`undo`),glyph:`↶`,run:()=>y().undo().run(),enabled:e.can().undo()},{key:`redo`,label:o(`redo`),glyph:`↷`,run:()=>y().redo().run(),enabled:e.can().redo()}],x=b.length+1,S=e=>{let t=(e+x)%x;d(t),_.current[t]?.focus()},C=e=>{let t={ArrowRight:u+1,ArrowLeft:u-1,Home:0,End:x-1};e.key in t&&(e.preventDefault(),S(t[e.key]))},w=()=>{_.current[x-1]?.focus()},T=()=>{h(null),w()},E=e=>{p(!1),h(e)},D=a(),O=[{key:`settings`,label:o(`menuSettings`),run:()=>E(`settings`)},{key:`switch`,label:o(`menuSwitchGender`),run:()=>E(`switch`),disabled:!D,note:D?void 0:o(`switchUnsupported`)},{key:`help`,label:o(`menuHelp`),href:BN},{key:`about`,label:o(`menuAbout`),href:VN}];return W.createElement(W.Fragment,null,W.createElement(`div`,{className:`witty-editor-toolbar`,role:`toolbar`,"aria-label":o(`toolbar`),onKeyDown:C},b.map((e,t)=>W.createElement(`button`,{key:e.key,ref:e=>{_.current[t]=e},type:`button`,className:`witty-editor-tool witty-editor-tool--${e.key}`,"aria-label":e.label,title:e.label,"aria-pressed":e.active,"aria-disabled":!e.enabled,tabIndex:t===u?0:-1,onFocus:()=>d(t),onMouseDown:e=>e.preventDefault(),onClick:()=>e.enabled&&e.run()},e.glyph)),W.createElement(`button`,{ref:e=>{_.current[x-1]=e},type:`button`,className:`witty-editor-tool witty-editor-tool--settings is-${s.state}`,"aria-label":o(`menu`),title:`${o(`menu`)} · ${l.text}`,"aria-haspopup":`menu`,"aria-expanded":f,"aria-controls":f?g:void 0,tabIndex:u===x-1?0:-1,onFocus:()=>d(x-1),onClick:()=>p(e=>!e),onKeyDown:e=>{e.key===`ArrowDown`&&(e.preventDefault(),e.stopPropagation(),p(!0))}},W.createElement(eP,{status:s})),f&&W.createElement(YN,{id:g,label:o(`menu`),items:O,anchor:()=>_.current[x-1],onClose:e=>{p(!1),e&&w()}})),W.createElement(`span`,{className:`witty-editor-sr-only`,role:`status`,"aria-live":`polite`},c??l.announce),m===`settings`&&W.createElement(JN,{id:v,store:t,loadOptions:r,onClose:T}),m===`switch`&&W.createElement(ZN,{id:v,store:t,loadOptions:r,onSwitch:i,onClose:T}))},nP=`
151
+ `)&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function gN(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
152
+ `));let n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){let i=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=i:n.push(i)}return n}function _N(e){return e==`.`||e==`!`||e==`?`}new class extends XM{tokenize(e){let t=[],n=0;for(let r=0;r<e.length;r++){if(r==e.length-1){t.push(e.slice(n));break}if(_N(e[r])&&e[r+1].match(/\s/)){for(t.push(e.slice(n,r+1)),r=n=r+1;e[r+1]?.match(/\s/);)r++;t.push(e.slice(n,r+1)),n=r+1}}return t}},new class extends XM{tokenize(e){return e.split(/([{}:;,]|\s+)/)}},new class extends XM{constructor(){super(...arguments),this.tokenize=gN}get useLongestToken(){return!0}castInput(e,t){let{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>t===void 0?n:t}=t;return typeof e==`string`?e:JSON.stringify(vN(e,null,null,r),null,` `)}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,`$1`),t.replace(/,([\r\n])/g,`$1`),n)}};function vN(e,t,n,r,i){t||=[],n||=[],r&&(e=r(i===void 0?``:i,e));let a=0;for(;a<t.length;a+=1)if(t[a]===e)return n[a];let o;if(Object.prototype.toString.call(e)===`[object Array]`){for(t.push(e),o=Array(e.length),n.push(o),a=0;a<e.length;a+=1)o[a]=vN(e[a],t,n,r,String(a));return t.pop(),n.pop(),o}if(e&&e.toJSON&&(e=e.toJSON()),typeof e==`object`&&e){t.push(e),o={},n.push(o);let i=[],s;for(s in e)Object.prototype.hasOwnProperty.call(e,s)&&i.push(s);for(i.sort(),a=0;a<i.length;a+=1)s=i[a],o[s]=vN(e[s],t,n,r,s);t.pop(),n.pop()}else o=e;return o}new class extends XM{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};var yN=e=>(new DOMParser().parseFromString(e,`text/html`).body.textContent??``).trim(),bN={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`},xN=e=>e.replace(/[&<>"']/g,e=>bN[e]),SN=(e,t,n)=>{let r=fN(t,n,{intlSegmenter:new Intl.Segmenter(e,{granularity:`word`})}),i,a=``,o=``,s=0,c=r.length-1;for(let e=0;e<r.length;e++)i=r[e],i.added||i.removed?(a===``?s=e:(a.endsWith(`</ins>`)||a.endsWith(`</del>`))&&(a+=` `),c=e,o=i.added?`ins`:`del`,i.value!==`undefined`&&(a+=`<${o}>${xN(i.value)}</${o}>`)):a!==``&&e<r.length-1&&(a+=xN(i.value));let l=120-yN(a).length;if(l>0){let e=``;if(s>0&&(e=r[0].value.substring(Math.max(0,r[0].value.length-Math.min(50,l)),r[0].value.length),e!=r[0].value&&(e=e.slice(e.indexOf(` `)),e=`...`+e),a=xN(e)+a),l-=e.length,c<r.length-1&&l){let e=r[r.length-1].value.substring(0,Math.min(50,l));e!=r[r.length-1].value&&(e=e.substring(0,e.lastIndexOf(` `)),e+=`...`),a+=xN(e)}}return a},CN=({analytics:e,element:t,data:n,prevData:r,hide:i,updateTextWithAlternative:a,addIgnoredTerm:o,movePopoverNextOrPrev:s,setLLMSuggestionsRequest:c,getLLMSuggestions:l,focusOnOpen:u,llmAlternativesEnabled:d,dashboardAvailable:f,ignoreTermPermanently:p,onAlternativeAccepted:m})=>{let h=document.documentElement||document.body,{t:g,i18n:_}=ky(eb.popover),{analytics:v,alternativeHovered:y,setAlternativeHovered:b,showLearningBite:x,setShowLearningBite:S,showLearningBiteRef:C,isLoading:w,isSuccess:T,isFailure:E,llmAlternativesResponse:D,hidePopover:O,clickAlternative:ee,alternativeKeyDown:te,handleIgnoreClick:ne,goToAdjacentAlert:re}=UC({analytics:e,element:t,data:n,prevData:r,hide:i,updateTextWithAlternative:a,addIgnoredTerm:o,movePopoverNextOrPrev:s,setLLMSuggestionsRequest:c,getLLMSuggestions:l,llmAlternativesEnabled:d,ignoreTermPermanently:p,onAlternativeAccepted:m});(0,W.useEffect)(()=>{_.changeLanguage(n.alert.data?.language)},[n.alert.data?.language]);let{x:k,y:A,strategy:ie,refs:ae}=RC({placement:`bottom-start`,middleware:[(e=>({name:`elementCords`,options:e,fn:({placement:n,rects:r})=>{let i={top:0,left:0,bottom:0,right:0};if(Fj(t)){let t=document.getElementsByTagName(`iframe`),n=Array.from(t).find(t=>{try{return(t.contentDocument||t.contentWindow?.document)?.contains(e.node)}catch(e){return console.error(`Failed to access iframe content: `,e),!1}});try{n?.getBoundingClientRect()&&(i=n?.getBoundingClientRect())}catch(e){console.error(`Failed to get iframe bounding rect: `,e)}}let a=e.position.x+i.left+h.scrollLeft,o=n.includes(`bottom`)?e.position.y+e.position.height+i.top+h.scrollTop:e.position.y-r.floating.height+i.top+h.scrollTop;return{x:C.current?a/2:a,y:o}}}))(n),VC(),zC(4),BC()]});(0,W.useEffect)(()=>{ae.setReference(t),C.current=x},[ae.setReference,x]),(0,W.useEffect)(()=>(Lj(t)?.addEventListener(`scroll`,oe),t?.addEventListener(`scroll`,oe),document?.addEventListener(`click`,se),document?.addEventListener(`input`,se),gO()?.addEventListener(`click`,se),gO()?.addEventListener(`input`,se),()=>{document.removeEventListener(`click`,se),document.removeEventListener(`input`,se),Lj(t)?.removeEventListener(`scroll`,oe),t.removeEventListener(`scroll`,oe),gO().removeEventListener(`click`,se),gO().removeEventListener(`input`,se)}),[ae.floating.current]),(0,W.useEffect)(()=>{u&&ae.floating.current?.focus()},[n.alert.id,u,ae.floating.current]),(0,W.useEffect)(()=>{let e=gO(),n=e=>{if(e.key!==`Escape`)return;e.preventDefault(),e.stopPropagation();let n=ae.floating.current?.contains(document.activeElement);O(!0),n&&t.focus?.()};return document.addEventListener(`keydown`,n,!0),e!==document&&e?.addEventListener(`keydown`,n,!0),()=>{document.removeEventListener(`keydown`,n,!0),e!==document&&e?.removeEventListener(`keydown`,n,!0)}},[ae.floating.current]);let oe=()=>{O()},se=e=>{let t=!ae.floating.current?.contains(e.target),r=gO().documentElement||gO().body,i=e.pageX+r.scrollLeft,a=e.pageY-r.scrollTop,o=i>=n.position.x&&i<=n.position.x+n.position.width&&a>=n.position.y&&a<=n.position.y+n.position.height;t&&!o&&O()},ce=e=>{let t=(e=!0)=>W.createElement(`div`,{key:`default-expl-${e?`visible`:`hidden`}`,style:{visibility:e?`visible`:`hidden`,gridArea:`1 / 1`}},n.alert.data?.explanation?.text,n.alert.data?.explanation?.context&&` (`+n.alert.data?.explanation?.context+`)`);if(!D||D.loading)return t(!0);let r=n.alert.data.alternatives.map((n,r)=>{let i=le(n);return W.createElement(`div`,{key:`explanation-${r}-${n.text||`alt`}`,style:{position:`relative`,top:0,gridArea:`1 / 1`,visibility:e&&e.text===n.text?`visible`:`hidden`}},i||t(!0))});return r.push(t(e===null)),r},le=e=>{let t=D?.data?.results?.get(e.text);if(!t){let r=n.alert.startOffset-n.alert.data.fullSentence.range[0],i=n.alert.endOffset-n.alert.data.fullSentence.range[0];t=n.alert.data.fullSentence.raw.substring(0,r)+e.text+n.alert.data.fullSentence.raw.substring(i)}return W.createElement(`div`,{dangerouslySetInnerHTML:{__html:SN(n.alert.data.language,n.alert.data.fullSentence.raw,t)}})},ue=e=>{if(e&&e.text===``)return W.createElement(`i`,null,g(`removeSpaces`));{let t=/\(\((.*?)\)\)/;if(RegExp(t).exec(e.text)){let n=e.text.split(t);return W.createElement(`span`,null,n[0],`\xA0`,`[`,W.createElement(`i`,null,n[1]),`]`,`\xA0`,n[2])}return e.text.length>25&&e.context?e.text.substring(0,25)+`...`:e.text.length>35?e.text.substring(0,35)+`...`:e.text}};return W.createElement(`div`,{id:`witty-works-ext-popover`,ref:ae.setFloating,role:`dialog`,"aria-label":g(`suggestionsDialog`),tabIndex:-1,style:{position:ie,top:`${A}px`,left:`${k}px`,maxWidth:`min(${x?850:350}px, calc(100vw - 16px))`},onMouseDown:e=>e.preventDefault()},W.createElement(`div`,{id:`witty-works-ext-popover-content`,className:`witty-works-ext-lato-popover-text`},W.createElement(`div`,{className:`witty-works-ext-section witty-works-ext-wittyworks-container witty-works-ext-container-row witty-works-ext-justify-space-between`},W.createElement(`a`,{className:`witty-works-ext-margin-right witty-works-ext-cursor-pointer`,href:`https://www.witty.works/`,target:`_blank`,rel:`noreferrer`,"aria-label":g(`wittyLogo`)},W.createElement(KC,{"aria-hidden":`true`})),W.createElement(`div`,{className:`witty-works-ext-container-row`},W.createElement(`button`,{className:`witty-works-ext-margin-right witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer witty-works-ext-margin-auto witty-works-button`,style:n.index===1?{display:`none`}:{},onClick:()=>{n.index!==1&&re(`previous`)},"aria-label":g(`previous`),title:g(`previous`)},W.createElement(JC,{alt:g(`previous`)})),W.createElement(`div`,{className:`witty-works-ext-margin-right witty-works-ext-lato-popover-text-gray witty-works-ext-margin-right`,role:`status`,"aria-live":`polite`,"aria-label":`${n.index} ${g(`alertOftotal`)} ${n.totalAlerts}`},`${n.index} ${g(`alertOftotal`)} ${n.totalAlerts}`),W.createElement(`button`,{className:`witty-works-ext-margin-right witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer witty-works-ext-margin-auto witty-works-button`,style:n.index===n.totalAlerts?{display:`none`}:{},onClick:()=>{n.index!==n.totalAlerts&&re(`next`)},"aria-label":g(`next`),title:g(`next`)},W.createElement(qC,{alt:g(`next`)}))),W.createElement(`button`,{className:`witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer witty-works-button`,onClick:()=>{O(!0)},"aria-label":g(`close`),title:g(`close`)},W.createElement(GC,{alt:g(`close`)}))),n.alert.data?.explanation?.text&&W.createElement(W.Fragment,null,W.createElement(`div`,{className:`witty-works-ext-separator`}),W.createElement(`div`,{className:`witty-works-ext-wittyworks-container witty-works-ext-container-rounded witty-works-ext-container-column witty-works-ext-full-padding witty-works-ext-justify-start witty-works-ext-margin-top`,style:{backgroundColor:ov(n.alert.data?.gravity,n.alert.data?.subcategory).default}},W.createElement(`div`,{className:`witty-works-ext-lato-popover-text witty-works-ext-justify-space-between`,style:{display:`flex`,flexDirection:x?`row`:`column`,alignItems:x?`center`:`flex-start`}},W.createElement(`div`,{className:`witty-works-ext-container-row witty-works-ext-justify-start`,style:{flex:1}},W.createElement(`div`,{style:{fontSize:`2em`,marginRight:`0.5em`,flexShrink:0,height:`100%`}},n.alert.data?.explanation?.icon_image?W.createElement(`img`,{src:n.alert.data?.explanation?.icon_image,alt:``,style:{width:`50px`}}):W.createElement(`span`,null,n.alert.data?.explanation?.icon)),W.createElement(`div`,{className:`witty-works-ext-rephrasing`,style:{flex:`0 1 252px`,minWidth:0,height:`100%`}},W.createElement(`b`,null,n.alert.data?.label.split(`:`).pop()),W.createElement(`br`,null),W.createElement(`div`,{style:{position:`relative`,display:`grid`}},ce(y)))),n.alert.data?.explanation?.url&&W.createElement(`div`,{className:`witty-works-ext-container-row witty-works-ext-justify-end witty-works-ext-lato-popover-text-gray witty-works-ext-cursor-pointer`,style:{marginTop:x?`0em`:`1em`}},W.createElement(`button`,{type:`button`,className:`witty-works-ext-dropdown-select witty-works-ext-container-row`,onClick:()=>{v.popoverLogs(n.alert,`learning_bites`),S(!x)},style:{cursor:n.alert.data?.explanation?.url?`pointer`:`default`},"aria-expanded":x,"aria-label":g(`leanrMoreExtendedText`),title:g(`leanrMoreExtendedText`)},g(`learnMore`),n.alert.data?.explanation?.content===`video`&&W.createElement(YC,{className:`witty-works-ext-margin-left`,style:{marginTop:`0.2em`},alt:g(`video`)}),W.createElement(`div`,{className:`witty-works-ext-margin-left`,style:{pointerEvents:`none`}},x?W.createElement(QC,null):W.createElement($C,null))),n.alert.data?.source?.url&&W.createElement(`a`,{className:`witty-works-ext-dropdown-select witty-works-ext-container-row`,href:n.alert.data.source.url,target:`_new`,"aria-label":g(`visitSource`),title:g(`visitSource`)},g(`visitSource`),W.createElement(ZC,{className:`witty-works-ext-margin-left`,alt:g(`openNewWindow`)})))))),W.createElement(`div`,{style:{display:x?`flex`:`none`}},W.createElement(`div`,{className:`witty-works-ext-learning-bite-dig-deeper`},W.createElement(`div`,null,W.createElement(`div`,null,YM(n.alert.data?.explanation?.long_text??``)),W.createElement(`div`,null,n.alert.data?.explanation?.url&&W.createElement(`a`,{className:`witty-works-dig-deeper witty-works-ext-container-row`,href:n.alert.data.explanation.url,target:`_new`,"aria-label":g(`leanrMoreExtendedText`),title:g(`leanrMoreExtendedText`)},g(`leanrMoreExtendedText`),W.createElement(XC,{className:`witty-works-ext-margin-left`,alt:g(`openNewWindow`)})))),n.alert.data?.explanation?.video_url&&W.createElement(`video`,{width:`500`,style:{maxWidth:`100%`},controls:!0},W.createElement(`source`,{src:n.alert.data?.explanation?.video_url,type:`video/mp4`}),`Your browser does not support the video tag.`),!n.alert.data?.explanation?.video_url&&n.alert.data?.explanation?.image_url&&W.createElement(`img`,{style:{width:`500px`,maxWidth:`100%`},src:n.alert.data?.explanation?.image_url?.src,alt:n.alert.data?.explanation?.image_url?.alt}))),W.createElement(`div`,{className:`witty-works-ext-separator`,style:{marginBottom:`1em`,marginTop:`1em`}}),n.alert.data?.alternatives?.length>0&&!x&&W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-row`},W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-btn-container`},g(`insteadTry`)),W.createElement(`div`,null,n.alert.data?.alternatives.map((e,t)=>e.remove?W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-btn-container`,onMouseEnter:()=>{b(e)},onMouseLeave:()=>{b(null)},key:`${t}-${e.text||`alt`}-container`},W.createElement(`button`,{type:`button`,className:`witty-works-ext-wittyworks-popover-alternative-btn witty-works-ext-lato-popover-text-green witty-works-ext-remove-text witty-works-ext-margin-right`,key:`${t}-${e.text||`alt`}-remove-it`,onPointerDown:e=>ee(e.nativeEvent,` `),onKeyDown:te(` `),"aria-label":`${g(`removeText`)} ${n.alert.data?.text}`,title:g(`removeText`)},n.alert.data?.text),e.context&&W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-context`},e.context)):W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-btn-container`,key:`${t}-${e.text||`alt`}-container`,onMouseEnter:()=>{b(e)},onMouseLeave:()=>{b(null)}},W.createElement(`button`,{type:`button`,className:`witty-works-ext-wittyworks-popover-alternative-btn witty-works-ext-lato-popover-text-green witty-works-ext-margin-right`,onPointerDown:e=>ee(e.nativeEvent,n.alert.data?.alternatives[t]?.text),onKeyDown:te(n.alert.data?.alternatives[t]?.text),"aria-label":n.alert.data?.alternatives[t]?.text,title:n.alert.data?.alternatives[t]?.text},ue(e)),e&&e.context&&W.createElement(`div`,{className:`witty-works-ext-wittyworks-popover-alternative-context`,style:{color:`black`}},e.url?W.createElement(W.Fragment,null,e.context.startsWith(`💡`)?W.createElement(W.Fragment,null,W.createElement(`span`,{style:{whiteSpace:`nowrap`}},W.createElement(`span`,null,e.context.substring(0,3)),W.createElement(`a`,{href:e.url,target:`_blank`,style:{textDecoration:`underline`,color:`black`},rel:`noopener noreferrer`,"aria-label":e.context,title:e.context},e.context.substring(3)))):W.createElement(`a`,{href:e.url,target:`_blank`,style:{textDecoration:`underline`,color:`black`,whiteSpace:`nowrap`},rel:`noopener noreferrer`,"aria-label":e.context,title:e.context},e.context)):W.createElement(`span`,{style:{color:`black`,whiteSpace:`nowrap`}},e.context))))))),!x&&W.createElement(`div`,{className:`witty-works-ext-container-row`},W.createElement(`button`,{onClick:ne(`ignore_once`),className:`witty-works-ext-ignore-section witty-works-ext-ignore-color-transformer witty-works-ext-margin-top witty-works-button`,"aria-label":g(`ignoreOnce`),title:g(`ignoreOnce`)},W.createElement(`span`,{className:`witty-works-ext-margin-right witty-works-ext-cursor-pointer`},W.createElement(mO,{alt:g(`ignoreOnce`)})),W.createElement(`span`,{className:`witty-works-ext-lato-popover-text-gray`},g(`ignoreOnce`))),f&&n?.alert?.data?.text.length<=50&&W.createElement(`button`,{onClick:ne(`ignore_permanently`),className:`witty-works-ext-ignore-section witty-works-ext-ignore-color-transformer witty-works-ext-margin-top witty-works-button`,"aria-label":g(`ignorePermanently`),title:g(`ignorePermanently`)},W.createElement(`span`,{className:`witty-works-ext-margin-right witty-works-ext-cursor-pointer`},W.createElement(mO,{alt:g(`ignorePermanently`)})),W.createElement(`span`,{className:`witty-works-ext-lato-popover-text-gray witty-works-ext-margin-right`},g(`ignorePermanently`)),w===`ignore_permanently`&&W.createElement(dO,null),T===`ignore_permanently`&&W.createElement(fO,null),E===`ignore_permanently`&&W.createElement(W.Fragment,null,W.createElement(pO,null),` `,W.createElement(`span`,{className:`witty-works-ext-margin-left`},g(`failedRequestText`))))))},wN=e=>{let t=0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);t=(t<<5)-t+r,t&=t}return t.toString()},TN=()=>({data:null,error:null,loading:!0}),EN=e=>`${wN(e.alert.data.fullSentence.raw)}::${e.alert.data.text}`,DN=(e,t)=>({data:e?{...e,results:new Map(Object.entries(e.results))}:null,error:t||null,loading:!1}),ON=(e,t,n,r)=>{let i=Cb(n,r),{from:a,to:o}=t;if(i.scope===`sentence`){let{detail:r}=t,s=r.data.fullSentence,c=t.from-(r.absOffset-s.range[0]),l=c+s.raw.length;c>=0&&l<=e.content.size&&e.textBetween(c,l)===s.raw?(a=c,o=l):i=Cb(n,null)}return n===` `&&a>0&&e.textBetween(a-1,a)===` `&&--a,{from:a,to:o,text:i.text}},kN={popoverLogs:()=>void 0,alternativeLog:()=>void 0,ignoreLog:()=>void 0},AN=class{view;options;container;root;openId=null;focusOnOpen=!1;prevData=null;llmCache=new Map;rewriteGeneration=0;destroyed=!1;constructor(e,t){this.view=e,this.options=t,this.container=document.createElement(`div`),this.container.className=`witty-editor-popover`,document.body.append(this.container),this.root=(0,Yx.createRoot)(this.container)}get isOpen(){return this.openId!==null}open(e,{viaKeyboard:t=!1}={}){this.destroyed||(this.focusOnOpen=t,this.openId=e,kx(this.view,e),this.render())}openAtSelection(){let{from:e}=this.view.state.selection,t=xx(this.view.state).find(t=>t.from<=e&&e<=t.to);return t?(this.open(t.id,{viaKeyboard:!0}),!0):!1}close(){this.openId!==null&&(this.openId=null,this.prevData=null,kx(this.view,null),this.root.render(null))}update(){if(this.openId!==null){if(!this.current()){this.close();return}this.render()}}resetRewrites(){this.llmCache.clear(),this.rewriteGeneration+=1}destroy(){this.destroyed=!0,this.openId=null,this.root.unmount(),this.container.remove()}current(){return xx(this.view.state).find(e=>e.id===this.openId)}render(){if(this.destroyed)return;let e=xx(this.view.state),t=e.findIndex(e=>e.id===this.openId),n=e[t];if(!n){this.close();return}let r=this.view.coordsAtPos(n.from),i=this.view.coordsAtPos(n.to),a={index:t+1,totalAlerts:e.length,alert:n.detail,position:new DOMRect(r.left,r.top,Math.max(i.right-r.left,1),r.bottom-r.top),node:this.view.domAtPos(n.from).node};this.root.render(W.createElement(CN,{analytics:kN,element:this.view.dom,data:a,prevData:this.prevData,hide:()=>this.close(),updateTextWithAlternative:e=>this.apply(n,e),addIgnoredTerm:e=>{this.options.ignored.add(e),Ax(this.view,e)},movePopoverNextOrPrev:e=>this.move(t,e),setLLMSuggestionsRequest:e=>this.requestRewrites(e),getLLMSuggestions:e=>this.llmCache.get(EN(e)),focusOnOpen:this.focusOnOpen,llmAlternativesEnabled:this.options.llmAlternatives(),dashboardAvailable:!1,ignoreTermPermanently:()=>Promise.reject(Error(`no dashboard to persist ignores to`)),onAlternativeAccepted:()=>void 0})),this.prevData=a}move(e,t){let n=xx(this.view.state)[e+(t===`previous`?-1:1)];n&&this.open(n.id,{viaKeyboard:this.focusOnOpen})}apply(e,t){this.close();let{state:n}=this.view,{from:r,to:i,text:a}=ON(n.doc,e,t,this.llmCache.get(EN({alert:e.detail}))?.data?.results),o=a?n.tr.insertText(a,r,i):n.tr.delete(r,i);this.view.dispatch(o.scrollIntoView()),this.view.focus()}rewriteBody(e){let t=mb(e.alert.data.fullSentence,e.alert),n=_b(e.alert.data.language,this.options.config());return n?{...t,gender_separator:n}:t}requestRewrites(e){let t=EN(e),n=this.llmCache.get(t);if(n&&!n.error)return;let r=this.rewriteGeneration;this.llmCache.set(t,TN()),this.render(),fetch(`${this.options.endpoint}${cb}`,{method:`POST`,headers:{...db,...this.options.headers()},body:JSON.stringify(this.rewriteBody(e)),signal:AbortSignal.timeout(this.options.llmTimeoutMs)}).then(async e=>{if(!e.ok)throw Error(`HTTP ${e.status}`);return DN(await e.json(),null)}).catch(e=>DN(null,{message:String(e)})).then(e=>{this.destroyed||r!==this.rewriteGeneration||(this.llmCache.set(t,e),this.openId!==null&&this.render())})}},jN=e=>{let t=e,n=new Set;return{get:()=>t,set(e){t={...t,...e},n.forEach(e=>e())},subscribe(e){return n.add(e),()=>{n.delete(e)}}}},MN=e=>jN(e),NN=e=>{let t={};for(let n of[`gendered_roles_format`,`german_gender_ending`,`french_gender_separator`]){let r=e[n];r&&(t[n]=r)}return t},PN=(e,t,n)=>{let r={...e};return n?r[t]=n:delete r[t],r},FN=(e,t,n)=>({...e,disabled_categories:rv(t.key,t.advanced_key,n,e.disabled_categories??[])}),IN=({categoryKey:e,label:t,value:n,hasAdvanced:r,locked:i=!1,onChange:a})=>{let{t:o}=ky(eb.options),s=[o(`levelOff`),o(`levelBasic`),o(`levelAdvanced`)][n];return W.createElement(`div`,{className:`witty-category`},W.createElement(`button`,{type:`button`,className:[`witty-category-toggle`,n>tv.Off?`is-on`:``,n===tv.Basic?`is-middle`:``,i?`is-locked`:``].filter(Boolean).join(` `),"data-category":e,"data-level":n,"aria-label":`${t}: ${s}`,"aria-disabled":i,title:i?o(`levelLocked`):s,onClick:()=>{i||a(n>=(r?tv.Advanced:tv.Basic)?tv.Off:n+1)}},W.createElement(`span`,{className:`witty-category-knob`})),W.createElement(`span`,{className:`witty-category-label`},t),W.createElement(`span`,{className:`witty-category-level`},s))},LN={gendered_roles_format:`genderedRolesFormat`,german_gender_ending:`germanGenderEnding`,french_gender_separator:`frenchGenderSeparator`},RN=({orthography:e,onOrthographyChange:t,llmAlternatives:n,onLlmAlternativesChange:r,configOptions:i,languageFormat:a,onFormatFieldChange:o,categories:s,categoryGroups:c,disabledCategories:l,onCategoryLevelChange:u,categoriesError:d=!1,idPrefix:f=``})=>{let{t:p}=ky(eb.options),m=(e,t)=>i[e]?.labels?.[t]||t;return W.createElement(W.Fragment,null,W.createElement(`section`,null,W.createElement(`h2`,null,p(`customisationHeadline`)),W.createElement(`p`,{className:`witty-options-muted`},p(`orgOverrideNote`)),W.createElement(`label`,null,W.createElement(`input`,{type:`checkbox`,id:`${f}opt-orthography`,checked:e,onChange:e=>t(e.target.checked)}),`\xA0`,p(`orthography`)),W.createElement(`label`,null,W.createElement(`input`,{type:`checkbox`,id:`${f}opt-llm-alternatives`,checked:n,onChange:e=>r(e.target.checked)}),`\xA0`,p(`llmAlternatives`))),Object.keys(i).length>0&&W.createElement(`section`,{id:`${f}language-format-section`},W.createElement(`h2`,null,p(`languageHeadline`)),W.createElement(`p`,{className:`witty-options-muted`},p(`orgOverrideNote`)),ev.filter(e=>i[e]).map(e=>{let t=i[e],n=LN[e];return W.createElement(`div`,{className:`witty-format-field`,key:e},W.createElement(`label`,{htmlFor:`${f}opt-${e}`},p(n)),W.createElement(`p`,{className:`witty-options-muted`},p(`${n}Hint`)),W.createElement(`select`,{id:`${f}opt-${e}`,"data-field":e,value:a[e]||``,onChange:t=>o(e,t.target.value)},W.createElement(`option`,{value:``},p(`useApiDefault`),t.default?` (${t.default})`:``),t.values.map(t=>W.createElement(`option`,{value:t,key:t},m(e,t)))))})),s.length>0&&W.createElement(`section`,{id:`${f}categories-section`},W.createElement(`h2`,null,p(`categoriesHeadline`)),W.createElement(`p`,{className:`witty-options-muted`},p(`categoriesIntro`)),c.map(e=>{let t=s.filter(t=>t.parent===e.key);return t.length?W.createElement(`div`,{className:`witty-category-group`,key:e.key},W.createElement(`h3`,null,e.label||e.key),t.map(e=>W.createElement(IN,{key:e.key,categoryKey:e.key,label:e.label||e.key,hasAdvanced:!!e.advanced_key,locked:e.proficiency_level===`openly_discriminating`,value:nv(e.key,e.advanced_key,l),onChange:t=>u(e,t)}))):null})),d&&W.createElement(`p`,{className:`witty-options-muted`},p(`categoriesFailed`)))},zN=e=>(0,G.jsxs)(`svg`,{width:25,height:21,viewBox:`0 0 25 21`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M14.4244 15.865C15.2179 17.3926 17.2257 17.3746 17.9964 15.833L16.5828 14.9778C16.4193 15.3047 15.9934 15.3086 15.8251 14.9846L14.4244 15.865Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.0406 13.2011L14.4244 15.865L15.8251 14.9846L14.4413 12.3206L13.0406 13.2011Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.3408 11.9904C12.954 12.2335 12.8196 12.7756 13.0406 13.2011L14.4413 12.3206C14.2203 11.8951 13.7276 11.7473 13.3408 11.9904Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 4.41595C10.7681 3.56076 10.0151 3 9.17787 3V4.7747C9.17787 4.7747 9.51518 4.89365 9.58114 5.07505L10.5101 7.62978C10.6755 8.0848 11.145 8.30612 11.5586 8.12411C11.9722 7.94211 12.1734 7.4257 12.008 6.97068L11.079 4.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 3H4.05053V4.7747H9.17787V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 3C2.49311 3 1.50583 4.83684 2.25638 6.33803L3.66995 5.48277C3.51074 5.16433 3.72017 4.7747 4.05053 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 14.8317L3.66995 5.48277L2.25638 6.33803L6.93059 15.687L8.34416 14.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 14.8151C8.95664 15.1596 8.51289 15.1692 8.34416 14.8317L6.93059 15.687C7.71306 17.252 9.75015 17.2339 10.519 15.687L9.11322 14.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 4.24516L9.11322 14.8151L10.519 15.687C10.5317 15.6613 10.5441 15.6353 10.5562 15.6088L15.3604 5.03882L13.9175 4.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M15.7489 3C14.9733 3 14.2643 3.48204 13.9175 4.24516L15.3604 5.03882C15.434 4.87695 15.5844 4.7747 15.7489 4.7747V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M20.9495 3H15.7489V4.7747H20.9495V3Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M22.7436 6.33803C23.4942 4.83684 22.5069 3 20.9495 3V4.7747C21.2798 4.7747 21.4893 5.16433 21.3301 5.48277L22.7436 6.33803Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M17.9964 15.833L22.7436 6.33803L21.3301 5.48277L16.5828 14.9778L17.9964 15.833Z`,fill:`#9489DB`})]}),BN=e=>(0,G.jsxs)(`svg`,{width:25,height:24,viewBox:`0 0 25 24`,fill:`none`,xmlns:`http://www.w3.org/2000/svg`,...e,children:[(0,G.jsx)(`path`,{d:`M14.4244 18.865C15.2179 20.3926 17.2257 20.3746 17.9964 18.833L16.5828 17.9778C16.4193 18.3047 15.9934 18.3086 15.8251 17.9846L14.4244 18.865Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.0406 16.2011L14.4244 18.865L15.8251 17.9846L14.4413 15.3206L13.0406 16.2011Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.3408 14.9904C12.954 15.2335 12.8196 15.7756 13.0406 16.2011L14.4413 15.3206C14.2203 14.8951 13.7276 14.7473 13.3408 14.9904Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M11.079 7.41595C10.7681 6.56076 10.0151 6 9.17787 6V7.7747C9.17787 7.7747 9.51518 7.89365 9.58114 8.07505L10.5101 10.6298C10.6755 11.0848 11.145 11.3061 11.5586 11.1241C11.9722 10.9421 12.1734 10.4257 12.008 9.97068L11.079 7.41595Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.17787 6H4.05053V7.7747H9.17787V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M4.05053 6C2.49311 6 1.50583 7.83684 2.25638 9.33803L3.66995 8.48277C3.51074 8.16433 3.72017 7.7747 4.05053 7.7747V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M8.34416 17.8317L3.66995 8.48277L2.25638 9.33803L6.93059 18.687L8.34416 17.8317Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M9.11322 17.8151C8.95664 18.1596 8.51289 18.1692 8.34416 17.8317L6.93059 18.687C7.71306 20.252 9.75014 20.2339 10.519 18.687L9.11322 17.8151Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M13.9175 7.24516L9.11322 17.8151L10.519 18.687C10.5317 18.6613 10.5441 18.6353 10.5562 18.6088L15.3604 8.03882L13.9175 7.24516Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M15.7489 6C14.9733 6 14.2643 6.48204 13.9175 7.24516L15.3604 8.03882C15.434 7.87695 15.5844 7.7747 15.7489 7.7747V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M20.9495 6H15.7489V7.7747H20.9495V6Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M22.7436 9.33803C23.4942 7.83684 22.5069 6 20.9495 6V7.7747C21.2798 7.7747 21.4893 8.16433 21.33 8.48277L22.7436 9.33803Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M17.9964 18.833L22.7436 9.33803L21.33 8.48277L16.5828 17.9778L17.9964 18.833Z`,fill:`#9489DB`}),(0,G.jsx)(`path`,{d:`M6.38 5.43V11.15C6.38 11.7633 6.34333 12.3733 6.27 12.98C6.19667 13.58 6.1 14.1933 5.98 14.82H3.88C3.76 14.1933 3.66333 13.58 3.59 12.98C3.51667 12.3733 3.48 11.7633 3.48 11.15V5.43H6.38ZM3.14 18.43C3.14 18.19 3.18333 17.9667 3.27 17.76C3.36333 17.5533 3.48667 17.3733 3.64 17.22C3.8 17.0667 3.98667 16.9467 4.2 16.86C4.41333 16.7667 4.64667 16.72 4.9 16.72C5.14667 16.72 5.37667 16.7667 5.59 16.86C5.80333 16.9467 5.99 17.0667 6.15 17.22C6.31 17.3733 6.43333 17.5533 6.52 17.76C6.61333 17.9667 6.66 18.19 6.66 18.43C6.66 18.67 6.61333 18.8967 6.52 19.11C6.43333 19.3167 6.31 19.4967 6.15 19.65C5.99 19.8033 5.80333 19.9233 5.59 20.01C5.37667 20.0967 5.14667 20.14 4.9 20.14C4.64667 20.14 4.41333 20.0967 4.2 20.01C3.98667 19.9233 3.8 19.8033 3.64 19.65C3.48667 19.4967 3.36333 19.3167 3.27 19.11C3.18333 18.8967 3.14 18.67 3.14 18.43Z`,fill:`#F06464`})]}),VN=`https://www.witty.works/en/help/how-do-i-use-the-witty-editor`,HN=`https://www.witty.works/`,UN=e=>{let t=(0,W.useRef)(0),n=(0,W.useCallback)(n=>{let r=()=>{t.current+=1,n()};return e.on(`transaction`,r),()=>{e.off(`transaction`,r)}},[e]);return(0,W.useSyncExternalStore)(n,()=>t.current)},WN=e=>(0,W.useSyncExternalStore)(e.subscribe,e.get),GN=async e=>{let t=async t=>{let n=await fetch(`${e.endpoint}${t}`,{headers:{...db,...e.headers()}});if(!n.ok)throw Error(String(n.status));return n.json()},n=navigator.language||`en-US`,[r,i]=await Promise.allSettled([t(ub(n)),t(`${lb}?locale=${encodeURIComponent(n.split(`-`)[0])}`).catch(()=>t(lb))]),a=r.status===`fulfilled`?r.value:void 0;return{categories:a?.categories||[],categoryGroups:a?.groups||[],categoriesError:!a,configOptions:i.status===`fulfilled`&&i.value.options||{}}},KN=e=>{let t;return()=>(t??=GN(e).then(e=>(e.categoriesError&&(t=void 0),e)),t)},qN=(e,t)=>e?.configOptions.german_gender_ending?.labels?.[t]||t,JN=e=>{let[t,n]=(0,W.useState)(null);return(0,W.useEffect)(()=>{let t=!0;return e().then(e=>{t&&n(e)}),()=>{t=!1}},[e]),t},YN=({id:e,store:t,loadOptions:n,onClose:r})=>{let{t:i}=ky(eb.editor),a=WN(t),o=JN(n),{config:s}=a;return W.createElement(`div`,{id:e,className:`witty-editor-settings witty-preferences`,role:`region`,"aria-label":i(`settings`),onKeyDown:e=>{e.key===`Escape`&&(e.stopPropagation(),r())}},W.createElement(`button`,{type:`button`,className:`witty-editor-settings-close`,"aria-label":i(`closeSettings`),title:i(`closeSettings`),onClick:r},`×`),!o&&W.createElement(`p`,{"aria-live":`polite`},i(`settingsLoading`)),W.createElement(RN,{idPrefix:`${e}-`,orthography:a.orthography,onOrthographyChange:e=>t.set({orthography:e}),llmAlternatives:a.llmAlternatives,onLlmAlternativesChange:e=>t.set({llmAlternatives:e}),configOptions:o?.configOptions??{},languageFormat:NN(s),onFormatFieldChange:(e,n)=>t.set({config:PN(s,e,n)}),categories:o?.categories??[],categoryGroups:o?.categoryGroups??[],disabledCategories:s.disabled_categories??[],onCategoryLevelChange:(e,n)=>t.set({config:FN(s,e,n)}),categoriesError:o?.categoriesError}))},XN=({id:e,label:t,items:n,anchor:r,onClose:i})=>{let a=(0,W.useRef)([]),[o,s]=(0,W.useState)(0);(0,W.useEffect)(()=>{a.current[0]?.focus()},[]);let c=e=>{let t=(e+n.length)%n.length;s(t),a.current[t]?.focus()};return W.createElement(`div`,{id:e,className:`witty-editor-menu`,role:`menu`,tabIndex:-1,"aria-label":t,onKeyDown:e=>{e.stopPropagation();let t=a.current.indexOf(document.activeElement),r=t<0?o:t,s={ArrowDown:r+1,ArrowUp:r-1,Home:0,End:n.length-1};e.key in s?(e.preventDefault(),c(s[e.key])):e.key===`Escape`?(e.preventDefault(),i(!0)):e.key===`Tab`&&i(!1)},onBlur:e=>{let t=e.relatedTarget;(!t||!e.currentTarget.contains(t)&&t!==r())&&i(!1)}},n.map((e,t)=>{let n={ref:e=>{a.current[t]=e},role:`menuitem`,tabIndex:t===o?0:-1,className:`witty-editor-menu-item`,onFocus:()=>s(t),onMouseDown:e=>e.preventDefault()};return W.createElement(`div`,{key:e.key,role:`none`},e.href?W.createElement(`a`,{...n,href:e.href,target:`_blank`,rel:`noopener noreferrer`,onClick:()=>i(!1)},e.label):W.createElement(`button`,{...n,type:`button`,"aria-disabled":e.disabled||void 0,onClick:()=>!e.disabled&&e.run?.()},e.label,e.note&&W.createElement(`span`,{className:`witty-editor-menu-note`},e.note)))}))},ZN=(e,t,n)=>{let r=qN(n,t.target),i={switched:e(`switched`,{count:t.count,format:r}),nothing:e(`switchNothing`,{format:r}),disabled:e(`switchDisabled`),unsupported:e(`switchUnsupported`),unavailable:e(`switchInklusivum`),forced:e(`switchForced`,{format:qN(n,t.applied??``)})}[t.outcome];return t.limitReached&&(t.outcome===`switched`||t.outcome===`nothing`)?`${i} ${e(`limitReached`)}`:i},QN=({id:e,store:t,loadOptions:n,onSwitch:r,onClose:i})=>{let{t:a}=ky(eb.editor),o=WN(t),s=JN(n),[c,l]=(0,W.useState)(``),[u,d]=(0,W.useState)(!1),f=o.config.german_gender_ending,p=e=>{d(!0),l(a(`switching`)),r(e).then(e=>l(ZN(a,e,s))).catch(()=>l(a(`statusFailed`))).finally(()=>d(!1))};return W.createElement(`div`,{id:e,className:`witty-editor-settings witty-editor-switch witty-preferences`,role:`region`,"aria-label":a(`switchTitle`),onKeyDown:e=>{e.key===`Escape`&&(e.stopPropagation(),i())}},W.createElement(`button`,{type:`button`,className:`witty-editor-settings-close`,"aria-label":a(`closeSettings`),title:a(`closeSettings`),onClick:i},`×`),W.createElement(`h2`,null,a(`switchTitle`)),W.createElement(`p`,{className:`witty-options-muted`},a(`switchIntro`)),W.createElement(`ul`,{className:`witty-editor-switch-formats`},Nx.map(e=>W.createElement(`li`,{key:e},W.createElement(`button`,{type:`button`,className:`witty-editor-switch-format`,"aria-disabled":u||void 0,"aria-current":e===f||void 0,onClick:()=>!u&&p(e)},qN(s,e),e===f&&` (${a(`switchCurrent`)})`))),W.createElement(`li`,null,W.createElement(`button`,{type:`button`,className:`witty-editor-switch-format`,"aria-disabled":`true`,"aria-describedby":`${e}-inklusivum`},qN(s,Px)),W.createElement(`span`,{id:`${e}-inklusivum`,className:`witty-options-muted`},` `,a(`switchInklusivum`)))),W.createElement(`p`,{className:`witty-editor-switch-result`,role:`status`,"aria-live":`polite`},c))},$N=e=>{let{t}=ky(eb.editor);switch(e.state){case`checking`:return{text:t(`statusChecking`),announce:``};case`idle`:{let n=e.alerts?t(`statusAlerts`,{count:e.alerts}):t(`statusNoAlerts`),r=e.limitReached?`${n}. ${t(`limitReached`)}`:n;return{text:r,announce:r}}case`unauthorized`:return{text:t(`statusUnauthorized`),announce:t(`statusUnauthorized`)};default:return{text:t(`statusFailed`),announce:t(`statusFailed`)}}},eP=()=>typeof matchMedia==`function`&&matchMedia(`(prefers-reduced-motion: reduce)`).matches,tP=({status:e})=>e.state===`checking`?eP()?W.createElement(zN,{"aria-hidden":`true`,style:{opacity:.5}}):W.createElement(dO,null):e.state===`idle`?W.createElement(zN,{"aria-hidden":`true`}):W.createElement(BN,{"aria-hidden":`true`}),nP=({editor:e,store:t,status:n,loadOptions:r,onSwitch:i,switchSupported:a})=>{let{t:o}=ky(eb.editor);UN(e);let{status:s,notice:c}=(0,W.useSyncExternalStore)(n.subscribe,n.get),l=$N(s),[u,d]=(0,W.useState)(0),[f,p]=(0,W.useState)(!1),[m,h]=(0,W.useState)(null),g=(0,W.useId)(),_=(0,W.useRef)([]),v=(0,W.useId)(),y=()=>e.chain().focus(),b=[{key:`bold`,label:o(`bold`),glyph:`B`,run:()=>y().toggleBold().run(),active:e.isActive(`bold`),enabled:e.can().toggleBold()},{key:`italic`,label:o(`italic`),glyph:`I`,run:()=>y().toggleItalic().run(),active:e.isActive(`italic`),enabled:e.can().toggleItalic()},{key:`underline`,label:o(`underline`),glyph:`U`,run:()=>y().toggleUnderline().run(),active:e.isActive(`underline`),enabled:e.can().toggleUnderline()},{key:`heading`,label:o(`heading`),glyph:`H`,run:()=>y().toggleHeading({level:2}).run(),active:e.isActive(`heading`,{level:2}),enabled:e.can().toggleHeading({level:2})},{key:`bulletList`,label:o(`bulletList`),glyph:`•`,run:()=>y().toggleBulletList().run(),active:e.isActive(`bulletList`),enabled:e.can().toggleBulletList()},{key:`orderedList`,label:o(`orderedList`),glyph:`1.`,run:()=>y().toggleOrderedList().run(),active:e.isActive(`orderedList`),enabled:e.can().toggleOrderedList()},{key:`quote`,label:o(`quote`),glyph:`❝`,run:()=>y().toggleBlockquote().run(),active:e.isActive(`blockquote`),enabled:e.can().toggleBlockquote()},{key:`undo`,label:o(`undo`),glyph:`↶`,run:()=>y().undo().run(),enabled:e.can().undo()},{key:`redo`,label:o(`redo`),glyph:`↷`,run:()=>y().redo().run(),enabled:e.can().redo()}],x=b.length+1,S=e=>{let t=(e+x)%x;d(t),_.current[t]?.focus()},C=e=>{let t={ArrowRight:u+1,ArrowLeft:u-1,Home:0,End:x-1};e.key in t&&(e.preventDefault(),S(t[e.key]))},w=()=>{_.current[x-1]?.focus()},T=()=>{h(null),w()},E=e=>{p(!1),h(e)},D=a(),O=[{key:`settings`,label:o(`menuSettings`),run:()=>E(`settings`)},{key:`switch`,label:o(`menuSwitchGender`),run:()=>E(`switch`),disabled:!D,note:D?void 0:o(`switchUnsupported`)},{key:`help`,label:o(`menuHelp`),href:VN},{key:`about`,label:o(`menuAbout`),href:HN}];return W.createElement(W.Fragment,null,W.createElement(`div`,{className:`witty-editor-toolbar`,role:`toolbar`,"aria-label":o(`toolbar`),onKeyDown:C},b.map((e,t)=>W.createElement(`button`,{key:e.key,ref:e=>{_.current[t]=e},type:`button`,className:`witty-editor-tool witty-editor-tool--${e.key}`,"aria-label":e.label,title:e.label,"aria-pressed":e.active,"aria-disabled":!e.enabled,tabIndex:t===u?0:-1,onFocus:()=>d(t),onMouseDown:e=>e.preventDefault(),onClick:()=>e.enabled&&e.run()},e.glyph)),W.createElement(`button`,{ref:e=>{_.current[x-1]=e},type:`button`,className:`witty-editor-tool witty-editor-tool--settings is-${s.state}`,"aria-label":o(`menu`),title:`${o(`menu`)} · ${l.text}`,"aria-haspopup":`menu`,"aria-expanded":f,"aria-controls":f?g:void 0,tabIndex:u===x-1?0:-1,onFocus:()=>d(x-1),onClick:()=>p(e=>!e),onKeyDown:e=>{e.key===`ArrowDown`&&(e.preventDefault(),e.stopPropagation(),p(!0))}},W.createElement(tP,{status:s})),f&&W.createElement(XN,{id:g,label:o(`menu`),items:O,anchor:()=>_.current[x-1],onClose:e=>{p(!1),e&&w()}})),W.createElement(`span`,{className:`witty-editor-sr-only`,role:`status`,"aria-live":`polite`},c??l.announce),m===`settings`&&W.createElement(YN,{id:v,store:t,loadOptions:r,onClose:T}),m===`switch`&&W.createElement(QN,{id:v,store:t,loadOptions:r,onSwitch:i,onClose:T}))},rP=`
153
153
  .witty-editor-toolbar {
154
154
  display: flex;
155
155
  flex-wrap: wrap;
@@ -245,5 +245,5 @@ Error generating stack: `+e.message+`
245
245
  font-size: 1.25rem;
246
246
  cursor: pointer;
247
247
  }
248
- `,rP=(e,t)=>{let n=(0,Jx.createRoot)(e);return n.render(W.createElement(tP,t)),{destroy:()=>n.unmount()}},iP=`wittyGenderFormatSwitch`,aP=()=>[`.witty-editor .ProseMirror { outline: none; min-height: 8rem; }`,`.witty-editor-limit { margin: 0.25rem 0 0; font-size: 0.875em; color: #595959; }`,`.witty-editor .ProseMirror:focus-visible { outline: 2px solid #55b8e9; outline-offset: 2px; border-radius: 2px; }`,`.witty-editor-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }`,nP,`.witty-alert { border-bottom: 2px solid transparent; cursor: pointer; }`,`.witty-alert--dotted { border-bottom-style: dotted; border-bottom-width: 3px; }`,`.witty-alert--selected { background-color: var(--witty-alert-fill); border-radius: 4px; }`,...Object.entries(iv).map(([e,t])=>`.witty-alert--${e} { border-bottom-color: ${t.hover}; --witty-alert-fill: ${t.highlight}33; }`)].join(`
249
- `),oP=`witty-editor-styles`,sP=()=>{if(document.getElementById(oP))return;let e=document.createElement(`style`);e.id=oP,e.textContent=aP(),document.head.append(e)},cP=e=>nf.create({name:`wittyPopoverTriggers`,addKeyboardShortcuts(){return{"Alt-Shift-w":()=>e()?.openAtSelection()??!1}},addProseMirrorPlugins(){return[new Gn({props:{handleClick:(t,n)=>{let r=xx(t.state).find(e=>e.from<=n&&n<e.to);return r&&setTimeout(()=>e()?.open(r.id)),!1}}})]}}),lP=0;return e.mount=(e,{endpoint:t=`${location.origin}/`,apiKey:n=``,lang:r=`auto`,config:i,content:a=``,toolbar:o=!0,onSettingsChange:s,label:c=`Text to check`,describedBy:l,maxRequestLength:u,maxTextLength:d,delay:f=500,llmAlternatives:p=!1,llmTimeoutMs:m=hb,onStatus:h}={})=>{ob(),sP(),e.classList.add(`witty-editor`);let g=n,_=jN({config:i??{},llmAlternatives:p,orthography:!0}),v=()=>fb({apiKey:g}),y=null,b=()=>y??_.get().config,x=`unknown`,S=bb({endpoint:t,headers:v,lang:r,config:b}),C=async(e,t)=>{let n=await S(e,t);return n.results?.some(e=>e.bulk===`gender_format`)&&(x=`yes`),n},w=new Set,T=()=>new Promise((e,t)=>{w.add({armed:!1,resolve:e,reject:t})}),E=document.createElement(`span`);E.id=`witty-editor-hint-${lP+=1}`,E.className=`witty-editor-sr-only`,E.textContent=ty.t(`shortcutHint`,{ns:eb.editor});let D=()=>({role:`textbox`,"aria-multiline":`true`,"aria-label":c,"aria-describedby":[E.id,l].filter(Boolean).join(` `),spellcheck:_.get().orthography?`false`:`true`}),O=document.createElement(`div`),ee=document.createElement(`div`),te=document.createElement(`p`);te.className=`witty-editor-limit`,te.hidden=!0,te.textContent=ty.t(`limitReached`,{ns:eb.editor}),e.append(...o?[O]:[],ee,te,E);let ne=AN({status:{state:`idle`,alerts:0,limitReached:!1},notice:null}),re=new Set,k={},A=new yf({element:ee,extensions:[J_,jx.configure({check:C,delay:f,maxRequestLength:u,maxTextLength:d,cacheScope:()=>JSON.stringify([b(),r,g]),isIgnored:e=>re.has(e.data.text),onError:e=>{let t=e instanceof vb&&(e.status===401||e.status===403)?{state:`unauthorized`}:{state:`error`,message:e instanceof Error?e.message:String(e)};ne.set({status:t}),h?.(t),w.forEach(t=>t.reject(e)),w.clear()}}),cP(()=>k.current)],content:a,editorProps:{attributes:D()},onTransaction:({editor:e,transaction:t})=>{k.current?.update();let n=t.getMeta(mx);if(n?.type===`start`&&(ne.set({status:{state:`checking`}}),w.forEach(e=>{e.armed=!0})),n?.type===`results`&&n.complete!==!1)for(let t of w)t.armed&&(t.resolve(bx(e.state)),w.delete(t));if(t.docChanged&&!t.getMeta(iP)&&ne.get().notice&&ne.set({notice:null}),t.docChanged||n?.type===`results`||n?.type===`dismiss`){let t={state:`idle`,alerts:xx(e.state).length,limitReached:bx(e.state)};(n?.type===`dismiss`||n?.type===`results`&&n.complete!==!1||n===void 0&&ne.get().status.state!==`checking`)&&(ne.set({status:t}),te.hidden=!t.limitReached),h?.(t)}}}),ie=new kN(A.view,{endpoint:t,headers:v,llmAlternatives:()=>_.get().llmAlternatives,llmTimeoutMs:m,ignored:re,config:()=>_.get().config});k.current=ie;let ae=_.get(),oe=_.subscribe(()=>{let e=_.get();(e.config!==ae.config||e.llmAlternatives!==ae.llmAlternatives)&&ie.resetRewrites(),e.config!==ae.config&&Ox(A.view),e.orthography!==ae.orthography&&A.setOptions({editorProps:{attributes:D()}}),ae=e}),se=GN({endpoint:t,headers:v}),ce=(e,t)=>ty.t(e,{ns:eb.editor,...t}),le=null,ue=async e=>{let t=e;if(!Nx.includes(t))return{outcome:`unavailable`,target:e,count:0,limitReached:!1};let n={..._.get().config,german_gender_ending:t};y=Ix(n,t).config;let r=T();_.set({config:n}),Ox(A.view);let i;try{i=await r}finally{y=null}let a=xx(A.state),o=Lx(a),s;if(o.length)A.view.dispatch(Rx(A.state,o).setMeta(iP,!0)),s={outcome:`switched`,target:e,count:o.length,limitReached:i};else{let t=Hx(A.state.doc.textContent,e,a);t===`unsupported`&&(x=`no`),s={outcome:t,target:e,count:0,limitReached:i}}Ox(A.view);let c=await se().catch(()=>null);return ne.set({notice:XN(ce,s,c)}),h?.({state:`idle`,alerts:xx(A.state).length,limitReached:bx(A.state),genderFormatSwitch:s}),s},de=e=>(le=(le??Promise.resolve()).catch(()=>void 0).then(()=>ue(e)),le),fe=o?rP(O,{editor:A,store:{..._,set:e=>{_.set(e),s?.(_.get())}},status:ne,loadOptions:se,onSwitch:async e=>{let t=await de(e);return s?.(_.get()),t},switchSupported:()=>x!==`no`}):void 0;return{editor:A,setApiKey(e){g=e,ie.resetRewrites(),Ox(A.view)},setConfig(e){_.set({config:e})},getText:()=>A.getText(),switchGenderFormat:de,getSettings:()=>{let e=_.get();return{...e,config:structuredClone(e.config)}},destroy:()=>{oe(),fe?.destroy(),ie.destroy(),A.destroy(),O.remove(),ee.remove(),E.remove(),te.remove()}}},e})({});
248
+ `,iP=(e,t)=>{let n=(0,Yx.createRoot)(e);return n.render(W.createElement(nP,t)),{destroy:()=>n.unmount()}},aP=`wittyGenderFormatSwitch`,oP=()=>[`.witty-editor .ProseMirror { outline: none; min-height: 8rem; }`,`.witty-editor-limit { margin: 0.25rem 0 0; font-size: 0.875em; color: #595959; }`,`.witty-editor .ProseMirror:focus-visible { outline: 2px solid #55b8e9; outline-offset: 2px; border-radius: 2px; }`,`.witty-editor-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }`,rP,`.witty-alert { border-bottom: 2px solid transparent; cursor: pointer; }`,`.witty-alert--dotted { border-bottom-style: dotted; border-bottom-width: 3px; }`,`.witty-alert--selected { background-color: var(--witty-alert-fill); border-radius: 4px; }`,...Object.entries(iv).map(([e,t])=>`.witty-alert--${e} { border-bottom-color: ${t.hover}; --witty-alert-fill: ${t.highlight}33; }`)].join(`
249
+ `),sP=`witty-editor-styles`,cP=()=>{if(document.getElementById(sP))return;let e=document.createElement(`style`);e.id=sP,e.textContent=oP(),document.head.append(e)},lP=e=>nf.create({name:`wittyPopoverTriggers`,addKeyboardShortcuts(){return{"Alt-Shift-w":()=>e()?.openAtSelection()??!1}},addProseMirrorPlugins(){return[new Gn({props:{handleClick:(t,n)=>{let r=xx(t.state).find(e=>e.from<=n&&n<e.to);return r&&setTimeout(()=>e()?.open(r.id)),!1}}})]}}),uP=0;return e.mount=(e,{endpoint:t=`${location.origin}/`,apiKey:n=``,lang:r=`auto`,config:i,content:a=``,toolbar:o=!0,onSettingsChange:s,label:c=`Text to check`,describedBy:l,maxRequestLength:u,maxTextLength:d,delay:f=500,llmAlternatives:p=!1,llmTimeoutMs:m=hb,onStatus:h}={})=>{ob(),cP(),e.classList.add(`witty-editor`);let g=n,_=MN({config:i??{},llmAlternatives:p,orthography:!0}),v=()=>fb({apiKey:g}),y=null,b=()=>y??_.get().config,x=null,S=`unknown`,C=bb({endpoint:t,headers:v,lang:r,config:b}),w=async(e,t)=>{let n=x,r=await C(e,t);return(r.bulk_actions||r.results?.some(e=>e.bulk===`gender_format`))&&(S=`yes`),n&&(n.bulkActions.push(r.bulk_actions),r.language?.startsWith(`de`)&&r.gender_separator&&n.separators.push(r.gender_separator)),r},T=new Set,E=()=>new Promise((e,t)=>{T.add({armed:!1,resolve:e,reject:t})}),D=document.createElement(`span`);D.id=`witty-editor-hint-${uP+=1}`,D.className=`witty-editor-sr-only`,D.textContent=ty.t(`shortcutHint`,{ns:eb.editor});let O=()=>({role:`textbox`,"aria-multiline":`true`,"aria-label":c,"aria-describedby":[D.id,l].filter(Boolean).join(` `),spellcheck:_.get().orthography?`false`:`true`}),ee=document.createElement(`div`),te=document.createElement(`div`),ne=document.createElement(`p`);ne.className=`witty-editor-limit`,ne.hidden=!0,ne.textContent=ty.t(`limitReached`,{ns:eb.editor}),e.append(...o?[ee]:[],te,ne,D);let re=jN({status:{state:`idle`,alerts:0,limitReached:!1},notice:null}),k=new Set,A={},ie=new yf({element:te,extensions:[J_,jx.configure({check:w,delay:f,maxRequestLength:u,maxTextLength:d,cacheScope:()=>JSON.stringify([b(),r,g]),isIgnored:e=>k.has(e.data.text),onError:e=>{let t=e instanceof vb&&(e.status===401||e.status===403)?{state:`unauthorized`}:{state:`error`,message:e instanceof Error?e.message:String(e)};re.set({status:t}),h?.(t),T.forEach(t=>t.reject(e)),T.clear()}}),lP(()=>A.current)],content:a,editorProps:{attributes:O()},onTransaction:({editor:e,transaction:t})=>{A.current?.update();let n=t.getMeta(mx);if(n?.type===`start`&&(re.set({status:{state:`checking`}}),T.forEach(e=>{e.armed=!0})),n?.type===`results`&&n.complete!==!1)for(let t of T)t.armed&&(t.resolve(bx(e.state)),T.delete(t));if(t.docChanged&&!t.getMeta(aP)&&re.get().notice&&re.set({notice:null}),t.docChanged||n?.type===`results`||n?.type===`dismiss`){let t={state:`idle`,alerts:xx(e.state).length,limitReached:bx(e.state)};(n?.type===`dismiss`||n?.type===`results`&&n.complete!==!1||n===void 0&&re.get().status.state!==`checking`)&&(re.set({status:t}),ne.hidden=!t.limitReached),h?.(t)}}}),ae=new AN(ie.view,{endpoint:t,headers:v,llmAlternatives:()=>_.get().llmAlternatives,llmTimeoutMs:m,ignored:k,config:()=>_.get().config});A.current=ae;let oe=_.get(),se=_.subscribe(()=>{let e=_.get();(e.config!==oe.config||e.llmAlternatives!==oe.llmAlternatives)&&ae.resetRewrites(),e.config!==oe.config&&Ox(ie.view),e.orthography!==oe.orthography&&ie.setOptions({editorProps:{attributes:O()}}),oe=e}),ce=KN({endpoint:t,headers:v}),le=(e,t)=>ty.t(e,{ns:eb.editor,...t}),ue=null,de=async e=>{let t=e;if(!Nx.includes(t))return{outcome:`unavailable`,target:e,count:0,limitReached:!1};let n=_.get().config,r={...n,german_gender_ending:t};y=Ix(r,t).config;let i={separators:[],bulkActions:[]};x=i;let a=E();_.set({config:r}),Ox(ie.view);let o;try{o=await a}finally{y=null,x=null}let s=Ux(i,e,ie.state.doc.textContent,xx(ie.state)),c;s.outcome===`switched`?(ie.view.dispatch(Rx(ie.state,s.apply).setMeta(aP,!0)),c={outcome:`switched`,target:e,count:s.apply.length,limitReached:o}):s.outcome===`forced`?(_.set({config:n}),c={outcome:`forced`,target:e,count:0,limitReached:o,applied:s.applied}):(s.outcome===`unsupported`&&(S=`no`),c={outcome:s.outcome,target:e,count:0,limitReached:o}),Ox(ie.view);let l=await ce().catch(()=>null);return re.set({notice:ZN(le,c,l)}),h?.({state:`idle`,alerts:xx(ie.state).length,limitReached:bx(ie.state),genderFormatSwitch:c}),c},fe=e=>(ue=(ue??Promise.resolve()).catch(()=>void 0).then(()=>de(e)),ue),pe=o?iP(ee,{editor:ie,store:{..._,set:e=>{_.set(e),s?.(_.get())}},status:re,loadOptions:ce,onSwitch:async e=>{let t=await fe(e);return s?.(_.get()),t},switchSupported:()=>S!==`no`}):void 0;return{editor:ie,setApiKey(e){g=e,ae.resetRewrites(),Ox(ie.view)},setConfig(e){_.set({config:e})},getText:()=>ie.getText(),switchGenderFormat:fe,getSettings:()=>{let e=_.get();return{...e,config:structuredClone(e.config)}},destroy:()=>{se(),pe?.destroy(),ae.destroy(),ie.destroy(),ee.remove(),te.remove(),D.remove(),ne.remove()}}},e})({});