layers-design-system 3.7.11 → 3.7.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{en-06380725.js → en-8a8c929d.js} +1 -1
- package/dist/{en-f6c5c2a1.cjs → en-af42a7cf.cjs} +1 -1
- package/dist/{es-a4248530.cjs → es-04ea6343.cjs} +1 -1
- package/dist/{es-beee3d41.js → es-3af1057f.js} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{main-4afbbabc.cjs → main-478d0159.cjs} +25 -25
- package/dist/{main-93ba59f1.js → main-8ff325d2.js} +2046 -2028
- package/dist/{pt-br-cff7d2a1.js → pt-br-58df94bc.js} +1 -1
- package/dist/{pt-br-01ab10ae.cjs → pt-br-d03dee39.cjs} +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -32,31 +32,31 @@ For more detail, please visit: ${a}
|
|
|
32
32
|
horizontal/vertical
|
|
33
33
|
`);const u=Math.max(0,t*r-c),d=Math.min(u,i*r),f=Math.max(0,(i+1)*r-c);switch(l===mb&&(s>=f-c&&s<=d+c?l=bs:l=ku),l){case hb:return d;case gb:return f;case ku:{const p=Math.round(f+(d-f)/2);return p<Math.ceil(c/2)?0:p>u+Math.floor(c/2)?u:p}case bs:default:return s>=f&&s<=d?s:s<f?f:d}},getStartIndexForOffset:({total:e,itemSize:t},r)=>Math.max(0,Math.min(e-1,Math.floor(r/t))),getStopIndexForStartIndex:({height:e,total:t,itemSize:r,layout:o,width:a},i,l)=>{const s=i*r,c=ws(o)?a:e,u=Math.ceil((c+l-s)/r);return Math.max(0,Math.min(t-1,i+u-1))},initCache(){},clearCache:!0,validateProps(){}}),sX="ElDynamicSizeList",Mi=(e,t,r)=>{const{itemSize:o}=e,{items:a,lastVisitedIndex:i}=r;if(t>i){let l=0;if(i>=0){const s=a[i];l=s.offset+s.size}for(let s=i+1;s<=t;s++){const c=o(s);a[s]={offset:l,size:c},l+=c}r.lastVisitedIndex=t}return a[t]},cX=(e,t,r)=>{const{items:o,lastVisitedIndex:a}=t;return(a>0?o[a].offset:0)>=r?Eb(e,t,0,a,r):uX(e,t,Math.max(0,a),r)},Eb=(e,t,r,o,a)=>{for(;r<=o;){const i=r+Math.floor((o-r)/2),l=Mi(e,i,t).offset;if(l===a)return i;l<a?r=i+1:l>a&&(o=i-1)}return Math.max(0,r-1)},uX=(e,t,r,o)=>{const{total:a}=e;let i=1;for(;r<a&&Mi(e,r,t).offset<o;)r+=i,i*=2;return Eb(e,t,Math.floor(r/2),Math.min(r,a-1),o)},Tg=({total:e},{items:t,estimatedItemSize:r,lastVisitedIndex:o})=>{let a=0;if(o>=e&&(o=e-1),o>=0){const s=t[o];a=s.offset+s.size}const l=(e-o-1)*r;return a+l},dX=Cb({name:"ElDynamicSizeList",getItemOffset:(e,t,r)=>Mi(e,t,r).offset,getItemSize:(e,t,{items:r})=>r[t].size,getEstimatedTotalSize:Tg,getOffset:(e,t,r,o,a)=>{const{height:i,layout:l,width:s}=e,c=ws(l)?s:i,u=Mi(e,t,a),d=Tg(e,a),f=Math.max(0,Math.min(d-c,u.offset)),p=Math.max(0,u.offset-c+u.size);switch(r===mb&&(o>=p-c&&o<=f+c?r=bs:r=ku),r){case hb:return f;case gb:return p;case ku:return Math.round(p+(f-p)/2);case bs:default:return o>=p&&o<=f?o:o<p?p:f}},getStartIndexForOffset:(e,t,r)=>cX(e,r,t),getStopIndexForStartIndex:(e,t,r,o)=>{const{height:a,total:i,layout:l,width:s}=e,c=ws(l)?s:a,u=Mi(e,t,o),d=r+c;let f=u.offset+u.size,p=t;for(;p<i-1&&f<d;)p++,f+=Mi(e,p,o).size;return p},initCache({estimatedItemSize:e=ZZ},t){const r={items:{},estimatedItemSize:e,lastVisitedIndex:-1};return r.clearCacheAfterIndex=(o,a=!0)=>{var i,l;r.lastVisitedIndex=Math.min(r.lastVisitedIndex,o-1),(i=t.exposed)==null||i.getItemStyleCache(-1),a&&((l=t.proxy)==null||l.$forceUpdate())},r},clearCache:!1,validateProps:({itemSize:e})=>{process.env.NODE_ENV!=="production"&&typeof e!="function"&&gn(sX,`
|
|
34
34
|
itemSize is required as function, but the given value was ${typeof e}
|
|
35
|
-
`)}}),fX={loading:Boolean,data:{type:Array,required:!0},hoveringIndex:Number,width:Number,id:String,ariaLabel:String};var pX=n.defineComponent({name:"ElSelectDropdown",props:fX,setup(e,{slots:t,expose:r}){const o=n.inject(Ch),a=he("select"),{getLabel:i,getValue:l,getDisabled:s}=Qs(o.props),c=n.ref([]),u=n.ref(),d=n.computed(()=>e.data.length);n.watch(()=>d.value,()=>{var _,j;(j=(_=o.tooltipRef.value)==null?void 0:_.updatePopper)==null||j.call(_)});const f=n.computed(()=>Rt(o.props.estimatedOptionHeight)),p=n.computed(()=>f.value?{itemSize:o.props.itemHeight}:{estimatedSize:o.props.estimatedOptionHeight,itemSize:_=>c.value[_]}),h=(_=[],j)=>{const{props:{valueKey:R}}=o;return ft(j)?_&&_.some(P=>n.toRaw(jt(P,R))===jt(j,R)):_.includes(j)},m=(_,j)=>{if(ft(j)){const{valueKey:R}=o.props;return jt(_,R)===jt(j,R)}else return _===j},g=(_,j)=>o.props.multiple?h(_,l(j)):m(_,l(j)),v=(_,j)=>{const{disabled:R,multiple:P,multipleLimit:$}=o.props;return R||!j&&(P?$>0&&_.length>=$:!1)},y=_=>e.hoveringIndex===_;r({listRef:u,isSized:f,isItemDisabled:v,isItemHovering:y,isItemSelected:g,scrollToItem:_=>{const j=u.value;j&&j.scrollToItem(_)},resetScrollTop:()=>{const _=u.value;_&&_.resetScrollTop()}});const k=_=>{const{index:j,data:R,style:P}=_,$=n.unref(f),{itemSize:V,estimatedSize:D}=n.unref(p),{modelValue:x}=o.props,{onSelect:S,onHover:L}=o,B=R[j];if(B.type==="Group")return n.createVNode(VZ,{item:B,style:P,height:$?V:D},null);const F=g(x,B),T=v(x,F),z=y(j);return n.createVNode(WZ,n.mergeProps(_,{selected:F,disabled:s(B)||T,created:!!B.created,hovering:z,item:B,onSelect:S,onHover:L}),{default:I=>{var Z;return((Z=t.default)==null?void 0:Z.call(t,I))||n.createVNode("span",null,[i(B)])}})},{onKeyboardNavigate:w,onKeyboardSelect:C}=o,E=()=>{w("forward")},A=()=>{w("backward")},O=_=>{const j=Lt(_),{tab:R,esc:P,down:$,up:V,enter:D,numpadEnter:x}=ve;switch([P,$,V,D,x].includes(j)&&(_.preventDefault(),_.stopPropagation()),j){case R:case P:break;case $:E();break;case V:A();break;case D:case x:C();break}};return()=>{var _,j,R,P;const{data:$,width:V}=e,{height:D,multiple:x,scrollbarAlwaysOn:S}=o.props,L=n.computed(()=>fu?!0:S),B=n.unref(f)?lX:dX;return n.createVNode("div",{class:[a.b("dropdown"),a.is("multiple",x)],style:{width:`${V}px`}},[(_=t.header)==null?void 0:_.call(t),((j=t.loading)==null?void 0:j.call(t))||((R=t.empty)==null?void 0:R.call(t))||n.createVNode(B,n.mergeProps({ref:u},n.unref(p),{className:a.be("dropdown","list"),scrollbarAlwaysOn:L.value,data:$,height:D,width:V,total:$.length,innerElement:"ul",innerProps:{id:e.id,role:"listbox","aria-label":e.ariaLabel,"aria-orientation":"vertical"},onKeydown:O}),{default:F=>n.createVNode(k,F,null)}),(P=t.footer)==null?void 0:P.call(t)])}}});function mX(e,t){const{aliasProps:r,getLabel:o,getValue:a}=Qs(e),i=n.ref(0),l=n.ref(),s=n.computed(()=>e.allowCreate&&e.filterable);n.watch(()=>e.options,h=>{const m=new Set(h.map(g=>o(g)));t.createdOptions=t.createdOptions.filter(g=>!m.has(o(g)))});function c(h){const m=g=>o(g)===h;return e.options&&e.options.some(m)||t.createdOptions.some(m)}function u(h){s.value&&(e.multiple&&h.created?i.value++:l.value=h)}function d(h){if(s.value)if(h&&h.length>0){if(c(h)){t.createdOptions=t.createdOptions.filter(g=>o(g)!==t.previousQuery);return}const m={[r.value.value]:h,[r.value.label]:h,created:!0,[r.value.disabled]:!1};t.createdOptions.length>=i.value?t.createdOptions[i.value]=m:t.createdOptions.push(m)}else if(e.multiple)t.createdOptions.length=i.value;else{const m=l.value;t.createdOptions.length=0,m&&m.created&&t.createdOptions.push(m)}}function f(h){if(!s.value||!h||!h.created||h.created&&e.reserveKeyword&&t.inputValue===o(h))return;const m=t.createdOptions.findIndex(g=>a(g)===a(h));~m&&(t.createdOptions.splice(m,1),i.value--)}function p(){s.value&&(t.createdOptions.length=0,i.value=0)}return{createNewOption:d,removeNewOption:f,selectNewOption:u,clearAllNewOption:p}}const hX=(e,t)=>{const{t:r}=Nt(),o=n.useSlots(),a=he("select"),i=he("input"),{form:l,formItem:s}=Kn(),{inputId:c}=io(e,{formItemContext:s}),{aliasProps:u,getLabel:d,getValue:f,getDisabled:p,getOptions:h}=Qs(e),{valueOnClear:m,isEmptyValue:g}=zm(e),v=n.reactive({inputValue:"",cachedOptions:[],createdOptions:[],hoveringIndex:-1,inputHovering:!1,selectionWidth:0,collapseItemWidth:0,previousQuery:null,previousValue:void 0,selectedLabel:"",menuVisibleOnFocus:!1,isBeforeHide:!1}),y=n.ref(-1),N=n.ref(!1),b=n.ref(),M=n.ref(),k=n.ref(),w=n.ref(),C=n.ref(),E=n.ref(),A=n.ref(),O=n.ref(),_=n.ref(),j=n.ref(),{isComposing:R,handleCompositionStart:P,handleCompositionEnd:$,handleCompositionUpdate:V}=rh({afterComposition:ee=>ie(ee)}),D=Bt(),{wrapperRef:x,isFocused:S,handleBlur:L}=Ys(C,{disabled:D,afterFocus(){e.automaticDropdown&&!z.value&&(z.value=!0,v.menuVisibleOnFocus=!0)},beforeBlur(ee){var me,Te;return((me=k.value)==null?void 0:me.isFocusInsideContent(ee))||((Te=w.value)==null?void 0:Te.isFocusInsideContent(ee))},afterBlur(){var ee;z.value=!1,v.menuVisibleOnFocus=!1,e.validateEvent&&((ee=s==null?void 0:s.validate)==null||ee.call(s,"blur").catch(me=>He(me)))}}),B=n.computed(()=>Ye("")),F=n.computed(()=>e.loading?!1:e.options.length>0||v.createdOptions.length>0),T=n.ref([]),z=n.ref(!1),I=n.computed(()=>{var ee;return(ee=l==null?void 0:l.statusIcon)!=null?ee:!1}),Z=n.computed(()=>{const ee=T.value.length*e.itemHeight;return ee>e.height?e.height:ee}),q=n.computed(()=>e.multiple?De(e.modelValue)&&e.modelValue.length>0:!g(e.modelValue)),te=n.computed(()=>e.clearable&&!D.value&&q.value&&(S.value||v.inputHovering)),J=n.computed(()=>e.remote&&e.filterable&&!e.remoteShowSuffix?"":e.suffixIcon),W=n.computed(()=>J.value&&a.is("reverse",z.value)),ae=n.computed(()=>(s==null?void 0:s.validateState)||""),ce=n.computed(()=>{if(ae.value)return Ym[ae.value]}),ye=n.computed(()=>e.remote?e.debounce:0),Ae=n.computed(()=>e.remote&&!v.inputValue&&!F.value),Fe=n.computed(()=>e.loading?e.loadingText||r("el.select.loading"):e.filterable&&v.inputValue&&F.value&&T.value.length===0?e.noMatchText||r("el.select.noMatch"):F.value?null:e.noDataText||r("el.select.noData")),_e=n.computed(()=>e.filterable&&at(e.filterMethod)),Le=n.computed(()=>e.filterable&&e.remote&&at(e.remoteMethod)),Ye=ee=>{const me=new RegExp(M6(ee),"i"),Te=Oe=>_e.value||Le.value?!0:ee?me.test(d(Oe)||""):!0;return e.loading?[]:[...v.createdOptions,...e.options].reduce((Oe,Vt)=>{const Zn=h(Vt);if(De(Zn)){const yl=Zn.filter(Te);yl.length>0&&Oe.push({label:d(Vt),type:"Group"},...yl)}else(e.remote||Te(Vt))&&Oe.push(Vt);return Oe},[])},Ke=()=>{T.value=Ye(v.inputValue)},Be=n.computed(()=>{const ee=new Map;return B.value.forEach((me,Te)=>{ee.set(de(f(me)),{option:me,index:Te})}),ee}),et=n.computed(()=>{const ee=new Map;return T.value.forEach((me,Te)=>{ee.set(de(f(me)),{option:me,index:Te})}),ee}),lt=n.computed(()=>T.value.every(ee=>p(ee))),je=mn(),H=n.computed(()=>je.value==="small"?"small":"default"),G=()=>{var ee;if(Ve(e.fitInputWidth)){y.value=e.fitInputWidth;return}const me=((ee=b.value)==null?void 0:ee.offsetWidth)||200;!e.fitInputWidth&&F.value?n.nextTick(()=>{y.value=Math.max(me,ze())}):y.value=me},ze=()=>{var ee,me;const Oe=document.createElement("canvas").getContext("2d"),Vt=a.be("dropdown","item"),yl=(((me=(ee=O.value)==null?void 0:ee.listRef)==null?void 0:me.innerRef)||document).querySelector(`.${Vt}`);if(yl===null||Oe===null)return 0;const oc=getComputedStyle(yl),YN=Number.parseFloat(oc.paddingLeft)+Number.parseFloat(oc.paddingRight);return Oe.font=`bold ${oc.font.replace(new RegExp(`\\b${oc.fontWeight}\\b`),"")}`,T.value.reduce((QN,WN)=>{const qN=Oe.measureText(d(WN));return Math.max(qN.width,QN)},0)+YN},pe=()=>{if(!M.value)return 0;const ee=window.getComputedStyle(M.value);return Number.parseFloat(ee.gap||"6px")},we=n.computed(()=>{const ee=pe(),me=e.filterable?ee+fh:0;return{maxWidth:`${j.value&&e.maxCollapseTags===1?v.selectionWidth-v.collapseItemWidth-ee-me:v.selectionWidth-me}px`}}),be=n.computed(()=>({maxWidth:`${v.selectionWidth}px`})),ct=n.computed(()=>De(e.modelValue)?e.modelValue.length===0&&!v.inputValue:e.filterable?!v.inputValue:!0),kt=n.computed(()=>{var ee;const me=(ee=e.placeholder)!=null?ee:r("el.select.placeholder");return e.multiple||!q.value?me:v.selectedLabel}),At=n.computed(()=>{var ee,me;return(me=(ee=k.value)==null?void 0:ee.popperRef)==null?void 0:me.contentRef}),Ut=n.computed(()=>{if(e.multiple){const ee=e.modelValue.length;if(ee>0&&et.value.has(e.modelValue[ee-1])){const{index:me}=et.value.get(e.modelValue[ee-1]);return me}}else if(!g(e.modelValue)&&et.value.has(e.modelValue)){const{index:ee}=et.value.get(e.modelValue);return ee}return-1}),ne=n.computed({get(){return z.value&&(e.loading||!Ae.value||e.remote&&!!o.empty)&&(!N.value||!$d(v.previousQuery))},set(ee){z.value=ee}}),Q=n.computed(()=>e.multiple?e.collapseTags?v.cachedOptions.slice(0,e.maxCollapseTags):v.cachedOptions:[]),oe=n.computed(()=>e.multiple?e.collapseTags?v.cachedOptions.slice(e.maxCollapseTags):[]:[]),{createNewOption:Y,removeNewOption:le,selectNewOption:Ne,clearAllNewOption:Ue}=mX(e,v),ut=ee=>{var me;D.value||e.filterable&&z.value&&ee&&!((me=A.value)!=null&&me.contains(ee.target))||(v.menuVisibleOnFocus?v.menuVisibleOnFocus=!1:z.value=!z.value)},rt=()=>{v.inputValue.length>0&&!z.value&&(z.value=!0),Y(v.inputValue),n.nextTick(()=>{qt(v.inputValue)})},Ct=Im(()=>{rt(),N.value=!1},ye),qt=ee=>{v.previousQuery===ee||R.value||(v.previousQuery=ee,e.filterable&&at(e.filterMethod)?e.filterMethod(ee):e.filterable&&e.remote&&at(e.remoteMethod)&&e.remoteMethod(ee),e.defaultFirstOption&&(e.filterable||e.remote)&&T.value.length?n.nextTick(cn):n.nextTick(U))},cn=()=>{const ee=T.value.filter(Oe=>!Oe.disabled&&Oe.type!=="Group"),me=ee.find(Oe=>Oe.created),Te=ee[0];v.hoveringIndex=se(T.value,me||Te)},_t=ee=>{Yt(e.modelValue,ee)||t(st,ee)},Qe=ee=>{t($e,ee),_t(ee),v.previousValue=e.multiple?String(ee):ee,n.nextTick(()=>{if(e.multiple&&De(e.modelValue)){const me=v.cachedOptions.slice(),Te=e.modelValue.map(Oe=>pt(Oe,me));Yt(v.cachedOptions,Te)||(v.cachedOptions=Te)}else Mr(!0)})},se=(ee=[],me)=>{if(!ft(me))return ee.indexOf(me);const Te=e.valueKey;let Oe=-1;return ee.some((Vt,Zn)=>jt(Vt,Te)===jt(me,Te)?(Oe=Zn,!0):!1),Oe},de=ee=>ft(ee)?jt(ee,e.valueKey):ee,Ce=()=>{G()},Ht=()=>{v.selectionWidth=Number.parseFloat(window.getComputedStyle(M.value).width)},Jn=()=>{v.collapseItemWidth=j.value.getBoundingClientRect().width},Ot=()=>{var ee,me;(me=(ee=k.value)==null?void 0:ee.updatePopper)==null||me.call(ee)},To=()=>{var ee,me;(me=(ee=w.value)==null?void 0:ee.updatePopper)==null||me.call(ee)},Pr=ee=>{const me=f(ee);if(e.multiple){let Te=e.modelValue.slice();const Oe=se(Te,me);Oe>-1?(Te=[...Te.slice(0,Oe),...Te.slice(Oe+1)],v.cachedOptions.splice(Oe,1),le(ee)):(e.multipleLimit<=0||Te.length<e.multipleLimit)&&(Te=[...Te,me],v.cachedOptions.push(ee),Ne(ee)),Qe(Te),ee.created&&qt(""),e.filterable&&!e.reserveKeyword&&(v.inputValue="")}else v.selectedLabel=d(ee),!Yt(e.modelValue,me)&&Qe(me),z.value=!1,Ne(ee),ee.created||Ue();yr()},da=(ee,me)=>{let Te=e.modelValue.slice();const Oe=se(Te,f(me));Oe>-1&&!D.value&&(Te=[...e.modelValue.slice(0,Oe),...e.modelValue.slice(Oe+1)],v.cachedOptions.splice(Oe,1),Qe(Te),t("remove-tag",f(me)),le(me)),ee.stopPropagation(),yr()},yr=()=>{var ee;(ee=C.value)==null||ee.focus()},lo=()=>{var ee;if(z.value){z.value=!1,n.nextTick(()=>{var me;return(me=C.value)==null?void 0:me.blur()});return}(ee=C.value)==null||ee.blur()},Bn=()=>{v.inputValue.length>0?v.inputValue="":z.value=!1},ei=ee=>Jy(ee,me=>!v.cachedOptions.some(Te=>f(Te)===me&&p(Te))),ti=ee=>{const me=Lt(ee);if(e.multiple&&me!==ve.delete&&v.inputValue.length===0){ee.preventDefault();const Te=e.modelValue.slice(),Oe=ei(Te);if(Oe<0)return;const Vt=Te[Oe];Te.splice(Oe,1);const Zn=v.cachedOptions[Oe];v.cachedOptions.splice(Oe,1),le(Zn),Qe(Te),t("remove-tag",Vt)}},ni=()=>{let ee;De(e.modelValue)?ee=[]:ee=m.value,v.selectedLabel="",z.value=!1,Qe(ee),t("clear"),Ue(),yr()},Rr=(ee,me=void 0)=>{const Te=T.value;if(!["forward","backward"].includes(ee)||D.value||Te.length<=0||lt.value||R.value)return;if(!z.value)return ut();Rt(me)&&(me=v.hoveringIndex);let Oe=-1;ee==="forward"?(Oe=me+1,Oe>=Te.length&&(Oe=0)):ee==="backward"&&(Oe=me-1,(Oe<0||Oe>=Te.length)&&(Oe=Te.length-1));const Vt=Te[Oe];if(p(Vt)||Vt.type==="Group")return Rr(ee,Oe);v.hoveringIndex=Oe,ot(Oe)},X=()=>{if(z.value)~v.hoveringIndex&&T.value[v.hoveringIndex]&&Pr(T.value[v.hoveringIndex]);else return ut()},re=ee=>{v.hoveringIndex=ee??-1},U=()=>{if(!e.multiple)v.hoveringIndex=T.value.findIndex(ee=>de(f(ee))===de(e.modelValue));else{const ee=e.modelValue.length;if(ee>0){const me=e.modelValue[ee-1];v.hoveringIndex=T.value.findIndex(Te=>de(me)===de(f(Te)))}else v.hoveringIndex=-1}},ie=ee=>{if(v.inputValue=ee.target.value,e.remote)N.value=!0,Ct();else return rt()},ue=ee=>{if(z.value=!1,S.value){const me=new FocusEvent("blur",ee);L(me)}},Re=()=>(v.isBeforeHide=!1,n.nextTick(()=>{~Ut.value&&ot(Ut.value)})),ot=ee=>{O.value.scrollToItem(ee)},pt=(ee,me)=>{const Te=de(ee);if(Be.value.has(Te)){const{option:Oe}=Be.value.get(Te);return Oe}if(me&&me.length){const Oe=me.find(Vt=>de(f(Vt))===Te);if(Oe)return Oe}return{[u.value.value]:ee,[u.value.label]:ee}},mt=ee=>{var me,Te;return(Te=(me=Be.value.get(f(ee)))==null?void 0:me.index)!=null?Te:-1},Mr=(ee=!1)=>{if(e.multiple)if(e.modelValue.length>0){const me=v.cachedOptions.slice();v.cachedOptions.length=0,v.previousValue=e.modelValue.toString();for(const Te of e.modelValue){const Oe=pt(Te,me);v.cachedOptions.push(Oe)}}else v.cachedOptions=[],v.previousValue=void 0;else if(q.value){v.previousValue=e.modelValue;const me=T.value,Te=me.findIndex(Oe=>de(f(Oe))===de(e.modelValue));~Te?v.selectedLabel=d(me[Te]):(!v.selectedLabel||ee)&&(v.selectedLabel=de(e.modelValue))}else v.selectedLabel="",v.previousValue=void 0;Ue(),G()};n.watch(()=>e.fitInputWidth,()=>{G()}),n.watch(z,ee=>{ee?(e.persistent||G(),qt("")):(v.inputValue="",v.previousQuery=null,v.isBeforeHide=!0,v.menuVisibleOnFocus=!1,Y(""))}),n.watch(()=>e.modelValue,(ee,me)=>{var Te;(!ee||De(ee)&&ee.length===0||e.multiple&&!Yt(ee.toString(),v.previousValue)||!e.multiple&&de(ee)!==de(v.previousValue))&&Mr(!0),!Yt(ee,me)&&e.validateEvent&&((Te=s==null?void 0:s.validate)==null||Te.call(s,"change").catch(Vt=>He(Vt)))},{deep:!0}),n.watch(()=>e.options,()=>{const ee=C.value;(!ee||ee&&document.activeElement!==ee)&&Mr()},{deep:!0,flush:"post"}),n.watch(()=>T.value,()=>(G(),O.value&&n.nextTick(O.value.resetScrollTop))),n.watchEffect(()=>{v.isBeforeHide||Ke()}),n.watchEffect(()=>{const{valueKey:ee,options:me}=e,Te=new Map;for(const Oe of me){const Vt=f(Oe);let Zn=Vt;if(ft(Zn)&&(Zn=jt(Vt,ee)),Te.get(Zn)){He("ElSelectV2","The option values you provided seem to be duplicated, which may cause some problems, please check.");break}else Te.set(Zn,!0)}}),n.onMounted(()=>{Mr()}),zt(b,Ce),zt(M,Ht),zt(x,Ot),zt(_,To),zt(j,Jn);let Et;return n.watch(()=>ne.value,ee=>{ee?Et=zt(O,Ot).stop:(Et==null||Et(),Et=void 0),t("visible-change",ee)}),{inputId:c,collapseTagSize:H,currentPlaceholder:kt,expanded:z,emptyText:Fe,popupHeight:Z,debounce:ye,allOptions:B,allOptionsValueMap:Be,filteredOptions:T,iconComponent:J,iconReverse:W,tagStyle:we,collapseTagStyle:be,popperSize:y,dropdownMenuVisible:ne,hasModelValue:q,shouldShowPlaceholder:ct,selectDisabled:D,selectSize:je,needStatusIcon:I,showClearBtn:te,states:v,isFocused:S,nsSelect:a,nsInput:i,inputRef:C,menuRef:O,tagMenuRef:_,tooltipRef:k,tagTooltipRef:w,selectRef:b,wrapperRef:x,selectionRef:M,prefixRef:E,suffixRef:A,collapseItemRef:j,popperRef:At,validateState:ae,validateIcon:ce,showTagList:Q,collapseTagList:oe,debouncedOnInputChange:Ct,deleteTag:da,getLabel:d,getValue:f,getDisabled:p,getValueKey:de,getIndex:mt,handleClear:ni,handleClickOutside:ue,handleDel:ti,handleEsc:Bn,focus:yr,blur:lo,handleMenuEnter:Re,handleResize:Ce,resetSelectionWidth:Ht,updateTooltip:Ot,updateTagTooltip:To,updateOptions:Ke,toggleMenu:ut,scrollTo:ot,onInput:ie,onKeyboardNavigate:Rr,onKeyboardSelect:X,onSelect:Pr,onHover:re,handleCompositionStart:P,handleCompositionEnd:$,handleCompositionUpdate:V}};var gX=n.defineComponent({name:"ElSelectV2",components:{ElSelectMenu:pX,ElTag:v6,ElTooltip:Ka,ElIcon:ke},directives:{ClickOutside:ps},props:PZ,emits:FZ,setup(e,{emit:t}){const r=n.computed(()=>{const{modelValue:c,multiple:u}=e,d=u?[]:void 0;return De(c)?u?c:d:u?d:c}),o=hX(n.reactive({...n.toRefs(e),modelValue:r}),t),{calculatorRef:a,inputStyle:i}=w6(),l=Ar();n.provide(Ch,{props:n.reactive({...n.toRefs(e),height:o.popupHeight,modelValue:r}),expanded:o.expanded,tooltipRef:o.tooltipRef,contentId:l,onSelect:o.onSelect,onHover:o.onHover,onKeyboardNavigate:o.onKeyboardNavigate,onKeyboardSelect:o.onKeyboardSelect});const s=n.computed(()=>e.multiple?o.states.cachedOptions.map(c=>o.getLabel(c)):o.states.selectedLabel);return{...o,modelValue:r,selectedLabel:s,calculatorRef:a,inputStyle:i,contentId:l,BORDER_HORIZONTAL_WIDTH:b6}}});const vX=["id","value","autocomplete","tabindex","aria-expanded","aria-label","disabled","aria-controls","aria-activedescendant","readonly","name"],yX=["textContent"],MX={key:1};function bX(e,t,r,o,a,i){const l=n.resolveComponent("el-tag"),s=n.resolveComponent("el-tooltip"),c=n.resolveComponent("el-icon"),u=n.resolveComponent("el-select-menu"),d=n.resolveDirective("click-outside");return n.withDirectives((n.openBlock(),n.createElementBlock("div",{ref:"selectRef",class:n.normalizeClass([e.nsSelect.b(),e.nsSelect.m(e.selectSize)]),onMouseenter:t[14]||(t[14]=f=>e.states.inputHovering=!0),onMouseleave:t[15]||(t[15]=f=>e.states.inputHovering=!1)},[n.createVNode(s,{ref:"tooltipRef",visible:e.dropdownMenuVisible,teleported:e.teleported,"popper-class":[e.nsSelect.e("popper"),e.popperClass],"popper-style":e.popperStyle,"gpu-acceleration":!1,"stop-popper-mouse-event":!1,"popper-options":e.popperOptions,"fallback-placements":e.fallbackPlacements,effect:e.effect,placement:e.placement,pure:"",transition:`${e.nsSelect.namespace.value}-zoom-in-top`,trigger:"click",persistent:e.persistent,"append-to":e.appendTo,"show-arrow":e.showArrow,offset:e.offset,onBeforeShow:e.handleMenuEnter,onHide:t[13]||(t[13]=f=>e.states.isBeforeHide=!1)},{default:n.withCtx(()=>{var f,p;return[n.createElementVNode("div",{ref:"wrapperRef",class:n.normalizeClass([e.nsSelect.e("wrapper"),e.nsSelect.is("focused",e.isFocused),e.nsSelect.is("hovering",e.states.inputHovering),e.nsSelect.is("filterable",e.filterable),e.nsSelect.is("disabled",e.selectDisabled)]),onClick:t[10]||(t[10]=n.withModifiers((...h)=>e.toggleMenu&&e.toggleMenu(...h),["prevent"]))},[e.$slots.prefix?(n.openBlock(),n.createElementBlock("div",{key:0,ref:"prefixRef",class:n.normalizeClass(e.nsSelect.e("prefix"))},[n.renderSlot(e.$slots,"prefix")],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("div",{ref:"selectionRef",class:n.normalizeClass([e.nsSelect.e("selection"),e.nsSelect.is("near",e.multiple&&!e.$slots.prefix&&!!e.modelValue.length)])},[e.multiple?n.renderSlot(e.$slots,"tag",{key:0,data:e.states.cachedOptions,deleteTag:e.deleteTag,selectDisabled:e.selectDisabled},()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.showTagList,h=>(n.openBlock(),n.createElementBlock("div",{key:e.getValueKey(e.getValue(h)),class:n.normalizeClass(e.nsSelect.e("selected-item"))},[n.createVNode(l,{closable:!e.selectDisabled&&!e.getDisabled(h),size:e.collapseTagSize,type:e.tagType,effect:e.tagEffect,"disable-transitions":"",style:n.normalizeStyle(e.tagStyle),onClose:m=>e.deleteTag(m,h)},{default:n.withCtx(()=>[n.createElementVNode("span",{class:n.normalizeClass(e.nsSelect.e("tags-text"))},[n.renderSlot(e.$slots,"label",{index:e.getIndex(h),label:e.getLabel(h),value:e.getValue(h)},()=>[n.createTextVNode(n.toDisplayString(e.getLabel(h)),1)])],2)]),_:2},1032,["closable","size","type","effect","style","onClose"])],2))),128)),e.collapseTags&&e.modelValue.length>e.maxCollapseTags?(n.openBlock(),n.createBlock(s,{key:0,ref:"tagTooltipRef",disabled:e.dropdownMenuVisible||!e.collapseTagsTooltip,"fallback-placements":["bottom","top","right","left"],effect:e.effect,placement:"bottom","popper-class":e.popperClass,"popper-style":e.popperStyle,teleported:e.teleported,"popper-options":e.popperOptions},{default:n.withCtx(()=>[n.createElementVNode("div",{ref:"collapseItemRef",class:n.normalizeClass(e.nsSelect.e("selected-item"))},[n.createVNode(l,{closable:!1,size:e.collapseTagSize,type:e.tagType,effect:e.tagEffect,style:n.normalizeStyle(e.collapseTagStyle),"disable-transitions":""},{default:n.withCtx(()=>[n.createElementVNode("span",{class:n.normalizeClass(e.nsSelect.e("tags-text"))}," + "+n.toDisplayString(e.modelValue.length-e.maxCollapseTags),3)]),_:1},8,["size","type","effect","style"])],2)]),content:n.withCtx(()=>[n.createElementVNode("div",{ref:"tagMenuRef",class:n.normalizeClass(e.nsSelect.e("selection"))},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.collapseTagList,h=>(n.openBlock(),n.createElementBlock("div",{key:e.getValueKey(e.getValue(h)),class:n.normalizeClass(e.nsSelect.e("selected-item"))},[n.createVNode(l,{class:"in-tooltip",closable:!e.selectDisabled&&!e.getDisabled(h),size:e.collapseTagSize,type:e.tagType,effect:e.tagEffect,"disable-transitions":"",onClose:m=>e.deleteTag(m,h)},{default:n.withCtx(()=>[n.createElementVNode("span",{class:n.normalizeClass(e.nsSelect.e("tags-text"))},[n.renderSlot(e.$slots,"label",{index:e.getIndex(h),label:e.getLabel(h),value:e.getValue(h)},()=>[n.createTextVNode(n.toDisplayString(e.getLabel(h)),1)])],2)]),_:2},1032,["closable","size","type","effect","onClose"])],2))),128))],2)]),_:3},8,["disabled","effect","popper-class","popper-style","teleported","popper-options"])):n.createCommentVNode("v-if",!0)]):n.createCommentVNode("v-if",!0),n.createElementVNode("div",{class:n.normalizeClass([e.nsSelect.e("selected-item"),e.nsSelect.e("input-wrapper"),e.nsSelect.is("hidden",!e.filterable||e.selectDisabled)])},[n.createElementVNode("input",{id:e.inputId,ref:"inputRef",value:e.states.inputValue,style:n.normalizeStyle(e.inputStyle),autocomplete:e.autocomplete,tabindex:e.tabindex,"aria-autocomplete":"none","aria-haspopup":"listbox",autocapitalize:"off","aria-expanded":e.expanded,"aria-label":e.ariaLabel,class:n.normalizeClass([e.nsSelect.e("input"),e.nsSelect.is(e.selectSize)]),disabled:e.selectDisabled,role:"combobox","aria-controls":e.contentId,"aria-activedescendant":e.states.hoveringIndex>=0?`${e.contentId}-${e.states.hoveringIndex}`:"",readonly:!e.filterable,spellcheck:"false",type:"text",name:e.name,onInput:t[0]||(t[0]=(...h)=>e.onInput&&e.onInput(...h)),onCompositionstart:t[1]||(t[1]=(...h)=>e.handleCompositionStart&&e.handleCompositionStart(...h)),onCompositionupdate:t[2]||(t[2]=(...h)=>e.handleCompositionUpdate&&e.handleCompositionUpdate(...h)),onCompositionend:t[3]||(t[3]=(...h)=>e.handleCompositionEnd&&e.handleCompositionEnd(...h)),onKeydown:[t[4]||(t[4]=n.withKeys(n.withModifiers(h=>e.onKeyboardNavigate("backward"),["stop","prevent"]),["up"])),t[5]||(t[5]=n.withKeys(n.withModifiers(h=>e.onKeyboardNavigate("forward"),["stop","prevent"]),["down"])),t[6]||(t[6]=n.withKeys(n.withModifiers((...h)=>e.onKeyboardSelect&&e.onKeyboardSelect(...h),["stop","prevent"]),["enter"])),t[7]||(t[7]=n.withKeys(n.withModifiers((...h)=>e.handleEsc&&e.handleEsc(...h),["stop","prevent"]),["esc"])),t[8]||(t[8]=n.withKeys(n.withModifiers((...h)=>e.handleDel&&e.handleDel(...h),["stop"]),["delete"]))],onClick:t[9]||(t[9]=n.withModifiers((...h)=>e.toggleMenu&&e.toggleMenu(...h),["stop"]))},null,46,vX),e.filterable?(n.openBlock(),n.createElementBlock("span",{key:0,ref:"calculatorRef","aria-hidden":"true",class:n.normalizeClass(e.nsSelect.e("input-calculator")),textContent:n.toDisplayString(e.states.inputValue)},null,10,yX)):n.createCommentVNode("v-if",!0)],2),e.shouldShowPlaceholder?(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass([e.nsSelect.e("selected-item"),e.nsSelect.e("placeholder"),e.nsSelect.is("transparent",!e.hasModelValue||e.expanded&&!e.states.inputValue)])},[e.hasModelValue?n.renderSlot(e.$slots,"label",{key:0,index:(p=(f=e.allOptionsValueMap.get(e.modelValue))==null?void 0:f.index)!=null?p:-1,label:e.currentPlaceholder,value:e.modelValue},()=>[n.createElementVNode("span",null,n.toDisplayString(e.currentPlaceholder),1)]):(n.openBlock(),n.createElementBlock("span",MX,n.toDisplayString(e.currentPlaceholder),1))],2)):n.createCommentVNode("v-if",!0)],2),n.createElementVNode("div",{ref:"suffixRef",class:n.normalizeClass(e.nsSelect.e("suffix"))},[e.iconComponent?n.withDirectives((n.openBlock(),n.createBlock(c,{key:0,class:n.normalizeClass([e.nsSelect.e("caret"),e.nsInput.e("icon"),e.iconReverse])},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.iconComponent)))]),_:1},8,["class"])),[[n.vShow,!e.showClearBtn]]):n.createCommentVNode("v-if",!0),e.showClearBtn&&e.clearIcon?(n.openBlock(),n.createBlock(c,{key:1,class:n.normalizeClass([e.nsSelect.e("caret"),e.nsInput.e("icon"),e.nsSelect.e("clear")]),onClick:n.withModifiers(e.handleClear,["prevent","stop"])},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.clearIcon)))]),_:1},8,["class","onClick"])):n.createCommentVNode("v-if",!0),e.validateState&&e.validateIcon&&e.needStatusIcon?(n.openBlock(),n.createBlock(c,{key:2,class:n.normalizeClass([e.nsInput.e("icon"),e.nsInput.e("validateIcon"),e.nsInput.is("loading",e.validateState==="validating")])},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.validateIcon)))]),_:1},8,["class"])):n.createCommentVNode("v-if",!0)],2)],2)]}),content:n.withCtx(()=>[n.createVNode(u,{id:e.contentId,ref:"menuRef",data:e.filteredOptions,width:e.popperSize-e.BORDER_HORIZONTAL_WIDTH,"hovering-index":e.states.hoveringIndex,"scrollbar-always-on":e.scrollbarAlwaysOn,"aria-label":e.ariaLabel},n.createSlots({default:n.withCtx(f=>[n.renderSlot(e.$slots,"default",n.normalizeProps(n.guardReactiveProps(f)))]),_:2},[e.$slots.header?{name:"header",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","header")),onClick:t[11]||(t[11]=n.withModifiers(()=>{},["stop"]))},[n.renderSlot(e.$slots,"header")],2)]),key:"0"}:void 0,e.$slots.loading&&e.loading?{name:"loading",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","loading"))},[n.renderSlot(e.$slots,"loading")],2)]),key:"1"}:e.loading||e.filteredOptions.length===0?{name:"empty",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","empty"))},[n.renderSlot(e.$slots,"empty",{},()=>[n.createElementVNode("span",null,n.toDisplayString(e.emptyText),1)])],2)]),key:"2"}:void 0,e.$slots.footer?{name:"footer",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","footer")),onClick:t[12]||(t[12]=n.withModifiers(()=>{},["stop"]))},[n.renderSlot(e.$slots,"footer")],2)]),key:"3"}:void 0]),1032,["id","data","width","hovering-index","scrollbar-always-on","aria-label"])]),_:3},8,["visible","teleported","popper-class","popper-style","popper-options","fallback-placements","effect","placement","transition","persistent","append-to","show-arrow","offset","onBeforeShow"])],34)),[[d,e.handleClickOutside,e.popperRef]])}var wX=sn(gX,[["render",bX]]);const NX=it(wX),Tb=Symbol("sliderContextKey"),kX=ge({modelValue:{type:K([Number,Array]),default:0},id:{type:String,default:void 0},min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},showInput:Boolean,showInputControls:{type:Boolean,default:!0},size:Qn,inputSize:Qn,showStops:Boolean,showTooltip:{type:Boolean,default:!0},formatTooltip:{type:K(Function),default:void 0},disabled:{type:Boolean,default:void 0},range:Boolean,vertical:Boolean,height:String,rangeStartLabel:{type:String,default:void 0},rangeEndLabel:{type:String,default:void 0},formatValueText:{type:K(Function),default:void 0},tooltipClass:{type:String,default:void 0},placement:{type:String,values:aa,default:"top"},marks:{type:K(Object)},validateEvent:{type:Boolean,default:!0},persistent:{type:Boolean,default:!0},...Ln(["ariaLabel"])}),Bf=e=>Ve(e)||De(e)&&e.every(Ve),xX={[$e]:Bf,[Yn]:Bf,[st]:Bf},CX=ge({modelValue:{type:Number,default:0},vertical:Boolean,tooltipClass:String,placement:{type:String,values:aa,default:"top"}}),EX={[$e]:e=>Ve(e)},TX=(e,t,r)=>{const o=n.ref(),a=n.ref(!1),i=n.computed(()=>t.value instanceof Function),l=n.computed(()=>i.value&&t.value(e.modelValue)||e.modelValue),s=uu(()=>{r.value&&(a.value=!0)},50),c=uu(()=>{r.value&&(a.value=!1)},50);return{tooltip:o,tooltipVisible:a,formatValue:l,displayTooltip:s,hideTooltip:c}},DX=(e,t,r)=>{const{disabled:o,min:a,max:i,step:l,showTooltip:s,persistent:c,precision:u,sliderSize:d,formatTooltip:f,emitChange:p,resetSize:h,updateDragging:m}=n.inject(Tb),{tooltip:g,tooltipVisible:v,formatValue:y,displayTooltip:N,hideTooltip:b}=TX(e,f,s),M=n.ref(),k=n.computed(()=>`${(e.modelValue-a.value)/(i.value-a.value)*100}%`),w=n.computed(()=>e.vertical?{bottom:k.value}:{left:k.value}),C=()=>{t.hovering=!0,N()},E=()=>{t.hovering=!1,t.dragging||b()},A=T=>{o.value||(T.preventDefault(),S(T),window.addEventListener("mousemove",L),window.addEventListener("touchmove",L),window.addEventListener("mouseup",B),window.addEventListener("touchend",B),window.addEventListener("contextmenu",B),M.value.focus())},O=T=>{o.value||(t.newPosition=Number.parseFloat(k.value)+T/(i.value-a.value)*100,F(t.newPosition),p())},_=()=>{O(-l.value)},j=()=>{O(l.value)},R=()=>{O(-l.value*4)},P=()=>{O(l.value*4)},$=()=>{o.value||(F(0),p())},V=()=>{o.value||(F(100),p())},D=T=>{const z=Lt(T);let I=!0;switch(z){case ve.left:case ve.down:_();break;case ve.right:case ve.up:j();break;case ve.home:$();break;case ve.end:V();break;case ve.pageDown:R();break;case ve.pageUp:P();break;default:I=!1;break}I&&T.preventDefault()},x=T=>{let z,I;return T.type.startsWith("touch")?(I=T.touches[0].clientY,z=T.touches[0].clientX):(I=T.clientY,z=T.clientX),{clientX:z,clientY:I}},S=T=>{t.dragging=!0,t.isClick=!0;const{clientX:z,clientY:I}=x(T);e.vertical?t.startY=I:t.startX=z,t.startPosition=Number.parseFloat(k.value),t.newPosition=t.startPosition},L=T=>{if(t.dragging){t.isClick=!1,N(),h();let z;const{clientX:I,clientY:Z}=x(T);e.vertical?(t.currentY=Z,z=(t.startY-t.currentY)/d.value*100):(t.currentX=I,z=(t.currentX-t.startX)/d.value*100),t.newPosition=t.startPosition+z,F(t.newPosition)}},B=()=>{t.dragging&&(setTimeout(()=>{t.dragging=!1,t.hovering||b(),t.isClick||F(t.newPosition),p()},0),window.removeEventListener("mousemove",L),window.removeEventListener("touchmove",L),window.removeEventListener("mouseup",B),window.removeEventListener("touchend",B),window.removeEventListener("contextmenu",B))},F=async T=>{if(T===null||Number.isNaN(+T))return;T=wa(T,0,100);const z=Math.floor((i.value-a.value)/l.value),I=z*l.value/(i.value-a.value)*100,Z=I+(100-I)/2;let q;if(T<I){const te=I/z,J=Math.round(T/te);q=a.value+J*l.value}else T<Z?q=a.value+z*l.value:q=i.value;q=Number.parseFloat(q.toFixed(u.value)),q!==e.modelValue&&r($e,q),!t.dragging&&e.modelValue!==t.oldValue&&(t.oldValue=e.modelValue),await n.nextTick(),t.dragging&&N(),g.value.updatePopper()};return n.watch(()=>t.dragging,T=>{m(T)}),ht(M,"touchstart",A,{passive:!1}),{disabled:o,button:M,tooltip:g,tooltipVisible:v,showTooltip:s,persistent:c,wrapperStyle:w,formatValue:y,handleMouseEnter:C,handleMouseLeave:E,onButtonDown:A,onKeyDown:D,setPosition:F}},SX=["tabindex"];var Dg=n.defineComponent({name:"ElSliderButton",__name:"button",props:CX,emits:EX,setup(e,{expose:t,emit:r}){const o=e,a=r,i=he("slider"),l=n.reactive({hovering:!1,dragging:!1,isClick:!1,startX:0,currentX:0,startY:0,currentY:0,startPosition:0,newPosition:0,oldValue:o.modelValue}),s=n.computed(()=>f.value?p.value:!1),{disabled:c,button:u,tooltip:d,showTooltip:f,persistent:p,tooltipVisible:h,wrapperStyle:m,formatValue:g,handleMouseEnter:v,handleMouseLeave:y,onButtonDown:N,onKeyDown:b,setPosition:M}=DX(o,l,a),{hovering:k,dragging:w}=n.toRefs(l);return t({onButtonDown:N,onKeyDown:b,setPosition:M,hovering:k,dragging:w}),(C,E)=>(n.openBlock(),n.createElementBlock("div",{ref_key:"button",ref:u,class:n.normalizeClass([n.unref(i).e("button-wrapper"),{hover:n.unref(k),dragging:n.unref(w)}]),style:n.normalizeStyle(n.unref(m)),tabindex:n.unref(c)?void 0:0,onMouseenter:E[0]||(E[0]=(...A)=>n.unref(v)&&n.unref(v)(...A)),onMouseleave:E[1]||(E[1]=(...A)=>n.unref(y)&&n.unref(y)(...A)),onMousedown:E[2]||(E[2]=(...A)=>n.unref(N)&&n.unref(N)(...A)),onFocus:E[3]||(E[3]=(...A)=>n.unref(v)&&n.unref(v)(...A)),onBlur:E[4]||(E[4]=(...A)=>n.unref(y)&&n.unref(y)(...A)),onKeydown:E[5]||(E[5]=(...A)=>n.unref(b)&&n.unref(b)(...A))},[n.createVNode(n.unref(Ka),{ref_key:"tooltip",ref:d,visible:n.unref(h),placement:C.placement,"fallback-placements":["top","bottom","right","left"],"stop-popper-mouse-event":!1,"popper-class":C.tooltipClass,disabled:!n.unref(f),persistent:s.value},{content:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(n.unref(g)),1)]),default:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass([n.unref(i).e("button"),{hover:n.unref(k),dragging:n.unref(w)}])},null,2)]),_:1},8,["visible","placement","popper-class","disabled","persistent"])],46,SX))}});const _X=ge({mark:{type:K([String,Object]),default:void 0}});var IX=n.defineComponent({name:"ElSliderMarker",props:_X,setup(e){const t=he("slider"),r=n.computed(()=>nt(e.mark)?e.mark:e.mark.label),o=n.computed(()=>nt(e.mark)?void 0:e.mark.style);return()=>n.h("div",{class:t.e("marks-text"),style:o.value},r.value)}});const AX=(e,t,r)=>{const{formItem:o}=Kn(),a=n.shallowRef(),i=n.ref(),l=n.ref(),s={firstButton:i,secondButton:l},c=Bt(),u=n.computed(()=>Math.min(t.firstValue,t.secondValue)),d=n.computed(()=>Math.max(t.firstValue,t.secondValue)),f=n.computed(()=>e.range?`${100*(d.value-u.value)/(e.max-e.min)}%`:`${100*(t.firstValue-e.min)/(e.max-e.min)}%`),p=n.computed(()=>e.range?`${100*(u.value-e.min)/(e.max-e.min)}%`:"0%"),h=n.computed(()=>e.vertical?{height:e.height}:{}),m=n.computed(()=>e.vertical?{height:f.value,bottom:p.value}:{width:f.value,left:p.value}),g=()=>{if(a.value){const _=a.value.getBoundingClientRect();t.sliderSize=_[e.vertical?"height":"width"]}},v=_=>{const j=e.min+_*(e.max-e.min)/100;if(!e.range)return i;let R;return Math.abs(u.value-j)<Math.abs(d.value-j)?R=t.firstValue<t.secondValue?"firstButton":"secondButton":R=t.firstValue>t.secondValue?"firstButton":"secondButton",s[R]},y=_=>{const j=v(_);return j.value.setPosition(_),j},N=_=>{t.firstValue=_??e.min,M(e.range?[u.value,d.value]:_??e.min)},b=_=>{t.secondValue=_,e.range&&M([u.value,d.value])},M=_=>{r($e,_),r(Yn,_)},k=async()=>{await n.nextTick(),r(st,e.range?[u.value,d.value]:e.modelValue)},w=_=>{var j,R,P,$,V,D;if(c.value||t.dragging)return;g();let x=0;if(e.vertical){const S=(P=(R=(j=_.touches)==null?void 0:j.item(0))==null?void 0:R.clientY)!=null?P:_.clientY;x=(a.value.getBoundingClientRect().bottom-S)/t.sliderSize*100}else{const S=(D=(V=($=_.touches)==null?void 0:$.item(0))==null?void 0:V.clientX)!=null?D:_.clientX,L=a.value.getBoundingClientRect().left;x=(S-L)/t.sliderSize*100}if(!(x<0||x>100))return y(x)};return{elFormItem:o,slider:a,firstButton:i,secondButton:l,sliderDisabled:c,minValue:u,maxValue:d,runwayStyle:h,barStyle:m,resetSize:g,setPosition:y,emitChange:k,onSliderWrapperPrevent:_=>{var j,R;((j=s.firstButton.value)!=null&&j.dragging||(R=s.secondButton.value)!=null&&R.dragging)&&_.preventDefault()},onSliderClick:_=>{w(_)&&k()},onSliderDown:async _=>{const j=w(_);j&&(await n.nextTick(),j.value.onButtonDown(_))},onSliderMarkerDown:_=>{if(c.value||t.dragging)return;y(_)&&k()},setFirstValue:N,setSecondValue:b}},OX=(e,t,r,o)=>({stops:n.computed(()=>{if(!e.showStops||e.min>e.max)return[];if(e.step===0)return He("ElSlider","step should not be 0."),[];const l=Math.ceil((e.max-e.min)/e.step),s=100*e.step/(e.max-e.min),c=Array.from({length:l-1}).map((u,d)=>(d+1)*s);return e.range?c.filter(u=>u<100*(r.value-e.min)/(e.max-e.min)||u>100*(o.value-e.min)/(e.max-e.min)):c.filter(u=>u>100*(t.firstValue-e.min)/(e.max-e.min))}),getStopStyle:l=>e.vertical?{bottom:`${l}%`}:{left:`${l}%`}}),zX=e=>n.computed(()=>e.marks?Object.keys(e.marks).map(Number.parseFloat).sort((r,o)=>r-o).filter(r=>r<=e.max&&r>=e.min).map(r=>({point:r,position:(r-e.min)*100/(e.max-e.min),mark:e.marks[r]})):[]),jX=(e,t,r,o,a,i)=>{const l=u=>{a($e,u),a(Yn,u)},s=()=>e.range?![r.value,o.value].every((u,d)=>u===t.oldValue[d]):e.modelValue!==t.oldValue,c=()=>{var u,d;e.min>e.max&&gn("Slider","min should not be greater than max.");const f=e.modelValue;e.range&&De(f)?f[1]<e.min?l([e.min,e.min]):f[0]>e.max?l([e.max,e.max]):f[0]<e.min?l([e.min,f[1]]):f[1]>e.max?l([f[0],e.max]):(t.firstValue=f[0],t.secondValue=f[1],s()&&(e.validateEvent&&((u=i==null?void 0:i.validate)==null||u.call(i,"change").catch(p=>He(p))),t.oldValue=f.slice())):!e.range&&Ve(f)&&!Number.isNaN(f)&&(f<e.min?l(e.min):f>e.max?l(e.max):(t.firstValue=f,s()&&(e.validateEvent&&((d=i==null?void 0:i.validate)==null||d.call(i,"change").catch(p=>He(p))),t.oldValue=f)))};c(),n.watch(()=>t.dragging,u=>{u||c()}),n.watch(()=>e.modelValue,(u,d)=>{t.dragging||De(u)&&De(d)&&u.every((f,p)=>f===d[p])&&t.firstValue===u[0]&&t.secondValue===u[1]||c()},{deep:!0}),n.watch(()=>[e.min,e.max],()=>{c()})},LX=(e,t,r)=>{const o=n.ref();return n.onMounted(async()=>{e.range?(De(e.modelValue)?(t.firstValue=Math.max(e.min,e.modelValue[0]),t.secondValue=Math.min(e.max,e.modelValue[1])):(t.firstValue=e.min,t.secondValue=e.max),t.oldValue=[t.firstValue,t.secondValue]):(!Ve(e.modelValue)||Number.isNaN(e.modelValue)?t.firstValue=e.min:t.firstValue=Math.min(e.max,Math.max(e.min,e.modelValue)),t.oldValue=t.firstValue),ht(window,"resize",r),await n.nextTick(),r()}),{sliderWrapper:o}},BX=["id","role","aria-label","aria-labelledby"],VX={key:1};var $X=n.defineComponent({name:"ElSlider",__name:"slider",props:kX,emits:xX,setup(e,{expose:t,emit:r}){const o=e,a=r,i=he("slider"),{t:l}=Nt(),s=n.reactive({firstValue:0,secondValue:0,oldValue:0,dragging:!1,sliderSize:1}),{elFormItem:c,slider:u,firstButton:d,secondButton:f,sliderDisabled:p,minValue:h,maxValue:m,runwayStyle:g,barStyle:v,resetSize:y,emitChange:N,onSliderWrapperPrevent:b,onSliderClick:M,onSliderDown:k,onSliderMarkerDown:w,setFirstValue:C,setSecondValue:E}=AX(o,s,a),{stops:A,getStopStyle:O}=OX(o,s,h,m),{inputId:_,isLabeledByFormItem:j}=io(o,{formItemContext:c}),R=mn(),P=n.computed(()=>o.inputSize||R.value),$=n.computed(()=>o.ariaLabel||l("el.slider.defaultLabel",{min:o.min,max:o.max})),V=n.computed(()=>o.range?o.rangeStartLabel||l("el.slider.defaultRangeStartLabel"):$.value),D=n.computed(()=>o.formatValueText?o.formatValueText(z.value):`${z.value}`),x=n.computed(()=>o.rangeEndLabel||l("el.slider.defaultRangeEndLabel")),S=n.computed(()=>o.formatValueText?o.formatValueText(I.value):`${I.value}`),L=n.computed(()=>[i.b(),i.m(R.value),i.is("vertical",o.vertical),{[i.m("with-input")]:o.showInput}]),B=zX(o);jX(o,s,h,m,a,c);const F=n.computed(()=>{const te=[o.min,o.max,o.step].map(J=>{const W=`${J}`.split(".")[1];return W?W.length:0});return Math.max.apply(null,te)}),{sliderWrapper:T}=LX(o,s,y),{firstValue:z,secondValue:I,sliderSize:Z}=n.toRefs(s),q=te=>{s.dragging=te};return ht(T,"touchstart",b,{passive:!1}),ht(T,"touchmove",b,{passive:!1}),n.provide(Tb,{...n.toRefs(o),sliderSize:Z,disabled:p,precision:F,emitChange:N,resetSize:y,updateDragging:q}),t({onSliderClick:M}),(te,J)=>{var W,ae;return n.openBlock(),n.createElementBlock("div",{id:te.range?n.unref(_):void 0,ref_key:"sliderWrapper",ref:T,class:n.normalizeClass(L.value),role:te.range?"group":void 0,"aria-label":te.range&&!n.unref(j)?$.value:void 0,"aria-labelledby":te.range&&n.unref(j)?(W=n.unref(c))==null?void 0:W.labelId:void 0},[n.createElementVNode("div",{ref_key:"slider",ref:u,class:n.normalizeClass([n.unref(i).e("runway"),{"show-input":te.showInput&&!te.range},n.unref(i).is("disabled",n.unref(p))]),style:n.normalizeStyle(n.unref(g)),onMousedown:J[0]||(J[0]=(...ce)=>n.unref(k)&&n.unref(k)(...ce)),onTouchstartPassive:J[1]||(J[1]=(...ce)=>n.unref(k)&&n.unref(k)(...ce))},[n.createElementVNode("div",{class:n.normalizeClass(n.unref(i).e("bar")),style:n.normalizeStyle(n.unref(v))},null,6),n.createVNode(Dg,{id:te.range?void 0:n.unref(_),ref_key:"firstButton",ref:d,"model-value":n.unref(z),vertical:te.vertical,"tooltip-class":te.tooltipClass,placement:te.placement,role:"slider","aria-label":te.range||!n.unref(j)?V.value:void 0,"aria-labelledby":!te.range&&n.unref(j)?(ae=n.unref(c))==null?void 0:ae.labelId:void 0,"aria-valuemin":te.min,"aria-valuemax":te.range?n.unref(I):te.max,"aria-valuenow":n.unref(z),"aria-valuetext":D.value,"aria-orientation":te.vertical?"vertical":"horizontal","aria-disabled":n.unref(p),"onUpdate:modelValue":n.unref(C)},null,8,["id","model-value","vertical","tooltip-class","placement","aria-label","aria-labelledby","aria-valuemin","aria-valuemax","aria-valuenow","aria-valuetext","aria-orientation","aria-disabled","onUpdate:modelValue"]),te.range?(n.openBlock(),n.createBlock(Dg,{key:0,ref_key:"secondButton",ref:f,"model-value":n.unref(I),vertical:te.vertical,"tooltip-class":te.tooltipClass,placement:te.placement,role:"slider","aria-label":x.value,"aria-valuemin":n.unref(z),"aria-valuemax":te.max,"aria-valuenow":n.unref(I),"aria-valuetext":S.value,"aria-orientation":te.vertical?"vertical":"horizontal","aria-disabled":n.unref(p),"onUpdate:modelValue":n.unref(E)},null,8,["model-value","vertical","tooltip-class","placement","aria-label","aria-valuemin","aria-valuemax","aria-valuenow","aria-valuetext","aria-orientation","aria-disabled","onUpdate:modelValue"])):n.createCommentVNode("v-if",!0),te.showStops?(n.openBlock(),n.createElementBlock("div",VX,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(A),(ce,ye)=>(n.openBlock(),n.createElementBlock("div",{key:ye,class:n.normalizeClass(n.unref(i).e("stop")),style:n.normalizeStyle(n.unref(O)(ce))},null,6))),128))])):n.createCommentVNode("v-if",!0),n.unref(B).length>0?(n.openBlock(),n.createElementBlock(n.Fragment,{key:2},[n.createElementVNode("div",null,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(B),(ce,ye)=>(n.openBlock(),n.createElementBlock("div",{key:ye,style:n.normalizeStyle(n.unref(O)(ce.position)),class:n.normalizeClass([n.unref(i).e("stop"),n.unref(i).e("marks-stop")])},null,6))),128))]),n.createElementVNode("div",{class:n.normalizeClass(n.unref(i).e("marks"))},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(B),(ce,ye)=>(n.openBlock(),n.createBlock(n.unref(IX),{key:ye,mark:ce.mark,style:n.normalizeStyle(n.unref(O)(ce.position)),onMousedown:n.withModifiers(Ae=>n.unref(w)(ce.position),["stop"])},null,8,["mark","style","onMousedown"]))),128))],2)],64)):n.createCommentVNode("v-if",!0)],38),te.showInput&&!te.range?(n.openBlock(),n.createBlock(n.unref(mZ),{key:0,ref:"input","model-value":n.unref(z),class:n.normalizeClass(n.unref(i).e("input")),step:te.step,disabled:n.unref(p),controls:te.showInputControls,min:te.min,max:te.max,precision:F.value,size:P.value,"onUpdate:modelValue":n.unref(C),onChange:n.unref(N)},null,8,["model-value","class","step","disabled","controls","min","max","precision","size","onUpdate:modelValue","onChange"])):n.createCommentVNode("v-if",!0)],10,BX)}}});const PX=it($X),RX=e=>["",...Fs].includes(e),FX=ge({modelValue:{type:[Boolean,String,Number],default:!1},disabled:{type:Boolean,default:void 0},loading:Boolean,size:{type:String,validator:RX},width:{type:[String,Number],default:""},inlinePrompt:Boolean,inactiveActionIcon:{type:Qt},activeActionIcon:{type:Qt},activeIcon:{type:Qt},inactiveIcon:{type:Qt},activeText:{type:String,default:""},inactiveText:{type:String,default:""},activeValue:{type:[Boolean,String,Number],default:!0},inactiveValue:{type:[Boolean,String,Number],default:!1},name:{type:String,default:""},validateEvent:{type:Boolean,default:!0},beforeChange:{type:K(Function)},id:String,tabindex:{type:[String,Number]},...Ln(["ariaLabel"])}),UX={[$e]:e=>an(e)||nt(e)||Ve(e),[st]:e=>an(e)||nt(e)||Ve(e),[Yn]:e=>an(e)||nt(e)||Ve(e)},HX=["id","aria-checked","aria-disabled","aria-label","name","true-value","false-value","disabled","tabindex"],YX=["aria-hidden"],QX={key:1},WX={key:1},qX=["aria-hidden"],Vf="ElSwitch";var GX=n.defineComponent({name:Vf,__name:"switch",props:FX,emits:UX,setup(e,{expose:t,emit:r}){const o=e,a=r,{formItem:i}=Kn(),l=mn(),s=he("switch"),{inputId:c}=io(o,{formItemContext:i}),u=Bt(n.computed(()=>{if(o.loading)return!0})),d=n.ref(o.modelValue!==!1),f=n.shallowRef(),p=n.computed(()=>[s.b(),s.m(l.value),s.is("disabled",u.value),s.is("checked",y.value)]),h=n.computed(()=>[s.e("label"),s.em("label","left"),s.is("active",!y.value)]),m=n.computed(()=>[s.e("label"),s.em("label","right"),s.is("active",y.value)]),g=n.computed(()=>({width:Ir(o.width)}));n.watch(()=>o.modelValue,()=>{d.value=!0});const v=n.computed(()=>d.value?o.modelValue:!1),y=n.computed(()=>v.value===o.activeValue);[o.activeValue,o.inactiveValue].includes(v.value)||(a($e,o.inactiveValue),a(st,o.inactiveValue),a(Yn,o.inactiveValue)),n.watch(y,k=>{var w;f.value.checked=k,o.validateEvent&&((w=i==null?void 0:i.validate)==null||w.call(i,"change").catch(C=>He(C)))});const N=()=>{const k=y.value?o.inactiveValue:o.activeValue;a($e,k),a(st,k),a(Yn,k),n.nextTick(()=>{f.value.checked=y.value})},b=()=>{if(u.value)return;const{beforeChange:k}=o;if(!k){N();return}const w=k();[du(w),an(w)].includes(!0)||gn(Vf,"beforeChange must return type `Promise<boolean>` or `boolean`"),du(w)?w.then(E=>{E&&N()}).catch(E=>{He(Vf,`some error occurred: ${E}`)}):w&&N()},M=()=>{var k,w;(w=(k=f.value)==null?void 0:k.focus)==null||w.call(k)};return n.onMounted(()=>{f.value.checked=y.value}),t({focus:M,checked:y}),(k,w)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(p.value),onClick:n.withModifiers(b,["prevent"])},[n.createElementVNode("input",{id:n.unref(c),ref_key:"input",ref:f,class:n.normalizeClass(n.unref(s).e("input")),type:"checkbox",role:"switch","aria-checked":y.value,"aria-disabled":n.unref(u),"aria-label":e.ariaLabel,name:e.name,"true-value":e.activeValue,"false-value":e.inactiveValue,disabled:n.unref(u),tabindex:e.tabindex,onChange:N,onKeydown:n.withKeys(b,["enter"])},null,42,HX),!e.inlinePrompt&&(e.inactiveIcon||e.inactiveText||k.$slots.inactive)?(n.openBlock(),n.createElementBlock("span",{key:0,class:n.normalizeClass(h.value)},[n.renderSlot(k.$slots,"inactive",{},()=>[e.inactiveIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.inactiveIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.inactiveIcon&&e.inactiveText?(n.openBlock(),n.createElementBlock("span",{key:1,"aria-hidden":y.value},n.toDisplayString(e.inactiveText),9,YX)):n.createCommentVNode("v-if",!0)])],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("span",{class:n.normalizeClass(n.unref(s).e("core")),style:n.normalizeStyle(g.value)},[e.inlinePrompt?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(n.unref(s).e("inner"))},[y.value?(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass(n.unref(s).e("inner-wrapper"))},[n.renderSlot(k.$slots,"active",{},()=>[e.activeIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.activeIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.activeIcon&&e.activeText?(n.openBlock(),n.createElementBlock("span",WX,n.toDisplayString(e.activeText),1)):n.createCommentVNode("v-if",!0)])],2)):(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(n.unref(s).e("inner-wrapper"))},[n.renderSlot(k.$slots,"inactive",{},()=>[e.inactiveIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.inactiveIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.inactiveIcon&&e.inactiveText?(n.openBlock(),n.createElementBlock("span",QX,n.toDisplayString(e.inactiveText),1)):n.createCommentVNode("v-if",!0)])],2))],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("div",{class:n.normalizeClass(n.unref(s).e("action"))},[e.loading?(n.openBlock(),n.createBlock(n.unref(ke),{key:0,class:n.normalizeClass(n.unref(s).is("loading"))},{default:n.withCtx(()=>[n.createVNode(n.unref(Ud))]),_:1},8,["class"])):y.value?n.renderSlot(k.$slots,"active-action",{key:1},()=>[e.activeActionIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.activeActionIcon)))]),_:1})):n.createCommentVNode("v-if",!0)]):y.value?n.createCommentVNode("v-if",!0):n.renderSlot(k.$slots,"inactive-action",{key:2},()=>[e.inactiveActionIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.inactiveActionIcon)))]),_:1})):n.createCommentVNode("v-if",!0)])],2)],6),!e.inlinePrompt&&(e.activeIcon||e.activeText||k.$slots.active)?(n.openBlock(),n.createElementBlock("span",{key:1,class:n.normalizeClass(m.value)},[n.renderSlot(k.$slots,"active",{},()=>[e.activeIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.activeIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.activeIcon&&e.activeText?(n.openBlock(),n.createElementBlock("span",{key:1,"aria-hidden":!y.value},n.toDisplayString(e.activeText),9,qX)):n.createCommentVNode("v-if",!0)])],2)):n.createCommentVNode("v-if",!0)],2))}});const KX=it(GX),Kd=Symbol("tabsRootContextKey"),JX=ge({tabs:{type:K(Array),default:()=>Wn([])},tabRefs:{type:K(Object),default:()=>Wn({})}}),Sg="ElTabBar";var ZX=n.defineComponent({name:Sg,__name:"tab-bar",props:JX,setup(e,{expose:t}){const r=e,o=n.inject(Kd);o||gn(Sg,"<el-tabs><el-tab-bar /></el-tabs>");const a=he("tabs"),i=n.ref(),l=n.ref(),s=n.computed(()=>{var h;return Rt(o.props.defaultValue)||!!((h=l.value)!=null&&h.transform)}),c=()=>{let h=0,m=0;const g=["top","bottom"].includes(o.props.tabPosition)?"width":"height",v=g==="width"?"x":"y",y=v==="x"?"left":"top";return r.tabs.every(N=>{if(Rt(N.paneName))return!1;const b=r.tabRefs[N.paneName];if(!b)return!1;if(!N.active)return!0;h=b[`offset${Vo(y)}`],m=b[`client${Vo(g)}`];const M=window.getComputedStyle(b);return g==="width"&&(m-=Number.parseFloat(M.paddingLeft)+Number.parseFloat(M.paddingRight),h+=Number.parseFloat(M.paddingLeft)),!1}),{[g]:`${m}px`,transform:`translate${Vo(v)}(${h}px)`}},u=()=>l.value=c(),d=[],f=()=>{d.forEach(h=>h.stop()),d.length=0,Object.values(r.tabRefs).forEach(h=>{d.push(zt(h,u))})};n.watch(()=>r.tabs,async()=>{await n.nextTick(),u(),f()},{immediate:!0});const p=zt(i,()=>u());return n.onBeforeUnmount(()=>{d.forEach(h=>h.stop()),d.length=0,p.stop()}),t({ref:i,update:u}),(h,m)=>s.value?(n.openBlock(),n.createElementBlock("div",{key:0,ref_key:"barRef",ref:i,class:n.normalizeClass([n.unref(a).e("active-bar"),n.unref(a).is(n.unref(o).props.tabPosition)]),style:n.normalizeStyle(l.value)},null,6)):n.createCommentVNode("v-if",!0)}});const XX=ge({panes:{type:K(Array),default:()=>Wn([])},currentName:{type:[String,Number],default:""},editable:Boolean,type:{type:String,values:["card","border-card",""],default:""},stretch:Boolean,tabindex:{type:[String,Number],default:void 0}}),eee={tabClick:(e,t,r)=>r instanceof Event,tabRemove:(e,t)=>t instanceof Event},_g="ElTabNav",tee=n.defineComponent({name:_g,props:XX,emits:eee,setup(e,{expose:t,emit:r}){const o=n.inject(Kd);o||gn(_g,"<el-tabs><tab-nav /></el-tabs>");const a=he("tabs"),i=mz(),l=vz(),s=n.ref(),c=n.ref(),u=n.ref(),d=n.ref({}),f=n.ref(),p=n.ref(!1),h=n.ref(0),m=n.ref(!1),g=n.ref(!0),v=n.shallowRef(),y=n.computed(()=>["top","bottom"].includes(o.props.tabPosition)),N=n.computed(()=>y.value?"width":"height"),b=n.computed(()=>({transform:`translate${N.value==="width"?"X":"Y"}(-${h.value}px)`})),{width:M,height:k}=E1(s),{width:w,height:C}=E1(c,{width:0,height:0},{box:"border-box"}),E=n.computed(()=>y.value?M.value:k.value),A=n.computed(()=>y.value?w.value:C.value),{onWheel:O}=bb({atStartEdge:n.computed(()=>h.value<=0),atEndEdge:n.computed(()=>A.value-h.value<=E.value),layout:n.computed(()=>y.value?"horizontal":"vertical")},L=>{h.value=wa(h.value+L,0,A.value-E.value)}),_=()=>{if(!s.value)return;const L=s.value[`offset${Vo(N.value)}`],B=h.value;if(!B)return;const F=B>L?B-L:0;h.value=F},j=()=>{if(!s.value||!c.value)return;const L=c.value[`offset${Vo(N.value)}`],B=s.value[`offset${Vo(N.value)}`],F=h.value;if(L-F<=B)return;const T=L-F>B*2?F+B:L-B;h.value=T},R=async()=>{const L=c.value;if(!p.value||!u.value||!s.value||!L)return;await n.nextTick();const B=d.value[e.currentName];if(!B)return;const F=s.value,T=B.getBoundingClientRect(),z=F.getBoundingClientRect(),I=y.value?L.offsetWidth-z.width:L.offsetHeight-z.height,Z=h.value;let q=Z;y.value?(T.left<z.left&&(q=Z-(z.left-T.left)),T.right>z.right&&(q=Z+T.right-z.right)):(T.top<z.top&&(q=Z-(z.top-T.top)),T.bottom>z.bottom&&(q=Z+(T.bottom-z.bottom))),q=Math.max(q,0),h.value=Math.min(q,I)},P=()=>{var L;if(!c.value||!s.value)return;e.stretch&&((L=f.value)==null||L.update());const B=c.value[`offset${Vo(N.value)}`],F=s.value[`offset${Vo(N.value)}`],T=h.value;F<B?(p.value=p.value||{},p.value.prev=T,p.value.next=T+F<B,B-T<F&&(h.value=B-F)):(p.value=!1,T>0&&(h.value=0))},$=L=>{const B=Lt(L);let F=0;switch(B){case ve.left:case ve.up:F=-1;break;case ve.right:case ve.down:F=1;break;default:return}const T=Array.from(L.currentTarget.querySelectorAll("[role=tab]:not(.is-disabled)"));let I=T.indexOf(L.target)+F;I<0?I=T.length-1:I>=T.length&&(I=0),T[I].focus({preventScroll:!0}),T[I].click(),V()},V=()=>{g.value&&(m.value=!0)},D=()=>m.value=!1,x=(L,B)=>{d.value[B]=L},S=async()=>{await n.nextTick();const L=d.value[e.currentName];L==null||L.focus({preventScroll:!0})};return n.watch(i,L=>{L==="hidden"?g.value=!1:L==="visible"&&setTimeout(()=>g.value=!0,50)}),n.watch(l,L=>{L?setTimeout(()=>g.value=!0,50):g.value=!1}),zt(u,()=>{Bm(P)}),n.onMounted(()=>setTimeout(()=>R(),0)),n.onUpdated(()=>P()),t({scrollToActiveTab:R,removeFocus:D,focusActiveTab:S,tabListRef:c,tabBarRef:f,scheduleRender:()=>n.triggerRef(v)}),()=>{const L=p.value?[n.createVNode("span",{class:[a.e("nav-prev"),a.is("disabled",!p.value.prev)],onClick:_},[n.createVNode(ke,null,{default:()=>[n.createVNode(ji,null,null)]})]),n.createVNode("span",{class:[a.e("nav-next"),a.is("disabled",!p.value.next)],onClick:j},[n.createVNode(ke,null,{default:()=>[n.createVNode(Wo,null,null)]})])]:null,B=e.panes.map((F,T)=>{var z,I,Z,q,te;const J=F.uid,W=F.props.disabled,ae=(I=(z=F.props.name)!=null?z:F.index)!=null?I:`${T}`,ce=!W&&(F.isClosable||F.props.closable!==!1&&e.editable);F.index=`${T}`;const ye=ce?n.createVNode(ke,{class:"is-icon-close",onClick:_e=>r("tabRemove",F,_e)},{default:()=>[n.createVNode(bo,null,null)]}):null,Ae=((q=(Z=F.slots).label)==null?void 0:q.call(Z))||F.props.label,Fe=!W&&F.active?(te=e.tabindex)!=null?te:o.props.tabindex:-1;return n.createVNode("div",{ref:_e=>x(_e,ae),class:[a.e("item"),a.is(o.props.tabPosition),a.is("active",F.active),a.is("disabled",W),a.is("closable",ce),a.is("focus",m.value)],id:`tab-${ae}`,key:`tab-${J}`,"aria-controls":`pane-${ae}`,role:"tab","aria-selected":F.active,tabindex:Fe,onFocus:()=>V(),onBlur:()=>D(),onClick:_e=>{D(),r("tabClick",F,ae,_e)},onKeydown:_e=>{const Le=Lt(_e);ce&&(Le===ve.delete||Le===ve.backspace)&&r("tabRemove",F,_e)}},[Ae,ye])});return v.value,n.createVNode("div",{ref:u,class:[a.e("nav-wrap"),a.is("scrollable",!!p.value),a.is(o.props.tabPosition)]},[L,n.createVNode("div",{class:a.e("nav-scroll"),ref:s},[e.panes.length>0?n.createVNode("div",{class:[a.e("nav"),a.is(o.props.tabPosition),a.is("stretch",e.stretch&&["top","bottom"].includes(o.props.tabPosition))],ref:c,style:b.value,role:"tablist",onKeydown:$,onWheel:O},[e.type?null:n.createVNode(ZX,{ref:f,tabs:[...e.panes],tabRefs:d.value},null),B]):null])])}}}),nee=ge({type:{type:String,values:["card","border-card",""],default:""},closable:Boolean,addable:Boolean,modelValue:{type:[String,Number]},defaultValue:{type:[String,Number]},editable:Boolean,tabPosition:{type:String,values:["top","right","bottom","left"],default:"top"},beforeLeave:{type:K(Function),default:()=>!0},stretch:Boolean,tabindex:{type:[String,Number],default:0}}),$f=e=>nt(e)||Ve(e),ree={[$e]:e=>$f(e),tabClick:(e,t)=>t instanceof Event,tabChange:e=>$f(e),edit:(e,t)=>["remove","add"].includes(t),tabRemove:e=>$f(e),tabAdd:()=>!0},oee=n.defineComponent({name:"ElTabs",props:nee,emits:ree,setup(e,{emit:t,slots:r,expose:o}){var a;const i=he("tabs"),l=n.computed(()=>["left","right"].includes(e.tabPosition)),{children:s,addChild:c,removeChild:u,ChildrenSorter:d}=SW(n.getCurrentInstance(),"ElTabPane"),f=n.ref(),p=n.ref((a=Rt(e.modelValue)?e.defaultValue:e.modelValue)!=null?a:"0"),h=async(b,M=!1)=>{var k,w,C,E;if(!(p.value===b||Rt(b)))try{let A;if(e.beforeLeave){const O=e.beforeLeave(b,p.value);A=O instanceof Promise?await O:O}else A=!0;if(A!==!1){const O=(k=s.value.find(_=>_.paneName===p.value))==null?void 0:k.isFocusInsidePane();p.value=b,M&&(t($e,b),t("tabChange",b)),(C=(w=f.value)==null?void 0:w.removeFocus)==null||C.call(w),O&&((E=f.value)==null||E.focusActiveTab())}}catch{}},m=(b,M,k)=>{b.props.disabled||(t("tabClick",b,k),h(M,!0))},g=(b,M)=>{b.props.disabled||Rt(b.props.name)||(M.stopPropagation(),t("edit",b.props.name,"remove"),t("tabRemove",b.props.name))},v=()=>{t("edit",void 0,"add"),t("tabAdd")},y=b=>{const M=Lt(b);[ve.enter,ve.numpadEnter].includes(M)&&v()},N=b=>{const M=b.el.firstChild,k=["bottom","right"].includes(e.tabPosition)?b.children[0].el:b.children[1].el;M!==k&&M.before(k)};return n.watch(()=>e.modelValue,b=>h(b)),n.watch(p,async()=>{var b;await n.nextTick(),(b=f.value)==null||b.scrollToActiveTab()}),n.provide(Kd,{props:e,currentName:p,registerPane:c,unregisterPane:u,nav$:f}),o({currentName:p,get tabNavRef(){return Vd(f.value,["scheduleRender"])}}),()=>{const b=r["add-icon"],M=e.editable||e.addable?n.createVNode("div",{class:[i.e("new-tab"),l.value&&i.e("new-tab-vertical")],tabindex:e.tabindex,onClick:v,onKeydown:y},[b?n.renderSlot(r,"add-icon"):n.createVNode(ke,{class:i.is("icon-plus")},{default:()=>[n.createVNode(Fm,null,null)]})]):null,k=()=>n.createVNode(tee,{ref:f,currentName:p.value,editable:e.editable,type:e.type,panes:s.value,stretch:e.stretch,onTabClick:m,onTabRemove:g},null),w=n.createVNode("div",{class:[i.e("header"),l.value&&i.e("header-vertical"),i.is(e.tabPosition)]},[n.createVNode(d,null,{default:k,$stable:!0}),M]),C=n.createVNode("div",{class:i.e("content")},[n.renderSlot(r,"default")]);return n.createVNode("div",{class:[i.b(),i.m(e.tabPosition),{[i.m("card")]:e.type==="card",[i.m("border-card")]:e.type==="border-card"}],onVnodeMounted:N,onVnodeUpdated:N},[C,w])}}}),aee=ge({label:{type:String,default:""},name:{type:[String,Number]},closable:{type:Boolean,default:void 0},disabled:Boolean,lazy:Boolean}),iee=["id","aria-hidden","aria-labelledby"],Ig="ElTabPane";var Db=n.defineComponent({name:Ig,__name:"tab-pane",props:aee,setup(e){const t=e,r=n.getCurrentInstance(),o=n.useSlots(),a=n.inject(Kd);a||gn(Ig,"usage: <el-tabs><el-tab-pane /></el-tabs/>");const i=he("tab-pane"),l=n.ref(),s=n.ref(),c=n.computed(()=>{var g;return(g=t.closable)!=null?g:a.props.closable}),u=n.computed(()=>{var g;return a.currentName.value===((g=t.name)!=null?g:s.value)}),d=n.ref(u.value),f=n.computed(()=>{var g;return(g=t.name)!=null?g:s.value}),p=n.computed(()=>!t.lazy||d.value||u.value),h=()=>{var g;return(g=l.value)==null?void 0:g.contains(document.activeElement)};n.watch(u,g=>{g&&(d.value=!0)});const m=n.reactive({uid:r.uid,getVnode:()=>r.vnode,slots:o,props:t,paneName:f,active:u,index:s,isClosable:c,isFocusInsidePane:h});return a.registerPane(m),n.onBeforeUnmount(()=>{a.unregisterPane(m)}),n.onBeforeUpdate(()=>{var g;o.label&&((g=a.nav$.value)==null||g.scheduleRender())}),(g,v)=>p.value?n.withDirectives((n.openBlock(),n.createElementBlock("div",{key:0,id:`pane-${f.value}`,ref_key:"paneRef",ref:l,class:n.normalizeClass(n.unref(i).b()),role:"tabpanel","aria-hidden":!u.value,"aria-labelledby":`tab-${f.value}`},[n.renderSlot(g.$slots,"default")],10,iee)),[[n.vShow,u.value]]):n.createCommentVNode("v-if",!0)}});const lee=it(oee,{TabPane:Db}),see=Gn(Db);var cee=Object.defineProperty,uee=(e,t,r)=>t in e?cee(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Mc=(e,t,r)=>uee(e,typeof t!="symbol"?t+"":t,r);const dee="ElUpload";class fee extends Error{constructor(t,r,o,a){super(t),Mc(this,"name","UploadAjaxError"),Mc(this,"status"),Mc(this,"method"),Mc(this,"url"),this.status=r,this.method=o,this.url=a}}function Ag(e,t,r){let o;return r.response?o=`${r.response.error||r.response}`:r.responseText?o=`${r.responseText}`:o=`fail to ${t.method} ${e} ${r.status}`,new fee(o,r.status,t.method,e)}function pee(e){const t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch{return t}}const mee=e=>{typeof XMLHttpRequest>"u"&&gn(dee,"XMLHttpRequest is undefined");const t=new XMLHttpRequest,r=e.action;t.upload&&t.upload.addEventListener("progress",i=>{const l=i;l.percent=i.total>0?i.loaded/i.total*100:0,e.onProgress(l)});const o=new FormData;if(e.data)for(const[i,l]of Object.entries(e.data))De(l)&&l.length?o.append(i,...l):o.append(i,l);o.append(e.filename,e.file,e.file.name),t.addEventListener("error",()=>{e.onError(Ag(r,e,t))}),t.addEventListener("load",()=>{if(t.status<200||t.status>=300)return e.onError(Ag(r,e,t));e.onSuccess(pee(t))}),t.open(e.method,r,!0),e.withCredentials&&"withCredentials"in t&&(t.withCredentials=!0);const a=e.headers||{};if(a instanceof Headers)a.forEach((i,l)=>t.setRequestHeader(l,i));else for(const[i,l]of Object.entries(a))Hn(l)||t.setRequestHeader(i,String(l));return t.send(o),t},Sb=["text","picture","picture-card"];let hee=1;const d0=()=>Date.now()+hee++,_b=ge({action:{type:String,default:"#"},headers:{type:K(Object)},method:{type:String,default:"post"},data:{type:K([Object,Function,Promise]),default:()=>Wn({})},multiple:Boolean,name:{type:String,default:"file"},drag:Boolean,withCredentials:Boolean,showFileList:{type:Boolean,default:!0},accept:{type:String,default:""},fileList:{type:K(Array),default:()=>Wn([])},autoUpload:{type:Boolean,default:!0},listType:{type:String,values:Sb,default:"text"},httpRequest:{type:K(Function),default:mee},disabled:{type:Boolean,default:void 0},limit:Number,directory:Boolean}),gee=ge({..._b,beforeUpload:{type:K(Function),default:dt},beforeRemove:{type:K(Function)},onRemove:{type:K(Function),default:dt},onChange:{type:K(Function),default:dt},onPreview:{type:K(Function),default:dt},onSuccess:{type:K(Function),default:dt},onProgress:{type:K(Function),default:dt},onError:{type:K(Function),default:dt},onExceed:{type:K(Function),default:dt},crossorigin:{type:K(String)}}),Ib=Symbol("uploadContextKey"),vee=ge({files:{type:K(Array),default:()=>Wn([])},disabled:{type:Boolean,default:void 0},handlePreview:{type:K(Function),default:dt},listType:{type:String,values:Sb,default:"text"},crossorigin:{type:K(String)}}),yee={remove:e=>!!e},Mee=["tabindex","aria-disabled","onKeydown"],bee=["src","crossorigin"],wee=["onClick"],Nee=["title"],kee=["onClick"],xee=["onClick"];var Og=n.defineComponent({name:"ElUploadList",__name:"upload-list",props:vee,emits:yee,setup(e,{emit:t}){const r=e,o=t,{t:a}=Nt(),i=he("upload"),l=he("icon"),s=he("list"),c=Bt(),u=n.ref(!1),d=n.computed(()=>[i.b("list"),i.bm("list",r.listType),i.is("disabled",c.value)]),f=p=>{o("remove",p)};return(p,h)=>(n.openBlock(),n.createBlock(n.TransitionGroup,{tag:"ul",class:n.normalizeClass(d.value),name:n.unref(s).b()},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.files,(m,g)=>(n.openBlock(),n.createElementBlock("li",{key:m.uid||m.name,class:n.normalizeClass([n.unref(i).be("list","item"),n.unref(i).is(m.status),{focusing:u.value}]),tabindex:n.unref(c)?void 0:0,"aria-disabled":n.unref(c),role:"button",onKeydown:n.withKeys(v=>!n.unref(c)&&f(m),["delete"]),onFocus:h[0]||(h[0]=v=>u.value=!0),onBlur:h[1]||(h[1]=v=>u.value=!1),onClick:h[2]||(h[2]=v=>u.value=!1)},[n.renderSlot(p.$slots,"default",{file:m,index:g},()=>[e.listType==="picture"||m.status!=="uploading"&&e.listType==="picture-card"?(n.openBlock(),n.createElementBlock("img",{key:0,class:n.normalizeClass(n.unref(i).be("list","item-thumbnail")),src:m.url,crossorigin:e.crossorigin,alt:""},null,10,bee)):n.createCommentVNode("v-if",!0),m.status==="uploading"||e.listType!=="picture-card"?(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass(n.unref(i).be("list","item-info"))},[n.createElementVNode("a",{class:n.normalizeClass(n.unref(i).be("list","item-name")),onClick:n.withModifiers(v=>e.handlePreview(m),["prevent"])},[n.createVNode(n.unref(ke),{class:n.normalizeClass(n.unref(l).m("document"))},{default:n.withCtx(()=>[n.createVNode(n.unref(MM))]),_:1},8,["class"]),n.createElementVNode("span",{class:n.normalizeClass(n.unref(i).be("list","item-file-name")),title:m.name},n.toDisplayString(m.name),11,Nee)],10,wee),m.status==="uploading"?(n.openBlock(),n.createBlock(n.unref(db),{key:0,type:e.listType==="picture-card"?"circle":"line","stroke-width":e.listType==="picture-card"?6:2,percentage:Number(m.percentage),style:n.normalizeStyle(e.listType==="picture-card"?"":"margin-top: 0.5rem")},null,8,["type","stroke-width","percentage","style"])):n.createCommentVNode("v-if",!0)],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("label",{class:n.normalizeClass(n.unref(i).be("list","item-status-label"))},[e.listType==="text"?(n.openBlock(),n.createBlock(n.unref(ke),{key:0,class:n.normalizeClass([n.unref(l).m("upload-success"),n.unref(l).m("circle-check")])},{default:n.withCtx(()=>[n.createVNode(n.unref(Fd))]),_:1},8,["class"])):["picture-card","picture"].includes(e.listType)?(n.openBlock(),n.createBlock(n.unref(ke),{key:1,class:n.normalizeClass([n.unref(l).m("upload-success"),n.unref(l).m("check")])},{default:n.withCtx(()=>[n.createVNode(n.unref($m))]),_:1},8,["class"])):n.createCommentVNode("v-if",!0)],2),n.unref(c)?n.createCommentVNode("v-if",!0):(n.openBlock(),n.createBlock(n.unref(ke),{key:2,class:n.normalizeClass(n.unref(l).m("close")),onClick:v=>f(m)},{default:n.withCtx(()=>[n.createVNode(n.unref(bo))]),_:1},8,["class","onClick"])),n.createCommentVNode(" Due to close btn only appears when li gets focused disappears after li gets blurred, thus keyboard navigation can never reach close btn"),n.createCommentVNode(" This is a bug which needs to be fixed "),n.createCommentVNode(" TODO: Fix the incorrect navigation interaction "),n.unref(c)?n.createCommentVNode("v-if",!0):(n.openBlock(),n.createElementBlock("i",{key:3,class:n.normalizeClass(n.unref(l).m("close-tip"))},n.toDisplayString(n.unref(a)("el.upload.deleteTip")),3)),e.listType==="picture-card"?(n.openBlock(),n.createElementBlock("span",{key:4,class:n.normalizeClass(n.unref(i).be("list","item-actions"))},[n.createElementVNode("span",{class:n.normalizeClass(n.unref(i).be("list","item-preview")),onClick:v=>e.handlePreview(m)},[n.createVNode(n.unref(ke),{class:n.normalizeClass(n.unref(l).m("zoom-in"))},{default:n.withCtx(()=>[n.createVNode(n.unref(Hm))]),_:1},8,["class"])],10,kee),n.unref(c)?n.createCommentVNode("v-if",!0):(n.openBlock(),n.createElementBlock("span",{key:0,class:n.normalizeClass(n.unref(i).be("list","item-delete")),onClick:v=>f(m)},[n.createVNode(n.unref(ke),{class:n.normalizeClass(n.unref(l).m("delete"))},{default:n.withCtx(()=>[n.createVNode(n.unref(yM))]),_:1},8,["class"])],10,xee))],2)):n.createCommentVNode("v-if",!0)])],42,Mee))),128)),n.renderSlot(p.$slots,"append")]),_:3},8,["class","name"]))}});const Cee=ge({..._b,beforeUpload:{type:K(Function),default:dt},onRemove:{type:K(Function),default:dt},onStart:{type:K(Function),default:dt},onSuccess:{type:K(Function),default:dt},onProgress:{type:K(Function),default:dt},onError:{type:K(Function),default:dt},onExceed:{type:K(Function),default:dt}}),Eee=ge({disabled:{type:Boolean,default:void 0},directory:Boolean}),Tee={file:e=>De(e)},zg="ElUploadDrag";var Dee=n.defineComponent({name:zg,__name:"upload-dragger",props:Eee,emits:Tee,setup(e,{emit:t}){const r=e,o=t;n.inject(Ib)||gn(zg,"usage: <el-upload><el-upload-dragger /></el-upload>");const i=he("upload"),l=n.ref(!1),s=Bt(),c=h=>new Promise((m,g)=>h.file(m,g)),u=async h=>{try{if(h.isFile){const m=await c(h);return m.isDirectory=!1,[m]}if(h.isDirectory){const m=h.createReader(),g=()=>new Promise((M,k)=>m.readEntries(M,k)),v=[];let y=await g();for(;y.length>0;)v.push(...y),y=await g();const N=v.map(M=>u(M).catch(()=>[])),b=await Promise.all(N);return lu(b)}}catch{return[]}return[]},d=async h=>{if(s.value)return;l.value=!1,h.stopPropagation();const m=Array.from(h.dataTransfer.files),g=h.dataTransfer.items||[];if(r.directory){const v=Array.from(g).map(N=>{var b;return(b=N==null?void 0:N.webkitGetAsEntry)==null?void 0:b.call(N)}).filter(N=>N),y=await Promise.all(v.map(u));o("file",lu(y));return}m.forEach((v,y)=>{var N;const b=g[y],M=(N=b==null?void 0:b.webkitGetAsEntry)==null?void 0:N.call(b);M&&(v.isDirectory=M.isDirectory)}),o("file",m)},f=()=>{s.value||(l.value=!0)},p=h=>{h.currentTarget.contains(h.relatedTarget)||(l.value=!1)};return(h,m)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([n.unref(i).b("dragger"),n.unref(i).is("dragover",l.value)]),onDrop:n.withModifiers(d,["prevent"]),onDragover:n.withModifiers(f,["prevent"]),onDragleave:n.withModifiers(p,["prevent"])},[n.renderSlot(h.$slots,"default")],34))}});const See=["tabindex","aria-disabled","onKeydown"],_ee=["name","disabled","multiple","accept","webkitdirectory"];var jg=n.defineComponent({name:"ElUploadContent",inheritAttrs:!1,__name:"upload-content",props:Cee,setup(e,{expose:t}){const r=e,o=he("upload"),a=Bt(),i=n.shallowRef({}),l=n.shallowRef(),s=g=>{if(g.length===0)return;const{autoUpload:v,limit:y,fileList:N,multiple:b,onStart:M,onExceed:k}=r;if(y&&N.length+g.length>y){k(g,N);return}b||(g=g.slice(0,1));for(const w of g){const C=w;C.uid=d0(),M(C),v&&c(C)}},c=async g=>{if(l.value.value="",!r.beforeUpload)return d(g);let v,y={};try{const b=r.data,M=r.beforeUpload(g);y=Hp(r.data)?y1(r.data):r.data,v=await M,Hp(r.data)&&Yt(b,y)&&(y=y1(r.data))}catch{v=!1}if(v===!1){r.onRemove(g);return}let N=g;v instanceof Blob&&(v instanceof File?N=v:N=new File([v],g.name,{type:g.type})),d(Object.assign(N,{uid:g.uid}),y)},u=async(g,v)=>at(g)?g(v):g,d=async(g,v)=>{const{headers:y,data:N,method:b,withCredentials:M,name:k,action:w,onProgress:C,onSuccess:E,onError:A,httpRequest:O}=r;try{v=await u(v??N,g)}catch{r.onRemove(g);return}const{uid:_}=g,j={headers:y||{},withCredentials:M,file:g,data:v,method:b,filename:k,action:w,onProgress:P=>{C(P,g)},onSuccess:P=>{E(P,g),delete i.value[_]},onError:P=>{A(P,g),delete i.value[_]}},R=O(j);i.value[_]=R,R instanceof Promise&&R.then(j.onSuccess,j.onError)},f=g=>{const v=g.target.files;v&&s(Array.from(v))},p=()=>{a.value||(l.value.value="",l.value.click())},h=()=>{p()};return t({abort:g=>{kz(i.value).filter(g?([y])=>String(g.uid)===y:()=>!0).forEach(([y,N])=>{N instanceof XMLHttpRequest&&N.abort(),delete i.value[y]})},upload:c}),(g,v)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([n.unref(o).b(),n.unref(o).m(e.listType),n.unref(o).is("drag",e.drag),n.unref(o).is("disabled",n.unref(a))]),tabindex:n.unref(a)?void 0:0,"aria-disabled":n.unref(a),role:"button",onClick:p,onKeydown:n.withKeys(n.withModifiers(h,["self"]),["enter","space"])},[e.drag?(n.openBlock(),n.createBlock(Dee,{key:0,disabled:n.unref(a),directory:e.directory,onFile:s},{default:n.withCtx(()=>[n.renderSlot(g.$slots,"default")]),_:3},8,["disabled","directory"])):n.renderSlot(g.$slots,"default",{key:1}),n.createElementVNode("input",{ref_key:"inputRef",ref:l,class:n.normalizeClass(n.unref(o).e("input")),name:e.name,disabled:n.unref(a),multiple:e.multiple,accept:e.accept,webkitdirectory:e.directory||void 0,type:"file",onChange:f,onClick:v[0]||(v[0]=n.withModifiers(()=>{},["stop"]))},null,42,_ee)],42,See))}});const Lg="ElUpload",Bg=e=>{var t;(t=e.url)!=null&&t.startsWith("blob:")&&URL.revokeObjectURL(e.url)},Iee=(e,t)=>{const r=gz(e,"fileList",void 0,{passive:!0}),o=m=>r.value.find(g=>g.uid===m.uid);function a(m){var g;(g=t.value)==null||g.abort(m)}function i(m=["ready","uploading","success","fail"]){r.value=r.value.filter(g=>!m.includes(g.status))}function l(m){r.value=r.value.filter(g=>g.uid!==m.uid)}const s=m=>{n.nextTick(()=>e.onChange(m,r.value))},c=(m,g)=>{const v=o(g);v&&(console.error(m),v.status="fail",l(v),e.onError(m,v,r.value),s(v))},u=(m,g)=>{const v=o(g);v&&(e.onProgress(m,v,r.value),v.status="uploading",v.percentage=Math.round(m.percent))},d=(m,g)=>{const v=o(g);v&&(v.status="success",v.response=m,e.onSuccess(m,v,r.value),s(v))},f=m=>{Hn(m.uid)&&(m.uid=d0());const g={name:m.name,percentage:0,status:"ready",size:m.size,raw:m,uid:m.uid};if(e.listType==="picture-card"||e.listType==="picture")try{g.url=URL.createObjectURL(m)}catch(v){He(Lg,v.message),e.onError(v,g,r.value)}r.value=[...r.value,g],s(g)},p=async m=>{const g=m instanceof File?o(m):m;g||gn(Lg,"file to be removed not found");const v=y=>{a(y),l(y),e.onRemove(y,r.value),Bg(y)};e.beforeRemove?await e.beforeRemove(g,r.value)!==!1&&v(g):v(g)};function h(){r.value.filter(({status:m})=>m==="ready").forEach(({raw:m})=>{var g;return m&&((g=t.value)==null?void 0:g.upload(m))})}return n.watch(()=>e.listType,m=>{m!=="picture-card"&&m!=="picture"||(r.value=r.value.map(g=>{const{raw:v,url:y}=g;if(!y&&v)try{g.url=URL.createObjectURL(v)}catch(N){e.onError(N,g,r.value)}return g}))}),n.watch(r,m=>{for(const g of m)g.uid||(g.uid=d0()),g.status||(g.status="success")},{immediate:!0,deep:!0}),{uploadFiles:r,abort:a,clearFiles:i,handleError:c,handleProgress:u,handleStart:f,handleSuccess:d,handleRemove:p,submit:h,revokeFileObjectURL:Bg}};var Aee=n.defineComponent({name:"ElUpload",__name:"upload",props:gee,setup(e,{expose:t}){const r=e,o=Bt(),a=n.shallowRef(),{abort:i,submit:l,clearFiles:s,uploadFiles:c,handleStart:u,handleError:d,handleRemove:f,handleSuccess:p,handleProgress:h,revokeFileObjectURL:m}=Iee(r,a),g=n.computed(()=>r.listType==="picture-card"),v=n.computed(()=>({...r,fileList:c.value,onStart:u,onProgress:h,onSuccess:p,onError:d,onRemove:f}));return n.onBeforeUnmount(()=>{c.value.forEach(m)}),n.provide(Ib,{accept:n.toRef(r,"accept")}),t({abort:i,submit:l,clearFiles:s,handleStart:u,handleRemove:f}),(y,N)=>(n.openBlock(),n.createElementBlock("div",null,[g.value&&e.showFileList?(n.openBlock(),n.createBlock(Og,{key:0,disabled:n.unref(o),"list-type":e.listType,files:n.unref(c),crossorigin:e.crossorigin,"handle-preview":e.onPreview,onRemove:n.unref(f)},n.createSlots({append:n.withCtx(()=>[n.createVNode(jg,n.mergeProps({ref_key:"uploadRef",ref:a},v.value),{default:n.withCtx(()=>[y.$slots.trigger?n.renderSlot(y.$slots,"trigger",{key:0}):n.createCommentVNode("v-if",!0),!y.$slots.trigger&&y.$slots.default?n.renderSlot(y.$slots,"default",{key:1}):n.createCommentVNode("v-if",!0)]),_:3},16)]),_:2},[y.$slots.file?{name:"default",fn:n.withCtx(({file:b,index:M})=>[n.renderSlot(y.$slots,"file",{file:b,index:M})]),key:"0"}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):n.createCommentVNode("v-if",!0),!g.value||g.value&&!e.showFileList?(n.openBlock(),n.createBlock(jg,n.mergeProps({key:1,ref_key:"uploadRef",ref:a},v.value),{default:n.withCtx(()=>[y.$slots.trigger?n.renderSlot(y.$slots,"trigger",{key:0}):n.createCommentVNode("v-if",!0),!y.$slots.trigger&&y.$slots.default?n.renderSlot(y.$slots,"default",{key:1}):n.createCommentVNode("v-if",!0)]),_:3},16)):n.createCommentVNode("v-if",!0),y.$slots.trigger?n.renderSlot(y.$slots,"default",{key:2}):n.createCommentVNode("v-if",!0),n.renderSlot(y.$slots,"tip"),!g.value&&e.showFileList?(n.openBlock(),n.createBlock(Og,{key:3,disabled:n.unref(o),"list-type":e.listType,files:n.unref(c),crossorigin:e.crossorigin,"handle-preview":e.onPreview,onRemove:n.unref(f)},n.createSlots({_:2},[y.$slots.file?{name:"default",fn:n.withCtx(({file:b,index:M})=>[n.renderSlot(y.$slots,"file",{file:b,index:M})]),key:"0"}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):n.createCommentVNode("v-if",!0)]))}});const Oee=it(Aee);function zee(e,t){let r;const o=n.ref(!1),a=n.reactive({...e,originalPosition:"",originalOverflow:"",visible:!1});function i(h){a.text=h}function l(){const h=a.parent,m=p.ns;if(!h.vLoadingAddClassList){let g=h.getAttribute("loading-number");g=Number.parseInt(g)-1,g?h.setAttribute("loading-number",g.toString()):(cs(h,m.bm("parent","relative")),h.removeAttribute("loading-number")),cs(h,m.bm("parent","hidden"))}s(),f.unmount()}function s(){var h,m;(m=(h=p.$el)==null?void 0:h.parentNode)==null||m.removeChild(p.$el)}function c(){var h;e.beforeClose&&!e.beforeClose()||(o.value=!0,clearTimeout(r),r=setTimeout(u,400),a.visible=!1,(h=e.closed)==null||h.call(e))}function u(){if(!o.value)return;const h=a.parent;o.value=!1,h.vLoadingAddClassList=void 0,l()}const d=n.defineComponent({name:"ElLoading",setup(h,{expose:m}){const{ns:g,zIndex:v}=xz("loading");return m({ns:g,zIndex:v}),()=>{const y=a.spinner||a.svg,N=n.h("svg",{class:"circular",viewBox:a.svgViewBox?a.svgViewBox:"0 0 50 50",...y?{innerHTML:y}:{}},[n.h("circle",{class:"path",cx:"25",cy:"25",r:"20",fill:"none"})]),b=a.text?n.h("p",{class:g.b("text")},[a.text]):void 0;return n.h(n.Transition,{name:g.b("fade"),onAfterLeave:u},{default:n.withCtx(()=>[n.withDirectives(n.createVNode("div",{style:{backgroundColor:a.background||""},class:[g.b("mask"),a.customClass,g.is("fullscreen",a.fullscreen)]},[n.h("div",{class:g.b("spinner")},[N,b])]),[[n.vShow,a.visible]])])})}}}),f=n.createApp(d);Object.assign(f._context,t??{});const p=f.mount(document.createElement("div"));return{...n.toRefs(a),setText:i,removeElLoadingChild:s,close:c,handleAfterLeave:u,vm:p,get $el(){return p.$el}}}let bc;const Ti=function(e={},t){if(!tt)return;const r=jee(e);if(r.fullscreen&&bc)return bc;const o=zee({...r,closed:()=>{var i;(i=r.closed)==null||i.call(r),r.fullscreen&&(bc=void 0)}},t??Ti._context);Lee(r,r.parent,o),Vg(r,r.parent,o),r.parent.vLoadingAddClassList=()=>Vg(r,r.parent,o);let a=r.parent.getAttribute("loading-number");return a?a=`${Number.parseInt(a)+1}`:a="1",r.parent.setAttribute("loading-number",a),r.parent.appendChild(o.$el),n.nextTick(()=>o.visible.value=r.visible),r.fullscreen&&(bc=o),o},jee=e=>{var t,r,o,a;let i;return nt(e.target)?i=(t=document.querySelector(e.target))!=null?t:document.body:i=e.target||document.body,{parent:i===document.body||e.body?document.body:i,background:e.background||"",svg:e.svg||"",svgViewBox:e.svgViewBox||"",spinner:e.spinner||!1,text:e.text||"",fullscreen:i===document.body&&((r=e.fullscreen)!=null?r:!0),lock:(o=e.lock)!=null?o:!1,customClass:e.customClass||"",visible:(a=e.visible)!=null?a:!0,beforeClose:e.beforeClose,closed:e.closed,target:i}},Lee=async(e,t,r)=>{const{nextZIndex:o}=r.vm.zIndex||r.vm._.exposed.zIndex,a={};if(e.fullscreen)r.originalPosition.value=Bo(document.body,"position"),r.originalOverflow.value=Bo(document.body,"overflow"),a.zIndex=o();else if(e.parent===document.body){r.originalPosition.value=Bo(document.body,"position"),await n.nextTick();for(const i of["top","left"]){const l=i==="top"?"scrollTop":"scrollLeft";a[i]=`${e.target.getBoundingClientRect()[i]+document.body[l]+document.documentElement[l]-Number.parseInt(Bo(document.body,`margin-${i}`),10)}px`}for(const i of["height","width"])a[i]=`${e.target.getBoundingClientRect()[i]}px`}else r.originalPosition.value=Bo(t,"position");for(const[i,l]of Object.entries(a))r.$el.style[i]=l},Vg=(e,t,r)=>{const o=r.vm.ns||r.vm._.exposed.ns;["absolute","fixed","sticky"].includes(r.originalPosition.value)?cs(t,o.bm("parent","relative")):Yp(t,o.bm("parent","relative")),e.fullscreen&&e.lock?Yp(t,o.bm("parent","hidden")):cs(t,o.bm("parent","hidden"))};Ti._context=null;const Al=Symbol("ElLoading"),ga=e=>`element-loading-${GO(e)}`,$g=(e,t)=>{var r,o,a,i;const l=t.instance,s=h=>ft(t.value)?t.value[h]:void 0,c=h=>{const m=nt(h)&&(l==null?void 0:l[h])||h;return n.ref(m)},u=h=>c(s(h)||e.getAttribute(ga(h))),d=(r=s("fullscreen"))!=null?r:t.modifiers.fullscreen,f={text:u("text"),svg:u("svg"),svgViewBox:u("svgViewBox"),spinner:u("spinner"),background:u("background"),customClass:u("customClass"),fullscreen:d,target:(o=s("target"))!=null?o:d?void 0:e,body:(a=s("body"))!=null?a:t.modifiers.body,lock:(i=s("lock"))!=null?i:t.modifiers.lock},p=Ti(f);p._context=Rl._context,e[Al]={options:f,instance:p}},Bee=(e,t)=>{for(const r of Object.keys(e))n.isRef(e[r])&&(e[r].value=t[r])},Rl={mounted(e,t){t.value&&$g(e,t)},updated(e,t){const r=e[Al];if(!t.value){r==null||r.instance.close(),e[Al]=null;return}r?Bee(r.options,ft(t.value)?t.value:{text:e.getAttribute(ga("text")),svg:e.getAttribute(ga("svg")),svgViewBox:e.getAttribute(ga("svgViewBox")),spinner:e.getAttribute(ga("spinner")),background:e.getAttribute(ga("background")),customClass:e.getAttribute(ga("customClass"))}):$g(e,t)},unmounted(e){var t;(t=e[Al])==null||t.instance.close(),e[Al]=null}};Rl._context=null;const Vee={install(e){Ti._context=e._context,Rl._context=e._context,e.directive("loading",Rl),e.config.globalProperties.$loading=Ti},directive:Rl,service:Ti},Eh="pt-br",Pg={"pt-br":{"simple-filter":"Filtro simples","advanced-filter":"Filtro avançado","search-placeholder":"Digite algo para buscar",searching:"Procurando","recently-searched":"Buscas recentes","send-for-all":"Enviar para todos","show-more":"Mostrar mais","load-more":"Carregar mais","search-for-markers-classes-users":"Busque por marcadores, turmas, alunos e usuários","when-you-have-markers-classes":"Quando você tiver marcadores e turmas, eles aparecerão aqui.","not-found":"Não encontramos resultados","make-sure-to-type-something":"Tenha certeza que você está digitando uma palavra-chave correta",clean:"Limpar","see-all":"Ver todos","selected-recipients":"Destinatários selecionados",cancel:"Cancelar",continue:"Continuar","show-for-all-tags":"Você já selecionou alguns destinatários e eles serão substituídos pela tag todos.","one-result-found":"1 resultado encontrado","results-found":" resultados encontrados","error-target-loading":"Erro ao carregar o público alvo.","error-searching":"Erro ao buscar o público desejado.","add-filter":"Adicionar filtro",save:"Salvar",search:"Pesquisar",bold:"Negrito",italic:"Itálico",underline:"Sublinhado",title:"Título","bullet-list":"Lista com marcadores","numbered-list":"Lista numerada",link:"Inserir link",blockquote:"Citação","remove-formatting":"Remover formatação","insert-link":"Insira um link","insert-valid-link":"Insira um link válido",insert:"Inserir","edit-link":"Editar link","remove-link":"Remover link","text-editor-placeholder":"Escreva algo...","date-editor-relative-past":"Relativo - Passado","date-editor-relative-future":"Relativo - Futuro","date-editor-absolute":"Absoluto","date-relative-comparation-lt":"Há menos de","date-relative-comparation-gt":"Há mais de","date-relative-comparation-eq":"Há exatamente","date-relative-future-gt":"Daqui a mais de","date-relative-future-lt":"Daqui a menos de","date-relative-future-eq":"Daqui a exatamente","date-absolute-eq":"Em","date-absolute-gte":"A partir de","date-absolute-lt":"Até","type-to-filter":"Digite para filtrar","choose-a-mode-to-filter":"Escolha um modo para filtrar","less-than":"Menor que","less-or-equal":"Menor ou igual a","greater-than":"Maior que","greater-or-equal":"Maior ou igual a",equal:"Igual a",different:"Diferente de",contains:"Contém","starts-at":"Começa em","ends-at":"Termina em",exactly:"É exatamente","not-equal":"Não é","start-placeholder":"Do dia","end-placeholder":"Ao dia","placeholder-date":"Selecione uma data",time:"Horário",date:"Selecione uma data","from-day":"Do dia","to-day":"Ao dia","calendar-weekday-sunday":"Dom","calendar-weekday-monday":"Seg","calendar-weekday-tuesday":"Ter","calendar-weekday-wednesday":"Qua","calendar-weekday-thursday":"Qui","calendar-weekday-friday":"Sex","calendar-weekday-saturday":"Sáb","calendar-month-january":"Janeiro","calendar-month-february":"Fevereiro","calendar-month-march":"Março","calendar-month-april":"Abril","calendar-month-may":"Maio","calendar-month-june":"Junho","calendar-month-july":"Julho","calendar-month-august":"Agosto","calendar-month-september":"Setembro","calendar-month-october":"Outubro","calendar-month-november":"Novembro","calendar-month-december":"Dezembro","calendar-date-separator":" de "},en:{"simple-filter":"Simple filter","advanced-filter":"Advanced filter","search-placeholder":"Type something to search",searching:"Searching","recently-searched":"Recently searched","send-for-all":"Send for all","show-more":"Show more","load-more":"Load more","search-for-markers-classes-users":"Search for markers, classes, students, and users","when-you-have-markers-classes":"When you have markers and classes, they will appear here.","not-found":"We did not find any results","make-sure-to-type-something":"Make sure you are typing a correct keyword",clean:"Clean","see-all":"See all","selected-recipients":"Selected recipients",cancel:"Cancel",continue:"Continue","show-for-all-tags":"You have already selected some recipients and they will be replaced by the tag all.","one-result-found":"1 result found","results-found":" results found","error-target-loading":"Error loading target audience.","error-searching":"Error searching for the desired audience.","add-filter":"Add filter",save:"Save",search:"Search",bold:"Bold",italic:"Italic",underline:"Underline",title:"Title","bullet-list":"Bullet list","numbered-list":"Numbered list",link:"Insert link",blockquote:"Blockquote","remove-formatting":"Remove formatting","insert-link":"Insert a link","insert-valid-link":"Insert a valid link",insert:"Insert","edit-link":"Edit link","remove-link":"Remove link","text-editor-placeholder":"Write something...","date-editor-relative-past":"Relative - Past","date-editor-relative-future":"Relative - Future","date-editor-absolute":"Absolute","date-relative-comparation-lt":"Less than","date-relative-comparation-gt":"More than","date-relative-comparation-eq":"Exactly","date-relative-future-gt":"In more than","date-relative-future-lt":"In less than","date-relative-future-eq":"In exactly","date-absolute-eq":"On","date-absolute-gte":"From","date-absolute-lt":"Until","type-to-filter":"Type to filter","choose-a-mode-to-filter":"Choose a mode to filter","less-than":"Less than","less-or-equal":"Less than or equal to","greater-than":"Greater than","greater-or-equal":"Greater than or equal to",equal:"Equal to",different:"Different from",contains:"Contains","starts-at":"Starts at","ends-at":"Ends at",exactly:"Exactly","not-equal":"Not equal to","start-placeholder":"From the day","end-placeholder":"To the day","placeholder-date":"Select a date",time:"Time",date:"Select a date","from-day":"From day","to-day":"To day","calendar-weekday-sunday":"Sun","calendar-weekday-monday":"Mon","calendar-weekday-tuesday":"Tue","calendar-weekday-wednesday":"Wed","calendar-weekday-thursday":"Thu","calendar-weekday-friday":"Fri","calendar-weekday-saturday":"Sat","calendar-month-january":"January","calendar-month-february":"February","calendar-month-march":"March","calendar-month-april":"April","calendar-month-may":"May","calendar-month-june":"June","calendar-month-july":"July","calendar-month-august":"August","calendar-month-september":"September","calendar-month-october":"October","calendar-month-november":"November","calendar-month-december":"December","calendar-date-separator":" "},es:{"simple-filter":"Filtro simple","advanced-filter":"Filtro avanzado","search-placeholder":"Escribe algo para buscar",searching:"Buscando","recently-searched":"Buscas recientes","send-for-all":"Enviar para todos","show-more":"Mostrar más","load-more":"Cargar más","search-for-markers-classes-users":"Busque por marcadores, clases, estudiantes y usuarios","when-you-have-markers-classes":"Cuando tengas marcadores y clases, aparecerán aquí.","not-found":"No encontramos resultados","make-sure-to-type-something":"Asegúrate de escribir una palabra clave correcta",clean:"Limpiar","see-all":"Ver todos","selected-recipients":"Destinatarios seleccionados",cancel:"Cancelar",continue:"Continuar","show-for-all-tags":"Ya has seleccionado algunos destinatarios y serán reemplazados por la etiqueta todos.","one-result-found":"1 resultado encontrado","results-found":" resultados encontrados","error-target-loading":"Error al cargar el público objetivo.","error-searching":"Error al buscar el público deseado.","add-filter":"Agregar filtro",save:"Guardar",search:"Buscar",bold:"Negrita",italic:"Cursiva",underline:"Subrayado",title:"Título","bullet-list":"Lista con viñetas","numbered-list":"Lista numerada",link:"Insertar enlace",blockquote:"Cita","remove-formatting":"Eliminar formato","insert-link":"Inserte un enlace","insert-valid-link":"Inserte un enlace válido",insert:"Insertar","edit-link":"Editar enlace","remove-link":"Eliminar enlace","text-editor-placeholder":"Escribe algo...","date-editor-relative-past":"Relativo - Pasado","date-editor-relative-future":"Relativo - Futuro","date-editor-absolute":"Absoluto","date-relative-comparation-lt":"Hace menos de","date-relative-comparation-gt":"Hace más de","date-relative-comparation-eq":"Hace exactamente","date-relative-future-gt":"En más de","date-relative-future-lt":"En menos de","date-relative-future-eq":"En exactamente","date-absolute-eq":"En","date-absolute-gte":"A partir de","date-absolute-lt":"Hasta","type-to-filter":"Escriba para filtrar","choose-a-mode-to-filter":"Elija un modo para filtrar","less-than":"Menor que","less-or-equal":"Menor o igual a","greater-than":"Mayor que","greater-or-equal":"Mayor o igual a",equal:"Igual a",different:"Diferente de",contains:"Contiene","starts-at":"Comienza en","ends-at":"Termina en",exactly:"Es exactamente","not-equal":"No es igual a","start-placeholder":"Desde el día","end-placeholder":"Hasta el día","placeholder-date":"Seleccionar una fecha",time:"Hora",date:"Seleccionar fecha","from-day":"Desde el día","to-day":"Hasta el día","calendar-weekday-sunday":"Dom","calendar-weekday-monday":"Lun","calendar-weekday-tuesday":"Mar","calendar-weekday-wednesday":"Mié","calendar-weekday-thursday":"Jue","calendar-weekday-friday":"Vie","calendar-weekday-saturday":"Sáb","calendar-month-january":"Enero","calendar-month-february":"Febrero","calendar-month-march":"Marzo","calendar-month-april":"Abril","calendar-month-may":"Mayo","calendar-month-june":"Junio","calendar-month-july":"Julio","calendar-month-august":"Agosto","calendar-month-september":"Septiembre","calendar-month-october":"Octubre","calendar-month-november":"Noviembre","calendar-month-december":"Diciembre","calendar-date-separator":" de "}};let Ab=Eh;function pn(){return Ab}function Fl(e,t){var r,o;return t=t||pn(),((r=Pg[t])==null?void 0:r[e])||((o=Pg[Eh])==null?void 0:o[e])||e}const $ee=e=>({setLanguage:async function(t){["en","es","pt-br"].includes(t)||(t=Eh);let o;switch(t){case"en":o=await Promise.resolve().then(()=>$O),await Promise.resolve().then(()=>require("./en-f6c5c2a1.cjs")).then(a=>a.en);break;case"es":o=await Promise.resolve().then(()=>require("./es-8dd974d7.cjs")),await Promise.resolve().then(()=>require("./es-a4248530.cjs")).then(a=>a.es);break;default:o=await Promise.resolve().then(()=>require("./pt-br-21743d21.cjs")),await Promise.resolve().then(()=>require("./pt-br-01ab10ae.cjs")).then(a=>a.ptBr);break}mM({locale:o.default},e,!0),Nd.locale(t),Ab=t}});function Ob(e){const t=[];if(e&&e.format&&t.push(`format:${e.format}`),e&&e.type&&t.push(`type:${e.type}`),t.push("DEFAULT"),t.length===0)throw new Error(`Unprocessable fieldSchema ${e}`);return t}const Hc=new Map;function Pee(e,t){if(!e)throw new Error(`Received ${e} fieldSchema, componentType ${t}`);if(e.components&&e.components[t])return e.components[t];const r=Ob(e);for(const o of r){const a=Hc.get(`${o}:${t}`);if(a)return a}throw new Error(`Component not found for field schema ${JSON.stringify(e)} and component type ${t}`)}function Ree(e,t,r){const a=`${Ob(e)[0]}:${t}`;Hc.has(a)&&Hc.get(a)!==r&&console.warn(`Overwriting component for key ${a}`),Hc.set(a,r)}const Sn={get:Pee,register:Ree},zb={};zb.install=function(e){e.config.globalProperties.$L.FieldTypeComponents=Sn};const Fee=e=>{let t=e;return e.startsWith("El")&&(t=e.substring(2)),`L${t}`},Uee=[Gr,TQ,DQ,GQ,cq,iJ,lJ,sJ,sZ,EW,TW,db,PX,see,Oee],jb={};jb.install=function(e){for(const t of Uee)e.component(Fee(t.name),t);for(const[t,r]of Object.entries(SM)){const o=`ElIcon${t}`;e.component(o,r)}};const Hee=n.defineComponent({name:"LAlert",components:{Alert:rH},props:{type:{type:String,default:"info"},showIcon:{type:Boolean,default:!1}}});function Yee(e,t,r,o,a,i){const l=n.resolveComponent("Alert");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{type:e.type,"show-icon":e.showIcon,class:"l-alert"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["type","show-icon"])}const Qee=xe(Hee,[["render",Yee],["__scopeId","data-v-17379a78"]]),Wee=Object.freeze(Object.defineProperty({__proto__:null,default:Qee},Symbol.toStringTag,{value:"Module"}));function qee(e){if(!e)return"";var t=1e3;if(Math.abs(e)<t)return e+" B";var r=["kb","MB","GB","TB","PB","EB","ZB","YB"],o=-1;do e/=t,++o;while(Math.abs(e)>=t&&o<r.length-1);return e.toFixed(1)+" "+r[o]}const Gee={tagName:"l-attachment-chip",props:{name:String,mime:String,thumb:String,url:String,size:Number,closeable:{type:Boolean,default:!1}},computed:{prettySize(){return qee(this.size)},prettyMime(){if(!this.mime)return{extension:"???",color:"gray-20"};if(this.mime.indexOf("image/")>-1){const e={extension:"IMG",color:"green"};return{"image/gif":{extension:"GIF",color:"primary"},"image/jpeg":{extension:"JPG",color:"primary"},"image/png":{extension:"PNG",color:"primary"},"image/svg+xml":{extension:"SVG",color:"danger"}}[this.mime]||e}if(this.mime.indexOf("text/")>-1){const e={extension:"TXT",color:"lead"};return{"text/css":{extension:"CSS",color:"lead"},"text/csv":{extension:"CSV",color:"lead"},"text/html":{extension:"HTML",color:"lead"}}[this.mime]||e}if(this.mime.indexOf("video/")>-1){const e={extension:"VID",color:"danger"};return{"video/quicktime":{extension:"MOV",color:"danger"},"video/mp4":{extension:"MP4",color:"danger"},"video/mpeg":{extension:"MP4",color:"danger"}}[this.mime]||e}if(this.mime.indexOf("audio/")>-1)return{extension:"AUD",color:"info"};if(this.mime.indexOf("application/")>-1){const e={extension:"FIL",color:"danger"};return{"application/zip":{extension:"ZIP",color:"danger"},"application/x-rar-compressed":{extension:"RAR",color:"danger"},"application/pdf":{extension:"PDF",color:"danger"},"application/xml":{extension:"XML",color:"danger"},"application/javascript":{extension:"JS",color:"success"},"application/json":{extension:"JSON",color:"success"},"application/msword":{extension:"DOC",color:"link"},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{extension:"DOC",color:"link"},"application/vnd.ms-powerpoint":{extension:"PPT",color:"salmon"},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{extension:"PPT",color:"info"},"application/vnd.ms-excel":{extension:"XLS",color:"success"},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{extension:"XLS",color:"success"}}[this.mime]||e}return{extension:"FIL",color:"gray-20"}}},methods:{handleClose(e){e.stopPropagation(),this.$emit("close",this)}}},Kee={class:"l-attachment-chip"},Jee={key:0,class:"l-attachment-chip-thumb"},Zee=["src"],Xee={key:1,class:"l-attachment-chip-mime"},ete={class:"l-attachment-chip-text"},tte={key:0,class:"l-attachment-chip-name"},nte={key:1,class:"l-attachment-chip-size"};function rte(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",Kee,[r.thumb?(n.openBlock(),n.createElementBlock("div",Jee,[n.createElementVNode("img",{alt:"Thumb",src:r.thumb,width:"32",height:"32"},null,8,Zee)])):r.mime&&i.prettyMime?(n.openBlock(),n.createElementBlock("div",Xee,[n.createElementVNode("div",{class:"l-attachment-chip-extension",style:n.normalizeStyle({"background-color":"var(--color-"+i.prettyMime.color+")"})},n.toDisplayString(i.prettyMime.extension),5)])):n.createCommentVNode("",!0),n.createElementVNode("span",ete,[r.name?(n.openBlock(),n.createElementBlock("span",tte,n.toDisplayString(r.name),1)):n.createCommentVNode("",!0),i.prettySize&&!r.closeable?(n.openBlock(),n.createElementBlock("span",nte,"("+n.toDisplayString(i.prettySize)+")",1)):n.createCommentVNode("",!0)]),r.closeable?(n.openBlock(),n.createElementBlock("button",{key:2,class:"l-attachment-chip-clear",onClick:t[0]||(t[0]=(...s)=>i.handleClose&&i.handleClose(...s))},[n.createVNode(l,{color:"link"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-multiply")])),_:1})])):n.createCommentVNode("",!0)])}const ote=xe(Gee,[["render",rte]]),ate=Object.freeze(Object.defineProperty({__proto__:null,default:ote},Symbol.toStringTag,{value:"Module"}));const ite={tagName:"l-box"};function lte(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",null,[n.renderSlot(e.$slots,"default")])}const ste=xe(ite,[["render",lte]]),cte=Object.freeze(Object.defineProperty({__proto__:null,default:ste},Symbol.toStringTag,{value:"Module"}));const ute={tagName:"l-box-header",props:["icon"]};function dte(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",null,[n.createElementVNode("h1",null,[r.icon?(n.openBlock(),n.createBlock(l,{key:0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.icon),1)]),_:1})):n.createCommentVNode("",!0),n.renderSlot(e.$slots,"default")])])}const fte=xe(ute,[["render",dte]]),pte=Object.freeze(Object.defineProperty({__proto__:null,default:fte},Symbol.toStringTag,{value:"Module"}));const mte={tagName:"l-button",name:"LButton",components:{ElIcon:ke,ElLoading:Vee},inject:{elForm:{default:""},elFormItem:{default:""}},props:{type:{type:String,default:"default"},size:String,icon:{type:String,default:""},nativeType:{type:String,default:"button"},loading:Boolean,disabled:Boolean,plain:Boolean,autofocus:Boolean,round:Boolean,circle:Boolean,fab:Boolean,square:Boolean,fill:Boolean,textColor:String},computed:{isElementIcon(){return this.icon.startsWith("el-")||this.icon.startsWith("El")},iconPascalCase(){return this.icon.replace(/(^\w|-\w)/g,e=>e.replace(/-/,"").toUpperCase())},elementIconLoaded(){return this.isElementIcon&&SM[this.iconPascalCase]},_elFormItemSize(){return(this.elFormItem||{}).elFormItemSize},buttonSize(){return this.size||this._elFormItemSize||(this.$el||{}).size},buttonDisabled(){return this.disabled||(this.elForm||{}).disabled},textColorStyle(){return Oi(this.textColor)}}},hte=["disabled","autofocus","type"];function gte(e,t,r,o,a,i){const l=n.resolveComponent("el-icon-loading"),s=n.resolveComponent("el-icon");return n.openBlock(),n.createElementBlock("button",{class:n.normalizeClass(["l-button el-button",[r.type?"el-button--"+r.type:"",i.buttonSize?"el-button--"+i.buttonSize:"",{"is-disabled":i.buttonDisabled,"is-loading":r.loading,"is-plain":r.plain,"is-round":r.round,"is-circle":r.circle,"is-fab":r.fab,"is-square":r.square,"is-fill":r.fill}]]),disabled:i.buttonDisabled||r.loading,autofocus:r.autofocus,type:r.nativeType},[r.loading?(n.openBlock(),n.createBlock(s,{key:0},{default:n.withCtx(()=>[n.createVNode(l)]),_:1})):n.createCommentVNode("",!0),r.icon&&!r.loading?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[i.isElementIcon?(n.openBlock(),n.createBlock(s,{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(r.icon)))]),_:1})):(n.openBlock(),n.createElementBlock("i",{key:1,class:n.normalizeClass(r.icon)},null,2))],64)):n.createCommentVNode("",!0),e.$slots.default?(n.openBlock(),n.createElementBlock("span",{key:2,style:n.normalizeStyle(r.type=="text"&&r.textColor?{color:i.textColorStyle}:"")},[n.renderSlot(e.$slots,"default")],4)):n.createCommentVNode("",!0)],10,hte)}const vte=xe(mte,[["render",gte]]),yte=Object.freeze(Object.defineProperty({__proto__:null,default:vte},Symbol.toStringTag,{value:"Module"}));const Mte={tagName:"l-calendar",name:"LCalendar",props:{lang:{type:String,default(){return pn()}},modelValue:{type:String,default:null},disabledDate:{type:Function,default:null}},data(){return{currentDate:new Date}},computed:{weekDays(){return[this.$tds("calendar-weekday-sunday",this.lang),this.$tds("calendar-weekday-monday",this.lang),this.$tds("calendar-weekday-tuesday",this.lang),this.$tds("calendar-weekday-wednesday",this.lang),this.$tds("calendar-weekday-thursday",this.lang),this.$tds("calendar-weekday-friday",this.lang),this.$tds("calendar-weekday-saturday",this.lang)]},currentMonthYear(){const e=["calendar-month-january","calendar-month-february","calendar-month-march","calendar-month-april","calendar-month-may","calendar-month-june","calendar-month-july","calendar-month-august","calendar-month-september","calendar-month-october","calendar-month-november","calendar-month-december"],t=this.$tds(e[this.currentDate.getMonth()],this.lang),r=this.$tds("calendar-date-separator",this.lang);return`${t}${r}${this.currentDate.getFullYear()}`},weeks(){const e=[],t=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth(),1),r=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth()+1,0),o=new Date(t.getFullYear(),t.getMonth(),1-t.getDay());for(let a=0;a<6;a++){const i=[];for(let l=0;l<7;l++){const s=new Date(o);s.setDate(o.getDate()+a*7+l),i.push(s)}if(e.push(i),i[6]>r)break}return e}},methods:{getCellClasses(e){if(!e)return[];const t=[],r=new Date;r.setHours(0,0,0,0);const o=this.currentDate.getMonth();if(this.disabledDate&&this.disabledDate(e)?t.push("disabled-cell"):t.push("available"),e.getMonth()!==o&&t.push("prev-month"),this.modelValue){const i=new Date(this.modelValue);e.toDateString()===i.toDateString()&&t.push("current")}return e.toDateString()===r.toDateString()&&t.push("today"),t},handleDateClick(e){if(!e||this.disabledDate&&this.disabledDate(e))return;const t=e.toISOString();this.$emit("update:modelValue",t),this.$emit("change",t)},prevMonth(){this.currentDate=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth()-1,1)},nextMonth(){this.currentDate=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth()+1,1)},prevYear(){this.currentDate=new Date(this.currentDate.getFullYear()-1,this.currentDate.getMonth(),1)},nextYear(){this.currentDate=new Date(this.currentDate.getFullYear()+1,this.currentDate.getMonth(),1)}}},bte={class:"l-calendar-wrapper"},wte={class:"l-calendar__body"},Nte={class:"l-calendar__header"},kte={class:"l-calendar-header-button-wrapper"},xte={class:"l-calendar-header__label"},Cte={class:"l-calendar-header-button-wrapper"},Ete={class:"l-calendar-table"},Tte={class:"l-calendar-table-header"},Dte=["onClick"];function Ste(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",bte,[n.createElementVNode("div",wte,[n.createElementVNode("div",Nte,[n.createElementVNode("div",kte,[n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[0]||(t[0]=(...s)=>i.prevYear&&i.prevYear(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[4]||(t[4]=[n.createTextVNode("uil-angle-double-left")])),_:1})]),n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[1]||(t[1]=(...s)=>i.prevMonth&&i.prevMonth(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[5]||(t[5]=[n.createTextVNode("uil-angle-left")])),_:1})])]),n.createElementVNode("span",xte,n.toDisplayString(i.currentMonthYear),1),n.createElementVNode("div",Cte,[n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[2]||(t[2]=(...s)=>i.nextMonth&&i.nextMonth(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[6]||(t[6]=[n.createTextVNode("uil-angle-right")])),_:1})]),n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[3]||(t[3]=(...s)=>i.nextYear&&i.nextYear(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[7]||(t[7]=[n.createTextVNode("uil-angle-double-right")])),_:1})])])]),n.createElementVNode("table",Ete,[n.createElementVNode("tbody",null,[n.createElementVNode("tr",Tte,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.weekDays,s=>(n.openBlock(),n.createElementBlock("th",{key:s},n.toDisplayString(s),1))),128))]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.weeks,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c,class:"l-calendar-table-body"},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(i.getCellClasses(u)),onClick:f=>i.handleDateClick(u)},[n.createElementVNode("div",null,n.toDisplayString(u?u.getDate():""),1)],10,Dte))),128))]))),128))])])])])}const _te=xe(Mte,[["render",Ste]]),Ite=Object.freeze(Object.defineProperty({__proto__:null,default:_te},Symbol.toStringTag,{value:"Module"}));const Ate={tagName:"l-carousel",name:"Lcarousel",props:["images","height","width"],data:function(){return{selected:0}},methods:{previous(){this.selected--,this.$refs[`img:${this.selected}`][0].scrollIntoView({behavior:"smooth"})},next(){this.selected++,this.$refs[`img:${this.selected}`][0].scrollIntoView({behavior:"smooth"})}}},Ote={class:"carousel"},zte={class:"slider-container"},jte={class:"img-container"},Lte=["src","height","width"];function Bte(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",Ote,[e.selected>0?(n.openBlock(),n.createBlock(l,{key:0,class:"slider-control",circle:"",icon:"uil-angle-left",style:{left:"1em"},onClick:i.previous},null,8,["onClick"])):n.createCommentVNode("",!0),n.createElementVNode("div",zte,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.images,(s,c)=>(n.openBlock(),n.createElementBlock("div",{key:s.index,class:"slide",ref_for:!0,ref:`img:${c}`},[n.createElementVNode("div",jte,[n.createElementVNode("img",{alt:"Carousel image",src:s.src,height:r.height,width:r.width,style:{"border-radius":"10px"}},null,8,Lte)])]))),128))]),e.selected<r.images.length-1?(n.openBlock(),n.createBlock(l,{key:1,class:"slider-control",circle:"",icon:"uil-angle-right",style:{right:"1em"},onClick:i.next},null,8,["onClick"])):n.createCommentVNode("",!0)])}const Vte=xe(Ate,[["render",Bte],["__scopeId","data-v-4e5bb0e6"]]),$te=Object.freeze(Object.defineProperty({__proto__:null,default:Vte},Symbol.toStringTag,{value:"Module"}));const Pte={name:"LCheckbox",components:{ElCheckbox:VW}};function Rte(e,t,r,o,a,i){const l=n.resolveComponent("ElCheckbox");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-checkbox"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Fte=xe(Pte,[["render",Rte],["__scopeId","data-v-66702b20"]]),Ute=Object.freeze(Object.defineProperty({__proto__:null,default:Fte},Symbol.toStringTag,{value:"Module"}));const Hte={name:"LCheckboxButton",components:{CheckboxButton:$W}};function Yte(e,t,r,o,a,i){const l=n.resolveComponent("CheckboxButton");return n.openBlock(),n.createBlock(l,n.mergeProps({class:"l-checkbox-button"},e.$attrs),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Qte=xe(Hte,[["render",Yte],["__scopeId","data-v-6640b3ce"]]),Wte=Object.freeze(Object.defineProperty({__proto__:null,default:Qte},Symbol.toStringTag,{value:"Module"}));const qte={name:"LCheckboxGroup",components:{CheckboxGroup:PW},props:{separated:{type:Boolean,default:!1},color:{type:String,default:"aqua"}},computed:{customFill(){return W3(this.color)}},mounted(){const e=this.$refs.checkboxGroup.$el;this.separated&&e.children&&e.children.length&&Array.from(e.children).forEach(t=>t.classList.add("l-checkbox-button-separated"))}};function Gte(e,t,r,o,a,i){const l=n.resolveComponent("CheckboxGroup");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:[{"l-checkbox-group-separated":r.separated},"l-checkbox-group"],fill:i.customFill,"text-color":"white",ref:"checkboxGroup"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["class","fill"])}const Kte=xe(qte,[["render",Gte],["__scopeId","data-v-2664a205"]]),Jte=Object.freeze(Object.defineProperty({__proto__:null,default:Kte},Symbol.toStringTag,{value:"Module"}));const Zte={name:"LChip",props:{style:Object,icon:String,color:String,outline:{type:Boolean,default:!1},fill:{type:Boolean,default:!1},showIcon:{type:Boolean,default:!0},hideIcon:{type:Boolean,default:!1},bold:{type:Boolean,default:!1}},computed:{chipStyle(){return{"--color":Oi(this.color),"--b-color":Lp(this.color),...this.style}},chipClasses(){return{fill:this.fill,outline:this.outline,bold:this.bold}},getColor(){return Oi(this.color)||this.color},getColorLight(){return Lp(this.color)||this.color}}},Xte={key:1,class:"no-icon"},ene={class:"text"};function tne(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",{class:n.normalizeClass(["l-chip",i.chipClasses]),style:n.normalizeStyle(i.chipStyle)},[r.icon?(n.openBlock(),n.createBlock(l,{key:0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.icon),1)]),_:1})):r.hideIcon?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("span",Xte)),n.createElementVNode("span",ene,[n.renderSlot(e.$slots,"default",{},void 0,!0)])],6)}const nne=xe(Zte,[["render",tne],["__scopeId","data-v-d09f7499"]]),rne=Object.freeze(Object.defineProperty({__proto__:null,default:nne},Symbol.toStringTag,{value:"Module"}));const one={name:"LCircularLoader",props:{width:{type:Number,default:24},height:{type:Number,default:24},type:{type:String,default:"light"}}};function ane(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["loader-container",{dark:r.type==="dark"}]),style:n.normalizeStyle({width:`${r.width}px`,height:`${r.height}px`,"border-radius":`${r.width}px`})},[n.createElementVNode("div",{class:"loader",style:n.normalizeStyle({width:`${r.width*.66}px`})},t[0]||(t[0]=[n.createElementVNode("svg",{class:"circular",viewBox:"25 25 50 50"},[n.createElementVNode("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none","stroke-width":"5","stroke-miterlimit":"10"})],-1)]),4)],6)}const ine=xe(one,[["render",ane],["__scopeId","data-v-11599f46"]]),lne=Object.freeze(Object.defineProperty({__proto__:null,default:ine},Symbol.toStringTag,{value:"Module"}));const sne={components:{ElCollapseItem:uq},name:"LCollapseItem"};function cne(e,t,r,o,a,i){const l=n.resolveComponent("el-collapse-item");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-collapse-item"}),n.createSlots({default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.title?{name:"title",fn:n.withCtx(s=>[n.renderSlot(e.$slots,"title",n.normalizeProps(n.guardReactiveProps(s)),void 0,!0)]),key:"0"}:void 0]),1040)}const une=xe(sne,[["render",cne],["__scopeId","data-v-f754de68"]]),dne=Object.freeze(Object.defineProperty({__proto__:null,default:une},Symbol.toStringTag,{value:"Module"}));const fne={render:()=>n.h("i",{class:"uil uil-calender"})},pne={name:"LDatePicker",tagName:"l-date-picker",components:{ElDatePicker:nK},props:{prefixIcon:{type:[String,Object],default:()=>fne},format:{type:String,default:()=>"DD/MM/YYYY"},lang:{type:String,default:""},clearable:{type:Boolean,default:!0},startPlaceholder:{type:String,default(e){return Fl("start-placeholder",e.lang||pn())}},endPlaceholder:{type:String,default(e){return Fl("end-placeholder",e.lang||pn())}},placeholder:{type:String,default(e){return Fl("placeholder-date",e.lang||pn())}},rangeSeparator:{type:String,default:()=>" "},popperClass:{type:String,default:()=>"l-date-picker-popper"},hideIcon:{type:Boolean,default:()=>!1}}};function mne(e,t,r,o,a,i){const l=n.resolveComponent("el-date-picker");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{"prefix-icon":r.prefixIcon,format:r.format,"start-placeholder":r.startPlaceholder,"end-placeholder":r.endPlaceholder,placeholder:r.placeholder,"range-separator":r.rangeSeparator,"popper-class":r.popperClass,clearable:r.clearable,ref:"date-picker",class:[{"hide-icon":r.hideIcon,"clearable-input":r.clearable},"l-date-picker"]}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["prefix-icon","format","start-placeholder","end-placeholder","placeholder","range-separator","popper-class","clearable","class"])}const hne=xe(pne,[["render",mne]]),gne=Object.freeze(Object.defineProperty({__proto__:null,default:hne},Symbol.toStringTag,{value:"Module"}));const vne={name:"LDialog",components:{ElDialog:bK}};function yne(e,t,r,o,a,i){const l=n.resolveComponent("el-dialog");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-dialog"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Mne=xe(vne,[["render",yne],["__scopeId","data-v-450b5a10"]]),bne=Object.freeze(Object.defineProperty({__proto__:null,default:Mne},Symbol.toStringTag,{value:"Module"})),wne="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjgwIiBoZWlnaHQ9IjIwMCIgdmlld0JveD0iMCAwIDI4MCAyMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik0xNzYuNjggNTMuNTQ2M0MxOTYuMjggNTQuNTY1NSAyMjAuMTY0IDU3LjIzMTEgMjIyLjc0NiA4NS4wNzk5QzIyNC44NCAxMDcuNjY1IDIwMi41ODYgMTI0LjIzNSAxODUuMjcxIDEyOS4zOTNDMTY1LjM0IDEzNS4zMjkgMTQ5LjI5NiAxMjAuNTI4IDEyOS4zMzIgMTE4LjUzNEMxMDguOTk5IDExNi41MDcgOTguNDU5NiAxNDMuMTEzIDc4Ljg3NjQgMTM5LjgxNEM1OS44MzY0IDEzNi42MTcgNDguNzI2IDEwNy4zMzQgNDguMjUgODkuNDE0M0M0Ny42OSA2Ny40NDU1IDYwLjU3IDQ5LjU3NTkgNzQuMDEgMzYuMjQ3OUM4OC4yOTU2IDIyLjA1MTkgMTA3LjAxNiAxMS4zMTY3IDEyOC4zOTIgMjEuMzIzOUMxNDguMTg4IDMwLjU3NTEgMTUzLjQ2O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name:"LFailedToLoad",props:{title:{type:String,default:"Algo deu errado :("},actionFunction:{type:Function},actionLabel:{type:String,default:"Tentar novamente"},loading:{type:Boolean,default:!1}}},kne={class:"failed-to-load"},xne={class:"lead--text title mt-3"};function Cne(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",kne,[t[0]||(t[0]=n.createElementVNode("div",{style:{display:"flex"}},[n.createElementVNode("img",{alt:"Failed to load",src:wne,height:"280",class:"mt-5",style:{display:"flex"}})],-1)),n.createElementVNode("h1",xne,n.toDisplayString(r.title),1),n.createVNode(l,{onClick:r.actionFunction,height:"40",width:"220",block:"",class:"mt-3 bold f-19",loading:r.loading},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.actionLabel),1)]),_:1},8,["onClick","loading"])])}const Ene=xe(Nne,[["render",Cne],["__scopeId","data-v-407d980d"]]),Tne=Object.freeze(Object.defineProperty({__proto__:null,default:Ene},Symbol.toStringTag,{value:"Module"}));const Dne={tagName:"l-form",name:"LForm",components:{ElForm:KJ},inheritAttrs:!1};function Sne(e,t,r,o,a,i){const l=n.resolveComponent("el-form");return n.openBlock(),n.createBlock(l,n.normalizeProps(n.guardReactiveProps(e.$attrs)),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16)}const _ne=xe(Dne,[["render",Sne]]),Ine=Object.freeze(Object.defineProperty({__proto__:null,default:_ne},Symbol.toStringTag,{value:"Module"}));const Ane={tagName:"l-form-item",name:"LFormItem",components:{ElFormItem:JJ},inheritAttrs:!1};function One(e,t,r,o,a,i){const l=n.resolveComponent("el-form-item");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-form-item"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16)}const zne=xe(Ane,[["render",One]]),jne=Object.freeze(Object.defineProperty({__proto__:null,default:zne},Symbol.toStringTag,{value:"Module"}));const Lne={name:"LHelperBox",props:{icon:{type:String,required:!0},title:{type:String,required:!0},description:{type:String,required:!0},actionButtonText:{type:String},href:{type:String},width:{type:[Number,String]}},computed:{computedWidth(){return`${this.width||200}px`}},methods:{actionButtonClick(){this.$emit("actionButtonClick"),this.href&&window.open(this.href,"_blank")}}},Bne=["alt","src"],Vne={class:"mt-2 lead--text"},$ne={class:"mt-2 box-value lead-light--text mb-1"};function Pne(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",{class:"box p-4",style:n.normalizeStyle({width:i.computedWidth})},[n.createElementVNode("img",{alt:r.title,src:r.icon,class:"box-image"},null,8,Bne),n.createElementVNode("h4",Vne,n.toDisplayString(r.title),1),n.createElementVNode("div",$ne,n.toDisplayString(r.description),1),r.actionButtonText?(n.openBlock(),n.createBlock(l,{key:0,class:"mt-2",onClick:t[0]||(t[0]=s=>i.actionButtonClick())},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.actionButtonText),1)]),_:1})):n.createCommentVNode("",!0)],4)}const Rne=xe(Lne,[["render",Pne]]),Fne=Object.freeze(Object.defineProperty({__proto__:null,default:Rne},Symbol.toStringTag,{value:"Module"}));let Pf=null;const Une={tagName:"l-image-viewer",name:"LImageViewer",props:["images","index"],data:function(){return{selected:0,cards:[],scale:0,showCommands:!0,latestTap:0,lastMouseUp:0,lastMouseDown:0,zoomed:!1}},mounted(){Pf=document.querySelectorAll("[observer-targets]"),this.intersectionObserver=new IntersectionObserver(t=>this.onChangeVisibility(t[0]),{threshold:[.9,1]}),Pf.forEach(t=>{this.intersectionObserver.observe(t)});const e=parseInt(this.index)||0;this.cards=this.images.map((t,r)=>(t.scale=r,t)),this.scale=2-this.index,this.slideAndScale(),this.select(e)},beforeUnmount(){this.intersectionObserver.disconnect()},methods:{onChangeVisibility(e){e.isIntersecting&&(this.selected=Number(e.target.id))},toggleCommands(){let t=new Date().getTime()-this.latestTap,r=this.lastMouseUp-this.lastMouseDown;(t>700||t<0)&&r<100?this.showCommands=!this.showCommands:r>1500&&this.download(),this.latestTap=new Date().getTime()},updateMouseUp(){this.lastMouseUp=new Date().getTime()},updateMouseDown(){this.lastMouseDown=new Date().getTime()},back(){this.$emit("close",null)},download:async function(){const e=this.images[this.selected],t=window.LayersPortal;t?await t("download",{url:e.src,name:e.name}):window.open(e.src)},previous(){this.selected<=0||(document.getElementById("gallery-container").scrollTo({left:Math.abs(window.innerWidth-window.innerWidth*this.selected),behavior:"smooth"}),this.cards[0].scale<2&&this.scale++,this.lastMouseDown=0,this.slideAndScale())},next(){this.selected>=Pf.length-1||(document.getElementById("gallery-container").scrollTo({left:window.innerWidth*(this.selected+1),behavior:"smooth"}),this.cards[this.cards.length-1].scale!=2&&this.scale--,this.lastMouseDown=0,this.slideAndScale())},select(e){e>this.selected&&document.getElementById("gallery-container").scrollTo({left:window.innerWidth*e,behavior:"smooth"}),e<this.selected&&document.getElementById("gallery-container").scrollTo({left:Math.abs(window.innerWidth-window.innerWidth*(e+1)),behavior:"smooth"});const t=this.cards[e].scale;t!==2&&(this.scale-=t-2,this.slideAndScale())},slideAndScale:function(){this.cards.map((e,t)=>{e.scale=t+this.scale})}},watch:{selected:function(e,t){this.$refs.zoomer[t].reset()}}},Hne={class:"image-viewer",style:{position:"relative"}},Yne={key:0},Qne=["id"],Wne=["src"],qne={key:0,class:"web-image-selector"},Gne={class:"carousel-container"},Kne=["onClick","data-scale"],Jne=["alt","src"];function Zne(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("v-zoomer");return n.openBlock(),n.createElementBlock("div",Hne,[n.createElementVNode("div",{class:n.normalizeClass(["header",{colapsed:!e.showCommands}])},[n.createVNode(l,{circle:"",onClick:i.back,class:"header-button",icon:"uil-arrow-left"},null,8,["onClick"]),r.images.length!==1?(n.openBlock(),n.createElementBlock("div",Yne,n.toDisplayString(parseInt(e.selected)+1)+"/"+n.toDisplayString(r.images.length),1)):n.createCommentVNode("",!0),n.createVNode(l,{circle:"",onClick:i.download,class:"header-button",icon:"el-icon-download"},null,8,["onClick"])],2),n.createVNode(n.Transition,{name:"el-notification-fade"},{default:n.withCtx(()=>[e.selected>0&&e.showCommands?(n.openBlock(),n.createBlock(l,{key:0,onClick:i.previous,onTouchstart:i.previous,circle:"",icon:"uil-angle-left",class:"nav-button left"},null,8,["onClick","onTouchstart"])):n.createCommentVNode("",!0)]),_:1}),n.createVNode(n.Transition,{name:"el-notification-fade"},{default:n.withCtx(()=>[e.selected<r.images.length-1&&e.showCommands?(n.openBlock(),n.createBlock(l,{key:0,onClick:i.next,circle:"",icon:"uil-angle-right",class:"nav-button right"},null,8,["onClick"])):n.createCommentVNode("",!0)]),_:1}),n.createElementVNode("div",{class:"row scroll-container",id:"gallery-container",style:n.normalizeStyle({overflow:e.zoomed?"hidden":"auto"})},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.images,(c,u)=>(n.openBlock(),n.createElementBlock("div",{"observer-targets":"",class:"image-container",onClick:t[1]||(t[1]=(...d)=>i.toggleCommands&&i.toggleCommands(...d)),onMousedown:t[2]||(t[2]=(...d)=>i.updateMouseDown&&i.updateMouseDown(...d)),onMouseup:t[3]||(t[3]=(...d)=>i.updateMouseUp&&i.updateMouseUp(...d)),ref_for:!0,ref:`${c.id}-${u}`,id:u,key:u},[n.createVNode(s,{zoomed:e.zoomed,"onUpdate:zoomed":t[0]||(t[0]=d=>e.zoomed=d),class:"image",ref_for:!0,ref:"zoomer"},{default:n.withCtx(()=>[n.createElementVNode("img",{alt:"Box image",class:"image",src:c.src},null,8,Wne)]),_:2},1032,["zoomed"])],40,Qne))),128))],4),r.images.length?(n.openBlock(),n.createElementBlock("div",qne,[n.createElementVNode("div",Gne,[t[4]||(t[4]=n.createElementVNode("div",{class:"fade-box left"},null,-1)),n.createElementVNode("div",{class:"carousel-inner",style:n.normalizeStyle({transform:`translateX(${this.scale*8.5}em)`})},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.cards,(c,u)=>(n.openBlock(),n.createElementBlock("div",{key:c.id,onClick:d=>i.select(u),class:n.normalizeClass(["card",{selected:u==e.selected}]),"data-scale":c.scale},[n.createElementVNode("img",{alt:c.id,src:c.src,style:{width:"100%",height:"100%","object-fit":"cover"}},null,8,Jne)],10,Kne))),128))],4),t[5]||(t[5]=n.createElementVNode("div",{class:"fade-box right"},null,-1))])])):n.createCommentVNode("",!0)])}const Xne=xe(Une,[["render",Zne],["__scopeId","data-v-334ba796"]]),ere=Object.freeze(Object.defineProperty({__proto__:null,default:Xne},Symbol.toStringTag,{value:"Module"}));const tre={tagName:"l-input",name:"LInput",components:{ElInput:Gr},props:{error:{type:Boolean,default:!1},errorMessage:{type:String,default:""},noBorder:{type:Boolean,default:!1}}},nre={class:"l-input-wrapper"},rre={key:0,class:"l-input-error-message"};function ore(e,t,r,o,a,i){const l=n.resolveComponent("el-input");return n.openBlock(),n.createElementBlock("div",nre,[n.createVNode(l,n.mergeProps(e.$attrs,{class:["l-input",{"l-input-error":r.error}],"input-style":{border:r.noBorder?"none":"",boxShadow:r.noBorder?"none":""}}),n.createSlots({default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.prefix?{name:"prefix",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"prefix",{},void 0,!0)]),key:"0"}:void 0,e.$slots.suffix?{name:"suffix",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"suffix",{},void 0,!0)]),key:"1"}:void 0,e.$slots.prepend?{name:"prepend",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"prepend",{},void 0,!0)]),key:"2"}:void 0,e.$slots.append?{name:"append",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"append",{},void 0,!0)]),key:"3"}:void 0]),1040,["class","input-style"]),r.errorMessage?(n.openBlock(),n.createElementBlock("div",rre,n.toDisplayString(r.errorMessage),1)):n.createCommentVNode("",!0)])}const are=xe(tre,[["render",ore],["__scopeId","data-v-3a81ac87"]]),ire=Object.freeze(Object.defineProperty({__proto__:null,default:are},Symbol.toStringTag,{value:"Module"}));const lre={name:"LLinearProgress",props:{color:{type:String,default:"rainbow"},background:{type:String,default:"transparent"},height:{type:Number,default:4}},methods:{getColor:Oi}};function sre(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:"l-linear-progress",style:n.normalizeStyle({height:r.height+"px"})},[n.createElementVNode("div",{class:"l-linear-progress-background",style:n.normalizeStyle({"--color":i.getColor(r.background)})},null,4),n.createElementVNode("div",{class:n.normalizeClass(["l-linear-progress-indeterminate",[r.color]]),style:n.normalizeStyle({"--color":i.getColor(r.color)})},null,6)],4)}const cre=xe(lre,[["render",sre],["__scopeId","data-v-7fdc26e5"]]),ure=Object.freeze(Object.defineProperty({__proto__:null,default:cre},Symbol.toStringTag,{value:"Module"}));const dre={name:"LNotice",props:{type:{type:String},outline:{type:Boolean,default:()=>!1},fill:{type:Boolean,default:()=>!0},showIcon:{type:Boolean,default:()=>!0},color:{type:String},icon:{type:String}},computed:{computedColor(){return this.color||this.type},computedIcon(){if(this.icon)return this.icon;if(!this.type)return null;switch(this.type){case"danger":return"uil-exclamation-circle";case"warning":return"uil-clock";case"success":return"uil-check-circle";default:throw new Error(`Unknown type ${this.type}`)}}}},fre={key:1,class:"no-icon"},pre={class:"text"};function mre(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",{style:n.normalizeStyle({"--color":i.computedColor}),class:n.normalizeClass({outline:r.outline,fill:r.fill})},[r.showIcon?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[i.computedIcon?(n.openBlock(),n.createBlock(l,{key:0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.computedIcon),1)]),_:1})):(n.openBlock(),n.createElementBlock("span",fre))],64)):n.createCommentVNode("",!0),n.createElementVNode("span",pre,[n.renderSlot(e.$slots,"default")])],6)}const hre=xe(dre,[["render",mre]]),gre=Object.freeze(Object.defineProperty({__proto__:null,default:hre},Symbol.toStringTag,{value:"Module"}));const vre=n.defineComponent({name:"LPresentation",data:()=>({dialogVisible:!1}),props:{image:{type:String,required:!0},color:{type:String,default:"#FFF"},placement:{type:String,default:"bottom"},value:{type:Boolean,default:!1},isTooltip:{type:Boolean,default:!1},mode:{type:String,default:"contain",required:!1},tooltipClass:{type:String,required:!1}},emits:["update:value","close"],onMounted(){this.dialogVisible=this.value},watch:{dialogVisible(e){this.$emit("update:value",e),e||this.$emit("close")},value(e){this.dialogVisible=e,this.isTooltip&&e&&n.nextTick(this.updateTooltipArrow)}},setup(e,{emit:t}){return{updateTooltipArrow:()=>{const a=this.$refs.tooltip.popperElm;a&&a.style.setProperty("--popper-arrow",e.color)},close:()=>{t("update:value",!1),t("close")}}}}),yre={class:"tooltip-content"},Mre=["src"],bre={key:1},wre=["src"],Nre={class:"tooltip-content"};function kre(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("l-tooltip"),c=n.resolveComponent("l-dialog");return e.isTooltip?(n.openBlock(),n.createBlock(s,{key:0,ref:"tooltip",placement:e.placement,effect:"light",modelValue:e.dialogVisible,"onUpdate:modelValue":t[0]||(t[0]=u=>e.dialogVisible=u),manual:"",tooltipClass:`l-presentation-popper ${e.tooltipClass?e.tooltipClass:""}`},{content:n.withCtx(()=>[n.createElementVNode("div",yre,[n.createElementVNode("div",{class:"image-container",style:n.normalizeStyle({"background-color":e.color})},[n.createElementVNode("img",{src:e.image,class:n.normalizeClass(["l-presentation-image",e.mode]),draggable:"false",alt:"Presentation"},null,10,Mre),n.createVNode(l,{onClick:e.close,class:"close-button",fab:"",icon:"uil-times",size:"mini",type:"info"},null,8,["onClick"])],4),n.createElementVNode("p",null,[n.renderSlot(e.$slots,"content",{},void 0,!0)])]),n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["placement","modelValue","tooltipClass"])):(n.openBlock(),n.createElementBlock("div",bre,[n.createVNode(c,{modelValue:e.dialogVisible,"onUpdate:modelValue":t[1]||(t[1]=u=>e.dialogVisible=u),"before-close":e.close},{header:n.withCtx(()=>[n.createElementVNode("div",{class:"image-container",style:n.normalizeStyle({"background-color":e.color})},[n.createElementVNode("img",{src:e.image,class:n.normalizeClass(["l-presentation-image",e.mode]),width:"280",height:"160",draggable:"false",alt:"Presentation"},null,10,wre)],4)]),default:n.withCtx(()=>[n.createElementVNode("div",Nre,[n.createElementVNode("p",null,[n.renderSlot(e.$slots,"content",{},void 0,!0)])])]),_:3},8,["modelValue","before-close"]),n.renderSlot(e.$slots,"default",{},void 0,!0)]))}const xre=xe(vre,[["render",kre],["__scopeId","data-v-3e34dd20"]]),Cre=Object.freeze(Object.defineProperty({__proto__:null,default:xre},Symbol.toStringTag,{value:"Module"}));const Ere=n.defineComponent({name:"LPromptDialog",props:{title:{type:String,required:!0},content:{type:String,default:""},buttonCloseLabel:{type:String,default:"Cancelar"},buttonConfirmLabel:{type:String,default:"Continuar"}},methods:{close(){this.$emit("close")},selectModel(){this.$emit("answer",!0)}}}),Tre={class:"prompt-dialog"},Dre={key:0,style:{display:"block"},class:"mt-4"},Sre={class:"l-d-flex mt-4 prompt-buttons"};function _re(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",Tre,[n.createElementVNode("h3",null,n.toDisplayString(e.title),1),e.content?(n.openBlock(),n.createElementBlock("p",Dre,n.toDisplayString(e.content),1)):n.createCommentVNode("",!0),n.createElementVNode("div",Sre,[n.createVNode(l,{onClick:e.close,type:"primary",plain:"",class:"bold my-0 ml-0 mr-2 dialog-button decline-button-dialog"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.buttonCloseLabel),1)]),_:1},8,["onClick"]),n.createVNode(l,{onClick:e.selectModel,type:"primary",class:"bold m-0 dialog-button confirm-button-dialog"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.buttonConfirmLabel),1)]),_:1},8,["onClick"])])])}const Th=xe(Ere,[["render",_re],["__scopeId","data-v-75693735"]]),Ire=Object.freeze(Object.defineProperty({__proto__:null,default:Th},Symbol.toStringTag,{value:"Module"}));const Are=n.defineComponent({name:"LRadio",components:{ElRadio:qW}});function Ore(e,t,r,o,a,i){const l=n.resolveComponent("ElRadio");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-radio"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const zre=xe(Are,[["render",Ore],["__scopeId","data-v-7560e4a6"]]),jre=Object.freeze(Object.defineProperty({__proto__:null,default:zre},Symbol.toStringTag,{value:"Module"}));const Lre=n.defineComponent({name:"LRadiobutton",components:{ElRadioButton:KW}});function Bre(e,t,r,o,a,i){const l=n.resolveComponent("ElRadioButton");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-radio-button"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Vre=xe(Lre,[["render",Bre],["__scopeId","data-v-85dba2ee"]]),$re=Object.freeze(Object.defineProperty({__proto__:null,default:Vre},Symbol.toStringTag,{value:"Module"}));const Pre=n.defineComponent({name:"LRadioGroup",components:{RadioGroup:GW},props:{separated:{type:Boolean,default:!1},color:{type:String,default:"primary"}},computed:{fill(){return W3(this.color)}},onMounted(){if(this.separated){const e=this.$refs.radioGroup.$el;e.classList.add("l-radio-group-separated"),e.children&&e.children.length&&Array.from(e.children).forEach(t=>t.classList.add("l-radio-button-separated"))}}});function Rre(e,t,r,o,a,i){const l=n.resolveComponent("RadioGroup");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:[{"l-radio-group-separated":e.separated},"l-radio-group"],ref:"radioGroup",fill:e.fill}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["class","fill"])}const Fre=xe(Pre,[["render",Rre],["__scopeId","data-v-9ec95acb"]]),Ure=Object.freeze(Object.defineProperty({__proto__:null,default:Fre},Symbol.toStringTag,{value:"Module"}));const Hre={name:"l-rating",components:{ElRate:jZ},props:{colors:{type:Array,default:()=>["#99A9BF","#F7BA2A","#FF9900"]},allowHalf:{type:Boolean,default:!1}}};function Yre(e,t,r,o,a,i){const l=n.resolveComponent("el-rate");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{colors:r.colors,"allow-half":r.allowHalf}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["colors","allow-half"])}const Qre=xe(Hre,[["render",Yre]]),Wre=Object.freeze(Object.defineProperty({__proto__:null,default:Qre},Symbol.toStringTag,{value:"Module"}));var qre=rl,Gre=ko,Kre="[object Symbol]";function Jre(e){return typeof e=="symbol"||Gre(e)&&qre(e)==Kre}var Jd=Jre,Zre=vr,Xre=Jd,eoe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,toe=/^\w*$/;function noe(e,t){if(Zre(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||Xre(e)?!0:toe.test(e)||!eoe.test(e)||t!=null&&e in Object(t)}var Dh=noe,Lb=im,roe="Expected a function";function Sh(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(roe);var r=function(){var o=arguments,a=t?t.apply(this,o):o[0],i=r.cache;if(i.has(a))return i.get(a);var l=e.apply(this,o);return r.cache=i.set(a,l)||i,l};return r.cache=new(Sh.Cache||Lb),r}Sh.Cache=Lb;var ooe=Sh,aoe=ooe,ioe=500;function loe(e){var t=aoe(e,function(o){return r.size===ioe&&r.clear(),o}),r=t.cache;return t}var soe=loe,coe=soe,uoe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,doe=/\\(\\)?/g,foe=coe(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(uoe,function(r,o,a,i){t.push(a?i.replace(doe,"$1"):o||r)}),t}),poe=foe;function moe(e,t){for(var r=-1,o=e==null?0:e.length,a=Array(o);++r<o;)a[r]=t(e[r],r,e);return a}var Bb=moe,Rg=nl,hoe=Bb,goe=vr,voe=Jd,yoe=1/0,Fg=Rg?Rg.prototype:void 0,Ug=Fg?Fg.toString:void 0;function Vb(e){if(typeof e=="string")return e;if(goe(e))return hoe(e,Vb)+"";if(voe(e))return Ug?Ug.call(e):"";var t=e+"";return t=="0"&&1/e==-yoe?"-0":t}var Moe=Vb,boe=Moe;function woe(e){return e==null?"":boe(e)}var Noe=woe,koe=vr,xoe=Dh,Coe=poe,Eoe=Noe;function Toe(e,t){return koe(e)?e:xoe(e,t)?[e]:Coe(Eoe(e))}var $b=Toe,Doe=Jd,Soe=1/0;function _oe(e){if(typeof e=="string"||Doe(e))return e;var t=e+"";return t=="0"&&1/e==-Soe?"-0":t}var Zd=_oe,Ioe=$b,Aoe=Zd;function Ooe(e,t){t=Ioe(t,e);for(var r=0,o=t.length;e!=null&&r<o;)e=e[Aoe(t[r++])];return r&&r==o?e:void 0}var Pb=Ooe,zoe=Pb;function joe(e,t,r){var o=e==null?void 0:zoe(e,t);return o===void 0?r:o}var Rb=joe;const Dt=St(Rb);function Loe(e,t){for(var r=-1,o=e==null?0:e.length;++r<o&&t(e[r],r,e)!==!1;);return e}var Boe=Loe,Voe=uy,$oe=Voe(Object.keys,Object),Poe=$oe,Roe=um,Foe=Poe,Uoe=Object.prototype,Hoe=Uoe.hasOwnProperty;function Yoe(e){if(!Roe(e))return Foe(e);var t=[];for(var r in Object(e))Hoe.call(e,r)&&r!="constructor"&&t.push(r);return t}var Qoe=Yoe,Woe=vy,qoe=Qoe,Goe=ll;function Koe(e){return Goe(e)?Woe(e):qoe(e)}var Ja=Koe;const Joe=St(Ja);var Zoe=$s,Xoe=Ja;function eae(e,t){return e&&Zoe(t,Xoe(t),e)}var tae=eae,nae=$s,rae=Ps;function oae(e,t){return e&&nae(t,rae(t),e)}var aae=oae;function iae(e,t){for(var r=-1,o=e==null?0:e.length,a=0,i=[];++r<o;){var l=e[r];t(l,r,e)&&(i[a++]=l)}return i}var Fb=iae;function lae(){return[]}var Ub=lae,sae=Fb,cae=Ub,uae=Object.prototype,dae=uae.propertyIsEnumerable,Hg=Object.getOwnPropertySymbols,fae=Hg?function(e){return e==null?[]:(e=Object(e),sae(Hg(e),function(t){return dae.call(e,t)}))}:cae,_h=fae,pae=$s,mae=_h;function hae(e,t){return pae(e,mae(e),t)}var gae=hae;function vae(e,t){for(var r=-1,o=t.length,a=e.length;++r<o;)e[a+r]=t[r];return e}var Ih=vae,yae=Ih,Mae=cm,bae=_h,wae=Ub,Nae=Object.getOwnPropertySymbols,kae=Nae?function(e){for(var t=[];e;)yae(t,bae(e)),e=Mae(e);return t}:wae,Hb=kae,xae=$s,Cae=Hb;function Eae(e,t){return xae(e,Cae(e),t)}var Tae=Eae,Dae=Ih,Sae=vr;function _ae(e,t,r){var o=t(e);return Sae(e)?o:Dae(o,r(e))}var Yb=_ae,Iae=Yb,Aae=_h,Oae=Ja;function zae(e){return Iae(e,Oae,Aae)}var Qb=zae,jae=Yb,Lae=Hb,Bae=Ps;function Vae(e){return jae(e,Bae,Lae)}var $ae=Vae,Pae=Ha,Rae=jr,Fae=Pae(Rae,"DataView"),Uae=Fae,Hae=Ha,Yae=jr,Qae=Hae(Yae,"Promise"),Wae=Qae,qae=Ha,Gae=jr,Kae=qae(Gae,"Set"),Wb=Kae,Jae=Ha,Zae=jr,Xae=Jae(Zae,"WeakMap"),eie=Xae,f0=Uae,p0=am,m0=Wae,h0=Wb,g0=eie,qb=rl,pl=ny,Yg="[object Map]",tie="[object Object]",Qg="[object Promise]",Wg="[object Set]",qg="[object WeakMap]",Gg="[object DataView]",nie=pl(f0),rie=pl(p0),oie=pl(m0),aie=pl(h0),iie=pl(g0),va=qb;(f0&&va(new f0(new ArrayBuffer(1)))!=Gg||p0&&va(new p0)!=Yg||m0&&va(m0.resolve())!=Qg||h0&&va(new h0)!=Wg||g0&&va(new g0)!=qg)&&(va=function(e){var t=qb(e),r=t==tie?e.constructor:void 0,o=r?pl(r):"";if(o)switch(o){case nie:return Gg;case rie:return Yg;case oie:return Qg;case aie:return Wg;case iie:return qg}return t});var Xd=va,lie=Object.prototype,sie=lie.hasOwnProperty;function cie(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&sie.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var uie=cie,die=sm;function fie(e,t){var r=t?die(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var pie=fie,mie=/\w*$/;function hie(e){var t=new e.constructor(e.source,mie.exec(e));return t.lastIndex=e.lastIndex,t}var gie=hie,Kg=nl,Jg=Kg?Kg.prototype:void 0,Zg=Jg?Jg.valueOf:void 0;function vie(e){return Zg?Object(Zg.call(e)):{}}var yie=vie,Mie=sm,bie=pie,wie=gie,Nie=yie,kie=sy,xie="[object Boolean]",Cie="[object Date]",Eie="[object Map]",Tie="[object Number]",Die="[object RegExp]",Sie="[object Set]",_ie="[object String]",Iie="[object Symbol]",Aie="[object ArrayBuffer]",Oie="[object DataView]",zie="[object Float32Array]",jie="[object Float64Array]",Lie="[object Int8Array]",Bie="[object Int16Array]",Vie="[object Int32Array]",$ie="[object Uint8Array]",Pie="[object Uint8ClampedArray]",Rie="[object Uint16Array]",Fie="[object Uint32Array]";function Uie(e,t,r){var o=e.constructor;switch(t){case Aie:return Mie(e);case xie:case Cie:return new o(+e);case Oie:return bie(e,r);case zie:case jie:case Lie:case Bie:case Vie:case $ie:case Pie:case Rie:case Fie:return kie(e,r);case Eie:return new o;case Tie:case _ie:return new o(e);case Die:return wie(e);case Sie:return new o;case Iie:return Nie(e)}}var Hie=Uie,Yie=Xd,Qie=ko,Wie="[object Map]";function qie(e){return Qie(e)&&Yie(e)==Wie}var Gie=qie,Kie=Gie,Jie=_d,Xg=fm,e4=Xg&&Xg.isMap,Zie=e4?Jie(e4):Kie,Xie=Zie,ele=Xd,tle=ko,nle="[object Set]";function rle(e){return tle(e)&&ele(e)==nle}var ole=rle,ale=ole,ile=_d,t4=fm,n4=t4&&t4.isSet,lle=n4?ile(n4):ale,sle=lle,cle=Td,ule=Boe,dle=gy,fle=tae,ple=aae,mle=iy,hle=cy,gle=gae,vle=Tae,yle=Qb,Mle=$ae,ble=Xd,wle=uie,Nle=Hie,kle=dy,xle=vr,Cle=Sd,Ele=Xie,Tle=Lr,Dle=sle,Sle=Ja,_le=Ps,Ile=1,Ale=2,Ole=4,Gb="[object Arguments]",zle="[object Array]",jle="[object Boolean]",Lle="[object Date]",Ble="[object Error]",Kb="[object Function]",Vle="[object GeneratorFunction]",$le="[object Map]",Ple="[object Number]",Jb="[object Object]",Rle="[object RegExp]",Fle="[object Set]",Ule="[object String]",Hle="[object Symbol]",Yle="[object WeakMap]",Qle="[object ArrayBuffer]",Wle="[object DataView]",qle="[object Float32Array]",Gle="[object Float64Array]",Kle="[object Int8Array]",Jle="[object Int16Array]",Zle="[object Int32Array]",Xle="[object Uint8Array]",ese="[object Uint8ClampedArray]",tse="[object Uint16Array]",nse="[object Uint32Array]",Mt={};Mt[Gb]=Mt[zle]=Mt[Qle]=Mt[Wle]=Mt[jle]=Mt[Lle]=Mt[qle]=Mt[Gle]=Mt[Kle]=Mt[Jle]=Mt[Zle]=Mt[$le]=Mt[Ple]=Mt[Jb]=Mt[Rle]=Mt[Fle]=Mt[Ule]=Mt[Hle]=Mt[Xle]=Mt[ese]=Mt[tse]=Mt[nse]=!0;Mt[Ble]=Mt[Kb]=Mt[Yle]=!1;function Yc(e,t,r,o,a,i){var l,s=t&Ile,c=t&Ale,u=t&Ole;if(r&&(l=a?r(e,o,a,i):r(e)),l!==void 0)return l;if(!Tle(e))return e;var d=xle(e);if(d){if(l=wle(e),!s)return hle(e,l)}else{var f=ble(e),p=f==Kb||f==Vle;if(Cle(e))return mle(e,s);if(f==Jb||f==Gb||p&&!a){if(l=c||p?{}:kle(e),!s)return c?vle(e,ple(l,e)):gle(e,fle(l,e))}else{if(!Mt[f])return a?e:{};l=Nle(e,f,s)}}i||(i=new cle);var h=i.get(e);if(h)return h;i.set(e,l),Dle(e)?e.forEach(function(v){l.add(Yc(v,t,r,v,e,i))}):Ele(e)&&e.forEach(function(v,y){l.set(y,Yc(v,t,r,y,e,i))});var m=u?c?Mle:yle:c?_le:Sle,g=d?void 0:m(e);return ule(g||e,function(v,y){g&&(y=v,v=e[y]),dle(l,y,Yc(v,t,r,y,e,i))}),l}var rse=Yc,ose=rse,ase=1,ise=4;function lse(e){return ose(e,ase|ise)}var sse=lse;const $n=St(sse);var cse="__lodash_hash_undefined__";function use(e){return this.__data__.set(e,cse),this}var dse=use;function fse(e){return this.__data__.has(e)}var pse=fse,mse=im,hse=dse,gse=pse;function Cu(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new mse;++t<r;)this.add(e[t])}Cu.prototype.add=Cu.prototype.push=hse;Cu.prototype.has=gse;var Ah=Cu;function vse(e,t){for(var r=-1,o=e==null?0:e.length;++r<o;)if(t(e[r],r,e))return!0;return!1}var yse=vse;function Mse(e,t){return e.has(t)}var Oh=Mse,bse=Ah,wse=yse,Nse=Oh,kse=1,xse=2;function Cse(e,t,r,o,a,i){var l=r&kse,s=e.length,c=t.length;if(s!=c&&!(l&&c>s))return!1;var u=i.get(e),d=i.get(t);if(u&&d)return u==t&&d==e;var f=-1,p=!0,h=r&xse?new bse:void 0;for(i.set(e,t),i.set(t,e);++f<s;){var m=e[f],g=t[f];if(o)var v=l?o(g,m,f,t,e,i):o(m,g,f,e,t,i);if(v!==void 0){if(v)continue;p=!1;break}if(h){if(!wse(t,function(y,N){if(!Nse(h,N)&&(m===y||a(m,y,r,o,i)))return h.push(N)})){p=!1;break}}else if(!(m===g||a(m,g,r,o,i))){p=!1;break}}return i.delete(e),i.delete(t),p}var Zb=Cse;function Ese(e){var t=-1,r=Array(e.size);return e.forEach(function(o,a){r[++t]=[a,o]}),r}var Tse=Ese;function Dse(e){var t=-1,r=Array(e.size);return e.forEach(function(o){r[++t]=o}),r}var zh=Dse,r4=nl,o4=ly,Sse=Vs,_se=Zb,Ise=Tse,Ase=zh,Ose=1,zse=2,jse="[object Boolean]",Lse="[object Date]",Bse="[object Error]",Vse="[object Map]",$se="[object Number]",Pse="[object RegExp]",Rse="[object Set]",Fse="[object String]",Use="[object Symbol]",Hse="[object ArrayBuffer]",Yse="[object DataView]",a4=r4?r4.prototype:void 0,Rf=a4?a4.valueOf:void 0;function Qse(e,t,r,o,a,i,l){switch(r){case Yse:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case Hse:return!(e.byteLength!=t.byteLength||!i(new o4(e),new o4(t)));case jse:case Lse:case $se:return Sse(+e,+t);case Bse:return e.name==t.name&&e.message==t.message;case Pse:case Fse:return e==t+"";case Vse:var s=Ise;case Rse:var c=o&Ose;if(s||(s=Ase),e.size!=t.size&&!c)return!1;var u=l.get(e);if(u)return u==t;o|=zse,l.set(e,t);var d=_se(s(e),s(t),o,a,i,l);return l.delete(e),d;case Use:if(Rf)return Rf.call(e)==Rf.call(t)}return!1}var Wse=Qse,i4=Qb,qse=1,Gse=Object.prototype,Kse=Gse.hasOwnProperty;function Jse(e,t,r,o,a,i){var l=r&qse,s=i4(e),c=s.length,u=i4(t),d=u.length;if(c!=d&&!l)return!1;for(var f=c;f--;){var p=s[f];if(!(l?p in t:Kse.call(t,p)))return!1}var h=i.get(e),m=i.get(t);if(h&&m)return h==t&&m==e;var g=!0;i.set(e,t),i.set(t,e);for(var v=l;++f<c;){p=s[f];var y=e[p],N=t[p];if(o)var b=l?o(N,y,p,t,e,i):o(y,N,p,e,t,i);if(!(b===void 0?y===N||a(y,N,r,o,i):b)){g=!1;break}v||(v=p=="constructor")}if(g&&!v){var M=e.constructor,k=t.constructor;M!=k&&"constructor"in e&&"constructor"in t&&!(typeof M=="function"&&M instanceof M&&typeof k=="function"&&k instanceof k)&&(g=!1)}return i.delete(e),i.delete(t),g}var Zse=Jse,Ff=Td,Xse=Zb,ece=Wse,tce=Zse,l4=Xd,s4=vr,c4=Sd,nce=pm,rce=1,u4="[object Arguments]",d4="[object Array]",wc="[object Object]",oce=Object.prototype,f4=oce.hasOwnProperty;function ace(e,t,r,o,a,i){var l=s4(e),s=s4(t),c=l?d4:l4(e),u=s?d4:l4(t);c=c==u4?wc:c,u=u==u4?wc:u;var d=c==wc,f=u==wc,p=c==u;if(p&&c4(e)){if(!c4(t))return!1;l=!0,d=!1}if(p&&!d)return i||(i=new Ff),l||nce(e)?Xse(e,t,r,o,a,i):ece(e,t,c,r,o,a,i);if(!(r&rce)){var h=d&&f4.call(e,"__wrapped__"),m=f&&f4.call(t,"__wrapped__");if(h||m){var g=h?e.value():e,v=m?t.value():t;return i||(i=new Ff),a(g,v,r,o,i)}}return p?(i||(i=new Ff),tce(e,t,r,o,a,i)):!1}var ice=ace,lce=ice,p4=ko;function Xb(e,t,r,o,a){return e===t?!0:e==null||t==null||!p4(e)&&!p4(t)?e!==e&&t!==t:lce(e,t,r,o,Xb,a)}var jh=Xb,sce=jh;function cce(e,t){return sce(e,t)}var uce=cce;const dce=St(uce);function fce(e,t,r,o){for(var a=e.length,i=r+(o?1:-1);o?i--:++i<a;)if(t(e[i],i,e))return i;return-1}var e8=fce,pce=Td,mce=jh,hce=1,gce=2;function vce(e,t,r,o){var a=r.length,i=a,l=!o;if(e==null)return!i;for(e=Object(e);a--;){var s=r[a];if(l&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<i;){s=r[a];var c=s[0],u=e[c],d=s[1];if(l&&s[2]){if(u===void 0&&!(c in e))return!1}else{var f=new pce;if(o)var p=o(u,d,c,e,t,f);if(!(p===void 0?mce(d,u,hce|gce,o,f):p))return!1}}return!0}var yce=vce,Mce=Lr;function bce(e){return e===e&&!Mce(e)}var t8=bce,wce=t8,Nce=Ja;function kce(e){for(var t=Nce(e),r=t.length;r--;){var o=t[r],a=e[o];t[r]=[o,a,wce(a)]}return t}var xce=kce;function Cce(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}var n8=Cce,Ece=yce,Tce=xce,Dce=n8;function Sce(e){var t=Tce(e);return t.length==1&&t[0][2]?Dce(t[0][0],t[0][1]):function(r){return r===e||Ece(r,e,t)}}var _ce=Sce;function Ice(e,t){return e!=null&&t in Object(e)}var Ace=Ice,Oce=$b,zce=Dd,jce=vr,Lce=mm,Bce=dm,Vce=Zd;function $ce(e,t,r){t=Oce(t,e);for(var o=-1,a=t.length,i=!1;++o<a;){var l=Vce(t[o]);if(!(i=e!=null&&r(e,l)))break;e=e[l]}return i||++o!=a?i:(a=e==null?0:e.length,!!a&&Bce(a)&&Lce(l,a)&&(jce(e)||zce(e)))}var Pce=$ce,Rce=Ace,Fce=Pce;function Uce(e,t){return e!=null&&Fce(e,t,Rce)}var Hce=Uce,Yce=jh,Qce=Rb,Wce=Hce,qce=Dh,Gce=t8,Kce=n8,Jce=Zd,Zce=1,Xce=2;function eue(e,t){return qce(e)&&Gce(t)?Kce(Jce(e),t):function(r){var o=Qce(r,e);return o===void 0&&o===t?Wce(r,e):Yce(t,o,Zce|Xce)}}var tue=eue;function nue(e){return function(t){return t==null?void 0:t[e]}}var rue=nue,oue=Pb;function aue(e){return function(t){return oue(t,e)}}var iue=aue,lue=rue,sue=iue,cue=Dh,uue=Zd;function due(e){return cue(e)?lue(uue(e)):sue(e)}var fue=due,pue=_ce,mue=tue,hue=hm,gue=vr,vue=fue;function yue(e){return typeof e=="function"?e:e==null?hue:typeof e=="object"?gue(e)?mue(e[0],e[1]):pue(e):vue(e)}var Lh=yue,Mue=/\s/;function bue(e){for(var t=e.length;t--&&Mue.test(e.charAt(t)););return t}var wue=bue,Nue=wue,kue=/^\s+/;function xue(e){return e&&e.slice(0,Nue(e)+1).replace(kue,"")}var Cue=xue,Eue=Cue,m4=Lr,Tue=Jd,h4=0/0,Due=/^[-+]0x[0-9a-f]+$/i,Sue=/^0b[01]+$/i,_ue=/^0o[0-7]+$/i,Iue=parseInt;function Aue(e){if(typeof e=="number")return e;if(Tue(e))return h4;if(m4(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=m4(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Eue(e);var r=Sue.test(e);return r||_ue.test(e)?Iue(e.slice(2),r?2:8):Due.test(e)?h4:+e}var r8=Aue,Oue=r8,g4=1/0,zue=17976931348623157e292;function jue(e){if(!e)return e===0?e:0;if(e=Oue(e),e===g4||e===-g4){var t=e<0?-1:1;return t*zue}return e===e?e:0}var Lue=jue,Bue=Lue;function Vue(e){var t=Bue(e),r=t%1;return t===t?r?t-r:t:0}var $ue=Vue,Pue=e8,Rue=Lh,Fue=$ue,Uue=Math.max;function Hue(e,t,r){var o=e==null?0:e.length;if(!o)return-1;var a=r==null?0:Fue(r);return a<0&&(a=Uue(o+a,0)),Pue(e,Rue(t),a)}var o8=Hue;const v4=St(o8);var Yue=Lh,Que=ll,Wue=Ja;function que(e){return function(t,r,o){var a=Object(t);if(!Que(t)){var i=Yue(r);t=Wue(t),r=function(s){return i(a[s],s,a)}}var l=e(t,r,o);return l>-1?a[i?t[l]:l]:void 0}}var Gue=que,Kue=Gue,Jue=o8,Zue=Kue(Jue),Xue=Zue;const ede=St(Xue);var tde=ay,nde=Ja;function rde(e,t){return e&&tde(e,t,nde)}var ode=rde,ade=ll;function ide(e,t){return function(r,o){if(r==null)return r;if(!ade(r))return e(r,o);for(var a=r.length,i=t?a:-1,l=Object(r);(t?i--:++i<a)&&o(l[i],i,l)!==!1;);return r}}var lde=ide,sde=ode,cde=lde,ude=cde(sde),dde=ude,fde=dde;function pde(e,t){var r=[];return fde(e,function(o,a,i){t(o,a,i)&&r.push(o)}),r}var mde=pde,hde=Fb,gde=mde,vde=Lh,yde=vr;function Mde(e,t){var r=yde(e)?hde:gde;return r(e,vde(t))}var bde=Mde;const a8=St(bde);const wde={name:"AddFilterButton",props:{schema:Object,filters:Array,lang:{type:String,default(){return pn()}}},methods:{addFilter(e){const t={path:e.path,value:null,comparison:null,valid:!1};this.$emit("addFilter",t)},hasFilterFor(e){return ede(this.filters,{path:e})}},computed:{availableOptions(){var e,t;return(t=(e=this.schema)==null?void 0:e.fields)!=null&&t.length?a8(this.schema.fields,r=>r.filterable&&!this.hasFilterFor(r.path)):[]}}};function Nde(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button"),c=n.resolveComponent("l-dropdown-item"),u=n.resolveComponent("l-tooltip"),d=n.resolveComponent("l-dropdown-menu"),f=n.resolveComponent("l-dropdown");return n.openBlock(),n.createBlock(f,{trigger:"click",placement:"bottom-start",onCommand:i.addFilter},{default:n.withCtx(()=>[n.withDirectives(n.createVNode(s,{class:"add-filter-button",round:"",plain:"",size:"small"},{default:n.withCtx(()=>[n.createVNode(l,{style:{"margin-right":"4px"}},{default:n.withCtx(()=>t[0]||(t[0]=[n.createTextVNode("uil-plus")])),_:1}),n.createTextVNode(n.toDisplayString(e.$tds("add-filter",r.lang)),1)]),_:1},512),[[n.vShow,i.availableOptions.length>0]])]),dropdown:n.withCtx(()=>[n.createVNode(d,null,{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.availableOptions,p=>(n.openBlock(),n.createBlock(u,{key:p.title,disabled:!p.description,content:p.description,effect:"light","open-delay":600,placement:"right-start"},{default:n.withCtx(()=>[n.createVNode(c,{command:p,disabled:i.hasFilterFor(p.path)},{default:n.withCtx(()=>[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(p)),1)]),_:2},1024),n.createTextVNode(" "+n.toDisplayString(p.title),1)]),_:2},1032,["command","disabled"])]),_:2},1032,["disabled","content"]))),128))]),_:1})]),_:1},8,["onCommand"])}const kde=xe(wde,[["render",Nde]]);const xde={props:{filter:Object,schema:Object},emits:["update:filter","change","cancel"],data(){return Dt(this.schema,"options.enum")?{form:{value:this.filter.value||[],comparison:this.filter.comparison||"in"}}:{form:{value:this.filter.value,comparison:this.filter.comparison||"contains"}}},watch:{"form.comparison":{handler(){this.$nextTick(()=>this.focus())}}},methods:{focus(){this.$refs.valueInput&&this.$refs.valueInput[0].$el.focus()},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};console.log("newFilter",t),this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{valuesEnum(){return Dt(this.schema,"options.enum")},inlineComponent(){try{return this.$L.FieldTypeComponents.get(this.schema,"default")}catch{return null}},comparisons(){return[{label:this.$tds("contains"),value:"contains"},{label:this.$tds("starts-at"),value:"starts_with"},{label:this.$tds("ends-at"),value:"ends_with"},{label:this.$tds("exactly"),value:"eq"},{label:this.$tds("not-equal"),value:"neq"}]},rules(){return{value:[{required:!0,message:`${this.$tds("type-to-filter")} ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`${this.$tds("choose-a-mode-to-filter")} ${this.schema.title}`,trigger:"change"}]}}}},Cde=["textContent"];function Ede(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox"),s=n.resolveComponent("l-checkbox-group"),c=n.resolveComponent("l-form-item"),u=n.resolveComponent("l-radio"),d=n.resolveComponent("l-input"),f=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(f,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[3]||(t[3]=n.withModifiers(()=>{},["prevent"])),class:"item-wrapper"},{default:n.withCtx(()=>[i.valuesEnum?(n.openBlock(),n.createBlock(c,{key:0,prop:"value"},{default:n.withCtx(()=>[n.createVNode(s,{modelValue:a.form.value,"onUpdate:modelValue":t[0]||(t[0]=p=>a.form.value=p),style:{display:"flex","flex-direction":"column"}},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.valuesEnum,p=>(n.openBlock(),n.createBlock(l,{label:p,value:p,key:p},{default:n.withCtx(()=>[i.inlineComponent?(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.inlineComponent),{key:0,value:p,schema:r.schema},null,8,["value","schema"])):(n.openBlock(),n.createElementBlock("span",{key:1,textContent:n.toDisplayString(p)},null,8,Cde))]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})):(n.openBlock(),n.createBlock(c,{key:1,prop:"comparison"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.comparisons,p=>(n.openBlock(),n.createElementBlock("div",{key:p.value},[n.createVNode(u,{modelValue:a.form.comparison,"onUpdate:modelValue":t[1]||(t[1]=h=>a.form.comparison=h),label:p.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(p.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison===p.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createVNode(d,{ref_for:!0,ref:"valueInput",modelValue:a.form.value,"onUpdate:modelValue":t[2]||(t[2]=h=>a.form.value=h)},null,8,["modelValue"])]),_:1})):n.createCommentVNode("",!0)]))),128))]),_:1}))]),_:1},8,["model","rules"])}const Tde=xe(xde,[["render",Ede],["__scopeId","data-v-4a82d0be"]]);/*!
|
|
35
|
+
`)}}),fX={loading:Boolean,data:{type:Array,required:!0},hoveringIndex:Number,width:Number,id:String,ariaLabel:String};var pX=n.defineComponent({name:"ElSelectDropdown",props:fX,setup(e,{slots:t,expose:r}){const o=n.inject(Ch),a=he("select"),{getLabel:i,getValue:l,getDisabled:s}=Qs(o.props),c=n.ref([]),u=n.ref(),d=n.computed(()=>e.data.length);n.watch(()=>d.value,()=>{var _,j;(j=(_=o.tooltipRef.value)==null?void 0:_.updatePopper)==null||j.call(_)});const f=n.computed(()=>Rt(o.props.estimatedOptionHeight)),p=n.computed(()=>f.value?{itemSize:o.props.itemHeight}:{estimatedSize:o.props.estimatedOptionHeight,itemSize:_=>c.value[_]}),h=(_=[],j)=>{const{props:{valueKey:R}}=o;return ft(j)?_&&_.some(P=>n.toRaw(jt(P,R))===jt(j,R)):_.includes(j)},m=(_,j)=>{if(ft(j)){const{valueKey:R}=o.props;return jt(_,R)===jt(j,R)}else return _===j},g=(_,j)=>o.props.multiple?h(_,l(j)):m(_,l(j)),v=(_,j)=>{const{disabled:R,multiple:P,multipleLimit:$}=o.props;return R||!j&&(P?$>0&&_.length>=$:!1)},y=_=>e.hoveringIndex===_;r({listRef:u,isSized:f,isItemDisabled:v,isItemHovering:y,isItemSelected:g,scrollToItem:_=>{const j=u.value;j&&j.scrollToItem(_)},resetScrollTop:()=>{const _=u.value;_&&_.resetScrollTop()}});const k=_=>{const{index:j,data:R,style:P}=_,$=n.unref(f),{itemSize:V,estimatedSize:D}=n.unref(p),{modelValue:x}=o.props,{onSelect:S,onHover:L}=o,B=R[j];if(B.type==="Group")return n.createVNode(VZ,{item:B,style:P,height:$?V:D},null);const F=g(x,B),T=v(x,F),z=y(j);return n.createVNode(WZ,n.mergeProps(_,{selected:F,disabled:s(B)||T,created:!!B.created,hovering:z,item:B,onSelect:S,onHover:L}),{default:I=>{var Z;return((Z=t.default)==null?void 0:Z.call(t,I))||n.createVNode("span",null,[i(B)])}})},{onKeyboardNavigate:w,onKeyboardSelect:C}=o,E=()=>{w("forward")},A=()=>{w("backward")},O=_=>{const j=Lt(_),{tab:R,esc:P,down:$,up:V,enter:D,numpadEnter:x}=ve;switch([P,$,V,D,x].includes(j)&&(_.preventDefault(),_.stopPropagation()),j){case R:case P:break;case $:E();break;case V:A();break;case D:case x:C();break}};return()=>{var _,j,R,P;const{data:$,width:V}=e,{height:D,multiple:x,scrollbarAlwaysOn:S}=o.props,L=n.computed(()=>fu?!0:S),B=n.unref(f)?lX:dX;return n.createVNode("div",{class:[a.b("dropdown"),a.is("multiple",x)],style:{width:`${V}px`}},[(_=t.header)==null?void 0:_.call(t),((j=t.loading)==null?void 0:j.call(t))||((R=t.empty)==null?void 0:R.call(t))||n.createVNode(B,n.mergeProps({ref:u},n.unref(p),{className:a.be("dropdown","list"),scrollbarAlwaysOn:L.value,data:$,height:D,width:V,total:$.length,innerElement:"ul",innerProps:{id:e.id,role:"listbox","aria-label":e.ariaLabel,"aria-orientation":"vertical"},onKeydown:O}),{default:F=>n.createVNode(k,F,null)}),(P=t.footer)==null?void 0:P.call(t)])}}});function mX(e,t){const{aliasProps:r,getLabel:o,getValue:a}=Qs(e),i=n.ref(0),l=n.ref(),s=n.computed(()=>e.allowCreate&&e.filterable);n.watch(()=>e.options,h=>{const m=new Set(h.map(g=>o(g)));t.createdOptions=t.createdOptions.filter(g=>!m.has(o(g)))});function c(h){const m=g=>o(g)===h;return e.options&&e.options.some(m)||t.createdOptions.some(m)}function u(h){s.value&&(e.multiple&&h.created?i.value++:l.value=h)}function d(h){if(s.value)if(h&&h.length>0){if(c(h)){t.createdOptions=t.createdOptions.filter(g=>o(g)!==t.previousQuery);return}const m={[r.value.value]:h,[r.value.label]:h,created:!0,[r.value.disabled]:!1};t.createdOptions.length>=i.value?t.createdOptions[i.value]=m:t.createdOptions.push(m)}else if(e.multiple)t.createdOptions.length=i.value;else{const m=l.value;t.createdOptions.length=0,m&&m.created&&t.createdOptions.push(m)}}function f(h){if(!s.value||!h||!h.created||h.created&&e.reserveKeyword&&t.inputValue===o(h))return;const m=t.createdOptions.findIndex(g=>a(g)===a(h));~m&&(t.createdOptions.splice(m,1),i.value--)}function p(){s.value&&(t.createdOptions.length=0,i.value=0)}return{createNewOption:d,removeNewOption:f,selectNewOption:u,clearAllNewOption:p}}const hX=(e,t)=>{const{t:r}=Nt(),o=n.useSlots(),a=he("select"),i=he("input"),{form:l,formItem:s}=Kn(),{inputId:c}=io(e,{formItemContext:s}),{aliasProps:u,getLabel:d,getValue:f,getDisabled:p,getOptions:h}=Qs(e),{valueOnClear:m,isEmptyValue:g}=zm(e),v=n.reactive({inputValue:"",cachedOptions:[],createdOptions:[],hoveringIndex:-1,inputHovering:!1,selectionWidth:0,collapseItemWidth:0,previousQuery:null,previousValue:void 0,selectedLabel:"",menuVisibleOnFocus:!1,isBeforeHide:!1}),y=n.ref(-1),N=n.ref(!1),b=n.ref(),M=n.ref(),k=n.ref(),w=n.ref(),C=n.ref(),E=n.ref(),A=n.ref(),O=n.ref(),_=n.ref(),j=n.ref(),{isComposing:R,handleCompositionStart:P,handleCompositionEnd:$,handleCompositionUpdate:V}=rh({afterComposition:ee=>ie(ee)}),D=Bt(),{wrapperRef:x,isFocused:S,handleBlur:L}=Ys(C,{disabled:D,afterFocus(){e.automaticDropdown&&!z.value&&(z.value=!0,v.menuVisibleOnFocus=!0)},beforeBlur(ee){var me,Te;return((me=k.value)==null?void 0:me.isFocusInsideContent(ee))||((Te=w.value)==null?void 0:Te.isFocusInsideContent(ee))},afterBlur(){var ee;z.value=!1,v.menuVisibleOnFocus=!1,e.validateEvent&&((ee=s==null?void 0:s.validate)==null||ee.call(s,"blur").catch(me=>He(me)))}}),B=n.computed(()=>Ye("")),F=n.computed(()=>e.loading?!1:e.options.length>0||v.createdOptions.length>0),T=n.ref([]),z=n.ref(!1),I=n.computed(()=>{var ee;return(ee=l==null?void 0:l.statusIcon)!=null?ee:!1}),Z=n.computed(()=>{const ee=T.value.length*e.itemHeight;return ee>e.height?e.height:ee}),q=n.computed(()=>e.multiple?De(e.modelValue)&&e.modelValue.length>0:!g(e.modelValue)),te=n.computed(()=>e.clearable&&!D.value&&q.value&&(S.value||v.inputHovering)),J=n.computed(()=>e.remote&&e.filterable&&!e.remoteShowSuffix?"":e.suffixIcon),W=n.computed(()=>J.value&&a.is("reverse",z.value)),ae=n.computed(()=>(s==null?void 0:s.validateState)||""),ce=n.computed(()=>{if(ae.value)return Ym[ae.value]}),ye=n.computed(()=>e.remote?e.debounce:0),Ae=n.computed(()=>e.remote&&!v.inputValue&&!F.value),Fe=n.computed(()=>e.loading?e.loadingText||r("el.select.loading"):e.filterable&&v.inputValue&&F.value&&T.value.length===0?e.noMatchText||r("el.select.noMatch"):F.value?null:e.noDataText||r("el.select.noData")),_e=n.computed(()=>e.filterable&&at(e.filterMethod)),Le=n.computed(()=>e.filterable&&e.remote&&at(e.remoteMethod)),Ye=ee=>{const me=new RegExp(M6(ee),"i"),Te=Oe=>_e.value||Le.value?!0:ee?me.test(d(Oe)||""):!0;return e.loading?[]:[...v.createdOptions,...e.options].reduce((Oe,Vt)=>{const Zn=h(Vt);if(De(Zn)){const yl=Zn.filter(Te);yl.length>0&&Oe.push({label:d(Vt),type:"Group"},...yl)}else(e.remote||Te(Vt))&&Oe.push(Vt);return Oe},[])},Ke=()=>{T.value=Ye(v.inputValue)},Be=n.computed(()=>{const ee=new Map;return B.value.forEach((me,Te)=>{ee.set(de(f(me)),{option:me,index:Te})}),ee}),et=n.computed(()=>{const ee=new Map;return T.value.forEach((me,Te)=>{ee.set(de(f(me)),{option:me,index:Te})}),ee}),lt=n.computed(()=>T.value.every(ee=>p(ee))),je=mn(),H=n.computed(()=>je.value==="small"?"small":"default"),G=()=>{var ee;if(Ve(e.fitInputWidth)){y.value=e.fitInputWidth;return}const me=((ee=b.value)==null?void 0:ee.offsetWidth)||200;!e.fitInputWidth&&F.value?n.nextTick(()=>{y.value=Math.max(me,ze())}):y.value=me},ze=()=>{var ee,me;const Oe=document.createElement("canvas").getContext("2d"),Vt=a.be("dropdown","item"),yl=(((me=(ee=O.value)==null?void 0:ee.listRef)==null?void 0:me.innerRef)||document).querySelector(`.${Vt}`);if(yl===null||Oe===null)return 0;const oc=getComputedStyle(yl),YN=Number.parseFloat(oc.paddingLeft)+Number.parseFloat(oc.paddingRight);return Oe.font=`bold ${oc.font.replace(new RegExp(`\\b${oc.fontWeight}\\b`),"")}`,T.value.reduce((QN,WN)=>{const qN=Oe.measureText(d(WN));return Math.max(qN.width,QN)},0)+YN},pe=()=>{if(!M.value)return 0;const ee=window.getComputedStyle(M.value);return Number.parseFloat(ee.gap||"6px")},we=n.computed(()=>{const ee=pe(),me=e.filterable?ee+fh:0;return{maxWidth:`${j.value&&e.maxCollapseTags===1?v.selectionWidth-v.collapseItemWidth-ee-me:v.selectionWidth-me}px`}}),be=n.computed(()=>({maxWidth:`${v.selectionWidth}px`})),ct=n.computed(()=>De(e.modelValue)?e.modelValue.length===0&&!v.inputValue:e.filterable?!v.inputValue:!0),kt=n.computed(()=>{var ee;const me=(ee=e.placeholder)!=null?ee:r("el.select.placeholder");return e.multiple||!q.value?me:v.selectedLabel}),At=n.computed(()=>{var ee,me;return(me=(ee=k.value)==null?void 0:ee.popperRef)==null?void 0:me.contentRef}),Ut=n.computed(()=>{if(e.multiple){const ee=e.modelValue.length;if(ee>0&&et.value.has(e.modelValue[ee-1])){const{index:me}=et.value.get(e.modelValue[ee-1]);return me}}else if(!g(e.modelValue)&&et.value.has(e.modelValue)){const{index:ee}=et.value.get(e.modelValue);return ee}return-1}),ne=n.computed({get(){return z.value&&(e.loading||!Ae.value||e.remote&&!!o.empty)&&(!N.value||!$d(v.previousQuery))},set(ee){z.value=ee}}),Q=n.computed(()=>e.multiple?e.collapseTags?v.cachedOptions.slice(0,e.maxCollapseTags):v.cachedOptions:[]),oe=n.computed(()=>e.multiple?e.collapseTags?v.cachedOptions.slice(e.maxCollapseTags):[]:[]),{createNewOption:Y,removeNewOption:le,selectNewOption:Ne,clearAllNewOption:Ue}=mX(e,v),ut=ee=>{var me;D.value||e.filterable&&z.value&&ee&&!((me=A.value)!=null&&me.contains(ee.target))||(v.menuVisibleOnFocus?v.menuVisibleOnFocus=!1:z.value=!z.value)},rt=()=>{v.inputValue.length>0&&!z.value&&(z.value=!0),Y(v.inputValue),n.nextTick(()=>{qt(v.inputValue)})},Ct=Im(()=>{rt(),N.value=!1},ye),qt=ee=>{v.previousQuery===ee||R.value||(v.previousQuery=ee,e.filterable&&at(e.filterMethod)?e.filterMethod(ee):e.filterable&&e.remote&&at(e.remoteMethod)&&e.remoteMethod(ee),e.defaultFirstOption&&(e.filterable||e.remote)&&T.value.length?n.nextTick(cn):n.nextTick(U))},cn=()=>{const ee=T.value.filter(Oe=>!Oe.disabled&&Oe.type!=="Group"),me=ee.find(Oe=>Oe.created),Te=ee[0];v.hoveringIndex=se(T.value,me||Te)},_t=ee=>{Yt(e.modelValue,ee)||t(st,ee)},Qe=ee=>{t($e,ee),_t(ee),v.previousValue=e.multiple?String(ee):ee,n.nextTick(()=>{if(e.multiple&&De(e.modelValue)){const me=v.cachedOptions.slice(),Te=e.modelValue.map(Oe=>pt(Oe,me));Yt(v.cachedOptions,Te)||(v.cachedOptions=Te)}else Mr(!0)})},se=(ee=[],me)=>{if(!ft(me))return ee.indexOf(me);const Te=e.valueKey;let Oe=-1;return ee.some((Vt,Zn)=>jt(Vt,Te)===jt(me,Te)?(Oe=Zn,!0):!1),Oe},de=ee=>ft(ee)?jt(ee,e.valueKey):ee,Ce=()=>{G()},Ht=()=>{v.selectionWidth=Number.parseFloat(window.getComputedStyle(M.value).width)},Jn=()=>{v.collapseItemWidth=j.value.getBoundingClientRect().width},Ot=()=>{var ee,me;(me=(ee=k.value)==null?void 0:ee.updatePopper)==null||me.call(ee)},To=()=>{var ee,me;(me=(ee=w.value)==null?void 0:ee.updatePopper)==null||me.call(ee)},Pr=ee=>{const me=f(ee);if(e.multiple){let Te=e.modelValue.slice();const Oe=se(Te,me);Oe>-1?(Te=[...Te.slice(0,Oe),...Te.slice(Oe+1)],v.cachedOptions.splice(Oe,1),le(ee)):(e.multipleLimit<=0||Te.length<e.multipleLimit)&&(Te=[...Te,me],v.cachedOptions.push(ee),Ne(ee)),Qe(Te),ee.created&&qt(""),e.filterable&&!e.reserveKeyword&&(v.inputValue="")}else v.selectedLabel=d(ee),!Yt(e.modelValue,me)&&Qe(me),z.value=!1,Ne(ee),ee.created||Ue();yr()},da=(ee,me)=>{let Te=e.modelValue.slice();const Oe=se(Te,f(me));Oe>-1&&!D.value&&(Te=[...e.modelValue.slice(0,Oe),...e.modelValue.slice(Oe+1)],v.cachedOptions.splice(Oe,1),Qe(Te),t("remove-tag",f(me)),le(me)),ee.stopPropagation(),yr()},yr=()=>{var ee;(ee=C.value)==null||ee.focus()},lo=()=>{var ee;if(z.value){z.value=!1,n.nextTick(()=>{var me;return(me=C.value)==null?void 0:me.blur()});return}(ee=C.value)==null||ee.blur()},Bn=()=>{v.inputValue.length>0?v.inputValue="":z.value=!1},ei=ee=>Jy(ee,me=>!v.cachedOptions.some(Te=>f(Te)===me&&p(Te))),ti=ee=>{const me=Lt(ee);if(e.multiple&&me!==ve.delete&&v.inputValue.length===0){ee.preventDefault();const Te=e.modelValue.slice(),Oe=ei(Te);if(Oe<0)return;const Vt=Te[Oe];Te.splice(Oe,1);const Zn=v.cachedOptions[Oe];v.cachedOptions.splice(Oe,1),le(Zn),Qe(Te),t("remove-tag",Vt)}},ni=()=>{let ee;De(e.modelValue)?ee=[]:ee=m.value,v.selectedLabel="",z.value=!1,Qe(ee),t("clear"),Ue(),yr()},Rr=(ee,me=void 0)=>{const Te=T.value;if(!["forward","backward"].includes(ee)||D.value||Te.length<=0||lt.value||R.value)return;if(!z.value)return ut();Rt(me)&&(me=v.hoveringIndex);let Oe=-1;ee==="forward"?(Oe=me+1,Oe>=Te.length&&(Oe=0)):ee==="backward"&&(Oe=me-1,(Oe<0||Oe>=Te.length)&&(Oe=Te.length-1));const Vt=Te[Oe];if(p(Vt)||Vt.type==="Group")return Rr(ee,Oe);v.hoveringIndex=Oe,ot(Oe)},X=()=>{if(z.value)~v.hoveringIndex&&T.value[v.hoveringIndex]&&Pr(T.value[v.hoveringIndex]);else return ut()},re=ee=>{v.hoveringIndex=ee??-1},U=()=>{if(!e.multiple)v.hoveringIndex=T.value.findIndex(ee=>de(f(ee))===de(e.modelValue));else{const ee=e.modelValue.length;if(ee>0){const me=e.modelValue[ee-1];v.hoveringIndex=T.value.findIndex(Te=>de(me)===de(f(Te)))}else v.hoveringIndex=-1}},ie=ee=>{if(v.inputValue=ee.target.value,e.remote)N.value=!0,Ct();else return rt()},ue=ee=>{if(z.value=!1,S.value){const me=new FocusEvent("blur",ee);L(me)}},Re=()=>(v.isBeforeHide=!1,n.nextTick(()=>{~Ut.value&&ot(Ut.value)})),ot=ee=>{O.value.scrollToItem(ee)},pt=(ee,me)=>{const Te=de(ee);if(Be.value.has(Te)){const{option:Oe}=Be.value.get(Te);return Oe}if(me&&me.length){const Oe=me.find(Vt=>de(f(Vt))===Te);if(Oe)return Oe}return{[u.value.value]:ee,[u.value.label]:ee}},mt=ee=>{var me,Te;return(Te=(me=Be.value.get(f(ee)))==null?void 0:me.index)!=null?Te:-1},Mr=(ee=!1)=>{if(e.multiple)if(e.modelValue.length>0){const me=v.cachedOptions.slice();v.cachedOptions.length=0,v.previousValue=e.modelValue.toString();for(const Te of e.modelValue){const Oe=pt(Te,me);v.cachedOptions.push(Oe)}}else v.cachedOptions=[],v.previousValue=void 0;else if(q.value){v.previousValue=e.modelValue;const me=T.value,Te=me.findIndex(Oe=>de(f(Oe))===de(e.modelValue));~Te?v.selectedLabel=d(me[Te]):(!v.selectedLabel||ee)&&(v.selectedLabel=de(e.modelValue))}else v.selectedLabel="",v.previousValue=void 0;Ue(),G()};n.watch(()=>e.fitInputWidth,()=>{G()}),n.watch(z,ee=>{ee?(e.persistent||G(),qt("")):(v.inputValue="",v.previousQuery=null,v.isBeforeHide=!0,v.menuVisibleOnFocus=!1,Y(""))}),n.watch(()=>e.modelValue,(ee,me)=>{var Te;(!ee||De(ee)&&ee.length===0||e.multiple&&!Yt(ee.toString(),v.previousValue)||!e.multiple&&de(ee)!==de(v.previousValue))&&Mr(!0),!Yt(ee,me)&&e.validateEvent&&((Te=s==null?void 0:s.validate)==null||Te.call(s,"change").catch(Vt=>He(Vt)))},{deep:!0}),n.watch(()=>e.options,()=>{const ee=C.value;(!ee||ee&&document.activeElement!==ee)&&Mr()},{deep:!0,flush:"post"}),n.watch(()=>T.value,()=>(G(),O.value&&n.nextTick(O.value.resetScrollTop))),n.watchEffect(()=>{v.isBeforeHide||Ke()}),n.watchEffect(()=>{const{valueKey:ee,options:me}=e,Te=new Map;for(const Oe of me){const Vt=f(Oe);let Zn=Vt;if(ft(Zn)&&(Zn=jt(Vt,ee)),Te.get(Zn)){He("ElSelectV2","The option values you provided seem to be duplicated, which may cause some problems, please check.");break}else Te.set(Zn,!0)}}),n.onMounted(()=>{Mr()}),zt(b,Ce),zt(M,Ht),zt(x,Ot),zt(_,To),zt(j,Jn);let Et;return n.watch(()=>ne.value,ee=>{ee?Et=zt(O,Ot).stop:(Et==null||Et(),Et=void 0),t("visible-change",ee)}),{inputId:c,collapseTagSize:H,currentPlaceholder:kt,expanded:z,emptyText:Fe,popupHeight:Z,debounce:ye,allOptions:B,allOptionsValueMap:Be,filteredOptions:T,iconComponent:J,iconReverse:W,tagStyle:we,collapseTagStyle:be,popperSize:y,dropdownMenuVisible:ne,hasModelValue:q,shouldShowPlaceholder:ct,selectDisabled:D,selectSize:je,needStatusIcon:I,showClearBtn:te,states:v,isFocused:S,nsSelect:a,nsInput:i,inputRef:C,menuRef:O,tagMenuRef:_,tooltipRef:k,tagTooltipRef:w,selectRef:b,wrapperRef:x,selectionRef:M,prefixRef:E,suffixRef:A,collapseItemRef:j,popperRef:At,validateState:ae,validateIcon:ce,showTagList:Q,collapseTagList:oe,debouncedOnInputChange:Ct,deleteTag:da,getLabel:d,getValue:f,getDisabled:p,getValueKey:de,getIndex:mt,handleClear:ni,handleClickOutside:ue,handleDel:ti,handleEsc:Bn,focus:yr,blur:lo,handleMenuEnter:Re,handleResize:Ce,resetSelectionWidth:Ht,updateTooltip:Ot,updateTagTooltip:To,updateOptions:Ke,toggleMenu:ut,scrollTo:ot,onInput:ie,onKeyboardNavigate:Rr,onKeyboardSelect:X,onSelect:Pr,onHover:re,handleCompositionStart:P,handleCompositionEnd:$,handleCompositionUpdate:V}};var gX=n.defineComponent({name:"ElSelectV2",components:{ElSelectMenu:pX,ElTag:v6,ElTooltip:Ka,ElIcon:ke},directives:{ClickOutside:ps},props:PZ,emits:FZ,setup(e,{emit:t}){const r=n.computed(()=>{const{modelValue:c,multiple:u}=e,d=u?[]:void 0;return De(c)?u?c:d:u?d:c}),o=hX(n.reactive({...n.toRefs(e),modelValue:r}),t),{calculatorRef:a,inputStyle:i}=w6(),l=Ar();n.provide(Ch,{props:n.reactive({...n.toRefs(e),height:o.popupHeight,modelValue:r}),expanded:o.expanded,tooltipRef:o.tooltipRef,contentId:l,onSelect:o.onSelect,onHover:o.onHover,onKeyboardNavigate:o.onKeyboardNavigate,onKeyboardSelect:o.onKeyboardSelect});const s=n.computed(()=>e.multiple?o.states.cachedOptions.map(c=>o.getLabel(c)):o.states.selectedLabel);return{...o,modelValue:r,selectedLabel:s,calculatorRef:a,inputStyle:i,contentId:l,BORDER_HORIZONTAL_WIDTH:b6}}});const vX=["id","value","autocomplete","tabindex","aria-expanded","aria-label","disabled","aria-controls","aria-activedescendant","readonly","name"],yX=["textContent"],MX={key:1};function bX(e,t,r,o,a,i){const l=n.resolveComponent("el-tag"),s=n.resolveComponent("el-tooltip"),c=n.resolveComponent("el-icon"),u=n.resolveComponent("el-select-menu"),d=n.resolveDirective("click-outside");return n.withDirectives((n.openBlock(),n.createElementBlock("div",{ref:"selectRef",class:n.normalizeClass([e.nsSelect.b(),e.nsSelect.m(e.selectSize)]),onMouseenter:t[14]||(t[14]=f=>e.states.inputHovering=!0),onMouseleave:t[15]||(t[15]=f=>e.states.inputHovering=!1)},[n.createVNode(s,{ref:"tooltipRef",visible:e.dropdownMenuVisible,teleported:e.teleported,"popper-class":[e.nsSelect.e("popper"),e.popperClass],"popper-style":e.popperStyle,"gpu-acceleration":!1,"stop-popper-mouse-event":!1,"popper-options":e.popperOptions,"fallback-placements":e.fallbackPlacements,effect:e.effect,placement:e.placement,pure:"",transition:`${e.nsSelect.namespace.value}-zoom-in-top`,trigger:"click",persistent:e.persistent,"append-to":e.appendTo,"show-arrow":e.showArrow,offset:e.offset,onBeforeShow:e.handleMenuEnter,onHide:t[13]||(t[13]=f=>e.states.isBeforeHide=!1)},{default:n.withCtx(()=>{var f,p;return[n.createElementVNode("div",{ref:"wrapperRef",class:n.normalizeClass([e.nsSelect.e("wrapper"),e.nsSelect.is("focused",e.isFocused),e.nsSelect.is("hovering",e.states.inputHovering),e.nsSelect.is("filterable",e.filterable),e.nsSelect.is("disabled",e.selectDisabled)]),onClick:t[10]||(t[10]=n.withModifiers((...h)=>e.toggleMenu&&e.toggleMenu(...h),["prevent"]))},[e.$slots.prefix?(n.openBlock(),n.createElementBlock("div",{key:0,ref:"prefixRef",class:n.normalizeClass(e.nsSelect.e("prefix"))},[n.renderSlot(e.$slots,"prefix")],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("div",{ref:"selectionRef",class:n.normalizeClass([e.nsSelect.e("selection"),e.nsSelect.is("near",e.multiple&&!e.$slots.prefix&&!!e.modelValue.length)])},[e.multiple?n.renderSlot(e.$slots,"tag",{key:0,data:e.states.cachedOptions,deleteTag:e.deleteTag,selectDisabled:e.selectDisabled},()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.showTagList,h=>(n.openBlock(),n.createElementBlock("div",{key:e.getValueKey(e.getValue(h)),class:n.normalizeClass(e.nsSelect.e("selected-item"))},[n.createVNode(l,{closable:!e.selectDisabled&&!e.getDisabled(h),size:e.collapseTagSize,type:e.tagType,effect:e.tagEffect,"disable-transitions":"",style:n.normalizeStyle(e.tagStyle),onClose:m=>e.deleteTag(m,h)},{default:n.withCtx(()=>[n.createElementVNode("span",{class:n.normalizeClass(e.nsSelect.e("tags-text"))},[n.renderSlot(e.$slots,"label",{index:e.getIndex(h),label:e.getLabel(h),value:e.getValue(h)},()=>[n.createTextVNode(n.toDisplayString(e.getLabel(h)),1)])],2)]),_:2},1032,["closable","size","type","effect","style","onClose"])],2))),128)),e.collapseTags&&e.modelValue.length>e.maxCollapseTags?(n.openBlock(),n.createBlock(s,{key:0,ref:"tagTooltipRef",disabled:e.dropdownMenuVisible||!e.collapseTagsTooltip,"fallback-placements":["bottom","top","right","left"],effect:e.effect,placement:"bottom","popper-class":e.popperClass,"popper-style":e.popperStyle,teleported:e.teleported,"popper-options":e.popperOptions},{default:n.withCtx(()=>[n.createElementVNode("div",{ref:"collapseItemRef",class:n.normalizeClass(e.nsSelect.e("selected-item"))},[n.createVNode(l,{closable:!1,size:e.collapseTagSize,type:e.tagType,effect:e.tagEffect,style:n.normalizeStyle(e.collapseTagStyle),"disable-transitions":""},{default:n.withCtx(()=>[n.createElementVNode("span",{class:n.normalizeClass(e.nsSelect.e("tags-text"))}," + "+n.toDisplayString(e.modelValue.length-e.maxCollapseTags),3)]),_:1},8,["size","type","effect","style"])],2)]),content:n.withCtx(()=>[n.createElementVNode("div",{ref:"tagMenuRef",class:n.normalizeClass(e.nsSelect.e("selection"))},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.collapseTagList,h=>(n.openBlock(),n.createElementBlock("div",{key:e.getValueKey(e.getValue(h)),class:n.normalizeClass(e.nsSelect.e("selected-item"))},[n.createVNode(l,{class:"in-tooltip",closable:!e.selectDisabled&&!e.getDisabled(h),size:e.collapseTagSize,type:e.tagType,effect:e.tagEffect,"disable-transitions":"",onClose:m=>e.deleteTag(m,h)},{default:n.withCtx(()=>[n.createElementVNode("span",{class:n.normalizeClass(e.nsSelect.e("tags-text"))},[n.renderSlot(e.$slots,"label",{index:e.getIndex(h),label:e.getLabel(h),value:e.getValue(h)},()=>[n.createTextVNode(n.toDisplayString(e.getLabel(h)),1)])],2)]),_:2},1032,["closable","size","type","effect","onClose"])],2))),128))],2)]),_:3},8,["disabled","effect","popper-class","popper-style","teleported","popper-options"])):n.createCommentVNode("v-if",!0)]):n.createCommentVNode("v-if",!0),n.createElementVNode("div",{class:n.normalizeClass([e.nsSelect.e("selected-item"),e.nsSelect.e("input-wrapper"),e.nsSelect.is("hidden",!e.filterable||e.selectDisabled)])},[n.createElementVNode("input",{id:e.inputId,ref:"inputRef",value:e.states.inputValue,style:n.normalizeStyle(e.inputStyle),autocomplete:e.autocomplete,tabindex:e.tabindex,"aria-autocomplete":"none","aria-haspopup":"listbox",autocapitalize:"off","aria-expanded":e.expanded,"aria-label":e.ariaLabel,class:n.normalizeClass([e.nsSelect.e("input"),e.nsSelect.is(e.selectSize)]),disabled:e.selectDisabled,role:"combobox","aria-controls":e.contentId,"aria-activedescendant":e.states.hoveringIndex>=0?`${e.contentId}-${e.states.hoveringIndex}`:"",readonly:!e.filterable,spellcheck:"false",type:"text",name:e.name,onInput:t[0]||(t[0]=(...h)=>e.onInput&&e.onInput(...h)),onCompositionstart:t[1]||(t[1]=(...h)=>e.handleCompositionStart&&e.handleCompositionStart(...h)),onCompositionupdate:t[2]||(t[2]=(...h)=>e.handleCompositionUpdate&&e.handleCompositionUpdate(...h)),onCompositionend:t[3]||(t[3]=(...h)=>e.handleCompositionEnd&&e.handleCompositionEnd(...h)),onKeydown:[t[4]||(t[4]=n.withKeys(n.withModifiers(h=>e.onKeyboardNavigate("backward"),["stop","prevent"]),["up"])),t[5]||(t[5]=n.withKeys(n.withModifiers(h=>e.onKeyboardNavigate("forward"),["stop","prevent"]),["down"])),t[6]||(t[6]=n.withKeys(n.withModifiers((...h)=>e.onKeyboardSelect&&e.onKeyboardSelect(...h),["stop","prevent"]),["enter"])),t[7]||(t[7]=n.withKeys(n.withModifiers((...h)=>e.handleEsc&&e.handleEsc(...h),["stop","prevent"]),["esc"])),t[8]||(t[8]=n.withKeys(n.withModifiers((...h)=>e.handleDel&&e.handleDel(...h),["stop"]),["delete"]))],onClick:t[9]||(t[9]=n.withModifiers((...h)=>e.toggleMenu&&e.toggleMenu(...h),["stop"]))},null,46,vX),e.filterable?(n.openBlock(),n.createElementBlock("span",{key:0,ref:"calculatorRef","aria-hidden":"true",class:n.normalizeClass(e.nsSelect.e("input-calculator")),textContent:n.toDisplayString(e.states.inputValue)},null,10,yX)):n.createCommentVNode("v-if",!0)],2),e.shouldShowPlaceholder?(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass([e.nsSelect.e("selected-item"),e.nsSelect.e("placeholder"),e.nsSelect.is("transparent",!e.hasModelValue||e.expanded&&!e.states.inputValue)])},[e.hasModelValue?n.renderSlot(e.$slots,"label",{key:0,index:(p=(f=e.allOptionsValueMap.get(e.modelValue))==null?void 0:f.index)!=null?p:-1,label:e.currentPlaceholder,value:e.modelValue},()=>[n.createElementVNode("span",null,n.toDisplayString(e.currentPlaceholder),1)]):(n.openBlock(),n.createElementBlock("span",MX,n.toDisplayString(e.currentPlaceholder),1))],2)):n.createCommentVNode("v-if",!0)],2),n.createElementVNode("div",{ref:"suffixRef",class:n.normalizeClass(e.nsSelect.e("suffix"))},[e.iconComponent?n.withDirectives((n.openBlock(),n.createBlock(c,{key:0,class:n.normalizeClass([e.nsSelect.e("caret"),e.nsInput.e("icon"),e.iconReverse])},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.iconComponent)))]),_:1},8,["class"])),[[n.vShow,!e.showClearBtn]]):n.createCommentVNode("v-if",!0),e.showClearBtn&&e.clearIcon?(n.openBlock(),n.createBlock(c,{key:1,class:n.normalizeClass([e.nsSelect.e("caret"),e.nsInput.e("icon"),e.nsSelect.e("clear")]),onClick:n.withModifiers(e.handleClear,["prevent","stop"])},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.clearIcon)))]),_:1},8,["class","onClick"])):n.createCommentVNode("v-if",!0),e.validateState&&e.validateIcon&&e.needStatusIcon?(n.openBlock(),n.createBlock(c,{key:2,class:n.normalizeClass([e.nsInput.e("icon"),e.nsInput.e("validateIcon"),e.nsInput.is("loading",e.validateState==="validating")])},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.validateIcon)))]),_:1},8,["class"])):n.createCommentVNode("v-if",!0)],2)],2)]}),content:n.withCtx(()=>[n.createVNode(u,{id:e.contentId,ref:"menuRef",data:e.filteredOptions,width:e.popperSize-e.BORDER_HORIZONTAL_WIDTH,"hovering-index":e.states.hoveringIndex,"scrollbar-always-on":e.scrollbarAlwaysOn,"aria-label":e.ariaLabel},n.createSlots({default:n.withCtx(f=>[n.renderSlot(e.$slots,"default",n.normalizeProps(n.guardReactiveProps(f)))]),_:2},[e.$slots.header?{name:"header",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","header")),onClick:t[11]||(t[11]=n.withModifiers(()=>{},["stop"]))},[n.renderSlot(e.$slots,"header")],2)]),key:"0"}:void 0,e.$slots.loading&&e.loading?{name:"loading",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","loading"))},[n.renderSlot(e.$slots,"loading")],2)]),key:"1"}:e.loading||e.filteredOptions.length===0?{name:"empty",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","empty"))},[n.renderSlot(e.$slots,"empty",{},()=>[n.createElementVNode("span",null,n.toDisplayString(e.emptyText),1)])],2)]),key:"2"}:void 0,e.$slots.footer?{name:"footer",fn:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass(e.nsSelect.be("dropdown","footer")),onClick:t[12]||(t[12]=n.withModifiers(()=>{},["stop"]))},[n.renderSlot(e.$slots,"footer")],2)]),key:"3"}:void 0]),1032,["id","data","width","hovering-index","scrollbar-always-on","aria-label"])]),_:3},8,["visible","teleported","popper-class","popper-style","popper-options","fallback-placements","effect","placement","transition","persistent","append-to","show-arrow","offset","onBeforeShow"])],34)),[[d,e.handleClickOutside,e.popperRef]])}var wX=sn(gX,[["render",bX]]);const NX=it(wX),Tb=Symbol("sliderContextKey"),kX=ge({modelValue:{type:K([Number,Array]),default:0},id:{type:String,default:void 0},min:{type:Number,default:0},max:{type:Number,default:100},step:{type:Number,default:1},showInput:Boolean,showInputControls:{type:Boolean,default:!0},size:Qn,inputSize:Qn,showStops:Boolean,showTooltip:{type:Boolean,default:!0},formatTooltip:{type:K(Function),default:void 0},disabled:{type:Boolean,default:void 0},range:Boolean,vertical:Boolean,height:String,rangeStartLabel:{type:String,default:void 0},rangeEndLabel:{type:String,default:void 0},formatValueText:{type:K(Function),default:void 0},tooltipClass:{type:String,default:void 0},placement:{type:String,values:aa,default:"top"},marks:{type:K(Object)},validateEvent:{type:Boolean,default:!0},persistent:{type:Boolean,default:!0},...Ln(["ariaLabel"])}),Bf=e=>Ve(e)||De(e)&&e.every(Ve),xX={[$e]:Bf,[Yn]:Bf,[st]:Bf},CX=ge({modelValue:{type:Number,default:0},vertical:Boolean,tooltipClass:String,placement:{type:String,values:aa,default:"top"}}),EX={[$e]:e=>Ve(e)},TX=(e,t,r)=>{const o=n.ref(),a=n.ref(!1),i=n.computed(()=>t.value instanceof Function),l=n.computed(()=>i.value&&t.value(e.modelValue)||e.modelValue),s=uu(()=>{r.value&&(a.value=!0)},50),c=uu(()=>{r.value&&(a.value=!1)},50);return{tooltip:o,tooltipVisible:a,formatValue:l,displayTooltip:s,hideTooltip:c}},DX=(e,t,r)=>{const{disabled:o,min:a,max:i,step:l,showTooltip:s,persistent:c,precision:u,sliderSize:d,formatTooltip:f,emitChange:p,resetSize:h,updateDragging:m}=n.inject(Tb),{tooltip:g,tooltipVisible:v,formatValue:y,displayTooltip:N,hideTooltip:b}=TX(e,f,s),M=n.ref(),k=n.computed(()=>`${(e.modelValue-a.value)/(i.value-a.value)*100}%`),w=n.computed(()=>e.vertical?{bottom:k.value}:{left:k.value}),C=()=>{t.hovering=!0,N()},E=()=>{t.hovering=!1,t.dragging||b()},A=T=>{o.value||(T.preventDefault(),S(T),window.addEventListener("mousemove",L),window.addEventListener("touchmove",L),window.addEventListener("mouseup",B),window.addEventListener("touchend",B),window.addEventListener("contextmenu",B),M.value.focus())},O=T=>{o.value||(t.newPosition=Number.parseFloat(k.value)+T/(i.value-a.value)*100,F(t.newPosition),p())},_=()=>{O(-l.value)},j=()=>{O(l.value)},R=()=>{O(-l.value*4)},P=()=>{O(l.value*4)},$=()=>{o.value||(F(0),p())},V=()=>{o.value||(F(100),p())},D=T=>{const z=Lt(T);let I=!0;switch(z){case ve.left:case ve.down:_();break;case ve.right:case ve.up:j();break;case ve.home:$();break;case ve.end:V();break;case ve.pageDown:R();break;case ve.pageUp:P();break;default:I=!1;break}I&&T.preventDefault()},x=T=>{let z,I;return T.type.startsWith("touch")?(I=T.touches[0].clientY,z=T.touches[0].clientX):(I=T.clientY,z=T.clientX),{clientX:z,clientY:I}},S=T=>{t.dragging=!0,t.isClick=!0;const{clientX:z,clientY:I}=x(T);e.vertical?t.startY=I:t.startX=z,t.startPosition=Number.parseFloat(k.value),t.newPosition=t.startPosition},L=T=>{if(t.dragging){t.isClick=!1,N(),h();let z;const{clientX:I,clientY:Z}=x(T);e.vertical?(t.currentY=Z,z=(t.startY-t.currentY)/d.value*100):(t.currentX=I,z=(t.currentX-t.startX)/d.value*100),t.newPosition=t.startPosition+z,F(t.newPosition)}},B=()=>{t.dragging&&(setTimeout(()=>{t.dragging=!1,t.hovering||b(),t.isClick||F(t.newPosition),p()},0),window.removeEventListener("mousemove",L),window.removeEventListener("touchmove",L),window.removeEventListener("mouseup",B),window.removeEventListener("touchend",B),window.removeEventListener("contextmenu",B))},F=async T=>{if(T===null||Number.isNaN(+T))return;T=wa(T,0,100);const z=Math.floor((i.value-a.value)/l.value),I=z*l.value/(i.value-a.value)*100,Z=I+(100-I)/2;let q;if(T<I){const te=I/z,J=Math.round(T/te);q=a.value+J*l.value}else T<Z?q=a.value+z*l.value:q=i.value;q=Number.parseFloat(q.toFixed(u.value)),q!==e.modelValue&&r($e,q),!t.dragging&&e.modelValue!==t.oldValue&&(t.oldValue=e.modelValue),await n.nextTick(),t.dragging&&N(),g.value.updatePopper()};return n.watch(()=>t.dragging,T=>{m(T)}),ht(M,"touchstart",A,{passive:!1}),{disabled:o,button:M,tooltip:g,tooltipVisible:v,showTooltip:s,persistent:c,wrapperStyle:w,formatValue:y,handleMouseEnter:C,handleMouseLeave:E,onButtonDown:A,onKeyDown:D,setPosition:F}},SX=["tabindex"];var Dg=n.defineComponent({name:"ElSliderButton",__name:"button",props:CX,emits:EX,setup(e,{expose:t,emit:r}){const o=e,a=r,i=he("slider"),l=n.reactive({hovering:!1,dragging:!1,isClick:!1,startX:0,currentX:0,startY:0,currentY:0,startPosition:0,newPosition:0,oldValue:o.modelValue}),s=n.computed(()=>f.value?p.value:!1),{disabled:c,button:u,tooltip:d,showTooltip:f,persistent:p,tooltipVisible:h,wrapperStyle:m,formatValue:g,handleMouseEnter:v,handleMouseLeave:y,onButtonDown:N,onKeyDown:b,setPosition:M}=DX(o,l,a),{hovering:k,dragging:w}=n.toRefs(l);return t({onButtonDown:N,onKeyDown:b,setPosition:M,hovering:k,dragging:w}),(C,E)=>(n.openBlock(),n.createElementBlock("div",{ref_key:"button",ref:u,class:n.normalizeClass([n.unref(i).e("button-wrapper"),{hover:n.unref(k),dragging:n.unref(w)}]),style:n.normalizeStyle(n.unref(m)),tabindex:n.unref(c)?void 0:0,onMouseenter:E[0]||(E[0]=(...A)=>n.unref(v)&&n.unref(v)(...A)),onMouseleave:E[1]||(E[1]=(...A)=>n.unref(y)&&n.unref(y)(...A)),onMousedown:E[2]||(E[2]=(...A)=>n.unref(N)&&n.unref(N)(...A)),onFocus:E[3]||(E[3]=(...A)=>n.unref(v)&&n.unref(v)(...A)),onBlur:E[4]||(E[4]=(...A)=>n.unref(y)&&n.unref(y)(...A)),onKeydown:E[5]||(E[5]=(...A)=>n.unref(b)&&n.unref(b)(...A))},[n.createVNode(n.unref(Ka),{ref_key:"tooltip",ref:d,visible:n.unref(h),placement:C.placement,"fallback-placements":["top","bottom","right","left"],"stop-popper-mouse-event":!1,"popper-class":C.tooltipClass,disabled:!n.unref(f),persistent:s.value},{content:n.withCtx(()=>[n.createElementVNode("span",null,n.toDisplayString(n.unref(g)),1)]),default:n.withCtx(()=>[n.createElementVNode("div",{class:n.normalizeClass([n.unref(i).e("button"),{hover:n.unref(k),dragging:n.unref(w)}])},null,2)]),_:1},8,["visible","placement","popper-class","disabled","persistent"])],46,SX))}});const _X=ge({mark:{type:K([String,Object]),default:void 0}});var IX=n.defineComponent({name:"ElSliderMarker",props:_X,setup(e){const t=he("slider"),r=n.computed(()=>nt(e.mark)?e.mark:e.mark.label),o=n.computed(()=>nt(e.mark)?void 0:e.mark.style);return()=>n.h("div",{class:t.e("marks-text"),style:o.value},r.value)}});const AX=(e,t,r)=>{const{formItem:o}=Kn(),a=n.shallowRef(),i=n.ref(),l=n.ref(),s={firstButton:i,secondButton:l},c=Bt(),u=n.computed(()=>Math.min(t.firstValue,t.secondValue)),d=n.computed(()=>Math.max(t.firstValue,t.secondValue)),f=n.computed(()=>e.range?`${100*(d.value-u.value)/(e.max-e.min)}%`:`${100*(t.firstValue-e.min)/(e.max-e.min)}%`),p=n.computed(()=>e.range?`${100*(u.value-e.min)/(e.max-e.min)}%`:"0%"),h=n.computed(()=>e.vertical?{height:e.height}:{}),m=n.computed(()=>e.vertical?{height:f.value,bottom:p.value}:{width:f.value,left:p.value}),g=()=>{if(a.value){const _=a.value.getBoundingClientRect();t.sliderSize=_[e.vertical?"height":"width"]}},v=_=>{const j=e.min+_*(e.max-e.min)/100;if(!e.range)return i;let R;return Math.abs(u.value-j)<Math.abs(d.value-j)?R=t.firstValue<t.secondValue?"firstButton":"secondButton":R=t.firstValue>t.secondValue?"firstButton":"secondButton",s[R]},y=_=>{const j=v(_);return j.value.setPosition(_),j},N=_=>{t.firstValue=_??e.min,M(e.range?[u.value,d.value]:_??e.min)},b=_=>{t.secondValue=_,e.range&&M([u.value,d.value])},M=_=>{r($e,_),r(Yn,_)},k=async()=>{await n.nextTick(),r(st,e.range?[u.value,d.value]:e.modelValue)},w=_=>{var j,R,P,$,V,D;if(c.value||t.dragging)return;g();let x=0;if(e.vertical){const S=(P=(R=(j=_.touches)==null?void 0:j.item(0))==null?void 0:R.clientY)!=null?P:_.clientY;x=(a.value.getBoundingClientRect().bottom-S)/t.sliderSize*100}else{const S=(D=(V=($=_.touches)==null?void 0:$.item(0))==null?void 0:V.clientX)!=null?D:_.clientX,L=a.value.getBoundingClientRect().left;x=(S-L)/t.sliderSize*100}if(!(x<0||x>100))return y(x)};return{elFormItem:o,slider:a,firstButton:i,secondButton:l,sliderDisabled:c,minValue:u,maxValue:d,runwayStyle:h,barStyle:m,resetSize:g,setPosition:y,emitChange:k,onSliderWrapperPrevent:_=>{var j,R;((j=s.firstButton.value)!=null&&j.dragging||(R=s.secondButton.value)!=null&&R.dragging)&&_.preventDefault()},onSliderClick:_=>{w(_)&&k()},onSliderDown:async _=>{const j=w(_);j&&(await n.nextTick(),j.value.onButtonDown(_))},onSliderMarkerDown:_=>{if(c.value||t.dragging)return;y(_)&&k()},setFirstValue:N,setSecondValue:b}},OX=(e,t,r,o)=>({stops:n.computed(()=>{if(!e.showStops||e.min>e.max)return[];if(e.step===0)return He("ElSlider","step should not be 0."),[];const l=Math.ceil((e.max-e.min)/e.step),s=100*e.step/(e.max-e.min),c=Array.from({length:l-1}).map((u,d)=>(d+1)*s);return e.range?c.filter(u=>u<100*(r.value-e.min)/(e.max-e.min)||u>100*(o.value-e.min)/(e.max-e.min)):c.filter(u=>u>100*(t.firstValue-e.min)/(e.max-e.min))}),getStopStyle:l=>e.vertical?{bottom:`${l}%`}:{left:`${l}%`}}),zX=e=>n.computed(()=>e.marks?Object.keys(e.marks).map(Number.parseFloat).sort((r,o)=>r-o).filter(r=>r<=e.max&&r>=e.min).map(r=>({point:r,position:(r-e.min)*100/(e.max-e.min),mark:e.marks[r]})):[]),jX=(e,t,r,o,a,i)=>{const l=u=>{a($e,u),a(Yn,u)},s=()=>e.range?![r.value,o.value].every((u,d)=>u===t.oldValue[d]):e.modelValue!==t.oldValue,c=()=>{var u,d;e.min>e.max&&gn("Slider","min should not be greater than max.");const f=e.modelValue;e.range&&De(f)?f[1]<e.min?l([e.min,e.min]):f[0]>e.max?l([e.max,e.max]):f[0]<e.min?l([e.min,f[1]]):f[1]>e.max?l([f[0],e.max]):(t.firstValue=f[0],t.secondValue=f[1],s()&&(e.validateEvent&&((u=i==null?void 0:i.validate)==null||u.call(i,"change").catch(p=>He(p))),t.oldValue=f.slice())):!e.range&&Ve(f)&&!Number.isNaN(f)&&(f<e.min?l(e.min):f>e.max?l(e.max):(t.firstValue=f,s()&&(e.validateEvent&&((d=i==null?void 0:i.validate)==null||d.call(i,"change").catch(p=>He(p))),t.oldValue=f)))};c(),n.watch(()=>t.dragging,u=>{u||c()}),n.watch(()=>e.modelValue,(u,d)=>{t.dragging||De(u)&&De(d)&&u.every((f,p)=>f===d[p])&&t.firstValue===u[0]&&t.secondValue===u[1]||c()},{deep:!0}),n.watch(()=>[e.min,e.max],()=>{c()})},LX=(e,t,r)=>{const o=n.ref();return n.onMounted(async()=>{e.range?(De(e.modelValue)?(t.firstValue=Math.max(e.min,e.modelValue[0]),t.secondValue=Math.min(e.max,e.modelValue[1])):(t.firstValue=e.min,t.secondValue=e.max),t.oldValue=[t.firstValue,t.secondValue]):(!Ve(e.modelValue)||Number.isNaN(e.modelValue)?t.firstValue=e.min:t.firstValue=Math.min(e.max,Math.max(e.min,e.modelValue)),t.oldValue=t.firstValue),ht(window,"resize",r),await n.nextTick(),r()}),{sliderWrapper:o}},BX=["id","role","aria-label","aria-labelledby"],VX={key:1};var $X=n.defineComponent({name:"ElSlider",__name:"slider",props:kX,emits:xX,setup(e,{expose:t,emit:r}){const o=e,a=r,i=he("slider"),{t:l}=Nt(),s=n.reactive({firstValue:0,secondValue:0,oldValue:0,dragging:!1,sliderSize:1}),{elFormItem:c,slider:u,firstButton:d,secondButton:f,sliderDisabled:p,minValue:h,maxValue:m,runwayStyle:g,barStyle:v,resetSize:y,emitChange:N,onSliderWrapperPrevent:b,onSliderClick:M,onSliderDown:k,onSliderMarkerDown:w,setFirstValue:C,setSecondValue:E}=AX(o,s,a),{stops:A,getStopStyle:O}=OX(o,s,h,m),{inputId:_,isLabeledByFormItem:j}=io(o,{formItemContext:c}),R=mn(),P=n.computed(()=>o.inputSize||R.value),$=n.computed(()=>o.ariaLabel||l("el.slider.defaultLabel",{min:o.min,max:o.max})),V=n.computed(()=>o.range?o.rangeStartLabel||l("el.slider.defaultRangeStartLabel"):$.value),D=n.computed(()=>o.formatValueText?o.formatValueText(z.value):`${z.value}`),x=n.computed(()=>o.rangeEndLabel||l("el.slider.defaultRangeEndLabel")),S=n.computed(()=>o.formatValueText?o.formatValueText(I.value):`${I.value}`),L=n.computed(()=>[i.b(),i.m(R.value),i.is("vertical",o.vertical),{[i.m("with-input")]:o.showInput}]),B=zX(o);jX(o,s,h,m,a,c);const F=n.computed(()=>{const te=[o.min,o.max,o.step].map(J=>{const W=`${J}`.split(".")[1];return W?W.length:0});return Math.max.apply(null,te)}),{sliderWrapper:T}=LX(o,s,y),{firstValue:z,secondValue:I,sliderSize:Z}=n.toRefs(s),q=te=>{s.dragging=te};return ht(T,"touchstart",b,{passive:!1}),ht(T,"touchmove",b,{passive:!1}),n.provide(Tb,{...n.toRefs(o),sliderSize:Z,disabled:p,precision:F,emitChange:N,resetSize:y,updateDragging:q}),t({onSliderClick:M}),(te,J)=>{var W,ae;return n.openBlock(),n.createElementBlock("div",{id:te.range?n.unref(_):void 0,ref_key:"sliderWrapper",ref:T,class:n.normalizeClass(L.value),role:te.range?"group":void 0,"aria-label":te.range&&!n.unref(j)?$.value:void 0,"aria-labelledby":te.range&&n.unref(j)?(W=n.unref(c))==null?void 0:W.labelId:void 0},[n.createElementVNode("div",{ref_key:"slider",ref:u,class:n.normalizeClass([n.unref(i).e("runway"),{"show-input":te.showInput&&!te.range},n.unref(i).is("disabled",n.unref(p))]),style:n.normalizeStyle(n.unref(g)),onMousedown:J[0]||(J[0]=(...ce)=>n.unref(k)&&n.unref(k)(...ce)),onTouchstartPassive:J[1]||(J[1]=(...ce)=>n.unref(k)&&n.unref(k)(...ce))},[n.createElementVNode("div",{class:n.normalizeClass(n.unref(i).e("bar")),style:n.normalizeStyle(n.unref(v))},null,6),n.createVNode(Dg,{id:te.range?void 0:n.unref(_),ref_key:"firstButton",ref:d,"model-value":n.unref(z),vertical:te.vertical,"tooltip-class":te.tooltipClass,placement:te.placement,role:"slider","aria-label":te.range||!n.unref(j)?V.value:void 0,"aria-labelledby":!te.range&&n.unref(j)?(ae=n.unref(c))==null?void 0:ae.labelId:void 0,"aria-valuemin":te.min,"aria-valuemax":te.range?n.unref(I):te.max,"aria-valuenow":n.unref(z),"aria-valuetext":D.value,"aria-orientation":te.vertical?"vertical":"horizontal","aria-disabled":n.unref(p),"onUpdate:modelValue":n.unref(C)},null,8,["id","model-value","vertical","tooltip-class","placement","aria-label","aria-labelledby","aria-valuemin","aria-valuemax","aria-valuenow","aria-valuetext","aria-orientation","aria-disabled","onUpdate:modelValue"]),te.range?(n.openBlock(),n.createBlock(Dg,{key:0,ref_key:"secondButton",ref:f,"model-value":n.unref(I),vertical:te.vertical,"tooltip-class":te.tooltipClass,placement:te.placement,role:"slider","aria-label":x.value,"aria-valuemin":n.unref(z),"aria-valuemax":te.max,"aria-valuenow":n.unref(I),"aria-valuetext":S.value,"aria-orientation":te.vertical?"vertical":"horizontal","aria-disabled":n.unref(p),"onUpdate:modelValue":n.unref(E)},null,8,["model-value","vertical","tooltip-class","placement","aria-label","aria-valuemin","aria-valuemax","aria-valuenow","aria-valuetext","aria-orientation","aria-disabled","onUpdate:modelValue"])):n.createCommentVNode("v-if",!0),te.showStops?(n.openBlock(),n.createElementBlock("div",VX,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(A),(ce,ye)=>(n.openBlock(),n.createElementBlock("div",{key:ye,class:n.normalizeClass(n.unref(i).e("stop")),style:n.normalizeStyle(n.unref(O)(ce))},null,6))),128))])):n.createCommentVNode("v-if",!0),n.unref(B).length>0?(n.openBlock(),n.createElementBlock(n.Fragment,{key:2},[n.createElementVNode("div",null,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(B),(ce,ye)=>(n.openBlock(),n.createElementBlock("div",{key:ye,style:n.normalizeStyle(n.unref(O)(ce.position)),class:n.normalizeClass([n.unref(i).e("stop"),n.unref(i).e("marks-stop")])},null,6))),128))]),n.createElementVNode("div",{class:n.normalizeClass(n.unref(i).e("marks"))},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(n.unref(B),(ce,ye)=>(n.openBlock(),n.createBlock(n.unref(IX),{key:ye,mark:ce.mark,style:n.normalizeStyle(n.unref(O)(ce.position)),onMousedown:n.withModifiers(Ae=>n.unref(w)(ce.position),["stop"])},null,8,["mark","style","onMousedown"]))),128))],2)],64)):n.createCommentVNode("v-if",!0)],38),te.showInput&&!te.range?(n.openBlock(),n.createBlock(n.unref(mZ),{key:0,ref:"input","model-value":n.unref(z),class:n.normalizeClass(n.unref(i).e("input")),step:te.step,disabled:n.unref(p),controls:te.showInputControls,min:te.min,max:te.max,precision:F.value,size:P.value,"onUpdate:modelValue":n.unref(C),onChange:n.unref(N)},null,8,["model-value","class","step","disabled","controls","min","max","precision","size","onUpdate:modelValue","onChange"])):n.createCommentVNode("v-if",!0)],10,BX)}}});const PX=it($X),RX=e=>["",...Fs].includes(e),FX=ge({modelValue:{type:[Boolean,String,Number],default:!1},disabled:{type:Boolean,default:void 0},loading:Boolean,size:{type:String,validator:RX},width:{type:[String,Number],default:""},inlinePrompt:Boolean,inactiveActionIcon:{type:Qt},activeActionIcon:{type:Qt},activeIcon:{type:Qt},inactiveIcon:{type:Qt},activeText:{type:String,default:""},inactiveText:{type:String,default:""},activeValue:{type:[Boolean,String,Number],default:!0},inactiveValue:{type:[Boolean,String,Number],default:!1},name:{type:String,default:""},validateEvent:{type:Boolean,default:!0},beforeChange:{type:K(Function)},id:String,tabindex:{type:[String,Number]},...Ln(["ariaLabel"])}),UX={[$e]:e=>an(e)||nt(e)||Ve(e),[st]:e=>an(e)||nt(e)||Ve(e),[Yn]:e=>an(e)||nt(e)||Ve(e)},HX=["id","aria-checked","aria-disabled","aria-label","name","true-value","false-value","disabled","tabindex"],YX=["aria-hidden"],QX={key:1},WX={key:1},qX=["aria-hidden"],Vf="ElSwitch";var GX=n.defineComponent({name:Vf,__name:"switch",props:FX,emits:UX,setup(e,{expose:t,emit:r}){const o=e,a=r,{formItem:i}=Kn(),l=mn(),s=he("switch"),{inputId:c}=io(o,{formItemContext:i}),u=Bt(n.computed(()=>{if(o.loading)return!0})),d=n.ref(o.modelValue!==!1),f=n.shallowRef(),p=n.computed(()=>[s.b(),s.m(l.value),s.is("disabled",u.value),s.is("checked",y.value)]),h=n.computed(()=>[s.e("label"),s.em("label","left"),s.is("active",!y.value)]),m=n.computed(()=>[s.e("label"),s.em("label","right"),s.is("active",y.value)]),g=n.computed(()=>({width:Ir(o.width)}));n.watch(()=>o.modelValue,()=>{d.value=!0});const v=n.computed(()=>d.value?o.modelValue:!1),y=n.computed(()=>v.value===o.activeValue);[o.activeValue,o.inactiveValue].includes(v.value)||(a($e,o.inactiveValue),a(st,o.inactiveValue),a(Yn,o.inactiveValue)),n.watch(y,k=>{var w;f.value.checked=k,o.validateEvent&&((w=i==null?void 0:i.validate)==null||w.call(i,"change").catch(C=>He(C)))});const N=()=>{const k=y.value?o.inactiveValue:o.activeValue;a($e,k),a(st,k),a(Yn,k),n.nextTick(()=>{f.value.checked=y.value})},b=()=>{if(u.value)return;const{beforeChange:k}=o;if(!k){N();return}const w=k();[du(w),an(w)].includes(!0)||gn(Vf,"beforeChange must return type `Promise<boolean>` or `boolean`"),du(w)?w.then(E=>{E&&N()}).catch(E=>{He(Vf,`some error occurred: ${E}`)}):w&&N()},M=()=>{var k,w;(w=(k=f.value)==null?void 0:k.focus)==null||w.call(k)};return n.onMounted(()=>{f.value.checked=y.value}),t({focus:M,checked:y}),(k,w)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(p.value),onClick:n.withModifiers(b,["prevent"])},[n.createElementVNode("input",{id:n.unref(c),ref_key:"input",ref:f,class:n.normalizeClass(n.unref(s).e("input")),type:"checkbox",role:"switch","aria-checked":y.value,"aria-disabled":n.unref(u),"aria-label":e.ariaLabel,name:e.name,"true-value":e.activeValue,"false-value":e.inactiveValue,disabled:n.unref(u),tabindex:e.tabindex,onChange:N,onKeydown:n.withKeys(b,["enter"])},null,42,HX),!e.inlinePrompt&&(e.inactiveIcon||e.inactiveText||k.$slots.inactive)?(n.openBlock(),n.createElementBlock("span",{key:0,class:n.normalizeClass(h.value)},[n.renderSlot(k.$slots,"inactive",{},()=>[e.inactiveIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.inactiveIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.inactiveIcon&&e.inactiveText?(n.openBlock(),n.createElementBlock("span",{key:1,"aria-hidden":y.value},n.toDisplayString(e.inactiveText),9,YX)):n.createCommentVNode("v-if",!0)])],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("span",{class:n.normalizeClass(n.unref(s).e("core")),style:n.normalizeStyle(g.value)},[e.inlinePrompt?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(n.unref(s).e("inner"))},[y.value?(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass(n.unref(s).e("inner-wrapper"))},[n.renderSlot(k.$slots,"active",{},()=>[e.activeIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.activeIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.activeIcon&&e.activeText?(n.openBlock(),n.createElementBlock("span",WX,n.toDisplayString(e.activeText),1)):n.createCommentVNode("v-if",!0)])],2)):(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass(n.unref(s).e("inner-wrapper"))},[n.renderSlot(k.$slots,"inactive",{},()=>[e.inactiveIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.inactiveIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.inactiveIcon&&e.inactiveText?(n.openBlock(),n.createElementBlock("span",QX,n.toDisplayString(e.inactiveText),1)):n.createCommentVNode("v-if",!0)])],2))],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("div",{class:n.normalizeClass(n.unref(s).e("action"))},[e.loading?(n.openBlock(),n.createBlock(n.unref(ke),{key:0,class:n.normalizeClass(n.unref(s).is("loading"))},{default:n.withCtx(()=>[n.createVNode(n.unref(Ud))]),_:1},8,["class"])):y.value?n.renderSlot(k.$slots,"active-action",{key:1},()=>[e.activeActionIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.activeActionIcon)))]),_:1})):n.createCommentVNode("v-if",!0)]):y.value?n.createCommentVNode("v-if",!0):n.renderSlot(k.$slots,"inactive-action",{key:2},()=>[e.inactiveActionIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.inactiveActionIcon)))]),_:1})):n.createCommentVNode("v-if",!0)])],2)],6),!e.inlinePrompt&&(e.activeIcon||e.activeText||k.$slots.active)?(n.openBlock(),n.createElementBlock("span",{key:1,class:n.normalizeClass(m.value)},[n.renderSlot(k.$slots,"active",{},()=>[e.activeIcon?(n.openBlock(),n.createBlock(n.unref(ke),{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.activeIcon)))]),_:1})):n.createCommentVNode("v-if",!0),!e.activeIcon&&e.activeText?(n.openBlock(),n.createElementBlock("span",{key:1,"aria-hidden":!y.value},n.toDisplayString(e.activeText),9,qX)):n.createCommentVNode("v-if",!0)])],2)):n.createCommentVNode("v-if",!0)],2))}});const KX=it(GX),Kd=Symbol("tabsRootContextKey"),JX=ge({tabs:{type:K(Array),default:()=>Wn([])},tabRefs:{type:K(Object),default:()=>Wn({})}}),Sg="ElTabBar";var ZX=n.defineComponent({name:Sg,__name:"tab-bar",props:JX,setup(e,{expose:t}){const r=e,o=n.inject(Kd);o||gn(Sg,"<el-tabs><el-tab-bar /></el-tabs>");const a=he("tabs"),i=n.ref(),l=n.ref(),s=n.computed(()=>{var h;return Rt(o.props.defaultValue)||!!((h=l.value)!=null&&h.transform)}),c=()=>{let h=0,m=0;const g=["top","bottom"].includes(o.props.tabPosition)?"width":"height",v=g==="width"?"x":"y",y=v==="x"?"left":"top";return r.tabs.every(N=>{if(Rt(N.paneName))return!1;const b=r.tabRefs[N.paneName];if(!b)return!1;if(!N.active)return!0;h=b[`offset${Vo(y)}`],m=b[`client${Vo(g)}`];const M=window.getComputedStyle(b);return g==="width"&&(m-=Number.parseFloat(M.paddingLeft)+Number.parseFloat(M.paddingRight),h+=Number.parseFloat(M.paddingLeft)),!1}),{[g]:`${m}px`,transform:`translate${Vo(v)}(${h}px)`}},u=()=>l.value=c(),d=[],f=()=>{d.forEach(h=>h.stop()),d.length=0,Object.values(r.tabRefs).forEach(h=>{d.push(zt(h,u))})};n.watch(()=>r.tabs,async()=>{await n.nextTick(),u(),f()},{immediate:!0});const p=zt(i,()=>u());return n.onBeforeUnmount(()=>{d.forEach(h=>h.stop()),d.length=0,p.stop()}),t({ref:i,update:u}),(h,m)=>s.value?(n.openBlock(),n.createElementBlock("div",{key:0,ref_key:"barRef",ref:i,class:n.normalizeClass([n.unref(a).e("active-bar"),n.unref(a).is(n.unref(o).props.tabPosition)]),style:n.normalizeStyle(l.value)},null,6)):n.createCommentVNode("v-if",!0)}});const XX=ge({panes:{type:K(Array),default:()=>Wn([])},currentName:{type:[String,Number],default:""},editable:Boolean,type:{type:String,values:["card","border-card",""],default:""},stretch:Boolean,tabindex:{type:[String,Number],default:void 0}}),eee={tabClick:(e,t,r)=>r instanceof Event,tabRemove:(e,t)=>t instanceof Event},_g="ElTabNav",tee=n.defineComponent({name:_g,props:XX,emits:eee,setup(e,{expose:t,emit:r}){const o=n.inject(Kd);o||gn(_g,"<el-tabs><tab-nav /></el-tabs>");const a=he("tabs"),i=mz(),l=vz(),s=n.ref(),c=n.ref(),u=n.ref(),d=n.ref({}),f=n.ref(),p=n.ref(!1),h=n.ref(0),m=n.ref(!1),g=n.ref(!0),v=n.shallowRef(),y=n.computed(()=>["top","bottom"].includes(o.props.tabPosition)),N=n.computed(()=>y.value?"width":"height"),b=n.computed(()=>({transform:`translate${N.value==="width"?"X":"Y"}(-${h.value}px)`})),{width:M,height:k}=E1(s),{width:w,height:C}=E1(c,{width:0,height:0},{box:"border-box"}),E=n.computed(()=>y.value?M.value:k.value),A=n.computed(()=>y.value?w.value:C.value),{onWheel:O}=bb({atStartEdge:n.computed(()=>h.value<=0),atEndEdge:n.computed(()=>A.value-h.value<=E.value),layout:n.computed(()=>y.value?"horizontal":"vertical")},L=>{h.value=wa(h.value+L,0,A.value-E.value)}),_=()=>{if(!s.value)return;const L=s.value[`offset${Vo(N.value)}`],B=h.value;if(!B)return;const F=B>L?B-L:0;h.value=F},j=()=>{if(!s.value||!c.value)return;const L=c.value[`offset${Vo(N.value)}`],B=s.value[`offset${Vo(N.value)}`],F=h.value;if(L-F<=B)return;const T=L-F>B*2?F+B:L-B;h.value=T},R=async()=>{const L=c.value;if(!p.value||!u.value||!s.value||!L)return;await n.nextTick();const B=d.value[e.currentName];if(!B)return;const F=s.value,T=B.getBoundingClientRect(),z=F.getBoundingClientRect(),I=y.value?L.offsetWidth-z.width:L.offsetHeight-z.height,Z=h.value;let q=Z;y.value?(T.left<z.left&&(q=Z-(z.left-T.left)),T.right>z.right&&(q=Z+T.right-z.right)):(T.top<z.top&&(q=Z-(z.top-T.top)),T.bottom>z.bottom&&(q=Z+(T.bottom-z.bottom))),q=Math.max(q,0),h.value=Math.min(q,I)},P=()=>{var L;if(!c.value||!s.value)return;e.stretch&&((L=f.value)==null||L.update());const B=c.value[`offset${Vo(N.value)}`],F=s.value[`offset${Vo(N.value)}`],T=h.value;F<B?(p.value=p.value||{},p.value.prev=T,p.value.next=T+F<B,B-T<F&&(h.value=B-F)):(p.value=!1,T>0&&(h.value=0))},$=L=>{const B=Lt(L);let F=0;switch(B){case ve.left:case ve.up:F=-1;break;case ve.right:case ve.down:F=1;break;default:return}const T=Array.from(L.currentTarget.querySelectorAll("[role=tab]:not(.is-disabled)"));let I=T.indexOf(L.target)+F;I<0?I=T.length-1:I>=T.length&&(I=0),T[I].focus({preventScroll:!0}),T[I].click(),V()},V=()=>{g.value&&(m.value=!0)},D=()=>m.value=!1,x=(L,B)=>{d.value[B]=L},S=async()=>{await n.nextTick();const L=d.value[e.currentName];L==null||L.focus({preventScroll:!0})};return n.watch(i,L=>{L==="hidden"?g.value=!1:L==="visible"&&setTimeout(()=>g.value=!0,50)}),n.watch(l,L=>{L?setTimeout(()=>g.value=!0,50):g.value=!1}),zt(u,()=>{Bm(P)}),n.onMounted(()=>setTimeout(()=>R(),0)),n.onUpdated(()=>P()),t({scrollToActiveTab:R,removeFocus:D,focusActiveTab:S,tabListRef:c,tabBarRef:f,scheduleRender:()=>n.triggerRef(v)}),()=>{const L=p.value?[n.createVNode("span",{class:[a.e("nav-prev"),a.is("disabled",!p.value.prev)],onClick:_},[n.createVNode(ke,null,{default:()=>[n.createVNode(ji,null,null)]})]),n.createVNode("span",{class:[a.e("nav-next"),a.is("disabled",!p.value.next)],onClick:j},[n.createVNode(ke,null,{default:()=>[n.createVNode(Wo,null,null)]})])]:null,B=e.panes.map((F,T)=>{var z,I,Z,q,te;const J=F.uid,W=F.props.disabled,ae=(I=(z=F.props.name)!=null?z:F.index)!=null?I:`${T}`,ce=!W&&(F.isClosable||F.props.closable!==!1&&e.editable);F.index=`${T}`;const ye=ce?n.createVNode(ke,{class:"is-icon-close",onClick:_e=>r("tabRemove",F,_e)},{default:()=>[n.createVNode(bo,null,null)]}):null,Ae=((q=(Z=F.slots).label)==null?void 0:q.call(Z))||F.props.label,Fe=!W&&F.active?(te=e.tabindex)!=null?te:o.props.tabindex:-1;return n.createVNode("div",{ref:_e=>x(_e,ae),class:[a.e("item"),a.is(o.props.tabPosition),a.is("active",F.active),a.is("disabled",W),a.is("closable",ce),a.is("focus",m.value)],id:`tab-${ae}`,key:`tab-${J}`,"aria-controls":`pane-${ae}`,role:"tab","aria-selected":F.active,tabindex:Fe,onFocus:()=>V(),onBlur:()=>D(),onClick:_e=>{D(),r("tabClick",F,ae,_e)},onKeydown:_e=>{const Le=Lt(_e);ce&&(Le===ve.delete||Le===ve.backspace)&&r("tabRemove",F,_e)}},[Ae,ye])});return v.value,n.createVNode("div",{ref:u,class:[a.e("nav-wrap"),a.is("scrollable",!!p.value),a.is(o.props.tabPosition)]},[L,n.createVNode("div",{class:a.e("nav-scroll"),ref:s},[e.panes.length>0?n.createVNode("div",{class:[a.e("nav"),a.is(o.props.tabPosition),a.is("stretch",e.stretch&&["top","bottom"].includes(o.props.tabPosition))],ref:c,style:b.value,role:"tablist",onKeydown:$,onWheel:O},[e.type?null:n.createVNode(ZX,{ref:f,tabs:[...e.panes],tabRefs:d.value},null),B]):null])])}}}),nee=ge({type:{type:String,values:["card","border-card",""],default:""},closable:Boolean,addable:Boolean,modelValue:{type:[String,Number]},defaultValue:{type:[String,Number]},editable:Boolean,tabPosition:{type:String,values:["top","right","bottom","left"],default:"top"},beforeLeave:{type:K(Function),default:()=>!0},stretch:Boolean,tabindex:{type:[String,Number],default:0}}),$f=e=>nt(e)||Ve(e),ree={[$e]:e=>$f(e),tabClick:(e,t)=>t instanceof Event,tabChange:e=>$f(e),edit:(e,t)=>["remove","add"].includes(t),tabRemove:e=>$f(e),tabAdd:()=>!0},oee=n.defineComponent({name:"ElTabs",props:nee,emits:ree,setup(e,{emit:t,slots:r,expose:o}){var a;const i=he("tabs"),l=n.computed(()=>["left","right"].includes(e.tabPosition)),{children:s,addChild:c,removeChild:u,ChildrenSorter:d}=SW(n.getCurrentInstance(),"ElTabPane"),f=n.ref(),p=n.ref((a=Rt(e.modelValue)?e.defaultValue:e.modelValue)!=null?a:"0"),h=async(b,M=!1)=>{var k,w,C,E;if(!(p.value===b||Rt(b)))try{let A;if(e.beforeLeave){const O=e.beforeLeave(b,p.value);A=O instanceof Promise?await O:O}else A=!0;if(A!==!1){const O=(k=s.value.find(_=>_.paneName===p.value))==null?void 0:k.isFocusInsidePane();p.value=b,M&&(t($e,b),t("tabChange",b)),(C=(w=f.value)==null?void 0:w.removeFocus)==null||C.call(w),O&&((E=f.value)==null||E.focusActiveTab())}}catch{}},m=(b,M,k)=>{b.props.disabled||(t("tabClick",b,k),h(M,!0))},g=(b,M)=>{b.props.disabled||Rt(b.props.name)||(M.stopPropagation(),t("edit",b.props.name,"remove"),t("tabRemove",b.props.name))},v=()=>{t("edit",void 0,"add"),t("tabAdd")},y=b=>{const M=Lt(b);[ve.enter,ve.numpadEnter].includes(M)&&v()},N=b=>{const M=b.el.firstChild,k=["bottom","right"].includes(e.tabPosition)?b.children[0].el:b.children[1].el;M!==k&&M.before(k)};return n.watch(()=>e.modelValue,b=>h(b)),n.watch(p,async()=>{var b;await n.nextTick(),(b=f.value)==null||b.scrollToActiveTab()}),n.provide(Kd,{props:e,currentName:p,registerPane:c,unregisterPane:u,nav$:f}),o({currentName:p,get tabNavRef(){return Vd(f.value,["scheduleRender"])}}),()=>{const b=r["add-icon"],M=e.editable||e.addable?n.createVNode("div",{class:[i.e("new-tab"),l.value&&i.e("new-tab-vertical")],tabindex:e.tabindex,onClick:v,onKeydown:y},[b?n.renderSlot(r,"add-icon"):n.createVNode(ke,{class:i.is("icon-plus")},{default:()=>[n.createVNode(Fm,null,null)]})]):null,k=()=>n.createVNode(tee,{ref:f,currentName:p.value,editable:e.editable,type:e.type,panes:s.value,stretch:e.stretch,onTabClick:m,onTabRemove:g},null),w=n.createVNode("div",{class:[i.e("header"),l.value&&i.e("header-vertical"),i.is(e.tabPosition)]},[n.createVNode(d,null,{default:k,$stable:!0}),M]),C=n.createVNode("div",{class:i.e("content")},[n.renderSlot(r,"default")]);return n.createVNode("div",{class:[i.b(),i.m(e.tabPosition),{[i.m("card")]:e.type==="card",[i.m("border-card")]:e.type==="border-card"}],onVnodeMounted:N,onVnodeUpdated:N},[C,w])}}}),aee=ge({label:{type:String,default:""},name:{type:[String,Number]},closable:{type:Boolean,default:void 0},disabled:Boolean,lazy:Boolean}),iee=["id","aria-hidden","aria-labelledby"],Ig="ElTabPane";var Db=n.defineComponent({name:Ig,__name:"tab-pane",props:aee,setup(e){const t=e,r=n.getCurrentInstance(),o=n.useSlots(),a=n.inject(Kd);a||gn(Ig,"usage: <el-tabs><el-tab-pane /></el-tabs/>");const i=he("tab-pane"),l=n.ref(),s=n.ref(),c=n.computed(()=>{var g;return(g=t.closable)!=null?g:a.props.closable}),u=n.computed(()=>{var g;return a.currentName.value===((g=t.name)!=null?g:s.value)}),d=n.ref(u.value),f=n.computed(()=>{var g;return(g=t.name)!=null?g:s.value}),p=n.computed(()=>!t.lazy||d.value||u.value),h=()=>{var g;return(g=l.value)==null?void 0:g.contains(document.activeElement)};n.watch(u,g=>{g&&(d.value=!0)});const m=n.reactive({uid:r.uid,getVnode:()=>r.vnode,slots:o,props:t,paneName:f,active:u,index:s,isClosable:c,isFocusInsidePane:h});return a.registerPane(m),n.onBeforeUnmount(()=>{a.unregisterPane(m)}),n.onBeforeUpdate(()=>{var g;o.label&&((g=a.nav$.value)==null||g.scheduleRender())}),(g,v)=>p.value?n.withDirectives((n.openBlock(),n.createElementBlock("div",{key:0,id:`pane-${f.value}`,ref_key:"paneRef",ref:l,class:n.normalizeClass(n.unref(i).b()),role:"tabpanel","aria-hidden":!u.value,"aria-labelledby":`tab-${f.value}`},[n.renderSlot(g.$slots,"default")],10,iee)),[[n.vShow,u.value]]):n.createCommentVNode("v-if",!0)}});const lee=it(oee,{TabPane:Db}),see=Gn(Db);var cee=Object.defineProperty,uee=(e,t,r)=>t in e?cee(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Mc=(e,t,r)=>uee(e,typeof t!="symbol"?t+"":t,r);const dee="ElUpload";class fee extends Error{constructor(t,r,o,a){super(t),Mc(this,"name","UploadAjaxError"),Mc(this,"status"),Mc(this,"method"),Mc(this,"url"),this.status=r,this.method=o,this.url=a}}function Ag(e,t,r){let o;return r.response?o=`${r.response.error||r.response}`:r.responseText?o=`${r.responseText}`:o=`fail to ${t.method} ${e} ${r.status}`,new fee(o,r.status,t.method,e)}function pee(e){const t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch{return t}}const mee=e=>{typeof XMLHttpRequest>"u"&&gn(dee,"XMLHttpRequest is undefined");const t=new XMLHttpRequest,r=e.action;t.upload&&t.upload.addEventListener("progress",i=>{const l=i;l.percent=i.total>0?i.loaded/i.total*100:0,e.onProgress(l)});const o=new FormData;if(e.data)for(const[i,l]of Object.entries(e.data))De(l)&&l.length?o.append(i,...l):o.append(i,l);o.append(e.filename,e.file,e.file.name),t.addEventListener("error",()=>{e.onError(Ag(r,e,t))}),t.addEventListener("load",()=>{if(t.status<200||t.status>=300)return e.onError(Ag(r,e,t));e.onSuccess(pee(t))}),t.open(e.method,r,!0),e.withCredentials&&"withCredentials"in t&&(t.withCredentials=!0);const a=e.headers||{};if(a instanceof Headers)a.forEach((i,l)=>t.setRequestHeader(l,i));else for(const[i,l]of Object.entries(a))Hn(l)||t.setRequestHeader(i,String(l));return t.send(o),t},Sb=["text","picture","picture-card"];let hee=1;const d0=()=>Date.now()+hee++,_b=ge({action:{type:String,default:"#"},headers:{type:K(Object)},method:{type:String,default:"post"},data:{type:K([Object,Function,Promise]),default:()=>Wn({})},multiple:Boolean,name:{type:String,default:"file"},drag:Boolean,withCredentials:Boolean,showFileList:{type:Boolean,default:!0},accept:{type:String,default:""},fileList:{type:K(Array),default:()=>Wn([])},autoUpload:{type:Boolean,default:!0},listType:{type:String,values:Sb,default:"text"},httpRequest:{type:K(Function),default:mee},disabled:{type:Boolean,default:void 0},limit:Number,directory:Boolean}),gee=ge({..._b,beforeUpload:{type:K(Function),default:dt},beforeRemove:{type:K(Function)},onRemove:{type:K(Function),default:dt},onChange:{type:K(Function),default:dt},onPreview:{type:K(Function),default:dt},onSuccess:{type:K(Function),default:dt},onProgress:{type:K(Function),default:dt},onError:{type:K(Function),default:dt},onExceed:{type:K(Function),default:dt},crossorigin:{type:K(String)}}),Ib=Symbol("uploadContextKey"),vee=ge({files:{type:K(Array),default:()=>Wn([])},disabled:{type:Boolean,default:void 0},handlePreview:{type:K(Function),default:dt},listType:{type:String,values:Sb,default:"text"},crossorigin:{type:K(String)}}),yee={remove:e=>!!e},Mee=["tabindex","aria-disabled","onKeydown"],bee=["src","crossorigin"],wee=["onClick"],Nee=["title"],kee=["onClick"],xee=["onClick"];var Og=n.defineComponent({name:"ElUploadList",__name:"upload-list",props:vee,emits:yee,setup(e,{emit:t}){const r=e,o=t,{t:a}=Nt(),i=he("upload"),l=he("icon"),s=he("list"),c=Bt(),u=n.ref(!1),d=n.computed(()=>[i.b("list"),i.bm("list",r.listType),i.is("disabled",c.value)]),f=p=>{o("remove",p)};return(p,h)=>(n.openBlock(),n.createBlock(n.TransitionGroup,{tag:"ul",class:n.normalizeClass(d.value),name:n.unref(s).b()},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.files,(m,g)=>(n.openBlock(),n.createElementBlock("li",{key:m.uid||m.name,class:n.normalizeClass([n.unref(i).be("list","item"),n.unref(i).is(m.status),{focusing:u.value}]),tabindex:n.unref(c)?void 0:0,"aria-disabled":n.unref(c),role:"button",onKeydown:n.withKeys(v=>!n.unref(c)&&f(m),["delete"]),onFocus:h[0]||(h[0]=v=>u.value=!0),onBlur:h[1]||(h[1]=v=>u.value=!1),onClick:h[2]||(h[2]=v=>u.value=!1)},[n.renderSlot(p.$slots,"default",{file:m,index:g},()=>[e.listType==="picture"||m.status!=="uploading"&&e.listType==="picture-card"?(n.openBlock(),n.createElementBlock("img",{key:0,class:n.normalizeClass(n.unref(i).be("list","item-thumbnail")),src:m.url,crossorigin:e.crossorigin,alt:""},null,10,bee)):n.createCommentVNode("v-if",!0),m.status==="uploading"||e.listType!=="picture-card"?(n.openBlock(),n.createElementBlock("div",{key:1,class:n.normalizeClass(n.unref(i).be("list","item-info"))},[n.createElementVNode("a",{class:n.normalizeClass(n.unref(i).be("list","item-name")),onClick:n.withModifiers(v=>e.handlePreview(m),["prevent"])},[n.createVNode(n.unref(ke),{class:n.normalizeClass(n.unref(l).m("document"))},{default:n.withCtx(()=>[n.createVNode(n.unref(MM))]),_:1},8,["class"]),n.createElementVNode("span",{class:n.normalizeClass(n.unref(i).be("list","item-file-name")),title:m.name},n.toDisplayString(m.name),11,Nee)],10,wee),m.status==="uploading"?(n.openBlock(),n.createBlock(n.unref(db),{key:0,type:e.listType==="picture-card"?"circle":"line","stroke-width":e.listType==="picture-card"?6:2,percentage:Number(m.percentage),style:n.normalizeStyle(e.listType==="picture-card"?"":"margin-top: 0.5rem")},null,8,["type","stroke-width","percentage","style"])):n.createCommentVNode("v-if",!0)],2)):n.createCommentVNode("v-if",!0),n.createElementVNode("label",{class:n.normalizeClass(n.unref(i).be("list","item-status-label"))},[e.listType==="text"?(n.openBlock(),n.createBlock(n.unref(ke),{key:0,class:n.normalizeClass([n.unref(l).m("upload-success"),n.unref(l).m("circle-check")])},{default:n.withCtx(()=>[n.createVNode(n.unref(Fd))]),_:1},8,["class"])):["picture-card","picture"].includes(e.listType)?(n.openBlock(),n.createBlock(n.unref(ke),{key:1,class:n.normalizeClass([n.unref(l).m("upload-success"),n.unref(l).m("check")])},{default:n.withCtx(()=>[n.createVNode(n.unref($m))]),_:1},8,["class"])):n.createCommentVNode("v-if",!0)],2),n.unref(c)?n.createCommentVNode("v-if",!0):(n.openBlock(),n.createBlock(n.unref(ke),{key:2,class:n.normalizeClass(n.unref(l).m("close")),onClick:v=>f(m)},{default:n.withCtx(()=>[n.createVNode(n.unref(bo))]),_:1},8,["class","onClick"])),n.createCommentVNode(" Due to close btn only appears when li gets focused disappears after li gets blurred, thus keyboard navigation can never reach close btn"),n.createCommentVNode(" This is a bug which needs to be fixed "),n.createCommentVNode(" TODO: Fix the incorrect navigation interaction "),n.unref(c)?n.createCommentVNode("v-if",!0):(n.openBlock(),n.createElementBlock("i",{key:3,class:n.normalizeClass(n.unref(l).m("close-tip"))},n.toDisplayString(n.unref(a)("el.upload.deleteTip")),3)),e.listType==="picture-card"?(n.openBlock(),n.createElementBlock("span",{key:4,class:n.normalizeClass(n.unref(i).be("list","item-actions"))},[n.createElementVNode("span",{class:n.normalizeClass(n.unref(i).be("list","item-preview")),onClick:v=>e.handlePreview(m)},[n.createVNode(n.unref(ke),{class:n.normalizeClass(n.unref(l).m("zoom-in"))},{default:n.withCtx(()=>[n.createVNode(n.unref(Hm))]),_:1},8,["class"])],10,kee),n.unref(c)?n.createCommentVNode("v-if",!0):(n.openBlock(),n.createElementBlock("span",{key:0,class:n.normalizeClass(n.unref(i).be("list","item-delete")),onClick:v=>f(m)},[n.createVNode(n.unref(ke),{class:n.normalizeClass(n.unref(l).m("delete"))},{default:n.withCtx(()=>[n.createVNode(n.unref(yM))]),_:1},8,["class"])],10,xee))],2)):n.createCommentVNode("v-if",!0)])],42,Mee))),128)),n.renderSlot(p.$slots,"append")]),_:3},8,["class","name"]))}});const Cee=ge({..._b,beforeUpload:{type:K(Function),default:dt},onRemove:{type:K(Function),default:dt},onStart:{type:K(Function),default:dt},onSuccess:{type:K(Function),default:dt},onProgress:{type:K(Function),default:dt},onError:{type:K(Function),default:dt},onExceed:{type:K(Function),default:dt}}),Eee=ge({disabled:{type:Boolean,default:void 0},directory:Boolean}),Tee={file:e=>De(e)},zg="ElUploadDrag";var Dee=n.defineComponent({name:zg,__name:"upload-dragger",props:Eee,emits:Tee,setup(e,{emit:t}){const r=e,o=t;n.inject(Ib)||gn(zg,"usage: <el-upload><el-upload-dragger /></el-upload>");const i=he("upload"),l=n.ref(!1),s=Bt(),c=h=>new Promise((m,g)=>h.file(m,g)),u=async h=>{try{if(h.isFile){const m=await c(h);return m.isDirectory=!1,[m]}if(h.isDirectory){const m=h.createReader(),g=()=>new Promise((M,k)=>m.readEntries(M,k)),v=[];let y=await g();for(;y.length>0;)v.push(...y),y=await g();const N=v.map(M=>u(M).catch(()=>[])),b=await Promise.all(N);return lu(b)}}catch{return[]}return[]},d=async h=>{if(s.value)return;l.value=!1,h.stopPropagation();const m=Array.from(h.dataTransfer.files),g=h.dataTransfer.items||[];if(r.directory){const v=Array.from(g).map(N=>{var b;return(b=N==null?void 0:N.webkitGetAsEntry)==null?void 0:b.call(N)}).filter(N=>N),y=await Promise.all(v.map(u));o("file",lu(y));return}m.forEach((v,y)=>{var N;const b=g[y],M=(N=b==null?void 0:b.webkitGetAsEntry)==null?void 0:N.call(b);M&&(v.isDirectory=M.isDirectory)}),o("file",m)},f=()=>{s.value||(l.value=!0)},p=h=>{h.currentTarget.contains(h.relatedTarget)||(l.value=!1)};return(h,m)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([n.unref(i).b("dragger"),n.unref(i).is("dragover",l.value)]),onDrop:n.withModifiers(d,["prevent"]),onDragover:n.withModifiers(f,["prevent"]),onDragleave:n.withModifiers(p,["prevent"])},[n.renderSlot(h.$slots,"default")],34))}});const See=["tabindex","aria-disabled","onKeydown"],_ee=["name","disabled","multiple","accept","webkitdirectory"];var jg=n.defineComponent({name:"ElUploadContent",inheritAttrs:!1,__name:"upload-content",props:Cee,setup(e,{expose:t}){const r=e,o=he("upload"),a=Bt(),i=n.shallowRef({}),l=n.shallowRef(),s=g=>{if(g.length===0)return;const{autoUpload:v,limit:y,fileList:N,multiple:b,onStart:M,onExceed:k}=r;if(y&&N.length+g.length>y){k(g,N);return}b||(g=g.slice(0,1));for(const w of g){const C=w;C.uid=d0(),M(C),v&&c(C)}},c=async g=>{if(l.value.value="",!r.beforeUpload)return d(g);let v,y={};try{const b=r.data,M=r.beforeUpload(g);y=Hp(r.data)?y1(r.data):r.data,v=await M,Hp(r.data)&&Yt(b,y)&&(y=y1(r.data))}catch{v=!1}if(v===!1){r.onRemove(g);return}let N=g;v instanceof Blob&&(v instanceof File?N=v:N=new File([v],g.name,{type:g.type})),d(Object.assign(N,{uid:g.uid}),y)},u=async(g,v)=>at(g)?g(v):g,d=async(g,v)=>{const{headers:y,data:N,method:b,withCredentials:M,name:k,action:w,onProgress:C,onSuccess:E,onError:A,httpRequest:O}=r;try{v=await u(v??N,g)}catch{r.onRemove(g);return}const{uid:_}=g,j={headers:y||{},withCredentials:M,file:g,data:v,method:b,filename:k,action:w,onProgress:P=>{C(P,g)},onSuccess:P=>{E(P,g),delete i.value[_]},onError:P=>{A(P,g),delete i.value[_]}},R=O(j);i.value[_]=R,R instanceof Promise&&R.then(j.onSuccess,j.onError)},f=g=>{const v=g.target.files;v&&s(Array.from(v))},p=()=>{a.value||(l.value.value="",l.value.click())},h=()=>{p()};return t({abort:g=>{kz(i.value).filter(g?([y])=>String(g.uid)===y:()=>!0).forEach(([y,N])=>{N instanceof XMLHttpRequest&&N.abort(),delete i.value[y]})},upload:c}),(g,v)=>(n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([n.unref(o).b(),n.unref(o).m(e.listType),n.unref(o).is("drag",e.drag),n.unref(o).is("disabled",n.unref(a))]),tabindex:n.unref(a)?void 0:0,"aria-disabled":n.unref(a),role:"button",onClick:p,onKeydown:n.withKeys(n.withModifiers(h,["self"]),["enter","space"])},[e.drag?(n.openBlock(),n.createBlock(Dee,{key:0,disabled:n.unref(a),directory:e.directory,onFile:s},{default:n.withCtx(()=>[n.renderSlot(g.$slots,"default")]),_:3},8,["disabled","directory"])):n.renderSlot(g.$slots,"default",{key:1}),n.createElementVNode("input",{ref_key:"inputRef",ref:l,class:n.normalizeClass(n.unref(o).e("input")),name:e.name,disabled:n.unref(a),multiple:e.multiple,accept:e.accept,webkitdirectory:e.directory||void 0,type:"file",onChange:f,onClick:v[0]||(v[0]=n.withModifiers(()=>{},["stop"]))},null,42,_ee)],42,See))}});const Lg="ElUpload",Bg=e=>{var t;(t=e.url)!=null&&t.startsWith("blob:")&&URL.revokeObjectURL(e.url)},Iee=(e,t)=>{const r=gz(e,"fileList",void 0,{passive:!0}),o=m=>r.value.find(g=>g.uid===m.uid);function a(m){var g;(g=t.value)==null||g.abort(m)}function i(m=["ready","uploading","success","fail"]){r.value=r.value.filter(g=>!m.includes(g.status))}function l(m){r.value=r.value.filter(g=>g.uid!==m.uid)}const s=m=>{n.nextTick(()=>e.onChange(m,r.value))},c=(m,g)=>{const v=o(g);v&&(console.error(m),v.status="fail",l(v),e.onError(m,v,r.value),s(v))},u=(m,g)=>{const v=o(g);v&&(e.onProgress(m,v,r.value),v.status="uploading",v.percentage=Math.round(m.percent))},d=(m,g)=>{const v=o(g);v&&(v.status="success",v.response=m,e.onSuccess(m,v,r.value),s(v))},f=m=>{Hn(m.uid)&&(m.uid=d0());const g={name:m.name,percentage:0,status:"ready",size:m.size,raw:m,uid:m.uid};if(e.listType==="picture-card"||e.listType==="picture")try{g.url=URL.createObjectURL(m)}catch(v){He(Lg,v.message),e.onError(v,g,r.value)}r.value=[...r.value,g],s(g)},p=async m=>{const g=m instanceof File?o(m):m;g||gn(Lg,"file to be removed not found");const v=y=>{a(y),l(y),e.onRemove(y,r.value),Bg(y)};e.beforeRemove?await e.beforeRemove(g,r.value)!==!1&&v(g):v(g)};function h(){r.value.filter(({status:m})=>m==="ready").forEach(({raw:m})=>{var g;return m&&((g=t.value)==null?void 0:g.upload(m))})}return n.watch(()=>e.listType,m=>{m!=="picture-card"&&m!=="picture"||(r.value=r.value.map(g=>{const{raw:v,url:y}=g;if(!y&&v)try{g.url=URL.createObjectURL(v)}catch(N){e.onError(N,g,r.value)}return g}))}),n.watch(r,m=>{for(const g of m)g.uid||(g.uid=d0()),g.status||(g.status="success")},{immediate:!0,deep:!0}),{uploadFiles:r,abort:a,clearFiles:i,handleError:c,handleProgress:u,handleStart:f,handleSuccess:d,handleRemove:p,submit:h,revokeFileObjectURL:Bg}};var Aee=n.defineComponent({name:"ElUpload",__name:"upload",props:gee,setup(e,{expose:t}){const r=e,o=Bt(),a=n.shallowRef(),{abort:i,submit:l,clearFiles:s,uploadFiles:c,handleStart:u,handleError:d,handleRemove:f,handleSuccess:p,handleProgress:h,revokeFileObjectURL:m}=Iee(r,a),g=n.computed(()=>r.listType==="picture-card"),v=n.computed(()=>({...r,fileList:c.value,onStart:u,onProgress:h,onSuccess:p,onError:d,onRemove:f}));return n.onBeforeUnmount(()=>{c.value.forEach(m)}),n.provide(Ib,{accept:n.toRef(r,"accept")}),t({abort:i,submit:l,clearFiles:s,handleStart:u,handleRemove:f}),(y,N)=>(n.openBlock(),n.createElementBlock("div",null,[g.value&&e.showFileList?(n.openBlock(),n.createBlock(Og,{key:0,disabled:n.unref(o),"list-type":e.listType,files:n.unref(c),crossorigin:e.crossorigin,"handle-preview":e.onPreview,onRemove:n.unref(f)},n.createSlots({append:n.withCtx(()=>[n.createVNode(jg,n.mergeProps({ref_key:"uploadRef",ref:a},v.value),{default:n.withCtx(()=>[y.$slots.trigger?n.renderSlot(y.$slots,"trigger",{key:0}):n.createCommentVNode("v-if",!0),!y.$slots.trigger&&y.$slots.default?n.renderSlot(y.$slots,"default",{key:1}):n.createCommentVNode("v-if",!0)]),_:3},16)]),_:2},[y.$slots.file?{name:"default",fn:n.withCtx(({file:b,index:M})=>[n.renderSlot(y.$slots,"file",{file:b,index:M})]),key:"0"}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):n.createCommentVNode("v-if",!0),!g.value||g.value&&!e.showFileList?(n.openBlock(),n.createBlock(jg,n.mergeProps({key:1,ref_key:"uploadRef",ref:a},v.value),{default:n.withCtx(()=>[y.$slots.trigger?n.renderSlot(y.$slots,"trigger",{key:0}):n.createCommentVNode("v-if",!0),!y.$slots.trigger&&y.$slots.default?n.renderSlot(y.$slots,"default",{key:1}):n.createCommentVNode("v-if",!0)]),_:3},16)):n.createCommentVNode("v-if",!0),y.$slots.trigger?n.renderSlot(y.$slots,"default",{key:2}):n.createCommentVNode("v-if",!0),n.renderSlot(y.$slots,"tip"),!g.value&&e.showFileList?(n.openBlock(),n.createBlock(Og,{key:3,disabled:n.unref(o),"list-type":e.listType,files:n.unref(c),crossorigin:e.crossorigin,"handle-preview":e.onPreview,onRemove:n.unref(f)},n.createSlots({_:2},[y.$slots.file?{name:"default",fn:n.withCtx(({file:b,index:M})=>[n.renderSlot(y.$slots,"file",{file:b,index:M})]),key:"0"}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):n.createCommentVNode("v-if",!0)]))}});const Oee=it(Aee);function zee(e,t){let r;const o=n.ref(!1),a=n.reactive({...e,originalPosition:"",originalOverflow:"",visible:!1});function i(h){a.text=h}function l(){const h=a.parent,m=p.ns;if(!h.vLoadingAddClassList){let g=h.getAttribute("loading-number");g=Number.parseInt(g)-1,g?h.setAttribute("loading-number",g.toString()):(cs(h,m.bm("parent","relative")),h.removeAttribute("loading-number")),cs(h,m.bm("parent","hidden"))}s(),f.unmount()}function s(){var h,m;(m=(h=p.$el)==null?void 0:h.parentNode)==null||m.removeChild(p.$el)}function c(){var h;e.beforeClose&&!e.beforeClose()||(o.value=!0,clearTimeout(r),r=setTimeout(u,400),a.visible=!1,(h=e.closed)==null||h.call(e))}function u(){if(!o.value)return;const h=a.parent;o.value=!1,h.vLoadingAddClassList=void 0,l()}const d=n.defineComponent({name:"ElLoading",setup(h,{expose:m}){const{ns:g,zIndex:v}=xz("loading");return m({ns:g,zIndex:v}),()=>{const y=a.spinner||a.svg,N=n.h("svg",{class:"circular",viewBox:a.svgViewBox?a.svgViewBox:"0 0 50 50",...y?{innerHTML:y}:{}},[n.h("circle",{class:"path",cx:"25",cy:"25",r:"20",fill:"none"})]),b=a.text?n.h("p",{class:g.b("text")},[a.text]):void 0;return n.h(n.Transition,{name:g.b("fade"),onAfterLeave:u},{default:n.withCtx(()=>[n.withDirectives(n.createVNode("div",{style:{backgroundColor:a.background||""},class:[g.b("mask"),a.customClass,g.is("fullscreen",a.fullscreen)]},[n.h("div",{class:g.b("spinner")},[N,b])]),[[n.vShow,a.visible]])])})}}}),f=n.createApp(d);Object.assign(f._context,t??{});const p=f.mount(document.createElement("div"));return{...n.toRefs(a),setText:i,removeElLoadingChild:s,close:c,handleAfterLeave:u,vm:p,get $el(){return p.$el}}}let bc;const Ti=function(e={},t){if(!tt)return;const r=jee(e);if(r.fullscreen&&bc)return bc;const o=zee({...r,closed:()=>{var i;(i=r.closed)==null||i.call(r),r.fullscreen&&(bc=void 0)}},t??Ti._context);Lee(r,r.parent,o),Vg(r,r.parent,o),r.parent.vLoadingAddClassList=()=>Vg(r,r.parent,o);let a=r.parent.getAttribute("loading-number");return a?a=`${Number.parseInt(a)+1}`:a="1",r.parent.setAttribute("loading-number",a),r.parent.appendChild(o.$el),n.nextTick(()=>o.visible.value=r.visible),r.fullscreen&&(bc=o),o},jee=e=>{var t,r,o,a;let i;return nt(e.target)?i=(t=document.querySelector(e.target))!=null?t:document.body:i=e.target||document.body,{parent:i===document.body||e.body?document.body:i,background:e.background||"",svg:e.svg||"",svgViewBox:e.svgViewBox||"",spinner:e.spinner||!1,text:e.text||"",fullscreen:i===document.body&&((r=e.fullscreen)!=null?r:!0),lock:(o=e.lock)!=null?o:!1,customClass:e.customClass||"",visible:(a=e.visible)!=null?a:!0,beforeClose:e.beforeClose,closed:e.closed,target:i}},Lee=async(e,t,r)=>{const{nextZIndex:o}=r.vm.zIndex||r.vm._.exposed.zIndex,a={};if(e.fullscreen)r.originalPosition.value=Bo(document.body,"position"),r.originalOverflow.value=Bo(document.body,"overflow"),a.zIndex=o();else if(e.parent===document.body){r.originalPosition.value=Bo(document.body,"position"),await n.nextTick();for(const i of["top","left"]){const l=i==="top"?"scrollTop":"scrollLeft";a[i]=`${e.target.getBoundingClientRect()[i]+document.body[l]+document.documentElement[l]-Number.parseInt(Bo(document.body,`margin-${i}`),10)}px`}for(const i of["height","width"])a[i]=`${e.target.getBoundingClientRect()[i]}px`}else r.originalPosition.value=Bo(t,"position");for(const[i,l]of Object.entries(a))r.$el.style[i]=l},Vg=(e,t,r)=>{const o=r.vm.ns||r.vm._.exposed.ns;["absolute","fixed","sticky"].includes(r.originalPosition.value)?cs(t,o.bm("parent","relative")):Yp(t,o.bm("parent","relative")),e.fullscreen&&e.lock?Yp(t,o.bm("parent","hidden")):cs(t,o.bm("parent","hidden"))};Ti._context=null;const Al=Symbol("ElLoading"),ga=e=>`element-loading-${GO(e)}`,$g=(e,t)=>{var r,o,a,i;const l=t.instance,s=h=>ft(t.value)?t.value[h]:void 0,c=h=>{const m=nt(h)&&(l==null?void 0:l[h])||h;return n.ref(m)},u=h=>c(s(h)||e.getAttribute(ga(h))),d=(r=s("fullscreen"))!=null?r:t.modifiers.fullscreen,f={text:u("text"),svg:u("svg"),svgViewBox:u("svgViewBox"),spinner:u("spinner"),background:u("background"),customClass:u("customClass"),fullscreen:d,target:(o=s("target"))!=null?o:d?void 0:e,body:(a=s("body"))!=null?a:t.modifiers.body,lock:(i=s("lock"))!=null?i:t.modifiers.lock},p=Ti(f);p._context=Rl._context,e[Al]={options:f,instance:p}},Bee=(e,t)=>{for(const r of Object.keys(e))n.isRef(e[r])&&(e[r].value=t[r])},Rl={mounted(e,t){t.value&&$g(e,t)},updated(e,t){const r=e[Al];if(!t.value){r==null||r.instance.close(),e[Al]=null;return}r?Bee(r.options,ft(t.value)?t.value:{text:e.getAttribute(ga("text")),svg:e.getAttribute(ga("svg")),svgViewBox:e.getAttribute(ga("svgViewBox")),spinner:e.getAttribute(ga("spinner")),background:e.getAttribute(ga("background")),customClass:e.getAttribute(ga("customClass"))}):$g(e,t)},unmounted(e){var t;(t=e[Al])==null||t.instance.close(),e[Al]=null}};Rl._context=null;const Vee={install(e){Ti._context=e._context,Rl._context=e._context,e.directive("loading",Rl),e.config.globalProperties.$loading=Ti},directive:Rl,service:Ti},Eh="pt-br",Pg={"pt-br":{"simple-filter":"Filtro simples","advanced-filter":"Filtro avançado","search-placeholder":"Digite algo para buscar",searching:"Procurando","recently-searched":"Buscas recentes","send-for-all":"Enviar para todos","show-more":"Mostrar mais","load-more":"Carregar mais","search-for-markers-classes-users":"Busque por marcadores, turmas, alunos e usuários","when-you-have-markers-classes":"Quando você tiver marcadores e turmas, eles aparecerão aqui.","not-found":"Não encontramos resultados","make-sure-to-type-something":"Tenha certeza que você está digitando uma palavra-chave correta",clean:"Limpar","see-all":"Ver todos","selected-recipients":"Destinatários selecionados",cancel:"Cancelar",continue:"Continuar","show-for-all-tags":"Você já selecionou alguns destinatários e eles serão substituídos pela tag todos.","one-result-found":"1 resultado encontrado","results-found":" resultados encontrados","error-target-loading":"Erro ao carregar o público alvo.","error-searching":"Erro ao buscar o público desejado.","add-filter":"Adicionar filtro",save:"Salvar",search:"Pesquisar",bold:"Negrito",italic:"Itálico",underline:"Sublinhado",title:"Título","bullet-list":"Lista com marcadores","numbered-list":"Lista numerada",link:"Inserir link",blockquote:"Citação","remove-formatting":"Remover formatação","insert-link":"Insira um link","insert-valid-link":"Insira um link válido",insert:"Inserir","edit-link":"Editar link","remove-link":"Remover link","text-editor-placeholder":"Escreva algo...","date-editor-relative-past":"Relativo - Passado","date-editor-relative-future":"Relativo - Futuro","date-editor-absolute":"Absoluto","date-relative-comparation-lt":"Há menos de","date-relative-comparation-gt":"Há mais de","date-relative-comparation-eq":"Há exatamente","date-relative-future-gt":"Daqui a mais de","date-relative-future-lt":"Daqui a menos de","date-relative-future-eq":"Daqui a exatamente","date-absolute-eq":"Em","date-absolute-gte":"A partir de","date-absolute-lt":"Até","type-to-filter":"Digite para filtrar","choose-a-mode-to-filter":"Escolha um modo para filtrar","less-than":"Menor que","less-or-equal":"Menor ou igual a","greater-than":"Maior que","greater-or-equal":"Maior ou igual a",equal:"Igual a",different:"Diferente de",contains:"Contém","starts-at":"Começa em","ends-at":"Termina em",exactly:"É exatamente","not-equal":"Não é","start-placeholder":"Do dia","end-placeholder":"Ao dia","placeholder-date":"Selecione uma data",time:"Horário",date:"Selecione uma data","from-day":"Do dia","to-day":"Ao dia","calendar-weekday-sunday":"Dom","calendar-weekday-monday":"Seg","calendar-weekday-tuesday":"Ter","calendar-weekday-wednesday":"Qua","calendar-weekday-thursday":"Qui","calendar-weekday-friday":"Sex","calendar-weekday-saturday":"Sáb","calendar-month-january":"Janeiro","calendar-month-february":"Fevereiro","calendar-month-march":"Março","calendar-month-april":"Abril","calendar-month-may":"Maio","calendar-month-june":"Junho","calendar-month-july":"Julho","calendar-month-august":"Agosto","calendar-month-september":"Setembro","calendar-month-october":"Outubro","calendar-month-november":"Novembro","calendar-month-december":"Dezembro","calendar-date-separator":" de "},en:{"simple-filter":"Simple filter","advanced-filter":"Advanced filter","search-placeholder":"Type something to search",searching:"Searching","recently-searched":"Recently searched","send-for-all":"Send for all","show-more":"Show more","load-more":"Load more","search-for-markers-classes-users":"Search for markers, classes, students, and users","when-you-have-markers-classes":"When you have markers and classes, they will appear here.","not-found":"We did not find any results","make-sure-to-type-something":"Make sure you are typing a correct keyword",clean:"Clean","see-all":"See all","selected-recipients":"Selected recipients",cancel:"Cancel",continue:"Continue","show-for-all-tags":"You have already selected some recipients and they will be replaced by the tag all.","one-result-found":"1 result found","results-found":" results found","error-target-loading":"Error loading target audience.","error-searching":"Error searching for the desired audience.","add-filter":"Add filter",save:"Save",search:"Search",bold:"Bold",italic:"Italic",underline:"Underline",title:"Title","bullet-list":"Bullet list","numbered-list":"Numbered list",link:"Insert link",blockquote:"Blockquote","remove-formatting":"Remove formatting","insert-link":"Insert a link","insert-valid-link":"Insert a valid link",insert:"Insert","edit-link":"Edit link","remove-link":"Remove link","text-editor-placeholder":"Write something...","date-editor-relative-past":"Relative - Past","date-editor-relative-future":"Relative - Future","date-editor-absolute":"Absolute","date-relative-comparation-lt":"Less than","date-relative-comparation-gt":"More than","date-relative-comparation-eq":"Exactly","date-relative-future-gt":"In more than","date-relative-future-lt":"In less than","date-relative-future-eq":"In exactly","date-absolute-eq":"On","date-absolute-gte":"From","date-absolute-lt":"Until","type-to-filter":"Type to filter","choose-a-mode-to-filter":"Choose a mode to filter","less-than":"Less than","less-or-equal":"Less than or equal to","greater-than":"Greater than","greater-or-equal":"Greater than or equal to",equal:"Equal to",different:"Different from",contains:"Contains","starts-at":"Starts at","ends-at":"Ends at",exactly:"Exactly","not-equal":"Not equal to","start-placeholder":"From the day","end-placeholder":"To the day","placeholder-date":"Select a date",time:"Time",date:"Select a date","from-day":"From day","to-day":"To day","calendar-weekday-sunday":"Sun","calendar-weekday-monday":"Mon","calendar-weekday-tuesday":"Tue","calendar-weekday-wednesday":"Wed","calendar-weekday-thursday":"Thu","calendar-weekday-friday":"Fri","calendar-weekday-saturday":"Sat","calendar-month-january":"January","calendar-month-february":"February","calendar-month-march":"March","calendar-month-april":"April","calendar-month-may":"May","calendar-month-june":"June","calendar-month-july":"July","calendar-month-august":"August","calendar-month-september":"September","calendar-month-october":"October","calendar-month-november":"November","calendar-month-december":"December","calendar-date-separator":" "},es:{"simple-filter":"Filtro simple","advanced-filter":"Filtro avanzado","search-placeholder":"Escribe algo para buscar",searching:"Buscando","recently-searched":"Buscas recientes","send-for-all":"Enviar para todos","show-more":"Mostrar más","load-more":"Cargar más","search-for-markers-classes-users":"Busque por marcadores, clases, estudiantes y usuarios","when-you-have-markers-classes":"Cuando tengas marcadores y clases, aparecerán aquí.","not-found":"No encontramos resultados","make-sure-to-type-something":"Asegúrate de escribir una palabra clave correcta",clean:"Limpiar","see-all":"Ver todos","selected-recipients":"Destinatarios seleccionados",cancel:"Cancelar",continue:"Continuar","show-for-all-tags":"Ya has seleccionado algunos destinatarios y serán reemplazados por la etiqueta todos.","one-result-found":"1 resultado encontrado","results-found":" resultados encontrados","error-target-loading":"Error al cargar el público objetivo.","error-searching":"Error al buscar el público deseado.","add-filter":"Agregar filtro",save:"Guardar",search:"Buscar",bold:"Negrita",italic:"Cursiva",underline:"Subrayado",title:"Título","bullet-list":"Lista con viñetas","numbered-list":"Lista numerada",link:"Insertar enlace",blockquote:"Cita","remove-formatting":"Eliminar formato","insert-link":"Inserte un enlace","insert-valid-link":"Inserte un enlace válido",insert:"Insertar","edit-link":"Editar enlace","remove-link":"Eliminar enlace","text-editor-placeholder":"Escribe algo...","date-editor-relative-past":"Relativo - Pasado","date-editor-relative-future":"Relativo - Futuro","date-editor-absolute":"Absoluto","date-relative-comparation-lt":"Hace menos de","date-relative-comparation-gt":"Hace más de","date-relative-comparation-eq":"Hace exactamente","date-relative-future-gt":"En más de","date-relative-future-lt":"En menos de","date-relative-future-eq":"En exactamente","date-absolute-eq":"En","date-absolute-gte":"A partir de","date-absolute-lt":"Hasta","type-to-filter":"Escriba para filtrar","choose-a-mode-to-filter":"Elija un modo para filtrar","less-than":"Menor que","less-or-equal":"Menor o igual a","greater-than":"Mayor que","greater-or-equal":"Mayor o igual a",equal:"Igual a",different:"Diferente de",contains:"Contiene","starts-at":"Comienza en","ends-at":"Termina en",exactly:"Es exactamente","not-equal":"No es igual a","start-placeholder":"Desde el día","end-placeholder":"Hasta el día","placeholder-date":"Seleccionar una fecha",time:"Hora",date:"Seleccionar fecha","from-day":"Desde el día","to-day":"Hasta el día","calendar-weekday-sunday":"Dom","calendar-weekday-monday":"Lun","calendar-weekday-tuesday":"Mar","calendar-weekday-wednesday":"Mié","calendar-weekday-thursday":"Jue","calendar-weekday-friday":"Vie","calendar-weekday-saturday":"Sáb","calendar-month-january":"Enero","calendar-month-february":"Febrero","calendar-month-march":"Marzo","calendar-month-april":"Abril","calendar-month-may":"Mayo","calendar-month-june":"Junio","calendar-month-july":"Julio","calendar-month-august":"Agosto","calendar-month-september":"Septiembre","calendar-month-october":"Octubre","calendar-month-november":"Noviembre","calendar-month-december":"Diciembre","calendar-date-separator":" de "}};let Ab=Eh;function pn(){return Ab}function Fl(e,t){var r,o;return t=t||pn(),((r=Pg[t])==null?void 0:r[e])||((o=Pg[Eh])==null?void 0:o[e])||e}const $ee=e=>({setLanguage:async function(t){["en","es","pt-br"].includes(t)||(t=Eh);let o;switch(t){case"en":o=await Promise.resolve().then(()=>$O),await Promise.resolve().then(()=>require("./en-af42a7cf.cjs")).then(a=>a.en);break;case"es":o=await Promise.resolve().then(()=>require("./es-8dd974d7.cjs")),await Promise.resolve().then(()=>require("./es-04ea6343.cjs")).then(a=>a.es);break;default:o=await Promise.resolve().then(()=>require("./pt-br-21743d21.cjs")),await Promise.resolve().then(()=>require("./pt-br-d03dee39.cjs")).then(a=>a.ptBr);break}mM({locale:o.default},e,!0),Nd.locale(t),Ab=t}});function Ob(e){const t=[];if(e&&e.format&&t.push(`format:${e.format}`),e&&e.type&&t.push(`type:${e.type}`),t.push("DEFAULT"),t.length===0)throw new Error(`Unprocessable fieldSchema ${e}`);return t}const Hc=new Map;function Pee(e,t){if(!e)throw new Error(`Received ${e} fieldSchema, componentType ${t}`);if(e.components&&e.components[t])return e.components[t];const r=Ob(e);for(const o of r){const a=Hc.get(`${o}:${t}`);if(a)return a}throw new Error(`Component not found for field schema ${JSON.stringify(e)} and component type ${t}`)}function Ree(e,t,r){const a=`${Ob(e)[0]}:${t}`;Hc.has(a)&&Hc.get(a)!==r&&console.warn(`Overwriting component for key ${a}`),Hc.set(a,r)}const Sn={get:Pee,register:Ree},zb={};zb.install=function(e){e.config.globalProperties.$L.FieldTypeComponents=Sn};const Fee=e=>{let t=e;return e.startsWith("El")&&(t=e.substring(2)),`L${t}`},Uee=[Gr,TQ,DQ,GQ,iJ,lJ,sJ,sZ,EW,TW,db,PX,see,Oee],jb={};jb.install=function(e){for(const t of Uee)e.component(Fee(t.name),t);for(const[t,r]of Object.entries(SM)){const o=`ElIcon${t}`;e.component(o,r)}};const Hee=n.defineComponent({name:"LAlert",components:{Alert:rH},props:{type:{type:String,default:"info"},showIcon:{type:Boolean,default:!1}}});function Yee(e,t,r,o,a,i){const l=n.resolveComponent("Alert");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{type:e.type,"show-icon":e.showIcon,class:"l-alert"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["type","show-icon"])}const Qee=xe(Hee,[["render",Yee],["__scopeId","data-v-17379a78"]]),Wee=Object.freeze(Object.defineProperty({__proto__:null,default:Qee},Symbol.toStringTag,{value:"Module"}));function qee(e){if(!e)return"";var t=1e3;if(Math.abs(e)<t)return e+" B";var r=["kb","MB","GB","TB","PB","EB","ZB","YB"],o=-1;do e/=t,++o;while(Math.abs(e)>=t&&o<r.length-1);return e.toFixed(1)+" "+r[o]}const Gee={tagName:"l-attachment-chip",props:{name:String,mime:String,thumb:String,url:String,size:Number,closeable:{type:Boolean,default:!1}},computed:{prettySize(){return qee(this.size)},prettyMime(){if(!this.mime)return{extension:"???",color:"gray-20"};if(this.mime.indexOf("image/")>-1){const e={extension:"IMG",color:"green"};return{"image/gif":{extension:"GIF",color:"primary"},"image/jpeg":{extension:"JPG",color:"primary"},"image/png":{extension:"PNG",color:"primary"},"image/svg+xml":{extension:"SVG",color:"danger"}}[this.mime]||e}if(this.mime.indexOf("text/")>-1){const e={extension:"TXT",color:"lead"};return{"text/css":{extension:"CSS",color:"lead"},"text/csv":{extension:"CSV",color:"lead"},"text/html":{extension:"HTML",color:"lead"}}[this.mime]||e}if(this.mime.indexOf("video/")>-1){const e={extension:"VID",color:"danger"};return{"video/quicktime":{extension:"MOV",color:"danger"},"video/mp4":{extension:"MP4",color:"danger"},"video/mpeg":{extension:"MP4",color:"danger"}}[this.mime]||e}if(this.mime.indexOf("audio/")>-1)return{extension:"AUD",color:"info"};if(this.mime.indexOf("application/")>-1){const e={extension:"FIL",color:"danger"};return{"application/zip":{extension:"ZIP",color:"danger"},"application/x-rar-compressed":{extension:"RAR",color:"danger"},"application/pdf":{extension:"PDF",color:"danger"},"application/xml":{extension:"XML",color:"danger"},"application/javascript":{extension:"JS",color:"success"},"application/json":{extension:"JSON",color:"success"},"application/msword":{extension:"DOC",color:"link"},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{extension:"DOC",color:"link"},"application/vnd.ms-powerpoint":{extension:"PPT",color:"salmon"},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{extension:"PPT",color:"info"},"application/vnd.ms-excel":{extension:"XLS",color:"success"},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{extension:"XLS",color:"success"}}[this.mime]||e}return{extension:"FIL",color:"gray-20"}}},methods:{handleClose(e){e.stopPropagation(),this.$emit("close",this)}}},Kee={class:"l-attachment-chip"},Jee={key:0,class:"l-attachment-chip-thumb"},Zee=["src"],Xee={key:1,class:"l-attachment-chip-mime"},ete={class:"l-attachment-chip-text"},tte={key:0,class:"l-attachment-chip-name"},nte={key:1,class:"l-attachment-chip-size"};function rte(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",Kee,[r.thumb?(n.openBlock(),n.createElementBlock("div",Jee,[n.createElementVNode("img",{alt:"Thumb",src:r.thumb,width:"32",height:"32"},null,8,Zee)])):r.mime&&i.prettyMime?(n.openBlock(),n.createElementBlock("div",Xee,[n.createElementVNode("div",{class:"l-attachment-chip-extension",style:n.normalizeStyle({"background-color":"var(--color-"+i.prettyMime.color+")"})},n.toDisplayString(i.prettyMime.extension),5)])):n.createCommentVNode("",!0),n.createElementVNode("span",ete,[r.name?(n.openBlock(),n.createElementBlock("span",tte,n.toDisplayString(r.name),1)):n.createCommentVNode("",!0),i.prettySize&&!r.closeable?(n.openBlock(),n.createElementBlock("span",nte,"("+n.toDisplayString(i.prettySize)+")",1)):n.createCommentVNode("",!0)]),r.closeable?(n.openBlock(),n.createElementBlock("button",{key:2,class:"l-attachment-chip-clear",onClick:t[0]||(t[0]=(...s)=>i.handleClose&&i.handleClose(...s))},[n.createVNode(l,{color:"link"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-multiply")])),_:1})])):n.createCommentVNode("",!0)])}const ote=xe(Gee,[["render",rte]]),ate=Object.freeze(Object.defineProperty({__proto__:null,default:ote},Symbol.toStringTag,{value:"Module"}));const ite={tagName:"l-box"};function lte(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",null,[n.renderSlot(e.$slots,"default")])}const ste=xe(ite,[["render",lte]]),cte=Object.freeze(Object.defineProperty({__proto__:null,default:ste},Symbol.toStringTag,{value:"Module"}));const ute={tagName:"l-box-header",props:["icon"]};function dte(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",null,[n.createElementVNode("h1",null,[r.icon?(n.openBlock(),n.createBlock(l,{key:0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.icon),1)]),_:1})):n.createCommentVNode("",!0),n.renderSlot(e.$slots,"default")])])}const fte=xe(ute,[["render",dte]]),pte=Object.freeze(Object.defineProperty({__proto__:null,default:fte},Symbol.toStringTag,{value:"Module"}));const mte={tagName:"l-button",name:"LButton",components:{ElIcon:ke,ElLoading:Vee},inject:{elForm:{default:""},elFormItem:{default:""}},props:{type:{type:String,default:"default"},size:String,icon:{type:String,default:""},nativeType:{type:String,default:"button"},loading:Boolean,disabled:Boolean,plain:Boolean,autofocus:Boolean,round:Boolean,circle:Boolean,fab:Boolean,square:Boolean,fill:Boolean,textColor:String},computed:{isElementIcon(){return this.icon.startsWith("el-")||this.icon.startsWith("El")},iconPascalCase(){return this.icon.replace(/(^\w|-\w)/g,e=>e.replace(/-/,"").toUpperCase())},elementIconLoaded(){return this.isElementIcon&&SM[this.iconPascalCase]},_elFormItemSize(){return(this.elFormItem||{}).elFormItemSize},buttonSize(){return this.size||this._elFormItemSize||(this.$el||{}).size},buttonDisabled(){return this.disabled||(this.elForm||{}).disabled},textColorStyle(){return Oi(this.textColor)}}},hte=["disabled","autofocus","type"];function gte(e,t,r,o,a,i){const l=n.resolveComponent("el-icon-loading"),s=n.resolveComponent("el-icon");return n.openBlock(),n.createElementBlock("button",{class:n.normalizeClass(["l-button el-button",[r.type?"el-button--"+r.type:"",i.buttonSize?"el-button--"+i.buttonSize:"",{"is-disabled":i.buttonDisabled,"is-loading":r.loading,"is-plain":r.plain,"is-round":r.round,"is-circle":r.circle,"is-fab":r.fab,"is-square":r.square,"is-fill":r.fill}]]),disabled:i.buttonDisabled||r.loading,autofocus:r.autofocus,type:r.nativeType},[r.loading?(n.openBlock(),n.createBlock(s,{key:0},{default:n.withCtx(()=>[n.createVNode(l)]),_:1})):n.createCommentVNode("",!0),r.icon&&!r.loading?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[i.isElementIcon?(n.openBlock(),n.createBlock(s,{key:0},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(r.icon)))]),_:1})):(n.openBlock(),n.createElementBlock("i",{key:1,class:n.normalizeClass(r.icon)},null,2))],64)):n.createCommentVNode("",!0),e.$slots.default?(n.openBlock(),n.createElementBlock("span",{key:2,style:n.normalizeStyle(r.type=="text"&&r.textColor?{color:i.textColorStyle}:"")},[n.renderSlot(e.$slots,"default")],4)):n.createCommentVNode("",!0)],10,hte)}const vte=xe(mte,[["render",gte]]),yte=Object.freeze(Object.defineProperty({__proto__:null,default:vte},Symbol.toStringTag,{value:"Module"}));const Mte={tagName:"l-calendar",name:"LCalendar",props:{lang:{type:String,default(){return pn()}},modelValue:{type:String,default:null},disabledDate:{type:Function,default:null}},data(){return{currentDate:new Date}},computed:{weekDays(){return[this.$tds("calendar-weekday-sunday",this.lang),this.$tds("calendar-weekday-monday",this.lang),this.$tds("calendar-weekday-tuesday",this.lang),this.$tds("calendar-weekday-wednesday",this.lang),this.$tds("calendar-weekday-thursday",this.lang),this.$tds("calendar-weekday-friday",this.lang),this.$tds("calendar-weekday-saturday",this.lang)]},currentMonthYear(){const e=["calendar-month-january","calendar-month-february","calendar-month-march","calendar-month-april","calendar-month-may","calendar-month-june","calendar-month-july","calendar-month-august","calendar-month-september","calendar-month-october","calendar-month-november","calendar-month-december"],t=this.$tds(e[this.currentDate.getMonth()],this.lang),r=this.$tds("calendar-date-separator",this.lang);return`${t}${r}${this.currentDate.getFullYear()}`},weeks(){const e=[],t=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth(),1),r=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth()+1,0),o=new Date(t.getFullYear(),t.getMonth(),1-t.getDay());for(let a=0;a<6;a++){const i=[];for(let l=0;l<7;l++){const s=new Date(o);s.setDate(o.getDate()+a*7+l),i.push(s)}if(e.push(i),i[6]>r)break}return e}},methods:{getCellClasses(e){if(!e)return[];const t=[],r=new Date;r.setHours(0,0,0,0);const o=this.currentDate.getMonth();if(this.disabledDate&&this.disabledDate(e)?t.push("disabled-cell"):t.push("available"),e.getMonth()!==o&&t.push("prev-month"),this.modelValue){const i=new Date(this.modelValue);e.toDateString()===i.toDateString()&&t.push("current")}return e.toDateString()===r.toDateString()&&t.push("today"),t},handleDateClick(e){if(!e||this.disabledDate&&this.disabledDate(e))return;const t=e.toISOString();this.$emit("update:modelValue",t),this.$emit("change",t)},prevMonth(){this.currentDate=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth()-1,1)},nextMonth(){this.currentDate=new Date(this.currentDate.getFullYear(),this.currentDate.getMonth()+1,1)},prevYear(){this.currentDate=new Date(this.currentDate.getFullYear()-1,this.currentDate.getMonth(),1)},nextYear(){this.currentDate=new Date(this.currentDate.getFullYear()+1,this.currentDate.getMonth(),1)}}},bte={class:"l-calendar-wrapper"},wte={class:"l-calendar__body"},Nte={class:"l-calendar__header"},kte={class:"l-calendar-header-button-wrapper"},xte={class:"l-calendar-header__label"},Cte={class:"l-calendar-header-button-wrapper"},Ete={class:"l-calendar-table"},Tte={class:"l-calendar-table-header"},Dte=["onClick"];function Ste(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",bte,[n.createElementVNode("div",wte,[n.createElementVNode("div",Nte,[n.createElementVNode("div",kte,[n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[0]||(t[0]=(...s)=>i.prevYear&&i.prevYear(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[4]||(t[4]=[n.createTextVNode("uil-angle-double-left")])),_:1})]),n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[1]||(t[1]=(...s)=>i.prevMonth&&i.prevMonth(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[5]||(t[5]=[n.createTextVNode("uil-angle-left")])),_:1})])]),n.createElementVNode("span",xte,n.toDisplayString(i.currentMonthYear),1),n.createElementVNode("div",Cte,[n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[2]||(t[2]=(...s)=>i.nextMonth&&i.nextMonth(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[6]||(t[6]=[n.createTextVNode("uil-angle-right")])),_:1})]),n.createElementVNode("button",{type:"button",class:"l-calendar-header__icon-btn",onClick:t[3]||(t[3]=(...s)=>i.nextYear&&i.nextYear(...s))},[n.createVNode(l,{class:"l-calendar-header__icon"},{default:n.withCtx(()=>t[7]||(t[7]=[n.createTextVNode("uil-angle-double-right")])),_:1})])])]),n.createElementVNode("table",Ete,[n.createElementVNode("tbody",null,[n.createElementVNode("tr",Tte,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.weekDays,s=>(n.openBlock(),n.createElementBlock("th",{key:s},n.toDisplayString(s),1))),128))]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.weeks,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c,class:"l-calendar-table-body"},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(s,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(i.getCellClasses(u)),onClick:f=>i.handleDateClick(u)},[n.createElementVNode("div",null,n.toDisplayString(u?u.getDate():""),1)],10,Dte))),128))]))),128))])])])])}const _te=xe(Mte,[["render",Ste]]),Ite=Object.freeze(Object.defineProperty({__proto__:null,default:_te},Symbol.toStringTag,{value:"Module"}));const Ate={tagName:"l-carousel",name:"Lcarousel",props:["images","height","width"],data:function(){return{selected:0}},methods:{previous(){this.selected--,this.$refs[`img:${this.selected}`][0].scrollIntoView({behavior:"smooth"})},next(){this.selected++,this.$refs[`img:${this.selected}`][0].scrollIntoView({behavior:"smooth"})}}},Ote={class:"carousel"},zte={class:"slider-container"},jte={class:"img-container"},Lte=["src","height","width"];function Bte(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",Ote,[e.selected>0?(n.openBlock(),n.createBlock(l,{key:0,class:"slider-control",circle:"",icon:"uil-angle-left",style:{left:"1em"},onClick:i.previous},null,8,["onClick"])):n.createCommentVNode("",!0),n.createElementVNode("div",zte,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.images,(s,c)=>(n.openBlock(),n.createElementBlock("div",{key:s.index,class:"slide",ref_for:!0,ref:`img:${c}`},[n.createElementVNode("div",jte,[n.createElementVNode("img",{alt:"Carousel image",src:s.src,height:r.height,width:r.width,style:{"border-radius":"10px"}},null,8,Lte)])]))),128))]),e.selected<r.images.length-1?(n.openBlock(),n.createBlock(l,{key:1,class:"slider-control",circle:"",icon:"uil-angle-right",style:{right:"1em"},onClick:i.next},null,8,["onClick"])):n.createCommentVNode("",!0)])}const Vte=xe(Ate,[["render",Bte],["__scopeId","data-v-4e5bb0e6"]]),$te=Object.freeze(Object.defineProperty({__proto__:null,default:Vte},Symbol.toStringTag,{value:"Module"}));const Pte={name:"LCheckbox",components:{ElCheckbox:VW}};function Rte(e,t,r,o,a,i){const l=n.resolveComponent("ElCheckbox");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-checkbox"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Fte=xe(Pte,[["render",Rte],["__scopeId","data-v-66702b20"]]),Ute=Object.freeze(Object.defineProperty({__proto__:null,default:Fte},Symbol.toStringTag,{value:"Module"}));const Hte={name:"LCheckboxButton",components:{CheckboxButton:$W}};function Yte(e,t,r,o,a,i){const l=n.resolveComponent("CheckboxButton");return n.openBlock(),n.createBlock(l,n.mergeProps({class:"l-checkbox-button"},e.$attrs),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Qte=xe(Hte,[["render",Yte],["__scopeId","data-v-6640b3ce"]]),Wte=Object.freeze(Object.defineProperty({__proto__:null,default:Qte},Symbol.toStringTag,{value:"Module"}));const qte={name:"LCheckboxGroup",components:{CheckboxGroup:PW},props:{separated:{type:Boolean,default:!1},color:{type:String,default:"aqua"}},computed:{customFill(){return W3(this.color)}},mounted(){const e=this.$refs.checkboxGroup.$el;this.separated&&e.children&&e.children.length&&Array.from(e.children).forEach(t=>t.classList.add("l-checkbox-button-separated"))}};function Gte(e,t,r,o,a,i){const l=n.resolveComponent("CheckboxGroup");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:[{"l-checkbox-group-separated":r.separated},"l-checkbox-group"],fill:i.customFill,"text-color":"white",ref:"checkboxGroup"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["class","fill"])}const Kte=xe(qte,[["render",Gte],["__scopeId","data-v-2664a205"]]),Jte=Object.freeze(Object.defineProperty({__proto__:null,default:Kte},Symbol.toStringTag,{value:"Module"}));const Zte={name:"LChip",props:{style:Object,icon:String,color:String,outline:{type:Boolean,default:!1},fill:{type:Boolean,default:!1},showIcon:{type:Boolean,default:!0},hideIcon:{type:Boolean,default:!1},bold:{type:Boolean,default:!1}},computed:{chipStyle(){return{"--color":Oi(this.color),"--b-color":Lp(this.color),...this.style}},chipClasses(){return{fill:this.fill,outline:this.outline,bold:this.bold}},getColor(){return Oi(this.color)||this.color},getColorLight(){return Lp(this.color)||this.color}}},Xte={key:1,class:"no-icon"},ene={class:"text"};function tne(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",{class:n.normalizeClass(["l-chip",i.chipClasses]),style:n.normalizeStyle(i.chipStyle)},[r.icon?(n.openBlock(),n.createBlock(l,{key:0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.icon),1)]),_:1})):r.hideIcon?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("span",Xte)),n.createElementVNode("span",ene,[n.renderSlot(e.$slots,"default",{},void 0,!0)])],6)}const nne=xe(Zte,[["render",tne],["__scopeId","data-v-d09f7499"]]),rne=Object.freeze(Object.defineProperty({__proto__:null,default:nne},Symbol.toStringTag,{value:"Module"}));const one={name:"LCircularLoader",props:{width:{type:Number,default:24},height:{type:Number,default:24},type:{type:String,default:"light"}}};function ane(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["loader-container",{dark:r.type==="dark"}]),style:n.normalizeStyle({width:`${r.width}px`,height:`${r.height}px`,"border-radius":`${r.width}px`})},[n.createElementVNode("div",{class:"loader",style:n.normalizeStyle({width:`${r.width*.66}px`})},t[0]||(t[0]=[n.createElementVNode("svg",{class:"circular",viewBox:"25 25 50 50"},[n.createElementVNode("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none","stroke-width":"5","stroke-miterlimit":"10"})],-1)]),4)],6)}const ine=xe(one,[["render",ane],["__scopeId","data-v-11599f46"]]),lne=Object.freeze(Object.defineProperty({__proto__:null,default:ine},Symbol.toStringTag,{value:"Module"}));const sne={tagName:"l-collapse",name:"LCollapse",components:{ElCollapse:cq}};function cne(e,t,r,o,a,i){const l=n.resolveComponent("el-collapse");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-collapse"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const une=xe(sne,[["render",cne],["__scopeId","data-v-f115834a"]]),dne=Object.freeze(Object.defineProperty({__proto__:null,default:une},Symbol.toStringTag,{value:"Module"}));const fne={components:{ElCollapseItem:uq},name:"LCollapseItem"};function pne(e,t,r,o,a,i){const l=n.resolveComponent("el-collapse-item");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-collapse-item"}),n.createSlots({default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.title?{name:"title",fn:n.withCtx(s=>[n.renderSlot(e.$slots,"title",n.normalizeProps(n.guardReactiveProps(s)),void 0,!0)]),key:"0"}:void 0]),1040)}const mne=xe(fne,[["render",pne],["__scopeId","data-v-971894ef"]]),hne=Object.freeze(Object.defineProperty({__proto__:null,default:mne},Symbol.toStringTag,{value:"Module"}));const gne={render:()=>n.h("i",{class:"uil uil-calender"})},vne={name:"LDatePicker",tagName:"l-date-picker",components:{ElDatePicker:nK},props:{prefixIcon:{type:[String,Object],default:()=>gne},format:{type:String,default:()=>"DD/MM/YYYY"},lang:{type:String,default:""},clearable:{type:Boolean,default:!0},startPlaceholder:{type:String,default(e){return Fl("start-placeholder",e.lang||pn())}},endPlaceholder:{type:String,default(e){return Fl("end-placeholder",e.lang||pn())}},placeholder:{type:String,default(e){return Fl("placeholder-date",e.lang||pn())}},rangeSeparator:{type:String,default:()=>" "},popperClass:{type:String,default:()=>"l-date-picker-popper"},hideIcon:{type:Boolean,default:()=>!1}}};function yne(e,t,r,o,a,i){const l=n.resolveComponent("el-date-picker");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{"prefix-icon":r.prefixIcon,format:r.format,"start-placeholder":r.startPlaceholder,"end-placeholder":r.endPlaceholder,placeholder:r.placeholder,"range-separator":r.rangeSeparator,"popper-class":r.popperClass,clearable:r.clearable,ref:"date-picker",class:[{"hide-icon":r.hideIcon,"clearable-input":r.clearable},"l-date-picker"]}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["prefix-icon","format","start-placeholder","end-placeholder","placeholder","range-separator","popper-class","clearable","class"])}const Mne=xe(vne,[["render",yne]]),bne=Object.freeze(Object.defineProperty({__proto__:null,default:Mne},Symbol.toStringTag,{value:"Module"}));const wne={name:"LDialog",components:{ElDialog:bK}};function Nne(e,t,r,o,a,i){const l=n.resolveComponent("el-dialog");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-dialog"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const kne=xe(wne,[["render",Nne],["__scopeId","data-v-450b5a10"]]),xne=Object.freeze(Object.defineProperty({__proto__:null,default:kne},Symbol.toStringTag,{value:"Module"})),Cne="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjgwIiBoZWlnaHQ9IjIwMCIgdmlld0JveD0iMCAwIDI4MCAyMDAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik0xNzYuNjggNTMuNTQ2M0MxOTYuMjggNTQuNTY1NSAyMjAuMTY0IDU3LjIzMTEgMjIyLjc0NiA4NS4wNzk5QzIyNC44NCAxMDcuNjY1IDIwMi41ODYgMTI0LjIzNSAxODUuMjcxIDEyOS4zOTNDMTY1LjM0IDEzNS4zMjkgMTQ5LjI5NiAxMjAuNTI4IDEyOS4zMzIgMTE4LjUzNEMxMDguOTk5IDExNi41MDcgOTguNDU5NiAxNDMuMTEzIDc4Ljg3NjQgMTM5LjgxNEM1OS44MzY0IDEzNi42MTcgNDguNzI2IDEwNy4zMzQgNDguMjUgODkuNDE0M0M0Ny42OSA2Ny40NDU1IDYwLjU3IDQ5LjU3NTkgNzQuMDEgMzYuMjQ3OUM4OC4yOTU2IDIyLjA1MTkgMTA3LjAxNiAxMS4zMTY3IDEyOC4zOTIgMjEuMzIzOUMxNDguMTg4IDMwLjU3NTEgMTUzLjQ2OCA1Mi4zMzY3IDE3Ni42OCA1My41NDYzWiIgZmlsbD0iIzU0NTFENiIvPgo8cGF0aCBvcGFjaXR5PSIwLjkiIGQ9Ik0xNzYuNjggNTMuNTQ2M0MxOTYuMjggNTQuNTY1NSAyMjAuMTY0IDU3LjIzMTEgMjIyLjc0NiA4NS4wNzk5QzIyNC44NCAxMDcuNjY1IDIwMi41ODYgMTI0LjIzNSAxODUuMjcxIDEyOS4zOTNDMTY1LjM0IDEzNS4zMjkgMTQ5Lj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AuOTIyIDUzLjE3OTNDMTExLjE4IDUzLjM4MDggMTExLjM5NiA1My42MzEyIDExMS41NTggNTMuOTE2MUwxMTUuNjc5IDYxLjE5NjFDMTE1Ljg0MSA2MS40ODA2IDExNS45NDQgNjEuNzk0MiAxMTUuOTg1IDYyLjExODhDMTE2LjAyNSA2Mi40NDM1IDExNiA2Mi43NzI5IDExNS45MTMgNjMuMDg4MkMxMTUuODI2IDYzLjQwMzUgMTE1LjY3NyA2My42OTg0IDExNS40NzUgNjMuOTU2QzExNS4yNzQgNjQuMjEzNyAxMTUuMDIzIDY0LjQyOSAxMTQuNzM4IDY0LjU4OTdDMTE0LjM2NiA2NC44MDYxIDExMy45NDMgNjQuOTIwMSAxMTMuNTEyIDY0LjkyMDFaIiBmaWxsPSJ3aGl0ZSIvPgo8cGF0aCBkPSJNMTU0Ljc4OSA3OS45NzgzTDE0OS45ODQgNzkuODA0N0wxNTIuMzA4IDg1LjQwNDdDMTUyLjMwOCA4NS40MDQ3IDE1Ni40MzYgODQuNjQzMSAxNTYuMjc5IDgyLjQxNDNMMTU0Ljc4OSA3OS45NzgzWiIgZmlsbD0iI0ZGQjU3MyIvPgo8cGF0aCBkPSJNMTQ2Ljc2NSA4Mi4xMTE5TDE0Ny45MjQgODYuMzg0N0wxNTIuMzE0IDg1LjM5MzVMMTQ5Ljk4NSA3OS44MDQ3TDE0Ni43NjUgODIuMTExOVoiIGZpbGw9IiNGRkI1NzMiLz4KPC9zdmc+Cg==";const Ene={name:"LFailedToLoad",props:{title:{type:String,default:"Algo deu errado :("},actionFunction:{type:Function},actionLabel:{type:String,default:"Tentar novamente"},loading:{type:Boolean,default:!1}}},Tne={class:"failed-to-load"},Dne={class:"lead--text title mt-3"};function Sne(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",Tne,[t[0]||(t[0]=n.createElementVNode("div",{style:{display:"flex"}},[n.createElementVNode("img",{alt:"Failed to load",src:Cne,height:"280",class:"mt-5",style:{display:"flex"}})],-1)),n.createElementVNode("h1",Dne,n.toDisplayString(r.title),1),n.createVNode(l,{onClick:r.actionFunction,height:"40",width:"220",block:"",class:"mt-3 bold f-19",loading:r.loading},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.actionLabel),1)]),_:1},8,["onClick","loading"])])}const _ne=xe(Ene,[["render",Sne],["__scopeId","data-v-407d980d"]]),Ine=Object.freeze(Object.defineProperty({__proto__:null,default:_ne},Symbol.toStringTag,{value:"Module"}));const Ane={tagName:"l-form",name:"LForm",components:{ElForm:KJ},inheritAttrs:!1};function One(e,t,r,o,a,i){const l=n.resolveComponent("el-form");return n.openBlock(),n.createBlock(l,n.normalizeProps(n.guardReactiveProps(e.$attrs)),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16)}const zne=xe(Ane,[["render",One]]),jne=Object.freeze(Object.defineProperty({__proto__:null,default:zne},Symbol.toStringTag,{value:"Module"}));const Lne={tagName:"l-form-item",name:"LFormItem",components:{ElFormItem:JJ},inheritAttrs:!1};function Bne(e,t,r,o,a,i){const l=n.resolveComponent("el-form-item");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-form-item"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16)}const Vne=xe(Lne,[["render",Bne]]),$ne=Object.freeze(Object.defineProperty({__proto__:null,default:Vne},Symbol.toStringTag,{value:"Module"}));const Pne={name:"LHelperBox",props:{icon:{type:String,required:!0},title:{type:String,required:!0},description:{type:String,required:!0},actionButtonText:{type:String},href:{type:String},width:{type:[Number,String]}},computed:{computedWidth(){return`${this.width||200}px`}},methods:{actionButtonClick(){this.$emit("actionButtonClick"),this.href&&window.open(this.href,"_blank")}}},Rne=["alt","src"],Fne={class:"mt-2 lead--text"},Une={class:"mt-2 box-value lead-light--text mb-1"};function Hne(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",{class:"box p-4",style:n.normalizeStyle({width:i.computedWidth})},[n.createElementVNode("img",{alt:r.title,src:r.icon,class:"box-image"},null,8,Rne),n.createElementVNode("h4",Fne,n.toDisplayString(r.title),1),n.createElementVNode("div",Une,n.toDisplayString(r.description),1),r.actionButtonText?(n.openBlock(),n.createBlock(l,{key:0,class:"mt-2",onClick:t[0]||(t[0]=s=>i.actionButtonClick())},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.actionButtonText),1)]),_:1})):n.createCommentVNode("",!0)],4)}const Yne=xe(Pne,[["render",Hne]]),Qne=Object.freeze(Object.defineProperty({__proto__:null,default:Yne},Symbol.toStringTag,{value:"Module"}));let Pf=null;const Wne={tagName:"l-image-viewer",name:"LImageViewer",props:["images","index"],data:function(){return{selected:0,cards:[],scale:0,showCommands:!0,latestTap:0,lastMouseUp:0,lastMouseDown:0,zoomed:!1}},mounted(){Pf=document.querySelectorAll("[observer-targets]"),this.intersectionObserver=new IntersectionObserver(t=>this.onChangeVisibility(t[0]),{threshold:[.9,1]}),Pf.forEach(t=>{this.intersectionObserver.observe(t)});const e=parseInt(this.index)||0;this.cards=this.images.map((t,r)=>(t.scale=r,t)),this.scale=2-this.index,this.slideAndScale(),this.select(e)},beforeUnmount(){this.intersectionObserver.disconnect()},methods:{onChangeVisibility(e){e.isIntersecting&&(this.selected=Number(e.target.id))},toggleCommands(){let t=new Date().getTime()-this.latestTap,r=this.lastMouseUp-this.lastMouseDown;(t>700||t<0)&&r<100?this.showCommands=!this.showCommands:r>1500&&this.download(),this.latestTap=new Date().getTime()},updateMouseUp(){this.lastMouseUp=new Date().getTime()},updateMouseDown(){this.lastMouseDown=new Date().getTime()},back(){this.$emit("close",null)},download:async function(){const e=this.images[this.selected],t=window.LayersPortal;t?await t("download",{url:e.src,name:e.name}):window.open(e.src)},previous(){this.selected<=0||(document.getElementById("gallery-container").scrollTo({left:Math.abs(window.innerWidth-window.innerWidth*this.selected),behavior:"smooth"}),this.cards[0].scale<2&&this.scale++,this.lastMouseDown=0,this.slideAndScale())},next(){this.selected>=Pf.length-1||(document.getElementById("gallery-container").scrollTo({left:window.innerWidth*(this.selected+1),behavior:"smooth"}),this.cards[this.cards.length-1].scale!=2&&this.scale--,this.lastMouseDown=0,this.slideAndScale())},select(e){e>this.selected&&document.getElementById("gallery-container").scrollTo({left:window.innerWidth*e,behavior:"smooth"}),e<this.selected&&document.getElementById("gallery-container").scrollTo({left:Math.abs(window.innerWidth-window.innerWidth*(e+1)),behavior:"smooth"});const t=this.cards[e].scale;t!==2&&(this.scale-=t-2,this.slideAndScale())},slideAndScale:function(){this.cards.map((e,t)=>{e.scale=t+this.scale})}},watch:{selected:function(e,t){this.$refs.zoomer[t].reset()}}},qne={class:"image-viewer",style:{position:"relative"}},Gne={key:0},Kne=["id"],Jne=["src"],Zne={key:0,class:"web-image-selector"},Xne={class:"carousel-container"},ere=["onClick","data-scale"],tre=["alt","src"];function nre(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("v-zoomer");return n.openBlock(),n.createElementBlock("div",qne,[n.createElementVNode("div",{class:n.normalizeClass(["header",{colapsed:!e.showCommands}])},[n.createVNode(l,{circle:"",onClick:i.back,class:"header-button",icon:"uil-arrow-left"},null,8,["onClick"]),r.images.length!==1?(n.openBlock(),n.createElementBlock("div",Gne,n.toDisplayString(parseInt(e.selected)+1)+"/"+n.toDisplayString(r.images.length),1)):n.createCommentVNode("",!0),n.createVNode(l,{circle:"",onClick:i.download,class:"header-button",icon:"el-icon-download"},null,8,["onClick"])],2),n.createVNode(n.Transition,{name:"el-notification-fade"},{default:n.withCtx(()=>[e.selected>0&&e.showCommands?(n.openBlock(),n.createBlock(l,{key:0,onClick:i.previous,onTouchstart:i.previous,circle:"",icon:"uil-angle-left",class:"nav-button left"},null,8,["onClick","onTouchstart"])):n.createCommentVNode("",!0)]),_:1}),n.createVNode(n.Transition,{name:"el-notification-fade"},{default:n.withCtx(()=>[e.selected<r.images.length-1&&e.showCommands?(n.openBlock(),n.createBlock(l,{key:0,onClick:i.next,circle:"",icon:"uil-angle-right",class:"nav-button right"},null,8,["onClick"])):n.createCommentVNode("",!0)]),_:1}),n.createElementVNode("div",{class:"row scroll-container",id:"gallery-container",style:n.normalizeStyle({overflow:e.zoomed?"hidden":"auto"})},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.images,(c,u)=>(n.openBlock(),n.createElementBlock("div",{"observer-targets":"",class:"image-container",onClick:t[1]||(t[1]=(...d)=>i.toggleCommands&&i.toggleCommands(...d)),onMousedown:t[2]||(t[2]=(...d)=>i.updateMouseDown&&i.updateMouseDown(...d)),onMouseup:t[3]||(t[3]=(...d)=>i.updateMouseUp&&i.updateMouseUp(...d)),ref_for:!0,ref:`${c.id}-${u}`,id:u,key:u},[n.createVNode(s,{zoomed:e.zoomed,"onUpdate:zoomed":t[0]||(t[0]=d=>e.zoomed=d),class:"image",ref_for:!0,ref:"zoomer"},{default:n.withCtx(()=>[n.createElementVNode("img",{alt:"Box image",class:"image",src:c.src},null,8,Jne)]),_:2},1032,["zoomed"])],40,Kne))),128))],4),r.images.length?(n.openBlock(),n.createElementBlock("div",Zne,[n.createElementVNode("div",Xne,[t[4]||(t[4]=n.createElementVNode("div",{class:"fade-box left"},null,-1)),n.createElementVNode("div",{class:"carousel-inner",style:n.normalizeStyle({transform:`translateX(${this.scale*8.5}em)`})},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.cards,(c,u)=>(n.openBlock(),n.createElementBlock("div",{key:c.id,onClick:d=>i.select(u),class:n.normalizeClass(["card",{selected:u==e.selected}]),"data-scale":c.scale},[n.createElementVNode("img",{alt:c.id,src:c.src,style:{width:"100%",height:"100%","object-fit":"cover"}},null,8,tre)],10,ere))),128))],4),t[5]||(t[5]=n.createElementVNode("div",{class:"fade-box right"},null,-1))])])):n.createCommentVNode("",!0)])}const rre=xe(Wne,[["render",nre],["__scopeId","data-v-334ba796"]]),ore=Object.freeze(Object.defineProperty({__proto__:null,default:rre},Symbol.toStringTag,{value:"Module"}));const are={tagName:"l-input",name:"LInput",components:{ElInput:Gr},props:{error:{type:Boolean,default:!1},errorMessage:{type:String,default:""},noBorder:{type:Boolean,default:!1}}},ire={class:"l-input-wrapper"},lre={key:0,class:"l-input-error-message"};function sre(e,t,r,o,a,i){const l=n.resolveComponent("el-input");return n.openBlock(),n.createElementBlock("div",ire,[n.createVNode(l,n.mergeProps(e.$attrs,{class:["l-input",{"l-input-error":r.error}],"input-style":{border:r.noBorder?"none":"",boxShadow:r.noBorder?"none":""}}),n.createSlots({default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.prefix?{name:"prefix",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"prefix",{},void 0,!0)]),key:"0"}:void 0,e.$slots.suffix?{name:"suffix",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"suffix",{},void 0,!0)]),key:"1"}:void 0,e.$slots.prepend?{name:"prepend",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"prepend",{},void 0,!0)]),key:"2"}:void 0,e.$slots.append?{name:"append",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"append",{},void 0,!0)]),key:"3"}:void 0]),1040,["class","input-style"]),r.errorMessage?(n.openBlock(),n.createElementBlock("div",lre,n.toDisplayString(r.errorMessage),1)):n.createCommentVNode("",!0)])}const cre=xe(are,[["render",sre],["__scopeId","data-v-3a81ac87"]]),ure=Object.freeze(Object.defineProperty({__proto__:null,default:cre},Symbol.toStringTag,{value:"Module"}));const dre={name:"LLinearProgress",props:{color:{type:String,default:"rainbow"},background:{type:String,default:"transparent"},height:{type:Number,default:4}},methods:{getColor:Oi}};function fre(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:"l-linear-progress",style:n.normalizeStyle({height:r.height+"px"})},[n.createElementVNode("div",{class:"l-linear-progress-background",style:n.normalizeStyle({"--color":i.getColor(r.background)})},null,4),n.createElementVNode("div",{class:n.normalizeClass(["l-linear-progress-indeterminate",[r.color]]),style:n.normalizeStyle({"--color":i.getColor(r.color)})},null,6)],4)}const pre=xe(dre,[["render",fre],["__scopeId","data-v-7fdc26e5"]]),mre=Object.freeze(Object.defineProperty({__proto__:null,default:pre},Symbol.toStringTag,{value:"Module"}));const hre={name:"LNotice",props:{type:{type:String},outline:{type:Boolean,default:()=>!1},fill:{type:Boolean,default:()=>!0},showIcon:{type:Boolean,default:()=>!0},color:{type:String},icon:{type:String}},computed:{computedColor(){return this.color||this.type},computedIcon(){if(this.icon)return this.icon;if(!this.type)return null;switch(this.type){case"danger":return"uil-exclamation-circle";case"warning":return"uil-clock";case"success":return"uil-check-circle";default:throw new Error(`Unknown type ${this.type}`)}}}},gre={key:1,class:"no-icon"},vre={class:"text"};function yre(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",{style:n.normalizeStyle({"--color":i.computedColor}),class:n.normalizeClass({outline:r.outline,fill:r.fill})},[r.showIcon?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[i.computedIcon?(n.openBlock(),n.createBlock(l,{key:0},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.computedIcon),1)]),_:1})):(n.openBlock(),n.createElementBlock("span",gre))],64)):n.createCommentVNode("",!0),n.createElementVNode("span",vre,[n.renderSlot(e.$slots,"default")])],6)}const Mre=xe(hre,[["render",yre]]),bre=Object.freeze(Object.defineProperty({__proto__:null,default:Mre},Symbol.toStringTag,{value:"Module"}));const wre=n.defineComponent({name:"LPresentation",data:()=>({dialogVisible:!1}),props:{image:{type:String,required:!0},color:{type:String,default:"#FFF"},placement:{type:String,default:"bottom"},value:{type:Boolean,default:!1},isTooltip:{type:Boolean,default:!1},mode:{type:String,default:"contain",required:!1},tooltipClass:{type:String,required:!1}},emits:["update:value","close"],onMounted(){this.dialogVisible=this.value},watch:{dialogVisible(e){this.$emit("update:value",e),e||this.$emit("close")},value(e){this.dialogVisible=e,this.isTooltip&&e&&n.nextTick(this.updateTooltipArrow)}},setup(e,{emit:t}){return{updateTooltipArrow:()=>{const a=this.$refs.tooltip.popperElm;a&&a.style.setProperty("--popper-arrow",e.color)},close:()=>{t("update:value",!1),t("close")}}}}),Nre={class:"tooltip-content"},kre=["src"],xre={key:1},Cre=["src"],Ere={class:"tooltip-content"};function Tre(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("l-tooltip"),c=n.resolveComponent("l-dialog");return e.isTooltip?(n.openBlock(),n.createBlock(s,{key:0,ref:"tooltip",placement:e.placement,effect:"light",modelValue:e.dialogVisible,"onUpdate:modelValue":t[0]||(t[0]=u=>e.dialogVisible=u),manual:"",tooltipClass:`l-presentation-popper ${e.tooltipClass?e.tooltipClass:""}`},{content:n.withCtx(()=>[n.createElementVNode("div",Nre,[n.createElementVNode("div",{class:"image-container",style:n.normalizeStyle({"background-color":e.color})},[n.createElementVNode("img",{src:e.image,class:n.normalizeClass(["l-presentation-image",e.mode]),draggable:"false",alt:"Presentation"},null,10,kre),n.createVNode(l,{onClick:e.close,class:"close-button",fab:"",icon:"uil-times",size:"mini",type:"info"},null,8,["onClick"])],4),n.createElementVNode("p",null,[n.renderSlot(e.$slots,"content",{},void 0,!0)])]),n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["placement","modelValue","tooltipClass"])):(n.openBlock(),n.createElementBlock("div",xre,[n.createVNode(c,{modelValue:e.dialogVisible,"onUpdate:modelValue":t[1]||(t[1]=u=>e.dialogVisible=u),"before-close":e.close},{header:n.withCtx(()=>[n.createElementVNode("div",{class:"image-container",style:n.normalizeStyle({"background-color":e.color})},[n.createElementVNode("img",{src:e.image,class:n.normalizeClass(["l-presentation-image",e.mode]),width:"280",height:"160",draggable:"false",alt:"Presentation"},null,10,Cre)],4)]),default:n.withCtx(()=>[n.createElementVNode("div",Ere,[n.createElementVNode("p",null,[n.renderSlot(e.$slots,"content",{},void 0,!0)])])]),_:3},8,["modelValue","before-close"]),n.renderSlot(e.$slots,"default",{},void 0,!0)]))}const Dre=xe(wre,[["render",Tre],["__scopeId","data-v-3e34dd20"]]),Sre=Object.freeze(Object.defineProperty({__proto__:null,default:Dre},Symbol.toStringTag,{value:"Module"}));const _re=n.defineComponent({name:"LPromptDialog",props:{title:{type:String,required:!0},content:{type:String,default:""},buttonCloseLabel:{type:String,default:"Cancelar"},buttonConfirmLabel:{type:String,default:"Continuar"}},methods:{close(){this.$emit("close")},selectModel(){this.$emit("answer",!0)}}}),Ire={class:"prompt-dialog"},Are={key:0,style:{display:"block"},class:"mt-4"},Ore={class:"l-d-flex mt-4 prompt-buttons"};function zre(e,t,r,o,a,i){const l=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",Ire,[n.createElementVNode("h3",null,n.toDisplayString(e.title),1),e.content?(n.openBlock(),n.createElementBlock("p",Are,n.toDisplayString(e.content),1)):n.createCommentVNode("",!0),n.createElementVNode("div",Ore,[n.createVNode(l,{onClick:e.close,type:"primary",plain:"",class:"bold my-0 ml-0 mr-2 dialog-button decline-button-dialog"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.buttonCloseLabel),1)]),_:1},8,["onClick"]),n.createVNode(l,{onClick:e.selectModel,type:"primary",class:"bold m-0 dialog-button confirm-button-dialog"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.buttonConfirmLabel),1)]),_:1},8,["onClick"])])])}const Th=xe(_re,[["render",zre],["__scopeId","data-v-75693735"]]),jre=Object.freeze(Object.defineProperty({__proto__:null,default:Th},Symbol.toStringTag,{value:"Module"}));const Lre=n.defineComponent({name:"LRadio",components:{ElRadio:qW}});function Bre(e,t,r,o,a,i){const l=n.resolveComponent("ElRadio");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-radio"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Vre=xe(Lre,[["render",Bre],["__scopeId","data-v-7560e4a6"]]),$re=Object.freeze(Object.defineProperty({__proto__:null,default:Vre},Symbol.toStringTag,{value:"Module"}));const Pre=n.defineComponent({name:"LRadiobutton",components:{ElRadioButton:KW}});function Rre(e,t,r,o,a,i){const l=n.resolveComponent("ElRadioButton");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-radio-button"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const Fre=xe(Pre,[["render",Rre],["__scopeId","data-v-85dba2ee"]]),Ure=Object.freeze(Object.defineProperty({__proto__:null,default:Fre},Symbol.toStringTag,{value:"Module"}));const Hre=n.defineComponent({name:"LRadioGroup",components:{RadioGroup:GW},props:{separated:{type:Boolean,default:!1},color:{type:String,default:"primary"}},computed:{fill(){return W3(this.color)}},onMounted(){if(this.separated){const e=this.$refs.radioGroup.$el;e.classList.add("l-radio-group-separated"),e.children&&e.children.length&&Array.from(e.children).forEach(t=>t.classList.add("l-radio-button-separated"))}}});function Yre(e,t,r,o,a,i){const l=n.resolveComponent("RadioGroup");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:[{"l-radio-group-separated":e.separated},"l-radio-group"],ref:"radioGroup",fill:e.fill}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["class","fill"])}const Qre=xe(Hre,[["render",Yre],["__scopeId","data-v-9ec95acb"]]),Wre=Object.freeze(Object.defineProperty({__proto__:null,default:Qre},Symbol.toStringTag,{value:"Module"}));const qre={name:"l-rating",components:{ElRate:jZ},props:{colors:{type:Array,default:()=>["#99A9BF","#F7BA2A","#FF9900"]},allowHalf:{type:Boolean,default:!1}}};function Gre(e,t,r,o,a,i){const l=n.resolveComponent("el-rate");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{colors:r.colors,"allow-half":r.allowHalf}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["colors","allow-half"])}const Kre=xe(qre,[["render",Gre]]),Jre=Object.freeze(Object.defineProperty({__proto__:null,default:Kre},Symbol.toStringTag,{value:"Module"}));var Zre=rl,Xre=ko,eoe="[object Symbol]";function toe(e){return typeof e=="symbol"||Xre(e)&&Zre(e)==eoe}var Jd=toe,noe=vr,roe=Jd,ooe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,aoe=/^\w*$/;function ioe(e,t){if(noe(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||roe(e)?!0:aoe.test(e)||!ooe.test(e)||t!=null&&e in Object(t)}var Dh=ioe,Lb=im,loe="Expected a function";function Sh(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(loe);var r=function(){var o=arguments,a=t?t.apply(this,o):o[0],i=r.cache;if(i.has(a))return i.get(a);var l=e.apply(this,o);return r.cache=i.set(a,l)||i,l};return r.cache=new(Sh.Cache||Lb),r}Sh.Cache=Lb;var soe=Sh,coe=soe,uoe=500;function doe(e){var t=coe(e,function(o){return r.size===uoe&&r.clear(),o}),r=t.cache;return t}var foe=doe,poe=foe,moe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,hoe=/\\(\\)?/g,goe=poe(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(moe,function(r,o,a,i){t.push(a?i.replace(hoe,"$1"):o||r)}),t}),voe=goe;function yoe(e,t){for(var r=-1,o=e==null?0:e.length,a=Array(o);++r<o;)a[r]=t(e[r],r,e);return a}var Bb=yoe,Rg=nl,Moe=Bb,boe=vr,woe=Jd,Noe=1/0,Fg=Rg?Rg.prototype:void 0,Ug=Fg?Fg.toString:void 0;function Vb(e){if(typeof e=="string")return e;if(boe(e))return Moe(e,Vb)+"";if(woe(e))return Ug?Ug.call(e):"";var t=e+"";return t=="0"&&1/e==-Noe?"-0":t}var koe=Vb,xoe=koe;function Coe(e){return e==null?"":xoe(e)}var Eoe=Coe,Toe=vr,Doe=Dh,Soe=voe,_oe=Eoe;function Ioe(e,t){return Toe(e)?e:Doe(e,t)?[e]:Soe(_oe(e))}var $b=Ioe,Aoe=Jd,Ooe=1/0;function zoe(e){if(typeof e=="string"||Aoe(e))return e;var t=e+"";return t=="0"&&1/e==-Ooe?"-0":t}var Zd=zoe,joe=$b,Loe=Zd;function Boe(e,t){t=joe(t,e);for(var r=0,o=t.length;e!=null&&r<o;)e=e[Loe(t[r++])];return r&&r==o?e:void 0}var Pb=Boe,Voe=Pb;function $oe(e,t,r){var o=e==null?void 0:Voe(e,t);return o===void 0?r:o}var Rb=$oe;const Dt=St(Rb);function Poe(e,t){for(var r=-1,o=e==null?0:e.length;++r<o&&t(e[r],r,e)!==!1;);return e}var Roe=Poe,Foe=uy,Uoe=Foe(Object.keys,Object),Hoe=Uoe,Yoe=um,Qoe=Hoe,Woe=Object.prototype,qoe=Woe.hasOwnProperty;function Goe(e){if(!Yoe(e))return Qoe(e);var t=[];for(var r in Object(e))qoe.call(e,r)&&r!="constructor"&&t.push(r);return t}var Koe=Goe,Joe=vy,Zoe=Koe,Xoe=ll;function eae(e){return Xoe(e)?Joe(e):Zoe(e)}var Ja=eae;const tae=St(Ja);var nae=$s,rae=Ja;function oae(e,t){return e&&nae(t,rae(t),e)}var aae=oae,iae=$s,lae=Ps;function sae(e,t){return e&&iae(t,lae(t),e)}var cae=sae;function uae(e,t){for(var r=-1,o=e==null?0:e.length,a=0,i=[];++r<o;){var l=e[r];t(l,r,e)&&(i[a++]=l)}return i}var Fb=uae;function dae(){return[]}var Ub=dae,fae=Fb,pae=Ub,mae=Object.prototype,hae=mae.propertyIsEnumerable,Hg=Object.getOwnPropertySymbols,gae=Hg?function(e){return e==null?[]:(e=Object(e),fae(Hg(e),function(t){return hae.call(e,t)}))}:pae,_h=gae,vae=$s,yae=_h;function Mae(e,t){return vae(e,yae(e),t)}var bae=Mae;function wae(e,t){for(var r=-1,o=t.length,a=e.length;++r<o;)e[a+r]=t[r];return e}var Ih=wae,Nae=Ih,kae=cm,xae=_h,Cae=Ub,Eae=Object.getOwnPropertySymbols,Tae=Eae?function(e){for(var t=[];e;)Nae(t,xae(e)),e=kae(e);return t}:Cae,Hb=Tae,Dae=$s,Sae=Hb;function _ae(e,t){return Dae(e,Sae(e),t)}var Iae=_ae,Aae=Ih,Oae=vr;function zae(e,t,r){var o=t(e);return Oae(e)?o:Aae(o,r(e))}var Yb=zae,jae=Yb,Lae=_h,Bae=Ja;function Vae(e){return jae(e,Bae,Lae)}var Qb=Vae,$ae=Yb,Pae=Hb,Rae=Ps;function Fae(e){return $ae(e,Rae,Pae)}var Uae=Fae,Hae=Ha,Yae=jr,Qae=Hae(Yae,"DataView"),Wae=Qae,qae=Ha,Gae=jr,Kae=qae(Gae,"Promise"),Jae=Kae,Zae=Ha,Xae=jr,eie=Zae(Xae,"Set"),Wb=eie,tie=Ha,nie=jr,rie=tie(nie,"WeakMap"),oie=rie,f0=Wae,p0=am,m0=Jae,h0=Wb,g0=oie,qb=rl,pl=ny,Yg="[object Map]",aie="[object Object]",Qg="[object Promise]",Wg="[object Set]",qg="[object WeakMap]",Gg="[object DataView]",iie=pl(f0),lie=pl(p0),sie=pl(m0),cie=pl(h0),uie=pl(g0),va=qb;(f0&&va(new f0(new ArrayBuffer(1)))!=Gg||p0&&va(new p0)!=Yg||m0&&va(m0.resolve())!=Qg||h0&&va(new h0)!=Wg||g0&&va(new g0)!=qg)&&(va=function(e){var t=qb(e),r=t==aie?e.constructor:void 0,o=r?pl(r):"";if(o)switch(o){case iie:return Gg;case lie:return Yg;case sie:return Qg;case cie:return Wg;case uie:return qg}return t});var Xd=va,die=Object.prototype,fie=die.hasOwnProperty;function pie(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&fie.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var mie=pie,hie=sm;function gie(e,t){var r=t?hie(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var vie=gie,yie=/\w*$/;function Mie(e){var t=new e.constructor(e.source,yie.exec(e));return t.lastIndex=e.lastIndex,t}var bie=Mie,Kg=nl,Jg=Kg?Kg.prototype:void 0,Zg=Jg?Jg.valueOf:void 0;function wie(e){return Zg?Object(Zg.call(e)):{}}var Nie=wie,kie=sm,xie=vie,Cie=bie,Eie=Nie,Tie=sy,Die="[object Boolean]",Sie="[object Date]",_ie="[object Map]",Iie="[object Number]",Aie="[object RegExp]",Oie="[object Set]",zie="[object String]",jie="[object Symbol]",Lie="[object ArrayBuffer]",Bie="[object DataView]",Vie="[object Float32Array]",$ie="[object Float64Array]",Pie="[object Int8Array]",Rie="[object Int16Array]",Fie="[object Int32Array]",Uie="[object Uint8Array]",Hie="[object Uint8ClampedArray]",Yie="[object Uint16Array]",Qie="[object Uint32Array]";function Wie(e,t,r){var o=e.constructor;switch(t){case Lie:return kie(e);case Die:case Sie:return new o(+e);case Bie:return xie(e,r);case Vie:case $ie:case Pie:case Rie:case Fie:case Uie:case Hie:case Yie:case Qie:return Tie(e,r);case _ie:return new o;case Iie:case zie:return new o(e);case Aie:return Cie(e);case Oie:return new o;case jie:return Eie(e)}}var qie=Wie,Gie=Xd,Kie=ko,Jie="[object Map]";function Zie(e){return Kie(e)&&Gie(e)==Jie}var Xie=Zie,ele=Xie,tle=_d,Xg=fm,e4=Xg&&Xg.isMap,nle=e4?tle(e4):ele,rle=nle,ole=Xd,ale=ko,ile="[object Set]";function lle(e){return ale(e)&&ole(e)==ile}var sle=lle,cle=sle,ule=_d,t4=fm,n4=t4&&t4.isSet,dle=n4?ule(n4):cle,fle=dle,ple=Td,mle=Roe,hle=gy,gle=aae,vle=cae,yle=iy,Mle=cy,ble=bae,wle=Iae,Nle=Qb,kle=Uae,xle=Xd,Cle=mie,Ele=qie,Tle=dy,Dle=vr,Sle=Sd,_le=rle,Ile=Lr,Ale=fle,Ole=Ja,zle=Ps,jle=1,Lle=2,Ble=4,Gb="[object Arguments]",Vle="[object Array]",$le="[object Boolean]",Ple="[object Date]",Rle="[object Error]",Kb="[object Function]",Fle="[object GeneratorFunction]",Ule="[object Map]",Hle="[object Number]",Jb="[object Object]",Yle="[object RegExp]",Qle="[object Set]",Wle="[object String]",qle="[object Symbol]",Gle="[object WeakMap]",Kle="[object ArrayBuffer]",Jle="[object DataView]",Zle="[object Float32Array]",Xle="[object Float64Array]",ese="[object Int8Array]",tse="[object Int16Array]",nse="[object Int32Array]",rse="[object Uint8Array]",ose="[object Uint8ClampedArray]",ase="[object Uint16Array]",ise="[object Uint32Array]",Mt={};Mt[Gb]=Mt[Vle]=Mt[Kle]=Mt[Jle]=Mt[$le]=Mt[Ple]=Mt[Zle]=Mt[Xle]=Mt[ese]=Mt[tse]=Mt[nse]=Mt[Ule]=Mt[Hle]=Mt[Jb]=Mt[Yle]=Mt[Qle]=Mt[Wle]=Mt[qle]=Mt[rse]=Mt[ose]=Mt[ase]=Mt[ise]=!0;Mt[Rle]=Mt[Kb]=Mt[Gle]=!1;function Yc(e,t,r,o,a,i){var l,s=t&jle,c=t&Lle,u=t&Ble;if(r&&(l=a?r(e,o,a,i):r(e)),l!==void 0)return l;if(!Ile(e))return e;var d=Dle(e);if(d){if(l=Cle(e),!s)return Mle(e,l)}else{var f=xle(e),p=f==Kb||f==Fle;if(Sle(e))return yle(e,s);if(f==Jb||f==Gb||p&&!a){if(l=c||p?{}:Tle(e),!s)return c?wle(e,vle(l,e)):ble(e,gle(l,e))}else{if(!Mt[f])return a?e:{};l=Ele(e,f,s)}}i||(i=new ple);var h=i.get(e);if(h)return h;i.set(e,l),Ale(e)?e.forEach(function(v){l.add(Yc(v,t,r,v,e,i))}):_le(e)&&e.forEach(function(v,y){l.set(y,Yc(v,t,r,y,e,i))});var m=u?c?kle:Nle:c?zle:Ole,g=d?void 0:m(e);return mle(g||e,function(v,y){g&&(y=v,v=e[y]),hle(l,y,Yc(v,t,r,y,e,i))}),l}var lse=Yc,sse=lse,cse=1,use=4;function dse(e){return sse(e,cse|use)}var fse=dse;const $n=St(fse);var pse="__lodash_hash_undefined__";function mse(e){return this.__data__.set(e,pse),this}var hse=mse;function gse(e){return this.__data__.has(e)}var vse=gse,yse=im,Mse=hse,bse=vse;function Cu(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new yse;++t<r;)this.add(e[t])}Cu.prototype.add=Cu.prototype.push=Mse;Cu.prototype.has=bse;var Ah=Cu;function wse(e,t){for(var r=-1,o=e==null?0:e.length;++r<o;)if(t(e[r],r,e))return!0;return!1}var Nse=wse;function kse(e,t){return e.has(t)}var Oh=kse,xse=Ah,Cse=Nse,Ese=Oh,Tse=1,Dse=2;function Sse(e,t,r,o,a,i){var l=r&Tse,s=e.length,c=t.length;if(s!=c&&!(l&&c>s))return!1;var u=i.get(e),d=i.get(t);if(u&&d)return u==t&&d==e;var f=-1,p=!0,h=r&Dse?new xse:void 0;for(i.set(e,t),i.set(t,e);++f<s;){var m=e[f],g=t[f];if(o)var v=l?o(g,m,f,t,e,i):o(m,g,f,e,t,i);if(v!==void 0){if(v)continue;p=!1;break}if(h){if(!Cse(t,function(y,N){if(!Ese(h,N)&&(m===y||a(m,y,r,o,i)))return h.push(N)})){p=!1;break}}else if(!(m===g||a(m,g,r,o,i))){p=!1;break}}return i.delete(e),i.delete(t),p}var Zb=Sse;function _se(e){var t=-1,r=Array(e.size);return e.forEach(function(o,a){r[++t]=[a,o]}),r}var Ise=_se;function Ase(e){var t=-1,r=Array(e.size);return e.forEach(function(o){r[++t]=o}),r}var zh=Ase,r4=nl,o4=ly,Ose=Vs,zse=Zb,jse=Ise,Lse=zh,Bse=1,Vse=2,$se="[object Boolean]",Pse="[object Date]",Rse="[object Error]",Fse="[object Map]",Use="[object Number]",Hse="[object RegExp]",Yse="[object Set]",Qse="[object String]",Wse="[object Symbol]",qse="[object ArrayBuffer]",Gse="[object DataView]",a4=r4?r4.prototype:void 0,Rf=a4?a4.valueOf:void 0;function Kse(e,t,r,o,a,i,l){switch(r){case Gse:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case qse:return!(e.byteLength!=t.byteLength||!i(new o4(e),new o4(t)));case $se:case Pse:case Use:return Ose(+e,+t);case Rse:return e.name==t.name&&e.message==t.message;case Hse:case Qse:return e==t+"";case Fse:var s=jse;case Yse:var c=o&Bse;if(s||(s=Lse),e.size!=t.size&&!c)return!1;var u=l.get(e);if(u)return u==t;o|=Vse,l.set(e,t);var d=zse(s(e),s(t),o,a,i,l);return l.delete(e),d;case Wse:if(Rf)return Rf.call(e)==Rf.call(t)}return!1}var Jse=Kse,i4=Qb,Zse=1,Xse=Object.prototype,ece=Xse.hasOwnProperty;function tce(e,t,r,o,a,i){var l=r&Zse,s=i4(e),c=s.length,u=i4(t),d=u.length;if(c!=d&&!l)return!1;for(var f=c;f--;){var p=s[f];if(!(l?p in t:ece.call(t,p)))return!1}var h=i.get(e),m=i.get(t);if(h&&m)return h==t&&m==e;var g=!0;i.set(e,t),i.set(t,e);for(var v=l;++f<c;){p=s[f];var y=e[p],N=t[p];if(o)var b=l?o(N,y,p,t,e,i):o(y,N,p,e,t,i);if(!(b===void 0?y===N||a(y,N,r,o,i):b)){g=!1;break}v||(v=p=="constructor")}if(g&&!v){var M=e.constructor,k=t.constructor;M!=k&&"constructor"in e&&"constructor"in t&&!(typeof M=="function"&&M instanceof M&&typeof k=="function"&&k instanceof k)&&(g=!1)}return i.delete(e),i.delete(t),g}var nce=tce,Ff=Td,rce=Zb,oce=Jse,ace=nce,l4=Xd,s4=vr,c4=Sd,ice=pm,lce=1,u4="[object Arguments]",d4="[object Array]",wc="[object Object]",sce=Object.prototype,f4=sce.hasOwnProperty;function cce(e,t,r,o,a,i){var l=s4(e),s=s4(t),c=l?d4:l4(e),u=s?d4:l4(t);c=c==u4?wc:c,u=u==u4?wc:u;var d=c==wc,f=u==wc,p=c==u;if(p&&c4(e)){if(!c4(t))return!1;l=!0,d=!1}if(p&&!d)return i||(i=new Ff),l||ice(e)?rce(e,t,r,o,a,i):oce(e,t,c,r,o,a,i);if(!(r&lce)){var h=d&&f4.call(e,"__wrapped__"),m=f&&f4.call(t,"__wrapped__");if(h||m){var g=h?e.value():e,v=m?t.value():t;return i||(i=new Ff),a(g,v,r,o,i)}}return p?(i||(i=new Ff),ace(e,t,r,o,a,i)):!1}var uce=cce,dce=uce,p4=ko;function Xb(e,t,r,o,a){return e===t?!0:e==null||t==null||!p4(e)&&!p4(t)?e!==e&&t!==t:dce(e,t,r,o,Xb,a)}var jh=Xb,fce=jh;function pce(e,t){return fce(e,t)}var mce=pce;const hce=St(mce);function gce(e,t,r,o){for(var a=e.length,i=r+(o?1:-1);o?i--:++i<a;)if(t(e[i],i,e))return i;return-1}var e8=gce,vce=Td,yce=jh,Mce=1,bce=2;function wce(e,t,r,o){var a=r.length,i=a,l=!o;if(e==null)return!i;for(e=Object(e);a--;){var s=r[a];if(l&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<i;){s=r[a];var c=s[0],u=e[c],d=s[1];if(l&&s[2]){if(u===void 0&&!(c in e))return!1}else{var f=new vce;if(o)var p=o(u,d,c,e,t,f);if(!(p===void 0?yce(d,u,Mce|bce,o,f):p))return!1}}return!0}var Nce=wce,kce=Lr;function xce(e){return e===e&&!kce(e)}var t8=xce,Cce=t8,Ece=Ja;function Tce(e){for(var t=Ece(e),r=t.length;r--;){var o=t[r],a=e[o];t[r]=[o,a,Cce(a)]}return t}var Dce=Tce;function Sce(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}var n8=Sce,_ce=Nce,Ice=Dce,Ace=n8;function Oce(e){var t=Ice(e);return t.length==1&&t[0][2]?Ace(t[0][0],t[0][1]):function(r){return r===e||_ce(r,e,t)}}var zce=Oce;function jce(e,t){return e!=null&&t in Object(e)}var Lce=jce,Bce=$b,Vce=Dd,$ce=vr,Pce=mm,Rce=dm,Fce=Zd;function Uce(e,t,r){t=Bce(t,e);for(var o=-1,a=t.length,i=!1;++o<a;){var l=Fce(t[o]);if(!(i=e!=null&&r(e,l)))break;e=e[l]}return i||++o!=a?i:(a=e==null?0:e.length,!!a&&Rce(a)&&Pce(l,a)&&($ce(e)||Vce(e)))}var Hce=Uce,Yce=Lce,Qce=Hce;function Wce(e,t){return e!=null&&Qce(e,t,Yce)}var qce=Wce,Gce=jh,Kce=Rb,Jce=qce,Zce=Dh,Xce=t8,eue=n8,tue=Zd,nue=1,rue=2;function oue(e,t){return Zce(e)&&Xce(t)?eue(tue(e),t):function(r){var o=Kce(r,e);return o===void 0&&o===t?Jce(r,e):Gce(t,o,nue|rue)}}var aue=oue;function iue(e){return function(t){return t==null?void 0:t[e]}}var lue=iue,sue=Pb;function cue(e){return function(t){return sue(t,e)}}var uue=cue,due=lue,fue=uue,pue=Dh,mue=Zd;function hue(e){return pue(e)?due(mue(e)):fue(e)}var gue=hue,vue=zce,yue=aue,Mue=hm,bue=vr,wue=gue;function Nue(e){return typeof e=="function"?e:e==null?Mue:typeof e=="object"?bue(e)?yue(e[0],e[1]):vue(e):wue(e)}var Lh=Nue,kue=/\s/;function xue(e){for(var t=e.length;t--&&kue.test(e.charAt(t)););return t}var Cue=xue,Eue=Cue,Tue=/^\s+/;function Due(e){return e&&e.slice(0,Eue(e)+1).replace(Tue,"")}var Sue=Due,_ue=Sue,m4=Lr,Iue=Jd,h4=0/0,Aue=/^[-+]0x[0-9a-f]+$/i,Oue=/^0b[01]+$/i,zue=/^0o[0-7]+$/i,jue=parseInt;function Lue(e){if(typeof e=="number")return e;if(Iue(e))return h4;if(m4(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=m4(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=_ue(e);var r=Oue.test(e);return r||zue.test(e)?jue(e.slice(2),r?2:8):Aue.test(e)?h4:+e}var r8=Lue,Bue=r8,g4=1/0,Vue=17976931348623157e292;function $ue(e){if(!e)return e===0?e:0;if(e=Bue(e),e===g4||e===-g4){var t=e<0?-1:1;return t*Vue}return e===e?e:0}var Pue=$ue,Rue=Pue;function Fue(e){var t=Rue(e),r=t%1;return t===t?r?t-r:t:0}var Uue=Fue,Hue=e8,Yue=Lh,Que=Uue,Wue=Math.max;function que(e,t,r){var o=e==null?0:e.length;if(!o)return-1;var a=r==null?0:Que(r);return a<0&&(a=Wue(o+a,0)),Hue(e,Yue(t),a)}var o8=que;const v4=St(o8);var Gue=Lh,Kue=ll,Jue=Ja;function Zue(e){return function(t,r,o){var a=Object(t);if(!Kue(t)){var i=Gue(r);t=Jue(t),r=function(s){return i(a[s],s,a)}}var l=e(t,r,o);return l>-1?a[i?t[l]:l]:void 0}}var Xue=Zue,ede=Xue,tde=o8,nde=ede(tde),rde=nde;const ode=St(rde);var ade=ay,ide=Ja;function lde(e,t){return e&&ade(e,t,ide)}var sde=lde,cde=ll;function ude(e,t){return function(r,o){if(r==null)return r;if(!cde(r))return e(r,o);for(var a=r.length,i=t?a:-1,l=Object(r);(t?i--:++i<a)&&o(l[i],i,l)!==!1;);return r}}var dde=ude,fde=sde,pde=dde,mde=pde(fde),hde=mde,gde=hde;function vde(e,t){var r=[];return gde(e,function(o,a,i){t(o,a,i)&&r.push(o)}),r}var yde=vde,Mde=Fb,bde=yde,wde=Lh,Nde=vr;function kde(e,t){var r=Nde(e)?Mde:bde;return r(e,wde(t))}var xde=kde;const a8=St(xde);const Cde={name:"AddFilterButton",props:{schema:Object,filters:Array,lang:{type:String,default(){return pn()}}},methods:{addFilter(e){const t={path:e.path,value:null,comparison:null,valid:!1};this.$emit("addFilter",t)},hasFilterFor(e){return ode(this.filters,{path:e})}},computed:{availableOptions(){var e,t;return(t=(e=this.schema)==null?void 0:e.fields)!=null&&t.length?a8(this.schema.fields,r=>r.filterable&&!this.hasFilterFor(r.path)):[]}}};function Ede(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button"),c=n.resolveComponent("l-dropdown-item"),u=n.resolveComponent("l-tooltip"),d=n.resolveComponent("l-dropdown-menu"),f=n.resolveComponent("l-dropdown");return n.openBlock(),n.createBlock(f,{trigger:"click",placement:"bottom-start",onCommand:i.addFilter},{default:n.withCtx(()=>[n.withDirectives(n.createVNode(s,{class:"add-filter-button",round:"",plain:"",size:"small"},{default:n.withCtx(()=>[n.createVNode(l,{style:{"margin-right":"4px"}},{default:n.withCtx(()=>t[0]||(t[0]=[n.createTextVNode("uil-plus")])),_:1}),n.createTextVNode(n.toDisplayString(e.$tds("add-filter",r.lang)),1)]),_:1},512),[[n.vShow,i.availableOptions.length>0]])]),dropdown:n.withCtx(()=>[n.createVNode(d,null,{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.availableOptions,p=>(n.openBlock(),n.createBlock(u,{key:p.title,disabled:!p.description,content:p.description,effect:"light","open-delay":600,placement:"right-start"},{default:n.withCtx(()=>[n.createVNode(c,{command:p,disabled:i.hasFilterFor(p.path)},{default:n.withCtx(()=>[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(p)),1)]),_:2},1024),n.createTextVNode(" "+n.toDisplayString(p.title),1)]),_:2},1032,["command","disabled"])]),_:2},1032,["disabled","content"]))),128))]),_:1})]),_:1},8,["onCommand"])}const Tde=xe(Cde,[["render",Ede]]);const Dde={props:{filter:Object,schema:Object},emits:["update:filter","change","cancel"],data(){return Dt(this.schema,"options.enum")?{form:{value:this.filter.value||[],comparison:this.filter.comparison||"in"}}:{form:{value:this.filter.value,comparison:this.filter.comparison||"contains"}}},watch:{"form.comparison":{handler(){this.$nextTick(()=>this.focus())}}},methods:{focus(){this.$refs.valueInput&&this.$refs.valueInput[0].$el.focus()},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};console.log("newFilter",t),this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{valuesEnum(){return Dt(this.schema,"options.enum")},inlineComponent(){try{return this.$L.FieldTypeComponents.get(this.schema,"default")}catch{return null}},comparisons(){return[{label:this.$tds("contains"),value:"contains"},{label:this.$tds("starts-at"),value:"starts_with"},{label:this.$tds("ends-at"),value:"ends_with"},{label:this.$tds("exactly"),value:"eq"},{label:this.$tds("not-equal"),value:"neq"}]},rules(){return{value:[{required:!0,message:`${this.$tds("type-to-filter")} ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`${this.$tds("choose-a-mode-to-filter")} ${this.schema.title}`,trigger:"change"}]}}}},Sde=["textContent"];function _de(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox"),s=n.resolveComponent("l-checkbox-group"),c=n.resolveComponent("l-form-item"),u=n.resolveComponent("l-radio"),d=n.resolveComponent("l-input"),f=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(f,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[3]||(t[3]=n.withModifiers(()=>{},["prevent"])),class:"item-wrapper"},{default:n.withCtx(()=>[i.valuesEnum?(n.openBlock(),n.createBlock(c,{key:0,prop:"value"},{default:n.withCtx(()=>[n.createVNode(s,{modelValue:a.form.value,"onUpdate:modelValue":t[0]||(t[0]=p=>a.form.value=p),style:{display:"flex","flex-direction":"column"}},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.valuesEnum,p=>(n.openBlock(),n.createBlock(l,{label:p,value:p,key:p},{default:n.withCtx(()=>[i.inlineComponent?(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.inlineComponent),{key:0,value:p,schema:r.schema},null,8,["value","schema"])):(n.openBlock(),n.createElementBlock("span",{key:1,textContent:n.toDisplayString(p)},null,8,Sde))]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})):(n.openBlock(),n.createBlock(c,{key:1,prop:"comparison"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.comparisons,p=>(n.openBlock(),n.createElementBlock("div",{key:p.value},[n.createVNode(u,{modelValue:a.form.comparison,"onUpdate:modelValue":t[1]||(t[1]=h=>a.form.comparison=h),label:p.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(p.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison===p.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createVNode(d,{ref_for:!0,ref:"valueInput",modelValue:a.form.value,"onUpdate:modelValue":t[2]||(t[2]=h=>a.form.value=h)},null,8,["modelValue"])]),_:1})):n.createCommentVNode("",!0)]))),128))]),_:1}))]),_:1},8,["model","rules"])}const Ide=xe(Dde,[["render",_de],["__scopeId","data-v-4a82d0be"]]);/*!
|
|
36
36
|
* currency.js - v1.2.2
|
|
37
37
|
* http://scurker.github.io/currency.js
|
|
38
38
|
*
|
|
39
39
|
* Copyright (c) 2019 Jason Wilson
|
|
40
40
|
* Released under MIT license
|
|
41
|
-
*/var Dde={symbol:"$",separator:",",decimal:".",formatWithSymbol:!1,errorOnInvalid:!1,precision:2,pattern:"!#",negativePattern:"-!#"},i8=function(t){return Math.round(t)},Bh=function(t){return Math.pow(10,t)},Sde=function(t,r){return i8(t/r)*r},_de=/(\d)(?=(\d{3})+\b)/g,Ide=/(\d)(?=(\d\d)+\d\b)/g;function Wr(e,t){var r=this;if(!(r instanceof Wr))return new Wr(e,t);var o=Object.assign({},Dde,t),a=Bh(o.precision),i=Qc(e,o);r.intValue=i,r.value=i/a,o.increment=o.increment||1/a,o.useVedic?o.groups=Ide:o.groups=_de,this.s=o,this.p=a}function Qc(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=0,a=t.decimal,i=t.errorOnInvalid,l=t.precision,s=Bh(l),c=typeof e=="number";if(c||e instanceof Wr)o=(c?e:e.value)*s;else if(typeof e=="string"){var u=new RegExp("[^-\\d"+a+"]","g"),d=new RegExp("\\"+a,"g");o=e.replace(/\((.*)\)/,"-$1").replace(u,"").replace(d,".")*s,o=o||0}else{if(i)throw Error("Invalid Input");o=0}return o=o.toFixed(4),r?i8(o):o}Wr.prototype={add:function(t){var r=this.intValue,o=this.s,a=this.p;return Wr((r+=Qc(t,o))/a,o)},subtract:function(t){var r=this.intValue,o=this.s,a=this.p;return Wr((r-=Qc(t,o))/a,o)},multiply:function(t){var r=this.intValue,o=this.s;return Wr((r*=t)/Bh(o.precision),o)},divide:function(t){var r=this.intValue,o=this.s;return Wr(r/=Qc(t,o,!1),o)},distribute:function(t){for(var r=this.intValue,o=this.p,a=this.s,i=[],l=Math[r>=0?"floor":"ceil"](r/t),s=Math.abs(r-l*t);t!==0;t--){var c=Wr(l/o,a);s-- >0&&(c=r>=0?c.add(1/o):c.subtract(1/o)),i.push(c)}return i},dollars:function(){return~~this.value},cents:function(){var t=this.intValue,r=this.p;return~~(t%r)},format:function(t){var r=this.s,o=r.pattern,a=r.negativePattern,i=r.formatWithSymbol,l=r.symbol,s=r.separator,c=r.decimal,u=r.groups,d=(this+"").replace(/^-/,"").split("."),f=d[0],p=d[1];return typeof t>"u"&&(t=i),(this.value>=0?o:a).replace("!",t?l:"").replace("#","".concat(f.replace(u,"$1"+s)).concat(p?c+p:""))},toString:function(){var t=this.intValue,r=this.p,o=this.s;return Sde(t/r,o.increment).toFixed(o.precision)},toJSON:function(){return this.value}};const Ade={props:["filter","schema"],emits:["update:filter","change","cancel"],data(){return{form:{value:this.filter.value,comparison:this.filter.comparison||"gt"},inputValue:this.formatValue(this.filter.value)}},methods:{focus(){this.$refs.valueInput.focus()},formatValue(e){return e?(e/100).toFixed(2).replace(".",","):"0,00"},getAmount(e){return e?Wr(e,{decimal:","}).intValue:0},changeInput(){this.form.value=this.getAmount(this.inputValue),this.inputValue=this.formatValue(this.form.value)},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{rules(){return{value:[{required:!0,message:`Digite para filtrar ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`Escolha um modo para filtrar ${this.schema.title}`,trigger:"change"}]}}}};function Ode(e,t,r,o,a,i){const l=n.resolveComponent("el-input"),s=n.resolveComponent("l-form-item"),c=n.resolveComponent("l-radio"),u=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(u,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[6]||(t[6]=n.withModifiers(()=>{},["prevent"])),class:"form-wrapper"},{default:n.withCtx(()=>[n.createVNode(s,{prop:"value"},{default:n.withCtx(()=>[n.createVNode(l,{ref:"valueInput",modelValue:a.inputValue,"onUpdate:modelValue":t[0]||(t[0]=d=>a.inputValue=d),size:"small",onChange:i.changeInput},{default:n.withCtx(()=>t[7]||(t[7]=[n.createElementVNode("template",{slot:"prepend"},[n.createTextVNode("R$")],-1)])),_:1},8,["modelValue","onChange"])]),_:1}),n.createVNode(s,{prop:"comparison"},{default:n.withCtx(()=>[n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[1]||(t[1]=d=>a.form.comparison=d),label:"gt"},{default:n.withCtx(()=>t[8]||(t[8]=[n.createTextVNode("Maior que")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[2]||(t[2]=d=>a.form.comparison=d),label:"gte"},{default:n.withCtx(()=>t[9]||(t[9]=[n.createTextVNode("Maior que ou igual a")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[3]||(t[3]=d=>a.form.comparison=d),label:"eq"},{default:n.withCtx(()=>t[10]||(t[10]=[n.createTextVNode("Igual a")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[4]||(t[4]=d=>a.form.comparison=d),label:"lt"},{default:n.withCtx(()=>t[11]||(t[11]=[n.createTextVNode("Menor que")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[5]||(t[5]=d=>a.form.comparison=d),label:"lte"},{default:n.withCtx(()=>t[12]||(t[12]=[n.createTextVNode("Menor que ou igual a")])),_:1},8,["modelValue"])]),_:1})]),_:1},8,["model","rules"])}const zde=xe(Ade,[["render",Ode],["__scopeId","data-v-ec3d17bd"]]);const jde={props:["filter","schema"],emits:["update:filter","change","cancel"],data(){return Dt(this.schema,"options.enum")?{form:{value:this.filter.value||[],comparison:this.filter.comparison||"in"}}:{form:{value:this.filter.value,comparison:this.filter.comparison||"gte"}}},watch:{"form.comparison":{handler(){this.$nextTick(()=>this.focus())}}},methods:{focus(){this.$refs.valueInput&&this.$refs.valueInput[0].$el.focus()},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{valuesEnum(){return Dt(this.schema,"options.enum")},inlineComponent(){try{return this.$L.FieldTypeComponents.get(this.schema,"default")}catch{return null}},comparisons(){return[{label:this.$tds("less-than"),value:"lt"},{label:this.$tds("less-or-equal"),value:"lte"},{label:this.$tds("greater-than"),value:"gt"},{label:this.$tds("greater-or-equal"),value:"gte"},{label:this.$tds("equal"),value:"eq"},{label:this.$tds("different"),value:"neq"}]},rules(){return{value:[{required:!0,message:`${this.$tds("type-to-filter")} ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`${this.$tds("choose-a-mode-to-filter")} ${this.schema.title}`,trigger:"change"}]}}}},Lde=["textContent"];function Bde(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox"),s=n.resolveComponent("l-checkbox-group"),c=n.resolveComponent("l-form-item"),u=n.resolveComponent("l-radio"),d=n.resolveComponent("l-input"),f=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(f,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[3]||(t[3]=n.withModifiers(()=>{},["prevent"])),class:"editor-wrapper"},{default:n.withCtx(()=>[i.valuesEnum?(n.openBlock(),n.createBlock(c,{key:0,prop:"value"},{default:n.withCtx(()=>[n.createVNode(s,{modelValue:a.form.value,"onUpdate:modelValue":t[0]||(t[0]=p=>a.form.value=p),style:{display:"flex","flex-direction":"column"}},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.valuesEnum,p=>(n.openBlock(),n.createElementBlock("div",{key:p},[n.createVNode(l,{label:p},{default:n.withCtx(()=>[i.inlineComponent?(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.inlineComponent),{key:0,value:p,schema:r.schema},null,8,["value","schema"])):(n.openBlock(),n.createElementBlock("span",{key:1,textContent:n.toDisplayString(p)},null,8,Lde))]),_:2},1032,["label"])]))),128))]),_:1},8,["modelValue"])]),_:1})):(n.openBlock(),n.createBlock(c,{key:1,prop:"comparison"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.comparisons,p=>(n.openBlock(),n.createElementBlock("div",{key:p.value},[n.createVNode(u,{modelValue:a.form.comparison,"onUpdate:modelValue":t[1]||(t[1]=h=>a.form.comparison=h),label:p.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(p.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==p.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createVNode(d,{ref_for:!0,ref:"valueInput",type:"number",modelValue:a.form.value,"onUpdate:modelValue":t[2]||(t[2]=h=>a.form.value=h),modelModifiers:{number:!0}},null,8,["modelValue"])]),_:1})):n.createCommentVNode("",!0)]))),128))]),_:1}))]),_:1},8,["model","rules"])}const Vde=xe(jde,[["render",Bde],["__scopeId","data-v-d486d53d"]]);const $de={props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0},lang:{type:String,default(){return pn()}}},emits:["update:filter","change","cancel"],data(){return{form:{value:this.filter.value,comparison:this.filter.comparison||"relative_past_gte"}}},watch:{"form.comparison":{handler(e,t){t.indexOf("relative_")===0&&e.indexOf("absolute_")===0?this.form.value=new Date:t.indexOf("absolute_")===0&&e.indexOf("relative_")===0&&(this.form.value=1),this.$nextTick(()=>this.focus())}}},methods:{focus(){this.$refs.valueInput&&this.$refs.valueInput.length>0&&this.$refs.valueInput[0].$el.focus()},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{relativePastComparisons(){return[{label:this.$tds("date-relative-comparation-lt"),value:"relative_past_gte"},{label:this.$tds("date-relative-comparation-gt"),value:"relative_past_lt"},{label:this.$tds("date-relative-comparation-eq"),value:"relative_past_eq"}]},relativeFutureComparisons(){return[{label:this.$tds("date-relative-future-gt"),value:"relative_future_gte"},{label:this.$tds("date-relative-future-lt"),value:"relative_future_lt"},{label:this.$tds("date-relative-future-eq"),value:"relative_future_eq"}]},absoluteComparisons(){return[{label:this.$tds("date-absolute-eq"),value:"absolute_eq"},{label:this.$tds("date-absolute-gte"),value:"absolute_gte"},{label:this.$tds("date-absolute-lt"),value:"absolute_lt"}]},rules(){return{value:[{required:!0,message:`${this.$tds("type-to-filter")} ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`${this.$tds("choose-a-mode-to-filter")} ${this.schema.title}`,trigger:"change"}]}}}},Pde={class:"row"},Rde={style:{"margin-left":"8px","white-space":"nowrap"}},Fde={class:"row"},Ude={style:{"margin-left":"8px","white-space":"nowrap"}},Hde={class:"row"};function Yde(e,t,r,o,a,i){const l=n.resolveComponent("l-radio"),s=n.resolveComponent("l-input"),c=n.resolveComponent("l-form-item"),u=n.resolveComponent("l-date-picker"),d=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(d,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[6]||(t[6]=n.withModifiers(()=>{},["prevent"]))},{default:n.withCtx(()=>[n.createVNode(c,{prop:"comparison",class:"item-wrapper",style:{"margin-bottom":"0"}},{default:n.withCtx(()=>[n.createElementVNode("strong",null,n.toDisplayString(e.$tds("date-editor-relative-past")),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.relativePastComparisons,f=>(n.openBlock(),n.createElementBlock("div",{key:f.value},[n.createVNode(l,{modelValue:a.form.comparison,"onUpdate:modelValue":t[0]||(t[0]=p=>a.form.comparison=p),label:f.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==f.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createElementVNode("div",Pde,[n.createVNode(s,{type:"number",min:"1",ref_for:!0,ref:"valueInput",modelValue:a.form.value,"onUpdate:modelValue":t[1]||(t[1]=p=>a.form.value=p),modelModifiers:{number:!0},size:"small"},null,8,["modelValue"]),n.createElementVNode("div",Rde,n.toDisplayString(a.form.value>1?"dias":"dia"),1)])]),_:1})):n.createCommentVNode("",!0)]))),128)),n.createElementVNode("strong",null,n.toDisplayString(e.$tds("date-editor-relative-future")),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.relativeFutureComparisons,f=>(n.openBlock(),n.createElementBlock("div",{key:f.value},[n.createVNode(l,{modelValue:a.form.comparison,"onUpdate:modelValue":t[2]||(t[2]=p=>a.form.comparison=p),label:f.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==f.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createElementVNode("div",Fde,[n.createVNode(s,{type:"number",min:"1",ref_for:!0,ref:"valueInput",modelValue:a.form.value,"onUpdate:modelValue":t[3]||(t[3]=p=>a.form.value=p),modelModifiers:{number:!0},size:"small"},null,8,["modelValue"]),n.createElementVNode("div",Ude,n.toDisplayString(a.form.value>1?"dias":"dia"),1)])]),_:1})):n.createCommentVNode("",!0)]))),128)),n.createElementVNode("strong",null,n.toDisplayString(e.$tds("date-editor-absolute")),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.absoluteComparisons,f=>(n.openBlock(),n.createElementBlock("div",{key:f.value},[n.createVNode(l,{modelValue:a.form.comparison,"onUpdate:modelValue":t[4]||(t[4]=p=>a.form.comparison=p),label:f.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==f.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value"},{default:n.withCtx(()=>[n.createElementVNode("div",Hde,[n.createVNode(u,{modelValue:a.form.value,"onUpdate:modelValue":t[5]||(t[5]=p=>a.form.value=p)},null,8,["modelValue"])])]),_:1})):n.createCommentVNode("",!0)]))),128))]),_:1})]),_:1},8,["model","rules"])}const Qde=xe($de,[["render",Yde],["__scopeId","data-v-1d6bf98b"]]),l8={};l8.register=function(){Sn.register({type:"String"},"filterChipEditor",Tde),Sn.register({type:"Number"},"filterChipEditor",Vde),Sn.register({type:"Date"},"filterChipEditor",Qde),Sn.register({format:"Amount"},"filterChipEditor",zde)};const Wde={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}},computed:{inlineComponent(){try{return this.$L.FieldTypeComponents.get(this.schema,"textOnly")}catch{return null}},comparisonLabel(){return console.log("filter",this.filter),{in:"é",eq:"é",neq:"não é",starts_with:"começa com",ends_with:"termina com",contains:"contém"}[this.filter.comparison]||""}}},qde={key:1},Gde={key:0},Kde={key:1};function Jde(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),n.createTextVNode(" "+n.toDisplayString(i.comparisonLabel)+" ",1),r.filter.comparison==="in"?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:0},n.renderList(r.filter.value,(s,c)=>(n.openBlock(),n.createElementBlock("span",{key:c},[i.inlineComponent?(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.inlineComponent),{key:0,value:s,schema:r.schema},null,8,["value","schema"])):(n.openBlock(),n.createElementBlock("span",qde,n.toDisplayString(s),1)),c<r.filter.value.length-1?(n.openBlock(),n.createElementBlock(n.Fragment,{key:2},[c<r.filter.value.length-2?(n.openBlock(),n.createElementBlock("span",Gde,", ")):(n.openBlock(),n.createElementBlock("span",Kde," ou "))],64)):n.createCommentVNode("",!0)]))),128)):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createTextVNode('"'+n.toDisplayString(r.filter.value)+'"',1)],64))])}const Zde=xe(Wde,[["render",Jde]]),Xde={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}},computed:{formattedValue(){return new Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL"}).format(this.filter.value/100)}}},efe={key:0},tfe={key:1},nfe={key:2},rfe={key:3},ofe={key:4};function afe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),t[1]||(t[1]=n.createTextVNode(" ")),r.filter.comparison==="eq"?(n.openBlock(),n.createElementBlock("span",efe,"=")):r.filter.comparison==="lt"?(n.openBlock(),n.createElementBlock("span",tfe,"<")):r.filter.comparison==="lte"?(n.openBlock(),n.createElementBlock("span",nfe,"<=")):r.filter.comparison==="gt"?(n.openBlock(),n.createElementBlock("span",rfe,">")):r.filter.comparison==="gte"?(n.openBlock(),n.createElementBlock("span",ofe,">=")):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(i.formattedValue),1)])}const ife=xe(Xde,[["render",afe]]),lfe={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}}},sfe={key:0},cfe={key:1},ufe={key:2},dfe={key:3},ffe={key:4},pfe={key:5};function mfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),t[1]||(t[1]=n.createTextVNode(" ")),r.filter.comparison==="eq"?(n.openBlock(),n.createElementBlock("span",sfe,"=")):r.filter.comparison==="neq"?(n.openBlock(),n.createElementBlock("span",cfe,"≠")):r.filter.comparison==="lt"?(n.openBlock(),n.createElementBlock("span",ufe,"<")):r.filter.comparison==="lte"?(n.openBlock(),n.createElementBlock("span",dfe,"≤")):r.filter.comparison==="gt"?(n.openBlock(),n.createElementBlock("span",ffe,">")):r.filter.comparison==="gte"?(n.openBlock(),n.createElementBlock("span",pfe,"≥")):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(r.filter.value),1)])}const hfe=xe(lfe,[["render",mfe]]),gfe={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}},computed:{comparisonLabel(){const e={relative_past_gte:"há menos de",relative_past_lt:"há mais de",relative_past_eq:"há exatamente",relative_future_gte:"daqui a mais de",relative_future_lt:"daqui a menos de",relative_future_eq:"daqui a exatamente",absolute_eq:"em",absolute_gte:"a partir de",absolute_lt:"até"};return console.log("filter",this.filter),e[this.filter.comparison]||""},formattedValue(){if(!this.filter.value)return"-";if(this.filter.comparison.startsWith("relative_"))return`${this.filter.value} ${this.filter.value>1?"dias":"dia"}`;const e=Dt(this.schema,"options.format","LL");return Nd(this.filter.value).format(e)}}};function vfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),n.createTextVNode(" "+n.toDisplayString(i.comparisonLabel)+" "+n.toDisplayString(i.formattedValue),1)])}const yfe=xe(gfe,[["render",vfe]]),s8={};s8.register=function(){Sn.register({type:"String"},"filterChipView",Zde),Sn.register({type:"Number"},"filterChipView",hfe),Sn.register({type:"Date"},"filterChipView",yfe),Sn.register({format:"Amount"},"filterChipView",ife)};l8.register();s8.register();const Mfe={name:"FilterChip",props:{filter:Object,schema:Object,lang:{type:String,default(){return pn()}}},components:{ElPopover:NZ},data(){return{editing:!1,localFilter:{...this.filter}}},watch:{filter(e){this.localFilter={...e}}},mounted(){(!this.$refs.editor||!this.$refs.view)&&this.remove(),this.$refs.editor&&this.$refs.editor.validate&&this.$refs.editor.validate(e=>{e||(this.editing=!0)})},methods:{toggleEditing(){this.editing=!this.editing},afterEnterPopover(){this.$refs.editor&&this.$refs.editor.focus&&this.$refs.editor.focus()},cancel(){this.editing=!1,this.$refs.editor&&this.$refs.editor.validate&&this.$refs.editor.validate(e=>{e||this.remove()})},change(){this.editing=!1},remove(){this.$emit("onRemove")},updateFilter(e){this.localFilter=e,this.$emit("update:filter",e)}},computed:{editorComponent(){return this.$L.FieldTypeComponents.get(this.schema,"filterChipEditor")},viewComponent(){return this.$L.FieldTypeComponents.get(this.schema,"filterChipView")}}},bfe={class:"filter-title"},wfe={class:"confirmation-buttons"};function Nfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button"),c=n.resolveComponent("el-popover");return n.openBlock(),n.createBlock(c,{"popper-class":"filter-chip-popper",class:"filter-chip",placement:"bottom-start",width:"288",trigger:"manual",visible:a.editing,"onUpdate:visible":t[2]||(t[2]=u=>a.editing=u),onAfterEnter:i.afterEnterPopover},{reference:n.withCtx(()=>[n.createVNode(s,{type:"primary",round:"",size:"small",onClick:i.toggleEditing},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.viewComponent),{ref:"view",schema:r.schema,filter:a.localFilter},null,8,["schema","filter"])),n.createVNode(l,{onClick:n.withModifiers(i.remove,["stop"]),class:"close-button"},{default:n.withCtx(()=>t[3]||(t[3]=[n.createTextVNode(" uil-times-circle ")])),_:1},8,["onClick"])]),_:1},8,["onClick"])]),default:n.withCtx(()=>[n.createElementVNode("div",bfe,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),n.createTextVNode(" "+n.toDisplayString(r.schema.title),1)]),t[4]||(t[4]=n.createElementVNode("br",null,null,-1)),(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.editorComponent),{ref:"editor",filter:a.localFilter,"onUpdate:filter":i.updateFilter,schema:r.schema,onCancel:i.cancel,onChange:i.change,class:"filter-form"},null,40,["filter","onUpdate:filter","schema","onCancel","onChange"])),n.createElementVNode("div",wfe,[n.createVNode(s,{plain:"",size:"small",onClick:t[0]||(t[0]=u=>this.$refs.editor.cancel())},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("cancel")),1)]),_:1}),n.createVNode(s,{type:"primary",size:"small",onClick:t[1]||(t[1]=u=>this.$refs.editor.save())},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("search")),1)]),_:1})])]),_:1},8,["visible","onAfterEnter"])}const kfe=xe(Mfe,[["render",Nfe]]);const xfe={tagName:"l-search-bar",emits:["update:modelValue","change"],props:{availableModes:{type:Array,default:()=>["simple"]},modelValue:{type:Object,default(e){return{mode:e.availableModes[0],queryText:"",filters:[]}}},schema:{type:Object,default:()=>({})},disabled:{type:Boolean,default:!1},lang:{type:String,default(){return pn()}}},data(){return{mode:Dt(this.value,"mode",this.availableModes[0]),queryText:Dt(this.value,"queryText",""),filters:$n(Dt(this.value,"filters",[]))}},watch:{modelValue(e){this.mode=Dt(e,"mode",this.availableModes[0]),this.queryText=Dt(e,"queryText","");const t=Dt(e,"filters",[]);dce(this.filters,t)||(this.filters=$n(t))},queryValue:{deep:!0,handler(e){this.isValid&&(this.$emit("change",$n(e)),this.$emit("update:modelValue",$n(e)))}}},methods:{getFilterSchema(e){const{path:t}=e;return this.schema.fields.find(r=>r.path===t)},updateFilter(e){const t=v4(this.filters,e);this.filters.splice(t,1,e)},addFilter(e){this.filters.push(Object.assign({},e))},removeFilter(e){const t=v4(this.filters,e);this.filters.splice(t,1)},clear(){switch(this.mode){case"simple":this.queryText="";return;case"advanced":this.filters.splice(0,this.filters.length);return;default:throw new Error(`Unknown mode ${this.mode}`)}}},computed:{queryValue(){return{mode:this.mode,queryText:this.queryText,filters:this.filters}},isValid(){return this.filters.filter(e=>!e.valid).length===0},availableModesOptions(){return[{icon:"uil-search",value:"simple",title:this.$tds("simple-filter",this.lang)},{icon:"uil-filter",value:"advanced",title:this.$tds("advanced-filter",this.lang)}].filter(e=>this.availableModes.includes(e.value))},showClearButton(){switch(this.mode){case"simple":return this.queryText.length>0;case"advanced":return this.filters.length>0;default:throw new Error(`Unknown mode ${this.mode}`)}}},components:{AddFilterButton:kde,FilterChip:kfe}},Cfe={key:1,class:"filters"},Efe={class:"clear-button"};function Tfe(e,t,r,o,a,i){const l=n.resolveComponent("l-toggle-button-group"),s=n.resolveComponent("l-input"),c=n.resolveComponent("filter-chip"),u=n.resolveComponent("add-filter-button"),d=n.resolveComponent("l-icon"),f=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([{disabled:r.disabled},"l-search-bar"])},[n.createVNode(l,{disabled:r.disabled,modelValue:a.mode,"onUpdate:modelValue":t[0]||(t[0]=p=>a.mode=p),options:i.availableModesOptions},null,8,["disabled","modelValue","options"]),a.mode==="simple"?(n.openBlock(),n.createBlock(s,{key:0,disabled:r.disabled,size:"large",modelValue:a.queryText,"onUpdate:modelValue":t[1]||(t[1]=p=>a.queryText=p),style:{flex:"1 1 auto"},placeholder:r.disabled?"":e.$tds("search-placeholder",r.lang),"input-style":"border: 0"},null,8,["disabled","modelValue","placeholder"])):(n.openBlock(),n.createElementBlock("div",Cfe,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.filters,p=>(n.openBlock(),n.createBlock(c,{key:p.path,filter:p,schema:i.getFilterSchema(p),"onUpdate:filter":i.updateFilter,onOnRemove:h=>i.removeFilter(p)},null,8,["filter","schema","onUpdate:filter","onOnRemove"]))),128)),n.createVNode(u,{schema:r.schema,filters:a.filters,lang:r.lang,onAddFilter:i.addFilter},null,8,["schema","filters","lang","onAddFilter"])])),n.createElementVNode("div",Efe,[n.withDirectives(n.createVNode(f,{type:"text",onClick:i.clear},{default:n.withCtx(()=>[n.createVNode(d,null,{default:n.withCtx(()=>t[2]||(t[2]=[n.createTextVNode("uil-times")])),_:1})]),_:1},8,["onClick"]),[[n.vShow,i.showClearButton]])])],2)}const Dfe=xe(xfe,[["render",Tfe]]),Sfe=Object.freeze(Object.defineProperty({__proto__:null,default:Dfe},Symbol.toStringTag,{value:"Module"}));var _fe=jr,Ife=function(){return _fe.Date.now()},Afe=Ife,Ofe=Lr,Uf=Afe,y4=r8,zfe="Expected a function",jfe=Math.max,Lfe=Math.min;function Bfe(e,t,r){var o,a,i,l,s,c,u=0,d=!1,f=!1,p=!0;if(typeof e!="function")throw new TypeError(zfe);t=y4(t)||0,Ofe(r)&&(d=!!r.leading,f="maxWait"in r,i=f?jfe(y4(r.maxWait)||0,t):i,p="trailing"in r?!!r.trailing:p);function h(w){var C=o,E=a;return o=a=void 0,u=w,l=e.apply(E,C),l}function m(w){return u=w,s=setTimeout(y,t),d?h(w):l}function g(w){var C=w-c,E=w-u,A=t-C;return f?Lfe(A,i-E):A}function v(w){var C=w-c,E=w-u;return c===void 0||C>=t||C<0||f&&E>=i}function y(){var w=Uf();if(v(w))return N(w);s=setTimeout(y,g(w))}function N(w){return s=void 0,p&&o?h(w):(o=a=void 0,l)}function b(){s!==void 0&&clearTimeout(s),u=0,o=c=a=s=void 0}function M(){return s===void 0?l:N(Uf())}function k(){var w=Uf(),C=v(w);if(o=arguments,a=this,c=w,C){if(s===void 0)return m(c);if(f)return clearTimeout(s),s=setTimeout(y,t),h(c)}return s===void 0&&(s=setTimeout(y,t)),l}return k.cancel=b,k.flush=M,k}var Vfe=Bfe;const $fe=St(Vfe);function Pfe(e){return e!==e}var Rfe=Pfe;function Ffe(e,t,r){for(var o=r-1,a=e.length;++o<a;)if(e[o]===t)return o;return-1}var Ufe=Ffe,Hfe=e8,Yfe=Rfe,Qfe=Ufe;function Wfe(e,t,r){return t===t?Qfe(e,t,r):Hfe(e,Yfe,r)}var qfe=Wfe,Gfe=qfe;function Kfe(e,t){var r=e==null?0:e.length;return!!r&&Gfe(e,t,0)>-1}var c8=Kfe;function Jfe(e,t,r){for(var o=-1,a=e==null?0:e.length;++o<a;)if(r(t,e[o]))return!0;return!1}var u8=Jfe,Zfe=Ah,Xfe=c8,epe=u8,tpe=Bb,npe=_d,rpe=Oh,ope=200;function ape(e,t,r,o){var a=-1,i=Xfe,l=!0,s=e.length,c=[],u=t.length;if(!s)return c;r&&(t=tpe(t,npe(r))),o?(i=epe,l=!1):t.length>=ope&&(i=rpe,l=!1,t=new Zfe(t));e:for(;++a<s;){var d=e[a],f=r==null?d:r(d);if(d=o||d!==0?d:0,l&&f===f){for(var p=u;p--;)if(t[p]===f)continue e;c.push(d)}else i(t,f,o)||c.push(d)}return c}var ipe=ape,M4=nl,lpe=Dd,spe=vr,b4=M4?M4.isConcatSpreadable:void 0;function cpe(e){return spe(e)||lpe(e)||!!(b4&&e&&e[b4])}var upe=cpe,dpe=Ih,fpe=upe;function d8(e,t,r,o,a){var i=-1,l=e.length;for(r||(r=fpe),a||(a=[]);++i<l;){var s=e[i];t>0&&r(s)?t>1?d8(s,t-1,r,o,a):dpe(a,s):o||(a[a.length]=s)}return a}var f8=d8,ppe=ipe,mpe=f8,hpe=My,w4=py,gpe=hpe(function(e,t){return w4(e)?ppe(e,mpe(t,1,w4,!0)):[]}),vpe=gpe;const ype=St(vpe),$a=e=>e!=null,v0=e=>typeof e=="function",Vh=e=>e!==null&&typeof e=="object",Mpe=e=>Vh(e)&&v0(e.then)&&v0(e.catch),p8=e=>typeof e=="number"||/^\d+(\.\d+)?$/.test(e),bpe=()=>Npe?/ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase()):!1;function wpe(){}const Gs=Object.assign,Npe=typeof window<"u";function N4(e,t){const r=t.split(".");let o=e;return r.forEach(a=>{var i;o=Vh(o)&&(i=o[a])!=null?i:""}),o}function kpe(e,t,r){return t.reduce((o,a)=>((!r||e[a]!==void 0)&&(o[a]=e[a]),o),{})}const m8=null,no=[Number,String],Dr={type:Boolean,default:!0},xpe=()=>({type:Array,default:()=>[]}),vo=e=>({type:String,default:e});var $h=typeof window<"u";function h8(e){let t;n.onMounted(()=>{e(),n.nextTick(()=>{t=!0})}),n.onActivated(()=>{t&&e()})}function g8(e,t,r={}){if(!$h)return;const{target:o=window,passive:a=!1,capture:i=!1}=r;let l=!1,s;const c=f=>{if(l)return;const p=n.unref(f);p&&!s&&(p.addEventListener(e,t,{capture:i,passive:a}),s=!0)},u=f=>{if(l)return;const p=n.unref(f);p&&s&&(p.removeEventListener(e,t,i),s=!1)};n.onUnmounted(()=>u(o)),n.onDeactivated(()=>u(o)),h8(()=>c(o));let d;return n.isRef(o)&&(d=n.watch(o,(f,p)=>{u(p),c(f)})),()=>{d==null||d(),u(o),l=!0}}var Nc,Hf;function Cpe(){if(!Nc&&(Nc=n.ref(0),Hf=n.ref(0),$h)){const e=()=>{Nc.value=window.innerWidth,Hf.value=window.innerHeight};e(),window.addEventListener("resize",e,{passive:!0}),window.addEventListener("orientationchange",e,{passive:!0})}return{width:Nc,height:Hf}}var Epe=/scroll|auto|overlay/i,Tpe=$h?window:void 0;function Dpe(e){return e.tagName!=="HTML"&&e.tagName!=="BODY"&&e.nodeType===1}function Spe(e,t=Tpe){let r=e;for(;r&&r!==t&&Dpe(r);){const{overflowY:o}=window.getComputedStyle(r);if(Epe.test(o))return r;r=r.parentNode}return t}bpe();const _pe=e=>e.stopPropagation();function v8(e,t){(typeof e.cancelable!="boolean"||e.cancelable)&&e.preventDefault(),t&&_pe(e)}Cpe();function ho(e){if($a(e))return p8(e)?`${e}px`:String(e)}function Ipe(e){if($a(e)){if(Array.isArray(e))return{width:ho(e[0]),height:ho(e[1])};const t=ho(e);return{width:t,height:t}}}function Ape(e){const t={};return e!==void 0&&(t.zIndex=+e),t}const Ope=/-(\w)/g,y8=e=>e.replace(Ope,(t,r)=>r.toUpperCase()),zpe=e=>e.replace(/([A-Z])/g,"-$1").toLowerCase().replace(/^-/,""),{hasOwnProperty:jpe}=Object.prototype;function Lpe(e,t,r){const o=t[r];$a(o)&&(!jpe.call(e,r)||!Vh(o)?e[r]=o:e[r]=M8(Object(e[r]),o))}function M8(e,t){return Object.keys(t).forEach(r=>{Lpe(e,t,r)}),e}var Bpe={name:"姓名",tel:"电话",save:"保存",confirm:"确认",cancel:"取消",delete:"删除",loading:"加载中...",noCoupon:"暂无优惠券",nameEmpty:"请填写姓名",addContact:"添加联系人",telInvalid:"请填写正确的电话",vanCalendar:{end:"结束",start:"开始",title:"日期选择",weekdays:["日","一","二","三","四","五","六"],monthTitle:(e,t)=>`${e}年${t}月`,rangePrompt:e=>`最多选择 ${e} 天`},vanCascader:{select:"请选择"},vanPagination:{prev:"上一页",next:"下一页"},vanPullRefresh:{pulling:"下拉即可刷新...",loosing:"释放即可刷新..."},vanSubmitBar:{label:"合计:"},vanCoupon:{unlimited:"无门槛",discount:e=>`${e}折`,condition:e=>`满${e}元可用`},vanCouponCell:{title:"优惠券",count:e=>`${e}张可用`},vanCouponList:{exchange:"兑换",close:"不使用",enable:"可用",disabled:"不可用",placeholder:"输入优惠码"},vanAddressEdit:{area:"地区",postal:"邮政编码",areaEmpty:"请选择地区",addressEmpty:"请填写详细地址",postalEmpty:"邮政编码不正确",addressDetail:"详细地址",defaultAddress:"设为默认收货地址"},vanAddressList:{add:"新增地址"}};const k4=n.ref("zh-CN"),x4=n.reactive({"zh-CN":Bpe}),Vpe={messages(){return x4[k4.value]},use(e,t){k4.value=e,this.add({[e]:t})},add(e={}){M8(x4,e)}};var $pe=Vpe;function Ppe(e){const t=y8(e)+".";return(r,...o)=>{const a=$pe.messages(),i=N4(a,t+r)||N4(a,r);return v0(i)?i(...o):i}}function y0(e,t){return t?typeof t=="string"?` ${e}--${t}`:Array.isArray(t)?t.reduce((r,o)=>r+y0(e,o),""):Object.keys(t).reduce((r,o)=>r+(t[o]?y0(e,o):""),""):""}function Rpe(e){return(t,r)=>(t&&typeof t!="string"&&(r=t,t=""),t=t?`${e}__${t}`:e,`${t}${y0(t,r)}`)}function Za(e){const t=`van-${e}`;return[t,Rpe(t),Ppe(t)]}const b8="van-haptics-feedback";function Fpe(e,{args:t=[],done:r,canceled:o}){if(e){const a=e.apply(null,t);Mpe(a)?a.then(i=>{i?r():o&&o()}).catch(wpe):a?r():o&&o()}else r()}function ml(e){return e.install=t=>{const{name:r}=e;r&&(t.component(r,e),t.component(y8(`-${r}`),e))},e}const Upe=Symbol();function Hpe(e){const t=n.getCurrentInstance();t&&Gs(t.proxy,e)}const[Ype,C4]=Za("badge"),Qpe={dot:Boolean,max:no,tag:vo("div"),color:String,offset:Array,content:no,showZero:Dr,position:vo("top-right")};var Wpe=n.defineComponent({name:Ype,props:Qpe,setup(e,{slots:t}){const r=()=>{if(t.content)return!0;const{content:l,showZero:s}=e;return $a(l)&&l!==""&&(s||l!==0&&l!=="0")},o=()=>{const{dot:l,max:s,content:c}=e;if(!l&&r())return t.content?t.content():$a(s)&&p8(c)&&+c>s?`${s}+`:c},a=n.computed(()=>{const l={background:e.color};if(e.offset){const[s,c]=e.offset;t.default?(l.top=ho(c),typeof s=="number"?l.right=ho(-s):l.right=s.startsWith("-")?s.replace("-",""):`-${s}`):(l.marginTop=ho(c),l.marginLeft=ho(s))}return l}),i=()=>{if(r()||e.dot)return n.createVNode("div",{class:C4([e.position,{dot:e.dot,fixed:!!t.default}]),style:a.value},[o()])};return()=>{if(t.default){const{tag:l}=e;return n.createVNode(l,{class:C4("wrapper")},{default:()=>[t.default(),i()]})}return i()}}});const qpe=ml(Wpe);let w8=2e3;const Gpe=()=>++w8,Kpe=e=>{w8=e},[N8,Jpe]=Za("config-provider"),k8=Symbol(N8),Zpe={tag:vo("div"),zIndex:Number,themeVars:Object,iconPrefix:String};function Xpe(e){const t={};return Object.keys(e).forEach(r=>{t[`--van-${zpe(r)}`]=e[r]}),t}n.defineComponent({name:N8,props:Zpe,setup(e,{slots:t}){const r=n.computed(()=>{if(e.themeVars)return Xpe(e.themeVars)});return n.provide(k8,e),n.watchEffect(()=>{e.zIndex!==void 0&&Kpe(e.zIndex)}),()=>n.createVNode(e.tag,{class:Jpe(),style:r.value},{default:()=>{var o;return[(o=t.default)==null?void 0:o.call(t)]}})}});const[e0e,E4]=Za("icon"),t0e=e=>e==null?void 0:e.includes("/"),n0e={dot:Boolean,tag:vo("i"),name:String,size:no,badge:no,color:String,badgeProps:Object,classPrefix:String};var r0e=n.defineComponent({name:e0e,props:n0e,setup(e,{slots:t}){const r=n.inject(k8,null),o=n.computed(()=>e.classPrefix||(r==null?void 0:r.iconPrefix)||E4());return()=>{const{tag:a,dot:i,name:l,size:s,badge:c,color:u}=e,d=t0e(l);return n.createVNode(qpe,n.mergeProps({dot:i,tag:a,class:[o.value,d?"":`${o.value}-${l}`],style:{color:u,fontSize:ho(s)},content:c},e.badgeProps),{default:()=>{var f;return[(f=t.default)==null?void 0:f.call(t),d&&n.createVNode("img",{class:E4("image"),src:l},null)]}})}}});const x8=ml(r0e),[o0e,Ul]=Za("loading"),a0e=Array(12).fill(null).map((e,t)=>n.createVNode("i",{class:Ul("line",String(t+1))},null)),i0e=n.createVNode("svg",{class:Ul("circular"),viewBox:"25 25 50 50"},[n.createVNode("circle",{cx:"50",cy:"50",r:"20",fill:"none"},null)]),l0e={size:no,type:vo("circular"),color:String,vertical:Boolean,textSize:no,textColor:String};var s0e=n.defineComponent({name:o0e,props:l0e,setup(e,{slots:t}){const r=n.computed(()=>Gs({color:e.color},Ipe(e.size))),o=()=>{var a;if(t.default)return n.createVNode("span",{class:Ul("text"),style:{fontSize:ho(e.textSize),color:(a=e.textColor)!=null?a:e.color}},[t.default()])};return()=>{const{type:a,vertical:i}=e;return n.createVNode("div",{class:Ul([a,{vertical:i}]),"aria-live":"polite","aria-busy":!0},[n.createVNode("span",{class:Ul("spinner",a),style:r.value},[a==="spinner"?a0e:i0e]),o()])}}});const c0e=ml(s0e),Ph={show:Boolean,zIndex:no,overlay:Dr,duration:no,teleport:[String,Object],lockScroll:Dr,lazyRender:Dr,beforeClose:Function,overlayStyle:Object,overlayClass:m8,transitionAppear:Boolean,closeOnClickOverlay:Dr},u0e=Object.keys(Ph);function d0e(e,t){return e>t?"horizontal":t>e?"vertical":""}function f0e(){const e=n.ref(0),t=n.ref(0),r=n.ref(0),o=n.ref(0),a=n.ref(0),i=n.ref(0),l=n.ref(""),s=()=>l.value==="vertical",c=()=>l.value==="horizontal",u=()=>{r.value=0,o.value=0,a.value=0,i.value=0,l.value=""};return{move:p=>{const h=p.touches[0];r.value=(h.clientX<0?0:h.clientX)-e.value,o.value=h.clientY-t.value,a.value=Math.abs(r.value),i.value=Math.abs(o.value);const m=10;(!l.value||a.value<m&&i.value<m)&&(l.value=d0e(a.value,i.value))},start:p=>{u(),e.value=p.touches[0].clientX,t.value=p.touches[0].clientY},reset:u,startX:e,startY:t,deltaX:r,deltaY:o,offsetX:a,offsetY:i,direction:l,isVertical:s,isHorizontal:c}}let xl=0;const T4="van-overflow-hidden";function p0e(e,t){const r=f0e(),o="01",a="10",i=d=>{r.move(d);const f=r.deltaY.value>0?a:o,p=Spe(d.target,e.value),{scrollHeight:h,offsetHeight:m,scrollTop:g}=p;let v="11";g===0?v=m>=h?"00":"01":g+m>=h&&(v="10"),v!=="11"&&r.isVertical()&&!(parseInt(v,2)&parseInt(f,2))&&v8(d,!0)},l=()=>{document.addEventListener("touchstart",r.start),document.addEventListener("touchmove",i,{passive:!1}),xl||document.body.classList.add(T4),xl++},s=()=>{xl&&(document.removeEventListener("touchstart",r.start),document.removeEventListener("touchmove",i),xl--,xl||document.body.classList.remove(T4))},c=()=>t()&&l(),u=()=>t()&&s();h8(c),n.onDeactivated(u),n.onBeforeUnmount(u),n.watch(t,d=>{d?l():s()})}function C8(e){const t=n.ref(!1);return n.watch(e,r=>{r&&(t.value=r)},{immediate:!0}),r=>()=>t.value?r():null}const[m0e,h0e]=Za("overlay"),g0e={show:Boolean,zIndex:no,duration:no,className:m8,lockScroll:Dr,lazyRender:Dr,customStyle:Object};var v0e=n.defineComponent({name:m0e,props:g0e,setup(e,{slots:t}){const r=n.ref(),o=C8(()=>e.show||!e.lazyRender),a=l=>{e.lockScroll&&v8(l,!0)},i=o(()=>{var l;const s=Gs(Ape(e.zIndex),e.customStyle);return $a(e.duration)&&(s.animationDuration=`${e.duration}s`),n.withDirectives(n.createVNode("div",{ref:r,style:s,class:[h0e(),e.className]},[(l=t.default)==null?void 0:l.call(t)]),[[n.vShow,e.show]])});return g8("touchmove",a,{target:r}),()=>n.createVNode(n.Transition,{name:"van-fade",appear:!0},{default:i})}});const y0e=ml(v0e),M0e=Gs({},Ph,{round:Boolean,position:vo("center"),closeIcon:vo("cross"),closeable:Boolean,transition:String,iconPrefix:String,closeOnPopstate:Boolean,closeIconPosition:vo("top-right"),safeAreaInsetTop:Boolean,safeAreaInsetBottom:Boolean}),[b0e,D4]=Za("popup");var w0e=n.defineComponent({name:b0e,inheritAttrs:!1,props:M0e,emits:["open","close","opened","closed","keydown","update:show","click-overlay","click-close-icon"],setup(e,{emit:t,attrs:r,slots:o}){let a,i;const l=n.ref(),s=n.ref(),c=C8(()=>e.show||!e.lazyRender),u=n.computed(()=>{const k={zIndex:l.value};if($a(e.duration)){const w=e.position==="center"?"animationDuration":"transitionDuration";k[w]=`${e.duration}s`}return k}),d=()=>{a||(a=!0,l.value=e.zIndex!==void 0?+e.zIndex:Gpe(),t("open"))},f=()=>{a&&Fpe(e.beforeClose,{done(){a=!1,t("close"),t("update:show",!1)}})},p=k=>{t("click-overlay",k),e.closeOnClickOverlay&&f()},h=()=>{if(e.overlay)return n.createVNode(y0e,{show:e.show,class:e.overlayClass,zIndex:l.value,duration:e.duration,customStyle:e.overlayStyle,role:e.closeOnClickOverlay?"button":void 0,tabindex:e.closeOnClickOverlay?0:void 0,onClick:p},{default:o["overlay-content"]})},m=k=>{t("click-close-icon",k),f()},g=()=>{if(e.closeable)return n.createVNode(x8,{role:"button",tabindex:0,name:e.closeIcon,class:[D4("close-icon",e.closeIconPosition),b8],classPrefix:e.iconPrefix,onClick:m},null)},v=()=>t("opened"),y=()=>t("closed"),N=k=>t("keydown",k),b=c(()=>{var k;const{round:w,position:C,safeAreaInsetTop:E,safeAreaInsetBottom:A}=e;return n.withDirectives(n.createVNode("div",n.mergeProps({ref:s,style:u.value,role:"dialog",tabindex:0,class:[D4({round:w,[C]:C}),{"van-safe-area-top":E,"van-safe-area-bottom":A}],onKeydown:N},r),[(k=o.default)==null?void 0:k.call(o),g()]),[[n.vShow,e.show]])}),M=()=>{const{position:k,transition:w,transitionAppear:C}=e,E=k==="center"?"van-fade":`van-popup-slide-${k}`;return n.createVNode(n.Transition,{name:w||E,appear:C,onAfterEnter:v,onAfterLeave:y},{default:b})};return n.watch(()=>e.show,k=>{k&&!a&&(d(),r.tabindex===0&&n.nextTick(()=>{var w;(w=s.value)==null||w.focus()})),!k&&a&&(a=!1,t("close"))}),Hpe({popupRef:s}),p0e(s,()=>e.show&&e.lockScroll),g8("popstate",()=>{e.closeOnPopstate&&(f(),i=!1)}),n.onMounted(()=>{e.show&&d()}),n.onActivated(()=>{i&&(t("update:show",!0),i=!1)}),n.onDeactivated(()=>{e.show&&e.teleport&&(f(),i=!0)}),n.provide(Upe,()=>e.show),()=>e.teleport?n.createVNode(n.Teleport,{to:e.teleport},{default:()=>[h(),M()]}):n.createVNode(n.Fragment,null,[h(),M()])}});const N0e=ml(w0e),[k0e,br]=Za("action-sheet"),x0e=Gs({},Ph,{title:String,round:Dr,actions:xpe(),closeIcon:vo("cross"),closeable:Dr,cancelText:String,description:String,closeOnPopstate:Dr,closeOnClickAction:Boolean,safeAreaInsetBottom:Dr}),C0e=[...u0e,"round","closeOnPopstate","safeAreaInsetBottom"];var E0e=n.defineComponent({name:k0e,props:x0e,emits:["select","cancel","update:show"],setup(e,{slots:t,emit:r}){const o=d=>r("update:show",d),a=()=>{o(!1),r("cancel")},i=()=>{if(e.title)return n.createVNode("div",{class:br("header")},[e.title,e.closeable&&n.createVNode(x8,{name:e.closeIcon,class:[br("close"),b8],onClick:a},null)])},l=()=>{if(t.cancel||e.cancelText)return[n.createVNode("div",{class:br("gap")},null),n.createVNode("button",{type:"button",class:br("cancel"),onClick:a},[t.cancel?t.cancel():e.cancelText])]},s=(d,f)=>d.loading?n.createVNode(c0e,{class:br("loading-icon")},null):t.action?t.action({action:d,index:f}):[n.createVNode("span",{class:br("name")},[d.name]),d.subname&&n.createVNode("div",{class:br("subname")},[d.subname])],c=(d,f)=>{const{color:p,loading:h,callback:m,disabled:g,className:v}=d,y=()=>{g||h||(m&&m(d),e.closeOnClickAction&&o(!1),n.nextTick(()=>r("select",d,f)))};return n.createVNode("button",{type:"button",style:{color:p},class:[br("item",{loading:h,disabled:g}),v],onClick:y},[s(d,f)])},u=()=>{if(e.description||t.description){const d=t.description?t.description():e.description;return n.createVNode("div",{class:br("description")},[d])}};return()=>n.createVNode(N0e,n.mergeProps({class:br(),position:"bottom","onUpdate:show":o},kpe(e,C0e)),{default:()=>{var d;return[i(),u(),n.createVNode("div",{class:br("content")},[e.actions.map(c),(d=t.default)==null?void 0:d.call(t)]),l()]}})}});const M0=ml(E0e);var Eu={},ef={};Object.defineProperty(ef,"__esModule",{value:!0});ef.errorHandler=void 0;function T0e(e){if(!e)return;const t={message:"Um problema aconteceu e foi enviado para análise",type:"error",retryable:!0};return!window.navigator.onLine||e.message==="Network Error"?(t.message="Parece que você está offline.",t.type="info",t):typeof e=="string"?(t.message=e,t.retryable=!1,t):e.response&&e.response.status&&e.response.status>=400&&e.response.status<500?(t.message="Algumas informações não foram atualizadas.",t.retryable=!1,t):(e.response&&e.response.status>=500&&(t.message="Ops, encontramos um erro. Tente novamente mais tarde."),t)}ef.errorHandler=T0e;(function(e){var t=Pt&&Pt.__createBinding||(Object.create?function(o,a,i,l){l===void 0&&(l=i),Object.defineProperty(o,l,{enumerable:!0,get:function(){return a[i]}})}:function(o,a,i,l){l===void 0&&(l=i),o[l]=a[i]}),r=Pt&&Pt.__exportStar||function(o,a){for(var i in o)i!=="default"&&!a.hasOwnProperty(i)&&t(a,o,i)};Object.defineProperty(e,"__esModule",{value:!0}),r(ef,e)})(Eu);const D0e={name:"TopicItem",props:{multipleTargets:{type:Boolean},depth:{type:Number,default:0},propagate:{type:Function},propagateIncludes:{type:Function},parentsTopic:{type:Array,default:()=>[]},isCheckedFunction:{type:Function},rootIsChecked:{type:Function},populateTopic:{type:Function},hasChildChecked:{type:Function},parentIncludes:{type:Array,default:()=>[]},includesMap:{type:Object},parentChecked:{type:Boolean},topic:{type:Object},disabled:{type:Boolean},checked:{type:Boolean},selectedTopicKind:{type:String},setLoadingTopicState:{type:Function},parentTotals:{type:Array,default:()=>[]},parentFetch:{type:Function},lang:{type:String,default(){return pn()}}},data:function(){return{showIncludes:!1,fetchingIncludes:!1,initialFetching:!0,fetched:!1,error:!1,includes:[],includesMapData:{},generator:null,buffer:[],hasMore:!1,limit:30,totals:[]}},created(){this.generator=this.combinedGenerator(),this.includesMapData=this.includesMap,this.totals=$n(this.parentTotals)},watch:{async showIncludes(e){e===!0&&this.fetched===!1&&(this.fetched=!0,await this.fetch(),this.initialFetching=!1)},async limit(){this.generator=this.combinedGenerator()}},computed:{includesNoData(){return{group:"Esta turma ainda não tem alunos",tag:"Esta tag ainda não tem turmas"}[this.topic.kind]},isSelectedEntityKind(){return this.topic.kind===this.selectedTopicKind},chanShowCheckbox(){return this.multipleTargets||this.isSelectedEntityKind&&!this.multipleTargets},shouldDisable(){return!this.parentsTopic.some(this.isCheckedFunction)&&!this.rootIsChecked(this.topic)?!1:this.totals.filter(o=>this.isTopicInCheckedParentsTopic(o.topic)||this.isCurrentTopic(o.topic)||this.rootIsChecked(o.topic)).reduce((o,a)=>o+a.total,0)>600}},methods:{async*fetchToGenerator(e,t=null){const r={id:this.topic.id,kind:e,limit:this.limit+1,page:0};t&&(r.groupContext=t);let{hits:o,total:a}=await this.populateTopic(r);for(this.totals.push({topic:this.topic,total:a});a>0;){if(o.length>0){yield o.shift(),a--;continue}r.page+=1,o=(await this.populateTopic(r)).hits}},async*combinedGenerator(){this.topic.kind==="group"?(yield*this.fetchToGenerator("group","member"),yield*this.fetchToGenerator("group","user")):this.topic.kind==="member"?yield*this.fetchToGenerator("member","user"):yield*this.fetchToGenerator("tag")},async fetchPage(e){this.limit=e||this.limit;const t=this.limit;for(;this.buffer.length<t+1;){let r=await this.generator.next();if(r.value){this.buffer.push(r.value);continue}break}return{results:this.buffer.splice(0,t),hasMore:this.buffer.length>0}},async fetch(e){const t=e||this.limit,r=$n(this.includes);this.fetchingIncludes=!0;try{const{results:o,hasMore:a}=await this.fetchPage(t);this.includes=[...r,...o],this.includesMapData={...this.includesMapData,[this.topic.id]:this.includes},this.$emit("includes",{topic:this.topic,includes:this.includes}),this.hasMore=a}catch(o){this.error=o,this.$notify({...Eu.errorHandler("Erro ao carregar mais."),duration:1e4,position:"bottom",showClose:!0})}finally{this.fetchingIncludes=!1}},color(e){return this.disabled?"gray-50":{member:"purple",group:"aqua",user:"link",tag:"warning"}[e]||"lead"},icon(e){return{member:"uil-graduation-cap",group:"uil-users-alt",user:"uil-user",tag:"uil-tag-alt"}[e]},isChildChecked(e){return this.isCheckedFunction(e)||this.isCheckedFunction(this.topic)},expandableKind(){return["group","tag","member"].includes(this.topic.kind)},toggleShowIncludes(){this.expandableKind&&(this.showIncludes=!this.showIncludes)},updateSelectedTopics(e,t){this.$emit("input",{topic:e,value:t})},async topicIncludedChanged(e,t){try{this.parentsTopic.some(this.isCheckedFunction)&&!t&&(this.setLoadingTopicState(!0),await this.parentFetch(t),this.parentsTopic.slice(this.parentsTopic.findIndex(this.rootIsChecked)).forEach(o=>{var a;this.updateSelectedTopics(o,!1),(a=this.includesMap[o.id])==null||a.forEach(i=>{this.hasChildChecked(i)||this.updateSelectedTopics(i,!0)})})),this.updateSelectedTopics(e,t)}finally{this.setLoadingTopicState(!1)}},checkedParents(){const e=this.parentsTopic.findIndex(this.rootIsChecked);let t=[];return e!==-1&&(t=this.parentsTopic.slice(e)),t},isTopicInCheckedParentsTopic(e){return this.checkedParents().some(r=>r.id===e.id&&r.kind===e.kind)},isCurrentTopic(e){return e.id===this.topic.id&&e.kind===this.topic.kind},async handlePagination(e){var t;if(!(e||!this.isCheckedFunction(this.topic)))try{for((t=this.parentsTopic)!=null&&t.length&&(await this.retry(()=>this.parentFetch(e)),this.includesMapData={...this.includesMapData,...this.includesMap});this.hasMore;)await this.retry(()=>this.fetch(200))}catch(r){console.error("handlePagination failed:",r)}},async retry(e,t=3,r=500){for(let o=0;o<t;o++)try{return await e()}catch(a){if(o===t-1)throw a;console.warn(`Retry ${o+1} failed. Retrying in ${r}ms...`),await new Promise(i=>setTimeout(i,r))}}}},S0e={class:"topic-item-group"},_0e={key:0,class:"topic-chevron mr-2"},I0e={class:"topic-icon"},A0e={key:0},O0e={class:"l-d-flex l-align-items-center my-2",style:{"justify-content":"center",width:"100%",height:"40px"}},z0e={key:1},j0e={class:"no-data-includes l-text-regular gray-60--text"},L0e={key:1},B0e={key:0,class:"mx-3 my-3"};function V0e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-checkbox"),c=n.resolveComponent("LCircularLoader"),u=n.resolveComponent("TopicItem",!0),d=n.resolveComponent("l-button"),f=n.resolveComponent("l-transition-expand");return n.openBlock(),n.createElementBlock("div",S0e,[n.createElementVNode("div",{class:n.normalizeClass("topic-item-group-header depth-"+r.depth+" l-d-flex l-align-items-center pl-3"+(i.isSelectedEntityKind&&r.depth>0?" user-topic-item-group-header":""))},[n.createElementVNode("div",{class:"l-flex l-d-flex l-align-items-center",onClick:t[0]||(t[0]=n.withModifiers(p=>i.isSelectedEntityKind?null:i.toggleShowIncludes(),["stop"]))},[i.isSelectedEntityKind?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",_0e,[n.createVNode(l,{class:"gray-60--text",size:"24"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.showIncludes?"uil-angle-down":"uil-angle-right"),1)]),_:1})])),n.createElementVNode("div",I0e,[n.createElementVNode("div",{class:n.normalizeClass(["bg-icon",i.color(r.topic.kind)])},null,2),n.createVNode(l,{class:n.normalizeClass(i.color(r.topic.kind)+"--text")},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.icon(r.topic.kind)),1)]),_:1},8,["class"])]),n.createElementVNode("div",{class:n.normalizeClass(["l-flex ml-2 mr-3 l-text-regular ellipsis-2",r.disabled?"gray-70--text":"lead-light--text"])},n.toDisplayString(r.topic.name),3)]),(n.openBlock(),n.createBlock(s,{disabled:r.disabled,checked:r.isCheckedFunction(r.topic),indeterminate:r.hasChildChecked(r.topic)&&!r.isCheckedFunction(r.topic),key:r.isCheckedFunction(r.topic),onChange:t[1]||(t[1]=p=>r.parentsTopic.length?i.topicIncludedChanged(r.topic,p):i.updateSelectedTopics(r.topic,p)),class:n.normalizeClass(["p-3",{"circular-checkbox":!r.multipleTargets}]),style:n.normalizeStyle({display:i.chanShowCheckbox?"block":"none"})},null,8,["disabled","checked","indeterminate","class","style"]))],2),t[7]||(t[7]=n.createElementVNode("hr",null,null,-1)),n.createVNode(f,null,{default:n.withCtx(()=>[e.showIncludes?(n.openBlock(),n.createElementBlock("div",A0e,[e.initialFetching?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createElementVNode("div",O0e,[n.createVNode(c,{width:40,height:40})]),t[5]||(t[5]=n.createElementVNode("hr",null,null,-1))],64)):(n.openBlock(),n.createElementBlock("div",z0e,[!e.includes.length&&!e.hasMore||e.error?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createElementVNode("div",j0e,n.toDisplayString(i.includesNoData),1),t[6]||(t[6]=n.createElementVNode("hr",null,null,-1))],64)):(n.openBlock(),n.createElementBlock("div",L0e,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.includes,p=>(n.openBlock(),n.createBlock(u,{key:p.id,onInput:t[2]||(t[2]=h=>r.propagate(h)),onIncludes:t[3]||(t[3]=h=>r.propagateIncludes(h)),propagateIncludes:r.propagateIncludes,hasChildChecked:r.hasChildChecked,isCheckedFunction:i.isChildChecked,rootIsChecked:r.rootIsChecked,checked:i.isChildChecked(p),depth:r.depth+1,topic:p,selectedTopicKind:r.selectedTopicKind,parentsTopic:[...r.parentsTopic,r.topic],parentIncludes:e.includes,includesMap:e.includesMapData,parentChecked:r.checked,populateTopic:r.populateTopic,propagate:r.propagate,disabled:r.disabled||i.shouldDisable,multipleTargets:r.multipleTargets,onChildUnchecked:i.handlePagination,onPropagatePagination:i.handlePagination,setLoadingTopicState:r.setLoadingTopicState,parentTotals:e.totals,parentFetch:i.handlePagination},null,8,["propagateIncludes","hasChildChecked","isCheckedFunction","rootIsChecked","checked","depth","topic","selectedTopicKind","parentsTopic","parentIncludes","includesMap","parentChecked","populateTopic","propagate","disabled","multipleTargets","onChildUnchecked","onPropagatePagination","setLoadingTopicState","parentTotals","parentFetch"]))),128)),e.hasMore?(n.openBlock(),n.createElementBlock("div",B0e,[n.createVNode(d,{loading:e.fetchingIncludes,onClick:t[4]||(t[4]=p=>i.fetch()),plain:"",fill:""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("load-more",r.lang)),1)]),_:1},8,["loading"])])):n.createCommentVNode("",!0)]))]))])):n.createCommentVNode("",!0)]),_:1})])}const $0e=xe(D0e,[["render",V0e],["__scopeId","data-v-8abbd897"]]);const P0e={props:{term:{type:String}}},R0e={class:"l-d-flex l-align-items-center lead--text recent-topic"},F0e={class:"l-flex l-text-regular mx-2"};function U0e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",R0e,[n.createVNode(l,{size:"16"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-history")])),_:1}),n.createElementVNode("div",F0e,n.toDisplayString(r.term),1),n.createVNode(s,{onClick:t[0]||(t[0]=n.withModifiers(c=>e.$emit("remove"),["stop"])),circle:"",icon:"uil-multiply",class:"border-none lead--text f-18 p-1"})])}const H0e=xe(P0e,[["render",U0e],["__scopeId","data-v-a8c57ab5"]]);const Y0e={props:{query:{type:Object},typing:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},hasAnySelectedTopic:{type:Boolean,default:!1},kinds:{type:Array},lang:{type:String,default(){return pn()}}},data:e=>{const t=$n(e.query);return{localQuery:t,queryKind:t.kind}},computed:{filteredKinds(){return this.kinds.filter(e=>this.localQuery.q||!(e.value==="member"||e.value==="user"))}},watch:{queryKind:{handler(e){this.localQuery={...this.localQuery,kind:e}},immediate:!0,deep:!0},localQuery:{handler(e){this.$emit("update:query",e)},deep:!0,immediate:!0}},methods:{clearInput(){this.updateQuery({target:{value:null}})},isSelected(e){return Dt(this.localQuery,"kind",null)===e},updateQuery(e){this.localQuery={...this.localQuery,q:Dt(e,"target.value",null)}},setInputClass(e){return"search-input-wrapper ml-2 l-flex"+" "+e},back(){this.$emit("close")},save(){this.$emit("save")}}},Q0e={class:"app-navigation"},W0e={class:"search-topics-header l-d-flex l-align-items-center pl-2 pr-3"},q0e=["placeholder"],G0e={key:0,class:"filter-kind l-d-flex px-3 pb-2"};function K0e(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("l-icon"),c=n.resolveComponent("l-radio-button"),u=n.resolveComponent("l-radio-group"),d=n.resolveComponent("l-linear-progress");return n.openBlock(),n.createElementBlock("div",Q0e,[n.createElementVNode("div",W0e,[n.createVNode(l,{onClick:i.back,circle:"",icon:"uil-arrow-left",class:"border-none gray-70--text f-24 p-1"},null,8,["onClick"]),n.createElementVNode("div",{class:n.normalizeClass(i.setInputClass("blurred"))},[n.withDirectives(n.createElementVNode("input",{style:{width:"100%"},autocomplete:"off",placeholder:e.$tds("search",r.lang),"onUpdate:modelValue":t[0]||(t[0]=f=>e.localQuery.q=f),onFocus:t[1]||(t[1]=f=>i.setInputClass("focused")),onBlur:t[2]||(t[2]=f=>i.setInputClass("blurred")),onKeypress:t[3]||(t[3]=n.withKeys(f=>f.target.blur(),["enter"])),onInput:t[4]||(t[4]=(...f)=>i.updateQuery&&i.updateQuery(...f))},null,40,q0e),[[n.vModelText,e.localQuery.q]]),e.localQuery.q?(n.openBlock(),n.createBlock(s,{key:0,class:"lead-light--text cursor-pointer",onClick:i.clearInput,size:"16"},{default:n.withCtx(()=>t[6]||(t[6]=[n.createTextVNode(" uil-times ")])),_:1},8,["onClick"])):n.createCommentVNode("",!0)],2),n.createVNode(l,{disabled:!r.hasAnySelectedTopic,onClick:i.save,loading:r.loading||r.typing,type:"primary",class:"save-button bold l-d-flex l-align-items-center f-14 ml-2"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("save",r.lang)),1)]),_:1},8,["disabled","onClick","loading"])]),e.localQuery.q||r.query.kind!=="*"?(n.openBlock(),n.createElementBlock("div",G0e,[n.createVNode(u,{modelValue:e.queryKind,"onUpdate:modelValue":t[5]||(t[5]=f=>e.queryKind=f),class:"l-flex-nowrap",size:"small",separated:"",color:"lead-light"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.filteredKinds,f=>(n.openBlock(),n.createBlock(c,{key:f.value,label:f.value},{default:n.withCtx(()=>[f.icon?(n.openBlock(),n.createBlock(s,{key:0,color:i.isSelected(f.value)?"white":"lead-light",size:"13"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.icon),1)]),_:2},1032,["color"])):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(f.name),1)]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue"])])):n.createCommentVNode("",!0),r.loading||r.typing?(n.openBlock(),n.createBlock(d,{key:1})):n.createCommentVNode("",!0)])}const J0e=xe(Y0e,[["render",K0e],["__scopeId","data-v-707d9274"]]),S4=Symbol.for("GlobalStack"),E8=class{static createStackInstance(t){if(console.warn(`[VueModals] No ModalStack was found for name "${t}". Using Modals without a stack instance causes one to be created as default at the end of the document body.`),this.globalStackInstances.get(t))return console.warn(`[VueModals] A ModalStack instance with the name "${t}" already exists. Returning stack.`),this.globalStackInstances.get(t);const r=document.createElement("aside");document.body.insertAdjacentElement("beforeend",r);const o=n.createApp(b0,{name:t});return o.mount(r),this.globalStackInstances.set(t,o),o}static stack(t="default"){if(t==="default"&&!this.globalStackInstances.has("default"))return this.createStackInstance("default");if(this.globalStackInstances.has(t))return this.globalStackInstances.get(t);throw new Error(`[VueModals] No stack instance found for name "${t??"default"}". Create a ModalStack instance with this name to use it.`)}static open(t){return this.stack(t.stack).push(t)}static registerStack(t,r){console.warn("register",t,r),this.globalStackInstances.has(t)?console.warn(`[VueModals] Multiple instances of ModalStack must have unique names. Duplicate name found for ModalStack "${t}".`):this.globalStackInstances.set(t,r)}static unregisterStack(t,r){console.warn("unregister",t,r),this.globalStackInstances.get(t)===r?this.globalStackInstances.delete(t):console.warn(`[VueModals] Could not unregister ModalStack because a duplicate name was found "${t}".`)}};E8.globalStackInstances=window[S4]||(window[S4]=new Map);let bi=E8;const Z0e=n.defineComponent({props:{stack:{type:Array},index:{type:Number},modal:{type:Object},position:{type:String,default:"right"}},computed:{ensuredPosition(){return this.position==="left"?"left":"right"},depth(){const e=this.stack.filter(r=>{const o=r.options.position??"right";return r.options.layout==="drawer"&&o===this.ensuredPosition}),t=e.findIndex(r=>r===this.modal);return e.length-t-1}}}),Rh=(e,t)=>{const r=e.__vccOpts||e;for(const[o,a]of t)r[o]=a;return r},X0e=["position"];function eme(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("section",{layout:"drawer",position:e.ensuredPosition,style:n.normalizeStyle({"--depth":e.depth})},[n.renderSlot(e.$slots,"default")],12,X0e)}const tme=Rh(Z0e,[["render",eme]]),nme=n.defineComponent({computed:{classes(){return{center:!0}}},props:{stack:{type:Array},index:{type:Number},modal:{type:Object},showClose:{type:Object}}}),rme={key:0,class:"header"},ome={class:"content"};function ame(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("section",{layout:"dialog",class:n.normalizeClass(e.classes)},[e.showClose?(n.openBlock(),n.createElementBlock("div",rme,[n.createElementVNode("button",{class:"close-button",onClick:t[0]||(t[0]=l=>e.$emit("close"))},"×")])):n.createCommentVNode("",!0),n.createElementVNode("div",ome,[n.renderSlot(e.$slots,"default")]),t[1]||(t[1]=n.createElementVNode("div",{class:"footer"},null,-1))],2)}const ime=Rh(nme,[["render",ame]]);var lme=1;const _4=Symbol("Reject"),I4=Symbol("Resolve"),Cl=Symbol("Fulfilled"),sme={drawer:tme,dialog:ime},cme=n.defineComponent({name:"vue-modals-stack",data(){return{stack:[]}},created(){bi.registerStack(this.name,this)},beforeUnmount(){bi.unregisterStack(this.name,this)},methods:{getLayoutComponentFromModalLayout(e){return typeof e=="string"?sme[e]??e:e},removeFromStack(e){const t=this.stack.findIndex(r=>r===e);t<0||this.stack.splice(t,1)},addToStack(e){this.stack.push(e)},push(e){const t=this.buildModal(e);return this.addToStack(t),t},close(e,t){return this.canClose(e)?(this.destroy(e,t),!0):!1},layoutForModal(e){const t=e.layout??e.options.layout??this.layout??"section",r=tf.app;if(typeof t=="string"){const o=r.component(t);if(o)return o}return t},canClose(e){var t;const r=new Event("beforeClose",{cancelable:!0});if(e.options.beforeClose&&(e.options.beforeClose(r),r.defaultPrevented))return!1;const o=(t=this.$refs[e.id])==null?void 0:t[0];return!(o&&typeof o.beforeClose=="function"&&(o.beforeClose(r),r.defaultPrevented)||!this.stack.filter(a=>a.options.parent===o).every(a=>this.canClose(a)))},destroy(e,t){e[Cl]||(e[Cl]=!0,e[_4](t??new Error("Modal closed"))),this.removeFromStack(e)},answer(e,t){e[Cl]||(e[Cl]=!0,e[I4](t)),this.removeFromStack(e)},pop(){if(this.stack.length){const e=this.stack[this.stack.length-1];if(this.close(e))return e}return null},popUntil(e){if(!(this.stack.findIndex(t=>e===t)<0))for(;this.stack.length>0;){const t=this.pop();if(t===e||t===null)return}},clear(){for(;this.stack.length;)this.destroy(this.stack[this.stack.length-1])},buildModal(e){var t;let r,o;const a=new Promise((i,l)=>{r=i,o=s=>"default"in e?i(e.default):l(s)});return!e.layout&&(t=e.component)!=null&&t.layout&&(e.layout=e.component.layout),e.parent&&n.onBeforeUnmount(()=>{this.destroy(a,new Error("Component was destroyed"))}),a.id=lme++,a.stack=this,a.options=e,a.layout=this.layoutForModal(a),a.position=e.position,a[_4]=o,a[I4]=r,a[Cl]=!1,a.close=i=>this.close(a,i),a.destroy=i=>this.destroy(a,i),a},onNameChanged(e,t){t&&bi.unregisterStack(t,this),e&&bi.registerStack(e,this)}},props:{name:{type:String,default:"default"},layout:{type:String,default:"drawer"}},watch:{name:[{handler:"onNameChanged"}]}}),ume=["onClick"];function dme(e,t,r,o,a,i){return n.openBlock(),n.createBlock(n.TransitionGroup,{tag:"div",stack:e.name,name:"modal"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.stack,(l,s)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:l.id},[l.options.hideOverlay?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",{key:0,style:n.normalizeStyle(`z-index: ${1e3+s}`),class:n.normalizeClass(["vue-modals-overlay",{below:s<e.stack.length-1,far:s<e.stack.length-4}]),onClick:c=>l.options.clickToClose!==!1&&e.close(l)},null,14,ume)),(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.getLayoutComponentFromModalLayout(l.layout)),{"modal-id":l.id,modal:l,showClose:l.options.showClose,class:"vue-modals-layout",style:n.normalizeStyle(`z-index: ${1001+s}`),stack:e.stack,index:s,position:l.position,onClose:c=>e.close(l,c),onDestroy:c=>e.destroy(l,c),onAnswer:c=>e.answer(l,c)},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(l.options.component),n.mergeProps({ref_for:!0,ref:l.id},l.options.props,{onClose:c=>e.close(l,c),onDestroy:c=>e.destroy(l,c),onAnswer:c=>e.answer(l,c)}),null,16,["onClose","onDestroy","onAnswer"]))]),_:2},1064,["modal-id","modal","showClose","style","stack","index","position","onClose","onDestroy","onAnswer"]))],64))),128))]),_:1},8,["stack"])}const b0=Rh(cme,[["render",dme]]),tf={app:void 0,install(e){e.component("vue-modals-stack",b0),e.config.globalProperties.$modals=bi,tf.app=e},Modals:bi,ModalStack:b0};async function fme(e){const t=window.LayersPortal?window.LayersPortal.platform:"shell";if(t==="shell"||t==="iframe"){const o=tf.Modals.stack().push({layout:"dialog",showClose:!1,component:Th,props:{title:e.title,content:e.content,buttonCloseLabel:e.buttonCloseLabel,buttonConfirmLabel:e.buttonConfirmLabel}});try{return await o}catch{return!1}}return window.confirm(e.content||e.title)}async function pme(){const e=tf.Modals.stack();window.history.go(1);const t=e.push({layout:"dialog",showClose:!1,component:Th,props:{buttonCloseLabel:"Permanecer aqui",buttonConfirmLabel:"Descartar alterações",title:"Alterações não salvas",content:"Você quer mesmo sair? Existem alterações que não foram salvas. Se você sair, suas alterações serão perdidas."}});try{const r=await t;if(r)return r}catch{}}const mme="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIwIiBoZWlnaHQ9IjE4MyIgdmlld0JveD0iMCAwIDIyMCAxODMiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNODMuMjk5NCAxNjQuMjk4TDgzLjI5OSAxNjQuMjk4Qzc5LjA5NiAxNjYuMjIgNzUuMTk0NiAxNjguMDA1IDcxLjMxNDcgMTY5LjIxQzUxLjk2MDMgMTc1LjIyMyAzMS4wNjI2IDE3NS45MjIgMTAuMjk0OCAxNDguMjIxQy0xMC40NzI5IDEyMC41MTkgLTAuMzE2MjIyIDg0Ljk0NTQgNDUuMjkwOSA3MC4xOTEyQzU3LjIwOTMgNjYuMzM5IDYyLjgwOTQgNTcuNzI3NSA2OS41NjAzIDQ3LjM0NjFDNzYuNjg1MSAzNi4zODk5IDg1LjA5MTcgMjMuNDYyNSAxMDMuNTYgMTIuMDc4MkMxNTIuNTU1IC0xOC4xMTMzIDE5Ny4wODggMTAuNzYzNSAyMTUuODU4IDcxLjI3MTRDMjM0LjYyNyAxMzEuNzc5IDE4Ni43IDE1OS4xNDQgMTMwLjY3MiAxNTQuNDk4QzEwOC43MSAxNTIuNjc1IDk0Ljg2MzQgMTU5LjAwOSA4My4yOTk0IDE2NC4yOThaIiBmaWxsPSIjNTQ1MUQ2Ii8+CjxwYXRoIG9wYWNpdHk9IjAuOSIgZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik04My4yOTk0IDE2NC4yOThMODMuMjk5IDE2NC4yOThDNzkuMDk2IDE2Ni4yMiA3NS4xOTQ2IDE2OC4wMDUgNzEuMzE0NyAxNjkuMjFD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kPSJNMTI2LjgzMyA0NC4wMDQ0TDEyNC4xMzggNDQuMTc1NUMxMjQuMTM4IDQ0LjE3NTUgMTI0LjgzMyA0MC44NzM3IDEyMy44NTggMzguNzIzNEMxMjIuOTQyIDM2LjU1MTUgMTIxLjkyMyAzNS4wMjY5IDEyNi4xODUgMzMuNjA2MUMxMzAuNDQ4IDMyLjE4NTMgMTM0LjM1NCAzNS41Njg1IDEyNi44MzMgNDQuMDA0NFoiIGZpbGw9IiMyNjMyMzgiLz4KPHBhdGggZD0iTTE0MC41MzYgMzcuOTg2NUMxMzUuNjQyIDM4Ljk2MDQgMTI2LjY2NSAzOS4wNTM4IDEyNS42NTEgMzMuMDU2NEMxMjUuMDA3IDI5LjAyMzcgMTMxLjIwMyAyOC4xMTY1IDEzMy4xMTkgMjkuNTE3QzEzNS4wNTYgMzAuOTc3NCAxMzkuMTIxIDMyLjc0NDkgMTQyLjQ5NiAzMy4zNDE4QzE0NS44NzEgMzMuOTM4NiAxNDcuODE4IDM2LjU0NzIgMTQwLjUzNiAzNy45ODY1WiIgZmlsbD0iIzI2MzIzOCIvPgo8cGF0aCBkPSJNMTQxLjI5OCA0Ny4zOTVMMTM4LjYxNSA0Ny4yMjM0QzEzOC42MTUgNDcuMjIzNCAxMzkuNjkzIDQ0LjA1MjUgMTM5LjAxNSA0MS43OTM4QzEzOC4zMzcgMzkuNTM1MSAxMzcuNTM0IDM3Ljg2MzggMTQxLjkzMSAzNy4wMDM2QzE0Ni4zNjYgMzYuMDYxOCAxNDkuNzg1IDM5Ljk2MTMgMTQxLjI5OCA0Ny4zOTVaIiBmaWxsPSIjMjYzMjM4Ii8+Cjwvc3ZnPgo=";const hme={tagName:"l-search-topics",name:"LSearchTopics",components:{TopicItemGroup:$0e,RecentTermSearched:H0e,SearchTopicsHeader:J0e,[M0.name]:M0},props:{multipleTargets:{type:Boolean,default:!0},canSendForAll:{type:Boolean,default:!1},searchTopics:{type:Function},populateTopic:{type:Function},alreadySelectedTopics:{type:Array},recentTopicsSearched:{type:Object},selectedTopicKind:{type:String,default:"user"},lang:{type:String,default(){return pn()}}},data:function(){return{forAllTagChecked:!1,showSelected:!1,selectedTopics:[],includesMap:{},querySearchTopics:{q:null,kind:"*",page:0},searchedTopics:{tag:{hits:[],total:0},group:{hits:[],total:0},member:{hits:[],total:0},user:{hits:[],total:0}},total:0,kinds:["*","tag","group","member","user"],kindsIcons:{tag:"uil-tag-alt",group:"uil-users-alt",member:"uil-graduation-cap",user:"uil-user","*":""},typing:!1,loading:!1,loadingMore:!1,loadingTopic:!1}},watch:{selectedTopics(e){(!e||e.length===0)&&(this.showSelected=!1)},querySearchTopics(){!this.typing&&!this.loadingMore&&(this.typing=!0),this.searchDebounced()}},computed:{canShowSendForAll(){return this.canSendForAll&&!this.hasQuery&&this.multipleTargets},searchingSpan(){var e;return this.querySearchTopics.q?this.querySearchTopics.q:this.querySearchTopics.kind==="*"?"":(e=this.getKindNamePlural(this.querySearchTopics.kind,this.lang))==null?void 0:e.toLowerCase()},hasQuery(){return this.querySearchTopics.q||this.querySearchTopics.kind!=="*"},showRecentSearchedTopics(){return this.recentTopicsSearched.data?this.recentTopicsSearched.data.length>0&&!this.hasQuery:!1},filteredSearchedTopics(){return{...this.searchedTopics,tag:{hits:this.searchedTopics.tag.hits.filter(e=>e.id!=="*"),total:this.searchedTopics.tag.total}}},forAllTag:{get(){return this.forAllTagChecked},set(e){const t=this.searchedTopics.tag.hits;if(this.selectedTopics&&this.selectedTopics.length&&this.selectedTopics.find(r=>r.id!=="*")&&e!=="confirm"){this.showForAllTagAlert().then(r=>{if(!r){this.forAllTagChecked=!1;return}const o=t.find(a=>a.id==="*");this.setSelectedTopics([o]),this.forAllTagChecked=!0});return}if(e=!!e,e&&this.searchedTopics&&t){const r=t.find(o=>o.id==="*");this.setSelectedTopics([r])}else this.setSelectedTopics([]);this.forAllTagChecked=e}},recentTopicsFiltered(){return $n(this.recentTopicsSearched.data).reverse().slice(0,3)},topicsSummary(){if(!this.selectedTopics||!this.selectedTopics.length)return"";if(this.forAllTagChecked)return this.$tds("send-for-all",this.lang);const e=[];return this.kinds.filter(t=>t!=="*").forEach(t=>{var o,a;const r=a8(this.selectedTopics,{kind:t}).length;r===1?e.push(`1 ${(o=this.getKindName(t,this.lang))==null?void 0:o.toLowerCase()}`):r>1&&e.push(`${r} ${(a=this.getKindNamePlural(t,this.lang))==null?void 0:a.toLowerCase()}`)}),e.length?e.join(", "):null},hasAnySearchedTopic(){return this.total?this.total>0:null},headerKinds(){return this.kinds.filter(e=>e!=="tag"||this.canSendForAll).map(e=>({value:e,name:this.getKindNamePlural(e,this.lang),icon:this.kindsIcons[e]}))},resultKinds(){return this.kinds.filter(t=>t!=="*").filter(t=>this.filteredSearchedTopics[t].total&&this.filteredSearchedTopics[t].hits.length)},totalLabel(){return this.total===1?this.$tds("one-result-found",this.lang):this.total+this.$tds("results-found",this.lang)},isAllEntities(){return this.querySearchTopics.kind==="*"}},async created(){this.loading=!0;try{const e=await this.searchTopics(this.querySearchTopics);this.searchedTopics=e.result,this.total=e.total}catch{this.$notify({...Eu.errorHandler(this.$tds("error-target-loading",this.lang)),duration:1e4,position:"bottom",showClose:!0})}finally{this.loading=!1}this.selectedTopics=this.alreadySelectedTopics,this.selectedTopics&&this.selectedTopics.length&&this.selectedTopics.find(e=>e.id==="*"&&e.kind==="tag")&&this.multipleTargets&&(this.forAllTag=!0)},unmounted(){this.setSelectedTopics([])},methods:{searchDebounced:$fe(async function(){console.log(this.querySearchTopics),Dt(this.querySearchTopics,"q.length",null)>3&&this.recentTopicsSearched.push(this.querySearchTopics.q),await this.getSearchedTopics(this.querySearchTopics),this.typing=!1},500,{leading:!1,trailing:!0}),useRecentTermSearched(e){this.setQuerySearchTopics({q:e,kind:"*"})},updateIncludesMap({topic:e,includes:t}){this.includesMap[e.id]=t},hasChildChecked(e){const t=this.includesMap[e.id];return t?t.some(this.isChecked)||t.some(this.hasChildChecked):!1},getKindName(e,t="pt-br"){return{"pt-br":{"*":"Procurar em tudo",tag:"Marcador",group:"Turma",member:"Aluno",user:"Usuário"},en:{"*":"Search all",tag:"Tag",group:"Group",member:"Member",user:"User"},es:{"*":"Buscar en todo",tag:"Etiqueta",group:"Grupo",member:"Miembro",user:"Usuario"}}[t][e]},getKindNamePlural(e,t="pt-br"){return{"pt-br":{"*":"Procurar em tudo",tag:"Marcadores",group:"Turmas",member:"Alunos",user:"Usuários"},en:{"*":"Search all",tag:"Tags",group:"Groups",member:"Members",user:"Users"},es:{"*":"Buscar en todo",tag:"Etiquetas",group:"Grupos",member:"Miembros",user:"Usuarios"}}[t][e]},async getSearchedTopics(e){this.loadingMore||(this.loading=!0);try{const t=await this.searchTopics(e);if(e.page>0){const r=$n(this.searchedTopics);await Promise.all(Joe(t.result).map(o=>{r[o]||(r[o]={hits:[],total:null}),r[o].hits=[...r[o].hits,...t.result[o].hits]})),this.searchedTopics=r}else this.searchedTopics=t.result,this.total=t.total}catch{this.$notify({...Eu.errorHandler(this.$tds("error-searching",this.lang)),duration:1e4,position:"bottom",showClose:!0})}finally{this.loading=!1,this.loadingMore=!1}},loadMore(){this.loadingMore=!0;const e=Dt(this.querySearchTopics,"page",0)+1,t=Dt(this.querySearchTopics,"q",null),r=Dt(this.querySearchTopics,"kind",null);this.setQuerySearchTopics({q:t,kind:r,page:e})},getTopicHits(e){return Dt(this.filteredSearchedTopics,`${e}.hits`,[])},getTopicTotal(e){return Dt(this.filteredSearchedTopics,`${e}.total`,[])},needShowMore(e){return this.getTopicTotal(e)>this.getTopicHits(e).length},isChecked(e){return this.forAllTagChecked?!0:this.selectedTopics.filter(t=>t.kind===e.kind&&t.id===e.id).length!==0},filterForKind(e){this.setQuerySearchTopics({q:this.querySearchTopics.q,kind:e,page:0})},setSelectedTopics(e){this.selectedTopics=e},removeFromRecentTopicsSearched(e){this.recentTopicsSearched.remove(e)},setQuerySearchTopics(e){this.querySearchTopics=e},async showForAllTagAlert(){const e=await fme({title:this.$tds("show-for-all-tags",this.lang),buttonCloseLabel:this.$tds("cancel",this.lang),buttonConfirmLabel:this.$tds("continue",this.lang)});if(e)return e},addTopic(e){if(this.selectedTopics.filter(r=>r.id===e.id&&r.kind===e.kind).length===0){const r=$n(this.selectedTopics);r.push(e),this.setSelectedTopics(r)}},removeTopic(e){const t=this.selectedTopics.findIndex(o=>o.id===e.id&&o.kind===e.kind);if(t==-1)return;const r=$n(this.selectedTopics);r.splice(t,1),this.setSelectedTopics(r)},updateSelectedTopics({topic:e,value:t}){if(!this.multipleTargets)return t?this.setSelectedTopics([e]):this.setSelectedTopics([]);if(!t){this.removeTopic(e);return}this.addTopic(e)},setLoadingTopicState(e){this.loadingTopic=e},onSave(){const e=this.selectedTopics.map(t=>({hash:t.hash,name:t.name,kind:t.kind,id:t.id}));this.$emit("answer",e)},async onClose(){const e=$n(this.alreadySelectedTopics).map(a=>a.kind+a.id),t=$n(this.selectedTopics).map(a=>a.kind+a.id);if(ype(t,e).length===0){this.$emit("close");return}await pme()&&this.$emit("close")},onInput(e){this.querySearchTopics=e}}},gme={class:"search-topics-page l-col l-d-flex column"},vme={class:"px-0 py-2 l-container scroll-y l-flex-grow-1"},yme={key:0,class:"gray-70--text searching-label mx-3"},Mme={class:"gray-70--text searching-label mx-3"},bme={class:"mb-5"},wme={key:0,class:"recent-search mb-3 mx-3"},Nme={class:"recent-search-title gray-70--text mb-2 l-text-regular"},kme={key:1,class:"topic-item-tag-for-all mx-3"},xme={class:"l-flex lead-light--text l-text-regular"},Cme={key:2,class:"results-total mb-2 px-3"},Eme={key:0,class:"topic-kind-title gray-70--text mb-2 px-3"},Tme={key:1,class:"m-3"},Dme={key:2,class:"m-3"},Sme={key:2,style:{display:"flex","flex-direction":"column",height:"100%","align-items":"stretch"}},_me={key:0,class:"topic-item-tag-for-all empty-tags-groups-for-all mx-3"},Ime={class:"l-flex lead-light--text l-text-regular"},Ame={key:1,class:"empty-tags-groups-placeholder"},Ome={class:"empty-tags-groups-placeholder-text mt-2"},zme={class:"text-small lead-light--text"},jme={key:2,class:"not-found-result mx-3"},Lme={class:"bold lead--text m-0"},Bme={class:"lead-light--text l-text-regular mt-3 mb-0"},Vme={key:0,class:"selected-topics"},$me={class:"ml-2 topics-selected-summary l-flex link--text"},Pme={class:"l-d-flex m-3 l-align-items-center"},Rme={class:"l-flex lead-light--text l-text-regular"},Fme={class:"mx-3 mb-3"};function Ume(e,t,r,o,a,i){const l=n.resolveComponent("SearchTopicsHeader"),s=n.resolveComponent("l-linear-progress"),c=n.resolveComponent("RecentTermSearched"),u=n.resolveComponent("l-checkbox"),d=n.resolveComponent("TopicItemGroup"),f=n.resolveComponent("l-button"),p=n.resolveComponent("l-target-chip"),h=n.resolveComponent("van-action-sheet");return n.openBlock(),n.createElementBlock("div",gme,[n.createVNode(l,{class:"drawer-search-topics-header",kinds:i.headerKinds,query:e.querySearchTopics,typing:e.typing,loading:e.loading,hasAnySelectedTopic:e.selectedTopics.length>0,lang:r.lang,onSave:i.onSave,onClose:i.onClose,"onUpdate:query":i.onInput},null,8,["kinds","query","typing","loading","hasAnySelectedTopic","lang","onSave","onClose","onUpdate:query"]),n.createElementVNode("div",vme,[e.loading||e.typing?(n.openBlock(),n.createElementBlock("div",yme,n.toDisplayString(e.$tds("searching",r.lang))+" "+n.toDisplayString(i.searchingSpan)+"... ",1)):i.hasAnySearchedTopic?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.withDirectives(n.createVNode(s,null,null,512),[[n.vShow,e.loadingTopic]]),n.withDirectives(n.createElementVNode("div",Mme,null,512),[[n.vShow,e.loadingTopic]]),n.createElementVNode("div",bme,[i.showRecentSearchedTopics?(n.openBlock(),n.createElementBlock("div",wme,[n.createElementVNode("div",Nme,n.toDisplayString(e.$tds("recently-searched",r.lang)),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.recentTopicsFiltered,(m,g)=>(n.openBlock(),n.createBlock(c,{onClick:v=>i.useRecentTermSearched(m),term:m,key:g,class:"mb-2 cursor-pointer",onRemove:v=>i.removeFromRecentTopicsSearched(m)},null,8,["onClick","term","onRemove"]))),128))])):n.createCommentVNode("",!0),i.canShowSendForAll?(n.openBlock(),n.createElementBlock("div",kme,[n.createElementVNode("div",xme,n.toDisplayString(e.$tds("send-for-all",r.lang)),1),n.createVNode(u,{modelValue:i.forAllTag,"onUpdate:modelValue":t[0]||(t[0]=m=>i.forAllTag=m)},null,8,["modelValue"])])):n.createCommentVNode("",!0),e.total>=1&&i.hasQuery?(n.openBlock(),n.createElementBlock("div",Cme,n.toDisplayString(i.totalLabel),1)):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.resultKinds,m=>(n.openBlock(),n.createElementBlock("div",{class:"topics-searched mb-3",key:m},[i.isAllEntities?(n.openBlock(),n.createElementBlock("h6",Eme,n.toDisplayString(i.getKindNamePlural(m,r.lang))+" ("+n.toDisplayString(i.getTopicTotal(m))+") ",1)):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.getTopicHits(m),g=>(n.openBlock(),n.createBlock(d,{onInput:t[1]||(t[1]=v=>i.updateSelectedTopics(v)),onIncludes:i.updateIncludesMap,propagateIncludes:i.updateIncludesMap,propagate:i.updateSelectedTopics,hasChildChecked:i.hasChildChecked,topic:g,selectedTopicKind:r.selectedTopicKind,parentTopic:g,populateTopic:r.populateTopic,disabled:e.forAllTagChecked||e.loadingTopic,checked:i.isChecked(g),isCheckedFunction:i.isChecked,rootIsChecked:i.isChecked,multipleTargets:r.multipleTargets,key:g.id,setLoadingTopicState:i.setLoadingTopicState,lang:r.lang},null,8,["onIncludes","propagateIncludes","propagate","hasChildChecked","topic","selectedTopicKind","parentTopic","populateTopic","disabled","checked","isCheckedFunction","rootIsChecked","multipleTargets","setLoadingTopicState","lang"]))),128)),i.isAllEntities&&i.needShowMore(m)?(n.openBlock(),n.createElementBlock("div",Tme,[n.createVNode(f,{loading:e.loading,onClick:g=>i.filterForKind(m),plain:"",fill:""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("show-more",r.lang))+" "+n.toDisplayString(i.getKindNamePlural(m,r.lang).toLowerCase()),1)]),_:2},1032,["loading","onClick"])])):n.createCommentVNode("",!0),!i.isAllEntities&&i.needShowMore(m)?(n.openBlock(),n.createElementBlock("div",Dme,[n.createVNode(f,{class:"ma-3",loading:e.loadingMore,onClick:t[2]||(t[2]=g=>i.loadMore()),plain:"",fill:""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("load-more",r.lang)),1)]),_:1},8,["loading"])])):n.createCommentVNode("",!0)]))),128))])],64)):(n.openBlock(),n.createElementBlock("div",Sme,[r.canSendForAll&&!this.hasQuery?(n.openBlock(),n.createElementBlock("div",_me,[n.createElementVNode("div",Ime,n.toDisplayString(e.$tds("send-for-all",r.lang)),1),n.createVNode(u,{modelValue:i.forAllTag,"onUpdate:modelValue":t[3]||(t[3]=m=>i.forAllTag=m)},null,8,["modelValue"])])):n.createCommentVNode("",!0),e.querySearchTopics.q?!e.typing&&!e.loading?(n.openBlock(),n.createElementBlock("div",jme,[n.createElementVNode("h4",Lme,n.toDisplayString(e.$tds("not-found",r.lang)),1),n.createElementVNode("p",Bme,n.toDisplayString(e.$tds("make-sure-to-type-something",r.lang)),1)])):n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",Ame,[t[7]||(t[7]=n.createElementVNode("img",{alt:"Search Topics",src:mme},null,-1)),n.createElementVNode("div",Ome,[n.createElementVNode("h3",null,n.toDisplayString(e.$tds("search-for-markers-classes-users",r.lang)),1),n.createElementVNode("span",zme,n.toDisplayString(e.$tds("when-you-have-markers-classes",r.lang))+". ",1)])]))]))]),e.selectedTopics&&e.selectedTopics.length?(n.openBlock(),n.createElementBlock("div",Vme,[n.createElementVNode("button",{class:"selected-topics-button l-d-flex l-align-items-center",style:{padding:"0"},onClick:t[4]||(t[4]=m=>e.forAllTagChecked?i.forAllTag=!1:e.showSelected=!0)},[t[8]||(t[8]=n.createElementVNode("div",{class:"selected-topics-button-bg"},null,-1)),n.createElementVNode("div",$me,n.toDisplayString(i.topicsSummary),1),n.createVNode(f,{class:"mr-2 bold link--text",type:"text"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.forAllTagChecked?e.$tds("clean",r.lang):e.$tds("see-all",r.lang)),1)]),_:1})]),n.createVNode(h,{show:e.showSelected,"onUpdate:show":t[6]||(t[6]=m=>e.showSelected=m),"lock-scroll":"",style:{"max-height":"500px","min-height":"180px"}},{default:n.withCtx(()=>[n.createElementVNode("div",Pme,[n.createElementVNode("div",Rme,n.toDisplayString(e.$tds("selected-recipients",r.lang)),1),n.createVNode(f,{onClick:t[5]||(t[5]=m=>e.showSelected=!1),circle:"",icon:"uil-multiply",class:"border-none gray-70--text f-24 p-1"})]),n.createElementVNode("div",Fme,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.selectedTopics,m=>(n.openBlock(),n.createBlock(p,{onRemove:g=>i.removeTopic(m),key:m.id,kind:m.kind,name:m.name,closeable:!0,class:"mr-2 mb-2"},null,8,["onRemove","kind","name"]))),128))])]),_:1},8,["show"])])):n.createCommentVNode("",!0)])}const Hme=xe(hme,[["render",Ume],["__scopeId","data-v-ac94160c"]]),Yme=Object.freeze(Object.defineProperty({__proto__:null,default:Hme},Symbol.toStringTag,{value:"Module"}));const Qme={tagName:"l-select",name:"LSelect",components:{ElSelect:CW}};function Wme(e,t,r,o,a,i){const l=n.resolveComponent("el-select");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-select"}),n.createSlots({default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.prefix?{name:"prefix",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"prefix",{},void 0,!0)]),key:"0"}:void 0,e.$slots.empty?{name:"empty",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"empty",{},void 0,!0)]),key:"1"}:void 0]),1040)}const qme=xe(Qme,[["render",Wme],["__scopeId","data-v-5bb89c93"]]),Gme=Object.freeze(Object.defineProperty({__proto__:null,default:qme},Symbol.toStringTag,{value:"Module"}));const Kme={name:"LSwitch",components:{ElSwitch:KX},props:{modelValue:{type:Boolean,default:!1}},emits:["update:modelValue"],methods:{onUpdateModelValue(e){this.$emit("update:modelValue",e)}}};function Jme(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("el-switch");return n.openBlock(),n.createBlock(s,n.mergeProps(e.$attrs,{"model-value":r.modelValue,"onUpdate:modelValue":i.onUpdateModelValue,class:"l-switch"}),{"active-action":n.withCtx(()=>[n.createVNode(l,null,{default:n.withCtx(()=>t[0]||(t[0]=[n.createTextVNode("uil-check")])),_:1})]),"inactive-action":n.withCtx(()=>[n.createVNode(l,null,{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-times")])),_:1})]),default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["model-value","onUpdate:modelValue"])}const Zme=xe(Kme,[["render",Jme],["__scopeId","data-v-e8ddf878"]]),Xme=Object.freeze(Object.defineProperty({__proto__:null,default:Zme},Symbol.toStringTag,{value:"Module"}));/*!
|
|
41
|
+
*/var Ade={symbol:"$",separator:",",decimal:".",formatWithSymbol:!1,errorOnInvalid:!1,precision:2,pattern:"!#",negativePattern:"-!#"},i8=function(t){return Math.round(t)},Bh=function(t){return Math.pow(10,t)},Ode=function(t,r){return i8(t/r)*r},zde=/(\d)(?=(\d{3})+\b)/g,jde=/(\d)(?=(\d\d)+\d\b)/g;function Wr(e,t){var r=this;if(!(r instanceof Wr))return new Wr(e,t);var o=Object.assign({},Ade,t),a=Bh(o.precision),i=Qc(e,o);r.intValue=i,r.value=i/a,o.increment=o.increment||1/a,o.useVedic?o.groups=jde:o.groups=zde,this.s=o,this.p=a}function Qc(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=0,a=t.decimal,i=t.errorOnInvalid,l=t.precision,s=Bh(l),c=typeof e=="number";if(c||e instanceof Wr)o=(c?e:e.value)*s;else if(typeof e=="string"){var u=new RegExp("[^-\\d"+a+"]","g"),d=new RegExp("\\"+a,"g");o=e.replace(/\((.*)\)/,"-$1").replace(u,"").replace(d,".")*s,o=o||0}else{if(i)throw Error("Invalid Input");o=0}return o=o.toFixed(4),r?i8(o):o}Wr.prototype={add:function(t){var r=this.intValue,o=this.s,a=this.p;return Wr((r+=Qc(t,o))/a,o)},subtract:function(t){var r=this.intValue,o=this.s,a=this.p;return Wr((r-=Qc(t,o))/a,o)},multiply:function(t){var r=this.intValue,o=this.s;return Wr((r*=t)/Bh(o.precision),o)},divide:function(t){var r=this.intValue,o=this.s;return Wr(r/=Qc(t,o,!1),o)},distribute:function(t){for(var r=this.intValue,o=this.p,a=this.s,i=[],l=Math[r>=0?"floor":"ceil"](r/t),s=Math.abs(r-l*t);t!==0;t--){var c=Wr(l/o,a);s-- >0&&(c=r>=0?c.add(1/o):c.subtract(1/o)),i.push(c)}return i},dollars:function(){return~~this.value},cents:function(){var t=this.intValue,r=this.p;return~~(t%r)},format:function(t){var r=this.s,o=r.pattern,a=r.negativePattern,i=r.formatWithSymbol,l=r.symbol,s=r.separator,c=r.decimal,u=r.groups,d=(this+"").replace(/^-/,"").split("."),f=d[0],p=d[1];return typeof t>"u"&&(t=i),(this.value>=0?o:a).replace("!",t?l:"").replace("#","".concat(f.replace(u,"$1"+s)).concat(p?c+p:""))},toString:function(){var t=this.intValue,r=this.p,o=this.s;return Ode(t/r,o.increment).toFixed(o.precision)},toJSON:function(){return this.value}};const Lde={props:["filter","schema"],emits:["update:filter","change","cancel"],data(){return{form:{value:this.filter.value,comparison:this.filter.comparison||"gt"},inputValue:this.formatValue(this.filter.value)}},methods:{focus(){this.$refs.valueInput.focus()},formatValue(e){return e?(e/100).toFixed(2).replace(".",","):"0,00"},getAmount(e){return e?Wr(e,{decimal:","}).intValue:0},changeInput(){this.form.value=this.getAmount(this.inputValue),this.inputValue=this.formatValue(this.form.value)},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{rules(){return{value:[{required:!0,message:`Digite para filtrar ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`Escolha um modo para filtrar ${this.schema.title}`,trigger:"change"}]}}}};function Bde(e,t,r,o,a,i){const l=n.resolveComponent("el-input"),s=n.resolveComponent("l-form-item"),c=n.resolveComponent("l-radio"),u=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(u,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[6]||(t[6]=n.withModifiers(()=>{},["prevent"])),class:"form-wrapper"},{default:n.withCtx(()=>[n.createVNode(s,{prop:"value"},{default:n.withCtx(()=>[n.createVNode(l,{ref:"valueInput",modelValue:a.inputValue,"onUpdate:modelValue":t[0]||(t[0]=d=>a.inputValue=d),size:"small",onChange:i.changeInput},{default:n.withCtx(()=>t[7]||(t[7]=[n.createElementVNode("template",{slot:"prepend"},[n.createTextVNode("R$")],-1)])),_:1},8,["modelValue","onChange"])]),_:1}),n.createVNode(s,{prop:"comparison"},{default:n.withCtx(()=>[n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[1]||(t[1]=d=>a.form.comparison=d),label:"gt"},{default:n.withCtx(()=>t[8]||(t[8]=[n.createTextVNode("Maior que")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[2]||(t[2]=d=>a.form.comparison=d),label:"gte"},{default:n.withCtx(()=>t[9]||(t[9]=[n.createTextVNode("Maior que ou igual a")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[3]||(t[3]=d=>a.form.comparison=d),label:"eq"},{default:n.withCtx(()=>t[10]||(t[10]=[n.createTextVNode("Igual a")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[4]||(t[4]=d=>a.form.comparison=d),label:"lt"},{default:n.withCtx(()=>t[11]||(t[11]=[n.createTextVNode("Menor que")])),_:1},8,["modelValue"]),n.createVNode(c,{modelValue:a.form.comparison,"onUpdate:modelValue":t[5]||(t[5]=d=>a.form.comparison=d),label:"lte"},{default:n.withCtx(()=>t[12]||(t[12]=[n.createTextVNode("Menor que ou igual a")])),_:1},8,["modelValue"])]),_:1})]),_:1},8,["model","rules"])}const Vde=xe(Lde,[["render",Bde],["__scopeId","data-v-ec3d17bd"]]);const $de={props:["filter","schema"],emits:["update:filter","change","cancel"],data(){return Dt(this.schema,"options.enum")?{form:{value:this.filter.value||[],comparison:this.filter.comparison||"in"}}:{form:{value:this.filter.value,comparison:this.filter.comparison||"gte"}}},watch:{"form.comparison":{handler(){this.$nextTick(()=>this.focus())}}},methods:{focus(){this.$refs.valueInput&&this.$refs.valueInput[0].$el.focus()},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{valuesEnum(){return Dt(this.schema,"options.enum")},inlineComponent(){try{return this.$L.FieldTypeComponents.get(this.schema,"default")}catch{return null}},comparisons(){return[{label:this.$tds("less-than"),value:"lt"},{label:this.$tds("less-or-equal"),value:"lte"},{label:this.$tds("greater-than"),value:"gt"},{label:this.$tds("greater-or-equal"),value:"gte"},{label:this.$tds("equal"),value:"eq"},{label:this.$tds("different"),value:"neq"}]},rules(){return{value:[{required:!0,message:`${this.$tds("type-to-filter")} ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`${this.$tds("choose-a-mode-to-filter")} ${this.schema.title}`,trigger:"change"}]}}}},Pde=["textContent"];function Rde(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox"),s=n.resolveComponent("l-checkbox-group"),c=n.resolveComponent("l-form-item"),u=n.resolveComponent("l-radio"),d=n.resolveComponent("l-input"),f=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(f,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[3]||(t[3]=n.withModifiers(()=>{},["prevent"])),class:"editor-wrapper"},{default:n.withCtx(()=>[i.valuesEnum?(n.openBlock(),n.createBlock(c,{key:0,prop:"value"},{default:n.withCtx(()=>[n.createVNode(s,{modelValue:a.form.value,"onUpdate:modelValue":t[0]||(t[0]=p=>a.form.value=p),style:{display:"flex","flex-direction":"column"}},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.valuesEnum,p=>(n.openBlock(),n.createElementBlock("div",{key:p},[n.createVNode(l,{label:p},{default:n.withCtx(()=>[i.inlineComponent?(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.inlineComponent),{key:0,value:p,schema:r.schema},null,8,["value","schema"])):(n.openBlock(),n.createElementBlock("span",{key:1,textContent:n.toDisplayString(p)},null,8,Pde))]),_:2},1032,["label"])]))),128))]),_:1},8,["modelValue"])]),_:1})):(n.openBlock(),n.createBlock(c,{key:1,prop:"comparison"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.comparisons,p=>(n.openBlock(),n.createElementBlock("div",{key:p.value},[n.createVNode(u,{modelValue:a.form.comparison,"onUpdate:modelValue":t[1]||(t[1]=h=>a.form.comparison=h),label:p.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(p.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==p.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createVNode(d,{ref_for:!0,ref:"valueInput",type:"number",modelValue:a.form.value,"onUpdate:modelValue":t[2]||(t[2]=h=>a.form.value=h),modelModifiers:{number:!0}},null,8,["modelValue"])]),_:1})):n.createCommentVNode("",!0)]))),128))]),_:1}))]),_:1},8,["model","rules"])}const Fde=xe($de,[["render",Rde],["__scopeId","data-v-d486d53d"]]);const Ude={props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0},lang:{type:String,default(){return pn()}}},emits:["update:filter","change","cancel"],data(){return{form:{value:this.filter.value,comparison:this.filter.comparison||"relative_past_gte"}}},watch:{"form.comparison":{handler(e,t){t.indexOf("relative_")===0&&e.indexOf("absolute_")===0?this.form.value=new Date:t.indexOf("absolute_")===0&&e.indexOf("relative_")===0&&(this.form.value=1),this.$nextTick(()=>this.focus())}}},methods:{focus(){this.$refs.valueInput&&this.$refs.valueInput.length>0&&this.$refs.valueInput[0].$el.focus()},validate(e){return this.$refs.form.validate(e)},save(){this.$refs.form.validate(e=>{if(e){const t={...this.filter,valid:e,value:this.form.value,comparison:this.form.comparison};this.$emit("update:filter",t),this.$emit("change",t)}})},cancel(){this.form.value=this.filter.value,this.form.comparison=this.filter.comparison,this.$emit("cancel")}},computed:{relativePastComparisons(){return[{label:this.$tds("date-relative-comparation-lt"),value:"relative_past_gte"},{label:this.$tds("date-relative-comparation-gt"),value:"relative_past_lt"},{label:this.$tds("date-relative-comparation-eq"),value:"relative_past_eq"}]},relativeFutureComparisons(){return[{label:this.$tds("date-relative-future-gt"),value:"relative_future_gte"},{label:this.$tds("date-relative-future-lt"),value:"relative_future_lt"},{label:this.$tds("date-relative-future-eq"),value:"relative_future_eq"}]},absoluteComparisons(){return[{label:this.$tds("date-absolute-eq"),value:"absolute_eq"},{label:this.$tds("date-absolute-gte"),value:"absolute_gte"},{label:this.$tds("date-absolute-lt"),value:"absolute_lt"}]},rules(){return{value:[{required:!0,message:`${this.$tds("type-to-filter")} ${this.schema.title}`,trigger:"change"}],comparison:[{required:!0,message:`${this.$tds("choose-a-mode-to-filter")} ${this.schema.title}`,trigger:"change"}]}}}},Hde={class:"row"},Yde={style:{"margin-left":"8px","white-space":"nowrap"}},Qde={class:"row"},Wde={style:{"margin-left":"8px","white-space":"nowrap"}},qde={class:"row"};function Gde(e,t,r,o,a,i){const l=n.resolveComponent("l-radio"),s=n.resolveComponent("l-input"),c=n.resolveComponent("l-form-item"),u=n.resolveComponent("l-date-picker"),d=n.resolveComponent("l-form");return n.openBlock(),n.createBlock(d,{model:a.form,rules:i.rules,ref:"form",onSubmit:t[6]||(t[6]=n.withModifiers(()=>{},["prevent"]))},{default:n.withCtx(()=>[n.createVNode(c,{prop:"comparison",class:"item-wrapper",style:{"margin-bottom":"0"}},{default:n.withCtx(()=>[n.createElementVNode("strong",null,n.toDisplayString(e.$tds("date-editor-relative-past")),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.relativePastComparisons,f=>(n.openBlock(),n.createElementBlock("div",{key:f.value},[n.createVNode(l,{modelValue:a.form.comparison,"onUpdate:modelValue":t[0]||(t[0]=p=>a.form.comparison=p),label:f.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==f.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createElementVNode("div",Hde,[n.createVNode(s,{type:"number",min:"1",ref_for:!0,ref:"valueInput",modelValue:a.form.value,"onUpdate:modelValue":t[1]||(t[1]=p=>a.form.value=p),modelModifiers:{number:!0},size:"small"},null,8,["modelValue"]),n.createElementVNode("div",Yde,n.toDisplayString(a.form.value>1?"dias":"dia"),1)])]),_:1})):n.createCommentVNode("",!0)]))),128)),n.createElementVNode("strong",null,n.toDisplayString(e.$tds("date-editor-relative-future")),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.relativeFutureComparisons,f=>(n.openBlock(),n.createElementBlock("div",{key:f.value},[n.createVNode(l,{modelValue:a.form.comparison,"onUpdate:modelValue":t[2]||(t[2]=p=>a.form.comparison=p),label:f.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==f.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value",style:{"margin-left":"24px","margin-bottom":"8px"}},{default:n.withCtx(()=>[n.createElementVNode("div",Qde,[n.createVNode(s,{type:"number",min:"1",ref_for:!0,ref:"valueInput",modelValue:a.form.value,"onUpdate:modelValue":t[3]||(t[3]=p=>a.form.value=p),modelModifiers:{number:!0},size:"small"},null,8,["modelValue"]),n.createElementVNode("div",Wde,n.toDisplayString(a.form.value>1?"dias":"dia"),1)])]),_:1})):n.createCommentVNode("",!0)]))),128)),n.createElementVNode("strong",null,n.toDisplayString(e.$tds("date-editor-absolute")),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.absoluteComparisons,f=>(n.openBlock(),n.createElementBlock("div",{key:f.value},[n.createVNode(l,{modelValue:a.form.comparison,"onUpdate:modelValue":t[4]||(t[4]=p=>a.form.comparison=p),label:f.value},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.label),1)]),_:2},1032,["modelValue","label"]),a.form.comparison==f.value?(n.openBlock(),n.createBlock(c,{key:0,prop:"value"},{default:n.withCtx(()=>[n.createElementVNode("div",qde,[n.createVNode(u,{modelValue:a.form.value,"onUpdate:modelValue":t[5]||(t[5]=p=>a.form.value=p)},null,8,["modelValue"])])]),_:1})):n.createCommentVNode("",!0)]))),128))]),_:1})]),_:1},8,["model","rules"])}const Kde=xe(Ude,[["render",Gde],["__scopeId","data-v-1d6bf98b"]]),l8={};l8.register=function(){Sn.register({type:"String"},"filterChipEditor",Ide),Sn.register({type:"Number"},"filterChipEditor",Fde),Sn.register({type:"Date"},"filterChipEditor",Kde),Sn.register({format:"Amount"},"filterChipEditor",Vde)};const Jde={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}},computed:{inlineComponent(){try{return this.$L.FieldTypeComponents.get(this.schema,"textOnly")}catch{return null}},comparisonLabel(){return console.log("filter",this.filter),{in:"é",eq:"é",neq:"não é",starts_with:"começa com",ends_with:"termina com",contains:"contém"}[this.filter.comparison]||""}}},Zde={key:1},Xde={key:0},efe={key:1};function tfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),n.createTextVNode(" "+n.toDisplayString(i.comparisonLabel)+" ",1),r.filter.comparison==="in"?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:0},n.renderList(r.filter.value,(s,c)=>(n.openBlock(),n.createElementBlock("span",{key:c},[i.inlineComponent?(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.inlineComponent),{key:0,value:s,schema:r.schema},null,8,["value","schema"])):(n.openBlock(),n.createElementBlock("span",Zde,n.toDisplayString(s),1)),c<r.filter.value.length-1?(n.openBlock(),n.createElementBlock(n.Fragment,{key:2},[c<r.filter.value.length-2?(n.openBlock(),n.createElementBlock("span",Xde,", ")):(n.openBlock(),n.createElementBlock("span",efe," ou "))],64)):n.createCommentVNode("",!0)]))),128)):(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createTextVNode('"'+n.toDisplayString(r.filter.value)+'"',1)],64))])}const nfe=xe(Jde,[["render",tfe]]),rfe={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}},computed:{formattedValue(){return new Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL"}).format(this.filter.value/100)}}},ofe={key:0},afe={key:1},ife={key:2},lfe={key:3},sfe={key:4};function cfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),t[1]||(t[1]=n.createTextVNode(" ")),r.filter.comparison==="eq"?(n.openBlock(),n.createElementBlock("span",ofe,"=")):r.filter.comparison==="lt"?(n.openBlock(),n.createElementBlock("span",afe,"<")):r.filter.comparison==="lte"?(n.openBlock(),n.createElementBlock("span",ife,"<=")):r.filter.comparison==="gt"?(n.openBlock(),n.createElementBlock("span",lfe,">")):r.filter.comparison==="gte"?(n.openBlock(),n.createElementBlock("span",sfe,">=")):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(i.formattedValue),1)])}const ufe=xe(rfe,[["render",cfe]]),dfe={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}}},ffe={key:0},pfe={key:1},mfe={key:2},hfe={key:3},gfe={key:4},vfe={key:5};function yfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),t[1]||(t[1]=n.createTextVNode(" ")),r.filter.comparison==="eq"?(n.openBlock(),n.createElementBlock("span",ffe,"=")):r.filter.comparison==="neq"?(n.openBlock(),n.createElementBlock("span",pfe,"≠")):r.filter.comparison==="lt"?(n.openBlock(),n.createElementBlock("span",mfe,"<")):r.filter.comparison==="lte"?(n.openBlock(),n.createElementBlock("span",hfe,"≤")):r.filter.comparison==="gt"?(n.openBlock(),n.createElementBlock("span",gfe,">")):r.filter.comparison==="gte"?(n.openBlock(),n.createElementBlock("span",vfe,"≥")):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(r.filter.value),1)])}const Mfe=xe(dfe,[["render",yfe]]),bfe={name:"FilterDisplay",props:{filter:{type:Object,required:!0},schema:{type:Object,required:!0}},computed:{comparisonLabel(){const e={relative_past_gte:"há menos de",relative_past_lt:"há mais de",relative_past_eq:"há exatamente",relative_future_gte:"daqui a mais de",relative_future_lt:"daqui a menos de",relative_future_eq:"daqui a exatamente",absolute_eq:"em",absolute_gte:"a partir de",absolute_lt:"até"};return console.log("filter",this.filter),e[this.filter.comparison]||""},formattedValue(){if(!this.filter.value)return"-";if(this.filter.comparison.startsWith("relative_"))return`${this.filter.value} ${this.filter.value>1?"dias":"dia"}`;const e=Dt(this.schema,"options.format","LL");return Nd(this.filter.value).format(e)}}};function wfe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("span",null,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),t[0]||(t[0]=n.createTextVNode(" ")),n.createElementVNode("strong",null,n.toDisplayString(r.schema.title),1),n.createTextVNode(" "+n.toDisplayString(i.comparisonLabel)+" "+n.toDisplayString(i.formattedValue),1)])}const Nfe=xe(bfe,[["render",wfe]]),s8={};s8.register=function(){Sn.register({type:"String"},"filterChipView",nfe),Sn.register({type:"Number"},"filterChipView",Mfe),Sn.register({type:"Date"},"filterChipView",Nfe),Sn.register({format:"Amount"},"filterChipView",ufe)};l8.register();s8.register();const kfe={name:"FilterChip",props:{filter:Object,schema:Object,lang:{type:String,default(){return pn()}}},components:{ElPopover:NZ},data(){return{editing:!1,localFilter:{...this.filter}}},watch:{filter(e){this.localFilter={...e}}},mounted(){(!this.$refs.editor||!this.$refs.view)&&this.remove(),this.$refs.editor&&this.$refs.editor.validate&&this.$refs.editor.validate(e=>{e||(this.editing=!0)})},methods:{toggleEditing(){this.editing=!this.editing},afterEnterPopover(){this.$refs.editor&&this.$refs.editor.focus&&this.$refs.editor.focus()},cancel(){this.editing=!1,this.$refs.editor&&this.$refs.editor.validate&&this.$refs.editor.validate(e=>{e||this.remove()})},change(){this.editing=!1},remove(){this.$emit("onRemove")},updateFilter(e){this.localFilter=e,this.$emit("update:filter",e)}},computed:{editorComponent(){return this.$L.FieldTypeComponents.get(this.schema,"filterChipEditor")},viewComponent(){return this.$L.FieldTypeComponents.get(this.schema,"filterChipView")}}},xfe={class:"filter-title"},Cfe={class:"confirmation-buttons"};function Efe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button"),c=n.resolveComponent("el-popover");return n.openBlock(),n.createBlock(c,{"popper-class":"filter-chip-popper",class:"filter-chip",placement:"bottom-start",width:"288",trigger:"manual",visible:a.editing,"onUpdate:visible":t[2]||(t[2]=u=>a.editing=u),onAfterEnter:i.afterEnterPopover},{reference:n.withCtx(()=>[n.createVNode(s,{type:"primary",round:"",size:"small",onClick:i.toggleEditing},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.viewComponent),{ref:"view",schema:r.schema,filter:a.localFilter},null,8,["schema","filter"])),n.createVNode(l,{onClick:n.withModifiers(i.remove,["stop"]),class:"close-button"},{default:n.withCtx(()=>t[3]||(t[3]=[n.createTextVNode(" uil-times-circle ")])),_:1},8,["onClick"])]),_:1},8,["onClick"])]),default:n.withCtx(()=>[n.createElementVNode("div",xfe,[n.createVNode(l,null,{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$L.Icons.get(r.schema)),1)]),_:1}),n.createTextVNode(" "+n.toDisplayString(r.schema.title),1)]),t[4]||(t[4]=n.createElementVNode("br",null,null,-1)),(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.editorComponent),{ref:"editor",filter:a.localFilter,"onUpdate:filter":i.updateFilter,schema:r.schema,onCancel:i.cancel,onChange:i.change,class:"filter-form"},null,40,["filter","onUpdate:filter","schema","onCancel","onChange"])),n.createElementVNode("div",Cfe,[n.createVNode(s,{plain:"",size:"small",onClick:t[0]||(t[0]=u=>this.$refs.editor.cancel())},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("cancel")),1)]),_:1}),n.createVNode(s,{type:"primary",size:"small",onClick:t[1]||(t[1]=u=>this.$refs.editor.save())},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("search")),1)]),_:1})])]),_:1},8,["visible","onAfterEnter"])}const Tfe=xe(kfe,[["render",Efe]]);const Dfe={tagName:"l-search-bar",emits:["update:modelValue","change"],props:{availableModes:{type:Array,default:()=>["simple"]},modelValue:{type:Object,default(e){return{mode:e.availableModes[0],queryText:"",filters:[]}}},schema:{type:Object,default:()=>({})},disabled:{type:Boolean,default:!1},lang:{type:String,default(){return pn()}}},data(){return{mode:Dt(this.value,"mode",this.availableModes[0]),queryText:Dt(this.value,"queryText",""),filters:$n(Dt(this.value,"filters",[]))}},watch:{modelValue(e){this.mode=Dt(e,"mode",this.availableModes[0]),this.queryText=Dt(e,"queryText","");const t=Dt(e,"filters",[]);hce(this.filters,t)||(this.filters=$n(t))},queryValue:{deep:!0,handler(e){this.isValid&&(this.$emit("change",$n(e)),this.$emit("update:modelValue",$n(e)))}}},methods:{getFilterSchema(e){const{path:t}=e;return this.schema.fields.find(r=>r.path===t)},updateFilter(e){const t=v4(this.filters,e);this.filters.splice(t,1,e)},addFilter(e){this.filters.push(Object.assign({},e))},removeFilter(e){const t=v4(this.filters,e);this.filters.splice(t,1)},clear(){switch(this.mode){case"simple":this.queryText="";return;case"advanced":this.filters.splice(0,this.filters.length);return;default:throw new Error(`Unknown mode ${this.mode}`)}}},computed:{queryValue(){return{mode:this.mode,queryText:this.queryText,filters:this.filters}},isValid(){return this.filters.filter(e=>!e.valid).length===0},availableModesOptions(){return[{icon:"uil-search",value:"simple",title:this.$tds("simple-filter",this.lang)},{icon:"uil-filter",value:"advanced",title:this.$tds("advanced-filter",this.lang)}].filter(e=>this.availableModes.includes(e.value))},showClearButton(){switch(this.mode){case"simple":return this.queryText.length>0;case"advanced":return this.filters.length>0;default:throw new Error(`Unknown mode ${this.mode}`)}}},components:{AddFilterButton:Tde,FilterChip:Tfe}},Sfe={key:1,class:"filters"},_fe={class:"clear-button"};function Ife(e,t,r,o,a,i){const l=n.resolveComponent("l-toggle-button-group"),s=n.resolveComponent("l-input"),c=n.resolveComponent("filter-chip"),u=n.resolveComponent("add-filter-button"),d=n.resolveComponent("l-icon"),f=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass([{disabled:r.disabled},"l-search-bar"])},[n.createVNode(l,{disabled:r.disabled,modelValue:a.mode,"onUpdate:modelValue":t[0]||(t[0]=p=>a.mode=p),options:i.availableModesOptions},null,8,["disabled","modelValue","options"]),a.mode==="simple"?(n.openBlock(),n.createBlock(s,{key:0,disabled:r.disabled,size:"large",modelValue:a.queryText,"onUpdate:modelValue":t[1]||(t[1]=p=>a.queryText=p),style:{flex:"1 1 auto"},placeholder:r.disabled?"":e.$tds("search-placeholder",r.lang),"input-style":"border: 0"},null,8,["disabled","modelValue","placeholder"])):(n.openBlock(),n.createElementBlock("div",Sfe,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.filters,p=>(n.openBlock(),n.createBlock(c,{key:p.path,filter:p,schema:i.getFilterSchema(p),"onUpdate:filter":i.updateFilter,onOnRemove:h=>i.removeFilter(p)},null,8,["filter","schema","onUpdate:filter","onOnRemove"]))),128)),n.createVNode(u,{schema:r.schema,filters:a.filters,lang:r.lang,onAddFilter:i.addFilter},null,8,["schema","filters","lang","onAddFilter"])])),n.createElementVNode("div",_fe,[n.withDirectives(n.createVNode(f,{type:"text",onClick:i.clear},{default:n.withCtx(()=>[n.createVNode(d,null,{default:n.withCtx(()=>t[2]||(t[2]=[n.createTextVNode("uil-times")])),_:1})]),_:1},8,["onClick"]),[[n.vShow,i.showClearButton]])])],2)}const Afe=xe(Dfe,[["render",Ife]]),Ofe=Object.freeze(Object.defineProperty({__proto__:null,default:Afe},Symbol.toStringTag,{value:"Module"}));var zfe=jr,jfe=function(){return zfe.Date.now()},Lfe=jfe,Bfe=Lr,Uf=Lfe,y4=r8,Vfe="Expected a function",$fe=Math.max,Pfe=Math.min;function Rfe(e,t,r){var o,a,i,l,s,c,u=0,d=!1,f=!1,p=!0;if(typeof e!="function")throw new TypeError(Vfe);t=y4(t)||0,Bfe(r)&&(d=!!r.leading,f="maxWait"in r,i=f?$fe(y4(r.maxWait)||0,t):i,p="trailing"in r?!!r.trailing:p);function h(w){var C=o,E=a;return o=a=void 0,u=w,l=e.apply(E,C),l}function m(w){return u=w,s=setTimeout(y,t),d?h(w):l}function g(w){var C=w-c,E=w-u,A=t-C;return f?Pfe(A,i-E):A}function v(w){var C=w-c,E=w-u;return c===void 0||C>=t||C<0||f&&E>=i}function y(){var w=Uf();if(v(w))return N(w);s=setTimeout(y,g(w))}function N(w){return s=void 0,p&&o?h(w):(o=a=void 0,l)}function b(){s!==void 0&&clearTimeout(s),u=0,o=c=a=s=void 0}function M(){return s===void 0?l:N(Uf())}function k(){var w=Uf(),C=v(w);if(o=arguments,a=this,c=w,C){if(s===void 0)return m(c);if(f)return clearTimeout(s),s=setTimeout(y,t),h(c)}return s===void 0&&(s=setTimeout(y,t)),l}return k.cancel=b,k.flush=M,k}var Ffe=Rfe;const Ufe=St(Ffe);function Hfe(e){return e!==e}var Yfe=Hfe;function Qfe(e,t,r){for(var o=r-1,a=e.length;++o<a;)if(e[o]===t)return o;return-1}var Wfe=Qfe,qfe=e8,Gfe=Yfe,Kfe=Wfe;function Jfe(e,t,r){return t===t?Kfe(e,t,r):qfe(e,Gfe,r)}var Zfe=Jfe,Xfe=Zfe;function epe(e,t){var r=e==null?0:e.length;return!!r&&Xfe(e,t,0)>-1}var c8=epe;function tpe(e,t,r){for(var o=-1,a=e==null?0:e.length;++o<a;)if(r(t,e[o]))return!0;return!1}var u8=tpe,npe=Ah,rpe=c8,ope=u8,ape=Bb,ipe=_d,lpe=Oh,spe=200;function cpe(e,t,r,o){var a=-1,i=rpe,l=!0,s=e.length,c=[],u=t.length;if(!s)return c;r&&(t=ape(t,ipe(r))),o?(i=ope,l=!1):t.length>=spe&&(i=lpe,l=!1,t=new npe(t));e:for(;++a<s;){var d=e[a],f=r==null?d:r(d);if(d=o||d!==0?d:0,l&&f===f){for(var p=u;p--;)if(t[p]===f)continue e;c.push(d)}else i(t,f,o)||c.push(d)}return c}var upe=cpe,M4=nl,dpe=Dd,fpe=vr,b4=M4?M4.isConcatSpreadable:void 0;function ppe(e){return fpe(e)||dpe(e)||!!(b4&&e&&e[b4])}var mpe=ppe,hpe=Ih,gpe=mpe;function d8(e,t,r,o,a){var i=-1,l=e.length;for(r||(r=gpe),a||(a=[]);++i<l;){var s=e[i];t>0&&r(s)?t>1?d8(s,t-1,r,o,a):hpe(a,s):o||(a[a.length]=s)}return a}var f8=d8,vpe=upe,ype=f8,Mpe=My,w4=py,bpe=Mpe(function(e,t){return w4(e)?vpe(e,ype(t,1,w4,!0)):[]}),wpe=bpe;const Npe=St(wpe),$a=e=>e!=null,v0=e=>typeof e=="function",Vh=e=>e!==null&&typeof e=="object",kpe=e=>Vh(e)&&v0(e.then)&&v0(e.catch),p8=e=>typeof e=="number"||/^\d+(\.\d+)?$/.test(e),xpe=()=>Epe?/ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase()):!1;function Cpe(){}const Gs=Object.assign,Epe=typeof window<"u";function N4(e,t){const r=t.split(".");let o=e;return r.forEach(a=>{var i;o=Vh(o)&&(i=o[a])!=null?i:""}),o}function Tpe(e,t,r){return t.reduce((o,a)=>((!r||e[a]!==void 0)&&(o[a]=e[a]),o),{})}const m8=null,no=[Number,String],Dr={type:Boolean,default:!0},Dpe=()=>({type:Array,default:()=>[]}),vo=e=>({type:String,default:e});var $h=typeof window<"u";function h8(e){let t;n.onMounted(()=>{e(),n.nextTick(()=>{t=!0})}),n.onActivated(()=>{t&&e()})}function g8(e,t,r={}){if(!$h)return;const{target:o=window,passive:a=!1,capture:i=!1}=r;let l=!1,s;const c=f=>{if(l)return;const p=n.unref(f);p&&!s&&(p.addEventListener(e,t,{capture:i,passive:a}),s=!0)},u=f=>{if(l)return;const p=n.unref(f);p&&s&&(p.removeEventListener(e,t,i),s=!1)};n.onUnmounted(()=>u(o)),n.onDeactivated(()=>u(o)),h8(()=>c(o));let d;return n.isRef(o)&&(d=n.watch(o,(f,p)=>{u(p),c(f)})),()=>{d==null||d(),u(o),l=!0}}var Nc,Hf;function Spe(){if(!Nc&&(Nc=n.ref(0),Hf=n.ref(0),$h)){const e=()=>{Nc.value=window.innerWidth,Hf.value=window.innerHeight};e(),window.addEventListener("resize",e,{passive:!0}),window.addEventListener("orientationchange",e,{passive:!0})}return{width:Nc,height:Hf}}var _pe=/scroll|auto|overlay/i,Ipe=$h?window:void 0;function Ape(e){return e.tagName!=="HTML"&&e.tagName!=="BODY"&&e.nodeType===1}function Ope(e,t=Ipe){let r=e;for(;r&&r!==t&&Ape(r);){const{overflowY:o}=window.getComputedStyle(r);if(_pe.test(o))return r;r=r.parentNode}return t}xpe();const zpe=e=>e.stopPropagation();function v8(e,t){(typeof e.cancelable!="boolean"||e.cancelable)&&e.preventDefault(),t&&zpe(e)}Spe();function ho(e){if($a(e))return p8(e)?`${e}px`:String(e)}function jpe(e){if($a(e)){if(Array.isArray(e))return{width:ho(e[0]),height:ho(e[1])};const t=ho(e);return{width:t,height:t}}}function Lpe(e){const t={};return e!==void 0&&(t.zIndex=+e),t}const Bpe=/-(\w)/g,y8=e=>e.replace(Bpe,(t,r)=>r.toUpperCase()),Vpe=e=>e.replace(/([A-Z])/g,"-$1").toLowerCase().replace(/^-/,""),{hasOwnProperty:$pe}=Object.prototype;function Ppe(e,t,r){const o=t[r];$a(o)&&(!$pe.call(e,r)||!Vh(o)?e[r]=o:e[r]=M8(Object(e[r]),o))}function M8(e,t){return Object.keys(t).forEach(r=>{Ppe(e,t,r)}),e}var Rpe={name:"姓名",tel:"电话",save:"保存",confirm:"确认",cancel:"取消",delete:"删除",loading:"加载中...",noCoupon:"暂无优惠券",nameEmpty:"请填写姓名",addContact:"添加联系人",telInvalid:"请填写正确的电话",vanCalendar:{end:"结束",start:"开始",title:"日期选择",weekdays:["日","一","二","三","四","五","六"],monthTitle:(e,t)=>`${e}年${t}月`,rangePrompt:e=>`最多选择 ${e} 天`},vanCascader:{select:"请选择"},vanPagination:{prev:"上一页",next:"下一页"},vanPullRefresh:{pulling:"下拉即可刷新...",loosing:"释放即可刷新..."},vanSubmitBar:{label:"合计:"},vanCoupon:{unlimited:"无门槛",discount:e=>`${e}折`,condition:e=>`满${e}元可用`},vanCouponCell:{title:"优惠券",count:e=>`${e}张可用`},vanCouponList:{exchange:"兑换",close:"不使用",enable:"可用",disabled:"不可用",placeholder:"输入优惠码"},vanAddressEdit:{area:"地区",postal:"邮政编码",areaEmpty:"请选择地区",addressEmpty:"请填写详细地址",postalEmpty:"邮政编码不正确",addressDetail:"详细地址",defaultAddress:"设为默认收货地址"},vanAddressList:{add:"新增地址"}};const k4=n.ref("zh-CN"),x4=n.reactive({"zh-CN":Rpe}),Fpe={messages(){return x4[k4.value]},use(e,t){k4.value=e,this.add({[e]:t})},add(e={}){M8(x4,e)}};var Upe=Fpe;function Hpe(e){const t=y8(e)+".";return(r,...o)=>{const a=Upe.messages(),i=N4(a,t+r)||N4(a,r);return v0(i)?i(...o):i}}function y0(e,t){return t?typeof t=="string"?` ${e}--${t}`:Array.isArray(t)?t.reduce((r,o)=>r+y0(e,o),""):Object.keys(t).reduce((r,o)=>r+(t[o]?y0(e,o):""),""):""}function Ype(e){return(t,r)=>(t&&typeof t!="string"&&(r=t,t=""),t=t?`${e}__${t}`:e,`${t}${y0(t,r)}`)}function Za(e){const t=`van-${e}`;return[t,Ype(t),Hpe(t)]}const b8="van-haptics-feedback";function Qpe(e,{args:t=[],done:r,canceled:o}){if(e){const a=e.apply(null,t);kpe(a)?a.then(i=>{i?r():o&&o()}).catch(Cpe):a?r():o&&o()}else r()}function ml(e){return e.install=t=>{const{name:r}=e;r&&(t.component(r,e),t.component(y8(`-${r}`),e))},e}const Wpe=Symbol();function qpe(e){const t=n.getCurrentInstance();t&&Gs(t.proxy,e)}const[Gpe,C4]=Za("badge"),Kpe={dot:Boolean,max:no,tag:vo("div"),color:String,offset:Array,content:no,showZero:Dr,position:vo("top-right")};var Jpe=n.defineComponent({name:Gpe,props:Kpe,setup(e,{slots:t}){const r=()=>{if(t.content)return!0;const{content:l,showZero:s}=e;return $a(l)&&l!==""&&(s||l!==0&&l!=="0")},o=()=>{const{dot:l,max:s,content:c}=e;if(!l&&r())return t.content?t.content():$a(s)&&p8(c)&&+c>s?`${s}+`:c},a=n.computed(()=>{const l={background:e.color};if(e.offset){const[s,c]=e.offset;t.default?(l.top=ho(c),typeof s=="number"?l.right=ho(-s):l.right=s.startsWith("-")?s.replace("-",""):`-${s}`):(l.marginTop=ho(c),l.marginLeft=ho(s))}return l}),i=()=>{if(r()||e.dot)return n.createVNode("div",{class:C4([e.position,{dot:e.dot,fixed:!!t.default}]),style:a.value},[o()])};return()=>{if(t.default){const{tag:l}=e;return n.createVNode(l,{class:C4("wrapper")},{default:()=>[t.default(),i()]})}return i()}}});const Zpe=ml(Jpe);let w8=2e3;const Xpe=()=>++w8,e0e=e=>{w8=e},[N8,t0e]=Za("config-provider"),k8=Symbol(N8),n0e={tag:vo("div"),zIndex:Number,themeVars:Object,iconPrefix:String};function r0e(e){const t={};return Object.keys(e).forEach(r=>{t[`--van-${Vpe(r)}`]=e[r]}),t}n.defineComponent({name:N8,props:n0e,setup(e,{slots:t}){const r=n.computed(()=>{if(e.themeVars)return r0e(e.themeVars)});return n.provide(k8,e),n.watchEffect(()=>{e.zIndex!==void 0&&e0e(e.zIndex)}),()=>n.createVNode(e.tag,{class:t0e(),style:r.value},{default:()=>{var o;return[(o=t.default)==null?void 0:o.call(t)]}})}});const[o0e,E4]=Za("icon"),a0e=e=>e==null?void 0:e.includes("/"),i0e={dot:Boolean,tag:vo("i"),name:String,size:no,badge:no,color:String,badgeProps:Object,classPrefix:String};var l0e=n.defineComponent({name:o0e,props:i0e,setup(e,{slots:t}){const r=n.inject(k8,null),o=n.computed(()=>e.classPrefix||(r==null?void 0:r.iconPrefix)||E4());return()=>{const{tag:a,dot:i,name:l,size:s,badge:c,color:u}=e,d=a0e(l);return n.createVNode(Zpe,n.mergeProps({dot:i,tag:a,class:[o.value,d?"":`${o.value}-${l}`],style:{color:u,fontSize:ho(s)},content:c},e.badgeProps),{default:()=>{var f;return[(f=t.default)==null?void 0:f.call(t),d&&n.createVNode("img",{class:E4("image"),src:l},null)]}})}}});const x8=ml(l0e),[s0e,Ul]=Za("loading"),c0e=Array(12).fill(null).map((e,t)=>n.createVNode("i",{class:Ul("line",String(t+1))},null)),u0e=n.createVNode("svg",{class:Ul("circular"),viewBox:"25 25 50 50"},[n.createVNode("circle",{cx:"50",cy:"50",r:"20",fill:"none"},null)]),d0e={size:no,type:vo("circular"),color:String,vertical:Boolean,textSize:no,textColor:String};var f0e=n.defineComponent({name:s0e,props:d0e,setup(e,{slots:t}){const r=n.computed(()=>Gs({color:e.color},jpe(e.size))),o=()=>{var a;if(t.default)return n.createVNode("span",{class:Ul("text"),style:{fontSize:ho(e.textSize),color:(a=e.textColor)!=null?a:e.color}},[t.default()])};return()=>{const{type:a,vertical:i}=e;return n.createVNode("div",{class:Ul([a,{vertical:i}]),"aria-live":"polite","aria-busy":!0},[n.createVNode("span",{class:Ul("spinner",a),style:r.value},[a==="spinner"?c0e:u0e]),o()])}}});const p0e=ml(f0e),Ph={show:Boolean,zIndex:no,overlay:Dr,duration:no,teleport:[String,Object],lockScroll:Dr,lazyRender:Dr,beforeClose:Function,overlayStyle:Object,overlayClass:m8,transitionAppear:Boolean,closeOnClickOverlay:Dr},m0e=Object.keys(Ph);function h0e(e,t){return e>t?"horizontal":t>e?"vertical":""}function g0e(){const e=n.ref(0),t=n.ref(0),r=n.ref(0),o=n.ref(0),a=n.ref(0),i=n.ref(0),l=n.ref(""),s=()=>l.value==="vertical",c=()=>l.value==="horizontal",u=()=>{r.value=0,o.value=0,a.value=0,i.value=0,l.value=""};return{move:p=>{const h=p.touches[0];r.value=(h.clientX<0?0:h.clientX)-e.value,o.value=h.clientY-t.value,a.value=Math.abs(r.value),i.value=Math.abs(o.value);const m=10;(!l.value||a.value<m&&i.value<m)&&(l.value=h0e(a.value,i.value))},start:p=>{u(),e.value=p.touches[0].clientX,t.value=p.touches[0].clientY},reset:u,startX:e,startY:t,deltaX:r,deltaY:o,offsetX:a,offsetY:i,direction:l,isVertical:s,isHorizontal:c}}let xl=0;const T4="van-overflow-hidden";function v0e(e,t){const r=g0e(),o="01",a="10",i=d=>{r.move(d);const f=r.deltaY.value>0?a:o,p=Ope(d.target,e.value),{scrollHeight:h,offsetHeight:m,scrollTop:g}=p;let v="11";g===0?v=m>=h?"00":"01":g+m>=h&&(v="10"),v!=="11"&&r.isVertical()&&!(parseInt(v,2)&parseInt(f,2))&&v8(d,!0)},l=()=>{document.addEventListener("touchstart",r.start),document.addEventListener("touchmove",i,{passive:!1}),xl||document.body.classList.add(T4),xl++},s=()=>{xl&&(document.removeEventListener("touchstart",r.start),document.removeEventListener("touchmove",i),xl--,xl||document.body.classList.remove(T4))},c=()=>t()&&l(),u=()=>t()&&s();h8(c),n.onDeactivated(u),n.onBeforeUnmount(u),n.watch(t,d=>{d?l():s()})}function C8(e){const t=n.ref(!1);return n.watch(e,r=>{r&&(t.value=r)},{immediate:!0}),r=>()=>t.value?r():null}const[y0e,M0e]=Za("overlay"),b0e={show:Boolean,zIndex:no,duration:no,className:m8,lockScroll:Dr,lazyRender:Dr,customStyle:Object};var w0e=n.defineComponent({name:y0e,props:b0e,setup(e,{slots:t}){const r=n.ref(),o=C8(()=>e.show||!e.lazyRender),a=l=>{e.lockScroll&&v8(l,!0)},i=o(()=>{var l;const s=Gs(Lpe(e.zIndex),e.customStyle);return $a(e.duration)&&(s.animationDuration=`${e.duration}s`),n.withDirectives(n.createVNode("div",{ref:r,style:s,class:[M0e(),e.className]},[(l=t.default)==null?void 0:l.call(t)]),[[n.vShow,e.show]])});return g8("touchmove",a,{target:r}),()=>n.createVNode(n.Transition,{name:"van-fade",appear:!0},{default:i})}});const N0e=ml(w0e),k0e=Gs({},Ph,{round:Boolean,position:vo("center"),closeIcon:vo("cross"),closeable:Boolean,transition:String,iconPrefix:String,closeOnPopstate:Boolean,closeIconPosition:vo("top-right"),safeAreaInsetTop:Boolean,safeAreaInsetBottom:Boolean}),[x0e,D4]=Za("popup");var C0e=n.defineComponent({name:x0e,inheritAttrs:!1,props:k0e,emits:["open","close","opened","closed","keydown","update:show","click-overlay","click-close-icon"],setup(e,{emit:t,attrs:r,slots:o}){let a,i;const l=n.ref(),s=n.ref(),c=C8(()=>e.show||!e.lazyRender),u=n.computed(()=>{const k={zIndex:l.value};if($a(e.duration)){const w=e.position==="center"?"animationDuration":"transitionDuration";k[w]=`${e.duration}s`}return k}),d=()=>{a||(a=!0,l.value=e.zIndex!==void 0?+e.zIndex:Xpe(),t("open"))},f=()=>{a&&Qpe(e.beforeClose,{done(){a=!1,t("close"),t("update:show",!1)}})},p=k=>{t("click-overlay",k),e.closeOnClickOverlay&&f()},h=()=>{if(e.overlay)return n.createVNode(N0e,{show:e.show,class:e.overlayClass,zIndex:l.value,duration:e.duration,customStyle:e.overlayStyle,role:e.closeOnClickOverlay?"button":void 0,tabindex:e.closeOnClickOverlay?0:void 0,onClick:p},{default:o["overlay-content"]})},m=k=>{t("click-close-icon",k),f()},g=()=>{if(e.closeable)return n.createVNode(x8,{role:"button",tabindex:0,name:e.closeIcon,class:[D4("close-icon",e.closeIconPosition),b8],classPrefix:e.iconPrefix,onClick:m},null)},v=()=>t("opened"),y=()=>t("closed"),N=k=>t("keydown",k),b=c(()=>{var k;const{round:w,position:C,safeAreaInsetTop:E,safeAreaInsetBottom:A}=e;return n.withDirectives(n.createVNode("div",n.mergeProps({ref:s,style:u.value,role:"dialog",tabindex:0,class:[D4({round:w,[C]:C}),{"van-safe-area-top":E,"van-safe-area-bottom":A}],onKeydown:N},r),[(k=o.default)==null?void 0:k.call(o),g()]),[[n.vShow,e.show]])}),M=()=>{const{position:k,transition:w,transitionAppear:C}=e,E=k==="center"?"van-fade":`van-popup-slide-${k}`;return n.createVNode(n.Transition,{name:w||E,appear:C,onAfterEnter:v,onAfterLeave:y},{default:b})};return n.watch(()=>e.show,k=>{k&&!a&&(d(),r.tabindex===0&&n.nextTick(()=>{var w;(w=s.value)==null||w.focus()})),!k&&a&&(a=!1,t("close"))}),qpe({popupRef:s}),v0e(s,()=>e.show&&e.lockScroll),g8("popstate",()=>{e.closeOnPopstate&&(f(),i=!1)}),n.onMounted(()=>{e.show&&d()}),n.onActivated(()=>{i&&(t("update:show",!0),i=!1)}),n.onDeactivated(()=>{e.show&&e.teleport&&(f(),i=!0)}),n.provide(Wpe,()=>e.show),()=>e.teleport?n.createVNode(n.Teleport,{to:e.teleport},{default:()=>[h(),M()]}):n.createVNode(n.Fragment,null,[h(),M()])}});const E0e=ml(C0e),[T0e,br]=Za("action-sheet"),D0e=Gs({},Ph,{title:String,round:Dr,actions:Dpe(),closeIcon:vo("cross"),closeable:Dr,cancelText:String,description:String,closeOnPopstate:Dr,closeOnClickAction:Boolean,safeAreaInsetBottom:Dr}),S0e=[...m0e,"round","closeOnPopstate","safeAreaInsetBottom"];var _0e=n.defineComponent({name:T0e,props:D0e,emits:["select","cancel","update:show"],setup(e,{slots:t,emit:r}){const o=d=>r("update:show",d),a=()=>{o(!1),r("cancel")},i=()=>{if(e.title)return n.createVNode("div",{class:br("header")},[e.title,e.closeable&&n.createVNode(x8,{name:e.closeIcon,class:[br("close"),b8],onClick:a},null)])},l=()=>{if(t.cancel||e.cancelText)return[n.createVNode("div",{class:br("gap")},null),n.createVNode("button",{type:"button",class:br("cancel"),onClick:a},[t.cancel?t.cancel():e.cancelText])]},s=(d,f)=>d.loading?n.createVNode(p0e,{class:br("loading-icon")},null):t.action?t.action({action:d,index:f}):[n.createVNode("span",{class:br("name")},[d.name]),d.subname&&n.createVNode("div",{class:br("subname")},[d.subname])],c=(d,f)=>{const{color:p,loading:h,callback:m,disabled:g,className:v}=d,y=()=>{g||h||(m&&m(d),e.closeOnClickAction&&o(!1),n.nextTick(()=>r("select",d,f)))};return n.createVNode("button",{type:"button",style:{color:p},class:[br("item",{loading:h,disabled:g}),v],onClick:y},[s(d,f)])},u=()=>{if(e.description||t.description){const d=t.description?t.description():e.description;return n.createVNode("div",{class:br("description")},[d])}};return()=>n.createVNode(E0e,n.mergeProps({class:br(),position:"bottom","onUpdate:show":o},Tpe(e,S0e)),{default:()=>{var d;return[i(),u(),n.createVNode("div",{class:br("content")},[e.actions.map(c),(d=t.default)==null?void 0:d.call(t)]),l()]}})}});const M0=ml(_0e);var Eu={},ef={};Object.defineProperty(ef,"__esModule",{value:!0});ef.errorHandler=void 0;function I0e(e){if(!e)return;const t={message:"Um problema aconteceu e foi enviado para análise",type:"error",retryable:!0};return!window.navigator.onLine||e.message==="Network Error"?(t.message="Parece que você está offline.",t.type="info",t):typeof e=="string"?(t.message=e,t.retryable=!1,t):e.response&&e.response.status&&e.response.status>=400&&e.response.status<500?(t.message="Algumas informações não foram atualizadas.",t.retryable=!1,t):(e.response&&e.response.status>=500&&(t.message="Ops, encontramos um erro. Tente novamente mais tarde."),t)}ef.errorHandler=I0e;(function(e){var t=Pt&&Pt.__createBinding||(Object.create?function(o,a,i,l){l===void 0&&(l=i),Object.defineProperty(o,l,{enumerable:!0,get:function(){return a[i]}})}:function(o,a,i,l){l===void 0&&(l=i),o[l]=a[i]}),r=Pt&&Pt.__exportStar||function(o,a){for(var i in o)i!=="default"&&!a.hasOwnProperty(i)&&t(a,o,i)};Object.defineProperty(e,"__esModule",{value:!0}),r(ef,e)})(Eu);const A0e={name:"TopicItem",props:{multipleTargets:{type:Boolean},depth:{type:Number,default:0},propagate:{type:Function},propagateIncludes:{type:Function},parentsTopic:{type:Array,default:()=>[]},isCheckedFunction:{type:Function},rootIsChecked:{type:Function},populateTopic:{type:Function},hasChildChecked:{type:Function},parentIncludes:{type:Array,default:()=>[]},includesMap:{type:Object},parentChecked:{type:Boolean},topic:{type:Object},disabled:{type:Boolean},checked:{type:Boolean},selectedTopicKind:{type:String},setLoadingTopicState:{type:Function},parentTotals:{type:Array,default:()=>[]},parentFetch:{type:Function},lang:{type:String,default(){return pn()}}},data:function(){return{showIncludes:!1,fetchingIncludes:!1,initialFetching:!0,fetched:!1,error:!1,includes:[],includesMapData:{},generator:null,buffer:[],hasMore:!1,limit:30,totals:[]}},created(){this.generator=this.combinedGenerator(),this.includesMapData=this.includesMap,this.totals=$n(this.parentTotals)},watch:{async showIncludes(e){e===!0&&this.fetched===!1&&(this.fetched=!0,await this.fetch(),this.initialFetching=!1)},async limit(){this.generator=this.combinedGenerator()}},computed:{includesNoData(){return{group:"Esta turma ainda não tem alunos",tag:"Esta tag ainda não tem turmas"}[this.topic.kind]},isSelectedEntityKind(){return this.topic.kind===this.selectedTopicKind},chanShowCheckbox(){return this.multipleTargets||this.isSelectedEntityKind&&!this.multipleTargets},shouldDisable(){return!this.parentsTopic.some(this.isCheckedFunction)&&!this.rootIsChecked(this.topic)?!1:this.totals.filter(o=>this.isTopicInCheckedParentsTopic(o.topic)||this.isCurrentTopic(o.topic)||this.rootIsChecked(o.topic)).reduce((o,a)=>o+a.total,0)>600}},methods:{async*fetchToGenerator(e,t=null){const r={id:this.topic.id,kind:e,limit:this.limit+1,page:0};t&&(r.groupContext=t);let{hits:o,total:a}=await this.populateTopic(r);for(this.totals.push({topic:this.topic,total:a});a>0;){if(o.length>0){yield o.shift(),a--;continue}r.page+=1,o=(await this.populateTopic(r)).hits}},async*combinedGenerator(){this.topic.kind==="group"?(yield*this.fetchToGenerator("group","member"),yield*this.fetchToGenerator("group","user")):this.topic.kind==="member"?yield*this.fetchToGenerator("member","user"):yield*this.fetchToGenerator("tag")},async fetchPage(e){this.limit=e||this.limit;const t=this.limit;for(;this.buffer.length<t+1;){let r=await this.generator.next();if(r.value){this.buffer.push(r.value);continue}break}return{results:this.buffer.splice(0,t),hasMore:this.buffer.length>0}},async fetch(e){const t=e||this.limit,r=$n(this.includes);this.fetchingIncludes=!0;try{const{results:o,hasMore:a}=await this.fetchPage(t);this.includes=[...r,...o],this.includesMapData={...this.includesMapData,[this.topic.id]:this.includes},this.$emit("includes",{topic:this.topic,includes:this.includes}),this.hasMore=a}catch(o){this.error=o,this.$notify({...Eu.errorHandler("Erro ao carregar mais."),duration:1e4,position:"bottom",showClose:!0})}finally{this.fetchingIncludes=!1}},color(e){return this.disabled?"gray-50":{member:"purple",group:"aqua",user:"link",tag:"warning"}[e]||"lead"},icon(e){return{member:"uil-graduation-cap",group:"uil-users-alt",user:"uil-user",tag:"uil-tag-alt"}[e]},isChildChecked(e){return this.isCheckedFunction(e)||this.isCheckedFunction(this.topic)},expandableKind(){return["group","tag","member"].includes(this.topic.kind)},toggleShowIncludes(){this.expandableKind&&(this.showIncludes=!this.showIncludes)},updateSelectedTopics(e,t){this.$emit("input",{topic:e,value:t})},async topicIncludedChanged(e,t){try{this.parentsTopic.some(this.isCheckedFunction)&&!t&&(this.setLoadingTopicState(!0),await this.parentFetch(t),this.parentsTopic.slice(this.parentsTopic.findIndex(this.rootIsChecked)).forEach(o=>{var a;this.updateSelectedTopics(o,!1),(a=this.includesMap[o.id])==null||a.forEach(i=>{this.hasChildChecked(i)||this.updateSelectedTopics(i,!0)})})),this.updateSelectedTopics(e,t)}finally{this.setLoadingTopicState(!1)}},checkedParents(){const e=this.parentsTopic.findIndex(this.rootIsChecked);let t=[];return e!==-1&&(t=this.parentsTopic.slice(e)),t},isTopicInCheckedParentsTopic(e){return this.checkedParents().some(r=>r.id===e.id&&r.kind===e.kind)},isCurrentTopic(e){return e.id===this.topic.id&&e.kind===this.topic.kind},async handlePagination(e){var t;if(!(e||!this.isCheckedFunction(this.topic)))try{for((t=this.parentsTopic)!=null&&t.length&&(await this.retry(()=>this.parentFetch(e)),this.includesMapData={...this.includesMapData,...this.includesMap});this.hasMore;)await this.retry(()=>this.fetch(200))}catch(r){console.error("handlePagination failed:",r)}},async retry(e,t=3,r=500){for(let o=0;o<t;o++)try{return await e()}catch(a){if(o===t-1)throw a;console.warn(`Retry ${o+1} failed. Retrying in ${r}ms...`),await new Promise(i=>setTimeout(i,r))}}}},O0e={class:"topic-item-group"},z0e={key:0,class:"topic-chevron mr-2"},j0e={class:"topic-icon"},L0e={key:0},B0e={class:"l-d-flex l-align-items-center my-2",style:{"justify-content":"center",width:"100%",height:"40px"}},V0e={key:1},$0e={class:"no-data-includes l-text-regular gray-60--text"},P0e={key:1},R0e={key:0,class:"mx-3 my-3"};function F0e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-checkbox"),c=n.resolveComponent("LCircularLoader"),u=n.resolveComponent("TopicItem",!0),d=n.resolveComponent("l-button"),f=n.resolveComponent("l-transition-expand");return n.openBlock(),n.createElementBlock("div",O0e,[n.createElementVNode("div",{class:n.normalizeClass("topic-item-group-header depth-"+r.depth+" l-d-flex l-align-items-center pl-3"+(i.isSelectedEntityKind&&r.depth>0?" user-topic-item-group-header":""))},[n.createElementVNode("div",{class:"l-flex l-d-flex l-align-items-center",onClick:t[0]||(t[0]=n.withModifiers(p=>i.isSelectedEntityKind?null:i.toggleShowIncludes(),["stop"]))},[i.isSelectedEntityKind?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",z0e,[n.createVNode(l,{class:"gray-60--text",size:"24"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.showIncludes?"uil-angle-down":"uil-angle-right"),1)]),_:1})])),n.createElementVNode("div",j0e,[n.createElementVNode("div",{class:n.normalizeClass(["bg-icon",i.color(r.topic.kind)])},null,2),n.createVNode(l,{class:n.normalizeClass(i.color(r.topic.kind)+"--text")},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.icon(r.topic.kind)),1)]),_:1},8,["class"])]),n.createElementVNode("div",{class:n.normalizeClass(["l-flex ml-2 mr-3 l-text-regular ellipsis-2",r.disabled?"gray-70--text":"lead-light--text"])},n.toDisplayString(r.topic.name),3)]),(n.openBlock(),n.createBlock(s,{disabled:r.disabled,checked:r.isCheckedFunction(r.topic),indeterminate:r.hasChildChecked(r.topic)&&!r.isCheckedFunction(r.topic),key:r.isCheckedFunction(r.topic),onChange:t[1]||(t[1]=p=>r.parentsTopic.length?i.topicIncludedChanged(r.topic,p):i.updateSelectedTopics(r.topic,p)),class:n.normalizeClass(["p-3",{"circular-checkbox":!r.multipleTargets}]),style:n.normalizeStyle({display:i.chanShowCheckbox?"block":"none"})},null,8,["disabled","checked","indeterminate","class","style"]))],2),t[7]||(t[7]=n.createElementVNode("hr",null,null,-1)),n.createVNode(f,null,{default:n.withCtx(()=>[e.showIncludes?(n.openBlock(),n.createElementBlock("div",L0e,[e.initialFetching?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createElementVNode("div",B0e,[n.createVNode(c,{width:40,height:40})]),t[5]||(t[5]=n.createElementVNode("hr",null,null,-1))],64)):(n.openBlock(),n.createElementBlock("div",V0e,[!e.includes.length&&!e.hasMore||e.error?(n.openBlock(),n.createElementBlock(n.Fragment,{key:0},[n.createElementVNode("div",$0e,n.toDisplayString(i.includesNoData),1),t[6]||(t[6]=n.createElementVNode("hr",null,null,-1))],64)):(n.openBlock(),n.createElementBlock("div",P0e,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.includes,p=>(n.openBlock(),n.createBlock(u,{key:p.id,onInput:t[2]||(t[2]=h=>r.propagate(h)),onIncludes:t[3]||(t[3]=h=>r.propagateIncludes(h)),propagateIncludes:r.propagateIncludes,hasChildChecked:r.hasChildChecked,isCheckedFunction:i.isChildChecked,rootIsChecked:r.rootIsChecked,checked:i.isChildChecked(p),depth:r.depth+1,topic:p,selectedTopicKind:r.selectedTopicKind,parentsTopic:[...r.parentsTopic,r.topic],parentIncludes:e.includes,includesMap:e.includesMapData,parentChecked:r.checked,populateTopic:r.populateTopic,propagate:r.propagate,disabled:r.disabled||i.shouldDisable,multipleTargets:r.multipleTargets,onChildUnchecked:i.handlePagination,onPropagatePagination:i.handlePagination,setLoadingTopicState:r.setLoadingTopicState,parentTotals:e.totals,parentFetch:i.handlePagination},null,8,["propagateIncludes","hasChildChecked","isCheckedFunction","rootIsChecked","checked","depth","topic","selectedTopicKind","parentsTopic","parentIncludes","includesMap","parentChecked","populateTopic","propagate","disabled","multipleTargets","onChildUnchecked","onPropagatePagination","setLoadingTopicState","parentTotals","parentFetch"]))),128)),e.hasMore?(n.openBlock(),n.createElementBlock("div",R0e,[n.createVNode(d,{loading:e.fetchingIncludes,onClick:t[4]||(t[4]=p=>i.fetch()),plain:"",fill:""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("load-more",r.lang)),1)]),_:1},8,["loading"])])):n.createCommentVNode("",!0)]))]))])):n.createCommentVNode("",!0)]),_:1})])}const U0e=xe(A0e,[["render",F0e],["__scopeId","data-v-8abbd897"]]);const H0e={props:{term:{type:String}}},Y0e={class:"l-d-flex l-align-items-center lead--text recent-topic"},Q0e={class:"l-flex l-text-regular mx-2"};function W0e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",Y0e,[n.createVNode(l,{size:"16"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-history")])),_:1}),n.createElementVNode("div",Q0e,n.toDisplayString(r.term),1),n.createVNode(s,{onClick:t[0]||(t[0]=n.withModifiers(c=>e.$emit("remove"),["stop"])),circle:"",icon:"uil-multiply",class:"border-none lead--text f-18 p-1"})])}const q0e=xe(H0e,[["render",W0e],["__scopeId","data-v-a8c57ab5"]]);const G0e={props:{query:{type:Object},typing:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},hasAnySelectedTopic:{type:Boolean,default:!1},kinds:{type:Array},lang:{type:String,default(){return pn()}}},data:e=>{const t=$n(e.query);return{localQuery:t,queryKind:t.kind}},computed:{filteredKinds(){return this.kinds.filter(e=>this.localQuery.q||!(e.value==="member"||e.value==="user"))}},watch:{queryKind:{handler(e){this.localQuery={...this.localQuery,kind:e}},immediate:!0,deep:!0},localQuery:{handler(e){this.$emit("update:query",e)},deep:!0,immediate:!0}},methods:{clearInput(){this.updateQuery({target:{value:null}})},isSelected(e){return Dt(this.localQuery,"kind",null)===e},updateQuery(e){this.localQuery={...this.localQuery,q:Dt(e,"target.value",null)}},setInputClass(e){return"search-input-wrapper ml-2 l-flex"+" "+e},back(){this.$emit("close")},save(){this.$emit("save")}}},K0e={class:"app-navigation"},J0e={class:"search-topics-header l-d-flex l-align-items-center pl-2 pr-3"},Z0e=["placeholder"],X0e={key:0,class:"filter-kind l-d-flex px-3 pb-2"};function eme(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("l-icon"),c=n.resolveComponent("l-radio-button"),u=n.resolveComponent("l-radio-group"),d=n.resolveComponent("l-linear-progress");return n.openBlock(),n.createElementBlock("div",K0e,[n.createElementVNode("div",J0e,[n.createVNode(l,{onClick:i.back,circle:"",icon:"uil-arrow-left",class:"border-none gray-70--text f-24 p-1"},null,8,["onClick"]),n.createElementVNode("div",{class:n.normalizeClass(i.setInputClass("blurred"))},[n.withDirectives(n.createElementVNode("input",{style:{width:"100%"},autocomplete:"off",placeholder:e.$tds("search",r.lang),"onUpdate:modelValue":t[0]||(t[0]=f=>e.localQuery.q=f),onFocus:t[1]||(t[1]=f=>i.setInputClass("focused")),onBlur:t[2]||(t[2]=f=>i.setInputClass("blurred")),onKeypress:t[3]||(t[3]=n.withKeys(f=>f.target.blur(),["enter"])),onInput:t[4]||(t[4]=(...f)=>i.updateQuery&&i.updateQuery(...f))},null,40,Z0e),[[n.vModelText,e.localQuery.q]]),e.localQuery.q?(n.openBlock(),n.createBlock(s,{key:0,class:"lead-light--text cursor-pointer",onClick:i.clearInput,size:"16"},{default:n.withCtx(()=>t[6]||(t[6]=[n.createTextVNode(" uil-times ")])),_:1},8,["onClick"])):n.createCommentVNode("",!0)],2),n.createVNode(l,{disabled:!r.hasAnySelectedTopic,onClick:i.save,loading:r.loading||r.typing,type:"primary",class:"save-button bold l-d-flex l-align-items-center f-14 ml-2"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("save",r.lang)),1)]),_:1},8,["disabled","onClick","loading"])]),e.localQuery.q||r.query.kind!=="*"?(n.openBlock(),n.createElementBlock("div",X0e,[n.createVNode(u,{modelValue:e.queryKind,"onUpdate:modelValue":t[5]||(t[5]=f=>e.queryKind=f),class:"l-flex-nowrap",size:"small",separated:"",color:"lead-light"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.filteredKinds,f=>(n.openBlock(),n.createBlock(c,{key:f.value,label:f.value},{default:n.withCtx(()=>[f.icon?(n.openBlock(),n.createBlock(s,{key:0,color:i.isSelected(f.value)?"white":"lead-light",size:"13"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(f.icon),1)]),_:2},1032,["color"])):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(f.name),1)]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue"])])):n.createCommentVNode("",!0),r.loading||r.typing?(n.openBlock(),n.createBlock(d,{key:1})):n.createCommentVNode("",!0)])}const tme=xe(G0e,[["render",eme],["__scopeId","data-v-707d9274"]]),S4=Symbol.for("GlobalStack"),E8=class{static createStackInstance(t){if(console.warn(`[VueModals] No ModalStack was found for name "${t}". Using Modals without a stack instance causes one to be created as default at the end of the document body.`),this.globalStackInstances.get(t))return console.warn(`[VueModals] A ModalStack instance with the name "${t}" already exists. Returning stack.`),this.globalStackInstances.get(t);const r=document.createElement("aside");document.body.insertAdjacentElement("beforeend",r);const o=n.createApp(b0,{name:t});return o.mount(r),this.globalStackInstances.set(t,o),o}static stack(t="default"){if(t==="default"&&!this.globalStackInstances.has("default"))return this.createStackInstance("default");if(this.globalStackInstances.has(t))return this.globalStackInstances.get(t);throw new Error(`[VueModals] No stack instance found for name "${t??"default"}". Create a ModalStack instance with this name to use it.`)}static open(t){return this.stack(t.stack).push(t)}static registerStack(t,r){console.warn("register",t,r),this.globalStackInstances.has(t)?console.warn(`[VueModals] Multiple instances of ModalStack must have unique names. Duplicate name found for ModalStack "${t}".`):this.globalStackInstances.set(t,r)}static unregisterStack(t,r){console.warn("unregister",t,r),this.globalStackInstances.get(t)===r?this.globalStackInstances.delete(t):console.warn(`[VueModals] Could not unregister ModalStack because a duplicate name was found "${t}".`)}};E8.globalStackInstances=window[S4]||(window[S4]=new Map);let bi=E8;const nme=n.defineComponent({props:{stack:{type:Array},index:{type:Number},modal:{type:Object},position:{type:String,default:"right"}},computed:{ensuredPosition(){return this.position==="left"?"left":"right"},depth(){const e=this.stack.filter(r=>{const o=r.options.position??"right";return r.options.layout==="drawer"&&o===this.ensuredPosition}),t=e.findIndex(r=>r===this.modal);return e.length-t-1}}}),Rh=(e,t)=>{const r=e.__vccOpts||e;for(const[o,a]of t)r[o]=a;return r},rme=["position"];function ome(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("section",{layout:"drawer",position:e.ensuredPosition,style:n.normalizeStyle({"--depth":e.depth})},[n.renderSlot(e.$slots,"default")],12,rme)}const ame=Rh(nme,[["render",ome]]),ime=n.defineComponent({computed:{classes(){return{center:!0}}},props:{stack:{type:Array},index:{type:Number},modal:{type:Object},showClose:{type:Object}}}),lme={key:0,class:"header"},sme={class:"content"};function cme(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("section",{layout:"dialog",class:n.normalizeClass(e.classes)},[e.showClose?(n.openBlock(),n.createElementBlock("div",lme,[n.createElementVNode("button",{class:"close-button",onClick:t[0]||(t[0]=l=>e.$emit("close"))},"×")])):n.createCommentVNode("",!0),n.createElementVNode("div",sme,[n.renderSlot(e.$slots,"default")]),t[1]||(t[1]=n.createElementVNode("div",{class:"footer"},null,-1))],2)}const ume=Rh(ime,[["render",cme]]);var dme=1;const _4=Symbol("Reject"),I4=Symbol("Resolve"),Cl=Symbol("Fulfilled"),fme={drawer:ame,dialog:ume},pme=n.defineComponent({name:"vue-modals-stack",data(){return{stack:[]}},created(){bi.registerStack(this.name,this)},beforeUnmount(){bi.unregisterStack(this.name,this)},methods:{getLayoutComponentFromModalLayout(e){return typeof e=="string"?fme[e]??e:e},removeFromStack(e){const t=this.stack.findIndex(r=>r===e);t<0||this.stack.splice(t,1)},addToStack(e){this.stack.push(e)},push(e){const t=this.buildModal(e);return this.addToStack(t),t},close(e,t){return this.canClose(e)?(this.destroy(e,t),!0):!1},layoutForModal(e){const t=e.layout??e.options.layout??this.layout??"section",r=tf.app;if(typeof t=="string"){const o=r.component(t);if(o)return o}return t},canClose(e){var t;const r=new Event("beforeClose",{cancelable:!0});if(e.options.beforeClose&&(e.options.beforeClose(r),r.defaultPrevented))return!1;const o=(t=this.$refs[e.id])==null?void 0:t[0];return!(o&&typeof o.beforeClose=="function"&&(o.beforeClose(r),r.defaultPrevented)||!this.stack.filter(a=>a.options.parent===o).every(a=>this.canClose(a)))},destroy(e,t){e[Cl]||(e[Cl]=!0,e[_4](t??new Error("Modal closed"))),this.removeFromStack(e)},answer(e,t){e[Cl]||(e[Cl]=!0,e[I4](t)),this.removeFromStack(e)},pop(){if(this.stack.length){const e=this.stack[this.stack.length-1];if(this.close(e))return e}return null},popUntil(e){if(!(this.stack.findIndex(t=>e===t)<0))for(;this.stack.length>0;){const t=this.pop();if(t===e||t===null)return}},clear(){for(;this.stack.length;)this.destroy(this.stack[this.stack.length-1])},buildModal(e){var t;let r,o;const a=new Promise((i,l)=>{r=i,o=s=>"default"in e?i(e.default):l(s)});return!e.layout&&(t=e.component)!=null&&t.layout&&(e.layout=e.component.layout),e.parent&&n.onBeforeUnmount(()=>{this.destroy(a,new Error("Component was destroyed"))}),a.id=dme++,a.stack=this,a.options=e,a.layout=this.layoutForModal(a),a.position=e.position,a[_4]=o,a[I4]=r,a[Cl]=!1,a.close=i=>this.close(a,i),a.destroy=i=>this.destroy(a,i),a},onNameChanged(e,t){t&&bi.unregisterStack(t,this),e&&bi.registerStack(e,this)}},props:{name:{type:String,default:"default"},layout:{type:String,default:"drawer"}},watch:{name:[{handler:"onNameChanged"}]}}),mme=["onClick"];function hme(e,t,r,o,a,i){return n.openBlock(),n.createBlock(n.TransitionGroup,{tag:"div",stack:e.name,name:"modal"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.stack,(l,s)=>(n.openBlock(),n.createElementBlock(n.Fragment,{key:l.id},[l.options.hideOverlay?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",{key:0,style:n.normalizeStyle(`z-index: ${1e3+s}`),class:n.normalizeClass(["vue-modals-overlay",{below:s<e.stack.length-1,far:s<e.stack.length-4}]),onClick:c=>l.options.clickToClose!==!1&&e.close(l)},null,14,mme)),(n.openBlock(),n.createBlock(n.resolveDynamicComponent(e.getLayoutComponentFromModalLayout(l.layout)),{"modal-id":l.id,modal:l,showClose:l.options.showClose,class:"vue-modals-layout",style:n.normalizeStyle(`z-index: ${1001+s}`),stack:e.stack,index:s,position:l.position,onClose:c=>e.close(l,c),onDestroy:c=>e.destroy(l,c),onAnswer:c=>e.answer(l,c)},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(l.options.component),n.mergeProps({ref_for:!0,ref:l.id},l.options.props,{onClose:c=>e.close(l,c),onDestroy:c=>e.destroy(l,c),onAnswer:c=>e.answer(l,c)}),null,16,["onClose","onDestroy","onAnswer"]))]),_:2},1064,["modal-id","modal","showClose","style","stack","index","position","onClose","onDestroy","onAnswer"]))],64))),128))]),_:1},8,["stack"])}const b0=Rh(pme,[["render",hme]]),tf={app:void 0,install(e){e.component("vue-modals-stack",b0),e.config.globalProperties.$modals=bi,tf.app=e},Modals:bi,ModalStack:b0};async function gme(e){const t=window.LayersPortal?window.LayersPortal.platform:"shell";if(t==="shell"||t==="iframe"){const o=tf.Modals.stack().push({layout:"dialog",showClose:!1,component:Th,props:{title:e.title,content:e.content,buttonCloseLabel:e.buttonCloseLabel,buttonConfirmLabel:e.buttonConfirmLabel}});try{return await o}catch{return!1}}return window.confirm(e.content||e.title)}async function vme(){const e=tf.Modals.stack();window.history.go(1);const t=e.push({layout:"dialog",showClose:!1,component:Th,props:{buttonCloseLabel:"Permanecer aqui",buttonConfirmLabel:"Descartar alterações",title:"Alterações não salvas",content:"Você quer mesmo sair? Existem alterações que não foram salvas. Se você sair, suas alterações serão perdidas."}});try{const r=await t;if(r)return r}catch{}}const yme="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIwIiBoZWlnaHQ9IjE4MyIgdmlld0JveD0iMCAwIDIyMCAxODMiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGZpbGwtcnVsZT0iZXZlbm9kZCIgY2xpcC1ydWxlPSJldmVub2RkIiBkPSJNODMuMjk5NCAxNjQuMjk4TDgzLjI5OSAxNjQuMjk4Qzc5LjA5NiAxNjYuMjIgNzUuMTk0NiAxNjguMDA1IDcxLjMxNDcgMTY5LjIxQzUxLjk2MDMgMTc1LjIyMyAzMS4wNjI2IDE3NS45MjIgMTAuMjk0OCAxNDguMjIxQy0xMC40NzI5IDEyMC41MTkgLTAuMzE2MjIyIDg0Ljk0NTQgNDUuMjkwOSA3MC4xOTEyQzU3LjIwOTMgNjYuMzM5IDYyLjgwOTQgNTcuNzI3NSA2OS41NjAzIDQ3LjM0NjFDNzYuNjg1MSAzNi4zODk5IDg1LjA5MTcgMjMuNDYyNSAxMDMuNTYgMTIuMDc4MkMxNTIuNTU1IC0xOC4xMTMzIDE5Ny4wODggMTAuNzYzNSAyMTUuODU4IDcxLjI3MTRDMjM0LjYyNyAxMzEuNzc5IDE4Ni43IDE1OS4xNDQgMTMwLjY3MiAxNTQuNDk4QzEwOC43MSAxNTIuNjc1IDk0Ljg2MzQgMTU5LjAwOSA4My4yOTk0IDE2NC4yOThaIiBmaWxsPSIjNTQ1MUQ2Ii8+CjxwYXRoIG9wYWNpdHk9IjAuOSIgZmlsbC1ydWxlPSJldmVub2RkIiB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{TopicItemGroup:U0e,RecentTermSearched:q0e,SearchTopicsHeader:tme,[M0.name]:M0},props:{multipleTargets:{type:Boolean,default:!0},canSendForAll:{type:Boolean,default:!1},searchTopics:{type:Function},populateTopic:{type:Function},alreadySelectedTopics:{type:Array},recentTopicsSearched:{type:Object},selectedTopicKind:{type:String,default:"user"},lang:{type:String,default(){return pn()}}},data:function(){return{forAllTagChecked:!1,showSelected:!1,selectedTopics:[],includesMap:{},querySearchTopics:{q:null,kind:"*",page:0},searchedTopics:{tag:{hits:[],total:0},group:{hits:[],total:0},member:{hits:[],total:0},user:{hits:[],total:0}},total:0,kinds:["*","tag","group","member","user"],kindsIcons:{tag:"uil-tag-alt",group:"uil-users-alt",member:"uil-graduation-cap",user:"uil-user","*":""},typing:!1,loading:!1,loadingMore:!1,loadingTopic:!1}},watch:{selectedTopics(e){(!e||e.length===0)&&(this.showSelected=!1)},querySearchTopics(){!this.typing&&!this.loadingMore&&(this.typing=!0),this.searchDebounced()}},computed:{canShowSendForAll(){return this.canSendForAll&&!this.hasQuery&&this.multipleTargets},searchingSpan(){var e;return this.querySearchTopics.q?this.querySearchTopics.q:this.querySearchTopics.kind==="*"?"":(e=this.getKindNamePlural(this.querySearchTopics.kind,this.lang))==null?void 0:e.toLowerCase()},hasQuery(){return this.querySearchTopics.q||this.querySearchTopics.kind!=="*"},showRecentSearchedTopics(){return this.recentTopicsSearched.data?this.recentTopicsSearched.data.length>0&&!this.hasQuery:!1},filteredSearchedTopics(){return{...this.searchedTopics,tag:{hits:this.searchedTopics.tag.hits.filter(e=>e.id!=="*"),total:this.searchedTopics.tag.total}}},forAllTag:{get(){return this.forAllTagChecked},set(e){const t=this.searchedTopics.tag.hits;if(this.selectedTopics&&this.selectedTopics.length&&this.selectedTopics.find(r=>r.id!=="*")&&e!=="confirm"){this.showForAllTagAlert().then(r=>{if(!r){this.forAllTagChecked=!1;return}const o=t.find(a=>a.id==="*");this.setSelectedTopics([o]),this.forAllTagChecked=!0});return}if(e=!!e,e&&this.searchedTopics&&t){const r=t.find(o=>o.id==="*");this.setSelectedTopics([r])}else this.setSelectedTopics([]);this.forAllTagChecked=e}},recentTopicsFiltered(){return $n(this.recentTopicsSearched.data).reverse().slice(0,3)},topicsSummary(){if(!this.selectedTopics||!this.selectedTopics.length)return"";if(this.forAllTagChecked)return this.$tds("send-for-all",this.lang);const e=[];return this.kinds.filter(t=>t!=="*").forEach(t=>{var o,a;const r=a8(this.selectedTopics,{kind:t}).length;r===1?e.push(`1 ${(o=this.getKindName(t,this.lang))==null?void 0:o.toLowerCase()}`):r>1&&e.push(`${r} ${(a=this.getKindNamePlural(t,this.lang))==null?void 0:a.toLowerCase()}`)}),e.length?e.join(", "):null},hasAnySearchedTopic(){return this.total?this.total>0:null},headerKinds(){return this.kinds.filter(e=>e!=="tag"||this.canSendForAll).map(e=>({value:e,name:this.getKindNamePlural(e,this.lang),icon:this.kindsIcons[e]}))},resultKinds(){return this.kinds.filter(t=>t!=="*").filter(t=>this.filteredSearchedTopics[t].total&&this.filteredSearchedTopics[t].hits.length)},totalLabel(){return this.total===1?this.$tds("one-result-found",this.lang):this.total+this.$tds("results-found",this.lang)},isAllEntities(){return this.querySearchTopics.kind==="*"}},async created(){this.loading=!0;try{const e=await this.searchTopics(this.querySearchTopics);this.searchedTopics=e.result,this.total=e.total}catch{this.$notify({...Eu.errorHandler(this.$tds("error-target-loading",this.lang)),duration:1e4,position:"bottom",showClose:!0})}finally{this.loading=!1}this.selectedTopics=this.alreadySelectedTopics,this.selectedTopics&&this.selectedTopics.length&&this.selectedTopics.find(e=>e.id==="*"&&e.kind==="tag")&&this.multipleTargets&&(this.forAllTag=!0)},unmounted(){this.setSelectedTopics([])},methods:{searchDebounced:Ufe(async function(){console.log(this.querySearchTopics),Dt(this.querySearchTopics,"q.length",null)>3&&this.recentTopicsSearched.push(this.querySearchTopics.q),await this.getSearchedTopics(this.querySearchTopics),this.typing=!1},500,{leading:!1,trailing:!0}),useRecentTermSearched(e){this.setQuerySearchTopics({q:e,kind:"*"})},updateIncludesMap({topic:e,includes:t}){this.includesMap[e.id]=t},hasChildChecked(e){const t=this.includesMap[e.id];return t?t.some(this.isChecked)||t.some(this.hasChildChecked):!1},getKindName(e,t="pt-br"){return{"pt-br":{"*":"Procurar em tudo",tag:"Marcador",group:"Turma",member:"Aluno",user:"Usuário"},en:{"*":"Search all",tag:"Tag",group:"Group",member:"Member",user:"User"},es:{"*":"Buscar en todo",tag:"Etiqueta",group:"Grupo",member:"Miembro",user:"Usuario"}}[t][e]},getKindNamePlural(e,t="pt-br"){return{"pt-br":{"*":"Procurar em tudo",tag:"Marcadores",group:"Turmas",member:"Alunos",user:"Usuários"},en:{"*":"Search all",tag:"Tags",group:"Groups",member:"Members",user:"Users"},es:{"*":"Buscar en todo",tag:"Etiquetas",group:"Grupos",member:"Miembros",user:"Usuarios"}}[t][e]},async getSearchedTopics(e){this.loadingMore||(this.loading=!0);try{const t=await this.searchTopics(e);if(e.page>0){const r=$n(this.searchedTopics);await Promise.all(tae(t.result).map(o=>{r[o]||(r[o]={hits:[],total:null}),r[o].hits=[...r[o].hits,...t.result[o].hits]})),this.searchedTopics=r}else this.searchedTopics=t.result,this.total=t.total}catch{this.$notify({...Eu.errorHandler(this.$tds("error-searching",this.lang)),duration:1e4,position:"bottom",showClose:!0})}finally{this.loading=!1,this.loadingMore=!1}},loadMore(){this.loadingMore=!0;const e=Dt(this.querySearchTopics,"page",0)+1,t=Dt(this.querySearchTopics,"q",null),r=Dt(this.querySearchTopics,"kind",null);this.setQuerySearchTopics({q:t,kind:r,page:e})},getTopicHits(e){return Dt(this.filteredSearchedTopics,`${e}.hits`,[])},getTopicTotal(e){return Dt(this.filteredSearchedTopics,`${e}.total`,[])},needShowMore(e){return this.getTopicTotal(e)>this.getTopicHits(e).length},isChecked(e){return this.forAllTagChecked?!0:this.selectedTopics.filter(t=>t.kind===e.kind&&t.id===e.id).length!==0},filterForKind(e){this.setQuerySearchTopics({q:this.querySearchTopics.q,kind:e,page:0})},setSelectedTopics(e){this.selectedTopics=e},removeFromRecentTopicsSearched(e){this.recentTopicsSearched.remove(e)},setQuerySearchTopics(e){this.querySearchTopics=e},async showForAllTagAlert(){const e=await gme({title:this.$tds("show-for-all-tags",this.lang),buttonCloseLabel:this.$tds("cancel",this.lang),buttonConfirmLabel:this.$tds("continue",this.lang)});if(e)return e},addTopic(e){if(this.selectedTopics.filter(r=>r.id===e.id&&r.kind===e.kind).length===0){const r=$n(this.selectedTopics);r.push(e),this.setSelectedTopics(r)}},removeTopic(e){const t=this.selectedTopics.findIndex(o=>o.id===e.id&&o.kind===e.kind);if(t==-1)return;const r=$n(this.selectedTopics);r.splice(t,1),this.setSelectedTopics(r)},updateSelectedTopics({topic:e,value:t}){if(!this.multipleTargets)return t?this.setSelectedTopics([e]):this.setSelectedTopics([]);if(!t){this.removeTopic(e);return}this.addTopic(e)},setLoadingTopicState(e){this.loadingTopic=e},onSave(){const e=this.selectedTopics.map(t=>({hash:t.hash,name:t.name,kind:t.kind,id:t.id}));this.$emit("answer",e)},async onClose(){const e=$n(this.alreadySelectedTopics).map(a=>a.kind+a.id),t=$n(this.selectedTopics).map(a=>a.kind+a.id);if(Npe(t,e).length===0){this.$emit("close");return}await vme()&&this.$emit("close")},onInput(e){this.querySearchTopics=e}}},bme={class:"search-topics-page l-col l-d-flex column"},wme={class:"px-0 py-2 l-container scroll-y l-flex-grow-1"},Nme={key:0,class:"gray-70--text searching-label mx-3"},kme={class:"gray-70--text searching-label mx-3"},xme={class:"mb-5"},Cme={key:0,class:"recent-search mb-3 mx-3"},Eme={class:"recent-search-title gray-70--text mb-2 l-text-regular"},Tme={key:1,class:"topic-item-tag-for-all mx-3"},Dme={class:"l-flex lead-light--text l-text-regular"},Sme={key:2,class:"results-total mb-2 px-3"},_me={key:0,class:"topic-kind-title gray-70--text mb-2 px-3"},Ime={key:1,class:"m-3"},Ame={key:2,class:"m-3"},Ome={key:2,style:{display:"flex","flex-direction":"column",height:"100%","align-items":"stretch"}},zme={key:0,class:"topic-item-tag-for-all empty-tags-groups-for-all mx-3"},jme={class:"l-flex lead-light--text l-text-regular"},Lme={key:1,class:"empty-tags-groups-placeholder"},Bme={class:"empty-tags-groups-placeholder-text mt-2"},Vme={class:"text-small lead-light--text"},$me={key:2,class:"not-found-result mx-3"},Pme={class:"bold lead--text m-0"},Rme={class:"lead-light--text l-text-regular mt-3 mb-0"},Fme={key:0,class:"selected-topics"},Ume={class:"ml-2 topics-selected-summary l-flex link--text"},Hme={class:"l-d-flex m-3 l-align-items-center"},Yme={class:"l-flex lead-light--text l-text-regular"},Qme={class:"mx-3 mb-3"};function Wme(e,t,r,o,a,i){const l=n.resolveComponent("SearchTopicsHeader"),s=n.resolveComponent("l-linear-progress"),c=n.resolveComponent("RecentTermSearched"),u=n.resolveComponent("l-checkbox"),d=n.resolveComponent("TopicItemGroup"),f=n.resolveComponent("l-button"),p=n.resolveComponent("l-target-chip"),h=n.resolveComponent("van-action-sheet");return n.openBlock(),n.createElementBlock("div",bme,[n.createVNode(l,{class:"drawer-search-topics-header",kinds:i.headerKinds,query:e.querySearchTopics,typing:e.typing,loading:e.loading,hasAnySelectedTopic:e.selectedTopics.length>0,lang:r.lang,onSave:i.onSave,onClose:i.onClose,"onUpdate:query":i.onInput},null,8,["kinds","query","typing","loading","hasAnySelectedTopic","lang","onSave","onClose","onUpdate:query"]),n.createElementVNode("div",wme,[e.loading||e.typing?(n.openBlock(),n.createElementBlock("div",Nme,n.toDisplayString(e.$tds("searching",r.lang))+" "+n.toDisplayString(i.searchingSpan)+"... ",1)):i.hasAnySearchedTopic?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.withDirectives(n.createVNode(s,null,null,512),[[n.vShow,e.loadingTopic]]),n.withDirectives(n.createElementVNode("div",kme,null,512),[[n.vShow,e.loadingTopic]]),n.createElementVNode("div",xme,[i.showRecentSearchedTopics?(n.openBlock(),n.createElementBlock("div",Cme,[n.createElementVNode("div",Eme,n.toDisplayString(e.$tds("recently-searched",r.lang)),1),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.recentTopicsFiltered,(m,g)=>(n.openBlock(),n.createBlock(c,{onClick:v=>i.useRecentTermSearched(m),term:m,key:g,class:"mb-2 cursor-pointer",onRemove:v=>i.removeFromRecentTopicsSearched(m)},null,8,["onClick","term","onRemove"]))),128))])):n.createCommentVNode("",!0),i.canShowSendForAll?(n.openBlock(),n.createElementBlock("div",Tme,[n.createElementVNode("div",Dme,n.toDisplayString(e.$tds("send-for-all",r.lang)),1),n.createVNode(u,{modelValue:i.forAllTag,"onUpdate:modelValue":t[0]||(t[0]=m=>i.forAllTag=m)},null,8,["modelValue"])])):n.createCommentVNode("",!0),e.total>=1&&i.hasQuery?(n.openBlock(),n.createElementBlock("div",Sme,n.toDisplayString(i.totalLabel),1)):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.resultKinds,m=>(n.openBlock(),n.createElementBlock("div",{class:"topics-searched mb-3",key:m},[i.isAllEntities?(n.openBlock(),n.createElementBlock("h6",_me,n.toDisplayString(i.getKindNamePlural(m,r.lang))+" ("+n.toDisplayString(i.getTopicTotal(m))+") ",1)):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.getTopicHits(m),g=>(n.openBlock(),n.createBlock(d,{onInput:t[1]||(t[1]=v=>i.updateSelectedTopics(v)),onIncludes:i.updateIncludesMap,propagateIncludes:i.updateIncludesMap,propagate:i.updateSelectedTopics,hasChildChecked:i.hasChildChecked,topic:g,selectedTopicKind:r.selectedTopicKind,parentTopic:g,populateTopic:r.populateTopic,disabled:e.forAllTagChecked||e.loadingTopic,checked:i.isChecked(g),isCheckedFunction:i.isChecked,rootIsChecked:i.isChecked,multipleTargets:r.multipleTargets,key:g.id,setLoadingTopicState:i.setLoadingTopicState,lang:r.lang},null,8,["onIncludes","propagateIncludes","propagate","hasChildChecked","topic","selectedTopicKind","parentTopic","populateTopic","disabled","checked","isCheckedFunction","rootIsChecked","multipleTargets","setLoadingTopicState","lang"]))),128)),i.isAllEntities&&i.needShowMore(m)?(n.openBlock(),n.createElementBlock("div",Ime,[n.createVNode(f,{loading:e.loading,onClick:g=>i.filterForKind(m),plain:"",fill:""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("show-more",r.lang))+" "+n.toDisplayString(i.getKindNamePlural(m,r.lang).toLowerCase()),1)]),_:2},1032,["loading","onClick"])])):n.createCommentVNode("",!0),!i.isAllEntities&&i.needShowMore(m)?(n.openBlock(),n.createElementBlock("div",Ame,[n.createVNode(f,{class:"ma-3",loading:e.loadingMore,onClick:t[2]||(t[2]=g=>i.loadMore()),plain:"",fill:""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("load-more",r.lang)),1)]),_:1},8,["loading"])])):n.createCommentVNode("",!0)]))),128))])],64)):(n.openBlock(),n.createElementBlock("div",Ome,[r.canSendForAll&&!this.hasQuery?(n.openBlock(),n.createElementBlock("div",zme,[n.createElementVNode("div",jme,n.toDisplayString(e.$tds("send-for-all",r.lang)),1),n.createVNode(u,{modelValue:i.forAllTag,"onUpdate:modelValue":t[3]||(t[3]=m=>i.forAllTag=m)},null,8,["modelValue"])])):n.createCommentVNode("",!0),e.querySearchTopics.q?!e.typing&&!e.loading?(n.openBlock(),n.createElementBlock("div",$me,[n.createElementVNode("h4",Pme,n.toDisplayString(e.$tds("not-found",r.lang)),1),n.createElementVNode("p",Rme,n.toDisplayString(e.$tds("make-sure-to-type-something",r.lang)),1)])):n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",Lme,[t[7]||(t[7]=n.createElementVNode("img",{alt:"Search Topics",src:yme},null,-1)),n.createElementVNode("div",Bme,[n.createElementVNode("h3",null,n.toDisplayString(e.$tds("search-for-markers-classes-users",r.lang)),1),n.createElementVNode("span",Vme,n.toDisplayString(e.$tds("when-you-have-markers-classes",r.lang))+". ",1)])]))]))]),e.selectedTopics&&e.selectedTopics.length?(n.openBlock(),n.createElementBlock("div",Fme,[n.createElementVNode("button",{class:"selected-topics-button l-d-flex l-align-items-center",style:{padding:"0"},onClick:t[4]||(t[4]=m=>e.forAllTagChecked?i.forAllTag=!1:e.showSelected=!0)},[t[8]||(t[8]=n.createElementVNode("div",{class:"selected-topics-button-bg"},null,-1)),n.createElementVNode("div",Ume,n.toDisplayString(i.topicsSummary),1),n.createVNode(f,{class:"mr-2 bold link--text",type:"text"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.forAllTagChecked?e.$tds("clean",r.lang):e.$tds("see-all",r.lang)),1)]),_:1})]),n.createVNode(h,{show:e.showSelected,"onUpdate:show":t[6]||(t[6]=m=>e.showSelected=m),"lock-scroll":"",style:{"max-height":"500px","min-height":"180px"}},{default:n.withCtx(()=>[n.createElementVNode("div",Hme,[n.createElementVNode("div",Yme,n.toDisplayString(e.$tds("selected-recipients",r.lang)),1),n.createVNode(f,{onClick:t[5]||(t[5]=m=>e.showSelected=!1),circle:"",icon:"uil-multiply",class:"border-none gray-70--text f-24 p-1"})]),n.createElementVNode("div",Qme,[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.selectedTopics,m=>(n.openBlock(),n.createBlock(p,{onRemove:g=>i.removeTopic(m),key:m.id,kind:m.kind,name:m.name,closeable:!0,class:"mr-2 mb-2"},null,8,["onRemove","kind","name"]))),128))])]),_:1},8,["show"])])):n.createCommentVNode("",!0)])}const qme=xe(Mme,[["render",Wme],["__scopeId","data-v-ac94160c"]]),Gme=Object.freeze(Object.defineProperty({__proto__:null,default:qme},Symbol.toStringTag,{value:"Module"}));const Kme={tagName:"l-select",name:"LSelect",components:{ElSelect:CW}};function Jme(e,t,r,o,a,i){const l=n.resolveComponent("el-select");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-select"}),n.createSlots({default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.prefix?{name:"prefix",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"prefix",{},void 0,!0)]),key:"0"}:void 0,e.$slots.empty?{name:"empty",fn:n.withCtx(()=>[n.renderSlot(e.$slots,"empty",{},void 0,!0)]),key:"1"}:void 0]),1040)}const Zme=xe(Kme,[["render",Jme],["__scopeId","data-v-5bb89c93"]]),Xme=Object.freeze(Object.defineProperty({__proto__:null,default:Zme},Symbol.toStringTag,{value:"Module"}));const ehe={name:"LSwitch",components:{ElSwitch:KX},props:{modelValue:{type:Boolean,default:!1}},emits:["update:modelValue"],methods:{onUpdateModelValue(e){this.$emit("update:modelValue",e)}}};function the(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("el-switch");return n.openBlock(),n.createBlock(s,n.mergeProps(e.$attrs,{"model-value":r.modelValue,"onUpdate:modelValue":i.onUpdateModelValue,class:"l-switch"}),{"active-action":n.withCtx(()=>[n.createVNode(l,null,{default:n.withCtx(()=>t[0]||(t[0]=[n.createTextVNode("uil-check")])),_:1})]),"inactive-action":n.withCtx(()=>[n.createVNode(l,null,{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-times")])),_:1})]),default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16,["model-value","onUpdate:modelValue"])}const nhe=xe(ehe,[["render",the],["__scopeId","data-v-e8ddf878"]]),rhe=Object.freeze(Object.defineProperty({__proto__:null,default:nhe},Symbol.toStringTag,{value:"Module"}));/*!
|
|
42
42
|
* mustache.js - Logic-less {{mustache}} templates with JavaScript
|
|
43
43
|
* http://github.com/janl/mustache.js
|
|
44
|
-
*/var
|
|
45
|
-
`&&(d(),c="",u=0,r=!1);if(!g.scan(f))break;if(l=!0,y=g.scan(
|
|
44
|
+
*/var ohe=Object.prototype.toString,hl=Array.isArray||function(t){return ohe.call(t)==="[object Array]"};function Fh(e){return typeof e=="function"}function ahe(e){return hl(e)?"array":typeof e}function Yf(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function A4(e,t){return e!=null&&typeof e=="object"&&t in e}function ihe(e,t){return e!=null&&typeof e!="object"&&e.hasOwnProperty&&e.hasOwnProperty(t)}var lhe=RegExp.prototype.test;function she(e,t){return lhe.call(e,t)}var che=/\S/;function uhe(e){return!she(che,e)}var dhe={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};function fhe(e){return String(e).replace(/[&<>"'`=\/]/g,function(r){return dhe[r]})}var phe=/\s*/,mhe=/\s+/,O4=/\s*=/,hhe=/\s*\}/,ghe=/#|\^|\/|>|\{|&|=|!/;function vhe(e,t){if(!e)return[];var r=!1,o=[],a=[],i=[],l=!1,s=!1,c="",u=0;function d(){if(l&&!s)for(;i.length;)delete a[i.pop()];else i=[];l=!1,s=!1}var f,p,h;function m(E){if(typeof E=="string"&&(E=E.split(mhe,2)),!hl(E)||E.length!==2)throw new Error("Invalid tags: "+E);f=new RegExp(Yf(E[0])+"\\s*"),p=new RegExp("\\s*"+Yf(E[1])),h=new RegExp("\\s*"+Yf("}"+E[1]))}m(t||fr.tags);for(var g=new Ks(e),v,y,N,b,M,k;!g.eos();){if(v=g.pos,N=g.scanUntil(f),N)for(var w=0,C=N.length;w<C;++w)b=N.charAt(w),uhe(b)?(i.push(a.length),c+=b):(s=!0,r=!0,c+=" "),a.push(["text",b,v,v+1]),v+=1,b===`
|
|
45
|
+
`&&(d(),c="",u=0,r=!1);if(!g.scan(f))break;if(l=!0,y=g.scan(ghe)||"name",g.scan(phe),y==="="?(N=g.scanUntil(O4),g.scan(O4),g.scanUntil(p)):y==="{"?(N=g.scanUntil(h),g.scan(hhe),g.scanUntil(p),y="&"):N=g.scanUntil(p),!g.scan(p))throw new Error("Unclosed tag at "+g.pos);if(y==">"?M=[y,N,v,g.pos,c,u,r]:M=[y,N,v,g.pos],u++,a.push(M),y==="#"||y==="^")o.push(M);else if(y==="/"){if(k=o.pop(),!k)throw new Error('Unopened section "'+N+'" at '+v);if(k[1]!==N)throw new Error('Unclosed section "'+k[1]+'" at '+v)}else y==="name"||y==="{"||y==="&"?s=!0:y==="="&&m(N)}if(d(),k=o.pop(),k)throw new Error('Unclosed section "'+k[1]+'" at '+g.pos);return Mhe(yhe(a))}function yhe(e){for(var t=[],r,o,a=0,i=e.length;a<i;++a)r=e[a],r&&(r[0]==="text"&&o&&o[0]==="text"?(o[1]+=r[1],o[3]=r[3]):(t.push(r),o=r));return t}function Mhe(e){for(var t=[],r=t,o=[],a,i,l=0,s=e.length;l<s;++l)switch(a=e[l],a[0]){case"#":case"^":r.push(a),o.push(a),r=a[4]=[];break;case"/":i=o.pop(),i[5]=a[2],r=o.length>0?o[o.length-1][4]:t;break;default:r.push(a)}return t}function Ks(e){this.string=e,this.tail=e,this.pos=0}Ks.prototype.eos=function(){return this.tail===""};Ks.prototype.scan=function(t){var r=this.tail.match(t);if(!r||r.index!==0)return"";var o=r[0];return this.tail=this.tail.substring(o.length),this.pos+=o.length,o};Ks.prototype.scanUntil=function(t){var r=this.tail.search(t),o;switch(r){case-1:o=this.tail,this.tail="";break;case 0:o="";break;default:o=this.tail.substring(0,r),this.tail=this.tail.substring(r)}return this.pos+=o.length,o};function Yi(e,t){this.view=e,this.cache={".":this.view},this.parent=t}Yi.prototype.push=function(t){return new Yi(t,this)};Yi.prototype.lookup=function(t){var r=this.cache,o;if(r.hasOwnProperty(t))o=r[t];else{for(var a=this,i,l,s,c=!1;a;){if(t.indexOf(".")>0)for(i=a.view,l=t.split("."),s=0;i!=null&&s<l.length;)s===l.length-1&&(c=A4(i,l[s])||ihe(i,l[s])),i=i[l[s++]];else i=a.view[t],c=A4(a.view,t);if(c){o=i;break}a=a.parent}r[t]=o}return Fh(o)&&(o=o.call(this.view)),o};function xn(){this.templateCache={_cache:{},set:function(t,r){this._cache[t]=r},get:function(t){return this._cache[t]},clear:function(){this._cache={}}}}xn.prototype.clearCache=function(){typeof this.templateCache<"u"&&this.templateCache.clear()};xn.prototype.parse=function(t,r){var o=this.templateCache,a=t+":"+(r||fr.tags).join(":"),i=typeof o<"u",l=i?o.get(a):void 0;return l==null&&(l=vhe(t,r),i&&o.set(a,l)),l};xn.prototype.render=function(t,r,o,a){var i=this.getConfigTags(a),l=this.parse(t,i),s=r instanceof Yi?r:new Yi(r,void 0);return this.renderTokens(l,s,o,t,a)};xn.prototype.renderTokens=function(t,r,o,a,i){for(var l="",s,c,u,d=0,f=t.length;d<f;++d)u=void 0,s=t[d],c=s[0],c==="#"?u=this.renderSection(s,r,o,a,i):c==="^"?u=this.renderInverted(s,r,o,a,i):c===">"?u=this.renderPartial(s,r,o,i):c==="&"?u=this.unescapedValue(s,r):c==="name"?u=this.escapedValue(s,r,i):c==="text"&&(u=this.rawValue(s)),u!==void 0&&(l+=u);return l};xn.prototype.renderSection=function(t,r,o,a,i){var l=this,s="",c=r.lookup(t[1]);function u(p){return l.render(p,r,o,i)}if(c){if(hl(c))for(var d=0,f=c.length;d<f;++d)s+=this.renderTokens(t[4],r.push(c[d]),o,a,i);else if(typeof c=="object"||typeof c=="string"||typeof c=="number")s+=this.renderTokens(t[4],r.push(c),o,a,i);else if(Fh(c)){if(typeof a!="string")throw new Error("Cannot use higher-order sections without the original template");c=c.call(r.view,a.slice(t[3],t[5]),u),c!=null&&(s+=c)}else s+=this.renderTokens(t[4],r,o,a,i);return s}};xn.prototype.renderInverted=function(t,r,o,a,i){var l=r.lookup(t[1]);if(!l||hl(l)&&l.length===0)return this.renderTokens(t[4],r,o,a,i)};xn.prototype.indentPartial=function(t,r,o){for(var a=r.replace(/[^ \t]/g,""),i=t.split(`
|
|
46
46
|
`),l=0;l<i.length;l++)i[l].length&&(l>0||!o)&&(i[l]=a+i[l]);return i.join(`
|
|
47
|
-
`)};xn.prototype.renderPartial=function(t,r,o,a){if(o){var i=this.getConfigTags(a),l=Fh(o)?o(t[1]):o[t[1]];if(l!=null){var s=t[6],c=t[5],u=t[4],d=l;c==0&&u&&(d=this.indentPartial(l,u,s));var f=this.parse(d,i);return this.renderTokens(f,r,o,d,a)}}};xn.prototype.unescapedValue=function(t,r){var o=r.lookup(t[1]);if(o!=null)return o};xn.prototype.escapedValue=function(t,r,o){var a=this.getConfigEscape(o)||fr.escape,i=r.lookup(t[1]);if(i!=null)return typeof i=="number"&&a===fr.escape?String(i):a(i)};xn.prototype.rawValue=function(t){return t[1]};xn.prototype.getConfigTags=function(t){return hl(t)?t:t&&typeof t=="object"?t.tags:void 0};xn.prototype.getConfigEscape=function(t){if(t&&typeof t=="object"&&!hl(t))return t.escape};var fr={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(e){Ns.templateCache=e},get templateCache(){return Ns.templateCache}},Ns=new xn;fr.clearCache=function(){return Ns.clearCache()};fr.parse=function(t,r){return Ns.parse(t,r)};fr.render=function(t,r,o,a){if(typeof t!="string")throw new TypeError('Invalid template! Template should be a "string" but "'+the(t)+'" was given as the first argument for mustache#render(template, view, partials)');return Ns.render(t,r,o,a)};fr.escape=she;fr.Scanner=Ks;fr.Context=Yi;fr.Writer=xn;const ghe={props:["value","schema","entity"],methods:{hasRouterLink(){return Dt(this.schema,"options.routerLink")},getRouterLink(){const e=Dt(this.schema,"options.routerLink");return fr.render(e,this.entity)}}},vhe={key:1};function yhe(e,t,r,o,a,i){const l=n.resolveComponent("router-link");return e.$options.methods.hasRouterLink(e.props)?(n.openBlock(),n.createBlock(l,{key:0,to:e.$options.methods.getRouterLink(e.props)},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.value),1)]),_:1},8,["to"])):(n.openBlock(),n.createElementBlock("span",vhe,n.toDisplayString(r.value),1))}const Mhe=xe(ghe,[["render",yhe]]),bhe={props:["value","schema"],methods:{formatValue(e){return e}}};function whe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("span",null,n.toDisplayString(e.$options.methods.formatValue(r.value)),1)}const Nhe=xe(bhe,[["render",whe]]),khe={props:["value","schema"],methods:{formatValue(e){return isNaN(e)||e===null||e===void 0?"-":Number(e/100).toLocaleString("pt-BR",{style:"currency",currency:"BRL"})}}};function xhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("span",null,n.toDisplayString(e.$options.methods.formatValue(r.value)),1)}const Che=xe(khe,[["render",xhe]]),Ehe={props:["value","schema"]},The=["href"];function Dhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("a",{target:"_blank",href:`mailto:${r.value}`},n.toDisplayString(r.value),9,The)}const She=xe(Ehe,[["render",Dhe]]),_he={props:["value","schema"],methods:{formatValue(e,t){if(!e)return"-";const r=Dt(t,"options.format","dd/MM/yyyy hh:mm:ss");return Nd(e).format(r)}}};function Ihe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("span",null,n.toDisplayString(e.$options.methods.formatValue(r.value,r.schema)),1)}const Ahe=xe(_he,[["render",Ihe]]),T8={};T8.register=function(){Sn.register({type:"String"},"default",Mhe),Sn.register({type:"Date"},"default",Ahe),Sn.register({type:"Number"},"default",Nhe),Sn.register({format:"Amount"},"default",Che),Sn.register({format:"Email"},"default",She)};const Ohe={props:{perPage:Number,pagesCount:Number,totalCount:Number,columnSpecs:{type:Array},includedIds:{type:Array},excludedIds:{type:Array},selectable:Boolean,clickable:Boolean,multiselect:Boolean,page:Object},data(e){return{checked:this.computeChecked(e)}},emits:["selected","click-item"],computed:{includedAll(){return this.includedIds.toString()==="*"},estimatedRows(){return this.page&&this.pagesCount>1&&this.page.index>=this.pagesCount-1?this.totalCount%this.perPage:this.perPage}},methods:{getColumnComponent(e){return e.component},getColumnValue(e,t){return Dt(e,t.path)},computeChecked(e){const t=e||this;if(!t.page||!t.page.data)return[];let r=t.includedIds,o=t.excludedIds,a=t.includedAll;return t.page.data.map(i=>a&&!o.includes(i.id)||r.includes(i.id))}},watch:{includedAll(){this.checked=this.computeChecked(this)},includedIds(){this.checked=this.computeChecked(this)},excludedIds(){this.checked=this.computeChecked(this)}}},zhe={class:"l-table-tbody"},jhe={key:"selector",class:"l-table-cell l-table-column-selector"},Lhe=["onClick"],Bhe={key:"selector",class:"l-table-cell l-table-column-selector"},Vhe={key:"selector",class:"l-table-cell l-table-column-selector"};function $he(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox");return n.openBlock(),n.createElementBlock("tbody",zhe,[r.page&&r.page.loaded?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:0},n.renderList(r.page.data,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c,class:n.normalizeClass({"l-table-selected":a.checked[c]})},[r.selectable?(n.openBlock(),n.createElementBlock("td",jhe,[n.createVNode(l,{modelValue:a.checked[c],"onUpdate:modelValue":u=>a.checked[c]=u,class:"l-table-selector",type:r.multiselect?"checkbox":"radio",onChange:()=>e.$emit("selected",{key:s.id,selected:a.checked[c]})},null,8,["modelValue","onUpdate:modelValue","type","onChange"])])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.columnSpecs,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(["l-table-cell",`align-${u.align}${r.clickable?" cursor-pointer":""}`]),onClick:f=>e.$emit("click-item",s)},[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.getColumnComponent(u)),{value:i.getColumnValue(s,u),schema:u,entity:s},null,8,["value","schema","entity"]))],10,Lhe))),128))],2))),128)):r.page&&r.page.loading?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:1},n.renderList(i.estimatedRows,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c},[r.selectable?(n.openBlock(),n.createElementBlock("td",Bhe,[n.createVNode(l,{disabled:"",class:"l-table-selector",type:r.multiselect?"checkbox":"radio",value:i.includedAll},null,8,["type","value"])])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.columnSpecs,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(["l-table-cell",`align-${u.align}`])},t[0]||(t[0]=[n.createElementVNode("span",{class:"l-table-skeleton"},null,-1)]),2))),128))]))),128)):(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:2},n.renderList(i.estimatedRows,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c},[r.selectable?(n.openBlock(),n.createElementBlock("td",Vhe,[n.createVNode(l,{disabled:"",class:"l-table-selector",type:r.multiselect?"checkbox":"radio",checked:i.includedAll},null,8,["type","checked"])])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.columnSpecs,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(["l-table-cell",`align-${u.align}`])},t[1]||(t[1]=[n.createElementVNode("span",{class:"l-table-skeleton error"},null,-1)]),2))),128))]))),128))])}const Phe=xe(Ohe,[["render",$he]]);const Rhe={props:{title:String,maxWidth:{type:Number,default:null},minWidth:{type:Number,default:50}},data(){return{dragging:!1,deltaX:0}},computed:{handleStyle(){return this.dragging?{transform:`translateX(${this.deltaX}px)`}:null}},methods:{currentWidth(){return this.$el.parentElement.getBoundingClientRect().width},limitDeltaX(e){let t=this.currentWidth();return this.limitWidth(t+e)-t},limitWidth(e){return e?this.maxWidth&&this.maxWidth<e?this.maxWidth:this.minWidth&&this.minWidth>e?this.minWidth:e:null},resize(e){this.$emit("resize",this.limitWidth(e))},drag(e){this.dragging||this.unregisterDocumentHandlers();let t=e.clientX-this.dragStartClientX;this.deltaX=this.limitDeltaX(t),console.log("drag",this.deltaX)},dragStart(e){this.registerDocumentHandlers(),this.deltaX=0,this.dragging=!0,this.dragStartClientX=e.clientX,console.log("dragStart",e)},dragEnd(e){if(this.deltaX){let t=this.currentWidth()+this.deltaX;this.resize(t)}this.unregisterDocumentHandlers(),this.deltaX=0,this.dragging=!1,this.dragStartClientX=0,console.log("dragEnd",e)},registerDocumentHandlers(){this.unregisterDocumentHandlers(),this._documentMouseMove=e=>this.drag(e),this._documentMouseUp=e=>this.dragEnd(e),document.body.style.cursor="col-resize",document.addEventListener("mousemove",this._documentMouseMove),document.addEventListener("mouseup",this._documentMouseUp),document.onselectstart=()=>!1,document.ondragstart=()=>!1},unregisterDocumentHandlers(){document.removeEventListener("mousemove",this._documentMouseMove),document.removeEventListener("mouseup",this._documentMouseUp),document.body.style.cursor="",document.onselectstart=null,document.ondragstart=null}}};function Fhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["mt-handle",a.dragging?"dragging":""]),style:n.normalizeStyle(i.handleStyle),onDblclick:t[0]||(t[0]=l=>i.resize(null)),onMousedown:t[1]||(t[1]=(...l)=>i.dragStart&&i.dragStart(...l))},null,38)}const Uhe=xe(Rhe,[["render",Fhe]]);const Hhe={components:{LTableHeaderResizer:Uhe},props:{spec:{type:Object}},emits:["spec:update"],data:e=>({localSpec:e.spec}),computed:{resizable(){return this.localSpec.field&&this.localSpec.field.resizable},reordable(){return!0},icon(){return this.$L.Icons.get(this.localSpec.field)}},methods:{resizeColumn(e,t){e.width=t},toggleSorting(e){let t=this.localSpec.column.sortDirection,r="asc";t?t.toLowerCase()==="asc"&&(r="desc"):r="asc",this.$emit("sort",{direction:r,cumulative:e})}},watch:{localSpec:{handler(e){this.$emit("spec:update",e)},deep:!0}}},Yhe={key:1,class:"l-table-header-cell-content"};function Qhe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-tooltip"),c=n.resolveComponent("LTableHeaderResizer");return n.openBlock(),n.createElementBlock("th",{class:"l-table-header-cell l-table-cell",style:n.normalizeStyle({"--l-table-col-width":r.spec.column.width?`${r.spec.column.width}px`:"auto"})},[r.spec.sortable?(n.openBlock(),n.createElementBlock("a",{key:0,href:"#",class:n.normalizeClass(["l-table-header-cell-content",[r.spec.column.sortDirection?"active":null,`l-table-header-align-${r.spec.align}`]]),onClick:t[0]||(t[0]=n.withModifiers(u=>i.toggleSorting(),["prevent"]))},[n.createVNode(s,{key:"tooltip",disabled:!r.spec.description,content:r.spec.description,placement:"top","open-delay":600,offset:0},{default:n.withCtx(()=>[n.createElementVNode("span",null,[i.icon?(n.openBlock(),n.createBlock(l,{key:0,class:"l-table-header-icon"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.icon),1)]),_:1})):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(r.spec.title),1)])]),_:1},8,["disabled","content"]),n.createElementVNode("i",{class:n.normalizeClass(["l-table-sorter-icon uil uil-arrow-down",`l-table-sorter-${r.spec.column.sortDirection||"default"}`])},null,2)],2)):(n.openBlock(),n.createElementBlock("span",Yhe,[n.createVNode(s,{disabled:!r.spec.description,content:r.spec.description,placement:"top","open-delay":600,offset:0},{default:n.withCtx(()=>[n.createElementVNode("span",null,[i.icon?(n.openBlock(),n.createBlock(l,{key:0,class:"l-table-header-icon"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.icon),1)]),_:1})):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(r.spec.title),1)])]),_:1},8,["disabled","content"])])),t[2]||(t[2]=n.createElementVNode("span",{style:{width:"12px"}},null,-1)),i.resizable?(n.openBlock(),n.createBlock(c,{key:2,onResize:t[1]||(t[1]=u=>i.resizeColumn(r.spec.column,u))})):n.createCommentVNode("",!0)],4)}const Whe=xe(Hhe,[["render",Qhe]]);const qhe={props:["loading"]};function Ghe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-table-header-loader",{loading:r.loading}])},null,2)}const Khe=xe(qhe,[["render",Ghe]]);const Jhe={components:{LTableHeaderCell:Whe,LTableHeaderLoader:Khe},props:{columnSpecs:{type:Array},loading:{type:Boolean,default:!1},includedIds:{type:Array},excludedIds:{type:Array},total:{type:Number},selectable:{type:Boolean},multiselect:{type:Boolean}},data:e=>({localColumnSpecs:e.columnSpecs}),emits:["columnSpecs:update","selected"],computed:{selectedEverything(){let e=this.includedIds.length===this.total&&this.total>0,t=this.includedIds.toString()==="*"&&this.excludedIds.length==0;return e||t},selectedNothing(){return this.includedIds.length===0},selectedSomethings(){return!this.selectedNothing&&!this.selectedEverything}},methods:{changeSpecSort(e,{direction:t,cumulative:r}){if(console.log("changeSpecSort",e,t,r),r){let a=this.localColumnSpecs.reduce((i,l)=>Math.max(i,l.column.sortOrder),0)+1;e.column.sortOrder=a,e.column.sortDirection=t}else{for(let o of this.localColumnSpecs)o.column.sortOrder=null,o.column.sortDirection=null;e.column.sortOrder=1,e.column.sortDirection=t}},syncSpec(e){let t=this.localColumnSpecs.findIndex(r=>r.field===e.field);this.localColumnSpecs.splice(t,1,e)},changeSelection(e){this.$emit("selected",{key:"*",selected:e})}},watch:{localColumnSpecs:{handler(e){console.log("localColumnSpecs",e),this.$emit("columnSpecs:update",e)},deep:!0}}},Zhe={class:"l-table-header"},Xhe={key:0,scope:"col",class:"l-table-header-cell l-table-cell l-table-column-selector"},e2e={class:"l-table-header-extras"},t2e={colspan:"999"};function n2e(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox"),s=n.resolveComponent("LTableHeaderCell"),c=n.resolveComponent("LTableHeaderLoader");return n.openBlock(),n.createElementBlock("thead",Zhe,[n.createElementVNode("tr",null,[r.selectable?(n.openBlock(),n.createElementBlock("th",Xhe,[r.multiselect?(n.openBlock(),n.createBlock(l,{key:0,class:"l-table-selector",type:"checkbox",value:i.selectedEverything,indeterminate:i.selectedSomethings,onChange:t[0]||(t[0]=u=>i.changeSelection(u))},null,8,["value","indeterminate"])):n.createCommentVNode("",!0)])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.localColumnSpecs,(u,d)=>(n.openBlock(),n.createBlock(s,{key:d,spec:u,"onSpec:update":i.syncSpec,onSort:f=>i.changeSpecSort(u,f),ref_for:!0,ref:"headers"},null,8,["spec","onSpec:update","onSort"]))),128))]),n.createElementVNode("tr",e2e,[n.createElementVNode("td",t2e,[n.createVNode(c,{loading:r.loading},null,8,["loading"]),t[1]||(t[1]=n.createElementVNode("div",{class:"l-table-header-shadow-top"},null,-1))])])])}const r2e=xe(Jhe,[["render",n2e]]);const o2e={},a2e={class:"l-table-endspace"};function i2e(e,t){return n.openBlock(),n.createElementBlock("div",a2e)}const l2e=xe(o2e,[["render",i2e]]);const s2e={props:{loading:Boolean,automatic:Boolean},mounted(){this.intersectionObserver=new IntersectionObserver(([e])=>{e&&e.isIntersecting&&this.automatic&&this.$emit("appeared")}),this.intersectionObserver.observe(this.$el)},unmounted(){this.intersectionObserver&&this.intersectionObserver.disconnect()}};function c2e(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-table-loadmore",{loading:r.loading}]),onClick:t[0]||(t[0]=l=>e.$emit("click"))},t[1]||(t[1]=[n.createElementVNode("a",{href:"#",class:"l-table-loadmore-link"},"Carregar mais",-1)]),2)}const u2e=xe(s2e,[["render",c2e]]);const d2e=2e3,f2e={name:"LTableReloader",data(){return{canReload:!0}},methods:{reload(){this.canReload=!1,this.$emit("reload"),setTimeout(()=>this.canReload=!0,d2e)}}},p2e={class:"l-table-reloader"},m2e={class:"l-table-reloader-content"};function h2e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",p2e,[n.createElementVNode("div",m2e,[n.createVNode(l,{size:"22"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-cloud-exclamation")])),_:1}),t[3]||(t[3]=n.createElementVNode("span",{style:{"margin-left":"8px",flex:"1 1"}},"Algumas informações não puderam ser carregadas.",-1)),n.createVNode(s,{size:"mini",onClick:t[0]||(t[0]=c=>i.reload())},{default:n.withCtx(()=>t[2]||(t[2]=[n.createTextVNode("Recarregar")])),_:1})])])}const g2e=xe(f2e,[["render",h2e]]);const v2e={props:{height:{type:Number}}},y2e={class:"l-table-spacer"};function M2e(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("tbody",y2e,[n.createElementVNode("tr",{style:n.normalizeStyle({height:`${r.height}px`})},t[0]||(t[0]=[n.createElementVNode("td",{class:"l-table-spacer-bg",colspan:"999"},null,-1)]),4)])}const b2e=xe(v2e,[["render",M2e]]);var w2e=f8;function N2e(e){var t=e==null?0:e.length;return t?w2e(e,1):[]}var k2e=N2e;const x2e=St(k2e);function C2e(){}var E2e=C2e,Qf=Wb,T2e=E2e,D2e=zh,S2e=1/0,_2e=Qf&&1/D2e(new Qf([,-0]))[1]==S2e?function(e){return new Qf(e)}:T2e,I2e=_2e,A2e=Ah,O2e=c8,z2e=u8,j2e=Oh,L2e=I2e,B2e=zh,V2e=200;function $2e(e,t,r){var o=-1,a=O2e,i=e.length,l=!0,s=[],c=s;if(r)l=!1,a=z2e;else if(i>=V2e){var u=t?null:L2e(e);if(u)return B2e(u);l=!1,a=j2e,c=new A2e}else c=t?[]:s;e:for(;++o<i;){var d=e[o],f=t?t(d):d;if(d=r||d!==0?d:0,l&&f===f){for(var p=c.length;p--;)if(c[p]===f)continue e;t&&c.push(f),s.push(d)}else a(c,f,r)||(c!==s&&c.push(f),s.push(d))}return s}var P2e=$2e,R2e=P2e;function F2e(e){return e&&e.length?R2e(e):[]}var U2e=F2e;const H2e=St(U2e);function Y2e({key:e,selected:t},r){let{loadedPages:o,allowInvertedSelection:a,includedIds:i,excludedIds:l,multiselect:s,itemToId:c=h=>h}=r;if(!e===void 0||e===null)return{includedIds:i,excludedIds:l};if(e==="*"){if(i.splice(0,i.length),l.splice(0,l.length),t&&s&&a&&i.push("*"),t&&s&&!a){let h=x2e(o.filter(g=>g.data).map(g=>g.data));i=H2e(h.map(g=>c(g)))}return{includedIds:i,excludedIds:l}}let d=i.includes("*"),f=i.includes(e),p=l.includes(e);if(s||(i.splice(0,i.length),l.splice(0,l.length)),d&&s){if(t&&p){let h=l.indexOf(e);l.splice(h,1)}!t&&!p&&s&&l.push(e)}else if(t&&!f&&(s?i.push(e):i=[e]),!t&&f){let h=i.indexOf(e);i.splice(h,1)}return{includedIds:i,excludedIds:l}}function Q2e({pagesCount:e,currentPage:t,endingAdjacents:r=1,adjacents:o=2,next:a=!0,previous:i=!0,last:l=!1,first:s=!1,fixedWidth:c=!0}){const u=[];if(!e)return u;const d=c?r*2+o*2+3:r*2+1;if(e<=d)for(let f=0;f<e;f++)u.push(f);else{let f=0;for(let g=0;g<Math.min(r,e);g++)u.push(f=g);let p=r+o*2,h=o,m=o;c&&t<p&&(m+=p-t),c&&e-t-1<p&&(h+=p-(e-t-1));for(let g=Math.max(f+1,t-h);g<Math.min(t+m+1,e);g++)f+2===g&&u.push(f=f+1),f+1!==g&&u.push("...1"),u.push(f=g);for(let g=Math.max(f+1,e-r);g<e;g++)f+2===g&&u.push(f=f+1),f+1!==g&&u.push("...2"),u.push(f=g)}return i&&u.unshift("<"),a&&u.push(">"),s&&u.unshift("<<"),l&&u.push(">>"),u}const W2e={name:"LTablePagination",props:{pagesCount:Number,totalCount:Number,currentPage:{type:Number,default:2}},computed:{visiblePages(){return this.totalCount?Q2e({pagesCount:this.pagesCount,currentPage:this.currentPage,adjacents:1,endingAdjacents:1,fixedWidth:!0}):["...1"]}},methods:{clicked(e){typeof e=="number"?this.goto(parseInt(e)):e==="<"?this.goto(this.currentPage-1):e===">"?this.goto(this.currentPage+1):e==="<<"?this.goto(0):e===">>"&&this.goto(this.pagesCount-1)},goto(e){this.currentPage!=e&&(e=Math.max(0,Math.min(e,this.pagesCount-1)),this.$emit("goto",e))}}},q2e={class:"l-table-pagination"},G2e=["onClick"];function K2e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",q2e,[n.createVNode(n.TransitionGroup,{tag:"div",class:"l-table-pagination-pages",name:"l-table-pagination-transition"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.visiblePages,s=>(n.openBlock(),n.createElementBlock("span",{class:n.normalizeClass(["l-table-pagination-page-item",{active:s==r.currentPage}]),key:s,onClick:c=>i.clicked(s)},[s==="<"?(n.openBlock(),n.createBlock(l,{key:0,size:"20"},{default:n.withCtx(()=>t[0]||(t[0]=[n.createTextVNode("uil-angle-left")])),_:1})):s===">"?(n.openBlock(),n.createBlock(l,{key:1,size:"20"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-angle-right")])),_:1})):s==="...1"||s==="...2"?(n.openBlock(),n.createElementBlock(n.Fragment,{key:2},[n.createTextVNode(" ... ")],64)):(n.openBlock(),n.createElementBlock(n.Fragment,{key:3},[n.createTextVNode(n.toDisplayString(s+1),1)],64))],10,G2e))),128))]),_:1})])}const J2e=xe(W2e,[["render",K2e]]);T8.register();const Z2e=100,X2e=3e4,e1e=3,t1e="scrollBehavior"in document.documentElement.style,n1e={name:"LTable",tagName:"l-table",components:{LTableHeader:r2e,LTableBody:Phe,LTableReloader:g2e,LTableLoadMore:u2e,LTableEndspace:l2e,LTableBodySpacer:b2e,LTablePagination:J2e},props:{rows:{type:Array},primaryKey:{type:String,default:"id"},fetch:{type:Function},columns:{type:Array},pagination:{type:Boolean,default:!1},display:{type:String,enum:["all","more","paged"],default:"all"},autoLoadMore:{type:Boolean,default:!1},schema:{type:Object,required:!0},selectable:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},multiselect:{type:Boolean,default:!0},allowInvertedSelection:{type:Boolean,default:!0},rowHeight:{type:Number,default:32},borderTick:{type:Number,default:1},snapToPageOnMore:{type:Boolean,default:!0},stickyColumnLeft:{type:Boolean,default:!1},recycle:{type:Boolean,default:!0},limitPerPage:{type:Number,default:50}},emits:["loading","changeSelection","click-item"],mounted(){this.computeVisibleRows()},data(e){let t=[];return e.columns.length&&(t=e.columns.map(r=>this.buildColumnSpec(r))),{fetching:0,headerHeight:56,nonce:0,id:0,extraRows:15,lastComputedOffsetY:0,includedIds:[],excludedIds:[],scrollAtTop:!0,scrollAtLeft:!0,totalCount:0,firstPage:null,currentPage:null,lastPage:null,loadedPages:[],columnSpecs:t}},watch:{totalCount(e){this.$emit("changeSelection",{includedIds:this.includedIds,excludedIds:this.excludedIds,selectionCount:this.selectionCount,totalCount:e})},somePageIsLoading(e){this.$emit("loading",e)}},computed:{perPage(){return Number(this.limitPerPage)},pagesCount(){return Math.floor(this.totalCount/this.perPage)+1},selectionCount(){return this.includedIds.toString()==="*"?this.totalCount-this.excludedIds.length:this.includedIds.length},lastLoadedPage(){return this.loadedPages.length},isLoadMoreVisible(){return this.display==="more"&&this.lastLoadedPage<this.pagesCount},isPaginationVisible(){return(this.display==="page"||!!this.pagination)&&this.display!=="more"&&this.pagesCount!==null},isLeftColumnSticky(){return this.stickyColumnLeft||this.columns&&this.columns[0]&&this.columns[0].sticky},usingRecycledLayout(){return this.display!=="paged"&&this.recycle},hasVisibleFailedPages(){for(let e=this.firstPageRendered;e<=this.lastPageRendered;e++)if(this.loadedPages[e]&&this.loadedPages[e].failed)return!0;return!1},firstPageRendered(){return!this.usingRecycledLayout&&this.display!=="paged"?0:this.firstPage},lastPageRendered(){return this.display==="paged"?this.firstPage:this.usingRecycledLayout?this.lastPage:Math.max(0,this.lastLoadedPage-1)},visiblePages(){let e=[];for(let t=this.firstPageRendered;t<=this.lastPageRendered;t++){let r=this.loadedPages[t]||{index:t};e.push(r)}return e},contentStyle(){return{"--l-table-primary-color":"#2F8AF5","--l-table-warning-color":"#fd3a57","--l-table-bg-color":"white","--l-table-header-height":`${this.headerHeight}px`,"--l-table-header-text-color":"#232B34","--l-table-header-border-color":"#E8E8E8","--l-table-skeleton-height":`${Math.min(this.rowHeight-8,8)}px`,"--l-table-loader-height":"3px","--l-table-loader-color":"var(--l-table-primary-color)","--l-table-row-height":`${this.rowHeight}px`,"--l-table-cell-padding":"0 8px","--l-table-row-hover-color":"#fafbfd","--l-table-row-selected-color":"#eef5fa","--l-table-row-selected-hover-color":"#e6f0f8","--l-table-border-color":"#D3DAE6","--l-table-border-tick":`${this.borderTick}px`,"--l-table-selector-width":`${this.selectable?Math.min(this.headerHeight,this.rowHeight):0}px`,"--l-table-loadmore-height":"46px","--l-table-pagination-height":"48px","--l-table-pagination-color":"var(--l-table-primary-color)","--l-table-pagination-bg-color":"white","--l-table-reloader-margin":"16px","--l-table-endspace-bg-color":"#f5f5f5","--l-table-link-color":"var(--l-table-primary-color)"}},contentClasses(){return{"l-table-at-top":this.scrollAtTop,"l-table-at-left":this.scrollAtLeft,"l-table-sticky-column-left":this.isLeftColumnSticky}},spacing(){let e=0,t=0,r=this.display,o=this.totalCount;return r==="more"&&(o=this.loadedPages.length*this.perPage),(r==="all"||r==="more")&&(e=this.firstPageRendered*this.perPage*this.rowHeight,t=Math.max(0,(o-(this.lastPageRendered+1)*this.perPage)*this.rowHeight)),{top:Math.max(0,e),bottom:Math.max(0,t)}},rect(){return this.$refs.container.getBoundingClientRect()},somePageIsLoading(){return this.loadedPages.map(e=>e.loading).some(e=>e)}},methods:{itemToId(e){return e?this.primaryKey?e[this.primaryKey]:e:null},scrollTo(e=0,t){let r="auto";if(t){let o=this.$refs.container.scrollTop,a=this.perPage*this.rowHeight+1;r=Math.abs(o-e)<a?"smooth":"auto"}this.$refs.container.scrollTo({top:e,behavior:r})},gotoPage(e,t){if(e=Math.max(0,Math.min(this.pagesCount,e)),this.display==="paged"){this.setViewablePages(e,e,e),this.scrollTo(0,!0);return}this.display==="more"?this.setViewablePages(e-1,e,e):this.setViewablePages(e,e,e);let r=e*this.rowHeight*this.perPage;this.scrollTo(r,t)},async loadMore(e){let t=this.loadedPages[this.loadedPages.length-1];if(!t||t.loading)return!1;let r=this.loadedPages.length;this.setViewablePages(this.firstPage,r),e&&this.snapToPageOnMore&&t1e&&setTimeout(()=>this.gotoPage(r,!0),100)},reload(){this.id++,this.fetching=0,this.firstPage=null,this.lastPage=null,this.totalCount=null,this.loadedPages=[],this.includedIds=[],this.excludedIds=[],this.gotoPage(0),this.computeVisibleRows()},reloadFailedPages(){let e=0;for(let t=this.firstPageRendered;t<=this.lastPageRendered&&!(!(!this.loadedPages[t]||!this.loadedPages[t].failed)&&(this.loadedPages[t]=null,this.fetchPage(t),++e>=e1e));t++);},onScroll(){if(!(this.getScrollSpeed()>X2e)&&!this._scrollDebounce)return this.computeVisibleRows();clearTimeout(this._scrollDebounce),this._scrollDebounce=setTimeout(()=>{this.computeVisibleRows(),this._scrollDebounce=null},Z2e)},getScrollSpeed(){let e=this._lastOffsetY||0,t=this._lastOffsetYTime||0,r=this._lastOffsetY=this.$refs.container.scrollTop,o=this._lastOffsetYTime=Date.now();return Math.abs(1e3*(e-r)/(o-t))},computeVisibleRows(){let e=this.$refs.container.scrollTop,t=this.$refs.container.scrollLeft,r=this.lastComputedOffsetY;this.scrollAtTop=e===0,this.scrollAtLeft=t===0;let o=Math.abs(r-e);if(e>2&&r>2&&o<150||(this.lastComputedOffsetY=e,this.display==="paged"))return;let i=this.rect.height-this.headerHeight,l=Math.max(0,Math.floor(e/this.rowHeight)),s=Math.ceil(i/this.rowHeight),c=l+s,u=this.extraRows,d=this.perPage,f=Math.floor((l-u)/this.perPage),p=Math.floor((c+u)/d),h=p>=this.pagesCount-1?s:s/2,m=Math.floor((l+h)/this.perPage);if(this.display==="more"){for(f=Math.min(f,this.lastLoadedPage);!this.loadedPages[f]&&f>0;)f--;for(p=Math.max(p,f);!this.loadedPages[p]&&p>f&&p>0;)p--}this.setViewablePages(f,p,m)},setViewablePages(e=0,t=0,r=0){this.display==="paged"&&(t=e),e=Math.min(Math.max(e,0),this.pagesCount-1),t=Math.min(Math.max(t,e),this.pagesCount-1),r=Math.min(t,Math.max(e,r||0));let o=e!==this.firstPage||t!==this.lastPage;this.firstPage=e,this.lastPage=t,this.currentPage=r,o&&this.scheduleFeching()},buildColumnSpec(e){if(!this.schema.fields)throw new Error("Missing schema.fields!");const t=this.schema.fields.find(o=>o.path===e.path);if(!t)throw new Error(`Missing field schema for path ${e.path}`);const r=this.$L.FieldTypeComponents.get(t,"default");return Object.assign({},t,{width:e.width||null,sortable:t?t.sortable:!1,sticky:t&&t.sticky||e.sticky||!1,align:t&&t.align||"left",column:e,field:t,component:r})},handleColumnSpecsUpdate(e){this.columnSpecs=e,this.reload()},changeSelection({key:e,selected:t}){const{includedIds:r,excludedIds:o}=Y2e({key:e,selected:t},this);this.includedIds=r,this.excludedIds=o,this.$nextTick(()=>{this.$emit("changeSelection",{includedIds:this.includedIds,excludedIds:this.excludedIds,selectionCount:this.selectionCount,totalCount:this.totalCount})})},scheduleFeching(){for(let e=this.firstPage;e<=this.lastPage;e++)this.fetchPage(e)},async fetchPage(e){let t=this.loadedPages[e];if(t)return t;t=this.loadedPages[e]={id:this.id,index:e,startedAt:Date.now(),duration:null,loading:!0,loaded:!1,failed:!1,error:null,data:null};try{this.fetching++;const{hits:r,total:o}=await this.resolvePageData(e);Object.assign(t,{duration:Date.now()-t.startedAt,loading:!1,loaded:!0,data:r});let a=this.loadedPages.indexOf(t)>=0;o!==void 0&&a&&(this.totalCount=o)}catch(r){console.error("LTable","Failed to call `fetch` callback",r),Object.assign(t,{loading:!1,failed:!0,error:r.toString()})}finally{this.id===t.id&&this.fetching--}return t},async resolvePageData(e){if(this.rows){let t=this.perPage,r=e*t;return{data:this.rows.slice(r,r+t),total:this.rows.length}}else{if(this.fetch)return await this.fetch({page:e,offset:e*this.perPage,limit:this.perPage,schema:this.schema,columns:this.columns,perPage:this.perPage,primaryKey:this.primaryKey});throw new Error("Cannot discover data. Either `rows` or `fetch` property must be assigned to table")}}}},r1e={class:"l-table-table",border:"0"};function o1e(e,t,r,o,a,i){const l=n.resolveComponent("LTableHeader"),s=n.resolveComponent("LTableBodySpacer"),c=n.resolveComponent("LTableBody"),u=n.resolveComponent("LTableLoadMore"),d=n.resolveComponent("LTableEndspace"),f=n.resolveComponent("LTableReloader"),p=n.resolveComponent("LTablePagination");return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-table-container",i.contentClasses]),ref:"container",style:n.normalizeStyle(i.contentStyle),onScroll:t[7]||(t[7]=(...h)=>i.onScroll&&i.onScroll(...h))},[n.createElementVNode("table",r1e,[t[8]||(t[8]=n.createElementVNode("caption",{style:{display:"none"}}," Table Header ",-1)),n.createVNode(l,{height:a.headerHeight,selectable:r.selectable,columnSpecs:a.columnSpecs,loading:!!a.fetching,total:a.totalCount,includedIds:a.includedIds,excludedIds:a.excludedIds,multiselect:r.multiselect,onSelected:t[0]||(t[0]=h=>i.changeSelection(h)),"onColumnSpecs:update":i.handleColumnSpecsUpdate},null,8,["height","selectable","columnSpecs","loading","total","includedIds","excludedIds","multiselect","onColumnSpecs:update"]),n.createVNode(s,{height:i.spacing.top},null,8,["height"]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.visiblePages,h=>(n.openBlock(),n.createBlock(c,{key:`${h.index}-${h.loading}-${h.loaded}`,page:h,perPage:i.perPage,pagesCount:i.pagesCount,totalCount:a.totalCount,selectable:r.selectable,clickable:r.clickable,columnSpecs:a.columnSpecs,includedIds:a.includedIds,excludedIds:a.excludedIds,multiselect:r.multiselect,onClickItem:t[1]||(t[1]=m=>e.$emit("click-item",m)),onSelected:t[2]||(t[2]=m=>i.changeSelection(m))},null,8,["page","perPage","pagesCount","totalCount","selectable","clickable","columnSpecs","includedIds","excludedIds","multiselect"]))),128)),n.createVNode(s,{height:i.spacing.bottom},null,8,["height"])]),i.isLoadMoreVisible?(n.openBlock(),n.createBlock(u,{key:0,onClick:t[3]||(t[3]=h=>i.loadMore(!0)),onAppeared:t[4]||(t[4]=h=>i.loadMore()),automatic:r.autoLoadMore},null,8,["automatic"])):n.createCommentVNode("",!0),n.createVNode(d),n.createVNode(n.Transition,{name:"scale-up"},{default:n.withCtx(()=>[i.hasVisibleFailedPages?(n.openBlock(),n.createBlock(f,{key:0,onReload:t[5]||(t[5]=h=>i.reloadFailedPages())})):n.createCommentVNode("",!0)]),_:1}),i.isPaginationVisible?(n.openBlock(),n.createBlock(p,{key:1,currentPage:a.currentPage,pagesCount:i.pagesCount,totalCount:a.totalCount,onGoto:t[6]||(t[6]=h=>i.gotoPage(h))},null,8,["currentPage","pagesCount","totalCount"])):n.createCommentVNode("",!0)],38)}const a1e=xe(n1e,[["render",o1e]]),i1e=Object.freeze(Object.defineProperty({__proto__:null,default:a1e},Symbol.toStringTag,{value:"Module"}));const l1e={name:"LTabs",components:{ElTabs:lee},methods:{calcPaneInstances(e=!1){if(this.$slots.default){const r=this.$slots.default.filter(a=>a.tag&&a.componentOptions&&a.componentOptions.Ctor.options.tagName==="l-tab-pane").map(({componentInstance:a})=>a),o=!(r.length===this.panes.length&&r.every((a,i)=>a===this.panes[i]));(e||o)&&(this.panes=r)}else this.panes.length!==0&&(this.panes=[])}},data(){return{panes:[]}}};function s1e(e,t,r,o,a,i){const l=n.resolveComponent("el-tabs");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-tabs"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const c1e=xe(l1e,[["render",s1e],["__scopeId","data-v-848cce78"]]),u1e=Object.freeze(Object.defineProperty({__proto__:null,default:c1e},Symbol.toStringTag,{value:"Module"})),d1e={tagName:"l-target-chip",name:"LTargetChip",props:{kind:{type:String,required:!0},closeable:{type:Boolean,default:!1},name:{type:String,required:!0},count:{type:Number}},computed:{color:function(){return{member:"purple",group:"aqua",user:"link",tag:"warning",community:"danger",role:"lead-light"}[this.kind]||"lead"},icon:function(){return{member:"uil-graduation-cap",group:"uil-users-alt",user:"uil-user",tag:"uil-tag-alt",role:"uil-user",community:"uil-channel"}[this.kind]}}},f1e={class:"l-d-flex l-align-items"};function p1e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-chip");return n.openBlock(),n.createBlock(s,{style:{height:"24px"},bold:"",fill:"",color:i.color,icon:i.icon},{default:n.withCtx(()=>[n.createElementVNode("div",f1e,[n.createTextVNode(n.toDisplayString(r.count)+" "+n.toDisplayString(r.name)+" ",1),r.closeable?(n.openBlock(),n.createBlock(l,{key:0,onClick:t[0]||(t[0]=c=>e.$emit("remove")),class:"l-d-flex l-align-items-center ml-1 mr-0",style:{cursor:"pointer"},size:"15"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode(" uis-times-circle ")])),_:1})):n.createCommentVNode("",!0)])]),_:1},8,["color","icon"])}const m1e=xe(d1e,[["render",p1e]]),h1e=Object.freeze(Object.defineProperty({__proto__:null,default:m1e},Symbol.toStringTag,{value:"Module"}));const g1e={tagName:"l-target-input",name:"LTargetInput",props:{topics:{type:Array,required:!0},limit:{type:Number,default:3},editable:{type:Boolean,default:!1}},computed:{topicsToShow(){return this.topics.slice(0,this.limit)},moreTopicsText(){const e=this.topics.length-this.limit>1;return`+ ${this.topics.length-this.limit} destinatário`+(e?"s":"")}}};function v1e(e,t,r,o,a,i){const l=n.resolveComponent("l-target-chip"),s=n.resolveComponent("l-chip");return r.topics&&r.topics.length?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass("l-target-input"+(r.editable?" editable":""))},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.topicsToShow,c=>(n.openBlock(),n.createBlock(l,{kind:c.kind,name:c.name,key:c.id,class:"mr-2 mb-2"},null,8,["kind","name"]))),128)),r.topics.length>this.limit?(n.openBlock(),n.createBlock(s,{key:0,color:"purple",class:"mb-2",fill:"","hide-icon":""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.moreTopicsText),1)]),_:1})):n.createCommentVNode("",!0)],2)):n.createCommentVNode("",!0)}const y1e=xe(g1e,[["render",v1e],["__scopeId","data-v-1da7433b"]]),M1e=Object.freeze(Object.defineProperty({__proto__:null,default:y1e},Symbol.toStringTag,{value:"Module"}));function nn(e){this.content=e}nn.prototype={constructor:nn,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,r){var o=r&&r!=e?this.remove(r):this,a=o.find(e),i=o.content.slice();return a==-1?i.push(r||e,t):(i[a+1]=t,r&&(i[a]=r)),new nn(i)},remove:function(e){var t=this.find(e);if(t==-1)return this;var r=this.content.slice();return r.splice(t,2),new nn(r)},addToStart:function(e,t){return new nn([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var r=this.remove(e).content.slice();return r.push(e,t),new nn(r)},addBefore:function(e,t,r){var o=this.remove(t),a=o.content.slice(),i=o.find(e);return a.splice(i==-1?a.length:i,0,t,r),new nn(a)},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=nn.from(e),e.size?new nn(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=nn.from(e),e.size?new nn(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=nn.from(e);for(var r=0;r<e.content.length;r+=2)t=t.remove(e.content[r]);return t},toObject:function(){var e={};return this.forEach(function(t,r){e[t]=r}),e},get size(){return this.content.length>>1}};nn.from=function(e){if(e instanceof nn)return e;var t=[];if(e)for(var r in e)t.push(r,e[r]);return new nn(t)};function D8(e,t,r){for(let o=0;;o++){if(o==e.childCount||o==t.childCount)return e.childCount==t.childCount?null:r;let a=e.child(o),i=t.child(o);if(a==i){r+=a.nodeSize;continue}if(!a.sameMarkup(i))return r;if(a.isText&&a.text!=i.text){for(let l=0;a.text[l]==i.text[l];l++)r++;return r}if(a.content.size||i.content.size){let l=D8(a.content,i.content,r+1);if(l!=null)return l}r+=a.nodeSize}}function S8(e,t,r,o){for(let a=e.childCount,i=t.childCount;;){if(a==0||i==0)return a==i?null:{a:r,b:o};let l=e.child(--a),s=t.child(--i),c=l.nodeSize;if(l==s){r-=c,o-=c;continue}if(!l.sameMarkup(s))return{a:r,b:o};if(l.isText&&l.text!=s.text){let u=0,d=Math.min(l.text.length,s.text.length);for(;u<d&&l.text[l.text.length-u-1]==s.text[s.text.length-u-1];)u++,r--,o--;return{a:r,b:o}}if(l.content.size||s.content.size){let u=S8(l.content,s.content,r-1,o-1);if(u)return u}r-=c,o-=c}}class fe{constructor(t,r){if(this.content=t,this.size=r||0,r==null)for(let o=0;o<t.length;o++)this.size+=t[o].nodeSize}nodesBetween(t,r,o,a=0,i){for(let l=0,s=0;s<r;l++){let c=this.content[l],u=s+c.nodeSize;if(u>t&&o(c,a+s,i||null,l)!==!1&&c.content.size){let d=s+1;c.nodesBetween(Math.max(0,t-d),Math.min(c.content.size,r-d),o,a+d)}s=u}}descendants(t){this.nodesBetween(0,this.size,t)}textBetween(t,r,o,a){let i="",l=!0;return this.nodesBetween(t,r,(s,c)=>{let u=s.isText?s.text.slice(Math.max(t,c)-c,r-c):s.isLeaf?a?typeof a=="function"?a(s):a:s.type.spec.leafText?s.type.spec.leafText(s):"":"";s.isBlock&&(s.isLeaf&&u||s.isTextblock)&&o&&(l?l=!1:i+=o),i+=u},0),i}append(t){if(!t.size)return this;if(!this.size)return t;let r=this.lastChild,o=t.firstChild,a=this.content.slice(),i=0;for(r.isText&&r.sameMarkup(o)&&(a[a.length-1]=r.withText(r.text+o.text),i=1);i<t.content.length;i++)a.push(t.content[i]);return new fe(a,this.size+t.size)}cut(t,r=this.size){if(t==0&&r==this.size)return this;let o=[],a=0;if(r>t)for(let i=0,l=0;l<r;i++){let s=this.content[i],c=l+s.nodeSize;c>t&&((l<t||c>r)&&(s.isText?s=s.cut(Math.max(0,t-l),Math.min(s.text.length,r-l)):s=s.cut(Math.max(0,t-l-1),Math.min(s.content.size,r-l-1))),o.push(s),a+=s.nodeSize),l=c}return new fe(o,a)}cutByIndex(t,r){return t==r?fe.empty:t==0&&r==this.content.length?this:new fe(this.content.slice(t,r))}replaceChild(t,r){let o=this.content[t];if(o==r)return this;let a=this.content.slice(),i=this.size+r.nodeSize-o.nodeSize;return a[t]=r,new fe(a,i)}addToStart(t){return new fe([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new fe(this.content.concat(t),this.size+t.nodeSize)}eq(t){if(this.content.length!=t.content.length)return!1;for(let r=0;r<this.content.length;r++)if(!this.content[r].eq(t.content[r]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(t){let r=this.content[t];if(!r)throw new RangeError("Index "+t+" out of range for "+this);return r}maybeChild(t){return this.content[t]||null}forEach(t){for(let r=0,o=0;r<this.content.length;r++){let a=this.content[r];t(a,o,r),o+=a.nodeSize}}findDiffStart(t,r=0){return D8(this,t,r)}findDiffEnd(t,r=this.size,o=t.size){return S8(this,t,r,o)}findIndex(t,r=-1){if(t==0)return kc(0,t);if(t==this.size)return kc(this.content.length,t);if(t>this.size||t<0)throw new RangeError(`Position ${t} outside of fragment (${this})`);for(let o=0,a=0;;o++){let i=this.child(o),l=a+i.nodeSize;if(l>=t)return l==t||r>0?kc(o+1,l):kc(o,a);a=l}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(t=>t.toJSON()):null}static fromJSON(t,r){if(!r)return fe.empty;if(!Array.isArray(r))throw new RangeError("Invalid input for Fragment.fromJSON");return new fe(r.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return fe.empty;let r,o=0;for(let a=0;a<t.length;a++){let i=t[a];o+=i.nodeSize,a&&i.isText&&t[a-1].sameMarkup(i)?(r||(r=t.slice(0,a)),r[r.length-1]=i.withText(r[r.length-1].text+i.text)):r&&r.push(i)}return new fe(r||t,o)}static from(t){if(!t)return fe.empty;if(t instanceof fe)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new fe([t],t.nodeSize);throw new RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}fe.empty=new fe([],0);const Wf={index:0,offset:0};function kc(e,t){return Wf.index=e,Wf.offset=t,Wf}function Tu(e,t){if(e===t)return!0;if(!(e&&typeof e=="object")||!(t&&typeof t=="object"))return!1;let r=Array.isArray(e);if(Array.isArray(t)!=r)return!1;if(r){if(e.length!=t.length)return!1;for(let o=0;o<e.length;o++)if(!Tu(e[o],t[o]))return!1}else{for(let o in e)if(!(o in t)||!Tu(e[o],t[o]))return!1;for(let o in t)if(!(o in e))return!1}return!0}let gt=class w0{constructor(t,r){this.type=t,this.attrs=r}addToSet(t){let r,o=!1;for(let a=0;a<t.length;a++){let i=t[a];if(this.eq(i))return t;if(this.type.excludes(i.type))r||(r=t.slice(0,a));else{if(i.type.excludes(this.type))return t;!o&&i.type.rank>this.type.rank&&(r||(r=t.slice(0,a)),r.push(this),o=!0),r&&r.push(i)}}return r||(r=t.slice()),o||r.push(this),r}removeFromSet(t){for(let r=0;r<t.length;r++)if(this.eq(t[r]))return t.slice(0,r).concat(t.slice(r+1));return t}isInSet(t){for(let r=0;r<t.length;r++)if(this.eq(t[r]))return!0;return!1}eq(t){return this==t||this.type==t.type&&Tu(this.attrs,t.attrs)}toJSON(){let t={type:this.type.name};for(let r in this.attrs){t.attrs=this.attrs;break}return t}static fromJSON(t,r){if(!r)throw new RangeError("Invalid input for Mark.fromJSON");let o=t.marks[r.type];if(!o)throw new RangeError(`There is no mark type ${r.type} in this schema`);let a=o.create(r.attrs);return o.checkAttrs(a.attrs),a}static sameSet(t,r){if(t==r)return!0;if(t.length!=r.length)return!1;for(let o=0;o<t.length;o++)if(!t[o].eq(r[o]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return w0.none;if(t instanceof w0)return[t];let r=t.slice();return r.sort((o,a)=>o.type.rank-a.type.rank),r}};gt.none=[];class Du extends Error{}class Ee{constructor(t,r,o){this.content=t,this.openStart=r,this.openEnd=o}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,r){let o=I8(this.content,t+this.openStart,r);return o&&new Ee(o,this.openStart,this.openEnd)}removeBetween(t,r){return new Ee(_8(this.content,t+this.openStart,r+this.openStart),this.openStart,this.openEnd)}eq(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}static fromJSON(t,r){if(!r)return Ee.empty;let o=r.openStart||0,a=r.openEnd||0;if(typeof o!="number"||typeof a!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new Ee(fe.fromJSON(t,r.content),o,a)}static maxOpen(t,r=!0){let o=0,a=0;for(let i=t.firstChild;i&&!i.isLeaf&&(r||!i.type.spec.isolating);i=i.firstChild)o++;for(let i=t.lastChild;i&&!i.isLeaf&&(r||!i.type.spec.isolating);i=i.lastChild)a++;return new Ee(t,o,a)}}Ee.empty=new Ee(fe.empty,0,0);function _8(e,t,r){let{index:o,offset:a}=e.findIndex(t),i=e.maybeChild(o),{index:l,offset:s}=e.findIndex(r);if(a==t||i.isText){if(s!=r&&!e.child(l).isText)throw new RangeError("Removing non-flat range");return e.cut(0,t).append(e.cut(r))}if(o!=l)throw new RangeError("Removing non-flat range");return e.replaceChild(o,i.copy(_8(i.content,t-a-1,r-a-1)))}function I8(e,t,r,o){let{index:a,offset:i}=e.findIndex(t),l=e.maybeChild(a);if(i==t||l.isText)return o&&!o.canReplace(a,a,r)?null:e.cut(0,t).append(r).append(e.cut(t));let s=I8(l.content,t-i-1,r);return s&&e.replaceChild(a,l.copy(s))}function b1e(e,t,r){if(r.openStart>e.depth)throw new Du("Inserted content deeper than insertion position");if(e.depth-r.openStart!=t.depth-r.openEnd)throw new Du("Inconsistent open depths");return A8(e,t,r,0)}function A8(e,t,r,o){let a=e.index(o),i=e.node(o);if(a==t.index(o)&&o<e.depth-r.openStart){let l=A8(e,t,r,o+1);return i.copy(i.content.replaceChild(a,l))}else if(r.content.size)if(!r.openStart&&!r.openEnd&&e.depth==o&&t.depth==o){let l=e.parent,s=l.content;return _a(l,s.cut(0,e.parentOffset).append(r.content).append(s.cut(t.parentOffset)))}else{let{start:l,end:s}=w1e(r,e);return _a(i,z8(e,l,s,t,o))}else return _a(i,Su(e,t,o))}function O8(e,t){if(!t.type.compatibleContent(e.type))throw new Du("Cannot join "+t.type.name+" onto "+e.type.name)}function N0(e,t,r){let o=e.node(r);return O8(o,t.node(r)),o}function Sa(e,t){let r=t.length-1;r>=0&&e.isText&&e.sameMarkup(t[r])?t[r]=e.withText(t[r].text+e.text):t.push(e)}function Hl(e,t,r,o){let a=(t||e).node(r),i=0,l=t?t.index(r):a.childCount;e&&(i=e.index(r),e.depth>r?i++:e.textOffset&&(Sa(e.nodeAfter,o),i++));for(let s=i;s<l;s++)Sa(a.child(s),o);t&&t.depth==r&&t.textOffset&&Sa(t.nodeBefore,o)}function _a(e,t){return e.type.checkContent(t),e.copy(t)}function z8(e,t,r,o,a){let i=e.depth>a&&N0(e,t,a+1),l=o.depth>a&&N0(r,o,a+1),s=[];return Hl(null,e,a,s),i&&l&&t.index(a)==r.index(a)?(O8(i,l),Sa(_a(i,z8(e,t,r,o,a+1)),s)):(i&&Sa(_a(i,Su(e,t,a+1)),s),Hl(t,r,a,s),l&&Sa(_a(l,Su(r,o,a+1)),s)),Hl(o,null,a,s),new fe(s)}function Su(e,t,r){let o=[];if(Hl(null,e,r,o),e.depth>r){let a=N0(e,t,r+1);Sa(_a(a,Su(e,t,r+1)),o)}return Hl(t,null,r,o),new fe(o)}function w1e(e,t){let r=t.depth-e.openStart,a=t.node(r).copy(e.content);for(let i=r-1;i>=0;i--)a=t.node(i).copy(fe.from(a));return{start:a.resolveNoCache(e.openStart+r),end:a.resolveNoCache(a.content.size-e.openEnd-r)}}class ks{constructor(t,r,o){this.pos=t,this.path=r,this.parentOffset=o,this.depth=r.length/3-1}resolveDepth(t){return t==null?this.depth:t<0?this.depth+t:t}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(t){return this.path[this.resolveDepth(t)*3]}index(t){return this.path[this.resolveDepth(t)*3+1]}indexAfter(t){return t=this.resolveDepth(t),this.index(t)+(t==this.depth&&!this.textOffset?0:1)}start(t){return t=this.resolveDepth(t),t==0?0:this.path[t*3-1]+1}end(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}before(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]}after(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]+this.path[t*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let t=this.parent,r=this.index(this.depth);if(r==t.childCount)return null;let o=this.pos-this.path[this.path.length-1],a=t.child(r);return o?t.child(r).cut(o):a}get nodeBefore(){let t=this.index(this.depth),r=this.pos-this.path[this.path.length-1];return r?this.parent.child(t).cut(0,r):t==0?null:this.parent.child(t-1)}posAtIndex(t,r){r=this.resolveDepth(r);let o=this.path[r*3],a=r==0?0:this.path[r*3-1]+1;for(let i=0;i<t;i++)a+=o.child(i).nodeSize;return a}marks(){let t=this.parent,r=this.index();if(t.content.size==0)return gt.none;if(this.textOffset)return t.child(r).marks;let o=t.maybeChild(r-1),a=t.maybeChild(r);if(!o){let s=o;o=a,a=s}let i=o.marks;for(var l=0;l<i.length;l++)i[l].type.spec.inclusive===!1&&(!a||!i[l].isInSet(a.marks))&&(i=i[l--].removeFromSet(i));return i}marksAcross(t){let r=this.parent.maybeChild(this.index());if(!r||!r.isInline)return null;let o=r.marks,a=t.parent.maybeChild(t.index());for(var i=0;i<o.length;i++)o[i].type.spec.inclusive===!1&&(!a||!o[i].isInSet(a.marks))&&(o=o[i--].removeFromSet(o));return o}sharedDepth(t){for(let r=this.depth;r>0;r--)if(this.start(r)<=t&&this.end(r)>=t)return r;return 0}blockRange(t=this,r){if(t.pos<this.pos)return t.blockRange(this);for(let o=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);o>=0;o--)if(t.pos<=this.end(o)&&(!r||r(this.node(o))))return new _u(this,t,o);return null}sameParent(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}max(t){return t.pos>this.pos?t:this}min(t){return t.pos<this.pos?t:this}toString(){let t="";for(let r=1;r<=this.depth;r++)t+=(t?"/":"")+this.node(r).type.name+"_"+this.index(r-1);return t+":"+this.parentOffset}static resolve(t,r){if(!(r>=0&&r<=t.content.size))throw new RangeError("Position "+r+" out of range");let o=[],a=0,i=r;for(let l=t;;){let{index:s,offset:c}=l.content.findIndex(i),u=i-c;if(o.push(l,s,a+c),!u||(l=l.child(s),l.isText))break;i=u-1,a+=c+1}return new ks(r,o,i)}static resolveCached(t,r){let o=z4.get(t);if(o)for(let i=0;i<o.elts.length;i++){let l=o.elts[i];if(l.pos==r)return l}else z4.set(t,o=new N1e);let a=o.elts[o.i]=ks.resolve(t,r);return o.i=(o.i+1)%k1e,a}}class N1e{constructor(){this.elts=[],this.i=0}}const k1e=12,z4=new WeakMap;class _u{constructor(t,r,o){this.$from=t,this.$to=r,this.depth=o}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const x1e=Object.create(null);let Ia=class k0{constructor(t,r,o,a=gt.none){this.type=t,this.attrs=r,this.marks=a,this.content=o||fe.empty}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(t){return this.content.child(t)}maybeChild(t){return this.content.maybeChild(t)}forEach(t){this.content.forEach(t)}nodesBetween(t,r,o,a=0){this.content.nodesBetween(t,r,o,a,this)}descendants(t){this.nodesBetween(0,this.content.size,t)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(t,r,o,a){return this.content.textBetween(t,r,o,a)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}sameMarkup(t){return this.hasMarkup(t.type,t.attrs,t.marks)}hasMarkup(t,r,o){return this.type==t&&Tu(this.attrs,r||t.defaultAttrs||x1e)&>.sameSet(this.marks,o||gt.none)}copy(t=null){return t==this.content?this:new k0(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new k0(this.type,this.attrs,this.content,t)}cut(t,r=this.content.size){return t==0&&r==this.content.size?this:this.copy(this.content.cut(t,r))}slice(t,r=this.content.size,o=!1){if(t==r)return Ee.empty;let a=this.resolve(t),i=this.resolve(r),l=o?0:a.sharedDepth(r),s=a.start(l),u=a.node(l).content.cut(a.pos-s,i.pos-s);return new Ee(u,a.depth-l,i.depth-l)}replace(t,r,o){return b1e(this.resolve(t),this.resolve(r),o)}nodeAt(t){for(let r=this;;){let{index:o,offset:a}=r.content.findIndex(t);if(r=r.maybeChild(o),!r)return null;if(a==t||r.isText)return r;t-=a+1}}childAfter(t){let{index:r,offset:o}=this.content.findIndex(t);return{node:this.content.maybeChild(r),index:r,offset:o}}childBefore(t){if(t==0)return{node:null,index:0,offset:0};let{index:r,offset:o}=this.content.findIndex(t);if(o<t)return{node:this.content.child(r),index:r,offset:o};let a=this.content.child(r-1);return{node:a,index:r-1,offset:o-a.nodeSize}}resolve(t){return ks.resolveCached(this,t)}resolveNoCache(t){return ks.resolve(this,t)}rangeHasMark(t,r,o){let a=!1;return r>t&&this.nodesBetween(t,r,i=>(o.isInSet(i.marks)&&(a=!0),!a)),a}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),j8(this.marks,t)}contentMatchAt(t){let r=this.type.contentMatch.matchFragment(this.content,0,t);if(!r)throw new Error("Called contentMatchAt on a node with invalid content");return r}canReplace(t,r,o=fe.empty,a=0,i=o.childCount){let l=this.contentMatchAt(t).matchFragment(o,a,i),s=l&&l.matchFragment(this.content,r);if(!s||!s.validEnd)return!1;for(let c=a;c<i;c++)if(!this.type.allowsMarks(o.child(c).marks))return!1;return!0}canReplaceWith(t,r,o,a){if(a&&!this.type.allowsMarks(a))return!1;let i=this.contentMatchAt(t).matchType(o),l=i&&i.matchFragment(this.content,r);return l?l.validEnd:!1}canAppend(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let t=gt.none;for(let r=0;r<this.marks.length;r++){let o=this.marks[r];o.type.checkAttrs(o.attrs),t=o.addToSet(t)}if(!gt.sameSet(t,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(r=>r.type.name)}`);this.content.forEach(r=>r.check())}toJSON(){let t={type:this.type.name};for(let r in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map(r=>r.toJSON())),t}static fromJSON(t,r){if(!r)throw new RangeError("Invalid input for Node.fromJSON");let o;if(r.marks){if(!Array.isArray(r.marks))throw new RangeError("Invalid mark data for Node.fromJSON");o=r.marks.map(t.markFromJSON)}if(r.type=="text"){if(typeof r.text!="string")throw new RangeError("Invalid text node in JSON");return t.text(r.text,o)}let a=fe.fromJSON(t,r.content),i=t.nodeType(r.type).create(r.attrs,a,o);return i.type.checkAttrs(i.attrs),i}};Ia.prototype.text=void 0;class Iu extends Ia{constructor(t,r,o,a){if(super(t,r,null,a),!o)throw new RangeError("Empty text nodes are not allowed");this.text=o}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):j8(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(t,r){return this.text.slice(t,r)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new Iu(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new Iu(this.type,this.attrs,t,this.marks)}cut(t=0,r=this.text.length){return t==0&&r==this.text.length?this:this.withText(this.text.slice(t,r))}eq(t){return this.sameMarkup(t)&&this.text==t.text}toJSON(){let t=super.toJSON();return t.text=this.text,t}}function j8(e,t){for(let r=e.length-1;r>=0;r--)t=e[r].type.name+"("+t+")";return t}class Pa{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,r){let o=new C1e(t,r);if(o.next==null)return Pa.empty;let a=L8(o);o.next&&o.err("Unexpected trailing text");let i=A1e(I1e(a));return O1e(i,o),i}matchType(t){for(let r=0;r<this.next.length;r++)if(this.next[r].type==t)return this.next[r].next;return null}matchFragment(t,r=0,o=t.childCount){let a=this;for(let i=r;a&&i<o;i++)a=a.matchType(t.child(i).type);return a}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let t=0;t<this.next.length;t++){let{type:r}=this.next[t];if(!(r.isText||r.hasRequiredAttrs()))return r}return null}compatible(t){for(let r=0;r<this.next.length;r++)for(let o=0;o<t.next.length;o++)if(this.next[r].type==t.next[o].type)return!0;return!1}fillBefore(t,r=!1,o=0){let a=[this];function i(l,s){let c=l.matchFragment(t,o);if(c&&(!r||c.validEnd))return fe.from(s.map(u=>u.createAndFill()));for(let u=0;u<l.next.length;u++){let{type:d,next:f}=l.next[u];if(!(d.isText||d.hasRequiredAttrs())&&a.indexOf(f)==-1){a.push(f);let p=i(f,s.concat(d));if(p)return p}}return null}return i(this,[])}findWrapping(t){for(let o=0;o<this.wrapCache.length;o+=2)if(this.wrapCache[o]==t)return this.wrapCache[o+1];let r=this.computeWrapping(t);return this.wrapCache.push(t,r),r}computeWrapping(t){let r=Object.create(null),o=[{match:this,type:null,via:null}];for(;o.length;){let a=o.shift(),i=a.match;if(i.matchType(t)){let l=[];for(let s=a;s.type;s=s.via)l.push(s.type);return l.reverse()}for(let l=0;l<i.next.length;l++){let{type:s,next:c}=i.next[l];!s.isLeaf&&!s.hasRequiredAttrs()&&!(s.name in r)&&(!a.type||c.validEnd)&&(o.push({match:s.contentMatch,type:s,via:a}),r[s.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(t){if(t>=this.next.length)throw new RangeError(`There's no ${t}th edge in this content match`);return this.next[t]}toString(){let t=[];function r(o){t.push(o);for(let a=0;a<o.next.length;a++)t.indexOf(o.next[a].next)==-1&&r(o.next[a].next)}return r(this),t.map((o,a)=>{let i=a+(o.validEnd?"*":" ")+" ";for(let l=0;l<o.next.length;l++)i+=(l?", ":"")+o.next[l].type.name+"->"+t.indexOf(o.next[l].next);return i}).join(`
|
|
48
|
-
`)}}Pa.empty=new Pa(!0);class C1e{constructor(t,r){this.string=t,this.nodeTypes=r,this.inline=null,this.pos=0,this.tokens=t.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(t){return this.next==t&&(this.pos++||!0)}err(t){throw new SyntaxError(t+" (in content expression '"+this.string+"')")}}function L8(e){let t=[];do t.push(E1e(e));while(e.eat("|"));return t.length==1?t[0]:{type:"choice",exprs:t}}function E1e(e){let t=[];do t.push(T1e(e));while(e.next&&e.next!=")"&&e.next!="|");return t.length==1?t[0]:{type:"seq",exprs:t}}function T1e(e){let t=_1e(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=D1e(e,t);else break;return t}function j4(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function D1e(e,t){let r=j4(e),o=r;return e.eat(",")&&(e.next!="}"?o=j4(e):o=-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:r,max:o,expr:t}}function S1e(e,t){let r=e.nodeTypes,o=r[t];if(o)return[o];let a=[];for(let i in r){let l=r[i];l.isInGroup(t)&&a.push(l)}return a.length==0&&e.err("No node type or group '"+t+"' found"),a}function _1e(e){if(e.eat("(")){let t=L8(e);return e.eat(")")||e.err("Missing closing paren"),t}else if(/\W/.test(e.next))e.err("Unexpected token '"+e.next+"'");else{let t=S1e(e,e.next).map(r=>(e.inline==null?e.inline=r.isInline:e.inline!=r.isInline&&e.err("Mixing inline and block content"),{type:"name",value:r}));return e.pos++,t.length==1?t[0]:{type:"choice",exprs:t}}}function I1e(e){let t=[[]];return a(i(e,0),r()),t;function r(){return t.push([])-1}function o(l,s,c){let u={term:c,to:s};return t[l].push(u),u}function a(l,s){l.forEach(c=>c.to=s)}function i(l,s){if(l.type=="choice")return l.exprs.reduce((c,u)=>c.concat(i(u,s)),[]);if(l.type=="seq")for(let c=0;;c++){let u=i(l.exprs[c],s);if(c==l.exprs.length-1)return u;a(u,s=r())}else if(l.type=="star"){let c=r();return o(s,c),a(i(l.expr,c),c),[o(c)]}else if(l.type=="plus"){let c=r();return a(i(l.expr,s),c),a(i(l.expr,c),c),[o(c)]}else{if(l.type=="opt")return[o(s)].concat(i(l.expr,s));if(l.type=="range"){let c=s;for(let u=0;u<l.min;u++){let d=r();a(i(l.expr,c),d),c=d}if(l.max==-1)a(i(l.expr,c),c);else for(let u=l.min;u<l.max;u++){let d=r();o(c,d),a(i(l.expr,c),d),c=d}return[o(c)]}else{if(l.type=="name")return[o(s,void 0,l.value)];throw new Error("Unknown expr type")}}}}function B8(e,t){return t-e}function L4(e,t){let r=[];return o(t),r.sort(B8);function o(a){let i=e[a];if(i.length==1&&!i[0].term)return o(i[0].to);r.push(a);for(let l=0;l<i.length;l++){let{term:s,to:c}=i[l];!s&&r.indexOf(c)==-1&&o(c)}}}function A1e(e){let t=Object.create(null);return r(L4(e,0));function r(o){let a=[];o.forEach(l=>{e[l].forEach(({term:s,to:c})=>{if(!s)return;let u;for(let d=0;d<a.length;d++)a[d][0]==s&&(u=a[d][1]);L4(e,c).forEach(d=>{u||a.push([s,u=[]]),u.indexOf(d)==-1&&u.push(d)})})});let i=t[o.join(",")]=new Pa(o.indexOf(e.length-1)>-1);for(let l=0;l<a.length;l++){let s=a[l][1].sort(B8);i.next.push({type:a[l][0],next:t[s.join(",")]||r(s)})}return i}}function O1e(e,t){for(let r=0,o=[e];r<o.length;r++){let a=o[r],i=!a.validEnd,l=[];for(let s=0;s<a.next.length;s++){let{type:c,next:u}=a.next[s];l.push(c.name),i&&!(c.isText||c.hasRequiredAttrs())&&(i=!1),o.indexOf(u)==-1&&o.push(u)}i&&t.err("Only non-generatable nodes ("+l.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function V8(e){let t=Object.create(null);for(let r in e){let o=e[r];if(!o.hasDefault)return null;t[r]=o.default}return t}function $8(e,t){let r=Object.create(null);for(let o in e){let a=t&&t[o];if(a===void 0){let i=e[o];if(i.hasDefault)a=i.default;else throw new RangeError("No value supplied for attribute "+o)}r[o]=a}return r}function P8(e,t,r,o){for(let a in t)if(!(a in e))throw new RangeError(`Unsupported attribute ${a} for ${r} of type ${a}`);for(let a in e){let i=e[a];i.validate&&i.validate(t[a])}}function R8(e,t){let r=Object.create(null);if(t)for(let o in t)r[o]=new j1e(e,o,t[o]);return r}let B4=class F8{constructor(t,r,o){this.name=t,this.schema=r,this.spec=o,this.markSet=null,this.groups=o.group?o.group.split(" "):[],this.attrs=R8(t,o.attrs),this.defaultAttrs=V8(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(o.inline||t=="text"),this.isText=t=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==Pa.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(t){return this.groups.indexOf(t)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let t in this.attrs)if(this.attrs[t].isRequired)return!0;return!1}compatibleContent(t){return this==t||this.contentMatch.compatible(t.contentMatch)}computeAttrs(t){return!t&&this.defaultAttrs?this.defaultAttrs:$8(this.attrs,t)}create(t=null,r,o){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new Ia(this,this.computeAttrs(t),fe.from(r),gt.setFrom(o))}createChecked(t=null,r,o){return r=fe.from(r),this.checkContent(r),new Ia(this,this.computeAttrs(t),r,gt.setFrom(o))}createAndFill(t=null,r,o){if(t=this.computeAttrs(t),r=fe.from(r),r.size){let l=this.contentMatch.fillBefore(r);if(!l)return null;r=l.append(r)}let a=this.contentMatch.matchFragment(r),i=a&&a.fillBefore(fe.empty,!0);return i?new Ia(this,t,r.append(i),gt.setFrom(o)):null}validContent(t){let r=this.contentMatch.matchFragment(t);if(!r||!r.validEnd)return!1;for(let o=0;o<t.childCount;o++)if(!this.allowsMarks(t.child(o).marks))return!1;return!0}checkContent(t){if(!this.validContent(t))throw new RangeError(`Invalid content for node ${this.name}: ${t.toString().slice(0,50)}`)}checkAttrs(t){P8(this.attrs,t,"node",this.name)}allowsMarkType(t){return this.markSet==null||this.markSet.indexOf(t)>-1}allowsMarks(t){if(this.markSet==null)return!0;for(let r=0;r<t.length;r++)if(!this.allowsMarkType(t[r].type))return!1;return!0}allowedMarks(t){if(this.markSet==null)return t;let r;for(let o=0;o<t.length;o++)this.allowsMarkType(t[o].type)?r&&r.push(t[o]):r||(r=t.slice(0,o));return r?r.length?r:gt.none:t}static compile(t,r){let o=Object.create(null);t.forEach((i,l)=>o[i]=new F8(i,r,l));let a=r.spec.topNode||"doc";if(!o[a])throw new RangeError("Schema is missing its top node type ('"+a+"')");if(!o.text)throw new RangeError("Every schema needs a 'text' type");for(let i in o.text.attrs)throw new RangeError("The text node type should not have attributes");return o}};function z1e(e,t,r){let o=r.split("|");return a=>{let i=a===null?"null":typeof a;if(o.indexOf(i)<0)throw new RangeError(`Expected value of type ${o} for attribute ${t} on type ${e}, got ${i}`)}}class j1e{constructor(t,r,o){this.hasDefault=Object.prototype.hasOwnProperty.call(o,"default"),this.default=o.default,this.validate=typeof o.validate=="string"?z1e(t,r,o.validate):o.validate}get isRequired(){return!this.hasDefault}}class nf{constructor(t,r,o,a){this.name=t,this.rank=r,this.schema=o,this.spec=a,this.attrs=R8(t,a.attrs),this.excluded=null;let i=V8(this.attrs);this.instance=i?new gt(this,i):null}create(t=null){return!t&&this.instance?this.instance:new gt(this,$8(this.attrs,t))}static compile(t,r){let o=Object.create(null),a=0;return t.forEach((i,l)=>o[i]=new nf(i,a++,r,l)),o}removeFromSet(t){for(var r=0;r<t.length;r++)t[r].type==this&&(t=t.slice(0,r).concat(t.slice(r+1)),r--);return t}isInSet(t){for(let r=0;r<t.length;r++)if(t[r].type==this)return t[r]}checkAttrs(t){P8(this.attrs,t,"mark",this.name)}excludes(t){return this.excluded.indexOf(t)>-1}}class U8{constructor(t){this.linebreakReplacement=null,this.cached=Object.create(null);let r=this.spec={};for(let a in t)r[a]=t[a];r.nodes=nn.from(t.nodes),r.marks=nn.from(t.marks||{}),this.nodes=B4.compile(this.spec.nodes,this),this.marks=nf.compile(this.spec.marks,this);let o=Object.create(null);for(let a in this.nodes){if(a in this.marks)throw new RangeError(a+" can not be both a node and a mark");let i=this.nodes[a],l=i.spec.content||"",s=i.spec.marks;if(i.contentMatch=o[l]||(o[l]=Pa.parse(l,this.nodes)),i.inlineContent=i.contentMatch.inlineContent,i.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!i.isInline||!i.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=i}i.markSet=s=="_"?null:s?V4(this,s.split(" ")):s==""||!i.inlineContent?[]:null}for(let a in this.marks){let i=this.marks[a],l=i.spec.excludes;i.excluded=l==null?[i]:l==""?[]:V4(this,l.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(t,r=null,o,a){if(typeof t=="string")t=this.nodeType(t);else if(t instanceof B4){if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}else throw new RangeError("Invalid node type: "+t);return t.createChecked(r,o,a)}text(t,r){let o=this.nodes.text;return new Iu(o,o.defaultAttrs,t,gt.setFrom(r))}mark(t,r){return typeof t=="string"&&(t=this.marks[t]),t.create(r)}nodeFromJSON(t){return Ia.fromJSON(this,t)}markFromJSON(t){return gt.fromJSON(this,t)}nodeType(t){let r=this.nodes[t];if(!r)throw new RangeError("Unknown node type: "+t);return r}}function V4(e,t){let r=[];for(let o=0;o<t.length;o++){let a=t[o],i=e.marks[a],l=i;if(i)r.push(i);else for(let s in e.marks){let c=e.marks[s];(a=="_"||c.spec.group&&c.spec.group.split(" ").indexOf(a)>-1)&&r.push(l=c)}if(!l)throw new SyntaxError("Unknown mark type: '"+t[o]+"'")}return r}function L1e(e){return e.tag!=null}function B1e(e){return e.style!=null}class Go{constructor(t,r){this.schema=t,this.rules=r,this.tags=[],this.styles=[];let o=this.matchedStyles=[];r.forEach(a=>{if(L1e(a))this.tags.push(a);else if(B1e(a)){let i=/[^=]*/.exec(a.style)[0];o.indexOf(i)<0&&o.push(i),this.styles.push(a)}}),this.normalizeLists=!this.tags.some(a=>{if(!/^(ul|ol)\b/.test(a.tag)||!a.node)return!1;let i=t.nodes[a.node];return i.contentMatch.matchType(i)})}parse(t,r={}){let o=new P4(this,r,!1);return o.addAll(t,gt.none,r.from,r.to),o.finish()}parseSlice(t,r={}){let o=new P4(this,r,!0);return o.addAll(t,gt.none,r.from,r.to),Ee.maxOpen(o.finish())}matchTag(t,r,o){for(let a=o?this.tags.indexOf(o)+1:0;a<this.tags.length;a++){let i=this.tags[a];if(P1e(t,i.tag)&&(i.namespace===void 0||t.namespaceURI==i.namespace)&&(!i.context||r.matchesContext(i.context))){if(i.getAttrs){let l=i.getAttrs(t);if(l===!1)continue;i.attrs=l||void 0}return i}}}matchStyle(t,r,o,a){for(let i=a?this.styles.indexOf(a)+1:0;i<this.styles.length;i++){let l=this.styles[i],s=l.style;if(!(s.indexOf(t)!=0||l.context&&!o.matchesContext(l.context)||s.length>t.length&&(s.charCodeAt(t.length)!=61||s.slice(t.length+1)!=r))){if(l.getAttrs){let c=l.getAttrs(r);if(c===!1)continue;l.attrs=c||void 0}return l}}}static schemaRules(t){let r=[];function o(a){let i=a.priority==null?50:a.priority,l=0;for(;l<r.length;l++){let s=r[l];if((s.priority==null?50:s.priority)<i)break}r.splice(l,0,a)}for(let a in t.marks){let i=t.marks[a].spec.parseDOM;i&&i.forEach(l=>{o(l=R4(l)),l.mark||l.ignore||l.clearMark||(l.mark=a)})}for(let a in t.nodes){let i=t.nodes[a].spec.parseDOM;i&&i.forEach(l=>{o(l=R4(l)),l.node||l.ignore||l.mark||(l.node=a)})}return r}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new Go(t,Go.schemaRules(t)))}}const H8={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},V1e={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},Y8={ol:!0,ul:!0},Au=1,Ou=2,Yl=4;function $4(e,t,r){return t!=null?(t?Au:0)|(t==="full"?Ou:0):e&&e.whitespace=="pre"?Au|Ou:r&~Yl}class xc{constructor(t,r,o,a,i,l){this.type=t,this.attrs=r,this.marks=o,this.solid=a,this.options=l,this.content=[],this.activeMarks=gt.none,this.match=i||(l&Yl?null:t.contentMatch)}findWrapping(t){if(!this.match){if(!this.type)return[];let r=this.type.contentMatch.fillBefore(fe.from(t));if(r)this.match=this.type.contentMatch.matchFragment(r);else{let o=this.type.contentMatch,a;return(a=o.findWrapping(t.type))?(this.match=o,a):null}}return this.match.findWrapping(t.type)}finish(t){if(!(this.options&Au)){let o=this.content[this.content.length-1],a;if(o&&o.isText&&(a=/[ \t\r\n\u000c]+$/.exec(o.text))){let i=o;o.text.length==a[0].length?this.content.pop():this.content[this.content.length-1]=i.withText(i.text.slice(0,i.text.length-a[0].length))}}let r=fe.from(this.content);return!t&&this.match&&(r=r.append(this.match.fillBefore(fe.empty,!0))),this.type?this.type.create(this.attrs,r,this.marks):r}inlineContext(t){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:t.parentNode&&!H8.hasOwnProperty(t.parentNode.nodeName.toLowerCase())}}class P4{constructor(t,r,o){this.parser=t,this.options=r,this.isOpen=o,this.open=0;let a=r.topNode,i,l=$4(null,r.preserveWhitespace,0)|(o?Yl:0);a?i=new xc(a.type,a.attrs,gt.none,!0,r.topMatch||a.type.contentMatch,l):o?i=new xc(null,null,gt.none,!0,null,l):i=new xc(t.schema.topNodeType,null,gt.none,!0,null,l),this.nodes=[i],this.find=r.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(t,r){t.nodeType==3?this.addTextNode(t,r):t.nodeType==1&&this.addElement(t,r)}addTextNode(t,r){let o=t.nodeValue,a=this.top;if(a.options&Ou||a.inlineContext(t)||/[^ \t\r\n\u000c]/.test(o)){if(a.options&Au)a.options&Ou?o=o.replace(/\r\n?/g,`
|
|
49
|
-
`):o=o.replace(/\r?\n|\r/g," ");else if(o=o.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(o)&&this.open==this.nodes.length-1){let i=a.content[a.content.length-1],l=t.previousSibling;(!i||l&&l.nodeName=="BR"||i.isText&&/[ \t\r\n\u000c]$/.test(i.text))&&(o=o.slice(1))}o&&this.insertNode(this.parser.schema.text(o),r),this.findInText(t)}else this.findInside(t)}addElement(t,r,o){let a=t.nodeName.toLowerCase(),i;Y8.hasOwnProperty(a)&&this.parser.normalizeLists
|
|
50
|
-
`),r)}ignoreFallback(t,r){t.nodeName=="BR"&&(!this.top.type||!this.top.type.inlineContent)&&this.findPlace(this.parser.schema.text("-"),r)}readStyles(t,r){let o=t.style;if(o&&o.length)for(let a=0;a<this.parser.matchedStyles.length;a++){let i=this.parser.matchedStyles[a],l=o.getPropertyValue(i);if(l)for(let s=void 0;;){let c=this.parser.matchStyle(i,l,this,s);if(!c)break;if(c.ignore)return null;if(c.clearMark?r=r.filter(u=>!c.clearMark(u)):r=r.concat(this.parser.schema.marks[c.mark].create(c.attrs)),c.consuming===!1)s=c;else break}}return r}addElementByRule(t,r,o,a){let i,l;if(r.node)if(l=this.parser.schema.nodes[r.node],l.isLeaf)this.insertNode(l.create(r.attrs),o)||this.leafFallback(t,o);else{let c=this.enter(l,r.attrs||null,o,r.preserveWhitespace);c&&(i=!0,o=c)}else{let c=this.parser.schema.marks[r.mark];o=o.concat(c.create(r.attrs))}let s=this.top;if(l&&l.isLeaf)this.findInside(t);else if(a)this.addElement(t,o,a);else if(r.getContent)this.findInside(t),r.getContent(t,this.parser.schema).forEach(c=>this.insertNode(c,o));else{let c=t;typeof r.contentElement=="string"?c=t.querySelector(r.contentElement):typeof r.contentElement=="function"?c=r.contentElement(t):r.contentElement&&(c=r.contentElement),this.findAround(t,c,!0),this.addAll(c,o),this.findAround(t,c,!1)}i&&this.sync(s)&&this.open--}addAll(t,r,o,a){let i=o||0;for(let l=o?t.childNodes[o]:t.firstChild,s=a==null?null:t.childNodes[a];l!=s;l=l.nextSibling,++i)this.findAtPoint(t,i),this.addDOM(l,r);this.findAtPoint(t,i)}findPlace(t,r){let o,a;for(let i=this.open;i>=0;i--){let l=this.nodes[i],s=l.findWrapping(t);if(s&&(!o||o.length>s.length)&&(o=s,a=l,!s.length)||l.solid)break}if(!o)return null;this.sync(a);for(let i=0;i<o.length;i++)r=this.enterInner(o[i],null,r,!1);return r}insertNode(t,r){if(t.isInline&&this.needsBlock&&!this.top.type){let a=this.textblockFromContext();a&&(r=this.enterInner(a,null,r))}let o=this.findPlace(t,r);if(o){this.closeExtra();let a=this.top;a.match&&(a.match=a.match.matchType(t.type));let i=gt.none;for(let l of o.concat(t.marks))(a.type?a.type.allowsMarkType(l.type):F4(l.type,t.type))&&(i=l.addToSet(i));return a.content.push(t.mark(i)),!0}return!1}enter(t,r,o,a){let i=this.findPlace(t.create(r),o);return i&&(i=this.enterInner(t,r,o,!0,a)),i}enterInner(t,r,o,a=!1,i){this.closeExtra();let l=this.top;l.match=l.match&&l.match.matchType(t);let s=$4(t,i,l.options);l.options&Yl&&l.content.length==0&&(s|=Yl);let c=gt.none;return o=o.filter(u=>(l.type?l.type.allowsMarkType(u.type):F4(u.type,t))?(c=u.addToSet(c),!1):!0),this.nodes.push(new xc(t,r,c,a,null,s)),this.open++,o}closeExtra(t=!1){let r=this.nodes.length-1;if(r>this.open){for(;r>this.open;r--)this.nodes[r-1].content.push(this.nodes[r].finish(t));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(this.isOpen||this.options.topOpen)}sync(t){for(let r=this.open;r>=0;r--)if(this.nodes[r]==t)return this.open=r,!0;return!1}get currentPos(){this.closeExtra();let t=0;for(let r=this.open;r>=0;r--){let o=this.nodes[r].content;for(let a=o.length-1;a>=0;a--)t+=o[a].nodeSize;r&&t++}return t}findAtPoint(t,r){if(this.find)for(let o=0;o<this.find.length;o++)this.find[o].node==t&&this.find[o].offset==r&&(this.find[o].pos=this.currentPos)}findInside(t){if(this.find)for(let r=0;r<this.find.length;r++)this.find[r].pos==null&&t.nodeType==1&&t.contains(this.find[r].node)&&(this.find[r].pos=this.currentPos)}findAround(t,r,o){if(t!=r&&this.find)for(let a=0;a<this.find.length;a++)this.find[a].pos==null&&t.nodeType==1&&t.contains(this.find[a].node)&&r.compareDocumentPosition(this.find[a].node)&(o?2:4)&&(this.find[a].pos=this.currentPos)}findInText(t){if(this.find)for(let r=0;r<this.find.length;r++)this.find[r].node==t&&(this.find[r].pos=this.currentPos-(t.nodeValue.length-this.find[r].offset))}matchesContext(t){if(t.indexOf("|")>-1)return t.split(/\s*\|\s*/).some(this.matchesContext,this);let r=t.split("/"),o=this.options.context,a=!this.isOpen&&(!o||o.parent.type==this.nodes[0].type),i=-(o?o.depth+1:0)+(a?0:1),l=(s,c)=>{for(;s>=0;s--){let u=r[s];if(u==""){if(s==r.length-1||s==0)continue;for(;c>=i;c--)if(l(s-1,c))return!0;return!1}else{let d=c>0||c==0&&a?this.nodes[c].type:o&&c>=i?o.node(c-i).type:null;if(!d||d.name!=u&&!d.isInGroup(u))return!1;c--}}return!0};return l(r.length-1,this.open)}textblockFromContext(){let t=this.options.context;if(t)for(let r=t.depth;r>=0;r--){let o=t.node(r).contentMatchAt(t.indexAfter(r)).defaultType;if(o&&o.isTextblock&&o.defaultAttrs)return o}for(let r in this.parser.schema.nodes){let o=this.parser.schema.nodes[r];if(o.isTextblock&&o.defaultAttrs)return o}}}function $1e(e){for(let t=e.firstChild,r=null;t;t=t.nextSibling){let o=t.nodeType==1?t.nodeName.toLowerCase():null;o&&Y8.hasOwnProperty(o)&&r?(r.appendChild(t),t=r):o=="li"?r=t:o&&(r=null)}}function P1e(e,t){return(e.matches||e.msMatchesSelector||e.webkitMatchesSelector||e.mozMatchesSelector).call(e,t)}function R4(e){let t={};for(let r in e)t[r]=e[r];return t}function F4(e,t){let r=t.schema.nodes;for(let o in r){let a=r[o];if(!a.allowsMarkType(e))continue;let i=[],l=s=>{i.push(s);for(let c=0;c<s.edgeCount;c++){let{type:u,next:d}=s.edge(c);if(u==t||i.indexOf(d)<0&&l(d))return!0}};if(l(a.contentMatch))return!0}}class Xa{constructor(t,r){this.nodes=t,this.marks=r}serializeFragment(t,r={},o){o||(o=qf(r).createDocumentFragment());let a=o,i=[];return t.forEach(l=>{if(i.length||l.marks.length){let s=0,c=0;for(;s<i.length&&c<l.marks.length;){let u=l.marks[c];if(!this.marks[u.type.name]){c++;continue}if(!u.eq(i[s][0])||u.type.spec.spanning===!1)break;s++,c++}for(;s<i.length;)a=i.pop()[1];for(;c<l.marks.length;){let u=l.marks[c++],d=this.serializeMark(u,l.isInline,r);d&&(i.push([u,a]),a.appendChild(d.dom),a=d.contentDOM||d.dom)}}a.appendChild(this.serializeNodeInner(l,r))}),o}serializeNodeInner(t,r){let{dom:o,contentDOM:a}=Wc(qf(r),this.nodes[t.type.name](t),null,t.attrs);if(a){if(t.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(t.content,r,a)}return o}serializeNode(t,r={}){let o=this.serializeNodeInner(t,r);for(let a=t.marks.length-1;a>=0;a--){let i=this.serializeMark(t.marks[a],t.isInline,r);i&&((i.contentDOM||i.dom).appendChild(o),o=i.dom)}return o}serializeMark(t,r,o={}){let a=this.marks[t.type.name];return a&&Wc(qf(o),a(t,r),null,t.attrs)}static renderSpec(t,r,o=null,a){return Wc(t,r,o,a)}static fromSchema(t){return t.cached.domSerializer||(t.cached.domSerializer=new Xa(this.nodesFromSchema(t),this.marksFromSchema(t)))}static nodesFromSchema(t){let r=U4(t.nodes);return r.text||(r.text=o=>o.text),r}static marksFromSchema(t){return U4(t.marks)}}function U4(e){let t={};for(let r in e){let o=e[r].spec.toDOM;o&&(t[r]=o)}return t}function qf(e){return e.document||window.document}const H4=new WeakMap;function R1e(e){let t=H4.get(e);return t===void 0&&H4.set(e,t=F1e(e)),t}function F1e(e){let t=null;function r(o){if(o&&typeof o=="object")if(Array.isArray(o))if(typeof o[0]=="string")t||(t=[]),t.push(o);else for(let a=0;a<o.length;a++)r(o[a]);else for(let a in o)r(o[a])}return r(e),t}function Wc(e,t,r,o){if(typeof t=="string")return{dom:e.createTextNode(t)};if(t.nodeType!=null)return{dom:t};if(t.dom&&t.dom.nodeType!=null)return t;let a=t[0],i;if(typeof a!="string")throw new RangeError("Invalid array passed to renderSpec");if(o&&(i=R1e(o))&&i.indexOf(t)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let l=a.indexOf(" ");l>0&&(r=a.slice(0,l),a=a.slice(l+1));let s,c=r?e.createElementNS(r,a):e.createElement(a),u=t[1],d=1;if(u&&typeof u=="object"&&u.nodeType==null&&!Array.isArray(u)){d=2;for(let f in u)if(u[f]!=null){let p=f.indexOf(" ");p>0?c.setAttributeNS(f.slice(0,p),f.slice(p+1),u[f]):c.setAttribute(f,u[f])}}for(let f=d;f<t.length;f++){let p=t[f];if(p===0){if(f<t.length-1||f>d)throw new RangeError("Content hole must be the only child of its parent node");return{dom:c,contentDOM:c}}else{let{dom:h,contentDOM:m}=Wc(e,p,r,o);if(c.appendChild(h),m){if(s)throw new RangeError("Multiple content holes");s=m}}}return{dom:c,contentDOM:s}}const Q8=65535,W8=Math.pow(2,16);function U1e(e,t){return e+t*W8}function Y4(e){return e&Q8}function H1e(e){return(e-(e&Q8))/W8}const q8=1,G8=2,qc=4,K8=8;class x0{constructor(t,r,o){this.pos=t,this.delInfo=r,this.recover=o}get deleted(){return(this.delInfo&K8)>0}get deletedBefore(){return(this.delInfo&(q8|qc))>0}get deletedAfter(){return(this.delInfo&(G8|qc))>0}get deletedAcross(){return(this.delInfo&qc)>0}}class Pn{constructor(t,r=!1){if(this.ranges=t,this.inverted=r,!t.length&&Pn.empty)return Pn.empty}recover(t){let r=0,o=Y4(t);if(!this.inverted)for(let a=0;a<o;a++)r+=this.ranges[a*3+2]-this.ranges[a*3+1];return this.ranges[o*3]+r+H1e(t)}mapResult(t,r=1){return this._map(t,r,!1)}map(t,r=1){return this._map(t,r,!0)}_map(t,r,o){let a=0,i=this.inverted?2:1,l=this.inverted?1:2;for(let s=0;s<this.ranges.length;s+=3){let c=this.ranges[s]-(this.inverted?a:0);if(c>t)break;let u=this.ranges[s+i],d=this.ranges[s+l],f=c+u;if(t<=f){let p=u?t==c?-1:t==f?1:r:r,h=c+a+(p<0?0:d);if(o)return h;let m=t==(r<0?c:f)?null:U1e(s/3,t-c),g=t==c?G8:t==f?q8:qc;return(r<0?t!=c:t!=f)&&(g|=K8),new x0(h,g,m)}a+=d-u}return o?t+a:new x0(t+a,0,null)}touches(t,r){let o=0,a=Y4(r),i=this.inverted?2:1,l=this.inverted?1:2;for(let s=0;s<this.ranges.length;s+=3){let c=this.ranges[s]-(this.inverted?o:0);if(c>t)break;let u=this.ranges[s+i],d=c+u;if(t<=d&&s==a*3)return!0;o+=this.ranges[s+l]-u}return!1}forEach(t){let r=this.inverted?2:1,o=this.inverted?1:2;for(let a=0,i=0;a<this.ranges.length;a+=3){let l=this.ranges[a],s=l-(this.inverted?i:0),c=l+(this.inverted?0:i),u=this.ranges[a+r],d=this.ranges[a+o];t(s,s+u,c,c+d),i+=d-u}}invert(){return new Pn(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(t){return t==0?Pn.empty:new Pn(t<0?[0,-t,0]:[0,0,t])}}Pn.empty=new Pn([]);class Di{constructor(t=[],r,o=0,a=t.length){this.maps=t,this.mirror=r,this.from=o,this.to=a}slice(t=0,r=this.maps.length){return new Di(this.maps,this.mirror,t,r)}copy(){return new Di(this.maps.slice(),this.mirror&&this.mirror.slice(),this.from,this.to)}appendMap(t,r){this.to=this.maps.push(t),r!=null&&this.setMirror(this.maps.length-1,r)}appendMapping(t){for(let r=0,o=this.maps.length;r<t.maps.length;r++){let a=t.getMirror(r);this.appendMap(t.maps[r],a!=null&&a<r?o+a:void 0)}}getMirror(t){if(this.mirror){for(let r=0;r<this.mirror.length;r++)if(this.mirror[r]==t)return this.mirror[r+(r%2?-1:1)]}}setMirror(t,r){this.mirror||(this.mirror=[]),this.mirror.push(t,r)}appendMappingInverted(t){for(let r=t.maps.length-1,o=this.maps.length+t.maps.length;r>=0;r--){let a=t.getMirror(r);this.appendMap(t.maps[r].invert(),a!=null&&a>r?o-a-1:void 0)}}invert(){let t=new Di;return t.appendMappingInverted(this),t}map(t,r=1){if(this.mirror)return this._map(t,r,!0);for(let o=this.from;o<this.to;o++)t=this.maps[o].map(t,r);return t}mapResult(t,r=1){return this._map(t,r,!1)}_map(t,r,o){let a=0;for(let i=this.from;i<this.to;i++){let l=this.maps[i],s=l.mapResult(t,r);if(s.recover!=null){let c=this.getMirror(i);if(c!=null&&c>i&&c<this.to){i=c,t=this.maps[c].recover(s.recover);continue}}a|=s.delInfo,t=s.pos}return o?t:new x0(t,a,null)}}const Gf=Object.create(null);class vn{getMap(){return Pn.empty}merge(t){return null}static fromJSON(t,r){if(!r||!r.stepType)throw new RangeError("Invalid input for Step.fromJSON");let o=Gf[r.stepType];if(!o)throw new RangeError(`No step type ${r.stepType} defined`);return o.fromJSON(t,r)}static jsonID(t,r){if(t in Gf)throw new RangeError("Duplicate use of step JSON ID "+t);return Gf[t]=r,r.prototype.jsonID=t,r}}class Ft{constructor(t,r){this.doc=t,this.failed=r}static ok(t){return new Ft(t,null)}static fail(t){return new Ft(null,t)}static fromReplace(t,r,o,a){try{return Ft.ok(t.replace(r,o,a))}catch(i){if(i instanceof Du)return Ft.fail(i.message);throw i}}}function Uh(e,t,r){let o=[];for(let a=0;a<e.childCount;a++){let i=e.child(a);i.content.size&&(i=i.copy(Uh(i.content,t,i))),i.isInline&&(i=t(i,r,a)),o.push(i)}return fe.fromArray(o)}class Ho extends vn{constructor(t,r,o){super(),this.from=t,this.to=r,this.mark=o}apply(t){let r=t.slice(this.from,this.to),o=t.resolve(this.from),a=o.node(o.sharedDepth(this.to)),i=new Ee(Uh(r.content,(l,s)=>!l.isAtom||!s.type.allowsMarkType(this.mark.type)?l:l.mark(this.mark.addToSet(l.marks)),a),r.openStart,r.openEnd);return Ft.fromReplace(t,this.from,this.to,i)}invert(){return new Kr(this.from,this.to,this.mark)}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return r.deleted&&o.deleted||r.pos>=o.pos?null:new Ho(r.pos,o.pos,this.mark)}merge(t){return t instanceof Ho&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Ho(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number")throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new Ho(r.from,r.to,t.markFromJSON(r.mark))}}vn.jsonID("addMark",Ho);class Kr extends vn{constructor(t,r,o){super(),this.from=t,this.to=r,this.mark=o}apply(t){let r=t.slice(this.from,this.to),o=new Ee(Uh(r.content,a=>a.mark(this.mark.removeFromSet(a.marks)),t),r.openStart,r.openEnd);return Ft.fromReplace(t,this.from,this.to,o)}invert(){return new Ho(this.from,this.to,this.mark)}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return r.deleted&&o.deleted||r.pos>=o.pos?null:new Kr(r.pos,o.pos,this.mark)}merge(t){return t instanceof Kr&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Kr(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number")throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new Kr(r.from,r.to,t.markFromJSON(r.mark))}}vn.jsonID("removeMark",Kr);class Yo extends vn{constructor(t,r){super(),this.pos=t,this.mark=r}apply(t){let r=t.nodeAt(this.pos);if(!r)return Ft.fail("No node at mark step's position");let o=r.type.create(r.attrs,null,this.mark.addToSet(r.marks));return Ft.fromReplace(t,this.pos,this.pos+1,new Ee(fe.from(o),0,r.isLeaf?0:1))}invert(t){let r=t.nodeAt(this.pos);if(r){let o=this.mark.addToSet(r.marks);if(o.length==r.marks.length){for(let a=0;a<r.marks.length;a++)if(!r.marks[a].isInSet(o))return new Yo(this.pos,r.marks[a]);return new Yo(this.pos,this.mark)}}return new Qi(this.pos,this.mark)}map(t){let r=t.mapResult(this.pos,1);return r.deletedAfter?null:new Yo(r.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,r){if(typeof r.pos!="number")throw new RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new Yo(r.pos,t.markFromJSON(r.mark))}}vn.jsonID("addNodeMark",Yo);class Qi extends vn{constructor(t,r){super(),this.pos=t,this.mark=r}apply(t){let r=t.nodeAt(this.pos);if(!r)return Ft.fail("No node at mark step's position");let o=r.type.create(r.attrs,null,this.mark.removeFromSet(r.marks));return Ft.fromReplace(t,this.pos,this.pos+1,new Ee(fe.from(o),0,r.isLeaf?0:1))}invert(t){let r=t.nodeAt(this.pos);return!r||!this.mark.isInSet(r.marks)?this:new Yo(this.pos,this.mark)}map(t){let r=t.mapResult(this.pos,1);return r.deletedAfter?null:new Qi(r.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,r){if(typeof r.pos!="number")throw new RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new Qi(r.pos,t.markFromJSON(r.mark))}}vn.jsonID("removeNodeMark",Qi);class Kt extends vn{constructor(t,r,o,a=!1){super(),this.from=t,this.to=r,this.slice=o,this.structure=a}apply(t){return this.structure&&C0(t,this.from,this.to)?Ft.fail("Structure replace would overwrite content"):Ft.fromReplace(t,this.from,this.to,this.slice)}getMap(){return new Pn([this.from,this.to-this.from,this.slice.size])}invert(t){return new Kt(this.from,this.from+this.slice.size,t.slice(this.from,this.to))}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return r.deletedAcross&&o.deletedAcross?null:new Kt(r.pos,Math.max(r.pos,o.pos),this.slice)}merge(t){if(!(t instanceof Kt)||t.structure||this.structure)return null;if(this.from+this.slice.size==t.from&&!this.slice.openEnd&&!t.slice.openStart){let r=this.slice.size+t.slice.size==0?Ee.empty:new Ee(this.slice.content.append(t.slice.content),this.slice.openStart,t.slice.openEnd);return new Kt(this.from,this.to+(t.to-t.from),r,this.structure)}else if(t.to==this.from&&!this.slice.openStart&&!t.slice.openEnd){let r=this.slice.size+t.slice.size==0?Ee.empty:new Ee(t.slice.content.append(this.slice.content),t.slice.openStart,this.slice.openEnd);return new Kt(t.from,this.to,r,this.structure)}else return null}toJSON(){let t={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number")throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new Kt(r.from,r.to,Ee.fromJSON(t,r.slice),!!r.structure)}}vn.jsonID("replace",Kt);class Zt extends vn{constructor(t,r,o,a,i,l,s=!1){super(),this.from=t,this.to=r,this.gapFrom=o,this.gapTo=a,this.slice=i,this.insert=l,this.structure=s}apply(t){if(this.structure&&(C0(t,this.from,this.gapFrom)||C0(t,this.gapTo,this.to)))return Ft.fail("Structure gap-replace would overwrite content");let r=t.slice(this.gapFrom,this.gapTo);if(r.openStart||r.openEnd)return Ft.fail("Gap is not a flat range");let o=this.slice.insertAt(this.insert,r.content);return o?Ft.fromReplace(t,this.from,this.to,o):Ft.fail("Content does not fit in gap")}getMap(){return new Pn([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(t){let r=this.gapTo-this.gapFrom;return new Zt(this.from,this.from+this.slice.size+r,this.from+this.insert,this.from+this.insert+r,t.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1),a=this.from==this.gapFrom?r.pos:t.map(this.gapFrom,-1),i=this.to==this.gapTo?o.pos:t.map(this.gapTo,1);return r.deletedAcross&&o.deletedAcross||a<r.pos||i>o.pos?null:new Zt(r.pos,o.pos,a,i,this.slice,this.insert,this.structure)}toJSON(){let t={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number"||typeof r.gapFrom!="number"||typeof r.gapTo!="number"||typeof r.insert!="number")throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new Zt(r.from,r.to,r.gapFrom,r.gapTo,Ee.fromJSON(t,r.slice),r.insert,!!r.structure)}}vn.jsonID("replaceAround",Zt);function C0(e,t,r){let o=e.resolve(t),a=r-t,i=o.depth;for(;a>0&&i>0&&o.indexAfter(i)==o.node(i).childCount;)i--,a--;if(a>0){let l=o.node(i).maybeChild(o.indexAfter(i));for(;a>0;){if(!l||l.isLeaf)return!0;l=l.firstChild,a--}}return!1}function Y1e(e,t,r,o){let a=[],i=[],l,s;e.doc.nodesBetween(t,r,(c,u,d)=>{if(!c.isInline)return;let f=c.marks;if(!o.isInSet(f)&&d.type.allowsMarkType(o.type)){let p=Math.max(u,t),h=Math.min(u+c.nodeSize,r),m=o.addToSet(f);for(let g=0;g<f.length;g++)f[g].isInSet(m)||(l&&l.to==p&&l.mark.eq(f[g])?l.to=h:a.push(l=new Kr(p,h,f[g])));s&&s.to==p?s.to=h:i.push(s=new Ho(p,h,o))}}),a.forEach(c=>e.step(c)),i.forEach(c=>e.step(c))}function Q1e(e,t,r,o){let a=[],i=0;e.doc.nodesBetween(t,r,(l,s)=>{if(!l.isInline)return;i++;let c=null;if(o instanceof nf){let u=l.marks,d;for(;d=o.isInSet(u);)(c||(c=[])).push(d),u=d.removeFromSet(u)}else o?o.isInSet(l.marks)&&(c=[o]):c=l.marks;if(c&&c.length){let u=Math.min(s+l.nodeSize,r);for(let d=0;d<c.length;d++){let f=c[d],p;for(let h=0;h<a.length;h++){let m=a[h];m.step==i-1&&f.eq(a[h].style)&&(p=m)}p?(p.to=u,p.step=i):a.push({style:f,from:Math.max(s,t),to:u,step:i})}}}),a.forEach(l=>e.step(new Kr(l.from,l.to,l.style)))}function Hh(e,t,r,o=r.contentMatch,a=!0){let i=e.doc.nodeAt(t),l=[],s=t+1;for(let c=0;c<i.childCount;c++){let u=i.child(c),d=s+u.nodeSize,f=o.matchType(u.type);if(!f)l.push(new Kt(s,d,Ee.empty));else{o=f;for(let p=0;p<u.marks.length;p++)r.allowsMarkType(u.marks[p].type)||e.step(new Kr(s,d,u.marks[p]));if(a&&u.isText&&r.whitespace!="pre"){let p,h=/\r?\n|\r/g,m;for(;p=h.exec(u.text);)m||(m=new Ee(fe.from(r.schema.text(" ",r.allowedMarks(u.marks))),0,0)),l.push(new Kt(s+p.index,s+p.index+p[0].length,m))}}s=d}if(!o.validEnd){let c=o.fillBefore(fe.empty,!0);e.replace(s,s,new Ee(c,0,0))}for(let c=l.length-1;c>=0;c--)e.step(l[c])}function W1e(e,t,r){return(t==0||e.canReplace(t,e.childCount))&&(r==e.childCount||e.canReplace(0,r))}function gl(e){let r=e.parent.content.cutByIndex(e.startIndex,e.endIndex);for(let o=e.depth;;--o){let a=e.$from.node(o),i=e.$from.index(o),l=e.$to.indexAfter(o);if(o<e.depth&&a.canReplace(i,l,r))return o;if(o==0||a.type.spec.isolating||!W1e(a,i,l))break}return null}function q1e(e,t,r){let{$from:o,$to:a,depth:i}=t,l=o.before(i+1),s=a.after(i+1),c=l,u=s,d=fe.empty,f=0;for(let m=i,g=!1;m>r;m--)g||o.index(m)>0?(g=!0,d=fe.from(o.node(m).copy(d)),f++):c--;let p=fe.empty,h=0;for(let m=i,g=!1;m>r;m--)g||a.after(m+1)<a.end(m)?(g=!0,p=fe.from(a.node(m).copy(p)),h++):u++;e.step(new Zt(c,u,l,s,new Ee(d.append(p),f,h),d.size-f,!0))}function Yh(e,t,r=null,o=e){let a=G1e(e,t),i=a&&K1e(o,t);return i?a.map(Q4).concat({type:t,attrs:r}).concat(i.map(Q4)):null}function Q4(e){return{type:e,attrs:null}}function G1e(e,t){let{parent:r,startIndex:o,endIndex:a}=e,i=r.contentMatchAt(o).findWrapping(t);if(!i)return null;let l=i.length?i[0]:t;return r.canReplaceWith(o,a,l)?i:null}function K1e(e,t){let{parent:r,startIndex:o,endIndex:a}=e,i=r.child(o),l=t.contentMatch.findWrapping(i.type);if(!l)return null;let c=(l.length?l[l.length-1]:t).contentMatch;for(let u=o;c&&u<a;u++)c=c.matchType(r.child(u).type);return!c||!c.validEnd?null:l}function J1e(e,t,r){let o=fe.empty;for(let l=r.length-1;l>=0;l--){if(o.size){let s=r[l].type.contentMatch.matchFragment(o);if(!s||!s.validEnd)throw new RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}o=fe.from(r[l].type.create(r[l].attrs,o))}let a=t.start,i=t.end;e.step(new Zt(a,i,a,i,new Ee(o,0,0),r.length,!0))}function Z1e(e,t,r,o,a){if(!o.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");let i=e.steps.length;e.doc.nodesBetween(t,r,(l,s)=>{let c=typeof a=="function"?a(l):a;if(l.isTextblock&&!l.hasMarkup(o,c)&&X1e(e.doc,e.mapping.slice(i).map(s),o)){let u=null;if(o.schema.linebreakReplacement){let h=o.whitespace=="pre",m=!!o.contentMatch.matchType(o.schema.linebreakReplacement);h&&!m?u=!1:!h&&m&&(u=!0)}u===!1&&Z8(e,l,s,i),Hh(e,e.mapping.slice(i).map(s,1),o,void 0,u===null);let d=e.mapping.slice(i),f=d.map(s,1),p=d.map(s+l.nodeSize,1);return e.step(new Zt(f,p,f+1,p-1,new Ee(fe.from(o.create(c,null,l.marks)),0,0),1,!0)),u===!0&&J8(e,l,s,i),!1}})}function J8(e,t,r,o){t.forEach((a,i)=>{if(a.isText){let l,s=/\r?\n|\r/g;for(;l=s.exec(a.text);){let c=e.mapping.slice(o).map(r+1+i+l.index);e.replaceWith(c,c+1,t.type.schema.linebreakReplacement.create())}}})}function Z8(e,t,r,o){t.forEach((a,i)=>{if(a.type==a.type.schema.linebreakReplacement){let l=e.mapping.slice(o).map(r+1+i);e.replaceWith(l,l+1,t.type.schema.text(`
|
|
51
|
-
`))}})}function X1e(e,t,r){let o=e.resolve(t),a=o.index();return o.parent.canReplaceWith(a,a+1,r)}function ege(e,t,r,o,a){let i=e.doc.nodeAt(t);if(!i)throw new RangeError("No node at given position");r||(r=i.type);let l=r.create(o,null,a||i.marks);if(i.isLeaf)return e.replaceWith(t,t+i.nodeSize,l);if(!r.validContent(i.content))throw new RangeError("Invalid content for node type "+r.name);e.step(new Zt(t,t+i.nodeSize,t+1,t+i.nodeSize-1,new Ee(fe.from(l),0,0),1,!0))}function Si(e,t,r=1,o){let a=e.resolve(t),i=a.depth-r,l=o&&o[o.length-1]||a.parent;if(i<0||a.parent.type.spec.isolating||!a.parent.canReplace(a.index(),a.parent.childCount)||!l.type.validContent(a.parent.content.cutByIndex(a.index(),a.parent.childCount)))return!1;for(let u=a.depth-1,d=r-2;u>i;u--,d--){let f=a.node(u),p=a.index(u);if(f.type.spec.isolating)return!1;let h=f.content.cutByIndex(p,f.childCount),m=o&&o[d+1];m&&(h=h.replaceChild(0,m.type.create(m.attrs)));let g=o&&o[d]||f;if(!f.canReplace(p+1,f.childCount)||!g.type.validContent(h))return!1}let s=a.indexAfter(i),c=o&&o[0];return a.node(i).canReplaceWith(s,s,c?c.type:a.node(i+1).type)}function tge(e,t,r=1,o){let a=e.doc.resolve(t),i=fe.empty,l=fe.empty;for(let s=a.depth,c=a.depth-r,u=r-1;s>c;s--,u--){i=fe.from(a.node(s).copy(i));let d=o&&o[u];l=fe.from(d?d.type.create(d.attrs,l):a.node(s).copy(l))}e.step(new Kt(t,t,new Ee(i.append(l),r,r),!0))}function la(e,t){let r=e.resolve(t),o=r.index();return X8(r.nodeBefore,r.nodeAfter)&&r.parent.canReplace(o,o+1)}function nge(e,t){t.content.size||e.type.compatibleContent(t.type);let r=e.contentMatchAt(e.childCount),{linebreakReplacement:o}=e.type.schema;for(let a=0;a<t.childCount;a++){let i=t.child(a),l=i.type==o?e.type.schema.nodes.text:i.type;if(r=r.matchType(l),!r||!e.type.allowsMarks(i.marks))return!1}return r.validEnd}function X8(e,t){return!!(e&&t&&!e.isLeaf&&nge(e,t))}function rf(e,t,r=-1){let o=e.resolve(t);for(let a=o.depth;;a--){let i,l,s=o.index(a);if(a==o.depth?(i=o.nodeBefore,l=o.nodeAfter):r>0?(i=o.node(a+1),s++,l=o.node(a).maybeChild(s)):(i=o.node(a).maybeChild(s-1),l=o.node(a+1)),i&&!i.isTextblock&&X8(i,l)&&o.node(a).canReplace(s,s+1))return t;if(a==0)break;t=r<0?o.before(a):o.after(a)}}function rge(e,t,r){let o=null,{linebreakReplacement:a}=e.doc.type.schema,i=e.doc.resolve(t-r),l=i.node().type;if(a&&l.inlineContent){let d=l.whitespace=="pre",f=!!l.contentMatch.matchType(a);d&&!f?o=!1:!d&&f&&(o=!0)}let s=e.steps.length;if(o===!1){let d=e.doc.resolve(t+r);Z8(e,d.node(),d.before(),s)}l.inlineContent&&Hh(e,t+r-1,l,i.node().contentMatchAt(i.index()),o==null);let c=e.mapping.slice(s),u=c.map(t-r);if(e.step(new Kt(u,c.map(t+r,-1),Ee.empty,!0)),o===!0){let d=e.doc.resolve(u);J8(e,d.node(),d.before(),e.steps.length)}return e}function oge(e,t,r){let o=e.resolve(t);if(o.parent.canReplaceWith(o.index(),o.index(),r))return t;if(o.parentOffset==0)for(let a=o.depth-1;a>=0;a--){let i=o.index(a);if(o.node(a).canReplaceWith(i,i,r))return o.before(a+1);if(i>0)return null}if(o.parentOffset==o.parent.content.size)for(let a=o.depth-1;a>=0;a--){let i=o.indexAfter(a);if(o.node(a).canReplaceWith(i,i,r))return o.after(a+1);if(i<o.node(a).childCount)return null}return null}function age(e,t,r){let o=e.resolve(t);if(!r.content.size)return t;let a=r.content;for(let i=0;i<r.openStart;i++)a=a.firstChild.content;for(let i=1;i<=(r.openStart==0&&r.size?2:1);i++)for(let l=o.depth;l>=0;l--){let s=l==o.depth?0:o.pos<=(o.start(l+1)+o.end(l+1))/2?-1:1,c=o.index(l)+(s>0?1:0),u=o.node(l),d=!1;if(i==1)d=u.canReplace(c,c,a);else{let f=u.contentMatchAt(c).findWrapping(a.firstChild.type);d=f&&u.canReplaceWith(c,c,f[0])}if(d)return s==0?o.pos:s<0?o.before(l+1):o.after(l+1)}return null}function of(e,t,r=t,o=Ee.empty){if(t==r&&!o.size)return null;let a=e.resolve(t),i=e.resolve(r);return ew(a,i,o)?new Kt(t,r,o):new ige(a,i,o).fit()}function ew(e,t,r){return!r.openStart&&!r.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),r.content)}class ige{constructor(t,r,o){this.$from=t,this.$to=r,this.unplaced=o,this.frontier=[],this.placed=fe.empty;for(let a=0;a<=t.depth;a++){let i=t.node(a);this.frontier.push({type:i.type,match:i.contentMatchAt(t.indexAfter(a))})}for(let a=t.depth;a>0;a--)this.placed=fe.from(t.node(a).copy(this.placed))}get depth(){return this.frontier.length-1}fit(){for(;this.unplaced.size;){let u=this.findFittable();u?this.placeNodes(u):this.openMore()||this.dropNode()}let t=this.mustMoveInline(),r=this.placed.size-this.depth-this.$from.depth,o=this.$from,a=this.close(t<0?this.$to:o.doc.resolve(t));if(!a)return null;let i=this.placed,l=o.depth,s=a.depth;for(;l&&s&&i.childCount==1;)i=i.firstChild.content,l--,s--;let c=new Ee(i,l,s);return t>-1?new Zt(o.pos,t,this.$to.pos,this.$to.end(),c,r):c.size||o.pos!=this.$to.pos?new Kt(o.pos,a.pos,c):null}findFittable(){let t=this.unplaced.openStart;for(let r=this.unplaced.content,o=0,a=this.unplaced.openEnd;o<t;o++){let i=r.firstChild;if(r.childCount>1&&(a=0),i.type.spec.isolating&&a<=o){t=o;break}r=i.content}for(let r=1;r<=2;r++)for(let o=r==1?t:this.unplaced.openStart;o>=0;o--){let a,i=null;o?(i=Kf(this.unplaced.content,o-1).firstChild,a=i.content):a=this.unplaced.content;let l=a.firstChild;for(let s=this.depth;s>=0;s--){let{type:c,match:u}=this.frontier[s],d,f=null;if(r==1&&(l?u.matchType(l.type)||(f=u.fillBefore(fe.from(l),!1)):i&&c.compatibleContent(i.type)))return{sliceDepth:o,frontierDepth:s,parent:i,inject:f};if(r==2&&l&&(d=u.findWrapping(l.type)))return{sliceDepth:o,frontierDepth:s,parent:i,wrap:d};if(i&&u.matchType(i.type))break}}}openMore(){let{content:t,openStart:r,openEnd:o}=this.unplaced,a=Kf(t,r);return!a.childCount||a.firstChild.isLeaf?!1:(this.unplaced=new Ee(t,r+1,Math.max(o,a.size+r>=t.size-o?r+1:0)),!0)}dropNode(){let{content:t,openStart:r,openEnd:o}=this.unplaced,a=Kf(t,r);if(a.childCount<=1&&r>0){let i=t.size-r<=r+a.size;this.unplaced=new Ee(Ol(t,r-1,1),r-1,i?r-1:o)}else this.unplaced=new Ee(Ol(t,r,1),r,o)}placeNodes({sliceDepth:t,frontierDepth:r,parent:o,inject:a,wrap:i}){for(;this.depth>r;)this.closeFrontierNode();if(i)for(let g=0;g<i.length;g++)this.openFrontierNode(i[g]);let l=this.unplaced,s=o?o.content:l.content,c=l.openStart-t,u=0,d=[],{match:f,type:p}=this.frontier[r];if(a){for(let g=0;g<a.childCount;g++)d.push(a.child(g));f=f.matchFragment(a)}let h=s.size+t-(l.content.size-l.openEnd);for(;u<s.childCount;){let g=s.child(u),v=f.matchType(g.type);if(!v)break;u++,(u>1||c==0||g.content.size)&&(f=v,d.push(tw(g.mark(p.allowedMarks(g.marks)),u==1?c:0,u==s.childCount?h:-1)))}let m=u==s.childCount;m||(h=-1),this.placed=zl(this.placed,r,fe.from(d)),this.frontier[r].match=f,m&&h<0&&o&&o.type==this.frontier[this.depth].type&&this.frontier.length>1&&this.closeFrontierNode();for(let g=0,v=s;g<h;g++){let y=v.lastChild;this.frontier.push({type:y.type,match:y.contentMatchAt(y.childCount)}),v=y.content}this.unplaced=m?t==0?Ee.empty:new Ee(Ol(l.content,t-1,1),t-1,h<0?l.openEnd:t-1):new Ee(Ol(l.content,t,u),l.openStart,l.openEnd)}mustMoveInline(){if(!this.$to.parent.isTextblock)return-1;let t=this.frontier[this.depth],r;if(!t.type.isTextblock||!Jf(this.$to,this.$to.depth,t.type,t.match,!1)||this.$to.depth==this.depth&&(r=this.findCloseLevel(this.$to))&&r.depth==this.depth)return-1;let{depth:o}=this.$to,a=this.$to.after(o);for(;o>1&&a==this.$to.end(--o);)++a;return a}findCloseLevel(t){e:for(let r=Math.min(this.depth,t.depth);r>=0;r--){let{match:o,type:a}=this.frontier[r],i=r<t.depth&&t.end(r+1)==t.pos+(t.depth-(r+1)),l=Jf(t,r,a,o,i);if(l){for(let s=r-1;s>=0;s--){let{match:c,type:u}=this.frontier[s],d=Jf(t,s,u,c,!0);if(!d||d.childCount)continue e}return{depth:r,fit:l,move:i?t.doc.resolve(t.after(r+1)):t}}}}close(t){let r=this.findCloseLevel(t);if(!r)return null;for(;this.depth>r.depth;)this.closeFrontierNode();r.fit.childCount&&(this.placed=zl(this.placed,r.depth,r.fit)),t=r.move;for(let o=r.depth+1;o<=t.depth;o++){let a=t.node(o),i=a.type.contentMatch.fillBefore(a.content,!0,t.index(o));this.openFrontierNode(a.type,a.attrs,i)}return t}openFrontierNode(t,r=null,o){let a=this.frontier[this.depth];a.match=a.match.matchType(t),this.placed=zl(this.placed,this.depth,fe.from(t.create(r,o))),this.frontier.push({type:t,match:t.contentMatch})}closeFrontierNode(){let r=this.frontier.pop().match.fillBefore(fe.empty,!0);r.childCount&&(this.placed=zl(this.placed,this.frontier.length,r))}}function Ol(e,t,r){return t==0?e.cutByIndex(r,e.childCount):e.replaceChild(0,e.firstChild.copy(Ol(e.firstChild.content,t-1,r)))}function zl(e,t,r){return t==0?e.append(r):e.replaceChild(e.childCount-1,e.lastChild.copy(zl(e.lastChild.content,t-1,r)))}function Kf(e,t){for(let r=0;r<t;r++)e=e.firstChild.content;return e}function tw(e,t,r){if(t<=0)return e;let o=e.content;return t>1&&(o=o.replaceChild(0,tw(o.firstChild,t-1,o.childCount==1?r-1:0))),t>0&&(o=e.type.contentMatch.fillBefore(o).append(o),r<=0&&(o=o.append(e.type.contentMatch.matchFragment(o).fillBefore(fe.empty,!0)))),e.copy(o)}function Jf(e,t,r,o,a){let i=e.node(t),l=a?e.indexAfter(t):e.index(t);if(l==i.childCount&&!r.compatibleContent(i.type))return null;let s=o.fillBefore(i.content,!0,l);return s&&!lge(r,i.content,l)?s:null}function lge(e,t,r){for(let o=r;o<t.childCount;o++)if(!e.allowsMarks(t.child(o).marks))return!0;return!1}function sge(e){return e.spec.defining||e.spec.definingForContent}function cge(e,t,r,o){if(!o.size)return e.deleteRange(t,r);let a=e.doc.resolve(t),i=e.doc.resolve(r);if(ew(a,i,o))return e.step(new Kt(t,r,o));let l=rw(a,e.doc.resolve(r));l[l.length-1]==0&&l.pop();let s=-(a.depth+1);l.unshift(s);for(let p=a.depth,h=a.pos-1;p>0;p--,h--){let m=a.node(p).type.spec;if(m.defining||m.definingAsContext||m.isolating)break;l.indexOf(p)>-1?s=p:a.before(p)==h&&l.splice(1,0,-p)}let c=l.indexOf(s),u=[],d=o.openStart;for(let p=o.content,h=0;;h++){let m=p.firstChild;if(u.push(m),h==o.openStart)break;p=m.content}for(let p=d-1;p>=0;p--){let h=u[p],m=sge(h.type);if(m&&!h.sameMarkup(a.node(Math.abs(s)-1)))d=p;else if(m||!h.type.isTextblock)break}for(let p=o.openStart;p>=0;p--){let h=(p+d+1)%(o.openStart+1),m=u[h];if(m)for(let g=0;g<l.length;g++){let v=l[(g+c)%l.length],y=!0;v<0&&(y=!1,v=-v);let N=a.node(v-1),b=a.index(v-1);if(N.canReplaceWith(b,b,m.type,m.marks))return e.replace(a.before(v),y?i.after(v):r,new Ee(nw(o.content,0,o.openStart,h),h,o.openEnd))}}let f=e.steps.length;for(let p=l.length-1;p>=0&&(e.replace(t,r,o),!(e.steps.length>f));p--){let h=l[p];h<0||(t=a.before(h),r=i.after(h))}}function nw(e,t,r,o,a){if(t<r){let i=e.firstChild;e=e.replaceChild(0,i.copy(nw(i.content,t+1,r,o,i)))}if(t>o){let i=a.contentMatchAt(0),l=i.fillBefore(e).append(e);e=l.append(i.matchFragment(l).fillBefore(fe.empty,!0))}return e}function uge(e,t,r,o){if(!o.isInline&&t==r&&e.doc.resolve(t).parent.content.size){let a=oge(e.doc,t,o.type);a!=null&&(t=r=a)}e.replaceRange(t,r,new Ee(fe.from(o),0,0))}function dge(e,t,r){let o=e.doc.resolve(t),a=e.doc.resolve(r),i=rw(o,a);for(let l=0;l<i.length;l++){let s=i[l],c=l==i.length-1;if(c&&s==0||o.node(s).type.contentMatch.validEnd)return e.delete(o.start(s),a.end(s));if(s>0&&(c||o.node(s-1).canReplace(o.index(s-1),a.indexAfter(s-1))))return e.delete(o.before(s),a.after(s))}for(let l=1;l<=o.depth&&l<=a.depth;l++)if(t-o.start(l)==o.depth-l&&r>o.end(l)&&a.end(l)-r!=a.depth-l&&o.start(l-1)==a.start(l-1)&&o.node(l-1).canReplace(o.index(l-1),a.index(l-1)))return e.delete(o.before(l),r);e.delete(t,r)}function rw(e,t){let r=[],o=Math.min(e.depth,t.depth);for(let a=o;a>=0;a--){let i=e.start(a);if(i<e.pos-(e.depth-a)||t.end(a)>t.pos+(t.depth-a)||e.node(a).type.spec.isolating||t.node(a).type.spec.isolating)break;(i==t.start(a)||a==e.depth&&a==t.depth&&e.parent.inlineContent&&t.parent.inlineContent&&a&&t.start(a-1)==i-1)&&r.push(a)}return r}class _i extends vn{constructor(t,r,o){super(),this.pos=t,this.attr=r,this.value=o}apply(t){let r=t.nodeAt(this.pos);if(!r)return Ft.fail("No node at attribute step's position");let o=Object.create(null);for(let i in r.attrs)o[i]=r.attrs[i];o[this.attr]=this.value;let a=r.type.create(o,null,r.marks);return Ft.fromReplace(t,this.pos,this.pos+1,new Ee(fe.from(a),0,r.isLeaf?0:1))}getMap(){return Pn.empty}invert(t){return new _i(this.pos,this.attr,t.nodeAt(this.pos).attrs[this.attr])}map(t){let r=t.mapResult(this.pos,1);return r.deletedAfter?null:new _i(r.pos,this.attr,this.value)}toJSON(){return{stepType:"attr",pos:this.pos,attr:this.attr,value:this.value}}static fromJSON(t,r){if(typeof r.pos!="number"||typeof r.attr!="string")throw new RangeError("Invalid input for AttrStep.fromJSON");return new _i(r.pos,r.attr,r.value)}}vn.jsonID("attr",_i);class xs extends vn{constructor(t,r){super(),this.attr=t,this.value=r}apply(t){let r=Object.create(null);for(let a in t.attrs)r[a]=t.attrs[a];r[this.attr]=this.value;let o=t.type.create(r,t.content,t.marks);return Ft.ok(o)}getMap(){return Pn.empty}invert(t){return new xs(this.attr,t.attrs[this.attr])}map(t){return this}toJSON(){return{stepType:"docAttr",attr:this.attr,value:this.value}}static fromJSON(t,r){if(typeof r.attr!="string")throw new RangeError("Invalid input for DocAttrStep.fromJSON");return new xs(r.attr,r.value)}}vn.jsonID("docAttr",xs);let Wi=class extends Error{};Wi=function e(t){let r=Error.call(this,t);return r.__proto__=e.prototype,r};Wi.prototype=Object.create(Error.prototype);Wi.prototype.constructor=Wi;Wi.prototype.name="TransformError";class ow{constructor(t){this.doc=t,this.steps=[],this.docs=[],this.mapping=new Di}get before(){return this.docs.length?this.docs[0]:this.doc}step(t){let r=this.maybeStep(t);if(r.failed)throw new Wi(r.failed);return this}maybeStep(t){let r=t.apply(this.doc);return r.failed||this.addStep(t,r.doc),r}get docChanged(){return this.steps.length>0}addStep(t,r){this.docs.push(this.doc),this.steps.push(t),this.mapping.appendMap(t.getMap()),this.doc=r}replace(t,r=t,o=Ee.empty){let a=of(this.doc,t,r,o);return a&&this.step(a),this}replaceWith(t,r,o){return this.replace(t,r,new Ee(fe.from(o),0,0))}delete(t,r){return this.replace(t,r,Ee.empty)}insert(t,r){return this.replaceWith(t,t,r)}replaceRange(t,r,o){return cge(this,t,r,o),this}replaceRangeWith(t,r,o){return uge(this,t,r,o),this}deleteRange(t,r){return dge(this,t,r),this}lift(t,r){return q1e(this,t,r),this}join(t,r=1){return rge(this,t,r),this}wrap(t,r){return J1e(this,t,r),this}setBlockType(t,r=t,o,a=null){return Z1e(this,t,r,o,a),this}setNodeMarkup(t,r,o=null,a){return ege(this,t,r,o,a),this}setNodeAttribute(t,r,o){return this.step(new _i(t,r,o)),this}setDocAttribute(t,r){return this.step(new xs(t,r)),this}addNodeMark(t,r){return this.step(new Yo(t,r)),this}removeNodeMark(t,r){if(!(r instanceof gt)){let o=this.doc.nodeAt(t);if(!o)throw new RangeError("No node at position "+t);if(r=r.isInSet(o.marks),!r)return this}return this.step(new Qi(t,r)),this}split(t,r=1,o){return tge(this,t,r,o),this}addMark(t,r,o){return Y1e(this,t,r,o),this}removeMark(t,r,o){return Q1e(this,t,r,o),this}clearIncompatible(t,r,o){return Hh(this,t,r,o),this}}const Zf=Object.create(null);class Ze{constructor(t,r,o){this.$anchor=t,this.$head=r,this.ranges=o||[new fge(t.min(r),t.max(r))]}get anchor(){return this.$anchor.pos}get head(){return this.$head.pos}get from(){return this.$from.pos}get to(){return this.$to.pos}get $from(){return this.ranges[0].$from}get $to(){return this.ranges[0].$to}get empty(){let t=this.ranges;for(let r=0;r<t.length;r++)if(t[r].$from.pos!=t[r].$to.pos)return!1;return!0}content(){return this.$from.doc.slice(this.from,this.to,!0)}replace(t,r=Ee.empty){let o=r.content.lastChild,a=null;for(let s=0;s<r.openEnd;s++)a=o,o=o.lastChild;let i=t.steps.length,l=this.ranges;for(let s=0;s<l.length;s++){let{$from:c,$to:u}=l[s],d=t.mapping.slice(i);t.replaceRange(d.map(c.pos),d.map(u.pos),s?Ee.empty:r),s==0&&G4(t,i,(o?o.isInline:a&&a.isTextblock)?-1:1)}}replaceWith(t,r){let o=t.steps.length,a=this.ranges;for(let i=0;i<a.length;i++){let{$from:l,$to:s}=a[i],c=t.mapping.slice(o),u=c.map(l.pos),d=c.map(s.pos);i?t.deleteRange(u,d):(t.replaceRangeWith(u,d,r),G4(t,o,r.isInline?-1:1))}}static findFrom(t,r,o=!1){let a=t.parent.inlineContent?new Ge(t):hi(t.node(0),t.parent,t.pos,t.index(),r,o);if(a)return a;for(let i=t.depth-1;i>=0;i--){let l=r<0?hi(t.node(0),t.node(i),t.before(i+1),t.index(i),r,o):hi(t.node(0),t.node(i),t.after(i+1),t.index(i)+1,r,o);if(l)return l}return null}static near(t,r=1){return this.findFrom(t,r)||this.findFrom(t,-r)||new _r(t.node(0))}static atStart(t){return hi(t,t,0,0,1)||new _r(t)}static atEnd(t){return hi(t,t,t.content.size,t.childCount,-1)||new _r(t)}static fromJSON(t,r){if(!r||!r.type)throw new RangeError("Invalid input for Selection.fromJSON");let o=Zf[r.type];if(!o)throw new RangeError(`No selection type ${r.type} defined`);return o.fromJSON(t,r)}static jsonID(t,r){if(t in Zf)throw new RangeError("Duplicate use of selection JSON ID "+t);return Zf[t]=r,r.prototype.jsonID=t,r}getBookmark(){return Ge.between(this.$anchor,this.$head).getBookmark()}}Ze.prototype.visible=!0;class fge{constructor(t,r){this.$from=t,this.$to=r}}let W4=!1;function q4(e){!W4&&!e.parent.inlineContent&&(W4=!0,console.warn("TextSelection endpoint not pointing into a node with inline content ("+e.parent.type.name+")"))}class Ge extends Ze{constructor(t,r=t){q4(t),q4(r),super(t,r)}get $cursor(){return this.$anchor.pos==this.$head.pos?this.$head:null}map(t,r){let o=t.resolve(r.map(this.head));if(!o.parent.inlineContent)return Ze.near(o);let a=t.resolve(r.map(this.anchor));return new Ge(a.parent.inlineContent?a:o,o)}replace(t,r=Ee.empty){if(super.replace(t,r),r==Ee.empty){let o=this.$from.marksAcross(this.$to);o&&t.ensureMarks(o)}}eq(t){return t instanceof Ge&&t.anchor==this.anchor&&t.head==this.head}getBookmark(){return new af(this.anchor,this.head)}toJSON(){return{type:"text",anchor:this.anchor,head:this.head}}static fromJSON(t,r){if(typeof r.anchor!="number"||typeof r.head!="number")throw new RangeError("Invalid input for TextSelection.fromJSON");return new Ge(t.resolve(r.anchor),t.resolve(r.head))}static create(t,r,o=r){let a=t.resolve(r);return new this(a,o==r?a:t.resolve(o))}static between(t,r,o){let a=t.pos-r.pos;if((!o||a)&&(o=a>=0?1:-1),!r.parent.inlineContent){let i=Ze.findFrom(r,o,!0)||Ze.findFrom(r,-o,!0);if(i)r=i.$head;else return Ze.near(r,o)}return t.parent.inlineContent||(a==0?t=r:(t=(Ze.findFrom(t,-o,!0)||Ze.findFrom(t,o,!0)).$anchor,t.pos<r.pos!=a<0&&(t=r))),new Ge(t,r)}}Ze.jsonID("text",Ge);class af{constructor(t,r){this.anchor=t,this.head=r}map(t){return new af(t.map(this.anchor),t.map(this.head))}resolve(t){return Ge.between(t.resolve(this.anchor),t.resolve(this.head))}}class Pe extends Ze{constructor(t){let r=t.nodeAfter,o=t.node(0).resolve(t.pos+r.nodeSize);super(t,o),this.node=r}map(t,r){let{deleted:o,pos:a}=r.mapResult(this.anchor),i=t.resolve(a);return o?Ze.near(i):new Pe(i)}content(){return new Ee(fe.from(this.node),0,0)}eq(t){return t instanceof Pe&&t.anchor==this.anchor}toJSON(){return{type:"node",anchor:this.anchor}}getBookmark(){return new Qh(this.anchor)}static fromJSON(t,r){if(typeof r.anchor!="number")throw new RangeError("Invalid input for NodeSelection.fromJSON");return new Pe(t.resolve(r.anchor))}static create(t,r){return new Pe(t.resolve(r))}static isSelectable(t){return!t.isText&&t.type.spec.selectable!==!1}}Pe.prototype.visible=!1;Ze.jsonID("node",Pe);class Qh{constructor(t){this.anchor=t}map(t){let{deleted:r,pos:o}=t.mapResult(this.anchor);return r?new af(o,o):new Qh(o)}resolve(t){let r=t.resolve(this.anchor),o=r.nodeAfter;return o&&Pe.isSelectable(o)?new Pe(r):Ze.near(r)}}class _r extends Ze{constructor(t){super(t.resolve(0),t.resolve(t.content.size))}replace(t,r=Ee.empty){if(r==Ee.empty){t.delete(0,t.doc.content.size);let o=Ze.atStart(t.doc);o.eq(t.selection)||t.setSelection(o)}else super.replace(t,r)}toJSON(){return{type:"all"}}static fromJSON(t){return new _r(t)}map(t){return new _r(t)}eq(t){return t instanceof _r}getBookmark(){return pge}}Ze.jsonID("all",_r);const pge={map(){return this},resolve(e){return new _r(e)}};function hi(e,t,r,o,a,i=!1){if(t.inlineContent)return Ge.create(e,r);for(let l=o-(a>0?0:1);a>0?l<t.childCount:l>=0;l+=a){let s=t.child(l);if(s.isAtom){if(!i&&Pe.isSelectable(s))return Pe.create(e,r-(a<0?s.nodeSize:0))}else{let c=hi(e,s,r+a,a<0?s.childCount:0,a,i);if(c)return c}r+=s.nodeSize*a}return null}function G4(e,t,r){let o=e.steps.length-1;if(o<t)return;let a=e.steps[o];if(!(a instanceof Kt||a instanceof Zt))return;let i=e.mapping.maps[o],l;i.forEach((s,c,u,d)=>{l==null&&(l=d)}),e.setSelection(Ze.near(e.doc.resolve(l),r))}const K4=1,Cc=2,J4=4;class mge extends ow{constructor(t){super(t.doc),this.curSelectionFor=0,this.updated=0,this.meta=Object.create(null),this.time=Date.now(),this.curSelection=t.selection,this.storedMarks=t.storedMarks}get selection(){return this.curSelectionFor<this.steps.length&&(this.curSelection=this.curSelection.map(this.doc,this.mapping.slice(this.curSelectionFor)),this.curSelectionFor=this.steps.length),this.curSelection}setSelection(t){if(t.$from.doc!=this.doc)throw new RangeError("Selection passed to setSelection must point at the current document");return this.curSelection=t,this.curSelectionFor=this.steps.length,this.updated=(this.updated|K4)&~Cc,this.storedMarks=null,this}get selectionSet(){return(this.updated&K4)>0}setStoredMarks(t){return this.storedMarks=t,this.updated|=Cc,this}ensureMarks(t){return gt.sameSet(this.storedMarks||this.selection.$from.marks(),t)||this.setStoredMarks(t),this}addStoredMark(t){return this.ensureMarks(t.addToSet(this.storedMarks||this.selection.$head.marks()))}removeStoredMark(t){return this.ensureMarks(t.removeFromSet(this.storedMarks||this.selection.$head.marks()))}get storedMarksSet(){return(this.updated&Cc)>0}addStep(t,r){super.addStep(t,r),this.updated=this.updated&~Cc,this.storedMarks=null}setTime(t){return this.time=t,this}replaceSelection(t){return this.selection.replace(this,t),this}replaceSelectionWith(t,r=!0){let o=this.selection;return r&&(t=t.mark(this.storedMarks||(o.empty?o.$from.marks():o.$from.marksAcross(o.$to)||gt.none))),o.replaceWith(this,t),this}deleteSelection(){return this.selection.replace(this),this}insertText(t,r,o){let a=this.doc.type.schema;if(r==null)return t?this.replaceSelectionWith(a.text(t),!0):this.deleteSelection();{if(o==null&&(o=r),o=o??r,!t)return this.deleteRange(r,o);let i=this.storedMarks;if(!i){let l=this.doc.resolve(r);i=o==r?l.marks():l.marksAcross(this.doc.resolve(o))}return this.replaceRangeWith(r,o,a.text(t,i)),this.selection.empty||this.setSelection(Ze.near(this.selection.$to)),this}}setMeta(t,r){return this.meta[typeof t=="string"?t:t.key]=r,this}getMeta(t){return this.meta[typeof t=="string"?t:t.key]}get isGeneric(){for(let t in this.meta)return!1;return!0}scrollIntoView(){return this.updated|=J4,this}get scrolledIntoView(){return(this.updated&J4)>0}}function Z4(e,t){return!t||!e?e:e.bind(t)}class jl{constructor(t,r,o){this.name=t,this.init=Z4(r.init,o),this.apply=Z4(r.apply,o)}}const hge=[new jl("doc",{init(e){return e.doc||e.schema.topNodeType.createAndFill()},apply(e){return e.doc}}),new jl("selection",{init(e,t){return e.selection||Ze.atStart(t.doc)},apply(e){return e.selection}}),new jl("storedMarks",{init(e){return e.storedMarks||null},apply(e,t,r,o){return o.selection.$cursor?e.storedMarks:null}}),new jl("scrollToSelection",{init(){return 0},apply(e,t){return e.scrolledIntoView?t+1:t}})];class Xf{constructor(t,r){this.schema=t,this.plugins=[],this.pluginsByKey=Object.create(null),this.fields=hge.slice(),r&&r.forEach(o=>{if(this.pluginsByKey[o.key])throw new RangeError("Adding different instances of a keyed plugin ("+o.key+")");this.plugins.push(o),this.pluginsByKey[o.key]=o,o.spec.state&&this.fields.push(new jl(o.key,o.spec.state,o))})}}class wi{constructor(t){this.config=t}get schema(){return this.config.schema}get plugins(){return this.config.plugins}apply(t){return this.applyTransaction(t).state}filterTransaction(t,r=-1){for(let o=0;o<this.config.plugins.length;o++)if(o!=r){let a=this.config.plugins[o];if(a.spec.filterTransaction&&!a.spec.filterTransaction.call(a,t,this))return!1}return!0}applyTransaction(t){if(!this.filterTransaction(t))return{state:this,transactions:[]};let r=[t],o=this.applyInner(t),a=null;for(;;){let i=!1;for(let l=0;l<this.config.plugins.length;l++){let s=this.config.plugins[l];if(s.spec.appendTransaction){let c=a?a[l].n:0,u=a?a[l].state:this,d=c<r.length&&s.spec.appendTransaction.call(s,c?r.slice(c):r,u,o);if(d&&o.filterTransaction(d,l)){if(d.setMeta("appendedTransaction",t),!a){a=[];for(let f=0;f<this.config.plugins.length;f++)a.push(f<l?{state:o,n:r.length}:{state:this,n:0})}r.push(d),o=o.applyInner(d),i=!0}a&&(a[l]={state:o,n:r.length})}}if(!i)return{state:o,transactions:r}}}applyInner(t){if(!t.before.eq(this.doc))throw new RangeError("Applying a mismatched transaction");let r=new wi(this.config),o=this.config.fields;for(let a=0;a<o.length;a++){let i=o[a];r[i.name]=i.apply(t,this[i.name],this,r)}return r}get tr(){return new mge(this)}static create(t){let r=new Xf(t.doc?t.doc.type.schema:t.schema,t.plugins),o=new wi(r);for(let a=0;a<r.fields.length;a++)o[r.fields[a].name]=r.fields[a].init(t,o);return o}reconfigure(t){let r=new Xf(this.schema,t.plugins),o=r.fields,a=new wi(r);for(let i=0;i<o.length;i++){let l=o[i].name;a[l]=this.hasOwnProperty(l)?this[l]:o[i].init(t,a)}return a}toJSON(t){let r={doc:this.doc.toJSON(),selection:this.selection.toJSON()};if(this.storedMarks&&(r.storedMarks=this.storedMarks.map(o=>o.toJSON())),t&&typeof t=="object")for(let o in t){if(o=="doc"||o=="selection")throw new RangeError("The JSON fields `doc` and `selection` are reserved");let a=t[o],i=a.spec.state;i&&i.toJSON&&(r[o]=i.toJSON.call(a,this[a.key]))}return r}static fromJSON(t,r,o){if(!r)throw new RangeError("Invalid input for EditorState.fromJSON");if(!t.schema)throw new RangeError("Required config field 'schema' missing");let a=new Xf(t.schema,t.plugins),i=new wi(a);return a.fields.forEach(l=>{if(l.name=="doc")i.doc=Ia.fromJSON(t.schema,r.doc);else if(l.name=="selection")i.selection=Ze.fromJSON(i.doc,r.selection);else if(l.name=="storedMarks")r.storedMarks&&(i.storedMarks=r.storedMarks.map(t.schema.markFromJSON));else{if(o)for(let s in o){let c=o[s],u=c.spec.state;if(c.key==l.name&&u&&u.fromJSON&&Object.prototype.hasOwnProperty.call(r,s)){i[l.name]=u.fromJSON.call(c,t,r[s],i);return}}i[l.name]=l.init(t,i)}}),i}}function aw(e,t,r){for(let o in e){let a=e[o];a instanceof Function?a=a.bind(t):o=="handleDOMEvents"&&(a=aw(a,t,{})),r[o]=a}return r}let tn=class{constructor(t){this.spec=t,this.props={},t.props&&aw(t.props,this,this.props),this.key=t.key?t.key.key:iw("plugin")}getState(t){return t[this.key]}};const ep=Object.create(null);function iw(e){return e in ep?e+"$"+ ++ep[e]:(ep[e]=0,e+"$")}class yn{constructor(t="key"){this.key=iw(t)}get(t){return t.config.pluginsByKey[this.key]}getState(t){return t[this.key]}}const rn=function(e){for(var t=0;;t++)if(e=e.previousSibling,!e)return t},Cs=function(e){let t=e.assignedSlot||e.parentNode;return t&&t.nodeType==11?t.host:t};let E0=null;const fo=function(e,t,r){let o=E0||(E0=document.createRange());return o.setEnd(e,r??e.nodeValue.length),o.setStart(e,t||0),o},gge=function(){E0=null},Ra=function(e,t,r,o){return r&&(X4(e,t,r,o,-1)||X4(e,t,r,o,1))},vge=/^(img|br|input|textarea|hr)$/i;function X4(e,t,r,o,a){for(;;){if(e==r&&t==o)return!0;if(t==(a<0?0:nr(e))){let i=e.parentNode;if(!i||i.nodeType!=1||Js(e)||vge.test(e.nodeName)||e.contentEditable=="false")return!1;t=rn(e)+(a<0?0:1),e=i}else if(e.nodeType==1){if(e=e.childNodes[t+(a<0?-1:0)],e.contentEditable=="false")return!1;t=a<0?nr(e):0}else return!1}}function nr(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function yge(e,t){for(;;){if(e.nodeType==3&&t)return e;if(e.nodeType==1&&t>0){if(e.contentEditable=="false")return null;e=e.childNodes[t-1],t=nr(e)}else if(e.parentNode&&!Js(e))t=rn(e),e=e.parentNode;else return null}}function Mge(e,t){for(;;){if(e.nodeType==3&&t<e.nodeValue.length)return e;if(e.nodeType==1&&t<e.childNodes.length){if(e.contentEditable=="false")return null;e=e.childNodes[t],t=0}else if(e.parentNode&&!Js(e))t=rn(e)+1,e=e.parentNode;else return null}}function bge(e,t,r){for(let o=t==0,a=t==nr(e);o||a;){if(e==r)return!0;let i=rn(e);if(e=e.parentNode,!e)return!1;o=o&&i==0,a=a&&i==nr(e)}}function Js(e){let t;for(let r=e;r&&!(t=r.pmViewDesc);r=r.parentNode);return t&&t.node&&t.node.isBlock&&(t.dom==e||t.contentDOM==e)}const lf=function(e){return e.focusNode&&Ra(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)};function Ma(e,t){let r=document.createEvent("Event");return r.initEvent("keydown",!0,!0),r.keyCode=e,r.key=r.code=t,r}function wge(e){let t=e.activeElement;for(;t&&t.shadowRoot;)t=t.shadowRoot.activeElement;return t}function Nge(e,t,r){if(e.caretPositionFromPoint)try{let o=e.caretPositionFromPoint(t,r);if(o)return{node:o.offsetNode,offset:Math.min(nr(o.offsetNode),o.offset)}}catch{}if(e.caretRangeFromPoint){let o=e.caretRangeFromPoint(t,r);if(o)return{node:o.startContainer,offset:Math.min(nr(o.startContainer),o.startOffset)}}}const ro=typeof navigator<"u"?navigator:null,ev=typeof document<"u"?document:null,sa=ro&&ro.userAgent||"",T0=/Edge\/(\d+)/.exec(sa),lw=/MSIE \d/.exec(sa),D0=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(sa),An=!!(lw||D0||T0),Ko=lw?document.documentMode:D0?+D0[1]:T0?+T0[1]:0,Or=!An&&/gecko\/(\d+)/i.test(sa);Or&&+(/Firefox\/(\d+)/.exec(sa)||[0,0])[1];const S0=!An&&/Chrome\/(\d+)/.exec(sa),fn=!!S0,sw=S0?+S0[1]:0,bn=!An&&!!ro&&/Apple Computer/.test(ro.vendor),qi=bn&&(/Mobile\/\w+/.test(sa)||!!ro&&ro.maxTouchPoints>2),tr=qi||(ro?/Mac/.test(ro.platform):!1),kge=ro?/Win/.test(ro.platform):!1,Er=/Android \d/.test(sa),Zs=!!ev&&"webkitFontSmoothing"in ev.documentElement.style,xge=Zs?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;function Cge(e){let t=e.defaultView&&e.defaultView.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.documentElement.clientWidth,top:0,bottom:e.documentElement.clientHeight}}function co(e,t){return typeof e=="number"?e:e[t]}function Ege(e){let t=e.getBoundingClientRect(),r=t.width/e.offsetWidth||1,o=t.height/e.offsetHeight||1;return{left:t.left,right:t.left+e.clientWidth*r,top:t.top,bottom:t.top+e.clientHeight*o}}function tv(e,t,r){let o=e.someProp("scrollThreshold")||0,a=e.someProp("scrollMargin")||5,i=e.dom.ownerDocument;for(let l=r||e.dom;l;l=Cs(l)){if(l.nodeType!=1)continue;let s=l,c=s==i.body,u=c?Cge(i):Ege(s),d=0,f=0;if(t.top<u.top+co(o,"top")?f=-(u.top-t.top+co(a,"top")):t.bottom>u.bottom-co(o,"bottom")&&(f=t.bottom-t.top>u.bottom-u.top?t.top+co(a,"top")-u.top:t.bottom-u.bottom+co(a,"bottom")),t.left<u.left+co(o,"left")?d=-(u.left-t.left+co(a,"left")):t.right>u.right-co(o,"right")&&(d=t.right-u.right+co(a,"right")),d||f)if(c)i.defaultView.scrollBy(d,f);else{let p=s.scrollLeft,h=s.scrollTop;f&&(s.scrollTop+=f),d&&(s.scrollLeft+=d);let m=s.scrollLeft-p,g=s.scrollTop-h;t={left:t.left-m,top:t.top-g,right:t.right-m,bottom:t.bottom-g}}if(c||/^(fixed|sticky)$/.test(getComputedStyle(l).position))break}}function Tge(e){let t=e.dom.getBoundingClientRect(),r=Math.max(0,t.top),o,a;for(let i=(t.left+t.right)/2,l=r+1;l<Math.min(innerHeight,t.bottom);l+=5){let s=e.root.elementFromPoint(i,l);if(!s||s==e.dom||!e.dom.contains(s))continue;let c=s.getBoundingClientRect();if(c.top>=r-20){o=s,a=c.top;break}}return{refDOM:o,refTop:a,stack:cw(e.dom)}}function cw(e){let t=[],r=e.ownerDocument;for(let o=e;o&&(t.push({dom:o,top:o.scrollTop,left:o.scrollLeft}),e!=r);o=Cs(o));return t}function Dge({refDOM:e,refTop:t,stack:r}){let o=e?e.getBoundingClientRect().top:0;uw(r,o==0?0:o-t)}function uw(e,t){for(let r=0;r<e.length;r++){let{dom:o,top:a,left:i}=e[r];o.scrollTop!=a+t&&(o.scrollTop=a+t),o.scrollLeft!=i&&(o.scrollLeft=i)}}let ci=null;function Sge(e){if(e.setActive)return e.setActive();if(ci)return e.focus(ci);let t=cw(e);e.focus(ci==null?{get preventScroll(){return ci={preventScroll:!0},!0}}:void 0),ci||(ci=!1,uw(t,0))}function dw(e,t){let r,o=2e8,a,i=0,l=t.top,s=t.top,c,u;for(let d=e.firstChild,f=0;d;d=d.nextSibling,f++){let p;if(d.nodeType==1)p=d.getClientRects();else if(d.nodeType==3)p=fo(d).getClientRects();else continue;for(let h=0;h<p.length;h++){let m=p[h];if(m.top<=l&&m.bottom>=s){l=Math.max(m.bottom,l),s=Math.min(m.top,s);let g=m.left>t.left?m.left-t.left:m.right<t.left?t.left-m.right:0;if(g<o){r=d,o=g,a=g&&r.nodeType==3?{left:m.right<t.left?m.right:m.left,top:t.top}:t,d.nodeType==1&&g&&(i=f+(t.left>=(m.left+m.right)/2?1:0));continue}}else m.top>t.top&&!c&&m.left<=t.left&&m.right>=t.left&&(c=d,u={left:Math.max(m.left,Math.min(m.right,t.left)),top:m.top});!r&&(t.left>=m.right&&t.top>=m.top||t.left>=m.left&&t.top>=m.bottom)&&(i=f+1)}}return!r&&c&&(r=c,a=u,o=0),r&&r.nodeType==3?_ge(r,a):!r||o&&r.nodeType==1?{node:e,offset:i}:dw(r,a)}function _ge(e,t){let r=e.nodeValue.length,o=document.createRange();for(let a=0;a<r;a++){o.setEnd(e,a+1),o.setStart(e,a);let i=Ao(o,1);if(i.top!=i.bottom&&Wh(t,i))return{node:e,offset:a+(t.left>=(i.left+i.right)/2?1:0)}}return{node:e,offset:0}}function Wh(e,t){return e.left>=t.left-1&&e.left<=t.right+1&&e.top>=t.top-1&&e.top<=t.bottom+1}function Ige(e,t){let r=e.parentNode;return r&&/^li$/i.test(r.nodeName)&&t.left<e.getBoundingClientRect().left?r:e}function Age(e,t,r){let{node:o,offset:a}=dw(t,r),i=-1;if(o.nodeType==1&&!o.firstChild){let l=o.getBoundingClientRect();i=l.left!=l.right&&r.left>(l.left+l.right)/2?1:-1}return e.docView.posFromDOM(o,a,i)}function Oge(e,t,r,o){let a=-1;for(let i=t,l=!1;i!=e.dom;){let s=e.docView.nearestDesc(i,!0);if(!s)return null;if(s.dom.nodeType==1&&(s.node.isBlock&&s.parent||!s.contentDOM)){let c=s.dom.getBoundingClientRect();if(s.node.isBlock&&s.parent&&(!l&&c.left>o.left||c.top>o.top?a=s.posBefore:(!l&&c.right<o.left||c.bottom<o.top)&&(a=s.posAfter),l=!0),!s.contentDOM&&a<0&&!s.node.isText)return(s.node.isBlock?o.top<(c.top+c.bottom)/2:o.left<(c.left+c.right)/2)?s.posBefore:s.posAfter}i=s.dom.parentNode}return a>-1?a:e.docView.posFromDOM(t,r,-1)}function fw(e,t,r){let o=e.childNodes.length;if(o&&r.top<r.bottom)for(let a=Math.max(0,Math.min(o-1,Math.floor(o*(t.top-r.top)/(r.bottom-r.top))-2)),i=a;;){let l=e.childNodes[i];if(l.nodeType==1){let s=l.getClientRects();for(let c=0;c<s.length;c++){let u=s[c];if(Wh(t,u))return fw(l,t,u)}}if((i=(i+1)%o)==a)break}return e}function zge(e,t){let r=e.dom.ownerDocument,o,a=0,i=Nge(r,t.left,t.top);i&&({node:o,offset:a}=i);let l=(e.root.elementFromPoint?e.root:r).elementFromPoint(t.left,t.top),s;if(!l||!e.dom.contains(l.nodeType!=1?l.parentNode:l)){let u=e.dom.getBoundingClientRect();if(!Wh(t,u)||(l=fw(e.dom,t,u),!l))return null}if(bn)for(let u=l;o&&u;u=Cs(u))u.draggable&&(o=void 0);if(l=Ige(l,t),o){if(Or&&o.nodeType==1&&(a=Math.min(a,o.childNodes.length),a<o.childNodes.length)){let d=o.childNodes[a],f;d.nodeName=="IMG"&&(f=d.getBoundingClientRect()).right<=t.left&&f.bottom>t.top&&a++}let u;Zs&&a&&o.nodeType==1&&(u=o.childNodes[a-1]).nodeType==1&&u.contentEditable=="false"&&u.getBoundingClientRect().top>=t.top&&a--,o==e.dom&&a==o.childNodes.length-1&&o.lastChild.nodeType==1&&t.top>o.lastChild.getBoundingClientRect().bottom?s=e.state.doc.content.size:(a==0||o.nodeType!=1||o.childNodes[a-1].nodeName!="BR")&&(s=Oge(e,o,a,t))}s==null&&(s=Age(e,l,t));let c=e.docView.nearestDesc(l,!0);return{pos:s,inside:c?c.posAtStart-c.border:-1}}function nv(e){return e.top<e.bottom||e.left<e.right}function Ao(e,t){let r=e.getClientRects();if(r.length){let o=r[t<0?0:r.length-1];if(nv(o))return o}return Array.prototype.find.call(r,nv)||e.getBoundingClientRect()}const jge=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;function pw(e,t,r){let{node:o,offset:a,atom:i}=e.docView.domFromPos(t,r<0?-1:1),l=Zs||Or;if(o.nodeType==3)if(l&&(jge.test(o.nodeValue)||(r<0?!a:a==o.nodeValue.length))){let c=Ao(fo(o,a,a),r);if(Or&&a&&/\s/.test(o.nodeValue[a-1])&&a<o.nodeValue.length){let u=Ao(fo(o,a-1,a-1),-1);if(u.top==c.top){let d=Ao(fo(o,a,a+1),-1);if(d.top!=c.top)return El(d,d.left<u.left)}}return c}else{let c=a,u=a,d=r<0?1:-1;return r<0&&!a?(u++,d=-1):r>=0&&a==o.nodeValue.length?(c--,d=1):r<0?c--:u++,El(Ao(fo(o,c,u),d),d<0)}if(!e.state.doc.resolve(t-(i||0)).parent.inlineContent){if(i==null&&a&&(r<0||a==nr(o))){let c=o.childNodes[a-1];if(c.nodeType==1)return tp(c.getBoundingClientRect(),!1)}if(i==null&&a<nr(o)){let c=o.childNodes[a];if(c.nodeType==1)return tp(c.getBoundingClientRect(),!0)}return tp(o.getBoundingClientRect(),r>=0)}if(i==null&&a&&(r<0||a==nr(o))){let c=o.childNodes[a-1],u=c.nodeType==3?fo(c,nr(c)-(l?0:1)):c.nodeType==1&&(c.nodeName!="BR"||!c.nextSibling)?c:null;if(u)return El(Ao(u,1),!1)}if(i==null&&a<nr(o)){let c=o.childNodes[a];for(;c.pmViewDesc&&c.pmViewDesc.ignoreForCoords;)c=c.nextSibling;let u=c?c.nodeType==3?fo(c,0,l?0:1):c.nodeType==1?c:null:null;if(u)return El(Ao(u,-1),!0)}return El(Ao(o.nodeType==3?fo(o):o,-r),r>=0)}function El(e,t){if(e.width==0)return e;let r=t?e.left:e.right;return{top:e.top,bottom:e.bottom,left:r,right:r}}function tp(e,t){if(e.height==0)return e;let r=t?e.top:e.bottom;return{top:r,bottom:r,left:e.left,right:e.right}}function mw(e,t,r){let o=e.state,a=e.root.activeElement;o!=t&&e.updateState(t),a!=e.dom&&e.focus();try{return r()}finally{o!=t&&e.updateState(o),a!=e.dom&&a&&a.focus()}}function Lge(e,t,r){let o=t.selection,a=r=="up"?o.$from:o.$to;return mw(e,t,()=>{let{node:i}=e.docView.domFromPos(a.pos,r=="up"?-1:1);for(;;){let s=e.docView.nearestDesc(i,!0);if(!s)break;if(s.node.isBlock){i=s.contentDOM||s.dom;break}i=s.dom.parentNode}let l=pw(e,a.pos,1);for(let s=i.firstChild;s;s=s.nextSibling){let c;if(s.nodeType==1)c=s.getClientRects();else if(s.nodeType==3)c=fo(s,0,s.nodeValue.length).getClientRects();else continue;for(let u=0;u<c.length;u++){let d=c[u];if(d.bottom>d.top+1&&(r=="up"?l.top-d.top>(d.bottom-l.top)*2:d.bottom-l.bottom>(l.bottom-d.top)*2))return!1}}return!0})}const Bge=/[\u0590-\u08ac]/;function Vge(e,t,r){let{$head:o}=t.selection;if(!o.parent.isTextblock)return!1;let a=o.parentOffset,i=!a,l=a==o.parent.content.size,s=e.domSelection();return s?!Bge.test(o.parent.textContent)||!s.modify?r=="left"||r=="backward"?i:l:mw(e,t,()=>{let{focusNode:c,focusOffset:u,anchorNode:d,anchorOffset:f}=e.domSelectionRange(),p=s.caretBidiLevel;s.modify("move",r,"character");let h=o.depth?e.docView.domAfterPos(o.before()):e.dom,{focusNode:m,focusOffset:g}=e.domSelectionRange(),v=m&&!h.contains(m.nodeType==1?m:m.parentNode)||c==m&&u==g;try{s.collapse(d,f),c&&(c!=d||u!=f)&&s.extend&&s.extend(c,u)}catch{}return p!=null&&(s.caretBidiLevel=p),v}):o.pos==o.start()||o.pos==o.end()}let rv=null,ov=null,av=!1;function $ge(e,t,r){return rv==t&&ov==r?av:(rv=t,ov=r,av=r=="up"||r=="down"?Lge(e,t,r):Vge(e,t,r))}const ar=0,iv=1,Ca=2,oo=3;class Xs{constructor(t,r,o,a){this.parent=t,this.children=r,this.dom=o,this.contentDOM=a,this.dirty=ar,o.pmViewDesc=this}matchesWidget(t){return!1}matchesMark(t){return!1}matchesNode(t,r,o){return!1}matchesHack(t){return!1}parseRule(){return null}stopEvent(t){return!1}get size(){let t=0;for(let r=0;r<this.children.length;r++)t+=this.children[r].size;return t}get border(){return 0}destroy(){this.parent=void 0,this.dom.pmViewDesc==this&&(this.dom.pmViewDesc=void 0);for(let t=0;t<this.children.length;t++)this.children[t].destroy()}posBeforeChild(t){for(let r=0,o=this.posAtStart;;r++){let a=this.children[r];if(a==t)return o;o+=a.size}}get posBefore(){return this.parent.posBeforeChild(this)}get posAtStart(){return this.parent?this.parent.posBeforeChild(this)+this.border:0}get posAfter(){return this.posBefore+this.size}get posAtEnd(){return this.posAtStart+this.size-2*this.border}localPosFromDOM(t,r,o){if(this.contentDOM&&this.contentDOM.contains(t.nodeType==1?t:t.parentNode))if(o<0){let i,l;if(t==this.contentDOM)i=t.childNodes[r-1];else{for(;t.parentNode!=this.contentDOM;)t=t.parentNode;i=t.previousSibling}for(;i&&!((l=i.pmViewDesc)&&l.parent==this);)i=i.previousSibling;return i?this.posBeforeChild(l)+l.size:this.posAtStart}else{let i,l;if(t==this.contentDOM)i=t.childNodes[r];else{for(;t.parentNode!=this.contentDOM;)t=t.parentNode;i=t.nextSibling}for(;i&&!((l=i.pmViewDesc)&&l.parent==this);)i=i.nextSibling;return i?this.posBeforeChild(l):this.posAtEnd}let a;if(t==this.dom&&this.contentDOM)a=r>rn(this.contentDOM);else if(this.contentDOM&&this.contentDOM!=this.dom&&this.dom.contains(this.contentDOM))a=t.compareDocumentPosition(this.contentDOM)&2;else if(this.dom.firstChild){if(r==0)for(let i=t;;i=i.parentNode){if(i==this.dom){a=!1;break}if(i.previousSibling)break}if(a==null&&r==t.childNodes.length)for(let i=t;;i=i.parentNode){if(i==this.dom){a=!0;break}if(i.nextSibling)break}}return a??o>0?this.posAtEnd:this.posAtStart}nearestDesc(t,r=!1){for(let o=!0,a=t;a;a=a.parentNode){let i=this.getDesc(a),l;if(i&&(!r||i.node))if(o&&(l=i.nodeDOM)&&!(l.nodeType==1?l.contains(t.nodeType==1?t:t.parentNode):l==t))o=!1;else return i}}getDesc(t){let r=t.pmViewDesc;for(let o=r;o;o=o.parent)if(o==this)return r}posFromDOM(t,r,o){for(let a=t;a;a=a.parentNode){let i=this.getDesc(a);if(i)return i.localPosFromDOM(t,r,o)}return-1}descAt(t){for(let r=0,o=0;r<this.children.length;r++){let a=this.children[r],i=o+a.size;if(o==t&&i!=o){for(;!a.border&&a.children.length;)a=a.children[0];return a}if(t<i)return a.descAt(t-o-a.border);o=i}}domFromPos(t,r){if(!this.contentDOM)return{node:this.dom,offset:0,atom:t+1};let o=0,a=0;for(let i=0;o<this.children.length;o++){let l=this.children[o],s=i+l.size;if(s>t||l instanceof gw){a=t-i;break}i=s}if(a)return this.children[o].domFromPos(a-this.children[o].border,r);for(let i;o&&!(i=this.children[o-1]).size&&i instanceof hw&&i.side>=0;o--);if(r<=0){let i,l=!0;for(;i=o?this.children[o-1]:null,!(!i||i.dom.parentNode==this.contentDOM);o--,l=!1);return i&&r&&l&&!i.border&&!i.domAtom?i.domFromPos(i.size,r):{node:this.contentDOM,offset:i?rn(i.dom)+1:0}}else{let i,l=!0;for(;i=o<this.children.length?this.children[o]:null,!(!i||i.dom.parentNode==this.contentDOM);o++,l=!1);return i&&l&&!i.border&&!i.domAtom?i.domFromPos(0,r):{node:this.contentDOM,offset:i?rn(i.dom):this.contentDOM.childNodes.length}}}parseRange(t,r,o=0){if(this.children.length==0)return{node:this.contentDOM,from:t,to:r,fromOffset:0,toOffset:this.contentDOM.childNodes.length};let a=-1,i=-1;for(let l=o,s=0;;s++){let c=this.children[s],u=l+c.size;if(a==-1&&t<=u){let d=l+c.border;if(t>=d&&r<=u-c.border&&c.node&&c.contentDOM&&this.contentDOM.contains(c.contentDOM))return c.parseRange(t,r,d);t=l;for(let f=s;f>0;f--){let p=this.children[f-1];if(p.size&&p.dom.parentNode==this.contentDOM&&!p.emptyChildAt(1)){a=rn(p.dom)+1;break}t-=p.size}a==-1&&(a=0)}if(a>-1&&(u>r||s==this.children.length-1)){r=u;for(let d=s+1;d<this.children.length;d++){let f=this.children[d];if(f.size&&f.dom.parentNode==this.contentDOM&&!f.emptyChildAt(-1)){i=rn(f.dom);break}r+=f.size}i==-1&&(i=this.contentDOM.childNodes.length);break}l=u}return{node:this.contentDOM,from:t,to:r,fromOffset:a,toOffset:i}}emptyChildAt(t){if(this.border||!this.contentDOM||!this.children.length)return!1;let r=this.children[t<0?0:this.children.length-1];return r.size==0||r.emptyChildAt(t)}domAfterPos(t){let{node:r,offset:o}=this.domFromPos(t,0);if(r.nodeType!=1||o==r.childNodes.length)throw new RangeError("No node after pos "+t);return r.childNodes[o]}setSelection(t,r,o,a=!1){let i=Math.min(t,r),l=Math.max(t,r);for(let p=0,h=0;p<this.children.length;p++){let m=this.children[p],g=h+m.size;if(i>h&&l<g)return m.setSelection(t-h-m.border,r-h-m.border,o,a);h=g}let s=this.domFromPos(t,t?-1:1),c=r==t?s:this.domFromPos(r,r?-1:1),u=o.getSelection(),d=!1;if((Or||bn)&&t==r){let{node:p,offset:h}=s;if(p.nodeType==3){if(d=!!(h&&p.nodeValue[h-1]==`
|
|
52
|
-
`),d&&h==p.nodeValue.length)for(let m=p,g;m;m=m.parentNode){if(g=m.nextSibling){g.nodeName=="BR"&&(s=c={node:g.parentNode,offset:rn(g)+1});break}let v=m.pmViewDesc;if(v&&v.node&&v.node.isBlock)break}}else{let m=p.childNodes[h-1];d=m&&(m.nodeName=="BR"||m.contentEditable=="false")}}if(Or&&u.focusNode&&u.focusNode!=c.node&&u.focusNode.nodeType==1){let p=u.focusNode.childNodes[u.focusOffset];p&&p.contentEditable=="false"&&(a=!0)}if(!(a||d&&bn)&&Ra(s.node,s.offset,u.anchorNode,u.anchorOffset)&&Ra(c.node,c.offset,u.focusNode,u.focusOffset))return;let f=!1;if((u.extend||t==r)&&!d){u.collapse(s.node,s.offset);try{t!=r&&u.extend(c.node,c.offset),f=!0}catch{}}if(!f){if(t>r){let h=s;s=c,c=h}let p=document.createRange();p.setEnd(c.node,c.offset),p.setStart(s.node,s.offset),u.removeAllRanges(),u.addRange(p)}}ignoreMutation(t){return!this.contentDOM&&t.type!="selection"}get contentLost(){return this.contentDOM&&this.contentDOM!=this.dom&&!this.dom.contains(this.contentDOM)}markDirty(t,r){for(let o=0,a=0;a<this.children.length;a++){let i=this.children[a],l=o+i.size;if(o==l?t<=l&&r>=o:t<l&&r>o){let s=o+i.border,c=l-i.border;if(t>=s&&r<=c){this.dirty=t==o||r==l?Ca:iv,t==s&&r==c&&(i.contentLost||i.dom.parentNode!=this.contentDOM)?i.dirty=oo:i.markDirty(t-s,r-s);return}else i.dirty=i.dom==i.contentDOM&&i.dom.parentNode==this.contentDOM&&!i.children.length?Ca:oo}o=l}this.dirty=Ca}markParentsDirty(){let t=1;for(let r=this.parent;r;r=r.parent,t++){let o=t==1?Ca:iv;r.dirty<o&&(r.dirty=o)}}get domAtom(){return!1}get ignoreForCoords(){return!1}isText(t){return!1}}class hw extends Xs{constructor(t,r,o,a){let i,l=r.type.toDOM;if(typeof l=="function"&&(l=l(o,()=>{if(!i)return a;if(i.parent)return i.parent.posBeforeChild(i)})),!r.type.spec.raw){if(l.nodeType!=1){let s=document.createElement("span");s.appendChild(l),l=s}l.contentEditable="false",l.classList.add("ProseMirror-widget")}super(t,[],l,null),this.widget=r,this.widget=r,i=this}matchesWidget(t){return this.dirty==ar&&t.type.eq(this.widget.type)}parseRule(){return{ignore:!0}}stopEvent(t){let r=this.widget.spec.stopEvent;return r?r(t):!1}ignoreMutation(t){return t.type!="selection"||this.widget.spec.ignoreSelection}destroy(){this.widget.type.destroy(this.dom),super.destroy()}get domAtom(){return!0}get side(){return this.widget.type.side}}class Pge extends Xs{constructor(t,r,o,a){super(t,[],r,null),this.textDOM=o,this.text=a}get size(){return this.text.length}localPosFromDOM(t,r){return t!=this.textDOM?this.posAtStart+(r?this.size:0):this.posAtStart+r}domFromPos(t){return{node:this.textDOM,offset:t}}ignoreMutation(t){return t.type==="characterData"&&t.target.nodeValue==t.oldValue}}class Fa extends Xs{constructor(t,r,o,a,i){super(t,[],o,a),this.mark=r,this.spec=i}static create(t,r,o,a){let i=a.nodeViews[r.type.name],l=i&&i(r,a,o);return(!l||!l.dom)&&(l=Xa.renderSpec(document,r.type.spec.toDOM(r,o),null,r.attrs)),new Fa(t,r,l.dom,l.contentDOM||l.dom,l)}parseRule(){return this.dirty&oo||this.mark.type.spec.reparseInView?null:{mark:this.mark.type.name,attrs:this.mark.attrs,contentElement:this.contentDOM}}matchesMark(t){return this.dirty!=oo&&this.mark.eq(t)}markDirty(t,r){if(super.markDirty(t,r),this.dirty!=ar){let o=this.parent;for(;!o.node;)o=o.parent;o.dirty<this.dirty&&(o.dirty=this.dirty),this.dirty=ar}}slice(t,r,o){let a=Fa.create(this.parent,this.mark,!0,o),i=this.children,l=this.size;r<l&&(i=I0(i,r,l,o)),t>0&&(i=I0(i,0,t,o));for(let s=0;s<i.length;s++)i[s].parent=a;return a.children=i,a}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}}class Jo extends Xs{constructor(t,r,o,a,i,l,s,c,u){super(t,[],i,l),this.node=r,this.outerDeco=o,this.innerDeco=a,this.nodeDOM=s}static create(t,r,o,a,i,l){let s=i.nodeViews[r.type.name],c,u=s&&s(r,i,()=>{if(!c)return l;if(c.parent)return c.parent.posBeforeChild(c)},o,a),d=u&&u.dom,f=u&&u.contentDOM;if(r.isText){if(!d)d=document.createTextNode(r.text);else if(d.nodeType!=3)throw new RangeError("Text must be rendered as a DOM text node")}else d||({dom:d,contentDOM:f}=Xa.renderSpec(document,r.type.spec.toDOM(r),null,r.attrs));!f&&!r.isText&&d.nodeName!="BR"&&(d.hasAttribute("contenteditable")||(d.contentEditable="false"),r.type.spec.draggable&&(d.draggable=!0));let p=d;return d=Mw(d,o,r),u?c=new Rge(t,r,o,a,d,f||null,p,u,i,l+1):r.isText?new sf(t,r,o,a,d,p,i):new Jo(t,r,o,a,d,f||null,p,i,l+1)}parseRule(){if(this.node.type.spec.reparseInView)return null;let t={node:this.node.type.name,attrs:this.node.attrs};if(this.node.type.whitespace=="pre"&&(t.preserveWhitespace="full"),!this.contentDOM)t.getContent=()=>this.node.content;else if(!this.contentLost)t.contentElement=this.contentDOM;else{for(let r=this.children.length-1;r>=0;r--){let o=this.children[r];if(this.dom.contains(o.dom.parentNode)){t.contentElement=o.dom.parentNode;break}}t.contentElement||(t.getContent=()=>fe.empty)}return t}matchesNode(t,r,o){return this.dirty==ar&&t.eq(this.node)&&zu(r,this.outerDeco)&&o.eq(this.innerDeco)}get size(){return this.node.nodeSize}get border(){return this.node.isLeaf?0:1}updateChildren(t,r){let o=this.node.inlineContent,a=r,i=t.composing?this.localCompositionInfo(t,r):null,l=i&&i.pos>-1?i:null,s=i&&i.pos<0,c=new Uge(this,l&&l.node,t);Qge(this.node,this.innerDeco,(u,d,f)=>{u.spec.marks?c.syncToMarks(u.spec.marks,o,t):u.type.side>=0&&!f&&c.syncToMarks(d==this.node.childCount?gt.none:this.node.child(d).marks,o,t),c.placeWidget(u,t,a)},(u,d,f,p)=>{c.syncToMarks(u.marks,o,t);let h;c.findNodeMatch(u,d,f,p)||s&&t.state.selection.from>a&&t.state.selection.to<a+u.nodeSize&&(h=c.findIndexWithChild(i.node))>-1&&c.updateNodeAt(u,d,f,h,t)||c.updateNextNode(u,d,f,t,p,a)||c.addNode(u,d,f,t,a),a+=u.nodeSize}),c.syncToMarks([],o,t),this.node.isTextblock&&c.addTextblockHacks(),c.destroyRest(),(c.changed||this.dirty==Ca)&&(l&&this.protectLocalComposition(t,l),vw(this.contentDOM,this.children,t),qi&&Wge(this.dom))}localCompositionInfo(t,r){let{from:o,to:a}=t.state.selection;if(!(t.state.selection instanceof Ge)||o<r||a>r+this.node.content.size)return null;let i=t.input.compositionNode;if(!i||!this.dom.contains(i.parentNode))return null;if(this.node.inlineContent){let l=i.nodeValue,s=qge(this.node.content,l,o-r,a-r);return s<0?null:{node:i,pos:s,text:l}}else return{node:i,pos:-1,text:""}}protectLocalComposition(t,{node:r,pos:o,text:a}){if(this.getDesc(r))return;let i=r;for(;i.parentNode!=this.contentDOM;i=i.parentNode){for(;i.previousSibling;)i.parentNode.removeChild(i.previousSibling);for(;i.nextSibling;)i.parentNode.removeChild(i.nextSibling);i.pmViewDesc&&(i.pmViewDesc=void 0)}let l=new Pge(this,i,r,a);t.input.compositionNodes.push(l),this.children=I0(this.children,o,o+a.length,t,l)}update(t,r,o,a){return this.dirty==oo||!t.sameMarkup(this.node)?!1:(this.updateInner(t,r,o,a),!0)}updateInner(t,r,o,a){this.updateOuterDeco(r),this.node=t,this.innerDeco=o,this.contentDOM&&this.updateChildren(a,this.posAtStart),this.dirty=ar}updateOuterDeco(t){if(zu(t,this.outerDeco))return;let r=this.nodeDOM.nodeType!=1,o=this.dom;this.dom=yw(this.dom,this.nodeDOM,_0(this.outerDeco,this.node,r),_0(t,this.node,r)),this.dom!=o&&(o.pmViewDesc=void 0,this.dom.pmViewDesc=this),this.outerDeco=t}selectNode(){this.nodeDOM.nodeType==1&&this.nodeDOM.classList.add("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&(this.dom.draggable=!0)}deselectNode(){this.nodeDOM.nodeType==1&&(this.nodeDOM.classList.remove("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&this.dom.removeAttribute("draggable"))}get domAtom(){return this.node.isAtom}}function lv(e,t,r,o,a){Mw(o,t,e);let i=new Jo(void 0,e,t,r,o,o,o,a,0);return i.contentDOM&&i.updateChildren(a,0),i}class sf extends Jo{constructor(t,r,o,a,i,l,s){super(t,r,o,a,i,null,l,s,0)}parseRule(){let t=this.nodeDOM.parentNode;for(;t&&t!=this.dom&&!t.pmIsDeco;)t=t.parentNode;return{skip:t||!0}}update(t,r,o,a){return this.dirty==oo||this.dirty!=ar&&!this.inParent()||!t.sameMarkup(this.node)?!1:(this.updateOuterDeco(r),(this.dirty!=ar||t.text!=this.node.text)&&t.text!=this.nodeDOM.nodeValue&&(this.nodeDOM.nodeValue=t.text,a.trackWrites==this.nodeDOM&&(a.trackWrites=null)),this.node=t,this.dirty=ar,!0)}inParent(){let t=this.parent.contentDOM;for(let r=this.nodeDOM;r;r=r.parentNode)if(r==t)return!0;return!1}domFromPos(t){return{node:this.nodeDOM,offset:t}}localPosFromDOM(t,r,o){return t==this.nodeDOM?this.posAtStart+Math.min(r,this.node.text.length):super.localPosFromDOM(t,r,o)}ignoreMutation(t){return t.type!="characterData"&&t.type!="selection"}slice(t,r,o){let a=this.node.cut(t,r),i=document.createTextNode(a.text);return new sf(this.parent,a,this.outerDeco,this.innerDeco,i,i,o)}markDirty(t,r){super.markDirty(t,r),this.dom!=this.nodeDOM&&(t==0||r==this.nodeDOM.nodeValue.length)&&(this.dirty=oo)}get domAtom(){return!1}isText(t){return this.node.text==t}}class gw extends Xs{parseRule(){return{ignore:!0}}matchesHack(t){return this.dirty==ar&&this.dom.nodeName==t}get domAtom(){return!0}get ignoreForCoords(){return this.dom.nodeName=="IMG"}}class Rge extends Jo{constructor(t,r,o,a,i,l,s,c,u,d){super(t,r,o,a,i,l,s,u,d),this.spec=c}update(t,r,o,a){if(this.dirty==oo)return!1;if(this.spec.update&&(this.node.type==t.type||this.spec.multiType)){let i=this.spec.update(t,r,o);return i&&this.updateInner(t,r,o,a),i}else return!this.contentDOM&&!t.isLeaf?!1:super.update(t,r,o,a)}selectNode(){this.spec.selectNode?this.spec.selectNode():super.selectNode()}deselectNode(){this.spec.deselectNode?this.spec.deselectNode():super.deselectNode()}setSelection(t,r,o,a){this.spec.setSelection?this.spec.setSelection(t,r,o):super.setSelection(t,r,o,a)}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}stopEvent(t){return this.spec.stopEvent?this.spec.stopEvent(t):!1}ignoreMutation(t){return this.spec.ignoreMutation?this.spec.ignoreMutation(t):super.ignoreMutation(t)}}function vw(e,t,r){let o=e.firstChild,a=!1;for(let i=0;i<t.length;i++){let l=t[i],s=l.dom;if(s.parentNode==e){for(;s!=o;)o=sv(o),a=!0;o=o.nextSibling}else a=!0,e.insertBefore(s,o);if(l instanceof Fa){let c=o?o.previousSibling:e.lastChild;vw(l.contentDOM,l.children,r),o=c?c.nextSibling:e.firstChild}}for(;o;)o=sv(o),a=!0;a&&r.trackWrites==e&&(r.trackWrites=null)}const Ql=function(e){e&&(this.nodeName=e)};Ql.prototype=Object.create(null);const Ea=[new Ql];function _0(e,t,r){if(e.length==0)return Ea;let o=r?Ea[0]:new Ql,a=[o];for(let i=0;i<e.length;i++){let l=e[i].type.attrs;if(l){l.nodeName&&a.push(o=new Ql(l.nodeName));for(let s in l){let c=l[s];c!=null&&(r&&a.length==1&&a.push(o=new Ql(t.isInline?"span":"div")),s=="class"?o.class=(o.class?o.class+" ":"")+c:s=="style"?o.style=(o.style?o.style+";":"")+c:s!="nodeName"&&(o[s]=c))}}}return a}function yw(e,t,r,o){if(r==Ea&&o==Ea)return t;let a=t;for(let i=0;i<o.length;i++){let l=o[i],s=r[i];if(i){let c;s&&s.nodeName==l.nodeName&&a!=e&&(c=a.parentNode)&&c.nodeName.toLowerCase()==l.nodeName||(c=document.createElement(l.nodeName),c.pmIsDeco=!0,c.appendChild(a),s=Ea[0]),a=c}Fge(a,s||Ea[0],l)}return a}function Fge(e,t,r){for(let o in t)o!="class"&&o!="style"&&o!="nodeName"&&!(o in r)&&e.removeAttribute(o);for(let o in r)o!="class"&&o!="style"&&o!="nodeName"&&r[o]!=t[o]&&e.setAttribute(o,r[o]);if(t.class!=r.class){let o=t.class?t.class.split(" ").filter(Boolean):[],a=r.class?r.class.split(" ").filter(Boolean):[];for(let i=0;i<o.length;i++)a.indexOf(o[i])==-1&&e.classList.remove(o[i]);for(let i=0;i<a.length;i++)o.indexOf(a[i])==-1&&e.classList.add(a[i]);e.classList.length==0&&e.removeAttribute("class")}if(t.style!=r.style){if(t.style){let o=/\s*([\w\-\xa1-\uffff]+)\s*:(?:"(?:\\.|[^"])*"|'(?:\\.|[^'])*'|\(.*?\)|[^;])*/g,a;for(;a=o.exec(t.style);)e.style.removeProperty(a[1])}r.style&&(e.style.cssText+=r.style)}}function Mw(e,t,r){return yw(e,e,Ea,_0(t,r,e.nodeType!=1))}function zu(e,t){if(e.length!=t.length)return!1;for(let r=0;r<e.length;r++)if(!e[r].type.eq(t[r].type))return!1;return!0}function sv(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}class Uge{constructor(t,r,o){this.lock=r,this.view=o,this.index=0,this.stack=[],this.changed=!1,this.top=t,this.preMatch=Hge(t.node.content,t)}destroyBetween(t,r){if(t!=r){for(let o=t;o<r;o++)this.top.children[o].destroy();this.top.children.splice(t,r-t),this.changed=!0}}destroyRest(){this.destroyBetween(this.index,this.top.children.length)}syncToMarks(t,r,o){let a=0,i=this.stack.length>>1,l=Math.min(i,t.length);for(;a<l&&(a==i-1?this.top:this.stack[a+1<<1]).matchesMark(t[a])&&t[a].type.spec.spanning!==!1;)a++;for(;a<i;)this.destroyRest(),this.top.dirty=ar,this.index=this.stack.pop(),this.top=this.stack.pop(),i--;for(;i<t.length;){this.stack.push(this.top,this.index+1);let s=-1;for(let c=this.index;c<Math.min(this.index+3,this.top.children.length);c++){let u=this.top.children[c];if(u.matchesMark(t[i])&&!this.isLocked(u.dom)){s=c;break}}if(s>-1)s>this.index&&(this.changed=!0,this.destroyBetween(this.index,s)),this.top=this.top.children[this.index];else{let c=Fa.create(this.top,t[i],r,o);this.top.children.splice(this.index,0,c),this.top=c,this.changed=!0}this.index=0,i++}}findNodeMatch(t,r,o,a){let i=-1,l;if(a>=this.preMatch.index&&(l=this.preMatch.matches[a-this.preMatch.index]).parent==this.top&&l.matchesNode(t,r,o))i=this.top.children.indexOf(l,this.index);else for(let s=this.index,c=Math.min(this.top.children.length,s+5);s<c;s++){let u=this.top.children[s];if(u.matchesNode(t,r,o)&&!this.preMatch.matched.has(u)){i=s;break}}return i<0?!1:(this.destroyBetween(this.index,i),this.index++,!0)}updateNodeAt(t,r,o,a,i){let l=this.top.children[a];return l.dirty==oo&&l.dom==l.contentDOM&&(l.dirty=Ca),l.update(t,r,o,i)?(this.destroyBetween(this.index,a),this.index++,!0):!1}findIndexWithChild(t){for(;;){let r=t.parentNode;if(!r)return-1;if(r==this.top.contentDOM){let o=t.pmViewDesc;if(o){for(let a=this.index;a<this.top.children.length;a++)if(this.top.children[a]==o)return a}return-1}t=r}}updateNextNode(t,r,o,a,i,l){for(let s=this.index;s<this.top.children.length;s++){let c=this.top.children[s];if(c instanceof Jo){let u=this.preMatch.matched.get(c);if(u!=null&&u!=i)return!1;let d=c.dom,f,p=this.isLocked(d)&&!(t.isText&&c.node&&c.node.isText&&c.nodeDOM.nodeValue==t.text&&c.dirty!=oo&&zu(r,c.outerDeco));if(!p&&c.update(t,r,o,a))return this.destroyBetween(this.index,s),c.dom!=d&&(this.changed=!0),this.index++,!0;if(!p&&(f=this.recreateWrapper(c,t,r,o,a,l)))return this.destroyBetween(this.index,s),this.top.children[this.index]=f,f.contentDOM&&(f.dirty=Ca,f.updateChildren(a,l+1),f.dirty=ar),this.changed=!0,this.index++,!0;break}}return!1}recreateWrapper(t,r,o,a,i,l){if(t.dirty||r.isAtom||!t.children.length||!t.node.content.eq(r.content)||!zu(o,t.outerDeco)||!a.eq(t.innerDeco))return null;let s=Jo.create(this.top,r,o,a,i,l);if(s.contentDOM){s.children=t.children,t.children=[];for(let c of s.children)c.parent=s}return t.destroy(),s}addNode(t,r,o,a,i){let l=Jo.create(this.top,t,r,o,a,i);l.contentDOM&&l.updateChildren(a,i+1),this.top.children.splice(this.index++,0,l),this.changed=!0}placeWidget(t,r,o){let a=this.index<this.top.children.length?this.top.children[this.index]:null;if(a&&a.matchesWidget(t)&&(t==a.widget||!a.widget.type.toDOM.parentNode))this.index++;else{let i=new hw(this.top,t,r,o);this.top.children.splice(this.index++,0,i),this.changed=!0}}addTextblockHacks(){let t=this.top.children[this.index-1],r=this.top;for(;t instanceof Fa;)r=t,t=r.children[r.children.length-1];(!t||!(t instanceof sf)||/\n$/.test(t.node.text)||this.view.requiresGeckoHackNode&&/\s$/.test(t.node.text))&&((bn||fn)&&t&&t.dom.contentEditable=="false"&&this.addHackNode("IMG",r),this.addHackNode("BR",this.top))}addHackNode(t,r){if(r==this.top&&this.index<r.children.length&&r.children[this.index].matchesHack(t))this.index++;else{let o=document.createElement(t);t=="IMG"&&(o.className="ProseMirror-separator",o.alt=""),t=="BR"&&(o.className="ProseMirror-trailingBreak");let a=new gw(this.top,[],o,null);r!=this.top?r.children.push(a):r.children.splice(this.index++,0,a),this.changed=!0}}isLocked(t){return this.lock&&(t==this.lock||t.nodeType==1&&t.contains(this.lock.parentNode))}}function Hge(e,t){let r=t,o=r.children.length,a=e.childCount,i=new Map,l=[];e:for(;a>0;){let s;for(;;)if(o){let u=r.children[o-1];if(u instanceof Fa)r=u,o=u.children.length;else{s=u,o--;break}}else{if(r==t)break e;o=r.parent.children.indexOf(r),r=r.parent}let c=s.node;if(c){if(c!=e.child(a-1))break;--a,i.set(s,a),l.push(s)}}return{index:a,matched:i,matches:l.reverse()}}function Yge(e,t){return e.type.side-t.type.side}function Qge(e,t,r,o){let a=t.locals(e),i=0;if(a.length==0){for(let u=0;u<e.childCount;u++){let d=e.child(u);o(d,a,t.forChild(i,d),u),i+=d.nodeSize}return}let l=0,s=[],c=null;for(let u=0;;){let d,f;for(;l<a.length&&a[l].to==i;){let v=a[l++];v.widget&&(d?(f||(f=[d])).push(v):d=v)}if(d)if(f){f.sort(Yge);for(let v=0;v<f.length;v++)r(f[v],u,!!c)}else r(d,u,!!c);let p,h;if(c)h=-1,p=c,c=null;else if(u<e.childCount)h=u,p=e.child(u++);else break;for(let v=0;v<s.length;v++)s[v].to<=i&&s.splice(v--,1);for(;l<a.length&&a[l].from<=i&&a[l].to>i;)s.push(a[l++]);let m=i+p.nodeSize;if(p.isText){let v=m;l<a.length&&a[l].from<v&&(v=a[l].from);for(let y=0;y<s.length;y++)s[y].to<v&&(v=s[y].to);v<m&&(c=p.cut(v-i),p=p.cut(0,v-i),m=v,h=-1)}else for(;l<a.length&&a[l].to<m;)l++;let g=p.isInline&&!p.isLeaf?s.filter(v=>!v.inline):s.slice();o(p,g,t.forChild(i,p),h),i=m}}function Wge(e){if(e.nodeName=="UL"||e.nodeName=="OL"){let t=e.style.cssText;e.style.cssText=t+"; list-style: square !important",window.getComputedStyle(e).listStyle,e.style.cssText=t}}function qge(e,t,r,o){for(let a=0,i=0;a<e.childCount&&i<=o;){let l=e.child(a++),s=i;if(i+=l.nodeSize,!l.isText)continue;let c=l.text;for(;a<e.childCount;){let u=e.child(a++);if(i+=u.nodeSize,!u.isText)break;c+=u.text}if(i>=r){if(i>=o&&c.slice(o-t.length-s,o-s)==t)return o-t.length;let u=s<o?c.lastIndexOf(t,o-s-1):-1;if(u>=0&&u+t.length+s>=r)return s+u;if(r==o&&c.length>=o+t.length-s&&c.slice(o-s,o-s+t.length)==t)return o}}return-1}function I0(e,t,r,o,a){let i=[];for(let l=0,s=0;l<e.length;l++){let c=e[l],u=s,d=s+=c.size;u>=r||d<=t?i.push(c):(u<t&&i.push(c.slice(0,t-u,o)),a&&(i.push(a),a=void 0),d>r&&i.push(c.slice(r-u,c.size,o)))}return i}function qh(e,t=null){let r=e.domSelectionRange(),o=e.state.doc;if(!r.focusNode)return null;let a=e.docView.nearestDesc(r.focusNode),i=a&&a.size==0,l=e.docView.posFromDOM(r.focusNode,r.focusOffset,1);if(l<0)return null;let s=o.resolve(l),c,u;if(lf(r)){for(c=l;a&&!a.node;)a=a.parent;let f=a.node;if(a&&f.isAtom&&Pe.isSelectable(f)&&a.parent&&!(f.isInline&&bge(r.focusNode,r.focusOffset,a.dom))){let p=a.posBefore;u=new Pe(l==p?s:o.resolve(p))}}else{if(r instanceof e.dom.ownerDocument.defaultView.Selection&&r.rangeCount>1){let f=l,p=l;for(let h=0;h<r.rangeCount;h++){let m=r.getRangeAt(h);f=Math.min(f,e.docView.posFromDOM(m.startContainer,m.startOffset,1)),p=Math.max(p,e.docView.posFromDOM(m.endContainer,m.endOffset,-1))}if(f<0)return null;[c,l]=p==e.state.selection.anchor?[p,f]:[f,p],s=o.resolve(l)}else c=e.docView.posFromDOM(r.anchorNode,r.anchorOffset,1);if(c<0)return null}let d=o.resolve(c);if(!u){let f=t=="pointer"||e.state.selection.head<s.pos&&!i?1:-1;u=Gh(e,d,s,f)}return u}function bw(e){return e.editable?e.hasFocus():Nw(e)&&document.activeElement&&document.activeElement.contains(e.dom)}function yo(e,t=!1){let r=e.state.selection;if(ww(e,r),!!bw(e)){if(!t&&e.input.mouseDown&&e.input.mouseDown.allowDefault&&fn){let o=e.domSelectionRange(),a=e.domObserver.currentSelection;if(o.anchorNode&&a.anchorNode&&Ra(o.anchorNode,o.anchorOffset,a.anchorNode,a.anchorOffset)){e.input.mouseDown.delayedSelectionSync=!0,e.domObserver.setCurSelection();return}}if(e.domObserver.disconnectSelection(),e.cursorWrapper)Kge(e);else{let{anchor:o,head:a}=r,i,l;cv&&!(r instanceof Ge)&&(r.$from.parent.inlineContent||(i=uv(e,r.from)),!r.empty&&!r.$from.parent.inlineContent&&(l=uv(e,r.to))),e.docView.setSelection(o,a,e.root,t),cv&&(i&&dv(i),l&&dv(l)),r.visible?e.dom.classList.remove("ProseMirror-hideselection"):(e.dom.classList.add("ProseMirror-hideselection"),"onselectionchange"in document&&Gge(e))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}}const cv=bn||fn&&sw<63;function uv(e,t){let{node:r,offset:o}=e.docView.domFromPos(t,0),a=o<r.childNodes.length?r.childNodes[o]:null,i=o?r.childNodes[o-1]:null;if(bn&&a&&a.contentEditable=="false")return np(a);if((!a||a.contentEditable=="false")&&(!i||i.contentEditable=="false")){if(a)return np(a);if(i)return np(i)}}function np(e){return e.contentEditable="true",bn&&e.draggable&&(e.draggable=!1,e.wasDraggable=!0),e}function dv(e){e.contentEditable="false",e.wasDraggable&&(e.draggable=!0,e.wasDraggable=null)}function Gge(e){let t=e.dom.ownerDocument;t.removeEventListener("selectionchange",e.input.hideSelectionGuard);let r=e.domSelectionRange(),o=r.anchorNode,a=r.anchorOffset;t.addEventListener("selectionchange",e.input.hideSelectionGuard=()=>{(r.anchorNode!=o||r.anchorOffset!=a)&&(t.removeEventListener("selectionchange",e.input.hideSelectionGuard),setTimeout(()=>{(!bw(e)||e.state.selection.visible)&&e.dom.classList.remove("ProseMirror-hideselection")},20))})}function Kge(e){let t=e.domSelection(),r=document.createRange();if(!t)return;let o=e.cursorWrapper.dom,a=o.nodeName=="IMG";a?r.setStart(o.parentNode,rn(o)+1):r.setStart(o,0),r.collapse(!0),t.removeAllRanges(),t.addRange(r),!a&&!e.state.selection.visible&&An&&Ko<=11&&(o.disabled=!0,o.disabled=!1)}function ww(e,t){if(t instanceof Pe){let r=e.docView.descAt(t.from);r!=e.lastSelectedViewDesc&&(fv(e),r&&r.selectNode(),e.lastSelectedViewDesc=r)}else fv(e)}function fv(e){e.lastSelectedViewDesc&&(e.lastSelectedViewDesc.parent&&e.lastSelectedViewDesc.deselectNode(),e.lastSelectedViewDesc=void 0)}function Gh(e,t,r,o){return e.someProp("createSelectionBetween",a=>a(e,t,r))||Ge.between(t,r,o)}function pv(e){return e.editable&&!e.hasFocus()?!1:Nw(e)}function Nw(e){let t=e.domSelectionRange();if(!t.anchorNode)return!1;try{return e.dom.contains(t.anchorNode.nodeType==3?t.anchorNode.parentNode:t.anchorNode)&&(e.editable||e.dom.contains(t.focusNode.nodeType==3?t.focusNode.parentNode:t.focusNode))}catch{return!1}}function Jge(e){let t=e.docView.domFromPos(e.state.selection.anchor,0),r=e.domSelectionRange();return Ra(t.node,t.offset,r.anchorNode,r.anchorOffset)}function A0(e,t){let{$anchor:r,$head:o}=e.selection,a=t>0?r.max(o):r.min(o),i=a.parent.inlineContent?a.depth?e.doc.resolve(t>0?a.after():a.before()):null:a;return i&&Ze.findFrom(i,t)}function zo(e,t){return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()),!0}function mv(e,t,r){let o=e.state.selection;if(o instanceof Ge)if(r.indexOf("s")>-1){let{$head:a}=o,i=a.textOffset?null:t<0?a.nodeBefore:a.nodeAfter;if(!i||i.isText||!i.isLeaf)return!1;let l=e.state.doc.resolve(a.pos+i.nodeSize*(t<0?-1:1));return zo(e,new Ge(o.$anchor,l))}else if(o.empty){if(e.endOfTextblock(t>0?"forward":"backward")){let a=A0(e.state,t);return a&&a instanceof Pe?zo(e,a):!1}else if(!(tr&&r.indexOf("m")>-1)){let a=o.$head,i=a.textOffset?null:t<0?a.nodeBefore:a.nodeAfter,l;if(!i||i.isText)return!1;let s=t<0?a.pos-i.nodeSize:a.pos;return i.isAtom||(l=e.docView.descAt(s))&&!l.contentDOM?Pe.isSelectable(i)?zo(e,new Pe(t<0?e.state.doc.resolve(a.pos-i.nodeSize):a)):Zs?zo(e,new Ge(e.state.doc.resolve(t<0?s:s+i.nodeSize))):!1:!1}}else return!1;else{if(o instanceof Pe&&o.node.isInline)return zo(e,new Ge(t>0?o.$to:o.$from));{let a=A0(e.state,t);return a?zo(e,a):!1}}}function ju(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function Wl(e,t){let r=e.pmViewDesc;return r&&r.size==0&&(t<0||e.nextSibling||e.nodeName!="BR")}function ui(e,t){return t<0?Zge(e):Xge(e)}function Zge(e){let t=e.domSelectionRange(),r=t.focusNode,o=t.focusOffset;if(!r)return;let a,i,l=!1;for(Or&&r.nodeType==1&&o<ju(r)&&Wl(r.childNodes[o],-1)&&(l=!0);;)if(o>0){if(r.nodeType!=1)break;{let s=r.childNodes[o-1];if(Wl(s,-1))a=r,i=--o;else if(s.nodeType==3)r=s,o=r.nodeValue.length;else break}}else{if(kw(r))break;{let s=r.previousSibling;for(;s&&Wl(s,-1);)a=r.parentNode,i=rn(s),s=s.previousSibling;if(s)r=s,o=ju(r);else{if(r=r.parentNode,r==e.dom)break;o=0}}}l?O0(e,r,o):a&&O0(e,a,i)}function Xge(e){let t=e.domSelectionRange(),r=t.focusNode,o=t.focusOffset;if(!r)return;let a=ju(r),i,l;for(;;)if(o<a){if(r.nodeType!=1)break;let s=r.childNodes[o];if(Wl(s,1))i=r,l=++o;else break}else{if(kw(r))break;{let s=r.nextSibling;for(;s&&Wl(s,1);)i=s.parentNode,l=rn(s)+1,s=s.nextSibling;if(s)r=s,o=0,a=ju(r);else{if(r=r.parentNode,r==e.dom)break;o=a=0}}}i&&O0(e,i,l)}function kw(e){let t=e.pmViewDesc;return t&&t.node&&t.node.isBlock}function e4e(e,t){for(;e&&t==e.childNodes.length&&!Js(e);)t=rn(e)+1,e=e.parentNode;for(;e&&t<e.childNodes.length;){let r=e.childNodes[t];if(r.nodeType==3)return r;if(r.nodeType==1&&r.contentEditable=="false")break;e=r,t=0}}function t4e(e,t){for(;e&&!t&&!Js(e);)t=rn(e),e=e.parentNode;for(;e&&t;){let r=e.childNodes[t-1];if(r.nodeType==3)return r;if(r.nodeType==1&&r.contentEditable=="false")break;e=r,t=e.childNodes.length}}function O0(e,t,r){if(t.nodeType!=3){let i,l;(l=e4e(t,r))?(t=l,r=0):(i=t4e(t,r))&&(t=i,r=i.nodeValue.length)}let o=e.domSelection();if(!o)return;if(lf(o)){let i=document.createRange();i.setEnd(t,r),i.setStart(t,r),o.removeAllRanges(),o.addRange(i)}else o.extend&&o.extend(t,r);e.domObserver.setCurSelection();let{state:a}=e;setTimeout(()=>{e.state==a&&yo(e)},50)}function hv(e,t){let r=e.state.doc.resolve(t);if(!(fn||kge)&&r.parent.inlineContent){let a=e.coordsAtPos(t);if(t>r.start()){let i=e.coordsAtPos(t-1),l=(i.top+i.bottom)/2;if(l>a.top&&l<a.bottom&&Math.abs(i.left-a.left)>1)return i.left<a.left?"ltr":"rtl"}if(t<r.end()){let i=e.coordsAtPos(t+1),l=(i.top+i.bottom)/2;if(l>a.top&&l<a.bottom&&Math.abs(i.left-a.left)>1)return i.left>a.left?"ltr":"rtl"}}return getComputedStyle(e.dom).direction=="rtl"?"rtl":"ltr"}function gv(e,t,r){let o=e.state.selection;if(o instanceof Ge&&!o.empty||r.indexOf("s")>-1||tr&&r.indexOf("m")>-1)return!1;let{$from:a,$to:i}=o;if(!a.parent.inlineContent||e.endOfTextblock(t<0?"up":"down")){let l=A0(e.state,t);if(l&&l instanceof Pe)return zo(e,l)}if(!a.parent.inlineContent){let l=t<0?a:i,s=o instanceof _r?Ze.near(l,t):Ze.findFrom(l,t);return s?zo(e,s):!1}return!1}function vv(e,t){if(!(e.state.selection instanceof Ge))return!0;let{$head:r,$anchor:o,empty:a}=e.state.selection;if(!r.sameParent(o))return!0;if(!a)return!1;if(e.endOfTextblock(t>0?"forward":"backward"))return!0;let i=!r.textOffset&&(t<0?r.nodeBefore:r.nodeAfter);if(i&&!i.isText){let l=e.state.tr;return t<0?l.delete(r.pos-i.nodeSize,r.pos):l.delete(r.pos,r.pos+i.nodeSize),e.dispatch(l),!0}return!1}function yv(e,t,r){e.domObserver.stop(),t.contentEditable=r,e.domObserver.start()}function n4e(e){if(!bn||e.state.selection.$head.parentOffset>0)return!1;let{focusNode:t,focusOffset:r}=e.domSelectionRange();if(t&&t.nodeType==1&&r==0&&t.firstChild&&t.firstChild.contentEditable=="false"){let o=t.firstChild;yv(e,o,"true"),setTimeout(()=>yv(e,o,"false"),20)}return!1}function r4e(e){let t="";return e.ctrlKey&&(t+="c"),e.metaKey&&(t+="m"),e.altKey&&(t+="a"),e.shiftKey&&(t+="s"),t}function o4e(e,t){let r=t.keyCode,o=r4e(t);if(r==8||tr&&r==72&&o=="c")return vv(e,-1)||ui(e,-1);if(r==46&&!t.shiftKey||tr&&r==68&&o=="c")return vv(e,1)||ui(e,1);if(r==13||r==27)return!0;if(r==37||tr&&r==66&&o=="c"){let a=r==37?hv(e,e.state.selection.from)=="ltr"?-1:1:-1;return mv(e,a,o)||ui(e,a)}else if(r==39||tr&&r==70&&o=="c"){let a=r==39?hv(e,e.state.selection.from)=="ltr"?1:-1:1;return mv(e,a,o)||ui(e,a)}else{if(r==38||tr&&r==80&&o=="c")return gv(e,-1,o)||ui(e,-1);if(r==40||tr&&r==78&&o=="c")return n4e(e)||gv(e,1,o)||ui(e,1);if(o==(tr?"m":"c")&&(r==66||r==73||r==89||r==90))return!0}return!1}function xw(e,t){e.someProp("transformCopied",h=>{t=h(t,e)});let r=[],{content:o,openStart:a,openEnd:i}=t;for(;a>1&&i>1&&o.childCount==1&&o.firstChild.childCount==1;){a--,i--;let h=o.firstChild;r.push(h.type.name,h.attrs!=h.type.defaultAttrs?h.attrs:null),o=h.content}let l=e.someProp("clipboardSerializer")||Xa.fromSchema(e.state.schema),s=_w(),c=s.createElement("div");c.appendChild(l.serializeFragment(o,{document:s}));let u=c.firstChild,d,f=0;for(;u&&u.nodeType==1&&(d=Sw[u.nodeName.toLowerCase()]);){for(let h=d.length-1;h>=0;h--){let m=s.createElement(d[h]);for(;c.firstChild;)m.appendChild(c.firstChild);c.appendChild(m),f++}u=c.firstChild}u&&u.nodeType==1&&u.setAttribute("data-pm-slice",`${a} ${i}${f?` -${f}`:""} ${JSON.stringify(r)}`);let p=e.someProp("clipboardTextSerializer",h=>h(t,e))||t.content.textBetween(0,t.content.size,`
|
|
47
|
+
`)};xn.prototype.renderPartial=function(t,r,o,a){if(o){var i=this.getConfigTags(a),l=Fh(o)?o(t[1]):o[t[1]];if(l!=null){var s=t[6],c=t[5],u=t[4],d=l;c==0&&u&&(d=this.indentPartial(l,u,s));var f=this.parse(d,i);return this.renderTokens(f,r,o,d,a)}}};xn.prototype.unescapedValue=function(t,r){var o=r.lookup(t[1]);if(o!=null)return o};xn.prototype.escapedValue=function(t,r,o){var a=this.getConfigEscape(o)||fr.escape,i=r.lookup(t[1]);if(i!=null)return typeof i=="number"&&a===fr.escape?String(i):a(i)};xn.prototype.rawValue=function(t){return t[1]};xn.prototype.getConfigTags=function(t){return hl(t)?t:t&&typeof t=="object"?t.tags:void 0};xn.prototype.getConfigEscape=function(t){if(t&&typeof t=="object"&&!hl(t))return t.escape};var fr={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(e){Ns.templateCache=e},get templateCache(){return Ns.templateCache}},Ns=new xn;fr.clearCache=function(){return Ns.clearCache()};fr.parse=function(t,r){return Ns.parse(t,r)};fr.render=function(t,r,o,a){if(typeof t!="string")throw new TypeError('Invalid template! Template should be a "string" but "'+ahe(t)+'" was given as the first argument for mustache#render(template, view, partials)');return Ns.render(t,r,o,a)};fr.escape=fhe;fr.Scanner=Ks;fr.Context=Yi;fr.Writer=xn;const bhe={props:["value","schema","entity"],methods:{hasRouterLink(){return Dt(this.schema,"options.routerLink")},getRouterLink(){const e=Dt(this.schema,"options.routerLink");return fr.render(e,this.entity)}}},whe={key:1};function Nhe(e,t,r,o,a,i){const l=n.resolveComponent("router-link");return e.$options.methods.hasRouterLink(e.props)?(n.openBlock(),n.createBlock(l,{key:0,to:e.$options.methods.getRouterLink(e.props)},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(r.value),1)]),_:1},8,["to"])):(n.openBlock(),n.createElementBlock("span",whe,n.toDisplayString(r.value),1))}const khe=xe(bhe,[["render",Nhe]]),xhe={props:["value","schema"],methods:{formatValue(e){return e}}};function Che(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("span",null,n.toDisplayString(e.$options.methods.formatValue(r.value)),1)}const Ehe=xe(xhe,[["render",Che]]),The={props:["value","schema"],methods:{formatValue(e){return isNaN(e)||e===null||e===void 0?"-":Number(e/100).toLocaleString("pt-BR",{style:"currency",currency:"BRL"})}}};function Dhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("span",null,n.toDisplayString(e.$options.methods.formatValue(r.value)),1)}const She=xe(The,[["render",Dhe]]),_he={props:["value","schema"]},Ihe=["href"];function Ahe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("a",{target:"_blank",href:`mailto:${r.value}`},n.toDisplayString(r.value),9,Ihe)}const Ohe=xe(_he,[["render",Ahe]]),zhe={props:["value","schema"],methods:{formatValue(e,t){if(!e)return"-";const r=Dt(t,"options.format","dd/MM/yyyy hh:mm:ss");return Nd(e).format(r)}}};function jhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("span",null,n.toDisplayString(e.$options.methods.formatValue(r.value,r.schema)),1)}const Lhe=xe(zhe,[["render",jhe]]),T8={};T8.register=function(){Sn.register({type:"String"},"default",khe),Sn.register({type:"Date"},"default",Lhe),Sn.register({type:"Number"},"default",Ehe),Sn.register({format:"Amount"},"default",She),Sn.register({format:"Email"},"default",Ohe)};const Bhe={props:{perPage:Number,pagesCount:Number,totalCount:Number,columnSpecs:{type:Array},includedIds:{type:Array},excludedIds:{type:Array},selectable:Boolean,clickable:Boolean,multiselect:Boolean,page:Object},data(e){return{checked:this.computeChecked(e)}},emits:["selected","click-item"],computed:{includedAll(){return this.includedIds.toString()==="*"},estimatedRows(){return this.page&&this.pagesCount>1&&this.page.index>=this.pagesCount-1?this.totalCount%this.perPage:this.perPage}},methods:{getColumnComponent(e){return e.component},getColumnValue(e,t){return Dt(e,t.path)},computeChecked(e){const t=e||this;if(!t.page||!t.page.data)return[];let r=t.includedIds,o=t.excludedIds,a=t.includedAll;return t.page.data.map(i=>a&&!o.includes(i.id)||r.includes(i.id))}},watch:{includedAll(){this.checked=this.computeChecked(this)},includedIds(){this.checked=this.computeChecked(this)},excludedIds(){this.checked=this.computeChecked(this)}}},Vhe={class:"l-table-tbody"},$he={key:"selector",class:"l-table-cell l-table-column-selector"},Phe=["onClick"],Rhe={key:"selector",class:"l-table-cell l-table-column-selector"},Fhe={key:"selector",class:"l-table-cell l-table-column-selector"};function Uhe(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox");return n.openBlock(),n.createElementBlock("tbody",Vhe,[r.page&&r.page.loaded?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:0},n.renderList(r.page.data,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c,class:n.normalizeClass({"l-table-selected":a.checked[c]})},[r.selectable?(n.openBlock(),n.createElementBlock("td",$he,[n.createVNode(l,{modelValue:a.checked[c],"onUpdate:modelValue":u=>a.checked[c]=u,class:"l-table-selector",type:r.multiselect?"checkbox":"radio",onChange:()=>e.$emit("selected",{key:s.id,selected:a.checked[c]})},null,8,["modelValue","onUpdate:modelValue","type","onChange"])])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.columnSpecs,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(["l-table-cell",`align-${u.align}${r.clickable?" cursor-pointer":""}`]),onClick:f=>e.$emit("click-item",s)},[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(i.getColumnComponent(u)),{value:i.getColumnValue(s,u),schema:u,entity:s},null,8,["value","schema","entity"]))],10,Phe))),128))],2))),128)):r.page&&r.page.loading?(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:1},n.renderList(i.estimatedRows,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c},[r.selectable?(n.openBlock(),n.createElementBlock("td",Rhe,[n.createVNode(l,{disabled:"",class:"l-table-selector",type:r.multiselect?"checkbox":"radio",value:i.includedAll},null,8,["type","value"])])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.columnSpecs,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(["l-table-cell",`align-${u.align}`])},t[0]||(t[0]=[n.createElementVNode("span",{class:"l-table-skeleton"},null,-1)]),2))),128))]))),128)):(n.openBlock(!0),n.createElementBlock(n.Fragment,{key:2},n.renderList(i.estimatedRows,(s,c)=>(n.openBlock(),n.createElementBlock("tr",{key:c},[r.selectable?(n.openBlock(),n.createElementBlock("td",Fhe,[n.createVNode(l,{disabled:"",class:"l-table-selector",type:r.multiselect?"checkbox":"radio",checked:i.includedAll},null,8,["type","checked"])])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.columnSpecs,(u,d)=>(n.openBlock(),n.createElementBlock("td",{key:d,class:n.normalizeClass(["l-table-cell",`align-${u.align}`])},t[1]||(t[1]=[n.createElementVNode("span",{class:"l-table-skeleton error"},null,-1)]),2))),128))]))),128))])}const Hhe=xe(Bhe,[["render",Uhe]]);const Yhe={props:{title:String,maxWidth:{type:Number,default:null},minWidth:{type:Number,default:50}},data(){return{dragging:!1,deltaX:0}},computed:{handleStyle(){return this.dragging?{transform:`translateX(${this.deltaX}px)`}:null}},methods:{currentWidth(){return this.$el.parentElement.getBoundingClientRect().width},limitDeltaX(e){let t=this.currentWidth();return this.limitWidth(t+e)-t},limitWidth(e){return e?this.maxWidth&&this.maxWidth<e?this.maxWidth:this.minWidth&&this.minWidth>e?this.minWidth:e:null},resize(e){this.$emit("resize",this.limitWidth(e))},drag(e){this.dragging||this.unregisterDocumentHandlers();let t=e.clientX-this.dragStartClientX;this.deltaX=this.limitDeltaX(t),console.log("drag",this.deltaX)},dragStart(e){this.registerDocumentHandlers(),this.deltaX=0,this.dragging=!0,this.dragStartClientX=e.clientX,console.log("dragStart",e)},dragEnd(e){if(this.deltaX){let t=this.currentWidth()+this.deltaX;this.resize(t)}this.unregisterDocumentHandlers(),this.deltaX=0,this.dragging=!1,this.dragStartClientX=0,console.log("dragEnd",e)},registerDocumentHandlers(){this.unregisterDocumentHandlers(),this._documentMouseMove=e=>this.drag(e),this._documentMouseUp=e=>this.dragEnd(e),document.body.style.cursor="col-resize",document.addEventListener("mousemove",this._documentMouseMove),document.addEventListener("mouseup",this._documentMouseUp),document.onselectstart=()=>!1,document.ondragstart=()=>!1},unregisterDocumentHandlers(){document.removeEventListener("mousemove",this._documentMouseMove),document.removeEventListener("mouseup",this._documentMouseUp),document.body.style.cursor="",document.onselectstart=null,document.ondragstart=null}}};function Qhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["mt-handle",a.dragging?"dragging":""]),style:n.normalizeStyle(i.handleStyle),onDblclick:t[0]||(t[0]=l=>i.resize(null)),onMousedown:t[1]||(t[1]=(...l)=>i.dragStart&&i.dragStart(...l))},null,38)}const Whe=xe(Yhe,[["render",Qhe]]);const qhe={components:{LTableHeaderResizer:Whe},props:{spec:{type:Object}},emits:["spec:update"],data:e=>({localSpec:e.spec}),computed:{resizable(){return this.localSpec.field&&this.localSpec.field.resizable},reordable(){return!0},icon(){return this.$L.Icons.get(this.localSpec.field)}},methods:{resizeColumn(e,t){e.width=t},toggleSorting(e){let t=this.localSpec.column.sortDirection,r="asc";t?t.toLowerCase()==="asc"&&(r="desc"):r="asc",this.$emit("sort",{direction:r,cumulative:e})}},watch:{localSpec:{handler(e){this.$emit("spec:update",e)},deep:!0}}},Ghe={key:1,class:"l-table-header-cell-content"};function Khe(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-tooltip"),c=n.resolveComponent("LTableHeaderResizer");return n.openBlock(),n.createElementBlock("th",{class:"l-table-header-cell l-table-cell",style:n.normalizeStyle({"--l-table-col-width":r.spec.column.width?`${r.spec.column.width}px`:"auto"})},[r.spec.sortable?(n.openBlock(),n.createElementBlock("a",{key:0,href:"#",class:n.normalizeClass(["l-table-header-cell-content",[r.spec.column.sortDirection?"active":null,`l-table-header-align-${r.spec.align}`]]),onClick:t[0]||(t[0]=n.withModifiers(u=>i.toggleSorting(),["prevent"]))},[n.createVNode(s,{key:"tooltip",disabled:!r.spec.description,content:r.spec.description,placement:"top","open-delay":600,offset:0},{default:n.withCtx(()=>[n.createElementVNode("span",null,[i.icon?(n.openBlock(),n.createBlock(l,{key:0,class:"l-table-header-icon"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.icon),1)]),_:1})):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(r.spec.title),1)])]),_:1},8,["disabled","content"]),n.createElementVNode("i",{class:n.normalizeClass(["l-table-sorter-icon uil uil-arrow-down",`l-table-sorter-${r.spec.column.sortDirection||"default"}`])},null,2)],2)):(n.openBlock(),n.createElementBlock("span",Ghe,[n.createVNode(s,{disabled:!r.spec.description,content:r.spec.description,placement:"top","open-delay":600,offset:0},{default:n.withCtx(()=>[n.createElementVNode("span",null,[i.icon?(n.openBlock(),n.createBlock(l,{key:0,class:"l-table-header-icon"},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.icon),1)]),_:1})):n.createCommentVNode("",!0),n.createTextVNode(" "+n.toDisplayString(r.spec.title),1)])]),_:1},8,["disabled","content"])])),t[2]||(t[2]=n.createElementVNode("span",{style:{width:"12px"}},null,-1)),i.resizable?(n.openBlock(),n.createBlock(c,{key:2,onResize:t[1]||(t[1]=u=>i.resizeColumn(r.spec.column,u))})):n.createCommentVNode("",!0)],4)}const Jhe=xe(qhe,[["render",Khe]]);const Zhe={props:["loading"]};function Xhe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-table-header-loader",{loading:r.loading}])},null,2)}const e2e=xe(Zhe,[["render",Xhe]]);const t2e={components:{LTableHeaderCell:Jhe,LTableHeaderLoader:e2e},props:{columnSpecs:{type:Array},loading:{type:Boolean,default:!1},includedIds:{type:Array},excludedIds:{type:Array},total:{type:Number},selectable:{type:Boolean},multiselect:{type:Boolean}},data:e=>({localColumnSpecs:e.columnSpecs}),emits:["columnSpecs:update","selected"],computed:{selectedEverything(){let e=this.includedIds.length===this.total&&this.total>0,t=this.includedIds.toString()==="*"&&this.excludedIds.length==0;return e||t},selectedNothing(){return this.includedIds.length===0},selectedSomethings(){return!this.selectedNothing&&!this.selectedEverything}},methods:{changeSpecSort(e,{direction:t,cumulative:r}){if(console.log("changeSpecSort",e,t,r),r){let a=this.localColumnSpecs.reduce((i,l)=>Math.max(i,l.column.sortOrder),0)+1;e.column.sortOrder=a,e.column.sortDirection=t}else{for(let o of this.localColumnSpecs)o.column.sortOrder=null,o.column.sortDirection=null;e.column.sortOrder=1,e.column.sortDirection=t}},syncSpec(e){let t=this.localColumnSpecs.findIndex(r=>r.field===e.field);this.localColumnSpecs.splice(t,1,e)},changeSelection(e){this.$emit("selected",{key:"*",selected:e})}},watch:{localColumnSpecs:{handler(e){console.log("localColumnSpecs",e),this.$emit("columnSpecs:update",e)},deep:!0}}},n2e={class:"l-table-header"},r2e={key:0,scope:"col",class:"l-table-header-cell l-table-cell l-table-column-selector"},o2e={class:"l-table-header-extras"},a2e={colspan:"999"};function i2e(e,t,r,o,a,i){const l=n.resolveComponent("l-checkbox"),s=n.resolveComponent("LTableHeaderCell"),c=n.resolveComponent("LTableHeaderLoader");return n.openBlock(),n.createElementBlock("thead",n2e,[n.createElementVNode("tr",null,[r.selectable?(n.openBlock(),n.createElementBlock("th",r2e,[r.multiselect?(n.openBlock(),n.createBlock(l,{key:0,class:"l-table-selector",type:"checkbox",value:i.selectedEverything,indeterminate:i.selectedSomethings,onChange:t[0]||(t[0]=u=>i.changeSelection(u))},null,8,["value","indeterminate"])):n.createCommentVNode("",!0)])):n.createCommentVNode("",!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(e.localColumnSpecs,(u,d)=>(n.openBlock(),n.createBlock(s,{key:d,spec:u,"onSpec:update":i.syncSpec,onSort:f=>i.changeSpecSort(u,f),ref_for:!0,ref:"headers"},null,8,["spec","onSpec:update","onSort"]))),128))]),n.createElementVNode("tr",o2e,[n.createElementVNode("td",a2e,[n.createVNode(c,{loading:r.loading},null,8,["loading"]),t[1]||(t[1]=n.createElementVNode("div",{class:"l-table-header-shadow-top"},null,-1))])])])}const l2e=xe(t2e,[["render",i2e]]);const s2e={},c2e={class:"l-table-endspace"};function u2e(e,t){return n.openBlock(),n.createElementBlock("div",c2e)}const d2e=xe(s2e,[["render",u2e]]);const f2e={props:{loading:Boolean,automatic:Boolean},mounted(){this.intersectionObserver=new IntersectionObserver(([e])=>{e&&e.isIntersecting&&this.automatic&&this.$emit("appeared")}),this.intersectionObserver.observe(this.$el)},unmounted(){this.intersectionObserver&&this.intersectionObserver.disconnect()}};function p2e(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-table-loadmore",{loading:r.loading}]),onClick:t[0]||(t[0]=l=>e.$emit("click"))},t[1]||(t[1]=[n.createElementVNode("a",{href:"#",class:"l-table-loadmore-link"},"Carregar mais",-1)]),2)}const m2e=xe(f2e,[["render",p2e]]);const h2e=2e3,g2e={name:"LTableReloader",data(){return{canReload:!0}},methods:{reload(){this.canReload=!1,this.$emit("reload"),setTimeout(()=>this.canReload=!0,h2e)}}},v2e={class:"l-table-reloader"},y2e={class:"l-table-reloader-content"};function M2e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-button");return n.openBlock(),n.createElementBlock("div",v2e,[n.createElementVNode("div",y2e,[n.createVNode(l,{size:"22"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-cloud-exclamation")])),_:1}),t[3]||(t[3]=n.createElementVNode("span",{style:{"margin-left":"8px",flex:"1 1"}},"Algumas informações não puderam ser carregadas.",-1)),n.createVNode(s,{size:"mini",onClick:t[0]||(t[0]=c=>i.reload())},{default:n.withCtx(()=>t[2]||(t[2]=[n.createTextVNode("Recarregar")])),_:1})])])}const b2e=xe(g2e,[["render",M2e]]);const w2e={props:{height:{type:Number}}},N2e={class:"l-table-spacer"};function k2e(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("tbody",N2e,[n.createElementVNode("tr",{style:n.normalizeStyle({height:`${r.height}px`})},t[0]||(t[0]=[n.createElementVNode("td",{class:"l-table-spacer-bg",colspan:"999"},null,-1)]),4)])}const x2e=xe(w2e,[["render",k2e]]);var C2e=f8;function E2e(e){var t=e==null?0:e.length;return t?C2e(e,1):[]}var T2e=E2e;const D2e=St(T2e);function S2e(){}var _2e=S2e,Qf=Wb,I2e=_2e,A2e=zh,O2e=1/0,z2e=Qf&&1/A2e(new Qf([,-0]))[1]==O2e?function(e){return new Qf(e)}:I2e,j2e=z2e,L2e=Ah,B2e=c8,V2e=u8,$2e=Oh,P2e=j2e,R2e=zh,F2e=200;function U2e(e,t,r){var o=-1,a=B2e,i=e.length,l=!0,s=[],c=s;if(r)l=!1,a=V2e;else if(i>=F2e){var u=t?null:P2e(e);if(u)return R2e(u);l=!1,a=$2e,c=new L2e}else c=t?[]:s;e:for(;++o<i;){var d=e[o],f=t?t(d):d;if(d=r||d!==0?d:0,l&&f===f){for(var p=c.length;p--;)if(c[p]===f)continue e;t&&c.push(f),s.push(d)}else a(c,f,r)||(c!==s&&c.push(f),s.push(d))}return s}var H2e=U2e,Y2e=H2e;function Q2e(e){return e&&e.length?Y2e(e):[]}var W2e=Q2e;const q2e=St(W2e);function G2e({key:e,selected:t},r){let{loadedPages:o,allowInvertedSelection:a,includedIds:i,excludedIds:l,multiselect:s,itemToId:c=h=>h}=r;if(!e===void 0||e===null)return{includedIds:i,excludedIds:l};if(e==="*"){if(i.splice(0,i.length),l.splice(0,l.length),t&&s&&a&&i.push("*"),t&&s&&!a){let h=D2e(o.filter(g=>g.data).map(g=>g.data));i=q2e(h.map(g=>c(g)))}return{includedIds:i,excludedIds:l}}let d=i.includes("*"),f=i.includes(e),p=l.includes(e);if(s||(i.splice(0,i.length),l.splice(0,l.length)),d&&s){if(t&&p){let h=l.indexOf(e);l.splice(h,1)}!t&&!p&&s&&l.push(e)}else if(t&&!f&&(s?i.push(e):i=[e]),!t&&f){let h=i.indexOf(e);i.splice(h,1)}return{includedIds:i,excludedIds:l}}function K2e({pagesCount:e,currentPage:t,endingAdjacents:r=1,adjacents:o=2,next:a=!0,previous:i=!0,last:l=!1,first:s=!1,fixedWidth:c=!0}){const u=[];if(!e)return u;const d=c?r*2+o*2+3:r*2+1;if(e<=d)for(let f=0;f<e;f++)u.push(f);else{let f=0;for(let g=0;g<Math.min(r,e);g++)u.push(f=g);let p=r+o*2,h=o,m=o;c&&t<p&&(m+=p-t),c&&e-t-1<p&&(h+=p-(e-t-1));for(let g=Math.max(f+1,t-h);g<Math.min(t+m+1,e);g++)f+2===g&&u.push(f=f+1),f+1!==g&&u.push("...1"),u.push(f=g);for(let g=Math.max(f+1,e-r);g<e;g++)f+2===g&&u.push(f=f+1),f+1!==g&&u.push("...2"),u.push(f=g)}return i&&u.unshift("<"),a&&u.push(">"),s&&u.unshift("<<"),l&&u.push(">>"),u}const J2e={name:"LTablePagination",props:{pagesCount:Number,totalCount:Number,currentPage:{type:Number,default:2}},computed:{visiblePages(){return this.totalCount?K2e({pagesCount:this.pagesCount,currentPage:this.currentPage,adjacents:1,endingAdjacents:1,fixedWidth:!0}):["...1"]}},methods:{clicked(e){typeof e=="number"?this.goto(parseInt(e)):e==="<"?this.goto(this.currentPage-1):e===">"?this.goto(this.currentPage+1):e==="<<"?this.goto(0):e===">>"&&this.goto(this.pagesCount-1)},goto(e){this.currentPage!=e&&(e=Math.max(0,Math.min(e,this.pagesCount-1)),this.$emit("goto",e))}}},Z2e={class:"l-table-pagination"},X2e=["onClick"];function e1e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon");return n.openBlock(),n.createElementBlock("div",Z2e,[n.createVNode(n.TransitionGroup,{tag:"div",class:"l-table-pagination-pages",name:"l-table-pagination-transition"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.visiblePages,s=>(n.openBlock(),n.createElementBlock("span",{class:n.normalizeClass(["l-table-pagination-page-item",{active:s==r.currentPage}]),key:s,onClick:c=>i.clicked(s)},[s==="<"?(n.openBlock(),n.createBlock(l,{key:0,size:"20"},{default:n.withCtx(()=>t[0]||(t[0]=[n.createTextVNode("uil-angle-left")])),_:1})):s===">"?(n.openBlock(),n.createBlock(l,{key:1,size:"20"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode("uil-angle-right")])),_:1})):s==="...1"||s==="...2"?(n.openBlock(),n.createElementBlock(n.Fragment,{key:2},[n.createTextVNode(" ... ")],64)):(n.openBlock(),n.createElementBlock(n.Fragment,{key:3},[n.createTextVNode(n.toDisplayString(s+1),1)],64))],10,X2e))),128))]),_:1})])}const t1e=xe(J2e,[["render",e1e]]);T8.register();const n1e=100,r1e=3e4,o1e=3,a1e="scrollBehavior"in document.documentElement.style,i1e={name:"LTable",tagName:"l-table",components:{LTableHeader:l2e,LTableBody:Hhe,LTableReloader:b2e,LTableLoadMore:m2e,LTableEndspace:d2e,LTableBodySpacer:x2e,LTablePagination:t1e},props:{rows:{type:Array},primaryKey:{type:String,default:"id"},fetch:{type:Function},columns:{type:Array},pagination:{type:Boolean,default:!1},display:{type:String,enum:["all","more","paged"],default:"all"},autoLoadMore:{type:Boolean,default:!1},schema:{type:Object,required:!0},selectable:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},multiselect:{type:Boolean,default:!0},allowInvertedSelection:{type:Boolean,default:!0},rowHeight:{type:Number,default:32},borderTick:{type:Number,default:1},snapToPageOnMore:{type:Boolean,default:!0},stickyColumnLeft:{type:Boolean,default:!1},recycle:{type:Boolean,default:!0},limitPerPage:{type:Number,default:50}},emits:["loading","changeSelection","click-item"],mounted(){this.computeVisibleRows()},data(e){let t=[];return e.columns.length&&(t=e.columns.map(r=>this.buildColumnSpec(r))),{fetching:0,headerHeight:56,nonce:0,id:0,extraRows:15,lastComputedOffsetY:0,includedIds:[],excludedIds:[],scrollAtTop:!0,scrollAtLeft:!0,totalCount:0,firstPage:null,currentPage:null,lastPage:null,loadedPages:[],columnSpecs:t}},watch:{totalCount(e){this.$emit("changeSelection",{includedIds:this.includedIds,excludedIds:this.excludedIds,selectionCount:this.selectionCount,totalCount:e})},somePageIsLoading(e){this.$emit("loading",e)}},computed:{perPage(){return Number(this.limitPerPage)},pagesCount(){return Math.floor(this.totalCount/this.perPage)+1},selectionCount(){return this.includedIds.toString()==="*"?this.totalCount-this.excludedIds.length:this.includedIds.length},lastLoadedPage(){return this.loadedPages.length},isLoadMoreVisible(){return this.display==="more"&&this.lastLoadedPage<this.pagesCount},isPaginationVisible(){return(this.display==="page"||!!this.pagination)&&this.display!=="more"&&this.pagesCount!==null},isLeftColumnSticky(){return this.stickyColumnLeft||this.columns&&this.columns[0]&&this.columns[0].sticky},usingRecycledLayout(){return this.display!=="paged"&&this.recycle},hasVisibleFailedPages(){for(let e=this.firstPageRendered;e<=this.lastPageRendered;e++)if(this.loadedPages[e]&&this.loadedPages[e].failed)return!0;return!1},firstPageRendered(){return!this.usingRecycledLayout&&this.display!=="paged"?0:this.firstPage},lastPageRendered(){return this.display==="paged"?this.firstPage:this.usingRecycledLayout?this.lastPage:Math.max(0,this.lastLoadedPage-1)},visiblePages(){let e=[];for(let t=this.firstPageRendered;t<=this.lastPageRendered;t++){let r=this.loadedPages[t]||{index:t};e.push(r)}return e},contentStyle(){return{"--l-table-primary-color":"#2F8AF5","--l-table-warning-color":"#fd3a57","--l-table-bg-color":"white","--l-table-header-height":`${this.headerHeight}px`,"--l-table-header-text-color":"#232B34","--l-table-header-border-color":"#E8E8E8","--l-table-skeleton-height":`${Math.min(this.rowHeight-8,8)}px`,"--l-table-loader-height":"3px","--l-table-loader-color":"var(--l-table-primary-color)","--l-table-row-height":`${this.rowHeight}px`,"--l-table-cell-padding":"0 8px","--l-table-row-hover-color":"#fafbfd","--l-table-row-selected-color":"#eef5fa","--l-table-row-selected-hover-color":"#e6f0f8","--l-table-border-color":"#D3DAE6","--l-table-border-tick":`${this.borderTick}px`,"--l-table-selector-width":`${this.selectable?Math.min(this.headerHeight,this.rowHeight):0}px`,"--l-table-loadmore-height":"46px","--l-table-pagination-height":"48px","--l-table-pagination-color":"var(--l-table-primary-color)","--l-table-pagination-bg-color":"white","--l-table-reloader-margin":"16px","--l-table-endspace-bg-color":"#f5f5f5","--l-table-link-color":"var(--l-table-primary-color)"}},contentClasses(){return{"l-table-at-top":this.scrollAtTop,"l-table-at-left":this.scrollAtLeft,"l-table-sticky-column-left":this.isLeftColumnSticky}},spacing(){let e=0,t=0,r=this.display,o=this.totalCount;return r==="more"&&(o=this.loadedPages.length*this.perPage),(r==="all"||r==="more")&&(e=this.firstPageRendered*this.perPage*this.rowHeight,t=Math.max(0,(o-(this.lastPageRendered+1)*this.perPage)*this.rowHeight)),{top:Math.max(0,e),bottom:Math.max(0,t)}},rect(){return this.$refs.container.getBoundingClientRect()},somePageIsLoading(){return this.loadedPages.map(e=>e.loading).some(e=>e)}},methods:{itemToId(e){return e?this.primaryKey?e[this.primaryKey]:e:null},scrollTo(e=0,t){let r="auto";if(t){let o=this.$refs.container.scrollTop,a=this.perPage*this.rowHeight+1;r=Math.abs(o-e)<a?"smooth":"auto"}this.$refs.container.scrollTo({top:e,behavior:r})},gotoPage(e,t){if(e=Math.max(0,Math.min(this.pagesCount,e)),this.display==="paged"){this.setViewablePages(e,e,e),this.scrollTo(0,!0);return}this.display==="more"?this.setViewablePages(e-1,e,e):this.setViewablePages(e,e,e);let r=e*this.rowHeight*this.perPage;this.scrollTo(r,t)},async loadMore(e){let t=this.loadedPages[this.loadedPages.length-1];if(!t||t.loading)return!1;let r=this.loadedPages.length;this.setViewablePages(this.firstPage,r),e&&this.snapToPageOnMore&&a1e&&setTimeout(()=>this.gotoPage(r,!0),100)},reload(){this.id++,this.fetching=0,this.firstPage=null,this.lastPage=null,this.totalCount=null,this.loadedPages=[],this.includedIds=[],this.excludedIds=[],this.gotoPage(0),this.computeVisibleRows()},reloadFailedPages(){let e=0;for(let t=this.firstPageRendered;t<=this.lastPageRendered&&!(!(!this.loadedPages[t]||!this.loadedPages[t].failed)&&(this.loadedPages[t]=null,this.fetchPage(t),++e>=o1e));t++);},onScroll(){if(!(this.getScrollSpeed()>r1e)&&!this._scrollDebounce)return this.computeVisibleRows();clearTimeout(this._scrollDebounce),this._scrollDebounce=setTimeout(()=>{this.computeVisibleRows(),this._scrollDebounce=null},n1e)},getScrollSpeed(){let e=this._lastOffsetY||0,t=this._lastOffsetYTime||0,r=this._lastOffsetY=this.$refs.container.scrollTop,o=this._lastOffsetYTime=Date.now();return Math.abs(1e3*(e-r)/(o-t))},computeVisibleRows(){let e=this.$refs.container.scrollTop,t=this.$refs.container.scrollLeft,r=this.lastComputedOffsetY;this.scrollAtTop=e===0,this.scrollAtLeft=t===0;let o=Math.abs(r-e);if(e>2&&r>2&&o<150||(this.lastComputedOffsetY=e,this.display==="paged"))return;let i=this.rect.height-this.headerHeight,l=Math.max(0,Math.floor(e/this.rowHeight)),s=Math.ceil(i/this.rowHeight),c=l+s,u=this.extraRows,d=this.perPage,f=Math.floor((l-u)/this.perPage),p=Math.floor((c+u)/d),h=p>=this.pagesCount-1?s:s/2,m=Math.floor((l+h)/this.perPage);if(this.display==="more"){for(f=Math.min(f,this.lastLoadedPage);!this.loadedPages[f]&&f>0;)f--;for(p=Math.max(p,f);!this.loadedPages[p]&&p>f&&p>0;)p--}this.setViewablePages(f,p,m)},setViewablePages(e=0,t=0,r=0){this.display==="paged"&&(t=e),e=Math.min(Math.max(e,0),this.pagesCount-1),t=Math.min(Math.max(t,e),this.pagesCount-1),r=Math.min(t,Math.max(e,r||0));let o=e!==this.firstPage||t!==this.lastPage;this.firstPage=e,this.lastPage=t,this.currentPage=r,o&&this.scheduleFeching()},buildColumnSpec(e){if(!this.schema.fields)throw new Error("Missing schema.fields!");const t=this.schema.fields.find(o=>o.path===e.path);if(!t)throw new Error(`Missing field schema for path ${e.path}`);const r=this.$L.FieldTypeComponents.get(t,"default");return Object.assign({},t,{width:e.width||null,sortable:t?t.sortable:!1,sticky:t&&t.sticky||e.sticky||!1,align:t&&t.align||"left",column:e,field:t,component:r})},handleColumnSpecsUpdate(e){this.columnSpecs=e,this.reload()},changeSelection({key:e,selected:t}){const{includedIds:r,excludedIds:o}=G2e({key:e,selected:t},this);this.includedIds=r,this.excludedIds=o,this.$nextTick(()=>{this.$emit("changeSelection",{includedIds:this.includedIds,excludedIds:this.excludedIds,selectionCount:this.selectionCount,totalCount:this.totalCount})})},scheduleFeching(){for(let e=this.firstPage;e<=this.lastPage;e++)this.fetchPage(e)},async fetchPage(e){let t=this.loadedPages[e];if(t)return t;t=this.loadedPages[e]={id:this.id,index:e,startedAt:Date.now(),duration:null,loading:!0,loaded:!1,failed:!1,error:null,data:null};try{this.fetching++;const{hits:r,total:o}=await this.resolvePageData(e);Object.assign(t,{duration:Date.now()-t.startedAt,loading:!1,loaded:!0,data:r});let a=this.loadedPages.indexOf(t)>=0;o!==void 0&&a&&(this.totalCount=o)}catch(r){console.error("LTable","Failed to call `fetch` callback",r),Object.assign(t,{loading:!1,failed:!0,error:r.toString()})}finally{this.id===t.id&&this.fetching--}return t},async resolvePageData(e){if(this.rows){let t=this.perPage,r=e*t;return{data:this.rows.slice(r,r+t),total:this.rows.length}}else{if(this.fetch)return await this.fetch({page:e,offset:e*this.perPage,limit:this.perPage,schema:this.schema,columns:this.columns,perPage:this.perPage,primaryKey:this.primaryKey});throw new Error("Cannot discover data. Either `rows` or `fetch` property must be assigned to table")}}}},l1e={class:"l-table-table",border:"0"};function s1e(e,t,r,o,a,i){const l=n.resolveComponent("LTableHeader"),s=n.resolveComponent("LTableBodySpacer"),c=n.resolveComponent("LTableBody"),u=n.resolveComponent("LTableLoadMore"),d=n.resolveComponent("LTableEndspace"),f=n.resolveComponent("LTableReloader"),p=n.resolveComponent("LTablePagination");return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-table-container",i.contentClasses]),ref:"container",style:n.normalizeStyle(i.contentStyle),onScroll:t[7]||(t[7]=(...h)=>i.onScroll&&i.onScroll(...h))},[n.createElementVNode("table",l1e,[t[8]||(t[8]=n.createElementVNode("caption",{style:{display:"none"}}," Table Header ",-1)),n.createVNode(l,{height:a.headerHeight,selectable:r.selectable,columnSpecs:a.columnSpecs,loading:!!a.fetching,total:a.totalCount,includedIds:a.includedIds,excludedIds:a.excludedIds,multiselect:r.multiselect,onSelected:t[0]||(t[0]=h=>i.changeSelection(h)),"onColumnSpecs:update":i.handleColumnSpecsUpdate},null,8,["height","selectable","columnSpecs","loading","total","includedIds","excludedIds","multiselect","onColumnSpecs:update"]),n.createVNode(s,{height:i.spacing.top},null,8,["height"]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.visiblePages,h=>(n.openBlock(),n.createBlock(c,{key:`${h.index}-${h.loading}-${h.loaded}`,page:h,perPage:i.perPage,pagesCount:i.pagesCount,totalCount:a.totalCount,selectable:r.selectable,clickable:r.clickable,columnSpecs:a.columnSpecs,includedIds:a.includedIds,excludedIds:a.excludedIds,multiselect:r.multiselect,onClickItem:t[1]||(t[1]=m=>e.$emit("click-item",m)),onSelected:t[2]||(t[2]=m=>i.changeSelection(m))},null,8,["page","perPage","pagesCount","totalCount","selectable","clickable","columnSpecs","includedIds","excludedIds","multiselect"]))),128)),n.createVNode(s,{height:i.spacing.bottom},null,8,["height"])]),i.isLoadMoreVisible?(n.openBlock(),n.createBlock(u,{key:0,onClick:t[3]||(t[3]=h=>i.loadMore(!0)),onAppeared:t[4]||(t[4]=h=>i.loadMore()),automatic:r.autoLoadMore},null,8,["automatic"])):n.createCommentVNode("",!0),n.createVNode(d),n.createVNode(n.Transition,{name:"scale-up"},{default:n.withCtx(()=>[i.hasVisibleFailedPages?(n.openBlock(),n.createBlock(f,{key:0,onReload:t[5]||(t[5]=h=>i.reloadFailedPages())})):n.createCommentVNode("",!0)]),_:1}),i.isPaginationVisible?(n.openBlock(),n.createBlock(p,{key:1,currentPage:a.currentPage,pagesCount:i.pagesCount,totalCount:a.totalCount,onGoto:t[6]||(t[6]=h=>i.gotoPage(h))},null,8,["currentPage","pagesCount","totalCount"])):n.createCommentVNode("",!0)],38)}const c1e=xe(i1e,[["render",s1e]]),u1e=Object.freeze(Object.defineProperty({__proto__:null,default:c1e},Symbol.toStringTag,{value:"Module"}));const d1e={name:"LTabs",components:{ElTabs:lee},methods:{calcPaneInstances(e=!1){if(this.$slots.default){const r=this.$slots.default.filter(a=>a.tag&&a.componentOptions&&a.componentOptions.Ctor.options.tagName==="l-tab-pane").map(({componentInstance:a})=>a),o=!(r.length===this.panes.length&&r.every((a,i)=>a===this.panes[i]));(e||o)&&(this.panes=r)}else this.panes.length!==0&&(this.panes=[])}},data(){return{panes:[]}}};function f1e(e,t,r,o,a,i){const l=n.resolveComponent("el-tabs");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{class:"l-tabs"}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},16)}const p1e=xe(d1e,[["render",f1e],["__scopeId","data-v-556a0c7c"]]),m1e=Object.freeze(Object.defineProperty({__proto__:null,default:p1e},Symbol.toStringTag,{value:"Module"})),h1e={tagName:"l-target-chip",name:"LTargetChip",props:{kind:{type:String,required:!0},closeable:{type:Boolean,default:!1},name:{type:String,required:!0},count:{type:Number}},computed:{color:function(){return{member:"purple",group:"aqua",user:"link",tag:"warning",community:"danger",role:"lead-light"}[this.kind]||"lead"},icon:function(){return{member:"uil-graduation-cap",group:"uil-users-alt",user:"uil-user",tag:"uil-tag-alt",role:"uil-user",community:"uil-channel"}[this.kind]}}},g1e={class:"l-d-flex l-align-items"};function v1e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-chip");return n.openBlock(),n.createBlock(s,{style:{height:"24px"},bold:"",fill:"",color:i.color,icon:i.icon},{default:n.withCtx(()=>[n.createElementVNode("div",g1e,[n.createTextVNode(n.toDisplayString(r.count)+" "+n.toDisplayString(r.name)+" ",1),r.closeable?(n.openBlock(),n.createBlock(l,{key:0,onClick:t[0]||(t[0]=c=>e.$emit("remove")),class:"l-d-flex l-align-items-center ml-1 mr-0",style:{cursor:"pointer"},size:"15"},{default:n.withCtx(()=>t[1]||(t[1]=[n.createTextVNode(" uis-times-circle ")])),_:1})):n.createCommentVNode("",!0)])]),_:1},8,["color","icon"])}const y1e=xe(h1e,[["render",v1e]]),M1e=Object.freeze(Object.defineProperty({__proto__:null,default:y1e},Symbol.toStringTag,{value:"Module"}));const b1e={tagName:"l-target-input",name:"LTargetInput",props:{topics:{type:Array,required:!0},limit:{type:Number,default:3},editable:{type:Boolean,default:!1}},computed:{topicsToShow(){return this.topics.slice(0,this.limit)},moreTopicsText(){const e=this.topics.length-this.limit>1;return`+ ${this.topics.length-this.limit} destinatário`+(e?"s":"")}}};function w1e(e,t,r,o,a,i){const l=n.resolveComponent("l-target-chip"),s=n.resolveComponent("l-chip");return r.topics&&r.topics.length?(n.openBlock(),n.createElementBlock("div",{key:0,class:n.normalizeClass("l-target-input"+(r.editable?" editable":""))},[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.topicsToShow,c=>(n.openBlock(),n.createBlock(l,{kind:c.kind,name:c.name,key:c.id,class:"mr-2 mb-2"},null,8,["kind","name"]))),128)),r.topics.length>this.limit?(n.openBlock(),n.createBlock(s,{key:0,color:"purple",class:"mb-2",fill:"","hide-icon":""},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(i.moreTopicsText),1)]),_:1})):n.createCommentVNode("",!0)],2)):n.createCommentVNode("",!0)}const N1e=xe(b1e,[["render",w1e],["__scopeId","data-v-1da7433b"]]),k1e=Object.freeze(Object.defineProperty({__proto__:null,default:N1e},Symbol.toStringTag,{value:"Module"}));function nn(e){this.content=e}nn.prototype={constructor:nn,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,r){var o=r&&r!=e?this.remove(r):this,a=o.find(e),i=o.content.slice();return a==-1?i.push(r||e,t):(i[a+1]=t,r&&(i[a]=r)),new nn(i)},remove:function(e){var t=this.find(e);if(t==-1)return this;var r=this.content.slice();return r.splice(t,2),new nn(r)},addToStart:function(e,t){return new nn([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var r=this.remove(e).content.slice();return r.push(e,t),new nn(r)},addBefore:function(e,t,r){var o=this.remove(t),a=o.content.slice(),i=o.find(e);return a.splice(i==-1?a.length:i,0,t,r),new nn(a)},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=nn.from(e),e.size?new nn(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=nn.from(e),e.size?new nn(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=nn.from(e);for(var r=0;r<e.content.length;r+=2)t=t.remove(e.content[r]);return t},toObject:function(){var e={};return this.forEach(function(t,r){e[t]=r}),e},get size(){return this.content.length>>1}};nn.from=function(e){if(e instanceof nn)return e;var t=[];if(e)for(var r in e)t.push(r,e[r]);return new nn(t)};function D8(e,t,r){for(let o=0;;o++){if(o==e.childCount||o==t.childCount)return e.childCount==t.childCount?null:r;let a=e.child(o),i=t.child(o);if(a==i){r+=a.nodeSize;continue}if(!a.sameMarkup(i))return r;if(a.isText&&a.text!=i.text){for(let l=0;a.text[l]==i.text[l];l++)r++;return r}if(a.content.size||i.content.size){let l=D8(a.content,i.content,r+1);if(l!=null)return l}r+=a.nodeSize}}function S8(e,t,r,o){for(let a=e.childCount,i=t.childCount;;){if(a==0||i==0)return a==i?null:{a:r,b:o};let l=e.child(--a),s=t.child(--i),c=l.nodeSize;if(l==s){r-=c,o-=c;continue}if(!l.sameMarkup(s))return{a:r,b:o};if(l.isText&&l.text!=s.text){let u=0,d=Math.min(l.text.length,s.text.length);for(;u<d&&l.text[l.text.length-u-1]==s.text[s.text.length-u-1];)u++,r--,o--;return{a:r,b:o}}if(l.content.size||s.content.size){let u=S8(l.content,s.content,r-1,o-1);if(u)return u}r-=c,o-=c}}class fe{constructor(t,r){if(this.content=t,this.size=r||0,r==null)for(let o=0;o<t.length;o++)this.size+=t[o].nodeSize}nodesBetween(t,r,o,a=0,i){for(let l=0,s=0;s<r;l++){let c=this.content[l],u=s+c.nodeSize;if(u>t&&o(c,a+s,i||null,l)!==!1&&c.content.size){let d=s+1;c.nodesBetween(Math.max(0,t-d),Math.min(c.content.size,r-d),o,a+d)}s=u}}descendants(t){this.nodesBetween(0,this.size,t)}textBetween(t,r,o,a){let i="",l=!0;return this.nodesBetween(t,r,(s,c)=>{let u=s.isText?s.text.slice(Math.max(t,c)-c,r-c):s.isLeaf?a?typeof a=="function"?a(s):a:s.type.spec.leafText?s.type.spec.leafText(s):"":"";s.isBlock&&(s.isLeaf&&u||s.isTextblock)&&o&&(l?l=!1:i+=o),i+=u},0),i}append(t){if(!t.size)return this;if(!this.size)return t;let r=this.lastChild,o=t.firstChild,a=this.content.slice(),i=0;for(r.isText&&r.sameMarkup(o)&&(a[a.length-1]=r.withText(r.text+o.text),i=1);i<t.content.length;i++)a.push(t.content[i]);return new fe(a,this.size+t.size)}cut(t,r=this.size){if(t==0&&r==this.size)return this;let o=[],a=0;if(r>t)for(let i=0,l=0;l<r;i++){let s=this.content[i],c=l+s.nodeSize;c>t&&((l<t||c>r)&&(s.isText?s=s.cut(Math.max(0,t-l),Math.min(s.text.length,r-l)):s=s.cut(Math.max(0,t-l-1),Math.min(s.content.size,r-l-1))),o.push(s),a+=s.nodeSize),l=c}return new fe(o,a)}cutByIndex(t,r){return t==r?fe.empty:t==0&&r==this.content.length?this:new fe(this.content.slice(t,r))}replaceChild(t,r){let o=this.content[t];if(o==r)return this;let a=this.content.slice(),i=this.size+r.nodeSize-o.nodeSize;return a[t]=r,new fe(a,i)}addToStart(t){return new fe([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new fe(this.content.concat(t),this.size+t.nodeSize)}eq(t){if(this.content.length!=t.content.length)return!1;for(let r=0;r<this.content.length;r++)if(!this.content[r].eq(t.content[r]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(t){let r=this.content[t];if(!r)throw new RangeError("Index "+t+" out of range for "+this);return r}maybeChild(t){return this.content[t]||null}forEach(t){for(let r=0,o=0;r<this.content.length;r++){let a=this.content[r];t(a,o,r),o+=a.nodeSize}}findDiffStart(t,r=0){return D8(this,t,r)}findDiffEnd(t,r=this.size,o=t.size){return S8(this,t,r,o)}findIndex(t,r=-1){if(t==0)return kc(0,t);if(t==this.size)return kc(this.content.length,t);if(t>this.size||t<0)throw new RangeError(`Position ${t} outside of fragment (${this})`);for(let o=0,a=0;;o++){let i=this.child(o),l=a+i.nodeSize;if(l>=t)return l==t||r>0?kc(o+1,l):kc(o,a);a=l}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(t=>t.toJSON()):null}static fromJSON(t,r){if(!r)return fe.empty;if(!Array.isArray(r))throw new RangeError("Invalid input for Fragment.fromJSON");return new fe(r.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return fe.empty;let r,o=0;for(let a=0;a<t.length;a++){let i=t[a];o+=i.nodeSize,a&&i.isText&&t[a-1].sameMarkup(i)?(r||(r=t.slice(0,a)),r[r.length-1]=i.withText(r[r.length-1].text+i.text)):r&&r.push(i)}return new fe(r||t,o)}static from(t){if(!t)return fe.empty;if(t instanceof fe)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new fe([t],t.nodeSize);throw new RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}fe.empty=new fe([],0);const Wf={index:0,offset:0};function kc(e,t){return Wf.index=e,Wf.offset=t,Wf}function Tu(e,t){if(e===t)return!0;if(!(e&&typeof e=="object")||!(t&&typeof t=="object"))return!1;let r=Array.isArray(e);if(Array.isArray(t)!=r)return!1;if(r){if(e.length!=t.length)return!1;for(let o=0;o<e.length;o++)if(!Tu(e[o],t[o]))return!1}else{for(let o in e)if(!(o in t)||!Tu(e[o],t[o]))return!1;for(let o in t)if(!(o in e))return!1}return!0}let gt=class w0{constructor(t,r){this.type=t,this.attrs=r}addToSet(t){let r,o=!1;for(let a=0;a<t.length;a++){let i=t[a];if(this.eq(i))return t;if(this.type.excludes(i.type))r||(r=t.slice(0,a));else{if(i.type.excludes(this.type))return t;!o&&i.type.rank>this.type.rank&&(r||(r=t.slice(0,a)),r.push(this),o=!0),r&&r.push(i)}}return r||(r=t.slice()),o||r.push(this),r}removeFromSet(t){for(let r=0;r<t.length;r++)if(this.eq(t[r]))return t.slice(0,r).concat(t.slice(r+1));return t}isInSet(t){for(let r=0;r<t.length;r++)if(this.eq(t[r]))return!0;return!1}eq(t){return this==t||this.type==t.type&&Tu(this.attrs,t.attrs)}toJSON(){let t={type:this.type.name};for(let r in this.attrs){t.attrs=this.attrs;break}return t}static fromJSON(t,r){if(!r)throw new RangeError("Invalid input for Mark.fromJSON");let o=t.marks[r.type];if(!o)throw new RangeError(`There is no mark type ${r.type} in this schema`);let a=o.create(r.attrs);return o.checkAttrs(a.attrs),a}static sameSet(t,r){if(t==r)return!0;if(t.length!=r.length)return!1;for(let o=0;o<t.length;o++)if(!t[o].eq(r[o]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return w0.none;if(t instanceof w0)return[t];let r=t.slice();return r.sort((o,a)=>o.type.rank-a.type.rank),r}};gt.none=[];class Du extends Error{}class Ee{constructor(t,r,o){this.content=t,this.openStart=r,this.openEnd=o}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,r){let o=I8(this.content,t+this.openStart,r);return o&&new Ee(o,this.openStart,this.openEnd)}removeBetween(t,r){return new Ee(_8(this.content,t+this.openStart,r+this.openStart),this.openStart,this.openEnd)}eq(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}static fromJSON(t,r){if(!r)return Ee.empty;let o=r.openStart||0,a=r.openEnd||0;if(typeof o!="number"||typeof a!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new Ee(fe.fromJSON(t,r.content),o,a)}static maxOpen(t,r=!0){let o=0,a=0;for(let i=t.firstChild;i&&!i.isLeaf&&(r||!i.type.spec.isolating);i=i.firstChild)o++;for(let i=t.lastChild;i&&!i.isLeaf&&(r||!i.type.spec.isolating);i=i.lastChild)a++;return new Ee(t,o,a)}}Ee.empty=new Ee(fe.empty,0,0);function _8(e,t,r){let{index:o,offset:a}=e.findIndex(t),i=e.maybeChild(o),{index:l,offset:s}=e.findIndex(r);if(a==t||i.isText){if(s!=r&&!e.child(l).isText)throw new RangeError("Removing non-flat range");return e.cut(0,t).append(e.cut(r))}if(o!=l)throw new RangeError("Removing non-flat range");return e.replaceChild(o,i.copy(_8(i.content,t-a-1,r-a-1)))}function I8(e,t,r,o){let{index:a,offset:i}=e.findIndex(t),l=e.maybeChild(a);if(i==t||l.isText)return o&&!o.canReplace(a,a,r)?null:e.cut(0,t).append(r).append(e.cut(t));let s=I8(l.content,t-i-1,r);return s&&e.replaceChild(a,l.copy(s))}function x1e(e,t,r){if(r.openStart>e.depth)throw new Du("Inserted content deeper than insertion position");if(e.depth-r.openStart!=t.depth-r.openEnd)throw new Du("Inconsistent open depths");return A8(e,t,r,0)}function A8(e,t,r,o){let a=e.index(o),i=e.node(o);if(a==t.index(o)&&o<e.depth-r.openStart){let l=A8(e,t,r,o+1);return i.copy(i.content.replaceChild(a,l))}else if(r.content.size)if(!r.openStart&&!r.openEnd&&e.depth==o&&t.depth==o){let l=e.parent,s=l.content;return _a(l,s.cut(0,e.parentOffset).append(r.content).append(s.cut(t.parentOffset)))}else{let{start:l,end:s}=C1e(r,e);return _a(i,z8(e,l,s,t,o))}else return _a(i,Su(e,t,o))}function O8(e,t){if(!t.type.compatibleContent(e.type))throw new Du("Cannot join "+t.type.name+" onto "+e.type.name)}function N0(e,t,r){let o=e.node(r);return O8(o,t.node(r)),o}function Sa(e,t){let r=t.length-1;r>=0&&e.isText&&e.sameMarkup(t[r])?t[r]=e.withText(t[r].text+e.text):t.push(e)}function Hl(e,t,r,o){let a=(t||e).node(r),i=0,l=t?t.index(r):a.childCount;e&&(i=e.index(r),e.depth>r?i++:e.textOffset&&(Sa(e.nodeAfter,o),i++));for(let s=i;s<l;s++)Sa(a.child(s),o);t&&t.depth==r&&t.textOffset&&Sa(t.nodeBefore,o)}function _a(e,t){return e.type.checkContent(t),e.copy(t)}function z8(e,t,r,o,a){let i=e.depth>a&&N0(e,t,a+1),l=o.depth>a&&N0(r,o,a+1),s=[];return Hl(null,e,a,s),i&&l&&t.index(a)==r.index(a)?(O8(i,l),Sa(_a(i,z8(e,t,r,o,a+1)),s)):(i&&Sa(_a(i,Su(e,t,a+1)),s),Hl(t,r,a,s),l&&Sa(_a(l,Su(r,o,a+1)),s)),Hl(o,null,a,s),new fe(s)}function Su(e,t,r){let o=[];if(Hl(null,e,r,o),e.depth>r){let a=N0(e,t,r+1);Sa(_a(a,Su(e,t,r+1)),o)}return Hl(t,null,r,o),new fe(o)}function C1e(e,t){let r=t.depth-e.openStart,a=t.node(r).copy(e.content);for(let i=r-1;i>=0;i--)a=t.node(i).copy(fe.from(a));return{start:a.resolveNoCache(e.openStart+r),end:a.resolveNoCache(a.content.size-e.openEnd-r)}}class ks{constructor(t,r,o){this.pos=t,this.path=r,this.parentOffset=o,this.depth=r.length/3-1}resolveDepth(t){return t==null?this.depth:t<0?this.depth+t:t}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(t){return this.path[this.resolveDepth(t)*3]}index(t){return this.path[this.resolveDepth(t)*3+1]}indexAfter(t){return t=this.resolveDepth(t),this.index(t)+(t==this.depth&&!this.textOffset?0:1)}start(t){return t=this.resolveDepth(t),t==0?0:this.path[t*3-1]+1}end(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}before(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]}after(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]+this.path[t*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let t=this.parent,r=this.index(this.depth);if(r==t.childCount)return null;let o=this.pos-this.path[this.path.length-1],a=t.child(r);return o?t.child(r).cut(o):a}get nodeBefore(){let t=this.index(this.depth),r=this.pos-this.path[this.path.length-1];return r?this.parent.child(t).cut(0,r):t==0?null:this.parent.child(t-1)}posAtIndex(t,r){r=this.resolveDepth(r);let o=this.path[r*3],a=r==0?0:this.path[r*3-1]+1;for(let i=0;i<t;i++)a+=o.child(i).nodeSize;return a}marks(){let t=this.parent,r=this.index();if(t.content.size==0)return gt.none;if(this.textOffset)return t.child(r).marks;let o=t.maybeChild(r-1),a=t.maybeChild(r);if(!o){let s=o;o=a,a=s}let i=o.marks;for(var l=0;l<i.length;l++)i[l].type.spec.inclusive===!1&&(!a||!i[l].isInSet(a.marks))&&(i=i[l--].removeFromSet(i));return i}marksAcross(t){let r=this.parent.maybeChild(this.index());if(!r||!r.isInline)return null;let o=r.marks,a=t.parent.maybeChild(t.index());for(var i=0;i<o.length;i++)o[i].type.spec.inclusive===!1&&(!a||!o[i].isInSet(a.marks))&&(o=o[i--].removeFromSet(o));return o}sharedDepth(t){for(let r=this.depth;r>0;r--)if(this.start(r)<=t&&this.end(r)>=t)return r;return 0}blockRange(t=this,r){if(t.pos<this.pos)return t.blockRange(this);for(let o=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);o>=0;o--)if(t.pos<=this.end(o)&&(!r||r(this.node(o))))return new _u(this,t,o);return null}sameParent(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}max(t){return t.pos>this.pos?t:this}min(t){return t.pos<this.pos?t:this}toString(){let t="";for(let r=1;r<=this.depth;r++)t+=(t?"/":"")+this.node(r).type.name+"_"+this.index(r-1);return t+":"+this.parentOffset}static resolve(t,r){if(!(r>=0&&r<=t.content.size))throw new RangeError("Position "+r+" out of range");let o=[],a=0,i=r;for(let l=t;;){let{index:s,offset:c}=l.content.findIndex(i),u=i-c;if(o.push(l,s,a+c),!u||(l=l.child(s),l.isText))break;i=u-1,a+=c+1}return new ks(r,o,i)}static resolveCached(t,r){let o=z4.get(t);if(o)for(let i=0;i<o.elts.length;i++){let l=o.elts[i];if(l.pos==r)return l}else z4.set(t,o=new E1e);let a=o.elts[o.i]=ks.resolve(t,r);return o.i=(o.i+1)%T1e,a}}class E1e{constructor(){this.elts=[],this.i=0}}const T1e=12,z4=new WeakMap;class _u{constructor(t,r,o){this.$from=t,this.$to=r,this.depth=o}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const D1e=Object.create(null);let Ia=class k0{constructor(t,r,o,a=gt.none){this.type=t,this.attrs=r,this.marks=a,this.content=o||fe.empty}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(t){return this.content.child(t)}maybeChild(t){return this.content.maybeChild(t)}forEach(t){this.content.forEach(t)}nodesBetween(t,r,o,a=0){this.content.nodesBetween(t,r,o,a,this)}descendants(t){this.nodesBetween(0,this.content.size,t)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(t,r,o,a){return this.content.textBetween(t,r,o,a)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}sameMarkup(t){return this.hasMarkup(t.type,t.attrs,t.marks)}hasMarkup(t,r,o){return this.type==t&&Tu(this.attrs,r||t.defaultAttrs||D1e)&>.sameSet(this.marks,o||gt.none)}copy(t=null){return t==this.content?this:new k0(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new k0(this.type,this.attrs,this.content,t)}cut(t,r=this.content.size){return t==0&&r==this.content.size?this:this.copy(this.content.cut(t,r))}slice(t,r=this.content.size,o=!1){if(t==r)return Ee.empty;let a=this.resolve(t),i=this.resolve(r),l=o?0:a.sharedDepth(r),s=a.start(l),u=a.node(l).content.cut(a.pos-s,i.pos-s);return new Ee(u,a.depth-l,i.depth-l)}replace(t,r,o){return x1e(this.resolve(t),this.resolve(r),o)}nodeAt(t){for(let r=this;;){let{index:o,offset:a}=r.content.findIndex(t);if(r=r.maybeChild(o),!r)return null;if(a==t||r.isText)return r;t-=a+1}}childAfter(t){let{index:r,offset:o}=this.content.findIndex(t);return{node:this.content.maybeChild(r),index:r,offset:o}}childBefore(t){if(t==0)return{node:null,index:0,offset:0};let{index:r,offset:o}=this.content.findIndex(t);if(o<t)return{node:this.content.child(r),index:r,offset:o};let a=this.content.child(r-1);return{node:a,index:r-1,offset:o-a.nodeSize}}resolve(t){return ks.resolveCached(this,t)}resolveNoCache(t){return ks.resolve(this,t)}rangeHasMark(t,r,o){let a=!1;return r>t&&this.nodesBetween(t,r,i=>(o.isInSet(i.marks)&&(a=!0),!a)),a}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),j8(this.marks,t)}contentMatchAt(t){let r=this.type.contentMatch.matchFragment(this.content,0,t);if(!r)throw new Error("Called contentMatchAt on a node with invalid content");return r}canReplace(t,r,o=fe.empty,a=0,i=o.childCount){let l=this.contentMatchAt(t).matchFragment(o,a,i),s=l&&l.matchFragment(this.content,r);if(!s||!s.validEnd)return!1;for(let c=a;c<i;c++)if(!this.type.allowsMarks(o.child(c).marks))return!1;return!0}canReplaceWith(t,r,o,a){if(a&&!this.type.allowsMarks(a))return!1;let i=this.contentMatchAt(t).matchType(o),l=i&&i.matchFragment(this.content,r);return l?l.validEnd:!1}canAppend(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let t=gt.none;for(let r=0;r<this.marks.length;r++){let o=this.marks[r];o.type.checkAttrs(o.attrs),t=o.addToSet(t)}if(!gt.sameSet(t,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(r=>r.type.name)}`);this.content.forEach(r=>r.check())}toJSON(){let t={type:this.type.name};for(let r in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map(r=>r.toJSON())),t}static fromJSON(t,r){if(!r)throw new RangeError("Invalid input for Node.fromJSON");let o;if(r.marks){if(!Array.isArray(r.marks))throw new RangeError("Invalid mark data for Node.fromJSON");o=r.marks.map(t.markFromJSON)}if(r.type=="text"){if(typeof r.text!="string")throw new RangeError("Invalid text node in JSON");return t.text(r.text,o)}let a=fe.fromJSON(t,r.content),i=t.nodeType(r.type).create(r.attrs,a,o);return i.type.checkAttrs(i.attrs),i}};Ia.prototype.text=void 0;class Iu extends Ia{constructor(t,r,o,a){if(super(t,r,null,a),!o)throw new RangeError("Empty text nodes are not allowed");this.text=o}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):j8(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(t,r){return this.text.slice(t,r)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new Iu(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new Iu(this.type,this.attrs,t,this.marks)}cut(t=0,r=this.text.length){return t==0&&r==this.text.length?this:this.withText(this.text.slice(t,r))}eq(t){return this.sameMarkup(t)&&this.text==t.text}toJSON(){let t=super.toJSON();return t.text=this.text,t}}function j8(e,t){for(let r=e.length-1;r>=0;r--)t=e[r].type.name+"("+t+")";return t}class Pa{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,r){let o=new S1e(t,r);if(o.next==null)return Pa.empty;let a=L8(o);o.next&&o.err("Unexpected trailing text");let i=L1e(j1e(a));return B1e(i,o),i}matchType(t){for(let r=0;r<this.next.length;r++)if(this.next[r].type==t)return this.next[r].next;return null}matchFragment(t,r=0,o=t.childCount){let a=this;for(let i=r;a&&i<o;i++)a=a.matchType(t.child(i).type);return a}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let t=0;t<this.next.length;t++){let{type:r}=this.next[t];if(!(r.isText||r.hasRequiredAttrs()))return r}return null}compatible(t){for(let r=0;r<this.next.length;r++)for(let o=0;o<t.next.length;o++)if(this.next[r].type==t.next[o].type)return!0;return!1}fillBefore(t,r=!1,o=0){let a=[this];function i(l,s){let c=l.matchFragment(t,o);if(c&&(!r||c.validEnd))return fe.from(s.map(u=>u.createAndFill()));for(let u=0;u<l.next.length;u++){let{type:d,next:f}=l.next[u];if(!(d.isText||d.hasRequiredAttrs())&&a.indexOf(f)==-1){a.push(f);let p=i(f,s.concat(d));if(p)return p}}return null}return i(this,[])}findWrapping(t){for(let o=0;o<this.wrapCache.length;o+=2)if(this.wrapCache[o]==t)return this.wrapCache[o+1];let r=this.computeWrapping(t);return this.wrapCache.push(t,r),r}computeWrapping(t){let r=Object.create(null),o=[{match:this,type:null,via:null}];for(;o.length;){let a=o.shift(),i=a.match;if(i.matchType(t)){let l=[];for(let s=a;s.type;s=s.via)l.push(s.type);return l.reverse()}for(let l=0;l<i.next.length;l++){let{type:s,next:c}=i.next[l];!s.isLeaf&&!s.hasRequiredAttrs()&&!(s.name in r)&&(!a.type||c.validEnd)&&(o.push({match:s.contentMatch,type:s,via:a}),r[s.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(t){if(t>=this.next.length)throw new RangeError(`There's no ${t}th edge in this content match`);return this.next[t]}toString(){let t=[];function r(o){t.push(o);for(let a=0;a<o.next.length;a++)t.indexOf(o.next[a].next)==-1&&r(o.next[a].next)}return r(this),t.map((o,a)=>{let i=a+(o.validEnd?"*":" ")+" ";for(let l=0;l<o.next.length;l++)i+=(l?", ":"")+o.next[l].type.name+"->"+t.indexOf(o.next[l].next);return i}).join(`
|
|
48
|
+
`)}}Pa.empty=new Pa(!0);class S1e{constructor(t,r){this.string=t,this.nodeTypes=r,this.inline=null,this.pos=0,this.tokens=t.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(t){return this.next==t&&(this.pos++||!0)}err(t){throw new SyntaxError(t+" (in content expression '"+this.string+"')")}}function L8(e){let t=[];do t.push(_1e(e));while(e.eat("|"));return t.length==1?t[0]:{type:"choice",exprs:t}}function _1e(e){let t=[];do t.push(I1e(e));while(e.next&&e.next!=")"&&e.next!="|");return t.length==1?t[0]:{type:"seq",exprs:t}}function I1e(e){let t=z1e(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=A1e(e,t);else break;return t}function j4(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function A1e(e,t){let r=j4(e),o=r;return e.eat(",")&&(e.next!="}"?o=j4(e):o=-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:r,max:o,expr:t}}function O1e(e,t){let r=e.nodeTypes,o=r[t];if(o)return[o];let a=[];for(let i in r){let l=r[i];l.isInGroup(t)&&a.push(l)}return a.length==0&&e.err("No node type or group '"+t+"' found"),a}function z1e(e){if(e.eat("(")){let t=L8(e);return e.eat(")")||e.err("Missing closing paren"),t}else if(/\W/.test(e.next))e.err("Unexpected token '"+e.next+"'");else{let t=O1e(e,e.next).map(r=>(e.inline==null?e.inline=r.isInline:e.inline!=r.isInline&&e.err("Mixing inline and block content"),{type:"name",value:r}));return e.pos++,t.length==1?t[0]:{type:"choice",exprs:t}}}function j1e(e){let t=[[]];return a(i(e,0),r()),t;function r(){return t.push([])-1}function o(l,s,c){let u={term:c,to:s};return t[l].push(u),u}function a(l,s){l.forEach(c=>c.to=s)}function i(l,s){if(l.type=="choice")return l.exprs.reduce((c,u)=>c.concat(i(u,s)),[]);if(l.type=="seq")for(let c=0;;c++){let u=i(l.exprs[c],s);if(c==l.exprs.length-1)return u;a(u,s=r())}else if(l.type=="star"){let c=r();return o(s,c),a(i(l.expr,c),c),[o(c)]}else if(l.type=="plus"){let c=r();return a(i(l.expr,s),c),a(i(l.expr,c),c),[o(c)]}else{if(l.type=="opt")return[o(s)].concat(i(l.expr,s));if(l.type=="range"){let c=s;for(let u=0;u<l.min;u++){let d=r();a(i(l.expr,c),d),c=d}if(l.max==-1)a(i(l.expr,c),c);else for(let u=l.min;u<l.max;u++){let d=r();o(c,d),a(i(l.expr,c),d),c=d}return[o(c)]}else{if(l.type=="name")return[o(s,void 0,l.value)];throw new Error("Unknown expr type")}}}}function B8(e,t){return t-e}function L4(e,t){let r=[];return o(t),r.sort(B8);function o(a){let i=e[a];if(i.length==1&&!i[0].term)return o(i[0].to);r.push(a);for(let l=0;l<i.length;l++){let{term:s,to:c}=i[l];!s&&r.indexOf(c)==-1&&o(c)}}}function L1e(e){let t=Object.create(null);return r(L4(e,0));function r(o){let a=[];o.forEach(l=>{e[l].forEach(({term:s,to:c})=>{if(!s)return;let u;for(let d=0;d<a.length;d++)a[d][0]==s&&(u=a[d][1]);L4(e,c).forEach(d=>{u||a.push([s,u=[]]),u.indexOf(d)==-1&&u.push(d)})})});let i=t[o.join(",")]=new Pa(o.indexOf(e.length-1)>-1);for(let l=0;l<a.length;l++){let s=a[l][1].sort(B8);i.next.push({type:a[l][0],next:t[s.join(",")]||r(s)})}return i}}function B1e(e,t){for(let r=0,o=[e];r<o.length;r++){let a=o[r],i=!a.validEnd,l=[];for(let s=0;s<a.next.length;s++){let{type:c,next:u}=a.next[s];l.push(c.name),i&&!(c.isText||c.hasRequiredAttrs())&&(i=!1),o.indexOf(u)==-1&&o.push(u)}i&&t.err("Only non-generatable nodes ("+l.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function V8(e){let t=Object.create(null);for(let r in e){let o=e[r];if(!o.hasDefault)return null;t[r]=o.default}return t}function $8(e,t){let r=Object.create(null);for(let o in e){let a=t&&t[o];if(a===void 0){let i=e[o];if(i.hasDefault)a=i.default;else throw new RangeError("No value supplied for attribute "+o)}r[o]=a}return r}function P8(e,t,r,o){for(let a in t)if(!(a in e))throw new RangeError(`Unsupported attribute ${a} for ${r} of type ${a}`);for(let a in e){let i=e[a];i.validate&&i.validate(t[a])}}function R8(e,t){let r=Object.create(null);if(t)for(let o in t)r[o]=new $1e(e,o,t[o]);return r}let B4=class F8{constructor(t,r,o){this.name=t,this.schema=r,this.spec=o,this.markSet=null,this.groups=o.group?o.group.split(" "):[],this.attrs=R8(t,o.attrs),this.defaultAttrs=V8(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(o.inline||t=="text"),this.isText=t=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==Pa.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(t){return this.groups.indexOf(t)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let t in this.attrs)if(this.attrs[t].isRequired)return!0;return!1}compatibleContent(t){return this==t||this.contentMatch.compatible(t.contentMatch)}computeAttrs(t){return!t&&this.defaultAttrs?this.defaultAttrs:$8(this.attrs,t)}create(t=null,r,o){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new Ia(this,this.computeAttrs(t),fe.from(r),gt.setFrom(o))}createChecked(t=null,r,o){return r=fe.from(r),this.checkContent(r),new Ia(this,this.computeAttrs(t),r,gt.setFrom(o))}createAndFill(t=null,r,o){if(t=this.computeAttrs(t),r=fe.from(r),r.size){let l=this.contentMatch.fillBefore(r);if(!l)return null;r=l.append(r)}let a=this.contentMatch.matchFragment(r),i=a&&a.fillBefore(fe.empty,!0);return i?new Ia(this,t,r.append(i),gt.setFrom(o)):null}validContent(t){let r=this.contentMatch.matchFragment(t);if(!r||!r.validEnd)return!1;for(let o=0;o<t.childCount;o++)if(!this.allowsMarks(t.child(o).marks))return!1;return!0}checkContent(t){if(!this.validContent(t))throw new RangeError(`Invalid content for node ${this.name}: ${t.toString().slice(0,50)}`)}checkAttrs(t){P8(this.attrs,t,"node",this.name)}allowsMarkType(t){return this.markSet==null||this.markSet.indexOf(t)>-1}allowsMarks(t){if(this.markSet==null)return!0;for(let r=0;r<t.length;r++)if(!this.allowsMarkType(t[r].type))return!1;return!0}allowedMarks(t){if(this.markSet==null)return t;let r;for(let o=0;o<t.length;o++)this.allowsMarkType(t[o].type)?r&&r.push(t[o]):r||(r=t.slice(0,o));return r?r.length?r:gt.none:t}static compile(t,r){let o=Object.create(null);t.forEach((i,l)=>o[i]=new F8(i,r,l));let a=r.spec.topNode||"doc";if(!o[a])throw new RangeError("Schema is missing its top node type ('"+a+"')");if(!o.text)throw new RangeError("Every schema needs a 'text' type");for(let i in o.text.attrs)throw new RangeError("The text node type should not have attributes");return o}};function V1e(e,t,r){let o=r.split("|");return a=>{let i=a===null?"null":typeof a;if(o.indexOf(i)<0)throw new RangeError(`Expected value of type ${o} for attribute ${t} on type ${e}, got ${i}`)}}class $1e{constructor(t,r,o){this.hasDefault=Object.prototype.hasOwnProperty.call(o,"default"),this.default=o.default,this.validate=typeof o.validate=="string"?V1e(t,r,o.validate):o.validate}get isRequired(){return!this.hasDefault}}class nf{constructor(t,r,o,a){this.name=t,this.rank=r,this.schema=o,this.spec=a,this.attrs=R8(t,a.attrs),this.excluded=null;let i=V8(this.attrs);this.instance=i?new gt(this,i):null}create(t=null){return!t&&this.instance?this.instance:new gt(this,$8(this.attrs,t))}static compile(t,r){let o=Object.create(null),a=0;return t.forEach((i,l)=>o[i]=new nf(i,a++,r,l)),o}removeFromSet(t){for(var r=0;r<t.length;r++)t[r].type==this&&(t=t.slice(0,r).concat(t.slice(r+1)),r--);return t}isInSet(t){for(let r=0;r<t.length;r++)if(t[r].type==this)return t[r]}checkAttrs(t){P8(this.attrs,t,"mark",this.name)}excludes(t){return this.excluded.indexOf(t)>-1}}class U8{constructor(t){this.linebreakReplacement=null,this.cached=Object.create(null);let r=this.spec={};for(let a in t)r[a]=t[a];r.nodes=nn.from(t.nodes),r.marks=nn.from(t.marks||{}),this.nodes=B4.compile(this.spec.nodes,this),this.marks=nf.compile(this.spec.marks,this);let o=Object.create(null);for(let a in this.nodes){if(a in this.marks)throw new RangeError(a+" can not be both a node and a mark");let i=this.nodes[a],l=i.spec.content||"",s=i.spec.marks;if(i.contentMatch=o[l]||(o[l]=Pa.parse(l,this.nodes)),i.inlineContent=i.contentMatch.inlineContent,i.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!i.isInline||!i.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=i}i.markSet=s=="_"?null:s?V4(this,s.split(" ")):s==""||!i.inlineContent?[]:null}for(let a in this.marks){let i=this.marks[a],l=i.spec.excludes;i.excluded=l==null?[i]:l==""?[]:V4(this,l.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(t,r=null,o,a){if(typeof t=="string")t=this.nodeType(t);else if(t instanceof B4){if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}else throw new RangeError("Invalid node type: "+t);return t.createChecked(r,o,a)}text(t,r){let o=this.nodes.text;return new Iu(o,o.defaultAttrs,t,gt.setFrom(r))}mark(t,r){return typeof t=="string"&&(t=this.marks[t]),t.create(r)}nodeFromJSON(t){return Ia.fromJSON(this,t)}markFromJSON(t){return gt.fromJSON(this,t)}nodeType(t){let r=this.nodes[t];if(!r)throw new RangeError("Unknown node type: "+t);return r}}function V4(e,t){let r=[];for(let o=0;o<t.length;o++){let a=t[o],i=e.marks[a],l=i;if(i)r.push(i);else for(let s in e.marks){let c=e.marks[s];(a=="_"||c.spec.group&&c.spec.group.split(" ").indexOf(a)>-1)&&r.push(l=c)}if(!l)throw new SyntaxError("Unknown mark type: '"+t[o]+"'")}return r}function P1e(e){return e.tag!=null}function R1e(e){return e.style!=null}class Go{constructor(t,r){this.schema=t,this.rules=r,this.tags=[],this.styles=[];let o=this.matchedStyles=[];r.forEach(a=>{if(P1e(a))this.tags.push(a);else if(R1e(a)){let i=/[^=]*/.exec(a.style)[0];o.indexOf(i)<0&&o.push(i),this.styles.push(a)}}),this.normalizeLists=!this.tags.some(a=>{if(!/^(ul|ol)\b/.test(a.tag)||!a.node)return!1;let i=t.nodes[a.node];return i.contentMatch.matchType(i)})}parse(t,r={}){let o=new P4(this,r,!1);return o.addAll(t,gt.none,r.from,r.to),o.finish()}parseSlice(t,r={}){let o=new P4(this,r,!0);return o.addAll(t,gt.none,r.from,r.to),Ee.maxOpen(o.finish())}matchTag(t,r,o){for(let a=o?this.tags.indexOf(o)+1:0;a<this.tags.length;a++){let i=this.tags[a];if(H1e(t,i.tag)&&(i.namespace===void 0||t.namespaceURI==i.namespace)&&(!i.context||r.matchesContext(i.context))){if(i.getAttrs){let l=i.getAttrs(t);if(l===!1)continue;i.attrs=l||void 0}return i}}}matchStyle(t,r,o,a){for(let i=a?this.styles.indexOf(a)+1:0;i<this.styles.length;i++){let l=this.styles[i],s=l.style;if(!(s.indexOf(t)!=0||l.context&&!o.matchesContext(l.context)||s.length>t.length&&(s.charCodeAt(t.length)!=61||s.slice(t.length+1)!=r))){if(l.getAttrs){let c=l.getAttrs(r);if(c===!1)continue;l.attrs=c||void 0}return l}}}static schemaRules(t){let r=[];function o(a){let i=a.priority==null?50:a.priority,l=0;for(;l<r.length;l++){let s=r[l];if((s.priority==null?50:s.priority)<i)break}r.splice(l,0,a)}for(let a in t.marks){let i=t.marks[a].spec.parseDOM;i&&i.forEach(l=>{o(l=R4(l)),l.mark||l.ignore||l.clearMark||(l.mark=a)})}for(let a in t.nodes){let i=t.nodes[a].spec.parseDOM;i&&i.forEach(l=>{o(l=R4(l)),l.node||l.ignore||l.mark||(l.node=a)})}return r}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new Go(t,Go.schemaRules(t)))}}const H8={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},F1e={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},Y8={ol:!0,ul:!0},Au=1,Ou=2,Yl=4;function $4(e,t,r){return t!=null?(t?Au:0)|(t==="full"?Ou:0):e&&e.whitespace=="pre"?Au|Ou:r&~Yl}class xc{constructor(t,r,o,a,i,l){this.type=t,this.attrs=r,this.marks=o,this.solid=a,this.options=l,this.content=[],this.activeMarks=gt.none,this.match=i||(l&Yl?null:t.contentMatch)}findWrapping(t){if(!this.match){if(!this.type)return[];let r=this.type.contentMatch.fillBefore(fe.from(t));if(r)this.match=this.type.contentMatch.matchFragment(r);else{let o=this.type.contentMatch,a;return(a=o.findWrapping(t.type))?(this.match=o,a):null}}return this.match.findWrapping(t.type)}finish(t){if(!(this.options&Au)){let o=this.content[this.content.length-1],a;if(o&&o.isText&&(a=/[ \t\r\n\u000c]+$/.exec(o.text))){let i=o;o.text.length==a[0].length?this.content.pop():this.content[this.content.length-1]=i.withText(i.text.slice(0,i.text.length-a[0].length))}}let r=fe.from(this.content);return!t&&this.match&&(r=r.append(this.match.fillBefore(fe.empty,!0))),this.type?this.type.create(this.attrs,r,this.marks):r}inlineContext(t){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:t.parentNode&&!H8.hasOwnProperty(t.parentNode.nodeName.toLowerCase())}}class P4{constructor(t,r,o){this.parser=t,this.options=r,this.isOpen=o,this.open=0;let a=r.topNode,i,l=$4(null,r.preserveWhitespace,0)|(o?Yl:0);a?i=new xc(a.type,a.attrs,gt.none,!0,r.topMatch||a.type.contentMatch,l):o?i=new xc(null,null,gt.none,!0,null,l):i=new xc(t.schema.topNodeType,null,gt.none,!0,null,l),this.nodes=[i],this.find=r.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(t,r){t.nodeType==3?this.addTextNode(t,r):t.nodeType==1&&this.addElement(t,r)}addTextNode(t,r){let o=t.nodeValue,a=this.top;if(a.options&Ou||a.inlineContext(t)||/[^ \t\r\n\u000c]/.test(o)){if(a.options&Au)a.options&Ou?o=o.replace(/\r\n?/g,`
|
|
49
|
+
`):o=o.replace(/\r?\n|\r/g," ");else if(o=o.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(o)&&this.open==this.nodes.length-1){let i=a.content[a.content.length-1],l=t.previousSibling;(!i||l&&l.nodeName=="BR"||i.isText&&/[ \t\r\n\u000c]$/.test(i.text))&&(o=o.slice(1))}o&&this.insertNode(this.parser.schema.text(o),r),this.findInText(t)}else this.findInside(t)}addElement(t,r,o){let a=t.nodeName.toLowerCase(),i;Y8.hasOwnProperty(a)&&this.parser.normalizeLists&&U1e(t);let l=this.options.ruleFromNode&&this.options.ruleFromNode(t)||(i=this.parser.matchTag(t,this,o));if(l?l.ignore:F1e.hasOwnProperty(a))this.findInside(t),this.ignoreFallback(t,r);else if(!l||l.skip||l.closeParent){l&&l.closeParent?this.open=Math.max(0,this.open-1):l&&l.skip.nodeType&&(t=l.skip);let s,c=this.top,u=this.needsBlock;if(H8.hasOwnProperty(a))c.content.length&&c.content[0].isInline&&this.open&&(this.open--,c=this.top),s=!0,c.type||(this.needsBlock=!0);else if(!t.firstChild){this.leafFallback(t,r);return}let d=l&&l.skip?r:this.readStyles(t,r);d&&this.addAll(t,d),s&&this.sync(c),this.needsBlock=u}else{let s=this.readStyles(t,r);s&&this.addElementByRule(t,l,s,l.consuming===!1?i:void 0)}}leafFallback(t,r){t.nodeName=="BR"&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(t.ownerDocument.createTextNode(`
|
|
50
|
+
`),r)}ignoreFallback(t,r){t.nodeName=="BR"&&(!this.top.type||!this.top.type.inlineContent)&&this.findPlace(this.parser.schema.text("-"),r)}readStyles(t,r){let o=t.style;if(o&&o.length)for(let a=0;a<this.parser.matchedStyles.length;a++){let i=this.parser.matchedStyles[a],l=o.getPropertyValue(i);if(l)for(let s=void 0;;){let c=this.parser.matchStyle(i,l,this,s);if(!c)break;if(c.ignore)return null;if(c.clearMark?r=r.filter(u=>!c.clearMark(u)):r=r.concat(this.parser.schema.marks[c.mark].create(c.attrs)),c.consuming===!1)s=c;else break}}return r}addElementByRule(t,r,o,a){let i,l;if(r.node)if(l=this.parser.schema.nodes[r.node],l.isLeaf)this.insertNode(l.create(r.attrs),o)||this.leafFallback(t,o);else{let c=this.enter(l,r.attrs||null,o,r.preserveWhitespace);c&&(i=!0,o=c)}else{let c=this.parser.schema.marks[r.mark];o=o.concat(c.create(r.attrs))}let s=this.top;if(l&&l.isLeaf)this.findInside(t);else if(a)this.addElement(t,o,a);else if(r.getContent)this.findInside(t),r.getContent(t,this.parser.schema).forEach(c=>this.insertNode(c,o));else{let c=t;typeof r.contentElement=="string"?c=t.querySelector(r.contentElement):typeof r.contentElement=="function"?c=r.contentElement(t):r.contentElement&&(c=r.contentElement),this.findAround(t,c,!0),this.addAll(c,o),this.findAround(t,c,!1)}i&&this.sync(s)&&this.open--}addAll(t,r,o,a){let i=o||0;for(let l=o?t.childNodes[o]:t.firstChild,s=a==null?null:t.childNodes[a];l!=s;l=l.nextSibling,++i)this.findAtPoint(t,i),this.addDOM(l,r);this.findAtPoint(t,i)}findPlace(t,r){let o,a;for(let i=this.open;i>=0;i--){let l=this.nodes[i],s=l.findWrapping(t);if(s&&(!o||o.length>s.length)&&(o=s,a=l,!s.length)||l.solid)break}if(!o)return null;this.sync(a);for(let i=0;i<o.length;i++)r=this.enterInner(o[i],null,r,!1);return r}insertNode(t,r){if(t.isInline&&this.needsBlock&&!this.top.type){let a=this.textblockFromContext();a&&(r=this.enterInner(a,null,r))}let o=this.findPlace(t,r);if(o){this.closeExtra();let a=this.top;a.match&&(a.match=a.match.matchType(t.type));let i=gt.none;for(let l of o.concat(t.marks))(a.type?a.type.allowsMarkType(l.type):F4(l.type,t.type))&&(i=l.addToSet(i));return a.content.push(t.mark(i)),!0}return!1}enter(t,r,o,a){let i=this.findPlace(t.create(r),o);return i&&(i=this.enterInner(t,r,o,!0,a)),i}enterInner(t,r,o,a=!1,i){this.closeExtra();let l=this.top;l.match=l.match&&l.match.matchType(t);let s=$4(t,i,l.options);l.options&Yl&&l.content.length==0&&(s|=Yl);let c=gt.none;return o=o.filter(u=>(l.type?l.type.allowsMarkType(u.type):F4(u.type,t))?(c=u.addToSet(c),!1):!0),this.nodes.push(new xc(t,r,c,a,null,s)),this.open++,o}closeExtra(t=!1){let r=this.nodes.length-1;if(r>this.open){for(;r>this.open;r--)this.nodes[r-1].content.push(this.nodes[r].finish(t));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(this.isOpen||this.options.topOpen)}sync(t){for(let r=this.open;r>=0;r--)if(this.nodes[r]==t)return this.open=r,!0;return!1}get currentPos(){this.closeExtra();let t=0;for(let r=this.open;r>=0;r--){let o=this.nodes[r].content;for(let a=o.length-1;a>=0;a--)t+=o[a].nodeSize;r&&t++}return t}findAtPoint(t,r){if(this.find)for(let o=0;o<this.find.length;o++)this.find[o].node==t&&this.find[o].offset==r&&(this.find[o].pos=this.currentPos)}findInside(t){if(this.find)for(let r=0;r<this.find.length;r++)this.find[r].pos==null&&t.nodeType==1&&t.contains(this.find[r].node)&&(this.find[r].pos=this.currentPos)}findAround(t,r,o){if(t!=r&&this.find)for(let a=0;a<this.find.length;a++)this.find[a].pos==null&&t.nodeType==1&&t.contains(this.find[a].node)&&r.compareDocumentPosition(this.find[a].node)&(o?2:4)&&(this.find[a].pos=this.currentPos)}findInText(t){if(this.find)for(let r=0;r<this.find.length;r++)this.find[r].node==t&&(this.find[r].pos=this.currentPos-(t.nodeValue.length-this.find[r].offset))}matchesContext(t){if(t.indexOf("|")>-1)return t.split(/\s*\|\s*/).some(this.matchesContext,this);let r=t.split("/"),o=this.options.context,a=!this.isOpen&&(!o||o.parent.type==this.nodes[0].type),i=-(o?o.depth+1:0)+(a?0:1),l=(s,c)=>{for(;s>=0;s--){let u=r[s];if(u==""){if(s==r.length-1||s==0)continue;for(;c>=i;c--)if(l(s-1,c))return!0;return!1}else{let d=c>0||c==0&&a?this.nodes[c].type:o&&c>=i?o.node(c-i).type:null;if(!d||d.name!=u&&!d.isInGroup(u))return!1;c--}}return!0};return l(r.length-1,this.open)}textblockFromContext(){let t=this.options.context;if(t)for(let r=t.depth;r>=0;r--){let o=t.node(r).contentMatchAt(t.indexAfter(r)).defaultType;if(o&&o.isTextblock&&o.defaultAttrs)return o}for(let r in this.parser.schema.nodes){let o=this.parser.schema.nodes[r];if(o.isTextblock&&o.defaultAttrs)return o}}}function U1e(e){for(let t=e.firstChild,r=null;t;t=t.nextSibling){let o=t.nodeType==1?t.nodeName.toLowerCase():null;o&&Y8.hasOwnProperty(o)&&r?(r.appendChild(t),t=r):o=="li"?r=t:o&&(r=null)}}function H1e(e,t){return(e.matches||e.msMatchesSelector||e.webkitMatchesSelector||e.mozMatchesSelector).call(e,t)}function R4(e){let t={};for(let r in e)t[r]=e[r];return t}function F4(e,t){let r=t.schema.nodes;for(let o in r){let a=r[o];if(!a.allowsMarkType(e))continue;let i=[],l=s=>{i.push(s);for(let c=0;c<s.edgeCount;c++){let{type:u,next:d}=s.edge(c);if(u==t||i.indexOf(d)<0&&l(d))return!0}};if(l(a.contentMatch))return!0}}class Xa{constructor(t,r){this.nodes=t,this.marks=r}serializeFragment(t,r={},o){o||(o=qf(r).createDocumentFragment());let a=o,i=[];return t.forEach(l=>{if(i.length||l.marks.length){let s=0,c=0;for(;s<i.length&&c<l.marks.length;){let u=l.marks[c];if(!this.marks[u.type.name]){c++;continue}if(!u.eq(i[s][0])||u.type.spec.spanning===!1)break;s++,c++}for(;s<i.length;)a=i.pop()[1];for(;c<l.marks.length;){let u=l.marks[c++],d=this.serializeMark(u,l.isInline,r);d&&(i.push([u,a]),a.appendChild(d.dom),a=d.contentDOM||d.dom)}}a.appendChild(this.serializeNodeInner(l,r))}),o}serializeNodeInner(t,r){let{dom:o,contentDOM:a}=Wc(qf(r),this.nodes[t.type.name](t),null,t.attrs);if(a){if(t.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(t.content,r,a)}return o}serializeNode(t,r={}){let o=this.serializeNodeInner(t,r);for(let a=t.marks.length-1;a>=0;a--){let i=this.serializeMark(t.marks[a],t.isInline,r);i&&((i.contentDOM||i.dom).appendChild(o),o=i.dom)}return o}serializeMark(t,r,o={}){let a=this.marks[t.type.name];return a&&Wc(qf(o),a(t,r),null,t.attrs)}static renderSpec(t,r,o=null,a){return Wc(t,r,o,a)}static fromSchema(t){return t.cached.domSerializer||(t.cached.domSerializer=new Xa(this.nodesFromSchema(t),this.marksFromSchema(t)))}static nodesFromSchema(t){let r=U4(t.nodes);return r.text||(r.text=o=>o.text),r}static marksFromSchema(t){return U4(t.marks)}}function U4(e){let t={};for(let r in e){let o=e[r].spec.toDOM;o&&(t[r]=o)}return t}function qf(e){return e.document||window.document}const H4=new WeakMap;function Y1e(e){let t=H4.get(e);return t===void 0&&H4.set(e,t=Q1e(e)),t}function Q1e(e){let t=null;function r(o){if(o&&typeof o=="object")if(Array.isArray(o))if(typeof o[0]=="string")t||(t=[]),t.push(o);else for(let a=0;a<o.length;a++)r(o[a]);else for(let a in o)r(o[a])}return r(e),t}function Wc(e,t,r,o){if(typeof t=="string")return{dom:e.createTextNode(t)};if(t.nodeType!=null)return{dom:t};if(t.dom&&t.dom.nodeType!=null)return t;let a=t[0],i;if(typeof a!="string")throw new RangeError("Invalid array passed to renderSpec");if(o&&(i=Y1e(o))&&i.indexOf(t)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let l=a.indexOf(" ");l>0&&(r=a.slice(0,l),a=a.slice(l+1));let s,c=r?e.createElementNS(r,a):e.createElement(a),u=t[1],d=1;if(u&&typeof u=="object"&&u.nodeType==null&&!Array.isArray(u)){d=2;for(let f in u)if(u[f]!=null){let p=f.indexOf(" ");p>0?c.setAttributeNS(f.slice(0,p),f.slice(p+1),u[f]):c.setAttribute(f,u[f])}}for(let f=d;f<t.length;f++){let p=t[f];if(p===0){if(f<t.length-1||f>d)throw new RangeError("Content hole must be the only child of its parent node");return{dom:c,contentDOM:c}}else{let{dom:h,contentDOM:m}=Wc(e,p,r,o);if(c.appendChild(h),m){if(s)throw new RangeError("Multiple content holes");s=m}}}return{dom:c,contentDOM:s}}const Q8=65535,W8=Math.pow(2,16);function W1e(e,t){return e+t*W8}function Y4(e){return e&Q8}function q1e(e){return(e-(e&Q8))/W8}const q8=1,G8=2,qc=4,K8=8;class x0{constructor(t,r,o){this.pos=t,this.delInfo=r,this.recover=o}get deleted(){return(this.delInfo&K8)>0}get deletedBefore(){return(this.delInfo&(q8|qc))>0}get deletedAfter(){return(this.delInfo&(G8|qc))>0}get deletedAcross(){return(this.delInfo&qc)>0}}class Pn{constructor(t,r=!1){if(this.ranges=t,this.inverted=r,!t.length&&Pn.empty)return Pn.empty}recover(t){let r=0,o=Y4(t);if(!this.inverted)for(let a=0;a<o;a++)r+=this.ranges[a*3+2]-this.ranges[a*3+1];return this.ranges[o*3]+r+q1e(t)}mapResult(t,r=1){return this._map(t,r,!1)}map(t,r=1){return this._map(t,r,!0)}_map(t,r,o){let a=0,i=this.inverted?2:1,l=this.inverted?1:2;for(let s=0;s<this.ranges.length;s+=3){let c=this.ranges[s]-(this.inverted?a:0);if(c>t)break;let u=this.ranges[s+i],d=this.ranges[s+l],f=c+u;if(t<=f){let p=u?t==c?-1:t==f?1:r:r,h=c+a+(p<0?0:d);if(o)return h;let m=t==(r<0?c:f)?null:W1e(s/3,t-c),g=t==c?G8:t==f?q8:qc;return(r<0?t!=c:t!=f)&&(g|=K8),new x0(h,g,m)}a+=d-u}return o?t+a:new x0(t+a,0,null)}touches(t,r){let o=0,a=Y4(r),i=this.inverted?2:1,l=this.inverted?1:2;for(let s=0;s<this.ranges.length;s+=3){let c=this.ranges[s]-(this.inverted?o:0);if(c>t)break;let u=this.ranges[s+i],d=c+u;if(t<=d&&s==a*3)return!0;o+=this.ranges[s+l]-u}return!1}forEach(t){let r=this.inverted?2:1,o=this.inverted?1:2;for(let a=0,i=0;a<this.ranges.length;a+=3){let l=this.ranges[a],s=l-(this.inverted?i:0),c=l+(this.inverted?0:i),u=this.ranges[a+r],d=this.ranges[a+o];t(s,s+u,c,c+d),i+=d-u}}invert(){return new Pn(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(t){return t==0?Pn.empty:new Pn(t<0?[0,-t,0]:[0,0,t])}}Pn.empty=new Pn([]);class Di{constructor(t=[],r,o=0,a=t.length){this.maps=t,this.mirror=r,this.from=o,this.to=a}slice(t=0,r=this.maps.length){return new Di(this.maps,this.mirror,t,r)}copy(){return new Di(this.maps.slice(),this.mirror&&this.mirror.slice(),this.from,this.to)}appendMap(t,r){this.to=this.maps.push(t),r!=null&&this.setMirror(this.maps.length-1,r)}appendMapping(t){for(let r=0,o=this.maps.length;r<t.maps.length;r++){let a=t.getMirror(r);this.appendMap(t.maps[r],a!=null&&a<r?o+a:void 0)}}getMirror(t){if(this.mirror){for(let r=0;r<this.mirror.length;r++)if(this.mirror[r]==t)return this.mirror[r+(r%2?-1:1)]}}setMirror(t,r){this.mirror||(this.mirror=[]),this.mirror.push(t,r)}appendMappingInverted(t){for(let r=t.maps.length-1,o=this.maps.length+t.maps.length;r>=0;r--){let a=t.getMirror(r);this.appendMap(t.maps[r].invert(),a!=null&&a>r?o-a-1:void 0)}}invert(){let t=new Di;return t.appendMappingInverted(this),t}map(t,r=1){if(this.mirror)return this._map(t,r,!0);for(let o=this.from;o<this.to;o++)t=this.maps[o].map(t,r);return t}mapResult(t,r=1){return this._map(t,r,!1)}_map(t,r,o){let a=0;for(let i=this.from;i<this.to;i++){let l=this.maps[i],s=l.mapResult(t,r);if(s.recover!=null){let c=this.getMirror(i);if(c!=null&&c>i&&c<this.to){i=c,t=this.maps[c].recover(s.recover);continue}}a|=s.delInfo,t=s.pos}return o?t:new x0(t,a,null)}}const Gf=Object.create(null);class vn{getMap(){return Pn.empty}merge(t){return null}static fromJSON(t,r){if(!r||!r.stepType)throw new RangeError("Invalid input for Step.fromJSON");let o=Gf[r.stepType];if(!o)throw new RangeError(`No step type ${r.stepType} defined`);return o.fromJSON(t,r)}static jsonID(t,r){if(t in Gf)throw new RangeError("Duplicate use of step JSON ID "+t);return Gf[t]=r,r.prototype.jsonID=t,r}}class Ft{constructor(t,r){this.doc=t,this.failed=r}static ok(t){return new Ft(t,null)}static fail(t){return new Ft(null,t)}static fromReplace(t,r,o,a){try{return Ft.ok(t.replace(r,o,a))}catch(i){if(i instanceof Du)return Ft.fail(i.message);throw i}}}function Uh(e,t,r){let o=[];for(let a=0;a<e.childCount;a++){let i=e.child(a);i.content.size&&(i=i.copy(Uh(i.content,t,i))),i.isInline&&(i=t(i,r,a)),o.push(i)}return fe.fromArray(o)}class Ho extends vn{constructor(t,r,o){super(),this.from=t,this.to=r,this.mark=o}apply(t){let r=t.slice(this.from,this.to),o=t.resolve(this.from),a=o.node(o.sharedDepth(this.to)),i=new Ee(Uh(r.content,(l,s)=>!l.isAtom||!s.type.allowsMarkType(this.mark.type)?l:l.mark(this.mark.addToSet(l.marks)),a),r.openStart,r.openEnd);return Ft.fromReplace(t,this.from,this.to,i)}invert(){return new Kr(this.from,this.to,this.mark)}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return r.deleted&&o.deleted||r.pos>=o.pos?null:new Ho(r.pos,o.pos,this.mark)}merge(t){return t instanceof Ho&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Ho(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number")throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new Ho(r.from,r.to,t.markFromJSON(r.mark))}}vn.jsonID("addMark",Ho);class Kr extends vn{constructor(t,r,o){super(),this.from=t,this.to=r,this.mark=o}apply(t){let r=t.slice(this.from,this.to),o=new Ee(Uh(r.content,a=>a.mark(this.mark.removeFromSet(a.marks)),t),r.openStart,r.openEnd);return Ft.fromReplace(t,this.from,this.to,o)}invert(){return new Ho(this.from,this.to,this.mark)}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return r.deleted&&o.deleted||r.pos>=o.pos?null:new Kr(r.pos,o.pos,this.mark)}merge(t){return t instanceof Kr&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Kr(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number")throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new Kr(r.from,r.to,t.markFromJSON(r.mark))}}vn.jsonID("removeMark",Kr);class Yo extends vn{constructor(t,r){super(),this.pos=t,this.mark=r}apply(t){let r=t.nodeAt(this.pos);if(!r)return Ft.fail("No node at mark step's position");let o=r.type.create(r.attrs,null,this.mark.addToSet(r.marks));return Ft.fromReplace(t,this.pos,this.pos+1,new Ee(fe.from(o),0,r.isLeaf?0:1))}invert(t){let r=t.nodeAt(this.pos);if(r){let o=this.mark.addToSet(r.marks);if(o.length==r.marks.length){for(let a=0;a<r.marks.length;a++)if(!r.marks[a].isInSet(o))return new Yo(this.pos,r.marks[a]);return new Yo(this.pos,this.mark)}}return new Qi(this.pos,this.mark)}map(t){let r=t.mapResult(this.pos,1);return r.deletedAfter?null:new Yo(r.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,r){if(typeof r.pos!="number")throw new RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new Yo(r.pos,t.markFromJSON(r.mark))}}vn.jsonID("addNodeMark",Yo);class Qi extends vn{constructor(t,r){super(),this.pos=t,this.mark=r}apply(t){let r=t.nodeAt(this.pos);if(!r)return Ft.fail("No node at mark step's position");let o=r.type.create(r.attrs,null,this.mark.removeFromSet(r.marks));return Ft.fromReplace(t,this.pos,this.pos+1,new Ee(fe.from(o),0,r.isLeaf?0:1))}invert(t){let r=t.nodeAt(this.pos);return!r||!this.mark.isInSet(r.marks)?this:new Yo(this.pos,this.mark)}map(t){let r=t.mapResult(this.pos,1);return r.deletedAfter?null:new Qi(r.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,r){if(typeof r.pos!="number")throw new RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new Qi(r.pos,t.markFromJSON(r.mark))}}vn.jsonID("removeNodeMark",Qi);class Kt extends vn{constructor(t,r,o,a=!1){super(),this.from=t,this.to=r,this.slice=o,this.structure=a}apply(t){return this.structure&&C0(t,this.from,this.to)?Ft.fail("Structure replace would overwrite content"):Ft.fromReplace(t,this.from,this.to,this.slice)}getMap(){return new Pn([this.from,this.to-this.from,this.slice.size])}invert(t){return new Kt(this.from,this.from+this.slice.size,t.slice(this.from,this.to))}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return r.deletedAcross&&o.deletedAcross?null:new Kt(r.pos,Math.max(r.pos,o.pos),this.slice)}merge(t){if(!(t instanceof Kt)||t.structure||this.structure)return null;if(this.from+this.slice.size==t.from&&!this.slice.openEnd&&!t.slice.openStart){let r=this.slice.size+t.slice.size==0?Ee.empty:new Ee(this.slice.content.append(t.slice.content),this.slice.openStart,t.slice.openEnd);return new Kt(this.from,this.to+(t.to-t.from),r,this.structure)}else if(t.to==this.from&&!this.slice.openStart&&!t.slice.openEnd){let r=this.slice.size+t.slice.size==0?Ee.empty:new Ee(t.slice.content.append(this.slice.content),t.slice.openStart,this.slice.openEnd);return new Kt(t.from,this.to,r,this.structure)}else return null}toJSON(){let t={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number")throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new Kt(r.from,r.to,Ee.fromJSON(t,r.slice),!!r.structure)}}vn.jsonID("replace",Kt);class Zt extends vn{constructor(t,r,o,a,i,l,s=!1){super(),this.from=t,this.to=r,this.gapFrom=o,this.gapTo=a,this.slice=i,this.insert=l,this.structure=s}apply(t){if(this.structure&&(C0(t,this.from,this.gapFrom)||C0(t,this.gapTo,this.to)))return Ft.fail("Structure gap-replace would overwrite content");let r=t.slice(this.gapFrom,this.gapTo);if(r.openStart||r.openEnd)return Ft.fail("Gap is not a flat range");let o=this.slice.insertAt(this.insert,r.content);return o?Ft.fromReplace(t,this.from,this.to,o):Ft.fail("Content does not fit in gap")}getMap(){return new Pn([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(t){let r=this.gapTo-this.gapFrom;return new Zt(this.from,this.from+this.slice.size+r,this.from+this.insert,this.from+this.insert+r,t.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(t){let r=t.mapResult(this.from,1),o=t.mapResult(this.to,-1),a=this.from==this.gapFrom?r.pos:t.map(this.gapFrom,-1),i=this.to==this.gapTo?o.pos:t.map(this.gapTo,1);return r.deletedAcross&&o.deletedAcross||a<r.pos||i>o.pos?null:new Zt(r.pos,o.pos,a,i,this.slice,this.insert,this.structure)}toJSON(){let t={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,r){if(typeof r.from!="number"||typeof r.to!="number"||typeof r.gapFrom!="number"||typeof r.gapTo!="number"||typeof r.insert!="number")throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new Zt(r.from,r.to,r.gapFrom,r.gapTo,Ee.fromJSON(t,r.slice),r.insert,!!r.structure)}}vn.jsonID("replaceAround",Zt);function C0(e,t,r){let o=e.resolve(t),a=r-t,i=o.depth;for(;a>0&&i>0&&o.indexAfter(i)==o.node(i).childCount;)i--,a--;if(a>0){let l=o.node(i).maybeChild(o.indexAfter(i));for(;a>0;){if(!l||l.isLeaf)return!0;l=l.firstChild,a--}}return!1}function G1e(e,t,r,o){let a=[],i=[],l,s;e.doc.nodesBetween(t,r,(c,u,d)=>{if(!c.isInline)return;let f=c.marks;if(!o.isInSet(f)&&d.type.allowsMarkType(o.type)){let p=Math.max(u,t),h=Math.min(u+c.nodeSize,r),m=o.addToSet(f);for(let g=0;g<f.length;g++)f[g].isInSet(m)||(l&&l.to==p&&l.mark.eq(f[g])?l.to=h:a.push(l=new Kr(p,h,f[g])));s&&s.to==p?s.to=h:i.push(s=new Ho(p,h,o))}}),a.forEach(c=>e.step(c)),i.forEach(c=>e.step(c))}function K1e(e,t,r,o){let a=[],i=0;e.doc.nodesBetween(t,r,(l,s)=>{if(!l.isInline)return;i++;let c=null;if(o instanceof nf){let u=l.marks,d;for(;d=o.isInSet(u);)(c||(c=[])).push(d),u=d.removeFromSet(u)}else o?o.isInSet(l.marks)&&(c=[o]):c=l.marks;if(c&&c.length){let u=Math.min(s+l.nodeSize,r);for(let d=0;d<c.length;d++){let f=c[d],p;for(let h=0;h<a.length;h++){let m=a[h];m.step==i-1&&f.eq(a[h].style)&&(p=m)}p?(p.to=u,p.step=i):a.push({style:f,from:Math.max(s,t),to:u,step:i})}}}),a.forEach(l=>e.step(new Kr(l.from,l.to,l.style)))}function Hh(e,t,r,o=r.contentMatch,a=!0){let i=e.doc.nodeAt(t),l=[],s=t+1;for(let c=0;c<i.childCount;c++){let u=i.child(c),d=s+u.nodeSize,f=o.matchType(u.type);if(!f)l.push(new Kt(s,d,Ee.empty));else{o=f;for(let p=0;p<u.marks.length;p++)r.allowsMarkType(u.marks[p].type)||e.step(new Kr(s,d,u.marks[p]));if(a&&u.isText&&r.whitespace!="pre"){let p,h=/\r?\n|\r/g,m;for(;p=h.exec(u.text);)m||(m=new Ee(fe.from(r.schema.text(" ",r.allowedMarks(u.marks))),0,0)),l.push(new Kt(s+p.index,s+p.index+p[0].length,m))}}s=d}if(!o.validEnd){let c=o.fillBefore(fe.empty,!0);e.replace(s,s,new Ee(c,0,0))}for(let c=l.length-1;c>=0;c--)e.step(l[c])}function J1e(e,t,r){return(t==0||e.canReplace(t,e.childCount))&&(r==e.childCount||e.canReplace(0,r))}function gl(e){let r=e.parent.content.cutByIndex(e.startIndex,e.endIndex);for(let o=e.depth;;--o){let a=e.$from.node(o),i=e.$from.index(o),l=e.$to.indexAfter(o);if(o<e.depth&&a.canReplace(i,l,r))return o;if(o==0||a.type.spec.isolating||!J1e(a,i,l))break}return null}function Z1e(e,t,r){let{$from:o,$to:a,depth:i}=t,l=o.before(i+1),s=a.after(i+1),c=l,u=s,d=fe.empty,f=0;for(let m=i,g=!1;m>r;m--)g||o.index(m)>0?(g=!0,d=fe.from(o.node(m).copy(d)),f++):c--;let p=fe.empty,h=0;for(let m=i,g=!1;m>r;m--)g||a.after(m+1)<a.end(m)?(g=!0,p=fe.from(a.node(m).copy(p)),h++):u++;e.step(new Zt(c,u,l,s,new Ee(d.append(p),f,h),d.size-f,!0))}function Yh(e,t,r=null,o=e){let a=X1e(e,t),i=a&&ege(o,t);return i?a.map(Q4).concat({type:t,attrs:r}).concat(i.map(Q4)):null}function Q4(e){return{type:e,attrs:null}}function X1e(e,t){let{parent:r,startIndex:o,endIndex:a}=e,i=r.contentMatchAt(o).findWrapping(t);if(!i)return null;let l=i.length?i[0]:t;return r.canReplaceWith(o,a,l)?i:null}function ege(e,t){let{parent:r,startIndex:o,endIndex:a}=e,i=r.child(o),l=t.contentMatch.findWrapping(i.type);if(!l)return null;let c=(l.length?l[l.length-1]:t).contentMatch;for(let u=o;c&&u<a;u++)c=c.matchType(r.child(u).type);return!c||!c.validEnd?null:l}function tge(e,t,r){let o=fe.empty;for(let l=r.length-1;l>=0;l--){if(o.size){let s=r[l].type.contentMatch.matchFragment(o);if(!s||!s.validEnd)throw new RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}o=fe.from(r[l].type.create(r[l].attrs,o))}let a=t.start,i=t.end;e.step(new Zt(a,i,a,i,new Ee(o,0,0),r.length,!0))}function nge(e,t,r,o,a){if(!o.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");let i=e.steps.length;e.doc.nodesBetween(t,r,(l,s)=>{let c=typeof a=="function"?a(l):a;if(l.isTextblock&&!l.hasMarkup(o,c)&&rge(e.doc,e.mapping.slice(i).map(s),o)){let u=null;if(o.schema.linebreakReplacement){let h=o.whitespace=="pre",m=!!o.contentMatch.matchType(o.schema.linebreakReplacement);h&&!m?u=!1:!h&&m&&(u=!0)}u===!1&&Z8(e,l,s,i),Hh(e,e.mapping.slice(i).map(s,1),o,void 0,u===null);let d=e.mapping.slice(i),f=d.map(s,1),p=d.map(s+l.nodeSize,1);return e.step(new Zt(f,p,f+1,p-1,new Ee(fe.from(o.create(c,null,l.marks)),0,0),1,!0)),u===!0&&J8(e,l,s,i),!1}})}function J8(e,t,r,o){t.forEach((a,i)=>{if(a.isText){let l,s=/\r?\n|\r/g;for(;l=s.exec(a.text);){let c=e.mapping.slice(o).map(r+1+i+l.index);e.replaceWith(c,c+1,t.type.schema.linebreakReplacement.create())}}})}function Z8(e,t,r,o){t.forEach((a,i)=>{if(a.type==a.type.schema.linebreakReplacement){let l=e.mapping.slice(o).map(r+1+i);e.replaceWith(l,l+1,t.type.schema.text(`
|
|
51
|
+
`))}})}function rge(e,t,r){let o=e.resolve(t),a=o.index();return o.parent.canReplaceWith(a,a+1,r)}function oge(e,t,r,o,a){let i=e.doc.nodeAt(t);if(!i)throw new RangeError("No node at given position");r||(r=i.type);let l=r.create(o,null,a||i.marks);if(i.isLeaf)return e.replaceWith(t,t+i.nodeSize,l);if(!r.validContent(i.content))throw new RangeError("Invalid content for node type "+r.name);e.step(new Zt(t,t+i.nodeSize,t+1,t+i.nodeSize-1,new Ee(fe.from(l),0,0),1,!0))}function Si(e,t,r=1,o){let a=e.resolve(t),i=a.depth-r,l=o&&o[o.length-1]||a.parent;if(i<0||a.parent.type.spec.isolating||!a.parent.canReplace(a.index(),a.parent.childCount)||!l.type.validContent(a.parent.content.cutByIndex(a.index(),a.parent.childCount)))return!1;for(let u=a.depth-1,d=r-2;u>i;u--,d--){let f=a.node(u),p=a.index(u);if(f.type.spec.isolating)return!1;let h=f.content.cutByIndex(p,f.childCount),m=o&&o[d+1];m&&(h=h.replaceChild(0,m.type.create(m.attrs)));let g=o&&o[d]||f;if(!f.canReplace(p+1,f.childCount)||!g.type.validContent(h))return!1}let s=a.indexAfter(i),c=o&&o[0];return a.node(i).canReplaceWith(s,s,c?c.type:a.node(i+1).type)}function age(e,t,r=1,o){let a=e.doc.resolve(t),i=fe.empty,l=fe.empty;for(let s=a.depth,c=a.depth-r,u=r-1;s>c;s--,u--){i=fe.from(a.node(s).copy(i));let d=o&&o[u];l=fe.from(d?d.type.create(d.attrs,l):a.node(s).copy(l))}e.step(new Kt(t,t,new Ee(i.append(l),r,r),!0))}function la(e,t){let r=e.resolve(t),o=r.index();return X8(r.nodeBefore,r.nodeAfter)&&r.parent.canReplace(o,o+1)}function ige(e,t){t.content.size||e.type.compatibleContent(t.type);let r=e.contentMatchAt(e.childCount),{linebreakReplacement:o}=e.type.schema;for(let a=0;a<t.childCount;a++){let i=t.child(a),l=i.type==o?e.type.schema.nodes.text:i.type;if(r=r.matchType(l),!r||!e.type.allowsMarks(i.marks))return!1}return r.validEnd}function X8(e,t){return!!(e&&t&&!e.isLeaf&&ige(e,t))}function rf(e,t,r=-1){let o=e.resolve(t);for(let a=o.depth;;a--){let i,l,s=o.index(a);if(a==o.depth?(i=o.nodeBefore,l=o.nodeAfter):r>0?(i=o.node(a+1),s++,l=o.node(a).maybeChild(s)):(i=o.node(a).maybeChild(s-1),l=o.node(a+1)),i&&!i.isTextblock&&X8(i,l)&&o.node(a).canReplace(s,s+1))return t;if(a==0)break;t=r<0?o.before(a):o.after(a)}}function lge(e,t,r){let o=null,{linebreakReplacement:a}=e.doc.type.schema,i=e.doc.resolve(t-r),l=i.node().type;if(a&&l.inlineContent){let d=l.whitespace=="pre",f=!!l.contentMatch.matchType(a);d&&!f?o=!1:!d&&f&&(o=!0)}let s=e.steps.length;if(o===!1){let d=e.doc.resolve(t+r);Z8(e,d.node(),d.before(),s)}l.inlineContent&&Hh(e,t+r-1,l,i.node().contentMatchAt(i.index()),o==null);let c=e.mapping.slice(s),u=c.map(t-r);if(e.step(new Kt(u,c.map(t+r,-1),Ee.empty,!0)),o===!0){let d=e.doc.resolve(u);J8(e,d.node(),d.before(),e.steps.length)}return e}function sge(e,t,r){let o=e.resolve(t);if(o.parent.canReplaceWith(o.index(),o.index(),r))return t;if(o.parentOffset==0)for(let a=o.depth-1;a>=0;a--){let i=o.index(a);if(o.node(a).canReplaceWith(i,i,r))return o.before(a+1);if(i>0)return null}if(o.parentOffset==o.parent.content.size)for(let a=o.depth-1;a>=0;a--){let i=o.indexAfter(a);if(o.node(a).canReplaceWith(i,i,r))return o.after(a+1);if(i<o.node(a).childCount)return null}return null}function cge(e,t,r){let o=e.resolve(t);if(!r.content.size)return t;let a=r.content;for(let i=0;i<r.openStart;i++)a=a.firstChild.content;for(let i=1;i<=(r.openStart==0&&r.size?2:1);i++)for(let l=o.depth;l>=0;l--){let s=l==o.depth?0:o.pos<=(o.start(l+1)+o.end(l+1))/2?-1:1,c=o.index(l)+(s>0?1:0),u=o.node(l),d=!1;if(i==1)d=u.canReplace(c,c,a);else{let f=u.contentMatchAt(c).findWrapping(a.firstChild.type);d=f&&u.canReplaceWith(c,c,f[0])}if(d)return s==0?o.pos:s<0?o.before(l+1):o.after(l+1)}return null}function of(e,t,r=t,o=Ee.empty){if(t==r&&!o.size)return null;let a=e.resolve(t),i=e.resolve(r);return ew(a,i,o)?new Kt(t,r,o):new uge(a,i,o).fit()}function ew(e,t,r){return!r.openStart&&!r.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),r.content)}class uge{constructor(t,r,o){this.$from=t,this.$to=r,this.unplaced=o,this.frontier=[],this.placed=fe.empty;for(let a=0;a<=t.depth;a++){let i=t.node(a);this.frontier.push({type:i.type,match:i.contentMatchAt(t.indexAfter(a))})}for(let a=t.depth;a>0;a--)this.placed=fe.from(t.node(a).copy(this.placed))}get depth(){return this.frontier.length-1}fit(){for(;this.unplaced.size;){let u=this.findFittable();u?this.placeNodes(u):this.openMore()||this.dropNode()}let t=this.mustMoveInline(),r=this.placed.size-this.depth-this.$from.depth,o=this.$from,a=this.close(t<0?this.$to:o.doc.resolve(t));if(!a)return null;let i=this.placed,l=o.depth,s=a.depth;for(;l&&s&&i.childCount==1;)i=i.firstChild.content,l--,s--;let c=new Ee(i,l,s);return t>-1?new Zt(o.pos,t,this.$to.pos,this.$to.end(),c,r):c.size||o.pos!=this.$to.pos?new Kt(o.pos,a.pos,c):null}findFittable(){let t=this.unplaced.openStart;for(let r=this.unplaced.content,o=0,a=this.unplaced.openEnd;o<t;o++){let i=r.firstChild;if(r.childCount>1&&(a=0),i.type.spec.isolating&&a<=o){t=o;break}r=i.content}for(let r=1;r<=2;r++)for(let o=r==1?t:this.unplaced.openStart;o>=0;o--){let a,i=null;o?(i=Kf(this.unplaced.content,o-1).firstChild,a=i.content):a=this.unplaced.content;let l=a.firstChild;for(let s=this.depth;s>=0;s--){let{type:c,match:u}=this.frontier[s],d,f=null;if(r==1&&(l?u.matchType(l.type)||(f=u.fillBefore(fe.from(l),!1)):i&&c.compatibleContent(i.type)))return{sliceDepth:o,frontierDepth:s,parent:i,inject:f};if(r==2&&l&&(d=u.findWrapping(l.type)))return{sliceDepth:o,frontierDepth:s,parent:i,wrap:d};if(i&&u.matchType(i.type))break}}}openMore(){let{content:t,openStart:r,openEnd:o}=this.unplaced,a=Kf(t,r);return!a.childCount||a.firstChild.isLeaf?!1:(this.unplaced=new Ee(t,r+1,Math.max(o,a.size+r>=t.size-o?r+1:0)),!0)}dropNode(){let{content:t,openStart:r,openEnd:o}=this.unplaced,a=Kf(t,r);if(a.childCount<=1&&r>0){let i=t.size-r<=r+a.size;this.unplaced=new Ee(Ol(t,r-1,1),r-1,i?r-1:o)}else this.unplaced=new Ee(Ol(t,r,1),r,o)}placeNodes({sliceDepth:t,frontierDepth:r,parent:o,inject:a,wrap:i}){for(;this.depth>r;)this.closeFrontierNode();if(i)for(let g=0;g<i.length;g++)this.openFrontierNode(i[g]);let l=this.unplaced,s=o?o.content:l.content,c=l.openStart-t,u=0,d=[],{match:f,type:p}=this.frontier[r];if(a){for(let g=0;g<a.childCount;g++)d.push(a.child(g));f=f.matchFragment(a)}let h=s.size+t-(l.content.size-l.openEnd);for(;u<s.childCount;){let g=s.child(u),v=f.matchType(g.type);if(!v)break;u++,(u>1||c==0||g.content.size)&&(f=v,d.push(tw(g.mark(p.allowedMarks(g.marks)),u==1?c:0,u==s.childCount?h:-1)))}let m=u==s.childCount;m||(h=-1),this.placed=zl(this.placed,r,fe.from(d)),this.frontier[r].match=f,m&&h<0&&o&&o.type==this.frontier[this.depth].type&&this.frontier.length>1&&this.closeFrontierNode();for(let g=0,v=s;g<h;g++){let y=v.lastChild;this.frontier.push({type:y.type,match:y.contentMatchAt(y.childCount)}),v=y.content}this.unplaced=m?t==0?Ee.empty:new Ee(Ol(l.content,t-1,1),t-1,h<0?l.openEnd:t-1):new Ee(Ol(l.content,t,u),l.openStart,l.openEnd)}mustMoveInline(){if(!this.$to.parent.isTextblock)return-1;let t=this.frontier[this.depth],r;if(!t.type.isTextblock||!Jf(this.$to,this.$to.depth,t.type,t.match,!1)||this.$to.depth==this.depth&&(r=this.findCloseLevel(this.$to))&&r.depth==this.depth)return-1;let{depth:o}=this.$to,a=this.$to.after(o);for(;o>1&&a==this.$to.end(--o);)++a;return a}findCloseLevel(t){e:for(let r=Math.min(this.depth,t.depth);r>=0;r--){let{match:o,type:a}=this.frontier[r],i=r<t.depth&&t.end(r+1)==t.pos+(t.depth-(r+1)),l=Jf(t,r,a,o,i);if(l){for(let s=r-1;s>=0;s--){let{match:c,type:u}=this.frontier[s],d=Jf(t,s,u,c,!0);if(!d||d.childCount)continue e}return{depth:r,fit:l,move:i?t.doc.resolve(t.after(r+1)):t}}}}close(t){let r=this.findCloseLevel(t);if(!r)return null;for(;this.depth>r.depth;)this.closeFrontierNode();r.fit.childCount&&(this.placed=zl(this.placed,r.depth,r.fit)),t=r.move;for(let o=r.depth+1;o<=t.depth;o++){let a=t.node(o),i=a.type.contentMatch.fillBefore(a.content,!0,t.index(o));this.openFrontierNode(a.type,a.attrs,i)}return t}openFrontierNode(t,r=null,o){let a=this.frontier[this.depth];a.match=a.match.matchType(t),this.placed=zl(this.placed,this.depth,fe.from(t.create(r,o))),this.frontier.push({type:t,match:t.contentMatch})}closeFrontierNode(){let r=this.frontier.pop().match.fillBefore(fe.empty,!0);r.childCount&&(this.placed=zl(this.placed,this.frontier.length,r))}}function Ol(e,t,r){return t==0?e.cutByIndex(r,e.childCount):e.replaceChild(0,e.firstChild.copy(Ol(e.firstChild.content,t-1,r)))}function zl(e,t,r){return t==0?e.append(r):e.replaceChild(e.childCount-1,e.lastChild.copy(zl(e.lastChild.content,t-1,r)))}function Kf(e,t){for(let r=0;r<t;r++)e=e.firstChild.content;return e}function tw(e,t,r){if(t<=0)return e;let o=e.content;return t>1&&(o=o.replaceChild(0,tw(o.firstChild,t-1,o.childCount==1?r-1:0))),t>0&&(o=e.type.contentMatch.fillBefore(o).append(o),r<=0&&(o=o.append(e.type.contentMatch.matchFragment(o).fillBefore(fe.empty,!0)))),e.copy(o)}function Jf(e,t,r,o,a){let i=e.node(t),l=a?e.indexAfter(t):e.index(t);if(l==i.childCount&&!r.compatibleContent(i.type))return null;let s=o.fillBefore(i.content,!0,l);return s&&!dge(r,i.content,l)?s:null}function dge(e,t,r){for(let o=r;o<t.childCount;o++)if(!e.allowsMarks(t.child(o).marks))return!0;return!1}function fge(e){return e.spec.defining||e.spec.definingForContent}function pge(e,t,r,o){if(!o.size)return e.deleteRange(t,r);let a=e.doc.resolve(t),i=e.doc.resolve(r);if(ew(a,i,o))return e.step(new Kt(t,r,o));let l=rw(a,e.doc.resolve(r));l[l.length-1]==0&&l.pop();let s=-(a.depth+1);l.unshift(s);for(let p=a.depth,h=a.pos-1;p>0;p--,h--){let m=a.node(p).type.spec;if(m.defining||m.definingAsContext||m.isolating)break;l.indexOf(p)>-1?s=p:a.before(p)==h&&l.splice(1,0,-p)}let c=l.indexOf(s),u=[],d=o.openStart;for(let p=o.content,h=0;;h++){let m=p.firstChild;if(u.push(m),h==o.openStart)break;p=m.content}for(let p=d-1;p>=0;p--){let h=u[p],m=fge(h.type);if(m&&!h.sameMarkup(a.node(Math.abs(s)-1)))d=p;else if(m||!h.type.isTextblock)break}for(let p=o.openStart;p>=0;p--){let h=(p+d+1)%(o.openStart+1),m=u[h];if(m)for(let g=0;g<l.length;g++){let v=l[(g+c)%l.length],y=!0;v<0&&(y=!1,v=-v);let N=a.node(v-1),b=a.index(v-1);if(N.canReplaceWith(b,b,m.type,m.marks))return e.replace(a.before(v),y?i.after(v):r,new Ee(nw(o.content,0,o.openStart,h),h,o.openEnd))}}let f=e.steps.length;for(let p=l.length-1;p>=0&&(e.replace(t,r,o),!(e.steps.length>f));p--){let h=l[p];h<0||(t=a.before(h),r=i.after(h))}}function nw(e,t,r,o,a){if(t<r){let i=e.firstChild;e=e.replaceChild(0,i.copy(nw(i.content,t+1,r,o,i)))}if(t>o){let i=a.contentMatchAt(0),l=i.fillBefore(e).append(e);e=l.append(i.matchFragment(l).fillBefore(fe.empty,!0))}return e}function mge(e,t,r,o){if(!o.isInline&&t==r&&e.doc.resolve(t).parent.content.size){let a=sge(e.doc,t,o.type);a!=null&&(t=r=a)}e.replaceRange(t,r,new Ee(fe.from(o),0,0))}function hge(e,t,r){let o=e.doc.resolve(t),a=e.doc.resolve(r),i=rw(o,a);for(let l=0;l<i.length;l++){let s=i[l],c=l==i.length-1;if(c&&s==0||o.node(s).type.contentMatch.validEnd)return e.delete(o.start(s),a.end(s));if(s>0&&(c||o.node(s-1).canReplace(o.index(s-1),a.indexAfter(s-1))))return e.delete(o.before(s),a.after(s))}for(let l=1;l<=o.depth&&l<=a.depth;l++)if(t-o.start(l)==o.depth-l&&r>o.end(l)&&a.end(l)-r!=a.depth-l&&o.start(l-1)==a.start(l-1)&&o.node(l-1).canReplace(o.index(l-1),a.index(l-1)))return e.delete(o.before(l),r);e.delete(t,r)}function rw(e,t){let r=[],o=Math.min(e.depth,t.depth);for(let a=o;a>=0;a--){let i=e.start(a);if(i<e.pos-(e.depth-a)||t.end(a)>t.pos+(t.depth-a)||e.node(a).type.spec.isolating||t.node(a).type.spec.isolating)break;(i==t.start(a)||a==e.depth&&a==t.depth&&e.parent.inlineContent&&t.parent.inlineContent&&a&&t.start(a-1)==i-1)&&r.push(a)}return r}class _i extends vn{constructor(t,r,o){super(),this.pos=t,this.attr=r,this.value=o}apply(t){let r=t.nodeAt(this.pos);if(!r)return Ft.fail("No node at attribute step's position");let o=Object.create(null);for(let i in r.attrs)o[i]=r.attrs[i];o[this.attr]=this.value;let a=r.type.create(o,null,r.marks);return Ft.fromReplace(t,this.pos,this.pos+1,new Ee(fe.from(a),0,r.isLeaf?0:1))}getMap(){return Pn.empty}invert(t){return new _i(this.pos,this.attr,t.nodeAt(this.pos).attrs[this.attr])}map(t){let r=t.mapResult(this.pos,1);return r.deletedAfter?null:new _i(r.pos,this.attr,this.value)}toJSON(){return{stepType:"attr",pos:this.pos,attr:this.attr,value:this.value}}static fromJSON(t,r){if(typeof r.pos!="number"||typeof r.attr!="string")throw new RangeError("Invalid input for AttrStep.fromJSON");return new _i(r.pos,r.attr,r.value)}}vn.jsonID("attr",_i);class xs extends vn{constructor(t,r){super(),this.attr=t,this.value=r}apply(t){let r=Object.create(null);for(let a in t.attrs)r[a]=t.attrs[a];r[this.attr]=this.value;let o=t.type.create(r,t.content,t.marks);return Ft.ok(o)}getMap(){return Pn.empty}invert(t){return new xs(this.attr,t.attrs[this.attr])}map(t){return this}toJSON(){return{stepType:"docAttr",attr:this.attr,value:this.value}}static fromJSON(t,r){if(typeof r.attr!="string")throw new RangeError("Invalid input for DocAttrStep.fromJSON");return new xs(r.attr,r.value)}}vn.jsonID("docAttr",xs);let Wi=class extends Error{};Wi=function e(t){let r=Error.call(this,t);return r.__proto__=e.prototype,r};Wi.prototype=Object.create(Error.prototype);Wi.prototype.constructor=Wi;Wi.prototype.name="TransformError";class ow{constructor(t){this.doc=t,this.steps=[],this.docs=[],this.mapping=new Di}get before(){return this.docs.length?this.docs[0]:this.doc}step(t){let r=this.maybeStep(t);if(r.failed)throw new Wi(r.failed);return this}maybeStep(t){let r=t.apply(this.doc);return r.failed||this.addStep(t,r.doc),r}get docChanged(){return this.steps.length>0}addStep(t,r){this.docs.push(this.doc),this.steps.push(t),this.mapping.appendMap(t.getMap()),this.doc=r}replace(t,r=t,o=Ee.empty){let a=of(this.doc,t,r,o);return a&&this.step(a),this}replaceWith(t,r,o){return this.replace(t,r,new Ee(fe.from(o),0,0))}delete(t,r){return this.replace(t,r,Ee.empty)}insert(t,r){return this.replaceWith(t,t,r)}replaceRange(t,r,o){return pge(this,t,r,o),this}replaceRangeWith(t,r,o){return mge(this,t,r,o),this}deleteRange(t,r){return hge(this,t,r),this}lift(t,r){return Z1e(this,t,r),this}join(t,r=1){return lge(this,t,r),this}wrap(t,r){return tge(this,t,r),this}setBlockType(t,r=t,o,a=null){return nge(this,t,r,o,a),this}setNodeMarkup(t,r,o=null,a){return oge(this,t,r,o,a),this}setNodeAttribute(t,r,o){return this.step(new _i(t,r,o)),this}setDocAttribute(t,r){return this.step(new xs(t,r)),this}addNodeMark(t,r){return this.step(new Yo(t,r)),this}removeNodeMark(t,r){if(!(r instanceof gt)){let o=this.doc.nodeAt(t);if(!o)throw new RangeError("No node at position "+t);if(r=r.isInSet(o.marks),!r)return this}return this.step(new Qi(t,r)),this}split(t,r=1,o){return age(this,t,r,o),this}addMark(t,r,o){return G1e(this,t,r,o),this}removeMark(t,r,o){return K1e(this,t,r,o),this}clearIncompatible(t,r,o){return Hh(this,t,r,o),this}}const Zf=Object.create(null);class Ze{constructor(t,r,o){this.$anchor=t,this.$head=r,this.ranges=o||[new gge(t.min(r),t.max(r))]}get anchor(){return this.$anchor.pos}get head(){return this.$head.pos}get from(){return this.$from.pos}get to(){return this.$to.pos}get $from(){return this.ranges[0].$from}get $to(){return this.ranges[0].$to}get empty(){let t=this.ranges;for(let r=0;r<t.length;r++)if(t[r].$from.pos!=t[r].$to.pos)return!1;return!0}content(){return this.$from.doc.slice(this.from,this.to,!0)}replace(t,r=Ee.empty){let o=r.content.lastChild,a=null;for(let s=0;s<r.openEnd;s++)a=o,o=o.lastChild;let i=t.steps.length,l=this.ranges;for(let s=0;s<l.length;s++){let{$from:c,$to:u}=l[s],d=t.mapping.slice(i);t.replaceRange(d.map(c.pos),d.map(u.pos),s?Ee.empty:r),s==0&&G4(t,i,(o?o.isInline:a&&a.isTextblock)?-1:1)}}replaceWith(t,r){let o=t.steps.length,a=this.ranges;for(let i=0;i<a.length;i++){let{$from:l,$to:s}=a[i],c=t.mapping.slice(o),u=c.map(l.pos),d=c.map(s.pos);i?t.deleteRange(u,d):(t.replaceRangeWith(u,d,r),G4(t,o,r.isInline?-1:1))}}static findFrom(t,r,o=!1){let a=t.parent.inlineContent?new Ge(t):hi(t.node(0),t.parent,t.pos,t.index(),r,o);if(a)return a;for(let i=t.depth-1;i>=0;i--){let l=r<0?hi(t.node(0),t.node(i),t.before(i+1),t.index(i),r,o):hi(t.node(0),t.node(i),t.after(i+1),t.index(i)+1,r,o);if(l)return l}return null}static near(t,r=1){return this.findFrom(t,r)||this.findFrom(t,-r)||new _r(t.node(0))}static atStart(t){return hi(t,t,0,0,1)||new _r(t)}static atEnd(t){return hi(t,t,t.content.size,t.childCount,-1)||new _r(t)}static fromJSON(t,r){if(!r||!r.type)throw new RangeError("Invalid input for Selection.fromJSON");let o=Zf[r.type];if(!o)throw new RangeError(`No selection type ${r.type} defined`);return o.fromJSON(t,r)}static jsonID(t,r){if(t in Zf)throw new RangeError("Duplicate use of selection JSON ID "+t);return Zf[t]=r,r.prototype.jsonID=t,r}getBookmark(){return Ge.between(this.$anchor,this.$head).getBookmark()}}Ze.prototype.visible=!0;class gge{constructor(t,r){this.$from=t,this.$to=r}}let W4=!1;function q4(e){!W4&&!e.parent.inlineContent&&(W4=!0,console.warn("TextSelection endpoint not pointing into a node with inline content ("+e.parent.type.name+")"))}class Ge extends Ze{constructor(t,r=t){q4(t),q4(r),super(t,r)}get $cursor(){return this.$anchor.pos==this.$head.pos?this.$head:null}map(t,r){let o=t.resolve(r.map(this.head));if(!o.parent.inlineContent)return Ze.near(o);let a=t.resolve(r.map(this.anchor));return new Ge(a.parent.inlineContent?a:o,o)}replace(t,r=Ee.empty){if(super.replace(t,r),r==Ee.empty){let o=this.$from.marksAcross(this.$to);o&&t.ensureMarks(o)}}eq(t){return t instanceof Ge&&t.anchor==this.anchor&&t.head==this.head}getBookmark(){return new af(this.anchor,this.head)}toJSON(){return{type:"text",anchor:this.anchor,head:this.head}}static fromJSON(t,r){if(typeof r.anchor!="number"||typeof r.head!="number")throw new RangeError("Invalid input for TextSelection.fromJSON");return new Ge(t.resolve(r.anchor),t.resolve(r.head))}static create(t,r,o=r){let a=t.resolve(r);return new this(a,o==r?a:t.resolve(o))}static between(t,r,o){let a=t.pos-r.pos;if((!o||a)&&(o=a>=0?1:-1),!r.parent.inlineContent){let i=Ze.findFrom(r,o,!0)||Ze.findFrom(r,-o,!0);if(i)r=i.$head;else return Ze.near(r,o)}return t.parent.inlineContent||(a==0?t=r:(t=(Ze.findFrom(t,-o,!0)||Ze.findFrom(t,o,!0)).$anchor,t.pos<r.pos!=a<0&&(t=r))),new Ge(t,r)}}Ze.jsonID("text",Ge);class af{constructor(t,r){this.anchor=t,this.head=r}map(t){return new af(t.map(this.anchor),t.map(this.head))}resolve(t){return Ge.between(t.resolve(this.anchor),t.resolve(this.head))}}class Pe extends Ze{constructor(t){let r=t.nodeAfter,o=t.node(0).resolve(t.pos+r.nodeSize);super(t,o),this.node=r}map(t,r){let{deleted:o,pos:a}=r.mapResult(this.anchor),i=t.resolve(a);return o?Ze.near(i):new Pe(i)}content(){return new Ee(fe.from(this.node),0,0)}eq(t){return t instanceof Pe&&t.anchor==this.anchor}toJSON(){return{type:"node",anchor:this.anchor}}getBookmark(){return new Qh(this.anchor)}static fromJSON(t,r){if(typeof r.anchor!="number")throw new RangeError("Invalid input for NodeSelection.fromJSON");return new Pe(t.resolve(r.anchor))}static create(t,r){return new Pe(t.resolve(r))}static isSelectable(t){return!t.isText&&t.type.spec.selectable!==!1}}Pe.prototype.visible=!1;Ze.jsonID("node",Pe);class Qh{constructor(t){this.anchor=t}map(t){let{deleted:r,pos:o}=t.mapResult(this.anchor);return r?new af(o,o):new Qh(o)}resolve(t){let r=t.resolve(this.anchor),o=r.nodeAfter;return o&&Pe.isSelectable(o)?new Pe(r):Ze.near(r)}}class _r extends Ze{constructor(t){super(t.resolve(0),t.resolve(t.content.size))}replace(t,r=Ee.empty){if(r==Ee.empty){t.delete(0,t.doc.content.size);let o=Ze.atStart(t.doc);o.eq(t.selection)||t.setSelection(o)}else super.replace(t,r)}toJSON(){return{type:"all"}}static fromJSON(t){return new _r(t)}map(t){return new _r(t)}eq(t){return t instanceof _r}getBookmark(){return vge}}Ze.jsonID("all",_r);const vge={map(){return this},resolve(e){return new _r(e)}};function hi(e,t,r,o,a,i=!1){if(t.inlineContent)return Ge.create(e,r);for(let l=o-(a>0?0:1);a>0?l<t.childCount:l>=0;l+=a){let s=t.child(l);if(s.isAtom){if(!i&&Pe.isSelectable(s))return Pe.create(e,r-(a<0?s.nodeSize:0))}else{let c=hi(e,s,r+a,a<0?s.childCount:0,a,i);if(c)return c}r+=s.nodeSize*a}return null}function G4(e,t,r){let o=e.steps.length-1;if(o<t)return;let a=e.steps[o];if(!(a instanceof Kt||a instanceof Zt))return;let i=e.mapping.maps[o],l;i.forEach((s,c,u,d)=>{l==null&&(l=d)}),e.setSelection(Ze.near(e.doc.resolve(l),r))}const K4=1,Cc=2,J4=4;class yge extends ow{constructor(t){super(t.doc),this.curSelectionFor=0,this.updated=0,this.meta=Object.create(null),this.time=Date.now(),this.curSelection=t.selection,this.storedMarks=t.storedMarks}get selection(){return this.curSelectionFor<this.steps.length&&(this.curSelection=this.curSelection.map(this.doc,this.mapping.slice(this.curSelectionFor)),this.curSelectionFor=this.steps.length),this.curSelection}setSelection(t){if(t.$from.doc!=this.doc)throw new RangeError("Selection passed to setSelection must point at the current document");return this.curSelection=t,this.curSelectionFor=this.steps.length,this.updated=(this.updated|K4)&~Cc,this.storedMarks=null,this}get selectionSet(){return(this.updated&K4)>0}setStoredMarks(t){return this.storedMarks=t,this.updated|=Cc,this}ensureMarks(t){return gt.sameSet(this.storedMarks||this.selection.$from.marks(),t)||this.setStoredMarks(t),this}addStoredMark(t){return this.ensureMarks(t.addToSet(this.storedMarks||this.selection.$head.marks()))}removeStoredMark(t){return this.ensureMarks(t.removeFromSet(this.storedMarks||this.selection.$head.marks()))}get storedMarksSet(){return(this.updated&Cc)>0}addStep(t,r){super.addStep(t,r),this.updated=this.updated&~Cc,this.storedMarks=null}setTime(t){return this.time=t,this}replaceSelection(t){return this.selection.replace(this,t),this}replaceSelectionWith(t,r=!0){let o=this.selection;return r&&(t=t.mark(this.storedMarks||(o.empty?o.$from.marks():o.$from.marksAcross(o.$to)||gt.none))),o.replaceWith(this,t),this}deleteSelection(){return this.selection.replace(this),this}insertText(t,r,o){let a=this.doc.type.schema;if(r==null)return t?this.replaceSelectionWith(a.text(t),!0):this.deleteSelection();{if(o==null&&(o=r),o=o??r,!t)return this.deleteRange(r,o);let i=this.storedMarks;if(!i){let l=this.doc.resolve(r);i=o==r?l.marks():l.marksAcross(this.doc.resolve(o))}return this.replaceRangeWith(r,o,a.text(t,i)),this.selection.empty||this.setSelection(Ze.near(this.selection.$to)),this}}setMeta(t,r){return this.meta[typeof t=="string"?t:t.key]=r,this}getMeta(t){return this.meta[typeof t=="string"?t:t.key]}get isGeneric(){for(let t in this.meta)return!1;return!0}scrollIntoView(){return this.updated|=J4,this}get scrolledIntoView(){return(this.updated&J4)>0}}function Z4(e,t){return!t||!e?e:e.bind(t)}class jl{constructor(t,r,o){this.name=t,this.init=Z4(r.init,o),this.apply=Z4(r.apply,o)}}const Mge=[new jl("doc",{init(e){return e.doc||e.schema.topNodeType.createAndFill()},apply(e){return e.doc}}),new jl("selection",{init(e,t){return e.selection||Ze.atStart(t.doc)},apply(e){return e.selection}}),new jl("storedMarks",{init(e){return e.storedMarks||null},apply(e,t,r,o){return o.selection.$cursor?e.storedMarks:null}}),new jl("scrollToSelection",{init(){return 0},apply(e,t){return e.scrolledIntoView?t+1:t}})];class Xf{constructor(t,r){this.schema=t,this.plugins=[],this.pluginsByKey=Object.create(null),this.fields=Mge.slice(),r&&r.forEach(o=>{if(this.pluginsByKey[o.key])throw new RangeError("Adding different instances of a keyed plugin ("+o.key+")");this.plugins.push(o),this.pluginsByKey[o.key]=o,o.spec.state&&this.fields.push(new jl(o.key,o.spec.state,o))})}}class wi{constructor(t){this.config=t}get schema(){return this.config.schema}get plugins(){return this.config.plugins}apply(t){return this.applyTransaction(t).state}filterTransaction(t,r=-1){for(let o=0;o<this.config.plugins.length;o++)if(o!=r){let a=this.config.plugins[o];if(a.spec.filterTransaction&&!a.spec.filterTransaction.call(a,t,this))return!1}return!0}applyTransaction(t){if(!this.filterTransaction(t))return{state:this,transactions:[]};let r=[t],o=this.applyInner(t),a=null;for(;;){let i=!1;for(let l=0;l<this.config.plugins.length;l++){let s=this.config.plugins[l];if(s.spec.appendTransaction){let c=a?a[l].n:0,u=a?a[l].state:this,d=c<r.length&&s.spec.appendTransaction.call(s,c?r.slice(c):r,u,o);if(d&&o.filterTransaction(d,l)){if(d.setMeta("appendedTransaction",t),!a){a=[];for(let f=0;f<this.config.plugins.length;f++)a.push(f<l?{state:o,n:r.length}:{state:this,n:0})}r.push(d),o=o.applyInner(d),i=!0}a&&(a[l]={state:o,n:r.length})}}if(!i)return{state:o,transactions:r}}}applyInner(t){if(!t.before.eq(this.doc))throw new RangeError("Applying a mismatched transaction");let r=new wi(this.config),o=this.config.fields;for(let a=0;a<o.length;a++){let i=o[a];r[i.name]=i.apply(t,this[i.name],this,r)}return r}get tr(){return new yge(this)}static create(t){let r=new Xf(t.doc?t.doc.type.schema:t.schema,t.plugins),o=new wi(r);for(let a=0;a<r.fields.length;a++)o[r.fields[a].name]=r.fields[a].init(t,o);return o}reconfigure(t){let r=new Xf(this.schema,t.plugins),o=r.fields,a=new wi(r);for(let i=0;i<o.length;i++){let l=o[i].name;a[l]=this.hasOwnProperty(l)?this[l]:o[i].init(t,a)}return a}toJSON(t){let r={doc:this.doc.toJSON(),selection:this.selection.toJSON()};if(this.storedMarks&&(r.storedMarks=this.storedMarks.map(o=>o.toJSON())),t&&typeof t=="object")for(let o in t){if(o=="doc"||o=="selection")throw new RangeError("The JSON fields `doc` and `selection` are reserved");let a=t[o],i=a.spec.state;i&&i.toJSON&&(r[o]=i.toJSON.call(a,this[a.key]))}return r}static fromJSON(t,r,o){if(!r)throw new RangeError("Invalid input for EditorState.fromJSON");if(!t.schema)throw new RangeError("Required config field 'schema' missing");let a=new Xf(t.schema,t.plugins),i=new wi(a);return a.fields.forEach(l=>{if(l.name=="doc")i.doc=Ia.fromJSON(t.schema,r.doc);else if(l.name=="selection")i.selection=Ze.fromJSON(i.doc,r.selection);else if(l.name=="storedMarks")r.storedMarks&&(i.storedMarks=r.storedMarks.map(t.schema.markFromJSON));else{if(o)for(let s in o){let c=o[s],u=c.spec.state;if(c.key==l.name&&u&&u.fromJSON&&Object.prototype.hasOwnProperty.call(r,s)){i[l.name]=u.fromJSON.call(c,t,r[s],i);return}}i[l.name]=l.init(t,i)}}),i}}function aw(e,t,r){for(let o in e){let a=e[o];a instanceof Function?a=a.bind(t):o=="handleDOMEvents"&&(a=aw(a,t,{})),r[o]=a}return r}let tn=class{constructor(t){this.spec=t,this.props={},t.props&&aw(t.props,this,this.props),this.key=t.key?t.key.key:iw("plugin")}getState(t){return t[this.key]}};const ep=Object.create(null);function iw(e){return e in ep?e+"$"+ ++ep[e]:(ep[e]=0,e+"$")}class yn{constructor(t="key"){this.key=iw(t)}get(t){return t.config.pluginsByKey[this.key]}getState(t){return t[this.key]}}const rn=function(e){for(var t=0;;t++)if(e=e.previousSibling,!e)return t},Cs=function(e){let t=e.assignedSlot||e.parentNode;return t&&t.nodeType==11?t.host:t};let E0=null;const fo=function(e,t,r){let o=E0||(E0=document.createRange());return o.setEnd(e,r??e.nodeValue.length),o.setStart(e,t||0),o},bge=function(){E0=null},Ra=function(e,t,r,o){return r&&(X4(e,t,r,o,-1)||X4(e,t,r,o,1))},wge=/^(img|br|input|textarea|hr)$/i;function X4(e,t,r,o,a){for(;;){if(e==r&&t==o)return!0;if(t==(a<0?0:nr(e))){let i=e.parentNode;if(!i||i.nodeType!=1||Js(e)||wge.test(e.nodeName)||e.contentEditable=="false")return!1;t=rn(e)+(a<0?0:1),e=i}else if(e.nodeType==1){if(e=e.childNodes[t+(a<0?-1:0)],e.contentEditable=="false")return!1;t=a<0?nr(e):0}else return!1}}function nr(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function Nge(e,t){for(;;){if(e.nodeType==3&&t)return e;if(e.nodeType==1&&t>0){if(e.contentEditable=="false")return null;e=e.childNodes[t-1],t=nr(e)}else if(e.parentNode&&!Js(e))t=rn(e),e=e.parentNode;else return null}}function kge(e,t){for(;;){if(e.nodeType==3&&t<e.nodeValue.length)return e;if(e.nodeType==1&&t<e.childNodes.length){if(e.contentEditable=="false")return null;e=e.childNodes[t],t=0}else if(e.parentNode&&!Js(e))t=rn(e)+1,e=e.parentNode;else return null}}function xge(e,t,r){for(let o=t==0,a=t==nr(e);o||a;){if(e==r)return!0;let i=rn(e);if(e=e.parentNode,!e)return!1;o=o&&i==0,a=a&&i==nr(e)}}function Js(e){let t;for(let r=e;r&&!(t=r.pmViewDesc);r=r.parentNode);return t&&t.node&&t.node.isBlock&&(t.dom==e||t.contentDOM==e)}const lf=function(e){return e.focusNode&&Ra(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)};function Ma(e,t){let r=document.createEvent("Event");return r.initEvent("keydown",!0,!0),r.keyCode=e,r.key=r.code=t,r}function Cge(e){let t=e.activeElement;for(;t&&t.shadowRoot;)t=t.shadowRoot.activeElement;return t}function Ege(e,t,r){if(e.caretPositionFromPoint)try{let o=e.caretPositionFromPoint(t,r);if(o)return{node:o.offsetNode,offset:Math.min(nr(o.offsetNode),o.offset)}}catch{}if(e.caretRangeFromPoint){let o=e.caretRangeFromPoint(t,r);if(o)return{node:o.startContainer,offset:Math.min(nr(o.startContainer),o.startOffset)}}}const ro=typeof navigator<"u"?navigator:null,ev=typeof document<"u"?document:null,sa=ro&&ro.userAgent||"",T0=/Edge\/(\d+)/.exec(sa),lw=/MSIE \d/.exec(sa),D0=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(sa),An=!!(lw||D0||T0),Ko=lw?document.documentMode:D0?+D0[1]:T0?+T0[1]:0,Or=!An&&/gecko\/(\d+)/i.test(sa);Or&&+(/Firefox\/(\d+)/.exec(sa)||[0,0])[1];const S0=!An&&/Chrome\/(\d+)/.exec(sa),fn=!!S0,sw=S0?+S0[1]:0,bn=!An&&!!ro&&/Apple Computer/.test(ro.vendor),qi=bn&&(/Mobile\/\w+/.test(sa)||!!ro&&ro.maxTouchPoints>2),tr=qi||(ro?/Mac/.test(ro.platform):!1),Tge=ro?/Win/.test(ro.platform):!1,Er=/Android \d/.test(sa),Zs=!!ev&&"webkitFontSmoothing"in ev.documentElement.style,Dge=Zs?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;function Sge(e){let t=e.defaultView&&e.defaultView.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.documentElement.clientWidth,top:0,bottom:e.documentElement.clientHeight}}function co(e,t){return typeof e=="number"?e:e[t]}function _ge(e){let t=e.getBoundingClientRect(),r=t.width/e.offsetWidth||1,o=t.height/e.offsetHeight||1;return{left:t.left,right:t.left+e.clientWidth*r,top:t.top,bottom:t.top+e.clientHeight*o}}function tv(e,t,r){let o=e.someProp("scrollThreshold")||0,a=e.someProp("scrollMargin")||5,i=e.dom.ownerDocument;for(let l=r||e.dom;l;l=Cs(l)){if(l.nodeType!=1)continue;let s=l,c=s==i.body,u=c?Sge(i):_ge(s),d=0,f=0;if(t.top<u.top+co(o,"top")?f=-(u.top-t.top+co(a,"top")):t.bottom>u.bottom-co(o,"bottom")&&(f=t.bottom-t.top>u.bottom-u.top?t.top+co(a,"top")-u.top:t.bottom-u.bottom+co(a,"bottom")),t.left<u.left+co(o,"left")?d=-(u.left-t.left+co(a,"left")):t.right>u.right-co(o,"right")&&(d=t.right-u.right+co(a,"right")),d||f)if(c)i.defaultView.scrollBy(d,f);else{let p=s.scrollLeft,h=s.scrollTop;f&&(s.scrollTop+=f),d&&(s.scrollLeft+=d);let m=s.scrollLeft-p,g=s.scrollTop-h;t={left:t.left-m,top:t.top-g,right:t.right-m,bottom:t.bottom-g}}if(c||/^(fixed|sticky)$/.test(getComputedStyle(l).position))break}}function Ige(e){let t=e.dom.getBoundingClientRect(),r=Math.max(0,t.top),o,a;for(let i=(t.left+t.right)/2,l=r+1;l<Math.min(innerHeight,t.bottom);l+=5){let s=e.root.elementFromPoint(i,l);if(!s||s==e.dom||!e.dom.contains(s))continue;let c=s.getBoundingClientRect();if(c.top>=r-20){o=s,a=c.top;break}}return{refDOM:o,refTop:a,stack:cw(e.dom)}}function cw(e){let t=[],r=e.ownerDocument;for(let o=e;o&&(t.push({dom:o,top:o.scrollTop,left:o.scrollLeft}),e!=r);o=Cs(o));return t}function Age({refDOM:e,refTop:t,stack:r}){let o=e?e.getBoundingClientRect().top:0;uw(r,o==0?0:o-t)}function uw(e,t){for(let r=0;r<e.length;r++){let{dom:o,top:a,left:i}=e[r];o.scrollTop!=a+t&&(o.scrollTop=a+t),o.scrollLeft!=i&&(o.scrollLeft=i)}}let ci=null;function Oge(e){if(e.setActive)return e.setActive();if(ci)return e.focus(ci);let t=cw(e);e.focus(ci==null?{get preventScroll(){return ci={preventScroll:!0},!0}}:void 0),ci||(ci=!1,uw(t,0))}function dw(e,t){let r,o=2e8,a,i=0,l=t.top,s=t.top,c,u;for(let d=e.firstChild,f=0;d;d=d.nextSibling,f++){let p;if(d.nodeType==1)p=d.getClientRects();else if(d.nodeType==3)p=fo(d).getClientRects();else continue;for(let h=0;h<p.length;h++){let m=p[h];if(m.top<=l&&m.bottom>=s){l=Math.max(m.bottom,l),s=Math.min(m.top,s);let g=m.left>t.left?m.left-t.left:m.right<t.left?t.left-m.right:0;if(g<o){r=d,o=g,a=g&&r.nodeType==3?{left:m.right<t.left?m.right:m.left,top:t.top}:t,d.nodeType==1&&g&&(i=f+(t.left>=(m.left+m.right)/2?1:0));continue}}else m.top>t.top&&!c&&m.left<=t.left&&m.right>=t.left&&(c=d,u={left:Math.max(m.left,Math.min(m.right,t.left)),top:m.top});!r&&(t.left>=m.right&&t.top>=m.top||t.left>=m.left&&t.top>=m.bottom)&&(i=f+1)}}return!r&&c&&(r=c,a=u,o=0),r&&r.nodeType==3?zge(r,a):!r||o&&r.nodeType==1?{node:e,offset:i}:dw(r,a)}function zge(e,t){let r=e.nodeValue.length,o=document.createRange();for(let a=0;a<r;a++){o.setEnd(e,a+1),o.setStart(e,a);let i=Ao(o,1);if(i.top!=i.bottom&&Wh(t,i))return{node:e,offset:a+(t.left>=(i.left+i.right)/2?1:0)}}return{node:e,offset:0}}function Wh(e,t){return e.left>=t.left-1&&e.left<=t.right+1&&e.top>=t.top-1&&e.top<=t.bottom+1}function jge(e,t){let r=e.parentNode;return r&&/^li$/i.test(r.nodeName)&&t.left<e.getBoundingClientRect().left?r:e}function Lge(e,t,r){let{node:o,offset:a}=dw(t,r),i=-1;if(o.nodeType==1&&!o.firstChild){let l=o.getBoundingClientRect();i=l.left!=l.right&&r.left>(l.left+l.right)/2?1:-1}return e.docView.posFromDOM(o,a,i)}function Bge(e,t,r,o){let a=-1;for(let i=t,l=!1;i!=e.dom;){let s=e.docView.nearestDesc(i,!0);if(!s)return null;if(s.dom.nodeType==1&&(s.node.isBlock&&s.parent||!s.contentDOM)){let c=s.dom.getBoundingClientRect();if(s.node.isBlock&&s.parent&&(!l&&c.left>o.left||c.top>o.top?a=s.posBefore:(!l&&c.right<o.left||c.bottom<o.top)&&(a=s.posAfter),l=!0),!s.contentDOM&&a<0&&!s.node.isText)return(s.node.isBlock?o.top<(c.top+c.bottom)/2:o.left<(c.left+c.right)/2)?s.posBefore:s.posAfter}i=s.dom.parentNode}return a>-1?a:e.docView.posFromDOM(t,r,-1)}function fw(e,t,r){let o=e.childNodes.length;if(o&&r.top<r.bottom)for(let a=Math.max(0,Math.min(o-1,Math.floor(o*(t.top-r.top)/(r.bottom-r.top))-2)),i=a;;){let l=e.childNodes[i];if(l.nodeType==1){let s=l.getClientRects();for(let c=0;c<s.length;c++){let u=s[c];if(Wh(t,u))return fw(l,t,u)}}if((i=(i+1)%o)==a)break}return e}function Vge(e,t){let r=e.dom.ownerDocument,o,a=0,i=Ege(r,t.left,t.top);i&&({node:o,offset:a}=i);let l=(e.root.elementFromPoint?e.root:r).elementFromPoint(t.left,t.top),s;if(!l||!e.dom.contains(l.nodeType!=1?l.parentNode:l)){let u=e.dom.getBoundingClientRect();if(!Wh(t,u)||(l=fw(e.dom,t,u),!l))return null}if(bn)for(let u=l;o&&u;u=Cs(u))u.draggable&&(o=void 0);if(l=jge(l,t),o){if(Or&&o.nodeType==1&&(a=Math.min(a,o.childNodes.length),a<o.childNodes.length)){let d=o.childNodes[a],f;d.nodeName=="IMG"&&(f=d.getBoundingClientRect()).right<=t.left&&f.bottom>t.top&&a++}let u;Zs&&a&&o.nodeType==1&&(u=o.childNodes[a-1]).nodeType==1&&u.contentEditable=="false"&&u.getBoundingClientRect().top>=t.top&&a--,o==e.dom&&a==o.childNodes.length-1&&o.lastChild.nodeType==1&&t.top>o.lastChild.getBoundingClientRect().bottom?s=e.state.doc.content.size:(a==0||o.nodeType!=1||o.childNodes[a-1].nodeName!="BR")&&(s=Bge(e,o,a,t))}s==null&&(s=Lge(e,l,t));let c=e.docView.nearestDesc(l,!0);return{pos:s,inside:c?c.posAtStart-c.border:-1}}function nv(e){return e.top<e.bottom||e.left<e.right}function Ao(e,t){let r=e.getClientRects();if(r.length){let o=r[t<0?0:r.length-1];if(nv(o))return o}return Array.prototype.find.call(r,nv)||e.getBoundingClientRect()}const $ge=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;function pw(e,t,r){let{node:o,offset:a,atom:i}=e.docView.domFromPos(t,r<0?-1:1),l=Zs||Or;if(o.nodeType==3)if(l&&($ge.test(o.nodeValue)||(r<0?!a:a==o.nodeValue.length))){let c=Ao(fo(o,a,a),r);if(Or&&a&&/\s/.test(o.nodeValue[a-1])&&a<o.nodeValue.length){let u=Ao(fo(o,a-1,a-1),-1);if(u.top==c.top){let d=Ao(fo(o,a,a+1),-1);if(d.top!=c.top)return El(d,d.left<u.left)}}return c}else{let c=a,u=a,d=r<0?1:-1;return r<0&&!a?(u++,d=-1):r>=0&&a==o.nodeValue.length?(c--,d=1):r<0?c--:u++,El(Ao(fo(o,c,u),d),d<0)}if(!e.state.doc.resolve(t-(i||0)).parent.inlineContent){if(i==null&&a&&(r<0||a==nr(o))){let c=o.childNodes[a-1];if(c.nodeType==1)return tp(c.getBoundingClientRect(),!1)}if(i==null&&a<nr(o)){let c=o.childNodes[a];if(c.nodeType==1)return tp(c.getBoundingClientRect(),!0)}return tp(o.getBoundingClientRect(),r>=0)}if(i==null&&a&&(r<0||a==nr(o))){let c=o.childNodes[a-1],u=c.nodeType==3?fo(c,nr(c)-(l?0:1)):c.nodeType==1&&(c.nodeName!="BR"||!c.nextSibling)?c:null;if(u)return El(Ao(u,1),!1)}if(i==null&&a<nr(o)){let c=o.childNodes[a];for(;c.pmViewDesc&&c.pmViewDesc.ignoreForCoords;)c=c.nextSibling;let u=c?c.nodeType==3?fo(c,0,l?0:1):c.nodeType==1?c:null:null;if(u)return El(Ao(u,-1),!0)}return El(Ao(o.nodeType==3?fo(o):o,-r),r>=0)}function El(e,t){if(e.width==0)return e;let r=t?e.left:e.right;return{top:e.top,bottom:e.bottom,left:r,right:r}}function tp(e,t){if(e.height==0)return e;let r=t?e.top:e.bottom;return{top:r,bottom:r,left:e.left,right:e.right}}function mw(e,t,r){let o=e.state,a=e.root.activeElement;o!=t&&e.updateState(t),a!=e.dom&&e.focus();try{return r()}finally{o!=t&&e.updateState(o),a!=e.dom&&a&&a.focus()}}function Pge(e,t,r){let o=t.selection,a=r=="up"?o.$from:o.$to;return mw(e,t,()=>{let{node:i}=e.docView.domFromPos(a.pos,r=="up"?-1:1);for(;;){let s=e.docView.nearestDesc(i,!0);if(!s)break;if(s.node.isBlock){i=s.contentDOM||s.dom;break}i=s.dom.parentNode}let l=pw(e,a.pos,1);for(let s=i.firstChild;s;s=s.nextSibling){let c;if(s.nodeType==1)c=s.getClientRects();else if(s.nodeType==3)c=fo(s,0,s.nodeValue.length).getClientRects();else continue;for(let u=0;u<c.length;u++){let d=c[u];if(d.bottom>d.top+1&&(r=="up"?l.top-d.top>(d.bottom-l.top)*2:d.bottom-l.bottom>(l.bottom-d.top)*2))return!1}}return!0})}const Rge=/[\u0590-\u08ac]/;function Fge(e,t,r){let{$head:o}=t.selection;if(!o.parent.isTextblock)return!1;let a=o.parentOffset,i=!a,l=a==o.parent.content.size,s=e.domSelection();return s?!Rge.test(o.parent.textContent)||!s.modify?r=="left"||r=="backward"?i:l:mw(e,t,()=>{let{focusNode:c,focusOffset:u,anchorNode:d,anchorOffset:f}=e.domSelectionRange(),p=s.caretBidiLevel;s.modify("move",r,"character");let h=o.depth?e.docView.domAfterPos(o.before()):e.dom,{focusNode:m,focusOffset:g}=e.domSelectionRange(),v=m&&!h.contains(m.nodeType==1?m:m.parentNode)||c==m&&u==g;try{s.collapse(d,f),c&&(c!=d||u!=f)&&s.extend&&s.extend(c,u)}catch{}return p!=null&&(s.caretBidiLevel=p),v}):o.pos==o.start()||o.pos==o.end()}let rv=null,ov=null,av=!1;function Uge(e,t,r){return rv==t&&ov==r?av:(rv=t,ov=r,av=r=="up"||r=="down"?Pge(e,t,r):Fge(e,t,r))}const ar=0,iv=1,Ca=2,oo=3;class Xs{constructor(t,r,o,a){this.parent=t,this.children=r,this.dom=o,this.contentDOM=a,this.dirty=ar,o.pmViewDesc=this}matchesWidget(t){return!1}matchesMark(t){return!1}matchesNode(t,r,o){return!1}matchesHack(t){return!1}parseRule(){return null}stopEvent(t){return!1}get size(){let t=0;for(let r=0;r<this.children.length;r++)t+=this.children[r].size;return t}get border(){return 0}destroy(){this.parent=void 0,this.dom.pmViewDesc==this&&(this.dom.pmViewDesc=void 0);for(let t=0;t<this.children.length;t++)this.children[t].destroy()}posBeforeChild(t){for(let r=0,o=this.posAtStart;;r++){let a=this.children[r];if(a==t)return o;o+=a.size}}get posBefore(){return this.parent.posBeforeChild(this)}get posAtStart(){return this.parent?this.parent.posBeforeChild(this)+this.border:0}get posAfter(){return this.posBefore+this.size}get posAtEnd(){return this.posAtStart+this.size-2*this.border}localPosFromDOM(t,r,o){if(this.contentDOM&&this.contentDOM.contains(t.nodeType==1?t:t.parentNode))if(o<0){let i,l;if(t==this.contentDOM)i=t.childNodes[r-1];else{for(;t.parentNode!=this.contentDOM;)t=t.parentNode;i=t.previousSibling}for(;i&&!((l=i.pmViewDesc)&&l.parent==this);)i=i.previousSibling;return i?this.posBeforeChild(l)+l.size:this.posAtStart}else{let i,l;if(t==this.contentDOM)i=t.childNodes[r];else{for(;t.parentNode!=this.contentDOM;)t=t.parentNode;i=t.nextSibling}for(;i&&!((l=i.pmViewDesc)&&l.parent==this);)i=i.nextSibling;return i?this.posBeforeChild(l):this.posAtEnd}let a;if(t==this.dom&&this.contentDOM)a=r>rn(this.contentDOM);else if(this.contentDOM&&this.contentDOM!=this.dom&&this.dom.contains(this.contentDOM))a=t.compareDocumentPosition(this.contentDOM)&2;else if(this.dom.firstChild){if(r==0)for(let i=t;;i=i.parentNode){if(i==this.dom){a=!1;break}if(i.previousSibling)break}if(a==null&&r==t.childNodes.length)for(let i=t;;i=i.parentNode){if(i==this.dom){a=!0;break}if(i.nextSibling)break}}return a??o>0?this.posAtEnd:this.posAtStart}nearestDesc(t,r=!1){for(let o=!0,a=t;a;a=a.parentNode){let i=this.getDesc(a),l;if(i&&(!r||i.node))if(o&&(l=i.nodeDOM)&&!(l.nodeType==1?l.contains(t.nodeType==1?t:t.parentNode):l==t))o=!1;else return i}}getDesc(t){let r=t.pmViewDesc;for(let o=r;o;o=o.parent)if(o==this)return r}posFromDOM(t,r,o){for(let a=t;a;a=a.parentNode){let i=this.getDesc(a);if(i)return i.localPosFromDOM(t,r,o)}return-1}descAt(t){for(let r=0,o=0;r<this.children.length;r++){let a=this.children[r],i=o+a.size;if(o==t&&i!=o){for(;!a.border&&a.children.length;)a=a.children[0];return a}if(t<i)return a.descAt(t-o-a.border);o=i}}domFromPos(t,r){if(!this.contentDOM)return{node:this.dom,offset:0,atom:t+1};let o=0,a=0;for(let i=0;o<this.children.length;o++){let l=this.children[o],s=i+l.size;if(s>t||l instanceof gw){a=t-i;break}i=s}if(a)return this.children[o].domFromPos(a-this.children[o].border,r);for(let i;o&&!(i=this.children[o-1]).size&&i instanceof hw&&i.side>=0;o--);if(r<=0){let i,l=!0;for(;i=o?this.children[o-1]:null,!(!i||i.dom.parentNode==this.contentDOM);o--,l=!1);return i&&r&&l&&!i.border&&!i.domAtom?i.domFromPos(i.size,r):{node:this.contentDOM,offset:i?rn(i.dom)+1:0}}else{let i,l=!0;for(;i=o<this.children.length?this.children[o]:null,!(!i||i.dom.parentNode==this.contentDOM);o++,l=!1);return i&&l&&!i.border&&!i.domAtom?i.domFromPos(0,r):{node:this.contentDOM,offset:i?rn(i.dom):this.contentDOM.childNodes.length}}}parseRange(t,r,o=0){if(this.children.length==0)return{node:this.contentDOM,from:t,to:r,fromOffset:0,toOffset:this.contentDOM.childNodes.length};let a=-1,i=-1;for(let l=o,s=0;;s++){let c=this.children[s],u=l+c.size;if(a==-1&&t<=u){let d=l+c.border;if(t>=d&&r<=u-c.border&&c.node&&c.contentDOM&&this.contentDOM.contains(c.contentDOM))return c.parseRange(t,r,d);t=l;for(let f=s;f>0;f--){let p=this.children[f-1];if(p.size&&p.dom.parentNode==this.contentDOM&&!p.emptyChildAt(1)){a=rn(p.dom)+1;break}t-=p.size}a==-1&&(a=0)}if(a>-1&&(u>r||s==this.children.length-1)){r=u;for(let d=s+1;d<this.children.length;d++){let f=this.children[d];if(f.size&&f.dom.parentNode==this.contentDOM&&!f.emptyChildAt(-1)){i=rn(f.dom);break}r+=f.size}i==-1&&(i=this.contentDOM.childNodes.length);break}l=u}return{node:this.contentDOM,from:t,to:r,fromOffset:a,toOffset:i}}emptyChildAt(t){if(this.border||!this.contentDOM||!this.children.length)return!1;let r=this.children[t<0?0:this.children.length-1];return r.size==0||r.emptyChildAt(t)}domAfterPos(t){let{node:r,offset:o}=this.domFromPos(t,0);if(r.nodeType!=1||o==r.childNodes.length)throw new RangeError("No node after pos "+t);return r.childNodes[o]}setSelection(t,r,o,a=!1){let i=Math.min(t,r),l=Math.max(t,r);for(let p=0,h=0;p<this.children.length;p++){let m=this.children[p],g=h+m.size;if(i>h&&l<g)return m.setSelection(t-h-m.border,r-h-m.border,o,a);h=g}let s=this.domFromPos(t,t?-1:1),c=r==t?s:this.domFromPos(r,r?-1:1),u=o.getSelection(),d=!1;if((Or||bn)&&t==r){let{node:p,offset:h}=s;if(p.nodeType==3){if(d=!!(h&&p.nodeValue[h-1]==`
|
|
52
|
+
`),d&&h==p.nodeValue.length)for(let m=p,g;m;m=m.parentNode){if(g=m.nextSibling){g.nodeName=="BR"&&(s=c={node:g.parentNode,offset:rn(g)+1});break}let v=m.pmViewDesc;if(v&&v.node&&v.node.isBlock)break}}else{let m=p.childNodes[h-1];d=m&&(m.nodeName=="BR"||m.contentEditable=="false")}}if(Or&&u.focusNode&&u.focusNode!=c.node&&u.focusNode.nodeType==1){let p=u.focusNode.childNodes[u.focusOffset];p&&p.contentEditable=="false"&&(a=!0)}if(!(a||d&&bn)&&Ra(s.node,s.offset,u.anchorNode,u.anchorOffset)&&Ra(c.node,c.offset,u.focusNode,u.focusOffset))return;let f=!1;if((u.extend||t==r)&&!d){u.collapse(s.node,s.offset);try{t!=r&&u.extend(c.node,c.offset),f=!0}catch{}}if(!f){if(t>r){let h=s;s=c,c=h}let p=document.createRange();p.setEnd(c.node,c.offset),p.setStart(s.node,s.offset),u.removeAllRanges(),u.addRange(p)}}ignoreMutation(t){return!this.contentDOM&&t.type!="selection"}get contentLost(){return this.contentDOM&&this.contentDOM!=this.dom&&!this.dom.contains(this.contentDOM)}markDirty(t,r){for(let o=0,a=0;a<this.children.length;a++){let i=this.children[a],l=o+i.size;if(o==l?t<=l&&r>=o:t<l&&r>o){let s=o+i.border,c=l-i.border;if(t>=s&&r<=c){this.dirty=t==o||r==l?Ca:iv,t==s&&r==c&&(i.contentLost||i.dom.parentNode!=this.contentDOM)?i.dirty=oo:i.markDirty(t-s,r-s);return}else i.dirty=i.dom==i.contentDOM&&i.dom.parentNode==this.contentDOM&&!i.children.length?Ca:oo}o=l}this.dirty=Ca}markParentsDirty(){let t=1;for(let r=this.parent;r;r=r.parent,t++){let o=t==1?Ca:iv;r.dirty<o&&(r.dirty=o)}}get domAtom(){return!1}get ignoreForCoords(){return!1}isText(t){return!1}}class hw extends Xs{constructor(t,r,o,a){let i,l=r.type.toDOM;if(typeof l=="function"&&(l=l(o,()=>{if(!i)return a;if(i.parent)return i.parent.posBeforeChild(i)})),!r.type.spec.raw){if(l.nodeType!=1){let s=document.createElement("span");s.appendChild(l),l=s}l.contentEditable="false",l.classList.add("ProseMirror-widget")}super(t,[],l,null),this.widget=r,this.widget=r,i=this}matchesWidget(t){return this.dirty==ar&&t.type.eq(this.widget.type)}parseRule(){return{ignore:!0}}stopEvent(t){let r=this.widget.spec.stopEvent;return r?r(t):!1}ignoreMutation(t){return t.type!="selection"||this.widget.spec.ignoreSelection}destroy(){this.widget.type.destroy(this.dom),super.destroy()}get domAtom(){return!0}get side(){return this.widget.type.side}}class Hge extends Xs{constructor(t,r,o,a){super(t,[],r,null),this.textDOM=o,this.text=a}get size(){return this.text.length}localPosFromDOM(t,r){return t!=this.textDOM?this.posAtStart+(r?this.size:0):this.posAtStart+r}domFromPos(t){return{node:this.textDOM,offset:t}}ignoreMutation(t){return t.type==="characterData"&&t.target.nodeValue==t.oldValue}}class Fa extends Xs{constructor(t,r,o,a,i){super(t,[],o,a),this.mark=r,this.spec=i}static create(t,r,o,a){let i=a.nodeViews[r.type.name],l=i&&i(r,a,o);return(!l||!l.dom)&&(l=Xa.renderSpec(document,r.type.spec.toDOM(r,o),null,r.attrs)),new Fa(t,r,l.dom,l.contentDOM||l.dom,l)}parseRule(){return this.dirty&oo||this.mark.type.spec.reparseInView?null:{mark:this.mark.type.name,attrs:this.mark.attrs,contentElement:this.contentDOM}}matchesMark(t){return this.dirty!=oo&&this.mark.eq(t)}markDirty(t,r){if(super.markDirty(t,r),this.dirty!=ar){let o=this.parent;for(;!o.node;)o=o.parent;o.dirty<this.dirty&&(o.dirty=this.dirty),this.dirty=ar}}slice(t,r,o){let a=Fa.create(this.parent,this.mark,!0,o),i=this.children,l=this.size;r<l&&(i=I0(i,r,l,o)),t>0&&(i=I0(i,0,t,o));for(let s=0;s<i.length;s++)i[s].parent=a;return a.children=i,a}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}}class Jo extends Xs{constructor(t,r,o,a,i,l,s,c,u){super(t,[],i,l),this.node=r,this.outerDeco=o,this.innerDeco=a,this.nodeDOM=s}static create(t,r,o,a,i,l){let s=i.nodeViews[r.type.name],c,u=s&&s(r,i,()=>{if(!c)return l;if(c.parent)return c.parent.posBeforeChild(c)},o,a),d=u&&u.dom,f=u&&u.contentDOM;if(r.isText){if(!d)d=document.createTextNode(r.text);else if(d.nodeType!=3)throw new RangeError("Text must be rendered as a DOM text node")}else d||({dom:d,contentDOM:f}=Xa.renderSpec(document,r.type.spec.toDOM(r),null,r.attrs));!f&&!r.isText&&d.nodeName!="BR"&&(d.hasAttribute("contenteditable")||(d.contentEditable="false"),r.type.spec.draggable&&(d.draggable=!0));let p=d;return d=Mw(d,o,r),u?c=new Yge(t,r,o,a,d,f||null,p,u,i,l+1):r.isText?new sf(t,r,o,a,d,p,i):new Jo(t,r,o,a,d,f||null,p,i,l+1)}parseRule(){if(this.node.type.spec.reparseInView)return null;let t={node:this.node.type.name,attrs:this.node.attrs};if(this.node.type.whitespace=="pre"&&(t.preserveWhitespace="full"),!this.contentDOM)t.getContent=()=>this.node.content;else if(!this.contentLost)t.contentElement=this.contentDOM;else{for(let r=this.children.length-1;r>=0;r--){let o=this.children[r];if(this.dom.contains(o.dom.parentNode)){t.contentElement=o.dom.parentNode;break}}t.contentElement||(t.getContent=()=>fe.empty)}return t}matchesNode(t,r,o){return this.dirty==ar&&t.eq(this.node)&&zu(r,this.outerDeco)&&o.eq(this.innerDeco)}get size(){return this.node.nodeSize}get border(){return this.node.isLeaf?0:1}updateChildren(t,r){let o=this.node.inlineContent,a=r,i=t.composing?this.localCompositionInfo(t,r):null,l=i&&i.pos>-1?i:null,s=i&&i.pos<0,c=new Wge(this,l&&l.node,t);Kge(this.node,this.innerDeco,(u,d,f)=>{u.spec.marks?c.syncToMarks(u.spec.marks,o,t):u.type.side>=0&&!f&&c.syncToMarks(d==this.node.childCount?gt.none:this.node.child(d).marks,o,t),c.placeWidget(u,t,a)},(u,d,f,p)=>{c.syncToMarks(u.marks,o,t);let h;c.findNodeMatch(u,d,f,p)||s&&t.state.selection.from>a&&t.state.selection.to<a+u.nodeSize&&(h=c.findIndexWithChild(i.node))>-1&&c.updateNodeAt(u,d,f,h,t)||c.updateNextNode(u,d,f,t,p,a)||c.addNode(u,d,f,t,a),a+=u.nodeSize}),c.syncToMarks([],o,t),this.node.isTextblock&&c.addTextblockHacks(),c.destroyRest(),(c.changed||this.dirty==Ca)&&(l&&this.protectLocalComposition(t,l),vw(this.contentDOM,this.children,t),qi&&Jge(this.dom))}localCompositionInfo(t,r){let{from:o,to:a}=t.state.selection;if(!(t.state.selection instanceof Ge)||o<r||a>r+this.node.content.size)return null;let i=t.input.compositionNode;if(!i||!this.dom.contains(i.parentNode))return null;if(this.node.inlineContent){let l=i.nodeValue,s=Zge(this.node.content,l,o-r,a-r);return s<0?null:{node:i,pos:s,text:l}}else return{node:i,pos:-1,text:""}}protectLocalComposition(t,{node:r,pos:o,text:a}){if(this.getDesc(r))return;let i=r;for(;i.parentNode!=this.contentDOM;i=i.parentNode){for(;i.previousSibling;)i.parentNode.removeChild(i.previousSibling);for(;i.nextSibling;)i.parentNode.removeChild(i.nextSibling);i.pmViewDesc&&(i.pmViewDesc=void 0)}let l=new Hge(this,i,r,a);t.input.compositionNodes.push(l),this.children=I0(this.children,o,o+a.length,t,l)}update(t,r,o,a){return this.dirty==oo||!t.sameMarkup(this.node)?!1:(this.updateInner(t,r,o,a),!0)}updateInner(t,r,o,a){this.updateOuterDeco(r),this.node=t,this.innerDeco=o,this.contentDOM&&this.updateChildren(a,this.posAtStart),this.dirty=ar}updateOuterDeco(t){if(zu(t,this.outerDeco))return;let r=this.nodeDOM.nodeType!=1,o=this.dom;this.dom=yw(this.dom,this.nodeDOM,_0(this.outerDeco,this.node,r),_0(t,this.node,r)),this.dom!=o&&(o.pmViewDesc=void 0,this.dom.pmViewDesc=this),this.outerDeco=t}selectNode(){this.nodeDOM.nodeType==1&&this.nodeDOM.classList.add("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&(this.dom.draggable=!0)}deselectNode(){this.nodeDOM.nodeType==1&&(this.nodeDOM.classList.remove("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&this.dom.removeAttribute("draggable"))}get domAtom(){return this.node.isAtom}}function lv(e,t,r,o,a){Mw(o,t,e);let i=new Jo(void 0,e,t,r,o,o,o,a,0);return i.contentDOM&&i.updateChildren(a,0),i}class sf extends Jo{constructor(t,r,o,a,i,l,s){super(t,r,o,a,i,null,l,s,0)}parseRule(){let t=this.nodeDOM.parentNode;for(;t&&t!=this.dom&&!t.pmIsDeco;)t=t.parentNode;return{skip:t||!0}}update(t,r,o,a){return this.dirty==oo||this.dirty!=ar&&!this.inParent()||!t.sameMarkup(this.node)?!1:(this.updateOuterDeco(r),(this.dirty!=ar||t.text!=this.node.text)&&t.text!=this.nodeDOM.nodeValue&&(this.nodeDOM.nodeValue=t.text,a.trackWrites==this.nodeDOM&&(a.trackWrites=null)),this.node=t,this.dirty=ar,!0)}inParent(){let t=this.parent.contentDOM;for(let r=this.nodeDOM;r;r=r.parentNode)if(r==t)return!0;return!1}domFromPos(t){return{node:this.nodeDOM,offset:t}}localPosFromDOM(t,r,o){return t==this.nodeDOM?this.posAtStart+Math.min(r,this.node.text.length):super.localPosFromDOM(t,r,o)}ignoreMutation(t){return t.type!="characterData"&&t.type!="selection"}slice(t,r,o){let a=this.node.cut(t,r),i=document.createTextNode(a.text);return new sf(this.parent,a,this.outerDeco,this.innerDeco,i,i,o)}markDirty(t,r){super.markDirty(t,r),this.dom!=this.nodeDOM&&(t==0||r==this.nodeDOM.nodeValue.length)&&(this.dirty=oo)}get domAtom(){return!1}isText(t){return this.node.text==t}}class gw extends Xs{parseRule(){return{ignore:!0}}matchesHack(t){return this.dirty==ar&&this.dom.nodeName==t}get domAtom(){return!0}get ignoreForCoords(){return this.dom.nodeName=="IMG"}}class Yge extends Jo{constructor(t,r,o,a,i,l,s,c,u,d){super(t,r,o,a,i,l,s,u,d),this.spec=c}update(t,r,o,a){if(this.dirty==oo)return!1;if(this.spec.update&&(this.node.type==t.type||this.spec.multiType)){let i=this.spec.update(t,r,o);return i&&this.updateInner(t,r,o,a),i}else return!this.contentDOM&&!t.isLeaf?!1:super.update(t,r,o,a)}selectNode(){this.spec.selectNode?this.spec.selectNode():super.selectNode()}deselectNode(){this.spec.deselectNode?this.spec.deselectNode():super.deselectNode()}setSelection(t,r,o,a){this.spec.setSelection?this.spec.setSelection(t,r,o):super.setSelection(t,r,o,a)}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}stopEvent(t){return this.spec.stopEvent?this.spec.stopEvent(t):!1}ignoreMutation(t){return this.spec.ignoreMutation?this.spec.ignoreMutation(t):super.ignoreMutation(t)}}function vw(e,t,r){let o=e.firstChild,a=!1;for(let i=0;i<t.length;i++){let l=t[i],s=l.dom;if(s.parentNode==e){for(;s!=o;)o=sv(o),a=!0;o=o.nextSibling}else a=!0,e.insertBefore(s,o);if(l instanceof Fa){let c=o?o.previousSibling:e.lastChild;vw(l.contentDOM,l.children,r),o=c?c.nextSibling:e.firstChild}}for(;o;)o=sv(o),a=!0;a&&r.trackWrites==e&&(r.trackWrites=null)}const Ql=function(e){e&&(this.nodeName=e)};Ql.prototype=Object.create(null);const Ea=[new Ql];function _0(e,t,r){if(e.length==0)return Ea;let o=r?Ea[0]:new Ql,a=[o];for(let i=0;i<e.length;i++){let l=e[i].type.attrs;if(l){l.nodeName&&a.push(o=new Ql(l.nodeName));for(let s in l){let c=l[s];c!=null&&(r&&a.length==1&&a.push(o=new Ql(t.isInline?"span":"div")),s=="class"?o.class=(o.class?o.class+" ":"")+c:s=="style"?o.style=(o.style?o.style+";":"")+c:s!="nodeName"&&(o[s]=c))}}}return a}function yw(e,t,r,o){if(r==Ea&&o==Ea)return t;let a=t;for(let i=0;i<o.length;i++){let l=o[i],s=r[i];if(i){let c;s&&s.nodeName==l.nodeName&&a!=e&&(c=a.parentNode)&&c.nodeName.toLowerCase()==l.nodeName||(c=document.createElement(l.nodeName),c.pmIsDeco=!0,c.appendChild(a),s=Ea[0]),a=c}Qge(a,s||Ea[0],l)}return a}function Qge(e,t,r){for(let o in t)o!="class"&&o!="style"&&o!="nodeName"&&!(o in r)&&e.removeAttribute(o);for(let o in r)o!="class"&&o!="style"&&o!="nodeName"&&r[o]!=t[o]&&e.setAttribute(o,r[o]);if(t.class!=r.class){let o=t.class?t.class.split(" ").filter(Boolean):[],a=r.class?r.class.split(" ").filter(Boolean):[];for(let i=0;i<o.length;i++)a.indexOf(o[i])==-1&&e.classList.remove(o[i]);for(let i=0;i<a.length;i++)o.indexOf(a[i])==-1&&e.classList.add(a[i]);e.classList.length==0&&e.removeAttribute("class")}if(t.style!=r.style){if(t.style){let o=/\s*([\w\-\xa1-\uffff]+)\s*:(?:"(?:\\.|[^"])*"|'(?:\\.|[^'])*'|\(.*?\)|[^;])*/g,a;for(;a=o.exec(t.style);)e.style.removeProperty(a[1])}r.style&&(e.style.cssText+=r.style)}}function Mw(e,t,r){return yw(e,e,Ea,_0(t,r,e.nodeType!=1))}function zu(e,t){if(e.length!=t.length)return!1;for(let r=0;r<e.length;r++)if(!e[r].type.eq(t[r].type))return!1;return!0}function sv(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}class Wge{constructor(t,r,o){this.lock=r,this.view=o,this.index=0,this.stack=[],this.changed=!1,this.top=t,this.preMatch=qge(t.node.content,t)}destroyBetween(t,r){if(t!=r){for(let o=t;o<r;o++)this.top.children[o].destroy();this.top.children.splice(t,r-t),this.changed=!0}}destroyRest(){this.destroyBetween(this.index,this.top.children.length)}syncToMarks(t,r,o){let a=0,i=this.stack.length>>1,l=Math.min(i,t.length);for(;a<l&&(a==i-1?this.top:this.stack[a+1<<1]).matchesMark(t[a])&&t[a].type.spec.spanning!==!1;)a++;for(;a<i;)this.destroyRest(),this.top.dirty=ar,this.index=this.stack.pop(),this.top=this.stack.pop(),i--;for(;i<t.length;){this.stack.push(this.top,this.index+1);let s=-1;for(let c=this.index;c<Math.min(this.index+3,this.top.children.length);c++){let u=this.top.children[c];if(u.matchesMark(t[i])&&!this.isLocked(u.dom)){s=c;break}}if(s>-1)s>this.index&&(this.changed=!0,this.destroyBetween(this.index,s)),this.top=this.top.children[this.index];else{let c=Fa.create(this.top,t[i],r,o);this.top.children.splice(this.index,0,c),this.top=c,this.changed=!0}this.index=0,i++}}findNodeMatch(t,r,o,a){let i=-1,l;if(a>=this.preMatch.index&&(l=this.preMatch.matches[a-this.preMatch.index]).parent==this.top&&l.matchesNode(t,r,o))i=this.top.children.indexOf(l,this.index);else for(let s=this.index,c=Math.min(this.top.children.length,s+5);s<c;s++){let u=this.top.children[s];if(u.matchesNode(t,r,o)&&!this.preMatch.matched.has(u)){i=s;break}}return i<0?!1:(this.destroyBetween(this.index,i),this.index++,!0)}updateNodeAt(t,r,o,a,i){let l=this.top.children[a];return l.dirty==oo&&l.dom==l.contentDOM&&(l.dirty=Ca),l.update(t,r,o,i)?(this.destroyBetween(this.index,a),this.index++,!0):!1}findIndexWithChild(t){for(;;){let r=t.parentNode;if(!r)return-1;if(r==this.top.contentDOM){let o=t.pmViewDesc;if(o){for(let a=this.index;a<this.top.children.length;a++)if(this.top.children[a]==o)return a}return-1}t=r}}updateNextNode(t,r,o,a,i,l){for(let s=this.index;s<this.top.children.length;s++){let c=this.top.children[s];if(c instanceof Jo){let u=this.preMatch.matched.get(c);if(u!=null&&u!=i)return!1;let d=c.dom,f,p=this.isLocked(d)&&!(t.isText&&c.node&&c.node.isText&&c.nodeDOM.nodeValue==t.text&&c.dirty!=oo&&zu(r,c.outerDeco));if(!p&&c.update(t,r,o,a))return this.destroyBetween(this.index,s),c.dom!=d&&(this.changed=!0),this.index++,!0;if(!p&&(f=this.recreateWrapper(c,t,r,o,a,l)))return this.destroyBetween(this.index,s),this.top.children[this.index]=f,f.contentDOM&&(f.dirty=Ca,f.updateChildren(a,l+1),f.dirty=ar),this.changed=!0,this.index++,!0;break}}return!1}recreateWrapper(t,r,o,a,i,l){if(t.dirty||r.isAtom||!t.children.length||!t.node.content.eq(r.content)||!zu(o,t.outerDeco)||!a.eq(t.innerDeco))return null;let s=Jo.create(this.top,r,o,a,i,l);if(s.contentDOM){s.children=t.children,t.children=[];for(let c of s.children)c.parent=s}return t.destroy(),s}addNode(t,r,o,a,i){let l=Jo.create(this.top,t,r,o,a,i);l.contentDOM&&l.updateChildren(a,i+1),this.top.children.splice(this.index++,0,l),this.changed=!0}placeWidget(t,r,o){let a=this.index<this.top.children.length?this.top.children[this.index]:null;if(a&&a.matchesWidget(t)&&(t==a.widget||!a.widget.type.toDOM.parentNode))this.index++;else{let i=new hw(this.top,t,r,o);this.top.children.splice(this.index++,0,i),this.changed=!0}}addTextblockHacks(){let t=this.top.children[this.index-1],r=this.top;for(;t instanceof Fa;)r=t,t=r.children[r.children.length-1];(!t||!(t instanceof sf)||/\n$/.test(t.node.text)||this.view.requiresGeckoHackNode&&/\s$/.test(t.node.text))&&((bn||fn)&&t&&t.dom.contentEditable=="false"&&this.addHackNode("IMG",r),this.addHackNode("BR",this.top))}addHackNode(t,r){if(r==this.top&&this.index<r.children.length&&r.children[this.index].matchesHack(t))this.index++;else{let o=document.createElement(t);t=="IMG"&&(o.className="ProseMirror-separator",o.alt=""),t=="BR"&&(o.className="ProseMirror-trailingBreak");let a=new gw(this.top,[],o,null);r!=this.top?r.children.push(a):r.children.splice(this.index++,0,a),this.changed=!0}}isLocked(t){return this.lock&&(t==this.lock||t.nodeType==1&&t.contains(this.lock.parentNode))}}function qge(e,t){let r=t,o=r.children.length,a=e.childCount,i=new Map,l=[];e:for(;a>0;){let s;for(;;)if(o){let u=r.children[o-1];if(u instanceof Fa)r=u,o=u.children.length;else{s=u,o--;break}}else{if(r==t)break e;o=r.parent.children.indexOf(r),r=r.parent}let c=s.node;if(c){if(c!=e.child(a-1))break;--a,i.set(s,a),l.push(s)}}return{index:a,matched:i,matches:l.reverse()}}function Gge(e,t){return e.type.side-t.type.side}function Kge(e,t,r,o){let a=t.locals(e),i=0;if(a.length==0){for(let u=0;u<e.childCount;u++){let d=e.child(u);o(d,a,t.forChild(i,d),u),i+=d.nodeSize}return}let l=0,s=[],c=null;for(let u=0;;){let d,f;for(;l<a.length&&a[l].to==i;){let v=a[l++];v.widget&&(d?(f||(f=[d])).push(v):d=v)}if(d)if(f){f.sort(Gge);for(let v=0;v<f.length;v++)r(f[v],u,!!c)}else r(d,u,!!c);let p,h;if(c)h=-1,p=c,c=null;else if(u<e.childCount)h=u,p=e.child(u++);else break;for(let v=0;v<s.length;v++)s[v].to<=i&&s.splice(v--,1);for(;l<a.length&&a[l].from<=i&&a[l].to>i;)s.push(a[l++]);let m=i+p.nodeSize;if(p.isText){let v=m;l<a.length&&a[l].from<v&&(v=a[l].from);for(let y=0;y<s.length;y++)s[y].to<v&&(v=s[y].to);v<m&&(c=p.cut(v-i),p=p.cut(0,v-i),m=v,h=-1)}else for(;l<a.length&&a[l].to<m;)l++;let g=p.isInline&&!p.isLeaf?s.filter(v=>!v.inline):s.slice();o(p,g,t.forChild(i,p),h),i=m}}function Jge(e){if(e.nodeName=="UL"||e.nodeName=="OL"){let t=e.style.cssText;e.style.cssText=t+"; list-style: square !important",window.getComputedStyle(e).listStyle,e.style.cssText=t}}function Zge(e,t,r,o){for(let a=0,i=0;a<e.childCount&&i<=o;){let l=e.child(a++),s=i;if(i+=l.nodeSize,!l.isText)continue;let c=l.text;for(;a<e.childCount;){let u=e.child(a++);if(i+=u.nodeSize,!u.isText)break;c+=u.text}if(i>=r){if(i>=o&&c.slice(o-t.length-s,o-s)==t)return o-t.length;let u=s<o?c.lastIndexOf(t,o-s-1):-1;if(u>=0&&u+t.length+s>=r)return s+u;if(r==o&&c.length>=o+t.length-s&&c.slice(o-s,o-s+t.length)==t)return o}}return-1}function I0(e,t,r,o,a){let i=[];for(let l=0,s=0;l<e.length;l++){let c=e[l],u=s,d=s+=c.size;u>=r||d<=t?i.push(c):(u<t&&i.push(c.slice(0,t-u,o)),a&&(i.push(a),a=void 0),d>r&&i.push(c.slice(r-u,c.size,o)))}return i}function qh(e,t=null){let r=e.domSelectionRange(),o=e.state.doc;if(!r.focusNode)return null;let a=e.docView.nearestDesc(r.focusNode),i=a&&a.size==0,l=e.docView.posFromDOM(r.focusNode,r.focusOffset,1);if(l<0)return null;let s=o.resolve(l),c,u;if(lf(r)){for(c=l;a&&!a.node;)a=a.parent;let f=a.node;if(a&&f.isAtom&&Pe.isSelectable(f)&&a.parent&&!(f.isInline&&xge(r.focusNode,r.focusOffset,a.dom))){let p=a.posBefore;u=new Pe(l==p?s:o.resolve(p))}}else{if(r instanceof e.dom.ownerDocument.defaultView.Selection&&r.rangeCount>1){let f=l,p=l;for(let h=0;h<r.rangeCount;h++){let m=r.getRangeAt(h);f=Math.min(f,e.docView.posFromDOM(m.startContainer,m.startOffset,1)),p=Math.max(p,e.docView.posFromDOM(m.endContainer,m.endOffset,-1))}if(f<0)return null;[c,l]=p==e.state.selection.anchor?[p,f]:[f,p],s=o.resolve(l)}else c=e.docView.posFromDOM(r.anchorNode,r.anchorOffset,1);if(c<0)return null}let d=o.resolve(c);if(!u){let f=t=="pointer"||e.state.selection.head<s.pos&&!i?1:-1;u=Gh(e,d,s,f)}return u}function bw(e){return e.editable?e.hasFocus():Nw(e)&&document.activeElement&&document.activeElement.contains(e.dom)}function yo(e,t=!1){let r=e.state.selection;if(ww(e,r),!!bw(e)){if(!t&&e.input.mouseDown&&e.input.mouseDown.allowDefault&&fn){let o=e.domSelectionRange(),a=e.domObserver.currentSelection;if(o.anchorNode&&a.anchorNode&&Ra(o.anchorNode,o.anchorOffset,a.anchorNode,a.anchorOffset)){e.input.mouseDown.delayedSelectionSync=!0,e.domObserver.setCurSelection();return}}if(e.domObserver.disconnectSelection(),e.cursorWrapper)e4e(e);else{let{anchor:o,head:a}=r,i,l;cv&&!(r instanceof Ge)&&(r.$from.parent.inlineContent||(i=uv(e,r.from)),!r.empty&&!r.$from.parent.inlineContent&&(l=uv(e,r.to))),e.docView.setSelection(o,a,e.root,t),cv&&(i&&dv(i),l&&dv(l)),r.visible?e.dom.classList.remove("ProseMirror-hideselection"):(e.dom.classList.add("ProseMirror-hideselection"),"onselectionchange"in document&&Xge(e))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}}const cv=bn||fn&&sw<63;function uv(e,t){let{node:r,offset:o}=e.docView.domFromPos(t,0),a=o<r.childNodes.length?r.childNodes[o]:null,i=o?r.childNodes[o-1]:null;if(bn&&a&&a.contentEditable=="false")return np(a);if((!a||a.contentEditable=="false")&&(!i||i.contentEditable=="false")){if(a)return np(a);if(i)return np(i)}}function np(e){return e.contentEditable="true",bn&&e.draggable&&(e.draggable=!1,e.wasDraggable=!0),e}function dv(e){e.contentEditable="false",e.wasDraggable&&(e.draggable=!0,e.wasDraggable=null)}function Xge(e){let t=e.dom.ownerDocument;t.removeEventListener("selectionchange",e.input.hideSelectionGuard);let r=e.domSelectionRange(),o=r.anchorNode,a=r.anchorOffset;t.addEventListener("selectionchange",e.input.hideSelectionGuard=()=>{(r.anchorNode!=o||r.anchorOffset!=a)&&(t.removeEventListener("selectionchange",e.input.hideSelectionGuard),setTimeout(()=>{(!bw(e)||e.state.selection.visible)&&e.dom.classList.remove("ProseMirror-hideselection")},20))})}function e4e(e){let t=e.domSelection(),r=document.createRange();if(!t)return;let o=e.cursorWrapper.dom,a=o.nodeName=="IMG";a?r.setStart(o.parentNode,rn(o)+1):r.setStart(o,0),r.collapse(!0),t.removeAllRanges(),t.addRange(r),!a&&!e.state.selection.visible&&An&&Ko<=11&&(o.disabled=!0,o.disabled=!1)}function ww(e,t){if(t instanceof Pe){let r=e.docView.descAt(t.from);r!=e.lastSelectedViewDesc&&(fv(e),r&&r.selectNode(),e.lastSelectedViewDesc=r)}else fv(e)}function fv(e){e.lastSelectedViewDesc&&(e.lastSelectedViewDesc.parent&&e.lastSelectedViewDesc.deselectNode(),e.lastSelectedViewDesc=void 0)}function Gh(e,t,r,o){return e.someProp("createSelectionBetween",a=>a(e,t,r))||Ge.between(t,r,o)}function pv(e){return e.editable&&!e.hasFocus()?!1:Nw(e)}function Nw(e){let t=e.domSelectionRange();if(!t.anchorNode)return!1;try{return e.dom.contains(t.anchorNode.nodeType==3?t.anchorNode.parentNode:t.anchorNode)&&(e.editable||e.dom.contains(t.focusNode.nodeType==3?t.focusNode.parentNode:t.focusNode))}catch{return!1}}function t4e(e){let t=e.docView.domFromPos(e.state.selection.anchor,0),r=e.domSelectionRange();return Ra(t.node,t.offset,r.anchorNode,r.anchorOffset)}function A0(e,t){let{$anchor:r,$head:o}=e.selection,a=t>0?r.max(o):r.min(o),i=a.parent.inlineContent?a.depth?e.doc.resolve(t>0?a.after():a.before()):null:a;return i&&Ze.findFrom(i,t)}function zo(e,t){return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()),!0}function mv(e,t,r){let o=e.state.selection;if(o instanceof Ge)if(r.indexOf("s")>-1){let{$head:a}=o,i=a.textOffset?null:t<0?a.nodeBefore:a.nodeAfter;if(!i||i.isText||!i.isLeaf)return!1;let l=e.state.doc.resolve(a.pos+i.nodeSize*(t<0?-1:1));return zo(e,new Ge(o.$anchor,l))}else if(o.empty){if(e.endOfTextblock(t>0?"forward":"backward")){let a=A0(e.state,t);return a&&a instanceof Pe?zo(e,a):!1}else if(!(tr&&r.indexOf("m")>-1)){let a=o.$head,i=a.textOffset?null:t<0?a.nodeBefore:a.nodeAfter,l;if(!i||i.isText)return!1;let s=t<0?a.pos-i.nodeSize:a.pos;return i.isAtom||(l=e.docView.descAt(s))&&!l.contentDOM?Pe.isSelectable(i)?zo(e,new Pe(t<0?e.state.doc.resolve(a.pos-i.nodeSize):a)):Zs?zo(e,new Ge(e.state.doc.resolve(t<0?s:s+i.nodeSize))):!1:!1}}else return!1;else{if(o instanceof Pe&&o.node.isInline)return zo(e,new Ge(t>0?o.$to:o.$from));{let a=A0(e.state,t);return a?zo(e,a):!1}}}function ju(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function Wl(e,t){let r=e.pmViewDesc;return r&&r.size==0&&(t<0||e.nextSibling||e.nodeName!="BR")}function ui(e,t){return t<0?n4e(e):r4e(e)}function n4e(e){let t=e.domSelectionRange(),r=t.focusNode,o=t.focusOffset;if(!r)return;let a,i,l=!1;for(Or&&r.nodeType==1&&o<ju(r)&&Wl(r.childNodes[o],-1)&&(l=!0);;)if(o>0){if(r.nodeType!=1)break;{let s=r.childNodes[o-1];if(Wl(s,-1))a=r,i=--o;else if(s.nodeType==3)r=s,o=r.nodeValue.length;else break}}else{if(kw(r))break;{let s=r.previousSibling;for(;s&&Wl(s,-1);)a=r.parentNode,i=rn(s),s=s.previousSibling;if(s)r=s,o=ju(r);else{if(r=r.parentNode,r==e.dom)break;o=0}}}l?O0(e,r,o):a&&O0(e,a,i)}function r4e(e){let t=e.domSelectionRange(),r=t.focusNode,o=t.focusOffset;if(!r)return;let a=ju(r),i,l;for(;;)if(o<a){if(r.nodeType!=1)break;let s=r.childNodes[o];if(Wl(s,1))i=r,l=++o;else break}else{if(kw(r))break;{let s=r.nextSibling;for(;s&&Wl(s,1);)i=s.parentNode,l=rn(s)+1,s=s.nextSibling;if(s)r=s,o=0,a=ju(r);else{if(r=r.parentNode,r==e.dom)break;o=a=0}}}i&&O0(e,i,l)}function kw(e){let t=e.pmViewDesc;return t&&t.node&&t.node.isBlock}function o4e(e,t){for(;e&&t==e.childNodes.length&&!Js(e);)t=rn(e)+1,e=e.parentNode;for(;e&&t<e.childNodes.length;){let r=e.childNodes[t];if(r.nodeType==3)return r;if(r.nodeType==1&&r.contentEditable=="false")break;e=r,t=0}}function a4e(e,t){for(;e&&!t&&!Js(e);)t=rn(e),e=e.parentNode;for(;e&&t;){let r=e.childNodes[t-1];if(r.nodeType==3)return r;if(r.nodeType==1&&r.contentEditable=="false")break;e=r,t=e.childNodes.length}}function O0(e,t,r){if(t.nodeType!=3){let i,l;(l=o4e(t,r))?(t=l,r=0):(i=a4e(t,r))&&(t=i,r=i.nodeValue.length)}let o=e.domSelection();if(!o)return;if(lf(o)){let i=document.createRange();i.setEnd(t,r),i.setStart(t,r),o.removeAllRanges(),o.addRange(i)}else o.extend&&o.extend(t,r);e.domObserver.setCurSelection();let{state:a}=e;setTimeout(()=>{e.state==a&&yo(e)},50)}function hv(e,t){let r=e.state.doc.resolve(t);if(!(fn||Tge)&&r.parent.inlineContent){let a=e.coordsAtPos(t);if(t>r.start()){let i=e.coordsAtPos(t-1),l=(i.top+i.bottom)/2;if(l>a.top&&l<a.bottom&&Math.abs(i.left-a.left)>1)return i.left<a.left?"ltr":"rtl"}if(t<r.end()){let i=e.coordsAtPos(t+1),l=(i.top+i.bottom)/2;if(l>a.top&&l<a.bottom&&Math.abs(i.left-a.left)>1)return i.left>a.left?"ltr":"rtl"}}return getComputedStyle(e.dom).direction=="rtl"?"rtl":"ltr"}function gv(e,t,r){let o=e.state.selection;if(o instanceof Ge&&!o.empty||r.indexOf("s")>-1||tr&&r.indexOf("m")>-1)return!1;let{$from:a,$to:i}=o;if(!a.parent.inlineContent||e.endOfTextblock(t<0?"up":"down")){let l=A0(e.state,t);if(l&&l instanceof Pe)return zo(e,l)}if(!a.parent.inlineContent){let l=t<0?a:i,s=o instanceof _r?Ze.near(l,t):Ze.findFrom(l,t);return s?zo(e,s):!1}return!1}function vv(e,t){if(!(e.state.selection instanceof Ge))return!0;let{$head:r,$anchor:o,empty:a}=e.state.selection;if(!r.sameParent(o))return!0;if(!a)return!1;if(e.endOfTextblock(t>0?"forward":"backward"))return!0;let i=!r.textOffset&&(t<0?r.nodeBefore:r.nodeAfter);if(i&&!i.isText){let l=e.state.tr;return t<0?l.delete(r.pos-i.nodeSize,r.pos):l.delete(r.pos,r.pos+i.nodeSize),e.dispatch(l),!0}return!1}function yv(e,t,r){e.domObserver.stop(),t.contentEditable=r,e.domObserver.start()}function i4e(e){if(!bn||e.state.selection.$head.parentOffset>0)return!1;let{focusNode:t,focusOffset:r}=e.domSelectionRange();if(t&&t.nodeType==1&&r==0&&t.firstChild&&t.firstChild.contentEditable=="false"){let o=t.firstChild;yv(e,o,"true"),setTimeout(()=>yv(e,o,"false"),20)}return!1}function l4e(e){let t="";return e.ctrlKey&&(t+="c"),e.metaKey&&(t+="m"),e.altKey&&(t+="a"),e.shiftKey&&(t+="s"),t}function s4e(e,t){let r=t.keyCode,o=l4e(t);if(r==8||tr&&r==72&&o=="c")return vv(e,-1)||ui(e,-1);if(r==46&&!t.shiftKey||tr&&r==68&&o=="c")return vv(e,1)||ui(e,1);if(r==13||r==27)return!0;if(r==37||tr&&r==66&&o=="c"){let a=r==37?hv(e,e.state.selection.from)=="ltr"?-1:1:-1;return mv(e,a,o)||ui(e,a)}else if(r==39||tr&&r==70&&o=="c"){let a=r==39?hv(e,e.state.selection.from)=="ltr"?1:-1:1;return mv(e,a,o)||ui(e,a)}else{if(r==38||tr&&r==80&&o=="c")return gv(e,-1,o)||ui(e,-1);if(r==40||tr&&r==78&&o=="c")return i4e(e)||gv(e,1,o)||ui(e,1);if(o==(tr?"m":"c")&&(r==66||r==73||r==89||r==90))return!0}return!1}function xw(e,t){e.someProp("transformCopied",h=>{t=h(t,e)});let r=[],{content:o,openStart:a,openEnd:i}=t;for(;a>1&&i>1&&o.childCount==1&&o.firstChild.childCount==1;){a--,i--;let h=o.firstChild;r.push(h.type.name,h.attrs!=h.type.defaultAttrs?h.attrs:null),o=h.content}let l=e.someProp("clipboardSerializer")||Xa.fromSchema(e.state.schema),s=_w(),c=s.createElement("div");c.appendChild(l.serializeFragment(o,{document:s}));let u=c.firstChild,d,f=0;for(;u&&u.nodeType==1&&(d=Sw[u.nodeName.toLowerCase()]);){for(let h=d.length-1;h>=0;h--){let m=s.createElement(d[h]);for(;c.firstChild;)m.appendChild(c.firstChild);c.appendChild(m),f++}u=c.firstChild}u&&u.nodeType==1&&u.setAttribute("data-pm-slice",`${a} ${i}${f?` -${f}`:""} ${JSON.stringify(r)}`);let p=e.someProp("clipboardTextSerializer",h=>h(t,e))||t.content.textBetween(0,t.content.size,`
|
|
53
53
|
|
|
54
54
|
`);return{dom:c,text:p,slice:t}}function Cw(e,t,r,o,a){let i=a.parent.type.spec.code,l,s;if(!r&&!t)return null;let c=t&&(o||i||!r);if(c){if(e.someProp("transformPastedText",p=>{t=p(t,i||o,e)}),i)return t?new Ee(fe.from(e.state.schema.text(t.replace(/\r\n?/g,`
|
|
55
|
-
`))),0,0):Ee.empty;let f=e.someProp("clipboardTextParser",p=>p(t,a,o,e));if(f)s=f;else{let p=a.marks(),{schema:h}=e.state,m=Xa.fromSchema(h);l=document.createElement("div"),t.split(/(?:\r\n?|\n)+/).forEach(g=>{let v=l.appendChild(document.createElement("p"));g&&v.appendChild(m.serializeNode(h.text(g,p)))})}}else e.someProp("transformPastedHTML",f=>{r=f(r,e)}),l=s4e(r),Zs&&c4e(l);let u=l&&l.querySelector("[data-pm-slice]"),d=u&&/^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(u.getAttribute("data-pm-slice")||"");if(d&&d[3])for(let f=+d[3];f>0;f--){let p=l.firstChild;for(;p&&p.nodeType!=1;)p=p.nextSibling;if(!p)break;l=p}if(s||(s=(e.someProp("clipboardParser")||e.someProp("domParser")||Go.fromSchema(e.state.schema)).parseSlice(l,{preserveWhitespace:!!(c||d),context:a,ruleFromNode(p){return p.nodeName=="BR"&&!p.nextSibling&&p.parentNode&&!a4e.test(p.parentNode.nodeName)?{ignore:!0}:null}})),d)s=u4e(Mv(s,+d[1],+d[2]),d[4]);else if(s=Ee.maxOpen(i4e(s.content,a),!0),s.openStart||s.openEnd){let f=0,p=0;for(let h=s.content.firstChild;f<s.openStart&&!h.type.spec.isolating;f++,h=h.firstChild);for(let h=s.content.lastChild;p<s.openEnd&&!h.type.spec.isolating;p++,h=h.lastChild);s=Mv(s,f,p)}return e.someProp("transformPasted",f=>{s=f(s,e)}),s}const a4e=/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;function i4e(e,t){if(e.childCount<2)return e;for(let r=t.depth;r>=0;r--){let a=t.node(r).contentMatchAt(t.index(r)),i,l=[];if(e.forEach(s=>{if(!l)return;let c=a.findWrapping(s.type),u;if(!c)return l=null;if(u=l.length&&i.length&&Tw(c,i,s,l[l.length-1],0))l[l.length-1]=u;else{l.length&&(l[l.length-1]=Dw(l[l.length-1],i.length));let d=Ew(s,c);l.push(d),a=a.matchType(d.type),i=c}}),l)return fe.from(l)}return e}function Ew(e,t,r=0){for(let o=t.length-1;o>=r;o--)e=t[o].create(null,fe.from(e));return e}function Tw(e,t,r,o,a){if(a<e.length&&a<t.length&&e[a]==t[a]){let i=Tw(e,t,r,o.lastChild,a+1);if(i)return o.copy(o.content.replaceChild(o.childCount-1,i));if(o.contentMatchAt(o.childCount).matchType(a==e.length-1?r.type:e[a+1]))return o.copy(o.content.append(fe.from(Ew(r,e,a+1))))}}function Dw(e,t){if(t==0)return e;let r=e.content.replaceChild(e.childCount-1,Dw(e.lastChild,t-1)),o=e.contentMatchAt(e.childCount).fillBefore(fe.empty,!0);return e.copy(r.append(o))}function z0(e,t,r,o,a,i){let l=t<0?e.firstChild:e.lastChild,s=l.content;return e.childCount>1&&(i=0),a<o-1&&(s=z0(s,t,r,o,a+1,i)),a>=r&&(s=t<0?l.contentMatchAt(0).fillBefore(s,i<=a).append(s):s.append(l.contentMatchAt(l.childCount).fillBefore(fe.empty,!0))),e.replaceChild(t<0?0:e.childCount-1,l.copy(s))}function Mv(e,t,r){return t<e.openStart&&(e=new Ee(z0(e.content,-1,t,e.openStart,0,e.openEnd),t,e.openEnd)),r<e.openEnd&&(e=new Ee(z0(e.content,1,r,e.openEnd,0,0),e.openStart,r)),e}const Sw={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]};let bv=null;function _w(){return bv||(bv=document.implementation.createHTMLDocument("title"))}let rp=null;function l4e(e){let t=window.trustedTypes;return t?(rp||(rp=t.createPolicy("ProseMirrorClipboard",{createHTML:r=>r})),rp.createHTML(e)):e}function s4e(e){let t=/^(\s*<meta [^>]*>)*/.exec(e);t&&(e=e.slice(t[0].length));let r=_w().createElement("div"),o=/<([a-z][^>\s]+)/i.exec(e),a;if((a=o&&Sw[o[1].toLowerCase()])&&(e=a.map(i=>"<"+i+">").join("")+e+a.map(i=>"</"+i+">").reverse().join("")),r.innerHTML=l4e(e),a)for(let i=0;i<a.length;i++)r=r.querySelector(a[i])||r;return r}function c4e(e){let t=e.querySelectorAll(fn?"span:not([class]):not([style])":"span.Apple-converted-space");for(let r=0;r<t.length;r++){let o=t[r];o.childNodes.length==1&&o.textContent==" "&&o.parentNode&&o.parentNode.replaceChild(e.ownerDocument.createTextNode(" "),o)}}function u4e(e,t){if(!e.size)return e;let r=e.content.firstChild.type.schema,o;try{o=JSON.parse(t)}catch{return e}let{content:a,openStart:i,openEnd:l}=e;for(let s=o.length-2;s>=0;s-=2){let c=r.nodes[o[s]];if(!c||c.hasRequiredAttrs())break;a=fe.from(c.create(o[s+1],a)),i++,l++}return new Ee(a,i,l)}const wn={},Nn={},d4e={touchstart:!0,touchmove:!0};class f4e{constructor(){this.shiftKey=!1,this.mouseDown=null,this.lastKeyCode=null,this.lastKeyCodeTime=0,this.lastClick={time:0,x:0,y:0,type:""},this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastIOSEnter=0,this.lastIOSEnterFallbackTimeout=-1,this.lastFocus=0,this.lastTouch=0,this.lastAndroidDelete=0,this.composing=!1,this.compositionNode=null,this.composingTimeout=-1,this.compositionNodes=[],this.compositionEndedAt=-2e8,this.compositionID=1,this.compositionPendingChanges=0,this.domChangeCount=0,this.eventHandlers=Object.create(null),this.hideSelectionGuard=null}}function p4e(e){for(let t in wn){let r=wn[t];e.dom.addEventListener(t,e.input.eventHandlers[t]=o=>{h4e(e,o)&&!Kh(e,o)&&(e.editable||!(o.type in Nn))&&r(e,o)},d4e[t]?{passive:!0}:void 0)}bn&&e.dom.addEventListener("input",()=>null),j0(e)}function Qo(e,t){e.input.lastSelectionOrigin=t,e.input.lastSelectionTime=Date.now()}function m4e(e){e.domObserver.stop();for(let t in e.input.eventHandlers)e.dom.removeEventListener(t,e.input.eventHandlers[t]);clearTimeout(e.input.composingTimeout),clearTimeout(e.input.lastIOSEnterFallbackTimeout)}function j0(e){e.someProp("handleDOMEvents",t=>{for(let r in t)e.input.eventHandlers[r]||e.dom.addEventListener(r,e.input.eventHandlers[r]=o=>Kh(e,o))})}function Kh(e,t){return e.someProp("handleDOMEvents",r=>{let o=r[t.type];return o?o(e,t)||t.defaultPrevented:!1})}function h4e(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let r=t.target;r!=e.dom;r=r.parentNode)if(!r||r.nodeType==11||r.pmViewDesc&&r.pmViewDesc.stopEvent(t))return!1;return!0}function g4e(e,t){!Kh(e,t)&&wn[t.type]&&(e.editable||!(t.type in Nn))&&wn[t.type](e,t)}Nn.keydown=(e,t)=>{let r=t;if(e.input.shiftKey=r.keyCode==16||r.shiftKey,!Aw(e,r)&&(e.input.lastKeyCode=r.keyCode,e.input.lastKeyCodeTime=Date.now(),!(Er&&fn&&r.keyCode==13)))if(r.keyCode!=229&&e.domObserver.forceFlush(),qi&&r.keyCode==13&&!r.ctrlKey&&!r.altKey&&!r.metaKey){let o=Date.now();e.input.lastIOSEnter=o,e.input.lastIOSEnterFallbackTimeout=setTimeout(()=>{e.input.lastIOSEnter==o&&(e.someProp("handleKeyDown",a=>a(e,Ma(13,"Enter"))),e.input.lastIOSEnter=0)},200)}else e.someProp("handleKeyDown",o=>o(e,r))||o4e(e,r)?r.preventDefault():Qo(e,"key")};Nn.keyup=(e,t)=>{t.keyCode==16&&(e.input.shiftKey=!1)};Nn.keypress=(e,t)=>{let r=t;if(Aw(e,r)||!r.charCode||r.ctrlKey&&!r.altKey||tr&&r.metaKey)return;if(e.someProp("handleKeyPress",a=>a(e,r))){r.preventDefault();return}let o=e.state.selection;if(!(o instanceof Ge)||!o.$from.sameParent(o.$to)){let a=String.fromCharCode(r.charCode);!/[\r\n]/.test(a)&&!e.someProp("handleTextInput",i=>i(e,o.$from.pos,o.$to.pos,a))&&e.dispatch(e.state.tr.insertText(a).scrollIntoView()),r.preventDefault()}};function cf(e){return{left:e.clientX,top:e.clientY}}function v4e(e,t){let r=t.x-e.clientX,o=t.y-e.clientY;return r*r+o*o<100}function Jh(e,t,r,o,a){if(o==-1)return!1;let i=e.state.doc.resolve(o);for(let l=i.depth+1;l>0;l--)if(e.someProp(t,s=>l>i.depth?s(e,r,i.nodeAfter,i.before(l),a,!0):s(e,r,i.node(l),i.before(l),a,!1)))return!0;return!1}function Ii(e,t,r){if(e.focused||e.focus(),e.state.selection.eq(t))return;let o=e.state.tr.setSelection(t);r=="pointer"&&o.setMeta("pointer",!0),e.dispatch(o)}function y4e(e,t){if(t==-1)return!1;let r=e.state.doc.resolve(t),o=r.nodeAfter;return o&&o.isAtom&&Pe.isSelectable(o)?(Ii(e,new Pe(r),"pointer"),!0):!1}function M4e(e,t){if(t==-1)return!1;let r=e.state.selection,o,a;r instanceof Pe&&(o=r.node);let i=e.state.doc.resolve(t);for(let l=i.depth+1;l>0;l--){let s=l>i.depth?i.nodeAfter:i.node(l);if(Pe.isSelectable(s)){o&&r.$from.depth>0&&l>=r.$from.depth&&i.before(r.$from.depth+1)==r.$from.pos?a=i.before(r.$from.depth):a=i.before(l);break}}return a!=null?(Ii(e,Pe.create(e.state.doc,a),"pointer"),!0):!1}function b4e(e,t,r,o,a){return Jh(e,"handleClickOn",t,r,o)||e.someProp("handleClick",i=>i(e,t,o))||(a?M4e(e,r):y4e(e,r))}function w4e(e,t,r,o){return Jh(e,"handleDoubleClickOn",t,r,o)||e.someProp("handleDoubleClick",a=>a(e,t,o))}function N4e(e,t,r,o){return Jh(e,"handleTripleClickOn",t,r,o)||e.someProp("handleTripleClick",a=>a(e,t,o))||k4e(e,r,o)}function k4e(e,t,r){if(r.button!=0)return!1;let o=e.state.doc;if(t==-1)return o.inlineContent?(Ii(e,Ge.create(o,0,o.content.size),"pointer"),!0):!1;let a=o.resolve(t);for(let i=a.depth+1;i>0;i--){let l=i>a.depth?a.nodeAfter:a.node(i),s=a.before(i);if(l.inlineContent)Ii(e,Ge.create(o,s+1,s+1+l.content.size),"pointer");else if(Pe.isSelectable(l))Ii(e,Pe.create(o,s),"pointer");else continue;return!0}}function Zh(e){return Lu(e)}const Iw=tr?"metaKey":"ctrlKey";wn.mousedown=(e,t)=>{let r=t;e.input.shiftKey=r.shiftKey;let o=Zh(e),a=Date.now(),i="singleClick";a-e.input.lastClick.time<500&&v4e(r,e.input.lastClick)&&!r[Iw]&&(e.input.lastClick.type=="singleClick"?i="doubleClick":e.input.lastClick.type=="doubleClick"&&(i="tripleClick")),e.input.lastClick={time:a,x:r.clientX,y:r.clientY,type:i};let l=e.posAtCoords(cf(r));l&&(i=="singleClick"?(e.input.mouseDown&&e.input.mouseDown.done(),e.input.mouseDown=new x4e(e,l,r,!!o)):(i=="doubleClick"?w4e:N4e)(e,l.pos,l.inside,r)?r.preventDefault():Qo(e,"pointer"))};class x4e{constructor(t,r,o,a){this.view=t,this.pos=r,this.event=o,this.flushed=a,this.delayedSelectionSync=!1,this.mightDrag=null,this.startDoc=t.state.doc,this.selectNode=!!o[Iw],this.allowDefault=o.shiftKey;let i,l;if(r.inside>-1)i=t.state.doc.nodeAt(r.inside),l=r.inside;else{let d=t.state.doc.resolve(r.pos);i=d.parent,l=d.depth?d.before():0}const s=a?null:o.target,c=s?t.docView.nearestDesc(s,!0):null;this.target=c&&c.dom.nodeType==1?c.dom:null;let{selection:u}=t.state;(o.button==0&&i.type.spec.draggable&&i.type.spec.selectable!==!1||u instanceof Pe&&u.from<=l&&u.to>l)&&(this.mightDrag={node:i,pos:l,addAttr:!!(this.target&&!this.target.draggable),setUneditable:!!(this.target&&Or&&!this.target.hasAttribute("contentEditable"))}),this.target&&this.mightDrag&&(this.mightDrag.addAttr||this.mightDrag.setUneditable)&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&(this.target.draggable=!0),this.mightDrag.setUneditable&&setTimeout(()=>{this.view.input.mouseDown==this&&this.target.setAttribute("contentEditable","false")},20),this.view.domObserver.start()),t.root.addEventListener("mouseup",this.up=this.up.bind(this)),t.root.addEventListener("mousemove",this.move=this.move.bind(this)),Qo(t,"pointer")}done(){this.view.root.removeEventListener("mouseup",this.up),this.view.root.removeEventListener("mousemove",this.move),this.mightDrag&&this.target&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&this.target.removeAttribute("draggable"),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.delayedSelectionSync&&setTimeout(()=>yo(this.view)),this.view.input.mouseDown=null}up(t){if(this.done(),!this.view.dom.contains(t.target))return;let r=this.pos;this.view.state.doc!=this.startDoc&&(r=this.view.posAtCoords(cf(t))),this.updateAllowDefault(t),this.allowDefault||!r?Qo(this.view,"pointer"):b4e(this.view,r.pos,r.inside,t,this.selectNode)?t.preventDefault():t.button==0&&(this.flushed||bn&&this.mightDrag&&!this.mightDrag.node.isAtom||fn&&!this.view.state.selection.visible&&Math.min(Math.abs(r.pos-this.view.state.selection.from),Math.abs(r.pos-this.view.state.selection.to))<=2)?(Ii(this.view,Ze.near(this.view.state.doc.resolve(r.pos)),"pointer"),t.preventDefault()):Qo(this.view,"pointer")}move(t){this.updateAllowDefault(t),Qo(this.view,"pointer"),t.buttons==0&&this.done()}updateAllowDefault(t){!this.allowDefault&&(Math.abs(this.event.x-t.clientX)>4||Math.abs(this.event.y-t.clientY)>4)&&(this.allowDefault=!0)}}wn.touchstart=e=>{e.input.lastTouch=Date.now(),Zh(e),Qo(e,"pointer")};wn.touchmove=e=>{e.input.lastTouch=Date.now(),Qo(e,"pointer")};wn.contextmenu=e=>Zh(e);function Aw(e,t){return e.composing?!0:bn&&Math.abs(t.timeStamp-e.input.compositionEndedAt)<500?(e.input.compositionEndedAt=-2e8,!0):!1}const C4e=Er?5e3:-1;Nn.compositionstart=Nn.compositionupdate=e=>{if(!e.composing){e.domObserver.flush();let{state:t}=e,r=t.selection.$to;if(t.selection instanceof Ge&&(t.storedMarks||!r.textOffset&&r.parentOffset&&r.nodeBefore.marks.some(o=>o.type.spec.inclusive===!1)))e.markCursor=e.state.storedMarks||r.marks(),Lu(e,!0),e.markCursor=null;else if(Lu(e,!t.selection.empty),Or&&t.selection.empty&&r.parentOffset&&!r.textOffset&&r.nodeBefore.marks.length){let o=e.domSelectionRange();for(let a=o.focusNode,i=o.focusOffset;a&&a.nodeType==1&&i!=0;){let l=i<0?a.lastChild:a.childNodes[i-1];if(!l)break;if(l.nodeType==3){let s=e.domSelection();s&&s.collapse(l,l.nodeValue.length);break}else a=l,i=-1}}e.input.composing=!0}Ow(e,C4e)};Nn.compositionend=(e,t)=>{e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=t.timeStamp,e.input.compositionPendingChanges=e.domObserver.pendingRecords().length?e.input.compositionID:0,e.input.compositionNode=null,e.input.compositionPendingChanges&&Promise.resolve().then(()=>e.domObserver.flush()),e.input.compositionID++,Ow(e,20))};function Ow(e,t){clearTimeout(e.input.composingTimeout),t>-1&&(e.input.composingTimeout=setTimeout(()=>Lu(e),t))}function zw(e){for(e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=T4e());e.input.compositionNodes.length>0;)e.input.compositionNodes.pop().markParentsDirty()}function E4e(e){let t=e.domSelectionRange();if(!t.focusNode)return null;let r=yge(t.focusNode,t.focusOffset),o=Mge(t.focusNode,t.focusOffset);if(r&&o&&r!=o){let a=o.pmViewDesc,i=e.domObserver.lastChangedTextNode;if(r==i||o==i)return i;if(!a||!a.isText(o.nodeValue))return o;if(e.input.compositionNode==o){let l=r.pmViewDesc;if(!(!l||!l.isText(r.nodeValue)))return o}}return r||o}function T4e(){let e=document.createEvent("Event");return e.initEvent("event",!0,!0),e.timeStamp}function Lu(e,t=!1){if(!(Er&&e.domObserver.flushingSoon>=0)){if(e.domObserver.forceFlush(),zw(e),t||e.docView&&e.docView.dirty){let r=qh(e);return r&&!r.eq(e.state.selection)?e.dispatch(e.state.tr.setSelection(r)):(e.markCursor||t)&&!e.state.selection.empty?e.dispatch(e.state.tr.deleteSelection()):e.updateState(e.state),!0}return!1}}function D4e(e,t){if(!e.dom.parentNode)return;let r=e.dom.parentNode.appendChild(document.createElement("div"));r.appendChild(t),r.style.cssText="position: fixed; left: -10000px; top: 10px";let o=getSelection(),a=document.createRange();a.selectNodeContents(t),e.dom.blur(),o.removeAllRanges(),o.addRange(a),setTimeout(()=>{r.parentNode&&r.parentNode.removeChild(r),e.focus()},50)}const Es=An&&Ko<15||qi&&xge<604;wn.copy=Nn.cut=(e,t)=>{let r=t,o=e.state.selection,a=r.type=="cut";if(o.empty)return;let i=Es?null:r.clipboardData,l=o.content(),{dom:s,text:c}=xw(e,l);i?(r.preventDefault(),i.clearData(),i.setData("text/html",s.innerHTML),i.setData("text/plain",c)):D4e(e,s),a&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))};function S4e(e){return e.openStart==0&&e.openEnd==0&&e.content.childCount==1?e.content.firstChild:null}function _4e(e,t){if(!e.dom.parentNode)return;let r=e.input.shiftKey||e.state.selection.$from.parent.type.spec.code,o=e.dom.parentNode.appendChild(document.createElement(r?"textarea":"div"));r||(o.contentEditable="true"),o.style.cssText="position: fixed; left: -10000px; top: 10px",o.focus();let a=e.input.shiftKey&&e.input.lastKeyCode!=45;setTimeout(()=>{e.focus(),o.parentNode&&o.parentNode.removeChild(o),r?Ts(e,o.value,null,a,t):Ts(e,o.textContent,o.innerHTML,a,t)},50)}function Ts(e,t,r,o,a){let i=Cw(e,t,r,o,e.state.selection.$from);if(e.someProp("handlePaste",c=>c(e,a,i||Ee.empty)))return!0;if(!i)return!1;let l=S4e(i),s=l?e.state.tr.replaceSelectionWith(l,o):e.state.tr.replaceSelection(i);return e.dispatch(s.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste")),!0}function jw(e){let t=e.getData("text/plain")||e.getData("Text");if(t)return t;let r=e.getData("text/uri-list");return r?r.replace(/\r?\n/g," "):""}Nn.paste=(e,t)=>{let r=t;if(e.composing&&!Er)return;let o=Es?null:r.clipboardData,a=e.input.shiftKey&&e.input.lastKeyCode!=45;o&&Ts(e,jw(o),o.getData("text/html"),a,r)?r.preventDefault():_4e(e,r)};class Lw{constructor(t,r,o){this.slice=t,this.move=r,this.node=o}}const Bw=tr?"altKey":"ctrlKey";wn.dragstart=(e,t)=>{let r=t,o=e.input.mouseDown;if(o&&o.done(),!r.dataTransfer)return;let a=e.state.selection,i=a.empty?null:e.posAtCoords(cf(r)),l;if(!(i&&i.pos>=a.from&&i.pos<=(a instanceof Pe?a.to-1:a.to))){if(o&&o.mightDrag)l=Pe.create(e.state.doc,o.mightDrag.pos);else if(r.target&&r.target.nodeType==1){let f=e.docView.nearestDesc(r.target,!0);f&&f.node.type.spec.draggable&&f!=e.docView&&(l=Pe.create(e.state.doc,f.posBefore))}}let s=(l||e.state.selection).content(),{dom:c,text:u,slice:d}=xw(e,s);(!r.dataTransfer.files.length||!fn||sw>120)&&r.dataTransfer.clearData(),r.dataTransfer.setData(Es?"Text":"text/html",c.innerHTML),r.dataTransfer.effectAllowed="copyMove",Es||r.dataTransfer.setData("text/plain",u),e.dragging=new Lw(d,!r[Bw],l)};wn.dragend=e=>{let t=e.dragging;window.setTimeout(()=>{e.dragging==t&&(e.dragging=null)},50)};Nn.dragover=Nn.dragenter=(e,t)=>t.preventDefault();Nn.drop=(e,t)=>{let r=t,o=e.dragging;if(e.dragging=null,!r.dataTransfer)return;let a=e.posAtCoords(cf(r));if(!a)return;let i=e.state.doc.resolve(a.pos),l=o&&o.slice;l?e.someProp("transformPasted",m=>{l=m(l,e)}):l=Cw(e,jw(r.dataTransfer),Es?null:r.dataTransfer.getData("text/html"),!1,i);let s=!!(o&&!r[Bw]);if(e.someProp("handleDrop",m=>m(e,r,l||Ee.empty,s))){r.preventDefault();return}if(!l)return;r.preventDefault();let c=l?age(e.state.doc,i.pos,l):i.pos;c==null&&(c=i.pos);let u=e.state.tr;if(s){let{node:m}=o;m?m.replace(u):u.deleteSelection()}let d=u.mapping.map(c),f=l.openStart==0&&l.openEnd==0&&l.content.childCount==1,p=u.doc;if(f?u.replaceRangeWith(d,d,l.content.firstChild):u.replaceRange(d,d,l),u.doc.eq(p))return;let h=u.doc.resolve(d);if(f&&Pe.isSelectable(l.content.firstChild)&&h.nodeAfter&&h.nodeAfter.sameMarkup(l.content.firstChild))u.setSelection(new Pe(h));else{let m=u.mapping.map(c);u.mapping.maps[u.mapping.maps.length-1].forEach((g,v,y,N)=>m=N),u.setSelection(Gh(e,h,u.doc.resolve(m)))}e.focus(),e.dispatch(u.setMeta("uiEvent","drop"))};wn.focus=e=>{e.input.lastFocus=Date.now(),e.focused||(e.domObserver.stop(),e.dom.classList.add("ProseMirror-focused"),e.domObserver.start(),e.focused=!0,setTimeout(()=>{e.docView&&e.hasFocus()&&!e.domObserver.currentSelection.eq(e.domSelectionRange())&&yo(e)},20))};wn.blur=(e,t)=>{let r=t;e.focused&&(e.domObserver.stop(),e.dom.classList.remove("ProseMirror-focused"),e.domObserver.start(),r.relatedTarget&&e.dom.contains(r.relatedTarget)&&e.domObserver.currentSelection.clear(),e.focused=!1)};wn.beforeinput=(e,t)=>{if(fn&&Er&&t.inputType=="deleteContentBackward"){e.domObserver.flushSoon();let{domChangeCount:o}=e.input;setTimeout(()=>{if(e.input.domChangeCount!=o||(e.dom.blur(),e.focus(),e.someProp("handleKeyDown",i=>i(e,Ma(8,"Backspace")))))return;let{$cursor:a}=e.state.selection;a&&a.pos>0&&e.dispatch(e.state.tr.delete(a.pos-1,a.pos).scrollIntoView())},50)}};for(let e in Nn)wn[e]=Nn[e];function Ds(e,t){if(e==t)return!0;for(let r in e)if(e[r]!==t[r])return!1;for(let r in t)if(!(r in e))return!1;return!0}class Bu{constructor(t,r){this.toDOM=t,this.spec=r||Aa,this.side=this.spec.side||0}map(t,r,o,a){let{pos:i,deleted:l}=t.mapResult(r.from+a,this.side<0?-1:1);return l?null:new Un(i-o,i-o,this)}valid(){return!0}eq(t){return this==t||t instanceof Bu&&(this.spec.key&&this.spec.key==t.spec.key||this.toDOM==t.toDOM&&Ds(this.spec,t.spec))}destroy(t){this.spec.destroy&&this.spec.destroy(t)}}class Zo{constructor(t,r){this.attrs=t,this.spec=r||Aa}map(t,r,o,a){let i=t.map(r.from+a,this.spec.inclusiveStart?-1:1)-o,l=t.map(r.to+a,this.spec.inclusiveEnd?1:-1)-o;return i>=l?null:new Un(i,l,this)}valid(t,r){return r.from<r.to}eq(t){return this==t||t instanceof Zo&&Ds(this.attrs,t.attrs)&&Ds(this.spec,t.spec)}static is(t){return t.type instanceof Zo}destroy(){}}class Xh{constructor(t,r){this.attrs=t,this.spec=r||Aa}map(t,r,o,a){let i=t.mapResult(r.from+a,1);if(i.deleted)return null;let l=t.mapResult(r.to+a,-1);return l.deleted||l.pos<=i.pos?null:new Un(i.pos-o,l.pos-o,this)}valid(t,r){let{index:o,offset:a}=t.content.findIndex(r.from),i;return a==r.from&&!(i=t.child(o)).isText&&a+i.nodeSize==r.to}eq(t){return this==t||t instanceof Xh&&Ds(this.attrs,t.attrs)&&Ds(this.spec,t.spec)}destroy(){}}class Un{constructor(t,r,o){this.from=t,this.to=r,this.type=o}copy(t,r){return new Un(t,r,this.type)}eq(t,r=0){return this.type.eq(t.type)&&this.from+r==t.from&&this.to+r==t.to}map(t,r,o){return this.type.map(t,this,r,o)}static widget(t,r,o){return new Un(t,t,new Bu(r,o))}static inline(t,r,o,a){return new Un(t,r,new Zo(o,a))}static node(t,r,o,a){return new Un(t,r,new Xh(o,a))}get spec(){return this.type.spec}get inline(){return this.type instanceof Zo}get widget(){return this.type instanceof Bu}}const gi=[],Aa={};class It{constructor(t,r){this.local=t.length?t:gi,this.children=r.length?r:gi}static create(t,r){return r.length?Vu(r,t,0,Aa):dn}find(t,r,o){let a=[];return this.findInner(t??0,r??1e9,a,0,o),a}findInner(t,r,o,a,i){for(let l=0;l<this.local.length;l++){let s=this.local[l];s.from<=r&&s.to>=t&&(!i||i(s.spec))&&o.push(s.copy(s.from+a,s.to+a))}for(let l=0;l<this.children.length;l+=3)if(this.children[l]<r&&this.children[l+1]>t){let s=this.children[l]+1;this.children[l+2].findInner(t-s,r-s,o,a+s,i)}}map(t,r,o){return this==dn||t.maps.length==0?this:this.mapInner(t,r,0,0,o||Aa)}mapInner(t,r,o,a,i){let l;for(let s=0;s<this.local.length;s++){let c=this.local[s].map(t,o,a);c&&c.type.valid(r,c)?(l||(l=[])).push(c):i.onRemove&&i.onRemove(this.local[s].spec)}return this.children.length?I4e(this.children,l||[],t,r,o,a,i):l?new It(l.sort(Oa),gi):dn}add(t,r){return r.length?this==dn?It.create(t,r):this.addInner(t,r,0):this}addInner(t,r,o){let a,i=0;t.forEach((s,c)=>{let u=c+o,d;if(d=$w(r,s,u)){for(a||(a=this.children.slice());i<a.length&&a[i]<c;)i+=3;a[i]==c?a[i+2]=a[i+2].addInner(s,d,u+1):a.splice(i,0,c,c+s.nodeSize,Vu(d,s,u+1,Aa)),i+=3}});let l=Vw(i?Pw(r):r,-o);for(let s=0;s<l.length;s++)l[s].type.valid(t,l[s])||l.splice(s--,1);return new It(l.length?this.local.concat(l).sort(Oa):this.local,a||this.children)}remove(t){return t.length==0||this==dn?this:this.removeInner(t,0)}removeInner(t,r){let o=this.children,a=this.local;for(let i=0;i<o.length;i+=3){let l,s=o[i]+r,c=o[i+1]+r;for(let d=0,f;d<t.length;d++)(f=t[d])&&f.from>s&&f.to<c&&(t[d]=null,(l||(l=[])).push(f));if(!l)continue;o==this.children&&(o=this.children.slice());let u=o[i+2].removeInner(l,s+1);u!=dn?o[i+2]=u:(o.splice(i,3),i-=3)}if(a.length){for(let i=0,l;i<t.length;i++)if(l=t[i])for(let s=0;s<a.length;s++)a[s].eq(l,r)&&(a==this.local&&(a=this.local.slice()),a.splice(s--,1))}return o==this.children&&a==this.local?this:a.length||o.length?new It(a,o):dn}forChild(t,r){if(this==dn)return this;if(r.isLeaf)return It.empty;let o,a;for(let s=0;s<this.children.length;s+=3)if(this.children[s]>=t){this.children[s]==t&&(o=this.children[s+2]);break}let i=t+1,l=i+r.content.size;for(let s=0;s<this.local.length;s++){let c=this.local[s];if(c.from<l&&c.to>i&&c.type instanceof Zo){let u=Math.max(i,c.from)-i,d=Math.min(l,c.to)-i;u<d&&(a||(a=[])).push(c.copy(u,d))}}if(a){let s=new It(a.sort(Oa),gi);return o?new Po([s,o]):s}return o||dn}eq(t){if(this==t)return!0;if(!(t instanceof It)||this.local.length!=t.local.length||this.children.length!=t.children.length)return!1;for(let r=0;r<this.local.length;r++)if(!this.local[r].eq(t.local[r]))return!1;for(let r=0;r<this.children.length;r+=3)if(this.children[r]!=t.children[r]||this.children[r+1]!=t.children[r+1]||!this.children[r+2].eq(t.children[r+2]))return!1;return!0}locals(t){return e2(this.localsInner(t))}localsInner(t){if(this==dn)return gi;if(t.inlineContent||!this.local.some(Zo.is))return this.local;let r=[];for(let o=0;o<this.local.length;o++)this.local[o].type instanceof Zo||r.push(this.local[o]);return r}forEachSet(t){t(this)}}It.empty=new It([],[]);It.removeOverlap=e2;const dn=It.empty;class Po{constructor(t){this.members=t}map(t,r){const o=this.members.map(a=>a.map(t,r,Aa));return Po.from(o)}forChild(t,r){if(r.isLeaf)return It.empty;let o=[];for(let a=0;a<this.members.length;a++){let i=this.members[a].forChild(t,r);i!=dn&&(i instanceof Po?o=o.concat(i.members):o.push(i))}return Po.from(o)}eq(t){if(!(t instanceof Po)||t.members.length!=this.members.length)return!1;for(let r=0;r<this.members.length;r++)if(!this.members[r].eq(t.members[r]))return!1;return!0}locals(t){let r,o=!0;for(let a=0;a<this.members.length;a++){let i=this.members[a].localsInner(t);if(i.length)if(!r)r=i;else{o&&(r=r.slice(),o=!1);for(let l=0;l<i.length;l++)r.push(i[l])}}return r?e2(o?r:r.sort(Oa)):gi}static from(t){switch(t.length){case 0:return dn;case 1:return t[0];default:return new Po(t.every(r=>r instanceof It)?t:t.reduce((r,o)=>r.concat(o instanceof It?o:o.members),[]))}}forEachSet(t){for(let r=0;r<this.members.length;r++)this.members[r].forEachSet(t)}}function I4e(e,t,r,o,a,i,l){let s=e.slice();for(let u=0,d=i;u<r.maps.length;u++){let f=0;r.maps[u].forEach((p,h,m,g)=>{let v=g-m-(h-p);for(let y=0;y<s.length;y+=3){let N=s[y+1];if(N<0||p>N+d-f)continue;let b=s[y]+d-f;h>=b?s[y+1]=p<=b?-2:-1:p>=d&&v&&(s[y]+=v,s[y+1]+=v)}f+=v}),d=r.maps[u].map(d,-1)}let c=!1;for(let u=0;u<s.length;u+=3)if(s[u+1]<0){if(s[u+1]==-2){c=!0,s[u+1]=-1;continue}let d=r.map(e[u]+i),f=d-a;if(f<0||f>=o.content.size){c=!0;continue}let p=r.map(e[u+1]+i,-1),h=p-a,{index:m,offset:g}=o.content.findIndex(f),v=o.maybeChild(m);if(v&&g==f&&g+v.nodeSize==h){let y=s[u+2].mapInner(r,v,d+1,e[u]+i+1,l);y!=dn?(s[u]=f,s[u+1]=h,s[u+2]=y):(s[u+1]=-2,c=!0)}else c=!0}if(c){let u=A4e(s,e,t,r,a,i,l),d=Vu(u,o,0,l);t=d.local;for(let f=0;f<s.length;f+=3)s[f+1]<0&&(s.splice(f,3),f-=3);for(let f=0,p=0;f<d.children.length;f+=3){let h=d.children[f];for(;p<s.length&&s[p]<h;)p+=3;s.splice(p,0,d.children[f],d.children[f+1],d.children[f+2])}}return new It(t.sort(Oa),s)}function Vw(e,t){if(!t||!e.length)return e;let r=[];for(let o=0;o<e.length;o++){let a=e[o];r.push(new Un(a.from+t,a.to+t,a.type))}return r}function A4e(e,t,r,o,a,i,l){function s(c,u){for(let d=0;d<c.local.length;d++){let f=c.local[d].map(o,a,u);f?r.push(f):l.onRemove&&l.onRemove(c.local[d].spec)}for(let d=0;d<c.children.length;d+=3)s(c.children[d+2],c.children[d]+u+1)}for(let c=0;c<e.length;c+=3)e[c+1]==-1&&s(e[c+2],t[c]+i+1);return r}function $w(e,t,r){if(t.isLeaf)return null;let o=r+t.nodeSize,a=null;for(let i=0,l;i<e.length;i++)(l=e[i])&&l.from>r&&l.to<o&&((a||(a=[])).push(l),e[i]=null);return a}function Pw(e){let t=[];for(let r=0;r<e.length;r++)e[r]!=null&&t.push(e[r]);return t}function Vu(e,t,r,o){let a=[],i=!1;t.forEach((s,c)=>{let u=$w(e,s,c+r);if(u){i=!0;let d=Vu(u,s,r+c+1,o);d!=dn&&a.push(c,c+s.nodeSize,d)}});let l=Vw(i?Pw(e):e,-r).sort(Oa);for(let s=0;s<l.length;s++)l[s].type.valid(t,l[s])||(o.onRemove&&o.onRemove(l[s].spec),l.splice(s--,1));return l.length||a.length?new It(l,a):dn}function Oa(e,t){return e.from-t.from||e.to-t.to}function e2(e){let t=e;for(let r=0;r<t.length-1;r++){let o=t[r];if(o.from!=o.to)for(let a=r+1;a<t.length;a++){let i=t[a];if(i.from==o.from){i.to!=o.to&&(t==e&&(t=e.slice()),t[a]=i.copy(i.from,o.to),wv(t,a+1,i.copy(o.to,i.to)));continue}else{i.from<o.to&&(t==e&&(t=e.slice()),t[r]=o.copy(o.from,i.from),wv(t,a,o.copy(i.from,o.to)));break}}}return t}function wv(e,t,r){for(;t<e.length&&Oa(r,e[t])>0;)t++;e.splice(t,0,r)}function op(e){let t=[];return e.someProp("decorations",r=>{let o=r(e.state);o&&o!=dn&&t.push(o)}),e.cursorWrapper&&t.push(It.create(e.state.doc,[e.cursorWrapper.deco])),Po.from(t)}const O4e={childList:!0,characterData:!0,characterDataOldValue:!0,attributes:!0,attributeOldValue:!0,subtree:!0},z4e=An&&Ko<=11;class j4e{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}set(t){this.anchorNode=t.anchorNode,this.anchorOffset=t.anchorOffset,this.focusNode=t.focusNode,this.focusOffset=t.focusOffset}clear(){this.anchorNode=this.focusNode=null}eq(t){return t.anchorNode==this.anchorNode&&t.anchorOffset==this.anchorOffset&&t.focusNode==this.focusNode&&t.focusOffset==this.focusOffset}}class L4e{constructor(t,r){this.view=t,this.handleDOMChange=r,this.queue=[],this.flushingSoon=-1,this.observer=null,this.currentSelection=new j4e,this.onCharData=null,this.suppressingSelectionUpdates=!1,this.lastChangedTextNode=null,this.observer=window.MutationObserver&&new window.MutationObserver(o=>{for(let a=0;a<o.length;a++)this.queue.push(o[a]);An&&Ko<=11&&o.some(a=>a.type=="childList"&&a.removedNodes.length||a.type=="characterData"&&a.oldValue.length>a.target.nodeValue.length)?this.flushSoon():this.flush()}),z4e&&(this.onCharData=o=>{this.queue.push({target:o.target,type:"characterData",oldValue:o.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this)}flushSoon(){this.flushingSoon<0&&(this.flushingSoon=window.setTimeout(()=>{this.flushingSoon=-1,this.flush()},20))}forceFlush(){this.flushingSoon>-1&&(window.clearTimeout(this.flushingSoon),this.flushingSoon=-1,this.flush())}start(){this.observer&&(this.observer.takeRecords(),this.observer.observe(this.view.dom,O4e)),this.onCharData&&this.view.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.connectSelection()}stop(){if(this.observer){let t=this.observer.takeRecords();if(t.length){for(let r=0;r<t.length;r++)this.queue.push(t[r]);window.setTimeout(()=>this.flush(),20)}this.observer.disconnect()}this.onCharData&&this.view.dom.removeEventListener("DOMCharacterDataModified",this.onCharData),this.disconnectSelection()}connectSelection(){this.view.dom.ownerDocument.addEventListener("selectionchange",this.onSelectionChange)}disconnectSelection(){this.view.dom.ownerDocument.removeEventListener("selectionchange",this.onSelectionChange)}suppressSelectionUpdates(){this.suppressingSelectionUpdates=!0,setTimeout(()=>this.suppressingSelectionUpdates=!1,50)}onSelectionChange(){if(pv(this.view)){if(this.suppressingSelectionUpdates)return yo(this.view);if(An&&Ko<=11&&!this.view.state.selection.empty){let t=this.view.domSelectionRange();if(t.focusNode&&Ra(t.focusNode,t.focusOffset,t.anchorNode,t.anchorOffset))return this.flushSoon()}this.flush()}}setCurSelection(){this.currentSelection.set(this.view.domSelectionRange())}ignoreSelectionChange(t){if(!t.focusNode)return!0;let r=new Set,o;for(let i=t.focusNode;i;i=Cs(i))r.add(i);for(let i=t.anchorNode;i;i=Cs(i))if(r.has(i)){o=i;break}let a=o&&this.view.docView.nearestDesc(o);if(a&&a.ignoreMutation({type:"selection",target:o.nodeType==3?o.parentNode:o}))return this.setCurSelection(),!0}pendingRecords(){if(this.observer)for(let t of this.observer.takeRecords())this.queue.push(t);return this.queue}flush(){let{view:t}=this;if(!t.docView||this.flushingSoon>-1)return;let r=this.pendingRecords();r.length&&(this.queue=[]);let o=t.domSelectionRange(),a=!this.suppressingSelectionUpdates&&!this.currentSelection.eq(o)&&pv(t)&&!this.ignoreSelectionChange(o),i=-1,l=-1,s=!1,c=[];if(t.editable)for(let d=0;d<r.length;d++){let f=this.registerMutation(r[d],c);f&&(i=i<0?f.from:Math.min(f.from,i),l=l<0?f.to:Math.max(f.to,l),f.typeOver&&(s=!0))}if(Or&&c.length){let d=c.filter(f=>f.nodeName=="BR");if(d.length==2){let[f,p]=d;f.parentNode&&f.parentNode.parentNode==p.parentNode?p.remove():f.remove()}else{let{focusNode:f}=this.currentSelection;for(let p of d){let h=p.parentNode;h&&h.nodeName=="LI"&&(!f||$4e(t,f)!=h)&&p.remove()}}}let u=null;i<0&&a&&t.input.lastFocus>Date.now()-200&&Math.max(t.input.lastTouch,t.input.lastClick.time)<Date.now()-300&&lf(o)&&(u=qh(t))&&u.eq(Ze.near(t.state.doc.resolve(0),1))?(t.input.lastFocus=0,yo(t),this.currentSelection.set(o),t.scrollToSelection()):(i>-1||a)&&(i>-1&&(t.docView.markDirty(i,l),B4e(t)),this.handleDOMChange(i,l,s,c),t.docView&&t.docView.dirty?t.updateState(t.state):this.currentSelection.eq(o)||yo(t),this.currentSelection.set(o))}registerMutation(t,r){if(r.indexOf(t.target)>-1)return null;let o=this.view.docView.nearestDesc(t.target);if(t.type=="attributes"&&(o==this.view.docView||t.attributeName=="contenteditable"||t.attributeName=="style"&&!t.oldValue&&!t.target.getAttribute("style"))||!o||o.ignoreMutation(t))return null;if(t.type=="childList"){for(let d=0;d<t.addedNodes.length;d++){let f=t.addedNodes[d];r.push(f),f.nodeType==3&&(this.lastChangedTextNode=f)}if(o.contentDOM&&o.contentDOM!=o.dom&&!o.contentDOM.contains(t.target))return{from:o.posBefore,to:o.posAfter};let a=t.previousSibling,i=t.nextSibling;if(An&&Ko<=11&&t.addedNodes.length)for(let d=0;d<t.addedNodes.length;d++){let{previousSibling:f,nextSibling:p}=t.addedNodes[d];(!f||Array.prototype.indexOf.call(t.addedNodes,f)<0)&&(a=f),(!p||Array.prototype.indexOf.call(t.addedNodes,p)<0)&&(i=p)}let l=a&&a.parentNode==t.target?rn(a)+1:0,s=o.localPosFromDOM(t.target,l,-1),c=i&&i.parentNode==t.target?rn(i):t.target.childNodes.length,u=o.localPosFromDOM(t.target,c,1);return{from:s,to:u}}else return t.type=="attributes"?{from:o.posAtStart-o.border,to:o.posAtEnd+o.border}:(this.lastChangedTextNode=t.target,{from:o.posAtStart,to:o.posAtEnd,typeOver:t.target.nodeValue==t.oldValue})}}let Nv=new WeakMap,kv=!1;function B4e(e){if(!Nv.has(e)&&(Nv.set(e,null),["normal","nowrap","pre-line"].indexOf(getComputedStyle(e.dom).whiteSpace)!==-1)){if(e.requiresGeckoHackNode=Or,kv)return;console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package."),kv=!0}}function xv(e,t){let r=t.startContainer,o=t.startOffset,a=t.endContainer,i=t.endOffset,l=e.domAtPos(e.state.selection.anchor);return Ra(l.node,l.offset,a,i)&&([r,o,a,i]=[a,i,r,o]),{anchorNode:r,anchorOffset:o,focusNode:a,focusOffset:i}}function V4e(e,t){if(t.getComposedRanges){let a=t.getComposedRanges(e.root)[0];if(a)return xv(e,a)}let r;function o(a){a.preventDefault(),a.stopImmediatePropagation(),r=a.getTargetRanges()[0]}return e.dom.addEventListener("beforeinput",o,!0),document.execCommand("indent"),e.dom.removeEventListener("beforeinput",o,!0),r?xv(e,r):null}function $4e(e,t){for(let r=t.parentNode;r&&r!=e.dom;r=r.parentNode){let o=e.docView.nearestDesc(r,!0);if(o&&o.node.isBlock)return r}return null}function P4e(e,t,r){let{node:o,fromOffset:a,toOffset:i,from:l,to:s}=e.docView.parseRange(t,r),c=e.domSelectionRange(),u,d=c.anchorNode;if(d&&e.dom.contains(d.nodeType==1?d:d.parentNode)&&(u=[{node:d,offset:c.anchorOffset}],lf(c)||u.push({node:c.focusNode,offset:c.focusOffset})),fn&&e.input.lastKeyCode===8)for(let v=i;v>a;v--){let y=o.childNodes[v-1],N=y.pmViewDesc;if(y.nodeName=="BR"&&!N){i=v;break}if(!N||N.size)break}let f=e.state.doc,p=e.someProp("domParser")||Go.fromSchema(e.state.schema),h=f.resolve(l),m=null,g=p.parse(o,{topNode:h.parent,topMatch:h.parent.contentMatchAt(h.index()),topOpen:!0,from:a,to:i,preserveWhitespace:h.parent.type.whitespace=="pre"?"full":!0,findPositions:u,ruleFromNode:R4e,context:h});if(u&&u[0].pos!=null){let v=u[0].pos,y=u[1]&&u[1].pos;y==null&&(y=v),m={anchor:v+l,head:y+l}}return{doc:g,sel:m,from:l,to:s}}function R4e(e){let t=e.pmViewDesc;if(t)return t.parseRule();if(e.nodeName=="BR"&&e.parentNode){if(bn&&/^(ul|ol)$/i.test(e.parentNode.nodeName)){let r=document.createElement("div");return r.appendChild(document.createElement("li")),{skip:r}}else if(e.parentNode.lastChild==e||bn&&/^(tr|table)$/i.test(e.parentNode.nodeName))return{ignore:!0}}else if(e.nodeName=="IMG"&&e.getAttribute("mark-placeholder"))return{ignore:!0};return null}const F4e=/^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;function U4e(e,t,r,o,a){let i=e.input.compositionPendingChanges||(e.composing?e.input.compositionID:0);if(e.input.compositionPendingChanges=0,t<0){let A=e.input.lastSelectionTime>Date.now()-50?e.input.lastSelectionOrigin:null,O=qh(e,A);if(O&&!e.state.selection.eq(O)){if(fn&&Er&&e.input.lastKeyCode===13&&Date.now()-100<e.input.lastKeyCodeTime&&e.someProp("handleKeyDown",j=>j(e,Ma(13,"Enter"))))return;let _=e.state.tr.setSelection(O);A=="pointer"?_.setMeta("pointer",!0):A=="key"&&_.scrollIntoView(),i&&_.setMeta("composition",i),e.dispatch(_)}return}let l=e.state.doc.resolve(t),s=l.sharedDepth(r);t=l.before(s+1),r=e.state.doc.resolve(r).after(s+1);let c=e.state.selection,u=P4e(e,t,r),d=e.state.doc,f=d.slice(u.from,u.to),p,h;e.input.lastKeyCode===8&&Date.now()-100<e.input.lastKeyCodeTime?(p=e.state.selection.to,h="end"):(p=e.state.selection.from,h="start"),e.input.lastKeyCode=null;let m=Q4e(f.content,u.doc.content,u.from,p,h);if(m&&e.input.domChangeCount++,(qi&&e.input.lastIOSEnter>Date.now()-225||Er)&&a.some(A=>A.nodeType==1&&!F4e.test(A.nodeName))&&(!m||m.endA>=m.endB)&&e.someProp("handleKeyDown",A=>A(e,Ma(13,"Enter")))){e.input.lastIOSEnter=0;return}if(!m)if(o&&c instanceof Ge&&!c.empty&&c.$head.sameParent(c.$anchor)&&!e.composing&&!(u.sel&&u.sel.anchor!=u.sel.head))m={start:c.from,endA:c.to,endB:c.to};else{if(u.sel){let A=Cv(e,e.state.doc,u.sel);if(A&&!A.eq(e.state.selection)){let O=e.state.tr.setSelection(A);i&&O.setMeta("composition",i),e.dispatch(O)}}return}e.state.selection.from<e.state.selection.to&&m.start==m.endB&&e.state.selection instanceof Ge&&(m.start>e.state.selection.from&&m.start<=e.state.selection.from+2&&e.state.selection.from>=u.from?m.start=e.state.selection.from:m.endA<e.state.selection.to&&m.endA>=e.state.selection.to-2&&e.state.selection.to<=u.to&&(m.endB+=e.state.selection.to-m.endA,m.endA=e.state.selection.to)),An&&Ko<=11&&m.endB==m.start+1&&m.endA==m.start&&m.start>u.from&&u.doc.textBetween(m.start-u.from-1,m.start-u.from+1)==" "&&(m.start--,m.endA--,m.endB--);let g=u.doc.resolveNoCache(m.start-u.from),v=u.doc.resolveNoCache(m.endB-u.from),y=d.resolve(m.start),N=g.sameParent(v)&&g.parent.inlineContent&&y.end()>=m.endA,b;if((qi&&e.input.lastIOSEnter>Date.now()-225&&(!N||a.some(A=>A.nodeName=="DIV"||A.nodeName=="P"))||!N&&g.pos<u.doc.content.size&&!g.sameParent(v)&&(b=Ze.findFrom(u.doc.resolve(g.pos+1),1,!0))&&b.head==v.pos)&&e.someProp("handleKeyDown",A=>A(e,Ma(13,"Enter")))){e.input.lastIOSEnter=0;return}if(e.state.selection.anchor>m.start&&Y4e(d,m.start,m.endA,g,v)&&e.someProp("handleKeyDown",A=>A(e,Ma(8,"Backspace")))){Er&&fn&&e.domObserver.suppressSelectionUpdates();return}fn&&Er&&m.endB==m.start&&(e.input.lastAndroidDelete=Date.now()),Er&&!N&&g.start()!=v.start()&&v.parentOffset==0&&g.depth==v.depth&&u.sel&&u.sel.anchor==u.sel.head&&u.sel.head==m.endA&&(m.endB-=2,v=u.doc.resolveNoCache(m.endB-u.from),setTimeout(()=>{e.someProp("handleKeyDown",function(A){return A(e,Ma(13,"Enter"))})},20));let M=m.start,k=m.endA,w,C,E;if(N){if(g.pos==v.pos)An&&Ko<=11&&g.parentOffset==0&&(e.domObserver.suppressSelectionUpdates(),setTimeout(()=>yo(e),20)),w=e.state.tr.delete(M,k),C=d.resolve(m.start).marksAcross(d.resolve(m.endA));else if(m.endA==m.endB&&(E=H4e(g.parent.content.cut(g.parentOffset,v.parentOffset),y.parent.content.cut(y.parentOffset,m.endA-y.start()))))w=e.state.tr,E.type=="add"?w.addMark(M,k,E.mark):w.removeMark(M,k,E.mark);else if(g.parent.child(g.index()).isText&&g.index()==v.index()-(v.textOffset?0:1)){let A=g.parent.textBetween(g.parentOffset,v.parentOffset);if(e.someProp("handleTextInput",O=>O(e,M,k,A)))return;w=e.state.tr.insertText(A,M,k)}}if(w||(w=e.state.tr.replace(M,k,u.doc.slice(m.start-u.from,m.endB-u.from))),u.sel){let A=Cv(e,w.doc,u.sel);A&&!(fn&&Er&&e.composing&&A.empty&&(m.start!=m.endB||e.input.lastAndroidDelete<Date.now()-100)&&(A.head==M||A.head==w.mapping.map(k)-1)||An&&A.empty&&A.head==M)&&w.setSelection(A)}C&&w.ensureMarks(C),i&&w.setMeta("composition",i),e.dispatch(w.scrollIntoView())}function Cv(e,t,r){return Math.max(r.anchor,r.head)>t.content.size?null:Gh(e,t.resolve(r.anchor),t.resolve(r.head))}function H4e(e,t){let r=e.firstChild.marks,o=t.firstChild.marks,a=r,i=o,l,s,c;for(let d=0;d<o.length;d++)a=o[d].removeFromSet(a);for(let d=0;d<r.length;d++)i=r[d].removeFromSet(i);if(a.length==1&&i.length==0)s=a[0],l="add",c=d=>d.mark(s.addToSet(d.marks));else if(a.length==0&&i.length==1)s=i[0],l="remove",c=d=>d.mark(s.removeFromSet(d.marks));else return null;let u=[];for(let d=0;d<t.childCount;d++)u.push(c(t.child(d)));if(fe.from(u).eq(e))return{mark:s,type:l}}function Y4e(e,t,r,o,a){if(r-t<=a.pos-o.pos||ap(o,!0,!1)<a.pos)return!1;let i=e.resolve(t);if(!o.parent.isTextblock){let s=i.nodeAfter;return s!=null&&r==t+s.nodeSize}if(i.parentOffset<i.parent.content.size||!i.parent.isTextblock)return!1;let l=e.resolve(ap(i,!0,!0));return!l.parent.isTextblock||l.pos>r||ap(l,!0,!1)<r?!1:o.parent.content.cut(o.parentOffset).eq(l.parent.content)}function ap(e,t,r){let o=e.depth,a=t?e.end():e.pos;for(;o>0&&(t||e.indexAfter(o)==e.node(o).childCount);)o--,a++,t=!1;if(r){let i=e.node(o).maybeChild(e.indexAfter(o));for(;i&&!i.isLeaf;)i=i.firstChild,a++}return a}function Q4e(e,t,r,o,a){let i=e.findDiffStart(t,r);if(i==null)return null;let{a:l,b:s}=e.findDiffEnd(t,r+e.size,r+t.size);if(a=="end"){let c=Math.max(0,i-Math.min(l,s));o-=l+c-i}if(l<i&&e.size<t.size){let c=o<=i&&o>=l?i-o:0;i-=c,i&&i<t.size&&Ev(t.textBetween(i-1,i+1))&&(i+=c?1:-1),s=i+(s-l),l=i}else if(s<i){let c=o<=i&&o>=s?i-o:0;i-=c,i&&i<e.size&&Ev(e.textBetween(i-1,i+1))&&(i+=c?1:-1),l=i+(l-s),s=i}return{start:i,endA:l,endB:s}}function Ev(e){if(e.length!=2)return!1;let t=e.charCodeAt(0),r=e.charCodeAt(1);return t>=56320&&t<=57343&&r>=55296&&r<=56319}class W4e{constructor(t,r){this._root=null,this.focused=!1,this.trackWrites=null,this.mounted=!1,this.markCursor=null,this.cursorWrapper=null,this.lastSelectedViewDesc=void 0,this.input=new f4e,this.prevDirectPlugins=[],this.pluginViews=[],this.requiresGeckoHackNode=!1,this.dragging=null,this._props=r,this.state=r.state,this.directPlugins=r.plugins||[],this.directPlugins.forEach(Iv),this.dispatch=this.dispatch.bind(this),this.dom=t&&t.mount||document.createElement("div"),t&&(t.appendChild?t.appendChild(this.dom):typeof t=="function"?t(this.dom):t.mount&&(this.mounted=!0)),this.editable=Sv(this),Dv(this),this.nodeViews=_v(this),this.docView=lv(this.state.doc,Tv(this),op(this),this.dom,this),this.domObserver=new L4e(this,(o,a,i,l)=>U4e(this,o,a,i,l)),this.domObserver.start(),p4e(this),this.updatePluginViews()}get composing(){return this.input.composing}get props(){if(this._props.state!=this.state){let t=this._props;this._props={};for(let r in t)this._props[r]=t[r];this._props.state=this.state}return this._props}update(t){t.handleDOMEvents!=this._props.handleDOMEvents&&j0(this);let r=this._props;this._props=t,t.plugins&&(t.plugins.forEach(Iv),this.directPlugins=t.plugins),this.updateStateInner(t.state,r)}setProps(t){let r={};for(let o in this._props)r[o]=this._props[o];r.state=this.state;for(let o in t)r[o]=t[o];this.update(r)}updateState(t){this.updateStateInner(t,this._props)}updateStateInner(t,r){var o;let a=this.state,i=!1,l=!1;t.storedMarks&&this.composing&&(zw(this),l=!0),this.state=t;let s=a.plugins!=t.plugins||this._props.plugins!=r.plugins;if(s||this._props.plugins!=r.plugins||this._props.nodeViews!=r.nodeViews){let h=_v(this);G4e(h,this.nodeViews)&&(this.nodeViews=h,i=!0)}(s||r.handleDOMEvents!=this._props.handleDOMEvents)&&j0(this),this.editable=Sv(this),Dv(this);let c=op(this),u=Tv(this),d=a.plugins!=t.plugins&&!a.doc.eq(t.doc)?"reset":t.scrollToSelection>a.scrollToSelection?"to selection":"preserve",f=i||!this.docView.matchesNode(t.doc,u,c);(f||!t.selection.eq(a.selection))&&(l=!0);let p=d=="preserve"&&l&&this.dom.style.overflowAnchor==null&&Tge(this);if(l){this.domObserver.stop();let h=f&&(An||fn)&&!this.composing&&!a.selection.empty&&!t.selection.empty&&q4e(a.selection,t.selection);if(f){let m=fn?this.trackWrites=this.domSelectionRange().focusNode:null;this.composing&&(this.input.compositionNode=E4e(this)),(i||!this.docView.update(t.doc,u,c,this))&&(this.docView.updateOuterDeco(u),this.docView.destroy(),this.docView=lv(t.doc,u,c,this.dom,this)),m&&!this.trackWrites&&(h=!0)}h||!(this.input.mouseDown&&this.domObserver.currentSelection.eq(this.domSelectionRange())&&Jge(this))?yo(this,h):(ww(this,t.selection),this.domObserver.setCurSelection()),this.domObserver.start()}this.updatePluginViews(a),!((o=this.dragging)===null||o===void 0)&&o.node&&!a.doc.eq(t.doc)&&this.updateDraggedNode(this.dragging,a),d=="reset"?this.dom.scrollTop=0:d=="to selection"?this.scrollToSelection():p&&Dge(p)}scrollToSelection(){let t=this.domSelectionRange().focusNode;if(!this.someProp("handleScrollToSelection",r=>r(this)))if(this.state.selection instanceof Pe){let r=this.docView.domAfterPos(this.state.selection.from);r.nodeType==1&&tv(this,r.getBoundingClientRect(),t)}else tv(this,this.coordsAtPos(this.state.selection.head,1),t)}destroyPluginViews(){let t;for(;t=this.pluginViews.pop();)t.destroy&&t.destroy()}updatePluginViews(t){if(!t||t.plugins!=this.state.plugins||this.directPlugins!=this.prevDirectPlugins){this.prevDirectPlugins=this.directPlugins,this.destroyPluginViews();for(let r=0;r<this.directPlugins.length;r++){let o=this.directPlugins[r];o.spec.view&&this.pluginViews.push(o.spec.view(this))}for(let r=0;r<this.state.plugins.length;r++){let o=this.state.plugins[r];o.spec.view&&this.pluginViews.push(o.spec.view(this))}}else for(let r=0;r<this.pluginViews.length;r++){let o=this.pluginViews[r];o.update&&o.update(this,t)}}updateDraggedNode(t,r){let o=t.node,a=-1;if(this.state.doc.nodeAt(o.from)==o.node)a=o.from;else{let i=o.from+(this.state.doc.content.size-r.doc.content.size);(i>0&&this.state.doc.nodeAt(i))==o.node&&(a=i)}this.dragging=new Lw(t.slice,t.move,a<0?void 0:Pe.create(this.state.doc,a))}someProp(t,r){let o=this._props&&this._props[t],a;if(o!=null&&(a=r?r(o):o))return a;for(let l=0;l<this.directPlugins.length;l++){let s=this.directPlugins[l].props[t];if(s!=null&&(a=r?r(s):s))return a}let i=this.state.plugins;if(i)for(let l=0;l<i.length;l++){let s=i[l].props[t];if(s!=null&&(a=r?r(s):s))return a}}hasFocus(){if(An){let t=this.root.activeElement;if(t==this.dom)return!0;if(!t||!this.dom.contains(t))return!1;for(;t&&this.dom!=t&&this.dom.contains(t);){if(t.contentEditable=="false")return!1;t=t.parentElement}return!0}return this.root.activeElement==this.dom}focus(){this.domObserver.stop(),this.editable&&Sge(this.dom),yo(this),this.domObserver.start()}get root(){let t=this._root;if(t==null){for(let r=this.dom.parentNode;r;r=r.parentNode)if(r.nodeType==9||r.nodeType==11&&r.host)return r.getSelection||(Object.getPrototypeOf(r).getSelection=()=>r.ownerDocument.getSelection()),this._root=r}return t||document}updateRoot(){this._root=null}posAtCoords(t){return zge(this,t)}coordsAtPos(t,r=1){return pw(this,t,r)}domAtPos(t,r=0){return this.docView.domFromPos(t,r)}nodeDOM(t){let r=this.docView.descAt(t);return r?r.nodeDOM:null}posAtDOM(t,r,o=-1){let a=this.docView.posFromDOM(t,r,o);if(a==null)throw new RangeError("DOM position not inside the editor");return a}endOfTextblock(t,r){return $ge(this,r||this.state,t)}pasteHTML(t,r){return Ts(this,"",t,!1,r||new ClipboardEvent("paste"))}pasteText(t,r){return Ts(this,t,null,!0,r||new ClipboardEvent("paste"))}destroy(){this.docView&&(m4e(this),this.destroyPluginViews(),this.mounted?(this.docView.update(this.state.doc,[],op(this),this),this.dom.textContent=""):this.dom.parentNode&&this.dom.parentNode.removeChild(this.dom),this.docView.destroy(),this.docView=null,gge())}get isDestroyed(){return this.docView==null}dispatchEvent(t){return g4e(this,t)}dispatch(t){let r=this._props.dispatchTransaction;r?r.call(this,t):this.updateState(this.state.apply(t))}domSelectionRange(){let t=this.domSelection();return t?bn&&this.root.nodeType===11&&wge(this.dom.ownerDocument)==this.dom&&V4e(this,t)||t:{focusNode:null,focusOffset:0,anchorNode:null,anchorOffset:0}}domSelection(){return this.root.getSelection()}}function Tv(e){let t=Object.create(null);return t.class="ProseMirror",t.contenteditable=String(e.editable),e.someProp("attributes",r=>{if(typeof r=="function"&&(r=r(e.state)),r)for(let o in r)o=="class"?t.class+=" "+r[o]:o=="style"?t.style=(t.style?t.style+";":"")+r[o]:!t[o]&&o!="contenteditable"&&o!="nodeName"&&(t[o]=String(r[o]))}),t.translate||(t.translate="no"),[Un.node(0,e.state.doc.content.size,t)]}function Dv(e){if(e.markCursor){let t=document.createElement("img");t.className="ProseMirror-separator",t.setAttribute("mark-placeholder","true"),t.setAttribute("alt",""),e.cursorWrapper={dom:t,deco:Un.widget(e.state.selection.from,t,{raw:!0,marks:e.markCursor})}}else e.cursorWrapper=null}function Sv(e){return!e.someProp("editable",t=>t(e.state)===!1)}function q4e(e,t){let r=Math.min(e.$anchor.sharedDepth(e.head),t.$anchor.sharedDepth(t.head));return e.$anchor.start(r)!=t.$anchor.start(r)}function _v(e){let t=Object.create(null);function r(o){for(let a in o)Object.prototype.hasOwnProperty.call(t,a)||(t[a]=o[a])}return e.someProp("nodeViews",r),e.someProp("markViews",r),t}function G4e(e,t){let r=0,o=0;for(let a in e){if(e[a]!=t[a])return!0;r++}for(let a in t)o++;return r!=o}function Iv(e){if(e.spec.state||e.spec.filterTransaction||e.spec.appendTransaction)throw new RangeError("Plugins passed directly to the view must not have a state component")}var ra={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},$u={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},K4e=typeof navigator<"u"&&/Mac/.test(navigator.platform),J4e=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);for(var on=0;on<10;on++)ra[48+on]=ra[96+on]=String(on);for(var on=1;on<=24;on++)ra[on+111]="F"+on;for(var on=65;on<=90;on++)ra[on]=String.fromCharCode(on+32),$u[on]=String.fromCharCode(on);for(var ip in ra)$u.hasOwnProperty(ip)||($u[ip]=ra[ip]);function Z4e(e){var t=K4e&&e.metaKey&&e.shiftKey&&!e.ctrlKey&&!e.altKey||J4e&&e.shiftKey&&e.key&&e.key.length==1||e.key=="Unidentified",r=!t&&e.key||(e.shiftKey?$u:ra)[e.keyCode]||e.key||"Unidentified";return r=="Esc"&&(r="Escape"),r=="Del"&&(r="Delete"),r=="Left"&&(r="ArrowLeft"),r=="Up"&&(r="ArrowUp"),r=="Right"&&(r="ArrowRight"),r=="Down"&&(r="ArrowDown"),r}const X4e=typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):!1;function eve(e){let t=e.split(/-(?!$)/),r=t[t.length-1];r=="Space"&&(r=" ");let o,a,i,l;for(let s=0;s<t.length-1;s++){let c=t[s];if(/^(cmd|meta|m)$/i.test(c))l=!0;else if(/^a(lt)?$/i.test(c))o=!0;else if(/^(c|ctrl|control)$/i.test(c))a=!0;else if(/^s(hift)?$/i.test(c))i=!0;else if(/^mod$/i.test(c))X4e?l=!0:a=!0;else throw new Error("Unrecognized modifier name: "+c)}return o&&(r="Alt-"+r),a&&(r="Ctrl-"+r),l&&(r="Meta-"+r),i&&(r="Shift-"+r),r}function tve(e){let t=Object.create(null);for(let r in e)t[eve(r)]=e[r];return t}function lp(e,t,r=!0){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),r&&t.shiftKey&&(e="Shift-"+e),e}function nve(e){return new tn({props:{handleKeyDown:rve(e)}})}function rve(e){let t=tve(e);return function(r,o){let a=Z4e(o),i,l=t[lp(a,o)];if(l&&l(r.state,r.dispatch,r))return!0;if(a.length==1&&a!=" "){if(o.shiftKey){let s=t[lp(a,o,!1)];if(s&&s(r.state,r.dispatch,r))return!0}if((o.shiftKey||o.altKey||o.metaKey||a.charCodeAt(0)>127)&&(i=ra[o.keyCode])&&i!=a){let s=t[lp(i,o)];if(s&&s(r.state,r.dispatch,r))return!0}}return!1}}const ove=(e,t)=>e.selection.empty?!1:(t&&t(e.tr.deleteSelection().scrollIntoView()),!0);function Rw(e,t){let{$cursor:r}=e.selection;return!r||(t?!t.endOfTextblock("backward",e):r.parentOffset>0)?null:r}const ave=(e,t,r)=>{let o=Rw(e,r);if(!o)return!1;let a=t2(o);if(!a){let l=o.blockRange(),s=l&&gl(l);return s==null?!1:(t&&t(e.tr.lift(l,s).scrollIntoView()),!0)}let i=a.nodeBefore;if(Yw(e,a,t,-1))return!0;if(o.parent.content.size==0&&(Gi(i,"end")||Pe.isSelectable(i)))for(let l=o.depth;;l--){let s=of(e.doc,o.before(l),o.after(l),Ee.empty);if(s&&s.slice.size<s.to-s.from){if(t){let c=e.tr.step(s);c.setSelection(Gi(i,"end")?Ze.findFrom(c.doc.resolve(c.mapping.map(a.pos,-1)),-1):Pe.create(c.doc,a.pos-i.nodeSize)),t(c.scrollIntoView())}return!0}if(l==1||o.node(l-1).childCount>1)break}return i.isAtom&&a.depth==o.depth-1?(t&&t(e.tr.delete(a.pos-i.nodeSize,a.pos).scrollIntoView()),!0):!1},ive=(e,t,r)=>{let o=Rw(e,r);if(!o)return!1;let a=t2(o);return a?Fw(e,a,t):!1},lve=(e,t,r)=>{let o=Uw(e,r);if(!o)return!1;let a=n2(o);return a?Fw(e,a,t):!1};function Fw(e,t,r){let o=t.nodeBefore,a=o,i=t.pos-1;for(;!a.isTextblock;i--){if(a.type.spec.isolating)return!1;let d=a.lastChild;if(!d)return!1;a=d}let l=t.nodeAfter,s=l,c=t.pos+1;for(;!s.isTextblock;c++){if(s.type.spec.isolating)return!1;let d=s.firstChild;if(!d)return!1;s=d}let u=of(e.doc,i,c,Ee.empty);if(!u||u.from!=i||u instanceof Kt&&u.slice.size>=c-i)return!1;if(r){let d=e.tr.step(u);d.setSelection(Ge.create(d.doc,i)),r(d.scrollIntoView())}return!0}function Gi(e,t,r=!1){for(let o=e;o;o=t=="start"?o.firstChild:o.lastChild){if(o.isTextblock)return!0;if(r&&o.childCount!=1)return!1}return!1}const sve=(e,t,r)=>{let{$head:o,empty:a}=e.selection,i=o;if(!a)return!1;if(o.parent.isTextblock){if(r?!r.endOfTextblock("backward",e):o.parentOffset>0)return!1;i=t2(o)}let l=i&&i.nodeBefore;return!l||!Pe.isSelectable(l)?!1:(t&&t(e.tr.setSelection(Pe.create(e.doc,i.pos-l.nodeSize)).scrollIntoView()),!0)};function t2(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){if(e.index(t)>0)return e.doc.resolve(e.before(t+1));if(e.node(t).type.spec.isolating)break}return null}function Uw(e,t){let{$cursor:r}=e.selection;return!r||(t?!t.endOfTextblock("forward",e):r.parentOffset<r.parent.content.size)?null:r}const cve=(e,t,r)=>{let o=Uw(e,r);if(!o)return!1;let a=n2(o);if(!a)return!1;let i=a.nodeAfter;if(Yw(e,a,t,1))return!0;if(o.parent.content.size==0&&(Gi(i,"start")||Pe.isSelectable(i))){let l=of(e.doc,o.before(),o.after(),Ee.empty);if(l&&l.slice.size<l.to-l.from){if(t){let s=e.tr.step(l);s.setSelection(Gi(i,"start")?Ze.findFrom(s.doc.resolve(s.mapping.map(a.pos)),1):Pe.create(s.doc,s.mapping.map(a.pos))),t(s.scrollIntoView())}return!0}}return i.isAtom&&a.depth==o.depth-1?(t&&t(e.tr.delete(a.pos,a.pos+i.nodeSize).scrollIntoView()),!0):!1},uve=(e,t,r)=>{let{$head:o,empty:a}=e.selection,i=o;if(!a)return!1;if(o.parent.isTextblock){if(r?!r.endOfTextblock("forward",e):o.parentOffset<o.parent.content.size)return!1;i=n2(o)}let l=i&&i.nodeAfter;return!l||!Pe.isSelectable(l)?!1:(t&&t(e.tr.setSelection(Pe.create(e.doc,i.pos)).scrollIntoView()),!0)};function n2(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){let r=e.node(t);if(e.index(t)+1<r.childCount)return e.doc.resolve(e.after(t+1));if(r.type.spec.isolating)break}return null}const dve=(e,t)=>{let r=e.selection,o=r instanceof Pe,a;if(o){if(r.node.isTextblock||!la(e.doc,r.from))return!1;a=r.from}else if(a=rf(e.doc,r.from,-1),a==null)return!1;if(t){let i=e.tr.join(a);o&&i.setSelection(Pe.create(i.doc,a-e.doc.resolve(a).nodeBefore.nodeSize)),t(i.scrollIntoView())}return!0},fve=(e,t)=>{let r=e.selection,o;if(r instanceof Pe){if(r.node.isTextblock||!la(e.doc,r.to))return!1;o=r.to}else if(o=rf(e.doc,r.to,1),o==null)return!1;return t&&t(e.tr.join(o).scrollIntoView()),!0},pve=(e,t)=>{let{$from:r,$to:o}=e.selection,a=r.blockRange(o),i=a&&gl(a);return i==null?!1:(t&&t(e.tr.lift(a,i).scrollIntoView()),!0)},mve=(e,t)=>{let{$head:r,$anchor:o}=e.selection;return!r.parent.type.spec.code||!r.sameParent(o)?!1:(t&&t(e.tr.insertText(`
|
|
56
|
-
`).scrollIntoView()),!0)};function Hw(e){for(let t=0;t<e.edgeCount;t++){let{type:r}=e.edge(t);if(r.isTextblock&&!r.hasRequiredAttrs())return r}return null}const hve=(e,t)=>{let{$head:r,$anchor:o}=e.selection;if(!r.parent.type.spec.code||!r.sameParent(o))return!1;let a=r.node(-1),i=r.indexAfter(-1),l=Hw(a.contentMatchAt(i));if(!l||!a.canReplaceWith(i,i,l))return!1;if(t){let s=r.after(),c=e.tr.replaceWith(s,s,l.createAndFill());c.setSelection(Ze.near(c.doc.resolve(s),1)),t(c.scrollIntoView())}return!0},gve=(e,t)=>{let r=e.selection,{$from:o,$to:a}=r;if(r instanceof _r||o.parent.inlineContent||a.parent.inlineContent)return!1;let i=Hw(a.parent.contentMatchAt(a.indexAfter()));if(!i||!i.isTextblock)return!1;if(t){let l=(!o.parentOffset&&a.index()<a.parent.childCount?o:a).pos,s=e.tr.insert(l,i.createAndFill());s.setSelection(Ge.create(s.doc,l+1)),t(s.scrollIntoView())}return!0},vve=(e,t)=>{let{$cursor:r}=e.selection;if(!r||r.parent.content.size)return!1;if(r.depth>1&&r.after()!=r.end(-1)){let i=r.before();if(Si(e.doc,i))return t&&t(e.tr.split(i).scrollIntoView()),!0}let o=r.blockRange(),a=o&&gl(o);return a==null?!1:(t&&t(e.tr.lift(o,a).scrollIntoView()),!0)},yve=(e,t)=>{let{$from:r,to:o}=e.selection,a,i=r.sharedDepth(o);return i==0?!1:(a=r.before(i),t&&t(e.tr.setSelection(Pe.create(e.doc,a))),!0)};function Mve(e,t,r){let o=t.nodeBefore,a=t.nodeAfter,i=t.index();return!o||!a||!o.type.compatibleContent(a.type)?!1:!o.content.size&&t.parent.canReplace(i-1,i)?(r&&r(e.tr.delete(t.pos-o.nodeSize,t.pos).scrollIntoView()),!0):!t.parent.canReplace(i,i+1)||!(a.isTextblock||la(e.doc,t.pos))?!1:(r&&r(e.tr.join(t.pos).scrollIntoView()),!0)}function Yw(e,t,r,o){let a=t.nodeBefore,i=t.nodeAfter,l,s,c=a.type.spec.isolating||i.type.spec.isolating;if(!c&&Mve(e,t,r))return!0;let u=!c&&t.parent.canReplace(t.index(),t.index()+1);if(u&&(l=(s=a.contentMatchAt(a.childCount)).findWrapping(i.type))&&s.matchType(l[0]||i.type).validEnd){if(r){let h=t.pos+i.nodeSize,m=fe.empty;for(let y=l.length-1;y>=0;y--)m=fe.from(l[y].create(null,m));m=fe.from(a.copy(m));let g=e.tr.step(new Zt(t.pos-1,h,t.pos,h,new Ee(m,1,0),l.length,!0)),v=g.doc.resolve(h+2*l.length);v.nodeAfter&&v.nodeAfter.type==a.type&&la(g.doc,v.pos)&&g.join(v.pos),r(g.scrollIntoView())}return!0}let d=i.type.spec.isolating||o>0&&c?null:Ze.findFrom(t,1),f=d&&d.$from.blockRange(d.$to),p=f&&gl(f);if(p!=null&&p>=t.depth)return r&&r(e.tr.lift(f,p).scrollIntoView()),!0;if(u&&Gi(i,"start",!0)&&Gi(a,"end")){let h=a,m=[];for(;m.push(h),!h.isTextblock;)h=h.lastChild;let g=i,v=1;for(;!g.isTextblock;g=g.firstChild)v++;if(h.canReplace(h.childCount,h.childCount,g.content)){if(r){let y=fe.empty;for(let b=m.length-1;b>=0;b--)y=fe.from(m[b].copy(y));let N=e.tr.step(new Zt(t.pos-m.length,t.pos+i.nodeSize,t.pos+v,t.pos+i.nodeSize-v,new Ee(y,m.length,0),0,!0));r(N.scrollIntoView())}return!0}}return!1}function Qw(e){return function(t,r){let o=t.selection,a=e<0?o.$from:o.$to,i=a.depth;for(;a.node(i).isInline;){if(!i)return!1;i--}return a.node(i).isTextblock?(r&&r(t.tr.setSelection(Ge.create(t.doc,e<0?a.start(i):a.end(i)))),!0):!1}}const bve=Qw(-1),wve=Qw(1);function Nve(e,t=null){return function(r,o){let{$from:a,$to:i}=r.selection,l=a.blockRange(i),s=l&&Yh(l,e,t);return s?(o&&o(r.tr.wrap(l,s).scrollIntoView()),!0):!1}}function Av(e,t=null){return function(r,o){let a=!1;for(let i=0;i<r.selection.ranges.length&&!a;i++){let{$from:{pos:l},$to:{pos:s}}=r.selection.ranges[i];r.doc.nodesBetween(l,s,(c,u)=>{if(a)return!1;if(!(!c.isTextblock||c.hasMarkup(e,t)))if(c.type==e)a=!0;else{let d=r.doc.resolve(u),f=d.index();a=d.parent.canReplaceWith(f,f+1,e)}})}if(!a)return!1;if(o){let i=r.tr;for(let l=0;l<r.selection.ranges.length;l++){let{$from:{pos:s},$to:{pos:c}}=r.selection.ranges[l];i.setBlockType(s,c,e,t)}o(i.scrollIntoView())}return!0}}typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):typeof os<"u"&&os.platform&&os.platform()=="darwin";function kve(e,t=null){return function(r,o){let{$from:a,$to:i}=r.selection,l=a.blockRange(i),s=!1,c=l;if(!l)return!1;if(l.depth>=2&&a.node(l.depth-1).type.compatibleContent(e)&&l.startIndex==0){if(a.index(l.depth-1)==0)return!1;let d=r.doc.resolve(l.start-2);c=new _u(d,d,l.depth),l.endIndex<l.parent.childCount&&(l=new _u(a,r.doc.resolve(i.end(l.depth)),l.depth)),s=!0}let u=Yh(c,e,t,l);return u?(o&&o(xve(r.tr,l,u,s,e).scrollIntoView()),!0):!1}}function xve(e,t,r,o,a){let i=fe.empty;for(let d=r.length-1;d>=0;d--)i=fe.from(r[d].type.create(r[d].attrs,i));e.step(new Zt(t.start-(o?2:0),t.end,t.start,t.end,new Ee(i,0,0),r.length,!0));let l=0;for(let d=0;d<r.length;d++)r[d].type==a&&(l=d+1);let s=r.length-l,c=t.start+r.length-(o?2:0),u=t.parent;for(let d=t.startIndex,f=t.endIndex,p=!0;d<f;d++,p=!1)!p&&Si(e.doc,c,s)&&(e.split(c,s),c+=2*s),c+=u.child(d).nodeSize;return e}function Cve(e){return function(t,r){let{$from:o,$to:a}=t.selection,i=o.blockRange(a,l=>l.childCount>0&&l.firstChild.type==e);return i?r?o.node(i.depth-1).type==e?Eve(t,r,e,i):Tve(t,r,i):!0:!1}}function Eve(e,t,r,o){let a=e.tr,i=o.end,l=o.$to.end(o.depth);i<l&&(a.step(new Zt(i-1,l,i,l,new Ee(fe.from(r.create(null,o.parent.copy())),1,0),1,!0)),o=new _u(a.doc.resolve(o.$from.pos),a.doc.resolve(l),o.depth));const s=gl(o);if(s==null)return!1;a.lift(o,s);let c=a.mapping.map(i,-1)-1;return la(a.doc,c)&&a.join(c),t(a.scrollIntoView()),!0}function Tve(e,t,r){let o=e.tr,a=r.parent;for(let h=r.end,m=r.endIndex-1,g=r.startIndex;m>g;m--)h-=a.child(m).nodeSize,o.delete(h-1,h+1);let i=o.doc.resolve(r.start),l=i.nodeAfter;if(o.mapping.map(r.end)!=r.start+i.nodeAfter.nodeSize)return!1;let s=r.startIndex==0,c=r.endIndex==a.childCount,u=i.node(-1),d=i.index(-1);if(!u.canReplace(d+(s?0:1),d+1,l.content.append(c?fe.empty:fe.from(a))))return!1;let f=i.pos,p=f+l.nodeSize;return o.step(new Zt(f-(s?1:0),p+(c?1:0),f+1,p-1,new Ee((s?fe.empty:fe.from(a.copy(fe.empty))).append(c?fe.empty:fe.from(a.copy(fe.empty))),s?0:1,c?0:1),s?0:1)),t(o.scrollIntoView()),!0}function Dve(e){return function(t,r){let{$from:o,$to:a}=t.selection,i=o.blockRange(a,u=>u.childCount>0&&u.firstChild.type==e);if(!i)return!1;let l=i.startIndex;if(l==0)return!1;let s=i.parent,c=s.child(l-1);if(c.type!=e)return!1;if(r){let u=c.lastChild&&c.lastChild.type==s.type,d=fe.from(u?e.create():null),f=new Ee(fe.from(e.create(null,fe.from(s.type.create(null,d)))),u?3:1,0),p=i.start,h=i.end;r(t.tr.step(new Zt(p-(u?3:1),h,p,h,f,1,!0)).scrollIntoView())}return!0}}function uf(e){const{state:t,transaction:r}=e;let{selection:o}=r,{doc:a}=r,{storedMarks:i}=r;return{...t,apply:t.apply.bind(t),applyTransaction:t.applyTransaction.bind(t),plugins:t.plugins,schema:t.schema,reconfigure:t.reconfigure.bind(t),toJSON:t.toJSON.bind(t),get storedMarks(){return i},get selection(){return o},get doc(){return a},get tr(){return o=r.selection,a=r.doc,i=r.storedMarks,r}}}class df{constructor(t){this.editor=t.editor,this.rawCommands=this.editor.extensionManager.commands,this.customState=t.state}get hasCustomState(){return!!this.customState}get state(){return this.customState||this.editor.state}get commands(){const{rawCommands:t,editor:r,state:o}=this,{view:a}=r,{tr:i}=o,l=this.buildProps(i);return Object.fromEntries(Object.entries(t).map(([s,c])=>[s,(...d)=>{const f=c(...d)(l);return!i.getMeta("preventDispatch")&&!this.hasCustomState&&a.dispatch(i),f}]))}get chain(){return()=>this.createChain()}get can(){return()=>this.createCan()}createChain(t,r=!0){const{rawCommands:o,editor:a,state:i}=this,{view:l}=a,s=[],c=!!t,u=t||i.tr,d=()=>(!c&&r&&!u.getMeta("preventDispatch")&&!this.hasCustomState&&l.dispatch(u),s.every(p=>p===!0)),f={...Object.fromEntries(Object.entries(o).map(([p,h])=>[p,(...g)=>{const v=this.buildProps(u,r),y=h(...g)(v);return s.push(y),f}])),run:d};return f}createCan(t){const{rawCommands:r,state:o}=this,a=!1,i=t||o.tr,l=this.buildProps(i,a);return{...Object.fromEntries(Object.entries(r).map(([c,u])=>[c,(...d)=>u(...d)({...l,dispatch:void 0})])),chain:()=>this.createChain(i,a)}}buildProps(t,r=!0){const{rawCommands:o,editor:a,state:i}=this,{view:l}=a,s={tr:t,editor:a,view:l,state:uf({state:i,transaction:t}),dispatch:r?()=>{}:void 0,chain:()=>this.createChain(t,r),can:()=>this.createCan(t),get commands(){return Object.fromEntries(Object.entries(o).map(([c,u])=>[c,(...d)=>u(...d)(s)]))}};return s}}class Sve{constructor(){this.callbacks={}}on(t,r){return this.callbacks[t]||(this.callbacks[t]=[]),this.callbacks[t].push(r),this}emit(t,...r){const o=this.callbacks[t];return o&&o.forEach(a=>a.apply(this,r)),this}off(t,r){const o=this.callbacks[t];return o&&(r?this.callbacks[t]=o.filter(a=>a!==r):delete this.callbacks[t]),this}removeAllListeners(){this.callbacks={}}}function Ie(e,t,r){return e.config[t]===void 0&&e.parent?Ie(e.parent,t,r):typeof e.config[t]=="function"?e.config[t].bind({...r,parent:e.parent?Ie(e.parent,t,r):null}):e.config[t]}function ff(e){const t=e.filter(a=>a.type==="extension"),r=e.filter(a=>a.type==="node"),o=e.filter(a=>a.type==="mark");return{baseExtensions:t,nodeExtensions:r,markExtensions:o}}function Ww(e){const t=[],{nodeExtensions:r,markExtensions:o}=ff(e),a=[...r,...o],i={default:null,rendered:!0,renderHTML:null,parseHTML:null,keepOnSplit:!0,isRequired:!1};return e.forEach(l=>{const s={name:l.name,options:l.options,storage:l.storage,extensions:a},c=Ie(l,"addGlobalAttributes",s);if(!c)return;c().forEach(d=>{d.types.forEach(f=>{Object.entries(d.attributes).forEach(([p,h])=>{t.push({type:f,name:p,attribute:{...i,...h}})})})})}),a.forEach(l=>{const s={name:l.name,options:l.options,storage:l.storage},c=Ie(l,"addAttributes",s);if(!c)return;const u=c();Object.entries(u).forEach(([d,f])=>{const p={...i,...f};typeof(p==null?void 0:p.default)=="function"&&(p.default=p.default()),p!=null&&p.isRequired&&(p==null?void 0:p.default)===void 0&&delete p.default,t.push({type:l.name,name:d,attribute:p})})}),t}function en(e,t){if(typeof e=="string"){if(!t.nodes[e])throw Error(`There is no node type named '${e}'. Maybe you forgot to add the extension?`);return t.nodes[e]}return e}function jn(...e){return e.filter(t=>!!t).reduce((t,r)=>{const o={...t};return Object.entries(r).forEach(([a,i])=>{if(!o[a]){o[a]=i;return}if(a==="class"){const s=i?i.split(" "):[],c=o[a]?o[a].split(" "):[],u=s.filter(d=>!c.includes(d));o[a]=[...c,...u].join(" ")}else if(a==="style"){const s=i?i.split(";").map(d=>d.trim()).filter(Boolean):[],c=o[a]?o[a].split(";").map(d=>d.trim()).filter(Boolean):[],u=new Map;c.forEach(d=>{const[f,p]=d.split(":").map(h=>h.trim());u.set(f,p)}),s.forEach(d=>{const[f,p]=d.split(":").map(h=>h.trim());u.set(f,p)}),o[a]=Array.from(u.entries()).map(([d,f])=>`${d}: ${f}`).join("; ")}else o[a]=i}),o},{})}function L0(e,t){return t.filter(r=>r.type===e.type.name).filter(r=>r.attribute.rendered).map(r=>r.attribute.renderHTML?r.attribute.renderHTML(e.attrs)||{}:{[r.name]:e.attrs[r.name]}).reduce((r,o)=>jn(r,o),{})}function qw(e){return typeof e=="function"}function Je(e,t=void 0,...r){return qw(e)?t?e.bind(t)(...r):e(...r):e}function _ve(e={}){return Object.keys(e).length===0&&e.constructor===Object}function Ive(e){return typeof e!="string"?e:e.match(/^[+-]?(?:\d*\.)?\d+$/)?Number(e):e==="true"?!0:e==="false"?!1:e}function Ov(e,t){return"style"in e?e:{...e,getAttrs:r=>{const o=e.getAttrs?e.getAttrs(r):e.attrs;if(o===!1)return!1;const a=t.reduce((i,l)=>{const s=l.attribute.parseHTML?l.attribute.parseHTML(r):Ive(r.getAttribute(l.name));return s==null?i:{...i,[l.name]:s}},{});return{...o,...a}}}}function zv(e){return Object.fromEntries(Object.entries(e).filter(([t,r])=>t==="attrs"&&_ve(r)?!1:r!=null))}function Ave(e,t){var r;const o=Ww(e),{nodeExtensions:a,markExtensions:i}=ff(e),l=(r=a.find(u=>Ie(u,"topNode")))===null||r===void 0?void 0:r.name,s=Object.fromEntries(a.map(u=>{const d=o.filter(y=>y.type===u.name),f={name:u.name,options:u.options,storage:u.storage,editor:t},p=e.reduce((y,N)=>{const b=Ie(N,"extendNodeSchema",f);return{...y,...b?b(u):{}}},{}),h=zv({...p,content:Je(Ie(u,"content",f)),marks:Je(Ie(u,"marks",f)),group:Je(Ie(u,"group",f)),inline:Je(Ie(u,"inline",f)),atom:Je(Ie(u,"atom",f)),selectable:Je(Ie(u,"selectable",f)),draggable:Je(Ie(u,"draggable",f)),code:Je(Ie(u,"code",f)),whitespace:Je(Ie(u,"whitespace",f)),defining:Je(Ie(u,"defining",f)),isolating:Je(Ie(u,"isolating",f)),attrs:Object.fromEntries(d.map(y=>{var N;return[y.name,{default:(N=y==null?void 0:y.attribute)===null||N===void 0?void 0:N.default}]}))}),m=Je(Ie(u,"parseHTML",f));m&&(h.parseDOM=m.map(y=>Ov(y,d)));const g=Ie(u,"renderHTML",f);g&&(h.toDOM=y=>g({node:y,HTMLAttributes:L0(y,d)}));const v=Ie(u,"renderText",f);return v&&(h.toText=v),[u.name,h]})),c=Object.fromEntries(i.map(u=>{const d=o.filter(v=>v.type===u.name),f={name:u.name,options:u.options,storage:u.storage,editor:t},p=e.reduce((v,y)=>{const N=Ie(y,"extendMarkSchema",f);return{...v,...N?N(u):{}}},{}),h=zv({...p,inclusive:Je(Ie(u,"inclusive",f)),excludes:Je(Ie(u,"excludes",f)),group:Je(Ie(u,"group",f)),spanning:Je(Ie(u,"spanning",f)),code:Je(Ie(u,"code",f)),attrs:Object.fromEntries(d.map(v=>{var y;return[v.name,{default:(y=v==null?void 0:v.attribute)===null||y===void 0?void 0:y.default}]}))}),m=Je(Ie(u,"parseHTML",f));m&&(h.parseDOM=m.map(v=>Ov(v,d)));const g=Ie(u,"renderHTML",f);return g&&(h.toDOM=v=>g({mark:v,HTMLAttributes:L0(v,d)})),[u.name,h]}));return new U8({topNode:l,nodes:s,marks:c})}function sp(e,t){return t.nodes[e]||t.marks[e]||null}function jv(e,t){return Array.isArray(t)?t.some(r=>(typeof r=="string"?r:r.name)===e.name):t}const Ove=(e,t=500)=>{let r="";const o=e.parentOffset;return e.parent.nodesBetween(Math.max(0,o-t),o,(a,i,l,s)=>{var c,u;const d=((u=(c=a.type.spec).toText)===null||u===void 0?void 0:u.call(c,{node:a,pos:i,parent:l,index:s}))||a.textContent||"%leaf%";r+=a.isAtom&&!a.isText?d:d.slice(0,Math.max(0,o-i))}),r};function r2(e){return Object.prototype.toString.call(e)==="[object RegExp]"}class o2{constructor(t){this.find=t.find,this.handler=t.handler}}const zve=(e,t)=>{if(r2(t))return t.exec(e);const r=t(e);if(!r)return null;const o=[r.text];return o.index=r.index,o.input=e,o.data=r.data,r.replaceWith&&(r.text.includes(r.replaceWith)||console.warn('[tiptap warn]: "inputRuleMatch.replaceWith" must be part of "inputRuleMatch.text".'),o.push(r.replaceWith)),o};function Ec(e){var t;const{editor:r,from:o,to:a,text:i,rules:l,plugin:s}=e,{view:c}=r;if(c.composing)return!1;const u=c.state.doc.resolve(o);if(u.parent.type.spec.code||!((t=u.nodeBefore||u.nodeAfter)===null||t===void 0)&&t.marks.find(p=>p.type.spec.code))return!1;let d=!1;const f=Ove(u)+i;return l.forEach(p=>{if(d)return;const h=zve(f,p.find);if(!h)return;const m=c.state.tr,g=uf({state:c.state,transaction:m}),v={from:o-(h[0].length-i.length),to:a},{commands:y,chain:N,can:b}=new df({editor:r,state:g});p.handler({state:g,range:v,match:h,commands:y,chain:N,can:b})===null||!m.steps.length||(m.setMeta(s,{transform:m,from:o,to:a,text:i}),c.dispatch(m),d=!0)}),d}function jve(e){const{editor:t,rules:r}=e,o=new tn({state:{init(){return null},apply(a,i){const l=a.getMeta(o);if(l)return l;const s=a.getMeta("applyInputRules");return!!s&&setTimeout(()=>{const{from:u,text:d}=s,f=u+d.length;Ec({editor:t,from:u,to:f,text:d,rules:r,plugin:o})}),a.selectionSet||a.docChanged?null:i}},props:{handleTextInput(a,i,l,s){return Ec({editor:t,from:i,to:l,text:s,rules:r,plugin:o})},handleDOMEvents:{compositionend:a=>(setTimeout(()=>{const{$cursor:i}=a.state.selection;i&&Ec({editor:t,from:i.pos,to:i.pos,text:"",rules:r,plugin:o})}),!1)},handleKeyDown(a,i){if(i.key!=="Enter")return!1;const{$cursor:l}=a.state.selection;return l?Ec({editor:t,from:l.pos,to:l.pos,text:`
|
|
57
|
-
`,rules:r,plugin:o}):!1}},isInputRules:!0});return o}function
|
|
55
|
+
`))),0,0):Ee.empty;let f=e.someProp("clipboardTextParser",p=>p(t,a,o,e));if(f)s=f;else{let p=a.marks(),{schema:h}=e.state,m=Xa.fromSchema(h);l=document.createElement("div"),t.split(/(?:\r\n?|\n)+/).forEach(g=>{let v=l.appendChild(document.createElement("p"));g&&v.appendChild(m.serializeNode(h.text(g,p)))})}}else e.someProp("transformPastedHTML",f=>{r=f(r,e)}),l=f4e(r),Zs&&p4e(l);let u=l&&l.querySelector("[data-pm-slice]"),d=u&&/^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(u.getAttribute("data-pm-slice")||"");if(d&&d[3])for(let f=+d[3];f>0;f--){let p=l.firstChild;for(;p&&p.nodeType!=1;)p=p.nextSibling;if(!p)break;l=p}if(s||(s=(e.someProp("clipboardParser")||e.someProp("domParser")||Go.fromSchema(e.state.schema)).parseSlice(l,{preserveWhitespace:!!(c||d),context:a,ruleFromNode(p){return p.nodeName=="BR"&&!p.nextSibling&&p.parentNode&&!c4e.test(p.parentNode.nodeName)?{ignore:!0}:null}})),d)s=m4e(Mv(s,+d[1],+d[2]),d[4]);else if(s=Ee.maxOpen(u4e(s.content,a),!0),s.openStart||s.openEnd){let f=0,p=0;for(let h=s.content.firstChild;f<s.openStart&&!h.type.spec.isolating;f++,h=h.firstChild);for(let h=s.content.lastChild;p<s.openEnd&&!h.type.spec.isolating;p++,h=h.lastChild);s=Mv(s,f,p)}return e.someProp("transformPasted",f=>{s=f(s,e)}),s}const c4e=/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;function u4e(e,t){if(e.childCount<2)return e;for(let r=t.depth;r>=0;r--){let a=t.node(r).contentMatchAt(t.index(r)),i,l=[];if(e.forEach(s=>{if(!l)return;let c=a.findWrapping(s.type),u;if(!c)return l=null;if(u=l.length&&i.length&&Tw(c,i,s,l[l.length-1],0))l[l.length-1]=u;else{l.length&&(l[l.length-1]=Dw(l[l.length-1],i.length));let d=Ew(s,c);l.push(d),a=a.matchType(d.type),i=c}}),l)return fe.from(l)}return e}function Ew(e,t,r=0){for(let o=t.length-1;o>=r;o--)e=t[o].create(null,fe.from(e));return e}function Tw(e,t,r,o,a){if(a<e.length&&a<t.length&&e[a]==t[a]){let i=Tw(e,t,r,o.lastChild,a+1);if(i)return o.copy(o.content.replaceChild(o.childCount-1,i));if(o.contentMatchAt(o.childCount).matchType(a==e.length-1?r.type:e[a+1]))return o.copy(o.content.append(fe.from(Ew(r,e,a+1))))}}function Dw(e,t){if(t==0)return e;let r=e.content.replaceChild(e.childCount-1,Dw(e.lastChild,t-1)),o=e.contentMatchAt(e.childCount).fillBefore(fe.empty,!0);return e.copy(r.append(o))}function z0(e,t,r,o,a,i){let l=t<0?e.firstChild:e.lastChild,s=l.content;return e.childCount>1&&(i=0),a<o-1&&(s=z0(s,t,r,o,a+1,i)),a>=r&&(s=t<0?l.contentMatchAt(0).fillBefore(s,i<=a).append(s):s.append(l.contentMatchAt(l.childCount).fillBefore(fe.empty,!0))),e.replaceChild(t<0?0:e.childCount-1,l.copy(s))}function Mv(e,t,r){return t<e.openStart&&(e=new Ee(z0(e.content,-1,t,e.openStart,0,e.openEnd),t,e.openEnd)),r<e.openEnd&&(e=new Ee(z0(e.content,1,r,e.openEnd,0,0),e.openStart,r)),e}const Sw={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]};let bv=null;function _w(){return bv||(bv=document.implementation.createHTMLDocument("title"))}let rp=null;function d4e(e){let t=window.trustedTypes;return t?(rp||(rp=t.createPolicy("ProseMirrorClipboard",{createHTML:r=>r})),rp.createHTML(e)):e}function f4e(e){let t=/^(\s*<meta [^>]*>)*/.exec(e);t&&(e=e.slice(t[0].length));let r=_w().createElement("div"),o=/<([a-z][^>\s]+)/i.exec(e),a;if((a=o&&Sw[o[1].toLowerCase()])&&(e=a.map(i=>"<"+i+">").join("")+e+a.map(i=>"</"+i+">").reverse().join("")),r.innerHTML=d4e(e),a)for(let i=0;i<a.length;i++)r=r.querySelector(a[i])||r;return r}function p4e(e){let t=e.querySelectorAll(fn?"span:not([class]):not([style])":"span.Apple-converted-space");for(let r=0;r<t.length;r++){let o=t[r];o.childNodes.length==1&&o.textContent==" "&&o.parentNode&&o.parentNode.replaceChild(e.ownerDocument.createTextNode(" "),o)}}function m4e(e,t){if(!e.size)return e;let r=e.content.firstChild.type.schema,o;try{o=JSON.parse(t)}catch{return e}let{content:a,openStart:i,openEnd:l}=e;for(let s=o.length-2;s>=0;s-=2){let c=r.nodes[o[s]];if(!c||c.hasRequiredAttrs())break;a=fe.from(c.create(o[s+1],a)),i++,l++}return new Ee(a,i,l)}const wn={},Nn={},h4e={touchstart:!0,touchmove:!0};class g4e{constructor(){this.shiftKey=!1,this.mouseDown=null,this.lastKeyCode=null,this.lastKeyCodeTime=0,this.lastClick={time:0,x:0,y:0,type:""},this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastIOSEnter=0,this.lastIOSEnterFallbackTimeout=-1,this.lastFocus=0,this.lastTouch=0,this.lastAndroidDelete=0,this.composing=!1,this.compositionNode=null,this.composingTimeout=-1,this.compositionNodes=[],this.compositionEndedAt=-2e8,this.compositionID=1,this.compositionPendingChanges=0,this.domChangeCount=0,this.eventHandlers=Object.create(null),this.hideSelectionGuard=null}}function v4e(e){for(let t in wn){let r=wn[t];e.dom.addEventListener(t,e.input.eventHandlers[t]=o=>{M4e(e,o)&&!Kh(e,o)&&(e.editable||!(o.type in Nn))&&r(e,o)},h4e[t]?{passive:!0}:void 0)}bn&&e.dom.addEventListener("input",()=>null),j0(e)}function Qo(e,t){e.input.lastSelectionOrigin=t,e.input.lastSelectionTime=Date.now()}function y4e(e){e.domObserver.stop();for(let t in e.input.eventHandlers)e.dom.removeEventListener(t,e.input.eventHandlers[t]);clearTimeout(e.input.composingTimeout),clearTimeout(e.input.lastIOSEnterFallbackTimeout)}function j0(e){e.someProp("handleDOMEvents",t=>{for(let r in t)e.input.eventHandlers[r]||e.dom.addEventListener(r,e.input.eventHandlers[r]=o=>Kh(e,o))})}function Kh(e,t){return e.someProp("handleDOMEvents",r=>{let o=r[t.type];return o?o(e,t)||t.defaultPrevented:!1})}function M4e(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let r=t.target;r!=e.dom;r=r.parentNode)if(!r||r.nodeType==11||r.pmViewDesc&&r.pmViewDesc.stopEvent(t))return!1;return!0}function b4e(e,t){!Kh(e,t)&&wn[t.type]&&(e.editable||!(t.type in Nn))&&wn[t.type](e,t)}Nn.keydown=(e,t)=>{let r=t;if(e.input.shiftKey=r.keyCode==16||r.shiftKey,!Aw(e,r)&&(e.input.lastKeyCode=r.keyCode,e.input.lastKeyCodeTime=Date.now(),!(Er&&fn&&r.keyCode==13)))if(r.keyCode!=229&&e.domObserver.forceFlush(),qi&&r.keyCode==13&&!r.ctrlKey&&!r.altKey&&!r.metaKey){let o=Date.now();e.input.lastIOSEnter=o,e.input.lastIOSEnterFallbackTimeout=setTimeout(()=>{e.input.lastIOSEnter==o&&(e.someProp("handleKeyDown",a=>a(e,Ma(13,"Enter"))),e.input.lastIOSEnter=0)},200)}else e.someProp("handleKeyDown",o=>o(e,r))||s4e(e,r)?r.preventDefault():Qo(e,"key")};Nn.keyup=(e,t)=>{t.keyCode==16&&(e.input.shiftKey=!1)};Nn.keypress=(e,t)=>{let r=t;if(Aw(e,r)||!r.charCode||r.ctrlKey&&!r.altKey||tr&&r.metaKey)return;if(e.someProp("handleKeyPress",a=>a(e,r))){r.preventDefault();return}let o=e.state.selection;if(!(o instanceof Ge)||!o.$from.sameParent(o.$to)){let a=String.fromCharCode(r.charCode);!/[\r\n]/.test(a)&&!e.someProp("handleTextInput",i=>i(e,o.$from.pos,o.$to.pos,a))&&e.dispatch(e.state.tr.insertText(a).scrollIntoView()),r.preventDefault()}};function cf(e){return{left:e.clientX,top:e.clientY}}function w4e(e,t){let r=t.x-e.clientX,o=t.y-e.clientY;return r*r+o*o<100}function Jh(e,t,r,o,a){if(o==-1)return!1;let i=e.state.doc.resolve(o);for(let l=i.depth+1;l>0;l--)if(e.someProp(t,s=>l>i.depth?s(e,r,i.nodeAfter,i.before(l),a,!0):s(e,r,i.node(l),i.before(l),a,!1)))return!0;return!1}function Ii(e,t,r){if(e.focused||e.focus(),e.state.selection.eq(t))return;let o=e.state.tr.setSelection(t);r=="pointer"&&o.setMeta("pointer",!0),e.dispatch(o)}function N4e(e,t){if(t==-1)return!1;let r=e.state.doc.resolve(t),o=r.nodeAfter;return o&&o.isAtom&&Pe.isSelectable(o)?(Ii(e,new Pe(r),"pointer"),!0):!1}function k4e(e,t){if(t==-1)return!1;let r=e.state.selection,o,a;r instanceof Pe&&(o=r.node);let i=e.state.doc.resolve(t);for(let l=i.depth+1;l>0;l--){let s=l>i.depth?i.nodeAfter:i.node(l);if(Pe.isSelectable(s)){o&&r.$from.depth>0&&l>=r.$from.depth&&i.before(r.$from.depth+1)==r.$from.pos?a=i.before(r.$from.depth):a=i.before(l);break}}return a!=null?(Ii(e,Pe.create(e.state.doc,a),"pointer"),!0):!1}function x4e(e,t,r,o,a){return Jh(e,"handleClickOn",t,r,o)||e.someProp("handleClick",i=>i(e,t,o))||(a?k4e(e,r):N4e(e,r))}function C4e(e,t,r,o){return Jh(e,"handleDoubleClickOn",t,r,o)||e.someProp("handleDoubleClick",a=>a(e,t,o))}function E4e(e,t,r,o){return Jh(e,"handleTripleClickOn",t,r,o)||e.someProp("handleTripleClick",a=>a(e,t,o))||T4e(e,r,o)}function T4e(e,t,r){if(r.button!=0)return!1;let o=e.state.doc;if(t==-1)return o.inlineContent?(Ii(e,Ge.create(o,0,o.content.size),"pointer"),!0):!1;let a=o.resolve(t);for(let i=a.depth+1;i>0;i--){let l=i>a.depth?a.nodeAfter:a.node(i),s=a.before(i);if(l.inlineContent)Ii(e,Ge.create(o,s+1,s+1+l.content.size),"pointer");else if(Pe.isSelectable(l))Ii(e,Pe.create(o,s),"pointer");else continue;return!0}}function Zh(e){return Lu(e)}const Iw=tr?"metaKey":"ctrlKey";wn.mousedown=(e,t)=>{let r=t;e.input.shiftKey=r.shiftKey;let o=Zh(e),a=Date.now(),i="singleClick";a-e.input.lastClick.time<500&&w4e(r,e.input.lastClick)&&!r[Iw]&&(e.input.lastClick.type=="singleClick"?i="doubleClick":e.input.lastClick.type=="doubleClick"&&(i="tripleClick")),e.input.lastClick={time:a,x:r.clientX,y:r.clientY,type:i};let l=e.posAtCoords(cf(r));l&&(i=="singleClick"?(e.input.mouseDown&&e.input.mouseDown.done(),e.input.mouseDown=new D4e(e,l,r,!!o)):(i=="doubleClick"?C4e:E4e)(e,l.pos,l.inside,r)?r.preventDefault():Qo(e,"pointer"))};class D4e{constructor(t,r,o,a){this.view=t,this.pos=r,this.event=o,this.flushed=a,this.delayedSelectionSync=!1,this.mightDrag=null,this.startDoc=t.state.doc,this.selectNode=!!o[Iw],this.allowDefault=o.shiftKey;let i,l;if(r.inside>-1)i=t.state.doc.nodeAt(r.inside),l=r.inside;else{let d=t.state.doc.resolve(r.pos);i=d.parent,l=d.depth?d.before():0}const s=a?null:o.target,c=s?t.docView.nearestDesc(s,!0):null;this.target=c&&c.dom.nodeType==1?c.dom:null;let{selection:u}=t.state;(o.button==0&&i.type.spec.draggable&&i.type.spec.selectable!==!1||u instanceof Pe&&u.from<=l&&u.to>l)&&(this.mightDrag={node:i,pos:l,addAttr:!!(this.target&&!this.target.draggable),setUneditable:!!(this.target&&Or&&!this.target.hasAttribute("contentEditable"))}),this.target&&this.mightDrag&&(this.mightDrag.addAttr||this.mightDrag.setUneditable)&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&(this.target.draggable=!0),this.mightDrag.setUneditable&&setTimeout(()=>{this.view.input.mouseDown==this&&this.target.setAttribute("contentEditable","false")},20),this.view.domObserver.start()),t.root.addEventListener("mouseup",this.up=this.up.bind(this)),t.root.addEventListener("mousemove",this.move=this.move.bind(this)),Qo(t,"pointer")}done(){this.view.root.removeEventListener("mouseup",this.up),this.view.root.removeEventListener("mousemove",this.move),this.mightDrag&&this.target&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&this.target.removeAttribute("draggable"),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.delayedSelectionSync&&setTimeout(()=>yo(this.view)),this.view.input.mouseDown=null}up(t){if(this.done(),!this.view.dom.contains(t.target))return;let r=this.pos;this.view.state.doc!=this.startDoc&&(r=this.view.posAtCoords(cf(t))),this.updateAllowDefault(t),this.allowDefault||!r?Qo(this.view,"pointer"):x4e(this.view,r.pos,r.inside,t,this.selectNode)?t.preventDefault():t.button==0&&(this.flushed||bn&&this.mightDrag&&!this.mightDrag.node.isAtom||fn&&!this.view.state.selection.visible&&Math.min(Math.abs(r.pos-this.view.state.selection.from),Math.abs(r.pos-this.view.state.selection.to))<=2)?(Ii(this.view,Ze.near(this.view.state.doc.resolve(r.pos)),"pointer"),t.preventDefault()):Qo(this.view,"pointer")}move(t){this.updateAllowDefault(t),Qo(this.view,"pointer"),t.buttons==0&&this.done()}updateAllowDefault(t){!this.allowDefault&&(Math.abs(this.event.x-t.clientX)>4||Math.abs(this.event.y-t.clientY)>4)&&(this.allowDefault=!0)}}wn.touchstart=e=>{e.input.lastTouch=Date.now(),Zh(e),Qo(e,"pointer")};wn.touchmove=e=>{e.input.lastTouch=Date.now(),Qo(e,"pointer")};wn.contextmenu=e=>Zh(e);function Aw(e,t){return e.composing?!0:bn&&Math.abs(t.timeStamp-e.input.compositionEndedAt)<500?(e.input.compositionEndedAt=-2e8,!0):!1}const S4e=Er?5e3:-1;Nn.compositionstart=Nn.compositionupdate=e=>{if(!e.composing){e.domObserver.flush();let{state:t}=e,r=t.selection.$to;if(t.selection instanceof Ge&&(t.storedMarks||!r.textOffset&&r.parentOffset&&r.nodeBefore.marks.some(o=>o.type.spec.inclusive===!1)))e.markCursor=e.state.storedMarks||r.marks(),Lu(e,!0),e.markCursor=null;else if(Lu(e,!t.selection.empty),Or&&t.selection.empty&&r.parentOffset&&!r.textOffset&&r.nodeBefore.marks.length){let o=e.domSelectionRange();for(let a=o.focusNode,i=o.focusOffset;a&&a.nodeType==1&&i!=0;){let l=i<0?a.lastChild:a.childNodes[i-1];if(!l)break;if(l.nodeType==3){let s=e.domSelection();s&&s.collapse(l,l.nodeValue.length);break}else a=l,i=-1}}e.input.composing=!0}Ow(e,S4e)};Nn.compositionend=(e,t)=>{e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=t.timeStamp,e.input.compositionPendingChanges=e.domObserver.pendingRecords().length?e.input.compositionID:0,e.input.compositionNode=null,e.input.compositionPendingChanges&&Promise.resolve().then(()=>e.domObserver.flush()),e.input.compositionID++,Ow(e,20))};function Ow(e,t){clearTimeout(e.input.composingTimeout),t>-1&&(e.input.composingTimeout=setTimeout(()=>Lu(e),t))}function zw(e){for(e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=I4e());e.input.compositionNodes.length>0;)e.input.compositionNodes.pop().markParentsDirty()}function _4e(e){let t=e.domSelectionRange();if(!t.focusNode)return null;let r=Nge(t.focusNode,t.focusOffset),o=kge(t.focusNode,t.focusOffset);if(r&&o&&r!=o){let a=o.pmViewDesc,i=e.domObserver.lastChangedTextNode;if(r==i||o==i)return i;if(!a||!a.isText(o.nodeValue))return o;if(e.input.compositionNode==o){let l=r.pmViewDesc;if(!(!l||!l.isText(r.nodeValue)))return o}}return r||o}function I4e(){let e=document.createEvent("Event");return e.initEvent("event",!0,!0),e.timeStamp}function Lu(e,t=!1){if(!(Er&&e.domObserver.flushingSoon>=0)){if(e.domObserver.forceFlush(),zw(e),t||e.docView&&e.docView.dirty){let r=qh(e);return r&&!r.eq(e.state.selection)?e.dispatch(e.state.tr.setSelection(r)):(e.markCursor||t)&&!e.state.selection.empty?e.dispatch(e.state.tr.deleteSelection()):e.updateState(e.state),!0}return!1}}function A4e(e,t){if(!e.dom.parentNode)return;let r=e.dom.parentNode.appendChild(document.createElement("div"));r.appendChild(t),r.style.cssText="position: fixed; left: -10000px; top: 10px";let o=getSelection(),a=document.createRange();a.selectNodeContents(t),e.dom.blur(),o.removeAllRanges(),o.addRange(a),setTimeout(()=>{r.parentNode&&r.parentNode.removeChild(r),e.focus()},50)}const Es=An&&Ko<15||qi&&Dge<604;wn.copy=Nn.cut=(e,t)=>{let r=t,o=e.state.selection,a=r.type=="cut";if(o.empty)return;let i=Es?null:r.clipboardData,l=o.content(),{dom:s,text:c}=xw(e,l);i?(r.preventDefault(),i.clearData(),i.setData("text/html",s.innerHTML),i.setData("text/plain",c)):A4e(e,s),a&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))};function O4e(e){return e.openStart==0&&e.openEnd==0&&e.content.childCount==1?e.content.firstChild:null}function z4e(e,t){if(!e.dom.parentNode)return;let r=e.input.shiftKey||e.state.selection.$from.parent.type.spec.code,o=e.dom.parentNode.appendChild(document.createElement(r?"textarea":"div"));r||(o.contentEditable="true"),o.style.cssText="position: fixed; left: -10000px; top: 10px",o.focus();let a=e.input.shiftKey&&e.input.lastKeyCode!=45;setTimeout(()=>{e.focus(),o.parentNode&&o.parentNode.removeChild(o),r?Ts(e,o.value,null,a,t):Ts(e,o.textContent,o.innerHTML,a,t)},50)}function Ts(e,t,r,o,a){let i=Cw(e,t,r,o,e.state.selection.$from);if(e.someProp("handlePaste",c=>c(e,a,i||Ee.empty)))return!0;if(!i)return!1;let l=O4e(i),s=l?e.state.tr.replaceSelectionWith(l,o):e.state.tr.replaceSelection(i);return e.dispatch(s.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste")),!0}function jw(e){let t=e.getData("text/plain")||e.getData("Text");if(t)return t;let r=e.getData("text/uri-list");return r?r.replace(/\r?\n/g," "):""}Nn.paste=(e,t)=>{let r=t;if(e.composing&&!Er)return;let o=Es?null:r.clipboardData,a=e.input.shiftKey&&e.input.lastKeyCode!=45;o&&Ts(e,jw(o),o.getData("text/html"),a,r)?r.preventDefault():z4e(e,r)};class Lw{constructor(t,r,o){this.slice=t,this.move=r,this.node=o}}const Bw=tr?"altKey":"ctrlKey";wn.dragstart=(e,t)=>{let r=t,o=e.input.mouseDown;if(o&&o.done(),!r.dataTransfer)return;let a=e.state.selection,i=a.empty?null:e.posAtCoords(cf(r)),l;if(!(i&&i.pos>=a.from&&i.pos<=(a instanceof Pe?a.to-1:a.to))){if(o&&o.mightDrag)l=Pe.create(e.state.doc,o.mightDrag.pos);else if(r.target&&r.target.nodeType==1){let f=e.docView.nearestDesc(r.target,!0);f&&f.node.type.spec.draggable&&f!=e.docView&&(l=Pe.create(e.state.doc,f.posBefore))}}let s=(l||e.state.selection).content(),{dom:c,text:u,slice:d}=xw(e,s);(!r.dataTransfer.files.length||!fn||sw>120)&&r.dataTransfer.clearData(),r.dataTransfer.setData(Es?"Text":"text/html",c.innerHTML),r.dataTransfer.effectAllowed="copyMove",Es||r.dataTransfer.setData("text/plain",u),e.dragging=new Lw(d,!r[Bw],l)};wn.dragend=e=>{let t=e.dragging;window.setTimeout(()=>{e.dragging==t&&(e.dragging=null)},50)};Nn.dragover=Nn.dragenter=(e,t)=>t.preventDefault();Nn.drop=(e,t)=>{let r=t,o=e.dragging;if(e.dragging=null,!r.dataTransfer)return;let a=e.posAtCoords(cf(r));if(!a)return;let i=e.state.doc.resolve(a.pos),l=o&&o.slice;l?e.someProp("transformPasted",m=>{l=m(l,e)}):l=Cw(e,jw(r.dataTransfer),Es?null:r.dataTransfer.getData("text/html"),!1,i);let s=!!(o&&!r[Bw]);if(e.someProp("handleDrop",m=>m(e,r,l||Ee.empty,s))){r.preventDefault();return}if(!l)return;r.preventDefault();let c=l?cge(e.state.doc,i.pos,l):i.pos;c==null&&(c=i.pos);let u=e.state.tr;if(s){let{node:m}=o;m?m.replace(u):u.deleteSelection()}let d=u.mapping.map(c),f=l.openStart==0&&l.openEnd==0&&l.content.childCount==1,p=u.doc;if(f?u.replaceRangeWith(d,d,l.content.firstChild):u.replaceRange(d,d,l),u.doc.eq(p))return;let h=u.doc.resolve(d);if(f&&Pe.isSelectable(l.content.firstChild)&&h.nodeAfter&&h.nodeAfter.sameMarkup(l.content.firstChild))u.setSelection(new Pe(h));else{let m=u.mapping.map(c);u.mapping.maps[u.mapping.maps.length-1].forEach((g,v,y,N)=>m=N),u.setSelection(Gh(e,h,u.doc.resolve(m)))}e.focus(),e.dispatch(u.setMeta("uiEvent","drop"))};wn.focus=e=>{e.input.lastFocus=Date.now(),e.focused||(e.domObserver.stop(),e.dom.classList.add("ProseMirror-focused"),e.domObserver.start(),e.focused=!0,setTimeout(()=>{e.docView&&e.hasFocus()&&!e.domObserver.currentSelection.eq(e.domSelectionRange())&&yo(e)},20))};wn.blur=(e,t)=>{let r=t;e.focused&&(e.domObserver.stop(),e.dom.classList.remove("ProseMirror-focused"),e.domObserver.start(),r.relatedTarget&&e.dom.contains(r.relatedTarget)&&e.domObserver.currentSelection.clear(),e.focused=!1)};wn.beforeinput=(e,t)=>{if(fn&&Er&&t.inputType=="deleteContentBackward"){e.domObserver.flushSoon();let{domChangeCount:o}=e.input;setTimeout(()=>{if(e.input.domChangeCount!=o||(e.dom.blur(),e.focus(),e.someProp("handleKeyDown",i=>i(e,Ma(8,"Backspace")))))return;let{$cursor:a}=e.state.selection;a&&a.pos>0&&e.dispatch(e.state.tr.delete(a.pos-1,a.pos).scrollIntoView())},50)}};for(let e in Nn)wn[e]=Nn[e];function Ds(e,t){if(e==t)return!0;for(let r in e)if(e[r]!==t[r])return!1;for(let r in t)if(!(r in e))return!1;return!0}class Bu{constructor(t,r){this.toDOM=t,this.spec=r||Aa,this.side=this.spec.side||0}map(t,r,o,a){let{pos:i,deleted:l}=t.mapResult(r.from+a,this.side<0?-1:1);return l?null:new Un(i-o,i-o,this)}valid(){return!0}eq(t){return this==t||t instanceof Bu&&(this.spec.key&&this.spec.key==t.spec.key||this.toDOM==t.toDOM&&Ds(this.spec,t.spec))}destroy(t){this.spec.destroy&&this.spec.destroy(t)}}class Zo{constructor(t,r){this.attrs=t,this.spec=r||Aa}map(t,r,o,a){let i=t.map(r.from+a,this.spec.inclusiveStart?-1:1)-o,l=t.map(r.to+a,this.spec.inclusiveEnd?1:-1)-o;return i>=l?null:new Un(i,l,this)}valid(t,r){return r.from<r.to}eq(t){return this==t||t instanceof Zo&&Ds(this.attrs,t.attrs)&&Ds(this.spec,t.spec)}static is(t){return t.type instanceof Zo}destroy(){}}class Xh{constructor(t,r){this.attrs=t,this.spec=r||Aa}map(t,r,o,a){let i=t.mapResult(r.from+a,1);if(i.deleted)return null;let l=t.mapResult(r.to+a,-1);return l.deleted||l.pos<=i.pos?null:new Un(i.pos-o,l.pos-o,this)}valid(t,r){let{index:o,offset:a}=t.content.findIndex(r.from),i;return a==r.from&&!(i=t.child(o)).isText&&a+i.nodeSize==r.to}eq(t){return this==t||t instanceof Xh&&Ds(this.attrs,t.attrs)&&Ds(this.spec,t.spec)}destroy(){}}class Un{constructor(t,r,o){this.from=t,this.to=r,this.type=o}copy(t,r){return new Un(t,r,this.type)}eq(t,r=0){return this.type.eq(t.type)&&this.from+r==t.from&&this.to+r==t.to}map(t,r,o){return this.type.map(t,this,r,o)}static widget(t,r,o){return new Un(t,t,new Bu(r,o))}static inline(t,r,o,a){return new Un(t,r,new Zo(o,a))}static node(t,r,o,a){return new Un(t,r,new Xh(o,a))}get spec(){return this.type.spec}get inline(){return this.type instanceof Zo}get widget(){return this.type instanceof Bu}}const gi=[],Aa={};class It{constructor(t,r){this.local=t.length?t:gi,this.children=r.length?r:gi}static create(t,r){return r.length?Vu(r,t,0,Aa):dn}find(t,r,o){let a=[];return this.findInner(t??0,r??1e9,a,0,o),a}findInner(t,r,o,a,i){for(let l=0;l<this.local.length;l++){let s=this.local[l];s.from<=r&&s.to>=t&&(!i||i(s.spec))&&o.push(s.copy(s.from+a,s.to+a))}for(let l=0;l<this.children.length;l+=3)if(this.children[l]<r&&this.children[l+1]>t){let s=this.children[l]+1;this.children[l+2].findInner(t-s,r-s,o,a+s,i)}}map(t,r,o){return this==dn||t.maps.length==0?this:this.mapInner(t,r,0,0,o||Aa)}mapInner(t,r,o,a,i){let l;for(let s=0;s<this.local.length;s++){let c=this.local[s].map(t,o,a);c&&c.type.valid(r,c)?(l||(l=[])).push(c):i.onRemove&&i.onRemove(this.local[s].spec)}return this.children.length?j4e(this.children,l||[],t,r,o,a,i):l?new It(l.sort(Oa),gi):dn}add(t,r){return r.length?this==dn?It.create(t,r):this.addInner(t,r,0):this}addInner(t,r,o){let a,i=0;t.forEach((s,c)=>{let u=c+o,d;if(d=$w(r,s,u)){for(a||(a=this.children.slice());i<a.length&&a[i]<c;)i+=3;a[i]==c?a[i+2]=a[i+2].addInner(s,d,u+1):a.splice(i,0,c,c+s.nodeSize,Vu(d,s,u+1,Aa)),i+=3}});let l=Vw(i?Pw(r):r,-o);for(let s=0;s<l.length;s++)l[s].type.valid(t,l[s])||l.splice(s--,1);return new It(l.length?this.local.concat(l).sort(Oa):this.local,a||this.children)}remove(t){return t.length==0||this==dn?this:this.removeInner(t,0)}removeInner(t,r){let o=this.children,a=this.local;for(let i=0;i<o.length;i+=3){let l,s=o[i]+r,c=o[i+1]+r;for(let d=0,f;d<t.length;d++)(f=t[d])&&f.from>s&&f.to<c&&(t[d]=null,(l||(l=[])).push(f));if(!l)continue;o==this.children&&(o=this.children.slice());let u=o[i+2].removeInner(l,s+1);u!=dn?o[i+2]=u:(o.splice(i,3),i-=3)}if(a.length){for(let i=0,l;i<t.length;i++)if(l=t[i])for(let s=0;s<a.length;s++)a[s].eq(l,r)&&(a==this.local&&(a=this.local.slice()),a.splice(s--,1))}return o==this.children&&a==this.local?this:a.length||o.length?new It(a,o):dn}forChild(t,r){if(this==dn)return this;if(r.isLeaf)return It.empty;let o,a;for(let s=0;s<this.children.length;s+=3)if(this.children[s]>=t){this.children[s]==t&&(o=this.children[s+2]);break}let i=t+1,l=i+r.content.size;for(let s=0;s<this.local.length;s++){let c=this.local[s];if(c.from<l&&c.to>i&&c.type instanceof Zo){let u=Math.max(i,c.from)-i,d=Math.min(l,c.to)-i;u<d&&(a||(a=[])).push(c.copy(u,d))}}if(a){let s=new It(a.sort(Oa),gi);return o?new Po([s,o]):s}return o||dn}eq(t){if(this==t)return!0;if(!(t instanceof It)||this.local.length!=t.local.length||this.children.length!=t.children.length)return!1;for(let r=0;r<this.local.length;r++)if(!this.local[r].eq(t.local[r]))return!1;for(let r=0;r<this.children.length;r+=3)if(this.children[r]!=t.children[r]||this.children[r+1]!=t.children[r+1]||!this.children[r+2].eq(t.children[r+2]))return!1;return!0}locals(t){return e2(this.localsInner(t))}localsInner(t){if(this==dn)return gi;if(t.inlineContent||!this.local.some(Zo.is))return this.local;let r=[];for(let o=0;o<this.local.length;o++)this.local[o].type instanceof Zo||r.push(this.local[o]);return r}forEachSet(t){t(this)}}It.empty=new It([],[]);It.removeOverlap=e2;const dn=It.empty;class Po{constructor(t){this.members=t}map(t,r){const o=this.members.map(a=>a.map(t,r,Aa));return Po.from(o)}forChild(t,r){if(r.isLeaf)return It.empty;let o=[];for(let a=0;a<this.members.length;a++){let i=this.members[a].forChild(t,r);i!=dn&&(i instanceof Po?o=o.concat(i.members):o.push(i))}return Po.from(o)}eq(t){if(!(t instanceof Po)||t.members.length!=this.members.length)return!1;for(let r=0;r<this.members.length;r++)if(!this.members[r].eq(t.members[r]))return!1;return!0}locals(t){let r,o=!0;for(let a=0;a<this.members.length;a++){let i=this.members[a].localsInner(t);if(i.length)if(!r)r=i;else{o&&(r=r.slice(),o=!1);for(let l=0;l<i.length;l++)r.push(i[l])}}return r?e2(o?r:r.sort(Oa)):gi}static from(t){switch(t.length){case 0:return dn;case 1:return t[0];default:return new Po(t.every(r=>r instanceof It)?t:t.reduce((r,o)=>r.concat(o instanceof It?o:o.members),[]))}}forEachSet(t){for(let r=0;r<this.members.length;r++)this.members[r].forEachSet(t)}}function j4e(e,t,r,o,a,i,l){let s=e.slice();for(let u=0,d=i;u<r.maps.length;u++){let f=0;r.maps[u].forEach((p,h,m,g)=>{let v=g-m-(h-p);for(let y=0;y<s.length;y+=3){let N=s[y+1];if(N<0||p>N+d-f)continue;let b=s[y]+d-f;h>=b?s[y+1]=p<=b?-2:-1:p>=d&&v&&(s[y]+=v,s[y+1]+=v)}f+=v}),d=r.maps[u].map(d,-1)}let c=!1;for(let u=0;u<s.length;u+=3)if(s[u+1]<0){if(s[u+1]==-2){c=!0,s[u+1]=-1;continue}let d=r.map(e[u]+i),f=d-a;if(f<0||f>=o.content.size){c=!0;continue}let p=r.map(e[u+1]+i,-1),h=p-a,{index:m,offset:g}=o.content.findIndex(f),v=o.maybeChild(m);if(v&&g==f&&g+v.nodeSize==h){let y=s[u+2].mapInner(r,v,d+1,e[u]+i+1,l);y!=dn?(s[u]=f,s[u+1]=h,s[u+2]=y):(s[u+1]=-2,c=!0)}else c=!0}if(c){let u=L4e(s,e,t,r,a,i,l),d=Vu(u,o,0,l);t=d.local;for(let f=0;f<s.length;f+=3)s[f+1]<0&&(s.splice(f,3),f-=3);for(let f=0,p=0;f<d.children.length;f+=3){let h=d.children[f];for(;p<s.length&&s[p]<h;)p+=3;s.splice(p,0,d.children[f],d.children[f+1],d.children[f+2])}}return new It(t.sort(Oa),s)}function Vw(e,t){if(!t||!e.length)return e;let r=[];for(let o=0;o<e.length;o++){let a=e[o];r.push(new Un(a.from+t,a.to+t,a.type))}return r}function L4e(e,t,r,o,a,i,l){function s(c,u){for(let d=0;d<c.local.length;d++){let f=c.local[d].map(o,a,u);f?r.push(f):l.onRemove&&l.onRemove(c.local[d].spec)}for(let d=0;d<c.children.length;d+=3)s(c.children[d+2],c.children[d]+u+1)}for(let c=0;c<e.length;c+=3)e[c+1]==-1&&s(e[c+2],t[c]+i+1);return r}function $w(e,t,r){if(t.isLeaf)return null;let o=r+t.nodeSize,a=null;for(let i=0,l;i<e.length;i++)(l=e[i])&&l.from>r&&l.to<o&&((a||(a=[])).push(l),e[i]=null);return a}function Pw(e){let t=[];for(let r=0;r<e.length;r++)e[r]!=null&&t.push(e[r]);return t}function Vu(e,t,r,o){let a=[],i=!1;t.forEach((s,c)=>{let u=$w(e,s,c+r);if(u){i=!0;let d=Vu(u,s,r+c+1,o);d!=dn&&a.push(c,c+s.nodeSize,d)}});let l=Vw(i?Pw(e):e,-r).sort(Oa);for(let s=0;s<l.length;s++)l[s].type.valid(t,l[s])||(o.onRemove&&o.onRemove(l[s].spec),l.splice(s--,1));return l.length||a.length?new It(l,a):dn}function Oa(e,t){return e.from-t.from||e.to-t.to}function e2(e){let t=e;for(let r=0;r<t.length-1;r++){let o=t[r];if(o.from!=o.to)for(let a=r+1;a<t.length;a++){let i=t[a];if(i.from==o.from){i.to!=o.to&&(t==e&&(t=e.slice()),t[a]=i.copy(i.from,o.to),wv(t,a+1,i.copy(o.to,i.to)));continue}else{i.from<o.to&&(t==e&&(t=e.slice()),t[r]=o.copy(o.from,i.from),wv(t,a,o.copy(i.from,o.to)));break}}}return t}function wv(e,t,r){for(;t<e.length&&Oa(r,e[t])>0;)t++;e.splice(t,0,r)}function op(e){let t=[];return e.someProp("decorations",r=>{let o=r(e.state);o&&o!=dn&&t.push(o)}),e.cursorWrapper&&t.push(It.create(e.state.doc,[e.cursorWrapper.deco])),Po.from(t)}const B4e={childList:!0,characterData:!0,characterDataOldValue:!0,attributes:!0,attributeOldValue:!0,subtree:!0},V4e=An&&Ko<=11;class $4e{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}set(t){this.anchorNode=t.anchorNode,this.anchorOffset=t.anchorOffset,this.focusNode=t.focusNode,this.focusOffset=t.focusOffset}clear(){this.anchorNode=this.focusNode=null}eq(t){return t.anchorNode==this.anchorNode&&t.anchorOffset==this.anchorOffset&&t.focusNode==this.focusNode&&t.focusOffset==this.focusOffset}}class P4e{constructor(t,r){this.view=t,this.handleDOMChange=r,this.queue=[],this.flushingSoon=-1,this.observer=null,this.currentSelection=new $4e,this.onCharData=null,this.suppressingSelectionUpdates=!1,this.lastChangedTextNode=null,this.observer=window.MutationObserver&&new window.MutationObserver(o=>{for(let a=0;a<o.length;a++)this.queue.push(o[a]);An&&Ko<=11&&o.some(a=>a.type=="childList"&&a.removedNodes.length||a.type=="characterData"&&a.oldValue.length>a.target.nodeValue.length)?this.flushSoon():this.flush()}),V4e&&(this.onCharData=o=>{this.queue.push({target:o.target,type:"characterData",oldValue:o.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this)}flushSoon(){this.flushingSoon<0&&(this.flushingSoon=window.setTimeout(()=>{this.flushingSoon=-1,this.flush()},20))}forceFlush(){this.flushingSoon>-1&&(window.clearTimeout(this.flushingSoon),this.flushingSoon=-1,this.flush())}start(){this.observer&&(this.observer.takeRecords(),this.observer.observe(this.view.dom,B4e)),this.onCharData&&this.view.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.connectSelection()}stop(){if(this.observer){let t=this.observer.takeRecords();if(t.length){for(let r=0;r<t.length;r++)this.queue.push(t[r]);window.setTimeout(()=>this.flush(),20)}this.observer.disconnect()}this.onCharData&&this.view.dom.removeEventListener("DOMCharacterDataModified",this.onCharData),this.disconnectSelection()}connectSelection(){this.view.dom.ownerDocument.addEventListener("selectionchange",this.onSelectionChange)}disconnectSelection(){this.view.dom.ownerDocument.removeEventListener("selectionchange",this.onSelectionChange)}suppressSelectionUpdates(){this.suppressingSelectionUpdates=!0,setTimeout(()=>this.suppressingSelectionUpdates=!1,50)}onSelectionChange(){if(pv(this.view)){if(this.suppressingSelectionUpdates)return yo(this.view);if(An&&Ko<=11&&!this.view.state.selection.empty){let t=this.view.domSelectionRange();if(t.focusNode&&Ra(t.focusNode,t.focusOffset,t.anchorNode,t.anchorOffset))return this.flushSoon()}this.flush()}}setCurSelection(){this.currentSelection.set(this.view.domSelectionRange())}ignoreSelectionChange(t){if(!t.focusNode)return!0;let r=new Set,o;for(let i=t.focusNode;i;i=Cs(i))r.add(i);for(let i=t.anchorNode;i;i=Cs(i))if(r.has(i)){o=i;break}let a=o&&this.view.docView.nearestDesc(o);if(a&&a.ignoreMutation({type:"selection",target:o.nodeType==3?o.parentNode:o}))return this.setCurSelection(),!0}pendingRecords(){if(this.observer)for(let t of this.observer.takeRecords())this.queue.push(t);return this.queue}flush(){let{view:t}=this;if(!t.docView||this.flushingSoon>-1)return;let r=this.pendingRecords();r.length&&(this.queue=[]);let o=t.domSelectionRange(),a=!this.suppressingSelectionUpdates&&!this.currentSelection.eq(o)&&pv(t)&&!this.ignoreSelectionChange(o),i=-1,l=-1,s=!1,c=[];if(t.editable)for(let d=0;d<r.length;d++){let f=this.registerMutation(r[d],c);f&&(i=i<0?f.from:Math.min(f.from,i),l=l<0?f.to:Math.max(f.to,l),f.typeOver&&(s=!0))}if(Or&&c.length){let d=c.filter(f=>f.nodeName=="BR");if(d.length==2){let[f,p]=d;f.parentNode&&f.parentNode.parentNode==p.parentNode?p.remove():f.remove()}else{let{focusNode:f}=this.currentSelection;for(let p of d){let h=p.parentNode;h&&h.nodeName=="LI"&&(!f||U4e(t,f)!=h)&&p.remove()}}}let u=null;i<0&&a&&t.input.lastFocus>Date.now()-200&&Math.max(t.input.lastTouch,t.input.lastClick.time)<Date.now()-300&&lf(o)&&(u=qh(t))&&u.eq(Ze.near(t.state.doc.resolve(0),1))?(t.input.lastFocus=0,yo(t),this.currentSelection.set(o),t.scrollToSelection()):(i>-1||a)&&(i>-1&&(t.docView.markDirty(i,l),R4e(t)),this.handleDOMChange(i,l,s,c),t.docView&&t.docView.dirty?t.updateState(t.state):this.currentSelection.eq(o)||yo(t),this.currentSelection.set(o))}registerMutation(t,r){if(r.indexOf(t.target)>-1)return null;let o=this.view.docView.nearestDesc(t.target);if(t.type=="attributes"&&(o==this.view.docView||t.attributeName=="contenteditable"||t.attributeName=="style"&&!t.oldValue&&!t.target.getAttribute("style"))||!o||o.ignoreMutation(t))return null;if(t.type=="childList"){for(let d=0;d<t.addedNodes.length;d++){let f=t.addedNodes[d];r.push(f),f.nodeType==3&&(this.lastChangedTextNode=f)}if(o.contentDOM&&o.contentDOM!=o.dom&&!o.contentDOM.contains(t.target))return{from:o.posBefore,to:o.posAfter};let a=t.previousSibling,i=t.nextSibling;if(An&&Ko<=11&&t.addedNodes.length)for(let d=0;d<t.addedNodes.length;d++){let{previousSibling:f,nextSibling:p}=t.addedNodes[d];(!f||Array.prototype.indexOf.call(t.addedNodes,f)<0)&&(a=f),(!p||Array.prototype.indexOf.call(t.addedNodes,p)<0)&&(i=p)}let l=a&&a.parentNode==t.target?rn(a)+1:0,s=o.localPosFromDOM(t.target,l,-1),c=i&&i.parentNode==t.target?rn(i):t.target.childNodes.length,u=o.localPosFromDOM(t.target,c,1);return{from:s,to:u}}else return t.type=="attributes"?{from:o.posAtStart-o.border,to:o.posAtEnd+o.border}:(this.lastChangedTextNode=t.target,{from:o.posAtStart,to:o.posAtEnd,typeOver:t.target.nodeValue==t.oldValue})}}let Nv=new WeakMap,kv=!1;function R4e(e){if(!Nv.has(e)&&(Nv.set(e,null),["normal","nowrap","pre-line"].indexOf(getComputedStyle(e.dom).whiteSpace)!==-1)){if(e.requiresGeckoHackNode=Or,kv)return;console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package."),kv=!0}}function xv(e,t){let r=t.startContainer,o=t.startOffset,a=t.endContainer,i=t.endOffset,l=e.domAtPos(e.state.selection.anchor);return Ra(l.node,l.offset,a,i)&&([r,o,a,i]=[a,i,r,o]),{anchorNode:r,anchorOffset:o,focusNode:a,focusOffset:i}}function F4e(e,t){if(t.getComposedRanges){let a=t.getComposedRanges(e.root)[0];if(a)return xv(e,a)}let r;function o(a){a.preventDefault(),a.stopImmediatePropagation(),r=a.getTargetRanges()[0]}return e.dom.addEventListener("beforeinput",o,!0),document.execCommand("indent"),e.dom.removeEventListener("beforeinput",o,!0),r?xv(e,r):null}function U4e(e,t){for(let r=t.parentNode;r&&r!=e.dom;r=r.parentNode){let o=e.docView.nearestDesc(r,!0);if(o&&o.node.isBlock)return r}return null}function H4e(e,t,r){let{node:o,fromOffset:a,toOffset:i,from:l,to:s}=e.docView.parseRange(t,r),c=e.domSelectionRange(),u,d=c.anchorNode;if(d&&e.dom.contains(d.nodeType==1?d:d.parentNode)&&(u=[{node:d,offset:c.anchorOffset}],lf(c)||u.push({node:c.focusNode,offset:c.focusOffset})),fn&&e.input.lastKeyCode===8)for(let v=i;v>a;v--){let y=o.childNodes[v-1],N=y.pmViewDesc;if(y.nodeName=="BR"&&!N){i=v;break}if(!N||N.size)break}let f=e.state.doc,p=e.someProp("domParser")||Go.fromSchema(e.state.schema),h=f.resolve(l),m=null,g=p.parse(o,{topNode:h.parent,topMatch:h.parent.contentMatchAt(h.index()),topOpen:!0,from:a,to:i,preserveWhitespace:h.parent.type.whitespace=="pre"?"full":!0,findPositions:u,ruleFromNode:Y4e,context:h});if(u&&u[0].pos!=null){let v=u[0].pos,y=u[1]&&u[1].pos;y==null&&(y=v),m={anchor:v+l,head:y+l}}return{doc:g,sel:m,from:l,to:s}}function Y4e(e){let t=e.pmViewDesc;if(t)return t.parseRule();if(e.nodeName=="BR"&&e.parentNode){if(bn&&/^(ul|ol)$/i.test(e.parentNode.nodeName)){let r=document.createElement("div");return r.appendChild(document.createElement("li")),{skip:r}}else if(e.parentNode.lastChild==e||bn&&/^(tr|table)$/i.test(e.parentNode.nodeName))return{ignore:!0}}else if(e.nodeName=="IMG"&&e.getAttribute("mark-placeholder"))return{ignore:!0};return null}const Q4e=/^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;function W4e(e,t,r,o,a){let i=e.input.compositionPendingChanges||(e.composing?e.input.compositionID:0);if(e.input.compositionPendingChanges=0,t<0){let A=e.input.lastSelectionTime>Date.now()-50?e.input.lastSelectionOrigin:null,O=qh(e,A);if(O&&!e.state.selection.eq(O)){if(fn&&Er&&e.input.lastKeyCode===13&&Date.now()-100<e.input.lastKeyCodeTime&&e.someProp("handleKeyDown",j=>j(e,Ma(13,"Enter"))))return;let _=e.state.tr.setSelection(O);A=="pointer"?_.setMeta("pointer",!0):A=="key"&&_.scrollIntoView(),i&&_.setMeta("composition",i),e.dispatch(_)}return}let l=e.state.doc.resolve(t),s=l.sharedDepth(r);t=l.before(s+1),r=e.state.doc.resolve(r).after(s+1);let c=e.state.selection,u=H4e(e,t,r),d=e.state.doc,f=d.slice(u.from,u.to),p,h;e.input.lastKeyCode===8&&Date.now()-100<e.input.lastKeyCodeTime?(p=e.state.selection.to,h="end"):(p=e.state.selection.from,h="start"),e.input.lastKeyCode=null;let m=K4e(f.content,u.doc.content,u.from,p,h);if(m&&e.input.domChangeCount++,(qi&&e.input.lastIOSEnter>Date.now()-225||Er)&&a.some(A=>A.nodeType==1&&!Q4e.test(A.nodeName))&&(!m||m.endA>=m.endB)&&e.someProp("handleKeyDown",A=>A(e,Ma(13,"Enter")))){e.input.lastIOSEnter=0;return}if(!m)if(o&&c instanceof Ge&&!c.empty&&c.$head.sameParent(c.$anchor)&&!e.composing&&!(u.sel&&u.sel.anchor!=u.sel.head))m={start:c.from,endA:c.to,endB:c.to};else{if(u.sel){let A=Cv(e,e.state.doc,u.sel);if(A&&!A.eq(e.state.selection)){let O=e.state.tr.setSelection(A);i&&O.setMeta("composition",i),e.dispatch(O)}}return}e.state.selection.from<e.state.selection.to&&m.start==m.endB&&e.state.selection instanceof Ge&&(m.start>e.state.selection.from&&m.start<=e.state.selection.from+2&&e.state.selection.from>=u.from?m.start=e.state.selection.from:m.endA<e.state.selection.to&&m.endA>=e.state.selection.to-2&&e.state.selection.to<=u.to&&(m.endB+=e.state.selection.to-m.endA,m.endA=e.state.selection.to)),An&&Ko<=11&&m.endB==m.start+1&&m.endA==m.start&&m.start>u.from&&u.doc.textBetween(m.start-u.from-1,m.start-u.from+1)==" "&&(m.start--,m.endA--,m.endB--);let g=u.doc.resolveNoCache(m.start-u.from),v=u.doc.resolveNoCache(m.endB-u.from),y=d.resolve(m.start),N=g.sameParent(v)&&g.parent.inlineContent&&y.end()>=m.endA,b;if((qi&&e.input.lastIOSEnter>Date.now()-225&&(!N||a.some(A=>A.nodeName=="DIV"||A.nodeName=="P"))||!N&&g.pos<u.doc.content.size&&!g.sameParent(v)&&(b=Ze.findFrom(u.doc.resolve(g.pos+1),1,!0))&&b.head==v.pos)&&e.someProp("handleKeyDown",A=>A(e,Ma(13,"Enter")))){e.input.lastIOSEnter=0;return}if(e.state.selection.anchor>m.start&&G4e(d,m.start,m.endA,g,v)&&e.someProp("handleKeyDown",A=>A(e,Ma(8,"Backspace")))){Er&&fn&&e.domObserver.suppressSelectionUpdates();return}fn&&Er&&m.endB==m.start&&(e.input.lastAndroidDelete=Date.now()),Er&&!N&&g.start()!=v.start()&&v.parentOffset==0&&g.depth==v.depth&&u.sel&&u.sel.anchor==u.sel.head&&u.sel.head==m.endA&&(m.endB-=2,v=u.doc.resolveNoCache(m.endB-u.from),setTimeout(()=>{e.someProp("handleKeyDown",function(A){return A(e,Ma(13,"Enter"))})},20));let M=m.start,k=m.endA,w,C,E;if(N){if(g.pos==v.pos)An&&Ko<=11&&g.parentOffset==0&&(e.domObserver.suppressSelectionUpdates(),setTimeout(()=>yo(e),20)),w=e.state.tr.delete(M,k),C=d.resolve(m.start).marksAcross(d.resolve(m.endA));else if(m.endA==m.endB&&(E=q4e(g.parent.content.cut(g.parentOffset,v.parentOffset),y.parent.content.cut(y.parentOffset,m.endA-y.start()))))w=e.state.tr,E.type=="add"?w.addMark(M,k,E.mark):w.removeMark(M,k,E.mark);else if(g.parent.child(g.index()).isText&&g.index()==v.index()-(v.textOffset?0:1)){let A=g.parent.textBetween(g.parentOffset,v.parentOffset);if(e.someProp("handleTextInput",O=>O(e,M,k,A)))return;w=e.state.tr.insertText(A,M,k)}}if(w||(w=e.state.tr.replace(M,k,u.doc.slice(m.start-u.from,m.endB-u.from))),u.sel){let A=Cv(e,w.doc,u.sel);A&&!(fn&&Er&&e.composing&&A.empty&&(m.start!=m.endB||e.input.lastAndroidDelete<Date.now()-100)&&(A.head==M||A.head==w.mapping.map(k)-1)||An&&A.empty&&A.head==M)&&w.setSelection(A)}C&&w.ensureMarks(C),i&&w.setMeta("composition",i),e.dispatch(w.scrollIntoView())}function Cv(e,t,r){return Math.max(r.anchor,r.head)>t.content.size?null:Gh(e,t.resolve(r.anchor),t.resolve(r.head))}function q4e(e,t){let r=e.firstChild.marks,o=t.firstChild.marks,a=r,i=o,l,s,c;for(let d=0;d<o.length;d++)a=o[d].removeFromSet(a);for(let d=0;d<r.length;d++)i=r[d].removeFromSet(i);if(a.length==1&&i.length==0)s=a[0],l="add",c=d=>d.mark(s.addToSet(d.marks));else if(a.length==0&&i.length==1)s=i[0],l="remove",c=d=>d.mark(s.removeFromSet(d.marks));else return null;let u=[];for(let d=0;d<t.childCount;d++)u.push(c(t.child(d)));if(fe.from(u).eq(e))return{mark:s,type:l}}function G4e(e,t,r,o,a){if(r-t<=a.pos-o.pos||ap(o,!0,!1)<a.pos)return!1;let i=e.resolve(t);if(!o.parent.isTextblock){let s=i.nodeAfter;return s!=null&&r==t+s.nodeSize}if(i.parentOffset<i.parent.content.size||!i.parent.isTextblock)return!1;let l=e.resolve(ap(i,!0,!0));return!l.parent.isTextblock||l.pos>r||ap(l,!0,!1)<r?!1:o.parent.content.cut(o.parentOffset).eq(l.parent.content)}function ap(e,t,r){let o=e.depth,a=t?e.end():e.pos;for(;o>0&&(t||e.indexAfter(o)==e.node(o).childCount);)o--,a++,t=!1;if(r){let i=e.node(o).maybeChild(e.indexAfter(o));for(;i&&!i.isLeaf;)i=i.firstChild,a++}return a}function K4e(e,t,r,o,a){let i=e.findDiffStart(t,r);if(i==null)return null;let{a:l,b:s}=e.findDiffEnd(t,r+e.size,r+t.size);if(a=="end"){let c=Math.max(0,i-Math.min(l,s));o-=l+c-i}if(l<i&&e.size<t.size){let c=o<=i&&o>=l?i-o:0;i-=c,i&&i<t.size&&Ev(t.textBetween(i-1,i+1))&&(i+=c?1:-1),s=i+(s-l),l=i}else if(s<i){let c=o<=i&&o>=s?i-o:0;i-=c,i&&i<e.size&&Ev(e.textBetween(i-1,i+1))&&(i+=c?1:-1),l=i+(l-s),s=i}return{start:i,endA:l,endB:s}}function Ev(e){if(e.length!=2)return!1;let t=e.charCodeAt(0),r=e.charCodeAt(1);return t>=56320&&t<=57343&&r>=55296&&r<=56319}class J4e{constructor(t,r){this._root=null,this.focused=!1,this.trackWrites=null,this.mounted=!1,this.markCursor=null,this.cursorWrapper=null,this.lastSelectedViewDesc=void 0,this.input=new g4e,this.prevDirectPlugins=[],this.pluginViews=[],this.requiresGeckoHackNode=!1,this.dragging=null,this._props=r,this.state=r.state,this.directPlugins=r.plugins||[],this.directPlugins.forEach(Iv),this.dispatch=this.dispatch.bind(this),this.dom=t&&t.mount||document.createElement("div"),t&&(t.appendChild?t.appendChild(this.dom):typeof t=="function"?t(this.dom):t.mount&&(this.mounted=!0)),this.editable=Sv(this),Dv(this),this.nodeViews=_v(this),this.docView=lv(this.state.doc,Tv(this),op(this),this.dom,this),this.domObserver=new P4e(this,(o,a,i,l)=>W4e(this,o,a,i,l)),this.domObserver.start(),v4e(this),this.updatePluginViews()}get composing(){return this.input.composing}get props(){if(this._props.state!=this.state){let t=this._props;this._props={};for(let r in t)this._props[r]=t[r];this._props.state=this.state}return this._props}update(t){t.handleDOMEvents!=this._props.handleDOMEvents&&j0(this);let r=this._props;this._props=t,t.plugins&&(t.plugins.forEach(Iv),this.directPlugins=t.plugins),this.updateStateInner(t.state,r)}setProps(t){let r={};for(let o in this._props)r[o]=this._props[o];r.state=this.state;for(let o in t)r[o]=t[o];this.update(r)}updateState(t){this.updateStateInner(t,this._props)}updateStateInner(t,r){var o;let a=this.state,i=!1,l=!1;t.storedMarks&&this.composing&&(zw(this),l=!0),this.state=t;let s=a.plugins!=t.plugins||this._props.plugins!=r.plugins;if(s||this._props.plugins!=r.plugins||this._props.nodeViews!=r.nodeViews){let h=_v(this);X4e(h,this.nodeViews)&&(this.nodeViews=h,i=!0)}(s||r.handleDOMEvents!=this._props.handleDOMEvents)&&j0(this),this.editable=Sv(this),Dv(this);let c=op(this),u=Tv(this),d=a.plugins!=t.plugins&&!a.doc.eq(t.doc)?"reset":t.scrollToSelection>a.scrollToSelection?"to selection":"preserve",f=i||!this.docView.matchesNode(t.doc,u,c);(f||!t.selection.eq(a.selection))&&(l=!0);let p=d=="preserve"&&l&&this.dom.style.overflowAnchor==null&&Ige(this);if(l){this.domObserver.stop();let h=f&&(An||fn)&&!this.composing&&!a.selection.empty&&!t.selection.empty&&Z4e(a.selection,t.selection);if(f){let m=fn?this.trackWrites=this.domSelectionRange().focusNode:null;this.composing&&(this.input.compositionNode=_4e(this)),(i||!this.docView.update(t.doc,u,c,this))&&(this.docView.updateOuterDeco(u),this.docView.destroy(),this.docView=lv(t.doc,u,c,this.dom,this)),m&&!this.trackWrites&&(h=!0)}h||!(this.input.mouseDown&&this.domObserver.currentSelection.eq(this.domSelectionRange())&&t4e(this))?yo(this,h):(ww(this,t.selection),this.domObserver.setCurSelection()),this.domObserver.start()}this.updatePluginViews(a),!((o=this.dragging)===null||o===void 0)&&o.node&&!a.doc.eq(t.doc)&&this.updateDraggedNode(this.dragging,a),d=="reset"?this.dom.scrollTop=0:d=="to selection"?this.scrollToSelection():p&&Age(p)}scrollToSelection(){let t=this.domSelectionRange().focusNode;if(!this.someProp("handleScrollToSelection",r=>r(this)))if(this.state.selection instanceof Pe){let r=this.docView.domAfterPos(this.state.selection.from);r.nodeType==1&&tv(this,r.getBoundingClientRect(),t)}else tv(this,this.coordsAtPos(this.state.selection.head,1),t)}destroyPluginViews(){let t;for(;t=this.pluginViews.pop();)t.destroy&&t.destroy()}updatePluginViews(t){if(!t||t.plugins!=this.state.plugins||this.directPlugins!=this.prevDirectPlugins){this.prevDirectPlugins=this.directPlugins,this.destroyPluginViews();for(let r=0;r<this.directPlugins.length;r++){let o=this.directPlugins[r];o.spec.view&&this.pluginViews.push(o.spec.view(this))}for(let r=0;r<this.state.plugins.length;r++){let o=this.state.plugins[r];o.spec.view&&this.pluginViews.push(o.spec.view(this))}}else for(let r=0;r<this.pluginViews.length;r++){let o=this.pluginViews[r];o.update&&o.update(this,t)}}updateDraggedNode(t,r){let o=t.node,a=-1;if(this.state.doc.nodeAt(o.from)==o.node)a=o.from;else{let i=o.from+(this.state.doc.content.size-r.doc.content.size);(i>0&&this.state.doc.nodeAt(i))==o.node&&(a=i)}this.dragging=new Lw(t.slice,t.move,a<0?void 0:Pe.create(this.state.doc,a))}someProp(t,r){let o=this._props&&this._props[t],a;if(o!=null&&(a=r?r(o):o))return a;for(let l=0;l<this.directPlugins.length;l++){let s=this.directPlugins[l].props[t];if(s!=null&&(a=r?r(s):s))return a}let i=this.state.plugins;if(i)for(let l=0;l<i.length;l++){let s=i[l].props[t];if(s!=null&&(a=r?r(s):s))return a}}hasFocus(){if(An){let t=this.root.activeElement;if(t==this.dom)return!0;if(!t||!this.dom.contains(t))return!1;for(;t&&this.dom!=t&&this.dom.contains(t);){if(t.contentEditable=="false")return!1;t=t.parentElement}return!0}return this.root.activeElement==this.dom}focus(){this.domObserver.stop(),this.editable&&Oge(this.dom),yo(this),this.domObserver.start()}get root(){let t=this._root;if(t==null){for(let r=this.dom.parentNode;r;r=r.parentNode)if(r.nodeType==9||r.nodeType==11&&r.host)return r.getSelection||(Object.getPrototypeOf(r).getSelection=()=>r.ownerDocument.getSelection()),this._root=r}return t||document}updateRoot(){this._root=null}posAtCoords(t){return Vge(this,t)}coordsAtPos(t,r=1){return pw(this,t,r)}domAtPos(t,r=0){return this.docView.domFromPos(t,r)}nodeDOM(t){let r=this.docView.descAt(t);return r?r.nodeDOM:null}posAtDOM(t,r,o=-1){let a=this.docView.posFromDOM(t,r,o);if(a==null)throw new RangeError("DOM position not inside the editor");return a}endOfTextblock(t,r){return Uge(this,r||this.state,t)}pasteHTML(t,r){return Ts(this,"",t,!1,r||new ClipboardEvent("paste"))}pasteText(t,r){return Ts(this,t,null,!0,r||new ClipboardEvent("paste"))}destroy(){this.docView&&(y4e(this),this.destroyPluginViews(),this.mounted?(this.docView.update(this.state.doc,[],op(this),this),this.dom.textContent=""):this.dom.parentNode&&this.dom.parentNode.removeChild(this.dom),this.docView.destroy(),this.docView=null,bge())}get isDestroyed(){return this.docView==null}dispatchEvent(t){return b4e(this,t)}dispatch(t){let r=this._props.dispatchTransaction;r?r.call(this,t):this.updateState(this.state.apply(t))}domSelectionRange(){let t=this.domSelection();return t?bn&&this.root.nodeType===11&&Cge(this.dom.ownerDocument)==this.dom&&F4e(this,t)||t:{focusNode:null,focusOffset:0,anchorNode:null,anchorOffset:0}}domSelection(){return this.root.getSelection()}}function Tv(e){let t=Object.create(null);return t.class="ProseMirror",t.contenteditable=String(e.editable),e.someProp("attributes",r=>{if(typeof r=="function"&&(r=r(e.state)),r)for(let o in r)o=="class"?t.class+=" "+r[o]:o=="style"?t.style=(t.style?t.style+";":"")+r[o]:!t[o]&&o!="contenteditable"&&o!="nodeName"&&(t[o]=String(r[o]))}),t.translate||(t.translate="no"),[Un.node(0,e.state.doc.content.size,t)]}function Dv(e){if(e.markCursor){let t=document.createElement("img");t.className="ProseMirror-separator",t.setAttribute("mark-placeholder","true"),t.setAttribute("alt",""),e.cursorWrapper={dom:t,deco:Un.widget(e.state.selection.from,t,{raw:!0,marks:e.markCursor})}}else e.cursorWrapper=null}function Sv(e){return!e.someProp("editable",t=>t(e.state)===!1)}function Z4e(e,t){let r=Math.min(e.$anchor.sharedDepth(e.head),t.$anchor.sharedDepth(t.head));return e.$anchor.start(r)!=t.$anchor.start(r)}function _v(e){let t=Object.create(null);function r(o){for(let a in o)Object.prototype.hasOwnProperty.call(t,a)||(t[a]=o[a])}return e.someProp("nodeViews",r),e.someProp("markViews",r),t}function X4e(e,t){let r=0,o=0;for(let a in e){if(e[a]!=t[a])return!0;r++}for(let a in t)o++;return r!=o}function Iv(e){if(e.spec.state||e.spec.filterTransaction||e.spec.appendTransaction)throw new RangeError("Plugins passed directly to the view must not have a state component")}var ra={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},$u={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},eve=typeof navigator<"u"&&/Mac/.test(navigator.platform),tve=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);for(var on=0;on<10;on++)ra[48+on]=ra[96+on]=String(on);for(var on=1;on<=24;on++)ra[on+111]="F"+on;for(var on=65;on<=90;on++)ra[on]=String.fromCharCode(on+32),$u[on]=String.fromCharCode(on);for(var ip in ra)$u.hasOwnProperty(ip)||($u[ip]=ra[ip]);function nve(e){var t=eve&&e.metaKey&&e.shiftKey&&!e.ctrlKey&&!e.altKey||tve&&e.shiftKey&&e.key&&e.key.length==1||e.key=="Unidentified",r=!t&&e.key||(e.shiftKey?$u:ra)[e.keyCode]||e.key||"Unidentified";return r=="Esc"&&(r="Escape"),r=="Del"&&(r="Delete"),r=="Left"&&(r="ArrowLeft"),r=="Up"&&(r="ArrowUp"),r=="Right"&&(r="ArrowRight"),r=="Down"&&(r="ArrowDown"),r}const rve=typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):!1;function ove(e){let t=e.split(/-(?!$)/),r=t[t.length-1];r=="Space"&&(r=" ");let o,a,i,l;for(let s=0;s<t.length-1;s++){let c=t[s];if(/^(cmd|meta|m)$/i.test(c))l=!0;else if(/^a(lt)?$/i.test(c))o=!0;else if(/^(c|ctrl|control)$/i.test(c))a=!0;else if(/^s(hift)?$/i.test(c))i=!0;else if(/^mod$/i.test(c))rve?l=!0:a=!0;else throw new Error("Unrecognized modifier name: "+c)}return o&&(r="Alt-"+r),a&&(r="Ctrl-"+r),l&&(r="Meta-"+r),i&&(r="Shift-"+r),r}function ave(e){let t=Object.create(null);for(let r in e)t[ove(r)]=e[r];return t}function lp(e,t,r=!0){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),r&&t.shiftKey&&(e="Shift-"+e),e}function ive(e){return new tn({props:{handleKeyDown:lve(e)}})}function lve(e){let t=ave(e);return function(r,o){let a=nve(o),i,l=t[lp(a,o)];if(l&&l(r.state,r.dispatch,r))return!0;if(a.length==1&&a!=" "){if(o.shiftKey){let s=t[lp(a,o,!1)];if(s&&s(r.state,r.dispatch,r))return!0}if((o.shiftKey||o.altKey||o.metaKey||a.charCodeAt(0)>127)&&(i=ra[o.keyCode])&&i!=a){let s=t[lp(i,o)];if(s&&s(r.state,r.dispatch,r))return!0}}return!1}}const sve=(e,t)=>e.selection.empty?!1:(t&&t(e.tr.deleteSelection().scrollIntoView()),!0);function Rw(e,t){let{$cursor:r}=e.selection;return!r||(t?!t.endOfTextblock("backward",e):r.parentOffset>0)?null:r}const cve=(e,t,r)=>{let o=Rw(e,r);if(!o)return!1;let a=t2(o);if(!a){let l=o.blockRange(),s=l&&gl(l);return s==null?!1:(t&&t(e.tr.lift(l,s).scrollIntoView()),!0)}let i=a.nodeBefore;if(Yw(e,a,t,-1))return!0;if(o.parent.content.size==0&&(Gi(i,"end")||Pe.isSelectable(i)))for(let l=o.depth;;l--){let s=of(e.doc,o.before(l),o.after(l),Ee.empty);if(s&&s.slice.size<s.to-s.from){if(t){let c=e.tr.step(s);c.setSelection(Gi(i,"end")?Ze.findFrom(c.doc.resolve(c.mapping.map(a.pos,-1)),-1):Pe.create(c.doc,a.pos-i.nodeSize)),t(c.scrollIntoView())}return!0}if(l==1||o.node(l-1).childCount>1)break}return i.isAtom&&a.depth==o.depth-1?(t&&t(e.tr.delete(a.pos-i.nodeSize,a.pos).scrollIntoView()),!0):!1},uve=(e,t,r)=>{let o=Rw(e,r);if(!o)return!1;let a=t2(o);return a?Fw(e,a,t):!1},dve=(e,t,r)=>{let o=Uw(e,r);if(!o)return!1;let a=n2(o);return a?Fw(e,a,t):!1};function Fw(e,t,r){let o=t.nodeBefore,a=o,i=t.pos-1;for(;!a.isTextblock;i--){if(a.type.spec.isolating)return!1;let d=a.lastChild;if(!d)return!1;a=d}let l=t.nodeAfter,s=l,c=t.pos+1;for(;!s.isTextblock;c++){if(s.type.spec.isolating)return!1;let d=s.firstChild;if(!d)return!1;s=d}let u=of(e.doc,i,c,Ee.empty);if(!u||u.from!=i||u instanceof Kt&&u.slice.size>=c-i)return!1;if(r){let d=e.tr.step(u);d.setSelection(Ge.create(d.doc,i)),r(d.scrollIntoView())}return!0}function Gi(e,t,r=!1){for(let o=e;o;o=t=="start"?o.firstChild:o.lastChild){if(o.isTextblock)return!0;if(r&&o.childCount!=1)return!1}return!1}const fve=(e,t,r)=>{let{$head:o,empty:a}=e.selection,i=o;if(!a)return!1;if(o.parent.isTextblock){if(r?!r.endOfTextblock("backward",e):o.parentOffset>0)return!1;i=t2(o)}let l=i&&i.nodeBefore;return!l||!Pe.isSelectable(l)?!1:(t&&t(e.tr.setSelection(Pe.create(e.doc,i.pos-l.nodeSize)).scrollIntoView()),!0)};function t2(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){if(e.index(t)>0)return e.doc.resolve(e.before(t+1));if(e.node(t).type.spec.isolating)break}return null}function Uw(e,t){let{$cursor:r}=e.selection;return!r||(t?!t.endOfTextblock("forward",e):r.parentOffset<r.parent.content.size)?null:r}const pve=(e,t,r)=>{let o=Uw(e,r);if(!o)return!1;let a=n2(o);if(!a)return!1;let i=a.nodeAfter;if(Yw(e,a,t,1))return!0;if(o.parent.content.size==0&&(Gi(i,"start")||Pe.isSelectable(i))){let l=of(e.doc,o.before(),o.after(),Ee.empty);if(l&&l.slice.size<l.to-l.from){if(t){let s=e.tr.step(l);s.setSelection(Gi(i,"start")?Ze.findFrom(s.doc.resolve(s.mapping.map(a.pos)),1):Pe.create(s.doc,s.mapping.map(a.pos))),t(s.scrollIntoView())}return!0}}return i.isAtom&&a.depth==o.depth-1?(t&&t(e.tr.delete(a.pos,a.pos+i.nodeSize).scrollIntoView()),!0):!1},mve=(e,t,r)=>{let{$head:o,empty:a}=e.selection,i=o;if(!a)return!1;if(o.parent.isTextblock){if(r?!r.endOfTextblock("forward",e):o.parentOffset<o.parent.content.size)return!1;i=n2(o)}let l=i&&i.nodeAfter;return!l||!Pe.isSelectable(l)?!1:(t&&t(e.tr.setSelection(Pe.create(e.doc,i.pos)).scrollIntoView()),!0)};function n2(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){let r=e.node(t);if(e.index(t)+1<r.childCount)return e.doc.resolve(e.after(t+1));if(r.type.spec.isolating)break}return null}const hve=(e,t)=>{let r=e.selection,o=r instanceof Pe,a;if(o){if(r.node.isTextblock||!la(e.doc,r.from))return!1;a=r.from}else if(a=rf(e.doc,r.from,-1),a==null)return!1;if(t){let i=e.tr.join(a);o&&i.setSelection(Pe.create(i.doc,a-e.doc.resolve(a).nodeBefore.nodeSize)),t(i.scrollIntoView())}return!0},gve=(e,t)=>{let r=e.selection,o;if(r instanceof Pe){if(r.node.isTextblock||!la(e.doc,r.to))return!1;o=r.to}else if(o=rf(e.doc,r.to,1),o==null)return!1;return t&&t(e.tr.join(o).scrollIntoView()),!0},vve=(e,t)=>{let{$from:r,$to:o}=e.selection,a=r.blockRange(o),i=a&&gl(a);return i==null?!1:(t&&t(e.tr.lift(a,i).scrollIntoView()),!0)},yve=(e,t)=>{let{$head:r,$anchor:o}=e.selection;return!r.parent.type.spec.code||!r.sameParent(o)?!1:(t&&t(e.tr.insertText(`
|
|
56
|
+
`).scrollIntoView()),!0)};function Hw(e){for(let t=0;t<e.edgeCount;t++){let{type:r}=e.edge(t);if(r.isTextblock&&!r.hasRequiredAttrs())return r}return null}const Mve=(e,t)=>{let{$head:r,$anchor:o}=e.selection;if(!r.parent.type.spec.code||!r.sameParent(o))return!1;let a=r.node(-1),i=r.indexAfter(-1),l=Hw(a.contentMatchAt(i));if(!l||!a.canReplaceWith(i,i,l))return!1;if(t){let s=r.after(),c=e.tr.replaceWith(s,s,l.createAndFill());c.setSelection(Ze.near(c.doc.resolve(s),1)),t(c.scrollIntoView())}return!0},bve=(e,t)=>{let r=e.selection,{$from:o,$to:a}=r;if(r instanceof _r||o.parent.inlineContent||a.parent.inlineContent)return!1;let i=Hw(a.parent.contentMatchAt(a.indexAfter()));if(!i||!i.isTextblock)return!1;if(t){let l=(!o.parentOffset&&a.index()<a.parent.childCount?o:a).pos,s=e.tr.insert(l,i.createAndFill());s.setSelection(Ge.create(s.doc,l+1)),t(s.scrollIntoView())}return!0},wve=(e,t)=>{let{$cursor:r}=e.selection;if(!r||r.parent.content.size)return!1;if(r.depth>1&&r.after()!=r.end(-1)){let i=r.before();if(Si(e.doc,i))return t&&t(e.tr.split(i).scrollIntoView()),!0}let o=r.blockRange(),a=o&&gl(o);return a==null?!1:(t&&t(e.tr.lift(o,a).scrollIntoView()),!0)},Nve=(e,t)=>{let{$from:r,to:o}=e.selection,a,i=r.sharedDepth(o);return i==0?!1:(a=r.before(i),t&&t(e.tr.setSelection(Pe.create(e.doc,a))),!0)};function kve(e,t,r){let o=t.nodeBefore,a=t.nodeAfter,i=t.index();return!o||!a||!o.type.compatibleContent(a.type)?!1:!o.content.size&&t.parent.canReplace(i-1,i)?(r&&r(e.tr.delete(t.pos-o.nodeSize,t.pos).scrollIntoView()),!0):!t.parent.canReplace(i,i+1)||!(a.isTextblock||la(e.doc,t.pos))?!1:(r&&r(e.tr.join(t.pos).scrollIntoView()),!0)}function Yw(e,t,r,o){let a=t.nodeBefore,i=t.nodeAfter,l,s,c=a.type.spec.isolating||i.type.spec.isolating;if(!c&&kve(e,t,r))return!0;let u=!c&&t.parent.canReplace(t.index(),t.index()+1);if(u&&(l=(s=a.contentMatchAt(a.childCount)).findWrapping(i.type))&&s.matchType(l[0]||i.type).validEnd){if(r){let h=t.pos+i.nodeSize,m=fe.empty;for(let y=l.length-1;y>=0;y--)m=fe.from(l[y].create(null,m));m=fe.from(a.copy(m));let g=e.tr.step(new Zt(t.pos-1,h,t.pos,h,new Ee(m,1,0),l.length,!0)),v=g.doc.resolve(h+2*l.length);v.nodeAfter&&v.nodeAfter.type==a.type&&la(g.doc,v.pos)&&g.join(v.pos),r(g.scrollIntoView())}return!0}let d=i.type.spec.isolating||o>0&&c?null:Ze.findFrom(t,1),f=d&&d.$from.blockRange(d.$to),p=f&&gl(f);if(p!=null&&p>=t.depth)return r&&r(e.tr.lift(f,p).scrollIntoView()),!0;if(u&&Gi(i,"start",!0)&&Gi(a,"end")){let h=a,m=[];for(;m.push(h),!h.isTextblock;)h=h.lastChild;let g=i,v=1;for(;!g.isTextblock;g=g.firstChild)v++;if(h.canReplace(h.childCount,h.childCount,g.content)){if(r){let y=fe.empty;for(let b=m.length-1;b>=0;b--)y=fe.from(m[b].copy(y));let N=e.tr.step(new Zt(t.pos-m.length,t.pos+i.nodeSize,t.pos+v,t.pos+i.nodeSize-v,new Ee(y,m.length,0),0,!0));r(N.scrollIntoView())}return!0}}return!1}function Qw(e){return function(t,r){let o=t.selection,a=e<0?o.$from:o.$to,i=a.depth;for(;a.node(i).isInline;){if(!i)return!1;i--}return a.node(i).isTextblock?(r&&r(t.tr.setSelection(Ge.create(t.doc,e<0?a.start(i):a.end(i)))),!0):!1}}const xve=Qw(-1),Cve=Qw(1);function Eve(e,t=null){return function(r,o){let{$from:a,$to:i}=r.selection,l=a.blockRange(i),s=l&&Yh(l,e,t);return s?(o&&o(r.tr.wrap(l,s).scrollIntoView()),!0):!1}}function Av(e,t=null){return function(r,o){let a=!1;for(let i=0;i<r.selection.ranges.length&&!a;i++){let{$from:{pos:l},$to:{pos:s}}=r.selection.ranges[i];r.doc.nodesBetween(l,s,(c,u)=>{if(a)return!1;if(!(!c.isTextblock||c.hasMarkup(e,t)))if(c.type==e)a=!0;else{let d=r.doc.resolve(u),f=d.index();a=d.parent.canReplaceWith(f,f+1,e)}})}if(!a)return!1;if(o){let i=r.tr;for(let l=0;l<r.selection.ranges.length;l++){let{$from:{pos:s},$to:{pos:c}}=r.selection.ranges[l];i.setBlockType(s,c,e,t)}o(i.scrollIntoView())}return!0}}typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):typeof os<"u"&&os.platform&&os.platform()=="darwin";function Tve(e,t=null){return function(r,o){let{$from:a,$to:i}=r.selection,l=a.blockRange(i),s=!1,c=l;if(!l)return!1;if(l.depth>=2&&a.node(l.depth-1).type.compatibleContent(e)&&l.startIndex==0){if(a.index(l.depth-1)==0)return!1;let d=r.doc.resolve(l.start-2);c=new _u(d,d,l.depth),l.endIndex<l.parent.childCount&&(l=new _u(a,r.doc.resolve(i.end(l.depth)),l.depth)),s=!0}let u=Yh(c,e,t,l);return u?(o&&o(Dve(r.tr,l,u,s,e).scrollIntoView()),!0):!1}}function Dve(e,t,r,o,a){let i=fe.empty;for(let d=r.length-1;d>=0;d--)i=fe.from(r[d].type.create(r[d].attrs,i));e.step(new Zt(t.start-(o?2:0),t.end,t.start,t.end,new Ee(i,0,0),r.length,!0));let l=0;for(let d=0;d<r.length;d++)r[d].type==a&&(l=d+1);let s=r.length-l,c=t.start+r.length-(o?2:0),u=t.parent;for(let d=t.startIndex,f=t.endIndex,p=!0;d<f;d++,p=!1)!p&&Si(e.doc,c,s)&&(e.split(c,s),c+=2*s),c+=u.child(d).nodeSize;return e}function Sve(e){return function(t,r){let{$from:o,$to:a}=t.selection,i=o.blockRange(a,l=>l.childCount>0&&l.firstChild.type==e);return i?r?o.node(i.depth-1).type==e?_ve(t,r,e,i):Ive(t,r,i):!0:!1}}function _ve(e,t,r,o){let a=e.tr,i=o.end,l=o.$to.end(o.depth);i<l&&(a.step(new Zt(i-1,l,i,l,new Ee(fe.from(r.create(null,o.parent.copy())),1,0),1,!0)),o=new _u(a.doc.resolve(o.$from.pos),a.doc.resolve(l),o.depth));const s=gl(o);if(s==null)return!1;a.lift(o,s);let c=a.mapping.map(i,-1)-1;return la(a.doc,c)&&a.join(c),t(a.scrollIntoView()),!0}function Ive(e,t,r){let o=e.tr,a=r.parent;for(let h=r.end,m=r.endIndex-1,g=r.startIndex;m>g;m--)h-=a.child(m).nodeSize,o.delete(h-1,h+1);let i=o.doc.resolve(r.start),l=i.nodeAfter;if(o.mapping.map(r.end)!=r.start+i.nodeAfter.nodeSize)return!1;let s=r.startIndex==0,c=r.endIndex==a.childCount,u=i.node(-1),d=i.index(-1);if(!u.canReplace(d+(s?0:1),d+1,l.content.append(c?fe.empty:fe.from(a))))return!1;let f=i.pos,p=f+l.nodeSize;return o.step(new Zt(f-(s?1:0),p+(c?1:0),f+1,p-1,new Ee((s?fe.empty:fe.from(a.copy(fe.empty))).append(c?fe.empty:fe.from(a.copy(fe.empty))),s?0:1,c?0:1),s?0:1)),t(o.scrollIntoView()),!0}function Ave(e){return function(t,r){let{$from:o,$to:a}=t.selection,i=o.blockRange(a,u=>u.childCount>0&&u.firstChild.type==e);if(!i)return!1;let l=i.startIndex;if(l==0)return!1;let s=i.parent,c=s.child(l-1);if(c.type!=e)return!1;if(r){let u=c.lastChild&&c.lastChild.type==s.type,d=fe.from(u?e.create():null),f=new Ee(fe.from(e.create(null,fe.from(s.type.create(null,d)))),u?3:1,0),p=i.start,h=i.end;r(t.tr.step(new Zt(p-(u?3:1),h,p,h,f,1,!0)).scrollIntoView())}return!0}}function uf(e){const{state:t,transaction:r}=e;let{selection:o}=r,{doc:a}=r,{storedMarks:i}=r;return{...t,apply:t.apply.bind(t),applyTransaction:t.applyTransaction.bind(t),plugins:t.plugins,schema:t.schema,reconfigure:t.reconfigure.bind(t),toJSON:t.toJSON.bind(t),get storedMarks(){return i},get selection(){return o},get doc(){return a},get tr(){return o=r.selection,a=r.doc,i=r.storedMarks,r}}}class df{constructor(t){this.editor=t.editor,this.rawCommands=this.editor.extensionManager.commands,this.customState=t.state}get hasCustomState(){return!!this.customState}get state(){return this.customState||this.editor.state}get commands(){const{rawCommands:t,editor:r,state:o}=this,{view:a}=r,{tr:i}=o,l=this.buildProps(i);return Object.fromEntries(Object.entries(t).map(([s,c])=>[s,(...d)=>{const f=c(...d)(l);return!i.getMeta("preventDispatch")&&!this.hasCustomState&&a.dispatch(i),f}]))}get chain(){return()=>this.createChain()}get can(){return()=>this.createCan()}createChain(t,r=!0){const{rawCommands:o,editor:a,state:i}=this,{view:l}=a,s=[],c=!!t,u=t||i.tr,d=()=>(!c&&r&&!u.getMeta("preventDispatch")&&!this.hasCustomState&&l.dispatch(u),s.every(p=>p===!0)),f={...Object.fromEntries(Object.entries(o).map(([p,h])=>[p,(...g)=>{const v=this.buildProps(u,r),y=h(...g)(v);return s.push(y),f}])),run:d};return f}createCan(t){const{rawCommands:r,state:o}=this,a=!1,i=t||o.tr,l=this.buildProps(i,a);return{...Object.fromEntries(Object.entries(r).map(([c,u])=>[c,(...d)=>u(...d)({...l,dispatch:void 0})])),chain:()=>this.createChain(i,a)}}buildProps(t,r=!0){const{rawCommands:o,editor:a,state:i}=this,{view:l}=a,s={tr:t,editor:a,view:l,state:uf({state:i,transaction:t}),dispatch:r?()=>{}:void 0,chain:()=>this.createChain(t,r),can:()=>this.createCan(t),get commands(){return Object.fromEntries(Object.entries(o).map(([c,u])=>[c,(...d)=>u(...d)(s)]))}};return s}}class Ove{constructor(){this.callbacks={}}on(t,r){return this.callbacks[t]||(this.callbacks[t]=[]),this.callbacks[t].push(r),this}emit(t,...r){const o=this.callbacks[t];return o&&o.forEach(a=>a.apply(this,r)),this}off(t,r){const o=this.callbacks[t];return o&&(r?this.callbacks[t]=o.filter(a=>a!==r):delete this.callbacks[t]),this}removeAllListeners(){this.callbacks={}}}function Ie(e,t,r){return e.config[t]===void 0&&e.parent?Ie(e.parent,t,r):typeof e.config[t]=="function"?e.config[t].bind({...r,parent:e.parent?Ie(e.parent,t,r):null}):e.config[t]}function ff(e){const t=e.filter(a=>a.type==="extension"),r=e.filter(a=>a.type==="node"),o=e.filter(a=>a.type==="mark");return{baseExtensions:t,nodeExtensions:r,markExtensions:o}}function Ww(e){const t=[],{nodeExtensions:r,markExtensions:o}=ff(e),a=[...r,...o],i={default:null,rendered:!0,renderHTML:null,parseHTML:null,keepOnSplit:!0,isRequired:!1};return e.forEach(l=>{const s={name:l.name,options:l.options,storage:l.storage,extensions:a},c=Ie(l,"addGlobalAttributes",s);if(!c)return;c().forEach(d=>{d.types.forEach(f=>{Object.entries(d.attributes).forEach(([p,h])=>{t.push({type:f,name:p,attribute:{...i,...h}})})})})}),a.forEach(l=>{const s={name:l.name,options:l.options,storage:l.storage},c=Ie(l,"addAttributes",s);if(!c)return;const u=c();Object.entries(u).forEach(([d,f])=>{const p={...i,...f};typeof(p==null?void 0:p.default)=="function"&&(p.default=p.default()),p!=null&&p.isRequired&&(p==null?void 0:p.default)===void 0&&delete p.default,t.push({type:l.name,name:d,attribute:p})})}),t}function en(e,t){if(typeof e=="string"){if(!t.nodes[e])throw Error(`There is no node type named '${e}'. Maybe you forgot to add the extension?`);return t.nodes[e]}return e}function jn(...e){return e.filter(t=>!!t).reduce((t,r)=>{const o={...t};return Object.entries(r).forEach(([a,i])=>{if(!o[a]){o[a]=i;return}if(a==="class"){const s=i?i.split(" "):[],c=o[a]?o[a].split(" "):[],u=s.filter(d=>!c.includes(d));o[a]=[...c,...u].join(" ")}else if(a==="style"){const s=i?i.split(";").map(d=>d.trim()).filter(Boolean):[],c=o[a]?o[a].split(";").map(d=>d.trim()).filter(Boolean):[],u=new Map;c.forEach(d=>{const[f,p]=d.split(":").map(h=>h.trim());u.set(f,p)}),s.forEach(d=>{const[f,p]=d.split(":").map(h=>h.trim());u.set(f,p)}),o[a]=Array.from(u.entries()).map(([d,f])=>`${d}: ${f}`).join("; ")}else o[a]=i}),o},{})}function L0(e,t){return t.filter(r=>r.type===e.type.name).filter(r=>r.attribute.rendered).map(r=>r.attribute.renderHTML?r.attribute.renderHTML(e.attrs)||{}:{[r.name]:e.attrs[r.name]}).reduce((r,o)=>jn(r,o),{})}function qw(e){return typeof e=="function"}function Je(e,t=void 0,...r){return qw(e)?t?e.bind(t)(...r):e(...r):e}function zve(e={}){return Object.keys(e).length===0&&e.constructor===Object}function jve(e){return typeof e!="string"?e:e.match(/^[+-]?(?:\d*\.)?\d+$/)?Number(e):e==="true"?!0:e==="false"?!1:e}function Ov(e,t){return"style"in e?e:{...e,getAttrs:r=>{const o=e.getAttrs?e.getAttrs(r):e.attrs;if(o===!1)return!1;const a=t.reduce((i,l)=>{const s=l.attribute.parseHTML?l.attribute.parseHTML(r):jve(r.getAttribute(l.name));return s==null?i:{...i,[l.name]:s}},{});return{...o,...a}}}}function zv(e){return Object.fromEntries(Object.entries(e).filter(([t,r])=>t==="attrs"&&zve(r)?!1:r!=null))}function Lve(e,t){var r;const o=Ww(e),{nodeExtensions:a,markExtensions:i}=ff(e),l=(r=a.find(u=>Ie(u,"topNode")))===null||r===void 0?void 0:r.name,s=Object.fromEntries(a.map(u=>{const d=o.filter(y=>y.type===u.name),f={name:u.name,options:u.options,storage:u.storage,editor:t},p=e.reduce((y,N)=>{const b=Ie(N,"extendNodeSchema",f);return{...y,...b?b(u):{}}},{}),h=zv({...p,content:Je(Ie(u,"content",f)),marks:Je(Ie(u,"marks",f)),group:Je(Ie(u,"group",f)),inline:Je(Ie(u,"inline",f)),atom:Je(Ie(u,"atom",f)),selectable:Je(Ie(u,"selectable",f)),draggable:Je(Ie(u,"draggable",f)),code:Je(Ie(u,"code",f)),whitespace:Je(Ie(u,"whitespace",f)),defining:Je(Ie(u,"defining",f)),isolating:Je(Ie(u,"isolating",f)),attrs:Object.fromEntries(d.map(y=>{var N;return[y.name,{default:(N=y==null?void 0:y.attribute)===null||N===void 0?void 0:N.default}]}))}),m=Je(Ie(u,"parseHTML",f));m&&(h.parseDOM=m.map(y=>Ov(y,d)));const g=Ie(u,"renderHTML",f);g&&(h.toDOM=y=>g({node:y,HTMLAttributes:L0(y,d)}));const v=Ie(u,"renderText",f);return v&&(h.toText=v),[u.name,h]})),c=Object.fromEntries(i.map(u=>{const d=o.filter(v=>v.type===u.name),f={name:u.name,options:u.options,storage:u.storage,editor:t},p=e.reduce((v,y)=>{const N=Ie(y,"extendMarkSchema",f);return{...v,...N?N(u):{}}},{}),h=zv({...p,inclusive:Je(Ie(u,"inclusive",f)),excludes:Je(Ie(u,"excludes",f)),group:Je(Ie(u,"group",f)),spanning:Je(Ie(u,"spanning",f)),code:Je(Ie(u,"code",f)),attrs:Object.fromEntries(d.map(v=>{var y;return[v.name,{default:(y=v==null?void 0:v.attribute)===null||y===void 0?void 0:y.default}]}))}),m=Je(Ie(u,"parseHTML",f));m&&(h.parseDOM=m.map(v=>Ov(v,d)));const g=Ie(u,"renderHTML",f);return g&&(h.toDOM=v=>g({mark:v,HTMLAttributes:L0(v,d)})),[u.name,h]}));return new U8({topNode:l,nodes:s,marks:c})}function sp(e,t){return t.nodes[e]||t.marks[e]||null}function jv(e,t){return Array.isArray(t)?t.some(r=>(typeof r=="string"?r:r.name)===e.name):t}const Bve=(e,t=500)=>{let r="";const o=e.parentOffset;return e.parent.nodesBetween(Math.max(0,o-t),o,(a,i,l,s)=>{var c,u;const d=((u=(c=a.type.spec).toText)===null||u===void 0?void 0:u.call(c,{node:a,pos:i,parent:l,index:s}))||a.textContent||"%leaf%";r+=a.isAtom&&!a.isText?d:d.slice(0,Math.max(0,o-i))}),r};function r2(e){return Object.prototype.toString.call(e)==="[object RegExp]"}class o2{constructor(t){this.find=t.find,this.handler=t.handler}}const Vve=(e,t)=>{if(r2(t))return t.exec(e);const r=t(e);if(!r)return null;const o=[r.text];return o.index=r.index,o.input=e,o.data=r.data,r.replaceWith&&(r.text.includes(r.replaceWith)||console.warn('[tiptap warn]: "inputRuleMatch.replaceWith" must be part of "inputRuleMatch.text".'),o.push(r.replaceWith)),o};function Ec(e){var t;const{editor:r,from:o,to:a,text:i,rules:l,plugin:s}=e,{view:c}=r;if(c.composing)return!1;const u=c.state.doc.resolve(o);if(u.parent.type.spec.code||!((t=u.nodeBefore||u.nodeAfter)===null||t===void 0)&&t.marks.find(p=>p.type.spec.code))return!1;let d=!1;const f=Bve(u)+i;return l.forEach(p=>{if(d)return;const h=Vve(f,p.find);if(!h)return;const m=c.state.tr,g=uf({state:c.state,transaction:m}),v={from:o-(h[0].length-i.length),to:a},{commands:y,chain:N,can:b}=new df({editor:r,state:g});p.handler({state:g,range:v,match:h,commands:y,chain:N,can:b})===null||!m.steps.length||(m.setMeta(s,{transform:m,from:o,to:a,text:i}),c.dispatch(m),d=!0)}),d}function $ve(e){const{editor:t,rules:r}=e,o=new tn({state:{init(){return null},apply(a,i){const l=a.getMeta(o);if(l)return l;const s=a.getMeta("applyInputRules");return!!s&&setTimeout(()=>{const{from:u,text:d}=s,f=u+d.length;Ec({editor:t,from:u,to:f,text:d,rules:r,plugin:o})}),a.selectionSet||a.docChanged?null:i}},props:{handleTextInput(a,i,l,s){return Ec({editor:t,from:i,to:l,text:s,rules:r,plugin:o})},handleDOMEvents:{compositionend:a=>(setTimeout(()=>{const{$cursor:i}=a.state.selection;i&&Ec({editor:t,from:i.pos,to:i.pos,text:"",rules:r,plugin:o})}),!1)},handleKeyDown(a,i){if(i.key!=="Enter")return!1;const{$cursor:l}=a.state.selection;return l?Ec({editor:t,from:l.pos,to:l.pos,text:`
|
|
57
|
+
`,rules:r,plugin:o}):!1}},isInputRules:!0});return o}function Pve(e){return Object.prototype.toString.call(e).slice(8,-1)}function Tc(e){return Pve(e)!=="Object"?!1:e.constructor===Object&&Object.getPrototypeOf(e)===Object.prototype}function pf(e,t){const r={...e};return Tc(e)&&Tc(t)&&Object.keys(t).forEach(o=>{Tc(t[o])&&Tc(e[o])?r[o]=pf(e[o],t[o]):r[o]=t[o]}),r}class oa{constructor(t={}){this.type="mark",this.name="mark",this.parent=null,this.child=null,this.config={name:this.name,defaultOptions:{}},this.config={...this.config,...t},this.name=this.config.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${this.name}".`),this.options=this.config.defaultOptions,this.config.addOptions&&(this.options=Je(Ie(this,"addOptions",{name:this.name}))),this.storage=Je(Ie(this,"addStorage",{name:this.name,options:this.options}))||{}}static create(t={}){return new oa(t)}configure(t={}){const r=this.extend({...this.config,addOptions:()=>pf(this.options,t)});return r.name=this.name,r.parent=this.parent,r}extend(t={}){const r=new oa(t);return r.parent=this,this.child=r,r.name=t.name?t.name:r.parent.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${r.name}".`),r.options=Je(Ie(r,"addOptions",{name:r.name})),r.storage=Je(Ie(r,"addStorage",{name:r.name,options:r.options})),r}static handleExit({editor:t,mark:r}){const{tr:o}=t.state,a=t.state.selection.$from;if(a.pos===a.end()){const l=a.marks();if(!!!l.find(u=>(u==null?void 0:u.type.name)===r.name))return!1;const c=l.find(u=>(u==null?void 0:u.type.name)===r.name);return c&&o.removeStoredMark(c),o.insertText(" ",a.pos),t.view.dispatch(o),!0}return!1}}function Rve(e){return typeof e=="number"}class Fve{constructor(t){this.find=t.find,this.handler=t.handler}}const Uve=(e,t,r)=>{if(r2(t))return[...e.matchAll(t)];const o=t(e,r);return o?o.map(a=>{const i=[a.text];return i.index=a.index,i.input=e,i.data=a.data,a.replaceWith&&(a.text.includes(a.replaceWith)||console.warn('[tiptap warn]: "pasteRuleMatch.replaceWith" must be part of "pasteRuleMatch.text".'),i.push(a.replaceWith)),i}):[]};function Hve(e){const{editor:t,state:r,from:o,to:a,rule:i,pasteEvent:l,dropEvent:s}=e,{commands:c,chain:u,can:d}=new df({editor:t,state:r}),f=[];return r.doc.nodesBetween(o,a,(h,m)=>{if(!h.isTextblock||h.type.spec.code)return;const g=Math.max(o,m),v=Math.min(a,m+h.content.size),y=h.textBetween(g-m,v-m,void 0,"");Uve(y,i.find,l).forEach(b=>{if(b.index===void 0)return;const M=g+b.index+1,k=M+b[0].length,w={from:r.tr.mapping.map(M),to:r.tr.mapping.map(k)},C=i.handler({state:r,range:w,match:b,commands:c,chain:u,can:d,pasteEvent:l,dropEvent:s});f.push(C)})}),f.every(h=>h!==null)}const Yve=e=>{var t;const r=new ClipboardEvent("paste",{clipboardData:new DataTransfer});return(t=r.clipboardData)===null||t===void 0||t.setData("text/html",e),r};function Qve(e){const{editor:t,rules:r}=e;let o=null,a=!1,i=!1,l=typeof ClipboardEvent<"u"?new ClipboardEvent("paste"):null,s=typeof DragEvent<"u"?new DragEvent("drop"):null;const c=({state:d,from:f,to:p,rule:h,pasteEvt:m})=>{const g=d.tr,v=uf({state:d,transaction:g});if(!(!Hve({editor:t,state:v,from:Math.max(f-1,0),to:p.b-1,rule:h,pasteEvent:m,dropEvent:s})||!g.steps.length))return s=typeof DragEvent<"u"?new DragEvent("drop"):null,l=typeof ClipboardEvent<"u"?new ClipboardEvent("paste"):null,g};return r.map(d=>new tn({view(f){const p=h=>{var m;o=!((m=f.dom.parentElement)===null||m===void 0)&&m.contains(h.target)?f.dom.parentElement:null};return window.addEventListener("dragstart",p),{destroy(){window.removeEventListener("dragstart",p)}}},props:{handleDOMEvents:{drop:(f,p)=>(i=o===f.dom.parentElement,s=p,!1),paste:(f,p)=>{var h;const m=(h=p.clipboardData)===null||h===void 0?void 0:h.getData("text/html");return l=p,a=!!(m!=null&&m.includes("data-pm-slice")),!1}}},appendTransaction:(f,p,h)=>{const m=f[0],g=m.getMeta("uiEvent")==="paste"&&!a,v=m.getMeta("uiEvent")==="drop"&&!i,y=m.getMeta("applyPasteRules"),N=!!y;if(!g&&!v&&!N)return;if(N){const{from:k,text:w}=y,C=k+w.length,E=Yve(w);return c({rule:d,state:h,from:k,to:{b:C},pasteEvt:E})}const b=p.doc.content.findDiffStart(h.doc.content),M=p.doc.content.findDiffEnd(h.doc.content);if(!(!Rve(b)||!M||b===M.b))return c({rule:d,state:h,from:b,to:M,pasteEvt:l})}}))}function Wve(e){const t=e.filter((r,o)=>e.indexOf(r)!==o);return Array.from(new Set(t))}class Ni{constructor(t,r){this.splittableMarks=[],this.editor=r,this.extensions=Ni.resolve(t),this.schema=Lve(this.extensions,r),this.setupExtensions()}static resolve(t){const r=Ni.sort(Ni.flatten(t)),o=Wve(r.map(a=>a.name));return o.length&&console.warn(`[tiptap warn]: Duplicate extension names found: [${o.map(a=>`'${a}'`).join(", ")}]. This can lead to issues.`),r}static flatten(t){return t.map(r=>{const o={name:r.name,options:r.options,storage:r.storage},a=Ie(r,"addExtensions",o);return a?[r,...this.flatten(a())]:r}).flat(10)}static sort(t){return t.sort((o,a)=>{const i=Ie(o,"priority")||100,l=Ie(a,"priority")||100;return i>l?-1:i<l?1:0})}get commands(){return this.extensions.reduce((t,r)=>{const o={name:r.name,options:r.options,storage:r.storage,editor:this.editor,type:sp(r.name,this.schema)},a=Ie(r,"addCommands",o);return a?{...t,...a()}:t},{})}get plugins(){const{editor:t}=this,r=Ni.sort([...this.extensions].reverse()),o=[],a=[],i=r.map(l=>{const s={name:l.name,options:l.options,storage:l.storage,editor:t,type:sp(l.name,this.schema)},c=[],u=Ie(l,"addKeyboardShortcuts",s);let d={};if(l.type==="mark"&&Ie(l,"exitable",s)&&(d.ArrowRight=()=>oa.handleExit({editor:t,mark:l})),u){const g=Object.fromEntries(Object.entries(u()).map(([v,y])=>[v,()=>y({editor:t})]));d={...d,...g}}const f=ive(d);c.push(f);const p=Ie(l,"addInputRules",s);jv(l,t.options.enableInputRules)&&p&&o.push(...p());const h=Ie(l,"addPasteRules",s);jv(l,t.options.enablePasteRules)&&h&&a.push(...h());const m=Ie(l,"addProseMirrorPlugins",s);if(m){const g=m();c.push(...g)}return c}).flat();return[$ve({editor:t,rules:o}),...Qve({editor:t,rules:a}),...i]}get attributes(){return Ww(this.extensions)}get nodeViews(){const{editor:t}=this,{nodeExtensions:r}=ff(this.extensions);return Object.fromEntries(r.filter(o=>!!Ie(o,"addNodeView")).map(o=>{const a=this.attributes.filter(c=>c.type===o.name),i={name:o.name,options:o.options,storage:o.storage,editor:t,type:en(o.name,this.schema)},l=Ie(o,"addNodeView",i);if(!l)return[];const s=(c,u,d,f,p)=>{const h=L0(c,a);return l()({node:c,view:u,getPos:d,decorations:f,innerDecorations:p,editor:t,extension:o,HTMLAttributes:h})};return[o.name,s]}))}setupExtensions(){this.extensions.forEach(t=>{var r;this.editor.extensionStorage[t.name]=t.storage;const o={name:t.name,options:t.options,storage:t.storage,editor:this.editor,type:sp(t.name,this.schema)};t.type==="mark"&&(!((r=Je(Ie(t,"keepOnSplit",o)))!==null&&r!==void 0)||r)&&this.splittableMarks.push(t.name);const a=Ie(t,"onBeforeCreate",o),i=Ie(t,"onCreate",o),l=Ie(t,"onUpdate",o),s=Ie(t,"onSelectionUpdate",o),c=Ie(t,"onTransaction",o),u=Ie(t,"onFocus",o),d=Ie(t,"onBlur",o),f=Ie(t,"onDestroy",o);a&&this.editor.on("beforeCreate",a),i&&this.editor.on("create",i),l&&this.editor.on("update",l),s&&this.editor.on("selectionUpdate",s),c&&this.editor.on("transaction",c),u&&this.editor.on("focus",u),d&&this.editor.on("blur",d),f&&this.editor.on("destroy",f)})}}class hn{constructor(t={}){this.type="extension",this.name="extension",this.parent=null,this.child=null,this.config={name:this.name,defaultOptions:{}},this.config={...this.config,...t},this.name=this.config.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${this.name}".`),this.options=this.config.defaultOptions,this.config.addOptions&&(this.options=Je(Ie(this,"addOptions",{name:this.name}))),this.storage=Je(Ie(this,"addStorage",{name:this.name,options:this.options}))||{}}static create(t={}){return new hn(t)}configure(t={}){const r=this.extend({...this.config,addOptions:()=>pf(this.options,t)});return r.name=this.name,r.parent=this.parent,r}extend(t={}){const r=new hn({...this.config,...t});return r.parent=this,this.child=r,r.name=t.name?t.name:r.parent.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${r.name}".`),r.options=Je(Ie(r,"addOptions",{name:r.name})),r.storage=Je(Ie(r,"addStorage",{name:r.name,options:r.options})),r}}function Gw(e,t,r){const{from:o,to:a}=t,{blockSeparator:i=`
|
|
58
58
|
|
|
59
|
-
`,textSerializers:l={}}=r||{};let s="";return e.nodesBetween(o,a,(c,u,d,f)=>{var p;c.isBlock&&u>o&&(s+=i);const h=l==null?void 0:l[c.type.name];if(h)return d&&(s+=h({node:c,pos:u,parent:d,index:f,range:t})),!1;c.isText&&(s+=(p=c==null?void 0:c.text)===null||p===void 0?void 0:p.slice(Math.max(o,u)-u,a-u))}),s}function Kw(e){return Object.fromEntries(Object.entries(e.nodes).filter(([,t])=>t.spec.toText).map(([t,r])=>[t,r.spec.toText]))}const Hve=hn.create({name:"clipboardTextSerializer",addOptions(){return{blockSeparator:void 0}},addProseMirrorPlugins(){return[new tn({key:new yn("clipboardTextSerializer"),props:{clipboardTextSerializer:()=>{const{editor:e}=this,{state:t,schema:r}=e,{doc:o,selection:a}=t,{ranges:i}=a,l=Math.min(...i.map(d=>d.$from.pos)),s=Math.max(...i.map(d=>d.$to.pos)),c=Kw(r);return Gw(o,{from:l,to:s},{...this.options.blockSeparator!==void 0?{blockSeparator:this.options.blockSeparator}:{},textSerializers:c})}}})]}}),Yve=()=>({editor:e,view:t})=>(requestAnimationFrame(()=>{var r;e.isDestroyed||(t.dom.blur(),(r=window==null?void 0:window.getSelection())===null||r===void 0||r.removeAllRanges())}),!0),Qve=(e=!1)=>({commands:t})=>t.setContent("",e),Wve=()=>({state:e,tr:t,dispatch:r})=>{const{selection:o}=t,{ranges:a}=o;return r&&a.forEach(({$from:i,$to:l})=>{e.doc.nodesBetween(i.pos,l.pos,(s,c)=>{if(s.type.isText)return;const{doc:u,mapping:d}=t,f=u.resolve(d.map(c)),p=u.resolve(d.map(c+s.nodeSize)),h=f.blockRange(p);if(!h)return;const m=gl(h);if(s.type.isTextblock){const{defaultType:g}=f.parent.contentMatchAt(f.index());t.setNodeMarkup(h.start,g)}(m||m===0)&&t.lift(h,m)})}),!0},qve=e=>t=>e(t),Gve=()=>({state:e,dispatch:t})=>gve(e,t),Kve=(e,t)=>({editor:r,tr:o})=>{const{state:a}=r,i=a.doc.slice(e.from,e.to);o.deleteRange(e.from,e.to);const l=o.mapping.map(t);return o.insert(l,i.content),o.setSelection(new Ge(o.doc.resolve(l-1))),!0},Jve=()=>({tr:e,dispatch:t})=>{const{selection:r}=e,o=r.$anchor.node();if(o.content.size>0)return!1;const a=e.selection.$anchor;for(let i=a.depth;i>0;i-=1)if(a.node(i).type===o.type){if(t){const s=a.before(i),c=a.after(i);e.delete(s,c).scrollIntoView()}return!0}return!1},Zve=e=>({tr:t,state:r,dispatch:o})=>{const a=en(e,r.schema),i=t.selection.$anchor;for(let l=i.depth;l>0;l-=1)if(i.node(l).type===a){if(o){const c=i.before(l),u=i.after(l);t.delete(c,u).scrollIntoView()}return!0}return!1},Xve=e=>({tr:t,dispatch:r})=>{const{from:o,to:a}=e;return r&&t.delete(o,a),!0},e3e=()=>({state:e,dispatch:t})=>ove(e,t),t3e=()=>({commands:e})=>e.keyboardShortcut("Enter"),n3e=()=>({state:e,dispatch:t})=>hve(e,t);function Pu(e,t,r={strict:!0}){const o=Object.keys(t);return o.length?o.every(a=>r.strict?t[a]===e[a]:r2(t[a])?t[a].test(e[a]):t[a]===e[a]):!0}function B0(e,t,r={}){return e.find(o=>o.type===t&&Pu(o.attrs,r))}function r3e(e,t,r={}){return!!B0(e,t,r)}function a2(e,t,r={}){if(!e||!t)return;let o=e.parent.childAfter(e.parentOffset);if((!o.node||!o.node.marks.some(u=>u.type===t))&&(o=e.parent.childBefore(e.parentOffset)),!o.node||!o.node.marks.some(u=>u.type===t))return;const a=B0([...o.node.marks],t,r);if(!a)return;let i=o.index,l=e.start()+o.offset,s=i+1,c=l+o.node.nodeSize;for(B0([...o.node.marks],t,r);i>0&&a.isInSet(e.parent.child(i-1).marks);)i-=1,l-=e.parent.child(i).nodeSize;for(;s<e.parent.childCount&&r3e([...e.parent.child(s).marks],t,r);)c+=e.parent.child(s).nodeSize,s+=1;return{from:l,to:c}}function ca(e,t){if(typeof e=="string"){if(!t.marks[e])throw Error(`There is no mark type named '${e}'. Maybe you forgot to add the extension?`);return t.marks[e]}return e}const o3e=(e,t={})=>({tr:r,state:o,dispatch:a})=>{const i=ca(e,o.schema),{doc:l,selection:s}=r,{$from:c,from:u,to:d}=s;if(a){const f=a2(c,i,t);if(f&&f.from<=u&&f.to>=d){const p=Ge.create(l,f.from,f.to);r.setSelection(p)}}return!0},a3e=e=>t=>{const r=typeof e=="function"?e(t):e;for(let o=0;o<r.length;o+=1)if(r[o](t))return!0;return!1};function i2(e){return e instanceof Ge}function go(e=0,t=0,r=0){return Math.min(Math.max(e,t),r)}function Jw(e,t=null){if(!t)return null;const r=Ze.atStart(e),o=Ze.atEnd(e);if(t==="start"||t===!0)return r;if(t==="end")return o;const a=r.from,i=o.to;return t==="all"?Ge.create(e,go(0,a,i),go(e.content.size,a,i)):Ge.create(e,go(t,a,i),go(t,a,i))}function l2(){return["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document}const i3e=(e=null,t={})=>({editor:r,view:o,tr:a,dispatch:i})=>{t={scrollIntoView:!0,...t};const l=()=>{l2()&&o.dom.focus(),requestAnimationFrame(()=>{r.isDestroyed||(o.focus(),t!=null&&t.scrollIntoView&&r.commands.scrollIntoView())})};if(o.hasFocus()&&e===null||e===!1)return!0;if(i&&e===null&&!i2(r.state.selection))return l(),!0;const s=Jw(a.doc,e)||r.state.selection,c=r.state.selection.eq(s);return i&&(c||a.setSelection(s),c&&a.storedMarks&&a.setStoredMarks(a.storedMarks),l()),!0},l3e=(e,t)=>r=>e.every((o,a)=>t(o,{...r,index:a})),s3e=(e,t)=>({tr:r,commands:o})=>o.insertContentAt({from:r.selection.from,to:r.selection.to},e,t),Zw=e=>{const t=e.childNodes;for(let r=t.length-1;r>=0;r-=1){const o=t[r];o.nodeType===3&&o.nodeValue&&/^(\n\s\s|\n)$/.test(o.nodeValue)?e.removeChild(o):o.nodeType===1&&Zw(o)}return e};function Dc(e){const t=`<body>${e}</body>`,r=new window.DOMParser().parseFromString(t,"text/html").body;return Zw(r)}function Ru(e,t,r){r={slice:!0,parseOptions:{},...r};const o=typeof e=="object"&&e!==null,a=typeof e=="string";if(o)try{if(Array.isArray(e)&&e.length>0)return fe.fromArray(e.map(s=>t.nodeFromJSON(s)));const l=t.nodeFromJSON(e);return r.errorOnInvalidContent&&l.check(),l}catch(i){if(r.errorOnInvalidContent)throw new Error("[tiptap error]: Invalid JSON content",{cause:i});return console.warn("[tiptap warn]: Invalid content.","Passed value:",e,"Error:",i),Ru("",t,r)}if(a){if(r.errorOnInvalidContent){let l=!1,s="";const c=new U8({topNode:t.spec.topNode,marks:t.spec.marks,nodes:t.spec.nodes.append({__tiptap__private__unknown__catch__all__node:{content:"inline*",group:"block",parseDOM:[{tag:"*",getAttrs:u=>(l=!0,s=typeof u=="string"?u:u.outerHTML,null)}]}})});if(r.slice?Go.fromSchema(c).parseSlice(Dc(e),r.parseOptions):Go.fromSchema(c).parse(Dc(e),r.parseOptions),r.errorOnInvalidContent&&l)throw new Error("[tiptap error]: Invalid HTML content",{cause:new Error(`Invalid element found: ${s}`)})}const i=Go.fromSchema(t);return r.slice?i.parseSlice(Dc(e),r.parseOptions).content:i.parse(Dc(e),r.parseOptions)}return Ru("",t,r)}function c3e(e,t,r){const o=e.steps.length-1;if(o<t)return;const a=e.steps[o];if(!(a instanceof Kt||a instanceof Zt))return;const i=e.mapping.maps[o];let l=0;i.forEach((s,c,u,d)=>{l===0&&(l=d)}),e.setSelection(Ze.near(e.doc.resolve(l),r))}const u3e=e=>!("type"in e),d3e=(e,t,r)=>({tr:o,dispatch:a,editor:i})=>{var l;if(a){r={parseOptions:i.options.parseOptions,updateSelection:!0,applyInputRules:!1,applyPasteRules:!1,...r};let s;try{s=Ru(t,i.schema,{parseOptions:{preserveWhitespace:"full",...r.parseOptions},errorOnInvalidContent:(l=r.errorOnInvalidContent)!==null&&l!==void 0?l:i.options.enableContentCheck})}catch(m){return i.emit("contentError",{editor:i,error:m,disableCollaboration:()=>{i.storage.collaboration&&(i.storage.collaboration.isDisabled=!0)}}),!1}let{from:c,to:u}=typeof e=="number"?{from:e,to:e}:{from:e.from,to:e.to},d=!0,f=!0;if((u3e(s)?s:[s]).forEach(m=>{m.check(),d=d?m.isText&&m.marks.length===0:!1,f=f?m.isBlock:!1}),c===u&&f){const{parent:m}=o.doc.resolve(c);m.isTextblock&&!m.type.spec.code&&!m.childCount&&(c-=1,u+=1)}let h;d?(Array.isArray(t)?h=t.map(m=>m.text||"").join(""):typeof t=="object"&&t&&t.text?h=t.text:h=t,o.insertText(h,c,u)):(h=s,o.replaceWith(c,u,h)),r.updateSelection&&c3e(o,o.steps.length-1,-1),r.applyInputRules&&o.setMeta("applyInputRules",{from:c,text:h}),r.applyPasteRules&&o.setMeta("applyPasteRules",{from:c,text:h})}return!0},f3e=()=>({state:e,dispatch:t})=>dve(e,t),p3e=()=>({state:e,dispatch:t})=>fve(e,t),m3e=()=>({state:e,dispatch:t})=>ave(e,t),h3e=()=>({state:e,dispatch:t})=>cve(e,t),g3e=()=>({state:e,dispatch:t,tr:r})=>{try{const o=rf(e.doc,e.selection.$from.pos,-1);return o==null?!1:(r.join(o,2),t&&t(r),!0)}catch{return!1}},v3e=()=>({state:e,dispatch:t,tr:r})=>{try{const o=rf(e.doc,e.selection.$from.pos,1);return o==null?!1:(r.join(o,2),t&&t(r),!0)}catch{return!1}},y3e=()=>({state:e,dispatch:t})=>ive(e,t),M3e=()=>({state:e,dispatch:t})=>lve(e,t);function Xw(){return typeof navigator<"u"?/Mac/.test(navigator.platform):!1}function b3e(e){const t=e.split(/-(?!$)/);let r=t[t.length-1];r==="Space"&&(r=" ");let o,a,i,l;for(let s=0;s<t.length-1;s+=1){const c=t[s];if(/^(cmd|meta|m)$/i.test(c))l=!0;else if(/^a(lt)?$/i.test(c))o=!0;else if(/^(c|ctrl|control)$/i.test(c))a=!0;else if(/^s(hift)?$/i.test(c))i=!0;else if(/^mod$/i.test(c))l2()||Xw()?l=!0:a=!0;else throw new Error(`Unrecognized modifier name: ${c}`)}return o&&(r=`Alt-${r}`),a&&(r=`Ctrl-${r}`),l&&(r=`Meta-${r}`),i&&(r=`Shift-${r}`),r}const w3e=e=>({editor:t,view:r,tr:o,dispatch:a})=>{const i=b3e(e).split(/-(?!$)/),l=i.find(u=>!["Alt","Ctrl","Meta","Shift"].includes(u)),s=new KeyboardEvent("keydown",{key:l==="Space"?" ":l,altKey:i.includes("Alt"),ctrlKey:i.includes("Ctrl"),metaKey:i.includes("Meta"),shiftKey:i.includes("Shift"),bubbles:!0,cancelable:!0}),c=t.captureTransaction(()=>{r.someProp("handleKeyDown",u=>u(r,s))});return c==null||c.steps.forEach(u=>{const d=u.map(o.mapping);d&&a&&o.maybeStep(d)}),!0};function Ss(e,t,r={}){const{from:o,to:a,empty:i}=e.selection,l=t?en(t,e.schema):null,s=[];e.doc.nodesBetween(o,a,(f,p)=>{if(f.isText)return;const h=Math.max(o,p),m=Math.min(a,p+f.nodeSize);s.push({node:f,from:h,to:m})});const c=a-o,u=s.filter(f=>l?l.name===f.node.type.name:!0).filter(f=>Pu(f.node.attrs,r,{strict:!1}));return i?!!u.length:u.reduce((f,p)=>f+p.to-p.from,0)>=c}const N3e=(e,t={})=>({state:r,dispatch:o})=>{const a=en(e,r.schema);return Ss(r,a,t)?pve(r,o):!1},k3e=()=>({state:e,dispatch:t})=>vve(e,t),x3e=e=>({state:t,dispatch:r})=>{const o=en(e,t.schema);return Cve(o)(t,r)},C3e=()=>({state:e,dispatch:t})=>mve(e,t);function mf(e,t){return t.nodes[e]?"node":t.marks[e]?"mark":null}function Lv(e,t){const r=typeof t=="string"?[t]:t;return Object.keys(e).reduce((o,a)=>(r.includes(a)||(o[a]=e[a]),o),{})}const E3e=(e,t)=>({tr:r,state:o,dispatch:a})=>{let i=null,l=null;const s=mf(typeof e=="string"?e:e.name,o.schema);return s?(s==="node"&&(i=en(e,o.schema)),s==="mark"&&(l=ca(e,o.schema)),a&&r.selection.ranges.forEach(c=>{o.doc.nodesBetween(c.$from.pos,c.$to.pos,(u,d)=>{i&&i===u.type&&r.setNodeMarkup(d,void 0,Lv(u.attrs,t)),l&&u.marks.length&&u.marks.forEach(f=>{l===f.type&&r.addMark(d,d+u.nodeSize,l.create(Lv(f.attrs,t)))})})}),!0):!1},T3e=()=>({tr:e,dispatch:t})=>(t&&e.scrollIntoView(),!0),D3e=()=>({tr:e,commands:t})=>t.setTextSelection({from:0,to:e.doc.content.size}),S3e=()=>({state:e,dispatch:t})=>sve(e,t),_3e=()=>({state:e,dispatch:t})=>uve(e,t),I3e=()=>({state:e,dispatch:t})=>yve(e,t),A3e=()=>({state:e,dispatch:t})=>wve(e,t),O3e=()=>({state:e,dispatch:t})=>bve(e,t);function V0(e,t,r={},o={}){return Ru(e,t,{slice:!1,parseOptions:r,errorOnInvalidContent:o.errorOnInvalidContent})}const z3e=(e,t=!1,r={},o={})=>({editor:a,tr:i,dispatch:l,commands:s})=>{var c,u;const{doc:d}=i;if(r.preserveWhitespace!=="full"){const f=V0(e,a.schema,r,{errorOnInvalidContent:(c=o.errorOnInvalidContent)!==null&&c!==void 0?c:a.options.enableContentCheck});return l&&i.replaceWith(0,d.content.size,f).setMeta("preventUpdate",!t),!0}return l&&i.setMeta("preventUpdate",!t),s.insertContentAt({from:0,to:d.content.size},e,{parseOptions:r,errorOnInvalidContent:(u=o.errorOnInvalidContent)!==null&&u!==void 0?u:a.options.enableContentCheck})};function eN(e,t){const r=ca(t,e.schema),{from:o,to:a,empty:i}=e.selection,l=[];i?(e.storedMarks&&l.push(...e.storedMarks),l.push(...e.selection.$head.marks())):e.doc.nodesBetween(o,a,c=>{l.push(...c.marks)});const s=l.find(c=>c.type.name===r.name);return s?{...s.attrs}:{}}function j3e(e,t){const r=new ow(e);return t.forEach(o=>{o.steps.forEach(a=>{r.step(a)})}),r}function L3e(e){for(let t=0;t<e.edgeCount;t+=1){const{type:r}=e.edge(t);if(r.isTextblock&&!r.hasRequiredAttrs())return r}return null}function B3e(e,t,r){const o=[];return e.nodesBetween(t.from,t.to,(a,i)=>{r(a)&&o.push({node:a,pos:i})}),o}function V3e(e,t){for(let r=e.depth;r>0;r-=1){const o=e.node(r);if(t(o))return{pos:r>0?e.before(r):0,start:e.start(r),depth:r,node:o}}}function s2(e){return t=>V3e(t.$from,e)}function $3e(e,t){const r=Xa.fromSchema(t).serializeFragment(e),a=document.implementation.createHTMLDocument().createElement("div");return a.appendChild(r),a.innerHTML}function P3e(e,t){const r={from:0,to:e.content.size};return Gw(e,r,t)}function R3e(e,t){const r=en(t,e.schema),{from:o,to:a}=e.selection,i=[];e.doc.nodesBetween(o,a,s=>{i.push(s)});const l=i.reverse().find(s=>s.type.name===r.name);return l?{...l.attrs}:{}}function tN(e,t){const r=mf(typeof t=="string"?t:t.name,e.schema);return r==="node"?R3e(e,t):r==="mark"?eN(e,t):{}}function F3e(e,t=JSON.stringify){const r={};return e.filter(o=>{const a=t(o);return Object.prototype.hasOwnProperty.call(r,a)?!1:r[a]=!0})}function U3e(e){const t=F3e(e);return t.length===1?t:t.filter((r,o)=>!t.filter((i,l)=>l!==o).some(i=>r.oldRange.from>=i.oldRange.from&&r.oldRange.to<=i.oldRange.to&&r.newRange.from>=i.newRange.from&&r.newRange.to<=i.newRange.to))}function H3e(e){const{mapping:t,steps:r}=e,o=[];return t.maps.forEach((a,i)=>{const l=[];if(a.ranges.length)a.forEach((s,c)=>{l.push({from:s,to:c})});else{const{from:s,to:c}=r[i];if(s===void 0||c===void 0)return;l.push({from:s,to:c})}l.forEach(({from:s,to:c})=>{const u=t.slice(i).map(s,-1),d=t.slice(i).map(c),f=t.invert().map(u,-1),p=t.invert().map(d);o.push({oldRange:{from:f,to:p},newRange:{from:u,to:d}})})}),U3e(o)}function c2(e,t,r){const o=[];return e===t?r.resolve(e).marks().forEach(a=>{const i=r.resolve(e),l=a2(i,a.type);l&&o.push({mark:a,...l})}):r.nodesBetween(e,t,(a,i)=>{!a||(a==null?void 0:a.nodeSize)===void 0||o.push(...a.marks.map(l=>({from:i,to:i+a.nodeSize,mark:l})))}),o}function Gc(e,t,r){return Object.fromEntries(Object.entries(r).filter(([o])=>{const a=e.find(i=>i.type===t&&i.name===o);return a?a.attribute.keepOnSplit:!1}))}function $0(e,t,r={}){const{empty:o,ranges:a}=e.selection,i=t?ca(t,e.schema):null;if(o)return!!(e.storedMarks||e.selection.$from.marks()).filter(f=>i?i.name===f.type.name:!0).find(f=>Pu(f.attrs,r,{strict:!1}));let l=0;const s=[];if(a.forEach(({$from:f,$to:p})=>{const h=f.pos,m=p.pos;e.doc.nodesBetween(h,m,(g,v)=>{if(!g.isText&&!g.marks.length)return;const y=Math.max(h,v),N=Math.min(m,v+g.nodeSize),b=N-y;l+=b,s.push(...g.marks.map(M=>({mark:M,from:y,to:N})))})}),l===0)return!1;const c=s.filter(f=>i?i.name===f.mark.type.name:!0).filter(f=>Pu(f.mark.attrs,r,{strict:!1})).reduce((f,p)=>f+p.to-p.from,0),u=s.filter(f=>i?f.mark.type!==i&&f.mark.type.excludes(i):!0).reduce((f,p)=>f+p.to-p.from,0);return(c>0?c+u:c)>=l}function Y3e(e,t,r={}){if(!t)return Ss(e,null,r)||$0(e,null,r);const o=mf(t,e.schema);return o==="node"?Ss(e,t,r):o==="mark"?$0(e,t,r):!1}function Bv(e,t){const{nodeExtensions:r}=ff(t),o=r.find(l=>l.name===e);if(!o)return!1;const a={name:o.name,options:o.options,storage:o.storage},i=Je(Ie(o,"group",a));return typeof i!="string"?!1:i.split(" ").includes("list")}function hf(e,{checkChildren:t=!0,ignoreWhitespace:r=!1}={}){var o;if(r){if(e.type.name==="hardBreak")return!0;if(e.isText)return/^\s*$/m.test((o=e.text)!==null&&o!==void 0?o:"")}if(e.isText)return!e.text;if(e.isAtom||e.isLeaf)return!1;if(e.content.childCount===0)return!0;if(t){let a=!0;return e.content.forEach(i=>{a!==!1&&(hf(i,{ignoreWhitespace:r,checkChildren:t})||(a=!1))}),a}return!1}function Q3e(e){return e instanceof Pe}function nN(e,t,r){const a=e.state.doc.content.size,i=go(t,0,a),l=go(r,0,a),s=e.coordsAtPos(i),c=e.coordsAtPos(l,-1),u=Math.min(s.top,c.top),d=Math.max(s.bottom,c.bottom),f=Math.min(s.left,c.left),p=Math.max(s.right,c.right),h=p-f,m=d-u,y={top:u,bottom:d,left:f,right:p,width:h,height:m,x:f,y:u};return{...y,toJSON:()=>y}}function W3e(e,t,r){var o;const{selection:a}=t;let i=null;if(i2(a)&&(i=a.$cursor),i){const s=(o=e.storedMarks)!==null&&o!==void 0?o:i.marks();return!!r.isInSet(s)||!s.some(c=>c.type.excludes(r))}const{ranges:l}=a;return l.some(({$from:s,$to:c})=>{let u=s.depth===0?e.doc.inlineContent&&e.doc.type.allowsMarkType(r):!1;return e.doc.nodesBetween(s.pos,c.pos,(d,f,p)=>{if(u)return!1;if(d.isInline){const h=!p||p.type.allowsMarkType(r),m=!!r.isInSet(d.marks)||!d.marks.some(g=>g.type.excludes(r));u=h&&m}return!u}),u})}const q3e=(e,t={})=>({tr:r,state:o,dispatch:a})=>{const{selection:i}=r,{empty:l,ranges:s}=i,c=ca(e,o.schema);if(a)if(l){const u=eN(o,c);r.addStoredMark(c.create({...u,...t}))}else s.forEach(u=>{const d=u.$from.pos,f=u.$to.pos;o.doc.nodesBetween(d,f,(p,h)=>{const m=Math.max(h,d),g=Math.min(h+p.nodeSize,f);p.marks.find(y=>y.type===c)?p.marks.forEach(y=>{c===y.type&&r.addMark(m,g,c.create({...y.attrs,...t}))}):r.addMark(m,g,c.create(t))})});return W3e(o,r,c)},G3e=(e,t)=>({tr:r})=>(r.setMeta(e,t),!0),K3e=(e,t={})=>({state:r,dispatch:o,chain:a})=>{const i=en(e,r.schema);return i.isTextblock?a().command(({commands:l})=>Av(i,t)(r)?!0:l.clearNodes()).command(({state:l})=>Av(i,t)(l,o)).run():(console.warn('[tiptap warn]: Currently "setNode()" only supports text block nodes.'),!1)},J3e=e=>({tr:t,dispatch:r})=>{if(r){const{doc:o}=t,a=go(e,0,o.content.size),i=Pe.create(o,a);t.setSelection(i)}return!0},Z3e=e=>({tr:t,dispatch:r})=>{if(r){const{doc:o}=t,{from:a,to:i}=typeof e=="number"?{from:e,to:e}:e,l=Ge.atStart(o).from,s=Ge.atEnd(o).to,c=go(a,l,s),u=go(i,l,s),d=Ge.create(o,c,u);t.setSelection(d)}return!0},X3e=e=>({state:t,dispatch:r})=>{const o=en(e,t.schema);return Dve(o)(t,r)};function Vv(e,t){const r=e.storedMarks||e.selection.$to.parentOffset&&e.selection.$from.marks();if(r){const o=r.filter(a=>t==null?void 0:t.includes(a.type.name));e.tr.ensureMarks(o)}}const eye=({keepMarks:e=!0}={})=>({tr:t,state:r,dispatch:o,editor:a})=>{const{selection:i,doc:l}=t,{$from:s,$to:c}=i,u=a.extensionManager.attributes,d=Gc(u,s.node().type.name,s.node().attrs);if(i instanceof Pe&&i.node.isBlock)return!s.parentOffset||!Si(l,s.pos)?!1:(o&&(e&&Vv(r,a.extensionManager.splittableMarks),t.split(s.pos).scrollIntoView()),!0);if(!s.parent.isBlock)return!1;const f=c.parentOffset===c.parent.content.size,p=s.depth===0?void 0:L3e(s.node(-1).contentMatchAt(s.indexAfter(-1)));let h=f&&p?[{type:p,attrs:d}]:void 0,m=Si(t.doc,t.mapping.map(s.pos),1,h);if(!h&&!m&&Si(t.doc,t.mapping.map(s.pos),1,p?[{type:p}]:void 0)&&(m=!0,h=p?[{type:p,attrs:d}]:void 0),o){if(m&&(i instanceof Ge&&t.deleteSelection(),t.split(t.mapping.map(s.pos),1,h),p&&!f&&!s.parentOffset&&s.parent.type!==p)){const g=t.mapping.map(s.before()),v=t.doc.resolve(g);s.node(-1).canReplaceWith(v.index(),v.index()+1,p)&&t.setNodeMarkup(t.mapping.map(s.before()),p)}e&&Vv(r,a.extensionManager.splittableMarks),t.scrollIntoView()}return m},tye=(e,t={})=>({tr:r,state:o,dispatch:a,editor:i})=>{var l;const s=en(e,o.schema),{$from:c,$to:u}=o.selection,d=o.selection.node;if(d&&d.isBlock||c.depth<2||!c.sameParent(u))return!1;const f=c.node(-1);if(f.type!==s)return!1;const p=i.extensionManager.attributes;if(c.parent.content.size===0&&c.node(-1).childCount===c.indexAfter(-1)){if(c.depth===2||c.node(-3).type!==s||c.index(-2)!==c.node(-2).childCount-1)return!1;if(a){let y=fe.empty;const N=c.index(-1)?1:c.index(-2)?2:3;for(let E=c.depth-N;E>=c.depth-3;E-=1)y=fe.from(c.node(E).copy(y));const b=c.indexAfter(-1)<c.node(-2).childCount?1:c.indexAfter(-2)<c.node(-3).childCount?2:3,M={...Gc(p,c.node().type.name,c.node().attrs),...t},k=((l=s.contentMatch.defaultType)===null||l===void 0?void 0:l.createAndFill(M))||void 0;y=y.append(fe.from(s.createAndFill(null,k)||void 0));const w=c.before(c.depth-(N-1));r.replace(w,c.after(-b),new Ee(y,4-N,0));let C=-1;r.doc.nodesBetween(w,r.doc.content.size,(E,A)=>{if(C>-1)return!1;E.isTextblock&&E.content.size===0&&(C=A+1)}),C>-1&&r.setSelection(Ge.near(r.doc.resolve(C))),r.scrollIntoView()}return!0}const h=u.pos===c.end()?f.contentMatchAt(0).defaultType:null,m={...Gc(p,f.type.name,f.attrs),...t},g={...Gc(p,c.node().type.name,c.node().attrs),...t};r.delete(c.pos,u.pos);const v=h?[{type:s,attrs:m},{type:h,attrs:g}]:[{type:s,attrs:m}];if(!Si(r.doc,c.pos,2))return!1;if(a){const{selection:y,storedMarks:N}=o,{splittableMarks:b}=i.extensionManager,M=N||y.$to.parentOffset&&y.$from.marks();if(r.split(c.pos,2,v).scrollIntoView(),!M||!a)return!0;const k=M.filter(w=>b.includes(w.type.name));r.ensureMarks(k)}return!0},cp=(e,t)=>{const r=s2(l=>l.type===t)(e.selection);if(!r)return!0;const o=e.doc.resolve(Math.max(0,r.pos-1)).before(r.depth);if(o===void 0)return!0;const a=e.doc.nodeAt(o);return r.node.type===(a==null?void 0:a.type)&&la(e.doc,r.pos)&&e.join(r.pos),!0},up=(e,t)=>{const r=s2(l=>l.type===t)(e.selection);if(!r)return!0;const o=e.doc.resolve(r.start).after(r.depth);if(o===void 0)return!0;const a=e.doc.nodeAt(o);return r.node.type===(a==null?void 0:a.type)&&la(e.doc,o)&&e.join(o),!0},nye=(e,t,r,o={})=>({editor:a,tr:i,state:l,dispatch:s,chain:c,commands:u,can:d})=>{const{extensions:f,splittableMarks:p}=a.extensionManager,h=en(e,l.schema),m=en(t,l.schema),{selection:g,storedMarks:v}=l,{$from:y,$to:N}=g,b=y.blockRange(N),M=v||g.$to.parentOffset&&g.$from.marks();if(!b)return!1;const k=s2(w=>Bv(w.type.name,f))(g);if(b.depth>=1&&k&&b.depth-k.depth<=1){if(k.node.type===h)return u.liftListItem(m);if(Bv(k.node.type.name,f)&&h.validContent(k.node.content)&&s)return c().command(()=>(i.setNodeMarkup(k.pos,h),!0)).command(()=>cp(i,h)).command(()=>up(i,h)).run()}return!r||!M||!s?c().command(()=>d().wrapInList(h,o)?!0:u.clearNodes()).wrapInList(h,o).command(()=>cp(i,h)).command(()=>up(i,h)).run():c().command(()=>{const w=d().wrapInList(h,o),C=M.filter(E=>p.includes(E.type.name));return i.ensureMarks(C),w?!0:u.clearNodes()}).wrapInList(h,o).command(()=>cp(i,h)).command(()=>up(i,h)).run()},rye=(e,t={},r={})=>({state:o,commands:a})=>{const{extendEmptyMarkRange:i=!1}=r,l=ca(e,o.schema);return $0(o,l,t)?a.unsetMark(l,{extendEmptyMarkRange:i}):a.setMark(l,t)},oye=(e,t,r={})=>({state:o,commands:a})=>{const i=en(e,o.schema),l=en(t,o.schema),s=Ss(o,i,r);let c;return o.selection.$anchor.sameParent(o.selection.$head)&&(c=o.selection.$anchor.parent.attrs),s?a.setNode(l,c):a.setNode(i,{...c,...r})},aye=(e,t={})=>({state:r,commands:o})=>{const a=en(e,r.schema);return Ss(r,a,t)?o.lift(a):o.wrapIn(a,t)},iye=()=>({state:e,dispatch:t})=>{const r=e.plugins;for(let o=0;o<r.length;o+=1){const a=r[o];let i;if(a.spec.isInputRules&&(i=a.getState(e))){if(t){const l=e.tr,s=i.transform;for(let c=s.steps.length-1;c>=0;c-=1)l.step(s.steps[c].invert(s.docs[c]));if(i.text){const c=l.doc.resolve(i.from).marks();l.replaceWith(i.from,i.to,e.schema.text(i.text,c))}else l.delete(i.from,i.to)}return!0}}return!1},lye=()=>({tr:e,dispatch:t})=>{const{selection:r}=e,{empty:o,ranges:a}=r;return o||t&&a.forEach(i=>{e.removeMark(i.$from.pos,i.$to.pos)}),!0},sye=(e,t={})=>({tr:r,state:o,dispatch:a})=>{var i;const{extendEmptyMarkRange:l=!1}=t,{selection:s}=r,c=ca(e,o.schema),{$from:u,empty:d,ranges:f}=s;if(!a)return!0;if(d&&l){let{from:p,to:h}=s;const m=(i=u.marks().find(v=>v.type===c))===null||i===void 0?void 0:i.attrs,g=a2(u,c,m);g&&(p=g.from,h=g.to),r.removeMark(p,h,c)}else f.forEach(p=>{r.removeMark(p.$from.pos,p.$to.pos,c)});return r.removeStoredMark(c),!0},cye=(e,t={})=>({tr:r,state:o,dispatch:a})=>{let i=null,l=null;const s=mf(typeof e=="string"?e:e.name,o.schema);return s?(s==="node"&&(i=en(e,o.schema)),s==="mark"&&(l=ca(e,o.schema)),a&&r.selection.ranges.forEach(c=>{const u=c.$from.pos,d=c.$to.pos;o.doc.nodesBetween(u,d,(f,p)=>{i&&i===f.type&&r.setNodeMarkup(p,void 0,{...f.attrs,...t}),l&&f.marks.length&&f.marks.forEach(h=>{if(l===h.type){const m=Math.max(p,u),g=Math.min(p+f.nodeSize,d);r.addMark(m,g,l.create({...h.attrs,...t}))}})})}),!0):!1},uye=(e,t={})=>({state:r,dispatch:o})=>{const a=en(e,r.schema);return Nve(a,t)(r,o)},dye=(e,t={})=>({state:r,dispatch:o})=>{const a=en(e,r.schema);return kve(a,t)(r,o)};var fye=Object.freeze({__proto__:null,blur:Yve,clearContent:Qve,clearNodes:Wve,command:qve,createParagraphNear:Gve,cut:Kve,deleteCurrentNode:Jve,deleteNode:Zve,deleteRange:Xve,deleteSelection:e3e,enter:t3e,exitCode:n3e,extendMarkRange:o3e,first:a3e,focus:i3e,forEach:l3e,insertContent:s3e,insertContentAt:d3e,joinBackward:m3e,joinDown:p3e,joinForward:h3e,joinItemBackward:g3e,joinItemForward:v3e,joinTextblockBackward:y3e,joinTextblockForward:M3e,joinUp:f3e,keyboardShortcut:w3e,lift:N3e,liftEmptyBlock:k3e,liftListItem:x3e,newlineInCode:C3e,resetAttributes:E3e,scrollIntoView:T3e,selectAll:D3e,selectNodeBackward:S3e,selectNodeForward:_3e,selectParentNode:I3e,selectTextblockEnd:A3e,selectTextblockStart:O3e,setContent:z3e,setMark:q3e,setMeta:G3e,setNode:K3e,setNodeSelection:J3e,setTextSelection:Z3e,sinkListItem:X3e,splitBlock:eye,splitListItem:tye,toggleList:nye,toggleMark:rye,toggleNode:oye,toggleWrap:aye,undoInputRule:iye,unsetAllMarks:lye,unsetMark:sye,updateAttributes:cye,wrapIn:uye,wrapInList:dye});const pye=hn.create({name:"commands",addCommands(){return{...fye}}}),mye=hn.create({name:"drop",addProseMirrorPlugins(){return[new tn({key:new yn("tiptapDrop"),props:{handleDrop:(e,t,r,o)=>{this.editor.emit("drop",{editor:this.editor,event:t,slice:r,moved:o})}}})]}}),hye=hn.create({name:"editable",addProseMirrorPlugins(){return[new tn({key:new yn("editable"),props:{editable:()=>this.editor.options.editable}})]}}),gye=hn.create({name:"focusEvents",addProseMirrorPlugins(){const{editor:e}=this;return[new tn({key:new yn("focusEvents"),props:{handleDOMEvents:{focus:(t,r)=>{e.isFocused=!0;const o=e.state.tr.setMeta("focus",{event:r}).setMeta("addToHistory",!1);return t.dispatch(o),!1},blur:(t,r)=>{e.isFocused=!1;const o=e.state.tr.setMeta("blur",{event:r}).setMeta("addToHistory",!1);return t.dispatch(o),!1}}}})]}}),vye=hn.create({name:"keymap",addKeyboardShortcuts(){const e=()=>this.editor.commands.first(({commands:l})=>[()=>l.undoInputRule(),()=>l.command(({tr:s})=>{const{selection:c,doc:u}=s,{empty:d,$anchor:f}=c,{pos:p,parent:h}=f,m=f.parent.isTextblock&&p>0?s.doc.resolve(p-1):f,g=m.parent.type.spec.isolating,v=f.pos-f.parentOffset,y=g&&m.parent.childCount===1?v===f.pos:Ze.atStart(u).from===p;return!d||!h.type.isTextblock||h.textContent.length||!y||y&&f.parent.type.name==="paragraph"?!1:l.clearNodes()}),()=>l.deleteSelection(),()=>l.joinBackward(),()=>l.selectNodeBackward()]),t=()=>this.editor.commands.first(({commands:l})=>[()=>l.deleteSelection(),()=>l.deleteCurrentNode(),()=>l.joinForward(),()=>l.selectNodeForward()]),o={Enter:()=>this.editor.commands.first(({commands:l})=>[()=>l.newlineInCode(),()=>l.createParagraphNear(),()=>l.liftEmptyBlock(),()=>l.splitBlock()]),"Mod-Enter":()=>this.editor.commands.exitCode(),Backspace:e,"Mod-Backspace":e,"Shift-Backspace":e,Delete:t,"Mod-Delete":t,"Mod-a":()=>this.editor.commands.selectAll()},a={...o},i={...o,"Ctrl-h":e,"Alt-Backspace":e,"Ctrl-d":t,"Ctrl-Alt-Backspace":t,"Alt-Delete":t,"Alt-d":t,"Ctrl-a":()=>this.editor.commands.selectTextblockStart(),"Ctrl-e":()=>this.editor.commands.selectTextblockEnd()};return l2()||Xw()?i:a},addProseMirrorPlugins(){return[new tn({key:new yn("clearDocument"),appendTransaction:(e,t,r)=>{const o=e.some(g=>g.docChanged)&&!t.doc.eq(r.doc),a=e.some(g=>g.getMeta("preventClearDocument"));if(!o||a)return;const{empty:i,from:l,to:s}=t.selection,c=Ze.atStart(t.doc).from,u=Ze.atEnd(t.doc).to;if(i||!(l===c&&s===u)||!hf(r.doc))return;const p=r.tr,h=uf({state:r,transaction:p}),{commands:m}=new df({editor:this.editor,state:h});if(m.clearNodes(),!!p.steps.length)return p}})]}}),yye=hn.create({name:"paste",addProseMirrorPlugins(){return[new tn({key:new yn("tiptapPaste"),props:{handlePaste:(e,t,r)=>{this.editor.emit("paste",{editor:this.editor,event:t,slice:r})}}})]}}),Mye=hn.create({name:"tabindex",addProseMirrorPlugins(){return[new tn({key:new yn("tabindex"),props:{attributes:()=>this.editor.isEditable?{tabindex:"0"}:{}}})]}});class ba{get name(){return this.node.type.name}constructor(t,r,o=!1,a=null){this.currentNode=null,this.actualDepth=null,this.isBlock=o,this.resolvedPos=t,this.editor=r,this.currentNode=a}get node(){return this.currentNode||this.resolvedPos.node()}get element(){return this.editor.view.domAtPos(this.pos).node}get depth(){var t;return(t=this.actualDepth)!==null&&t!==void 0?t:this.resolvedPos.depth}get pos(){return this.resolvedPos.pos}get content(){return this.node.content}set content(t){let r=this.from,o=this.to;if(this.isBlock){if(this.content.size===0){console.error(`You can’t set content on a block node. Tried to set content on ${this.name} at ${this.pos}`);return}r=this.from+1,o=this.to-1}this.editor.commands.insertContentAt({from:r,to:o},t)}get attributes(){return this.node.attrs}get textContent(){return this.node.textContent}get size(){return this.node.nodeSize}get from(){return this.isBlock?this.pos:this.resolvedPos.start(this.resolvedPos.depth)}get range(){return{from:this.from,to:this.to}}get to(){return this.isBlock?this.pos+this.size:this.resolvedPos.end(this.resolvedPos.depth)+(this.node.isText?0:1)}get parent(){if(this.depth===0)return null;const t=this.resolvedPos.start(this.resolvedPos.depth-1),r=this.resolvedPos.doc.resolve(t);return new ba(r,this.editor)}get before(){let t=this.resolvedPos.doc.resolve(this.from-(this.isBlock?1:2));return t.depth!==this.depth&&(t=this.resolvedPos.doc.resolve(this.from-3)),new ba(t,this.editor)}get after(){let t=this.resolvedPos.doc.resolve(this.to+(this.isBlock?2:1));return t.depth!==this.depth&&(t=this.resolvedPos.doc.resolve(this.to+3)),new ba(t,this.editor)}get children(){const t=[];return this.node.content.forEach((r,o)=>{const a=r.isBlock&&!r.isTextblock,i=r.isAtom&&!r.isText,l=this.pos+o+(i?0:1),s=this.resolvedPos.doc.resolve(l);if(!a&&s.depth<=this.depth)return;const c=new ba(s,this.editor,a,a?r:null);a&&(c.actualDepth=this.depth+1),t.push(new ba(s,this.editor,a,a?r:null))}),t}get firstChild(){return this.children[0]||null}get lastChild(){const t=this.children;return t[t.length-1]||null}closest(t,r={}){let o=null,a=this.parent;for(;a&&!o;){if(a.node.type.name===t)if(Object.keys(r).length>0){const i=a.node.attrs,l=Object.keys(r);for(let s=0;s<l.length;s+=1){const c=l[s];if(i[c]!==r[c])break}}else o=a;a=a.parent}return o}querySelector(t,r={}){return this.querySelectorAll(t,r,!0)[0]||null}querySelectorAll(t,r={},o=!1){let a=[];if(!this.children||this.children.length===0)return a;const i=Object.keys(r);return this.children.forEach(l=>{o&&a.length>0||(l.node.type.name===t&&i.every(c=>r[c]===l.node.attrs[c])&&a.push(l),!(o&&a.length>0)&&(a=a.concat(l.querySelectorAll(t,r,o))))}),a}setAttribute(t){const{tr:r}=this.editor.state;r.setNodeMarkup(this.from,void 0,{...this.node.attrs,...t}),this.editor.view.dispatch(r)}}const bye=`.ProseMirror {
|
|
59
|
+
`,textSerializers:l={}}=r||{};let s="";return e.nodesBetween(o,a,(c,u,d,f)=>{var p;c.isBlock&&u>o&&(s+=i);const h=l==null?void 0:l[c.type.name];if(h)return d&&(s+=h({node:c,pos:u,parent:d,index:f,range:t})),!1;c.isText&&(s+=(p=c==null?void 0:c.text)===null||p===void 0?void 0:p.slice(Math.max(o,u)-u,a-u))}),s}function Kw(e){return Object.fromEntries(Object.entries(e.nodes).filter(([,t])=>t.spec.toText).map(([t,r])=>[t,r.spec.toText]))}const qve=hn.create({name:"clipboardTextSerializer",addOptions(){return{blockSeparator:void 0}},addProseMirrorPlugins(){return[new tn({key:new yn("clipboardTextSerializer"),props:{clipboardTextSerializer:()=>{const{editor:e}=this,{state:t,schema:r}=e,{doc:o,selection:a}=t,{ranges:i}=a,l=Math.min(...i.map(d=>d.$from.pos)),s=Math.max(...i.map(d=>d.$to.pos)),c=Kw(r);return Gw(o,{from:l,to:s},{...this.options.blockSeparator!==void 0?{blockSeparator:this.options.blockSeparator}:{},textSerializers:c})}}})]}}),Gve=()=>({editor:e,view:t})=>(requestAnimationFrame(()=>{var r;e.isDestroyed||(t.dom.blur(),(r=window==null?void 0:window.getSelection())===null||r===void 0||r.removeAllRanges())}),!0),Kve=(e=!1)=>({commands:t})=>t.setContent("",e),Jve=()=>({state:e,tr:t,dispatch:r})=>{const{selection:o}=t,{ranges:a}=o;return r&&a.forEach(({$from:i,$to:l})=>{e.doc.nodesBetween(i.pos,l.pos,(s,c)=>{if(s.type.isText)return;const{doc:u,mapping:d}=t,f=u.resolve(d.map(c)),p=u.resolve(d.map(c+s.nodeSize)),h=f.blockRange(p);if(!h)return;const m=gl(h);if(s.type.isTextblock){const{defaultType:g}=f.parent.contentMatchAt(f.index());t.setNodeMarkup(h.start,g)}(m||m===0)&&t.lift(h,m)})}),!0},Zve=e=>t=>e(t),Xve=()=>({state:e,dispatch:t})=>bve(e,t),e3e=(e,t)=>({editor:r,tr:o})=>{const{state:a}=r,i=a.doc.slice(e.from,e.to);o.deleteRange(e.from,e.to);const l=o.mapping.map(t);return o.insert(l,i.content),o.setSelection(new Ge(o.doc.resolve(l-1))),!0},t3e=()=>({tr:e,dispatch:t})=>{const{selection:r}=e,o=r.$anchor.node();if(o.content.size>0)return!1;const a=e.selection.$anchor;for(let i=a.depth;i>0;i-=1)if(a.node(i).type===o.type){if(t){const s=a.before(i),c=a.after(i);e.delete(s,c).scrollIntoView()}return!0}return!1},n3e=e=>({tr:t,state:r,dispatch:o})=>{const a=en(e,r.schema),i=t.selection.$anchor;for(let l=i.depth;l>0;l-=1)if(i.node(l).type===a){if(o){const c=i.before(l),u=i.after(l);t.delete(c,u).scrollIntoView()}return!0}return!1},r3e=e=>({tr:t,dispatch:r})=>{const{from:o,to:a}=e;return r&&t.delete(o,a),!0},o3e=()=>({state:e,dispatch:t})=>sve(e,t),a3e=()=>({commands:e})=>e.keyboardShortcut("Enter"),i3e=()=>({state:e,dispatch:t})=>Mve(e,t);function Pu(e,t,r={strict:!0}){const o=Object.keys(t);return o.length?o.every(a=>r.strict?t[a]===e[a]:r2(t[a])?t[a].test(e[a]):t[a]===e[a]):!0}function B0(e,t,r={}){return e.find(o=>o.type===t&&Pu(o.attrs,r))}function l3e(e,t,r={}){return!!B0(e,t,r)}function a2(e,t,r={}){if(!e||!t)return;let o=e.parent.childAfter(e.parentOffset);if((!o.node||!o.node.marks.some(u=>u.type===t))&&(o=e.parent.childBefore(e.parentOffset)),!o.node||!o.node.marks.some(u=>u.type===t))return;const a=B0([...o.node.marks],t,r);if(!a)return;let i=o.index,l=e.start()+o.offset,s=i+1,c=l+o.node.nodeSize;for(B0([...o.node.marks],t,r);i>0&&a.isInSet(e.parent.child(i-1).marks);)i-=1,l-=e.parent.child(i).nodeSize;for(;s<e.parent.childCount&&l3e([...e.parent.child(s).marks],t,r);)c+=e.parent.child(s).nodeSize,s+=1;return{from:l,to:c}}function ca(e,t){if(typeof e=="string"){if(!t.marks[e])throw Error(`There is no mark type named '${e}'. Maybe you forgot to add the extension?`);return t.marks[e]}return e}const s3e=(e,t={})=>({tr:r,state:o,dispatch:a})=>{const i=ca(e,o.schema),{doc:l,selection:s}=r,{$from:c,from:u,to:d}=s;if(a){const f=a2(c,i,t);if(f&&f.from<=u&&f.to>=d){const p=Ge.create(l,f.from,f.to);r.setSelection(p)}}return!0},c3e=e=>t=>{const r=typeof e=="function"?e(t):e;for(let o=0;o<r.length;o+=1)if(r[o](t))return!0;return!1};function i2(e){return e instanceof Ge}function go(e=0,t=0,r=0){return Math.min(Math.max(e,t),r)}function Jw(e,t=null){if(!t)return null;const r=Ze.atStart(e),o=Ze.atEnd(e);if(t==="start"||t===!0)return r;if(t==="end")return o;const a=r.from,i=o.to;return t==="all"?Ge.create(e,go(0,a,i),go(e.content.size,a,i)):Ge.create(e,go(t,a,i),go(t,a,i))}function l2(){return["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in document}const u3e=(e=null,t={})=>({editor:r,view:o,tr:a,dispatch:i})=>{t={scrollIntoView:!0,...t};const l=()=>{l2()&&o.dom.focus(),requestAnimationFrame(()=>{r.isDestroyed||(o.focus(),t!=null&&t.scrollIntoView&&r.commands.scrollIntoView())})};if(o.hasFocus()&&e===null||e===!1)return!0;if(i&&e===null&&!i2(r.state.selection))return l(),!0;const s=Jw(a.doc,e)||r.state.selection,c=r.state.selection.eq(s);return i&&(c||a.setSelection(s),c&&a.storedMarks&&a.setStoredMarks(a.storedMarks),l()),!0},d3e=(e,t)=>r=>e.every((o,a)=>t(o,{...r,index:a})),f3e=(e,t)=>({tr:r,commands:o})=>o.insertContentAt({from:r.selection.from,to:r.selection.to},e,t),Zw=e=>{const t=e.childNodes;for(let r=t.length-1;r>=0;r-=1){const o=t[r];o.nodeType===3&&o.nodeValue&&/^(\n\s\s|\n)$/.test(o.nodeValue)?e.removeChild(o):o.nodeType===1&&Zw(o)}return e};function Dc(e){const t=`<body>${e}</body>`,r=new window.DOMParser().parseFromString(t,"text/html").body;return Zw(r)}function Ru(e,t,r){r={slice:!0,parseOptions:{},...r};const o=typeof e=="object"&&e!==null,a=typeof e=="string";if(o)try{if(Array.isArray(e)&&e.length>0)return fe.fromArray(e.map(s=>t.nodeFromJSON(s)));const l=t.nodeFromJSON(e);return r.errorOnInvalidContent&&l.check(),l}catch(i){if(r.errorOnInvalidContent)throw new Error("[tiptap error]: Invalid JSON content",{cause:i});return console.warn("[tiptap warn]: Invalid content.","Passed value:",e,"Error:",i),Ru("",t,r)}if(a){if(r.errorOnInvalidContent){let l=!1,s="";const c=new U8({topNode:t.spec.topNode,marks:t.spec.marks,nodes:t.spec.nodes.append({__tiptap__private__unknown__catch__all__node:{content:"inline*",group:"block",parseDOM:[{tag:"*",getAttrs:u=>(l=!0,s=typeof u=="string"?u:u.outerHTML,null)}]}})});if(r.slice?Go.fromSchema(c).parseSlice(Dc(e),r.parseOptions):Go.fromSchema(c).parse(Dc(e),r.parseOptions),r.errorOnInvalidContent&&l)throw new Error("[tiptap error]: Invalid HTML content",{cause:new Error(`Invalid element found: ${s}`)})}const i=Go.fromSchema(t);return r.slice?i.parseSlice(Dc(e),r.parseOptions).content:i.parse(Dc(e),r.parseOptions)}return Ru("",t,r)}function p3e(e,t,r){const o=e.steps.length-1;if(o<t)return;const a=e.steps[o];if(!(a instanceof Kt||a instanceof Zt))return;const i=e.mapping.maps[o];let l=0;i.forEach((s,c,u,d)=>{l===0&&(l=d)}),e.setSelection(Ze.near(e.doc.resolve(l),r))}const m3e=e=>!("type"in e),h3e=(e,t,r)=>({tr:o,dispatch:a,editor:i})=>{var l;if(a){r={parseOptions:i.options.parseOptions,updateSelection:!0,applyInputRules:!1,applyPasteRules:!1,...r};let s;try{s=Ru(t,i.schema,{parseOptions:{preserveWhitespace:"full",...r.parseOptions},errorOnInvalidContent:(l=r.errorOnInvalidContent)!==null&&l!==void 0?l:i.options.enableContentCheck})}catch(m){return i.emit("contentError",{editor:i,error:m,disableCollaboration:()=>{i.storage.collaboration&&(i.storage.collaboration.isDisabled=!0)}}),!1}let{from:c,to:u}=typeof e=="number"?{from:e,to:e}:{from:e.from,to:e.to},d=!0,f=!0;if((m3e(s)?s:[s]).forEach(m=>{m.check(),d=d?m.isText&&m.marks.length===0:!1,f=f?m.isBlock:!1}),c===u&&f){const{parent:m}=o.doc.resolve(c);m.isTextblock&&!m.type.spec.code&&!m.childCount&&(c-=1,u+=1)}let h;d?(Array.isArray(t)?h=t.map(m=>m.text||"").join(""):typeof t=="object"&&t&&t.text?h=t.text:h=t,o.insertText(h,c,u)):(h=s,o.replaceWith(c,u,h)),r.updateSelection&&p3e(o,o.steps.length-1,-1),r.applyInputRules&&o.setMeta("applyInputRules",{from:c,text:h}),r.applyPasteRules&&o.setMeta("applyPasteRules",{from:c,text:h})}return!0},g3e=()=>({state:e,dispatch:t})=>hve(e,t),v3e=()=>({state:e,dispatch:t})=>gve(e,t),y3e=()=>({state:e,dispatch:t})=>cve(e,t),M3e=()=>({state:e,dispatch:t})=>pve(e,t),b3e=()=>({state:e,dispatch:t,tr:r})=>{try{const o=rf(e.doc,e.selection.$from.pos,-1);return o==null?!1:(r.join(o,2),t&&t(r),!0)}catch{return!1}},w3e=()=>({state:e,dispatch:t,tr:r})=>{try{const o=rf(e.doc,e.selection.$from.pos,1);return o==null?!1:(r.join(o,2),t&&t(r),!0)}catch{return!1}},N3e=()=>({state:e,dispatch:t})=>uve(e,t),k3e=()=>({state:e,dispatch:t})=>dve(e,t);function Xw(){return typeof navigator<"u"?/Mac/.test(navigator.platform):!1}function x3e(e){const t=e.split(/-(?!$)/);let r=t[t.length-1];r==="Space"&&(r=" ");let o,a,i,l;for(let s=0;s<t.length-1;s+=1){const c=t[s];if(/^(cmd|meta|m)$/i.test(c))l=!0;else if(/^a(lt)?$/i.test(c))o=!0;else if(/^(c|ctrl|control)$/i.test(c))a=!0;else if(/^s(hift)?$/i.test(c))i=!0;else if(/^mod$/i.test(c))l2()||Xw()?l=!0:a=!0;else throw new Error(`Unrecognized modifier name: ${c}`)}return o&&(r=`Alt-${r}`),a&&(r=`Ctrl-${r}`),l&&(r=`Meta-${r}`),i&&(r=`Shift-${r}`),r}const C3e=e=>({editor:t,view:r,tr:o,dispatch:a})=>{const i=x3e(e).split(/-(?!$)/),l=i.find(u=>!["Alt","Ctrl","Meta","Shift"].includes(u)),s=new KeyboardEvent("keydown",{key:l==="Space"?" ":l,altKey:i.includes("Alt"),ctrlKey:i.includes("Ctrl"),metaKey:i.includes("Meta"),shiftKey:i.includes("Shift"),bubbles:!0,cancelable:!0}),c=t.captureTransaction(()=>{r.someProp("handleKeyDown",u=>u(r,s))});return c==null||c.steps.forEach(u=>{const d=u.map(o.mapping);d&&a&&o.maybeStep(d)}),!0};function Ss(e,t,r={}){const{from:o,to:a,empty:i}=e.selection,l=t?en(t,e.schema):null,s=[];e.doc.nodesBetween(o,a,(f,p)=>{if(f.isText)return;const h=Math.max(o,p),m=Math.min(a,p+f.nodeSize);s.push({node:f,from:h,to:m})});const c=a-o,u=s.filter(f=>l?l.name===f.node.type.name:!0).filter(f=>Pu(f.node.attrs,r,{strict:!1}));return i?!!u.length:u.reduce((f,p)=>f+p.to-p.from,0)>=c}const E3e=(e,t={})=>({state:r,dispatch:o})=>{const a=en(e,r.schema);return Ss(r,a,t)?vve(r,o):!1},T3e=()=>({state:e,dispatch:t})=>wve(e,t),D3e=e=>({state:t,dispatch:r})=>{const o=en(e,t.schema);return Sve(o)(t,r)},S3e=()=>({state:e,dispatch:t})=>yve(e,t);function mf(e,t){return t.nodes[e]?"node":t.marks[e]?"mark":null}function Lv(e,t){const r=typeof t=="string"?[t]:t;return Object.keys(e).reduce((o,a)=>(r.includes(a)||(o[a]=e[a]),o),{})}const _3e=(e,t)=>({tr:r,state:o,dispatch:a})=>{let i=null,l=null;const s=mf(typeof e=="string"?e:e.name,o.schema);return s?(s==="node"&&(i=en(e,o.schema)),s==="mark"&&(l=ca(e,o.schema)),a&&r.selection.ranges.forEach(c=>{o.doc.nodesBetween(c.$from.pos,c.$to.pos,(u,d)=>{i&&i===u.type&&r.setNodeMarkup(d,void 0,Lv(u.attrs,t)),l&&u.marks.length&&u.marks.forEach(f=>{l===f.type&&r.addMark(d,d+u.nodeSize,l.create(Lv(f.attrs,t)))})})}),!0):!1},I3e=()=>({tr:e,dispatch:t})=>(t&&e.scrollIntoView(),!0),A3e=()=>({tr:e,commands:t})=>t.setTextSelection({from:0,to:e.doc.content.size}),O3e=()=>({state:e,dispatch:t})=>fve(e,t),z3e=()=>({state:e,dispatch:t})=>mve(e,t),j3e=()=>({state:e,dispatch:t})=>Nve(e,t),L3e=()=>({state:e,dispatch:t})=>Cve(e,t),B3e=()=>({state:e,dispatch:t})=>xve(e,t);function V0(e,t,r={},o={}){return Ru(e,t,{slice:!1,parseOptions:r,errorOnInvalidContent:o.errorOnInvalidContent})}const V3e=(e,t=!1,r={},o={})=>({editor:a,tr:i,dispatch:l,commands:s})=>{var c,u;const{doc:d}=i;if(r.preserveWhitespace!=="full"){const f=V0(e,a.schema,r,{errorOnInvalidContent:(c=o.errorOnInvalidContent)!==null&&c!==void 0?c:a.options.enableContentCheck});return l&&i.replaceWith(0,d.content.size,f).setMeta("preventUpdate",!t),!0}return l&&i.setMeta("preventUpdate",!t),s.insertContentAt({from:0,to:d.content.size},e,{parseOptions:r,errorOnInvalidContent:(u=o.errorOnInvalidContent)!==null&&u!==void 0?u:a.options.enableContentCheck})};function eN(e,t){const r=ca(t,e.schema),{from:o,to:a,empty:i}=e.selection,l=[];i?(e.storedMarks&&l.push(...e.storedMarks),l.push(...e.selection.$head.marks())):e.doc.nodesBetween(o,a,c=>{l.push(...c.marks)});const s=l.find(c=>c.type.name===r.name);return s?{...s.attrs}:{}}function $3e(e,t){const r=new ow(e);return t.forEach(o=>{o.steps.forEach(a=>{r.step(a)})}),r}function P3e(e){for(let t=0;t<e.edgeCount;t+=1){const{type:r}=e.edge(t);if(r.isTextblock&&!r.hasRequiredAttrs())return r}return null}function R3e(e,t,r){const o=[];return e.nodesBetween(t.from,t.to,(a,i)=>{r(a)&&o.push({node:a,pos:i})}),o}function F3e(e,t){for(let r=e.depth;r>0;r-=1){const o=e.node(r);if(t(o))return{pos:r>0?e.before(r):0,start:e.start(r),depth:r,node:o}}}function s2(e){return t=>F3e(t.$from,e)}function U3e(e,t){const r=Xa.fromSchema(t).serializeFragment(e),a=document.implementation.createHTMLDocument().createElement("div");return a.appendChild(r),a.innerHTML}function H3e(e,t){const r={from:0,to:e.content.size};return Gw(e,r,t)}function Y3e(e,t){const r=en(t,e.schema),{from:o,to:a}=e.selection,i=[];e.doc.nodesBetween(o,a,s=>{i.push(s)});const l=i.reverse().find(s=>s.type.name===r.name);return l?{...l.attrs}:{}}function tN(e,t){const r=mf(typeof t=="string"?t:t.name,e.schema);return r==="node"?Y3e(e,t):r==="mark"?eN(e,t):{}}function Q3e(e,t=JSON.stringify){const r={};return e.filter(o=>{const a=t(o);return Object.prototype.hasOwnProperty.call(r,a)?!1:r[a]=!0})}function W3e(e){const t=Q3e(e);return t.length===1?t:t.filter((r,o)=>!t.filter((i,l)=>l!==o).some(i=>r.oldRange.from>=i.oldRange.from&&r.oldRange.to<=i.oldRange.to&&r.newRange.from>=i.newRange.from&&r.newRange.to<=i.newRange.to))}function q3e(e){const{mapping:t,steps:r}=e,o=[];return t.maps.forEach((a,i)=>{const l=[];if(a.ranges.length)a.forEach((s,c)=>{l.push({from:s,to:c})});else{const{from:s,to:c}=r[i];if(s===void 0||c===void 0)return;l.push({from:s,to:c})}l.forEach(({from:s,to:c})=>{const u=t.slice(i).map(s,-1),d=t.slice(i).map(c),f=t.invert().map(u,-1),p=t.invert().map(d);o.push({oldRange:{from:f,to:p},newRange:{from:u,to:d}})})}),W3e(o)}function c2(e,t,r){const o=[];return e===t?r.resolve(e).marks().forEach(a=>{const i=r.resolve(e),l=a2(i,a.type);l&&o.push({mark:a,...l})}):r.nodesBetween(e,t,(a,i)=>{!a||(a==null?void 0:a.nodeSize)===void 0||o.push(...a.marks.map(l=>({from:i,to:i+a.nodeSize,mark:l})))}),o}function Gc(e,t,r){return Object.fromEntries(Object.entries(r).filter(([o])=>{const a=e.find(i=>i.type===t&&i.name===o);return a?a.attribute.keepOnSplit:!1}))}function $0(e,t,r={}){const{empty:o,ranges:a}=e.selection,i=t?ca(t,e.schema):null;if(o)return!!(e.storedMarks||e.selection.$from.marks()).filter(f=>i?i.name===f.type.name:!0).find(f=>Pu(f.attrs,r,{strict:!1}));let l=0;const s=[];if(a.forEach(({$from:f,$to:p})=>{const h=f.pos,m=p.pos;e.doc.nodesBetween(h,m,(g,v)=>{if(!g.isText&&!g.marks.length)return;const y=Math.max(h,v),N=Math.min(m,v+g.nodeSize),b=N-y;l+=b,s.push(...g.marks.map(M=>({mark:M,from:y,to:N})))})}),l===0)return!1;const c=s.filter(f=>i?i.name===f.mark.type.name:!0).filter(f=>Pu(f.mark.attrs,r,{strict:!1})).reduce((f,p)=>f+p.to-p.from,0),u=s.filter(f=>i?f.mark.type!==i&&f.mark.type.excludes(i):!0).reduce((f,p)=>f+p.to-p.from,0);return(c>0?c+u:c)>=l}function G3e(e,t,r={}){if(!t)return Ss(e,null,r)||$0(e,null,r);const o=mf(t,e.schema);return o==="node"?Ss(e,t,r):o==="mark"?$0(e,t,r):!1}function Bv(e,t){const{nodeExtensions:r}=ff(t),o=r.find(l=>l.name===e);if(!o)return!1;const a={name:o.name,options:o.options,storage:o.storage},i=Je(Ie(o,"group",a));return typeof i!="string"?!1:i.split(" ").includes("list")}function hf(e,{checkChildren:t=!0,ignoreWhitespace:r=!1}={}){var o;if(r){if(e.type.name==="hardBreak")return!0;if(e.isText)return/^\s*$/m.test((o=e.text)!==null&&o!==void 0?o:"")}if(e.isText)return!e.text;if(e.isAtom||e.isLeaf)return!1;if(e.content.childCount===0)return!0;if(t){let a=!0;return e.content.forEach(i=>{a!==!1&&(hf(i,{ignoreWhitespace:r,checkChildren:t})||(a=!1))}),a}return!1}function K3e(e){return e instanceof Pe}function nN(e,t,r){const a=e.state.doc.content.size,i=go(t,0,a),l=go(r,0,a),s=e.coordsAtPos(i),c=e.coordsAtPos(l,-1),u=Math.min(s.top,c.top),d=Math.max(s.bottom,c.bottom),f=Math.min(s.left,c.left),p=Math.max(s.right,c.right),h=p-f,m=d-u,y={top:u,bottom:d,left:f,right:p,width:h,height:m,x:f,y:u};return{...y,toJSON:()=>y}}function J3e(e,t,r){var o;const{selection:a}=t;let i=null;if(i2(a)&&(i=a.$cursor),i){const s=(o=e.storedMarks)!==null&&o!==void 0?o:i.marks();return!!r.isInSet(s)||!s.some(c=>c.type.excludes(r))}const{ranges:l}=a;return l.some(({$from:s,$to:c})=>{let u=s.depth===0?e.doc.inlineContent&&e.doc.type.allowsMarkType(r):!1;return e.doc.nodesBetween(s.pos,c.pos,(d,f,p)=>{if(u)return!1;if(d.isInline){const h=!p||p.type.allowsMarkType(r),m=!!r.isInSet(d.marks)||!d.marks.some(g=>g.type.excludes(r));u=h&&m}return!u}),u})}const Z3e=(e,t={})=>({tr:r,state:o,dispatch:a})=>{const{selection:i}=r,{empty:l,ranges:s}=i,c=ca(e,o.schema);if(a)if(l){const u=eN(o,c);r.addStoredMark(c.create({...u,...t}))}else s.forEach(u=>{const d=u.$from.pos,f=u.$to.pos;o.doc.nodesBetween(d,f,(p,h)=>{const m=Math.max(h,d),g=Math.min(h+p.nodeSize,f);p.marks.find(y=>y.type===c)?p.marks.forEach(y=>{c===y.type&&r.addMark(m,g,c.create({...y.attrs,...t}))}):r.addMark(m,g,c.create(t))})});return J3e(o,r,c)},X3e=(e,t)=>({tr:r})=>(r.setMeta(e,t),!0),eye=(e,t={})=>({state:r,dispatch:o,chain:a})=>{const i=en(e,r.schema);return i.isTextblock?a().command(({commands:l})=>Av(i,t)(r)?!0:l.clearNodes()).command(({state:l})=>Av(i,t)(l,o)).run():(console.warn('[tiptap warn]: Currently "setNode()" only supports text block nodes.'),!1)},tye=e=>({tr:t,dispatch:r})=>{if(r){const{doc:o}=t,a=go(e,0,o.content.size),i=Pe.create(o,a);t.setSelection(i)}return!0},nye=e=>({tr:t,dispatch:r})=>{if(r){const{doc:o}=t,{from:a,to:i}=typeof e=="number"?{from:e,to:e}:e,l=Ge.atStart(o).from,s=Ge.atEnd(o).to,c=go(a,l,s),u=go(i,l,s),d=Ge.create(o,c,u);t.setSelection(d)}return!0},rye=e=>({state:t,dispatch:r})=>{const o=en(e,t.schema);return Ave(o)(t,r)};function Vv(e,t){const r=e.storedMarks||e.selection.$to.parentOffset&&e.selection.$from.marks();if(r){const o=r.filter(a=>t==null?void 0:t.includes(a.type.name));e.tr.ensureMarks(o)}}const oye=({keepMarks:e=!0}={})=>({tr:t,state:r,dispatch:o,editor:a})=>{const{selection:i,doc:l}=t,{$from:s,$to:c}=i,u=a.extensionManager.attributes,d=Gc(u,s.node().type.name,s.node().attrs);if(i instanceof Pe&&i.node.isBlock)return!s.parentOffset||!Si(l,s.pos)?!1:(o&&(e&&Vv(r,a.extensionManager.splittableMarks),t.split(s.pos).scrollIntoView()),!0);if(!s.parent.isBlock)return!1;const f=c.parentOffset===c.parent.content.size,p=s.depth===0?void 0:P3e(s.node(-1).contentMatchAt(s.indexAfter(-1)));let h=f&&p?[{type:p,attrs:d}]:void 0,m=Si(t.doc,t.mapping.map(s.pos),1,h);if(!h&&!m&&Si(t.doc,t.mapping.map(s.pos),1,p?[{type:p}]:void 0)&&(m=!0,h=p?[{type:p,attrs:d}]:void 0),o){if(m&&(i instanceof Ge&&t.deleteSelection(),t.split(t.mapping.map(s.pos),1,h),p&&!f&&!s.parentOffset&&s.parent.type!==p)){const g=t.mapping.map(s.before()),v=t.doc.resolve(g);s.node(-1).canReplaceWith(v.index(),v.index()+1,p)&&t.setNodeMarkup(t.mapping.map(s.before()),p)}e&&Vv(r,a.extensionManager.splittableMarks),t.scrollIntoView()}return m},aye=(e,t={})=>({tr:r,state:o,dispatch:a,editor:i})=>{var l;const s=en(e,o.schema),{$from:c,$to:u}=o.selection,d=o.selection.node;if(d&&d.isBlock||c.depth<2||!c.sameParent(u))return!1;const f=c.node(-1);if(f.type!==s)return!1;const p=i.extensionManager.attributes;if(c.parent.content.size===0&&c.node(-1).childCount===c.indexAfter(-1)){if(c.depth===2||c.node(-3).type!==s||c.index(-2)!==c.node(-2).childCount-1)return!1;if(a){let y=fe.empty;const N=c.index(-1)?1:c.index(-2)?2:3;for(let E=c.depth-N;E>=c.depth-3;E-=1)y=fe.from(c.node(E).copy(y));const b=c.indexAfter(-1)<c.node(-2).childCount?1:c.indexAfter(-2)<c.node(-3).childCount?2:3,M={...Gc(p,c.node().type.name,c.node().attrs),...t},k=((l=s.contentMatch.defaultType)===null||l===void 0?void 0:l.createAndFill(M))||void 0;y=y.append(fe.from(s.createAndFill(null,k)||void 0));const w=c.before(c.depth-(N-1));r.replace(w,c.after(-b),new Ee(y,4-N,0));let C=-1;r.doc.nodesBetween(w,r.doc.content.size,(E,A)=>{if(C>-1)return!1;E.isTextblock&&E.content.size===0&&(C=A+1)}),C>-1&&r.setSelection(Ge.near(r.doc.resolve(C))),r.scrollIntoView()}return!0}const h=u.pos===c.end()?f.contentMatchAt(0).defaultType:null,m={...Gc(p,f.type.name,f.attrs),...t},g={...Gc(p,c.node().type.name,c.node().attrs),...t};r.delete(c.pos,u.pos);const v=h?[{type:s,attrs:m},{type:h,attrs:g}]:[{type:s,attrs:m}];if(!Si(r.doc,c.pos,2))return!1;if(a){const{selection:y,storedMarks:N}=o,{splittableMarks:b}=i.extensionManager,M=N||y.$to.parentOffset&&y.$from.marks();if(r.split(c.pos,2,v).scrollIntoView(),!M||!a)return!0;const k=M.filter(w=>b.includes(w.type.name));r.ensureMarks(k)}return!0},cp=(e,t)=>{const r=s2(l=>l.type===t)(e.selection);if(!r)return!0;const o=e.doc.resolve(Math.max(0,r.pos-1)).before(r.depth);if(o===void 0)return!0;const a=e.doc.nodeAt(o);return r.node.type===(a==null?void 0:a.type)&&la(e.doc,r.pos)&&e.join(r.pos),!0},up=(e,t)=>{const r=s2(l=>l.type===t)(e.selection);if(!r)return!0;const o=e.doc.resolve(r.start).after(r.depth);if(o===void 0)return!0;const a=e.doc.nodeAt(o);return r.node.type===(a==null?void 0:a.type)&&la(e.doc,o)&&e.join(o),!0},iye=(e,t,r,o={})=>({editor:a,tr:i,state:l,dispatch:s,chain:c,commands:u,can:d})=>{const{extensions:f,splittableMarks:p}=a.extensionManager,h=en(e,l.schema),m=en(t,l.schema),{selection:g,storedMarks:v}=l,{$from:y,$to:N}=g,b=y.blockRange(N),M=v||g.$to.parentOffset&&g.$from.marks();if(!b)return!1;const k=s2(w=>Bv(w.type.name,f))(g);if(b.depth>=1&&k&&b.depth-k.depth<=1){if(k.node.type===h)return u.liftListItem(m);if(Bv(k.node.type.name,f)&&h.validContent(k.node.content)&&s)return c().command(()=>(i.setNodeMarkup(k.pos,h),!0)).command(()=>cp(i,h)).command(()=>up(i,h)).run()}return!r||!M||!s?c().command(()=>d().wrapInList(h,o)?!0:u.clearNodes()).wrapInList(h,o).command(()=>cp(i,h)).command(()=>up(i,h)).run():c().command(()=>{const w=d().wrapInList(h,o),C=M.filter(E=>p.includes(E.type.name));return i.ensureMarks(C),w?!0:u.clearNodes()}).wrapInList(h,o).command(()=>cp(i,h)).command(()=>up(i,h)).run()},lye=(e,t={},r={})=>({state:o,commands:a})=>{const{extendEmptyMarkRange:i=!1}=r,l=ca(e,o.schema);return $0(o,l,t)?a.unsetMark(l,{extendEmptyMarkRange:i}):a.setMark(l,t)},sye=(e,t,r={})=>({state:o,commands:a})=>{const i=en(e,o.schema),l=en(t,o.schema),s=Ss(o,i,r);let c;return o.selection.$anchor.sameParent(o.selection.$head)&&(c=o.selection.$anchor.parent.attrs),s?a.setNode(l,c):a.setNode(i,{...c,...r})},cye=(e,t={})=>({state:r,commands:o})=>{const a=en(e,r.schema);return Ss(r,a,t)?o.lift(a):o.wrapIn(a,t)},uye=()=>({state:e,dispatch:t})=>{const r=e.plugins;for(let o=0;o<r.length;o+=1){const a=r[o];let i;if(a.spec.isInputRules&&(i=a.getState(e))){if(t){const l=e.tr,s=i.transform;for(let c=s.steps.length-1;c>=0;c-=1)l.step(s.steps[c].invert(s.docs[c]));if(i.text){const c=l.doc.resolve(i.from).marks();l.replaceWith(i.from,i.to,e.schema.text(i.text,c))}else l.delete(i.from,i.to)}return!0}}return!1},dye=()=>({tr:e,dispatch:t})=>{const{selection:r}=e,{empty:o,ranges:a}=r;return o||t&&a.forEach(i=>{e.removeMark(i.$from.pos,i.$to.pos)}),!0},fye=(e,t={})=>({tr:r,state:o,dispatch:a})=>{var i;const{extendEmptyMarkRange:l=!1}=t,{selection:s}=r,c=ca(e,o.schema),{$from:u,empty:d,ranges:f}=s;if(!a)return!0;if(d&&l){let{from:p,to:h}=s;const m=(i=u.marks().find(v=>v.type===c))===null||i===void 0?void 0:i.attrs,g=a2(u,c,m);g&&(p=g.from,h=g.to),r.removeMark(p,h,c)}else f.forEach(p=>{r.removeMark(p.$from.pos,p.$to.pos,c)});return r.removeStoredMark(c),!0},pye=(e,t={})=>({tr:r,state:o,dispatch:a})=>{let i=null,l=null;const s=mf(typeof e=="string"?e:e.name,o.schema);return s?(s==="node"&&(i=en(e,o.schema)),s==="mark"&&(l=ca(e,o.schema)),a&&r.selection.ranges.forEach(c=>{const u=c.$from.pos,d=c.$to.pos;o.doc.nodesBetween(u,d,(f,p)=>{i&&i===f.type&&r.setNodeMarkup(p,void 0,{...f.attrs,...t}),l&&f.marks.length&&f.marks.forEach(h=>{if(l===h.type){const m=Math.max(p,u),g=Math.min(p+f.nodeSize,d);r.addMark(m,g,l.create({...h.attrs,...t}))}})})}),!0):!1},mye=(e,t={})=>({state:r,dispatch:o})=>{const a=en(e,r.schema);return Eve(a,t)(r,o)},hye=(e,t={})=>({state:r,dispatch:o})=>{const a=en(e,r.schema);return Tve(a,t)(r,o)};var gye=Object.freeze({__proto__:null,blur:Gve,clearContent:Kve,clearNodes:Jve,command:Zve,createParagraphNear:Xve,cut:e3e,deleteCurrentNode:t3e,deleteNode:n3e,deleteRange:r3e,deleteSelection:o3e,enter:a3e,exitCode:i3e,extendMarkRange:s3e,first:c3e,focus:u3e,forEach:d3e,insertContent:f3e,insertContentAt:h3e,joinBackward:y3e,joinDown:v3e,joinForward:M3e,joinItemBackward:b3e,joinItemForward:w3e,joinTextblockBackward:N3e,joinTextblockForward:k3e,joinUp:g3e,keyboardShortcut:C3e,lift:E3e,liftEmptyBlock:T3e,liftListItem:D3e,newlineInCode:S3e,resetAttributes:_3e,scrollIntoView:I3e,selectAll:A3e,selectNodeBackward:O3e,selectNodeForward:z3e,selectParentNode:j3e,selectTextblockEnd:L3e,selectTextblockStart:B3e,setContent:V3e,setMark:Z3e,setMeta:X3e,setNode:eye,setNodeSelection:tye,setTextSelection:nye,sinkListItem:rye,splitBlock:oye,splitListItem:aye,toggleList:iye,toggleMark:lye,toggleNode:sye,toggleWrap:cye,undoInputRule:uye,unsetAllMarks:dye,unsetMark:fye,updateAttributes:pye,wrapIn:mye,wrapInList:hye});const vye=hn.create({name:"commands",addCommands(){return{...gye}}}),yye=hn.create({name:"drop",addProseMirrorPlugins(){return[new tn({key:new yn("tiptapDrop"),props:{handleDrop:(e,t,r,o)=>{this.editor.emit("drop",{editor:this.editor,event:t,slice:r,moved:o})}}})]}}),Mye=hn.create({name:"editable",addProseMirrorPlugins(){return[new tn({key:new yn("editable"),props:{editable:()=>this.editor.options.editable}})]}}),bye=hn.create({name:"focusEvents",addProseMirrorPlugins(){const{editor:e}=this;return[new tn({key:new yn("focusEvents"),props:{handleDOMEvents:{focus:(t,r)=>{e.isFocused=!0;const o=e.state.tr.setMeta("focus",{event:r}).setMeta("addToHistory",!1);return t.dispatch(o),!1},blur:(t,r)=>{e.isFocused=!1;const o=e.state.tr.setMeta("blur",{event:r}).setMeta("addToHistory",!1);return t.dispatch(o),!1}}}})]}}),wye=hn.create({name:"keymap",addKeyboardShortcuts(){const e=()=>this.editor.commands.first(({commands:l})=>[()=>l.undoInputRule(),()=>l.command(({tr:s})=>{const{selection:c,doc:u}=s,{empty:d,$anchor:f}=c,{pos:p,parent:h}=f,m=f.parent.isTextblock&&p>0?s.doc.resolve(p-1):f,g=m.parent.type.spec.isolating,v=f.pos-f.parentOffset,y=g&&m.parent.childCount===1?v===f.pos:Ze.atStart(u).from===p;return!d||!h.type.isTextblock||h.textContent.length||!y||y&&f.parent.type.name==="paragraph"?!1:l.clearNodes()}),()=>l.deleteSelection(),()=>l.joinBackward(),()=>l.selectNodeBackward()]),t=()=>this.editor.commands.first(({commands:l})=>[()=>l.deleteSelection(),()=>l.deleteCurrentNode(),()=>l.joinForward(),()=>l.selectNodeForward()]),o={Enter:()=>this.editor.commands.first(({commands:l})=>[()=>l.newlineInCode(),()=>l.createParagraphNear(),()=>l.liftEmptyBlock(),()=>l.splitBlock()]),"Mod-Enter":()=>this.editor.commands.exitCode(),Backspace:e,"Mod-Backspace":e,"Shift-Backspace":e,Delete:t,"Mod-Delete":t,"Mod-a":()=>this.editor.commands.selectAll()},a={...o},i={...o,"Ctrl-h":e,"Alt-Backspace":e,"Ctrl-d":t,"Ctrl-Alt-Backspace":t,"Alt-Delete":t,"Alt-d":t,"Ctrl-a":()=>this.editor.commands.selectTextblockStart(),"Ctrl-e":()=>this.editor.commands.selectTextblockEnd()};return l2()||Xw()?i:a},addProseMirrorPlugins(){return[new tn({key:new yn("clearDocument"),appendTransaction:(e,t,r)=>{const o=e.some(g=>g.docChanged)&&!t.doc.eq(r.doc),a=e.some(g=>g.getMeta("preventClearDocument"));if(!o||a)return;const{empty:i,from:l,to:s}=t.selection,c=Ze.atStart(t.doc).from,u=Ze.atEnd(t.doc).to;if(i||!(l===c&&s===u)||!hf(r.doc))return;const p=r.tr,h=uf({state:r,transaction:p}),{commands:m}=new df({editor:this.editor,state:h});if(m.clearNodes(),!!p.steps.length)return p}})]}}),Nye=hn.create({name:"paste",addProseMirrorPlugins(){return[new tn({key:new yn("tiptapPaste"),props:{handlePaste:(e,t,r)=>{this.editor.emit("paste",{editor:this.editor,event:t,slice:r})}}})]}}),kye=hn.create({name:"tabindex",addProseMirrorPlugins(){return[new tn({key:new yn("tabindex"),props:{attributes:()=>this.editor.isEditable?{tabindex:"0"}:{}}})]}});class ba{get name(){return this.node.type.name}constructor(t,r,o=!1,a=null){this.currentNode=null,this.actualDepth=null,this.isBlock=o,this.resolvedPos=t,this.editor=r,this.currentNode=a}get node(){return this.currentNode||this.resolvedPos.node()}get element(){return this.editor.view.domAtPos(this.pos).node}get depth(){var t;return(t=this.actualDepth)!==null&&t!==void 0?t:this.resolvedPos.depth}get pos(){return this.resolvedPos.pos}get content(){return this.node.content}set content(t){let r=this.from,o=this.to;if(this.isBlock){if(this.content.size===0){console.error(`You can’t set content on a block node. Tried to set content on ${this.name} at ${this.pos}`);return}r=this.from+1,o=this.to-1}this.editor.commands.insertContentAt({from:r,to:o},t)}get attributes(){return this.node.attrs}get textContent(){return this.node.textContent}get size(){return this.node.nodeSize}get from(){return this.isBlock?this.pos:this.resolvedPos.start(this.resolvedPos.depth)}get range(){return{from:this.from,to:this.to}}get to(){return this.isBlock?this.pos+this.size:this.resolvedPos.end(this.resolvedPos.depth)+(this.node.isText?0:1)}get parent(){if(this.depth===0)return null;const t=this.resolvedPos.start(this.resolvedPos.depth-1),r=this.resolvedPos.doc.resolve(t);return new ba(r,this.editor)}get before(){let t=this.resolvedPos.doc.resolve(this.from-(this.isBlock?1:2));return t.depth!==this.depth&&(t=this.resolvedPos.doc.resolve(this.from-3)),new ba(t,this.editor)}get after(){let t=this.resolvedPos.doc.resolve(this.to+(this.isBlock?2:1));return t.depth!==this.depth&&(t=this.resolvedPos.doc.resolve(this.to+3)),new ba(t,this.editor)}get children(){const t=[];return this.node.content.forEach((r,o)=>{const a=r.isBlock&&!r.isTextblock,i=r.isAtom&&!r.isText,l=this.pos+o+(i?0:1),s=this.resolvedPos.doc.resolve(l);if(!a&&s.depth<=this.depth)return;const c=new ba(s,this.editor,a,a?r:null);a&&(c.actualDepth=this.depth+1),t.push(new ba(s,this.editor,a,a?r:null))}),t}get firstChild(){return this.children[0]||null}get lastChild(){const t=this.children;return t[t.length-1]||null}closest(t,r={}){let o=null,a=this.parent;for(;a&&!o;){if(a.node.type.name===t)if(Object.keys(r).length>0){const i=a.node.attrs,l=Object.keys(r);for(let s=0;s<l.length;s+=1){const c=l[s];if(i[c]!==r[c])break}}else o=a;a=a.parent}return o}querySelector(t,r={}){return this.querySelectorAll(t,r,!0)[0]||null}querySelectorAll(t,r={},o=!1){let a=[];if(!this.children||this.children.length===0)return a;const i=Object.keys(r);return this.children.forEach(l=>{o&&a.length>0||(l.node.type.name===t&&i.every(c=>r[c]===l.node.attrs[c])&&a.push(l),!(o&&a.length>0)&&(a=a.concat(l.querySelectorAll(t,r,o))))}),a}setAttribute(t){const{tr:r}=this.editor.state;r.setNodeMarkup(this.from,void 0,{...this.node.attrs,...t}),this.editor.view.dispatch(r)}}const xye=`.ProseMirror {
|
|
60
60
|
position: relative;
|
|
61
61
|
}
|
|
62
62
|
|
|
@@ -130,33 +130,33 @@ img.ProseMirror-separator {
|
|
|
130
130
|
|
|
131
131
|
.tippy-box[data-animation=fade][data-state=hidden] {
|
|
132
132
|
opacity: 0
|
|
133
|
-
}`;function
|
|
133
|
+
}`;function Cye(e,t,r){const o=document.querySelector(`style[data-tiptap-style${r?`-${r}`:""}]`);if(o!==null)return o;const a=document.createElement("style");return t&&a.setAttribute("nonce",t),a.setAttribute(`data-tiptap-style${r?`-${r}`:""}`,""),a.innerHTML=e,document.getElementsByTagName("head")[0].appendChild(a),a}let Eye=class extends Ove{constructor(t={}){super(),this.isFocused=!1,this.isInitialized=!1,this.extensionStorage={},this.options={element:document.createElement("div"),content:"",injectCSS:!0,injectNonce:void 0,extensions:[],autofocus:!1,editable:!0,editorProps:{},parseOptions:{},coreExtensionOptions:{},enableInputRules:!0,enablePasteRules:!0,enableCoreExtensions:!0,enableContentCheck:!1,onBeforeCreate:()=>null,onCreate:()=>null,onUpdate:()=>null,onSelectionUpdate:()=>null,onTransaction:()=>null,onFocus:()=>null,onBlur:()=>null,onDestroy:()=>null,onContentError:({error:r})=>{throw r},onPaste:()=>null,onDrop:()=>null},this.isCapturingTransaction=!1,this.capturedTransaction=null,this.setOptions(t),this.createExtensionManager(),this.createCommandManager(),this.createSchema(),this.on("beforeCreate",this.options.onBeforeCreate),this.emit("beforeCreate",{editor:this}),this.on("contentError",this.options.onContentError),this.createView(),this.injectCSS(),this.on("create",this.options.onCreate),this.on("update",this.options.onUpdate),this.on("selectionUpdate",this.options.onSelectionUpdate),this.on("transaction",this.options.onTransaction),this.on("focus",this.options.onFocus),this.on("blur",this.options.onBlur),this.on("destroy",this.options.onDestroy),this.on("drop",({event:r,slice:o,moved:a})=>this.options.onDrop(r,o,a)),this.on("paste",({event:r,slice:o})=>this.options.onPaste(r,o)),window.setTimeout(()=>{this.isDestroyed||(this.commands.focus(this.options.autofocus),this.emit("create",{editor:this}),this.isInitialized=!0)},0)}get storage(){return this.extensionStorage}get commands(){return this.commandManager.commands}chain(){return this.commandManager.chain()}can(){return this.commandManager.can()}injectCSS(){this.options.injectCSS&&document&&(this.css=Cye(xye,this.options.injectNonce))}setOptions(t={}){this.options={...this.options,...t},!(!this.view||!this.state||this.isDestroyed)&&(this.options.editorProps&&this.view.setProps(this.options.editorProps),this.view.updateState(this.state))}setEditable(t,r=!0){this.setOptions({editable:t}),r&&this.emit("update",{editor:this,transaction:this.state.tr})}get isEditable(){return this.options.editable&&this.view&&this.view.editable}get state(){return this.view.state}registerPlugin(t,r){const o=qw(r)?r(t,[...this.state.plugins]):[...this.state.plugins,t],a=this.state.reconfigure({plugins:o});return this.view.updateState(a),a}unregisterPlugin(t){if(this.isDestroyed)return;const r=this.state.plugins;let o=r;if([].concat(t).forEach(i=>{const l=typeof i=="string"?`${i}$`:i.key;o=r.filter(s=>!s.key.startsWith(l))}),r.length===o.length)return;const a=this.state.reconfigure({plugins:o});return this.view.updateState(a),a}createExtensionManager(){var t,r;const a=[...this.options.enableCoreExtensions?[Mye,qve.configure({blockSeparator:(r=(t=this.options.coreExtensionOptions)===null||t===void 0?void 0:t.clipboardTextSerializer)===null||r===void 0?void 0:r.blockSeparator}),vye,bye,wye,kye,yye,Nye].filter(i=>typeof this.options.enableCoreExtensions=="object"?this.options.enableCoreExtensions[i.name]!==!1:!0):[],...this.options.extensions].filter(i=>["extension","node","mark"].includes(i==null?void 0:i.type));this.extensionManager=new Ni(a,this)}createCommandManager(){this.commandManager=new df({editor:this})}createSchema(){this.schema=this.extensionManager.schema}createView(){let t;try{t=V0(this.options.content,this.schema,this.options.parseOptions,{errorOnInvalidContent:this.options.enableContentCheck})}catch(i){if(!(i instanceof Error)||!["[tiptap error]: Invalid JSON content","[tiptap error]: Invalid HTML content"].includes(i.message))throw i;this.emit("contentError",{editor:this,error:i,disableCollaboration:()=>{this.storage.collaboration&&(this.storage.collaboration.isDisabled=!0),this.options.extensions=this.options.extensions.filter(l=>l.name!=="collaboration"),this.createExtensionManager()}}),t=V0(this.options.content,this.schema,this.options.parseOptions,{errorOnInvalidContent:!1})}const r=Jw(t,this.options.autofocus);this.view=new J4e(this.options.element,{...this.options.editorProps,dispatchTransaction:this.dispatchTransaction.bind(this),state:wi.create({doc:t,selection:r||void 0})}),this.view.dom.setAttribute("role","textbox"),this.view.dom.getAttribute("aria-label")||this.view.dom.setAttribute("aria-label","Rich-Text Editor");const o=this.state.reconfigure({plugins:this.extensionManager.plugins});this.view.updateState(o),this.createNodeViews(),this.prependClass();const a=this.view.dom;a.editor=this}createNodeViews(){this.view.isDestroyed||this.view.setProps({nodeViews:this.extensionManager.nodeViews})}prependClass(){this.view.dom.className=`tiptap ${this.view.dom.className}`}captureTransaction(t){this.isCapturingTransaction=!0,t(),this.isCapturingTransaction=!1;const r=this.capturedTransaction;return this.capturedTransaction=null,r}dispatchTransaction(t){if(this.view.isDestroyed)return;if(this.isCapturingTransaction){if(!this.capturedTransaction){this.capturedTransaction=t;return}t.steps.forEach(l=>{var s;return(s=this.capturedTransaction)===null||s===void 0?void 0:s.step(l)});return}const r=this.state.apply(t),o=!this.state.selection.eq(r.selection);this.emit("beforeTransaction",{editor:this,transaction:t,nextState:r}),this.view.updateState(r),this.emit("transaction",{editor:this,transaction:t}),o&&this.emit("selectionUpdate",{editor:this,transaction:t});const a=t.getMeta("focus"),i=t.getMeta("blur");a&&this.emit("focus",{editor:this,event:a.event,transaction:t}),i&&this.emit("blur",{editor:this,event:i.event,transaction:t}),!(!t.docChanged||t.getMeta("preventUpdate"))&&this.emit("update",{editor:this,transaction:t})}getAttributes(t){return tN(this.state,t)}isActive(t,r){const o=typeof t=="string"?t:null,a=typeof t=="string"?r:t;return G3e(this.state,o,a)}getJSON(){return this.state.doc.toJSON()}getHTML(){return U3e(this.state.doc.content,this.schema)}getText(t){const{blockSeparator:r=`
|
|
134
134
|
|
|
135
|
-
`,textSerializers:o={}}=t||{};return P3e(this.state.doc,{blockSeparator:r,textSerializers:{...Kw(this.schema),...o}})}get isEmpty(){return hf(this.state.doc)}getCharacterCount(){return console.warn('[tiptap warn]: "editor.getCharacterCount()" is deprecated. Please use "editor.storage.characterCount.characters()" instead.'),this.state.doc.content.size-2}destroy(){if(this.emit("destroy"),this.view){const t=this.view.dom;t&&t.editor&&delete t.editor,this.view.destroy()}this.removeAllListeners()}get isDestroyed(){var t;return!(!((t=this.view)===null||t===void 0)&&t.docView)}$node(t,r){var o;return((o=this.$doc)===null||o===void 0?void 0:o.querySelector(t,r))||null}$nodes(t,r){var o;return((o=this.$doc)===null||o===void 0?void 0:o.querySelectorAll(t,r))||null}$pos(t){const r=this.state.doc.resolve(t);return new ba(r,this)}get $doc(){return this.$pos(0)}};function Fu(e){return new o2({find:e.find,handler:({state:t,range:r,match:o})=>{const a=Je(e.getAttributes,void 0,o);if(a===!1||a===null)return null;const{tr:i}=t,l=o[o.length-1],s=o[0];if(l){const c=s.search(/\S/),u=r.from+s.indexOf(l),d=u+l.length;if(c2(r.from,r.to,t.doc).filter(h=>h.mark.type.excluded.find(g=>g===e.type&&g!==h.mark.type)).filter(h=>h.to>u).length)return null;d<r.to&&i.delete(d,r.to),u>r.from&&i.delete(r.from+c,u);const p=r.from+c+l.length;i.addMark(r.from+c,p,e.type.create(a||{})),i.removeStoredMark(e.type)}}})}function kye(e){return new o2({find:e.find,handler:({state:t,range:r,match:o})=>{const a=t.doc.resolve(r.from),i=Je(e.getAttributes,void 0,o)||{};if(!a.node(-1).canReplaceWith(a.index(-1),a.indexAfter(-1),e.type))return null;t.tr.delete(r.from,r.to).setBlockType(r.from,r.from,e.type,i)}})}function _s(e){return new o2({find:e.find,handler:({state:t,range:r,match:o,chain:a})=>{const i=Je(e.getAttributes,void 0,o)||{},l=t.tr.delete(r.from,r.to),c=l.doc.resolve(r.from).blockRange(),u=c&&Yh(c,e.type,i);if(!u)return null;if(l.wrap(c,u),e.keepMarks&&e.editor){const{selection:f,storedMarks:p}=t,{splittableMarks:h}=e.editor.extensionManager,m=p||f.$to.parentOffset&&f.$from.marks();if(m){const g=m.filter(v=>h.includes(v.type.name));l.ensureMarks(g)}}if(e.keepAttributes){const f=e.type.name==="bulletList"||e.type.name==="orderedList"?"listItem":"taskList";a().updateAttributes(f,i).run()}const d=l.doc.resolve(r.from-1).nodeBefore;d&&d.type===e.type&&la(l.doc,r.from-1)&&(!e.joinPredicate||e.joinPredicate(o,d))&&l.join(r.from-1)}})}class pr{constructor(t={}){this.type="node",this.name="node",this.parent=null,this.child=null,this.config={name:this.name,defaultOptions:{}},this.config={...this.config,...t},this.name=this.config.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${this.name}".`),this.options=this.config.defaultOptions,this.config.addOptions&&(this.options=Je(Ie(this,"addOptions",{name:this.name}))),this.storage=Je(Ie(this,"addStorage",{name:this.name,options:this.options}))||{}}static create(t={}){return new pr(t)}configure(t={}){const r=this.extend({...this.config,addOptions:()=>pf(this.options,t)});return r.name=this.name,r.parent=this.parent,r}extend(t={}){const r=new pr(t);return r.parent=this,this.child=r,r.name=t.name?t.name:r.parent.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${r.name}".`),r.options=Je(Ie(r,"addOptions",{name:r.name})),r.storage=Je(Ie(r,"addStorage",{name:r.name,options:r.options})),r}}function Is(e){return new Vve({find:e.find,handler:({state:t,range:r,match:o,pasteEvent:a})=>{const i=Je(e.getAttributes,void 0,o,a);if(i===!1||i===null)return null;const{tr:l}=t,s=o[o.length-1],c=o[0];let u=r.to;if(s){const d=c.search(/\S/),f=r.from+c.indexOf(s),p=f+s.length;if(c2(r.from,r.to,t.doc).filter(m=>m.mark.type.excluded.find(v=>v===e.type&&v!==m.mark.type)).filter(m=>m.to>f).length)return null;p<r.to&&l.delete(p,r.to),f>r.from&&l.delete(r.from+d,f),u=r.from+d+s.length,l.addMark(r.from+d,u,e.type.create(i||{})),l.removeStoredMark(e.type)}}})}var On="top",mr="bottom",hr="right",zn="left",u2="auto",ec=[On,mr,hr,zn],Ki="start",As="end",xye="clippingParents",rN="viewport",Tl="popper",Cye="reference",$v=ec.reduce(function(e,t){return e.concat([t+"-"+Ki,t+"-"+As])},[]),oN=[].concat(ec,[u2]).reduce(function(e,t){return e.concat([t,t+"-"+Ki,t+"-"+As])},[]),Eye="beforeRead",Tye="read",Dye="afterRead",Sye="beforeMain",_ye="main",Iye="afterMain",Aye="beforeWrite",Oye="write",zye="afterWrite",jye=[Eye,Tye,Dye,Sye,_ye,Iye,Aye,Oye,zye];function ao(e){return e?(e.nodeName||"").toLowerCase():null}function qn(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Ua(e){var t=qn(e).Element;return e instanceof t||e instanceof Element}function ir(e){var t=qn(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function d2(e){if(typeof ShadowRoot>"u")return!1;var t=qn(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Lye(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var o=t.styles[r]||{},a=t.attributes[r]||{},i=t.elements[r];!ir(i)||!ao(i)||(Object.assign(i.style,o),Object.keys(a).forEach(function(l){var s=a[l];s===!1?i.removeAttribute(l):i.setAttribute(l,s===!0?"":s)}))})}function Bye(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(o){var a=t.elements[o],i=t.attributes[o]||{},l=Object.keys(t.styles.hasOwnProperty(o)?t.styles[o]:r[o]),s=l.reduce(function(c,u){return c[u]="",c},{});!ir(a)||!ao(a)||(Object.assign(a.style,s),Object.keys(i).forEach(function(c){a.removeAttribute(c)}))})}}const aN={name:"applyStyles",enabled:!0,phase:"write",fn:Lye,effect:Bye,requires:["computeStyles"]};function Xr(e){return e.split("-")[0]}var za=Math.max,Uu=Math.min,Ji=Math.round;function P0(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function iN(){return!/^((?!chrome|android).)*safari/i.test(P0())}function Zi(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var o=e.getBoundingClientRect(),a=1,i=1;t&&ir(e)&&(a=e.offsetWidth>0&&Ji(o.width)/e.offsetWidth||1,i=e.offsetHeight>0&&Ji(o.height)/e.offsetHeight||1);var l=Ua(e)?qn(e):window,s=l.visualViewport,c=!iN()&&r,u=(o.left+(c&&s?s.offsetLeft:0))/a,d=(o.top+(c&&s?s.offsetTop:0))/i,f=o.width/a,p=o.height/i;return{width:f,height:p,top:d,right:u+f,bottom:d+p,left:u,x:u,y:d}}function f2(e){var t=Zi(e),r=e.offsetWidth,o=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-o)<=1&&(o=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:o}}function lN(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&d2(r)){var o=t;do{if(o&&e.isSameNode(o))return!0;o=o.parentNode||o.host}while(o)}return!1}function No(e){return qn(e).getComputedStyle(e)}function Vye(e){return["table","td","th"].indexOf(ao(e))>=0}function ua(e){return((Ua(e)?e.ownerDocument:e.document)||window.document).documentElement}function gf(e){return ao(e)==="html"?e:e.assignedSlot||e.parentNode||(d2(e)?e.host:null)||ua(e)}function Pv(e){return!ir(e)||No(e).position==="fixed"?null:e.offsetParent}function $ye(e){var t=/firefox/i.test(P0()),r=/Trident/i.test(P0());if(r&&ir(e)){var o=No(e);if(o.position==="fixed")return null}var a=gf(e);for(d2(a)&&(a=a.host);ir(a)&&["html","body"].indexOf(ao(a))<0;){var i=No(a);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return a;a=a.parentNode}return null}function tc(e){for(var t=qn(e),r=Pv(e);r&&Vye(r)&&No(r).position==="static";)r=Pv(r);return r&&(ao(r)==="html"||ao(r)==="body"&&No(r).position==="static")?t:r||$ye(e)||t}function p2(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ql(e,t,r){return za(e,Uu(t,r))}function Pye(e,t,r){var o=ql(e,t,r);return o>r?r:o}function sN(){return{top:0,right:0,bottom:0,left:0}}function cN(e){return Object.assign({},sN(),e)}function uN(e,t){return t.reduce(function(r,o){return r[o]=e,r},{})}var Rye=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,cN(typeof t!="number"?t:uN(t,ec))};function Fye(e){var t,r=e.state,o=e.name,a=e.options,i=r.elements.arrow,l=r.modifiersData.popperOffsets,s=Xr(r.placement),c=p2(s),u=[zn,hr].indexOf(s)>=0,d=u?"height":"width";if(!(!i||!l)){var f=Rye(a.padding,r),p=f2(i),h=c==="y"?On:zn,m=c==="y"?mr:hr,g=r.rects.reference[d]+r.rects.reference[c]-l[c]-r.rects.popper[d],v=l[c]-r.rects.reference[c],y=tc(i),N=y?c==="y"?y.clientHeight||0:y.clientWidth||0:0,b=g/2-v/2,M=f[h],k=N-p[d]-f[m],w=N/2-p[d]/2+b,C=ql(M,w,k),E=c;r.modifiersData[o]=(t={},t[E]=C,t.centerOffset=C-w,t)}}function Uye(e){var t=e.state,r=e.options,o=r.element,a=o===void 0?"[data-popper-arrow]":o;a!=null&&(typeof a=="string"&&(a=t.elements.popper.querySelector(a),!a)||lN(t.elements.popper,a)&&(t.elements.arrow=a))}const Hye={name:"arrow",enabled:!0,phase:"main",fn:Fye,effect:Uye,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Xi(e){return e.split("-")[1]}var Yye={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Qye(e,t){var r=e.x,o=e.y,a=t.devicePixelRatio||1;return{x:Ji(r*a)/a||0,y:Ji(o*a)/a||0}}function Rv(e){var t,r=e.popper,o=e.popperRect,a=e.placement,i=e.variation,l=e.offsets,s=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,f=e.isFixed,p=l.x,h=p===void 0?0:p,m=l.y,g=m===void 0?0:m,v=typeof d=="function"?d({x:h,y:g}):{x:h,y:g};h=v.x,g=v.y;var y=l.hasOwnProperty("x"),N=l.hasOwnProperty("y"),b=zn,M=On,k=window;if(u){var w=tc(r),C="clientHeight",E="clientWidth";if(w===qn(r)&&(w=ua(r),No(w).position!=="static"&&s==="absolute"&&(C="scrollHeight",E="scrollWidth")),w=w,a===On||(a===zn||a===hr)&&i===As){M=mr;var A=f&&w===k&&k.visualViewport?k.visualViewport.height:w[C];g-=A-o.height,g*=c?1:-1}if(a===zn||(a===On||a===mr)&&i===As){b=hr;var O=f&&w===k&&k.visualViewport?k.visualViewport.width:w[E];h-=O-o.width,h*=c?1:-1}}var _=Object.assign({position:s},u&&Yye),j=d===!0?Qye({x:h,y:g},qn(r)):{x:h,y:g};if(h=j.x,g=j.y,c){var R;return Object.assign({},_,(R={},R[M]=N?"0":"",R[b]=y?"0":"",R.transform=(k.devicePixelRatio||1)<=1?"translate("+h+"px, "+g+"px)":"translate3d("+h+"px, "+g+"px, 0)",R))}return Object.assign({},_,(t={},t[M]=N?g+"px":"",t[b]=y?h+"px":"",t.transform="",t))}function Wye(e){var t=e.state,r=e.options,o=r.gpuAcceleration,a=o===void 0?!0:o,i=r.adaptive,l=i===void 0?!0:i,s=r.roundOffsets,c=s===void 0?!0:s,u={placement:Xr(t.placement),variation:Xi(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:a,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Rv(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:l,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Rv(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const qye={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Wye,data:{}};var Sc={passive:!0};function Gye(e){var t=e.state,r=e.instance,o=e.options,a=o.scroll,i=a===void 0?!0:a,l=o.resize,s=l===void 0?!0:l,c=qn(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach(function(d){d.addEventListener("scroll",r.update,Sc)}),s&&c.addEventListener("resize",r.update,Sc),function(){i&&u.forEach(function(d){d.removeEventListener("scroll",r.update,Sc)}),s&&c.removeEventListener("resize",r.update,Sc)}}const Kye={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Gye,data:{}};var Jye={left:"right",right:"left",bottom:"top",top:"bottom"};function Kc(e){return e.replace(/left|right|bottom|top/g,function(t){return Jye[t]})}var Zye={start:"end",end:"start"};function Fv(e){return e.replace(/start|end/g,function(t){return Zye[t]})}function m2(e){var t=qn(e),r=t.pageXOffset,o=t.pageYOffset;return{scrollLeft:r,scrollTop:o}}function h2(e){return Zi(ua(e)).left+m2(e).scrollLeft}function Xye(e,t){var r=qn(e),o=ua(e),a=r.visualViewport,i=o.clientWidth,l=o.clientHeight,s=0,c=0;if(a){i=a.width,l=a.height;var u=iN();(u||!u&&t==="fixed")&&(s=a.offsetLeft,c=a.offsetTop)}return{width:i,height:l,x:s+h2(e),y:c}}function eMe(e){var t,r=ua(e),o=m2(e),a=(t=e.ownerDocument)==null?void 0:t.body,i=za(r.scrollWidth,r.clientWidth,a?a.scrollWidth:0,a?a.clientWidth:0),l=za(r.scrollHeight,r.clientHeight,a?a.scrollHeight:0,a?a.clientHeight:0),s=-o.scrollLeft+h2(e),c=-o.scrollTop;return No(a||r).direction==="rtl"&&(s+=za(r.clientWidth,a?a.clientWidth:0)-i),{width:i,height:l,x:s,y:c}}function g2(e){var t=No(e),r=t.overflow,o=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+a+o)}function dN(e){return["html","body","#document"].indexOf(ao(e))>=0?e.ownerDocument.body:ir(e)&&g2(e)?e:dN(gf(e))}function Gl(e,t){var r;t===void 0&&(t=[]);var o=dN(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),i=qn(o),l=a?[i].concat(i.visualViewport||[],g2(o)?o:[]):o,s=t.concat(l);return a?s:s.concat(Gl(gf(l)))}function R0(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function tMe(e,t){var r=Zi(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function Uv(e,t,r){return t===rN?R0(Xye(e,r)):Ua(t)?tMe(t,r):R0(eMe(ua(e)))}function nMe(e){var t=Gl(gf(e)),r=["absolute","fixed"].indexOf(No(e).position)>=0,o=r&&ir(e)?tc(e):e;return Ua(o)?t.filter(function(a){return Ua(a)&&lN(a,o)&&ao(a)!=="body"}):[]}function rMe(e,t,r,o){var a=t==="clippingParents"?nMe(e):[].concat(t),i=[].concat(a,[r]),l=i[0],s=i.reduce(function(c,u){var d=Uv(e,u,o);return c.top=za(d.top,c.top),c.right=Uu(d.right,c.right),c.bottom=Uu(d.bottom,c.bottom),c.left=za(d.left,c.left),c},Uv(e,l,o));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function fN(e){var t=e.reference,r=e.element,o=e.placement,a=o?Xr(o):null,i=o?Xi(o):null,l=t.x+t.width/2-r.width/2,s=t.y+t.height/2-r.height/2,c;switch(a){case On:c={x:l,y:t.y-r.height};break;case mr:c={x:l,y:t.y+t.height};break;case hr:c={x:t.x+t.width,y:s};break;case zn:c={x:t.x-r.width,y:s};break;default:c={x:t.x,y:t.y}}var u=a?p2(a):null;if(u!=null){var d=u==="y"?"height":"width";switch(i){case Ki:c[u]=c[u]-(t[d]/2-r[d]/2);break;case As:c[u]=c[u]+(t[d]/2-r[d]/2);break}}return c}function Os(e,t){t===void 0&&(t={});var r=t,o=r.placement,a=o===void 0?e.placement:o,i=r.strategy,l=i===void 0?e.strategy:i,s=r.boundary,c=s===void 0?xye:s,u=r.rootBoundary,d=u===void 0?rN:u,f=r.elementContext,p=f===void 0?Tl:f,h=r.altBoundary,m=h===void 0?!1:h,g=r.padding,v=g===void 0?0:g,y=cN(typeof v!="number"?v:uN(v,ec)),N=p===Tl?Cye:Tl,b=e.rects.popper,M=e.elements[m?N:p],k=rMe(Ua(M)?M:M.contextElement||ua(e.elements.popper),c,d,l),w=Zi(e.elements.reference),C=fN({reference:w,element:b,strategy:"absolute",placement:a}),E=R0(Object.assign({},b,C)),A=p===Tl?E:w,O={top:k.top-A.top+y.top,bottom:A.bottom-k.bottom+y.bottom,left:k.left-A.left+y.left,right:A.right-k.right+y.right},_=e.modifiersData.offset;if(p===Tl&&_){var j=_[a];Object.keys(O).forEach(function(R){var P=[hr,mr].indexOf(R)>=0?1:-1,$=[On,mr].indexOf(R)>=0?"y":"x";O[R]+=j[$]*P})}return O}function oMe(e,t){t===void 0&&(t={});var r=t,o=r.placement,a=r.boundary,i=r.rootBoundary,l=r.padding,s=r.flipVariations,c=r.allowedAutoPlacements,u=c===void 0?oN:c,d=Xi(o),f=d?s?$v:$v.filter(function(m){return Xi(m)===d}):ec,p=f.filter(function(m){return u.indexOf(m)>=0});p.length===0&&(p=f);var h=p.reduce(function(m,g){return m[g]=Os(e,{placement:g,boundary:a,rootBoundary:i,padding:l})[Xr(g)],m},{});return Object.keys(h).sort(function(m,g){return h[m]-h[g]})}function aMe(e){if(Xr(e)===u2)return[];var t=Kc(e);return[Fv(e),t,Fv(t)]}function iMe(e){var t=e.state,r=e.options,o=e.name;if(!t.modifiersData[o]._skip){for(var a=r.mainAxis,i=a===void 0?!0:a,l=r.altAxis,s=l===void 0?!0:l,c=r.fallbackPlacements,u=r.padding,d=r.boundary,f=r.rootBoundary,p=r.altBoundary,h=r.flipVariations,m=h===void 0?!0:h,g=r.allowedAutoPlacements,v=t.options.placement,y=Xr(v),N=y===v,b=c||(N||!m?[Kc(v)]:aMe(v)),M=[v].concat(b).reduce(function(z,I){return z.concat(Xr(I)===u2?oMe(t,{placement:I,boundary:d,rootBoundary:f,padding:u,flipVariations:m,allowedAutoPlacements:g}):I)},[]),k=t.rects.reference,w=t.rects.popper,C=new Map,E=!0,A=M[0],O=0;O<M.length;O++){var _=M[O],j=Xr(_),R=Xi(_)===Ki,P=[On,mr].indexOf(j)>=0,$=P?"width":"height",V=Os(t,{placement:_,boundary:d,rootBoundary:f,altBoundary:p,padding:u}),D=P?R?hr:zn:R?mr:On;k[$]>w[$]&&(D=Kc(D));var x=Kc(D),S=[];if(i&&S.push(V[j]<=0),s&&S.push(V[D]<=0,V[x]<=0),S.every(function(z){return z})){A=_,E=!1;break}C.set(_,S)}if(E)for(var L=m?3:1,B=function(I){var Z=M.find(function(q){var te=C.get(q);if(te)return te.slice(0,I).every(function(J){return J})});if(Z)return A=Z,"break"},F=L;F>0;F--){var T=B(F);if(T==="break")break}t.placement!==A&&(t.modifiersData[o]._skip=!0,t.placement=A,t.reset=!0)}}const lMe={name:"flip",enabled:!0,phase:"main",fn:iMe,requiresIfExists:["offset"],data:{_skip:!1}};function Hv(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Yv(e){return[On,hr,mr,zn].some(function(t){return e[t]>=0})}function sMe(e){var t=e.state,r=e.name,o=t.rects.reference,a=t.rects.popper,i=t.modifiersData.preventOverflow,l=Os(t,{elementContext:"reference"}),s=Os(t,{altBoundary:!0}),c=Hv(l,o),u=Hv(s,a,i),d=Yv(c),f=Yv(u);t.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":f})}const cMe={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:sMe};function uMe(e,t,r){var o=Xr(e),a=[zn,On].indexOf(o)>=0?-1:1,i=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,l=i[0],s=i[1];return l=l||0,s=(s||0)*a,[zn,hr].indexOf(o)>=0?{x:s,y:l}:{x:l,y:s}}function dMe(e){var t=e.state,r=e.options,o=e.name,a=r.offset,i=a===void 0?[0,0]:a,l=oN.reduce(function(d,f){return d[f]=uMe(f,t.rects,i),d},{}),s=l[t.placement],c=s.x,u=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=u),t.modifiersData[o]=l}const fMe={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:dMe};function pMe(e){var t=e.state,r=e.name;t.modifiersData[r]=fN({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const mMe={name:"popperOffsets",enabled:!0,phase:"read",fn:pMe,data:{}};function hMe(e){return e==="x"?"y":"x"}function gMe(e){var t=e.state,r=e.options,o=e.name,a=r.mainAxis,i=a===void 0?!0:a,l=r.altAxis,s=l===void 0?!1:l,c=r.boundary,u=r.rootBoundary,d=r.altBoundary,f=r.padding,p=r.tether,h=p===void 0?!0:p,m=r.tetherOffset,g=m===void 0?0:m,v=Os(t,{boundary:c,rootBoundary:u,padding:f,altBoundary:d}),y=Xr(t.placement),N=Xi(t.placement),b=!N,M=p2(y),k=hMe(M),w=t.modifiersData.popperOffsets,C=t.rects.reference,E=t.rects.popper,A=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,O=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),_=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,j={x:0,y:0};if(w){if(i){var R,P=M==="y"?On:zn,$=M==="y"?mr:hr,V=M==="y"?"height":"width",D=w[M],x=D+v[P],S=D-v[$],L=h?-E[V]/2:0,B=N===Ki?C[V]:E[V],F=N===Ki?-E[V]:-C[V],T=t.elements.arrow,z=h&&T?f2(T):{width:0,height:0},I=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:sN(),Z=I[P],q=I[$],te=ql(0,C[V],z[V]),J=b?C[V]/2-L-te-Z-O.mainAxis:B-te-Z-O.mainAxis,W=b?-C[V]/2+L+te+q+O.mainAxis:F+te+q+O.mainAxis,ae=t.elements.arrow&&tc(t.elements.arrow),ce=ae?M==="y"?ae.clientTop||0:ae.clientLeft||0:0,ye=(R=_==null?void 0:_[M])!=null?R:0,Ae=D+J-ye-ce,Fe=D+W-ye,_e=ql(h?Uu(x,Ae):x,D,h?za(S,Fe):S);w[M]=_e,j[M]=_e-D}if(s){var Le,Ye=M==="x"?On:zn,Ke=M==="x"?mr:hr,Be=w[k],et=k==="y"?"height":"width",lt=Be+v[Ye],je=Be-v[Ke],H=[On,zn].indexOf(y)!==-1,G=(Le=_==null?void 0:_[k])!=null?Le:0,ze=H?lt:Be-C[et]-E[et]-G+O.altAxis,pe=H?Be+C[et]+E[et]-G-O.altAxis:je,we=h&&H?Pye(ze,Be,pe):ql(h?ze:lt,Be,h?pe:je);w[k]=we,j[k]=we-Be}t.modifiersData[o]=j}}const vMe={name:"preventOverflow",enabled:!0,phase:"main",fn:gMe,requiresIfExists:["offset"]};function yMe(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function MMe(e){return e===qn(e)||!ir(e)?m2(e):yMe(e)}function bMe(e){var t=e.getBoundingClientRect(),r=Ji(t.width)/e.offsetWidth||1,o=Ji(t.height)/e.offsetHeight||1;return r!==1||o!==1}function wMe(e,t,r){r===void 0&&(r=!1);var o=ir(t),a=ir(t)&&bMe(t),i=ua(t),l=Zi(e,a,r),s={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(o||!o&&!r)&&((ao(t)!=="body"||g2(i))&&(s=MMe(t)),ir(t)?(c=Zi(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):i&&(c.x=h2(i))),{x:l.left+s.scrollLeft-c.x,y:l.top+s.scrollTop-c.y,width:l.width,height:l.height}}function NMe(e){var t=new Map,r=new Set,o=[];e.forEach(function(i){t.set(i.name,i)});function a(i){r.add(i.name);var l=[].concat(i.requires||[],i.requiresIfExists||[]);l.forEach(function(s){if(!r.has(s)){var c=t.get(s);c&&a(c)}}),o.push(i)}return e.forEach(function(i){r.has(i.name)||a(i)}),o}function kMe(e){var t=NMe(e);return jye.reduce(function(r,o){return r.concat(t.filter(function(a){return a.phase===o}))},[])}function xMe(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function CMe(e){var t=e.reduce(function(r,o){var a=r[o.name];return r[o.name]=a?Object.assign({},a,o,{options:Object.assign({},a.options,o.options),data:Object.assign({},a.data,o.data)}):o,r},{});return Object.keys(t).map(function(r){return t[r]})}var Qv={placement:"bottom",modifiers:[],strategy:"absolute"};function Wv(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(o){return!(o&&typeof o.getBoundingClientRect=="function")})}function EMe(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,o=r===void 0?[]:r,a=t.defaultOptions,i=a===void 0?Qv:a;return function(s,c,u){u===void 0&&(u=i);var d={placement:"bottom",orderedModifiers:[],options:Object.assign({},Qv,i),modifiersData:{},elements:{reference:s,popper:c},attributes:{},styles:{}},f=[],p=!1,h={state:d,setOptions:function(y){var N=typeof y=="function"?y(d.options):y;g(),d.options=Object.assign({},i,d.options,N),d.scrollParents={reference:Ua(s)?Gl(s):s.contextElement?Gl(s.contextElement):[],popper:Gl(c)};var b=kMe(CMe([].concat(o,d.options.modifiers)));return d.orderedModifiers=b.filter(function(M){return M.enabled}),m(),h.update()},forceUpdate:function(){if(!p){var y=d.elements,N=y.reference,b=y.popper;if(Wv(N,b)){d.rects={reference:wMe(N,tc(b),d.options.strategy==="fixed"),popper:f2(b)},d.reset=!1,d.placement=d.options.placement,d.orderedModifiers.forEach(function(O){return d.modifiersData[O.name]=Object.assign({},O.data)});for(var M=0;M<d.orderedModifiers.length;M++){if(d.reset===!0){d.reset=!1,M=-1;continue}var k=d.orderedModifiers[M],w=k.fn,C=k.options,E=C===void 0?{}:C,A=k.name;typeof w=="function"&&(d=w({state:d,options:E,name:A,instance:h})||d)}}}},update:xMe(function(){return new Promise(function(v){h.forceUpdate(),v(d)})}),destroy:function(){g(),p=!0}};if(!Wv(s,c))return h;h.setOptions(u).then(function(v){!p&&u.onFirstUpdate&&u.onFirstUpdate(v)});function m(){d.orderedModifiers.forEach(function(v){var y=v.name,N=v.options,b=N===void 0?{}:N,M=v.effect;if(typeof M=="function"){var k=M({state:d,name:y,instance:h,options:b}),w=function(){};f.push(k||w)}})}function g(){f.forEach(function(v){return v()}),f=[]}return h}}var TMe=[Kye,mMe,qye,aN,fMe,lMe,vMe,Hye,cMe],DMe=EMe({defaultModifiers:TMe}),SMe="tippy-box",pN="tippy-content",_Me="tippy-backdrop",mN="tippy-arrow",hN="tippy-svg-arrow",ya={passive:!0,capture:!0},gN=function(){return document.body};function IMe(e,t){return{}.hasOwnProperty.call(e,t)}function dp(e,t,r){if(Array.isArray(e)){var o=e[t];return o??(Array.isArray(r)?r[t]:r)}return e}function v2(e,t){var r={}.toString.call(e);return r.indexOf("[object")===0&&r.indexOf(t+"]")>-1}function vN(e,t){return typeof e=="function"?e.apply(void 0,t):e}function qv(e,t){if(t===0)return e;var r;return function(o){clearTimeout(r),r=setTimeout(function(){e(o)},t)}}function AMe(e,t){var r=Object.assign({},e);return t.forEach(function(o){delete r[o]}),r}function OMe(e){return e.split(/\s+/).filter(Boolean)}function vi(e){return[].concat(e)}function Gv(e,t){e.indexOf(t)===-1&&e.push(t)}function zMe(e){return e.filter(function(t,r){return e.indexOf(t)===r})}function jMe(e){return e.split("-")[0]}function Hu(e){return[].slice.call(e)}function Kv(e){return Object.keys(e).reduce(function(t,r){return e[r]!==void 0&&(t[r]=e[r]),t},{})}function Kl(){return document.createElement("div")}function zs(e){return["Element","Fragment"].some(function(t){return v2(e,t)})}function LMe(e){return v2(e,"NodeList")}function BMe(e){return v2(e,"MouseEvent")}function VMe(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function $Me(e){return zs(e)?[e]:LMe(e)?Hu(e):Array.isArray(e)?e:Hu(document.querySelectorAll(e))}function fp(e,t){e.forEach(function(r){r&&(r.style.transitionDuration=t+"ms")})}function Jv(e,t){e.forEach(function(r){r&&r.setAttribute("data-state",t)})}function PMe(e){var t,r=vi(e),o=r[0];return o!=null&&(t=o.ownerDocument)!=null&&t.body?o.ownerDocument:document}function RMe(e,t){var r=t.clientX,o=t.clientY;return e.every(function(a){var i=a.popperRect,l=a.popperState,s=a.props,c=s.interactiveBorder,u=jMe(l.placement),d=l.modifiersData.offset;if(!d)return!0;var f=u==="bottom"?d.top.y:0,p=u==="top"?d.bottom.y:0,h=u==="right"?d.left.x:0,m=u==="left"?d.right.x:0,g=i.top-o+f>c,v=o-i.bottom-p>c,y=i.left-r+h>c,N=r-i.right-m>c;return g||v||y||N})}function pp(e,t,r){var o=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(a){e[o](a,r)})}function Zv(e,t){for(var r=t;r;){var o;if(e.contains(r))return!0;r=r.getRootNode==null||(o=r.getRootNode())==null?void 0:o.host}return!1}var qr={isTouch:!1},Xv=0;function FMe(){qr.isTouch||(qr.isTouch=!0,window.performance&&document.addEventListener("mousemove",yN))}function yN(){var e=performance.now();e-Xv<20&&(qr.isTouch=!1,document.removeEventListener("mousemove",yN)),Xv=e}function UMe(){var e=document.activeElement;if(VMe(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function HMe(){document.addEventListener("touchstart",FMe,ya),window.addEventListener("blur",UMe)}var YMe=typeof window<"u"&&typeof document<"u",QMe=YMe?!!window.msCrypto:!1;function di(e){var t=e==="destroy"?"n already-":" ";return[e+"() was called on a"+t+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function e3(e){var t=/[ \t]{2,}/g,r=/^[ \t]*/gm;return e.replace(t," ").replace(r,"").trim()}function WMe(e){return e3(`
|
|
135
|
+
`,textSerializers:o={}}=t||{};return H3e(this.state.doc,{blockSeparator:r,textSerializers:{...Kw(this.schema),...o}})}get isEmpty(){return hf(this.state.doc)}getCharacterCount(){return console.warn('[tiptap warn]: "editor.getCharacterCount()" is deprecated. Please use "editor.storage.characterCount.characters()" instead.'),this.state.doc.content.size-2}destroy(){if(this.emit("destroy"),this.view){const t=this.view.dom;t&&t.editor&&delete t.editor,this.view.destroy()}this.removeAllListeners()}get isDestroyed(){var t;return!(!((t=this.view)===null||t===void 0)&&t.docView)}$node(t,r){var o;return((o=this.$doc)===null||o===void 0?void 0:o.querySelector(t,r))||null}$nodes(t,r){var o;return((o=this.$doc)===null||o===void 0?void 0:o.querySelectorAll(t,r))||null}$pos(t){const r=this.state.doc.resolve(t);return new ba(r,this)}get $doc(){return this.$pos(0)}};function Fu(e){return new o2({find:e.find,handler:({state:t,range:r,match:o})=>{const a=Je(e.getAttributes,void 0,o);if(a===!1||a===null)return null;const{tr:i}=t,l=o[o.length-1],s=o[0];if(l){const c=s.search(/\S/),u=r.from+s.indexOf(l),d=u+l.length;if(c2(r.from,r.to,t.doc).filter(h=>h.mark.type.excluded.find(g=>g===e.type&&g!==h.mark.type)).filter(h=>h.to>u).length)return null;d<r.to&&i.delete(d,r.to),u>r.from&&i.delete(r.from+c,u);const p=r.from+c+l.length;i.addMark(r.from+c,p,e.type.create(a||{})),i.removeStoredMark(e.type)}}})}function Tye(e){return new o2({find:e.find,handler:({state:t,range:r,match:o})=>{const a=t.doc.resolve(r.from),i=Je(e.getAttributes,void 0,o)||{};if(!a.node(-1).canReplaceWith(a.index(-1),a.indexAfter(-1),e.type))return null;t.tr.delete(r.from,r.to).setBlockType(r.from,r.from,e.type,i)}})}function _s(e){return new o2({find:e.find,handler:({state:t,range:r,match:o,chain:a})=>{const i=Je(e.getAttributes,void 0,o)||{},l=t.tr.delete(r.from,r.to),c=l.doc.resolve(r.from).blockRange(),u=c&&Yh(c,e.type,i);if(!u)return null;if(l.wrap(c,u),e.keepMarks&&e.editor){const{selection:f,storedMarks:p}=t,{splittableMarks:h}=e.editor.extensionManager,m=p||f.$to.parentOffset&&f.$from.marks();if(m){const g=m.filter(v=>h.includes(v.type.name));l.ensureMarks(g)}}if(e.keepAttributes){const f=e.type.name==="bulletList"||e.type.name==="orderedList"?"listItem":"taskList";a().updateAttributes(f,i).run()}const d=l.doc.resolve(r.from-1).nodeBefore;d&&d.type===e.type&&la(l.doc,r.from-1)&&(!e.joinPredicate||e.joinPredicate(o,d))&&l.join(r.from-1)}})}class pr{constructor(t={}){this.type="node",this.name="node",this.parent=null,this.child=null,this.config={name:this.name,defaultOptions:{}},this.config={...this.config,...t},this.name=this.config.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${this.name}".`),this.options=this.config.defaultOptions,this.config.addOptions&&(this.options=Je(Ie(this,"addOptions",{name:this.name}))),this.storage=Je(Ie(this,"addStorage",{name:this.name,options:this.options}))||{}}static create(t={}){return new pr(t)}configure(t={}){const r=this.extend({...this.config,addOptions:()=>pf(this.options,t)});return r.name=this.name,r.parent=this.parent,r}extend(t={}){const r=new pr(t);return r.parent=this,this.child=r,r.name=t.name?t.name:r.parent.name,t.defaultOptions&&Object.keys(t.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${r.name}".`),r.options=Je(Ie(r,"addOptions",{name:r.name})),r.storage=Je(Ie(r,"addStorage",{name:r.name,options:r.options})),r}}function Is(e){return new Fve({find:e.find,handler:({state:t,range:r,match:o,pasteEvent:a})=>{const i=Je(e.getAttributes,void 0,o,a);if(i===!1||i===null)return null;const{tr:l}=t,s=o[o.length-1],c=o[0];let u=r.to;if(s){const d=c.search(/\S/),f=r.from+c.indexOf(s),p=f+s.length;if(c2(r.from,r.to,t.doc).filter(m=>m.mark.type.excluded.find(v=>v===e.type&&v!==m.mark.type)).filter(m=>m.to>f).length)return null;p<r.to&&l.delete(p,r.to),f>r.from&&l.delete(r.from+d,f),u=r.from+d+s.length,l.addMark(r.from+d,u,e.type.create(i||{})),l.removeStoredMark(e.type)}}})}var On="top",mr="bottom",hr="right",zn="left",u2="auto",ec=[On,mr,hr,zn],Ki="start",As="end",Dye="clippingParents",rN="viewport",Tl="popper",Sye="reference",$v=ec.reduce(function(e,t){return e.concat([t+"-"+Ki,t+"-"+As])},[]),oN=[].concat(ec,[u2]).reduce(function(e,t){return e.concat([t,t+"-"+Ki,t+"-"+As])},[]),_ye="beforeRead",Iye="read",Aye="afterRead",Oye="beforeMain",zye="main",jye="afterMain",Lye="beforeWrite",Bye="write",Vye="afterWrite",$ye=[_ye,Iye,Aye,Oye,zye,jye,Lye,Bye,Vye];function ao(e){return e?(e.nodeName||"").toLowerCase():null}function qn(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Ua(e){var t=qn(e).Element;return e instanceof t||e instanceof Element}function ir(e){var t=qn(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function d2(e){if(typeof ShadowRoot>"u")return!1;var t=qn(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function Pye(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var o=t.styles[r]||{},a=t.attributes[r]||{},i=t.elements[r];!ir(i)||!ao(i)||(Object.assign(i.style,o),Object.keys(a).forEach(function(l){var s=a[l];s===!1?i.removeAttribute(l):i.setAttribute(l,s===!0?"":s)}))})}function Rye(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(o){var a=t.elements[o],i=t.attributes[o]||{},l=Object.keys(t.styles.hasOwnProperty(o)?t.styles[o]:r[o]),s=l.reduce(function(c,u){return c[u]="",c},{});!ir(a)||!ao(a)||(Object.assign(a.style,s),Object.keys(i).forEach(function(c){a.removeAttribute(c)}))})}}const aN={name:"applyStyles",enabled:!0,phase:"write",fn:Pye,effect:Rye,requires:["computeStyles"]};function Xr(e){return e.split("-")[0]}var za=Math.max,Uu=Math.min,Ji=Math.round;function P0(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function iN(){return!/^((?!chrome|android).)*safari/i.test(P0())}function Zi(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var o=e.getBoundingClientRect(),a=1,i=1;t&&ir(e)&&(a=e.offsetWidth>0&&Ji(o.width)/e.offsetWidth||1,i=e.offsetHeight>0&&Ji(o.height)/e.offsetHeight||1);var l=Ua(e)?qn(e):window,s=l.visualViewport,c=!iN()&&r,u=(o.left+(c&&s?s.offsetLeft:0))/a,d=(o.top+(c&&s?s.offsetTop:0))/i,f=o.width/a,p=o.height/i;return{width:f,height:p,top:d,right:u+f,bottom:d+p,left:u,x:u,y:d}}function f2(e){var t=Zi(e),r=e.offsetWidth,o=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-o)<=1&&(o=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:o}}function lN(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&d2(r)){var o=t;do{if(o&&e.isSameNode(o))return!0;o=o.parentNode||o.host}while(o)}return!1}function No(e){return qn(e).getComputedStyle(e)}function Fye(e){return["table","td","th"].indexOf(ao(e))>=0}function ua(e){return((Ua(e)?e.ownerDocument:e.document)||window.document).documentElement}function gf(e){return ao(e)==="html"?e:e.assignedSlot||e.parentNode||(d2(e)?e.host:null)||ua(e)}function Pv(e){return!ir(e)||No(e).position==="fixed"?null:e.offsetParent}function Uye(e){var t=/firefox/i.test(P0()),r=/Trident/i.test(P0());if(r&&ir(e)){var o=No(e);if(o.position==="fixed")return null}var a=gf(e);for(d2(a)&&(a=a.host);ir(a)&&["html","body"].indexOf(ao(a))<0;){var i=No(a);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return a;a=a.parentNode}return null}function tc(e){for(var t=qn(e),r=Pv(e);r&&Fye(r)&&No(r).position==="static";)r=Pv(r);return r&&(ao(r)==="html"||ao(r)==="body"&&No(r).position==="static")?t:r||Uye(e)||t}function p2(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ql(e,t,r){return za(e,Uu(t,r))}function Hye(e,t,r){var o=ql(e,t,r);return o>r?r:o}function sN(){return{top:0,right:0,bottom:0,left:0}}function cN(e){return Object.assign({},sN(),e)}function uN(e,t){return t.reduce(function(r,o){return r[o]=e,r},{})}var Yye=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,cN(typeof t!="number"?t:uN(t,ec))};function Qye(e){var t,r=e.state,o=e.name,a=e.options,i=r.elements.arrow,l=r.modifiersData.popperOffsets,s=Xr(r.placement),c=p2(s),u=[zn,hr].indexOf(s)>=0,d=u?"height":"width";if(!(!i||!l)){var f=Yye(a.padding,r),p=f2(i),h=c==="y"?On:zn,m=c==="y"?mr:hr,g=r.rects.reference[d]+r.rects.reference[c]-l[c]-r.rects.popper[d],v=l[c]-r.rects.reference[c],y=tc(i),N=y?c==="y"?y.clientHeight||0:y.clientWidth||0:0,b=g/2-v/2,M=f[h],k=N-p[d]-f[m],w=N/2-p[d]/2+b,C=ql(M,w,k),E=c;r.modifiersData[o]=(t={},t[E]=C,t.centerOffset=C-w,t)}}function Wye(e){var t=e.state,r=e.options,o=r.element,a=o===void 0?"[data-popper-arrow]":o;a!=null&&(typeof a=="string"&&(a=t.elements.popper.querySelector(a),!a)||lN(t.elements.popper,a)&&(t.elements.arrow=a))}const qye={name:"arrow",enabled:!0,phase:"main",fn:Qye,effect:Wye,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Xi(e){return e.split("-")[1]}var Gye={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Kye(e,t){var r=e.x,o=e.y,a=t.devicePixelRatio||1;return{x:Ji(r*a)/a||0,y:Ji(o*a)/a||0}}function Rv(e){var t,r=e.popper,o=e.popperRect,a=e.placement,i=e.variation,l=e.offsets,s=e.position,c=e.gpuAcceleration,u=e.adaptive,d=e.roundOffsets,f=e.isFixed,p=l.x,h=p===void 0?0:p,m=l.y,g=m===void 0?0:m,v=typeof d=="function"?d({x:h,y:g}):{x:h,y:g};h=v.x,g=v.y;var y=l.hasOwnProperty("x"),N=l.hasOwnProperty("y"),b=zn,M=On,k=window;if(u){var w=tc(r),C="clientHeight",E="clientWidth";if(w===qn(r)&&(w=ua(r),No(w).position!=="static"&&s==="absolute"&&(C="scrollHeight",E="scrollWidth")),w=w,a===On||(a===zn||a===hr)&&i===As){M=mr;var A=f&&w===k&&k.visualViewport?k.visualViewport.height:w[C];g-=A-o.height,g*=c?1:-1}if(a===zn||(a===On||a===mr)&&i===As){b=hr;var O=f&&w===k&&k.visualViewport?k.visualViewport.width:w[E];h-=O-o.width,h*=c?1:-1}}var _=Object.assign({position:s},u&&Gye),j=d===!0?Kye({x:h,y:g},qn(r)):{x:h,y:g};if(h=j.x,g=j.y,c){var R;return Object.assign({},_,(R={},R[M]=N?"0":"",R[b]=y?"0":"",R.transform=(k.devicePixelRatio||1)<=1?"translate("+h+"px, "+g+"px)":"translate3d("+h+"px, "+g+"px, 0)",R))}return Object.assign({},_,(t={},t[M]=N?g+"px":"",t[b]=y?h+"px":"",t.transform="",t))}function Jye(e){var t=e.state,r=e.options,o=r.gpuAcceleration,a=o===void 0?!0:o,i=r.adaptive,l=i===void 0?!0:i,s=r.roundOffsets,c=s===void 0?!0:s,u={placement:Xr(t.placement),variation:Xi(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:a,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Rv(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:l,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Rv(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const Zye={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Jye,data:{}};var Sc={passive:!0};function Xye(e){var t=e.state,r=e.instance,o=e.options,a=o.scroll,i=a===void 0?!0:a,l=o.resize,s=l===void 0?!0:l,c=qn(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&u.forEach(function(d){d.addEventListener("scroll",r.update,Sc)}),s&&c.addEventListener("resize",r.update,Sc),function(){i&&u.forEach(function(d){d.removeEventListener("scroll",r.update,Sc)}),s&&c.removeEventListener("resize",r.update,Sc)}}const eMe={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Xye,data:{}};var tMe={left:"right",right:"left",bottom:"top",top:"bottom"};function Kc(e){return e.replace(/left|right|bottom|top/g,function(t){return tMe[t]})}var nMe={start:"end",end:"start"};function Fv(e){return e.replace(/start|end/g,function(t){return nMe[t]})}function m2(e){var t=qn(e),r=t.pageXOffset,o=t.pageYOffset;return{scrollLeft:r,scrollTop:o}}function h2(e){return Zi(ua(e)).left+m2(e).scrollLeft}function rMe(e,t){var r=qn(e),o=ua(e),a=r.visualViewport,i=o.clientWidth,l=o.clientHeight,s=0,c=0;if(a){i=a.width,l=a.height;var u=iN();(u||!u&&t==="fixed")&&(s=a.offsetLeft,c=a.offsetTop)}return{width:i,height:l,x:s+h2(e),y:c}}function oMe(e){var t,r=ua(e),o=m2(e),a=(t=e.ownerDocument)==null?void 0:t.body,i=za(r.scrollWidth,r.clientWidth,a?a.scrollWidth:0,a?a.clientWidth:0),l=za(r.scrollHeight,r.clientHeight,a?a.scrollHeight:0,a?a.clientHeight:0),s=-o.scrollLeft+h2(e),c=-o.scrollTop;return No(a||r).direction==="rtl"&&(s+=za(r.clientWidth,a?a.clientWidth:0)-i),{width:i,height:l,x:s,y:c}}function g2(e){var t=No(e),r=t.overflow,o=t.overflowX,a=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+a+o)}function dN(e){return["html","body","#document"].indexOf(ao(e))>=0?e.ownerDocument.body:ir(e)&&g2(e)?e:dN(gf(e))}function Gl(e,t){var r;t===void 0&&(t=[]);var o=dN(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),i=qn(o),l=a?[i].concat(i.visualViewport||[],g2(o)?o:[]):o,s=t.concat(l);return a?s:s.concat(Gl(gf(l)))}function R0(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function aMe(e,t){var r=Zi(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function Uv(e,t,r){return t===rN?R0(rMe(e,r)):Ua(t)?aMe(t,r):R0(oMe(ua(e)))}function iMe(e){var t=Gl(gf(e)),r=["absolute","fixed"].indexOf(No(e).position)>=0,o=r&&ir(e)?tc(e):e;return Ua(o)?t.filter(function(a){return Ua(a)&&lN(a,o)&&ao(a)!=="body"}):[]}function lMe(e,t,r,o){var a=t==="clippingParents"?iMe(e):[].concat(t),i=[].concat(a,[r]),l=i[0],s=i.reduce(function(c,u){var d=Uv(e,u,o);return c.top=za(d.top,c.top),c.right=Uu(d.right,c.right),c.bottom=Uu(d.bottom,c.bottom),c.left=za(d.left,c.left),c},Uv(e,l,o));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function fN(e){var t=e.reference,r=e.element,o=e.placement,a=o?Xr(o):null,i=o?Xi(o):null,l=t.x+t.width/2-r.width/2,s=t.y+t.height/2-r.height/2,c;switch(a){case On:c={x:l,y:t.y-r.height};break;case mr:c={x:l,y:t.y+t.height};break;case hr:c={x:t.x+t.width,y:s};break;case zn:c={x:t.x-r.width,y:s};break;default:c={x:t.x,y:t.y}}var u=a?p2(a):null;if(u!=null){var d=u==="y"?"height":"width";switch(i){case Ki:c[u]=c[u]-(t[d]/2-r[d]/2);break;case As:c[u]=c[u]+(t[d]/2-r[d]/2);break}}return c}function Os(e,t){t===void 0&&(t={});var r=t,o=r.placement,a=o===void 0?e.placement:o,i=r.strategy,l=i===void 0?e.strategy:i,s=r.boundary,c=s===void 0?Dye:s,u=r.rootBoundary,d=u===void 0?rN:u,f=r.elementContext,p=f===void 0?Tl:f,h=r.altBoundary,m=h===void 0?!1:h,g=r.padding,v=g===void 0?0:g,y=cN(typeof v!="number"?v:uN(v,ec)),N=p===Tl?Sye:Tl,b=e.rects.popper,M=e.elements[m?N:p],k=lMe(Ua(M)?M:M.contextElement||ua(e.elements.popper),c,d,l),w=Zi(e.elements.reference),C=fN({reference:w,element:b,strategy:"absolute",placement:a}),E=R0(Object.assign({},b,C)),A=p===Tl?E:w,O={top:k.top-A.top+y.top,bottom:A.bottom-k.bottom+y.bottom,left:k.left-A.left+y.left,right:A.right-k.right+y.right},_=e.modifiersData.offset;if(p===Tl&&_){var j=_[a];Object.keys(O).forEach(function(R){var P=[hr,mr].indexOf(R)>=0?1:-1,$=[On,mr].indexOf(R)>=0?"y":"x";O[R]+=j[$]*P})}return O}function sMe(e,t){t===void 0&&(t={});var r=t,o=r.placement,a=r.boundary,i=r.rootBoundary,l=r.padding,s=r.flipVariations,c=r.allowedAutoPlacements,u=c===void 0?oN:c,d=Xi(o),f=d?s?$v:$v.filter(function(m){return Xi(m)===d}):ec,p=f.filter(function(m){return u.indexOf(m)>=0});p.length===0&&(p=f);var h=p.reduce(function(m,g){return m[g]=Os(e,{placement:g,boundary:a,rootBoundary:i,padding:l})[Xr(g)],m},{});return Object.keys(h).sort(function(m,g){return h[m]-h[g]})}function cMe(e){if(Xr(e)===u2)return[];var t=Kc(e);return[Fv(e),t,Fv(t)]}function uMe(e){var t=e.state,r=e.options,o=e.name;if(!t.modifiersData[o]._skip){for(var a=r.mainAxis,i=a===void 0?!0:a,l=r.altAxis,s=l===void 0?!0:l,c=r.fallbackPlacements,u=r.padding,d=r.boundary,f=r.rootBoundary,p=r.altBoundary,h=r.flipVariations,m=h===void 0?!0:h,g=r.allowedAutoPlacements,v=t.options.placement,y=Xr(v),N=y===v,b=c||(N||!m?[Kc(v)]:cMe(v)),M=[v].concat(b).reduce(function(z,I){return z.concat(Xr(I)===u2?sMe(t,{placement:I,boundary:d,rootBoundary:f,padding:u,flipVariations:m,allowedAutoPlacements:g}):I)},[]),k=t.rects.reference,w=t.rects.popper,C=new Map,E=!0,A=M[0],O=0;O<M.length;O++){var _=M[O],j=Xr(_),R=Xi(_)===Ki,P=[On,mr].indexOf(j)>=0,$=P?"width":"height",V=Os(t,{placement:_,boundary:d,rootBoundary:f,altBoundary:p,padding:u}),D=P?R?hr:zn:R?mr:On;k[$]>w[$]&&(D=Kc(D));var x=Kc(D),S=[];if(i&&S.push(V[j]<=0),s&&S.push(V[D]<=0,V[x]<=0),S.every(function(z){return z})){A=_,E=!1;break}C.set(_,S)}if(E)for(var L=m?3:1,B=function(I){var Z=M.find(function(q){var te=C.get(q);if(te)return te.slice(0,I).every(function(J){return J})});if(Z)return A=Z,"break"},F=L;F>0;F--){var T=B(F);if(T==="break")break}t.placement!==A&&(t.modifiersData[o]._skip=!0,t.placement=A,t.reset=!0)}}const dMe={name:"flip",enabled:!0,phase:"main",fn:uMe,requiresIfExists:["offset"],data:{_skip:!1}};function Hv(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Yv(e){return[On,hr,mr,zn].some(function(t){return e[t]>=0})}function fMe(e){var t=e.state,r=e.name,o=t.rects.reference,a=t.rects.popper,i=t.modifiersData.preventOverflow,l=Os(t,{elementContext:"reference"}),s=Os(t,{altBoundary:!0}),c=Hv(l,o),u=Hv(s,a,i),d=Yv(c),f=Yv(u);t.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:u,isReferenceHidden:d,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":f})}const pMe={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:fMe};function mMe(e,t,r){var o=Xr(e),a=[zn,On].indexOf(o)>=0?-1:1,i=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,l=i[0],s=i[1];return l=l||0,s=(s||0)*a,[zn,hr].indexOf(o)>=0?{x:s,y:l}:{x:l,y:s}}function hMe(e){var t=e.state,r=e.options,o=e.name,a=r.offset,i=a===void 0?[0,0]:a,l=oN.reduce(function(d,f){return d[f]=mMe(f,t.rects,i),d},{}),s=l[t.placement],c=s.x,u=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=u),t.modifiersData[o]=l}const gMe={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:hMe};function vMe(e){var t=e.state,r=e.name;t.modifiersData[r]=fN({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const yMe={name:"popperOffsets",enabled:!0,phase:"read",fn:vMe,data:{}};function MMe(e){return e==="x"?"y":"x"}function bMe(e){var t=e.state,r=e.options,o=e.name,a=r.mainAxis,i=a===void 0?!0:a,l=r.altAxis,s=l===void 0?!1:l,c=r.boundary,u=r.rootBoundary,d=r.altBoundary,f=r.padding,p=r.tether,h=p===void 0?!0:p,m=r.tetherOffset,g=m===void 0?0:m,v=Os(t,{boundary:c,rootBoundary:u,padding:f,altBoundary:d}),y=Xr(t.placement),N=Xi(t.placement),b=!N,M=p2(y),k=MMe(M),w=t.modifiersData.popperOffsets,C=t.rects.reference,E=t.rects.popper,A=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,O=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),_=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,j={x:0,y:0};if(w){if(i){var R,P=M==="y"?On:zn,$=M==="y"?mr:hr,V=M==="y"?"height":"width",D=w[M],x=D+v[P],S=D-v[$],L=h?-E[V]/2:0,B=N===Ki?C[V]:E[V],F=N===Ki?-E[V]:-C[V],T=t.elements.arrow,z=h&&T?f2(T):{width:0,height:0},I=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:sN(),Z=I[P],q=I[$],te=ql(0,C[V],z[V]),J=b?C[V]/2-L-te-Z-O.mainAxis:B-te-Z-O.mainAxis,W=b?-C[V]/2+L+te+q+O.mainAxis:F+te+q+O.mainAxis,ae=t.elements.arrow&&tc(t.elements.arrow),ce=ae?M==="y"?ae.clientTop||0:ae.clientLeft||0:0,ye=(R=_==null?void 0:_[M])!=null?R:0,Ae=D+J-ye-ce,Fe=D+W-ye,_e=ql(h?Uu(x,Ae):x,D,h?za(S,Fe):S);w[M]=_e,j[M]=_e-D}if(s){var Le,Ye=M==="x"?On:zn,Ke=M==="x"?mr:hr,Be=w[k],et=k==="y"?"height":"width",lt=Be+v[Ye],je=Be-v[Ke],H=[On,zn].indexOf(y)!==-1,G=(Le=_==null?void 0:_[k])!=null?Le:0,ze=H?lt:Be-C[et]-E[et]-G+O.altAxis,pe=H?Be+C[et]+E[et]-G-O.altAxis:je,we=h&&H?Hye(ze,Be,pe):ql(h?ze:lt,Be,h?pe:je);w[k]=we,j[k]=we-Be}t.modifiersData[o]=j}}const wMe={name:"preventOverflow",enabled:!0,phase:"main",fn:bMe,requiresIfExists:["offset"]};function NMe(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function kMe(e){return e===qn(e)||!ir(e)?m2(e):NMe(e)}function xMe(e){var t=e.getBoundingClientRect(),r=Ji(t.width)/e.offsetWidth||1,o=Ji(t.height)/e.offsetHeight||1;return r!==1||o!==1}function CMe(e,t,r){r===void 0&&(r=!1);var o=ir(t),a=ir(t)&&xMe(t),i=ua(t),l=Zi(e,a,r),s={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(o||!o&&!r)&&((ao(t)!=="body"||g2(i))&&(s=kMe(t)),ir(t)?(c=Zi(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):i&&(c.x=h2(i))),{x:l.left+s.scrollLeft-c.x,y:l.top+s.scrollTop-c.y,width:l.width,height:l.height}}function EMe(e){var t=new Map,r=new Set,o=[];e.forEach(function(i){t.set(i.name,i)});function a(i){r.add(i.name);var l=[].concat(i.requires||[],i.requiresIfExists||[]);l.forEach(function(s){if(!r.has(s)){var c=t.get(s);c&&a(c)}}),o.push(i)}return e.forEach(function(i){r.has(i.name)||a(i)}),o}function TMe(e){var t=EMe(e);return $ye.reduce(function(r,o){return r.concat(t.filter(function(a){return a.phase===o}))},[])}function DMe(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function SMe(e){var t=e.reduce(function(r,o){var a=r[o.name];return r[o.name]=a?Object.assign({},a,o,{options:Object.assign({},a.options,o.options),data:Object.assign({},a.data,o.data)}):o,r},{});return Object.keys(t).map(function(r){return t[r]})}var Qv={placement:"bottom",modifiers:[],strategy:"absolute"};function Wv(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(o){return!(o&&typeof o.getBoundingClientRect=="function")})}function _Me(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,o=r===void 0?[]:r,a=t.defaultOptions,i=a===void 0?Qv:a;return function(s,c,u){u===void 0&&(u=i);var d={placement:"bottom",orderedModifiers:[],options:Object.assign({},Qv,i),modifiersData:{},elements:{reference:s,popper:c},attributes:{},styles:{}},f=[],p=!1,h={state:d,setOptions:function(y){var N=typeof y=="function"?y(d.options):y;g(),d.options=Object.assign({},i,d.options,N),d.scrollParents={reference:Ua(s)?Gl(s):s.contextElement?Gl(s.contextElement):[],popper:Gl(c)};var b=TMe(SMe([].concat(o,d.options.modifiers)));return d.orderedModifiers=b.filter(function(M){return M.enabled}),m(),h.update()},forceUpdate:function(){if(!p){var y=d.elements,N=y.reference,b=y.popper;if(Wv(N,b)){d.rects={reference:CMe(N,tc(b),d.options.strategy==="fixed"),popper:f2(b)},d.reset=!1,d.placement=d.options.placement,d.orderedModifiers.forEach(function(O){return d.modifiersData[O.name]=Object.assign({},O.data)});for(var M=0;M<d.orderedModifiers.length;M++){if(d.reset===!0){d.reset=!1,M=-1;continue}var k=d.orderedModifiers[M],w=k.fn,C=k.options,E=C===void 0?{}:C,A=k.name;typeof w=="function"&&(d=w({state:d,options:E,name:A,instance:h})||d)}}}},update:DMe(function(){return new Promise(function(v){h.forceUpdate(),v(d)})}),destroy:function(){g(),p=!0}};if(!Wv(s,c))return h;h.setOptions(u).then(function(v){!p&&u.onFirstUpdate&&u.onFirstUpdate(v)});function m(){d.orderedModifiers.forEach(function(v){var y=v.name,N=v.options,b=N===void 0?{}:N,M=v.effect;if(typeof M=="function"){var k=M({state:d,name:y,instance:h,options:b}),w=function(){};f.push(k||w)}})}function g(){f.forEach(function(v){return v()}),f=[]}return h}}var IMe=[eMe,yMe,Zye,aN,gMe,dMe,wMe,qye,pMe],AMe=_Me({defaultModifiers:IMe}),OMe="tippy-box",pN="tippy-content",zMe="tippy-backdrop",mN="tippy-arrow",hN="tippy-svg-arrow",ya={passive:!0,capture:!0},gN=function(){return document.body};function jMe(e,t){return{}.hasOwnProperty.call(e,t)}function dp(e,t,r){if(Array.isArray(e)){var o=e[t];return o??(Array.isArray(r)?r[t]:r)}return e}function v2(e,t){var r={}.toString.call(e);return r.indexOf("[object")===0&&r.indexOf(t+"]")>-1}function vN(e,t){return typeof e=="function"?e.apply(void 0,t):e}function qv(e,t){if(t===0)return e;var r;return function(o){clearTimeout(r),r=setTimeout(function(){e(o)},t)}}function LMe(e,t){var r=Object.assign({},e);return t.forEach(function(o){delete r[o]}),r}function BMe(e){return e.split(/\s+/).filter(Boolean)}function vi(e){return[].concat(e)}function Gv(e,t){e.indexOf(t)===-1&&e.push(t)}function VMe(e){return e.filter(function(t,r){return e.indexOf(t)===r})}function $Me(e){return e.split("-")[0]}function Hu(e){return[].slice.call(e)}function Kv(e){return Object.keys(e).reduce(function(t,r){return e[r]!==void 0&&(t[r]=e[r]),t},{})}function Kl(){return document.createElement("div")}function zs(e){return["Element","Fragment"].some(function(t){return v2(e,t)})}function PMe(e){return v2(e,"NodeList")}function RMe(e){return v2(e,"MouseEvent")}function FMe(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function UMe(e){return zs(e)?[e]:PMe(e)?Hu(e):Array.isArray(e)?e:Hu(document.querySelectorAll(e))}function fp(e,t){e.forEach(function(r){r&&(r.style.transitionDuration=t+"ms")})}function Jv(e,t){e.forEach(function(r){r&&r.setAttribute("data-state",t)})}function HMe(e){var t,r=vi(e),o=r[0];return o!=null&&(t=o.ownerDocument)!=null&&t.body?o.ownerDocument:document}function YMe(e,t){var r=t.clientX,o=t.clientY;return e.every(function(a){var i=a.popperRect,l=a.popperState,s=a.props,c=s.interactiveBorder,u=$Me(l.placement),d=l.modifiersData.offset;if(!d)return!0;var f=u==="bottom"?d.top.y:0,p=u==="top"?d.bottom.y:0,h=u==="right"?d.left.x:0,m=u==="left"?d.right.x:0,g=i.top-o+f>c,v=o-i.bottom-p>c,y=i.left-r+h>c,N=r-i.right-m>c;return g||v||y||N})}function pp(e,t,r){var o=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(a){e[o](a,r)})}function Zv(e,t){for(var r=t;r;){var o;if(e.contains(r))return!0;r=r.getRootNode==null||(o=r.getRootNode())==null?void 0:o.host}return!1}var qr={isTouch:!1},Xv=0;function QMe(){qr.isTouch||(qr.isTouch=!0,window.performance&&document.addEventListener("mousemove",yN))}function yN(){var e=performance.now();e-Xv<20&&(qr.isTouch=!1,document.removeEventListener("mousemove",yN)),Xv=e}function WMe(){var e=document.activeElement;if(FMe(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function qMe(){document.addEventListener("touchstart",QMe,ya),window.addEventListener("blur",WMe)}var GMe=typeof window<"u"&&typeof document<"u",KMe=GMe?!!window.msCrypto:!1;function di(e){var t=e==="destroy"?"n already-":" ";return[e+"() was called on a"+t+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function e3(e){var t=/[ \t]{2,}/g,r=/^[ \t]*/gm;return e.replace(t," ").replace(r,"").trim()}function JMe(e){return e3(`
|
|
136
136
|
%ctippy.js
|
|
137
137
|
|
|
138
138
|
%c`+e3(e)+`
|
|
139
139
|
|
|
140
140
|
%c👷 This is a development-only message. It will be removed in production.
|
|
141
|
-
`)}function MN(e){return[
|
|
141
|
+
`)}function MN(e){return[JMe(e),"color: #00C584; font-size: 1.3em; font-weight: bold;","line-height: 1.5","color: #a6a095;"]}var js;process.env.NODE_ENV!=="production"&&ZMe();function ZMe(){js=new Set}function po(e,t){if(e&&!js.has(t)){var r;js.add(t),(r=console).warn.apply(r,MN(t))}}function F0(e,t){if(e&&!js.has(t)){var r;js.add(t),(r=console).error.apply(r,MN(t))}}function XMe(e){var t=!e,r=Object.prototype.toString.call(e)==="[object Object]"&&!e.addEventListener;F0(t,["tippy() was passed","`"+String(e)+"`","as its targets (first) argument. Valid types are: String, Element,","Element[], or NodeList."].join(" ")),F0(r,["tippy() was passed a plain object which is not supported as an argument","for virtual positioning. Use props.getReferenceClientRect instead."].join(" "))}var bN={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},e6e={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},Rn=Object.assign({appendTo:gN,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},bN,e6e),t6e=Object.keys(Rn),n6e=function(t){process.env.NODE_ENV!=="production"&&NN(t,[]);var r=Object.keys(t);r.forEach(function(o){Rn[o]=t[o]})};function wN(e){var t=e.plugins||[],r=t.reduce(function(o,a){var i=a.name,l=a.defaultValue;if(i){var s;o[i]=e[i]!==void 0?e[i]:(s=Rn[i])!=null?s:l}return o},{});return Object.assign({},e,r)}function r6e(e,t){var r=t?Object.keys(wN(Object.assign({},Rn,{plugins:t}))):t6e,o=r.reduce(function(a,i){var l=(e.getAttribute("data-tippy-"+i)||"").trim();if(!l)return a;if(i==="content")a[i]=l;else try{a[i]=JSON.parse(l)}catch{a[i]=l}return a},{});return o}function t3(e,t){var r=Object.assign({},t,{content:vN(t.content,[e])},t.ignoreAttributes?{}:r6e(e,t.plugins));return r.aria=Object.assign({},Rn.aria,r.aria),r.aria={expanded:r.aria.expanded==="auto"?t.interactive:r.aria.expanded,content:r.aria.content==="auto"?t.interactive?null:"describedby":r.aria.content},r}function NN(e,t){e===void 0&&(e={}),t===void 0&&(t=[]);var r=Object.keys(e);r.forEach(function(o){var a=LMe(Rn,Object.keys(bN)),i=!jMe(a,o);i&&(i=t.filter(function(l){return l.name===o}).length===0),po(i,["`"+o+"`","is not a valid prop. You may have spelled it incorrectly, or if it's","a plugin, forgot to pass it in an array as props.plugins.",`
|
|
142
142
|
|
|
143
143
|
`,`All props: https://atomiks.github.io/tippyjs/v6/all-props/
|
|
144
|
-
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}var
|
|
144
|
+
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}var o6e=function(){return"innerHTML"};function U0(e,t){e[o6e()]=t}function n3(e){var t=Kl();return e===!0?t.className=mN:(t.className=hN,zs(e)?t.appendChild(e):U0(t,e)),t}function r3(e,t){zs(t.content)?(U0(e,""),e.appendChild(t.content)):typeof t.content!="function"&&(t.allowHTML?U0(e,t.content):e.textContent=t.content)}function H0(e){var t=e.firstElementChild,r=Hu(t.children);return{box:t,content:r.find(function(o){return o.classList.contains(pN)}),arrow:r.find(function(o){return o.classList.contains(mN)||o.classList.contains(hN)}),backdrop:r.find(function(o){return o.classList.contains(zMe)})}}function kN(e){var t=Kl(),r=Kl();r.className=OMe,r.setAttribute("data-state","hidden"),r.setAttribute("tabindex","-1");var o=Kl();o.className=pN,o.setAttribute("data-state","hidden"),r3(o,e.props),t.appendChild(r),r.appendChild(o),a(e.props,e.props);function a(i,l){var s=H0(t),c=s.box,u=s.content,d=s.arrow;l.theme?c.setAttribute("data-theme",l.theme):c.removeAttribute("data-theme"),typeof l.animation=="string"?c.setAttribute("data-animation",l.animation):c.removeAttribute("data-animation"),l.inertia?c.setAttribute("data-inertia",""):c.removeAttribute("data-inertia"),c.style.maxWidth=typeof l.maxWidth=="number"?l.maxWidth+"px":l.maxWidth,l.role?c.setAttribute("role",l.role):c.removeAttribute("role"),(i.content!==l.content||i.allowHTML!==l.allowHTML)&&r3(u,e.props),l.arrow?d?i.arrow!==l.arrow&&(c.removeChild(d),c.appendChild(n3(l.arrow))):c.appendChild(n3(l.arrow)):d&&c.removeChild(d)}return{popper:t,onUpdate:a}}kN.$$tippy=!0;var a6e=1,_c=[],mp=[];function i6e(e,t){var r=t3(e,Object.assign({},Rn,wN(Kv(t)))),o,a,i,l=!1,s=!1,c=!1,u=!1,d,f,p,h=[],m=qv(Ae,r.interactiveDebounce),g,v=a6e++,y=null,N=VMe(r.plugins),b={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},M={id:v,reference:e,popper:Kl(),popperInstance:y,props:r,state:b,plugins:N,clearDelayTimeouts:ze,setProps:pe,setContent:we,show:be,hide:ct,hideWithInteractivity:kt,enable:H,disable:G,unmount:At,destroy:Ut};if(!r.render)return process.env.NODE_ENV!=="production"&&F0(!0,"render() function has not been supplied."),M;var k=r.render(M),w=k.popper,C=k.onUpdate;w.setAttribute("data-tippy-root",""),w.id="tippy-"+M.id,M.popper=w,e._tippy=M,w._tippy=M;var E=N.map(function(ne){return ne.fn(M)}),A=e.hasAttribute("aria-expanded");return ae(),L(),D(),x("onCreate",[M]),r.showOnCreate&<(),w.addEventListener("mouseenter",function(){M.props.interactive&&M.state.isVisible&&M.clearDelayTimeouts()}),w.addEventListener("mouseleave",function(){M.props.interactive&&M.props.trigger.indexOf("mouseenter")>=0&&P().addEventListener("mousemove",m)}),M;function O(){var ne=M.props.touch;return Array.isArray(ne)?ne:[ne,0]}function _(){return O()[0]==="hold"}function j(){var ne;return!!((ne=M.props.render)!=null&&ne.$$tippy)}function R(){return g||e}function P(){var ne=R().parentNode;return ne?HMe(ne):document}function $(){return H0(w)}function V(ne){return M.state.isMounted&&!M.state.isVisible||qr.isTouch||d&&d.type==="focus"?0:dp(M.props.delay,ne?0:1,Rn.delay)}function D(ne){ne===void 0&&(ne=!1),w.style.pointerEvents=M.props.interactive&&!ne?"":"none",w.style.zIndex=""+M.props.zIndex}function x(ne,Q,oe){if(oe===void 0&&(oe=!0),E.forEach(function(le){le[ne]&&le[ne].apply(le,Q)}),oe){var Y;(Y=M.props)[ne].apply(Y,Q)}}function S(){var ne=M.props.aria;if(ne.content){var Q="aria-"+ne.content,oe=w.id,Y=vi(M.props.triggerTarget||e);Y.forEach(function(le){var Ne=le.getAttribute(Q);if(M.state.isVisible)le.setAttribute(Q,Ne?Ne+" "+oe:oe);else{var Ue=Ne&&Ne.replace(oe,"").trim();Ue?le.setAttribute(Q,Ue):le.removeAttribute(Q)}})}}function L(){if(!(A||!M.props.aria.expanded)){var ne=vi(M.props.triggerTarget||e);ne.forEach(function(Q){M.props.interactive?Q.setAttribute("aria-expanded",M.state.isVisible&&Q===R()?"true":"false"):Q.removeAttribute("aria-expanded")})}}function B(){P().removeEventListener("mousemove",m),_c=_c.filter(function(ne){return ne!==m})}function F(ne){if(!(qr.isTouch&&(c||ne.type==="mousedown"))){var Q=ne.composedPath&&ne.composedPath()[0]||ne.target;if(!(M.props.interactive&&Zv(w,Q))){if(vi(M.props.triggerTarget||e).some(function(oe){return Zv(oe,Q)})){if(qr.isTouch||M.state.isVisible&&M.props.trigger.indexOf("click")>=0)return}else x("onClickOutside",[M,ne]);M.props.hideOnClick===!0&&(M.clearDelayTimeouts(),M.hide(),s=!0,setTimeout(function(){s=!1}),M.state.isMounted||Z())}}}function T(){c=!0}function z(){c=!1}function I(){var ne=P();ne.addEventListener("mousedown",F,!0),ne.addEventListener("touchend",F,ya),ne.addEventListener("touchstart",z,ya),ne.addEventListener("touchmove",T,ya)}function Z(){var ne=P();ne.removeEventListener("mousedown",F,!0),ne.removeEventListener("touchend",F,ya),ne.removeEventListener("touchstart",z,ya),ne.removeEventListener("touchmove",T,ya)}function q(ne,Q){J(ne,function(){!M.state.isVisible&&w.parentNode&&w.parentNode.contains(w)&&Q()})}function te(ne,Q){J(ne,Q)}function J(ne,Q){var oe=$().box;function Y(le){le.target===oe&&(pp(oe,"remove",Y),Q())}if(ne===0)return Q();pp(oe,"remove",f),pp(oe,"add",Y),f=Y}function W(ne,Q,oe){oe===void 0&&(oe=!1);var Y=vi(M.props.triggerTarget||e);Y.forEach(function(le){le.addEventListener(ne,Q,oe),h.push({node:le,eventType:ne,handler:Q,options:oe})})}function ae(){_()&&(W("touchstart",ye,{passive:!0}),W("touchend",Fe,{passive:!0})),BMe(M.props.trigger).forEach(function(ne){if(ne!=="manual")switch(W(ne,ye),ne){case"mouseenter":W("mouseleave",Fe);break;case"focus":W(KMe?"focusout":"blur",_e);break;case"focusin":W("focusout",_e);break}})}function ce(){h.forEach(function(ne){var Q=ne.node,oe=ne.eventType,Y=ne.handler,le=ne.options;Q.removeEventListener(oe,Y,le)}),h=[]}function ye(ne){var Q,oe=!1;if(!(!M.state.isEnabled||Le(ne)||s)){var Y=((Q=d)==null?void 0:Q.type)==="focus";d=ne,g=ne.currentTarget,L(),!M.state.isVisible&&RMe(ne)&&_c.forEach(function(le){return le(ne)}),ne.type==="click"&&(M.props.trigger.indexOf("mouseenter")<0||l)&&M.props.hideOnClick!==!1&&M.state.isVisible?oe=!0:lt(ne),ne.type==="click"&&(l=!oe),oe&&!Y&&je(ne)}}function Ae(ne){var Q=ne.target,oe=R().contains(Q)||w.contains(Q);if(!(ne.type==="mousemove"&&oe)){var Y=et().concat(w).map(function(le){var Ne,Ue=le._tippy,ut=(Ne=Ue.popperInstance)==null?void 0:Ne.state;return ut?{popperRect:le.getBoundingClientRect(),popperState:ut,props:r}:null}).filter(Boolean);YMe(Y,ne)&&(B(),je(ne))}}function Fe(ne){var Q=Le(ne)||M.props.trigger.indexOf("click")>=0&&l;if(!Q){if(M.props.interactive){M.hideWithInteractivity(ne);return}je(ne)}}function _e(ne){M.props.trigger.indexOf("focusin")<0&&ne.target!==R()||M.props.interactive&&ne.relatedTarget&&w.contains(ne.relatedTarget)||je(ne)}function Le(ne){return qr.isTouch?_()!==ne.type.indexOf("touch")>=0:!1}function Ye(){Ke();var ne=M.props,Q=ne.popperOptions,oe=ne.placement,Y=ne.offset,le=ne.getReferenceClientRect,Ne=ne.moveTransition,Ue=j()?H0(w).arrow:null,ut=le?{getBoundingClientRect:le,contextElement:le.contextElement||R()}:e,rt={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(cn){var _t=cn.state;if(j()){var Qe=$(),se=Qe.box;["placement","reference-hidden","escaped"].forEach(function(de){de==="placement"?se.setAttribute("data-placement",_t.placement):_t.attributes.popper["data-popper-"+de]?se.setAttribute("data-"+de,""):se.removeAttribute("data-"+de)}),_t.attributes.popper={}}}},Ct=[{name:"offset",options:{offset:Y}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!Ne}},rt];j()&&Ue&&Ct.push({name:"arrow",options:{element:Ue,padding:3}}),Ct.push.apply(Ct,(Q==null?void 0:Q.modifiers)||[]),M.popperInstance=AMe(ut,w,Object.assign({},Q,{placement:oe,onFirstUpdate:p,modifiers:Ct}))}function Ke(){M.popperInstance&&(M.popperInstance.destroy(),M.popperInstance=null)}function Be(){var ne=M.props.appendTo,Q,oe=R();M.props.interactive&&ne===gN||ne==="parent"?Q=oe.parentNode:Q=vN(ne,[oe]),Q.contains(w)||Q.appendChild(w),M.state.isMounted=!0,Ye(),process.env.NODE_ENV!=="production"&&po(M.props.interactive&&ne===Rn.appendTo&&oe.nextElementSibling!==w,["Interactive tippy element may not be accessible via keyboard","navigation because it is not directly after the reference element","in the DOM source order.",`
|
|
145
145
|
|
|
146
146
|
`,"Using a wrapper <div> or <span> tag around the reference element","solves this by creating a new parentNode context.",`
|
|
147
147
|
|
|
148
148
|
`,"Specifying `appendTo: document.body` silences this warning, but it","assumes you are using a focus management solution to handle","keyboard navigation.",`
|
|
149
149
|
|
|
150
|
-
`,"See: https://atomiks.github.io/tippyjs/v6/accessibility/#interactivity"].join(" "))}function et(){return Hu(w.querySelectorAll("[data-tippy-root]"))}function lt(ne){M.clearDelayTimeouts(),ne&&x("onTrigger",[M,ne]),I();var Q=V(!0),oe=O(),Y=oe[0],le=oe[1];qr.isTouch&&Y==="hold"&&le&&(Q=le),Q?o=setTimeout(function(){M.show()},Q):M.show()}function je(ne){if(M.clearDelayTimeouts(),x("onUntrigger",[M,ne]),!M.state.isVisible){Z();return}if(!(M.props.trigger.indexOf("mouseenter")>=0&&M.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(ne.type)>=0&&l)){var Q=V(!1);Q?a=setTimeout(function(){M.state.isVisible&&M.hide()},Q):i=requestAnimationFrame(function(){M.hide()})}}function H(){M.state.isEnabled=!0}function G(){M.hide(),M.state.isEnabled=!1}function ze(){clearTimeout(o),clearTimeout(a),cancelAnimationFrame(i)}function pe(ne){if(process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("setProps")),!M.state.isDestroyed){x("onBeforeUpdate",[M,ne]),ce();var Q=M.props,oe=t3(e,Object.assign({},Q,Kv(ne),{ignoreAttributes:!0}));M.props=oe,ae(),Q.interactiveDebounce!==oe.interactiveDebounce&&(B(),m=qv(Ae,oe.interactiveDebounce)),Q.triggerTarget&&!oe.triggerTarget?vi(Q.triggerTarget).forEach(function(Y){Y.removeAttribute("aria-expanded")}):oe.triggerTarget&&e.removeAttribute("aria-expanded"),L(),D(),C&&C(Q,oe),M.popperInstance&&(Ye(),et().forEach(function(Y){requestAnimationFrame(Y._tippy.popperInstance.forceUpdate)})),x("onAfterUpdate",[M,ne])}}function we(ne){M.setProps({content:ne})}function be(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("show"));var ne=M.state.isVisible,Q=M.state.isDestroyed,oe=!M.state.isEnabled,Y=qr.isTouch&&!M.props.touch,le=dp(M.props.duration,0,Rn.duration);if(!(ne||Q||oe||Y)&&!R().hasAttribute("disabled")&&(x("onShow",[M],!1),M.props.onShow(M)!==!1)){if(M.state.isVisible=!0,j()&&(w.style.visibility="visible"),D(),I(),M.state.isMounted||(w.style.transition="none"),j()){var Ne=$(),Ue=Ne.box,ut=Ne.content;fp([Ue,ut],0)}p=function(){var Ct;if(!(!M.state.isVisible||u)){if(u=!0,w.offsetHeight,w.style.transition=M.props.moveTransition,j()&&M.props.animation){var qt=$(),cn=qt.box,_t=qt.content;fp([cn,_t],le),Jv([cn,_t],"visible")}S(),L(),Gv(mp,M),(Ct=M.popperInstance)==null||Ct.forceUpdate(),x("onMount",[M]),M.props.animation&&j()&&te(le,function(){M.state.isShown=!0,x("onShown",[M])})}},Be()}}function ct(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("hide"));var ne=!M.state.isVisible,Q=M.state.isDestroyed,oe=!M.state.isEnabled,Y=dp(M.props.duration,1,Rn.duration);if(!(ne||Q||oe)&&(x("onHide",[M],!1),M.props.onHide(M)!==!1)){if(M.state.isVisible=!1,M.state.isShown=!1,u=!1,l=!1,j()&&(w.style.visibility="hidden"),B(),Z(),D(!0),j()){var le=$(),Ne=le.box,Ue=le.content;M.props.animation&&(fp([Ne,Ue],Y),Jv([Ne,Ue],"hidden"))}S(),L(),M.props.animation?j()&&q(Y,M.unmount):M.unmount()}}function kt(ne){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("hideWithInteractivity")),P().addEventListener("mousemove",m),Gv(_c,m),m(ne)}function At(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("unmount")),M.state.isVisible&&M.hide(),M.state.isMounted&&(Ke(),et().forEach(function(ne){ne._tippy.unmount()}),w.parentNode&&w.parentNode.removeChild(w),mp=mp.filter(function(ne){return ne!==M}),M.state.isMounted=!1,x("onHidden",[M]))}function Ut(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("destroy")),!M.state.isDestroyed&&(M.clearDelayTimeouts(),M.unmount(),ce(),delete e._tippy,M.state.isDestroyed=!0,x("onDestroy",[M]))}}function vl(e,t){t===void 0&&(t={});var r=Rn.plugins.concat(t.plugins||[]);process.env.NODE_ENV!=="production"&&(
|
|
150
|
+
`,"See: https://atomiks.github.io/tippyjs/v6/accessibility/#interactivity"].join(" "))}function et(){return Hu(w.querySelectorAll("[data-tippy-root]"))}function lt(ne){M.clearDelayTimeouts(),ne&&x("onTrigger",[M,ne]),I();var Q=V(!0),oe=O(),Y=oe[0],le=oe[1];qr.isTouch&&Y==="hold"&&le&&(Q=le),Q?o=setTimeout(function(){M.show()},Q):M.show()}function je(ne){if(M.clearDelayTimeouts(),x("onUntrigger",[M,ne]),!M.state.isVisible){Z();return}if(!(M.props.trigger.indexOf("mouseenter")>=0&&M.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(ne.type)>=0&&l)){var Q=V(!1);Q?a=setTimeout(function(){M.state.isVisible&&M.hide()},Q):i=requestAnimationFrame(function(){M.hide()})}}function H(){M.state.isEnabled=!0}function G(){M.hide(),M.state.isEnabled=!1}function ze(){clearTimeout(o),clearTimeout(a),cancelAnimationFrame(i)}function pe(ne){if(process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("setProps")),!M.state.isDestroyed){x("onBeforeUpdate",[M,ne]),ce();var Q=M.props,oe=t3(e,Object.assign({},Q,Kv(ne),{ignoreAttributes:!0}));M.props=oe,ae(),Q.interactiveDebounce!==oe.interactiveDebounce&&(B(),m=qv(Ae,oe.interactiveDebounce)),Q.triggerTarget&&!oe.triggerTarget?vi(Q.triggerTarget).forEach(function(Y){Y.removeAttribute("aria-expanded")}):oe.triggerTarget&&e.removeAttribute("aria-expanded"),L(),D(),C&&C(Q,oe),M.popperInstance&&(Ye(),et().forEach(function(Y){requestAnimationFrame(Y._tippy.popperInstance.forceUpdate)})),x("onAfterUpdate",[M,ne])}}function we(ne){M.setProps({content:ne})}function be(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("show"));var ne=M.state.isVisible,Q=M.state.isDestroyed,oe=!M.state.isEnabled,Y=qr.isTouch&&!M.props.touch,le=dp(M.props.duration,0,Rn.duration);if(!(ne||Q||oe||Y)&&!R().hasAttribute("disabled")&&(x("onShow",[M],!1),M.props.onShow(M)!==!1)){if(M.state.isVisible=!0,j()&&(w.style.visibility="visible"),D(),I(),M.state.isMounted||(w.style.transition="none"),j()){var Ne=$(),Ue=Ne.box,ut=Ne.content;fp([Ue,ut],0)}p=function(){var Ct;if(!(!M.state.isVisible||u)){if(u=!0,w.offsetHeight,w.style.transition=M.props.moveTransition,j()&&M.props.animation){var qt=$(),cn=qt.box,_t=qt.content;fp([cn,_t],le),Jv([cn,_t],"visible")}S(),L(),Gv(mp,M),(Ct=M.popperInstance)==null||Ct.forceUpdate(),x("onMount",[M]),M.props.animation&&j()&&te(le,function(){M.state.isShown=!0,x("onShown",[M])})}},Be()}}function ct(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("hide"));var ne=!M.state.isVisible,Q=M.state.isDestroyed,oe=!M.state.isEnabled,Y=dp(M.props.duration,1,Rn.duration);if(!(ne||Q||oe)&&(x("onHide",[M],!1),M.props.onHide(M)!==!1)){if(M.state.isVisible=!1,M.state.isShown=!1,u=!1,l=!1,j()&&(w.style.visibility="hidden"),B(),Z(),D(!0),j()){var le=$(),Ne=le.box,Ue=le.content;M.props.animation&&(fp([Ne,Ue],Y),Jv([Ne,Ue],"hidden"))}S(),L(),M.props.animation?j()&&q(Y,M.unmount):M.unmount()}}function kt(ne){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("hideWithInteractivity")),P().addEventListener("mousemove",m),Gv(_c,m),m(ne)}function At(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("unmount")),M.state.isVisible&&M.hide(),M.state.isMounted&&(Ke(),et().forEach(function(ne){ne._tippy.unmount()}),w.parentNode&&w.parentNode.removeChild(w),mp=mp.filter(function(ne){return ne!==M}),M.state.isMounted=!1,x("onHidden",[M]))}function Ut(){process.env.NODE_ENV!=="production"&&po(M.state.isDestroyed,di("destroy")),!M.state.isDestroyed&&(M.clearDelayTimeouts(),M.unmount(),ce(),delete e._tippy,M.state.isDestroyed=!0,x("onDestroy",[M]))}}function vl(e,t){t===void 0&&(t={});var r=Rn.plugins.concat(t.plugins||[]);process.env.NODE_ENV!=="production"&&(XMe(e),NN(t,r)),qMe();var o=Object.assign({},t,{plugins:r}),a=UMe(e);if(process.env.NODE_ENV!=="production"){var i=zs(o.content),l=a.length>1;po(i&&l,["tippy() was passed an Element as the `content` prop, but more than","one tippy instance was created by this invocation. This means the","content element will only be appended to the last tippy instance.",`
|
|
151
151
|
|
|
152
152
|
`,"Instead, pass the .innerHTML of the element, or use a function that","returns a cloned version of the element instead.",`
|
|
153
153
|
|
|
154
154
|
`,`1) content: element.innerHTML
|
|
155
|
-
`,"2) content: () => element.cloneNode(true)"].join(" "))}var s=a.reduce(function(c,u){var d=u&&n6e(u,o);return d&&c.push(d),c},[]);return zs(e)?s[0]:s}vl.defaultProps=Rn;vl.setDefaultProps=ZMe;vl.currentInput=qr;Object.assign({},aN,{effect:function(t){var r=t.state,o={popper:{position:r.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(r.elements.popper.style,o.popper),r.styles=o,r.elements.arrow&&Object.assign(r.elements.arrow.style,o.arrow)}});vl.setDefaultProps({render:kN});class r6e{constructor({editor:t,element:r,view:o,tippyOptions:a={},updateDelay:i=250,shouldShow:l}){this.preventHide=!1,this.shouldShow=({view:s,state:c,from:u,to:d})=>{const{doc:f,selection:p}=c,{empty:h}=p,m=!f.textBetween(u,d).length&&i2(c.selection),g=this.element.contains(document.activeElement);return!(!(s.hasFocus()||g)||h||m||!this.editor.isEditable)},this.mousedownHandler=()=>{this.preventHide=!0},this.dragstartHandler=()=>{this.hide()},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:s})=>{var c;if(this.preventHide){this.preventHide=!1;return}s!=null&&s.relatedTarget&&(!((c=this.element.parentNode)===null||c===void 0)&&c.contains(s.relatedTarget))||this.hide()},this.tippyBlurHandler=s=>{this.blurHandler({event:s})},this.handleDebouncedUpdate=(s,c)=>{const u=!(c!=null&&c.selection.eq(s.state.selection)),d=!(c!=null&&c.doc.eq(s.state.doc));!u&&!d||(this.updateDebounceTimer&&clearTimeout(this.updateDebounceTimer),this.updateDebounceTimer=window.setTimeout(()=>{this.updateHandler(s,u,d,c)},this.updateDelay))},this.updateHandler=(s,c,u,d)=>{var f,p,h;const{state:m,composing:g}=s,{selection:v}=m;if(g||!c&&!u)return;this.createTooltip();const{ranges:N}=v,b=Math.min(...N.map(w=>w.$from.pos)),M=Math.max(...N.map(w=>w.$to.pos));if(!((f=this.shouldShow)===null||f===void 0?void 0:f.call(this,{editor:this.editor,view:s,state:m,oldState:d,from:b,to:M}))){this.hide();return}(p=this.tippy)===null||p===void 0||p.setProps({getReferenceClientRect:((h=this.tippyOptions)===null||h===void 0?void 0:h.getReferenceClientRect)||(()=>{if(Q3e(m.selection)){let w=s.nodeDOM(b);const C=w.dataset.nodeViewWrapper?w:w.querySelector("[data-node-view-wrapper]");if(C&&(w=C.firstChild),w)return w.getBoundingClientRect()}return nN(s,b,M)})}),this.show()},this.editor=t,this.element=r,this.view=o,this.updateDelay=i,l&&(this.shouldShow=l),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.addEventListener("dragstart",this.dragstartHandler),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.tippyOptions=a,this.element.remove(),this.element.style.visibility="visible"}createTooltip(){const{element:t}=this.editor.options,r=!!t.parentElement;this.tippy||!r||(this.tippy=vl(t,{duration:0,getReferenceClientRect:null,content:this.element,interactive:!0,trigger:"manual",placement:"top",hideOnClick:"toggle",...this.tippyOptions}),this.tippy.popper.firstChild&&this.tippy.popper.firstChild.addEventListener("blur",this.tippyBlurHandler))}update(t,r){const{state:o}=t,a=o.selection.from!==o.selection.to;if(this.updateDelay>0&&a){this.handleDebouncedUpdate(t,r);return}const i=!(r!=null&&r.selection.eq(t.state.selection)),l=!(r!=null&&r.doc.eq(t.state.doc));this.updateHandler(t,i,l,r)}show(){var t;(t=this.tippy)===null||t===void 0||t.show()}hide(){var t;(t=this.tippy)===null||t===void 0||t.hide()}destroy(){var t,r;!((t=this.tippy)===null||t===void 0)&&t.popper.firstChild&&this.tippy.popper.firstChild.removeEventListener("blur",this.tippyBlurHandler),(r=this.tippy)===null||r===void 0||r.destroy(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.removeEventListener("dragstart",this.dragstartHandler),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler)}}const xN=e=>new tn({key:typeof e.pluginKey=="string"?new yn(e.pluginKey):e.pluginKey,view:t=>new r6e({view:t,...e})});hn.create({name:"bubbleMenu",addOptions(){return{element:null,tippyOptions:{},pluginKey:"bubbleMenu",updateDelay:void 0,shouldShow:null}},addProseMirrorPlugins(){return this.options.element?[xN({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,tippyOptions:this.options.tippyOptions,updateDelay:this.options.updateDelay,shouldShow:this.options.shouldShow})]:[]}});class o6e{constructor({editor:t,element:r,view:o,tippyOptions:a={},shouldShow:i}){this.preventHide=!1,this.shouldShow=({view:l,state:s})=>{const{selection:c}=s,{$anchor:u,empty:d}=c,f=u.depth===1,p=u.parent.isTextblock&&!u.parent.type.spec.code&&!u.parent.textContent;return!(!l.hasFocus()||!d||!f||!p||!this.editor.isEditable)},this.mousedownHandler=()=>{this.preventHide=!0},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:l})=>{var s;if(this.preventHide){this.preventHide=!1;return}l!=null&&l.relatedTarget&&(!((s=this.element.parentNode)===null||s===void 0)&&s.contains(l.relatedTarget))||this.hide()},this.tippyBlurHandler=l=>{this.blurHandler({event:l})},this.editor=t,this.element=r,this.view=o,i&&(this.shouldShow=i),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.tippyOptions=a,this.element.remove(),this.element.style.visibility="visible"}createTooltip(){const{element:t}=this.editor.options,r=!!t.parentElement;this.tippy||!r||(this.tippy=vl(t,{duration:0,getReferenceClientRect:null,content:this.element,interactive:!0,trigger:"manual",placement:"right",hideOnClick:"toggle",...this.tippyOptions}),this.tippy.popper.firstChild&&this.tippy.popper.firstChild.addEventListener("blur",this.tippyBlurHandler))}update(t,r){var o,a,i;const{state:l}=t,{doc:s,selection:c}=l,{from:u,to:d}=c;if(r&&r.doc.eq(s)&&r.selection.eq(c))return;if(this.createTooltip(),!((o=this.shouldShow)===null||o===void 0?void 0:o.call(this,{editor:this.editor,view:t,state:l,oldState:r}))){this.hide();return}(a=this.tippy)===null||a===void 0||a.setProps({getReferenceClientRect:((i=this.tippyOptions)===null||i===void 0?void 0:i.getReferenceClientRect)||(()=>nN(t,u,d))}),this.show()}show(){var t;(t=this.tippy)===null||t===void 0||t.show()}hide(){var t;(t=this.tippy)===null||t===void 0||t.hide()}destroy(){var t,r;!((t=this.tippy)===null||t===void 0)&&t.popper.firstChild&&this.tippy.popper.firstChild.removeEventListener("blur",this.tippyBlurHandler),(r=this.tippy)===null||r===void 0||r.destroy(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler)}}const CN=e=>new tn({key:typeof e.pluginKey=="string"?new yn(e.pluginKey):e.pluginKey,view:t=>new o6e({view:t,...e})});hn.create({name:"floatingMenu",addOptions(){return{element:null,tippyOptions:{},pluginKey:"floatingMenu",shouldShow:null}},addProseMirrorPlugins(){return this.options.element?[CN({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,tippyOptions:this.options.tippyOptions,shouldShow:this.options.shouldShow})]:[]}});const a6e=n.defineComponent({name:"BubbleMenu",props:{pluginKey:{type:[String,Object],default:"bubbleMenu"},editor:{type:Object,required:!0},updateDelay:{type:Number,default:void 0},tippyOptions:{type:Object,default:()=>({})},shouldShow:{type:Function,default:null}},setup(e,{slots:t}){const r=n.ref(null);return n.onMounted(()=>{const{updateDelay:o,editor:a,pluginKey:i,shouldShow:l,tippyOptions:s}=e;a.registerPlugin(xN({updateDelay:o,editor:a,element:r.value,pluginKey:i,shouldShow:l,tippyOptions:s}))}),n.onBeforeUnmount(()=>{const{pluginKey:o,editor:a}=e;a.unregisterPlugin(o)}),()=>{var o;return n.h("div",{ref:r},(o=t.default)===null||o===void 0?void 0:o.call(t))}}});function o3(e){return n.customRef((t,r)=>({get(){return t(),e},set(o){e=o,requestAnimationFrame(()=>{requestAnimationFrame(()=>{r()})})}}))}class i6e extends Nye{constructor(t={}){return super(t),this.contentComponent=null,this.appContext=null,this.reactiveState=o3(this.view.state),this.reactiveExtensionStorage=o3(this.extensionStorage),this.on("beforeTransaction",({nextState:r})=>{this.reactiveState.value=r,this.reactiveExtensionStorage.value=this.extensionStorage}),n.markRaw(this)}get state(){return this.reactiveState?this.reactiveState.value:this.view.state}get storage(){return this.reactiveExtensionStorage?this.reactiveExtensionStorage.value:super.storage}registerPlugin(t,r){const o=super.registerPlugin(t,r);return this.reactiveState&&(this.reactiveState.value=o),o}unregisterPlugin(t){const r=super.unregisterPlugin(t);return this.reactiveState&&r&&(this.reactiveState.value=r),r}}const l6e=n.defineComponent({name:"EditorContent",props:{editor:{default:null,type:Object}},setup(e){const t=n.ref(),r=n.getCurrentInstance();return n.watchEffect(()=>{const o=e.editor;o&&o.options.element&&t.value&&n.nextTick(()=>{if(!t.value||!o.options.element.firstChild)return;const a=n.unref(t.value);t.value.append(...o.options.element.childNodes),o.contentComponent=r.ctx._,r&&(o.appContext={...r.appContext,provides:r.provides}),o.setOptions({element:a}),o.createNodeViews()})}),n.onBeforeUnmount(()=>{const o=e.editor;o&&(o.contentComponent=null,o.appContext=null)}),{rootEl:t}},render(){return n.h("div",{ref:e=>{this.rootEl=e}})}});n.defineComponent({name:"FloatingMenu",props:{pluginKey:{type:null,default:"floatingMenu"},editor:{type:Object,required:!0},tippyOptions:{type:Object,default:()=>({})},shouldShow:{type:Function,default:null}},setup(e,{slots:t}){const r=n.ref(null);return n.onMounted(()=>{const{pluginKey:o,editor:a,tippyOptions:i,shouldShow:l}=e;a.registerPlugin(CN({pluginKey:o,editor:a,element:r.value,tippyOptions:i,shouldShow:l}))}),n.onBeforeUnmount(()=>{const{pluginKey:o,editor:a}=e;a.unregisterPlugin(o)}),()=>{var o;return n.h("div",{ref:r},(o=t.default)===null||o===void 0?void 0:o.call(t))}}});n.defineComponent({name:"NodeViewContent",props:{as:{type:String,default:"div"}},render(){return n.h(this.as,{style:{whiteSpace:"pre-wrap"},"data-node-view-content":""})}});n.defineComponent({name:"NodeViewWrapper",props:{as:{type:String,default:"div"}},inject:["onDragStart","decorationClasses"],render(){var e,t;return n.h(this.as,{class:this.decorationClasses,style:{whiteSpace:"normal"},"data-node-view-wrapper":"",onDragstart:this.onDragStart},(t=(e=this.$slots).default)===null||t===void 0?void 0:t.call(e))}});const s6e=pr.create({name:"doc",topNode:!0,content:"block+"}),c6e=pr.create({name:"text",group:"inline"}),u6e=pr.create({name:"listItem",addOptions(){return{HTMLAttributes:{},bulletListTypeName:"bulletList",orderedListTypeName:"orderedList"}},content:"paragraph block*",defining:!0,parseHTML(){return[{tag:"li"}]},renderHTML({HTMLAttributes:e}){return["li",jn(this.options.HTMLAttributes,e),0]},addKeyboardShortcuts(){return{Enter:()=>this.editor.commands.splitListItem(this.name),Tab:()=>this.editor.commands.sinkListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)}}}),a3=new yn("templateHighlight"),d6e=hn.create({name:"templateHighlight",addOptions(){return{validVariables:[],isMailMergeMode:!1}},addProseMirrorPlugins(){const e=this;return[new tn({key:a3,state:{init(){return It.empty},apply(t){if(!e.options.isMailMergeMode)return It.empty;const r=e.options.validVariables||[],o=[];return t.doc.descendants((a,i)=>{if(!a.isText)return;const l=/{{\s*[\w.]+\s*}}/g;let s;for(;(s=l.exec(a.text))!==null;){const c=i+s.index,u=c+s[0].length,d=s[0],p=r.length===0||r.includes(d)?"template-variable-highlight":"template-variable-highlight-invalid";o.push(Un.inline(c,u,{class:p}))}}),It.create(t.doc,o)}},props:{decorations(t){return a3.getState(t)}}})]}}),f6e=pr.create({name:"paragraph",priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:"block",content:"inline*",parseHTML(){return[{tag:"p"}]},renderHTML({HTMLAttributes:e}){return["p",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),i3="min-height: 1.4em; overflow-wrap: break-word;",p6e="l-text-regular l-text-left color-lead-light my-3",m6e=f6e.extend({addAttributes(){return{class:{default:p6e,parseHTML:e=>{e.classList.forEach(t=>{t.includes("color-")&&t!=="color-lead-light"&&e.classList.remove(t)})}},style:{default:i3,parseHTML:e=>e.style=i3}}},addCommands(){return{setMarkUp:e=>({commands:t,chain:r})=>{switch(e){case"bold":return t.toggleBold();case"italic":return t.toggleItalic();case"underline":return t.toggleUnderline();case"heading":return t.toggleHeading({level:1});case"bulletList":return t.toggleBulletList();case"orderedList":return t.toggleOrderedList();case"blockquote":return t.toggleBlockquote();case"removeFormatting":return r().unsetAllMarks().clearNodes()}}}}}),h6e=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))$/,g6e=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))/g,v6e=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))$/,y6e=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))/g,M6e=oa.create({name:"bold",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"strong"},{tag:"b",getAttrs:e=>e.style.fontWeight!=="normal"&&null},{style:"font-weight=400",clearMark:e=>e.type.name===this.name},{style:"font-weight",getAttrs:e=>/^(bold(er)?|[5-9]\d{2,})$/.test(e)&&null}]},renderHTML({HTMLAttributes:e}){return["strong",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setBold:()=>({commands:e})=>e.setMark(this.name),toggleBold:()=>({commands:e})=>e.toggleMark(this.name),unsetBold:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-b":()=>this.editor.commands.toggleBold(),"Mod-B":()=>this.editor.commands.toggleBold()}},addInputRules(){return[Fu({find:h6e,type:this.type}),Fu({find:v6e,type:this.type})]},addPasteRules(){return[Is({find:g6e,type:this.type}),Is({find:y6e,type:this.type})]}}),b6e=M6e.extend({addAttributes(){return{class:{default:"l-bold"}}}}),w6e=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))$/,N6e=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))/g,k6e=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))$/,x6e=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))/g,C6e=oa.create({name:"italic",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"em"},{tag:"i",getAttrs:e=>e.style.fontStyle!=="normal"&&null},{style:"font-style=normal",clearMark:e=>e.type.name===this.name},{style:"font-style=italic"}]},renderHTML({HTMLAttributes:e}){return["em",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setItalic:()=>({commands:e})=>e.setMark(this.name),toggleItalic:()=>({commands:e})=>e.toggleMark(this.name),unsetItalic:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-i":()=>this.editor.commands.toggleItalic(),"Mod-I":()=>this.editor.commands.toggleItalic()}},addInputRules(){return[Fu({find:w6e,type:this.type}),Fu({find:k6e,type:this.type})]},addPasteRules(){return[Is({find:N6e,type:this.type}),Is({find:x6e,type:this.type})]}}),E6e=C6e.extend({addAttributes(){return{class:{default:""}}}}),T6e=oa.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",jn(this.options.HTMLAttributes,e),0]},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()}}}),l3="",D6e=T6e.extend({addAttributes(){return{class:{default:l3,parseHTML:e=>e.style=l3}}},parseHTML(){return[{tag:"u"},{style:"border-bottom",getAttrs:e=>e!==void 0||e!==0}]}}),S6e=pr.create({name:"heading",addOptions(){return{levels:[1,2,3,4,5,6],HTMLAttributes:{}}},content:"inline*",group:"block",defining:!0,addAttributes(){return{level:{default:1,rendered:!1}}},parseHTML(){return this.options.levels.map(e=>({tag:`h${e}`,attrs:{level:e}}))},renderHTML({node:e,HTMLAttributes:t}){return[`h${this.options.levels.includes(e.attrs.level)?e.attrs.level:this.options.levels[0]}`,jn(this.options.HTMLAttributes,t),0]},addCommands(){return{setHeading:e=>({commands:t})=>this.options.levels.includes(e.level)?t.setNode(this.name,e):!1,toggleHeading:e=>({commands:t})=>this.options.levels.includes(e.level)?t.toggleNode(this.name,"paragraph",e):!1}},addKeyboardShortcuts(){return this.options.levels.reduce((e,t)=>({...e,[`Mod-Alt-${t}`]:()=>this.editor.commands.toggleHeading({level:t})}),{})},addInputRules(){return this.options.levels.map(e=>kye({find:new RegExp(`^(#{1,${e}})\\s$`),type:this.type,getAttributes:{level:e}}))}}),_6e=S6e.extend({addOptions(){var e;return{...(e=this.parent)==null?void 0:e.call(this),levels:[1],HTMLAttributes:{class:"l-h2"}}}}),I6e="listItem",s3="textStyle",c3=/^\s*([-+*])\s$/,A6e=pr.create({name:"bulletList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:"ul"}]},renderHTML({HTMLAttributes:e}){return["ul",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{toggleBulletList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(I6e,this.editor.getAttributes(s3)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-8":()=>this.editor.commands.toggleBulletList()}},addInputRules(){let e=_s({find:c3,type:this.type});return(this.options.keepMarks||this.options.keepAttributes)&&(e=_s({find:c3,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:()=>this.editor.getAttributes(s3),editor:this.editor})),[e]}}),O6e=A6e.extend({addAttributes(){return{class:{default:"color-lead-light pl-4"},style:{default:"list-style-type: disc;"}}}}),z6e="listItem",u3="textStyle",d3=/^(\d+)\.\s$/,j6e=pr.create({name:"orderedList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes(){return{start:{default:1,parseHTML:e=>e.hasAttribute("start")?parseInt(e.getAttribute("start")||"",10):1},type:{default:void 0,parseHTML:e=>e.getAttribute("type")}}},parseHTML(){return[{tag:"ol"}]},renderHTML({HTMLAttributes:e}){const{start:t,...r}=e;return t===1?["ol",jn(this.options.HTMLAttributes,r),0]:["ol",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{toggleOrderedList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(z6e,this.editor.getAttributes(u3)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let e=_s({find:d3,type:this.type,getAttributes:t=>({start:+t[1]}),joinPredicate:(t,r)=>r.childCount+r.attrs.start===+t[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(e=_s({find:d3,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:t=>({start:+t[1],...this.editor.getAttributes(u3)}),joinPredicate:(t,r)=>r.childCount+r.attrs.start===+t[1],editor:this.editor})),[e]}}),L6e=j6e.extend({addAttributes(){return{class:{default:"color-lead-light pl-4"},style:{default:"list-style-type: decimal"}}}}),B6e=/^\s*>\s$/,V6e=pr.create({name:"blockquote",addOptions(){return{HTMLAttributes:{}}},content:"block+",group:"block",defining:!0,parseHTML(){return[{tag:"blockquote"}]},renderHTML({HTMLAttributes:e}){return["blockquote",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setBlockquote:()=>({commands:e})=>e.wrapIn(this.name),toggleBlockquote:()=>({commands:e})=>e.toggleWrap(this.name),unsetBlockquote:()=>({commands:e})=>e.lift(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-b":()=>this.editor.commands.toggleBlockquote()}},addInputRules(){return[_s({find:B6e,type:this.type})]}}),$6e=V6e.extend({addAttributes(){return{class:{default:"px-3 mx-0 my-2"},style:{default:"border-left: 3px solid var(--color-gray-50)"}}}}),P6e="aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4vianca6w0s2x0a2z0ure5ba0by2idu3namex3narepublic11d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2ntley5rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0cast4mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dabur3d1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3nlop4pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2o0dyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0ardian6cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6logistics9properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3ncaster6d0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2psy3ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rckmsd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2tura4vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9dnavy5lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0america6xi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0stone5umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0a1b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp2w2ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2olterskluwer11odside6rk0s2ld3w2s1tc1f3xbox3erox4finity6ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2",R6e="ελ1υ2бг1ел3дети4ею2католик6ом3мкд2он1сква6онлайн5рг3рус2ф2сайт3рб3укр3қаз3հայ3ישראל5קום3ابوظبي5رامكو5لاردن4بحرين5جزائر5سعودية6عليان5مغرب5مارات5یران5بارت2زار4يتك3ھارت5تونس4سودان3رية5شبكة4عراق2ب2مان4فلسطين6قطر3كاثوليك6وم3مصر2ليسيا5وريتانيا7قع4همراه5پاکستان7ڀارت4कॉम3नेट3भारत0म्3ोत5संगठन5বাংলা5ভারত2ৰত4ਭਾਰਤ4ભારત4ଭାରତ4இந்தியா6லங்கை6சிங்கப்பூர்11భారత్5ಭಾರತ4ഭാരതം5ලංකා4คอม3ไทย3ລາວ3გე2みんな3アマゾン4クラウド4グーグル4コム2ストア3セール3ファッション6ポイント4世界2中信1国1國1文网3亚马逊3企业2佛山2信息2健康2八卦2公司1益2台湾1灣2商城1店1标2嘉里0大酒店5在线2大拿2天主教3娱乐2家電2广东2微博2慈善2我爱你3手机2招聘2政务1府2新加坡2闻2时尚2書籍2机构2淡马锡3游戏2澳門2点看2移动2组织机构4网址1店1站1络2联通2谷歌2购物2通販2集团2電訊盈科4飞利浦3食品2餐厅2香格里拉3港2닷넷1컴2삼성2한국2",el=(e,t)=>{for(const r in t)e[r]=t[r];return e},Y0="numeric",Q0="ascii",W0="alpha",Jc="asciinumeric",Ic="alphanumeric",q0="domain",EN="emoji",F6e="scheme",U6e="slashscheme",f3="whitespace";function H6e(e,t){return e in t||(t[e]=[]),t[e]}function Ta(e,t,r){t[Y0]&&(t[Jc]=!0,t[Ic]=!0),t[Q0]&&(t[Jc]=!0,t[W0]=!0),t[Jc]&&(t[Ic]=!0),t[W0]&&(t[Ic]=!0),t[Ic]&&(t[q0]=!0),t[EN]&&(t[q0]=!0);for(const o in t){const a=H6e(o,r);a.indexOf(e)<0&&a.push(e)}}function Y6e(e,t){const r={};for(const o in t)t[o].indexOf(e)>=0&&(r[o]=!0);return r}function En(e){e===void 0&&(e=null),this.j={},this.jr=[],this.jd=null,this.t=e}En.groups={};En.prototype={accepts(){return!!this.t},go(e){const t=this,r=t.j[e];if(r)return r;for(let o=0;o<t.jr.length;o++){const a=t.jr[o][0],i=t.jr[o][1];if(i&&a.test(e))return i}return t.jd},has(e,t){return t===void 0&&(t=!1),t?e in this.j:!!this.go(e)},ta(e,t,r,o){for(let a=0;a<e.length;a++)this.tt(e[a],t,r,o)},tr(e,t,r,o){o=o||En.groups;let a;return t&&t.j?a=t:(a=new En(t),r&&o&&Ta(t,r,o)),this.jr.push([e,a]),a},ts(e,t,r,o){let a=this;const i=e.length;if(!i)return a;for(let l=0;l<i-1;l++)a=a.tt(e[l]);return a.tt(e[i-1],t,r,o)},tt(e,t,r,o){o=o||En.groups;const a=this;if(t&&t.j)return a.j[e]=t,t;const i=t;let l,s=a.go(e);if(s?(l=new En,el(l.j,s.j),l.jr.push.apply(l.jr,s.jr),l.jd=s.jd,l.t=s.t):l=new En,i){if(o)if(l.t&&typeof l.t=="string"){const c=el(Y6e(l.t,o),r);Ta(i,c,o)}else r&&Ta(i,r,o);l.t=i}return a.j[e]=l,l}};const We=(e,t,r,o,a)=>e.ta(t,r,o,a),Xn=(e,t,r,o,a)=>e.tr(t,r,o,a),p3=(e,t,r,o,a)=>e.ts(t,r,o,a),Me=(e,t,r,o,a)=>e.tt(t,r,o,a),uo="WORD",G0="UWORD",Ls="LOCALHOST",K0="TLD",J0="UTLD",Zc="SCHEME",yi="SLASH_SCHEME",y2="NUM",TN="WS",M2="NL",Jl="OPENBRACE",Zl="CLOSEBRACE",Yu="OPENBRACKET",Qu="CLOSEBRACKET",Wu="OPENPAREN",qu="CLOSEPAREN",Gu="OPENANGLEBRACKET",Ku="CLOSEANGLEBRACKET",Ju="FULLWIDTHLEFTPAREN",Zu="FULLWIDTHRIGHTPAREN",Xu="LEFTCORNERBRACKET",ed="RIGHTCORNERBRACKET",td="LEFTWHITECORNERBRACKET",nd="RIGHTWHITECORNERBRACKET",rd="FULLWIDTHLESSTHAN",od="FULLWIDTHGREATERTHAN",ad="AMPERSAND",id="APOSTROPHE",ld="ASTERISK",jo="AT",sd="BACKSLASH",cd="BACKTICK",ud="CARET",Ro="COLON",b2="COMMA",dd="DOLLAR",Ur="DOT",fd="EQUALS",w2="EXCLAMATION",Hr="HYPHEN",pd="PERCENT",md="PIPE",hd="PLUS",gd="POUND",vd="QUERY",N2="QUOTE",k2="SEMI",Yr="SLASH",Xl="TILDE",yd="UNDERSCORE",DN="EMOJI",Md="SYM";var SN=Object.freeze({__proto__:null,WORD:uo,UWORD:G0,LOCALHOST:Ls,TLD:K0,UTLD:J0,SCHEME:Zc,SLASH_SCHEME:yi,NUM:y2,WS:TN,NL:M2,OPENBRACE:Jl,CLOSEBRACE:Zl,OPENBRACKET:Yu,CLOSEBRACKET:Qu,OPENPAREN:Wu,CLOSEPAREN:qu,OPENANGLEBRACKET:Gu,CLOSEANGLEBRACKET:Ku,FULLWIDTHLEFTPAREN:Ju,FULLWIDTHRIGHTPAREN:Zu,LEFTCORNERBRACKET:Xu,RIGHTCORNERBRACKET:ed,LEFTWHITECORNERBRACKET:td,RIGHTWHITECORNERBRACKET:nd,FULLWIDTHLESSTHAN:rd,FULLWIDTHGREATERTHAN:od,AMPERSAND:ad,APOSTROPHE:id,ASTERISK:ld,AT:jo,BACKSLASH:sd,BACKTICK:cd,CARET:ud,COLON:Ro,COMMA:b2,DOLLAR:dd,DOT:Ur,EQUALS:fd,EXCLAMATION:w2,HYPHEN:Hr,PERCENT:pd,PIPE:md,PLUS:hd,POUND:gd,QUERY:vd,QUOTE:N2,SEMI:k2,SLASH:Yr,TILDE:Xl,UNDERSCORE:yd,EMOJI:DN,SYM:Md});const fi=/[a-z]/,hp=/\p{L}/u,gp=/\p{Emoji}/u,vp=/\d/,m3=/\s/,h3=`
|
|
156
|
-
`,
|
|
155
|
+
`,"2) content: () => element.cloneNode(true)"].join(" "))}var s=a.reduce(function(c,u){var d=u&&i6e(u,o);return d&&c.push(d),c},[]);return zs(e)?s[0]:s}vl.defaultProps=Rn;vl.setDefaultProps=n6e;vl.currentInput=qr;Object.assign({},aN,{effect:function(t){var r=t.state,o={popper:{position:r.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(r.elements.popper.style,o.popper),r.styles=o,r.elements.arrow&&Object.assign(r.elements.arrow.style,o.arrow)}});vl.setDefaultProps({render:kN});class l6e{constructor({editor:t,element:r,view:o,tippyOptions:a={},updateDelay:i=250,shouldShow:l}){this.preventHide=!1,this.shouldShow=({view:s,state:c,from:u,to:d})=>{const{doc:f,selection:p}=c,{empty:h}=p,m=!f.textBetween(u,d).length&&i2(c.selection),g=this.element.contains(document.activeElement);return!(!(s.hasFocus()||g)||h||m||!this.editor.isEditable)},this.mousedownHandler=()=>{this.preventHide=!0},this.dragstartHandler=()=>{this.hide()},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:s})=>{var c;if(this.preventHide){this.preventHide=!1;return}s!=null&&s.relatedTarget&&(!((c=this.element.parentNode)===null||c===void 0)&&c.contains(s.relatedTarget))||this.hide()},this.tippyBlurHandler=s=>{this.blurHandler({event:s})},this.handleDebouncedUpdate=(s,c)=>{const u=!(c!=null&&c.selection.eq(s.state.selection)),d=!(c!=null&&c.doc.eq(s.state.doc));!u&&!d||(this.updateDebounceTimer&&clearTimeout(this.updateDebounceTimer),this.updateDebounceTimer=window.setTimeout(()=>{this.updateHandler(s,u,d,c)},this.updateDelay))},this.updateHandler=(s,c,u,d)=>{var f,p,h;const{state:m,composing:g}=s,{selection:v}=m;if(g||!c&&!u)return;this.createTooltip();const{ranges:N}=v,b=Math.min(...N.map(w=>w.$from.pos)),M=Math.max(...N.map(w=>w.$to.pos));if(!((f=this.shouldShow)===null||f===void 0?void 0:f.call(this,{editor:this.editor,view:s,state:m,oldState:d,from:b,to:M}))){this.hide();return}(p=this.tippy)===null||p===void 0||p.setProps({getReferenceClientRect:((h=this.tippyOptions)===null||h===void 0?void 0:h.getReferenceClientRect)||(()=>{if(K3e(m.selection)){let w=s.nodeDOM(b);const C=w.dataset.nodeViewWrapper?w:w.querySelector("[data-node-view-wrapper]");if(C&&(w=C.firstChild),w)return w.getBoundingClientRect()}return nN(s,b,M)})}),this.show()},this.editor=t,this.element=r,this.view=o,this.updateDelay=i,l&&(this.shouldShow=l),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.addEventListener("dragstart",this.dragstartHandler),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.tippyOptions=a,this.element.remove(),this.element.style.visibility="visible"}createTooltip(){const{element:t}=this.editor.options,r=!!t.parentElement;this.tippy||!r||(this.tippy=vl(t,{duration:0,getReferenceClientRect:null,content:this.element,interactive:!0,trigger:"manual",placement:"top",hideOnClick:"toggle",...this.tippyOptions}),this.tippy.popper.firstChild&&this.tippy.popper.firstChild.addEventListener("blur",this.tippyBlurHandler))}update(t,r){const{state:o}=t,a=o.selection.from!==o.selection.to;if(this.updateDelay>0&&a){this.handleDebouncedUpdate(t,r);return}const i=!(r!=null&&r.selection.eq(t.state.selection)),l=!(r!=null&&r.doc.eq(t.state.doc));this.updateHandler(t,i,l,r)}show(){var t;(t=this.tippy)===null||t===void 0||t.show()}hide(){var t;(t=this.tippy)===null||t===void 0||t.hide()}destroy(){var t,r;!((t=this.tippy)===null||t===void 0)&&t.popper.firstChild&&this.tippy.popper.firstChild.removeEventListener("blur",this.tippyBlurHandler),(r=this.tippy)===null||r===void 0||r.destroy(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.removeEventListener("dragstart",this.dragstartHandler),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler)}}const xN=e=>new tn({key:typeof e.pluginKey=="string"?new yn(e.pluginKey):e.pluginKey,view:t=>new l6e({view:t,...e})});hn.create({name:"bubbleMenu",addOptions(){return{element:null,tippyOptions:{},pluginKey:"bubbleMenu",updateDelay:void 0,shouldShow:null}},addProseMirrorPlugins(){return this.options.element?[xN({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,tippyOptions:this.options.tippyOptions,updateDelay:this.options.updateDelay,shouldShow:this.options.shouldShow})]:[]}});class s6e{constructor({editor:t,element:r,view:o,tippyOptions:a={},shouldShow:i}){this.preventHide=!1,this.shouldShow=({view:l,state:s})=>{const{selection:c}=s,{$anchor:u,empty:d}=c,f=u.depth===1,p=u.parent.isTextblock&&!u.parent.type.spec.code&&!u.parent.textContent;return!(!l.hasFocus()||!d||!f||!p||!this.editor.isEditable)},this.mousedownHandler=()=>{this.preventHide=!0},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:l})=>{var s;if(this.preventHide){this.preventHide=!1;return}l!=null&&l.relatedTarget&&(!((s=this.element.parentNode)===null||s===void 0)&&s.contains(l.relatedTarget))||this.hide()},this.tippyBlurHandler=l=>{this.blurHandler({event:l})},this.editor=t,this.element=r,this.view=o,i&&(this.shouldShow=i),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.tippyOptions=a,this.element.remove(),this.element.style.visibility="visible"}createTooltip(){const{element:t}=this.editor.options,r=!!t.parentElement;this.tippy||!r||(this.tippy=vl(t,{duration:0,getReferenceClientRect:null,content:this.element,interactive:!0,trigger:"manual",placement:"right",hideOnClick:"toggle",...this.tippyOptions}),this.tippy.popper.firstChild&&this.tippy.popper.firstChild.addEventListener("blur",this.tippyBlurHandler))}update(t,r){var o,a,i;const{state:l}=t,{doc:s,selection:c}=l,{from:u,to:d}=c;if(r&&r.doc.eq(s)&&r.selection.eq(c))return;if(this.createTooltip(),!((o=this.shouldShow)===null||o===void 0?void 0:o.call(this,{editor:this.editor,view:t,state:l,oldState:r}))){this.hide();return}(a=this.tippy)===null||a===void 0||a.setProps({getReferenceClientRect:((i=this.tippyOptions)===null||i===void 0?void 0:i.getReferenceClientRect)||(()=>nN(t,u,d))}),this.show()}show(){var t;(t=this.tippy)===null||t===void 0||t.show()}hide(){var t;(t=this.tippy)===null||t===void 0||t.hide()}destroy(){var t,r;!((t=this.tippy)===null||t===void 0)&&t.popper.firstChild&&this.tippy.popper.firstChild.removeEventListener("blur",this.tippyBlurHandler),(r=this.tippy)===null||r===void 0||r.destroy(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler)}}const CN=e=>new tn({key:typeof e.pluginKey=="string"?new yn(e.pluginKey):e.pluginKey,view:t=>new s6e({view:t,...e})});hn.create({name:"floatingMenu",addOptions(){return{element:null,tippyOptions:{},pluginKey:"floatingMenu",shouldShow:null}},addProseMirrorPlugins(){return this.options.element?[CN({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,tippyOptions:this.options.tippyOptions,shouldShow:this.options.shouldShow})]:[]}});const c6e=n.defineComponent({name:"BubbleMenu",props:{pluginKey:{type:[String,Object],default:"bubbleMenu"},editor:{type:Object,required:!0},updateDelay:{type:Number,default:void 0},tippyOptions:{type:Object,default:()=>({})},shouldShow:{type:Function,default:null}},setup(e,{slots:t}){const r=n.ref(null);return n.onMounted(()=>{const{updateDelay:o,editor:a,pluginKey:i,shouldShow:l,tippyOptions:s}=e;a.registerPlugin(xN({updateDelay:o,editor:a,element:r.value,pluginKey:i,shouldShow:l,tippyOptions:s}))}),n.onBeforeUnmount(()=>{const{pluginKey:o,editor:a}=e;a.unregisterPlugin(o)}),()=>{var o;return n.h("div",{ref:r},(o=t.default)===null||o===void 0?void 0:o.call(t))}}});function o3(e){return n.customRef((t,r)=>({get(){return t(),e},set(o){e=o,requestAnimationFrame(()=>{requestAnimationFrame(()=>{r()})})}}))}class u6e extends Eye{constructor(t={}){return super(t),this.contentComponent=null,this.appContext=null,this.reactiveState=o3(this.view.state),this.reactiveExtensionStorage=o3(this.extensionStorage),this.on("beforeTransaction",({nextState:r})=>{this.reactiveState.value=r,this.reactiveExtensionStorage.value=this.extensionStorage}),n.markRaw(this)}get state(){return this.reactiveState?this.reactiveState.value:this.view.state}get storage(){return this.reactiveExtensionStorage?this.reactiveExtensionStorage.value:super.storage}registerPlugin(t,r){const o=super.registerPlugin(t,r);return this.reactiveState&&(this.reactiveState.value=o),o}unregisterPlugin(t){const r=super.unregisterPlugin(t);return this.reactiveState&&r&&(this.reactiveState.value=r),r}}const d6e=n.defineComponent({name:"EditorContent",props:{editor:{default:null,type:Object}},setup(e){const t=n.ref(),r=n.getCurrentInstance();return n.watchEffect(()=>{const o=e.editor;o&&o.options.element&&t.value&&n.nextTick(()=>{if(!t.value||!o.options.element.firstChild)return;const a=n.unref(t.value);t.value.append(...o.options.element.childNodes),o.contentComponent=r.ctx._,r&&(o.appContext={...r.appContext,provides:r.provides}),o.setOptions({element:a}),o.createNodeViews()})}),n.onBeforeUnmount(()=>{const o=e.editor;o&&(o.contentComponent=null,o.appContext=null)}),{rootEl:t}},render(){return n.h("div",{ref:e=>{this.rootEl=e}})}});n.defineComponent({name:"FloatingMenu",props:{pluginKey:{type:null,default:"floatingMenu"},editor:{type:Object,required:!0},tippyOptions:{type:Object,default:()=>({})},shouldShow:{type:Function,default:null}},setup(e,{slots:t}){const r=n.ref(null);return n.onMounted(()=>{const{pluginKey:o,editor:a,tippyOptions:i,shouldShow:l}=e;a.registerPlugin(CN({pluginKey:o,editor:a,element:r.value,tippyOptions:i,shouldShow:l}))}),n.onBeforeUnmount(()=>{const{pluginKey:o,editor:a}=e;a.unregisterPlugin(o)}),()=>{var o;return n.h("div",{ref:r},(o=t.default)===null||o===void 0?void 0:o.call(t))}}});n.defineComponent({name:"NodeViewContent",props:{as:{type:String,default:"div"}},render(){return n.h(this.as,{style:{whiteSpace:"pre-wrap"},"data-node-view-content":""})}});n.defineComponent({name:"NodeViewWrapper",props:{as:{type:String,default:"div"}},inject:["onDragStart","decorationClasses"],render(){var e,t;return n.h(this.as,{class:this.decorationClasses,style:{whiteSpace:"normal"},"data-node-view-wrapper":"",onDragstart:this.onDragStart},(t=(e=this.$slots).default)===null||t===void 0?void 0:t.call(e))}});const f6e=pr.create({name:"doc",topNode:!0,content:"block+"}),p6e=pr.create({name:"text",group:"inline"}),m6e=pr.create({name:"listItem",addOptions(){return{HTMLAttributes:{},bulletListTypeName:"bulletList",orderedListTypeName:"orderedList"}},content:"paragraph block*",defining:!0,parseHTML(){return[{tag:"li"}]},renderHTML({HTMLAttributes:e}){return["li",jn(this.options.HTMLAttributes,e),0]},addKeyboardShortcuts(){return{Enter:()=>this.editor.commands.splitListItem(this.name),Tab:()=>this.editor.commands.sinkListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)}}}),a3=new yn("templateHighlight"),h6e=hn.create({name:"templateHighlight",addOptions(){return{validVariables:[],isMailMergeMode:!1}},addProseMirrorPlugins(){const e=this;return[new tn({key:a3,state:{init(){return It.empty},apply(t){if(!e.options.isMailMergeMode)return It.empty;const r=e.options.validVariables||[],o=[];return t.doc.descendants((a,i)=>{if(!a.isText)return;const l=/{{\s*[\w.]+\s*}}/g;let s;for(;(s=l.exec(a.text))!==null;){const c=i+s.index,u=c+s[0].length,d=s[0],p=r.length===0||r.includes(d)?"template-variable-highlight":"template-variable-highlight-invalid";o.push(Un.inline(c,u,{class:p}))}}),It.create(t.doc,o)}},props:{decorations(t){return a3.getState(t)}}})]}}),g6e=pr.create({name:"paragraph",priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:"block",content:"inline*",parseHTML(){return[{tag:"p"}]},renderHTML({HTMLAttributes:e}){return["p",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setParagraph:()=>({commands:e})=>e.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),i3="min-height: 1.4em; overflow-wrap: break-word;",v6e="l-text-regular l-text-left color-lead-light my-3",y6e=g6e.extend({addAttributes(){return{class:{default:v6e,parseHTML:e=>{e.classList.forEach(t=>{t.includes("color-")&&t!=="color-lead-light"&&e.classList.remove(t)})}},style:{default:i3,parseHTML:e=>e.style=i3}}},addCommands(){return{setMarkUp:e=>({commands:t,chain:r})=>{switch(e){case"bold":return t.toggleBold();case"italic":return t.toggleItalic();case"underline":return t.toggleUnderline();case"heading":return t.toggleHeading({level:1});case"bulletList":return t.toggleBulletList();case"orderedList":return t.toggleOrderedList();case"blockquote":return t.toggleBlockquote();case"removeFormatting":return r().unsetAllMarks().clearNodes()}}}}}),M6e=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))$/,b6e=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))/g,w6e=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))$/,N6e=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))/g,k6e=oa.create({name:"bold",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"strong"},{tag:"b",getAttrs:e=>e.style.fontWeight!=="normal"&&null},{style:"font-weight=400",clearMark:e=>e.type.name===this.name},{style:"font-weight",getAttrs:e=>/^(bold(er)?|[5-9]\d{2,})$/.test(e)&&null}]},renderHTML({HTMLAttributes:e}){return["strong",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setBold:()=>({commands:e})=>e.setMark(this.name),toggleBold:()=>({commands:e})=>e.toggleMark(this.name),unsetBold:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-b":()=>this.editor.commands.toggleBold(),"Mod-B":()=>this.editor.commands.toggleBold()}},addInputRules(){return[Fu({find:M6e,type:this.type}),Fu({find:w6e,type:this.type})]},addPasteRules(){return[Is({find:b6e,type:this.type}),Is({find:N6e,type:this.type})]}}),x6e=k6e.extend({addAttributes(){return{class:{default:"l-bold"}}}}),C6e=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))$/,E6e=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))/g,T6e=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))$/,D6e=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))/g,S6e=oa.create({name:"italic",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"em"},{tag:"i",getAttrs:e=>e.style.fontStyle!=="normal"&&null},{style:"font-style=normal",clearMark:e=>e.type.name===this.name},{style:"font-style=italic"}]},renderHTML({HTMLAttributes:e}){return["em",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setItalic:()=>({commands:e})=>e.setMark(this.name),toggleItalic:()=>({commands:e})=>e.toggleMark(this.name),unsetItalic:()=>({commands:e})=>e.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-i":()=>this.editor.commands.toggleItalic(),"Mod-I":()=>this.editor.commands.toggleItalic()}},addInputRules(){return[Fu({find:C6e,type:this.type}),Fu({find:T6e,type:this.type})]},addPasteRules(){return[Is({find:E6e,type:this.type}),Is({find:D6e,type:this.type})]}}),_6e=S6e.extend({addAttributes(){return{class:{default:""}}}}),I6e=oa.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",jn(this.options.HTMLAttributes,e),0]},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()}}}),l3="",A6e=I6e.extend({addAttributes(){return{class:{default:l3,parseHTML:e=>e.style=l3}}},parseHTML(){return[{tag:"u"},{style:"border-bottom",getAttrs:e=>e!==void 0||e!==0}]}}),O6e=pr.create({name:"heading",addOptions(){return{levels:[1,2,3,4,5,6],HTMLAttributes:{}}},content:"inline*",group:"block",defining:!0,addAttributes(){return{level:{default:1,rendered:!1}}},parseHTML(){return this.options.levels.map(e=>({tag:`h${e}`,attrs:{level:e}}))},renderHTML({node:e,HTMLAttributes:t}){return[`h${this.options.levels.includes(e.attrs.level)?e.attrs.level:this.options.levels[0]}`,jn(this.options.HTMLAttributes,t),0]},addCommands(){return{setHeading:e=>({commands:t})=>this.options.levels.includes(e.level)?t.setNode(this.name,e):!1,toggleHeading:e=>({commands:t})=>this.options.levels.includes(e.level)?t.toggleNode(this.name,"paragraph",e):!1}},addKeyboardShortcuts(){return this.options.levels.reduce((e,t)=>({...e,[`Mod-Alt-${t}`]:()=>this.editor.commands.toggleHeading({level:t})}),{})},addInputRules(){return this.options.levels.map(e=>Tye({find:new RegExp(`^(#{1,${e}})\\s$`),type:this.type,getAttributes:{level:e}}))}}),z6e=O6e.extend({addOptions(){var e;return{...(e=this.parent)==null?void 0:e.call(this),levels:[1],HTMLAttributes:{class:"l-h2"}}}}),j6e="listItem",s3="textStyle",c3=/^\s*([-+*])\s$/,L6e=pr.create({name:"bulletList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:"ul"}]},renderHTML({HTMLAttributes:e}){return["ul",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{toggleBulletList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(j6e,this.editor.getAttributes(s3)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-8":()=>this.editor.commands.toggleBulletList()}},addInputRules(){let e=_s({find:c3,type:this.type});return(this.options.keepMarks||this.options.keepAttributes)&&(e=_s({find:c3,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:()=>this.editor.getAttributes(s3),editor:this.editor})),[e]}}),B6e=L6e.extend({addAttributes(){return{class:{default:"color-lead-light pl-4"},style:{default:"list-style-type: disc;"}}}}),V6e="listItem",u3="textStyle",d3=/^(\d+)\.\s$/,$6e=pr.create({name:"orderedList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes(){return{start:{default:1,parseHTML:e=>e.hasAttribute("start")?parseInt(e.getAttribute("start")||"",10):1},type:{default:void 0,parseHTML:e=>e.getAttribute("type")}}},parseHTML(){return[{tag:"ol"}]},renderHTML({HTMLAttributes:e}){const{start:t,...r}=e;return t===1?["ol",jn(this.options.HTMLAttributes,r),0]:["ol",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{toggleOrderedList:()=>({commands:e,chain:t})=>this.options.keepAttributes?t().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(V6e,this.editor.getAttributes(u3)).run():e.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let e=_s({find:d3,type:this.type,getAttributes:t=>({start:+t[1]}),joinPredicate:(t,r)=>r.childCount+r.attrs.start===+t[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(e=_s({find:d3,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:t=>({start:+t[1],...this.editor.getAttributes(u3)}),joinPredicate:(t,r)=>r.childCount+r.attrs.start===+t[1],editor:this.editor})),[e]}}),P6e=$6e.extend({addAttributes(){return{class:{default:"color-lead-light pl-4"},style:{default:"list-style-type: decimal"}}}}),R6e=/^\s*>\s$/,F6e=pr.create({name:"blockquote",addOptions(){return{HTMLAttributes:{}}},content:"block+",group:"block",defining:!0,parseHTML(){return[{tag:"blockquote"}]},renderHTML({HTMLAttributes:e}){return["blockquote",jn(this.options.HTMLAttributes,e),0]},addCommands(){return{setBlockquote:()=>({commands:e})=>e.wrapIn(this.name),toggleBlockquote:()=>({commands:e})=>e.toggleWrap(this.name),unsetBlockquote:()=>({commands:e})=>e.lift(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-b":()=>this.editor.commands.toggleBlockquote()}},addInputRules(){return[_s({find:R6e,type:this.type})]}}),U6e=F6e.extend({addAttributes(){return{class:{default:"px-3 mx-0 my-2"},style:{default:"border-left: 3px solid var(--color-gray-50)"}}}}),H6e="aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4vianca6w0s2x0a2z0ure5ba0by2idu3namex3narepublic11d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2ntley5rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0cast4mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dabur3d1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3nlop4pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2o0dyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0ardian6cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6logistics9properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3ncaster6d0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2psy3ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rckmsd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2tura4vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9dnavy5lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0america6xi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0stone5umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0a1b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp2w2ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2olterskluwer11odside6rk0s2ld3w2s1tc1f3xbox3erox4finity6ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2",Y6e="ελ1υ2бг1ел3дети4ею2католик6ом3мкд2он1сква6онлайн5рг3рус2ф2сайт3рб3укр3қаз3հայ3ישראל5קום3ابوظبي5رامكو5لاردن4بحرين5جزائر5سعودية6عليان5مغرب5مارات5یران5بارت2زار4يتك3ھارت5تونس4سودان3رية5شبكة4عراق2ب2مان4فلسطين6قطر3كاثوليك6وم3مصر2ليسيا5وريتانيا7قع4همراه5پاکستان7ڀارت4कॉम3नेट3भारत0म्3ोत5संगठन5বাংলা5ভারত2ৰত4ਭਾਰਤ4ભારત4ଭାରତ4இந்தியா6லங்கை6சிங்கப்பூர்11భారత్5ಭಾರತ4ഭാരതം5ලංකා4คอม3ไทย3ລາວ3გე2みんな3アマゾン4クラウド4グーグル4コム2ストア3セール3ファッション6ポイント4世界2中信1国1國1文网3亚马逊3企业2佛山2信息2健康2八卦2公司1益2台湾1灣2商城1店1标2嘉里0大酒店5在线2大拿2天主教3娱乐2家電2广东2微博2慈善2我爱你3手机2招聘2政务1府2新加坡2闻2时尚2書籍2机构2淡马锡3游戏2澳門2点看2移动2组织机构4网址1店1站1络2联通2谷歌2购物2通販2集团2電訊盈科4飞利浦3食品2餐厅2香格里拉3港2닷넷1컴2삼성2한국2",el=(e,t)=>{for(const r in t)e[r]=t[r];return e},Y0="numeric",Q0="ascii",W0="alpha",Jc="asciinumeric",Ic="alphanumeric",q0="domain",EN="emoji",Q6e="scheme",W6e="slashscheme",f3="whitespace";function q6e(e,t){return e in t||(t[e]=[]),t[e]}function Ta(e,t,r){t[Y0]&&(t[Jc]=!0,t[Ic]=!0),t[Q0]&&(t[Jc]=!0,t[W0]=!0),t[Jc]&&(t[Ic]=!0),t[W0]&&(t[Ic]=!0),t[Ic]&&(t[q0]=!0),t[EN]&&(t[q0]=!0);for(const o in t){const a=q6e(o,r);a.indexOf(e)<0&&a.push(e)}}function G6e(e,t){const r={};for(const o in t)t[o].indexOf(e)>=0&&(r[o]=!0);return r}function En(e){e===void 0&&(e=null),this.j={},this.jr=[],this.jd=null,this.t=e}En.groups={};En.prototype={accepts(){return!!this.t},go(e){const t=this,r=t.j[e];if(r)return r;for(let o=0;o<t.jr.length;o++){const a=t.jr[o][0],i=t.jr[o][1];if(i&&a.test(e))return i}return t.jd},has(e,t){return t===void 0&&(t=!1),t?e in this.j:!!this.go(e)},ta(e,t,r,o){for(let a=0;a<e.length;a++)this.tt(e[a],t,r,o)},tr(e,t,r,o){o=o||En.groups;let a;return t&&t.j?a=t:(a=new En(t),r&&o&&Ta(t,r,o)),this.jr.push([e,a]),a},ts(e,t,r,o){let a=this;const i=e.length;if(!i)return a;for(let l=0;l<i-1;l++)a=a.tt(e[l]);return a.tt(e[i-1],t,r,o)},tt(e,t,r,o){o=o||En.groups;const a=this;if(t&&t.j)return a.j[e]=t,t;const i=t;let l,s=a.go(e);if(s?(l=new En,el(l.j,s.j),l.jr.push.apply(l.jr,s.jr),l.jd=s.jd,l.t=s.t):l=new En,i){if(o)if(l.t&&typeof l.t=="string"){const c=el(G6e(l.t,o),r);Ta(i,c,o)}else r&&Ta(i,r,o);l.t=i}return a.j[e]=l,l}};const We=(e,t,r,o,a)=>e.ta(t,r,o,a),Xn=(e,t,r,o,a)=>e.tr(t,r,o,a),p3=(e,t,r,o,a)=>e.ts(t,r,o,a),Me=(e,t,r,o,a)=>e.tt(t,r,o,a),uo="WORD",G0="UWORD",Ls="LOCALHOST",K0="TLD",J0="UTLD",Zc="SCHEME",yi="SLASH_SCHEME",y2="NUM",TN="WS",M2="NL",Jl="OPENBRACE",Zl="CLOSEBRACE",Yu="OPENBRACKET",Qu="CLOSEBRACKET",Wu="OPENPAREN",qu="CLOSEPAREN",Gu="OPENANGLEBRACKET",Ku="CLOSEANGLEBRACKET",Ju="FULLWIDTHLEFTPAREN",Zu="FULLWIDTHRIGHTPAREN",Xu="LEFTCORNERBRACKET",ed="RIGHTCORNERBRACKET",td="LEFTWHITECORNERBRACKET",nd="RIGHTWHITECORNERBRACKET",rd="FULLWIDTHLESSTHAN",od="FULLWIDTHGREATERTHAN",ad="AMPERSAND",id="APOSTROPHE",ld="ASTERISK",jo="AT",sd="BACKSLASH",cd="BACKTICK",ud="CARET",Ro="COLON",b2="COMMA",dd="DOLLAR",Ur="DOT",fd="EQUALS",w2="EXCLAMATION",Hr="HYPHEN",pd="PERCENT",md="PIPE",hd="PLUS",gd="POUND",vd="QUERY",N2="QUOTE",k2="SEMI",Yr="SLASH",Xl="TILDE",yd="UNDERSCORE",DN="EMOJI",Md="SYM";var SN=Object.freeze({__proto__:null,WORD:uo,UWORD:G0,LOCALHOST:Ls,TLD:K0,UTLD:J0,SCHEME:Zc,SLASH_SCHEME:yi,NUM:y2,WS:TN,NL:M2,OPENBRACE:Jl,CLOSEBRACE:Zl,OPENBRACKET:Yu,CLOSEBRACKET:Qu,OPENPAREN:Wu,CLOSEPAREN:qu,OPENANGLEBRACKET:Gu,CLOSEANGLEBRACKET:Ku,FULLWIDTHLEFTPAREN:Ju,FULLWIDTHRIGHTPAREN:Zu,LEFTCORNERBRACKET:Xu,RIGHTCORNERBRACKET:ed,LEFTWHITECORNERBRACKET:td,RIGHTWHITECORNERBRACKET:nd,FULLWIDTHLESSTHAN:rd,FULLWIDTHGREATERTHAN:od,AMPERSAND:ad,APOSTROPHE:id,ASTERISK:ld,AT:jo,BACKSLASH:sd,BACKTICK:cd,CARET:ud,COLON:Ro,COMMA:b2,DOLLAR:dd,DOT:Ur,EQUALS:fd,EXCLAMATION:w2,HYPHEN:Hr,PERCENT:pd,PIPE:md,PLUS:hd,POUND:gd,QUERY:vd,QUOTE:N2,SEMI:k2,SLASH:Yr,TILDE:Xl,UNDERSCORE:yd,EMOJI:DN,SYM:Md});const fi=/[a-z]/,hp=/\p{L}/u,gp=/\p{Emoji}/u,vp=/\d/,m3=/\s/,h3=`
|
|
156
|
+
`,K6e="️",J6e="";let Ac=null,Oc=null;function Z6e(e){e===void 0&&(e=[]);const t={};En.groups=t;const r=new En;Ac==null&&(Ac=g3(H6e)),Oc==null&&(Oc=g3(Y6e)),Me(r,"'",id),Me(r,"{",Jl),Me(r,"}",Zl),Me(r,"[",Yu),Me(r,"]",Qu),Me(r,"(",Wu),Me(r,")",qu),Me(r,"<",Gu),Me(r,">",Ku),Me(r,"(",Ju),Me(r,")",Zu),Me(r,"「",Xu),Me(r,"」",ed),Me(r,"『",td),Me(r,"』",nd),Me(r,"<",rd),Me(r,">",od),Me(r,"&",ad),Me(r,"*",ld),Me(r,"@",jo),Me(r,"`",cd),Me(r,"^",ud),Me(r,":",Ro),Me(r,",",b2),Me(r,"$",dd),Me(r,".",Ur),Me(r,"=",fd),Me(r,"!",w2),Me(r,"-",Hr),Me(r,"%",pd),Me(r,"|",md),Me(r,"+",hd),Me(r,"#",gd),Me(r,"?",vd),Me(r,'"',N2),Me(r,"/",Yr),Me(r,";",k2),Me(r,"~",Xl),Me(r,"_",yd),Me(r,"\\",sd);const o=Xn(r,vp,y2,{[Y0]:!0});Xn(o,vp,o);const a=Xn(r,fi,uo,{[Q0]:!0});Xn(a,fi,a);const i=Xn(r,hp,G0,{[W0]:!0});Xn(i,fi),Xn(i,hp,i);const l=Xn(r,m3,TN,{[f3]:!0});Me(r,h3,M2,{[f3]:!0}),Me(l,h3),Xn(l,m3,l);const s=Xn(r,gp,DN,{[EN]:!0});Xn(s,gp,s),Me(s,K6e,s);const c=Me(s,J6e);Xn(c,gp,s);const u=[[fi,a]],d=[[fi,null],[hp,i]];for(let f=0;f<Ac.length;f++)So(r,Ac[f],K0,uo,u);for(let f=0;f<Oc.length;f++)So(r,Oc[f],J0,G0,d);Ta(K0,{tld:!0,ascii:!0},t),Ta(J0,{utld:!0,alpha:!0},t),So(r,"file",Zc,uo,u),So(r,"mailto",Zc,uo,u),So(r,"http",yi,uo,u),So(r,"https",yi,uo,u),So(r,"ftp",yi,uo,u),So(r,"ftps",yi,uo,u),Ta(Zc,{scheme:!0,ascii:!0},t),Ta(yi,{slashscheme:!0,ascii:!0},t),e=e.sort((f,p)=>f[0]>p[0]?1:-1);for(let f=0;f<e.length;f++){const p=e[f][0],m=e[f][1]?{[Q6e]:!0}:{[W6e]:!0};p.indexOf("-")>=0?m[q0]=!0:fi.test(p)?vp.test(p)?m[Jc]=!0:m[Q0]=!0:m[Y0]=!0,p3(r,p,p,m)}return p3(r,"localhost",Ls,{ascii:!0}),r.jd=new En(Md),{start:r,tokens:el({groups:t},SN)}}function X6e(e,t){const r=ebe(t.replace(/[A-Z]/g,s=>s.toLowerCase())),o=r.length,a=[];let i=0,l=0;for(;l<o;){let s=e,c=null,u=0,d=null,f=-1,p=-1;for(;l<o&&(c=s.go(r[l]));)s=c,s.accepts()?(f=0,p=0,d=s):f>=0&&(f+=r[l].length,p++),u+=r[l].length,i+=r[l].length,l++;i-=f,l-=p,u-=f,a.push({t:d.t,v:t.slice(i-u,i),s:i-u,e:i})}return a}function ebe(e){const t=[],r=e.length;let o=0;for(;o<r;){let a=e.charCodeAt(o),i,l=a<55296||a>56319||o+1===r||(i=e.charCodeAt(o+1))<56320||i>57343?e[o]:e.slice(o,o+2);t.push(l),o+=l.length}return t}function So(e,t,r,o,a){let i;const l=t.length;for(let s=0;s<l-1;s++){const c=t[s];e.j[c]?i=e.j[c]:(i=new En(o),i.jr=a.slice(),e.j[c]=i),e=i}return i=new En(r),i.jr=a.slice(),e.j[t[l-1]]=i,i}function g3(e){const t=[],r=[];let o=0,a="0123456789";for(;o<e.length;){let i=0;for(;a.indexOf(e[o+i])>=0;)i++;if(i>0){t.push(r.join(""));for(let l=parseInt(e.substring(o,o+i),10);l>0;l--)r.pop();o+=i}else r.push(e[o]),o++}return t}const Bs={defaultProtocol:"http",events:null,format:v3,formatHref:v3,nl2br:!1,tagName:"a",target:null,rel:null,validate:!0,truncate:1/0,className:null,attributes:null,ignoreTags:[],render:null};function x2(e,t){t===void 0&&(t=null);let r=el({},Bs);e&&(r=el(r,e instanceof x2?e.o:e));const o=r.ignoreTags,a=[];for(let i=0;i<o.length;i++)a.push(o[i].toUpperCase());this.o=r,t&&(this.defaultRender=t),this.ignoreTags=a}x2.prototype={o:Bs,ignoreTags:[],defaultRender(e){return e},check(e){return this.get("validate",e.toString(),e)},get(e,t,r){const o=t!=null;let a=this.o[e];return a&&(typeof a=="object"?(a=r.t in a?a[r.t]:Bs[e],typeof a=="function"&&o&&(a=a(t,r))):typeof a=="function"&&o&&(a=a(t,r.t,r)),a)},getObj(e,t,r){let o=this.o[e];return typeof o=="function"&&t!=null&&(o=o(t,r.t,r)),o},render(e){const t=e.render(this);return(this.get("render",null,e)||this.defaultRender)(t,e.t,e)}};function v3(e){return e}function _N(e,t){this.t="token",this.v=e,this.tk=t}_N.prototype={isLink:!1,toString(){return this.v},toHref(e){return this.toString()},toFormattedString(e){const t=this.toString(),r=e.get("truncate",t,this),o=e.get("format",t,this);return r&&o.length>r?o.substring(0,r)+"…":o},toFormattedHref(e){return e.get("formatHref",this.toHref(e.get("defaultProtocol")),this)},startIndex(){return this.tk[0].s},endIndex(){return this.tk[this.tk.length-1].e},toObject(e){return e===void 0&&(e=Bs.defaultProtocol),{type:this.t,value:this.toString(),isLink:this.isLink,href:this.toHref(e),start:this.startIndex(),end:this.endIndex()}},toFormattedObject(e){return{type:this.t,value:this.toFormattedString(e),isLink:this.isLink,href:this.toFormattedHref(e),start:this.startIndex(),end:this.endIndex()}},validate(e){return e.get("validate",this.toString(),this)},render(e){const t=this,r=this.toHref(e.get("defaultProtocol")),o=e.get("formatHref",r,this),a=e.get("tagName",r,t),i=this.toFormattedString(e),l={},s=e.get("className",r,t),c=e.get("target",r,t),u=e.get("rel",r,t),d=e.getObj("attributes",r,t),f=e.getObj("events",r,t);return l.href=o,s&&(l.class=s),c&&(l.target=c),u&&(l.rel=u),d&&el(l,d),{tagName:a,attributes:l,content:i,eventListeners:f}}};function vf(e,t){class r extends _N{constructor(a,i){super(a,i),this.t=e}}for(const o in t)r.prototype[o]=t[o];return r.t=e,r}const y3=vf("email",{isLink:!0,toHref(){return"mailto:"+this.toString()}}),M3=vf("text"),tbe=vf("nl"),zc=vf("url",{isLink:!0,toHref(e){return e===void 0&&(e=Bs.defaultProtocol),this.hasProtocol()?this.v:`${e}://${this.v}`},hasProtocol(){const e=this.tk;return e.length>=2&&e[0].t!==Ls&&e[1].t===Ro}}),er=e=>new En(e);function nbe(e){let{groups:t}=e;const r=t.domain.concat([ad,ld,jo,sd,cd,ud,dd,fd,Hr,y2,pd,md,hd,gd,Yr,Md,Xl,yd]),o=[id,Ro,b2,Ur,w2,vd,N2,k2,Gu,Ku,Jl,Zl,Qu,Yu,Wu,qu,Ju,Zu,Xu,ed,td,nd,rd,od],a=[ad,id,ld,sd,cd,ud,dd,fd,Hr,Jl,Zl,pd,md,hd,gd,vd,Yr,Md,Xl,yd],i=er(),l=Me(i,Xl);We(l,a,l),We(l,t.domain,l);const s=er(),c=er(),u=er();We(i,t.domain,s),We(i,t.scheme,c),We(i,t.slashscheme,u),We(s,a,l),We(s,t.domain,s);const d=Me(s,jo);Me(l,jo,d),Me(c,jo,d),Me(u,jo,d);const f=Me(l,Ur);We(f,a,l),We(f,t.domain,l);const p=er();We(d,t.domain,p),We(p,t.domain,p);const h=Me(p,Ur);We(h,t.domain,p);const m=er(y3);We(h,t.tld,m),We(h,t.utld,m),Me(d,Ls,m);const g=Me(p,Hr);We(g,t.domain,p),We(m,t.domain,p),Me(m,Ur,h),Me(m,Hr,g);const v=Me(m,Ro);We(v,t.numeric,y3);const y=Me(s,Hr),N=Me(s,Ur);We(y,t.domain,s),We(N,a,l),We(N,t.domain,s);const b=er(zc);We(N,t.tld,b),We(N,t.utld,b),We(b,t.domain,s),We(b,a,l),Me(b,Ur,N),Me(b,Hr,y),Me(b,jo,d);const M=Me(b,Ro),k=er(zc);We(M,t.numeric,k);const w=er(zc),C=er();We(w,r,w),We(w,o,C),We(C,r,w),We(C,o,C),Me(b,Yr,w),Me(k,Yr,w);const E=Me(c,Ro),A=Me(u,Ro),O=Me(A,Yr),_=Me(O,Yr);We(c,t.domain,s),Me(c,Ur,N),Me(c,Hr,y),We(u,t.domain,s),Me(u,Ur,N),Me(u,Hr,y),We(E,t.domain,w),Me(E,Yr,w),We(_,t.domain,w),We(_,r,w),Me(_,Yr,w);const j=[[Jl,Zl],[Yu,Qu],[Wu,qu],[Gu,Ku],[Ju,Zu],[Xu,ed],[td,nd],[rd,od]];for(let R=0;R<j.length;R++){const[P,$]=j[R],V=Me(w,P);Me(C,P,V),Me(V,$,w);const D=er(zc);We(V,r,D);const x=er();We(V,o),We(D,r,D),We(D,o,x),We(x,r,D),We(x,o,x),Me(D,$,w),Me(x,$,w)}return Me(i,Ls,b),Me(i,M2,tbe),{start:i,tokens:SN}}function rbe(e,t,r){let o=r.length,a=0,i=[],l=[];for(;a<o;){let s=e,c=null,u=null,d=0,f=null,p=-1;for(;a<o&&!(c=s.go(r[a].t));)l.push(r[a++]);for(;a<o&&(u=c||s.go(r[a].t));)c=null,s=u,s.accepts()?(p=0,f=s):p>=0&&p++,a++,d++;if(p<0)a-=d,a<o&&(l.push(r[a]),a++);else{l.length>0&&(i.push(yp(M3,t,l)),l=[]),a-=p,d-=p;const h=f.t,m=r.slice(a-d,a);i.push(yp(h,t,m))}}return l.length>0&&i.push(yp(M3,t,l)),i}function yp(e,t,r){const o=r[0].s,a=r[r.length-1].e,i=t.slice(o,a);return new e(i,r)}const obe=typeof console<"u"&&console&&console.warn||(()=>{}),abe="until manual call of linkify.init(). Register all schemes and plugins before invoking linkify the first time.",Tt={scanner:null,parser:null,tokenQueue:[],pluginQueue:[],customSchemes:[],initialized:!1};function ibe(){En.groups={},Tt.scanner=null,Tt.parser=null,Tt.tokenQueue=[],Tt.pluginQueue=[],Tt.customSchemes=[],Tt.initialized=!1}function b3(e,t){if(t===void 0&&(t=!1),Tt.initialized&&obe(`linkifyjs: already initialized - will not register custom scheme "${e}" ${abe}`),!/^[0-9a-z]+(-[0-9a-z]+)*$/.test(e))throw new Error(`linkifyjs: incorrect scheme format.
|
|
157
157
|
1. Must only contain digits, lowercase ASCII letters or "-"
|
|
158
158
|
2. Cannot start or end with "-"
|
|
159
|
-
3. "-" cannot repeat`);Tt.customSchemes.push([e,t])}function
|
|
160
|
-
`},addCommands(){return{setHardBreak:()=>({commands:e,chain:t,state:r,editor:o})=>e.first([()=>e.exitCode(),()=>e.command(()=>{const{selection:a,storedMarks:i}=r;if(a.$from.parent.type.spec.isolating)return!1;const{keepMarks:l}=this.options,{splittableMarks:s}=o.extensionManager,c=i||a.$to.parentOffset&&a.$from.marks();return t().insertContent({type:this.name}).command(({tr:u,dispatch:d})=>{if(d&&c&&l){const f=c.filter(p=>s.includes(p.type.name));u.ensureMarks(f)}return!0}).run()})])}},addKeyboardShortcuts(){return{"Mod-Enter":()=>this.editor.commands.setHardBreak(),"Shift-Enter":()=>this.editor.commands.setHardBreak()}}}),fbe=C3.extend({defaultOptions:{...C3.options,keepMarks:!1},addKeyboardShortcuts(){return{"Shift-Enter":()=>this.editor.commands.setHardBreak()}}});var bd=200,Xt=function(){};Xt.prototype.append=function(t){return t.length?(t=Xt.from(t),!this.length&&t||t.length<bd&&this.leafAppend(t)||this.length<bd&&t.leafPrepend(this)||this.appendInner(t)):this};Xt.prototype.prepend=function(t){return t.length?Xt.from(t).append(this):this};Xt.prototype.appendInner=function(t){return new pbe(this,t)};Xt.prototype.slice=function(t,r){return t===void 0&&(t=0),r===void 0&&(r=this.length),t>=r?Xt.empty:this.sliceInner(Math.max(0,t),Math.min(this.length,r))};Xt.prototype.get=function(t){if(!(t<0||t>=this.length))return this.getInner(t)};Xt.prototype.forEach=function(t,r,o){r===void 0&&(r=0),o===void 0&&(o=this.length),r<=o?this.forEachInner(t,r,o,0):this.forEachInvertedInner(t,r,o,0)};Xt.prototype.map=function(t,r,o){r===void 0&&(r=0),o===void 0&&(o=this.length);var a=[];return this.forEach(function(i,l){return a.push(t(i,l))},r,o),a};Xt.from=function(t){return t instanceof Xt?t:t&&t.length?new ON(t):Xt.empty};var ON=function(e){function t(o){e.call(this),this.values=o}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var r={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(a,i){return a==0&&i==this.length?this:new t(this.values.slice(a,i))},t.prototype.getInner=function(a){return this.values[a]},t.prototype.forEachInner=function(a,i,l,s){for(var c=i;c<l;c++)if(a(this.values[c],s+c)===!1)return!1},t.prototype.forEachInvertedInner=function(a,i,l,s){for(var c=i-1;c>=l;c--)if(a(this.values[c],s+c)===!1)return!1},t.prototype.leafAppend=function(a){if(this.length+a.length<=bd)return new t(this.values.concat(a.flatten()))},t.prototype.leafPrepend=function(a){if(this.length+a.length<=bd)return new t(a.flatten().concat(this.values))},r.length.get=function(){return this.values.length},r.depth.get=function(){return 0},Object.defineProperties(t.prototype,r),t}(Xt);Xt.empty=new ON([]);var pbe=function(e){function t(r,o){e.call(this),this.left=r,this.right=o,this.length=r.length+o.length,this.depth=Math.max(r.depth,o.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(o){return o<this.left.length?this.left.get(o):this.right.get(o-this.left.length)},t.prototype.forEachInner=function(o,a,i,l){var s=this.left.length;if(a<s&&this.left.forEachInner(o,a,Math.min(i,s),l)===!1||i>s&&this.right.forEachInner(o,Math.max(a-s,0),Math.min(this.length,i)-s,l+s)===!1)return!1},t.prototype.forEachInvertedInner=function(o,a,i,l){var s=this.left.length;if(a>s&&this.right.forEachInvertedInner(o,a-s,Math.max(i,s)-s,l+s)===!1||i<s&&this.left.forEachInvertedInner(o,Math.min(a,s),i,l)===!1)return!1},t.prototype.sliceInner=function(o,a){if(o==0&&a==this.length)return this;var i=this.left.length;return a<=i?this.left.slice(o,a):o>=i?this.right.slice(o-i,a-i):this.left.slice(o,i).append(this.right.slice(0,a-i))},t.prototype.leafAppend=function(o){var a=this.right.leafAppend(o);if(a)return new t(this.left,a)},t.prototype.leafPrepend=function(o){var a=this.left.leafPrepend(o);if(a)return new t(a,this.right)},t.prototype.appendInner=function(o){return this.left.depth>=Math.max(this.right.depth,o.depth)+1?new t(this.left,new t(this.right,o)):new t(this,o)},t}(Xt);const mbe=500;class Tr{constructor(t,r){this.items=t,this.eventCount=r}popEvent(t,r){if(this.eventCount==0)return null;let o=this.items.length;for(;;o--)if(this.items.get(o-1).selection){--o;break}let a,i;r&&(a=this.remapping(o,this.items.length),i=a.maps.length);let l=t.tr,s,c,u=[],d=[];return this.items.forEach((f,p)=>{if(!f.step){a||(a=this.remapping(o,p+1),i=a.maps.length),i--,d.push(f);return}if(a){d.push(new Qr(f.map));let h=f.step.map(a.slice(i)),m;h&&l.maybeStep(h).doc&&(m=l.mapping.maps[l.mapping.maps.length-1],u.push(new Qr(m,void 0,void 0,u.length+d.length))),i--,m&&a.appendMap(m,i)}else l.maybeStep(f.step);if(f.selection)return s=a?f.selection.map(a.slice(i)):f.selection,c=new Tr(this.items.slice(0,o).append(d.reverse().concat(u)),this.eventCount-1),!1},this.items.length,0),{remaining:c,transform:l,selection:s}}addTransform(t,r,o,a){let i=[],l=this.eventCount,s=this.items,c=!a&&s.length?s.get(s.length-1):null;for(let d=0;d<t.steps.length;d++){let f=t.steps[d].invert(t.docs[d]),p=new Qr(t.mapping.maps[d],f,r),h;(h=c&&c.merge(p))&&(p=h,d?i.pop():s=s.slice(0,s.length-1)),i.push(p),r&&(l++,r=void 0),a||(c=p)}let u=l-o.depth;return u>gbe&&(s=hbe(s,u),l-=u),new Tr(s.append(i),l)}remapping(t,r){let o=new Di;return this.items.forEach((a,i)=>{let l=a.mirrorOffset!=null&&i-a.mirrorOffset>=t?o.maps.length-a.mirrorOffset:void 0;o.appendMap(a.map,l)},t,r),o}addMaps(t){return this.eventCount==0?this:new Tr(this.items.append(t.map(r=>new Qr(r))),this.eventCount)}rebased(t,r){if(!this.eventCount)return this;let o=[],a=Math.max(0,this.items.length-r),i=t.mapping,l=t.steps.length,s=this.eventCount;this.items.forEach(p=>{p.selection&&s--},a);let c=r;this.items.forEach(p=>{let h=i.getMirror(--c);if(h==null)return;l=Math.min(l,h);let m=i.maps[h];if(p.step){let g=t.steps[h].invert(t.docs[h]),v=p.selection&&p.selection.map(i.slice(c+1,h));v&&s++,o.push(new Qr(m,g,v))}else o.push(new Qr(m))},a);let u=[];for(let p=r;p<l;p++)u.push(new Qr(i.maps[p]));let d=this.items.slice(0,a).append(u).append(o),f=new Tr(d,s);return f.emptyItemCount()>mbe&&(f=f.compress(this.items.length-o.length)),f}emptyItemCount(){let t=0;return this.items.forEach(r=>{r.step||t++}),t}compress(t=this.items.length){let r=this.remapping(0,t),o=r.maps.length,a=[],i=0;return this.items.forEach((l,s)=>{if(s>=t)a.push(l),l.selection&&i++;else if(l.step){let c=l.step.map(r.slice(o)),u=c&&c.getMap();if(o--,u&&r.appendMap(u,o),c){let d=l.selection&&l.selection.map(r.slice(o));d&&i++;let f=new Qr(u.invert(),c,d),p,h=a.length-1;(p=a.length&&a[h].merge(f))?a[h]=p:a.push(f)}}else l.map&&o--},this.items.length,0),new Tr(Xt.from(a.reverse()),i)}}Tr.empty=new Tr(Xt.empty,0);function hbe(e,t){let r;return e.forEach((o,a)=>{if(o.selection&&t--==0)return r=a,!1}),e.slice(r)}class Qr{constructor(t,r,o,a){this.map=t,this.step=r,this.selection=o,this.mirrorOffset=a}merge(t){if(this.step&&t.step&&!t.selection){let r=t.step.merge(this.step);if(r)return new Qr(r.getMap().invert(),r,this.selection)}}}class Lo{constructor(t,r,o,a,i){this.done=t,this.undone=r,this.prevRanges=o,this.prevTime=a,this.prevComposition=i}}const gbe=20;function vbe(e,t,r,o){let a=r.getMeta(ja),i;if(a)return a.historyState;r.getMeta(bbe)&&(e=new Lo(e.done,e.undone,null,0,-1));let l=r.getMeta("appendedTransaction");if(r.steps.length==0)return e;if(l&&l.getMeta(ja))return l.getMeta(ja).redo?new Lo(e.done.addTransform(r,void 0,o,Xc(t)),e.undone,E3(r.mapping.maps),e.prevTime,e.prevComposition):new Lo(e.done,e.undone.addTransform(r,void 0,o,Xc(t)),null,e.prevTime,e.prevComposition);if(r.getMeta("addToHistory")!==!1&&!(l&&l.getMeta("addToHistory")===!1)){let s=r.getMeta("composition"),c=e.prevTime==0||!l&&e.prevComposition!=s&&(e.prevTime<(r.time||0)-o.newGroupDelay||!ybe(r,e.prevRanges)),u=l?Mp(e.prevRanges,r.mapping):E3(r.mapping.maps);return new Lo(e.done.addTransform(r,c?t.selection.getBookmark():void 0,o,Xc(t)),Tr.empty,u,r.time,s??e.prevComposition)}else return(i=r.getMeta("rebased"))?new Lo(e.done.rebased(r,i),e.undone.rebased(r,i),Mp(e.prevRanges,r.mapping),e.prevTime,e.prevComposition):new Lo(e.done.addMaps(r.mapping.maps),e.undone.addMaps(r.mapping.maps),Mp(e.prevRanges,r.mapping),e.prevTime,e.prevComposition)}function ybe(e,t){if(!t)return!1;if(!e.docChanged)return!0;let r=!1;return e.mapping.maps[0].forEach((o,a)=>{for(let i=0;i<t.length;i+=2)o<=t[i+1]&&a>=t[i]&&(r=!0)}),r}function E3(e){let t=[];for(let r=e.length-1;r>=0&&t.length==0;r--)e[r].forEach((o,a,i,l)=>t.push(i,l));return t}function Mp(e,t){if(!e)return null;let r=[];for(let o=0;o<e.length;o+=2){let a=t.map(e[o],1),i=t.map(e[o+1],-1);a<=i&&r.push(a,i)}return r}function Mbe(e,t,r){let o=Xc(t),a=ja.get(t).spec.config,i=(r?e.undone:e.done).popEvent(t,o);if(!i)return null;let l=i.selection.resolve(i.transform.doc),s=(r?e.done:e.undone).addTransform(i.transform,t.selection.getBookmark(),a,o),c=new Lo(r?s:i.remaining,r?i.remaining:s,null,0,-1);return i.transform.setSelection(l).setMeta(ja,{redo:r,historyState:c})}let bp=!1,T3=null;function Xc(e){let t=e.plugins;if(T3!=t){bp=!1,T3=t;for(let r=0;r<t.length;r++)if(t[r].spec.historyPreserveItems){bp=!0;break}}return bp}const ja=new yn("history"),bbe=new yn("closeHistory");function wbe(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new tn({key:ja,state:{init(){return new Lo(Tr.empty,Tr.empty,null,0,-1)},apply(t,r,o){return vbe(r,o,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(t,r){let o=r.inputType,a=o=="historyUndo"?jN:o=="historyRedo"?LN:null;return a?(r.preventDefault(),a(t.state,t.dispatch)):!1}}}})}function zN(e,t){return(r,o)=>{let a=ja.getState(r);if(!a||(e?a.undone:a.done).eventCount==0)return!1;if(o){let i=Mbe(a,r,e);i&&o(t?i.scrollIntoView():i)}return!0}}const jN=zN(!1,!0),LN=zN(!0,!0),D3=hn.create({name:"history",addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:e,dispatch:t})=>jN(e,t),redo:()=>({state:e,dispatch:t})=>LN(e,t)}},addProseMirrorPlugins(){return[wbe(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()}}}),Nbe=D3.extend({defaultOptions:{...D3.options,newGroupDelay:150}});var kbe="4.0.0";function xbe(e){return e===void 0}function rr(e){return typeof e=="boolean"}function Cbe(e,t){for(var r in t)t.hasOwnProperty(r)&&xbe(e[r])&&(e[r]=t[r]);return e}function Ebe(e,t,r){var o;return e.length>t&&(r==null?(r="…",o=3):o=r.length,e=e.substring(0,t-o)+r),e}function vt(e,t){for(var r=e.length-1;r>=0;r--)e[r]===t&&e.splice(r,1)}function pa(e,t){for(var r=e.length-1;r>=0;r--)t(e[r])===!0&&e.splice(r,1)}function es(e){throw new Error("Unhandled case for value: '".concat(e,"'"))}var Ai=/[A-Za-z]/,un=/[\d]/,Cr=/\s/,wp=/['"]/,Tbe=/[\x00-\x1F\x7F]/,Dbe=/A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC/.source,Sbe=/\u2700-\u27bf\udde6-\uddff\ud800-\udbff\udc00-\udfff\ufe0e\ufe0f\u0300-\u036f\ufe20-\ufe23\u20d0-\u20f0\ud83c\udffb-\udfff\u200d\u3299\u3297\u303d\u3030\u24c2\ud83c\udd70-\udd71\udd7e-\udd7f\udd8e\udd91-\udd9a\udde6-\uddff\ude01-\ude02\ude1a\ude2f\ude32-\ude3a\ude50-\ude51\u203c\u2049\u25aa-\u25ab\u25b6\u25c0\u25fb-\u25fe\u00a9\u00ae\u2122\u2139\udc04\u2600-\u26FF\u2b05\u2b06\u2b07\u2b1b\u2b1c\u2b50\u2b55\u231a\u231b\u2328\u23cf\u23e9-\u23f3\u23f8-\u23fa\udccf\u2935\u2934\u2190-\u21ff/.source,_be=/\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D4-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D01-\u0D03\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF5\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F/.source,Ibe=Dbe+Sbe+_be,Abe=/0-9\u0660-\u0669\u06F0-\u06F9\u07C0-\u07C9\u0966-\u096F\u09E6-\u09EF\u0A66-\u0A6F\u0AE6-\u0AEF\u0B66-\u0B6F\u0BE6-\u0BEF\u0C66-\u0C6F\u0CE6-\u0CEF\u0D66-\u0D6F\u0DE6-\u0DEF\u0E50-\u0E59\u0ED0-\u0ED9\u0F20-\u0F29\u1040-\u1049\u1090-\u1099\u17E0-\u17E9\u1810-\u1819\u1946-\u194F\u19D0-\u19D9\u1A80-\u1A89\u1A90-\u1A99\u1B50-\u1B59\u1BB0-\u1BB9\u1C40-\u1C49\u1C50-\u1C59\uA620-\uA629\uA8D0-\uA8D9\uA900-\uA909\uA9D0-\uA9D9\uA9F0-\uA9F9\uAA50-\uAA59\uABF0-\uABF9\uFF10-\uFF19/.source,BN=Ibe+Abe,La=new RegExp("[".concat(BN,"]")),VN=function(){function e(t){t===void 0&&(t={}),this.tagName="",this.attrs={},this.innerHTML="",this.tagName=t.tagName||"",this.attrs=t.attrs||{},this.innerHTML=t.innerHtml||t.innerHTML||""}return e.prototype.setTagName=function(t){return this.tagName=t,this},e.prototype.getTagName=function(){return this.tagName||""},e.prototype.setAttr=function(t,r){var o=this.getAttrs();return o[t]=r,this},e.prototype.getAttr=function(t){return this.getAttrs()[t]},e.prototype.setAttrs=function(t){return Object.assign(this.getAttrs(),t),this},e.prototype.getAttrs=function(){return this.attrs||(this.attrs={})},e.prototype.setClass=function(t){return this.setAttr("class",t)},e.prototype.addClass=function(t){for(var r=this.getClass(),o=r?r.split(Cr):[],a=t.split(Cr),i;i=a.shift();)o.indexOf(i)===-1&&o.push(i);return this.getAttrs().class=o.join(" "),this},e.prototype.removeClass=function(t){for(var r=this.getClass(),o=r?r.split(Cr):[],a=t.split(Cr),i;o.length&&(i=a.shift());){var l=o.indexOf(i);l!==-1&&o.splice(l,1)}return this.getAttrs().class=o.join(" "),this},e.prototype.getClass=function(){return this.getAttrs().class||""},e.prototype.hasClass=function(t){return(" "+this.getClass()+" ").indexOf(" "+t+" ")!==-1},e.prototype.setInnerHTML=function(t){return this.innerHTML=t,this},e.prototype.setInnerHtml=function(t){return this.setInnerHTML(t)},e.prototype.getInnerHTML=function(){return this.innerHTML||""},e.prototype.getInnerHtml=function(){return this.getInnerHTML()},e.prototype.toAnchorString=function(){var t=this.getTagName(),r=this.buildAttrsStr();return r=r?" "+r:"",["<",t,r,">",this.getInnerHtml(),"</",t,">"].join("")},e.prototype.buildAttrsStr=function(){if(!this.attrs)return"";var t=this.getAttrs(),r=[];for(var o in t)t.hasOwnProperty(o)&&r.push(o+'="'+t[o]+'"');return r.join(" ")},e}();function Obe(e,t,r){var o,a;r==null?(r="…",a=3,o=8):(a=r.length,o=r.length);var i=function(N){var b={},M=N,k=M.match(/^([a-z]+):\/\//i);return k&&(b.scheme=k[1],M=M.substr(k[0].length)),k=M.match(/^(.*?)(?=(\?|#|\/|$))/i),k&&(b.host=k[1],M=M.substr(k[0].length)),k=M.match(/^\/(.*?)(?=(\?|#|$))/i),k&&(b.path=k[1],M=M.substr(k[0].length)),k=M.match(/^\?(.*?)(?=(#|$))/i),k&&(b.query=k[1],M=M.substr(k[0].length)),k=M.match(/^#(.*?)$/i),k&&(b.fragment=k[1]),b},l=function(N){var b="";return N.scheme&&N.host&&(b+=N.scheme+"://"),N.host&&(b+=N.host),N.path&&(b+="/"+N.path),N.query&&(b+="?"+N.query),N.fragment&&(b+="#"+N.fragment),b},s=function(N,b){var M=b/2,k=Math.ceil(M),w=-1*Math.floor(M),C="";return w<0&&(C=N.substr(w)),N.substr(0,k)+r+C};if(e.length<=t)return e;var c=t-a,u=i(e);if(u.query){var d=u.query.match(/^(.*?)(?=(\?|\#))(.*?)$/i);d&&(u.query=u.query.substr(0,d[1].length),e=l(u))}if(e.length<=t||(u.host&&(u.host=u.host.replace(/^www\./,""),e=l(u)),e.length<=t))return e;var f="";if(u.host&&(f+=u.host),f.length>=c)return u.host.length==t?(u.host.substr(0,t-a)+r).substr(0,c+o):s(f,c).substr(0,c+o);var p="";if(u.path&&(p+="/"+u.path),u.query&&(p+="?"+u.query),p)if((f+p).length>=c){if((f+p).length==t)return(f+p).substr(0,t);var h=c-f.length;return(f+s(p,h)).substr(0,c+o)}else f+=p;if(u.fragment){var m="#"+u.fragment;if((f+m).length>=c){if((f+m).length==t)return(f+m).substr(0,t);var g=c-f.length;return(f+s(m,g)).substr(0,c+o)}else f+=m}if(u.scheme&&u.host){var v=u.scheme+"://";if((f+v).length<c)return(v+f).substr(0,t)}if(f.length<=t)return f;var y="";return c>0&&(y=f.substr(-1*Math.floor(c/2))),(f.substr(0,Math.ceil(c/2))+r+y).substr(0,c+o)}function zbe(e,t,r){if(e.length<=t)return e;var o,a;r==null?(r="…",o=8,a=3):(o=r.length,a=r.length);var i=t-a,l="";return i>0&&(l=e.substr(-1*Math.floor(i/2))),(e.substr(0,Math.ceil(i/2))+r+l).substr(0,i+o)}function jbe(e,t,r){return Ebe(e,t,r)}var Lbe=function(){function e(t){t===void 0&&(t={}),this.newWindow=!1,this.truncate={},this.className="",this.newWindow=t.newWindow||!1,this.truncate=t.truncate||{},this.className=t.className||""}return e.prototype.build=function(t){return new VN({tagName:"a",attrs:this.createAttrs(t),innerHtml:this.processAnchorText(t.getAnchorText())})},e.prototype.createAttrs=function(t){var r={href:t.getAnchorHref()},o=this.createCssClass(t);return o&&(r.class=o),this.newWindow&&(r.target="_blank",r.rel="noopener noreferrer"),this.truncate&&this.truncate.length&&this.truncate.length<t.getAnchorText().length&&(r.title=t.getAnchorHref()),r},e.prototype.createCssClass=function(t){var r=this.className;if(r){for(var o=[r],a=t.getCssClassSuffixes(),i=0,l=a.length;i<l;i++)o.push(r+"-"+a[i]);return o.join(" ")}else return""},e.prototype.processAnchorText=function(t){return t=this.doTruncate(t),t},e.prototype.doTruncate=function(t){var r=this.truncate;if(!r||!r.length)return t;var o=r.length,a=r.location;return a==="smart"?Obe(t,o):a==="middle"?zbe(t,o):jbe(t,o)},e}(),Z0=function(e,t){return Z0=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,o){r.__proto__=o}||function(r,o){for(var a in o)Object.prototype.hasOwnProperty.call(o,a)&&(r[a]=o[a])},Z0(e,t)};function nc(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Z0(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}var Gt=function(){return Gt=Object.assign||function(t){for(var r,o=1,a=arguments.length;o<a;o++){r=arguments[o];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},Gt.apply(this,arguments)};var rc=function(){function e(t){this._=null,this.matchedText="",this.offset=0,this.tagBuilder=t.tagBuilder,this.matchedText=t.matchedText,this.offset=t.offset}return e.prototype.getMatchedText=function(){return this.matchedText},e.prototype.setOffset=function(t){this.offset=t},e.prototype.getOffset=function(){return this.offset},e.prototype.getCssClassSuffixes=function(){return[this.type]},e.prototype.buildTag=function(){return this.tagBuilder.build(this)},e}(),Bbe="(?:xn--vermgensberatung-pwb|xn--vermgensberater-ctb|xn--clchc0ea0b2g2a9gcd|xn--w4r85el8fhu5dnra|northwesternmutual|travelersinsurance|vermögensberatung|xn--5su34j936bgsg|xn--bck1b9a5dre4c|xn--mgbah1a3hjkrd|xn--mgbai9azgqp6j|xn--mgberp4a5d4ar|xn--xkc2dl3a5ee0h|vermögensberater|xn--fzys8d69uvgm|xn--mgba7c0bbn0a|xn--mgbcpq6gpa1a|xn--xkc2al3hye2a|americanexpress|kerryproperties|sandvikcoromant|xn--i1b6b1a6a2e|xn--kcrx77d1x4a|xn--lgbbat1ad8j|xn--mgba3a4f16a|xn--mgbaakc7dvf|xn--mgbc0a9azcg|xn--nqv7fs00ema|americanfamily|bananarepublic|cancerresearch|cookingchannel|kerrylogistics|weatherchannel|xn--54b7fta0cc|xn--6qq986b3xl|xn--80aqecdr1a|xn--b4w605ferd|xn--fiq228c5hs|xn--h2breg3eve|xn--jlq480n2rg|xn--jlq61u9w7b|xn--mgba3a3ejt|xn--mgbaam7a8h|xn--mgbayh7gpa|xn--mgbbh1a71e|xn--mgbca7dzdo|xn--mgbi4ecexp|xn--mgbx4cd0ab|xn--rvc1e0am3e|international|lifeinsurance|travelchannel|wolterskluwer|xn--cckwcxetd|xn--eckvdtc9d|xn--fpcrj9c3d|xn--fzc2c9e2c|xn--h2brj9c8c|xn--tiq49xqyj|xn--yfro4i67o|xn--ygbi2ammx|construction|lplfinancial|scholarships|versicherung|xn--3e0b707e|xn--45br5cyl|xn--4dbrk0ce|xn--80adxhks|xn--80asehdb|xn--8y0a063a|xn--gckr3f0f|xn--mgb9awbf|xn--mgbab2bd|xn--mgbgu82a|xn--mgbpl2fh|xn--mgbt3dhd|xn--mk1bu44c|xn--ngbc5azd|xn--ngbe9e0a|xn--ogbpf8fl|xn--qcka1pmc|accountants|barclaycard|blackfriday|blockbuster|bridgestone|calvinklein|contractors|creditunion|engineering|enterprises|foodnetwork|investments|kerryhotels|lamborghini|motorcycles|olayangroup|photography|playstation|productions|progressive|redumbrella|williamhill|xn--11b4c3d|xn--1ck2e1b|xn--1qqw23a|xn--2scrj9c|xn--3bst00m|xn--3ds443g|xn--3hcrj9c|xn--42c2d9a|xn--45brj9c|xn--55qw42g|xn--6frz82g|xn--80ao21a|xn--9krt00a|xn--cck2b3b|xn--czr694b|xn--d1acj3b|xn--efvy88h|xn--fct429k|xn--fjq720a|xn--flw351e|xn--g2xx48c|xn--gecrj9c|xn--gk3at1e|xn--h2brj9c|xn--hxt814e|xn--imr513n|xn--j6w193g|xn--jvr189m|xn--kprw13d|xn--kpry57d|xn--mgbbh1a|xn--mgbtx2b|xn--mix891f|xn--nyqy26a|xn--otu796d|xn--pgbs0dh|xn--q9jyb4c|xn--rhqv96g|xn--rovu88b|xn--s9brj9c|xn--ses554g|xn--t60b56a|xn--vuq861b|xn--w4rs40l|xn--xhq521b|xn--zfr164b|சிங்கப்பூர்|accountant|apartments|associates|basketball|bnpparibas|boehringer|capitalone|consulting|creditcard|cuisinella|eurovision|extraspace|foundation|healthcare|immobilien|industries|management|mitsubishi|nextdirect|properties|protection|prudential|realestate|republican|restaurant|schaeffler|tatamotors|technology|university|vlaanderen|volkswagen|xn--30rr7y|xn--3pxu8k|xn--45q11c|xn--4gbrim|xn--55qx5d|xn--5tzm5g|xn--80aswg|xn--90a3ac|xn--9dbq2a|xn--9et52u|xn--c2br7g|xn--cg4bki|xn--czrs0t|xn--czru2d|xn--fiq64b|xn--fiqs8s|xn--fiqz9s|xn--io0a7i|xn--kput3i|xn--mxtq1m|xn--o3cw4h|xn--pssy2u|xn--q7ce6a|xn--unup4y|xn--wgbh1c|xn--wgbl6a|xn--y9a3aq|accenture|alfaromeo|allfinanz|amsterdam|analytics|aquarelle|barcelona|bloomberg|christmas|community|directory|education|equipment|fairwinds|financial|firestone|fresenius|frontdoor|furniture|goldpoint|hisamitsu|homedepot|homegoods|homesense|institute|insurance|kuokgroup|lancaster|landrover|lifestyle|marketing|marshalls|melbourne|microsoft|panasonic|passagens|pramerica|richardli|shangrila|solutions|statebank|statefarm|stockholm|travelers|vacations|xn--90ais|xn--c1avg|xn--d1alf|xn--e1a4c|xn--fhbei|xn--j1aef|xn--j1amh|xn--l1acc|xn--ngbrx|xn--nqv7f|xn--p1acf|xn--qxa6a|xn--tckwe|xn--vhquv|yodobashi|موريتانيا|abudhabi|airforce|allstate|attorney|barclays|barefoot|bargains|baseball|boutique|bradesco|broadway|brussels|builders|business|capetown|catering|catholic|cipriani|cityeats|cleaning|clinique|clothing|commbank|computer|delivery|deloitte|democrat|diamonds|discount|discover|download|engineer|ericsson|etisalat|exchange|feedback|fidelity|firmdale|football|frontier|goodyear|grainger|graphics|guardian|hdfcbank|helsinki|holdings|hospital|infiniti|ipiranga|istanbul|jpmorgan|lighting|lundbeck|marriott|maserati|mckinsey|memorial|merckmsd|mortgage|observer|partners|pharmacy|pictures|plumbing|property|redstone|reliance|saarland|samsclub|security|services|shopping|showtime|softbank|software|stcgroup|supplies|training|vanguard|ventures|verisign|woodside|xn--90ae|xn--node|xn--p1ai|xn--qxam|yokohama|السعودية|abogado|academy|agakhan|alibaba|android|athleta|auction|audible|auspost|avianca|banamex|bauhaus|bentley|bestbuy|booking|brother|bugatti|capital|caravan|careers|channel|charity|chintai|citadel|clubmed|college|cologne|comcast|company|compare|contact|cooking|corsica|country|coupons|courses|cricket|cruises|dentist|digital|domains|exposed|express|farmers|fashion|ferrari|ferrero|finance|fishing|fitness|flights|florist|flowers|forsale|frogans|fujitsu|gallery|genting|godaddy|grocery|guitars|hamburg|hangout|hitachi|holiday|hosting|hoteles|hotmail|hyundai|ismaili|jewelry|juniper|kitchen|komatsu|lacaixa|lanxess|lasalle|latrobe|leclerc|limited|lincoln|markets|monster|netbank|netflix|network|neustar|okinawa|oldnavy|organic|origins|philips|pioneer|politie|realtor|recipes|rentals|reviews|rexroth|samsung|sandvik|schmidt|schwarz|science|shiksha|singles|staples|storage|support|surgery|systems|temasek|theater|theatre|tickets|tiffany|toshiba|trading|walmart|wanggou|watches|weather|website|wedding|whoswho|windows|winners|xfinity|yamaxun|youtube|zuerich|католик|اتصالات|البحرين|الجزائر|العليان|پاکستان|كاثوليك|இந்தியா|abarth|abbott|abbvie|africa|agency|airbus|airtel|alipay|alsace|alstom|amazon|anquan|aramco|author|bayern|beauty|berlin|bharti|bostik|boston|broker|camera|career|casino|center|chanel|chrome|church|circle|claims|clinic|coffee|comsec|condos|coupon|credit|cruise|dating|datsun|dealer|degree|dental|design|direct|doctor|dunlop|dupont|durban|emerck|energy|estate|events|expert|family|flickr|futbol|gallup|garden|george|giving|global|google|gratis|health|hermes|hiphop|hockey|hotels|hughes|imamat|insure|intuit|jaguar|joburg|juegos|kaufen|kinder|kindle|kosher|lancia|latino|lawyer|lefrak|living|locker|london|luxury|madrid|maison|makeup|market|mattel|mobile|monash|mormon|moscow|museum|mutual|nagoya|natura|nissan|nissay|norton|nowruz|office|olayan|online|oracle|orange|otsuka|pfizer|photos|physio|pictet|quebec|racing|realty|reisen|repair|report|review|rocher|rogers|ryukyu|safety|sakura|sanofi|school|schule|search|secure|select|shouji|soccer|social|stream|studio|supply|suzuki|swatch|sydney|taipei|taobao|target|tattoo|tennis|tienda|tjmaxx|tkmaxx|toyota|travel|unicom|viajes|viking|villas|virgin|vision|voting|voyage|vuelos|walter|webcam|xihuan|yachts|yandex|zappos|москва|онлайн|ابوظبي|ارامكو|الاردن|المغرب|امارات|فلسطين|مليسيا|भारतम्|இலங்கை|ファッション|actor|adult|aetna|amfam|amica|apple|archi|audio|autos|azure|baidu|beats|bible|bingo|black|boats|bosch|build|canon|cards|chase|cheap|cisco|citic|click|cloud|coach|codes|crown|cymru|dabur|dance|deals|delta|drive|dubai|earth|edeka|email|epson|faith|fedex|final|forex|forum|gallo|games|gifts|gives|glass|globo|gmail|green|gripe|group|gucci|guide|homes|honda|horse|house|hyatt|ikano|irish|jetzt|koeln|kyoto|lamer|lease|legal|lexus|lilly|linde|lipsy|loans|locus|lotte|lotto|macys|mango|media|miami|money|movie|music|nexus|nikon|ninja|nokia|nowtv|omega|osaka|paris|parts|party|phone|photo|pizza|place|poker|praxi|press|prime|promo|quest|radio|rehab|reise|ricoh|rocks|rodeo|rugby|salon|sener|seven|sharp|shell|shoes|skype|sling|smart|smile|solar|space|sport|stada|store|study|style|sucks|swiss|tatar|tires|tirol|tmall|today|tokyo|tools|toray|total|tours|trade|trust|tunes|tushu|ubank|vegas|video|vodka|volvo|wales|watch|weber|weibo|works|world|xerox|yahoo|ישראל|ایران|بازار|بھارت|سودان|سورية|همراه|भारोत|संगठन|বাংলা|భారత్|ഭാരതം|嘉里大酒店|aarp|able|adac|aero|akdn|ally|amex|arab|army|arpa|arte|asda|asia|audi|auto|baby|band|bank|bbva|beer|best|bike|bing|blog|blue|bofa|bond|book|buzz|cafe|call|camp|care|cars|casa|case|cash|cbre|cern|chat|citi|city|club|cool|coop|cyou|data|date|dclk|deal|dell|desi|diet|dish|docs|dvag|erni|fage|fail|fans|farm|fast|fiat|fido|film|fire|fish|flir|food|ford|free|fund|game|gbiz|gent|ggee|gift|gmbh|gold|golf|goog|guge|guru|hair|haus|hdfc|help|here|hgtv|host|hsbc|icbc|ieee|imdb|immo|info|itau|java|jeep|jobs|jprs|kddi|kids|kiwi|kpmg|kred|land|lego|lgbt|lidl|life|like|limo|link|live|loan|loft|love|ltda|luxe|maif|meet|meme|menu|mini|mint|mobi|moda|moto|name|navy|news|next|nico|nike|ollo|open|page|pars|pccw|pics|ping|pink|play|plus|pohl|porn|post|prod|prof|qpon|read|reit|rent|rest|rich|room|rsvp|ruhr|safe|sale|sarl|save|saxo|scot|seat|seek|sexy|shaw|shia|shop|show|silk|sina|site|skin|sncf|sohu|song|sony|spot|star|surf|talk|taxi|team|tech|teva|tiaa|tips|town|toys|tube|vana|visa|viva|vivo|vote|voto|wang|weir|wien|wiki|wine|work|xbox|yoga|zara|zero|zone|дети|сайт|بارت|بيتك|ڀارت|تونس|شبكة|عراق|عمان|موقع|भारत|ভারত|ভাৰত|ਭਾਰਤ|ભારત|ଭାରତ|ಭಾರತ|ලංකා|アマゾン|グーグル|クラウド|ポイント|组织机构|電訊盈科|香格里拉|aaa|abb|abc|aco|ads|aeg|afl|aig|anz|aol|app|art|aws|axa|bar|bbc|bbt|bcg|bcn|bet|bid|bio|biz|bms|bmw|bom|boo|bot|box|buy|bzh|cab|cal|cam|car|cat|cba|cbn|cbs|ceo|cfa|cfd|com|cpa|crs|dad|day|dds|dev|dhl|diy|dnp|dog|dot|dtv|dvr|eat|eco|edu|esq|eus|fan|fit|fly|foo|fox|frl|ftr|fun|fyi|gal|gap|gay|gdn|gea|gle|gmo|gmx|goo|gop|got|gov|hbo|hiv|hkt|hot|how|ibm|ice|icu|ifm|inc|ing|ink|int|ist|itv|jcb|jio|jll|jmp|jnj|jot|joy|kfh|kia|kim|kpn|krd|lat|law|lds|llc|llp|lol|lpl|ltd|man|map|mba|med|men|mil|mit|mlb|mls|mma|moe|moi|mom|mov|msd|mtn|mtr|nab|nba|nec|net|new|nfl|ngo|nhk|now|nra|nrw|ntt|nyc|obi|one|ong|onl|ooo|org|ott|ovh|pay|pet|phd|pid|pin|pnc|pro|pru|pub|pwc|red|ren|ril|rio|rip|run|rwe|sap|sas|sbi|sbs|sca|scb|ses|sew|sex|sfr|ski|sky|soy|spa|srl|stc|tab|tax|tci|tdk|tel|thd|tjx|top|trv|tui|tvs|ubs|uno|uol|ups|vet|vig|vin|vip|wed|win|wme|wow|wtc|wtf|xin|xxx|xyz|you|yun|zip|бел|ком|қаз|мкд|мон|орг|рус|срб|укр|հայ|קום|عرب|قطر|كوم|مصر|कॉम|नेट|คอม|ไทย|ລາວ|ストア|セール|みんな|中文网|亚马逊|天主教|我爱你|新加坡|淡马锡|诺基亚|飞利浦|ac|ad|ae|af|ag|ai|al|am|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cu|cv|cw|cx|cy|cz|de|dj|dk|dm|do|dz|ec|ee|eg|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|sj|sk|sl|sm|sn|so|sr|ss|st|su|sv|sx|sy|sz|tc|td|tf|tg|th|tj|tk|tl|tm|tn|to|tr|tt|tv|tw|tz|ua|ug|uk|us|uy|uz|va|vc|ve|vg|vi|vn|vu|wf|ws|ye|yt|za|zm|zw|ελ|ευ|бг|ею|рф|გე|닷넷|닷컴|삼성|한국|コム|世界|中信|中国|中國|企业|佛山|信息|健康|八卦|公司|公益|台湾|台灣|商城|商店|商标|嘉里|在线|大拿|娱乐|家電|广东|微博|慈善|手机|招聘|政务|政府|新闻|时尚|書籍|机构|游戏|澳門|点看|移动|网址|网店|网站|网络|联通|谷歌|购物|通販|集团|食品|餐厅|香港)",Vbe=new RegExp("^"+Bbe+"$"),$be=/[\/?#]/,Pbe=/[-+&@#/%=~_()|'$*\[\]{}\u2713]/,$N=/[?!:,.;^]/,PN=/https?:\/\//i,Rbe=new RegExp("^"+PN.source,"i"),Fbe=new RegExp($N.source+"$"),Ube=/^(javascript|vbscript):/i,Hbe=/^[A-Za-z][-.+A-Za-z0-9]*:(\/\/)?([^:/]*)/,Ybe=/^(?:\/\/)?([^/#?:]+)/;function Np(e){return Ai.test(e)}function S3(e){return Ai.test(e)||un.test(e)||e==="+"||e==="-"||e==="."}function Oo(e){return La.test(e)}function kp(e){return e==="_"||Oo(e)}function _3(e){return La.test(e)||Pbe.test(e)||$N.test(e)}function xp(e){return $be.test(e)}function RN(e){return Vbe.test(e.toLowerCase())}function Qbe(e){if(Ube.test(e))return!1;var t=e.match(Hbe);if(!t)return!1;var r=!!t[1],o=t[2];return r?!0:!(o.indexOf(".")===-1||!Ai.test(o))}function Wbe(e){var t=e.match(Ybe);if(!t)return!1;var r=t[0],o=r.split(".");if(o.length<2)return!1;var a=o[o.length-1];return!!RN(a)}var qbe=/^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/,Gbe=/[:/?#]/;function Kbe(e){var t=e.split(Gbe,1)[0];return qbe.test(t)}var Jbe=/^(https?:\/\/)?(www\.)?/i,Zbe=/^\/\//,Xbe=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="url",o.url="",o.urlMatchType="scheme",o.protocolRelativeMatch=!1,o.stripPrefix={scheme:!0,www:!0},o.stripTrailingSlash=!0,o.decodePercentEncoding=!0,o.protocolPrepended=!1,o.urlMatchType=r.urlMatchType,o.url=r.url,o.protocolRelativeMatch=r.protocolRelativeMatch,o.stripPrefix=r.stripPrefix,o.stripTrailingSlash=r.stripTrailingSlash,o.decodePercentEncoding=r.decodePercentEncoding,o}return t.prototype.getType=function(){return"url"},t.prototype.getUrlMatchType=function(){return this.urlMatchType},t.prototype.getUrl=function(){var r=this.url;return!this.protocolRelativeMatch&&this.urlMatchType!=="scheme"&&!this.protocolPrepended&&(r=this.url="http://"+r,this.protocolPrepended=!0),r},t.prototype.getAnchorHref=function(){var r=this.getUrl();return r.replace(/&/g,"&")},t.prototype.getAnchorText=function(){var r=this.getMatchedText();return this.protocolRelativeMatch&&(r=n8e(r)),this.stripPrefix.scheme&&(r=e8e(r)),this.stripPrefix.www&&(r=t8e(r)),this.stripTrailingSlash&&(r=r8e(r)),this.decodePercentEncoding&&(r=o8e(r)),r},t}(rc);function e8e(e){return e.replace(Rbe,"")}function t8e(e){return e.replace(Jbe,"$1")}function n8e(e){return e.replace(Zbe,"")}function r8e(e){return e.charAt(e.length-1)==="/"&&(e=e.slice(0,-1)),e}function o8e(e){var t=e.replace(/%22/gi,""").replace(/%26/gi,"&").replace(/%27/gi,"'").replace(/%3C/gi,"<").replace(/%3E/gi,">");try{return decodeURIComponent(t)}catch{return t}}var a8e=/^mailto:/i,i8e=new RegExp("[".concat(BN,"!#$%&'*+/=?^_`{|}~-]"));function l8e(e){return La.test(e)}function Cp(e){return i8e.test(e)}function s8e(e){var t=e.split(".").pop()||"";return RN(t)}var c8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="email",o.email="",o.email=r.email,o}return t.prototype.getType=function(){return"email"},t.prototype.getEmail=function(){return this.email},t.prototype.getAnchorHref=function(){return"mailto:"+this.email},t.prototype.getAnchorText=function(){return this.email},t}(rc);function I3(e){return e==="_"||La.test(e)}function u8e(e){return e.length<=140}var d8e=["twitter","facebook","instagram","tiktok"],f8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="hashtag",o.serviceName="twitter",o.hashtag="",o.serviceName=r.serviceName,o.hashtag=r.hashtag,o}return t.prototype.getType=function(){return"hashtag"},t.prototype.getServiceName=function(){return this.serviceName},t.prototype.getHashtag=function(){return this.hashtag},t.prototype.getAnchorHref=function(){var r=this.serviceName,o=this.hashtag;switch(r){case"twitter":return"https://twitter.com/hashtag/"+o;case"facebook":return"https://www.facebook.com/hashtag/"+o;case"instagram":return"https://instagram.com/explore/tags/"+o;case"tiktok":return"https://www.tiktok.com/tag/"+o;default:throw es(r),new Error("Invalid hashtag service: ".concat(r))}},t.prototype.getAnchorText=function(){return"#"+this.hashtag},t.prototype.getCssClassSuffixes=function(){var r=e.prototype.getCssClassSuffixes.call(this),o=this.getServiceName();return o&&r.push(o),r},t}(rc),p8e={twitter:/^@\w{1,15}$/,instagram:/^@[_\w]{1,30}$/,soundcloud:/^@[-a-z0-9_]{3,25}$/,tiktok:/^@[.\w]{1,23}[\w]$/},m8e=/[-\w.]/;function A3(e){return m8e.test(e)}function h8e(e,t){var r=p8e[t];return r.test(e)}var g8e=["twitter","instagram","soundcloud","tiktok"],v8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="mention",o.serviceName="twitter",o.mention="",o.mention=r.mention,o.serviceName=r.serviceName,o}return t.prototype.getType=function(){return"mention"},t.prototype.getMention=function(){return this.mention},t.prototype.getServiceName=function(){return this.serviceName},t.prototype.getAnchorHref=function(){switch(this.serviceName){case"twitter":return"https://twitter.com/"+this.mention;case"instagram":return"https://instagram.com/"+this.mention;case"soundcloud":return"https://soundcloud.com/"+this.mention;case"tiktok":return"https://www.tiktok.com/@"+this.mention;default:throw new Error("Unknown service name to point mention to: "+this.serviceName)}},t.prototype.getAnchorText=function(){return"@"+this.mention},t.prototype.getCssClassSuffixes=function(){var r=e.prototype.getCssClassSuffixes.call(this),o=this.getServiceName();return o&&r.push(o),r},t}(rc),y8e=/[-. ]/,M8e=/[-. ()]/,b8e=/[,;]/,w8e=/(?:(?:(?:(\+)?\d{1,3}[-. ]?)?\(?\d{3}\)?[-. ]?\d{3}[-. ]?\d{4})|(?:(\+)(?:9[976]\d|8[987530]\d|6[987]\d|5[90]\d|42\d|3[875]\d|2[98654321]\d|9[8543210]|8[6421]|6[6543210]|5[87654321]|4[987654310]|3[9643210]|2[70]|7|1)[-. ]?(?:\d[-. ]?){6,12}\d+))([,;]+[0-9]+#?)*/,N8e=/(0([1-9]-?[1-9]\d{3}|[1-9]{2}-?\d{3}|[1-9]{2}\d{1}-?\d{2}|[1-9]{2}\d{2}-?\d{1})-?\d{4}|0[789]0-?\d{4}-?\d{4}|050-?\d{4}-?\d{4})/,k8e=new RegExp("^".concat(w8e.source,"|").concat(N8e.source,"$"));function O3(e){return y8e.test(e)}function Ep(e){return b8e.test(e)}function x8e(e){var t=e.charAt(0)==="+"||M8e.test(e);return t&&k8e.test(e)}var C8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="phone",o.number="",o.plusSign=!1,o.number=r.number,o.plusSign=r.plusSign,o}return t.prototype.getType=function(){return"phone"},t.prototype.getPhoneNumber=function(){return this.number},t.prototype.getNumber=function(){return this.getPhoneNumber()},t.prototype.getAnchorHref=function(){return"tel:"+(this.plusSign?"+":"")+this.number},t.prototype.getAnchorText=function(){return this.matchedText},t}(rc);function E8e(e,t){for(var r=t.tagBuilder,o=t.stripPrefix,a=t.stripTrailingSlash,i=t.decodePercentEncoding,l=t.hashtagServiceName,s=t.mentionServiceName,c=[],u=e.length,d=[],f=0;f<u;f++){var p=e.charAt(f);if(d.length===0)v(p);else for(var h=d.length-1;h>=0;h--){var m=d[h];switch(m.state){case 11:w(m,p);break;case 12:C(m,p);break;case 0:y(m,p);break;case 1:N(m,p);break;case 2:b(m,p);break;case 3:M(m,p);break;case 4:k(m,p);break;case 5:E(m,p);break;case 6:A(m,p);break;case 7:O(m,p);break;case 13:_(m,p);break;case 14:j(m,p);break;case 8:R(m,p);break;case 9:P(m,p);break;case 10:$(m,p);break;case 15:V(m,p);break;case 16:D(m,p);break;case 17:x(m,p);break;case 18:S(m,p);break;case 19:L(m,p);break;case 20:B(m,p);break;case 21:F(m,p);break;case 22:T(m,p);break;case 23:z(m,p);break;case 24:I(m,p);break;case 25:Z(m,p);break;case 26:q(m,p);break;case 27:te(m,p);break;case 28:J(m,p);break;case 29:W(m,p);break;case 30:ae(m,p);break;case 31:ce(m,p);break;case 32:Ae(m,p);break;case 33:Fe(m,p);break;case 34:_e(m,p);break;case 35:Le(m,p);break;case 36:Ye(m,p);break;case 37:ye(m,p);break;case 38:Ke(m,p);break;case 39:Be(m,p);break;case 40:et(m,p);break;case 41:lt(m,p);break;default:es(m.state)}}}for(var g=d.length-1;g>=0;g--)d.forEach(function(H){return je(H)});return c;function v(H){if(H==="#")d.push(I8e(f,28));else if(H==="@")d.push(A8e(f,30));else if(H==="/")d.push(Dp(f,11));else if(H==="+")d.push(Sp(f,37));else if(H==="(")d.push(Sp(f,32));else{if(un.test(H)&&(d.push(Sp(f,38)),d.push(S8e(f,13))),l8e(H)){var G=H.toLowerCase()==="m"?15:22;d.push(_8e(f,G))}Np(H)&&d.push(Tp(f,0)),La.test(H)&&d.push(Dp(f,5))}}function y(H,G){G===":"?H.state=2:G==="-"?H.state=1:S3(G)||vt(d,H)}function N(H,G){G==="-"||(G==="/"?(vt(d,H),d.push(Dp(f,11))):S3(G)?H.state=0:vt(d,H))}function b(H,G){G==="/"?H.state=3:G==="."?vt(d,H):Oo(G)?(H.state=5,Np(G)&&d.push(Tp(f,0))):vt(d,H)}function M(H,G){G==="/"?H.state=4:_3(G)?(H.state=10,H.acceptStateReached=!0):je(H)}function k(H,G){G==="/"?H.state=10:Oo(G)?(H.state=5,H.acceptStateReached=!0):vt(d,H)}function w(H,G){G==="/"?H.state=12:vt(d,H)}function C(H,G){Oo(G)?H.state=5:vt(d,H)}function E(H,G){G==="."?H.state=7:G==="-"?H.state=6:G===":"?H.state=8:xp(G)?H.state=10:kp(G)||je(H)}function A(H,G){G==="-"||(G==="."?je(H):Oo(G)?H.state=5:je(H))}function O(H,G){G==="."?je(H):Oo(G)?(H.state=5,H.acceptStateReached=!0):je(H)}function _(H,G){G==="."?H.state=14:G===":"?H.state=8:un.test(G)||(xp(G)?H.state=10:La.test(G)?vt(d,H):je(H))}function j(H,G){un.test(G)?(H.octetsEncountered++,H.octetsEncountered===4&&(H.acceptStateReached=!0),H.state=13):je(H)}function R(H,G){un.test(G)?H.state=9:je(H)}function P(H,G){un.test(G)||(xp(G)?H.state=10:je(H))}function $(H,G){_3(G)||je(H)}function V(H,G){G.toLowerCase()==="a"?H.state=16:T(H,G)}function D(H,G){G.toLowerCase()==="i"?H.state=17:T(H,G)}function x(H,G){G.toLowerCase()==="l"?H.state=18:T(H,G)}function S(H,G){G.toLowerCase()==="t"?H.state=19:T(H,G)}function L(H,G){G.toLowerCase()==="o"?H.state=20:T(H,G)}function B(H,G){G.toLowerCase()===":"?H.state=21:T(H,G)}function F(H,G){Cp(G)?H.state=22:vt(d,H)}function T(H,G){G==="."?H.state=23:G==="@"?H.state=24:Cp(G)?H.state=22:vt(d,H)}function z(H,G){G==="."||G==="@"?vt(d,H):Cp(G)?H.state=22:vt(d,H)}function I(H,G){Oo(G)?H.state=25:vt(d,H)}function Z(H,G){G==="."?H.state=27:G==="-"?H.state=26:kp(G)||je(H)}function q(H,G){G==="-"||G==="."?je(H):kp(G)?H.state=25:je(H)}function te(H,G){G==="."||G==="-"?je(H):Oo(G)?(H.state=25,H.acceptStateReached=!0):je(H)}function J(H,G){I3(G)?(H.state=29,H.acceptStateReached=!0):vt(d,H)}function W(H,G){I3(G)||je(H)}function ae(H,G){A3(G)?(H.state=31,H.acceptStateReached=!0):vt(d,H)}function ce(H,G){A3(G)||(La.test(G)?vt(d,H):je(H))}function ye(H,G){un.test(G)?H.state=38:(vt(d,H),v(G))}function Ae(H,G){un.test(G)?H.state=33:vt(d,H),v(G)}function Fe(H,G){un.test(G)?H.state=34:vt(d,H)}function _e(H,G){un.test(G)?H.state=35:vt(d,H)}function Le(H,G){G===")"?H.state=36:vt(d,H)}function Ye(H,G){un.test(G)?H.state=38:O3(G)?H.state=39:vt(d,H)}function Ke(H,G){H.acceptStateReached=!0,Ep(G)?H.state=40:G==="#"?H.state=41:un.test(G)||(G==="("?H.state=32:O3(G)?H.state=39:(je(H),Np(G)&&d.push(Tp(f,0))))}function Be(H,G){un.test(G)?H.state=38:G==="("?H.state=32:(je(H),v(G))}function et(H,G){Ep(G)||(G==="#"?H.state=41:un.test(G)?H.state=38:je(H))}function lt(H,G){Ep(G)?H.state=40:un.test(G)?vt(d,H):je(H)}function je(H){if(vt(d,H),!!H.acceptStateReached){var G=H.startIdx,ze=e.slice(H.startIdx,f);if(ze=D8e(ze),H.type==="url"){var pe=e.charAt(H.startIdx-1);if(pe==="@")return;var we=H.matchType;if(we==="scheme"){var be=PN.exec(ze);if(be&&(G=G+be.index,ze=ze.slice(be.index)),!Qbe(ze))return}else if(we==="tld"){if(!Wbe(ze))return}else if(we==="ipV4"){if(!Kbe(ze))return}else es(we);c.push(new Xbe({tagBuilder:r,matchedText:ze,offset:G,urlMatchType:we,url:ze,protocolRelativeMatch:ze.slice(0,2)==="//",stripPrefix:o,stripTrailingSlash:a,decodePercentEncoding:i}))}else if(H.type==="email")s8e(ze)&&c.push(new c8e({tagBuilder:r,matchedText:ze,offset:G,email:ze.replace(a8e,"")}));else if(H.type==="hashtag")u8e(ze)&&c.push(new f8e({tagBuilder:r,matchedText:ze,offset:G,serviceName:l,hashtag:ze.slice(1)}));else if(H.type==="mention")h8e(ze,s)&&c.push(new v8e({tagBuilder:r,matchedText:ze,offset:G,serviceName:s,mention:ze.slice(1)}));else if(H.type==="phone"){if(ze=ze.replace(/ +$/g,""),x8e(ze)){var ct=ze.replace(/[^0-9,;#]/g,"");c.push(new C8e({tagBuilder:r,matchedText:ze,offset:G,number:ct,plusSign:ze.charAt(0)==="+"}))}}else es(H)}}}var T8e=/[\(\{\[]/,z3=/[\)\}\]]/,j3={")":"(","}":"{","]":"["};function D8e(e){for(var t={"(":0,"{":0,"[":0},r=0;r<e.length;r++){var o=e.charAt(r);T8e.test(o)?t[o]++:z3.test(o)&&t[j3[o]]--}for(var a=e.length-1,i;a>=0;)if(i=e.charAt(a),z3.test(i)){var l=j3[i];if(t[l]<0)t[l]++,a--;else break}else if(Fbe.test(i))a--;else break;return e.slice(0,a+1)}function Tp(e,t){return{type:"url",startIdx:e,state:t,acceptStateReached:!1,matchType:"scheme"}}function Dp(e,t){return{type:"url",startIdx:e,state:t,acceptStateReached:!1,matchType:"tld"}}function S8e(e,t){return{type:"url",startIdx:e,state:t,acceptStateReached:!1,matchType:"ipV4",octetsEncountered:1}}function _8e(e,t){return{type:"email",startIdx:e,state:t,acceptStateReached:!1}}function I8e(e,t){return{type:"hashtag",startIdx:e,state:t,acceptStateReached:!1}}function A8e(e,t){return{type:"mention",startIdx:e,state:t,acceptStateReached:!1}}function Sp(e,t){return{type:"phone",startIdx:e,state:t,acceptStateReached:!1}}function O8e(e,t){for(var r=t.onOpenTag,o=t.onCloseTag,a=t.onText,i=t.onComment,l=t.onDoctype,s=new Fr,c=0,u=e.length,d=0,f=0,p=s;c<u;){var h=e.charAt(c);switch(d){case 0:m(h);break;case 1:g(h);break;case 2:y(h);break;case 3:v(h);break;case 4:N(h);break;case 5:b(h);break;case 6:M(h);break;case 7:k(h);break;case 8:w(h);break;case 9:C(h);break;case 10:E(h);break;case 11:A(h);break;case 12:O(h);break;case 13:_();break;case 14:j(h);break;case 15:R(h);break;case 16:P(h);break;case 17:$(h);break;case 18:V(h);break;case 19:D(h);break;case 20:x(h);break;default:es(d)}c++}f<c&&F();function m(I){I==="<"&&L()}function g(I){I==="!"?d=13:I==="/"?(d=2,p=new Fr(Gt(Gt({},p),{isClosing:!0}))):I==="<"?L():Ai.test(I)?(d=3,p=new Fr(Gt(Gt({},p),{isOpening:!0}))):(d=0,p=s)}function v(I){Cr.test(I)?(p=new Fr(Gt(Gt({},p),{name:T()})),d=4):I==="<"?L():I==="/"?(p=new Fr(Gt(Gt({},p),{name:T()})),d=12):I===">"?(p=new Fr(Gt(Gt({},p),{name:T()})),B()):!Ai.test(I)&&!un.test(I)&&I!==":"&&S()}function y(I){I===">"?S():Ai.test(I)?d=3:S()}function N(I){Cr.test(I)||(I==="/"?d=12:I===">"?B():I==="<"?L():I==="="||wp.test(I)||Tbe.test(I)?S():d=5)}function b(I){Cr.test(I)?d=6:I==="/"?d=12:I==="="?d=7:I===">"?B():I==="<"?L():wp.test(I)&&S()}function M(I){Cr.test(I)||(I==="/"?d=12:I==="="?d=7:I===">"?B():I==="<"?L():wp.test(I)?S():d=5)}function k(I){Cr.test(I)||(I==='"'?d=8:I==="'"?d=9:/[>=`]/.test(I)?S():I==="<"?L():d=10)}function w(I){I==='"'&&(d=11)}function C(I){I==="'"&&(d=11)}function E(I){Cr.test(I)?d=4:I===">"?B():I==="<"&&L()}function A(I){Cr.test(I)?d=4:I==="/"?d=12:I===">"?B():I==="<"?L():(d=4,z())}function O(I){I===">"?(p=new Fr(Gt(Gt({},p),{isClosing:!0})),B()):d=4}function _(I){e.substr(c,2)==="--"?(c+=2,p=new Fr(Gt(Gt({},p),{type:"comment"})),d=14):e.substr(c,7).toUpperCase()==="DOCTYPE"?(c+=7,p=new Fr(Gt(Gt({},p),{type:"doctype"})),d=20):S()}function j(I){I==="-"?d=15:I===">"?S():d=16}function R(I){I==="-"?d=18:I===">"?S():d=16}function P(I){I==="-"&&(d=17)}function $(I){I==="-"?d=18:d=16}function V(I){I===">"?B():I==="!"?d=19:I==="-"||(d=16)}function D(I){I==="-"?d=17:I===">"?B():d=16}function x(I){I===">"?B():I==="<"&&L()}function S(){d=0,p=s}function L(){d=1,p=new Fr({idx:c})}function B(){var I=e.slice(f,p.idx);I&&a(I,f),p.type==="comment"?i(p.idx):p.type==="doctype"?l(p.idx):(p.isOpening&&r(p.name,p.idx),p.isClosing&&o(p.name,p.idx)),S(),f=c+1}function F(){var I=e.slice(f,c);a(I,f),f=c+1}function T(){var I=p.idx+(p.isClosing?2:1);return e.slice(I,c).toLowerCase()}function z(){c--}}var Fr=function(){function e(t){t===void 0&&(t={}),this.idx=t.idx!==void 0?t.idx:-1,this.type=t.type||"tag",this.name=t.name||"",this.isOpening=!!t.isOpening,this.isClosing=!!t.isClosing}return e}(),X0=function(){function e(t){t===void 0&&(t={}),this.version=e.version,this.urls={},this.email=!0,this.phone=!0,this.hashtag=!1,this.mention=!1,this.newWindow=!0,this.stripPrefix={scheme:!0,www:!0},this.stripTrailingSlash=!0,this.decodePercentEncoding=!0,this.truncate={length:0,location:"end"},this.className="",this.replaceFn=null,this.context=void 0,this.sanitizeHtml=!1,this.tagBuilder=null,this.urls=z8e(t.urls),this.email=rr(t.email)?t.email:this.email,this.phone=rr(t.phone)?t.phone:this.phone,this.hashtag=t.hashtag||this.hashtag,this.mention=t.mention||this.mention,this.newWindow=rr(t.newWindow)?t.newWindow:this.newWindow,this.stripPrefix=j8e(t.stripPrefix),this.stripTrailingSlash=rr(t.stripTrailingSlash)?t.stripTrailingSlash:this.stripTrailingSlash,this.decodePercentEncoding=rr(t.decodePercentEncoding)?t.decodePercentEncoding:this.decodePercentEncoding,this.sanitizeHtml=t.sanitizeHtml||!1;var r=this.mention;if(r!==!1&&g8e.indexOf(r)===-1)throw new Error("invalid `mention` cfg '".concat(r,"' - see docs"));var o=this.hashtag;if(o!==!1&&d8e.indexOf(o)===-1)throw new Error("invalid `hashtag` cfg '".concat(o,"' - see docs"));this.truncate=L8e(t.truncate),this.className=t.className||this.className,this.replaceFn=t.replaceFn||this.replaceFn,this.context=t.context||this}return e.link=function(t,r){var o=new e(r);return o.link(t)},e.parse=function(t,r){var o=new e(r);return o.parse(t)},e.prototype.parse=function(t){var r=this,o=["a","style","script"],a=0,i=[];return O8e(t,{onOpenTag:function(l){o.indexOf(l)>=0&&a++},onText:function(l,s){if(a===0){var c=/( | |<|<|>|>|"|"|')/gi,u=l.split(c),d=s;u.forEach(function(f,p){if(p%2===0){var h=r.parseText(f,d);i.push.apply(i,h)}d+=f.length})}},onCloseTag:function(l){o.indexOf(l)>=0&&(a=Math.max(a-1,0))},onComment:function(l){},onDoctype:function(l){}}),i=this.compactMatches(i),i=this.removeUnwantedMatches(i),i},e.prototype.compactMatches=function(t){t.sort(function(c,u){return c.getOffset()-u.getOffset()});for(var r=0;r<t.length-1;){var o=t[r],a=o.getOffset(),i=o.getMatchedText().length,l=a+i;if(r+1<t.length){if(t[r+1].getOffset()===a){var s=t[r+1].getMatchedText().length>i?r:r+1;t.splice(s,1);continue}if(t[r+1].getOffset()<l){t.splice(r+1,1);continue}}r++}return t},e.prototype.removeUnwantedMatches=function(t){return this.hashtag||pa(t,function(r){return r.getType()==="hashtag"}),this.email||pa(t,function(r){return r.getType()==="email"}),this.phone||pa(t,function(r){return r.getType()==="phone"}),this.mention||pa(t,function(r){return r.getType()==="mention"}),this.urls.schemeMatches||pa(t,function(r){return r.getType()==="url"&&r.getUrlMatchType()==="scheme"}),this.urls.tldMatches||pa(t,function(r){return r.getType()==="url"&&r.getUrlMatchType()==="tld"}),this.urls.ipV4Matches||pa(t,function(r){return r.getType()==="url"&&r.getUrlMatchType()==="ipV4"}),t},e.prototype.parseText=function(t,r){r===void 0&&(r=0),r=r||0;for(var o=E8e(t,{tagBuilder:this.getTagBuilder(),stripPrefix:this.stripPrefix,stripTrailingSlash:this.stripTrailingSlash,decodePercentEncoding:this.decodePercentEncoding,hashtagServiceName:this.hashtag,mentionServiceName:this.mention||"twitter"}),a=0,i=o.length;a<i;a++)o[a].setOffset(r+o[a].getOffset());return o},e.prototype.link=function(t){if(!t)return"";this.sanitizeHtml&&(t=t.replace(/</g,"<").replace(/>/g,">"));for(var r=this.parse(t),o=[],a=0,i=0,l=r.length;i<l;i++){var s=r[i];o.push(t.substring(a,s.getOffset())),o.push(this.createMatchReturnVal(s)),a=s.getOffset()+s.getMatchedText().length}return o.push(t.substring(a)),o.join("")},e.prototype.createMatchReturnVal=function(t){var r;if(this.replaceFn&&(r=this.replaceFn.call(this.context,t)),typeof r=="string")return r;if(r===!1)return t.getMatchedText();if(r instanceof VN)return r.toAnchorString();var o=t.buildTag();return o.toAnchorString()},e.prototype.getTagBuilder=function(){var t=this.tagBuilder;return t||(t=this.tagBuilder=new Lbe({newWindow:this.newWindow,truncate:this.truncate,className:this.className})),t},e.version=kbe,e}();function z8e(e){return e==null&&(e=!0),rr(e)?{schemeMatches:e,tldMatches:e,ipV4Matches:e}:{schemeMatches:rr(e.schemeMatches)?e.schemeMatches:!0,tldMatches:rr(e.tldMatches)?e.tldMatches:!0,ipV4Matches:rr(e.ipV4Matches)?e.ipV4Matches:!0}}function j8e(e){return e==null&&(e=!0),rr(e)?{scheme:e,www:e}:{scheme:rr(e.scheme)?e.scheme:!0,www:rr(e.www)?e.www:!0}}function L8e(e){return typeof e=="number"?{length:e,location:"end"}:Cbe(e||{},{length:Number.POSITIVE_INFINITY,location:"end"})}function B8e(e){return e.startsWith("http://")||e.startsWith("https://")?e:"https://"+e}const V8e={props:{previousURL:String,lang:{type:String,default(){return pn()}}},data(){return{linkToAppend:this.previousURL,linkError:""}},methods:{insertLink(){this.isLinkValid(this.linkToAppend)?(this.linkError=!1,this.$emit("setLink",{url:B8e(this.linkToAppend),insertedText:this.linkToAppend}),this.$emit("close")):this.linkError=!0},isLinkValid(e){return X0.link(e,{email:!1}).includes("href")}},computed:{disableButton(){return this.linkToAppend===""||this.linkToAppend===void 0},hasError(){return!!this.linkError}}},$8e={class:"wrapper-input mb-3"},P8e={key:0,class:"l-input-error-message"},R8e={class:"wrapper-buttons row l-justify-content-end"};function F8e(e,t,r,o,a,i){const l=n.resolveComponent("l-input"),s=n.resolveComponent("l-button"),c=n.resolveComponent("l-box");return n.openBlock(),n.createBlock(c,{class:"link-box column"},{default:n.withCtx(()=>[n.createElementVNode("div",$8e,[n.createVNode(l,{modelValue:a.linkToAppend,"onUpdate:modelValue":t[0]||(t[0]=u=>a.linkToAppend=u),placeholder:e.$tds("insert-link",r.lang),error:i.hasError,autofocus:"",style:{"box-sizing":"border-box"}},null,8,["modelValue","placeholder","error"]),a.linkError?(n.openBlock(),n.createElementBlock("div",P8e,n.toDisplayString(e.$tds("insert-valid-link",r.lang)),1)):n.createCommentVNode("",!0)]),n.createElementVNode("div",R8e,[n.createVNode(s,{size:"small",onClick:t[1]||(t[1]=u=>e.$emit("close"))},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("cancel",r.lang)),1)]),_:1}),n.createVNode(s,{size:"small",type:"primary",onClick:t[2]||(t[2]=u=>i.insertLink()),disabled:i.disableButton},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("insert",r.lang)),1)]),_:1},8,["disabled"])])]),_:1})}const U8e=xe(V8e,[["render",F8e],["__scopeId","data-v-e59381b7"]]);const H8e={props:{dataLink:String,lang:{type:String,default(){return pn()}}},data(){return{tooltipDelay:125}},methods:{actionButtonBased(e){this.$emit(e)}},computed:{tooltipLink(){return this.dataLink.length>=60?this.dataLink.slice(0,60)+"...":this.dataLink},boxButtons(){return[{tooltip:this.$tds("edit-link",this.lang),icon:"uil-edit",event:"edit"},{tooltip:this.$tds("remove-link",this.lang),icon:"uil-link-broken",event:"remove"}]}}},Y8e={class:"wrapper-floating-link l-ra-1 px-2 py-2 row l-align-items-center l-align-content-center"},Q8e=["href","open-delay"];function W8e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-tooltip");return n.openBlock(),n.createElementBlock("div",Y8e,[n.createVNode(l,{size:"24",class:"color-lead-light mr-2",icon:"uil-globe"}),n.createVNode(s,{class:"item color-link",content:i.tooltipLink},{default:n.withCtx(()=>[n.createElementVNode("a",{class:"l-flex-grow-1 h6 color-link l-ellipsis",target:"_blank",rel:"nofollow noopener noreferrer",style:{display:"inline"},href:r.dataLink,"open-delay":a.tooltipDelay},n.toDisplayString(r.dataLink),9,Q8e)]),_:1},8,["content"]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.boxButtons,(c,u)=>(n.openBlock(),n.createBlock(s,{class:"item",key:u,content:c.tooltip,"open-delay":a.tooltipDelay},{default:n.withCtx(()=>[n.createVNode(l,{size:"20",class:"color-lead-light ml-2",icon:c.icon,onClick:d=>i.actionButtonBased(c.event)},null,8,["icon","onClick"])]),_:2},1032,["content","open-delay"]))),128))])}const q8e=xe(H8e,[["render",W8e],["__scopeId","data-v-b523904a"]]),G8e=/<(\w+).[^>]*>\s*<\/\1>/g;function K8e(e){return e.replace(G8e,"")}/*! @license DOMPurify 2.4.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.4.7/LICENSE */function Fo(e){"@babel/helpers - typeof";return Fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fo(e)}function em(e,t){return em=Object.setPrototypeOf||function(o,a){return o.__proto__=a,o},em(e,t)}function J8e(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function eu(e,t,r){return J8e()?eu=Reflect.construct:eu=function(a,i,l){var s=[null];s.push.apply(s,i);var c=Function.bind.apply(a,s),u=new c;return l&&em(u,l.prototype),u},eu.apply(null,arguments)}function kr(e){return Z8e(e)||X8e(e)||ewe(e)||twe()}function Z8e(e){if(Array.isArray(e))return tm(e)}function X8e(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function ewe(e,t){if(e){if(typeof e=="string")return tm(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return tm(e,t)}}function tm(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,o=new Array(t);r<t;r++)o[r]=e[r];return o}function twe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
161
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var nwe=Object.hasOwnProperty,L3=Object.setPrototypeOf,rwe=Object.isFrozen,owe=Object.getPrototypeOf,awe=Object.getOwnPropertyDescriptor,kn=Object.freeze,zr=Object.seal,iwe=Object.create,FN=typeof Reflect<"u"&&Reflect,wd=FN.apply,nm=FN.construct;wd||(wd=function(t,r,o){return t.apply(r,o)});kn||(kn=function(t){return t});zr||(zr=function(t){return t});nm||(nm=function(t,r){return eu(t,kr(r))});var lwe=gr(Array.prototype.forEach),B3=gr(Array.prototype.pop),Dl=gr(Array.prototype.push),tu=gr(String.prototype.toLowerCase),_p=gr(String.prototype.toString),swe=gr(String.prototype.match),wr=gr(String.prototype.replace),cwe=gr(String.prototype.indexOf),uwe=gr(String.prototype.trim),Mn=gr(RegExp.prototype.test),Ip=dwe(TypeError);function gr(e){return function(t){for(var r=arguments.length,o=new Array(r>1?r-1:0),a=1;a<r;a++)o[a-1]=arguments[a];return wd(e,t,o)}}function dwe(e){return function(){for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return nm(e,r)}}function qe(e,t,r){var o;r=(o=r)!==null&&o!==void 0?o:tu,L3&&L3(e,null);for(var a=t.length;a--;){var i=t[a];if(typeof i=="string"){var l=r(i);l!==i&&(rwe(t)||(t[a]=l),i=l)}e[i]=!0}return e}function ma(e){var t=iwe(null),r;for(r in e)wd(nwe,e,[r])===!0&&(t[r]=e[r]);return t}function jc(e,t){for(;e!==null;){var r=awe(e,t);if(r){if(r.get)return gr(r.get);if(typeof r.value=="function")return gr(r.value)}e=owe(e)}function o(a){return console.warn("fallback value for",a),null}return o}var V3=kn(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Ap=kn(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Op=kn(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),fwe=kn(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),zp=kn(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),pwe=kn(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),$3=kn(["#text"]),P3=kn(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),jp=kn(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),R3=kn(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Lc=kn(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),mwe=zr(/\{\{[\w\W]*|[\w\W]*\}\}/gm),hwe=zr(/<%[\w\W]*|[\w\W]*%>/gm),gwe=zr(/\${[\w\W]*}/gm),vwe=zr(/^data-[\-\w.\u00B7-\uFFFF]/),ywe=zr(/^aria-[\-\w]+$/),Mwe=zr(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),bwe=zr(/^(?:\w+script|data):/i),wwe=zr(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Nwe=zr(/^html$/i),kwe=function(){return typeof window>"u"?null:window},xwe=function(t,r){if(Fo(t)!=="object"||typeof t.createPolicy!="function")return null;var o=null,a="data-tt-policy-suffix";r.currentScript&&r.currentScript.hasAttribute(a)&&(o=r.currentScript.getAttribute(a));var i="dompurify"+(o?"#"+o:"");try{return t.createPolicy(i,{createHTML:function(s){return s},createScriptURL:function(s){return s}})}catch{return console.warn("TrustedTypes policy "+i+" could not be created."),null}};function UN(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:kwe(),t=function(U){return UN(U)};if(t.version="2.4.7",t.removed=[],!e||!e.document||e.document.nodeType!==9)return t.isSupported=!1,t;var r=e.document,o=e.document,a=e.DocumentFragment,i=e.HTMLTemplateElement,l=e.Node,s=e.Element,c=e.NodeFilter,u=e.NamedNodeMap,d=u===void 0?e.NamedNodeMap||e.MozNamedAttrMap:u,f=e.HTMLFormElement,p=e.DOMParser,h=e.trustedTypes,m=s.prototype,g=jc(m,"cloneNode"),v=jc(m,"nextSibling"),y=jc(m,"childNodes"),N=jc(m,"parentNode");if(typeof i=="function"){var b=o.createElement("template");b.content&&b.content.ownerDocument&&(o=b.content.ownerDocument)}var M=xwe(h,r),k=M?M.createHTML(""):"",w=o,C=w.implementation,E=w.createNodeIterator,A=w.createDocumentFragment,O=w.getElementsByTagName,_=r.importNode,j={};try{j=ma(o).documentMode?o.documentMode:{}}catch{}var R={};t.isSupported=typeof N=="function"&&C&&C.createHTMLDocument!==void 0&&j!==9;var P=mwe,$=hwe,V=gwe,D=vwe,x=ywe,S=bwe,L=wwe,B=Mwe,F=null,T=qe({},[].concat(kr(V3),kr(Ap),kr(Op),kr(zp),kr($3))),z=null,I=qe({},[].concat(kr(P3),kr(jp),kr(R3),kr(Lc))),Z=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),q=null,te=null,J=!0,W=!0,ae=!1,ce=!0,ye=!1,Ae=!1,Fe=!1,_e=!1,Le=!1,Ye=!1,Ke=!1,Be=!0,et=!1,lt="user-content-",je=!0,H=!1,G={},ze=null,pe=qe({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),we=null,be=qe({},["audio","video","img","source","image","track"]),ct=null,kt=qe({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),At="http://www.w3.org/1998/Math/MathML",Ut="http://www.w3.org/2000/svg",ne="http://www.w3.org/1999/xhtml",Q=ne,oe=!1,Y=null,le=qe({},[At,Ut,ne],_p),Ne,Ue=["application/xhtml+xml","text/html"],ut="text/html",rt,Ct=null,qt=o.createElement("form"),cn=function(U){return U instanceof RegExp||U instanceof Function},_t=function(U){Ct&&Ct===U||((!U||Fo(U)!=="object")&&(U={}),U=ma(U),Ne=Ue.indexOf(U.PARSER_MEDIA_TYPE)===-1?Ne=ut:Ne=U.PARSER_MEDIA_TYPE,rt=Ne==="application/xhtml+xml"?_p:tu,F="ALLOWED_TAGS"in U?qe({},U.ALLOWED_TAGS,rt):T,z="ALLOWED_ATTR"in U?qe({},U.ALLOWED_ATTR,rt):I,Y="ALLOWED_NAMESPACES"in U?qe({},U.ALLOWED_NAMESPACES,_p):le,ct="ADD_URI_SAFE_ATTR"in U?qe(ma(kt),U.ADD_URI_SAFE_ATTR,rt):kt,we="ADD_DATA_URI_TAGS"in U?qe(ma(be),U.ADD_DATA_URI_TAGS,rt):be,ze="FORBID_CONTENTS"in U?qe({},U.FORBID_CONTENTS,rt):pe,q="FORBID_TAGS"in U?qe({},U.FORBID_TAGS,rt):{},te="FORBID_ATTR"in U?qe({},U.FORBID_ATTR,rt):{},G="USE_PROFILES"in U?U.USE_PROFILES:!1,J=U.ALLOW_ARIA_ATTR!==!1,W=U.ALLOW_DATA_ATTR!==!1,ae=U.ALLOW_UNKNOWN_PROTOCOLS||!1,ce=U.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ye=U.SAFE_FOR_TEMPLATES||!1,Ae=U.WHOLE_DOCUMENT||!1,Le=U.RETURN_DOM||!1,Ye=U.RETURN_DOM_FRAGMENT||!1,Ke=U.RETURN_TRUSTED_TYPE||!1,_e=U.FORCE_BODY||!1,Be=U.SANITIZE_DOM!==!1,et=U.SANITIZE_NAMED_PROPS||!1,je=U.KEEP_CONTENT!==!1,H=U.IN_PLACE||!1,B=U.ALLOWED_URI_REGEXP||B,Q=U.NAMESPACE||ne,Z=U.CUSTOM_ELEMENT_HANDLING||{},U.CUSTOM_ELEMENT_HANDLING&&cn(U.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Z.tagNameCheck=U.CUSTOM_ELEMENT_HANDLING.tagNameCheck),U.CUSTOM_ELEMENT_HANDLING&&cn(U.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Z.attributeNameCheck=U.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),U.CUSTOM_ELEMENT_HANDLING&&typeof U.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(Z.allowCustomizedBuiltInElements=U.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ye&&(W=!1),Ye&&(Le=!0),G&&(F=qe({},kr($3)),z=[],G.html===!0&&(qe(F,V3),qe(z,P3)),G.svg===!0&&(qe(F,Ap),qe(z,jp),qe(z,Lc)),G.svgFilters===!0&&(qe(F,Op),qe(z,jp),qe(z,Lc)),G.mathMl===!0&&(qe(F,zp),qe(z,R3),qe(z,Lc))),U.ADD_TAGS&&(F===T&&(F=ma(F)),qe(F,U.ADD_TAGS,rt)),U.ADD_ATTR&&(z===I&&(z=ma(z)),qe(z,U.ADD_ATTR,rt)),U.ADD_URI_SAFE_ATTR&&qe(ct,U.ADD_URI_SAFE_ATTR,rt),U.FORBID_CONTENTS&&(ze===pe&&(ze=ma(ze)),qe(ze,U.FORBID_CONTENTS,rt)),je&&(F["#text"]=!0),Ae&&qe(F,["html","head","body"]),F.table&&(qe(F,["tbody"]),delete q.tbody),kn&&kn(U),Ct=U)},Qe=qe({},["mi","mo","mn","ms","mtext"]),se=qe({},["foreignobject","desc","title","annotation-xml"]),de=qe({},["title","style","font","a","script"]),Ce=qe({},Ap);qe(Ce,Op),qe(Ce,fwe);var Ht=qe({},zp);qe(Ht,pwe);var Jn=function(U){var ie=N(U);(!ie||!ie.tagName)&&(ie={namespaceURI:Q,tagName:"template"});var ue=tu(U.tagName),Re=tu(ie.tagName);return Y[U.namespaceURI]?U.namespaceURI===Ut?ie.namespaceURI===ne?ue==="svg":ie.namespaceURI===At?ue==="svg"&&(Re==="annotation-xml"||Qe[Re]):!!Ce[ue]:U.namespaceURI===At?ie.namespaceURI===ne?ue==="math":ie.namespaceURI===Ut?ue==="math"&&se[Re]:!!Ht[ue]:U.namespaceURI===ne?ie.namespaceURI===Ut&&!se[Re]||ie.namespaceURI===At&&!Qe[Re]?!1:!Ht[ue]&&(de[ue]||!Ce[ue]):!!(Ne==="application/xhtml+xml"&&Y[U.namespaceURI]):!1},Ot=function(U){Dl(t.removed,{element:U});try{U.parentNode.removeChild(U)}catch{try{U.outerHTML=k}catch{U.remove()}}},To=function(U,ie){try{Dl(t.removed,{attribute:ie.getAttributeNode(U),from:ie})}catch{Dl(t.removed,{attribute:null,from:ie})}if(ie.removeAttribute(U),U==="is"&&!z[U])if(Le||Ye)try{Ot(ie)}catch{}else try{ie.setAttribute(U,"")}catch{}},Pr=function(U){var ie,ue;if(_e)U="<remove></remove>"+U;else{var Re=swe(U,/^[\r\n\t ]+/);ue=Re&&Re[0]}Ne==="application/xhtml+xml"&&Q===ne&&(U='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+U+"</body></html>");var ot=M?M.createHTML(U):U;if(Q===ne)try{ie=new p().parseFromString(ot,Ne)}catch{}if(!ie||!ie.documentElement){ie=C.createDocument(Q,"template",null);try{ie.documentElement.innerHTML=oe?k:ot}catch{}}var pt=ie.body||ie.documentElement;return U&&ue&&pt.insertBefore(o.createTextNode(ue),pt.childNodes[0]||null),Q===ne?O.call(ie,Ae?"html":"body")[0]:Ae?ie.documentElement:pt},da=function(U){return E.call(U.ownerDocument||U,U,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT,null,!1)},yr=function(U){return U instanceof f&&(typeof U.nodeName!="string"||typeof U.textContent!="string"||typeof U.removeChild!="function"||!(U.attributes instanceof d)||typeof U.removeAttribute!="function"||typeof U.setAttribute!="function"||typeof U.namespaceURI!="string"||typeof U.insertBefore!="function"||typeof U.hasChildNodes!="function")},lo=function(U){return Fo(l)==="object"?U instanceof l:U&&Fo(U)==="object"&&typeof U.nodeType=="number"&&typeof U.nodeName=="string"},Bn=function(U,ie,ue){R[U]&&lwe(R[U],function(Re){Re.call(t,ie,ue,Ct)})},ei=function(U){var ie;if(Bn("beforeSanitizeElements",U,null),yr(U)||Mn(/[\u0080-\uFFFF]/,U.nodeName))return Ot(U),!0;var ue=rt(U.nodeName);if(Bn("uponSanitizeElement",U,{tagName:ue,allowedTags:F}),U.hasChildNodes()&&!lo(U.firstElementChild)&&(!lo(U.content)||!lo(U.content.firstElementChild))&&Mn(/<[/\w]/g,U.innerHTML)&&Mn(/<[/\w]/g,U.textContent)||ue==="select"&&Mn(/<template/i,U.innerHTML))return Ot(U),!0;if(!F[ue]||q[ue]){if(!q[ue]&&ni(ue)&&(Z.tagNameCheck instanceof RegExp&&Mn(Z.tagNameCheck,ue)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(ue)))return!1;if(je&&!ze[ue]){var Re=N(U)||U.parentNode,ot=y(U)||U.childNodes;if(ot&&Re)for(var pt=ot.length,mt=pt-1;mt>=0;--mt)Re.insertBefore(g(ot[mt],!0),v(U))}return Ot(U),!0}return U instanceof s&&!Jn(U)||(ue==="noscript"||ue==="noembed"||ue==="noframes")&&Mn(/<\/no(script|embed|frames)/i,U.innerHTML)?(Ot(U),!0):(ye&&U.nodeType===3&&(ie=U.textContent,ie=wr(ie,P," "),ie=wr(ie,$," "),ie=wr(ie,V," "),U.textContent!==ie&&(Dl(t.removed,{element:U.cloneNode()}),U.textContent=ie)),Bn("afterSanitizeElements",U,null),!1)},ti=function(U,ie,ue){if(Be&&(ie==="id"||ie==="name")&&(ue in o||ue in qt))return!1;if(!(W&&!te[ie]&&Mn(D,ie))){if(!(J&&Mn(x,ie))){if(!z[ie]||te[ie]){if(!(ni(U)&&(Z.tagNameCheck instanceof RegExp&&Mn(Z.tagNameCheck,U)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(U))&&(Z.attributeNameCheck instanceof RegExp&&Mn(Z.attributeNameCheck,ie)||Z.attributeNameCheck instanceof Function&&Z.attributeNameCheck(ie))||ie==="is"&&Z.allowCustomizedBuiltInElements&&(Z.tagNameCheck instanceof RegExp&&Mn(Z.tagNameCheck,ue)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(ue))))return!1}else if(!ct[ie]){if(!Mn(B,wr(ue,L,""))){if(!((ie==="src"||ie==="xlink:href"||ie==="href")&&U!=="script"&&cwe(ue,"data:")===0&&we[U])){if(!(ae&&!Mn(S,wr(ue,L,"")))){if(ue)return!1}}}}}}return!0},ni=function(U){return U.indexOf("-")>0},Rr=function(U){var ie,ue,Re,ot;Bn("beforeSanitizeAttributes",U,null);var pt=U.attributes;if(pt){var mt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:z};for(ot=pt.length;ot--;){ie=pt[ot];var Mr=ie,Et=Mr.name,ee=Mr.namespaceURI;if(ue=Et==="value"?ie.value:uwe(ie.value),Re=rt(Et),mt.attrName=Re,mt.attrValue=ue,mt.keepAttr=!0,mt.forceKeepAttr=void 0,Bn("uponSanitizeAttribute",U,mt),ue=mt.attrValue,!mt.forceKeepAttr&&(To(Et,U),!!mt.keepAttr)){if(!ce&&Mn(/\/>/i,ue)){To(Et,U);continue}ye&&(ue=wr(ue,P," "),ue=wr(ue,$," "),ue=wr(ue,V," "));var me=rt(U.nodeName);if(ti(me,Re,ue)){if(et&&(Re==="id"||Re==="name")&&(To(Et,U),ue=lt+ue),M&&Fo(h)==="object"&&typeof h.getAttributeType=="function"&&!ee)switch(h.getAttributeType(me,Re)){case"TrustedHTML":{ue=M.createHTML(ue);break}case"TrustedScriptURL":{ue=M.createScriptURL(ue);break}}try{ee?U.setAttributeNS(ee,Et,ue):U.setAttribute(Et,ue),B3(t.removed)}catch{}}}}Bn("afterSanitizeAttributes",U,null)}},X=function re(U){var ie,ue=da(U);for(Bn("beforeSanitizeShadowDOM",U,null);ie=ue.nextNode();)Bn("uponSanitizeShadowNode",ie,null),!ei(ie)&&(ie.content instanceof a&&re(ie.content),Rr(ie));Bn("afterSanitizeShadowDOM",U,null)};return t.sanitize=function(re){var U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ie,ue,Re,ot,pt;if(oe=!re,oe&&(re="<!-->"),typeof re!="string"&&!lo(re))if(typeof re.toString=="function"){if(re=re.toString(),typeof re!="string")throw Ip("dirty is not a string, aborting")}else throw Ip("toString is not a function");if(!t.isSupported){if(Fo(e.toStaticHTML)==="object"||typeof e.toStaticHTML=="function"){if(typeof re=="string")return e.toStaticHTML(re);if(lo(re))return e.toStaticHTML(re.outerHTML)}return re}if(Fe||_t(U),t.removed=[],typeof re=="string"&&(H=!1),H){if(re.nodeName){var mt=rt(re.nodeName);if(!F[mt]||q[mt])throw Ip("root node is forbidden and cannot be sanitized in-place")}}else if(re instanceof l)ie=Pr("<!---->"),ue=ie.ownerDocument.importNode(re,!0),ue.nodeType===1&&ue.nodeName==="BODY"||ue.nodeName==="HTML"?ie=ue:ie.appendChild(ue);else{if(!Le&&!ye&&!Ae&&re.indexOf("<")===-1)return M&&Ke?M.createHTML(re):re;if(ie=Pr(re),!ie)return Le?null:Ke?k:""}ie&&_e&&Ot(ie.firstChild);for(var Mr=da(H?re:ie);Re=Mr.nextNode();)Re.nodeType===3&&Re===ot||ei(Re)||(Re.content instanceof a&&X(Re.content),Rr(Re),ot=Re);if(ot=null,H)return re;if(Le){if(Ye)for(pt=A.call(ie.ownerDocument);ie.firstChild;)pt.appendChild(ie.firstChild);else pt=ie;return(z.shadowroot||z.shadowrootmod)&&(pt=_.call(r,pt,!0)),pt}var Et=Ae?ie.outerHTML:ie.innerHTML;return Ae&&F["!doctype"]&&ie.ownerDocument&&ie.ownerDocument.doctype&&ie.ownerDocument.doctype.name&&Mn(Nwe,ie.ownerDocument.doctype.name)&&(Et="<!DOCTYPE "+ie.ownerDocument.doctype.name+`>
|
|
162
|
-
`+Et),ye&&(Et=wr(Et,P," "),Et=wr(Et,$," "),Et=wr(Et,V," ")),M&&Ke?M.createHTML(Et):Et},t.setConfig=function(re){_t(re),Fe=!0},t.clearConfig=function(){Ct=null,Fe=!1},t.isValidAttribute=function(re,U,ie){Ct||_t({});var ue=rt(re),Re=rt(U);return ti(ue,Re,ie)},t.addHook=function(re,U){typeof U=="function"&&(R[re]=R[re]||[],Dl(R[re],U))},t.removeHook=function(re){if(R[re])return B3(R[re])},t.removeHooks=function(re){R[re]&&(R[re]=[])},t.removeAllHooks=function(){R={}},t}var Cwe=UN();const Ewe="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTciIGhlaWdodD0iMTAiIHZpZXdCb3g9IjAgMCAxNyAxMCIgZmlsbD0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yNDggMTEuNTg1OSAxMC42MTg0IDExLjU4NTkgMTAuOTA4N0MxMS41ODU5IDExLjE5OSAxMS40ODkxIDExLjM5MjYgMTEuMjk1NSAxMS41ODYxQzExLjEwMiAxMS43Nzk3IDEwLjkwODQgMTEuODc2NCAxMC42MTgxIDExLjg3NjRaIiBmaWxsPSIjNDM0RTVCIi8+Cjwvc3ZnPgo=";const Swe={name:"LTextEditor",props:{modelValue:String,lang:{type:String,default(){return pn()}},validVariables:{type:Array,default:()=>[]},isMailMergeMode:{type:Boolean,default:!1},readOnly:{type:Boolean,default:!1},transparent:{type:Boolean,default:!1}},emits:["update:modelValue","useMarkUp","focus","input"],components:{EditorContent:l6e,LinkBox:U8e,BubbleMenu:a6e,FloatingLink:q8e},data(){return{editor:null,markUps:[{name:"bold",tooltip:this.$tds("bold",this.lang),icon:"uil-bold"},{name:"italic",tooltip:this.$tds("italic",this.lang),icon:"uil-italic"},{name:"underline",tooltip:this.$tds("underline",this.lang),icon:"uil-underline"},{name:"heading",tooltip:this.$tds("title",this.lang),icon:Ewe},{name:"bulletList",tooltip:this.$tds("bullet-list",this.lang),icon:"uil-list-ul"},{name:"orderedList",tooltip:this.$tds("numbered-list",this.lang),icon:"uil-list-ol-alt"},{name:"link",tooltip:this.$tds("link",this.lang),icon:"uil-link-alt"},{name:"blockquote",tooltip:this.$tds("blockquote",this.lang),icon:Twe},{name:"removeFormatting",tooltip:this.$tds("remove-formatting",this.lang),icon:Dwe}],showLinkBox:!1,isEditorFocused:null,isInternalUpdate:!1,tooltipDelay:125}},methods:{focusEditor(){var e;(e=this.editor)==null||e.commands.focus()},isUnicon(e){return e.startsWith("uil-")},markUpText(e){if(e==="link"){this.toggleLinkBox();return}this.editor.chain().focus().setMarkUp(e).run()},toggleLinkBox(){this.showLinkBox=!this.showLinkBox},closeLinkBox(){this.editor.commands.focus(),this.toggleLinkBox()},markUpLink(e){this.currentTextSelection||this.previousURL?this.editor.chain().focus().extendMarkRange("link").setLink({href:e.url,target:"_blank"}).run():this.editor.commands.insertContent(X0.link(e.insertedText))},markOffLink(){this.editor.chain().focus().extendMarkRange("link").unsetLink().run()},hasSomeMarkUpActive(){const e=this.editor.getJSON().content,t=this.markUps.map(i=>i.name),o=e.map(i=>i.type).some(i=>t.includes(i)),a=e.some(i=>{if(i.hasOwnProperty("content"))return i.content.some(l=>l.hasOwnProperty("marks"))});return o||a},addSpaceToFinalParagraphTag(e){return e.replace(/<\/p>/g," </p>")}},watch:{validVariables:{handler(e){if(this.editor){this.editor.extensionManager.extensions.forEach(o=>{o.name==="templateHighlight"&&(o.options.validVariables=e)});const{state:t}=this.editor,r=t.tr;r.setMeta("forceUpdate",!0),this.editor.view.dispatch(r)}},deep:!0},isMailMergeMode(e){if(this.editor){this.editor.extensionManager.extensions.forEach(o=>{o.name==="templateHighlight"&&(o.options.isMailMergeMode=e)});const{state:t}=this.editor,r=t.tr;r.setMeta("forceUpdate",!0),this.editor.view.dispatch(r)}},modelValue(e){if(!this.editor||this.isInternalUpdate)return;const t=this.editor.getHTML();e!==t&&this.editor.commands.setContent(e,!1)}},computed:{isEditorEmpty(){var e;return((e=this.editor)==null?void 0:e.isEmpty)??!0},previousURL(){return this.editor.getAttributes("link").href},showFloatingLink(){return this.editor.isActive("link")},finalText(){const e=this.editor.getHTML(),t=this.addSpaceToFinalParagraphTag(e),r=X0.link(t);return Cwe.sanitize(K8e(r),{ADD_ATTR:["target"]})},currentTextSelection(){const{view:e,state:t}=this.editor,{from:r,to:o}=e.state.selection;return t.doc.textBetween(r,o,"")},arrowXPosition(){const t=this.$refs.link[0].$el;return{left:`${t.offsetLeft+(t.offsetWidth-16.8)/2}px`}},linkBoxPosition(){const t=this.$refs.texteditor.$el.offsetWidth,r=this.$refs.link[0].$el;let o;return t>500?o=`${r.offsetLeft+r.offsetWidth/2-456*.75}px`:o="1rem",{left:o}},placeholderText(){return this.$tds("text-editor-placeholder",this.lang)}},beforeMount(){this.editor=new i6e({extensions:[s6e,c6e,u6e,m6e,d6e.configure({validVariables:this.validVariables,isMailMergeMode:this.isMailMergeMode}),b6e,E6e,D6e,_6e,O6e,L6e,$6e,cbe,dbe.configure({placeholder:this.placeholderText}),fbe,Nbe],content:this.modelValue,autofocus:!1,editable:!this.readOnly,onUpdate:()=>{this.isInternalUpdate=!0,this.$emit("input",this.finalText),this.$emit("useMarkUp",this.hasSomeMarkUpActive()),this.$emit("update:modelValue",this.finalText),this.$nextTick(()=>{this.isInternalUpdate=!1})},onFocus:()=>{this.isEditorFocused=!0,this.$emit("focus",!0)},onBlur:()=>{this.isEditorFocused=!1}})},beforeUnmount(){this.editor.destroy()}},_we={class:"editor-content-wrapper"},Iwe={key:1,class:"wrapper-editor-features"},Awe={key:0},Owe={class:"wrapper-scroll"},zwe={class:"wrapper-buttons py-2 pl-3 pr-4 l-d-flex row l-d-justify-content-start l-d-align-item-center"},jwe=["alt","src"];function Lwe(e,t,r,o,a,i){const l=n.resolveComponent("FloatingLink"),s=n.resolveComponent("BubbleMenu"),c=n.resolveComponent("EditorContent"),u=n.resolveComponent("l-icon"),d=n.resolveComponent("l-button"),f=n.resolveComponent("l-tooltip"),p=n.resolveComponent("LinkBox");return n.openBlock(),n.createElementBlock("section",{class:n.normalizeClass(["wrapper-text-editor",{"has-custom-placeholder":e.$slots["empty-content"],"has-custom-content":e.$slots["custom-content"],"is-transparent":r.transparent}])},[i.showFloatingLink?(n.openBlock(),n.createBlock(s,{key:0,editor:a.editor,tippyOptions:{zIndex:1e3},shouldShow:({editor:h})=>h.isActive("link")},{default:n.withCtx(()=>[n.createVNode(l,{"data-link":a.editor.getAttributes("link").href,onEdit:t[0]||(t[0]=h=>i.toggleLinkBox()),onRemove:t[1]||(t[1]=h=>i.markOffLink())},null,8,["data-link"])]),_:1},8,["editor","shouldShow"])):n.createCommentVNode("",!0),n.createElementVNode("div",_we,[n.createVNode(c,{editor:a.editor,ref:"texteditor"},null,8,["editor"]),e.$slots["empty-content"]&&i.isEditorEmpty?(n.openBlock(),n.createElementBlock("div",{key:0,class:"editor-custom-placeholder",role:"button",tabindex:"0",onClick:t[2]||(t[2]=(...h)=>i.focusEditor&&i.focusEditor(...h)),onKeydown:[t[3]||(t[3]=n.withKeys((...h)=>i.focusEditor&&i.focusEditor(...h),["enter"])),t[4]||(t[4]=n.withKeys(n.withModifiers((...h)=>i.focusEditor&&i.focusEditor(...h),["prevent"]),["space"]))]},[n.renderSlot(e.$slots,"empty-content",{editor:a.editor,focus:i.focusEditor},void 0,!0)],32)):n.createCommentVNode("",!0)]),r.readOnly?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",Iwe,[e.$slots["custom-content"]?(n.openBlock(),n.createElementBlock("div",Awe,[n.renderSlot(e.$slots,"custom-content",{editor:a.editor},void 0,!0)])):n.createCommentVNode("",!0),n.createElementVNode("div",Owe,[n.createElementVNode("div",zwe,[n.renderSlot(e.$slots,"custom-buttons",{editor:a.editor},void 0,!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.markUps,h=>(n.openBlock(),n.createBlock(f,{key:h.name,content:h.tooltip,class:"item","open-delay":a.tooltipDelay},{default:n.withCtx(()=>[n.createVNode(d,{onClick:m=>i.markUpText(h.name),class:n.normalizeClass(["button-text-editor",{"is-active":a.editor.isActive(h.name)}]),size:"small",square:"",ref_for:!0,ref:h.name},{default:n.withCtx(()=>[i.isUnicon(h.icon)?(n.openBlock(),n.createBlock(u,{key:0,size:"24",icon:h.icon},null,8,["icon"])):(n.openBlock(),n.createElementBlock("img",{key:1,alt:h.name,src:h.icon,class:n.normalizeClass({"icon-active":a.editor.isActive(h.name)})},null,10,jwe))]),_:2},1032,["onClick","class"])]),_:2},1032,["content","open-delay"]))),128))])]),a.showLinkBox?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createElementVNode("span",{class:"link-box-arrow",style:n.normalizeStyle([i.arrowXPosition])},null,4),n.createVNode(p,{class:"link-box-position",onClose:t[5]||(t[5]=h=>i.closeLinkBox()),onSetLink:t[6]||(t[6]=h=>i.markUpLink(h)),previousURL:i.previousURL,style:n.normalizeStyle([i.linkBoxPosition]),lang:r.lang},null,8,["previousURL","style","lang"])],64)):n.createCommentVNode("",!0)]))],2)}const Bwe=xe(Swe,[["render",Lwe],["__scopeId","data-v-f21a150c"]]),Vwe=Object.freeze(Object.defineProperty({__proto__:null,default:Bwe},Symbol.toStringTag,{value:"Module"}));const ki=48,HN=5,$we=ki*HN,Pwe=ki*Math.floor(HN/2),Rwe={tagName:"l-time-scroll",name:"LTimeScroll",props:{modelValue:{type:Object,default:()=>({hours:0,minutes:0})},padZero:{type:Boolean,default:!0}},emits:["update:modelValue"],data(){return{hoursScroll:0,minutesScroll:0,hoursSnapTimer:null,minutesSnapTimer:null}},computed:{ITEM_HEIGHT(){return ki},CONTAINER_HEIGHT(){return $we},SPACER_HEIGHT(){return Pwe},hourItems(){return Array.from({length:24},(e,t)=>t)},minuteItems(){return Array.from({length:60},(e,t)=>t)}},watch:{"modelValue.hours"(e){this.scrollToValue(this.$refs.hoursContainer,e)},"modelValue.minutes"(e){this.scrollToValue(this.$refs.minutesContainer,e)}},mounted(){this.$nextTick(()=>{this.scrollToValue(this.$refs.hoursContainer,this.modelValue.hours,!1),this.scrollToValue(this.$refs.minutesContainer,this.modelValue.minutes,!1),requestAnimationFrame(()=>{this.hoursScroll=this.$refs.hoursContainer?this.$refs.hoursContainer.scrollTop:0,this.minutesScroll=this.$refs.minutesContainer?this.$refs.minutesContainer.scrollTop:0})})},methods:{format(e){return this.padZero?String(e).padStart(2,"0"):String(e)},getItemStyle(e,t){const r=t/ki,o=Math.abs(e-r);return{opacity:Math.max(.15,1-o*.35),fontSize:`${Math.max(14,22-o*4)}px`,fontWeight:o<.5?"700":"400",color:o<.5?"#111827":"#9ca3af",transition:"font-size 0.1s ease, font-weight 0.1s ease"}},handleScroll(e){const t=e==="hours"?this.$refs.hoursContainer:this.$refs.minutesContainer;if(!t)return;e==="hours"?this.hoursScroll=t.scrollTop:this.minutesScroll=t.scrollTop;const r=e+"SnapTimer";this[r]&&clearTimeout(this[r]),this[r]=setTimeout(()=>{if(!t)return;const o=e==="hours"?this.hourItems:this.minuteItems,a=Math.round(t.scrollTop/ki),i=Math.max(0,Math.min(o.length-1,a)),l=e==="hours"?this.modelValue.hours:this.modelValue.minutes;o[i]!==l&&this.$emit("update:modelValue",{...this.modelValue,[e]:o[i]})},80)},scrollToValue(e,t,r=!0){if(!e)return;const o=t*ki;Math.abs(e.scrollTop-o)<2||e.scrollTo({top:o,behavior:r?"smooth":"instant"})},selectItem(e,t){this.$emit("update:modelValue",{...this.modelValue,[e]:t})}}},Fwe={class:"picker-wheels"},Uwe={class:"wheels-flex"},Hwe=["onClick"],Ywe=["onClick"];function Qwe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",Fwe,[t[3]||(t[3]=n.createElementVNode("div",{class:"highlight-row"},null,-1)),n.createElementVNode("div",Uwe,[n.createElementVNode("div",{ref:"hoursContainer",class:"wheel-container wheel-column",style:n.normalizeStyle({height:i.CONTAINER_HEIGHT+"px",scrollSnapType:"y mandatory"}),onScroll:t[0]||(t[0]=l=>i.handleScroll("hours"))},[n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.hourItems,(l,s)=>(n.openBlock(),n.createElementBlock("div",{key:"h"+l,class:"wheel-item",style:n.normalizeStyle({height:i.ITEM_HEIGHT+"px",lineHeight:i.ITEM_HEIGHT+"px",scrollSnapAlign:"center",...i.getItemStyle(s,a.hoursScroll)}),onClick:c=>i.selectItem("hours",l)},n.toDisplayString(i.format(l)),13,Hwe))),128)),n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4)],36),t[2]||(t[2]=n.createElementVNode("span",{class:"colon"},":",-1)),n.createElementVNode("div",{ref:"minutesContainer",class:"wheel-container wheel-column",style:n.normalizeStyle({height:i.CONTAINER_HEIGHT+"px",scrollSnapType:"y mandatory"}),onScroll:t[1]||(t[1]=l=>i.handleScroll("minutes"))},[n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.minuteItems,(l,s)=>(n.openBlock(),n.createElementBlock("div",{key:"m"+l,class:"wheel-item",style:n.normalizeStyle({height:i.ITEM_HEIGHT+"px",lineHeight:i.ITEM_HEIGHT+"px",scrollSnapAlign:"center",...i.getItemStyle(s,a.minutesScroll)}),onClick:c=>i.selectItem("minutes",l)},n.toDisplayString(i.format(l)),13,Ywe))),128)),n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4)],36)])])}const Wwe=xe(Rwe,[["render",Qwe],["__scopeId","data-v-f64b65e8"]]),qwe=Object.freeze(Object.defineProperty({__proto__:null,default:Wwe},Symbol.toStringTag,{value:"Module"}));const Gwe=/^(\d{2}):(\d{2})$/;function Sl(e,{required:t=!1}={}){if(e===""||e===null||e===void 0)return{valid:!t,minutes:null,present:!1};if(typeof e!="string")return{valid:!1,minutes:null,present:!0};const r=e.match(Gwe);if(!r)return{valid:!1,minutes:null,present:!0};const o=Number(r[1]),a=Number(r[2]);return o>23||a>59?{valid:!1,minutes:null,present:!0}:{valid:!0,minutes:o*60+a,present:!0}}function F3(e){const t=String(Math.floor(e/60)).padStart(2,"0"),r=String(e%60).padStart(2,"0");return`${t}:${r}`}function Kwe({start:e,end:t,step:r,minTime:o,maxTime:a,includeEndTime:i}){var m;const l=[],s=Sl(e,{required:!0}),c=Sl(t,{required:!0}),u=Sl(r,{required:!0}),d=Sl(o),f=Sl(a);if(!s.valid||!c.valid||!u.valid||!d.valid||!f.valid||u.minutes<=0||s.minutes>c.minutes||d.present&&f.present&&d.minutes>f.minutes)return l;const p=g=>{const v=F3(g);l.push({value:v,label:v,disabled:d.present&&g<=d.minutes||f.present&&g>=f.minutes})};let h=s.minutes;for(;h<=c.minutes;)p(h),h+=u.minutes;return i&&((m=l[l.length-1])==null?void 0:m.value)!==F3(c.minutes)&&p(c.minutes),l}const Jwe={name:"LTimeSelect",tagName:"l-time-select",inheritAttrs:!1,components:{ElIcon:ke,ElSelectV2:NX},props:{modelValue:{type:String,default:""},start:{type:String,default:"00:00"},end:{type:String,default:"23:59"},step:{type:String,default:"00:30"},minTime:{type:String,default:""},maxTime:{type:String,default:""},includeEndTime:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},prefixIcon:{type:[String,Object],default:()=>Rm},clearIcon:{type:[String,Object],default:()=>Eo},hideIcon:{type:Boolean,default:!1},popperClass:{type:String,default:"l-time-picker-popper"},lang:{type:String,default:""},placeholder:{type:String,default(e){return Fl("time",e.lang||pn())}},clearable:{type:Boolean,default:!1}},emits:["update:modelValue","change"],mounted(){var t;const e=(t=this.$refs.timeSelect)==null?void 0:t.inputRef;e&&(this._timeKeydownHandler=r=>{if(r.key>="0"&&r.key<="9"){r.preventDefault();const o=e.value.replace(/\D/g,"");if(o.length>=4)return;const a=this.formatTimeInput(o+r.key);e.value=a,e.dispatchEvent(new Event("input",{bubbles:!0}))}else if(r.key==="Backspace"){r.preventDefault();const o=e.value.replace(/\D/g,"");if(!o.length)return;const a=this.formatTimeInput(o.slice(0,-1));e.value=a,e.dispatchEvent(new Event("input",{bubbles:!0}))}},this._timePasteHandler=r=>{r.preventDefault();const a=r.clipboardData.getData("text").replace(/\D/g,"").slice(0,4);e.value=this.formatTimeInput(a),e.dispatchEvent(new Event("input",{bubbles:!0}))},e.addEventListener("keydown",this._timeKeydownHandler,!0),e.addEventListener("paste",this._timePasteHandler,!0))},beforeUnmount(){var t;const e=(t=this.$refs.timeSelect)==null?void 0:t.inputRef;e&&(this._timeKeydownHandler&&e.removeEventListener("keydown",this._timeKeydownHandler,!0),this._timePasteHandler&&e.removeEventListener("paste",this._timePasteHandler,!0))},methods:{formatTimeInput(e){const t=e.replace(/\D/g,"").slice(0,4);return t.length<2?t:t.slice(0,2)+":"+t.slice(2)}},computed:{proxyValue:{get(){return this.modelValue},set(e){this.$emit("update:modelValue",e)}},timeOptions(){return Kwe({start:this.start,end:this.end,step:this.step,minTime:this.minTime,maxTime:this.maxTime,includeEndTime:this.includeEndTime})}}},Zwe={key:0,class:"l-time-select__prefix","aria-hidden":"true"};function Xwe(e,t,r,o,a,i){const l=n.resolveComponent("el-icon"),s=n.resolveComponent("el-select-v2");return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-time-select-wrapper",{"hide-icon":r.hideIcon}])},[!r.hideIcon&&r.prefixIcon?(n.openBlock(),n.createElementBlock("span",Zwe,[n.createVNode(l,{class:"l-time-select__prefix-icon"},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(r.prefixIcon)))]),_:1})])):n.createCommentVNode("",!0),n.createVNode(s,{modelValue:i.proxyValue,"onUpdate:modelValue":t[0]||(t[0]=c=>i.proxyValue=c),options:i.timeOptions,"clear-icon":r.clearIcon,placeholder:r.placeholder,clearable:r.clearable,"popper-class":r.popperClass,disabled:r.disabled,filterable:"","default-first-option":"",ref:"timeSelect",class:n.normalizeClass(["l-time-select",{"has-prefix-icon":!r.hideIcon&&r.prefixIcon}]),onChange:t[1]||(t[1]=c=>e.$emit("change",c))},null,8,["modelValue","options","clear-icon","placeholder","clearable","popper-class","disabled","class"])],2)}const eNe=xe(Jwe,[["render",Xwe]]),tNe=Object.freeze(Object.defineProperty({__proto__:null,default:eNe},Symbol.toStringTag,{value:"Module"}));const nNe={name:"LToggleButtonGroup",props:{options:Array,modelValue:String,disabled:{type:Boolean,default:!1}},computed:{value:{get(){return this.modelValue},set(e){this.$emit("update:modelValue",e)}}},methods:{optionType(e){return this.disabled?"default":e.value===this.value?"primary":"default"},selectOption(e){this.value=e.value}}};function rNe(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("l-tooltip"),c=n.resolveComponent("l-button-group");return n.openBlock(),n.createBlock(c,{class:"l-toggle-button-group"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.options,u=>(n.openBlock(),n.createBlock(s,{effect:"dark",content:u.title,placement:"bottom",key:u.value},{default:n.withCtx(()=>[n.createVNode(l,{disabled:r.disabled,type:i.optionType(u),icon:u.icon,size:"small",plain:"",onClick:d=>i.selectOption(u)},null,8,["disabled","type","icon","onClick"])]),_:2},1032,["content"]))),128))]),_:1})}const oNe=xe(nNe,[["render",rNe]]),aNe=Object.freeze(Object.defineProperty({__proto__:null,default:oNe},Symbol.toStringTag,{value:"Module"}));const iNe={components:{ElTooltip:Ka},props:{tooltipClass:{type:String,default:"l-tooltip-popper"}}};function lNe(e,t,r,o,a,i){const l=n.resolveComponent("ElTooltip");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{"popper-class":r.tooltipClass}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["popper-class"])}const sNe=xe(iNe,[["render",lNe]]),cNe=Object.freeze(Object.defineProperty({__proto__:null,default:sNe},Symbol.toStringTag,{value:"Module"}));const uNe={name:"LTransitionExpand",methods:{enter(e){const t=getComputedStyle(e).width;e.style.width=t,e.style.position="absolute",e.style.visibility="hidden",e.style.height="auto";const r=getComputedStyle(e).height;e.style.width=null,e.style.position=null,e.style.visibility=null,e.style.height=0,getComputedStyle(e).height,requestAnimationFrame(()=>{e.style.height=r})},afterEnter(e){e.style.height="auto"},leave(e){const t=getComputedStyle(e).height;e.style.height=t,getComputedStyle(e).height,requestAnimationFrame(()=>{e.style.height=0})}}};function dNe(e,t,r,o,a,i){return n.openBlock(),n.createBlock(n.Transition,{class:"l-transition-expand",name:"expand",onEnter:i.enter,onAfterEnter:i.afterEnter,onLeave:i.leave},{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["onEnter","onAfterEnter","onLeave"])}const fNe=xe(uNe,[["render",dNe],["__scopeId","data-v-00bad3ad"]]),pNe=Object.freeze(Object.defineProperty({__proto__:null,default:fNe},Symbol.toStringTag,{value:"Module"})),U3=Object.assign({"../components/LAlert/index.vue":Wee,"../components/LAttachmentChip/index.vue":ate,"../components/LBox/index.vue":cte,"../components/LBoxHeader/index.vue":pte,"../components/LButton/index.vue":yte,"../components/LCalendar/index.vue":Ite,"../components/LCarousel/index.vue":$te,"../components/LCheckbox/index.vue":Ute,"../components/LCheckboxButton/index.vue":Wte,"../components/LCheckboxGroup/index.vue":Jte,"../components/LChip/index.vue":rne,"../components/LCircularLoader/index.vue":lne,"../components/LCollapseItem/index.vue":dne,"../components/LDatePicker/index.vue":gne,"../components/LDialog/index.vue":bne,"../components/LFailedToLoad/index.vue":Tne,"../components/LForm/index.vue":Ine,"../components/LFormItem/index.vue":jne,"../components/LHelperBox/index.vue":Fne,"../components/LIcon/index.vue":ak,"../components/LImageViewer/index.vue":ere,"../components/LInput/index.vue":ire,"../components/LLinearProgress/index.vue":ure,"../components/LNotice/index.vue":gre,"../components/LNotification/index.vue":pk,"../components/LPresentation/index.vue":Cre,"../components/LPromptDialog/index.vue":Ire,"../components/LRadio/index.vue":jre,"../components/LRadioButton/index.vue":$re,"../components/LRadioGroup/index.vue":Ure,"../components/LRating/index.vue":Wre,"../components/LSearchBar/index.vue":Sfe,"../components/LSearchTopics/index.vue":Yme,"../components/LSelect/index.vue":Gme,"../components/LSwitch/index.vue":Xme,"../components/LTable/index.vue":i1e,"../components/LTabs/index.vue":u1e,"../components/LTargetChip/index.vue":h1e,"../components/LTargetInput/index.vue":M1e,"../components/LTextEditor/index.vue":Vwe,"../components/LTimeScroll/index.vue":qwe,"../components/LTimeSelect/index.vue":tNe,"../components/LToggleButtonGroup/index.vue":aNe,"../components/LTooltip/index.vue":cNe,"../components/LTransitionExpand/index.vue":pNe}),mNe=(e,t="index")=>{const r=e.split("/"),o=r.pop().replace(".vue","");return o===t?r.pop():o},hNe={install(e){Object.keys(U3).forEach(t=>{const r=mNe(t);e.component(r,U3[t].default)})}};exports.Language=void 0;const C2={};C2.install=function(e,t={enabledNotify:!1}){e.config.globalProperties.$L={},e.use(M0),e.use(q3),e.use(K3),e.use(Z3),e.use(zb),exports.Language=$ee(e),e.config.globalProperties.$tds=Fl,e.use(jb),e.use(hNe),Nd.extend(KN),e.mixin({mounted(){this.__layers_addClassName()},updated(){this.__layers_addClassName()},methods:{__layers_addClassName(){var r;if(!this.__layers_addedClassName){const o=((r=this==null?void 0:this.$options)==null?void 0:r.tagName)||"";/^l-/.test(o)&&this.$el.classList&&this.$el.classList.add(o)}}}}),t.enabledNotify&&(e.config.globalProperties.$notify=function(r){const o=r.onClick&&r.onClick instanceof Function,a=[r.customClass,r.type,!r.customClass&&!r.type&&"default",o&&"cursor-pointer"];return Ba({...r,customClass:a.filter(i=>i).join(" ")})})};exports.LayersDesignSystem=C2;exports.Notification=Ba;exports.commonjsGlobal=Pt;exports.dayjs_minExports=Y3;
|
|
159
|
+
3. "-" cannot repeat`);Tt.customSchemes.push([e,t])}function lbe(){Tt.scanner=Z6e(Tt.customSchemes);for(let e=0;e<Tt.tokenQueue.length;e++)Tt.tokenQueue[e][1]({scanner:Tt.scanner});Tt.parser=nbe(Tt.scanner.tokens);for(let e=0;e<Tt.pluginQueue.length;e++)Tt.pluginQueue[e][1]({scanner:Tt.scanner,parser:Tt.parser});Tt.initialized=!0}function IN(e){return Tt.initialized||lbe(),rbe(Tt.parser.start,e,X6e(Tt.scanner.start,e))}function AN(e,t,r){if(t===void 0&&(t=null),r===void 0&&(r=null),t&&typeof t=="object"){if(r)throw Error(`linkifyjs: Invalid link type ${t}; must be a string`);r=t,t=null}const o=new x2(r),a=IN(e),i=[];for(let l=0;l<a.length;l++){const s=a[l];s.isLink&&(!t||s.t===t)&&o.check(s)&&i.push(s.toFormattedObject(o))}return i}function sbe(e){return e.length===1?e[0].isLink:e.length===3&&e[1].isLink?["()","[]"].includes(e[0].value+e[2].value):!1}function cbe(e){return new tn({key:new yn("autolink"),appendTransaction:(t,r,o)=>{const a=t.some(u=>u.docChanged)&&!r.doc.eq(o.doc),i=t.some(u=>u.getMeta("preventAutolink"));if(!a||i)return;const{tr:l}=o,s=$3e(r.doc,[...t]);if(q3e(s).forEach(({newRange:u})=>{const d=R3e(o.doc,u,h=>h.isTextblock);let f,p;if(d.length>1?(f=d[0],p=o.doc.textBetween(f.pos,f.pos+f.node.nodeSize,void 0," ")):d.length&&o.doc.textBetween(u.from,u.to," "," ").endsWith(" ")&&(f=d[0],p=o.doc.textBetween(f.pos,u.to,void 0," ")),f&&p){const h=p.split(" ").filter(y=>y!=="");if(h.length<=0)return!1;const m=h[h.length-1],g=f.pos+p.lastIndexOf(m);if(!m)return!1;const v=IN(m).map(y=>y.toObject(e.defaultProtocol));if(!sbe(v))return!1;v.filter(y=>y.isLink).map(y=>({...y,from:g+y.start+1,to:g+y.end+1})).filter(y=>o.schema.marks.code?!o.doc.rangeHasMark(y.from,y.to,o.schema.marks.code):!0).filter(y=>e.validate(y.value)).forEach(y=>{c2(y.from,y.to,o.doc).some(N=>N.mark.type===e.type)||l.addMark(y.from,y.to,e.type.create({href:y.href}))})}}),!!l.steps.length)return l}})}function ube(e){return new tn({key:new yn("handleClickLink"),props:{handleClick:(t,r,o)=>{var a,i;if(o.button!==0||!t.editable)return!1;let l=o.target;const s=[];for(;l.nodeName!=="DIV";)s.push(l),l=l.parentNode;if(!s.find(p=>p.nodeName==="A"))return!1;const c=tN(t.state,e.type.name),u=o.target,d=(a=u==null?void 0:u.href)!==null&&a!==void 0?a:c.href,f=(i=u==null?void 0:u.target)!==null&&i!==void 0?i:c.target;return u&&d?(window.open(d,f),!0):!1}}})}function dbe(e){return new tn({key:new yn("handlePasteLink"),props:{handlePaste:(t,r,o)=>{const{state:a}=t,{selection:i}=a,{empty:l}=i;if(l)return!1;let s="";o.content.forEach(u=>{s+=u.textContent});const c=AN(s,{defaultProtocol:e.defaultProtocol}).find(u=>u.isLink&&u.value===s);return!s||!c?!1:(e.editor.commands.setMark(e.type,{href:c.href}),!0)}}})}const fbe=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g;function w3(e,t){const r=["http","https","ftp","ftps","mailto","tel","callto","sms","cid","xmpp"];return t&&t.forEach(o=>{const a=typeof o=="string"?o:o.scheme;a&&r.push(a)}),!e||e.replace(fbe,"").match(new RegExp(`^(?:(?:${r.join("|")}):|[^a-z]|[a-z+.-]+(?:[^a-z+.-:]|$))`,"i"))}const N3=oa.create({name:"link",priority:1e3,keepOnSplit:!1,exitable:!0,onCreate(){this.options.protocols.forEach(e=>{if(typeof e=="string"){b3(e);return}b3(e.scheme,e.optionalSlashes)})},onDestroy(){ibe()},inclusive(){return this.options.autolink},addOptions(){return{openOnClick:!0,linkOnPaste:!0,autolink:!0,protocols:[],defaultProtocol:"http",HTMLAttributes:{target:"_blank",rel:"noopener noreferrer nofollow",class:null},validate:e=>!!e}},addAttributes(){return{href:{default:null,parseHTML(e){return e.getAttribute("href")}},target:{default:this.options.HTMLAttributes.target},rel:{default:this.options.HTMLAttributes.rel},class:{default:this.options.HTMLAttributes.class}}},parseHTML(){return[{tag:"a[href]",getAttrs:e=>{const t=e.getAttribute("href");return!t||!w3(t,this.options.protocols)?!1:null}}]},renderHTML({HTMLAttributes:e}){return w3(e.href,this.options.protocols)?["a",jn(this.options.HTMLAttributes,e),0]:["a",jn(this.options.HTMLAttributes,{...e,href:""}),0]},addCommands(){return{setLink:e=>({chain:t})=>t().setMark(this.name,e).setMeta("preventAutolink",!0).run(),toggleLink:e=>({chain:t})=>t().toggleMark(this.name,e,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run(),unsetLink:()=>({chain:e})=>e().unsetMark(this.name,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()}},addPasteRules(){return[Is({find:e=>{const t=[];if(e){const{validate:r}=this.options,o=AN(e).filter(a=>a.isLink&&r(a.value));o.length&&o.forEach(a=>t.push({text:a.value,data:{href:a.href},index:a.start}))}return t},type:this.type,getAttributes:e=>{var t;return{href:(t=e.data)===null||t===void 0?void 0:t.href}}})]},addProseMirrorPlugins(){const e=[];return this.options.autolink&&e.push(cbe({type:this.type,defaultProtocol:this.options.defaultProtocol,validate:this.options.validate})),this.options.openOnClick===!0&&e.push(ube({type:this.type})),this.options.linkOnPaste&&e.push(dbe({editor:this.editor,defaultProtocol:this.options.defaultProtocol,type:this.type})),e}}),k3="color-link",x3="text-decoration: underline",pbe=N3.extend({defaultOptions:{...N3.options,openOnClick:!1},priority:1,addAttributes(){return{class:{default:k3,parseHTML:e=>e.class=k3},style:{default:x3,parseHTML:e=>e.style=x3},href:{default:""}}}}),mbe=hn.create({name:"placeholder",addOptions(){return{emptyEditorClass:"is-editor-empty",emptyNodeClass:"is-empty",placeholder:"Write something …",showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){return[new tn({key:new yn("placeholder"),props:{decorations:({doc:e,selection:t})=>{const r=this.editor.isEditable||!this.options.showOnlyWhenEditable,{anchor:o}=t,a=[];if(!r)return null;const i=this.editor.isEmpty;return e.descendants((l,s)=>{const c=o>=s&&o<=s+l.nodeSize,u=!l.isLeaf&&hf(l);if((c||!this.options.showOnlyCurrent)&&u){const d=[this.options.emptyNodeClass];i&&d.push(this.options.emptyEditorClass);const f=Un.node(s,s+l.nodeSize,{class:d.join(" "),"data-placeholder":typeof this.options.placeholder=="function"?this.options.placeholder({editor:this.editor,node:l,pos:s,hasAnchor:c}):this.options.placeholder});a.push(f)}return this.options.includeChildren}),It.create(e,a)}}})]}}),hbe=mbe.extend({addOptions(){var e;return{...(e=this.parent)==null?void 0:e.call(this),emptyEditorClass:"is-editor-empty color-gray-60",placeholder:"Escreva a descrição aqui"}}}),C3=pr.create({name:"hardBreak",addOptions(){return{keepMarks:!0,HTMLAttributes:{}}},inline:!0,group:"inline",selectable:!1,parseHTML(){return[{tag:"br"}]},renderHTML({HTMLAttributes:e}){return["br",jn(this.options.HTMLAttributes,e)]},renderText(){return`
|
|
160
|
+
`},addCommands(){return{setHardBreak:()=>({commands:e,chain:t,state:r,editor:o})=>e.first([()=>e.exitCode(),()=>e.command(()=>{const{selection:a,storedMarks:i}=r;if(a.$from.parent.type.spec.isolating)return!1;const{keepMarks:l}=this.options,{splittableMarks:s}=o.extensionManager,c=i||a.$to.parentOffset&&a.$from.marks();return t().insertContent({type:this.name}).command(({tr:u,dispatch:d})=>{if(d&&c&&l){const f=c.filter(p=>s.includes(p.type.name));u.ensureMarks(f)}return!0}).run()})])}},addKeyboardShortcuts(){return{"Mod-Enter":()=>this.editor.commands.setHardBreak(),"Shift-Enter":()=>this.editor.commands.setHardBreak()}}}),gbe=C3.extend({defaultOptions:{...C3.options,keepMarks:!1},addKeyboardShortcuts(){return{"Shift-Enter":()=>this.editor.commands.setHardBreak()}}});var bd=200,Xt=function(){};Xt.prototype.append=function(t){return t.length?(t=Xt.from(t),!this.length&&t||t.length<bd&&this.leafAppend(t)||this.length<bd&&t.leafPrepend(this)||this.appendInner(t)):this};Xt.prototype.prepend=function(t){return t.length?Xt.from(t).append(this):this};Xt.prototype.appendInner=function(t){return new vbe(this,t)};Xt.prototype.slice=function(t,r){return t===void 0&&(t=0),r===void 0&&(r=this.length),t>=r?Xt.empty:this.sliceInner(Math.max(0,t),Math.min(this.length,r))};Xt.prototype.get=function(t){if(!(t<0||t>=this.length))return this.getInner(t)};Xt.prototype.forEach=function(t,r,o){r===void 0&&(r=0),o===void 0&&(o=this.length),r<=o?this.forEachInner(t,r,o,0):this.forEachInvertedInner(t,r,o,0)};Xt.prototype.map=function(t,r,o){r===void 0&&(r=0),o===void 0&&(o=this.length);var a=[];return this.forEach(function(i,l){return a.push(t(i,l))},r,o),a};Xt.from=function(t){return t instanceof Xt?t:t&&t.length?new ON(t):Xt.empty};var ON=function(e){function t(o){e.call(this),this.values=o}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var r={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(a,i){return a==0&&i==this.length?this:new t(this.values.slice(a,i))},t.prototype.getInner=function(a){return this.values[a]},t.prototype.forEachInner=function(a,i,l,s){for(var c=i;c<l;c++)if(a(this.values[c],s+c)===!1)return!1},t.prototype.forEachInvertedInner=function(a,i,l,s){for(var c=i-1;c>=l;c--)if(a(this.values[c],s+c)===!1)return!1},t.prototype.leafAppend=function(a){if(this.length+a.length<=bd)return new t(this.values.concat(a.flatten()))},t.prototype.leafPrepend=function(a){if(this.length+a.length<=bd)return new t(a.flatten().concat(this.values))},r.length.get=function(){return this.values.length},r.depth.get=function(){return 0},Object.defineProperties(t.prototype,r),t}(Xt);Xt.empty=new ON([]);var vbe=function(e){function t(r,o){e.call(this),this.left=r,this.right=o,this.length=r.length+o.length,this.depth=Math.max(r.depth,o.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(o){return o<this.left.length?this.left.get(o):this.right.get(o-this.left.length)},t.prototype.forEachInner=function(o,a,i,l){var s=this.left.length;if(a<s&&this.left.forEachInner(o,a,Math.min(i,s),l)===!1||i>s&&this.right.forEachInner(o,Math.max(a-s,0),Math.min(this.length,i)-s,l+s)===!1)return!1},t.prototype.forEachInvertedInner=function(o,a,i,l){var s=this.left.length;if(a>s&&this.right.forEachInvertedInner(o,a-s,Math.max(i,s)-s,l+s)===!1||i<s&&this.left.forEachInvertedInner(o,Math.min(a,s),i,l)===!1)return!1},t.prototype.sliceInner=function(o,a){if(o==0&&a==this.length)return this;var i=this.left.length;return a<=i?this.left.slice(o,a):o>=i?this.right.slice(o-i,a-i):this.left.slice(o,i).append(this.right.slice(0,a-i))},t.prototype.leafAppend=function(o){var a=this.right.leafAppend(o);if(a)return new t(this.left,a)},t.prototype.leafPrepend=function(o){var a=this.left.leafPrepend(o);if(a)return new t(a,this.right)},t.prototype.appendInner=function(o){return this.left.depth>=Math.max(this.right.depth,o.depth)+1?new t(this.left,new t(this.right,o)):new t(this,o)},t}(Xt);const ybe=500;class Tr{constructor(t,r){this.items=t,this.eventCount=r}popEvent(t,r){if(this.eventCount==0)return null;let o=this.items.length;for(;;o--)if(this.items.get(o-1).selection){--o;break}let a,i;r&&(a=this.remapping(o,this.items.length),i=a.maps.length);let l=t.tr,s,c,u=[],d=[];return this.items.forEach((f,p)=>{if(!f.step){a||(a=this.remapping(o,p+1),i=a.maps.length),i--,d.push(f);return}if(a){d.push(new Qr(f.map));let h=f.step.map(a.slice(i)),m;h&&l.maybeStep(h).doc&&(m=l.mapping.maps[l.mapping.maps.length-1],u.push(new Qr(m,void 0,void 0,u.length+d.length))),i--,m&&a.appendMap(m,i)}else l.maybeStep(f.step);if(f.selection)return s=a?f.selection.map(a.slice(i)):f.selection,c=new Tr(this.items.slice(0,o).append(d.reverse().concat(u)),this.eventCount-1),!1},this.items.length,0),{remaining:c,transform:l,selection:s}}addTransform(t,r,o,a){let i=[],l=this.eventCount,s=this.items,c=!a&&s.length?s.get(s.length-1):null;for(let d=0;d<t.steps.length;d++){let f=t.steps[d].invert(t.docs[d]),p=new Qr(t.mapping.maps[d],f,r),h;(h=c&&c.merge(p))&&(p=h,d?i.pop():s=s.slice(0,s.length-1)),i.push(p),r&&(l++,r=void 0),a||(c=p)}let u=l-o.depth;return u>bbe&&(s=Mbe(s,u),l-=u),new Tr(s.append(i),l)}remapping(t,r){let o=new Di;return this.items.forEach((a,i)=>{let l=a.mirrorOffset!=null&&i-a.mirrorOffset>=t?o.maps.length-a.mirrorOffset:void 0;o.appendMap(a.map,l)},t,r),o}addMaps(t){return this.eventCount==0?this:new Tr(this.items.append(t.map(r=>new Qr(r))),this.eventCount)}rebased(t,r){if(!this.eventCount)return this;let o=[],a=Math.max(0,this.items.length-r),i=t.mapping,l=t.steps.length,s=this.eventCount;this.items.forEach(p=>{p.selection&&s--},a);let c=r;this.items.forEach(p=>{let h=i.getMirror(--c);if(h==null)return;l=Math.min(l,h);let m=i.maps[h];if(p.step){let g=t.steps[h].invert(t.docs[h]),v=p.selection&&p.selection.map(i.slice(c+1,h));v&&s++,o.push(new Qr(m,g,v))}else o.push(new Qr(m))},a);let u=[];for(let p=r;p<l;p++)u.push(new Qr(i.maps[p]));let d=this.items.slice(0,a).append(u).append(o),f=new Tr(d,s);return f.emptyItemCount()>ybe&&(f=f.compress(this.items.length-o.length)),f}emptyItemCount(){let t=0;return this.items.forEach(r=>{r.step||t++}),t}compress(t=this.items.length){let r=this.remapping(0,t),o=r.maps.length,a=[],i=0;return this.items.forEach((l,s)=>{if(s>=t)a.push(l),l.selection&&i++;else if(l.step){let c=l.step.map(r.slice(o)),u=c&&c.getMap();if(o--,u&&r.appendMap(u,o),c){let d=l.selection&&l.selection.map(r.slice(o));d&&i++;let f=new Qr(u.invert(),c,d),p,h=a.length-1;(p=a.length&&a[h].merge(f))?a[h]=p:a.push(f)}}else l.map&&o--},this.items.length,0),new Tr(Xt.from(a.reverse()),i)}}Tr.empty=new Tr(Xt.empty,0);function Mbe(e,t){let r;return e.forEach((o,a)=>{if(o.selection&&t--==0)return r=a,!1}),e.slice(r)}class Qr{constructor(t,r,o,a){this.map=t,this.step=r,this.selection=o,this.mirrorOffset=a}merge(t){if(this.step&&t.step&&!t.selection){let r=t.step.merge(this.step);if(r)return new Qr(r.getMap().invert(),r,this.selection)}}}class Lo{constructor(t,r,o,a,i){this.done=t,this.undone=r,this.prevRanges=o,this.prevTime=a,this.prevComposition=i}}const bbe=20;function wbe(e,t,r,o){let a=r.getMeta(ja),i;if(a)return a.historyState;r.getMeta(xbe)&&(e=new Lo(e.done,e.undone,null,0,-1));let l=r.getMeta("appendedTransaction");if(r.steps.length==0)return e;if(l&&l.getMeta(ja))return l.getMeta(ja).redo?new Lo(e.done.addTransform(r,void 0,o,Xc(t)),e.undone,E3(r.mapping.maps),e.prevTime,e.prevComposition):new Lo(e.done,e.undone.addTransform(r,void 0,o,Xc(t)),null,e.prevTime,e.prevComposition);if(r.getMeta("addToHistory")!==!1&&!(l&&l.getMeta("addToHistory")===!1)){let s=r.getMeta("composition"),c=e.prevTime==0||!l&&e.prevComposition!=s&&(e.prevTime<(r.time||0)-o.newGroupDelay||!Nbe(r,e.prevRanges)),u=l?Mp(e.prevRanges,r.mapping):E3(r.mapping.maps);return new Lo(e.done.addTransform(r,c?t.selection.getBookmark():void 0,o,Xc(t)),Tr.empty,u,r.time,s??e.prevComposition)}else return(i=r.getMeta("rebased"))?new Lo(e.done.rebased(r,i),e.undone.rebased(r,i),Mp(e.prevRanges,r.mapping),e.prevTime,e.prevComposition):new Lo(e.done.addMaps(r.mapping.maps),e.undone.addMaps(r.mapping.maps),Mp(e.prevRanges,r.mapping),e.prevTime,e.prevComposition)}function Nbe(e,t){if(!t)return!1;if(!e.docChanged)return!0;let r=!1;return e.mapping.maps[0].forEach((o,a)=>{for(let i=0;i<t.length;i+=2)o<=t[i+1]&&a>=t[i]&&(r=!0)}),r}function E3(e){let t=[];for(let r=e.length-1;r>=0&&t.length==0;r--)e[r].forEach((o,a,i,l)=>t.push(i,l));return t}function Mp(e,t){if(!e)return null;let r=[];for(let o=0;o<e.length;o+=2){let a=t.map(e[o],1),i=t.map(e[o+1],-1);a<=i&&r.push(a,i)}return r}function kbe(e,t,r){let o=Xc(t),a=ja.get(t).spec.config,i=(r?e.undone:e.done).popEvent(t,o);if(!i)return null;let l=i.selection.resolve(i.transform.doc),s=(r?e.done:e.undone).addTransform(i.transform,t.selection.getBookmark(),a,o),c=new Lo(r?s:i.remaining,r?i.remaining:s,null,0,-1);return i.transform.setSelection(l).setMeta(ja,{redo:r,historyState:c})}let bp=!1,T3=null;function Xc(e){let t=e.plugins;if(T3!=t){bp=!1,T3=t;for(let r=0;r<t.length;r++)if(t[r].spec.historyPreserveItems){bp=!0;break}}return bp}const ja=new yn("history"),xbe=new yn("closeHistory");function Cbe(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new tn({key:ja,state:{init(){return new Lo(Tr.empty,Tr.empty,null,0,-1)},apply(t,r,o){return wbe(r,o,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(t,r){let o=r.inputType,a=o=="historyUndo"?jN:o=="historyRedo"?LN:null;return a?(r.preventDefault(),a(t.state,t.dispatch)):!1}}}})}function zN(e,t){return(r,o)=>{let a=ja.getState(r);if(!a||(e?a.undone:a.done).eventCount==0)return!1;if(o){let i=kbe(a,r,e);i&&o(t?i.scrollIntoView():i)}return!0}}const jN=zN(!1,!0),LN=zN(!0,!0),D3=hn.create({name:"history",addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:e,dispatch:t})=>jN(e,t),redo:()=>({state:e,dispatch:t})=>LN(e,t)}},addProseMirrorPlugins(){return[Cbe(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()}}}),Ebe=D3.extend({defaultOptions:{...D3.options,newGroupDelay:150}});var Tbe="4.0.0";function Dbe(e){return e===void 0}function rr(e){return typeof e=="boolean"}function Sbe(e,t){for(var r in t)t.hasOwnProperty(r)&&Dbe(e[r])&&(e[r]=t[r]);return e}function _be(e,t,r){var o;return e.length>t&&(r==null?(r="…",o=3):o=r.length,e=e.substring(0,t-o)+r),e}function vt(e,t){for(var r=e.length-1;r>=0;r--)e[r]===t&&e.splice(r,1)}function pa(e,t){for(var r=e.length-1;r>=0;r--)t(e[r])===!0&&e.splice(r,1)}function es(e){throw new Error("Unhandled case for value: '".concat(e,"'"))}var Ai=/[A-Za-z]/,un=/[\d]/,Cr=/\s/,wp=/['"]/,Ibe=/[\x00-\x1F\x7F]/,Abe=/A-Za-z\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16F1-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FD5\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC/.source,Obe=/\u2700-\u27bf\udde6-\uddff\ud800-\udbff\udc00-\udfff\ufe0e\ufe0f\u0300-\u036f\ufe20-\ufe23\u20d0-\u20f0\ud83c\udffb-\udfff\u200d\u3299\u3297\u303d\u3030\u24c2\ud83c\udd70-\udd71\udd7e-\udd7f\udd8e\udd91-\udd9a\udde6-\uddff\ude01-\ude02\ude1a\ude2f\ude32-\ude3a\ude50-\ude51\u203c\u2049\u25aa-\u25ab\u25b6\u25c0\u25fb-\u25fe\u00a9\u00ae\u2122\u2139\udc04\u2600-\u26FF\u2b05\u2b06\u2b07\u2b1b\u2b1c\u2b50\u2b55\u231a\u231b\u2328\u23cf\u23e9-\u23f3\u23f8-\u23fa\udccf\u2935\u2934\u2190-\u21ff/.source,zbe=/\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D4-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C03\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D01-\u0D03\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF5\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F/.source,jbe=Abe+Obe+zbe,Lbe=/0-9\u0660-\u0669\u06F0-\u06F9\u07C0-\u07C9\u0966-\u096F\u09E6-\u09EF\u0A66-\u0A6F\u0AE6-\u0AEF\u0B66-\u0B6F\u0BE6-\u0BEF\u0C66-\u0C6F\u0CE6-\u0CEF\u0D66-\u0D6F\u0DE6-\u0DEF\u0E50-\u0E59\u0ED0-\u0ED9\u0F20-\u0F29\u1040-\u1049\u1090-\u1099\u17E0-\u17E9\u1810-\u1819\u1946-\u194F\u19D0-\u19D9\u1A80-\u1A89\u1A90-\u1A99\u1B50-\u1B59\u1BB0-\u1BB9\u1C40-\u1C49\u1C50-\u1C59\uA620-\uA629\uA8D0-\uA8D9\uA900-\uA909\uA9D0-\uA9D9\uA9F0-\uA9F9\uAA50-\uAA59\uABF0-\uABF9\uFF10-\uFF19/.source,BN=jbe+Lbe,La=new RegExp("[".concat(BN,"]")),VN=function(){function e(t){t===void 0&&(t={}),this.tagName="",this.attrs={},this.innerHTML="",this.tagName=t.tagName||"",this.attrs=t.attrs||{},this.innerHTML=t.innerHtml||t.innerHTML||""}return e.prototype.setTagName=function(t){return this.tagName=t,this},e.prototype.getTagName=function(){return this.tagName||""},e.prototype.setAttr=function(t,r){var o=this.getAttrs();return o[t]=r,this},e.prototype.getAttr=function(t){return this.getAttrs()[t]},e.prototype.setAttrs=function(t){return Object.assign(this.getAttrs(),t),this},e.prototype.getAttrs=function(){return this.attrs||(this.attrs={})},e.prototype.setClass=function(t){return this.setAttr("class",t)},e.prototype.addClass=function(t){for(var r=this.getClass(),o=r?r.split(Cr):[],a=t.split(Cr),i;i=a.shift();)o.indexOf(i)===-1&&o.push(i);return this.getAttrs().class=o.join(" "),this},e.prototype.removeClass=function(t){for(var r=this.getClass(),o=r?r.split(Cr):[],a=t.split(Cr),i;o.length&&(i=a.shift());){var l=o.indexOf(i);l!==-1&&o.splice(l,1)}return this.getAttrs().class=o.join(" "),this},e.prototype.getClass=function(){return this.getAttrs().class||""},e.prototype.hasClass=function(t){return(" "+this.getClass()+" ").indexOf(" "+t+" ")!==-1},e.prototype.setInnerHTML=function(t){return this.innerHTML=t,this},e.prototype.setInnerHtml=function(t){return this.setInnerHTML(t)},e.prototype.getInnerHTML=function(){return this.innerHTML||""},e.prototype.getInnerHtml=function(){return this.getInnerHTML()},e.prototype.toAnchorString=function(){var t=this.getTagName(),r=this.buildAttrsStr();return r=r?" "+r:"",["<",t,r,">",this.getInnerHtml(),"</",t,">"].join("")},e.prototype.buildAttrsStr=function(){if(!this.attrs)return"";var t=this.getAttrs(),r=[];for(var o in t)t.hasOwnProperty(o)&&r.push(o+'="'+t[o]+'"');return r.join(" ")},e}();function Bbe(e,t,r){var o,a;r==null?(r="…",a=3,o=8):(a=r.length,o=r.length);var i=function(N){var b={},M=N,k=M.match(/^([a-z]+):\/\//i);return k&&(b.scheme=k[1],M=M.substr(k[0].length)),k=M.match(/^(.*?)(?=(\?|#|\/|$))/i),k&&(b.host=k[1],M=M.substr(k[0].length)),k=M.match(/^\/(.*?)(?=(\?|#|$))/i),k&&(b.path=k[1],M=M.substr(k[0].length)),k=M.match(/^\?(.*?)(?=(#|$))/i),k&&(b.query=k[1],M=M.substr(k[0].length)),k=M.match(/^#(.*?)$/i),k&&(b.fragment=k[1]),b},l=function(N){var b="";return N.scheme&&N.host&&(b+=N.scheme+"://"),N.host&&(b+=N.host),N.path&&(b+="/"+N.path),N.query&&(b+="?"+N.query),N.fragment&&(b+="#"+N.fragment),b},s=function(N,b){var M=b/2,k=Math.ceil(M),w=-1*Math.floor(M),C="";return w<0&&(C=N.substr(w)),N.substr(0,k)+r+C};if(e.length<=t)return e;var c=t-a,u=i(e);if(u.query){var d=u.query.match(/^(.*?)(?=(\?|\#))(.*?)$/i);d&&(u.query=u.query.substr(0,d[1].length),e=l(u))}if(e.length<=t||(u.host&&(u.host=u.host.replace(/^www\./,""),e=l(u)),e.length<=t))return e;var f="";if(u.host&&(f+=u.host),f.length>=c)return u.host.length==t?(u.host.substr(0,t-a)+r).substr(0,c+o):s(f,c).substr(0,c+o);var p="";if(u.path&&(p+="/"+u.path),u.query&&(p+="?"+u.query),p)if((f+p).length>=c){if((f+p).length==t)return(f+p).substr(0,t);var h=c-f.length;return(f+s(p,h)).substr(0,c+o)}else f+=p;if(u.fragment){var m="#"+u.fragment;if((f+m).length>=c){if((f+m).length==t)return(f+m).substr(0,t);var g=c-f.length;return(f+s(m,g)).substr(0,c+o)}else f+=m}if(u.scheme&&u.host){var v=u.scheme+"://";if((f+v).length<c)return(v+f).substr(0,t)}if(f.length<=t)return f;var y="";return c>0&&(y=f.substr(-1*Math.floor(c/2))),(f.substr(0,Math.ceil(c/2))+r+y).substr(0,c+o)}function Vbe(e,t,r){if(e.length<=t)return e;var o,a;r==null?(r="…",o=8,a=3):(o=r.length,a=r.length);var i=t-a,l="";return i>0&&(l=e.substr(-1*Math.floor(i/2))),(e.substr(0,Math.ceil(i/2))+r+l).substr(0,i+o)}function $be(e,t,r){return _be(e,t,r)}var Pbe=function(){function e(t){t===void 0&&(t={}),this.newWindow=!1,this.truncate={},this.className="",this.newWindow=t.newWindow||!1,this.truncate=t.truncate||{},this.className=t.className||""}return e.prototype.build=function(t){return new VN({tagName:"a",attrs:this.createAttrs(t),innerHtml:this.processAnchorText(t.getAnchorText())})},e.prototype.createAttrs=function(t){var r={href:t.getAnchorHref()},o=this.createCssClass(t);return o&&(r.class=o),this.newWindow&&(r.target="_blank",r.rel="noopener noreferrer"),this.truncate&&this.truncate.length&&this.truncate.length<t.getAnchorText().length&&(r.title=t.getAnchorHref()),r},e.prototype.createCssClass=function(t){var r=this.className;if(r){for(var o=[r],a=t.getCssClassSuffixes(),i=0,l=a.length;i<l;i++)o.push(r+"-"+a[i]);return o.join(" ")}else return""},e.prototype.processAnchorText=function(t){return t=this.doTruncate(t),t},e.prototype.doTruncate=function(t){var r=this.truncate;if(!r||!r.length)return t;var o=r.length,a=r.location;return a==="smart"?Bbe(t,o):a==="middle"?Vbe(t,o):$be(t,o)},e}(),Z0=function(e,t){return Z0=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,o){r.__proto__=o}||function(r,o){for(var a in o)Object.prototype.hasOwnProperty.call(o,a)&&(r[a]=o[a])},Z0(e,t)};function nc(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Z0(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}var Gt=function(){return Gt=Object.assign||function(t){for(var r,o=1,a=arguments.length;o<a;o++){r=arguments[o];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i])}return t},Gt.apply(this,arguments)};var rc=function(){function e(t){this._=null,this.matchedText="",this.offset=0,this.tagBuilder=t.tagBuilder,this.matchedText=t.matchedText,this.offset=t.offset}return e.prototype.getMatchedText=function(){return this.matchedText},e.prototype.setOffset=function(t){this.offset=t},e.prototype.getOffset=function(){return this.offset},e.prototype.getCssClassSuffixes=function(){return[this.type]},e.prototype.buildTag=function(){return this.tagBuilder.build(this)},e}(),Rbe="(?:xn--vermgensberatung-pwb|xn--vermgensberater-ctb|xn--clchc0ea0b2g2a9gcd|xn--w4r85el8fhu5dnra|northwesternmutual|travelersinsurance|vermögensberatung|xn--5su34j936bgsg|xn--bck1b9a5dre4c|xn--mgbah1a3hjkrd|xn--mgbai9azgqp6j|xn--mgberp4a5d4ar|xn--xkc2dl3a5ee0h|vermögensberater|xn--fzys8d69uvgm|xn--mgba7c0bbn0a|xn--mgbcpq6gpa1a|xn--xkc2al3hye2a|americanexpress|kerryproperties|sandvikcoromant|xn--i1b6b1a6a2e|xn--kcrx77d1x4a|xn--lgbbat1ad8j|xn--mgba3a4f16a|xn--mgbaakc7dvf|xn--mgbc0a9azcg|xn--nqv7fs00ema|americanfamily|bananarepublic|cancerresearch|cookingchannel|kerrylogistics|weatherchannel|xn--54b7fta0cc|xn--6qq986b3xl|xn--80aqecdr1a|xn--b4w605ferd|xn--fiq228c5hs|xn--h2breg3eve|xn--jlq480n2rg|xn--jlq61u9w7b|xn--mgba3a3ejt|xn--mgbaam7a8h|xn--mgbayh7gpa|xn--mgbbh1a71e|xn--mgbca7dzdo|xn--mgbi4ecexp|xn--mgbx4cd0ab|xn--rvc1e0am3e|international|lifeinsurance|travelchannel|wolterskluwer|xn--cckwcxetd|xn--eckvdtc9d|xn--fpcrj9c3d|xn--fzc2c9e2c|xn--h2brj9c8c|xn--tiq49xqyj|xn--yfro4i67o|xn--ygbi2ammx|construction|lplfinancial|scholarships|versicherung|xn--3e0b707e|xn--45br5cyl|xn--4dbrk0ce|xn--80adxhks|xn--80asehdb|xn--8y0a063a|xn--gckr3f0f|xn--mgb9awbf|xn--mgbab2bd|xn--mgbgu82a|xn--mgbpl2fh|xn--mgbt3dhd|xn--mk1bu44c|xn--ngbc5azd|xn--ngbe9e0a|xn--ogbpf8fl|xn--qcka1pmc|accountants|barclaycard|blackfriday|blockbuster|bridgestone|calvinklein|contractors|creditunion|engineering|enterprises|foodnetwork|investments|kerryhotels|lamborghini|motorcycles|olayangroup|photography|playstation|productions|progressive|redumbrella|williamhill|xn--11b4c3d|xn--1ck2e1b|xn--1qqw23a|xn--2scrj9c|xn--3bst00m|xn--3ds443g|xn--3hcrj9c|xn--42c2d9a|xn--45brj9c|xn--55qw42g|xn--6frz82g|xn--80ao21a|xn--9krt00a|xn--cck2b3b|xn--czr694b|xn--d1acj3b|xn--efvy88h|xn--fct429k|xn--fjq720a|xn--flw351e|xn--g2xx48c|xn--gecrj9c|xn--gk3at1e|xn--h2brj9c|xn--hxt814e|xn--imr513n|xn--j6w193g|xn--jvr189m|xn--kprw13d|xn--kpry57d|xn--mgbbh1a|xn--mgbtx2b|xn--mix891f|xn--nyqy26a|xn--otu796d|xn--pgbs0dh|xn--q9jyb4c|xn--rhqv96g|xn--rovu88b|xn--s9brj9c|xn--ses554g|xn--t60b56a|xn--vuq861b|xn--w4rs40l|xn--xhq521b|xn--zfr164b|சிங்கப்பூர்|accountant|apartments|associates|basketball|bnpparibas|boehringer|capitalone|consulting|creditcard|cuisinella|eurovision|extraspace|foundation|healthcare|immobilien|industries|management|mitsubishi|nextdirect|properties|protection|prudential|realestate|republican|restaurant|schaeffler|tatamotors|technology|university|vlaanderen|volkswagen|xn--30rr7y|xn--3pxu8k|xn--45q11c|xn--4gbrim|xn--55qx5d|xn--5tzm5g|xn--80aswg|xn--90a3ac|xn--9dbq2a|xn--9et52u|xn--c2br7g|xn--cg4bki|xn--czrs0t|xn--czru2d|xn--fiq64b|xn--fiqs8s|xn--fiqz9s|xn--io0a7i|xn--kput3i|xn--mxtq1m|xn--o3cw4h|xn--pssy2u|xn--q7ce6a|xn--unup4y|xn--wgbh1c|xn--wgbl6a|xn--y9a3aq|accenture|alfaromeo|allfinanz|amsterdam|analytics|aquarelle|barcelona|bloomberg|christmas|community|directory|education|equipment|fairwinds|financial|firestone|fresenius|frontdoor|furniture|goldpoint|hisamitsu|homedepot|homegoods|homesense|institute|insurance|kuokgroup|lancaster|landrover|lifestyle|marketing|marshalls|melbourne|microsoft|panasonic|passagens|pramerica|richardli|shangrila|solutions|statebank|statefarm|stockholm|travelers|vacations|xn--90ais|xn--c1avg|xn--d1alf|xn--e1a4c|xn--fhbei|xn--j1aef|xn--j1amh|xn--l1acc|xn--ngbrx|xn--nqv7f|xn--p1acf|xn--qxa6a|xn--tckwe|xn--vhquv|yodobashi|موريتانيا|abudhabi|airforce|allstate|attorney|barclays|barefoot|bargains|baseball|boutique|bradesco|broadway|brussels|builders|business|capetown|catering|catholic|cipriani|cityeats|cleaning|clinique|clothing|commbank|computer|delivery|deloitte|democrat|diamonds|discount|discover|download|engineer|ericsson|etisalat|exchange|feedback|fidelity|firmdale|football|frontier|goodyear|grainger|graphics|guardian|hdfcbank|helsinki|holdings|hospital|infiniti|ipiranga|istanbul|jpmorgan|lighting|lundbeck|marriott|maserati|mckinsey|memorial|merckmsd|mortgage|observer|partners|pharmacy|pictures|plumbing|property|redstone|reliance|saarland|samsclub|security|services|shopping|showtime|softbank|software|stcgroup|supplies|training|vanguard|ventures|verisign|woodside|xn--90ae|xn--node|xn--p1ai|xn--qxam|yokohama|السعودية|abogado|academy|agakhan|alibaba|android|athleta|auction|audible|auspost|avianca|banamex|bauhaus|bentley|bestbuy|booking|brother|bugatti|capital|caravan|careers|channel|charity|chintai|citadel|clubmed|college|cologne|comcast|company|compare|contact|cooking|corsica|country|coupons|courses|cricket|cruises|dentist|digital|domains|exposed|express|farmers|fashion|ferrari|ferrero|finance|fishing|fitness|flights|florist|flowers|forsale|frogans|fujitsu|gallery|genting|godaddy|grocery|guitars|hamburg|hangout|hitachi|holiday|hosting|hoteles|hotmail|hyundai|ismaili|jewelry|juniper|kitchen|komatsu|lacaixa|lanxess|lasalle|latrobe|leclerc|limited|lincoln|markets|monster|netbank|netflix|network|neustar|okinawa|oldnavy|organic|origins|philips|pioneer|politie|realtor|recipes|rentals|reviews|rexroth|samsung|sandvik|schmidt|schwarz|science|shiksha|singles|staples|storage|support|surgery|systems|temasek|theater|theatre|tickets|tiffany|toshiba|trading|walmart|wanggou|watches|weather|website|wedding|whoswho|windows|winners|xfinity|yamaxun|youtube|zuerich|католик|اتصالات|البحرين|الجزائر|العليان|پاکستان|كاثوليك|இந்தியா|abarth|abbott|abbvie|africa|agency|airbus|airtel|alipay|alsace|alstom|amazon|anquan|aramco|author|bayern|beauty|berlin|bharti|bostik|boston|broker|camera|career|casino|center|chanel|chrome|church|circle|claims|clinic|coffee|comsec|condos|coupon|credit|cruise|dating|datsun|dealer|degree|dental|design|direct|doctor|dunlop|dupont|durban|emerck|energy|estate|events|expert|family|flickr|futbol|gallup|garden|george|giving|global|google|gratis|health|hermes|hiphop|hockey|hotels|hughes|imamat|insure|intuit|jaguar|joburg|juegos|kaufen|kinder|kindle|kosher|lancia|latino|lawyer|lefrak|living|locker|london|luxury|madrid|maison|makeup|market|mattel|mobile|monash|mormon|moscow|museum|mutual|nagoya|natura|nissan|nissay|norton|nowruz|office|olayan|online|oracle|orange|otsuka|pfizer|photos|physio|pictet|quebec|racing|realty|reisen|repair|report|review|rocher|rogers|ryukyu|safety|sakura|sanofi|school|schule|search|secure|select|shouji|soccer|social|stream|studio|supply|suzuki|swatch|sydney|taipei|taobao|target|tattoo|tennis|tienda|tjmaxx|tkmaxx|toyota|travel|unicom|viajes|viking|villas|virgin|vision|voting|voyage|vuelos|walter|webcam|xihuan|yachts|yandex|zappos|москва|онлайн|ابوظبي|ارامكو|الاردن|المغرب|امارات|فلسطين|مليسيا|भारतम्|இலங்கை|ファッション|actor|adult|aetna|amfam|amica|apple|archi|audio|autos|azure|baidu|beats|bible|bingo|black|boats|bosch|build|canon|cards|chase|cheap|cisco|citic|click|cloud|coach|codes|crown|cymru|dabur|dance|deals|delta|drive|dubai|earth|edeka|email|epson|faith|fedex|final|forex|forum|gallo|games|gifts|gives|glass|globo|gmail|green|gripe|group|gucci|guide|homes|honda|horse|house|hyatt|ikano|irish|jetzt|koeln|kyoto|lamer|lease|legal|lexus|lilly|linde|lipsy|loans|locus|lotte|lotto|macys|mango|media|miami|money|movie|music|nexus|nikon|ninja|nokia|nowtv|omega|osaka|paris|parts|party|phone|photo|pizza|place|poker|praxi|press|prime|promo|quest|radio|rehab|reise|ricoh|rocks|rodeo|rugby|salon|sener|seven|sharp|shell|shoes|skype|sling|smart|smile|solar|space|sport|stada|store|study|style|sucks|swiss|tatar|tires|tirol|tmall|today|tokyo|tools|toray|total|tours|trade|trust|tunes|tushu|ubank|vegas|video|vodka|volvo|wales|watch|weber|weibo|works|world|xerox|yahoo|ישראל|ایران|بازار|بھارت|سودان|سورية|همراه|भारोत|संगठन|বাংলা|భారత్|ഭാരതം|嘉里大酒店|aarp|able|adac|aero|akdn|ally|amex|arab|army|arpa|arte|asda|asia|audi|auto|baby|band|bank|bbva|beer|best|bike|bing|blog|blue|bofa|bond|book|buzz|cafe|call|camp|care|cars|casa|case|cash|cbre|cern|chat|citi|city|club|cool|coop|cyou|data|date|dclk|deal|dell|desi|diet|dish|docs|dvag|erni|fage|fail|fans|farm|fast|fiat|fido|film|fire|fish|flir|food|ford|free|fund|game|gbiz|gent|ggee|gift|gmbh|gold|golf|goog|guge|guru|hair|haus|hdfc|help|here|hgtv|host|hsbc|icbc|ieee|imdb|immo|info|itau|java|jeep|jobs|jprs|kddi|kids|kiwi|kpmg|kred|land|lego|lgbt|lidl|life|like|limo|link|live|loan|loft|love|ltda|luxe|maif|meet|meme|menu|mini|mint|mobi|moda|moto|name|navy|news|next|nico|nike|ollo|open|page|pars|pccw|pics|ping|pink|play|plus|pohl|porn|post|prod|prof|qpon|read|reit|rent|rest|rich|room|rsvp|ruhr|safe|sale|sarl|save|saxo|scot|seat|seek|sexy|shaw|shia|shop|show|silk|sina|site|skin|sncf|sohu|song|sony|spot|star|surf|talk|taxi|team|tech|teva|tiaa|tips|town|toys|tube|vana|visa|viva|vivo|vote|voto|wang|weir|wien|wiki|wine|work|xbox|yoga|zara|zero|zone|дети|сайт|بارت|بيتك|ڀارت|تونس|شبكة|عراق|عمان|موقع|भारत|ভারত|ভাৰত|ਭਾਰਤ|ભારત|ଭାରତ|ಭಾರತ|ලංකා|アマゾン|グーグル|クラウド|ポイント|组织机构|電訊盈科|香格里拉|aaa|abb|abc|aco|ads|aeg|afl|aig|anz|aol|app|art|aws|axa|bar|bbc|bbt|bcg|bcn|bet|bid|bio|biz|bms|bmw|bom|boo|bot|box|buy|bzh|cab|cal|cam|car|cat|cba|cbn|cbs|ceo|cfa|cfd|com|cpa|crs|dad|day|dds|dev|dhl|diy|dnp|dog|dot|dtv|dvr|eat|eco|edu|esq|eus|fan|fit|fly|foo|fox|frl|ftr|fun|fyi|gal|gap|gay|gdn|gea|gle|gmo|gmx|goo|gop|got|gov|hbo|hiv|hkt|hot|how|ibm|ice|icu|ifm|inc|ing|ink|int|ist|itv|jcb|jio|jll|jmp|jnj|jot|joy|kfh|kia|kim|kpn|krd|lat|law|lds|llc|llp|lol|lpl|ltd|man|map|mba|med|men|mil|mit|mlb|mls|mma|moe|moi|mom|mov|msd|mtn|mtr|nab|nba|nec|net|new|nfl|ngo|nhk|now|nra|nrw|ntt|nyc|obi|one|ong|onl|ooo|org|ott|ovh|pay|pet|phd|pid|pin|pnc|pro|pru|pub|pwc|red|ren|ril|rio|rip|run|rwe|sap|sas|sbi|sbs|sca|scb|ses|sew|sex|sfr|ski|sky|soy|spa|srl|stc|tab|tax|tci|tdk|tel|thd|tjx|top|trv|tui|tvs|ubs|uno|uol|ups|vet|vig|vin|vip|wed|win|wme|wow|wtc|wtf|xin|xxx|xyz|you|yun|zip|бел|ком|қаз|мкд|мон|орг|рус|срб|укр|հայ|קום|عرب|قطر|كوم|مصر|कॉम|नेट|คอม|ไทย|ລາວ|ストア|セール|みんな|中文网|亚马逊|天主教|我爱你|新加坡|淡马锡|诺基亚|飞利浦|ac|ad|ae|af|ag|ai|al|am|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cu|cv|cw|cx|cy|cz|de|dj|dk|dm|do|dz|ec|ee|eg|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|sj|sk|sl|sm|sn|so|sr|ss|st|su|sv|sx|sy|sz|tc|td|tf|tg|th|tj|tk|tl|tm|tn|to|tr|tt|tv|tw|tz|ua|ug|uk|us|uy|uz|va|vc|ve|vg|vi|vn|vu|wf|ws|ye|yt|za|zm|zw|ελ|ευ|бг|ею|рф|გე|닷넷|닷컴|삼성|한국|コム|世界|中信|中国|中國|企业|佛山|信息|健康|八卦|公司|公益|台湾|台灣|商城|商店|商标|嘉里|在线|大拿|娱乐|家電|广东|微博|慈善|手机|招聘|政务|政府|新闻|时尚|書籍|机构|游戏|澳門|点看|移动|网址|网店|网站|网络|联通|谷歌|购物|通販|集团|食品|餐厅|香港)",Fbe=new RegExp("^"+Rbe+"$"),Ube=/[\/?#]/,Hbe=/[-+&@#/%=~_()|'$*\[\]{}\u2713]/,$N=/[?!:,.;^]/,PN=/https?:\/\//i,Ybe=new RegExp("^"+PN.source,"i"),Qbe=new RegExp($N.source+"$"),Wbe=/^(javascript|vbscript):/i,qbe=/^[A-Za-z][-.+A-Za-z0-9]*:(\/\/)?([^:/]*)/,Gbe=/^(?:\/\/)?([^/#?:]+)/;function Np(e){return Ai.test(e)}function S3(e){return Ai.test(e)||un.test(e)||e==="+"||e==="-"||e==="."}function Oo(e){return La.test(e)}function kp(e){return e==="_"||Oo(e)}function _3(e){return La.test(e)||Hbe.test(e)||$N.test(e)}function xp(e){return Ube.test(e)}function RN(e){return Fbe.test(e.toLowerCase())}function Kbe(e){if(Wbe.test(e))return!1;var t=e.match(qbe);if(!t)return!1;var r=!!t[1],o=t[2];return r?!0:!(o.indexOf(".")===-1||!Ai.test(o))}function Jbe(e){var t=e.match(Gbe);if(!t)return!1;var r=t[0],o=r.split(".");if(o.length<2)return!1;var a=o[o.length-1];return!!RN(a)}var Zbe=/^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/,Xbe=/[:/?#]/;function e8e(e){var t=e.split(Xbe,1)[0];return Zbe.test(t)}var t8e=/^(https?:\/\/)?(www\.)?/i,n8e=/^\/\//,r8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="url",o.url="",o.urlMatchType="scheme",o.protocolRelativeMatch=!1,o.stripPrefix={scheme:!0,www:!0},o.stripTrailingSlash=!0,o.decodePercentEncoding=!0,o.protocolPrepended=!1,o.urlMatchType=r.urlMatchType,o.url=r.url,o.protocolRelativeMatch=r.protocolRelativeMatch,o.stripPrefix=r.stripPrefix,o.stripTrailingSlash=r.stripTrailingSlash,o.decodePercentEncoding=r.decodePercentEncoding,o}return t.prototype.getType=function(){return"url"},t.prototype.getUrlMatchType=function(){return this.urlMatchType},t.prototype.getUrl=function(){var r=this.url;return!this.protocolRelativeMatch&&this.urlMatchType!=="scheme"&&!this.protocolPrepended&&(r=this.url="http://"+r,this.protocolPrepended=!0),r},t.prototype.getAnchorHref=function(){var r=this.getUrl();return r.replace(/&/g,"&")},t.prototype.getAnchorText=function(){var r=this.getMatchedText();return this.protocolRelativeMatch&&(r=i8e(r)),this.stripPrefix.scheme&&(r=o8e(r)),this.stripPrefix.www&&(r=a8e(r)),this.stripTrailingSlash&&(r=l8e(r)),this.decodePercentEncoding&&(r=s8e(r)),r},t}(rc);function o8e(e){return e.replace(Ybe,"")}function a8e(e){return e.replace(t8e,"$1")}function i8e(e){return e.replace(n8e,"")}function l8e(e){return e.charAt(e.length-1)==="/"&&(e=e.slice(0,-1)),e}function s8e(e){var t=e.replace(/%22/gi,""").replace(/%26/gi,"&").replace(/%27/gi,"'").replace(/%3C/gi,"<").replace(/%3E/gi,">");try{return decodeURIComponent(t)}catch{return t}}var c8e=/^mailto:/i,u8e=new RegExp("[".concat(BN,"!#$%&'*+/=?^_`{|}~-]"));function d8e(e){return La.test(e)}function Cp(e){return u8e.test(e)}function f8e(e){var t=e.split(".").pop()||"";return RN(t)}var p8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="email",o.email="",o.email=r.email,o}return t.prototype.getType=function(){return"email"},t.prototype.getEmail=function(){return this.email},t.prototype.getAnchorHref=function(){return"mailto:"+this.email},t.prototype.getAnchorText=function(){return this.email},t}(rc);function I3(e){return e==="_"||La.test(e)}function m8e(e){return e.length<=140}var h8e=["twitter","facebook","instagram","tiktok"],g8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="hashtag",o.serviceName="twitter",o.hashtag="",o.serviceName=r.serviceName,o.hashtag=r.hashtag,o}return t.prototype.getType=function(){return"hashtag"},t.prototype.getServiceName=function(){return this.serviceName},t.prototype.getHashtag=function(){return this.hashtag},t.prototype.getAnchorHref=function(){var r=this.serviceName,o=this.hashtag;switch(r){case"twitter":return"https://twitter.com/hashtag/"+o;case"facebook":return"https://www.facebook.com/hashtag/"+o;case"instagram":return"https://instagram.com/explore/tags/"+o;case"tiktok":return"https://www.tiktok.com/tag/"+o;default:throw es(r),new Error("Invalid hashtag service: ".concat(r))}},t.prototype.getAnchorText=function(){return"#"+this.hashtag},t.prototype.getCssClassSuffixes=function(){var r=e.prototype.getCssClassSuffixes.call(this),o=this.getServiceName();return o&&r.push(o),r},t}(rc),v8e={twitter:/^@\w{1,15}$/,instagram:/^@[_\w]{1,30}$/,soundcloud:/^@[-a-z0-9_]{3,25}$/,tiktok:/^@[.\w]{1,23}[\w]$/},y8e=/[-\w.]/;function A3(e){return y8e.test(e)}function M8e(e,t){var r=v8e[t];return r.test(e)}var b8e=["twitter","instagram","soundcloud","tiktok"],w8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="mention",o.serviceName="twitter",o.mention="",o.mention=r.mention,o.serviceName=r.serviceName,o}return t.prototype.getType=function(){return"mention"},t.prototype.getMention=function(){return this.mention},t.prototype.getServiceName=function(){return this.serviceName},t.prototype.getAnchorHref=function(){switch(this.serviceName){case"twitter":return"https://twitter.com/"+this.mention;case"instagram":return"https://instagram.com/"+this.mention;case"soundcloud":return"https://soundcloud.com/"+this.mention;case"tiktok":return"https://www.tiktok.com/@"+this.mention;default:throw new Error("Unknown service name to point mention to: "+this.serviceName)}},t.prototype.getAnchorText=function(){return"@"+this.mention},t.prototype.getCssClassSuffixes=function(){var r=e.prototype.getCssClassSuffixes.call(this),o=this.getServiceName();return o&&r.push(o),r},t}(rc),N8e=/[-. ]/,k8e=/[-. ()]/,x8e=/[,;]/,C8e=/(?:(?:(?:(\+)?\d{1,3}[-. ]?)?\(?\d{3}\)?[-. ]?\d{3}[-. ]?\d{4})|(?:(\+)(?:9[976]\d|8[987530]\d|6[987]\d|5[90]\d|42\d|3[875]\d|2[98654321]\d|9[8543210]|8[6421]|6[6543210]|5[87654321]|4[987654310]|3[9643210]|2[70]|7|1)[-. ]?(?:\d[-. ]?){6,12}\d+))([,;]+[0-9]+#?)*/,E8e=/(0([1-9]-?[1-9]\d{3}|[1-9]{2}-?\d{3}|[1-9]{2}\d{1}-?\d{2}|[1-9]{2}\d{2}-?\d{1})-?\d{4}|0[789]0-?\d{4}-?\d{4}|050-?\d{4}-?\d{4})/,T8e=new RegExp("^".concat(C8e.source,"|").concat(E8e.source,"$"));function O3(e){return N8e.test(e)}function Ep(e){return x8e.test(e)}function D8e(e){var t=e.charAt(0)==="+"||k8e.test(e);return t&&T8e.test(e)}var S8e=function(e){nc(t,e);function t(r){var o=e.call(this,r)||this;return o.type="phone",o.number="",o.plusSign=!1,o.number=r.number,o.plusSign=r.plusSign,o}return t.prototype.getType=function(){return"phone"},t.prototype.getPhoneNumber=function(){return this.number},t.prototype.getNumber=function(){return this.getPhoneNumber()},t.prototype.getAnchorHref=function(){return"tel:"+(this.plusSign?"+":"")+this.number},t.prototype.getAnchorText=function(){return this.matchedText},t}(rc);function _8e(e,t){for(var r=t.tagBuilder,o=t.stripPrefix,a=t.stripTrailingSlash,i=t.decodePercentEncoding,l=t.hashtagServiceName,s=t.mentionServiceName,c=[],u=e.length,d=[],f=0;f<u;f++){var p=e.charAt(f);if(d.length===0)v(p);else for(var h=d.length-1;h>=0;h--){var m=d[h];switch(m.state){case 11:w(m,p);break;case 12:C(m,p);break;case 0:y(m,p);break;case 1:N(m,p);break;case 2:b(m,p);break;case 3:M(m,p);break;case 4:k(m,p);break;case 5:E(m,p);break;case 6:A(m,p);break;case 7:O(m,p);break;case 13:_(m,p);break;case 14:j(m,p);break;case 8:R(m,p);break;case 9:P(m,p);break;case 10:$(m,p);break;case 15:V(m,p);break;case 16:D(m,p);break;case 17:x(m,p);break;case 18:S(m,p);break;case 19:L(m,p);break;case 20:B(m,p);break;case 21:F(m,p);break;case 22:T(m,p);break;case 23:z(m,p);break;case 24:I(m,p);break;case 25:Z(m,p);break;case 26:q(m,p);break;case 27:te(m,p);break;case 28:J(m,p);break;case 29:W(m,p);break;case 30:ae(m,p);break;case 31:ce(m,p);break;case 32:Ae(m,p);break;case 33:Fe(m,p);break;case 34:_e(m,p);break;case 35:Le(m,p);break;case 36:Ye(m,p);break;case 37:ye(m,p);break;case 38:Ke(m,p);break;case 39:Be(m,p);break;case 40:et(m,p);break;case 41:lt(m,p);break;default:es(m.state)}}}for(var g=d.length-1;g>=0;g--)d.forEach(function(H){return je(H)});return c;function v(H){if(H==="#")d.push(j8e(f,28));else if(H==="@")d.push(L8e(f,30));else if(H==="/")d.push(Dp(f,11));else if(H==="+")d.push(Sp(f,37));else if(H==="(")d.push(Sp(f,32));else{if(un.test(H)&&(d.push(Sp(f,38)),d.push(O8e(f,13))),d8e(H)){var G=H.toLowerCase()==="m"?15:22;d.push(z8e(f,G))}Np(H)&&d.push(Tp(f,0)),La.test(H)&&d.push(Dp(f,5))}}function y(H,G){G===":"?H.state=2:G==="-"?H.state=1:S3(G)||vt(d,H)}function N(H,G){G==="-"||(G==="/"?(vt(d,H),d.push(Dp(f,11))):S3(G)?H.state=0:vt(d,H))}function b(H,G){G==="/"?H.state=3:G==="."?vt(d,H):Oo(G)?(H.state=5,Np(G)&&d.push(Tp(f,0))):vt(d,H)}function M(H,G){G==="/"?H.state=4:_3(G)?(H.state=10,H.acceptStateReached=!0):je(H)}function k(H,G){G==="/"?H.state=10:Oo(G)?(H.state=5,H.acceptStateReached=!0):vt(d,H)}function w(H,G){G==="/"?H.state=12:vt(d,H)}function C(H,G){Oo(G)?H.state=5:vt(d,H)}function E(H,G){G==="."?H.state=7:G==="-"?H.state=6:G===":"?H.state=8:xp(G)?H.state=10:kp(G)||je(H)}function A(H,G){G==="-"||(G==="."?je(H):Oo(G)?H.state=5:je(H))}function O(H,G){G==="."?je(H):Oo(G)?(H.state=5,H.acceptStateReached=!0):je(H)}function _(H,G){G==="."?H.state=14:G===":"?H.state=8:un.test(G)||(xp(G)?H.state=10:La.test(G)?vt(d,H):je(H))}function j(H,G){un.test(G)?(H.octetsEncountered++,H.octetsEncountered===4&&(H.acceptStateReached=!0),H.state=13):je(H)}function R(H,G){un.test(G)?H.state=9:je(H)}function P(H,G){un.test(G)||(xp(G)?H.state=10:je(H))}function $(H,G){_3(G)||je(H)}function V(H,G){G.toLowerCase()==="a"?H.state=16:T(H,G)}function D(H,G){G.toLowerCase()==="i"?H.state=17:T(H,G)}function x(H,G){G.toLowerCase()==="l"?H.state=18:T(H,G)}function S(H,G){G.toLowerCase()==="t"?H.state=19:T(H,G)}function L(H,G){G.toLowerCase()==="o"?H.state=20:T(H,G)}function B(H,G){G.toLowerCase()===":"?H.state=21:T(H,G)}function F(H,G){Cp(G)?H.state=22:vt(d,H)}function T(H,G){G==="."?H.state=23:G==="@"?H.state=24:Cp(G)?H.state=22:vt(d,H)}function z(H,G){G==="."||G==="@"?vt(d,H):Cp(G)?H.state=22:vt(d,H)}function I(H,G){Oo(G)?H.state=25:vt(d,H)}function Z(H,G){G==="."?H.state=27:G==="-"?H.state=26:kp(G)||je(H)}function q(H,G){G==="-"||G==="."?je(H):kp(G)?H.state=25:je(H)}function te(H,G){G==="."||G==="-"?je(H):Oo(G)?(H.state=25,H.acceptStateReached=!0):je(H)}function J(H,G){I3(G)?(H.state=29,H.acceptStateReached=!0):vt(d,H)}function W(H,G){I3(G)||je(H)}function ae(H,G){A3(G)?(H.state=31,H.acceptStateReached=!0):vt(d,H)}function ce(H,G){A3(G)||(La.test(G)?vt(d,H):je(H))}function ye(H,G){un.test(G)?H.state=38:(vt(d,H),v(G))}function Ae(H,G){un.test(G)?H.state=33:vt(d,H),v(G)}function Fe(H,G){un.test(G)?H.state=34:vt(d,H)}function _e(H,G){un.test(G)?H.state=35:vt(d,H)}function Le(H,G){G===")"?H.state=36:vt(d,H)}function Ye(H,G){un.test(G)?H.state=38:O3(G)?H.state=39:vt(d,H)}function Ke(H,G){H.acceptStateReached=!0,Ep(G)?H.state=40:G==="#"?H.state=41:un.test(G)||(G==="("?H.state=32:O3(G)?H.state=39:(je(H),Np(G)&&d.push(Tp(f,0))))}function Be(H,G){un.test(G)?H.state=38:G==="("?H.state=32:(je(H),v(G))}function et(H,G){Ep(G)||(G==="#"?H.state=41:un.test(G)?H.state=38:je(H))}function lt(H,G){Ep(G)?H.state=40:un.test(G)?vt(d,H):je(H)}function je(H){if(vt(d,H),!!H.acceptStateReached){var G=H.startIdx,ze=e.slice(H.startIdx,f);if(ze=A8e(ze),H.type==="url"){var pe=e.charAt(H.startIdx-1);if(pe==="@")return;var we=H.matchType;if(we==="scheme"){var be=PN.exec(ze);if(be&&(G=G+be.index,ze=ze.slice(be.index)),!Kbe(ze))return}else if(we==="tld"){if(!Jbe(ze))return}else if(we==="ipV4"){if(!e8e(ze))return}else es(we);c.push(new r8e({tagBuilder:r,matchedText:ze,offset:G,urlMatchType:we,url:ze,protocolRelativeMatch:ze.slice(0,2)==="//",stripPrefix:o,stripTrailingSlash:a,decodePercentEncoding:i}))}else if(H.type==="email")f8e(ze)&&c.push(new p8e({tagBuilder:r,matchedText:ze,offset:G,email:ze.replace(c8e,"")}));else if(H.type==="hashtag")m8e(ze)&&c.push(new g8e({tagBuilder:r,matchedText:ze,offset:G,serviceName:l,hashtag:ze.slice(1)}));else if(H.type==="mention")M8e(ze,s)&&c.push(new w8e({tagBuilder:r,matchedText:ze,offset:G,serviceName:s,mention:ze.slice(1)}));else if(H.type==="phone"){if(ze=ze.replace(/ +$/g,""),D8e(ze)){var ct=ze.replace(/[^0-9,;#]/g,"");c.push(new S8e({tagBuilder:r,matchedText:ze,offset:G,number:ct,plusSign:ze.charAt(0)==="+"}))}}else es(H)}}}var I8e=/[\(\{\[]/,z3=/[\)\}\]]/,j3={")":"(","}":"{","]":"["};function A8e(e){for(var t={"(":0,"{":0,"[":0},r=0;r<e.length;r++){var o=e.charAt(r);I8e.test(o)?t[o]++:z3.test(o)&&t[j3[o]]--}for(var a=e.length-1,i;a>=0;)if(i=e.charAt(a),z3.test(i)){var l=j3[i];if(t[l]<0)t[l]++,a--;else break}else if(Qbe.test(i))a--;else break;return e.slice(0,a+1)}function Tp(e,t){return{type:"url",startIdx:e,state:t,acceptStateReached:!1,matchType:"scheme"}}function Dp(e,t){return{type:"url",startIdx:e,state:t,acceptStateReached:!1,matchType:"tld"}}function O8e(e,t){return{type:"url",startIdx:e,state:t,acceptStateReached:!1,matchType:"ipV4",octetsEncountered:1}}function z8e(e,t){return{type:"email",startIdx:e,state:t,acceptStateReached:!1}}function j8e(e,t){return{type:"hashtag",startIdx:e,state:t,acceptStateReached:!1}}function L8e(e,t){return{type:"mention",startIdx:e,state:t,acceptStateReached:!1}}function Sp(e,t){return{type:"phone",startIdx:e,state:t,acceptStateReached:!1}}function B8e(e,t){for(var r=t.onOpenTag,o=t.onCloseTag,a=t.onText,i=t.onComment,l=t.onDoctype,s=new Fr,c=0,u=e.length,d=0,f=0,p=s;c<u;){var h=e.charAt(c);switch(d){case 0:m(h);break;case 1:g(h);break;case 2:y(h);break;case 3:v(h);break;case 4:N(h);break;case 5:b(h);break;case 6:M(h);break;case 7:k(h);break;case 8:w(h);break;case 9:C(h);break;case 10:E(h);break;case 11:A(h);break;case 12:O(h);break;case 13:_();break;case 14:j(h);break;case 15:R(h);break;case 16:P(h);break;case 17:$(h);break;case 18:V(h);break;case 19:D(h);break;case 20:x(h);break;default:es(d)}c++}f<c&&F();function m(I){I==="<"&&L()}function g(I){I==="!"?d=13:I==="/"?(d=2,p=new Fr(Gt(Gt({},p),{isClosing:!0}))):I==="<"?L():Ai.test(I)?(d=3,p=new Fr(Gt(Gt({},p),{isOpening:!0}))):(d=0,p=s)}function v(I){Cr.test(I)?(p=new Fr(Gt(Gt({},p),{name:T()})),d=4):I==="<"?L():I==="/"?(p=new Fr(Gt(Gt({},p),{name:T()})),d=12):I===">"?(p=new Fr(Gt(Gt({},p),{name:T()})),B()):!Ai.test(I)&&!un.test(I)&&I!==":"&&S()}function y(I){I===">"?S():Ai.test(I)?d=3:S()}function N(I){Cr.test(I)||(I==="/"?d=12:I===">"?B():I==="<"?L():I==="="||wp.test(I)||Ibe.test(I)?S():d=5)}function b(I){Cr.test(I)?d=6:I==="/"?d=12:I==="="?d=7:I===">"?B():I==="<"?L():wp.test(I)&&S()}function M(I){Cr.test(I)||(I==="/"?d=12:I==="="?d=7:I===">"?B():I==="<"?L():wp.test(I)?S():d=5)}function k(I){Cr.test(I)||(I==='"'?d=8:I==="'"?d=9:/[>=`]/.test(I)?S():I==="<"?L():d=10)}function w(I){I==='"'&&(d=11)}function C(I){I==="'"&&(d=11)}function E(I){Cr.test(I)?d=4:I===">"?B():I==="<"&&L()}function A(I){Cr.test(I)?d=4:I==="/"?d=12:I===">"?B():I==="<"?L():(d=4,z())}function O(I){I===">"?(p=new Fr(Gt(Gt({},p),{isClosing:!0})),B()):d=4}function _(I){e.substr(c,2)==="--"?(c+=2,p=new Fr(Gt(Gt({},p),{type:"comment"})),d=14):e.substr(c,7).toUpperCase()==="DOCTYPE"?(c+=7,p=new Fr(Gt(Gt({},p),{type:"doctype"})),d=20):S()}function j(I){I==="-"?d=15:I===">"?S():d=16}function R(I){I==="-"?d=18:I===">"?S():d=16}function P(I){I==="-"&&(d=17)}function $(I){I==="-"?d=18:d=16}function V(I){I===">"?B():I==="!"?d=19:I==="-"||(d=16)}function D(I){I==="-"?d=17:I===">"?B():d=16}function x(I){I===">"?B():I==="<"&&L()}function S(){d=0,p=s}function L(){d=1,p=new Fr({idx:c})}function B(){var I=e.slice(f,p.idx);I&&a(I,f),p.type==="comment"?i(p.idx):p.type==="doctype"?l(p.idx):(p.isOpening&&r(p.name,p.idx),p.isClosing&&o(p.name,p.idx)),S(),f=c+1}function F(){var I=e.slice(f,c);a(I,f),f=c+1}function T(){var I=p.idx+(p.isClosing?2:1);return e.slice(I,c).toLowerCase()}function z(){c--}}var Fr=function(){function e(t){t===void 0&&(t={}),this.idx=t.idx!==void 0?t.idx:-1,this.type=t.type||"tag",this.name=t.name||"",this.isOpening=!!t.isOpening,this.isClosing=!!t.isClosing}return e}(),X0=function(){function e(t){t===void 0&&(t={}),this.version=e.version,this.urls={},this.email=!0,this.phone=!0,this.hashtag=!1,this.mention=!1,this.newWindow=!0,this.stripPrefix={scheme:!0,www:!0},this.stripTrailingSlash=!0,this.decodePercentEncoding=!0,this.truncate={length:0,location:"end"},this.className="",this.replaceFn=null,this.context=void 0,this.sanitizeHtml=!1,this.tagBuilder=null,this.urls=V8e(t.urls),this.email=rr(t.email)?t.email:this.email,this.phone=rr(t.phone)?t.phone:this.phone,this.hashtag=t.hashtag||this.hashtag,this.mention=t.mention||this.mention,this.newWindow=rr(t.newWindow)?t.newWindow:this.newWindow,this.stripPrefix=$8e(t.stripPrefix),this.stripTrailingSlash=rr(t.stripTrailingSlash)?t.stripTrailingSlash:this.stripTrailingSlash,this.decodePercentEncoding=rr(t.decodePercentEncoding)?t.decodePercentEncoding:this.decodePercentEncoding,this.sanitizeHtml=t.sanitizeHtml||!1;var r=this.mention;if(r!==!1&&b8e.indexOf(r)===-1)throw new Error("invalid `mention` cfg '".concat(r,"' - see docs"));var o=this.hashtag;if(o!==!1&&h8e.indexOf(o)===-1)throw new Error("invalid `hashtag` cfg '".concat(o,"' - see docs"));this.truncate=P8e(t.truncate),this.className=t.className||this.className,this.replaceFn=t.replaceFn||this.replaceFn,this.context=t.context||this}return e.link=function(t,r){var o=new e(r);return o.link(t)},e.parse=function(t,r){var o=new e(r);return o.parse(t)},e.prototype.parse=function(t){var r=this,o=["a","style","script"],a=0,i=[];return B8e(t,{onOpenTag:function(l){o.indexOf(l)>=0&&a++},onText:function(l,s){if(a===0){var c=/( | |<|<|>|>|"|"|')/gi,u=l.split(c),d=s;u.forEach(function(f,p){if(p%2===0){var h=r.parseText(f,d);i.push.apply(i,h)}d+=f.length})}},onCloseTag:function(l){o.indexOf(l)>=0&&(a=Math.max(a-1,0))},onComment:function(l){},onDoctype:function(l){}}),i=this.compactMatches(i),i=this.removeUnwantedMatches(i),i},e.prototype.compactMatches=function(t){t.sort(function(c,u){return c.getOffset()-u.getOffset()});for(var r=0;r<t.length-1;){var o=t[r],a=o.getOffset(),i=o.getMatchedText().length,l=a+i;if(r+1<t.length){if(t[r+1].getOffset()===a){var s=t[r+1].getMatchedText().length>i?r:r+1;t.splice(s,1);continue}if(t[r+1].getOffset()<l){t.splice(r+1,1);continue}}r++}return t},e.prototype.removeUnwantedMatches=function(t){return this.hashtag||pa(t,function(r){return r.getType()==="hashtag"}),this.email||pa(t,function(r){return r.getType()==="email"}),this.phone||pa(t,function(r){return r.getType()==="phone"}),this.mention||pa(t,function(r){return r.getType()==="mention"}),this.urls.schemeMatches||pa(t,function(r){return r.getType()==="url"&&r.getUrlMatchType()==="scheme"}),this.urls.tldMatches||pa(t,function(r){return r.getType()==="url"&&r.getUrlMatchType()==="tld"}),this.urls.ipV4Matches||pa(t,function(r){return r.getType()==="url"&&r.getUrlMatchType()==="ipV4"}),t},e.prototype.parseText=function(t,r){r===void 0&&(r=0),r=r||0;for(var o=_8e(t,{tagBuilder:this.getTagBuilder(),stripPrefix:this.stripPrefix,stripTrailingSlash:this.stripTrailingSlash,decodePercentEncoding:this.decodePercentEncoding,hashtagServiceName:this.hashtag,mentionServiceName:this.mention||"twitter"}),a=0,i=o.length;a<i;a++)o[a].setOffset(r+o[a].getOffset());return o},e.prototype.link=function(t){if(!t)return"";this.sanitizeHtml&&(t=t.replace(/</g,"<").replace(/>/g,">"));for(var r=this.parse(t),o=[],a=0,i=0,l=r.length;i<l;i++){var s=r[i];o.push(t.substring(a,s.getOffset())),o.push(this.createMatchReturnVal(s)),a=s.getOffset()+s.getMatchedText().length}return o.push(t.substring(a)),o.join("")},e.prototype.createMatchReturnVal=function(t){var r;if(this.replaceFn&&(r=this.replaceFn.call(this.context,t)),typeof r=="string")return r;if(r===!1)return t.getMatchedText();if(r instanceof VN)return r.toAnchorString();var o=t.buildTag();return o.toAnchorString()},e.prototype.getTagBuilder=function(){var t=this.tagBuilder;return t||(t=this.tagBuilder=new Pbe({newWindow:this.newWindow,truncate:this.truncate,className:this.className})),t},e.version=Tbe,e}();function V8e(e){return e==null&&(e=!0),rr(e)?{schemeMatches:e,tldMatches:e,ipV4Matches:e}:{schemeMatches:rr(e.schemeMatches)?e.schemeMatches:!0,tldMatches:rr(e.tldMatches)?e.tldMatches:!0,ipV4Matches:rr(e.ipV4Matches)?e.ipV4Matches:!0}}function $8e(e){return e==null&&(e=!0),rr(e)?{scheme:e,www:e}:{scheme:rr(e.scheme)?e.scheme:!0,www:rr(e.www)?e.www:!0}}function P8e(e){return typeof e=="number"?{length:e,location:"end"}:Sbe(e||{},{length:Number.POSITIVE_INFINITY,location:"end"})}function R8e(e){return e.startsWith("http://")||e.startsWith("https://")?e:"https://"+e}const F8e={props:{previousURL:String,lang:{type:String,default(){return pn()}}},data(){return{linkToAppend:this.previousURL,linkError:""}},methods:{insertLink(){this.isLinkValid(this.linkToAppend)?(this.linkError=!1,this.$emit("setLink",{url:R8e(this.linkToAppend),insertedText:this.linkToAppend}),this.$emit("close")):this.linkError=!0},isLinkValid(e){return X0.link(e,{email:!1}).includes("href")}},computed:{disableButton(){return this.linkToAppend===""||this.linkToAppend===void 0},hasError(){return!!this.linkError}}},U8e={class:"wrapper-input mb-3"},H8e={key:0,class:"l-input-error-message"},Y8e={class:"wrapper-buttons row l-justify-content-end"};function Q8e(e,t,r,o,a,i){const l=n.resolveComponent("l-input"),s=n.resolveComponent("l-button"),c=n.resolveComponent("l-box");return n.openBlock(),n.createBlock(c,{class:"link-box column"},{default:n.withCtx(()=>[n.createElementVNode("div",U8e,[n.createVNode(l,{modelValue:a.linkToAppend,"onUpdate:modelValue":t[0]||(t[0]=u=>a.linkToAppend=u),placeholder:e.$tds("insert-link",r.lang),error:i.hasError,autofocus:"",style:{"box-sizing":"border-box"}},null,8,["modelValue","placeholder","error"]),a.linkError?(n.openBlock(),n.createElementBlock("div",H8e,n.toDisplayString(e.$tds("insert-valid-link",r.lang)),1)):n.createCommentVNode("",!0)]),n.createElementVNode("div",Y8e,[n.createVNode(s,{size:"small",onClick:t[1]||(t[1]=u=>e.$emit("close"))},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("cancel",r.lang)),1)]),_:1}),n.createVNode(s,{size:"small",type:"primary",onClick:t[2]||(t[2]=u=>i.insertLink()),disabled:i.disableButton},{default:n.withCtx(()=>[n.createTextVNode(n.toDisplayString(e.$tds("insert",r.lang)),1)]),_:1},8,["disabled"])])]),_:1})}const W8e=xe(F8e,[["render",Q8e],["__scopeId","data-v-e59381b7"]]);const q8e={props:{dataLink:String,lang:{type:String,default(){return pn()}}},data(){return{tooltipDelay:125}},methods:{actionButtonBased(e){this.$emit(e)}},computed:{tooltipLink(){return this.dataLink.length>=60?this.dataLink.slice(0,60)+"...":this.dataLink},boxButtons(){return[{tooltip:this.$tds("edit-link",this.lang),icon:"uil-edit",event:"edit"},{tooltip:this.$tds("remove-link",this.lang),icon:"uil-link-broken",event:"remove"}]}}},G8e={class:"wrapper-floating-link l-ra-1 px-2 py-2 row l-align-items-center l-align-content-center"},K8e=["href","open-delay"];function J8e(e,t,r,o,a,i){const l=n.resolveComponent("l-icon"),s=n.resolveComponent("l-tooltip");return n.openBlock(),n.createElementBlock("div",G8e,[n.createVNode(l,{size:"24",class:"color-lead-light mr-2",icon:"uil-globe"}),n.createVNode(s,{class:"item color-link",content:i.tooltipLink},{default:n.withCtx(()=>[n.createElementVNode("a",{class:"l-flex-grow-1 h6 color-link l-ellipsis",target:"_blank",rel:"nofollow noopener noreferrer",style:{display:"inline"},href:r.dataLink,"open-delay":a.tooltipDelay},n.toDisplayString(r.dataLink),9,K8e)]),_:1},8,["content"]),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.boxButtons,(c,u)=>(n.openBlock(),n.createBlock(s,{class:"item",key:u,content:c.tooltip,"open-delay":a.tooltipDelay},{default:n.withCtx(()=>[n.createVNode(l,{size:"20",class:"color-lead-light ml-2",icon:c.icon,onClick:d=>i.actionButtonBased(c.event)},null,8,["icon","onClick"])]),_:2},1032,["content","open-delay"]))),128))])}const Z8e=xe(q8e,[["render",J8e],["__scopeId","data-v-b523904a"]]),X8e=/<(\w+).[^>]*>\s*<\/\1>/g;function ewe(e){return e.replace(X8e,"")}/*! @license DOMPurify 2.4.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.4.7/LICENSE */function Fo(e){"@babel/helpers - typeof";return Fo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fo(e)}function em(e,t){return em=Object.setPrototypeOf||function(o,a){return o.__proto__=a,o},em(e,t)}function twe(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function eu(e,t,r){return twe()?eu=Reflect.construct:eu=function(a,i,l){var s=[null];s.push.apply(s,i);var c=Function.bind.apply(a,s),u=new c;return l&&em(u,l.prototype),u},eu.apply(null,arguments)}function kr(e){return nwe(e)||rwe(e)||owe(e)||awe()}function nwe(e){if(Array.isArray(e))return tm(e)}function rwe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function owe(e,t){if(e){if(typeof e=="string")return tm(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return tm(e,t)}}function tm(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,o=new Array(t);r<t;r++)o[r]=e[r];return o}function awe(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
161
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var iwe=Object.hasOwnProperty,L3=Object.setPrototypeOf,lwe=Object.isFrozen,swe=Object.getPrototypeOf,cwe=Object.getOwnPropertyDescriptor,kn=Object.freeze,zr=Object.seal,uwe=Object.create,FN=typeof Reflect<"u"&&Reflect,wd=FN.apply,nm=FN.construct;wd||(wd=function(t,r,o){return t.apply(r,o)});kn||(kn=function(t){return t});zr||(zr=function(t){return t});nm||(nm=function(t,r){return eu(t,kr(r))});var dwe=gr(Array.prototype.forEach),B3=gr(Array.prototype.pop),Dl=gr(Array.prototype.push),tu=gr(String.prototype.toLowerCase),_p=gr(String.prototype.toString),fwe=gr(String.prototype.match),wr=gr(String.prototype.replace),pwe=gr(String.prototype.indexOf),mwe=gr(String.prototype.trim),Mn=gr(RegExp.prototype.test),Ip=hwe(TypeError);function gr(e){return function(t){for(var r=arguments.length,o=new Array(r>1?r-1:0),a=1;a<r;a++)o[a-1]=arguments[a];return wd(e,t,o)}}function hwe(e){return function(){for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return nm(e,r)}}function qe(e,t,r){var o;r=(o=r)!==null&&o!==void 0?o:tu,L3&&L3(e,null);for(var a=t.length;a--;){var i=t[a];if(typeof i=="string"){var l=r(i);l!==i&&(lwe(t)||(t[a]=l),i=l)}e[i]=!0}return e}function ma(e){var t=uwe(null),r;for(r in e)wd(iwe,e,[r])===!0&&(t[r]=e[r]);return t}function jc(e,t){for(;e!==null;){var r=cwe(e,t);if(r){if(r.get)return gr(r.get);if(typeof r.value=="function")return gr(r.value)}e=swe(e)}function o(a){return console.warn("fallback value for",a),null}return o}var V3=kn(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Ap=kn(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Op=kn(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),gwe=kn(["animate","color-profile","cursor","discard","fedropshadow","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),zp=kn(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),vwe=kn(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),$3=kn(["#text"]),P3=kn(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),jp=kn(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),R3=kn(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Lc=kn(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),ywe=zr(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Mwe=zr(/<%[\w\W]*|[\w\W]*%>/gm),bwe=zr(/\${[\w\W]*}/gm),wwe=zr(/^data-[\-\w.\u00B7-\uFFFF]/),Nwe=zr(/^aria-[\-\w]+$/),kwe=zr(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),xwe=zr(/^(?:\w+script|data):/i),Cwe=zr(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Ewe=zr(/^html$/i),Twe=function(){return typeof window>"u"?null:window},Dwe=function(t,r){if(Fo(t)!=="object"||typeof t.createPolicy!="function")return null;var o=null,a="data-tt-policy-suffix";r.currentScript&&r.currentScript.hasAttribute(a)&&(o=r.currentScript.getAttribute(a));var i="dompurify"+(o?"#"+o:"");try{return t.createPolicy(i,{createHTML:function(s){return s},createScriptURL:function(s){return s}})}catch{return console.warn("TrustedTypes policy "+i+" could not be created."),null}};function UN(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Twe(),t=function(U){return UN(U)};if(t.version="2.4.7",t.removed=[],!e||!e.document||e.document.nodeType!==9)return t.isSupported=!1,t;var r=e.document,o=e.document,a=e.DocumentFragment,i=e.HTMLTemplateElement,l=e.Node,s=e.Element,c=e.NodeFilter,u=e.NamedNodeMap,d=u===void 0?e.NamedNodeMap||e.MozNamedAttrMap:u,f=e.HTMLFormElement,p=e.DOMParser,h=e.trustedTypes,m=s.prototype,g=jc(m,"cloneNode"),v=jc(m,"nextSibling"),y=jc(m,"childNodes"),N=jc(m,"parentNode");if(typeof i=="function"){var b=o.createElement("template");b.content&&b.content.ownerDocument&&(o=b.content.ownerDocument)}var M=Dwe(h,r),k=M?M.createHTML(""):"",w=o,C=w.implementation,E=w.createNodeIterator,A=w.createDocumentFragment,O=w.getElementsByTagName,_=r.importNode,j={};try{j=ma(o).documentMode?o.documentMode:{}}catch{}var R={};t.isSupported=typeof N=="function"&&C&&C.createHTMLDocument!==void 0&&j!==9;var P=ywe,$=Mwe,V=bwe,D=wwe,x=Nwe,S=xwe,L=Cwe,B=kwe,F=null,T=qe({},[].concat(kr(V3),kr(Ap),kr(Op),kr(zp),kr($3))),z=null,I=qe({},[].concat(kr(P3),kr(jp),kr(R3),kr(Lc))),Z=Object.seal(Object.create(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),q=null,te=null,J=!0,W=!0,ae=!1,ce=!0,ye=!1,Ae=!1,Fe=!1,_e=!1,Le=!1,Ye=!1,Ke=!1,Be=!0,et=!1,lt="user-content-",je=!0,H=!1,G={},ze=null,pe=qe({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),we=null,be=qe({},["audio","video","img","source","image","track"]),ct=null,kt=qe({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),At="http://www.w3.org/1998/Math/MathML",Ut="http://www.w3.org/2000/svg",ne="http://www.w3.org/1999/xhtml",Q=ne,oe=!1,Y=null,le=qe({},[At,Ut,ne],_p),Ne,Ue=["application/xhtml+xml","text/html"],ut="text/html",rt,Ct=null,qt=o.createElement("form"),cn=function(U){return U instanceof RegExp||U instanceof Function},_t=function(U){Ct&&Ct===U||((!U||Fo(U)!=="object")&&(U={}),U=ma(U),Ne=Ue.indexOf(U.PARSER_MEDIA_TYPE)===-1?Ne=ut:Ne=U.PARSER_MEDIA_TYPE,rt=Ne==="application/xhtml+xml"?_p:tu,F="ALLOWED_TAGS"in U?qe({},U.ALLOWED_TAGS,rt):T,z="ALLOWED_ATTR"in U?qe({},U.ALLOWED_ATTR,rt):I,Y="ALLOWED_NAMESPACES"in U?qe({},U.ALLOWED_NAMESPACES,_p):le,ct="ADD_URI_SAFE_ATTR"in U?qe(ma(kt),U.ADD_URI_SAFE_ATTR,rt):kt,we="ADD_DATA_URI_TAGS"in U?qe(ma(be),U.ADD_DATA_URI_TAGS,rt):be,ze="FORBID_CONTENTS"in U?qe({},U.FORBID_CONTENTS,rt):pe,q="FORBID_TAGS"in U?qe({},U.FORBID_TAGS,rt):{},te="FORBID_ATTR"in U?qe({},U.FORBID_ATTR,rt):{},G="USE_PROFILES"in U?U.USE_PROFILES:!1,J=U.ALLOW_ARIA_ATTR!==!1,W=U.ALLOW_DATA_ATTR!==!1,ae=U.ALLOW_UNKNOWN_PROTOCOLS||!1,ce=U.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ye=U.SAFE_FOR_TEMPLATES||!1,Ae=U.WHOLE_DOCUMENT||!1,Le=U.RETURN_DOM||!1,Ye=U.RETURN_DOM_FRAGMENT||!1,Ke=U.RETURN_TRUSTED_TYPE||!1,_e=U.FORCE_BODY||!1,Be=U.SANITIZE_DOM!==!1,et=U.SANITIZE_NAMED_PROPS||!1,je=U.KEEP_CONTENT!==!1,H=U.IN_PLACE||!1,B=U.ALLOWED_URI_REGEXP||B,Q=U.NAMESPACE||ne,Z=U.CUSTOM_ELEMENT_HANDLING||{},U.CUSTOM_ELEMENT_HANDLING&&cn(U.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Z.tagNameCheck=U.CUSTOM_ELEMENT_HANDLING.tagNameCheck),U.CUSTOM_ELEMENT_HANDLING&&cn(U.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Z.attributeNameCheck=U.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),U.CUSTOM_ELEMENT_HANDLING&&typeof U.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(Z.allowCustomizedBuiltInElements=U.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ye&&(W=!1),Ye&&(Le=!0),G&&(F=qe({},kr($3)),z=[],G.html===!0&&(qe(F,V3),qe(z,P3)),G.svg===!0&&(qe(F,Ap),qe(z,jp),qe(z,Lc)),G.svgFilters===!0&&(qe(F,Op),qe(z,jp),qe(z,Lc)),G.mathMl===!0&&(qe(F,zp),qe(z,R3),qe(z,Lc))),U.ADD_TAGS&&(F===T&&(F=ma(F)),qe(F,U.ADD_TAGS,rt)),U.ADD_ATTR&&(z===I&&(z=ma(z)),qe(z,U.ADD_ATTR,rt)),U.ADD_URI_SAFE_ATTR&&qe(ct,U.ADD_URI_SAFE_ATTR,rt),U.FORBID_CONTENTS&&(ze===pe&&(ze=ma(ze)),qe(ze,U.FORBID_CONTENTS,rt)),je&&(F["#text"]=!0),Ae&&qe(F,["html","head","body"]),F.table&&(qe(F,["tbody"]),delete q.tbody),kn&&kn(U),Ct=U)},Qe=qe({},["mi","mo","mn","ms","mtext"]),se=qe({},["foreignobject","desc","title","annotation-xml"]),de=qe({},["title","style","font","a","script"]),Ce=qe({},Ap);qe(Ce,Op),qe(Ce,gwe);var Ht=qe({},zp);qe(Ht,vwe);var Jn=function(U){var ie=N(U);(!ie||!ie.tagName)&&(ie={namespaceURI:Q,tagName:"template"});var ue=tu(U.tagName),Re=tu(ie.tagName);return Y[U.namespaceURI]?U.namespaceURI===Ut?ie.namespaceURI===ne?ue==="svg":ie.namespaceURI===At?ue==="svg"&&(Re==="annotation-xml"||Qe[Re]):!!Ce[ue]:U.namespaceURI===At?ie.namespaceURI===ne?ue==="math":ie.namespaceURI===Ut?ue==="math"&&se[Re]:!!Ht[ue]:U.namespaceURI===ne?ie.namespaceURI===Ut&&!se[Re]||ie.namespaceURI===At&&!Qe[Re]?!1:!Ht[ue]&&(de[ue]||!Ce[ue]):!!(Ne==="application/xhtml+xml"&&Y[U.namespaceURI]):!1},Ot=function(U){Dl(t.removed,{element:U});try{U.parentNode.removeChild(U)}catch{try{U.outerHTML=k}catch{U.remove()}}},To=function(U,ie){try{Dl(t.removed,{attribute:ie.getAttributeNode(U),from:ie})}catch{Dl(t.removed,{attribute:null,from:ie})}if(ie.removeAttribute(U),U==="is"&&!z[U])if(Le||Ye)try{Ot(ie)}catch{}else try{ie.setAttribute(U,"")}catch{}},Pr=function(U){var ie,ue;if(_e)U="<remove></remove>"+U;else{var Re=fwe(U,/^[\r\n\t ]+/);ue=Re&&Re[0]}Ne==="application/xhtml+xml"&&Q===ne&&(U='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+U+"</body></html>");var ot=M?M.createHTML(U):U;if(Q===ne)try{ie=new p().parseFromString(ot,Ne)}catch{}if(!ie||!ie.documentElement){ie=C.createDocument(Q,"template",null);try{ie.documentElement.innerHTML=oe?k:ot}catch{}}var pt=ie.body||ie.documentElement;return U&&ue&&pt.insertBefore(o.createTextNode(ue),pt.childNodes[0]||null),Q===ne?O.call(ie,Ae?"html":"body")[0]:Ae?ie.documentElement:pt},da=function(U){return E.call(U.ownerDocument||U,U,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT,null,!1)},yr=function(U){return U instanceof f&&(typeof U.nodeName!="string"||typeof U.textContent!="string"||typeof U.removeChild!="function"||!(U.attributes instanceof d)||typeof U.removeAttribute!="function"||typeof U.setAttribute!="function"||typeof U.namespaceURI!="string"||typeof U.insertBefore!="function"||typeof U.hasChildNodes!="function")},lo=function(U){return Fo(l)==="object"?U instanceof l:U&&Fo(U)==="object"&&typeof U.nodeType=="number"&&typeof U.nodeName=="string"},Bn=function(U,ie,ue){R[U]&&dwe(R[U],function(Re){Re.call(t,ie,ue,Ct)})},ei=function(U){var ie;if(Bn("beforeSanitizeElements",U,null),yr(U)||Mn(/[\u0080-\uFFFF]/,U.nodeName))return Ot(U),!0;var ue=rt(U.nodeName);if(Bn("uponSanitizeElement",U,{tagName:ue,allowedTags:F}),U.hasChildNodes()&&!lo(U.firstElementChild)&&(!lo(U.content)||!lo(U.content.firstElementChild))&&Mn(/<[/\w]/g,U.innerHTML)&&Mn(/<[/\w]/g,U.textContent)||ue==="select"&&Mn(/<template/i,U.innerHTML))return Ot(U),!0;if(!F[ue]||q[ue]){if(!q[ue]&&ni(ue)&&(Z.tagNameCheck instanceof RegExp&&Mn(Z.tagNameCheck,ue)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(ue)))return!1;if(je&&!ze[ue]){var Re=N(U)||U.parentNode,ot=y(U)||U.childNodes;if(ot&&Re)for(var pt=ot.length,mt=pt-1;mt>=0;--mt)Re.insertBefore(g(ot[mt],!0),v(U))}return Ot(U),!0}return U instanceof s&&!Jn(U)||(ue==="noscript"||ue==="noembed"||ue==="noframes")&&Mn(/<\/no(script|embed|frames)/i,U.innerHTML)?(Ot(U),!0):(ye&&U.nodeType===3&&(ie=U.textContent,ie=wr(ie,P," "),ie=wr(ie,$," "),ie=wr(ie,V," "),U.textContent!==ie&&(Dl(t.removed,{element:U.cloneNode()}),U.textContent=ie)),Bn("afterSanitizeElements",U,null),!1)},ti=function(U,ie,ue){if(Be&&(ie==="id"||ie==="name")&&(ue in o||ue in qt))return!1;if(!(W&&!te[ie]&&Mn(D,ie))){if(!(J&&Mn(x,ie))){if(!z[ie]||te[ie]){if(!(ni(U)&&(Z.tagNameCheck instanceof RegExp&&Mn(Z.tagNameCheck,U)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(U))&&(Z.attributeNameCheck instanceof RegExp&&Mn(Z.attributeNameCheck,ie)||Z.attributeNameCheck instanceof Function&&Z.attributeNameCheck(ie))||ie==="is"&&Z.allowCustomizedBuiltInElements&&(Z.tagNameCheck instanceof RegExp&&Mn(Z.tagNameCheck,ue)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(ue))))return!1}else if(!ct[ie]){if(!Mn(B,wr(ue,L,""))){if(!((ie==="src"||ie==="xlink:href"||ie==="href")&&U!=="script"&&pwe(ue,"data:")===0&&we[U])){if(!(ae&&!Mn(S,wr(ue,L,"")))){if(ue)return!1}}}}}}return!0},ni=function(U){return U.indexOf("-")>0},Rr=function(U){var ie,ue,Re,ot;Bn("beforeSanitizeAttributes",U,null);var pt=U.attributes;if(pt){var mt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:z};for(ot=pt.length;ot--;){ie=pt[ot];var Mr=ie,Et=Mr.name,ee=Mr.namespaceURI;if(ue=Et==="value"?ie.value:mwe(ie.value),Re=rt(Et),mt.attrName=Re,mt.attrValue=ue,mt.keepAttr=!0,mt.forceKeepAttr=void 0,Bn("uponSanitizeAttribute",U,mt),ue=mt.attrValue,!mt.forceKeepAttr&&(To(Et,U),!!mt.keepAttr)){if(!ce&&Mn(/\/>/i,ue)){To(Et,U);continue}ye&&(ue=wr(ue,P," "),ue=wr(ue,$," "),ue=wr(ue,V," "));var me=rt(U.nodeName);if(ti(me,Re,ue)){if(et&&(Re==="id"||Re==="name")&&(To(Et,U),ue=lt+ue),M&&Fo(h)==="object"&&typeof h.getAttributeType=="function"&&!ee)switch(h.getAttributeType(me,Re)){case"TrustedHTML":{ue=M.createHTML(ue);break}case"TrustedScriptURL":{ue=M.createScriptURL(ue);break}}try{ee?U.setAttributeNS(ee,Et,ue):U.setAttribute(Et,ue),B3(t.removed)}catch{}}}}Bn("afterSanitizeAttributes",U,null)}},X=function re(U){var ie,ue=da(U);for(Bn("beforeSanitizeShadowDOM",U,null);ie=ue.nextNode();)Bn("uponSanitizeShadowNode",ie,null),!ei(ie)&&(ie.content instanceof a&&re(ie.content),Rr(ie));Bn("afterSanitizeShadowDOM",U,null)};return t.sanitize=function(re){var U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ie,ue,Re,ot,pt;if(oe=!re,oe&&(re="<!-->"),typeof re!="string"&&!lo(re))if(typeof re.toString=="function"){if(re=re.toString(),typeof re!="string")throw Ip("dirty is not a string, aborting")}else throw Ip("toString is not a function");if(!t.isSupported){if(Fo(e.toStaticHTML)==="object"||typeof e.toStaticHTML=="function"){if(typeof re=="string")return e.toStaticHTML(re);if(lo(re))return e.toStaticHTML(re.outerHTML)}return re}if(Fe||_t(U),t.removed=[],typeof re=="string"&&(H=!1),H){if(re.nodeName){var mt=rt(re.nodeName);if(!F[mt]||q[mt])throw Ip("root node is forbidden and cannot be sanitized in-place")}}else if(re instanceof l)ie=Pr("<!---->"),ue=ie.ownerDocument.importNode(re,!0),ue.nodeType===1&&ue.nodeName==="BODY"||ue.nodeName==="HTML"?ie=ue:ie.appendChild(ue);else{if(!Le&&!ye&&!Ae&&re.indexOf("<")===-1)return M&&Ke?M.createHTML(re):re;if(ie=Pr(re),!ie)return Le?null:Ke?k:""}ie&&_e&&Ot(ie.firstChild);for(var Mr=da(H?re:ie);Re=Mr.nextNode();)Re.nodeType===3&&Re===ot||ei(Re)||(Re.content instanceof a&&X(Re.content),Rr(Re),ot=Re);if(ot=null,H)return re;if(Le){if(Ye)for(pt=A.call(ie.ownerDocument);ie.firstChild;)pt.appendChild(ie.firstChild);else pt=ie;return(z.shadowroot||z.shadowrootmod)&&(pt=_.call(r,pt,!0)),pt}var Et=Ae?ie.outerHTML:ie.innerHTML;return Ae&&F["!doctype"]&&ie.ownerDocument&&ie.ownerDocument.doctype&&ie.ownerDocument.doctype.name&&Mn(Ewe,ie.ownerDocument.doctype.name)&&(Et="<!DOCTYPE "+ie.ownerDocument.doctype.name+`>
|
|
162
|
+
`+Et),ye&&(Et=wr(Et,P," "),Et=wr(Et,$," "),Et=wr(Et,V," ")),M&&Ke?M.createHTML(Et):Et},t.setConfig=function(re){_t(re),Fe=!0},t.clearConfig=function(){Ct=null,Fe=!1},t.isValidAttribute=function(re,U,ie){Ct||_t({});var ue=rt(re),Re=rt(U);return ti(ue,Re,ie)},t.addHook=function(re,U){typeof U=="function"&&(R[re]=R[re]||[],Dl(R[re],U))},t.removeHook=function(re){if(R[re])return B3(R[re])},t.removeHooks=function(re){R[re]&&(R[re]=[])},t.removeAllHooks=function(){R={}},t}var Swe=UN();const _we="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTciIGhlaWdodD0iMTAiIHZpZXdCb3g9IjAgMCAxNyAxMCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTcuMjM3MjQgMC44MzMyNTJDNy41NjcyNiAwLjgzMzI1MiA3LjgyODg3IDAuOTM5OTQgOC4wMjIwNSAxLjE1MzMyQzguMjIzMjggMS4zNTgxNiA4LjMyMzkgMS42MzU1NSA4LjMyMzkgMS45ODU0OVY4LjgzNDg4QzguMzIzOSA5LjE4NDgyIDguMjIzMjggOS40NjY0OCA4LjAyMjA1IDkuNjc5ODVDNy44Mjg4NyA5Ljg5MzIzIDcuNTY3MjYgOS45OTk5MiA3LjIzNzI0IDkuOTk5OTJDNi45MDcyMiA5Ljk5OTkyIDYuNjQxNiA5Ljg5NzUgNi40NDAzNyA5LjY5MjY2QzYuMjQ3MTggOS40NzkyOCA2LjE1MDU5IDkuMTkzMzUgNi4xNTA1OSA4LjgzNDg4VjYuMjc0MzZIMi42NzMzVjguODM0ODhDMi42NzMzIDkuMTg0ODIgMi41NzI2OSA5LjQ2NjQ4IDIuMzcxNDYgOS42Nzk4NUMyLjE3ODI3IDkuODkzMjMgMS45MTY2NyA5Ljk5OTkyIDEuNTg2NjUgOS45OTk5MkMxLjI1NjYzIDkuOTk5OTIgMC45OTEwMDYgOS44OTc1IDAuNzg5Nzc0IDkuNjkyNjZDMC41OTY1OTEgOS40NzkyOCAwLjUgOS4xOTMzNSAwLjUgOC44MzQ4OFYxLjk4NTQ5QzAuNSAxLjYzNTU1IDAuNTk2NTkxIDEuMzU4MTYgMC43ODk3Nz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2NyAwLjI2MzI3OCAwLjY1MDYxOSAwLjQ1NjgyNyAwLjQ1NzA3MUMwLjY1MDM3NSAwLjI2MzUyMiAwLjg0MzkyMyAwLjE2Njc0OCAxLjEzNDI1IDAuMTY2NzQ4QzEuNDI0NTcgMC4xNjY3NDggMS42MTgxMiAwLjI2MzUyMiAxLjgxMTY3IDAuNDU3MDcxTDExLjI5NTUgMTAuMjMxM0MxMS40ODkxIDEwLjQyNDggMTEuNTg1OSAxMC42MTg0IDExLjU4NTkgMTAuOTA4N0MxMS41ODU5IDExLjE5OSAxMS40ODkxIDExLjM5MjYgMTEuMjk1NSAxMS41ODYxQzExLjEwMiAxMS43Nzk3IDEwLjkwODQgMTEuODc2NCAxMC42MTgxIDExLjg3NjRaIiBmaWxsPSIjNDM0RTVCIi8+Cjwvc3ZnPgo=";const Owe={name:"LTextEditor",props:{modelValue:String,lang:{type:String,default(){return pn()}},validVariables:{type:Array,default:()=>[]},isMailMergeMode:{type:Boolean,default:!1},readOnly:{type:Boolean,default:!1},transparent:{type:Boolean,default:!1}},emits:["update:modelValue","useMarkUp","focus","input"],components:{EditorContent:d6e,LinkBox:W8e,BubbleMenu:c6e,FloatingLink:Z8e},data(){return{editor:null,markUps:[{name:"bold",tooltip:this.$tds("bold",this.lang),icon:"uil-bold"},{name:"italic",tooltip:this.$tds("italic",this.lang),icon:"uil-italic"},{name:"underline",tooltip:this.$tds("underline",this.lang),icon:"uil-underline"},{name:"heading",tooltip:this.$tds("title",this.lang),icon:_we},{name:"bulletList",tooltip:this.$tds("bullet-list",this.lang),icon:"uil-list-ul"},{name:"orderedList",tooltip:this.$tds("numbered-list",this.lang),icon:"uil-list-ol-alt"},{name:"link",tooltip:this.$tds("link",this.lang),icon:"uil-link-alt"},{name:"blockquote",tooltip:this.$tds("blockquote",this.lang),icon:Iwe},{name:"removeFormatting",tooltip:this.$tds("remove-formatting",this.lang),icon:Awe}],showLinkBox:!1,isEditorFocused:null,isInternalUpdate:!1,tooltipDelay:125}},methods:{focusEditor(){var e;(e=this.editor)==null||e.commands.focus()},isUnicon(e){return e.startsWith("uil-")},markUpText(e){if(e==="link"){this.toggleLinkBox();return}this.editor.chain().focus().setMarkUp(e).run()},toggleLinkBox(){this.showLinkBox=!this.showLinkBox},closeLinkBox(){this.editor.commands.focus(),this.toggleLinkBox()},markUpLink(e){this.currentTextSelection||this.previousURL?this.editor.chain().focus().extendMarkRange("link").setLink({href:e.url,target:"_blank"}).run():this.editor.commands.insertContent(X0.link(e.insertedText))},markOffLink(){this.editor.chain().focus().extendMarkRange("link").unsetLink().run()},hasSomeMarkUpActive(){const e=this.editor.getJSON().content,t=this.markUps.map(i=>i.name),o=e.map(i=>i.type).some(i=>t.includes(i)),a=e.some(i=>{if(i.hasOwnProperty("content"))return i.content.some(l=>l.hasOwnProperty("marks"))});return o||a},addSpaceToFinalParagraphTag(e){return e.replace(/<\/p>/g," </p>")}},watch:{validVariables:{handler(e){if(this.editor){this.editor.extensionManager.extensions.forEach(o=>{o.name==="templateHighlight"&&(o.options.validVariables=e)});const{state:t}=this.editor,r=t.tr;r.setMeta("forceUpdate",!0),this.editor.view.dispatch(r)}},deep:!0},isMailMergeMode(e){if(this.editor){this.editor.extensionManager.extensions.forEach(o=>{o.name==="templateHighlight"&&(o.options.isMailMergeMode=e)});const{state:t}=this.editor,r=t.tr;r.setMeta("forceUpdate",!0),this.editor.view.dispatch(r)}},modelValue(e){if(!this.editor||this.isInternalUpdate)return;const t=this.editor.getHTML();e!==t&&this.editor.commands.setContent(e,!1)}},computed:{isEditorEmpty(){var e;return((e=this.editor)==null?void 0:e.isEmpty)??!0},previousURL(){return this.editor.getAttributes("link").href},showFloatingLink(){return this.editor.isActive("link")},finalText(){const e=this.editor.getHTML(),t=this.addSpaceToFinalParagraphTag(e),r=X0.link(t);return Swe.sanitize(ewe(r),{ADD_ATTR:["target"]})},currentTextSelection(){const{view:e,state:t}=this.editor,{from:r,to:o}=e.state.selection;return t.doc.textBetween(r,o,"")},arrowXPosition(){const t=this.$refs.link[0].$el;return{left:`${t.offsetLeft+(t.offsetWidth-16.8)/2}px`}},linkBoxPosition(){const t=this.$refs.texteditor.$el.offsetWidth,r=this.$refs.link[0].$el;let o;return t>500?o=`${r.offsetLeft+r.offsetWidth/2-456*.75}px`:o="1rem",{left:o}},placeholderText(){return this.$tds("text-editor-placeholder",this.lang)}},beforeMount(){this.editor=new u6e({extensions:[f6e,p6e,m6e,y6e,h6e.configure({validVariables:this.validVariables,isMailMergeMode:this.isMailMergeMode}),x6e,_6e,A6e,z6e,B6e,P6e,U6e,pbe,hbe.configure({placeholder:this.placeholderText}),gbe,Ebe],content:this.modelValue,autofocus:!1,editable:!this.readOnly,onUpdate:()=>{this.isInternalUpdate=!0,this.$emit("input",this.finalText),this.$emit("useMarkUp",this.hasSomeMarkUpActive()),this.$emit("update:modelValue",this.finalText),this.$nextTick(()=>{this.isInternalUpdate=!1})},onFocus:()=>{this.isEditorFocused=!0,this.$emit("focus",!0)},onBlur:()=>{this.isEditorFocused=!1}})},beforeUnmount(){this.editor.destroy()}},zwe={class:"editor-content-wrapper"},jwe={key:1,class:"wrapper-editor-features"},Lwe={key:0},Bwe={class:"wrapper-scroll"},Vwe={class:"wrapper-buttons py-2 pl-3 pr-4 l-d-flex row l-d-justify-content-start l-d-align-item-center"},$we=["alt","src"];function Pwe(e,t,r,o,a,i){const l=n.resolveComponent("FloatingLink"),s=n.resolveComponent("BubbleMenu"),c=n.resolveComponent("EditorContent"),u=n.resolveComponent("l-icon"),d=n.resolveComponent("l-button"),f=n.resolveComponent("l-tooltip"),p=n.resolveComponent("LinkBox");return n.openBlock(),n.createElementBlock("section",{class:n.normalizeClass(["wrapper-text-editor",{"has-custom-placeholder":e.$slots["empty-content"],"has-custom-content":e.$slots["custom-content"],"is-transparent":r.transparent}])},[i.showFloatingLink?(n.openBlock(),n.createBlock(s,{key:0,editor:a.editor,tippyOptions:{zIndex:1e3},shouldShow:({editor:h})=>h.isActive("link")},{default:n.withCtx(()=>[n.createVNode(l,{"data-link":a.editor.getAttributes("link").href,onEdit:t[0]||(t[0]=h=>i.toggleLinkBox()),onRemove:t[1]||(t[1]=h=>i.markOffLink())},null,8,["data-link"])]),_:1},8,["editor","shouldShow"])):n.createCommentVNode("",!0),n.createElementVNode("div",zwe,[n.createVNode(c,{editor:a.editor,ref:"texteditor"},null,8,["editor"]),e.$slots["empty-content"]&&i.isEditorEmpty?(n.openBlock(),n.createElementBlock("div",{key:0,class:"editor-custom-placeholder",role:"button",tabindex:"0",onClick:t[2]||(t[2]=(...h)=>i.focusEditor&&i.focusEditor(...h)),onKeydown:[t[3]||(t[3]=n.withKeys((...h)=>i.focusEditor&&i.focusEditor(...h),["enter"])),t[4]||(t[4]=n.withKeys(n.withModifiers((...h)=>i.focusEditor&&i.focusEditor(...h),["prevent"]),["space"]))]},[n.renderSlot(e.$slots,"empty-content",{editor:a.editor,focus:i.focusEditor},void 0,!0)],32)):n.createCommentVNode("",!0)]),r.readOnly?n.createCommentVNode("",!0):(n.openBlock(),n.createElementBlock("div",jwe,[e.$slots["custom-content"]?(n.openBlock(),n.createElementBlock("div",Lwe,[n.renderSlot(e.$slots,"custom-content",{editor:a.editor},void 0,!0)])):n.createCommentVNode("",!0),n.createElementVNode("div",Bwe,[n.createElementVNode("div",Vwe,[n.renderSlot(e.$slots,"custom-buttons",{editor:a.editor},void 0,!0),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(a.markUps,h=>(n.openBlock(),n.createBlock(f,{key:h.name,content:h.tooltip,class:"item","open-delay":a.tooltipDelay},{default:n.withCtx(()=>[n.createVNode(d,{onClick:m=>i.markUpText(h.name),class:n.normalizeClass(["button-text-editor",{"is-active":a.editor.isActive(h.name)}]),size:"small",square:"",ref_for:!0,ref:h.name},{default:n.withCtx(()=>[i.isUnicon(h.icon)?(n.openBlock(),n.createBlock(u,{key:0,size:"24",icon:h.icon},null,8,["icon"])):(n.openBlock(),n.createElementBlock("img",{key:1,alt:h.name,src:h.icon,class:n.normalizeClass({"icon-active":a.editor.isActive(h.name)})},null,10,$we))]),_:2},1032,["onClick","class"])]),_:2},1032,["content","open-delay"]))),128))])]),a.showLinkBox?(n.openBlock(),n.createElementBlock(n.Fragment,{key:1},[n.createElementVNode("span",{class:"link-box-arrow",style:n.normalizeStyle([i.arrowXPosition])},null,4),n.createVNode(p,{class:"link-box-position",onClose:t[5]||(t[5]=h=>i.closeLinkBox()),onSetLink:t[6]||(t[6]=h=>i.markUpLink(h)),previousURL:i.previousURL,style:n.normalizeStyle([i.linkBoxPosition]),lang:r.lang},null,8,["previousURL","style","lang"])],64)):n.createCommentVNode("",!0)]))],2)}const Rwe=xe(Owe,[["render",Pwe],["__scopeId","data-v-f21a150c"]]),Fwe=Object.freeze(Object.defineProperty({__proto__:null,default:Rwe},Symbol.toStringTag,{value:"Module"}));const ki=48,HN=5,Uwe=ki*HN,Hwe=ki*Math.floor(HN/2),Ywe={tagName:"l-time-scroll",name:"LTimeScroll",props:{modelValue:{type:Object,default:()=>({hours:0,minutes:0})},padZero:{type:Boolean,default:!0}},emits:["update:modelValue"],data(){return{hoursScroll:0,minutesScroll:0,hoursSnapTimer:null,minutesSnapTimer:null}},computed:{ITEM_HEIGHT(){return ki},CONTAINER_HEIGHT(){return Uwe},SPACER_HEIGHT(){return Hwe},hourItems(){return Array.from({length:24},(e,t)=>t)},minuteItems(){return Array.from({length:60},(e,t)=>t)}},watch:{"modelValue.hours"(e){this.scrollToValue(this.$refs.hoursContainer,e)},"modelValue.minutes"(e){this.scrollToValue(this.$refs.minutesContainer,e)}},mounted(){this.$nextTick(()=>{this.scrollToValue(this.$refs.hoursContainer,this.modelValue.hours,!1),this.scrollToValue(this.$refs.minutesContainer,this.modelValue.minutes,!1),requestAnimationFrame(()=>{this.hoursScroll=this.$refs.hoursContainer?this.$refs.hoursContainer.scrollTop:0,this.minutesScroll=this.$refs.minutesContainer?this.$refs.minutesContainer.scrollTop:0})})},methods:{format(e){return this.padZero?String(e).padStart(2,"0"):String(e)},getItemStyle(e,t){const r=t/ki,o=Math.abs(e-r);return{opacity:Math.max(.15,1-o*.35),fontSize:`${Math.max(14,22-o*4)}px`,fontWeight:o<.5?"700":"400",color:o<.5?"#111827":"#9ca3af",transition:"font-size 0.1s ease, font-weight 0.1s ease"}},handleScroll(e){const t=e==="hours"?this.$refs.hoursContainer:this.$refs.minutesContainer;if(!t)return;e==="hours"?this.hoursScroll=t.scrollTop:this.minutesScroll=t.scrollTop;const r=e+"SnapTimer";this[r]&&clearTimeout(this[r]),this[r]=setTimeout(()=>{if(!t)return;const o=e==="hours"?this.hourItems:this.minuteItems,a=Math.round(t.scrollTop/ki),i=Math.max(0,Math.min(o.length-1,a)),l=e==="hours"?this.modelValue.hours:this.modelValue.minutes;o[i]!==l&&this.$emit("update:modelValue",{...this.modelValue,[e]:o[i]})},80)},scrollToValue(e,t,r=!0){if(!e)return;const o=t*ki;Math.abs(e.scrollTop-o)<2||e.scrollTo({top:o,behavior:r?"smooth":"instant"})},selectItem(e,t){this.$emit("update:modelValue",{...this.modelValue,[e]:t})}}},Qwe={class:"picker-wheels"},Wwe={class:"wheels-flex"},qwe=["onClick"],Gwe=["onClick"];function Kwe(e,t,r,o,a,i){return n.openBlock(),n.createElementBlock("div",Qwe,[t[3]||(t[3]=n.createElementVNode("div",{class:"highlight-row"},null,-1)),n.createElementVNode("div",Wwe,[n.createElementVNode("div",{ref:"hoursContainer",class:"wheel-container wheel-column",style:n.normalizeStyle({height:i.CONTAINER_HEIGHT+"px",scrollSnapType:"y mandatory"}),onScroll:t[0]||(t[0]=l=>i.handleScroll("hours"))},[n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.hourItems,(l,s)=>(n.openBlock(),n.createElementBlock("div",{key:"h"+l,class:"wheel-item",style:n.normalizeStyle({height:i.ITEM_HEIGHT+"px",lineHeight:i.ITEM_HEIGHT+"px",scrollSnapAlign:"center",...i.getItemStyle(s,a.hoursScroll)}),onClick:c=>i.selectItem("hours",l)},n.toDisplayString(i.format(l)),13,qwe))),128)),n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4)],36),t[2]||(t[2]=n.createElementVNode("span",{class:"colon"},":",-1)),n.createElementVNode("div",{ref:"minutesContainer",class:"wheel-container wheel-column",style:n.normalizeStyle({height:i.CONTAINER_HEIGHT+"px",scrollSnapType:"y mandatory"}),onScroll:t[1]||(t[1]=l=>i.handleScroll("minutes"))},[n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4),(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(i.minuteItems,(l,s)=>(n.openBlock(),n.createElementBlock("div",{key:"m"+l,class:"wheel-item",style:n.normalizeStyle({height:i.ITEM_HEIGHT+"px",lineHeight:i.ITEM_HEIGHT+"px",scrollSnapAlign:"center",...i.getItemStyle(s,a.minutesScroll)}),onClick:c=>i.selectItem("minutes",l)},n.toDisplayString(i.format(l)),13,Gwe))),128)),n.createElementVNode("div",{style:n.normalizeStyle({height:i.SPACER_HEIGHT+"px",flexShrink:0})},null,4)],36)])])}const Jwe=xe(Ywe,[["render",Kwe],["__scopeId","data-v-f64b65e8"]]),Zwe=Object.freeze(Object.defineProperty({__proto__:null,default:Jwe},Symbol.toStringTag,{value:"Module"}));const Xwe=/^(\d{2}):(\d{2})$/;function Sl(e,{required:t=!1}={}){if(e===""||e===null||e===void 0)return{valid:!t,minutes:null,present:!1};if(typeof e!="string")return{valid:!1,minutes:null,present:!0};const r=e.match(Xwe);if(!r)return{valid:!1,minutes:null,present:!0};const o=Number(r[1]),a=Number(r[2]);return o>23||a>59?{valid:!1,minutes:null,present:!0}:{valid:!0,minutes:o*60+a,present:!0}}function F3(e){const t=String(Math.floor(e/60)).padStart(2,"0"),r=String(e%60).padStart(2,"0");return`${t}:${r}`}function eNe({start:e,end:t,step:r,minTime:o,maxTime:a,includeEndTime:i}){var m;const l=[],s=Sl(e,{required:!0}),c=Sl(t,{required:!0}),u=Sl(r,{required:!0}),d=Sl(o),f=Sl(a);if(!s.valid||!c.valid||!u.valid||!d.valid||!f.valid||u.minutes<=0||s.minutes>c.minutes||d.present&&f.present&&d.minutes>f.minutes)return l;const p=g=>{const v=F3(g);l.push({value:v,label:v,disabled:d.present&&g<=d.minutes||f.present&&g>=f.minutes})};let h=s.minutes;for(;h<=c.minutes;)p(h),h+=u.minutes;return i&&((m=l[l.length-1])==null?void 0:m.value)!==F3(c.minutes)&&p(c.minutes),l}const tNe={name:"LTimeSelect",tagName:"l-time-select",inheritAttrs:!1,components:{ElIcon:ke,ElSelectV2:NX},props:{modelValue:{type:String,default:""},start:{type:String,default:"00:00"},end:{type:String,default:"23:59"},step:{type:String,default:"00:30"},minTime:{type:String,default:""},maxTime:{type:String,default:""},includeEndTime:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},prefixIcon:{type:[String,Object],default:()=>Rm},clearIcon:{type:[String,Object],default:()=>Eo},hideIcon:{type:Boolean,default:!1},popperClass:{type:String,default:"l-time-picker-popper"},lang:{type:String,default:""},placeholder:{type:String,default(e){return Fl("time",e.lang||pn())}},clearable:{type:Boolean,default:!1}},emits:["update:modelValue","change"],mounted(){var t;const e=(t=this.$refs.timeSelect)==null?void 0:t.inputRef;e&&(this._timeKeydownHandler=r=>{if(r.key>="0"&&r.key<="9"){r.preventDefault();const o=e.value.replace(/\D/g,"");if(o.length>=4)return;const a=this.formatTimeInput(o+r.key);e.value=a,e.dispatchEvent(new Event("input",{bubbles:!0}))}else if(r.key==="Backspace"){r.preventDefault();const o=e.value.replace(/\D/g,"");if(!o.length)return;const a=this.formatTimeInput(o.slice(0,-1));e.value=a,e.dispatchEvent(new Event("input",{bubbles:!0}))}},this._timePasteHandler=r=>{r.preventDefault();const a=r.clipboardData.getData("text").replace(/\D/g,"").slice(0,4);e.value=this.formatTimeInput(a),e.dispatchEvent(new Event("input",{bubbles:!0}))},e.addEventListener("keydown",this._timeKeydownHandler,!0),e.addEventListener("paste",this._timePasteHandler,!0))},beforeUnmount(){var t;const e=(t=this.$refs.timeSelect)==null?void 0:t.inputRef;e&&(this._timeKeydownHandler&&e.removeEventListener("keydown",this._timeKeydownHandler,!0),this._timePasteHandler&&e.removeEventListener("paste",this._timePasteHandler,!0))},methods:{formatTimeInput(e){const t=e.replace(/\D/g,"").slice(0,4);return t.length<2?t:t.slice(0,2)+":"+t.slice(2)}},computed:{proxyValue:{get(){return this.modelValue},set(e){this.$emit("update:modelValue",e)}},timeOptions(){return eNe({start:this.start,end:this.end,step:this.step,minTime:this.minTime,maxTime:this.maxTime,includeEndTime:this.includeEndTime})}}},nNe={key:0,class:"l-time-select__prefix","aria-hidden":"true"};function rNe(e,t,r,o,a,i){const l=n.resolveComponent("el-icon"),s=n.resolveComponent("el-select-v2");return n.openBlock(),n.createElementBlock("div",{class:n.normalizeClass(["l-time-select-wrapper",{"hide-icon":r.hideIcon}])},[!r.hideIcon&&r.prefixIcon?(n.openBlock(),n.createElementBlock("span",nNe,[n.createVNode(l,{class:"l-time-select__prefix-icon"},{default:n.withCtx(()=>[(n.openBlock(),n.createBlock(n.resolveDynamicComponent(r.prefixIcon)))]),_:1})])):n.createCommentVNode("",!0),n.createVNode(s,{modelValue:i.proxyValue,"onUpdate:modelValue":t[0]||(t[0]=c=>i.proxyValue=c),options:i.timeOptions,"clear-icon":r.clearIcon,placeholder:r.placeholder,clearable:r.clearable,"popper-class":r.popperClass,disabled:r.disabled,filterable:"","default-first-option":"",ref:"timeSelect",class:n.normalizeClass(["l-time-select",{"has-prefix-icon":!r.hideIcon&&r.prefixIcon}]),onChange:t[1]||(t[1]=c=>e.$emit("change",c))},null,8,["modelValue","options","clear-icon","placeholder","clearable","popper-class","disabled","class"])],2)}const oNe=xe(tNe,[["render",rNe]]),aNe=Object.freeze(Object.defineProperty({__proto__:null,default:oNe},Symbol.toStringTag,{value:"Module"}));const iNe={name:"LToggleButtonGroup",props:{options:Array,modelValue:String,disabled:{type:Boolean,default:!1}},computed:{value:{get(){return this.modelValue},set(e){this.$emit("update:modelValue",e)}}},methods:{optionType(e){return this.disabled?"default":e.value===this.value?"primary":"default"},selectOption(e){this.value=e.value}}};function lNe(e,t,r,o,a,i){const l=n.resolveComponent("l-button"),s=n.resolveComponent("l-tooltip"),c=n.resolveComponent("l-button-group");return n.openBlock(),n.createBlock(c,{class:"l-toggle-button-group"},{default:n.withCtx(()=>[(n.openBlock(!0),n.createElementBlock(n.Fragment,null,n.renderList(r.options,u=>(n.openBlock(),n.createBlock(s,{effect:"dark",content:u.title,placement:"bottom",key:u.value},{default:n.withCtx(()=>[n.createVNode(l,{disabled:r.disabled,type:i.optionType(u),icon:u.icon,size:"small",plain:"",onClick:d=>i.selectOption(u)},null,8,["disabled","type","icon","onClick"])]),_:2},1032,["content"]))),128))]),_:1})}const sNe=xe(iNe,[["render",lNe]]),cNe=Object.freeze(Object.defineProperty({__proto__:null,default:sNe},Symbol.toStringTag,{value:"Module"}));const uNe={components:{ElTooltip:Ka},props:{tooltipClass:{type:String,default:"l-tooltip-popper"}}};function dNe(e,t,r,o,a,i){const l=n.resolveComponent("ElTooltip");return n.openBlock(),n.createBlock(l,n.mergeProps(e.$attrs,{"popper-class":r.tooltipClass}),{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default")]),_:3},16,["popper-class"])}const fNe=xe(uNe,[["render",dNe]]),pNe=Object.freeze(Object.defineProperty({__proto__:null,default:fNe},Symbol.toStringTag,{value:"Module"}));const mNe={name:"LTransitionExpand",methods:{enter(e){const t=getComputedStyle(e).width;e.style.width=t,e.style.position="absolute",e.style.visibility="hidden",e.style.height="auto";const r=getComputedStyle(e).height;e.style.width=null,e.style.position=null,e.style.visibility=null,e.style.height=0,getComputedStyle(e).height,requestAnimationFrame(()=>{e.style.height=r})},afterEnter(e){e.style.height="auto"},leave(e){const t=getComputedStyle(e).height;e.style.height=t,getComputedStyle(e).height,requestAnimationFrame(()=>{e.style.height=0})}}};function hNe(e,t,r,o,a,i){return n.openBlock(),n.createBlock(n.Transition,{class:"l-transition-expand",name:"expand",onEnter:i.enter,onAfterEnter:i.afterEnter,onLeave:i.leave},{default:n.withCtx(()=>[n.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["onEnter","onAfterEnter","onLeave"])}const gNe=xe(mNe,[["render",hNe],["__scopeId","data-v-00bad3ad"]]),vNe=Object.freeze(Object.defineProperty({__proto__:null,default:gNe},Symbol.toStringTag,{value:"Module"})),U3=Object.assign({"../components/LAlert/index.vue":Wee,"../components/LAttachmentChip/index.vue":ate,"../components/LBox/index.vue":cte,"../components/LBoxHeader/index.vue":pte,"../components/LButton/index.vue":yte,"../components/LCalendar/index.vue":Ite,"../components/LCarousel/index.vue":$te,"../components/LCheckbox/index.vue":Ute,"../components/LCheckboxButton/index.vue":Wte,"../components/LCheckboxGroup/index.vue":Jte,"../components/LChip/index.vue":rne,"../components/LCircularLoader/index.vue":lne,"../components/LCollapse/index.vue":dne,"../components/LCollapseItem/index.vue":hne,"../components/LDatePicker/index.vue":bne,"../components/LDialog/index.vue":xne,"../components/LFailedToLoad/index.vue":Ine,"../components/LForm/index.vue":jne,"../components/LFormItem/index.vue":$ne,"../components/LHelperBox/index.vue":Qne,"../components/LIcon/index.vue":ak,"../components/LImageViewer/index.vue":ore,"../components/LInput/index.vue":ure,"../components/LLinearProgress/index.vue":mre,"../components/LNotice/index.vue":bre,"../components/LNotification/index.vue":pk,"../components/LPresentation/index.vue":Sre,"../components/LPromptDialog/index.vue":jre,"../components/LRadio/index.vue":$re,"../components/LRadioButton/index.vue":Ure,"../components/LRadioGroup/index.vue":Wre,"../components/LRating/index.vue":Jre,"../components/LSearchBar/index.vue":Ofe,"../components/LSearchTopics/index.vue":Gme,"../components/LSelect/index.vue":Xme,"../components/LSwitch/index.vue":rhe,"../components/LTable/index.vue":u1e,"../components/LTabs/index.vue":m1e,"../components/LTargetChip/index.vue":M1e,"../components/LTargetInput/index.vue":k1e,"../components/LTextEditor/index.vue":Fwe,"../components/LTimeScroll/index.vue":Zwe,"../components/LTimeSelect/index.vue":aNe,"../components/LToggleButtonGroup/index.vue":cNe,"../components/LTooltip/index.vue":pNe,"../components/LTransitionExpand/index.vue":vNe}),yNe=(e,t="index")=>{const r=e.split("/"),o=r.pop().replace(".vue","");return o===t?r.pop():o},MNe={install(e){Object.keys(U3).forEach(t=>{const r=yNe(t);e.component(r,U3[t].default)})}};exports.Language=void 0;const C2={};C2.install=function(e,t={enabledNotify:!1}){e.config.globalProperties.$L={},e.use(M0),e.use(q3),e.use(K3),e.use(Z3),e.use(zb),exports.Language=$ee(e),e.config.globalProperties.$tds=Fl,e.use(jb),e.use(MNe),Nd.extend(KN),e.mixin({mounted(){this.__layers_addClassName()},updated(){this.__layers_addClassName()},methods:{__layers_addClassName(){var r;if(!this.__layers_addedClassName){const o=((r=this==null?void 0:this.$options)==null?void 0:r.tagName)||"";/^l-/.test(o)&&this.$el.classList&&this.$el.classList.add(o)}}}}),t.enabledNotify&&(e.config.globalProperties.$notify=function(r){const o=r.onClick&&r.onClick instanceof Function,a=[r.customClass,r.type,!r.customClass&&!r.type&&"default",o&&"cursor-pointer"];return Ba({...r,customClass:a.filter(i=>i).join(" ")})})};exports.LayersDesignSystem=C2;exports.Notification=Ba;exports.commonjsGlobal=Pt;exports.dayjs_minExports=Y3;
|