import{e as mt,r as ke,g as oe,Q as si,n as tn,aB as fi,h as le,j as ht,aC as Ci,aE as pr,o as Sn,ac as Tr,w as ze,O as Dt,p as Mi,aK as ci,ak as Ii,al as ji,i as Pr,f as gr,k as rn,m as Ar,a8 as Di,N as Bi,a7 as Fi,am as Yt,an as Ui,ar as $i,a9 as bn,as as yr,aa as mr,T as Hi,aL as zi,ab as kt,d as Vi,x as qr,aq as _n,v as di,y as Lr,I as Rr,t as zr,a3 as Vr,aM as Ki,z as Ze,K as At,C as me,B as Ae,Y as On,Z as wn,H as Xe,F as qe,D as ot,E as at,A as It,G as Kr,V as hi,aN as Wi}from"./index.f89c7e6e.js";import{d as lt,a as Cr,b as xn,Q as yt,R as Gi,c as Qi,r as Zi,t as Yi}from"./QBtn.9455f382.js";import{Q as Tt,a as vi,b as pi}from"./QToolbarTitle.4eccf591.js";import{k as Nn,w as Mr,c as Ir,T as gi,a as jr,a9 as yi,g as jt,aF as mi,aG as Xi,am as br,d as Sr,aH as Ji,Q as eo,aI as to,aJ as Wr,aK as Gr,at as no,aL as ro,aM as io,ap as oo,a7 as ao,aN as Be,aO as lo,_ as uo,v as Je,a1 as so,o as Qr,q as _r,r as Rt,C as Zr,t as fo,s as co,aP as bi,aQ as ho}from"./QTable.18dd05c1.js";import{R as Yr,Q as vo}from"./rectangle-horizontal.719c7b3b.js";import{D as po}from"./MainPage.683ca653.js";/**
 * @license lucide-vue-next v0.406.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const go=Nn("ImageIcon",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]]);/**
 * @license lucide-vue-next v0.406.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const yo=Nn("LinkIcon",[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]]);/**
 * @license lucide-vue-next v0.406.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const mo=Nn("PaletteIcon",[["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["path",{d:"M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10c.926 0 1.648-.746 1.648-1.688 0-.437-.18-.835-.437-1.125-.29-.289-.438-.652-.438-1.125a1.64 1.64 0 0 1 1.668-1.668h1.996c3.051 0 5.555-2.503 5.555-5.554C21.965 6.012 17.461 2 12 2z",key:"12rzf8"}]]);/**
 * @license lucide-vue-next v0.406.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const _i=Nn("PencilRulerIcon",[["path",{d:"M13 7 8.7 2.7a2.41 2.41 0 0 0-3.4 0L2.7 5.3a2.41 2.41 0 0 0 0 3.4L7 13",key:"orapub"}],["path",{d:"m8 6 2-2",key:"115y1s"}],["path",{d:"m18 16 2-2",key:"ee94s4"}],["path",{d:"m17 11 4.3 4.3c.94.94.94 2.46 0 3.4l-2.6 2.6c-.94.94-2.46.94-3.4 0L11 17",key:"cfq27r"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);function en(i,R=new WeakMap){if(Object(i)!==i)return i;if(R.has(i))return R.get(i);const p=i instanceof Date?new Date(i):i instanceof RegExp?new RegExp(i.source,i.flags):i instanceof Set?new Set:i instanceof Map?new Map:typeof i.constructor!="function"?Object.create(null):i.prototype!==void 0&&typeof i.prototype.constructor=="function"?i:new i.constructor;if(typeof i.constructor=="function"&&typeof i.valueOf=="function"){const s=i.valueOf();if(Object(s)!==s){const t=new i.constructor(s);return R.set(i,t),t}}return R.set(i,p),i instanceof Set?i.forEach(s=>{p.add(en(s,R))}):i instanceof Map&&i.forEach((s,t)=>{p.set(t,en(s,R))}),Object.assign(p,...Object.keys(i).map(s=>({[s]:en(i[s],R)})))}var bo=mt({name:"QPopupEdit",props:{modelValue:{required:!0},title:String,buttons:Boolean,labelSet:String,labelCancel:String,color:{type:String,default:"primary"},validate:{type:Function,default:()=>!0},autoSave:Boolean,cover:{type:Boolean,default:!0},disable:Boolean},emits:["update:modelValue","save","cancel","beforeShow","show","beforeHide","hide"],setup(i,{slots:R,emit:p}){const{proxy:s}=ht(),{$q:t}=s,m=ke(null),O=ke(""),w=ke("");let y=!1;const _=oe(()=>si({initialValue:O.value,validate:i.validate,set:h,cancel:l,updatePosition:e},"value",()=>w.value,r=>{w.value=r}));function h(){i.validate(w.value)!==!1&&(n()===!0&&(p("save",w.value,O.value),p("update:modelValue",w.value)),u())}function l(){n()===!0&&p("cancel",w.value,O.value),u()}function e(){tn(()=>{m.value.updatePosition()})}function n(){return fi(w.value,O.value)===!1}function u(){y=!0,m.value.hide()}function f(){y=!1,O.value=en(i.modelValue),w.value=en(i.modelValue),p("beforeShow")}function c(){p("show")}function a(){y===!1&&n()===!0&&(i.autoSave===!0&&i.validate(w.value)===!0?(p("save",w.value,O.value),p("update:modelValue",w.value)):p("cancel",w.value,O.value)),p("beforeHide")}function o(){p("hide")}function d(){const r=R.default!==void 0?[].concat(R.default(_.value)):[];return i.title&&r.unshift(le("div",{class:"q-dialog__title q-mt-sm q-mb-sm"},i.title)),i.buttons===!0&&r.push(le("div",{class:"q-popup-edit__buttons row justify-center no-wrap"},[le(lt,{flat:!0,color:i.color,label:i.labelCancel||t.lang.label.cancel,onClick:l}),le(lt,{flat:!0,color:i.color,label:i.labelSet||t.lang.label.set,onClick:h})])),r}return Object.assign(s,{set:h,cancel:l,show(r){var g;(g=m.value)==null||g.show(r)},hide(r){var g;(g=m.value)==null||g.hide(r)},updatePosition:e}),()=>{if(i.disable!==!0)return le(Mr,{ref:m,class:"q-popup-edit",cover:i.cover,onBeforeShow:f,onShow:c,onBeforeHide:a,onHide:o,onEscapeKey:l},d)}}});const Xr="q-slider__marker-labels",_o=i=>({value:i}),Oo=({marker:i})=>le("div",{key:i.value,style:i.style,class:i.classes},i.label),Oi=[34,37,40,33,39,38],wo={...jr,...yi,min:{type:Number,default:0},max:{type:Number,default:100},innerMin:Number,innerMax:Number,step:{type:Number,default:1,validator:i=>i>=0},snap:Boolean,vertical:Boolean,reverse:Boolean,color:String,markerLabelsClass:String,label:Boolean,labelColor:String,labelTextColor:String,labelAlways:Boolean,switchLabelSide:Boolean,markers:[Boolean,Number],markerLabels:[Boolean,Array,Object,Function],switchMarkerLabelsSide:Boolean,trackImg:String,trackColor:String,innerTrackImg:String,innerTrackColor:String,selectionColor:String,selectionImg:String,thumbSize:{type:String,default:"20px"},trackSize:{type:String,default:"4px"},disable:Boolean,readonly:Boolean,dense:Boolean,tabindex:[String,Number],thumbColor:String,thumbPath:{type:String,default:"M 4, 10 a 6,6 0 1,0 12,0 a 6,6 0 1,0 -12,0"}},Eo=["pan","update:modelValue","change"];function ko({updateValue:i,updatePosition:R,getDragging:p,formAttrs:s}){const{props:t,emit:m,slots:O,proxy:{$q:w}}=ht(),y=Ir(t,w),_=mi(s),h=ke(!1),l=ke(!1),e=ke(!1),n=ke(!1),u=oe(()=>t.vertical===!0?"--v":"--h"),f=oe(()=>"-"+(t.switchLabelSide===!0?"switched":"standard")),c=oe(()=>t.vertical===!0?t.reverse===!0:t.reverse!==(w.lang.rtl===!0)),a=oe(()=>isNaN(t.innerMin)===!0||t.innerMin<t.min?t.min:t.innerMin),o=oe(()=>isNaN(t.innerMax)===!0||t.innerMax>t.max?t.max:t.innerMax),d=oe(()=>t.disable!==!0&&t.readonly!==!0&&a.value<o.value),r=oe(()=>{if(t.step===0)return ge=>ge;const ne=(String(t.step).trim().split(".")[1]||"").length;return ge=>parseFloat(ge.toFixed(ne))}),g=oe(()=>t.step===0?1:t.step),S=oe(()=>d.value===!0?t.tabindex||0:-1),k=oe(()=>t.max-t.min),A=oe(()=>o.value-a.value),M=oe(()=>fe(a.value)),T=oe(()=>fe(o.value)),b=oe(()=>t.vertical===!0?c.value===!0?"bottom":"top":c.value===!0?"right":"left"),E=oe(()=>t.vertical===!0?"height":"width"),x=oe(()=>t.vertical===!0?"width":"height"),q=oe(()=>t.vertical===!0?"vertical":"horizontal"),I=oe(()=>{const ne={role:"slider","aria-valuemin":a.value,"aria-valuemax":o.value,"aria-orientation":q.value,"data-step":t.step};return t.disable===!0?ne["aria-disabled"]="true":t.readonly===!0&&(ne["aria-readonly"]="true"),ne}),H=oe(()=>`q-slider q-slider${u.value} q-slider--${h.value===!0?"":"in"}active inline no-wrap `+(t.vertical===!0?"row":"column")+(t.disable===!0?" disabled":" q-slider--enabled"+(d.value===!0?" q-slider--editable":""))+(e.value==="both"?" q-slider--focus":"")+(t.label||t.labelAlways===!0?" q-slider--label":"")+(t.labelAlways===!0?" q-slider--label-always":"")+(y.value===!0?" q-slider--dark":"")+(t.dense===!0?" q-slider--dense q-slider--dense"+u.value:""));function K(ne){const ge="q-slider__"+ne;return`${ge} ${ge}${u.value} ${ge}${u.value}${f.value}`}function ee(ne){const ge="q-slider__"+ne;return`${ge} ${ge}${u.value}`}const V=oe(()=>{const ne=t.selectionColor||t.color;return"q-slider__selection absolute"+(ne!==void 0?` text-${ne}`:"")}),D=oe(()=>ee("markers")+" absolute overflow-hidden"),N=oe(()=>ee("track-container")),j=oe(()=>K("pin")),P=oe(()=>K("label")),B=oe(()=>K("text-container")),F=oe(()=>K("marker-labels-container")+(t.markerLabelsClass!==void 0?` ${t.markerLabelsClass}`:"")),C=oe(()=>"q-slider__track relative-position no-outline"+(t.trackColor!==void 0?` bg-${t.trackColor}`:"")),$=oe(()=>{const ne={[x.value]:t.trackSize};return t.trackImg!==void 0&&(ne.backgroundImage=`url(${t.trackImg}) !important`),ne}),z=oe(()=>"q-slider__inner absolute"+(t.innerTrackColor!==void 0?` bg-${t.innerTrackColor}`:"")),G=oe(()=>{const ne=T.value-M.value,ge={[b.value]:`${100*M.value}%`,[E.value]:ne===0?"2px":`${100*ne}%`};return t.innerTrackImg!==void 0&&(ge.backgroundImage=`url(${t.innerTrackImg}) !important`),ge});function J(ne){const{min:ge,max:Oe,step:Pe}=t;let Le=ge+ne*(Oe-ge);if(Pe>0){const Fe=(Le-a.value)%Pe;Le+=(Math.abs(Fe)>=Pe/2?(Fe<0?-1:1)*Pe:0)-Fe}return Le=r.value(Le),jt(Le,a.value,o.value)}function fe(ne){return k.value===0?0:(ne-t.min)/k.value}function Q(ne,ge){const Oe=Tr(ne),Pe=t.vertical===!0?jt((Oe.top-ge.top)/ge.height,0,1):jt((Oe.left-ge.left)/ge.width,0,1);return jt(c.value===!0?1-Pe:Pe,M.value,T.value)}const re=oe(()=>Ci(t.markers)===!0?t.markers:g.value),se=oe(()=>{const ne=[],ge=re.value,Oe=t.max;let Pe=t.min;do ne.push(Pe),Pe+=ge;while(Pe<Oe);return ne.push(Oe),ne}),ce=oe(()=>{const ne=` ${Xr}${u.value}-`;return Xr+`${ne}${t.switchMarkerLabelsSide===!0?"switched":"standard"}${ne}${c.value===!0?"rtl":"ltr"}`}),Ee=oe(()=>t.markerLabels===!1?null:Y(t.markerLabels).map((ne,ge)=>({index:ge,value:ne.value,label:ne.label||ne.value,classes:ce.value+(ne.classes!==void 0?" "+ne.classes:""),style:{...ie(ne.value),...ne.style||{}}}))),he=oe(()=>({markerList:Ee.value,markerMap:ue.value,classes:ce.value,getStyle:ie})),Z=oe(()=>{const ne=A.value===0?"2px":100*re.value/A.value;return{...G.value,backgroundSize:t.vertical===!0?`2px ${ne}%`:`${ne}% 2px`}});function Y(ne){if(ne===!1)return null;if(ne===!0)return se.value.map(_o);if(typeof ne=="function")return se.value.map(Oe=>{const Pe=ne(Oe);return pr(Pe)===!0?{...Pe,value:Oe}:{value:Oe,label:Pe}});const ge=({value:Oe})=>Oe>=t.min&&Oe<=t.max;return Array.isArray(ne)===!0?ne.map(Oe=>pr(Oe)===!0?Oe:{value:Oe}).filter(ge):Object.keys(ne).map(Oe=>{const Pe=ne[Oe],Le=Number(Oe);return pr(Pe)===!0?{...Pe,value:Le}:{value:Le,label:Pe}}).filter(ge)}function ie(ne){return{[b.value]:`${100*(ne-t.min)/k.value}%`}}const ue=oe(()=>{if(t.markerLabels===!1)return null;const ne={};return Ee.value.forEach(ge=>{ne[ge.value]=ge}),ne});function W(){if(O["marker-label-group"]!==void 0)return O["marker-label-group"](he.value);const ne=O["marker-label"]||Oo;return Ee.value.map(ge=>ne({marker:ge,...he.value}))}const te=oe(()=>[[gi,ae,void 0,{[q.value]:!0,prevent:!0,stop:!0,mouse:!0,mouseAllDir:!0}]]);function ae(ne){ne.isFinal===!0?(n.value!==void 0&&(R(ne.evt),ne.touch===!0&&i(!0),n.value=void 0,m("pan","end")),h.value=!1,e.value=!1):ne.isFirst===!0?(n.value=p(ne.evt),R(ne.evt),i(),h.value=!0,m("pan","start")):(R(ne.evt),i())}function de(){e.value=!1}function we(ne){R(ne,p(ne)),i(),l.value=!0,h.value=!0,document.addEventListener("mouseup",ye,!0)}function ye(){l.value=!1,h.value=!1,i(!0),de(),document.removeEventListener("mouseup",ye,!0)}function ve(ne){R(ne,p(ne)),i(!0)}function Ne(ne){Oi.includes(ne.keyCode)&&i(!0)}function be(ne){if(t.vertical===!0)return null;const ge=w.lang.rtl!==t.reverse?1-ne:ne;return{transform:`translateX(calc(${2*ge-1} * ${t.thumbSize} / 2 + ${50-100*ge}%))`}}function Ce(ne){const ge=oe(()=>l.value===!1&&(e.value===ne.focusValue||e.value==="both")?" q-slider--focus":""),Oe=oe(()=>`q-slider__thumb q-slider__thumb${u.value} q-slider__thumb${u.value}-${c.value===!0?"rtl":"ltr"} absolute non-selectable`+ge.value+(ne.thumbColor.value!==void 0?` text-${ne.thumbColor.value}`:"")),Pe=oe(()=>({width:t.thumbSize,height:t.thumbSize,[b.value]:`${100*ne.ratio.value}%`,zIndex:e.value===ne.focusValue?2:void 0})),Le=oe(()=>ne.labelColor.value!==void 0?` text-${ne.labelColor.value}`:""),Fe=oe(()=>be(ne.ratio.value)),Ve=oe(()=>"q-slider__text"+(ne.labelTextColor.value!==void 0?` text-${ne.labelTextColor.value}`:""));return()=>{const tt=[le("svg",{class:"q-slider__thumb-shape absolute-full",viewBox:"0 0 20 20","aria-hidden":"true"},[le("path",{d:t.thumbPath})]),le("div",{class:"q-slider__focus-ring fit"})];return(t.label===!0||t.labelAlways===!0)&&(tt.push(le("div",{class:j.value+" absolute fit no-pointer-events"+Le.value},[le("div",{class:P.value,style:{minWidth:t.thumbSize}},[le("div",{class:B.value,style:Fe.value},[le("span",{class:Ve.value},ne.label.value)])])])),t.name!==void 0&&t.disable!==!0&&_(tt,"push")),le("div",{class:Oe.value,style:Pe.value,...ne.getNodeData()},tt)}}function vt(ne,ge,Oe,Pe){const Le=[];t.innerTrackColor!=="transparent"&&Le.push(le("div",{key:"inner",class:z.value,style:G.value})),t.selectionColor!=="transparent"&&Le.push(le("div",{key:"selection",class:V.value,style:ne.value})),t.markers!==!1&&Le.push(le("div",{key:"marker",class:D.value,style:Z.value})),Pe(Le);const Fe=[Cr("div",{key:"trackC",class:N.value,tabindex:ge.value,...Oe.value},[le("div",{class:C.value,style:$.value},Le)],"slide",d.value,()=>te.value)];if(t.markerLabels!==!1){const Ve=t.switchMarkerLabelsSide===!0?"unshift":"push";Fe[Ve](le("div",{key:"markerL",class:F.value},W()))}return Fe}return Sn(()=>{document.removeEventListener("mouseup",ye,!0)}),{state:{active:h,focus:e,preventFocus:l,dragging:n,editable:d,classes:H,tabindex:S,attributes:I,roundValueFn:r,keyStep:g,trackLen:k,innerMin:a,innerMinRatio:M,innerMax:o,innerMaxRatio:T,positionProp:b,sizeProp:E,isReversed:c},methods:{onActivate:we,onMobileClick:ve,onBlur:de,onKeyup:Ne,getContent:vt,getThumbRenderFn:Ce,convertRatioToModel:J,convertModelToRatio:fe,getDraggingRatio:Q}}}const To=()=>({});var Ct=mt({name:"QSlider",props:{...wo,modelValue:{required:!0,default:null,validator:i=>typeof i=="number"||i===null},labelValue:[String,Number]},emits:Eo,setup(i,{emit:R}){const{proxy:{$q:p}}=ht(),{state:s,methods:t}=ko({updateValue:u,updatePosition:c,getDragging:f,formAttrs:Xi(i)}),m=ke(null),O=ke(0),w=ke(0);function y(){w.value=i.modelValue===null?s.innerMin.value:jt(i.modelValue,s.innerMin.value,s.innerMax.value)}ze(()=>`${i.modelValue}|${s.innerMin.value}|${s.innerMax.value}`,y),y();const _=oe(()=>t.convertModelToRatio(w.value)),h=oe(()=>s.active.value===!0?O.value:_.value),l=oe(()=>{const d={[s.positionProp.value]:`${100*s.innerMinRatio.value}%`,[s.sizeProp.value]:`${100*(h.value-s.innerMinRatio.value)}%`};return i.selectionImg!==void 0&&(d.backgroundImage=`url(${i.selectionImg}) !important`),d}),e=t.getThumbRenderFn({focusValue:!0,getNodeData:To,ratio:h,label:oe(()=>i.labelValue!==void 0?i.labelValue:w.value),thumbColor:oe(()=>i.thumbColor||i.color),labelColor:oe(()=>i.labelColor),labelTextColor:oe(()=>i.labelTextColor)}),n=oe(()=>s.editable.value!==!0?{}:p.platform.is.mobile===!0?{onClick:t.onMobileClick}:{onMousedown:t.onActivate,onFocus:a,onBlur:t.onBlur,onKeydown:o,onKeyup:t.onKeyup});function u(d){w.value!==i.modelValue&&R("update:modelValue",w.value),d===!0&&R("change",w.value)}function f(){return m.value.getBoundingClientRect()}function c(d,r=s.dragging.value){const g=t.getDraggingRatio(d,r);w.value=t.convertRatioToModel(g),O.value=i.snap!==!0||i.step===0?g:t.convertModelToRatio(w.value)}function a(){s.focus.value=!0}function o(d){if(Oi.includes(d.keyCode)===!1)return;Dt(d);const r=([34,33].includes(d.keyCode)?10:1)*s.keyStep.value,g=([34,37,40].includes(d.keyCode)?-1:1)*(s.isReversed.value===!0?-1:1)*(i.vertical===!0?-1:1)*r;w.value=jt(s.roundValueFn.value(w.value+g),s.innerMin.value,s.innerMax.value),u()}return()=>{const d=t.getContent(l,s.tabindex,n,r=>{r.push(e())});return le("div",{ref:m,class:s.classes.value+(i.modelValue===null?" q-slider--no-value":""),...s.attributes.value,"aria-valuenow":i.modelValue},d)}}});function Ao(i,R,p){const s=p===!0?["left","right"]:["top","bottom"];return`absolute-${R===!0?s[0]:s[1]}${i?` text-${i}`:""}`}const So=["left","center","right","justify"];var Jr=mt({name:"QTabs",props:{modelValue:[Number,String],align:{type:String,default:"center",validator:i=>So.includes(i)},breakpoint:{type:[String,Number],default:600},vertical:Boolean,shrink:Boolean,stretch:Boolean,activeClass:String,activeColor:String,activeBgColor:String,indicatorColor:String,leftIcon:String,rightIcon:String,outsideArrows:Boolean,mobileArrows:Boolean,switchIndicator:Boolean,narrowIndicator:Boolean,inlineLabel:Boolean,noCaps:Boolean,dense:Boolean,contentClass:String,"onUpdate:modelValue":[Function,Array]},setup(i,{slots:R,emit:p}){const{proxy:s}=ht(),{$q:t}=s,{registerTick:m}=br(),{registerTick:O}=br(),{registerTick:w}=br(),{registerTimeout:y,removeTimeout:_}=Sr(),{registerTimeout:h,removeTimeout:l}=Sr(),e=ke(null),n=ke(null),u=ke(i.modelValue),f=ke(!1),c=ke(!0),a=ke(!1),o=ke(!1),d=[],r=ke(0),g=ke(!1);let S=null,k=null,A;const M=oe(()=>({activeClass:i.activeClass,activeColor:i.activeColor,activeBgColor:i.activeBgColor,indicatorClass:Ao(i.indicatorColor,i.switchIndicator,i.vertical),narrowIndicator:i.narrowIndicator,inlineLabel:i.inlineLabel,noCaps:i.noCaps})),T=oe(()=>{const W=r.value,te=u.value;for(let ae=0;ae<W;ae++)if(d[ae].name.value===te)return!0;return!1}),b=oe(()=>`q-tabs__content--align-${f.value===!0?"left":o.value===!0?"justify":i.align}`),E=oe(()=>`q-tabs row no-wrap items-center q-tabs--${f.value===!0?"":"not-"}scrollable q-tabs--${i.vertical===!0?"vertical":"horizontal"} q-tabs__arrows--${i.outsideArrows===!0?"outside":"inside"} q-tabs--mobile-with${i.mobileArrows===!0?"":"out"}-arrows`+(i.dense===!0?" q-tabs--dense":"")+(i.shrink===!0?" col-shrink":"")+(i.stretch===!0?" self-stretch":"")),x=oe(()=>"q-tabs__content scroll--mobile row no-wrap items-center self-stretch hide-scrollbar relative-position "+b.value+(i.contentClass!==void 0?` ${i.contentClass}`:"")),q=oe(()=>i.vertical===!0?{container:"height",content:"offsetHeight",scroll:"scrollHeight"}:{container:"width",content:"offsetWidth",scroll:"scrollWidth"}),I=oe(()=>i.vertical!==!0&&t.lang.rtl===!0),H=oe(()=>Ji===!1&&I.value===!0);ze(I,j),ze(()=>i.modelValue,W=>{K({name:W,setCurrent:!0,skipEmit:!0})}),ze(()=>i.outsideArrows,ee);function K({name:W,setCurrent:te,skipEmit:ae}){u.value!==W&&(ae!==!0&&i["onUpdate:modelValue"]!==void 0&&p("update:modelValue",W),(te===!0||i["onUpdate:modelValue"]===void 0)&&(D(u.value,W),u.value=W))}function ee(){m(()=>{e.value&&V({width:e.value.offsetWidth,height:e.value.offsetHeight})})}function V(W){if(q.value===void 0||n.value===null)return;const te=W[q.value.container],ae=Math.min(n.value[q.value.scroll],Array.prototype.reduce.call(n.value.children,(we,ye)=>we+(ye[q.value.content]||0),0)),de=te>0&&ae>te;f.value=de,de===!0&&O(j),o.value=te<parseInt(i.breakpoint,10)}function D(W,te){const ae=W!=null&&W!==""?d.find(we=>we.name.value===W):null,de=te!=null&&te!==""?d.find(we=>we.name.value===te):null;if(ue===!0)ue=!1;else if(ae&&de){const we=ae.tabIndicatorRef.value,ye=de.tabIndicatorRef.value;S!==null&&(clearTimeout(S),S=null),we.style.transition="none",we.style.transform="none",ye.style.transition="none",ye.style.transform="none";const ve=we.getBoundingClientRect(),Ne=ye.getBoundingClientRect();ye.style.transform=i.vertical===!0?`translate3d(0,${ve.top-Ne.top}px,0) scale3d(1,${Ne.height?ve.height/Ne.height:1},1)`:`translate3d(${ve.left-Ne.left}px,0,0) scale3d(${Ne.width?ve.width/Ne.width:1},1,1)`,w(()=>{S=setTimeout(()=>{S=null,ye.style.transition="transform .25s cubic-bezier(.4, 0, .2, 1)",ye.style.transform="none"},70)})}de&&f.value===!0&&N(de.rootRef.value)}function N(W){const{left:te,width:ae,top:de,height:we}=n.value.getBoundingClientRect(),ye=W.getBoundingClientRect();let ve=i.vertical===!0?ye.top-de:ye.left-te;if(ve<0){n.value[i.vertical===!0?"scrollTop":"scrollLeft"]+=Math.floor(ve),j();return}ve+=i.vertical===!0?ye.height-we:ye.width-ae,ve>0&&(n.value[i.vertical===!0?"scrollTop":"scrollLeft"]+=Math.ceil(ve),j())}function j(){const W=n.value;if(W===null)return;const te=W.getBoundingClientRect(),ae=i.vertical===!0?W.scrollTop:Math.abs(W.scrollLeft);I.value===!0?(c.value=Math.ceil(ae+te.width)<W.scrollWidth-1,a.value=ae>0):(c.value=ae>0,a.value=i.vertical===!0?Math.ceil(ae+te.height)<W.scrollHeight:Math.ceil(ae+te.width)<W.scrollWidth)}function P(W){k!==null&&clearInterval(k),k=setInterval(()=>{G(W)===!0&&C()},5)}function B(){P(H.value===!0?Number.MAX_SAFE_INTEGER:0)}function F(){P(H.value===!0?0:Number.MAX_SAFE_INTEGER)}function C(){k!==null&&(clearInterval(k),k=null)}function $(W,te){const ae=Array.prototype.filter.call(n.value.children,Ne=>Ne===te||Ne.matches&&Ne.matches(".q-tab.q-focusable")===!0),de=ae.length;if(de===0)return;if(W===36)return N(ae[0]),ae[0].focus(),!0;if(W===35)return N(ae[de-1]),ae[de-1].focus(),!0;const we=W===(i.vertical===!0?38:37),ye=W===(i.vertical===!0?40:39),ve=we===!0?-1:ye===!0?1:void 0;if(ve!==void 0){const Ne=I.value===!0?-1:1,be=ae.indexOf(te)+ve*Ne;return be>=0&&be<de&&(N(ae[be]),ae[be].focus({preventScroll:!0})),!0}}const z=oe(()=>H.value===!0?{get:W=>Math.abs(W.scrollLeft),set:(W,te)=>{W.scrollLeft=-te}}:i.vertical===!0?{get:W=>W.scrollTop,set:(W,te)=>{W.scrollTop=te}}:{get:W=>W.scrollLeft,set:(W,te)=>{W.scrollLeft=te}});function G(W){const te=n.value,{get:ae,set:de}=z.value;let we=!1,ye=ae(te);const ve=W<ye?-1:1;return ye+=ve*5,ye<0?(we=!0,ye=0):(ve===-1&&ye<=W||ve===1&&ye>=W)&&(we=!0,ye=W),de(te,ye),j(),we}function J(W,te){for(const ae in W)if(W[ae]!==te[ae])return!1;return!0}function fe(){let W=null,te={matchedLen:0,queryDiff:9999,hrefLen:0};const ae=d.filter(ve=>{var Ne;return((Ne=ve.routeData)==null?void 0:Ne.hasRouterLink.value)===!0}),{hash:de,query:we}=s.$route,ye=Object.keys(we).length;for(const ve of ae){const Ne=ve.routeData.exact.value===!0;if(ve.routeData[Ne===!0?"linkIsExactActive":"linkIsActive"].value!==!0)continue;const{hash:be,query:Ce,matched:vt,href:ne}=ve.routeData.resolvedLink.value,ge=Object.keys(Ce).length;if(Ne===!0){if(be!==de||ge!==ye||J(we,Ce)===!1)continue;W=ve.name.value;break}if(be!==""&&be!==de||ge!==0&&J(Ce,we)===!1)continue;const Oe={matchedLen:vt.length,queryDiff:ye-ge,hrefLen:ne.length-be.length};if(Oe.matchedLen>te.matchedLen){W=ve.name.value,te=Oe;continue}else if(Oe.matchedLen!==te.matchedLen)continue;if(Oe.queryDiff<te.queryDiff)W=ve.name.value,te=Oe;else if(Oe.queryDiff!==te.queryDiff)continue;Oe.hrefLen>te.hrefLen&&(W=ve.name.value,te=Oe)}if(W===null&&d.some(ve=>ve.routeData===void 0&&ve.name.value===u.value)===!0){ue=!1;return}K({name:W,setCurrent:!0})}function Q(W){if(_(),g.value!==!0&&e.value!==null&&W.target&&typeof W.target.closest=="function"){const te=W.target.closest(".q-tab");te&&e.value.contains(te)===!0&&(g.value=!0,f.value===!0&&N(te))}}function re(){y(()=>{g.value=!1},30)}function se(){Z.avoidRouteWatcher===!1?h(fe):l()}function ce(){if(A===void 0){const W=ze(()=>s.$route.fullPath,se);A=()=>{W(),A=void 0}}}function Ee(W){d.push(W),r.value++,ee(),W.routeData===void 0||s.$route===void 0?h(()=>{if(f.value===!0){const te=u.value,ae=te!=null&&te!==""?d.find(de=>de.name.value===te):null;ae&&N(ae.rootRef.value)}}):(ce(),W.routeData.hasRouterLink.value===!0&&se())}function he(W){d.splice(d.indexOf(W),1),r.value--,ee(),A!==void 0&&W.routeData!==void 0&&(d.every(te=>te.routeData===void 0)===!0&&A(),se())}const Z={currentModel:u,tabProps:M,hasFocus:g,hasActiveTab:T,registerTab:Ee,unregisterTab:he,verifyRouteModel:se,updateModel:K,onKbdNavigate:$,avoidRouteWatcher:!1};Mi(ci,Z);function Y(){S!==null&&clearTimeout(S),C(),A==null||A()}let ie,ue;return Sn(Y),Ii(()=>{ie=A!==void 0,Y()}),ji(()=>{ie===!0&&(ce(),ue=!0,se()),ee()}),()=>le("div",{ref:e,class:E.value,role:"tablist",onFocusin:Q,onFocusout:re},[le(eo,{onResize:V}),le("div",{ref:n,class:x.value,onScroll:j},xn(R.default)),le(yt,{class:"q-tabs__arrow q-tabs__arrow--left absolute q-tab__icon"+(c.value===!0?"":" q-tabs__arrow--faded"),name:i.leftIcon||t.iconSet.tabs[i.vertical===!0?"up":"left"],onMousedownPassive:B,onTouchstartPassive:B,onMouseupPassive:C,onMouseleavePassive:C,onTouchendPassive:C}),le(yt,{class:"q-tabs__arrow q-tabs__arrow--right absolute q-tab__icon"+(a.value===!0?"":" q-tabs__arrow--faded"),name:i.rightIcon||t.iconSet.tabs[i.vertical===!0?"down":"right"],onMousedownPassive:F,onTouchstartPassive:F,onMouseupPassive:C,onMouseleavePassive:C,onTouchendPassive:C})])}});let xo=0;const No=["click","keydown"],Po={icon:String,label:[Number,String],alert:[Boolean,String],alertIcon:String,name:{type:[Number,String],default:()=>`t_${xo++}`},noCaps:Boolean,tabindex:[String,Number],disable:Boolean,contentClass:String,ripple:{type:[Boolean,Object],default:!0}};function qo(i,R,p,s){const t=Pr(ci,gr);if(t===gr)return console.error("QTab/QRouteTab component needs to be child of QTabs"),gr;const{proxy:m}=ht(),O=ke(null),w=ke(null),y=ke(null),_=oe(()=>i.disable===!0||i.ripple===!1?!1:Object.assign({keyCodes:[13,32],early:!0},i.ripple===!0?{}:i.ripple)),h=oe(()=>t.currentModel.value===i.name),l=oe(()=>"q-tab relative-position self-stretch flex flex-center text-center"+(h.value===!0?" q-tab--active"+(t.tabProps.value.activeClass?" "+t.tabProps.value.activeClass:"")+(t.tabProps.value.activeColor?` text-${t.tabProps.value.activeColor}`:"")+(t.tabProps.value.activeBgColor?` bg-${t.tabProps.value.activeBgColor}`:""):" q-tab--inactive")+(i.icon&&i.label&&t.tabProps.value.inlineLabel===!1?" q-tab--full":"")+(i.noCaps===!0||t.tabProps.value.noCaps===!0?" q-tab--no-caps":"")+(i.disable===!0?" disabled":" q-focusable q-hoverable cursor-pointer")+(s!==void 0?s.linkClass.value:"")),e=oe(()=>"q-tab__content self-stretch flex-center relative-position q-anchor--skip non-selectable "+(t.tabProps.value.inlineLabel===!0?"row no-wrap q-tab__content--inline":"column")+(i.contentClass!==void 0?` ${i.contentClass}`:"")),n=oe(()=>i.disable===!0||t.hasFocus.value===!0||h.value===!1&&t.hasActiveTab.value===!0?-1:i.tabindex||0);function u(d,r){var g;if(r!==!0&&(d==null?void 0:d.qAvoidFocus)!==!0&&((g=O.value)==null||g.focus()),i.disable===!0){(s==null?void 0:s.hasRouterLink.value)===!0&&Dt(d);return}if(s===void 0){t.updateModel({name:i.name}),p("click",d);return}if(s.hasRouterLink.value===!0){const S=(k={})=>{let A;const M=k.to===void 0||fi(k.to,i.to)===!0?t.avoidRouteWatcher=to():null;return s.navigateToRouterLink(d,{...k,returnRouterError:!0}).catch(T=>{A=T}).then(T=>{var b;if(M===t.avoidRouteWatcher&&(t.avoidRouteWatcher=!1,A===void 0&&(T===void 0||((b=T.message)==null?void 0:b.startsWith("Avoided redundant navigation"))===!0)&&t.updateModel({name:i.name})),k.returnRouterError===!0)return A!==void 0?Promise.reject(A):T})};p("click",d,S),d.defaultPrevented!==!0&&S();return}p("click",d)}function f(d){Di(d,[13,32])?u(d,!0):Bi(d)!==!0&&d.keyCode>=35&&d.keyCode<=40&&d.altKey!==!0&&d.metaKey!==!0&&t.onKbdNavigate(d.keyCode,m.$el)===!0&&Dt(d),p("keydown",d)}function c(){const d=t.tabProps.value.narrowIndicator,r=[],g=le("div",{ref:y,class:["q-tab__indicator",t.tabProps.value.indicatorClass]});i.icon!==void 0&&r.push(le(yt,{class:"q-tab__icon",name:i.icon})),i.label!==void 0&&r.push(le("div",{class:"q-tab__label"},i.label)),i.alert!==!1&&r.push(i.alertIcon!==void 0?le(yt,{class:"q-tab__alert-icon",color:i.alert!==!0?i.alert:void 0,name:i.alertIcon}):le("div",{class:"q-tab__alert"+(i.alert!==!0?` text-${i.alert}`:"")})),d===!0&&r.push(g);const S=[le("div",{class:"q-focus-helper",tabindex:-1,ref:O}),le("div",{class:e.value},Qi(R.default,r))];return d===!1&&S.push(g),S}const a={name:oe(()=>i.name),rootRef:w,tabIndicatorRef:y,routeData:s};Sn(()=>{t.unregisterTab(a)}),rn(()=>{t.registerTab(a)});function o(d,r){const g={ref:w,class:l.value,tabindex:n.value,role:"tab","aria-selected":h.value===!0?"true":"false","aria-disabled":i.disable===!0?"true":void 0,onClick:u,onKeydown:f,...r};return Ar(le(d,g,c()),[[Gi,_.value]])}return{renderTab:o,$tabs:t}}var Xt=mt({name:"QTab",props:Po,emits:No,setup(i,{slots:R,emit:p}){const{renderTab:s}=qo(i,R,p);return()=>s("div")}});function Lo(i){const R=[.06,6,50];return typeof i=="string"&&i.length&&i.split(":").forEach((p,s)=>{const t=parseFloat(p);t&&(R[s]=t)}),R}var Ro=Fi({name:"touch-swipe",beforeMount(i,{value:R,arg:p,modifiers:s}){if(s.mouse!==!0&&Yt.has.touch!==!0)return;const t=s.mouseCapture===!0?"Capture":"",m={handler:R,sensitivity:Lo(p),direction:Wr(s),noop:Ui,mouseStart(O){Gr(O,m)&&$i(O)&&(bn(m,"temp",[[document,"mousemove","move",`notPassive${t}`],[document,"mouseup","end","notPassiveCapture"]]),m.start(O,!0))},touchStart(O){if(Gr(O,m)){const w=O.target;bn(m,"temp",[[w,"touchmove","move","notPassiveCapture"],[w,"touchcancel","end","notPassiveCapture"],[w,"touchend","end","notPassiveCapture"]]),m.start(O)}},start(O,w){Yt.is.firefox===!0&&yr(i,!0);const y=Tr(O);m.event={x:y.left,y:y.top,time:Date.now(),mouse:w===!0,dir:!1}},move(O){if(m.event===void 0)return;if(m.event.dir!==!1){Dt(O);return}const w=Date.now()-m.event.time;if(w===0)return;const y=Tr(O),_=y.left-m.event.x,h=Math.abs(_),l=y.top-m.event.y,e=Math.abs(l);if(m.event.mouse!==!0){if(h<m.sensitivity[1]&&e<m.sensitivity[1]){m.end(O);return}}else if(window.getSelection().toString()!==""){m.end(O);return}else if(h<m.sensitivity[2]&&e<m.sensitivity[2])return;const n=h/w,u=e/w;m.direction.vertical===!0&&h<e&&h<100&&u>m.sensitivity[0]&&(m.event.dir=l<0?"up":"down"),m.direction.horizontal===!0&&h>e&&e<100&&n>m.sensitivity[0]&&(m.event.dir=_<0?"left":"right"),m.direction.up===!0&&h<e&&l<0&&h<100&&u>m.sensitivity[0]&&(m.event.dir="up"),m.direction.down===!0&&h<e&&l>0&&h<100&&u>m.sensitivity[0]&&(m.event.dir="down"),m.direction.left===!0&&h>e&&_<0&&e<100&&n>m.sensitivity[0]&&(m.event.dir="left"),m.direction.right===!0&&h>e&&_>0&&e<100&&n>m.sensitivity[0]&&(m.event.dir="right"),m.event.dir!==!1?(Dt(O),m.event.mouse===!0&&(document.body.classList.add("no-pointer-events--children"),document.body.classList.add("non-selectable"),no(),m.styleCleanup=f=>{m.styleCleanup=void 0,document.body.classList.remove("non-selectable");const c=()=>{document.body.classList.remove("no-pointer-events--children")};f===!0?setTimeout(c,50):c()}),m.handler({evt:O,touch:m.event.mouse!==!0,mouse:m.event.mouse,direction:m.event.dir,duration:w,distance:{x:h,y:e}})):m.end(O)},end(O){var w;m.event!==void 0&&(mr(m,"temp"),Yt.is.firefox===!0&&yr(i,!1),(w=m.styleCleanup)==null||w.call(m,!0),O!==void 0&&m.event.dir!==!1&&Dt(O),m.event=void 0)}};if(i.__qtouchswipe=m,s.mouse===!0){const O=s.mouseCapture===!0||s.mousecapture===!0?"Capture":"";bn(m,"main",[[i,"mousedown","mouseStart",`passive${O}`]])}Yt.has.touch===!0&&bn(m,"main",[[i,"touchstart","touchStart",`passive${s.capture===!0?"Capture":""}`],[i,"touchmove","noop","notPassiveCapture"]])},updated(i,R){const p=i.__qtouchswipe;p!==void 0&&(R.oldValue!==R.value&&(typeof R.value!="function"&&p.end(),p.handler=R.value),p.direction=Wr(R.modifiers))},beforeUnmount(i){var p;const R=i.__qtouchswipe;R!==void 0&&(mr(R,"main"),mr(R,"temp"),Yt.is.firefox===!0&&yr(i,!1),(p=R.styleCleanup)==null||p.call(R),delete i.__qtouchswipe)}});function wi(){let i=Object.create(null);return{getCache:(R,p)=>i[R]===void 0?i[R]=typeof p=="function"?p():p:i[R],setCache(R,p){i[R]=p},hasCache(R){return Object.hasOwnProperty.call(i,R)},clearCache(R){R!==void 0?delete i[R]:i=Object.create(null)}}}const Co={name:{required:!0},disable:Boolean},ei={setup(i,{slots:R}){return()=>le("div",{class:"q-panel scroll",role:"tabpanel"},xn(R.default))}},Mo={modelValue:{required:!0},animated:Boolean,infinite:Boolean,swipeable:Boolean,vertical:Boolean,transitionPrev:String,transitionNext:String,transitionDuration:{type:[String,Number],default:300},keepAlive:Boolean,keepAliveInclude:[String,Array,RegExp],keepAliveExclude:[String,Array,RegExp],keepAliveMax:Number},Io=["update:modelValue","beforeTransition","transition"];function jo(){const{props:i,emit:R,proxy:p}=ht(),{getCache:s}=wi(),{registerTimeout:t}=Sr();let m,O;const w=ke(null),y={value:null};function _(q){const I=i.vertical===!0?"up":"left";A((p.$q.lang.rtl===!0?-1:1)*(q.direction===I?1:-1))}const h=oe(()=>[[Ro,_,void 0,{horizontal:i.vertical!==!0,vertical:i.vertical,mouse:!0}]]),l=oe(()=>i.transitionPrev||`slide-${i.vertical===!0?"down":"right"}`),e=oe(()=>i.transitionNext||`slide-${i.vertical===!0?"up":"left"}`),n=oe(()=>`--q-transition-duration: ${i.transitionDuration}ms`),u=oe(()=>typeof i.modelValue=="string"||typeof i.modelValue=="number"?i.modelValue:String(i.modelValue)),f=oe(()=>({include:i.keepAliveInclude,exclude:i.keepAliveExclude,max:i.keepAliveMax})),c=oe(()=>i.keepAliveInclude!==void 0||i.keepAliveExclude!==void 0);ze(()=>i.modelValue,(q,I)=>{const H=r(q)===!0?g(q):-1;O!==!0&&k(H===-1?0:H<g(I)?-1:1),y.value!==H&&(y.value=H,R("beforeTransition",q,I),t(()=>{R("transition",q,I)},i.transitionDuration))});function a(){A(1)}function o(){A(-1)}function d(q){R("update:modelValue",q)}function r(q){return q!=null&&q!==""}function g(q){return m.findIndex(I=>I.props.name===q&&I.props.disable!==""&&I.props.disable!==!0)}function S(){return m.filter(q=>q.props.disable!==""&&q.props.disable!==!0)}function k(q){const I=q!==0&&i.animated===!0&&y.value!==-1?"q-transition--"+(q===-1?l.value:e.value):null;w.value!==I&&(w.value=I)}function A(q,I=y.value){let H=I+q;for(;H!==-1&&H<m.length;){const K=m[H];if(K!==void 0&&K.props.disable!==""&&K.props.disable!==!0){k(q),O=!0,R("update:modelValue",K.props.name),setTimeout(()=>{O=!1});return}H+=q}i.infinite===!0&&m.length!==0&&I!==-1&&I!==m.length&&A(q,q===-1?m.length:-1)}function M(){const q=g(i.modelValue);return y.value!==q&&(y.value=q),!0}function T(){const q=r(i.modelValue)===!0&&M()&&m[y.value];return i.keepAlive===!0?[le(zi,f.value,[le(c.value===!0?s(u.value,()=>({...ei,name:u.value})):ei,{key:u.value,style:n.value},()=>q)])]:[le("div",{class:"q-panel scroll",style:n.value,key:u.value,role:"tabpanel"},[q])]}function b(){if(m.length!==0)return i.animated===!0?[le(Hi,{name:w.value},T)]:T()}function E(q){return m=Zi(xn(q.default,[])).filter(I=>I.props!==null&&I.props.slot===void 0&&r(I.props.name)===!0),m.length}function x(){return m}return Object.assign(p,{next:a,previous:o,goTo:d}),{panelIndex:y,panelDirectives:h,updatePanelsList:E,updatePanelIndex:M,getPanelContent:b,getEnabledPanels:S,getPanels:x,isValidPanelName:r,keepAliveProps:f,needsUniqueKeepAliveWrapper:c,goToPanelByOffset:A,goToPanel:d,nextPanel:a,previousPanel:o}}var Do=mt({name:"QTabPanels",props:{...Mo,...jr},emits:Io,setup(i,{slots:R}){const p=ht(),s=Ir(i,p.proxy.$q),{updatePanelsList:t,getPanelContent:m,panelDirectives:O}=jo(),w=oe(()=>"q-tab-panels q-panel-parent"+(s.value===!0?" q-tab-panels--dark q-dark":""));return()=>(t(R),Cr("div",{class:w.value},m(),"pan",i.swipeable,()=>O.value))}}),Or=mt({name:"QTabPanel",props:Co,setup(i,{slots:R}){return()=>le("div",{class:"q-tab-panel",role:"tabpanel"},xn(R.default))}});const Bo=/^rgb(a)?\((\d{1,3}),(\d{1,3}),(\d{1,3}),?([01]?\.?\d*?)?\)$/;function ti({r:i,g:R,b:p,a:s}){const t=s!==void 0;if(i=Math.round(i),R=Math.round(R),p=Math.round(p),i>255||R>255||p>255||t&&s>100)throw new TypeError("Expected 3 numbers below 256 (and optionally one below 100)");return s=t?(Math.round(255*s/100)|1<<8).toString(16).slice(1):"","#"+(p|R<<8|i<<16|1<<24).toString(16).slice(1)+s}function ni({r:i,g:R,b:p,a:s}){return`rgb${s!==void 0?"a":""}(${i},${R},${p}${s!==void 0?","+s/100:""})`}function Ei(i){if(typeof i!="string")throw new TypeError("Expected a string");i=i.replace(/^#/,""),i.length===3?i=i[0]+i[0]+i[1]+i[1]+i[2]+i[2]:i.length===4&&(i=i[0]+i[0]+i[1]+i[1]+i[2]+i[2]+i[3]+i[3]);const R=parseInt(i,16);return i.length>6?{r:R>>24&255,g:R>>16&255,b:R>>8&255,a:Math.round((R&255)/2.55)}:{r:R>>16,g:R>>8&255,b:R&255}}function ri({h:i,s:R,v:p,a:s}){let t,m,O;R=R/100,p=p/100,i=i/360;const w=Math.floor(i*6),y=i*6-w,_=p*(1-R),h=p*(1-y*R),l=p*(1-(1-y)*R);switch(w%6){case 0:t=p,m=l,O=_;break;case 1:t=h,m=p,O=_;break;case 2:t=_,m=p,O=l;break;case 3:t=_,m=h,O=p;break;case 4:t=l,m=_,O=p;break;case 5:t=p,m=_,O=h;break}return{r:Math.round(t*255),g:Math.round(m*255),b:Math.round(O*255),a:s}}function wr({r:i,g:R,b:p,a:s}){const t=Math.max(i,R,p),m=Math.min(i,R,p),O=t-m,w=t===0?0:O/t,y=t/255;let _;switch(t){case m:_=0;break;case i:_=R-p+O*(R<p?6:0),_/=6*O;break;case R:_=p-i+O*2,_/=6*O;break;case p:_=i-R+O*4,_/=6*O;break}return{h:Math.round(_*360),s:Math.round(w*100),v:Math.round(y*100),a:s}}function ki(i){if(typeof i!="string")throw new TypeError("Expected a string");const R=i.replace(/ /g,""),p=Bo.exec(R);if(p===null)return Ei(R);const s={r:Math.min(255,parseInt(p[2],10)),g:Math.min(255,parseInt(p[3],10)),b:Math.min(255,parseInt(p[4],10))};if(p[1]){const t=parseFloat(p[5]);s.a=Math.min(1,isNaN(t)===!0?1:t)*100}return s}function Fo(i){if(typeof i!="string"&&(!i||i.r===void 0))throw new TypeError("Expected a string or a {r, g, b} object as color");const R=typeof i=="string"?ki(i):i,p=R.r/255,s=R.g/255,t=R.b/255,m=p<=.03928?p/12.92:Math.pow((p+.055)/1.055,2.4),O=s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4),w=t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4);return .2126*m+.7152*O+.0722*w}const Uo=["rgb(255,204,204)","rgb(255,230,204)","rgb(255,255,204)","rgb(204,255,204)","rgb(204,255,230)","rgb(204,255,255)","rgb(204,230,255)","rgb(204,204,255)","rgb(230,204,255)","rgb(255,204,255)","rgb(255,153,153)","rgb(255,204,153)","rgb(255,255,153)","rgb(153,255,153)","rgb(153,255,204)","rgb(153,255,255)","rgb(153,204,255)","rgb(153,153,255)","rgb(204,153,255)","rgb(255,153,255)","rgb(255,102,102)","rgb(255,179,102)","rgb(255,255,102)","rgb(102,255,102)","rgb(102,255,179)","rgb(102,255,255)","rgb(102,179,255)","rgb(102,102,255)","rgb(179,102,255)","rgb(255,102,255)","rgb(255,51,51)","rgb(255,153,51)","rgb(255,255,51)","rgb(51,255,51)","rgb(51,255,153)","rgb(51,255,255)","rgb(51,153,255)","rgb(51,51,255)","rgb(153,51,255)","rgb(255,51,255)","rgb(255,0,0)","rgb(255,128,0)","rgb(255,255,0)","rgb(0,255,0)","rgb(0,255,128)","rgb(0,255,255)","rgb(0,128,255)","rgb(0,0,255)","rgb(128,0,255)","rgb(255,0,255)","rgb(245,0,0)","rgb(245,123,0)","rgb(245,245,0)","rgb(0,245,0)","rgb(0,245,123)","rgb(0,245,245)","rgb(0,123,245)","rgb(0,0,245)","rgb(123,0,245)","rgb(245,0,245)","rgb(214,0,0)","rgb(214,108,0)","rgb(214,214,0)","rgb(0,214,0)","rgb(0,214,108)","rgb(0,214,214)","rgb(0,108,214)","rgb(0,0,214)","rgb(108,0,214)","rgb(214,0,214)","rgb(163,0,0)","rgb(163,82,0)","rgb(163,163,0)","rgb(0,163,0)","rgb(0,163,82)","rgb(0,163,163)","rgb(0,82,163)","rgb(0,0,163)","rgb(82,0,163)","rgb(163,0,163)","rgb(92,0,0)","rgb(92,46,0)","rgb(92,92,0)","rgb(0,92,0)","rgb(0,92,46)","rgb(0,92,92)","rgb(0,46,92)","rgb(0,0,92)","rgb(46,0,92)","rgb(92,0,92)","rgb(255,255,255)","rgb(205,205,205)","rgb(178,178,178)","rgb(153,153,153)","rgb(127,127,127)","rgb(102,102,102)","rgb(76,76,76)","rgb(51,51,51)","rgb(25,25,25)","rgb(0,0,0)"],ii="M5 5 h10 v10 h-10 v-10 z",$o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAH0lEQVQoU2NkYGAwZkAFZ5G5jPRRgOYEVDeB3EBjBQBOZwTVugIGyAAAAABJRU5ErkJggg==";var Ho=mt({name:"QColor",props:{...jr,...yi,modelValue:String,defaultValue:String,defaultView:{type:String,default:"spectrum",validator:i=>["spectrum","tune","palette"].includes(i)},formatModel:{type:String,default:"auto",validator:i=>["auto","hex","rgb","hexa","rgba"].includes(i)},palette:Array,noHeader:Boolean,noHeaderTabs:Boolean,noFooter:Boolean,square:Boolean,flat:Boolean,bordered:Boolean,disable:Boolean,readonly:Boolean},emits:["update:modelValue","change"],setup(i,{emit:R}){const{proxy:p}=ht(),{$q:s}=p,t=Ir(i,s),{getCache:m}=wi(),O=ke(null),w=ke(null),y=oe(()=>i.formatModel==="auto"?null:i.formatModel.indexOf("hex")!==-1),_=oe(()=>i.formatModel==="auto"?null:i.formatModel.indexOf("a")!==-1),h=ke(i.formatModel==="auto"?i.modelValue===void 0||i.modelValue===null||i.modelValue===""||i.modelValue.startsWith("#")?"hex":"rgb":i.formatModel.startsWith("hex")?"hex":"rgb"),l=ke(i.defaultView),e=ke(E(i.modelValue||i.defaultValue)),n=oe(()=>i.disable!==!0&&i.readonly!==!0),u=oe(()=>i.modelValue===void 0||i.modelValue===null||i.modelValue===""||i.modelValue.startsWith("#")),f=oe(()=>y.value!==null?y.value:u.value),c=oe(()=>({type:"hidden",name:i.name,value:e.value[f.value===!0?"hex":"rgb"]})),a=mi(c),o=oe(()=>_.value!==null?_.value:e.value.a!==void 0),d=oe(()=>({backgroundColor:e.value.rgb||"#000"})),r=oe(()=>`q-color-picker__header-content q-color-picker__header-content--${(e.value.a!==void 0&&e.value.a<65?!0:Fo(e.value)>.4)?"light":"dark"}`),g=oe(()=>({background:`hsl(${e.value.h},100%,50%)`})),S=oe(()=>({top:`${100-e.value.v}%`,[s.lang.rtl===!0?"right":"left"]:`${e.value.s}%`})),k=oe(()=>i.palette!==void 0&&i.palette.length!==0?i.palette:Uo),A=oe(()=>"q-color-picker"+(i.bordered===!0?" q-color-picker--bordered":"")+(i.square===!0?" q-color-picker--square no-border-radius":"")+(i.flat===!0?" q-color-picker--flat no-shadow":"")+(i.disable===!0?" disabled":"")+(t.value===!0?" q-color-picker--dark q-dark":"")),M=oe(()=>i.disable===!0?{"aria-disabled":"true"}:{}),T=oe(()=>[[gi,V,void 0,{prevent:!0,stop:!0,mouse:!0}]]);ze(()=>i.modelValue,Q=>{const re=E(Q||i.defaultValue);re.hex!==e.value.hex&&(e.value=re)}),ze(()=>i.defaultValue,Q=>{if(!i.modelValue&&Q){const re=E(Q);re.hex!==e.value.hex&&(e.value=re)}});function b(Q,re){e.value.hex=ti(Q),e.value.rgb=ni(Q),e.value.r=Q.r,e.value.g=Q.g,e.value.b=Q.b,e.value.a=Q.a;const se=e.value[f.value===!0?"hex":"rgb"];R("update:modelValue",se),re===!0&&R("change",se)}function E(Q){const re=_.value!==void 0?_.value:i.formatModel==="auto"?null:i.formatModel.indexOf("a")!==-1;if(typeof Q!="string"||Q.length===0||ro.anyColor(Q.replace(/ /g,""))!==!0)return{h:0,s:0,v:0,r:0,g:0,b:0,a:re===!0?100:void 0,hex:void 0,rgb:void 0};const se=ki(Q);return re===!0&&se.a===void 0&&(se.a=100),se.hex=ti(se),se.rgb=ni(se),Object.assign(se,wr(se))}function x(Q,re,se){const ce=O.value;if(ce===null)return;const Ee=ce.clientWidth,he=ce.clientHeight,Z=ce.getBoundingClientRect();let Y=Math.min(Ee,Math.max(0,Q-Z.left));s.lang.rtl===!0&&(Y=Ee-Y);const ie=Math.min(he,Math.max(0,re-Z.top)),ue=Math.round(100*Y/Ee),W=Math.round(100*Math.max(0,Math.min(1,-(ie/he)+1))),te=ri({h:e.value.h,s:ue,v:W,a:o.value===!0?e.value.a:void 0});e.value.s=ue,e.value.v=W,b(te,se)}function q(Q,re){const se=Math.round(Q),ce=ri({h:se,s:e.value.s,v:e.value.v,a:o.value===!0?e.value.a:void 0});e.value.h=se,b(ce,re)}function I(Q){q(Q,!0)}function H(Q,re,se,ce,Ee){if(ce!==void 0&&kt(ce),!/^[0-9]+$/.test(Q)){Ee===!0&&p.$forceUpdate();return}const he=Math.floor(Number(Q));if(he<0||he>se){Ee===!0&&p.$forceUpdate();return}const Z={r:re==="r"?he:e.value.r,g:re==="g"?he:e.value.g,b:re==="b"?he:e.value.b,a:o.value===!0?re==="a"?he:e.value.a:void 0};if(re!=="a"){const Y=wr(Z);e.value.h=Y.h,e.value.s=Y.s,e.value.v=Y.v}if(b(Z,Ee),Ee!==!0&&(ce==null?void 0:ce.target.selectionEnd)!==void 0){const Y=ce.target.selectionEnd;tn(()=>{ce.target.setSelectionRange(Y,Y)})}}function K(Q,re){let se;const ce=Q.target.value;if(kt(Q),h.value==="hex"){if(ce.length!==(o.value===!0?9:7)||!/^#[0-9A-Fa-f]+$/.test(ce))return!0;se=Ei(ce)}else{let he;if(ce.endsWith(")"))if(o.value!==!0&&ce.startsWith("rgb(")){if(he=ce.substring(4,ce.length-1).split(",").map(Z=>parseInt(Z,10)),he.length!==3||!/^rgb\([0-9]{1,3},[0-9]{1,3},[0-9]{1,3}\)$/.test(ce))return!0}else if(o.value===!0&&ce.startsWith("rgba(")){if(he=ce.substring(5,ce.length-1).split(","),he.length!==4||!/^rgba\([0-9]{1,3},[0-9]{1,3},[0-9]{1,3},(0|0\.[0-9]+[1-9]|0\.[1-9]+|1)\)$/.test(ce))return!0;for(let Y=0;Y<3;Y++){const ie=parseInt(he[Y],10);if(ie<0||ie>255)return!0;he[Y]=ie}const Z=parseFloat(he[3]);if(Z<0||Z>1)return!0;he[3]=Z}else return!0;else return!0;if(he[0]<0||he[0]>255||he[1]<0||he[1]>255||he[2]<0||he[2]>255||o.value===!0&&(he[3]<0||he[3]>1))return!0;se={r:he[0],g:he[1],b:he[2],a:o.value===!0?he[3]*100:void 0}}const Ee=wr(se);if(e.value.h=Ee.h,e.value.s=Ee.s,e.value.v=Ee.v,b(se,re),re!==!0){const he=Q.target.selectionEnd;tn(()=>{Q.target.setSelectionRange(he,he)})}}function ee(Q){const re=E(Q),se={r:re.r,g:re.g,b:re.b,a:re.a};se.a===void 0&&(se.a=e.value.a),e.value.h=re.h,e.value.s=re.s,e.value.v=re.v,b(se,!0)}function V(Q){Q.isFinal?x(Q.position.left,Q.position.top,!0):D(Q)}const D=Yi(Q=>{x(Q.position.left,Q.position.top)},20);function N(Q){x(Q.pageX-window.pageXOffset,Q.pageY-window.pageYOffset,!0)}function j(Q){x(Q.pageX-window.pageXOffset,Q.pageY-window.pageYOffset)}function P(Q){w.value!==null&&(w.value.$el.style.opacity=Q?1:0)}function B(Q){h.value=Q}function F(){const Q=[];return i.noHeaderTabs!==!0&&Q.push(le(Jr,{class:"q-color-picker__header-tabs",modelValue:h.value,dense:!0,align:"justify","onUpdate:modelValue":B},()=>[le(Xt,{label:"HEX"+(o.value===!0?"A":""),name:"hex",ripple:!1}),le(Xt,{label:"RGB"+(o.value===!0?"A":""),name:"rgb",ripple:!1})])),Q.push(le("div",{class:"q-color-picker__header-banner row flex-center no-wrap"},[le("input",{class:"fit",value:e.value[h.value],...n.value!==!0?{readonly:!0}:{},...m("topIn",{onInput:re=>{P(K(re)===!0)},onChange:kt,onBlur:re=>{K(re,!0)===!0&&p.$forceUpdate(),P(!1)}})}),le(yt,{ref:w,class:"q-color-picker__error-icon absolute no-pointer-events",name:s.iconSet.type.negative})])),le("div",{class:"q-color-picker__header relative-position overflow-hidden"},[le("div",{class:"q-color-picker__header-bg absolute-full"}),le("div",{class:r.value,style:d.value},Q)])}function C(){return le(Do,{modelValue:l.value,animated:!0},()=>[le(Or,{class:"q-color-picker__spectrum-tab overflow-hidden",name:"spectrum"},G),le(Or,{class:"q-pa-md q-color-picker__tune-tab",name:"tune"},J),le(Or,{class:"q-color-picker__palette-tab",name:"palette"},fe)])}function $(Q){l.value=Q}function z(){return le("div",{class:"q-color-picker__footer relative-position overflow-hidden"},[le(Jr,{class:"absolute-full",modelValue:l.value,dense:!0,align:"justify","onUpdate:modelValue":$},()=>[le(Xt,{icon:s.iconSet.colorPicker.spectrum,name:"spectrum",ripple:!1}),le(Xt,{icon:s.iconSet.colorPicker.tune,name:"tune",ripple:!1}),le(Xt,{icon:s.iconSet.colorPicker.palette,name:"palette",ripple:!1})])])}function G(){const Q={ref:O,class:"q-color-picker__spectrum non-selectable relative-position cursor-pointer"+(n.value!==!0?" readonly":""),style:g.value,...n.value===!0?{onClick:N,onMousedown:j}:{}},re=[le("div",{style:{paddingBottom:"100%"}}),le("div",{class:"q-color-picker__spectrum-white absolute-full"}),le("div",{class:"q-color-picker__spectrum-black absolute-full"}),le("div",{class:"absolute",style:S.value},[e.value.hex!==void 0?le("div",{class:"q-color-picker__spectrum-circle"}):null])],se=[le(Ct,{class:"q-color-picker__hue non-selectable",modelValue:e.value.h,min:0,max:360,trackSize:"8px",innerTrackColor:"transparent",selectionColor:"transparent",readonly:n.value!==!0,thumbPath:ii,"onUpdate:modelValue":q,onChange:I})];return o.value===!0&&se.push(le(Ct,{class:"q-color-picker__alpha non-selectable",modelValue:e.value.a,min:0,max:100,trackSize:"8px",trackColor:"white",innerTrackColor:"transparent",selectionColor:"transparent",trackImg:$o,readonly:n.value!==!0,hideSelection:!0,thumbPath:ii,...m("alphaSlide",{"onUpdate:modelValue":ce=>H(ce,"a",100),onChange:ce=>H(ce,"a",100,void 0,!0)})})),[Cr("div",Q,re,"spec",n.value,()=>T.value),le("div",{class:"q-color-picker__sliders"},se)]}function J(){return[le("div",{class:"row items-center no-wrap"},[le("div","R"),le(Ct,{modelValue:e.value.r,min:0,max:255,color:"red",dark:t.value,readonly:n.value!==!0,...m("rSlide",{"onUpdate:modelValue":Q=>H(Q,"r",255),onChange:Q=>H(Q,"r",255,void 0,!0)})}),le("input",{value:e.value.r,maxlength:3,readonly:n.value!==!0,onChange:kt,...m("rIn",{onInput:Q=>H(Q.target.value,"r",255,Q),onBlur:Q=>H(Q.target.value,"r",255,Q,!0)})})]),le("div",{class:"row items-center no-wrap"},[le("div","G"),le(Ct,{modelValue:e.value.g,min:0,max:255,color:"green",dark:t.value,readonly:n.value!==!0,...m("gSlide",{"onUpdate:modelValue":Q=>H(Q,"g",255),onChange:Q=>H(Q,"g",255,void 0,!0)})}),le("input",{value:e.value.g,maxlength:3,readonly:n.value!==!0,onChange:kt,...m("gIn",{onInput:Q=>H(Q.target.value,"g",255,Q),onBlur:Q=>H(Q.target.value,"g",255,Q,!0)})})]),le("div",{class:"row items-center no-wrap"},[le("div","B"),le(Ct,{modelValue:e.value.b,min:0,max:255,color:"blue",readonly:n.value!==!0,dark:t.value,...m("bSlide",{"onUpdate:modelValue":Q=>H(Q,"b",255),onChange:Q=>H(Q,"b",255,void 0,!0)})}),le("input",{value:e.value.b,maxlength:3,readonly:n.value!==!0,onChange:kt,...m("bIn",{onInput:Q=>H(Q.target.value,"b",255,Q),onBlur:Q=>H(Q.target.value,"b",255,Q,!0)})})]),o.value===!0?le("div",{class:"row items-center no-wrap"},[le("div","A"),le(Ct,{modelValue:e.value.a,color:"grey",readonly:n.value!==!0,dark:t.value,...m("aSlide",{"onUpdate:modelValue":Q=>H(Q,"a",100),onChange:Q=>H(Q,"a",100,void 0,!0)})}),le("input",{value:e.value.a,maxlength:3,readonly:n.value!==!0,onChange:kt,...m("aIn",{onInput:Q=>H(Q.target.value,"a",100,Q),onBlur:Q=>H(Q.target.value,"a",100,Q,!0)})})]):null]}function fe(){const Q=re=>le("div",{class:"q-color-picker__cube col-auto",style:{backgroundColor:re},...n.value===!0?m("palette#"+re,{onClick:()=>{ee(re)}}):{}});return[le("div",{class:"row items-center q-color-picker__palette-rows"+(n.value===!0?" q-color-picker__palette-rows--editable":"")},k.value.map(Q))]}return()=>{const Q=[C()];return i.name!==void 0&&i.disable!==!0&&a(Q,"push"),i.noHeader!==!0&&Q.unshift(F()),i.noFooter!==!0&&Q.push(z()),le("div",{class:A.value,...M.value},Q)}}}),zo=mt({name:"QPopupProxy",props:{...io,breakpoint:{type:[String,Number],default:450}},emits:["show","hide"],setup(i,{slots:R,emit:p,attrs:s}){const{proxy:t}=ht(),{$q:m}=t,O=ke(!1),w=ke(null),y=oe(()=>parseInt(i.breakpoint,10)),{canShow:_}=oo({showing:O});function h(){return m.screen.width<y.value||m.screen.height<y.value?"dialog":"menu"}const l=ke(h()),e=oe(()=>l.value==="menu"?{maxHeight:"99vh"}:{});ze(()=>h(),f=>{O.value!==!0&&(l.value=f)});function n(f){O.value=!0,p("show",f)}function u(f){O.value=!1,l.value=h(),p("hide",f)}return Object.assign(t,{show(f){_(f)===!0&&w.value.show(f)},hide(f){w.value.hide(f)},toggle(f){w.value.toggle(f)}}),si(t,"currentComponent",()=>({type:l.value,ref:w.value})),()=>{const f={ref:w,...e.value,...s,onShow:n,onHide:u};let c;return l.value==="dialog"?c=ao:(c=Mr,Object.assign(f,{target:i.target,contextMenu:i.contextMenu,noParentEvent:!0,separateClosePopup:!0})),le(c,f,R.default)}}}),Ti={exports:{}};/*!
 * Quill Editor v1.3.7
 * https://quilljs.com/
 * Copyright (c) 2014, Jason Chen
 * Copyright (c) 2013, salesforce.com
 */(function(i,R){(function(s,t){i.exports=t()})(typeof self!="undefined"?self:Be,function(){return function(p){var s={};function t(m){if(s[m])return s[m].exports;var O=s[m]={i:m,l:!1,exports:{}};return p[m].call(O.exports,O,O.exports,t),O.l=!0,O.exports}return t.m=p,t.c=s,t.d=function(m,O,w){t.o(m,O)||Object.defineProperty(m,O,{configurable:!1,enumerable:!0,get:w})},t.n=function(m){var O=m&&m.__esModule?function(){return m.default}:function(){return m};return t.d(O,"a",O),O},t.o=function(m,O){return Object.prototype.hasOwnProperty.call(m,O)},t.p="",t(t.s=109)}([function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(17),O=t(18),w=t(19),y=t(45),_=t(46),h=t(47),l=t(48),e=t(49),n=t(12),u=t(32),f=t(33),c=t(31),a=t(1),o={Scope:a.Scope,create:a.create,find:a.find,query:a.query,register:a.register,Container:m.default,Format:O.default,Leaf:w.default,Embed:l.default,Scroll:y.default,Block:h.default,Inline:_.default,Text:e.default,Attributor:{Attribute:n.default,Class:u.default,Style:f.default,Store:c.default}};s.default=o},function(p,s,t){var m=this&&this.__extends||function(){var c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,o){a.__proto__=o}||function(a,o){for(var d in o)o.hasOwnProperty(d)&&(a[d]=o[d])};return function(a,o){c(a,o);function d(){this.constructor=a}a.prototype=o===null?Object.create(o):(d.prototype=o.prototype,new d)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=function(c){m(a,c);function a(o){var d=this;return o="[Parchment] "+o,d=c.call(this,o)||this,d.message=o,d.name=d.constructor.name,d}return a}(Error);s.ParchmentError=O;var w={},y={},_={},h={};s.DATA_KEY="__blot";var l;(function(c){c[c.TYPE=3]="TYPE",c[c.LEVEL=12]="LEVEL",c[c.ATTRIBUTE=13]="ATTRIBUTE",c[c.BLOT=14]="BLOT",c[c.INLINE=7]="INLINE",c[c.BLOCK=11]="BLOCK",c[c.BLOCK_BLOT=10]="BLOCK_BLOT",c[c.INLINE_BLOT=6]="INLINE_BLOT",c[c.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",c[c.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",c[c.ANY=15]="ANY"})(l=s.Scope||(s.Scope={}));function e(c,a){var o=u(c);if(o==null)throw new O("Unable to create "+c+" blot");var d=o,r=c instanceof Node||c.nodeType===Node.TEXT_NODE?c:d.create(a);return new d(r,a)}s.create=e;function n(c,a){return a===void 0&&(a=!1),c==null?null:c[s.DATA_KEY]!=null?c[s.DATA_KEY].blot:a?n(c.parentNode,a):null}s.find=n;function u(c,a){a===void 0&&(a=l.ANY);var o;if(typeof c=="string")o=h[c]||w[c];else if(c instanceof Text||c.nodeType===Node.TEXT_NODE)o=h.text;else if(typeof c=="number")c&l.LEVEL&l.BLOCK?o=h.block:c&l.LEVEL&l.INLINE&&(o=h.inline);else if(c instanceof HTMLElement){var d=(c.getAttribute("class")||"").split(/\s+/);for(var r in d)if(o=y[d[r]],o)break;o=o||_[c.tagName]}return o==null?null:a&l.LEVEL&o.scope&&a&l.TYPE&o.scope?o:null}s.query=u;function f(){for(var c=[],a=0;a<arguments.length;a++)c[a]=arguments[a];if(c.length>1)return c.map(function(r){return f(r)});var o=c[0];if(typeof o.blotName!="string"&&typeof o.attrName!="string")throw new O("Invalid definition");if(o.blotName==="abstract")throw new O("Cannot register abstract class");if(h[o.blotName||o.attrName]=o,typeof o.keyName=="string")w[o.keyName]=o;else if(o.className!=null&&(y[o.className]=o),o.tagName!=null){Array.isArray(o.tagName)?o.tagName=o.tagName.map(function(r){return r.toUpperCase()}):o.tagName=o.tagName.toUpperCase();var d=Array.isArray(o.tagName)?o.tagName:[o.tagName];d.forEach(function(r){(_[r]==null||o.className==null)&&(_[r]=o)})}return o}s.register=f},function(p,s,t){var m=t(51),O=t(11),w=t(3),y=t(20),_=String.fromCharCode(0),h=function(l){Array.isArray(l)?this.ops=l:l!=null&&Array.isArray(l.ops)?this.ops=l.ops:this.ops=[]};h.prototype.insert=function(l,e){var n={};return l.length===0?this:(n.insert=l,e!=null&&typeof e=="object"&&Object.keys(e).length>0&&(n.attributes=e),this.push(n))},h.prototype.delete=function(l){return l<=0?this:this.push({delete:l})},h.prototype.retain=function(l,e){if(l<=0)return this;var n={retain:l};return e!=null&&typeof e=="object"&&Object.keys(e).length>0&&(n.attributes=e),this.push(n)},h.prototype.push=function(l){var e=this.ops.length,n=this.ops[e-1];if(l=w(!0,{},l),typeof n=="object"){if(typeof l.delete=="number"&&typeof n.delete=="number")return this.ops[e-1]={delete:n.delete+l.delete},this;if(typeof n.delete=="number"&&l.insert!=null&&(e-=1,n=this.ops[e-1],typeof n!="object"))return this.ops.unshift(l),this;if(O(l.attributes,n.attributes)){if(typeof l.insert=="string"&&typeof n.insert=="string")return this.ops[e-1]={insert:n.insert+l.insert},typeof l.attributes=="object"&&(this.ops[e-1].attributes=l.attributes),this;if(typeof l.retain=="number"&&typeof n.retain=="number")return this.ops[e-1]={retain:n.retain+l.retain},typeof l.attributes=="object"&&(this.ops[e-1].attributes=l.attributes),this}}return e===this.ops.length?this.ops.push(l):this.ops.splice(e,0,l),this},h.prototype.chop=function(){var l=this.ops[this.ops.length-1];return l&&l.retain&&!l.attributes&&this.ops.pop(),this},h.prototype.filter=function(l){return this.ops.filter(l)},h.prototype.forEach=function(l){this.ops.forEach(l)},h.prototype.map=function(l){return this.ops.map(l)},h.prototype.partition=function(l){var e=[],n=[];return this.forEach(function(u){var f=l(u)?e:n;f.push(u)}),[e,n]},h.prototype.reduce=function(l,e){return this.ops.reduce(l,e)},h.prototype.changeLength=function(){return this.reduce(function(l,e){return e.insert?l+y.length(e):e.delete?l-e.delete:l},0)},h.prototype.length=function(){return this.reduce(function(l,e){return l+y.length(e)},0)},h.prototype.slice=function(l,e){l=l||0,typeof e!="number"&&(e=1/0);for(var n=[],u=y.iterator(this.ops),f=0;f<e&&u.hasNext();){var c;f<l?c=u.next(l-f):(c=u.next(e-f),n.push(c)),f+=y.length(c)}return new h(n)},h.prototype.compose=function(l){var e=y.iterator(this.ops),n=y.iterator(l.ops),u=[],f=n.peek();if(f!=null&&typeof f.retain=="number"&&f.attributes==null){for(var c=f.retain;e.peekType()==="insert"&&e.peekLength()<=c;)c-=e.peekLength(),u.push(e.next());f.retain-c>0&&n.next(f.retain-c)}for(var a=new h(u);e.hasNext()||n.hasNext();)if(n.peekType()==="insert")a.push(n.next());else if(e.peekType()==="delete")a.push(e.next());else{var o=Math.min(e.peekLength(),n.peekLength()),d=e.next(o),r=n.next(o);if(typeof r.retain=="number"){var g={};typeof d.retain=="number"?g.retain=o:g.insert=d.insert;var S=y.attributes.compose(d.attributes,r.attributes,typeof d.retain=="number");if(S&&(g.attributes=S),a.push(g),!n.hasNext()&&O(a.ops[a.ops.length-1],g)){var k=new h(e.rest());return a.concat(k).chop()}}else typeof r.delete=="number"&&typeof d.retain=="number"&&a.push(r)}return a.chop()},h.prototype.concat=function(l){var e=new h(this.ops.slice());return l.ops.length>0&&(e.push(l.ops[0]),e.ops=e.ops.concat(l.ops.slice(1))),e},h.prototype.diff=function(l,e){if(this.ops===l.ops)return new h;var n=[this,l].map(function(o){return o.map(function(d){if(d.insert!=null)return typeof d.insert=="string"?d.insert:_;var r=o===l?"on":"with";throw new Error("diff() called "+r+" non-document")}).join("")}),u=new h,f=m(n[0],n[1],e),c=y.iterator(this.ops),a=y.iterator(l.ops);return f.forEach(function(o){for(var d=o[1].length;d>0;){var r=0;switch(o[0]){case m.INSERT:r=Math.min(a.peekLength(),d),u.push(a.next(r));break;case m.DELETE:r=Math.min(d,c.peekLength()),c.next(r),u.delete(r);break;case m.EQUAL:r=Math.min(c.peekLength(),a.peekLength(),d);var g=c.next(r),S=a.next(r);O(g.insert,S.insert)?u.retain(r,y.attributes.diff(g.attributes,S.attributes)):u.push(S).delete(r);break}d-=r}}),u.chop()},h.prototype.eachLine=function(l,e){e=e||`
`;for(var n=y.iterator(this.ops),u=new h,f=0;n.hasNext();){if(n.peekType()!=="insert")return;var c=n.peek(),a=y.length(c)-n.peekLength(),o=typeof c.insert=="string"?c.insert.indexOf(e,a)-a:-1;if(o<0)u.push(n.next());else if(o>0)u.push(n.next(o));else{if(l(u,n.next(1).attributes||{},f)===!1)return;f+=1,u=new h}}u.length()>0&&l(u,{},f)},h.prototype.transform=function(l,e){if(e=!!e,typeof l=="number")return this.transformPosition(l,e);for(var n=y.iterator(this.ops),u=y.iterator(l.ops),f=new h;n.hasNext()||u.hasNext();)if(n.peekType()==="insert"&&(e||u.peekType()!=="insert"))f.retain(y.length(n.next()));else if(u.peekType()==="insert")f.push(u.next());else{var c=Math.min(n.peekLength(),u.peekLength()),a=n.next(c),o=u.next(c);if(a.delete)continue;o.delete?f.push(o):f.retain(c,y.attributes.transform(a.attributes,o.attributes,e))}return f.chop()},h.prototype.transformPosition=function(l,e){e=!!e;for(var n=y.iterator(this.ops),u=0;n.hasNext()&&u<=l;){var f=n.peekLength(),c=n.peekType();if(n.next(),c==="delete"){l-=Math.min(f,l-u);continue}else c==="insert"&&(u<l||!e)&&(l+=f);u+=f}return l},p.exports=h},function(p,s){var t=Object.prototype.hasOwnProperty,m=Object.prototype.toString,O=Object.defineProperty,w=Object.getOwnPropertyDescriptor,y=function(n){return typeof Array.isArray=="function"?Array.isArray(n):m.call(n)==="[object Array]"},_=function(n){if(!n||m.call(n)!=="[object Object]")return!1;var u=t.call(n,"constructor"),f=n.constructor&&n.constructor.prototype&&t.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!u&&!f)return!1;var c;for(c in n);return typeof c=="undefined"||t.call(n,c)},h=function(n,u){O&&u.name==="__proto__"?O(n,u.name,{enumerable:!0,configurable:!0,value:u.newValue,writable:!0}):n[u.name]=u.newValue},l=function(n,u){if(u==="__proto__")if(t.call(n,u)){if(w)return w(n,u).value}else return;return n[u]};p.exports=function e(){var n,u,f,c,a,o,d=arguments[0],r=1,g=arguments.length,S=!1;for(typeof d=="boolean"&&(S=d,d=arguments[1]||{},r=2),(d==null||typeof d!="object"&&typeof d!="function")&&(d={});r<g;++r)if(n=arguments[r],n!=null)for(u in n)f=l(d,u),c=l(n,u),d!==c&&(S&&c&&(_(c)||(a=y(c)))?(a?(a=!1,o=f&&y(f)?f:[]):o=f&&_(f)?f:{},h(d,{name:u,newValue:e(S,o,c)})):typeof c!="undefined"&&h(d,{name:u,newValue:c}));return d}},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.BlockEmbed=s.bubbleFormats=void 0;var m=function(){function b(E,x){for(var q=0;q<x.length;q++){var I=x[q];I.enumerable=I.enumerable||!1,I.configurable=!0,"value"in I&&(I.writable=!0),Object.defineProperty(E,I.key,I)}}return function(E,x,q){return x&&b(E.prototype,x),q&&b(E,q),E}}(),O=function b(E,x,q){E===null&&(E=Function.prototype);var I=Object.getOwnPropertyDescriptor(E,x);if(I===void 0){var H=Object.getPrototypeOf(E);return H===null?void 0:b(H,x,q)}else{if("value"in I)return I.value;var K=I.get;return K===void 0?void 0:K.call(q)}},w=t(3),y=d(w),_=t(2),h=d(_),l=t(0),e=d(l),n=t(16),u=d(n),f=t(6),c=d(f),a=t(7),o=d(a);function d(b){return b&&b.__esModule?b:{default:b}}function r(b,E){if(!(b instanceof E))throw new TypeError("Cannot call a class as a function")}function g(b,E){if(!b)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return E&&(typeof E=="object"||typeof E=="function")?E:b}function S(b,E){if(typeof E!="function"&&E!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof E);b.prototype=Object.create(E&&E.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),E&&(Object.setPrototypeOf?Object.setPrototypeOf(b,E):b.__proto__=E)}var k=1,A=function(b){S(E,b);function E(){return r(this,E),g(this,(E.__proto__||Object.getPrototypeOf(E)).apply(this,arguments))}return m(E,[{key:"attach",value:function(){O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"attach",this).call(this),this.attributes=new e.default.Attributor.Store(this.domNode)}},{key:"delta",value:function(){return new h.default().insert(this.value(),(0,y.default)(this.formats(),this.attributes.values()))}},{key:"format",value:function(q,I){var H=e.default.query(q,e.default.Scope.BLOCK_ATTRIBUTE);H!=null&&this.attributes.attribute(H,I)}},{key:"formatAt",value:function(q,I,H,K){this.format(H,K)}},{key:"insertAt",value:function(q,I,H){if(typeof I=="string"&&I.endsWith(`
`)){var K=e.default.create(M.blotName);this.parent.insertBefore(K,q===0?this:this.next),K.insertAt(0,I.slice(0,-1))}else O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"insertAt",this).call(this,q,I,H)}}]),E}(e.default.Embed);A.scope=e.default.Scope.BLOCK_BLOT;var M=function(b){S(E,b);function E(x){r(this,E);var q=g(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,x));return q.cache={},q}return m(E,[{key:"delta",value:function(){return this.cache.delta==null&&(this.cache.delta=this.descendants(e.default.Leaf).reduce(function(q,I){return I.length()===0?q:q.insert(I.value(),T(I))},new h.default).insert(`
`,T(this))),this.cache.delta}},{key:"deleteAt",value:function(q,I){O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"deleteAt",this).call(this,q,I),this.cache={}}},{key:"formatAt",value:function(q,I,H,K){I<=0||(e.default.query(H,e.default.Scope.BLOCK)?q+I===this.length()&&this.format(H,K):O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"formatAt",this).call(this,q,Math.min(I,this.length()-q-1),H,K),this.cache={})}},{key:"insertAt",value:function(q,I,H){if(H!=null)return O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"insertAt",this).call(this,q,I,H);if(I.length!==0){var K=I.split(`
`),ee=K.shift();ee.length>0&&(q<this.length()-1||this.children.tail==null?O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"insertAt",this).call(this,Math.min(q,this.length()-1),ee):this.children.tail.insertAt(this.children.tail.length(),ee),this.cache={});var V=this;K.reduce(function(D,N){return V=V.split(D,!0),V.insertAt(0,N),N.length},q+ee.length)}}},{key:"insertBefore",value:function(q,I){var H=this.children.head;O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"insertBefore",this).call(this,q,I),H instanceof u.default&&H.remove(),this.cache={}}},{key:"length",value:function(){return this.cache.length==null&&(this.cache.length=O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"length",this).call(this)+k),this.cache.length}},{key:"moveChildren",value:function(q,I){O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"moveChildren",this).call(this,q,I),this.cache={}}},{key:"optimize",value:function(q){O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"optimize",this).call(this,q),this.cache={}}},{key:"path",value:function(q){return O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"path",this).call(this,q,!0)}},{key:"removeChild",value:function(q){O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"removeChild",this).call(this,q),this.cache={}}},{key:"split",value:function(q){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(I&&(q===0||q>=this.length()-k)){var H=this.clone();return q===0?(this.parent.insertBefore(H,this),this):(this.parent.insertBefore(H,this.next),H)}else{var K=O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"split",this).call(this,q,I);return this.cache={},K}}}]),E}(e.default.Block);M.blotName="block",M.tagName="P",M.defaultChild="break",M.allowedChildren=[c.default,e.default.Embed,o.default];function T(b){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return b==null||(typeof b.formats=="function"&&(E=(0,y.default)(E,b.formats())),b.parent==null||b.parent.blotName=="scroll"||b.parent.statics.scope!==b.statics.scope)?E:T(b.parent,E)}s.bubbleFormats=T,s.BlockEmbed=A,s.default=M},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.overload=s.expandConfig=void 0;var m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(V){return typeof V}:function(V){return V&&typeof Symbol=="function"&&V.constructor===Symbol&&V!==Symbol.prototype?"symbol":typeof V},O=function(){function V(D,N){var j=[],P=!0,B=!1,F=void 0;try{for(var C=D[Symbol.iterator](),$;!(P=($=C.next()).done)&&(j.push($.value),!(N&&j.length===N));P=!0);}catch(z){B=!0,F=z}finally{try{!P&&C.return&&C.return()}finally{if(B)throw F}}return j}return function(D,N){if(Array.isArray(D))return D;if(Symbol.iterator in Object(D))return V(D,N);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),w=function(){function V(D,N){for(var j=0;j<N.length;j++){var P=N[j];P.enumerable=P.enumerable||!1,P.configurable=!0,"value"in P&&(P.writable=!0),Object.defineProperty(D,P.key,P)}}return function(D,N,j){return N&&V(D.prototype,N),j&&V(D,j),D}}();t(50);var y=t(2),_=T(y),h=t(14),l=T(h),e=t(8),n=T(e),u=t(9),f=T(u),c=t(0),a=T(c),o=t(15),d=T(o),r=t(3),g=T(r),S=t(10),k=T(S),A=t(34),M=T(A);function T(V){return V&&V.__esModule?V:{default:V}}function b(V,D,N){return D in V?Object.defineProperty(V,D,{value:N,enumerable:!0,configurable:!0,writable:!0}):V[D]=N,V}function E(V,D){if(!(V instanceof D))throw new TypeError("Cannot call a class as a function")}var x=(0,k.default)("quill"),q=function(){w(V,null,[{key:"debug",value:function(N){N===!0&&(N="log"),k.default.level(N)}},{key:"find",value:function(N){return N.__quill||a.default.find(N)}},{key:"import",value:function(N){return this.imports[N]==null&&x.error("Cannot import "+N+". Are you sure it was registered?"),this.imports[N]}},{key:"register",value:function(N,j){var P=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(typeof N!="string"){var F=N.attrName||N.blotName;typeof F=="string"?this.register("formats/"+F,N,j):Object.keys(N).forEach(function(C){P.register(C,N[C],j)})}else this.imports[N]!=null&&!B&&x.warn("Overwriting "+N+" with",j),this.imports[N]=j,(N.startsWith("blots/")||N.startsWith("formats/"))&&j.blotName!=="abstract"?a.default.register(j):N.startsWith("modules")&&typeof j.register=="function"&&j.register()}}]);function V(D){var N=this,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(E(this,V),this.options=I(D,j),this.container=this.options.container,this.container==null)return x.error("Invalid Quill container",D);this.options.debug&&V.debug(this.options.debug);var P=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new n.default,this.scroll=a.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new l.default(this.scroll),this.selection=new d.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(n.default.events.EDITOR_CHANGE,function(F){F===n.default.events.TEXT_CHANGE&&N.root.classList.toggle("ql-blank",N.editor.isBlank())}),this.emitter.on(n.default.events.SCROLL_UPDATE,function(F,C){var $=N.selection.lastRange,z=$&&$.length===0?$.index:void 0;H.call(N,function(){return N.editor.update(null,C,z)},F)});var B=this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">`+P+"<p><br></p></div>");this.setContents(B),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return w(V,[{key:"addContainer",value:function(N){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(typeof N=="string"){var P=N;N=document.createElement("div"),N.classList.add(P)}return this.container.insertBefore(N,j),N}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(N,j,P){var B=this,F=K(N,j,P),C=O(F,4);return N=C[0],j=C[1],P=C[3],H.call(this,function(){return B.editor.deleteText(N,j)},P,N,-1*j)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.scroll.enable(N),this.container.classList.toggle("ql-disabled",!N)}},{key:"focus",value:function(){var N=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=N,this.scrollIntoView()}},{key:"format",value:function(N,j){var P=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:n.default.sources.API;return H.call(this,function(){var F=P.getSelection(!0),C=new _.default;if(F==null)return C;if(a.default.query(N,a.default.Scope.BLOCK))C=P.editor.formatLine(F.index,F.length,b({},N,j));else{if(F.length===0)return P.selection.format(N,j),C;C=P.editor.formatText(F.index,F.length,b({},N,j))}return P.setSelection(F,n.default.sources.SILENT),C},B)}},{key:"formatLine",value:function(N,j,P,B,F){var C=this,$=void 0,z=K(N,j,P,B,F),G=O(z,4);return N=G[0],j=G[1],$=G[2],F=G[3],H.call(this,function(){return C.editor.formatLine(N,j,$)},F,N,0)}},{key:"formatText",value:function(N,j,P,B,F){var C=this,$=void 0,z=K(N,j,P,B,F),G=O(z,4);return N=G[0],j=G[1],$=G[2],F=G[3],H.call(this,function(){return C.editor.formatText(N,j,$)},F,N,0)}},{key:"getBounds",value:function(N){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,P=void 0;typeof N=="number"?P=this.selection.getBounds(N,j):P=this.selection.getBounds(N.index,N.length);var B=this.container.getBoundingClientRect();return{bottom:P.bottom-B.top,height:P.height,left:P.left-B.left,right:P.right-B.left,top:P.top-B.top,width:P.width}}},{key:"getContents",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-N,P=K(N,j),B=O(P,2);return N=B[0],j=B[1],this.editor.getContents(N,j)}},{key:"getFormat",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.getSelection(!0),j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return typeof N=="number"?this.editor.getFormat(N,j):this.editor.getFormat(N.index,N.length)}},{key:"getIndex",value:function(N){return N.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(N){return this.scroll.leaf(N)}},{key:"getLine",value:function(N){return this.scroll.line(N)}},{key:"getLines",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;return typeof N!="number"?this.scroll.lines(N.index,N.length):this.scroll.lines(N,j)}},{key:"getModule",value:function(N){return this.theme.modules[N]}},{key:"getSelection",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return N&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-N,P=K(N,j),B=O(P,2);return N=B[0],j=B[1],this.editor.getText(N,j)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(N,j,P){var B=this,F=arguments.length>3&&arguments[3]!==void 0?arguments[3]:V.sources.API;return H.call(this,function(){return B.editor.insertEmbed(N,j,P)},F,N)}},{key:"insertText",value:function(N,j,P,B,F){var C=this,$=void 0,z=K(N,0,P,B,F),G=O(z,4);return N=G[0],$=G[2],F=G[3],H.call(this,function(){return C.editor.insertText(N,j,$)},F,N,j.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(N,j,P){this.clipboard.dangerouslyPasteHTML(N,j,P)}},{key:"removeFormat",value:function(N,j,P){var B=this,F=K(N,j,P),C=O(F,4);return N=C[0],j=C[1],P=C[3],H.call(this,function(){return B.editor.removeFormat(N,j)},P,N)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(N){var j=this,P=arguments.length>1&&arguments[1]!==void 0?arguments[1]:n.default.sources.API;return H.call(this,function(){N=new _.default(N);var B=j.getLength(),F=j.editor.deleteText(0,B),C=j.editor.applyDelta(N),$=C.ops[C.ops.length-1];$!=null&&typeof $.insert=="string"&&$.insert[$.insert.length-1]===`
`&&(j.editor.deleteText(j.getLength()-1,1),C.delete(1));var z=F.compose(C);return z},P)}},{key:"setSelection",value:function(N,j,P){if(N==null)this.selection.setRange(null,j||V.sources.API);else{var B=K(N,j,P),F=O(B,4);N=F[0],j=F[1],P=F[3],this.selection.setRange(new o.Range(N,j),P),P!==n.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(N){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:n.default.sources.API,P=new _.default().insert(N);return this.setContents(P,j)}},{key:"update",value:function(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:n.default.sources.USER,j=this.scroll.update(N);return this.selection.update(N),j}},{key:"updateContents",value:function(N){var j=this,P=arguments.length>1&&arguments[1]!==void 0?arguments[1]:n.default.sources.API;return H.call(this,function(){return N=new _.default(N),j.editor.applyDelta(N,P)},P,!0)}}]),V}();q.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},q.events=n.default.events,q.sources=n.default.sources,q.version="1.3.7",q.imports={delta:_.default,parchment:a.default,"core/module":f.default,"core/theme":M.default};function I(V,D){if(D=(0,g.default)(!0,{container:V,modules:{clipboard:!0,keyboard:!0,history:!0}},D),!D.theme||D.theme===q.DEFAULTS.theme)D.theme=M.default;else if(D.theme=q.import("themes/"+D.theme),D.theme==null)throw new Error("Invalid theme "+D.theme+". Did you register it?");var N=(0,g.default)(!0,{},D.theme.DEFAULTS);[N,D].forEach(function(B){B.modules=B.modules||{},Object.keys(B.modules).forEach(function(F){B.modules[F]===!0&&(B.modules[F]={})})});var j=Object.keys(N.modules).concat(Object.keys(D.modules)),P=j.reduce(function(B,F){var C=q.import("modules/"+F);return C==null?x.error("Cannot load "+F+" module. Are you sure you registered it?"):B[F]=C.DEFAULTS||{},B},{});return D.modules!=null&&D.modules.toolbar&&D.modules.toolbar.constructor!==Object&&(D.modules.toolbar={container:D.modules.toolbar}),D=(0,g.default)(!0,{},q.DEFAULTS,{modules:P},N,D),["bounds","container","scrollingContainer"].forEach(function(B){typeof D[B]=="string"&&(D[B]=document.querySelector(D[B]))}),D.modules=Object.keys(D.modules).reduce(function(B,F){return D.modules[F]&&(B[F]=D.modules[F]),B},{}),D}function H(V,D,N,j){if(this.options.strict&&!this.isEnabled()&&D===n.default.sources.USER)return new _.default;var P=N==null?null:this.getSelection(),B=this.editor.delta,F=V();if(P!=null&&(N===!0&&(N=P.index),j==null?P=ee(P,F,D):j!==0&&(P=ee(P,N,j,D)),this.setSelection(P,n.default.sources.SILENT)),F.length()>0){var C,$=[n.default.events.TEXT_CHANGE,F,B,D];if((C=this.emitter).emit.apply(C,[n.default.events.EDITOR_CHANGE].concat($)),D!==n.default.sources.SILENT){var z;(z=this.emitter).emit.apply(z,$)}}return F}function K(V,D,N,j,P){var B={};return typeof V.index=="number"&&typeof V.length=="number"?typeof D!="number"?(P=j,j=N,N=D,D=V.length,V=V.index):(D=V.length,V=V.index):typeof D!="number"&&(P=j,j=N,N=D,D=0),(typeof N=="undefined"?"undefined":m(N))==="object"?(B=N,P=j):typeof N=="string"&&(j!=null?B[N]=j:P=N),P=P||n.default.sources.API,[V,D,B,P]}function ee(V,D,N,j){if(V==null)return null;var P=void 0,B=void 0;if(D instanceof _.default){var F=[V.index,V.index+V.length].map(function(G){return D.transformPosition(G,j!==n.default.sources.USER)}),C=O(F,2);P=C[0],B=C[1]}else{var $=[V.index,V.index+V.length].map(function(G){return G<D||G===D&&j===n.default.sources.USER?G:N>=0?G+N:Math.max(D,G+N)}),z=O($,2);P=z[0],B=z[1]}return new o.Range(P,B-P)}s.expandConfig=I,s.overload=K,s.default=q},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function c(a,o){for(var d=0;d<o.length;d++){var r=o[d];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(a,r.key,r)}}return function(a,o,d){return o&&c(a.prototype,o),d&&c(a,d),a}}(),O=function c(a,o,d){a===null&&(a=Function.prototype);var r=Object.getOwnPropertyDescriptor(a,o);if(r===void 0){var g=Object.getPrototypeOf(a);return g===null?void 0:c(g,o,d)}else{if("value"in r)return r.value;var S=r.get;return S===void 0?void 0:S.call(d)}},w=t(7),y=l(w),_=t(0),h=l(_);function l(c){return c&&c.__esModule?c:{default:c}}function e(c,a){if(!(c instanceof a))throw new TypeError("Cannot call a class as a function")}function n(c,a){if(!c)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return a&&(typeof a=="object"||typeof a=="function")?a:c}function u(c,a){if(typeof a!="function"&&a!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof a);c.prototype=Object.create(a&&a.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}),a&&(Object.setPrototypeOf?Object.setPrototypeOf(c,a):c.__proto__=a)}var f=function(c){u(a,c);function a(){return e(this,a),n(this,(a.__proto__||Object.getPrototypeOf(a)).apply(this,arguments))}return m(a,[{key:"formatAt",value:function(d,r,g,S){if(a.compare(this.statics.blotName,g)<0&&h.default.query(g,h.default.Scope.BLOT)){var k=this.isolate(d,r);S&&k.wrap(g,S)}else O(a.prototype.__proto__||Object.getPrototypeOf(a.prototype),"formatAt",this).call(this,d,r,g,S)}},{key:"optimize",value:function(d){if(O(a.prototype.__proto__||Object.getPrototypeOf(a.prototype),"optimize",this).call(this,d),this.parent instanceof a&&a.compare(this.statics.blotName,this.parent.statics.blotName)>0){var r=this.parent.isolate(this.offset(),this.length());this.moveChildren(r),r.wrap(this)}}}],[{key:"compare",value:function(d,r){var g=a.order.indexOf(d),S=a.order.indexOf(r);return g>=0||S>=0?g-S:d===r?0:d<r?-1:1}}]),a}(h.default.Inline);f.allowedChildren=[f,h.default.Embed,y.default],f.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],s.default=f},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(0),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}function y(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function _(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function h(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var l=function(e){h(n,e);function n(){return y(this,n),_(this,(n.__proto__||Object.getPrototypeOf(n)).apply(this,arguments))}return n}(O.default.Text);s.default=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function o(d,r){for(var g=0;g<r.length;g++){var S=r[g];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(d,S.key,S)}}return function(d,r,g){return r&&o(d.prototype,r),g&&o(d,g),d}}(),O=function o(d,r,g){d===null&&(d=Function.prototype);var S=Object.getOwnPropertyDescriptor(d,r);if(S===void 0){var k=Object.getPrototypeOf(d);return k===null?void 0:o(k,r,g)}else{if("value"in S)return S.value;var A=S.get;return A===void 0?void 0:A.call(g)}},w=t(54),y=l(w),_=t(10),h=l(_);function l(o){return o&&o.__esModule?o:{default:o}}function e(o,d){if(!(o instanceof d))throw new TypeError("Cannot call a class as a function")}function n(o,d){if(!o)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return d&&(typeof d=="object"||typeof d=="function")?d:o}function u(o,d){if(typeof d!="function"&&d!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof d);o.prototype=Object.create(d&&d.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),d&&(Object.setPrototypeOf?Object.setPrototypeOf(o,d):o.__proto__=d)}var f=(0,h.default)("quill:events"),c=["selectionchange","mousedown","mouseup","click"];c.forEach(function(o){document.addEventListener(o,function(){for(var d=arguments.length,r=Array(d),g=0;g<d;g++)r[g]=arguments[g];[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(S){if(S.__quill&&S.__quill.emitter){var k;(k=S.__quill.emitter).handleDOM.apply(k,r)}})})});var a=function(o){u(d,o);function d(){e(this,d);var r=n(this,(d.__proto__||Object.getPrototypeOf(d)).call(this));return r.listeners={},r.on("error",f.error),r}return m(d,[{key:"emit",value:function(){f.log.apply(f,arguments),O(d.prototype.__proto__||Object.getPrototypeOf(d.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(g){for(var S=arguments.length,k=Array(S>1?S-1:0),A=1;A<S;A++)k[A-1]=arguments[A];(this.listeners[g.type]||[]).forEach(function(M){var T=M.node,b=M.handler;(g.target===T||T.contains(g.target))&&b.apply(void 0,[g].concat(k))})}},{key:"listenDOM",value:function(g,S,k){this.listeners[g]||(this.listeners[g]=[]),this.listeners[g].push({node:S,handler:k})}}]),d}(y.default);a.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},a.sources={API:"api",SILENT:"silent",USER:"user"},s.default=a},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});function m(w,y){if(!(w instanceof y))throw new TypeError("Cannot call a class as a function")}var O=function w(y){var _=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};m(this,w),this.quill=y,this.options=_};O.DEFAULTS={},s.default=O},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=["error","warn","log","info"],O="warn";function w(_){if(m.indexOf(_)<=m.indexOf(O)){for(var h,l=arguments.length,e=Array(l>1?l-1:0),n=1;n<l;n++)e[n-1]=arguments[n];(h=console)[_].apply(h,e)}}function y(_){return m.reduce(function(h,l){return h[l]=w.bind(console,l,_),h},{})}w.level=y.level=function(_){O=_},s.default=y},function(p,s,t){var m=Array.prototype.slice,O=t(52),w=t(53),y=p.exports=function(e,n,u){return u||(u={}),e===n?!0:e instanceof Date&&n instanceof Date?e.getTime()===n.getTime():!e||!n||typeof e!="object"&&typeof n!="object"?u.strict?e===n:e==n:l(e,n,u)};function _(e){return e==null}function h(e){return!(!e||typeof e!="object"||typeof e.length!="number"||typeof e.copy!="function"||typeof e.slice!="function"||e.length>0&&typeof e[0]!="number")}function l(e,n,u){var f,c;if(_(e)||_(n)||e.prototype!==n.prototype)return!1;if(w(e))return w(n)?(e=m.call(e),n=m.call(n),y(e,n,u)):!1;if(h(e)){if(!h(n)||e.length!==n.length)return!1;for(f=0;f<e.length;f++)if(e[f]!==n[f])return!1;return!0}try{var a=O(e),o=O(n)}catch{return!1}if(a.length!=o.length)return!1;for(a.sort(),o.sort(),f=a.length-1;f>=0;f--)if(a[f]!=o[f])return!1;for(f=a.length-1;f>=0;f--)if(c=a[f],!y(e[c],n[c],u))return!1;return typeof e==typeof n}},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(1),O=function(){function w(y,_,h){h===void 0&&(h={}),this.attrName=y,this.keyName=_;var l=m.Scope.TYPE&m.Scope.ATTRIBUTE;h.scope!=null?this.scope=h.scope&m.Scope.LEVEL|l:this.scope=m.Scope.ATTRIBUTE,h.whitelist!=null&&(this.whitelist=h.whitelist)}return w.keys=function(y){return[].map.call(y.attributes,function(_){return _.name})},w.prototype.add=function(y,_){return this.canAdd(y,_)?(y.setAttribute(this.keyName,_),!0):!1},w.prototype.canAdd=function(y,_){var h=m.query(y,m.Scope.BLOT&(this.scope|m.Scope.TYPE));return h==null?!1:this.whitelist==null?!0:typeof _=="string"?this.whitelist.indexOf(_.replace(/["']/g,""))>-1:this.whitelist.indexOf(_)>-1},w.prototype.remove=function(y){y.removeAttribute(this.keyName)},w.prototype.value=function(y){var _=y.getAttribute(this.keyName);return this.canAdd(y,_)&&_?_:""},w}();s.default=O},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.Code=void 0;var m=function(){function A(M,T){var b=[],E=!0,x=!1,q=void 0;try{for(var I=M[Symbol.iterator](),H;!(E=(H=I.next()).done)&&(b.push(H.value),!(T&&b.length===T));E=!0);}catch(K){x=!0,q=K}finally{try{!E&&I.return&&I.return()}finally{if(x)throw q}}return b}return function(M,T){if(Array.isArray(M))return M;if(Symbol.iterator in Object(M))return A(M,T);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function A(M,T){for(var b=0;b<T.length;b++){var E=T[b];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(M,E.key,E)}}return function(M,T,b){return T&&A(M.prototype,T),b&&A(M,b),M}}(),w=function A(M,T,b){M===null&&(M=Function.prototype);var E=Object.getOwnPropertyDescriptor(M,T);if(E===void 0){var x=Object.getPrototypeOf(M);return x===null?void 0:A(x,T,b)}else{if("value"in E)return E.value;var q=E.get;return q===void 0?void 0:q.call(b)}},y=t(2),_=o(y),h=t(0),l=o(h),e=t(4),n=o(e),u=t(6),f=o(u),c=t(7),a=o(c);function o(A){return A&&A.__esModule?A:{default:A}}function d(A,M){if(!(A instanceof M))throw new TypeError("Cannot call a class as a function")}function r(A,M){if(!A)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return M&&(typeof M=="object"||typeof M=="function")?M:A}function g(A,M){if(typeof M!="function"&&M!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof M);A.prototype=Object.create(M&&M.prototype,{constructor:{value:A,enumerable:!1,writable:!0,configurable:!0}}),M&&(Object.setPrototypeOf?Object.setPrototypeOf(A,M):A.__proto__=M)}var S=function(A){g(M,A);function M(){return d(this,M),r(this,(M.__proto__||Object.getPrototypeOf(M)).apply(this,arguments))}return M}(f.default);S.blotName="code",S.tagName="CODE";var k=function(A){g(M,A);function M(){return d(this,M),r(this,(M.__proto__||Object.getPrototypeOf(M)).apply(this,arguments))}return O(M,[{key:"delta",value:function(){var b=this,E=this.domNode.textContent;return E.endsWith(`
`)&&(E=E.slice(0,-1)),E.split(`
`).reduce(function(x,q){return x.insert(q).insert(`
`,b.formats())},new _.default)}},{key:"format",value:function(b,E){if(!(b===this.statics.blotName&&E)){var x=this.descendant(a.default,this.length()-1),q=m(x,1),I=q[0];I!=null&&I.deleteAt(I.length()-1,1),w(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"format",this).call(this,b,E)}}},{key:"formatAt",value:function(b,E,x,q){if(E!==0&&!(l.default.query(x,l.default.Scope.BLOCK)==null||x===this.statics.blotName&&q===this.statics.formats(this.domNode))){var I=this.newlineIndex(b);if(!(I<0||I>=b+E)){var H=this.newlineIndex(b,!0)+1,K=I-H+1,ee=this.isolate(H,K),V=ee.next;ee.format(x,q),V instanceof M&&V.formatAt(0,b-H+E-K,x,q)}}}},{key:"insertAt",value:function(b,E,x){if(x==null){var q=this.descendant(a.default,b),I=m(q,2),H=I[0],K=I[1];H.insertAt(K,E)}}},{key:"length",value:function(){var b=this.domNode.textContent.length;return this.domNode.textContent.endsWith(`
`)?b:b+1}},{key:"newlineIndex",value:function(b){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(E)return this.domNode.textContent.slice(0,b).lastIndexOf(`
`);var x=this.domNode.textContent.slice(b).indexOf(`
`);return x>-1?b+x:-1}},{key:"optimize",value:function(b){this.domNode.textContent.endsWith(`
`)||this.appendChild(l.default.create("text",`
`)),w(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"optimize",this).call(this,b);var E=this.next;E!=null&&E.prev===this&&E.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===E.statics.formats(E.domNode)&&(E.optimize(b),E.moveChildren(this),E.remove())}},{key:"replace",value:function(b){w(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"replace",this).call(this,b),[].slice.call(this.domNode.querySelectorAll("*")).forEach(function(E){var x=l.default.find(E);x==null?E.parentNode.removeChild(E):x instanceof l.default.Embed?x.remove():x.unwrap()})}}],[{key:"create",value:function(b){var E=w(M.__proto__||Object.getPrototypeOf(M),"create",this).call(this,b);return E.setAttribute("spellcheck",!1),E}},{key:"formats",value:function(){return!0}}]),M}(n.default);k.blotName="code-block",k.tagName="PRE",k.TAB="  ",s.Code=S,s.default=k},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(V){return typeof V}:function(V){return V&&typeof Symbol=="function"&&V.constructor===Symbol&&V!==Symbol.prototype?"symbol":typeof V},O=function(){function V(D,N){var j=[],P=!0,B=!1,F=void 0;try{for(var C=D[Symbol.iterator](),$;!(P=($=C.next()).done)&&(j.push($.value),!(N&&j.length===N));P=!0);}catch(z){B=!0,F=z}finally{try{!P&&C.return&&C.return()}finally{if(B)throw F}}return j}return function(D,N){if(Array.isArray(D))return D;if(Symbol.iterator in Object(D))return V(D,N);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),w=function(){function V(D,N){for(var j=0;j<N.length;j++){var P=N[j];P.enumerable=P.enumerable||!1,P.configurable=!0,"value"in P&&(P.writable=!0),Object.defineProperty(D,P.key,P)}}return function(D,N,j){return N&&V(D.prototype,N),j&&V(D,j),D}}(),y=t(2),_=E(y),h=t(20),l=E(h),e=t(0),n=E(e),u=t(13),f=E(u),c=t(24),a=E(c),o=t(4),d=E(o),r=t(16),g=E(r),S=t(21),k=E(S),A=t(11),M=E(A),T=t(3),b=E(T);function E(V){return V&&V.__esModule?V:{default:V}}function x(V,D,N){return D in V?Object.defineProperty(V,D,{value:N,enumerable:!0,configurable:!0,writable:!0}):V[D]=N,V}function q(V,D){if(!(V instanceof D))throw new TypeError("Cannot call a class as a function")}var I=/^[ -~]*$/,H=function(){function V(D){q(this,V),this.scroll=D,this.delta=this.getDelta()}return w(V,[{key:"applyDelta",value:function(N){var j=this,P=!1;this.scroll.update();var B=this.scroll.length();return this.scroll.batchStart(),N=ee(N),N.reduce(function(F,C){var $=C.retain||C.delete||C.insert.length||1,z=C.attributes||{};if(C.insert!=null){if(typeof C.insert=="string"){var G=C.insert;G.endsWith(`
`)&&P&&(P=!1,G=G.slice(0,-1)),F>=B&&!G.endsWith(`
`)&&(P=!0),j.scroll.insertAt(F,G);var J=j.scroll.line(F),fe=O(J,2),Q=fe[0],re=fe[1],se=(0,b.default)({},(0,o.bubbleFormats)(Q));if(Q instanceof d.default){var ce=Q.descendant(n.default.Leaf,re),Ee=O(ce,1),he=Ee[0];se=(0,b.default)(se,(0,o.bubbleFormats)(he))}z=l.default.attributes.diff(se,z)||{}}else if(m(C.insert)==="object"){var Z=Object.keys(C.insert)[0];if(Z==null)return F;j.scroll.insertAt(F,Z,C.insert[Z])}B+=$}return Object.keys(z).forEach(function(Y){j.scroll.formatAt(F,$,Y,z[Y])}),F+$},0),N.reduce(function(F,C){return typeof C.delete=="number"?(j.scroll.deleteAt(F,C.delete),F):F+(C.retain||C.insert.length||1)},0),this.scroll.batchEnd(),this.update(N)}},{key:"deleteText",value:function(N,j){return this.scroll.deleteAt(N,j),this.update(new _.default().retain(N).delete(j))}},{key:"formatLine",value:function(N,j){var P=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.scroll.update(),Object.keys(B).forEach(function(F){if(!(P.scroll.whitelist!=null&&!P.scroll.whitelist[F])){var C=P.scroll.lines(N,Math.max(j,1)),$=j;C.forEach(function(z){var G=z.length();if(!(z instanceof f.default))z.format(F,B[F]);else{var J=N-z.offset(P.scroll),fe=z.newlineIndex(J+$)-J+1;z.formatAt(J,fe,F,B[F])}$-=G})}}),this.scroll.optimize(),this.update(new _.default().retain(N).retain(j,(0,k.default)(B)))}},{key:"formatText",value:function(N,j){var P=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Object.keys(B).forEach(function(F){P.scroll.formatAt(N,j,F,B[F])}),this.update(new _.default().retain(N).retain(j,(0,k.default)(B)))}},{key:"getContents",value:function(N,j){return this.delta.slice(N,N+j)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce(function(N,j){return N.concat(j.delta())},new _.default)}},{key:"getFormat",value:function(N){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,P=[],B=[];j===0?this.scroll.path(N).forEach(function(C){var $=O(C,1),z=$[0];z instanceof d.default?P.push(z):z instanceof n.default.Leaf&&B.push(z)}):(P=this.scroll.lines(N,j),B=this.scroll.descendants(n.default.Leaf,N,j));var F=[P,B].map(function(C){if(C.length===0)return{};for(var $=(0,o.bubbleFormats)(C.shift());Object.keys($).length>0;){var z=C.shift();if(z==null)return $;$=K((0,o.bubbleFormats)(z),$)}return $});return b.default.apply(b.default,F)}},{key:"getText",value:function(N,j){return this.getContents(N,j).filter(function(P){return typeof P.insert=="string"}).map(function(P){return P.insert}).join("")}},{key:"insertEmbed",value:function(N,j,P){return this.scroll.insertAt(N,j,P),this.update(new _.default().retain(N).insert(x({},j,P)))}},{key:"insertText",value:function(N,j){var P=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return j=j.replace(/\r\n/g,`
`).replace(/\r/g,`
`),this.scroll.insertAt(N,j),Object.keys(B).forEach(function(F){P.scroll.formatAt(N,j.length,F,B[F])}),this.update(new _.default().retain(N).insert(j,(0,k.default)(B)))}},{key:"isBlank",value:function(){if(this.scroll.children.length==0)return!0;if(this.scroll.children.length>1)return!1;var N=this.scroll.children.head;return N.statics.blotName!==d.default.blotName||N.children.length>1?!1:N.children.head instanceof g.default}},{key:"removeFormat",value:function(N,j){var P=this.getText(N,j),B=this.scroll.line(N+j),F=O(B,2),C=F[0],$=F[1],z=0,G=new _.default;C!=null&&(C instanceof f.default?z=C.newlineIndex($)-$+1:z=C.length()-$,G=C.delta().slice($,$+z-1).insert(`
`));var J=this.getContents(N,j+z),fe=J.diff(new _.default().insert(P).concat(G)),Q=new _.default().retain(N).concat(fe);return this.applyDelta(Q)}},{key:"update",value:function(N){var j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],P=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,B=this.delta;if(j.length===1&&j[0].type==="characterData"&&j[0].target.data.match(I)&&n.default.find(j[0].target)){var F=n.default.find(j[0].target),C=(0,o.bubbleFormats)(F),$=F.offset(this.scroll),z=j[0].oldValue.replace(a.default.CONTENTS,""),G=new _.default().insert(z),J=new _.default().insert(F.value()),fe=new _.default().retain($).concat(G.diff(J,P));N=fe.reduce(function(Q,re){return re.insert?Q.insert(re.insert,C):Q.push(re)},new _.default),this.delta=B.compose(N)}else this.delta=this.getDelta(),(!N||!(0,M.default)(B.compose(N),this.delta))&&(N=B.diff(this.delta,P));return N}}]),V}();function K(V,D){return Object.keys(D).reduce(function(N,j){return V[j]==null||(D[j]===V[j]?N[j]=D[j]:Array.isArray(D[j])?D[j].indexOf(V[j])<0&&(N[j]=D[j].concat([V[j]])):N[j]=[D[j],V[j]]),N},{})}function ee(V){return V.reduce(function(D,N){if(N.insert===1){var j=(0,k.default)(N.attributes);return delete j.image,D.insert({image:N.attributes.image},j)}if(N.attributes!=null&&(N.attributes.list===!0||N.attributes.bullet===!0)&&(N=(0,k.default)(N),N.attributes.list?N.attributes.list="ordered":(N.attributes.list="bullet",delete N.attributes.bullet)),typeof N.insert=="string"){var P=N.insert.replace(/\r\n/g,`
`).replace(/\r/g,`
`);return D.insert(P,N.attributes)}return D.push(N)},new _.default)}s.default=H},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.Range=void 0;var m=function(){function A(M,T){var b=[],E=!0,x=!1,q=void 0;try{for(var I=M[Symbol.iterator](),H;!(E=(H=I.next()).done)&&(b.push(H.value),!(T&&b.length===T));E=!0);}catch(K){x=!0,q=K}finally{try{!E&&I.return&&I.return()}finally{if(x)throw q}}return b}return function(M,T){if(Array.isArray(M))return M;if(Symbol.iterator in Object(M))return A(M,T);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function A(M,T){for(var b=0;b<T.length;b++){var E=T[b];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(M,E.key,E)}}return function(M,T,b){return T&&A(M.prototype,T),b&&A(M,b),M}}(),w=t(0),y=a(w),_=t(21),h=a(_),l=t(11),e=a(l),n=t(8),u=a(n),f=t(10),c=a(f);function a(A){return A&&A.__esModule?A:{default:A}}function o(A){if(Array.isArray(A)){for(var M=0,T=Array(A.length);M<A.length;M++)T[M]=A[M];return T}else return Array.from(A)}function d(A,M){if(!(A instanceof M))throw new TypeError("Cannot call a class as a function")}var r=(0,c.default)("quill:selection"),g=function A(M){var T=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;d(this,A),this.index=M,this.length=T},S=function(){function A(M,T){var b=this;d(this,A),this.emitter=T,this.scroll=M,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=y.default.create("cursor",this),this.lastRange=this.savedRange=new g(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){b.mouseDown||setTimeout(b.update.bind(b,u.default.sources.USER),1)}),this.emitter.on(u.default.events.EDITOR_CHANGE,function(E,x){E===u.default.events.TEXT_CHANGE&&x.length()>0&&b.update(u.default.sources.SILENT)}),this.emitter.on(u.default.events.SCROLL_BEFORE_UPDATE,function(){if(!!b.hasFocus()){var E=b.getNativeRange();E!=null&&E.start.node!==b.cursor.textNode&&b.emitter.once(u.default.events.SCROLL_UPDATE,function(){try{b.setNativeRange(E.start.node,E.start.offset,E.end.node,E.end.offset)}catch{}})}}),this.emitter.on(u.default.events.SCROLL_OPTIMIZE,function(E,x){if(x.range){var q=x.range,I=q.startNode,H=q.startOffset,K=q.endNode,ee=q.endOffset;b.setNativeRange(I,H,K,ee)}}),this.update(u.default.sources.SILENT)}return O(A,[{key:"handleComposition",value:function(){var T=this;this.root.addEventListener("compositionstart",function(){T.composing=!0}),this.root.addEventListener("compositionend",function(){if(T.composing=!1,T.cursor.parent){var b=T.cursor.restore();if(!b)return;setTimeout(function(){T.setNativeRange(b.startNode,b.startOffset,b.endNode,b.endOffset)},1)}})}},{key:"handleDragging",value:function(){var T=this;this.emitter.listenDOM("mousedown",document.body,function(){T.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){T.mouseDown=!1,T.update(u.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(T,b){if(!(this.scroll.whitelist!=null&&!this.scroll.whitelist[T])){this.scroll.update();var E=this.getNativeRange();if(!(E==null||!E.native.collapsed||y.default.query(T,y.default.Scope.BLOCK))){if(E.start.node!==this.cursor.textNode){var x=y.default.find(E.start.node,!1);if(x==null)return;if(x instanceof y.default.Leaf){var q=x.split(E.start.offset);x.parent.insertBefore(this.cursor,q)}else x.insertBefore(this.cursor,E.start.node);this.cursor.attach()}this.cursor.format(T,b),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(T){var b=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,E=this.scroll.length();T=Math.min(T,E-1),b=Math.min(T+b,E-1)-T;var x=void 0,q=this.scroll.leaf(T),I=m(q,2),H=I[0],K=I[1];if(H==null)return null;var ee=H.position(K,!0),V=m(ee,2);x=V[0],K=V[1];var D=document.createRange();if(b>0){D.setStart(x,K);var N=this.scroll.leaf(T+b),j=m(N,2);if(H=j[0],K=j[1],H==null)return null;var P=H.position(K,!0),B=m(P,2);return x=B[0],K=B[1],D.setEnd(x,K),D.getBoundingClientRect()}else{var F="left",C=void 0;return x instanceof Text?(K<x.data.length?(D.setStart(x,K),D.setEnd(x,K+1)):(D.setStart(x,K-1),D.setEnd(x,K),F="right"),C=D.getBoundingClientRect()):(C=H.domNode.getBoundingClientRect(),K>0&&(F="right")),{bottom:C.top+C.height,height:C.height,left:C[F],right:C[F],top:C.top,width:0}}}},{key:"getNativeRange",value:function(){var T=document.getSelection();if(T==null||T.rangeCount<=0)return null;var b=T.getRangeAt(0);if(b==null)return null;var E=this.normalizeNative(b);return r.info("getNativeRange",E),E}},{key:"getRange",value:function(){var T=this.getNativeRange();if(T==null)return[null,null];var b=this.normalizedToRange(T);return[b,T]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(T){var b=this,E=[[T.start.node,T.start.offset]];T.native.collapsed||E.push([T.end.node,T.end.offset]);var x=E.map(function(H){var K=m(H,2),ee=K[0],V=K[1],D=y.default.find(ee,!0),N=D.offset(b.scroll);return V===0?N:D instanceof y.default.Container?N+D.length():N+D.index(ee,V)}),q=Math.min(Math.max.apply(Math,o(x)),this.scroll.length()-1),I=Math.min.apply(Math,[q].concat(o(x)));return new g(I,q-I)}},{key:"normalizeNative",value:function(T){if(!k(this.root,T.startContainer)||!T.collapsed&&!k(this.root,T.endContainer))return null;var b={start:{node:T.startContainer,offset:T.startOffset},end:{node:T.endContainer,offset:T.endOffset},native:T};return[b.start,b.end].forEach(function(E){for(var x=E.node,q=E.offset;!(x instanceof Text)&&x.childNodes.length>0;)if(x.childNodes.length>q)x=x.childNodes[q],q=0;else if(x.childNodes.length===q)x=x.lastChild,q=x instanceof Text?x.data.length:x.childNodes.length+1;else break;E.node=x,E.offset=q}),b}},{key:"rangeToNative",value:function(T){var b=this,E=T.collapsed?[T.index]:[T.index,T.index+T.length],x=[],q=this.scroll.length();return E.forEach(function(I,H){I=Math.min(q-1,I);var K=void 0,ee=b.scroll.leaf(I),V=m(ee,2),D=V[0],N=V[1],j=D.position(N,H!==0),P=m(j,2);K=P[0],N=P[1],x.push(K,N)}),x.length<2&&(x=x.concat(x)),x}},{key:"scrollIntoView",value:function(T){var b=this.lastRange;if(b!=null){var E=this.getBounds(b.index,b.length);if(E!=null){var x=this.scroll.length()-1,q=this.scroll.line(Math.min(b.index,x)),I=m(q,1),H=I[0],K=H;if(b.length>0){var ee=this.scroll.line(Math.min(b.index+b.length,x)),V=m(ee,1);K=V[0]}if(!(H==null||K==null)){var D=T.getBoundingClientRect();E.top<D.top?T.scrollTop-=D.top-E.top:E.bottom>D.bottom&&(T.scrollTop+=E.bottom-D.bottom)}}}}},{key:"setNativeRange",value:function(T,b){var E=arguments.length>2&&arguments[2]!==void 0?arguments[2]:T,x=arguments.length>3&&arguments[3]!==void 0?arguments[3]:b,q=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(r.info("setNativeRange",T,b,E,x),!(T!=null&&(this.root.parentNode==null||T.parentNode==null||E.parentNode==null))){var I=document.getSelection();if(I!=null)if(T!=null){this.hasFocus()||this.root.focus();var H=(this.getNativeRange()||{}).native;if(H==null||q||T!==H.startContainer||b!==H.startOffset||E!==H.endContainer||x!==H.endOffset){T.tagName=="BR"&&(b=[].indexOf.call(T.parentNode.childNodes,T),T=T.parentNode),E.tagName=="BR"&&(x=[].indexOf.call(E.parentNode.childNodes,E),E=E.parentNode);var K=document.createRange();K.setStart(T,b),K.setEnd(E,x),I.removeAllRanges(),I.addRange(K)}}else I.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(T){var b=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,E=arguments.length>2&&arguments[2]!==void 0?arguments[2]:u.default.sources.API;if(typeof b=="string"&&(E=b,b=!1),r.info("setRange",T),T!=null){var x=this.rangeToNative(T);this.setNativeRange.apply(this,o(x).concat([b]))}else this.setNativeRange(null);this.update(E)}},{key:"update",value:function(){var T=arguments.length>0&&arguments[0]!==void 0?arguments[0]:u.default.sources.USER,b=this.lastRange,E=this.getRange(),x=m(E,2),q=x[0],I=x[1];if(this.lastRange=q,this.lastRange!=null&&(this.savedRange=this.lastRange),!(0,e.default)(b,this.lastRange)){var H;!this.composing&&I!=null&&I.native.collapsed&&I.start.node!==this.cursor.textNode&&this.cursor.restore();var K=[u.default.events.SELECTION_CHANGE,(0,h.default)(this.lastRange),(0,h.default)(b),T];if((H=this.emitter).emit.apply(H,[u.default.events.EDITOR_CHANGE].concat(K)),T!==u.default.sources.SILENT){var ee;(ee=this.emitter).emit.apply(ee,K)}}}}]),A}();function k(A,M){try{M.parentNode}catch{return!1}return M instanceof Text&&(M=M.parentNode),A.contains(M)}s.Range=g,s.default=S},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function u(f,c){for(var a=0;a<c.length;a++){var o=c[a];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(f,o.key,o)}}return function(f,c,a){return c&&u(f.prototype,c),a&&u(f,a),f}}(),O=function u(f,c,a){f===null&&(f=Function.prototype);var o=Object.getOwnPropertyDescriptor(f,c);if(o===void 0){var d=Object.getPrototypeOf(f);return d===null?void 0:u(d,c,a)}else{if("value"in o)return o.value;var r=o.get;return r===void 0?void 0:r.call(a)}},w=t(0),y=_(w);function _(u){return u&&u.__esModule?u:{default:u}}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}function l(u,f){if(!u)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return f&&(typeof f=="object"||typeof f=="function")?f:u}function e(u,f){if(typeof f!="function"&&f!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof f);u.prototype=Object.create(f&&f.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),f&&(Object.setPrototypeOf?Object.setPrototypeOf(u,f):u.__proto__=f)}var n=function(u){e(f,u);function f(){return h(this,f),l(this,(f.__proto__||Object.getPrototypeOf(f)).apply(this,arguments))}return m(f,[{key:"insertInto",value:function(a,o){a.children.length===0?O(f.prototype.__proto__||Object.getPrototypeOf(f.prototype),"insertInto",this).call(this,a,o):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),f}(y.default.Embed);n.blotName="break",n.tagName="BR",s.default=n},function(p,s,t){var m=this&&this.__extends||function(){var l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var u in n)n.hasOwnProperty(u)&&(e[u]=n[u])};return function(e,n){l(e,n);function u(){this.constructor=e}e.prototype=n===null?Object.create(n):(u.prototype=n.prototype,new u)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(44),w=t(30),y=t(1),_=function(l){m(e,l);function e(n){var u=l.call(this,n)||this;return u.build(),u}return e.prototype.appendChild=function(n){this.insertBefore(n)},e.prototype.attach=function(){l.prototype.attach.call(this),this.children.forEach(function(n){n.attach()})},e.prototype.build=function(){var n=this;this.children=new O.default,[].slice.call(this.domNode.childNodes).reverse().forEach(function(u){try{var f=h(u);n.insertBefore(f,n.children.head||void 0)}catch(c){if(c instanceof y.ParchmentError)return;throw c}})},e.prototype.deleteAt=function(n,u){if(n===0&&u===this.length())return this.remove();this.children.forEachAt(n,u,function(f,c,a){f.deleteAt(c,a)})},e.prototype.descendant=function(n,u){var f=this.children.find(u),c=f[0],a=f[1];return n.blotName==null&&n(c)||n.blotName!=null&&c instanceof n?[c,a]:c instanceof e?c.descendant(n,a):[null,-1]},e.prototype.descendants=function(n,u,f){u===void 0&&(u=0),f===void 0&&(f=Number.MAX_VALUE);var c=[],a=f;return this.children.forEachAt(u,f,function(o,d,r){(n.blotName==null&&n(o)||n.blotName!=null&&o instanceof n)&&c.push(o),o instanceof e&&(c=c.concat(o.descendants(n,d,a))),a-=r}),c},e.prototype.detach=function(){this.children.forEach(function(n){n.detach()}),l.prototype.detach.call(this)},e.prototype.formatAt=function(n,u,f,c){this.children.forEachAt(n,u,function(a,o,d){a.formatAt(o,d,f,c)})},e.prototype.insertAt=function(n,u,f){var c=this.children.find(n),a=c[0],o=c[1];if(a)a.insertAt(o,u,f);else{var d=f==null?y.create("text",u):y.create(u,f);this.appendChild(d)}},e.prototype.insertBefore=function(n,u){if(this.statics.allowedChildren!=null&&!this.statics.allowedChildren.some(function(f){return n instanceof f}))throw new y.ParchmentError("Cannot insert "+n.statics.blotName+" into "+this.statics.blotName);n.insertInto(this,u)},e.prototype.length=function(){return this.children.reduce(function(n,u){return n+u.length()},0)},e.prototype.moveChildren=function(n,u){this.children.forEach(function(f){n.insertBefore(f,u)})},e.prototype.optimize=function(n){if(l.prototype.optimize.call(this,n),this.children.length===0)if(this.statics.defaultChild!=null){var u=y.create(this.statics.defaultChild);this.appendChild(u),u.optimize(n)}else this.remove()},e.prototype.path=function(n,u){u===void 0&&(u=!1);var f=this.children.find(n,u),c=f[0],a=f[1],o=[[this,n]];return c instanceof e?o.concat(c.path(a,u)):(c!=null&&o.push([c,a]),o)},e.prototype.removeChild=function(n){this.children.remove(n)},e.prototype.replace=function(n){n instanceof e&&n.moveChildren(this),l.prototype.replace.call(this,n)},e.prototype.split=function(n,u){if(u===void 0&&(u=!1),!u){if(n===0)return this;if(n===this.length())return this.next}var f=this.clone();return this.parent.insertBefore(f,this.next),this.children.forEachAt(n,this.length(),function(c,a,o){c=c.split(a,u),f.appendChild(c)}),f},e.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},e.prototype.update=function(n,u){var f=this,c=[],a=[];n.forEach(function(o){o.target===f.domNode&&o.type==="childList"&&(c.push.apply(c,o.addedNodes),a.push.apply(a,o.removedNodes))}),a.forEach(function(o){if(!(o.parentNode!=null&&o.tagName!=="IFRAME"&&document.body.compareDocumentPosition(o)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var d=y.find(o);d!=null&&(d.domNode.parentNode==null||d.domNode.parentNode===f.domNode)&&d.detach()}}),c.filter(function(o){return o.parentNode==f.domNode}).sort(function(o,d){return o===d?0:o.compareDocumentPosition(d)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1}).forEach(function(o){var d=null;o.nextSibling!=null&&(d=y.find(o.nextSibling));var r=h(o);(r.next!=d||r.next==null)&&(r.parent!=null&&r.parent.removeChild(f),f.insertBefore(r,d||void 0))})},e}(w.default);function h(l){var e=y.find(l);if(e==null)try{e=y.create(l)}catch{e=y.create(y.Scope.INLINE),[].slice.call(l.childNodes).forEach(function(u){e.domNode.appendChild(u)}),l.parentNode&&l.parentNode.replaceChild(e.domNode,l),e.attach()}return e}s.default=_},function(p,s,t){var m=this&&this.__extends||function(){var l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var u in n)n.hasOwnProperty(u)&&(e[u]=n[u])};return function(e,n){l(e,n);function u(){this.constructor=e}e.prototype=n===null?Object.create(n):(u.prototype=n.prototype,new u)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(12),w=t(31),y=t(17),_=t(1),h=function(l){m(e,l);function e(n){var u=l.call(this,n)||this;return u.attributes=new w.default(u.domNode),u}return e.formats=function(n){if(typeof this.tagName=="string")return!0;if(Array.isArray(this.tagName))return n.tagName.toLowerCase()},e.prototype.format=function(n,u){var f=_.query(n);f instanceof O.default?this.attributes.attribute(f,u):u&&f!=null&&(n!==this.statics.blotName||this.formats()[n]!==u)&&this.replaceWith(n,u)},e.prototype.formats=function(){var n=this.attributes.values(),u=this.statics.formats(this.domNode);return u!=null&&(n[this.statics.blotName]=u),n},e.prototype.replaceWith=function(n,u){var f=l.prototype.replaceWith.call(this,n,u);return this.attributes.copy(f),f},e.prototype.update=function(n,u){var f=this;l.prototype.update.call(this,n,u),n.some(function(c){return c.target===f.domNode&&c.type==="attributes"})&&this.attributes.build()},e.prototype.wrap=function(n,u){var f=l.prototype.wrap.call(this,n,u);return f instanceof e&&f.statics.scope===this.statics.scope&&this.attributes.move(f),f},e}(y.default);s.default=h},function(p,s,t){var m=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,l){h.__proto__=l}||function(h,l){for(var e in l)l.hasOwnProperty(e)&&(h[e]=l[e])};return function(h,l){_(h,l);function e(){this.constructor=h}h.prototype=l===null?Object.create(l):(e.prototype=l.prototype,new e)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(30),w=t(1),y=function(_){m(h,_);function h(){return _!==null&&_.apply(this,arguments)||this}return h.value=function(l){return!0},h.prototype.index=function(l,e){return this.domNode===l||this.domNode.compareDocumentPosition(l)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(e,1):-1},h.prototype.position=function(l,e){var n=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return l>0&&(n+=1),[this.parent.domNode,n]},h.prototype.value=function(){var l;return l={},l[this.statics.blotName]=this.statics.value(this.domNode)||!0,l},h.scope=w.Scope.INLINE_BLOT,h}(O.default);s.default=y},function(p,s,t){var m=t(11),O=t(3),w={attributes:{compose:function(_,h,l){typeof _!="object"&&(_={}),typeof h!="object"&&(h={});var e=O(!0,{},h);l||(e=Object.keys(e).reduce(function(u,f){return e[f]!=null&&(u[f]=e[f]),u},{}));for(var n in _)_[n]!==void 0&&h[n]===void 0&&(e[n]=_[n]);return Object.keys(e).length>0?e:void 0},diff:function(_,h){typeof _!="object"&&(_={}),typeof h!="object"&&(h={});var l=Object.keys(_).concat(Object.keys(h)).reduce(function(e,n){return m(_[n],h[n])||(e[n]=h[n]===void 0?null:h[n]),e},{});return Object.keys(l).length>0?l:void 0},transform:function(_,h,l){if(typeof _!="object")return h;if(typeof h=="object"){if(!l)return h;var e=Object.keys(h).reduce(function(n,u){return _[u]===void 0&&(n[u]=h[u]),n},{});return Object.keys(e).length>0?e:void 0}}},iterator:function(_){return new y(_)},length:function(_){return typeof _.delete=="number"?_.delete:typeof _.retain=="number"?_.retain:typeof _.insert=="string"?_.insert.length:1}};function y(_){this.ops=_,this.index=0,this.offset=0}y.prototype.hasNext=function(){return this.peekLength()<1/0},y.prototype.next=function(_){_||(_=1/0);var h=this.ops[this.index];if(h){var l=this.offset,e=w.length(h);if(_>=e-l?(_=e-l,this.index+=1,this.offset=0):this.offset+=_,typeof h.delete=="number")return{delete:_};var n={};return h.attributes&&(n.attributes=h.attributes),typeof h.retain=="number"?n.retain=_:typeof h.insert=="string"?n.insert=h.insert.substr(l,_):n.insert=h.insert,n}else return{retain:1/0}},y.prototype.peek=function(){return this.ops[this.index]},y.prototype.peekLength=function(){return this.ops[this.index]?w.length(this.ops[this.index])-this.offset:1/0},y.prototype.peekType=function(){return this.ops[this.index]?typeof this.ops[this.index].delete=="number"?"delete":typeof this.ops[this.index].retain=="number"?"retain":"insert":"retain"},y.prototype.rest=function(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);var _=this.offset,h=this.index,l=this.next(),e=this.ops.slice(this.index);return this.offset=_,this.index=h,[l].concat(e)}else return[]},p.exports=w},function(p,s){var t=function(){function m(f,c){return c!=null&&f instanceof c}var O;try{O=Map}catch{O=function(){}}var w;try{w=Set}catch{w=function(){}}var y;try{y=Promise}catch{y=function(){}}function _(f,c,a,o,d){typeof c=="object"&&(a=c.depth,o=c.prototype,d=c.includeNonEnumerable,c=c.circular);var r=[],g=[],S=typeof Buffer!="undefined";typeof c=="undefined"&&(c=!0),typeof a=="undefined"&&(a=1/0);function k(A,M){if(A===null)return null;if(M===0)return A;var T,b;if(typeof A!="object")return A;if(m(A,O))T=new O;else if(m(A,w))T=new w;else if(m(A,y))T=new y(function(D,N){A.then(function(j){D(k(j,M-1))},function(j){N(k(j,M-1))})});else if(_.__isArray(A))T=[];else if(_.__isRegExp(A))T=new RegExp(A.source,u(A)),A.lastIndex&&(T.lastIndex=A.lastIndex);else if(_.__isDate(A))T=new Date(A.getTime());else{if(S&&Buffer.isBuffer(A))return Buffer.allocUnsafe?T=Buffer.allocUnsafe(A.length):T=new Buffer(A.length),A.copy(T),T;m(A,Error)?T=Object.create(A):typeof o=="undefined"?(b=Object.getPrototypeOf(A),T=Object.create(b)):(T=Object.create(o),b=o)}if(c){var E=r.indexOf(A);if(E!=-1)return g[E];r.push(A),g.push(T)}m(A,O)&&A.forEach(function(D,N){var j=k(N,M-1),P=k(D,M-1);T.set(j,P)}),m(A,w)&&A.forEach(function(D){var N=k(D,M-1);T.add(N)});for(var x in A){var q;b&&(q=Object.getOwnPropertyDescriptor(b,x)),!(q&&q.set==null)&&(T[x]=k(A[x],M-1))}if(Object.getOwnPropertySymbols)for(var I=Object.getOwnPropertySymbols(A),x=0;x<I.length;x++){var H=I[x],K=Object.getOwnPropertyDescriptor(A,H);K&&!K.enumerable&&!d||(T[H]=k(A[H],M-1),K.enumerable||Object.defineProperty(T,H,{enumerable:!1}))}if(d)for(var ee=Object.getOwnPropertyNames(A),x=0;x<ee.length;x++){var V=ee[x],K=Object.getOwnPropertyDescriptor(A,V);K&&K.enumerable||(T[V]=k(A[V],M-1),Object.defineProperty(T,V,{enumerable:!1}))}return T}return k(f,a)}_.clonePrototype=function(c){if(c===null)return null;var a=function(){};return a.prototype=c,new a};function h(f){return Object.prototype.toString.call(f)}_.__objToStr=h;function l(f){return typeof f=="object"&&h(f)==="[object Date]"}_.__isDate=l;function e(f){return typeof f=="object"&&h(f)==="[object Array]"}_.__isArray=e;function n(f){return typeof f=="object"&&h(f)==="[object RegExp]"}_.__isRegExp=n;function u(f){var c="";return f.global&&(c+="g"),f.ignoreCase&&(c+="i"),f.multiline&&(c+="m"),c}return _.__getRegExpFlags=u,_}();typeof p=="object"&&p.exports&&(p.exports=t)},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function T(b,E){var x=[],q=!0,I=!1,H=void 0;try{for(var K=b[Symbol.iterator](),ee;!(q=(ee=K.next()).done)&&(x.push(ee.value),!(E&&x.length===E));q=!0);}catch(V){I=!0,H=V}finally{try{!q&&K.return&&K.return()}finally{if(I)throw H}}return x}return function(b,E){if(Array.isArray(b))return b;if(Symbol.iterator in Object(b))return T(b,E);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function T(b,E){for(var x=0;x<E.length;x++){var q=E[x];q.enumerable=q.enumerable||!1,q.configurable=!0,"value"in q&&(q.writable=!0),Object.defineProperty(b,q.key,q)}}return function(b,E,x){return E&&T(b.prototype,E),x&&T(b,x),b}}(),w=function T(b,E,x){b===null&&(b=Function.prototype);var q=Object.getOwnPropertyDescriptor(b,E);if(q===void 0){var I=Object.getPrototypeOf(b);return I===null?void 0:T(I,E,x)}else{if("value"in q)return q.value;var H=q.get;return H===void 0?void 0:H.call(x)}},y=t(0),_=r(y),h=t(8),l=r(h),e=t(4),n=r(e),u=t(16),f=r(u),c=t(13),a=r(c),o=t(25),d=r(o);function r(T){return T&&T.__esModule?T:{default:T}}function g(T,b){if(!(T instanceof b))throw new TypeError("Cannot call a class as a function")}function S(T,b){if(!T)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:T}function k(T,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);T.prototype=Object.create(b&&b.prototype,{constructor:{value:T,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(T,b):T.__proto__=b)}function A(T){return T instanceof n.default||T instanceof e.BlockEmbed}var M=function(T){k(b,T);function b(E,x){g(this,b);var q=S(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,E));return q.emitter=x.emitter,Array.isArray(x.whitelist)&&(q.whitelist=x.whitelist.reduce(function(I,H){return I[H]=!0,I},{})),q.domNode.addEventListener("DOMNodeInserted",function(){}),q.optimize(),q.enable(),q}return O(b,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(x,q){var I=this.line(x),H=m(I,2),K=H[0],ee=H[1],V=this.line(x+q),D=m(V,1),N=D[0];if(w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"deleteAt",this).call(this,x,q),N!=null&&K!==N&&ee>0){if(K instanceof e.BlockEmbed||N instanceof e.BlockEmbed){this.optimize();return}if(K instanceof a.default){var j=K.newlineIndex(K.length(),!0);if(j>-1&&(K=K.split(j+1),K===N)){this.optimize();return}}else if(N instanceof a.default){var P=N.newlineIndex(0);P>-1&&N.split(P+1)}var B=N.children.head instanceof f.default?null:N.children.head;K.moveChildren(N,B),K.remove()}this.optimize()}},{key:"enable",value:function(){var x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.domNode.setAttribute("contenteditable",x)}},{key:"formatAt",value:function(x,q,I,H){this.whitelist!=null&&!this.whitelist[I]||(w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"formatAt",this).call(this,x,q,I,H),this.optimize())}},{key:"insertAt",value:function(x,q,I){if(!(I!=null&&this.whitelist!=null&&!this.whitelist[q])){if(x>=this.length())if(I==null||_.default.query(q,_.default.Scope.BLOCK)==null){var H=_.default.create(this.statics.defaultChild);this.appendChild(H),I==null&&q.endsWith(`
`)&&(q=q.slice(0,-1)),H.insertAt(0,q,I)}else{var K=_.default.create(q,I);this.appendChild(K)}else w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"insertAt",this).call(this,x,q,I);this.optimize()}}},{key:"insertBefore",value:function(x,q){if(x.statics.scope===_.default.Scope.INLINE_BLOT){var I=_.default.create(this.statics.defaultChild);I.appendChild(x),x=I}w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"insertBefore",this).call(this,x,q)}},{key:"leaf",value:function(x){return this.path(x).pop()||[null,-1]}},{key:"line",value:function(x){return x===this.length()?this.line(x-1):this.descendant(A,x)}},{key:"lines",value:function(){var x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE,I=function H(K,ee,V){var D=[],N=V;return K.children.forEachAt(ee,V,function(j,P,B){A(j)?D.push(j):j instanceof _.default.Container&&(D=D.concat(H(j,P,N))),N-=B}),D};return I(this,x,q)}},{key:"optimize",value:function(){var x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.batch!==!0&&(w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"optimize",this).call(this,x,q),x.length>0&&this.emitter.emit(l.default.events.SCROLL_OPTIMIZE,x,q))}},{key:"path",value:function(x){return w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"path",this).call(this,x).slice(1)}},{key:"update",value:function(x){if(this.batch!==!0){var q=l.default.sources.USER;typeof x=="string"&&(q=x),Array.isArray(x)||(x=this.observer.takeRecords()),x.length>0&&this.emitter.emit(l.default.events.SCROLL_BEFORE_UPDATE,q,x),w(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"update",this).call(this,x.concat([])),x.length>0&&this.emitter.emit(l.default.events.SCROLL_UPDATE,q,x)}}}]),b}(_.default.Scroll);M.blotName="scroll",M.className="ql-editor",M.tagName="DIV",M.defaultChild="block",M.allowedChildren=[n.default,e.BlockEmbed,d.default],s.default=M},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.SHORTKEY=s.default=void 0;var m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(C){return typeof C}:function(C){return C&&typeof Symbol=="function"&&C.constructor===Symbol&&C!==Symbol.prototype?"symbol":typeof C},O=function(){function C($,z){var G=[],J=!0,fe=!1,Q=void 0;try{for(var re=$[Symbol.iterator](),se;!(J=(se=re.next()).done)&&(G.push(se.value),!(z&&G.length===z));J=!0);}catch(ce){fe=!0,Q=ce}finally{try{!J&&re.return&&re.return()}finally{if(fe)throw Q}}return G}return function($,z){if(Array.isArray($))return $;if(Symbol.iterator in Object($))return C($,z);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),w=function(){function C($,z){for(var G=0;G<z.length;G++){var J=z[G];J.enumerable=J.enumerable||!1,J.configurable=!0,"value"in J&&(J.writable=!0),Object.defineProperty($,J.key,J)}}return function($,z,G){return z&&C($.prototype,z),G&&C($,G),$}}(),y=t(21),_=T(y),h=t(11),l=T(h),e=t(3),n=T(e),u=t(2),f=T(u),c=t(20),a=T(c),o=t(0),d=T(o),r=t(5),g=T(r),S=t(10),k=T(S),A=t(9),M=T(A);function T(C){return C&&C.__esModule?C:{default:C}}function b(C,$,z){return $ in C?Object.defineProperty(C,$,{value:z,enumerable:!0,configurable:!0,writable:!0}):C[$]=z,C}function E(C,$){if(!(C instanceof $))throw new TypeError("Cannot call a class as a function")}function x(C,$){if(!C)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return $&&(typeof $=="object"||typeof $=="function")?$:C}function q(C,$){if(typeof $!="function"&&$!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof $);C.prototype=Object.create($&&$.prototype,{constructor:{value:C,enumerable:!1,writable:!0,configurable:!0}}),$&&(Object.setPrototypeOf?Object.setPrototypeOf(C,$):C.__proto__=$)}var I=(0,k.default)("quill:keyboard"),H=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey",K=function(C){q($,C),w($,null,[{key:"match",value:function(G,J){return J=F(J),["altKey","ctrlKey","metaKey","shiftKey"].some(function(fe){return!!J[fe]!==G[fe]&&J[fe]!==null})?!1:J.key===(G.which||G.keyCode)}}]);function $(z,G){E(this,$);var J=x(this,($.__proto__||Object.getPrototypeOf($)).call(this,z,G));return J.bindings={},Object.keys(J.options.bindings).forEach(function(fe){fe==="list autofill"&&z.scroll.whitelist!=null&&!z.scroll.whitelist.list||J.options.bindings[fe]&&J.addBinding(J.options.bindings[fe])}),J.addBinding({key:$.keys.ENTER,shiftKey:null},j),J.addBinding({key:$.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},function(){}),/Firefox/i.test(navigator.userAgent)?(J.addBinding({key:$.keys.BACKSPACE},{collapsed:!0},V),J.addBinding({key:$.keys.DELETE},{collapsed:!0},D)):(J.addBinding({key:$.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},V),J.addBinding({key:$.keys.DELETE},{collapsed:!0,suffix:/^.?$/},D)),J.addBinding({key:$.keys.BACKSPACE},{collapsed:!1},N),J.addBinding({key:$.keys.DELETE},{collapsed:!1},N),J.addBinding({key:$.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},V),J.listen(),J}return w($,[{key:"addBinding",value:function(G){var J=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},fe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Q=F(G);if(Q==null||Q.key==null)return I.warn("Attempted to add invalid keyboard binding",Q);typeof J=="function"&&(J={handler:J}),typeof fe=="function"&&(fe={handler:fe}),Q=(0,n.default)(Q,J,fe),this.bindings[Q.key]=this.bindings[Q.key]||[],this.bindings[Q.key].push(Q)}},{key:"listen",value:function(){var G=this;this.quill.root.addEventListener("keydown",function(J){if(!J.defaultPrevented){var fe=J.which||J.keyCode,Q=(G.bindings[fe]||[]).filter(function(be){return $.match(J,be)});if(Q.length!==0){var re=G.quill.getSelection();if(!(re==null||!G.quill.hasFocus())){var se=G.quill.getLine(re.index),ce=O(se,2),Ee=ce[0],he=ce[1],Z=G.quill.getLeaf(re.index),Y=O(Z,2),ie=Y[0],ue=Y[1],W=re.length===0?[ie,ue]:G.quill.getLeaf(re.index+re.length),te=O(W,2),ae=te[0],de=te[1],we=ie instanceof d.default.Text?ie.value().slice(0,ue):"",ye=ae instanceof d.default.Text?ae.value().slice(de):"",ve={collapsed:re.length===0,empty:re.length===0&&Ee.length()<=1,format:G.quill.getFormat(re),offset:he,prefix:we,suffix:ye},Ne=Q.some(function(be){if(be.collapsed!=null&&be.collapsed!==ve.collapsed||be.empty!=null&&be.empty!==ve.empty||be.offset!=null&&be.offset!==ve.offset)return!1;if(Array.isArray(be.format)){if(be.format.every(function(Ce){return ve.format[Ce]==null}))return!1}else if(m(be.format)==="object"&&!Object.keys(be.format).every(function(Ce){return be.format[Ce]===!0?ve.format[Ce]!=null:be.format[Ce]===!1?ve.format[Ce]==null:(0,l.default)(be.format[Ce],ve.format[Ce])}))return!1;return be.prefix!=null&&!be.prefix.test(ve.prefix)||be.suffix!=null&&!be.suffix.test(ve.suffix)?!1:be.handler.call(G,re,ve)!==!0});Ne&&J.preventDefault()}}}})}}]),$}(M.default);K.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},K.DEFAULTS={bindings:{bold:B("bold"),italic:B("italic"),underline:B("underline"),indent:{key:K.keys.TAB,format:["blockquote","indent","list"],handler:function($,z){if(z.collapsed&&z.offset!==0)return!0;this.quill.format("indent","+1",g.default.sources.USER)}},outdent:{key:K.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function($,z){if(z.collapsed&&z.offset!==0)return!0;this.quill.format("indent","-1",g.default.sources.USER)}},"outdent backspace":{key:K.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function($,z){z.format.indent!=null?this.quill.format("indent","-1",g.default.sources.USER):z.format.list!=null&&this.quill.format("list",!1,g.default.sources.USER)}},"indent code-block":P(!0),"outdent code-block":P(!1),"remove tab":{key:K.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function($){this.quill.deleteText($.index-1,1,g.default.sources.USER)}},tab:{key:K.keys.TAB,handler:function($){this.quill.history.cutoff();var z=new f.default().retain($.index).delete($.length).insert("	");this.quill.updateContents(z,g.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection($.index+1,g.default.sources.SILENT)}},"list empty enter":{key:K.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function($,z){this.quill.format("list",!1,g.default.sources.USER),z.format.indent&&this.quill.format("indent",!1,g.default.sources.USER)}},"checklist enter":{key:K.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function($){var z=this.quill.getLine($.index),G=O(z,2),J=G[0],fe=G[1],Q=(0,n.default)({},J.formats(),{list:"checked"}),re=new f.default().retain($.index).insert(`
`,Q).retain(J.length()-fe-1).retain(1,{list:"unchecked"});this.quill.updateContents(re,g.default.sources.USER),this.quill.setSelection($.index+1,g.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:K.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function($,z){var G=this.quill.getLine($.index),J=O(G,2),fe=J[0],Q=J[1],re=new f.default().retain($.index).insert(`
`,z.format).retain(fe.length()-Q-1).retain(1,{header:null});this.quill.updateContents(re,g.default.sources.USER),this.quill.setSelection($.index+1,g.default.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function($,z){var G=z.prefix.length,J=this.quill.getLine($.index),fe=O(J,2),Q=fe[0],re=fe[1];if(re>G)return!0;var se=void 0;switch(z.prefix.trim()){case"[]":case"[ ]":se="unchecked";break;case"[x]":se="checked";break;case"-":case"*":se="bullet";break;default:se="ordered"}this.quill.insertText($.index," ",g.default.sources.USER),this.quill.history.cutoff();var ce=new f.default().retain($.index-re).delete(G+1).retain(Q.length()-2-re).retain(1,{list:se});this.quill.updateContents(ce,g.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection($.index-G,g.default.sources.SILENT)}},"code exit":{key:K.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function($){var z=this.quill.getLine($.index),G=O(z,2),J=G[0],fe=G[1],Q=new f.default().retain($.index+J.length()-fe-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(Q,g.default.sources.USER)}},"embed left":ee(K.keys.LEFT,!1),"embed left shift":ee(K.keys.LEFT,!0),"embed right":ee(K.keys.RIGHT,!1),"embed right shift":ee(K.keys.RIGHT,!0)}};function ee(C,$){var z,G=C===K.keys.LEFT?"prefix":"suffix";return z={key:C,shiftKey:$,altKey:null},b(z,G,/^$/),b(z,"handler",function(fe){var Q=fe.index;C===K.keys.RIGHT&&(Q+=fe.length+1);var re=this.quill.getLeaf(Q),se=O(re,1),ce=se[0];return ce instanceof d.default.Embed?(C===K.keys.LEFT?$?this.quill.setSelection(fe.index-1,fe.length+1,g.default.sources.USER):this.quill.setSelection(fe.index-1,g.default.sources.USER):$?this.quill.setSelection(fe.index,fe.length+1,g.default.sources.USER):this.quill.setSelection(fe.index+fe.length+1,g.default.sources.USER),!1):!0}),z}function V(C,$){if(!(C.index===0||this.quill.getLength()<=1)){var z=this.quill.getLine(C.index),G=O(z,1),J=G[0],fe={};if($.offset===0){var Q=this.quill.getLine(C.index-1),re=O(Q,1),se=re[0];if(se!=null&&se.length()>1){var ce=J.formats(),Ee=this.quill.getFormat(C.index-1,1);fe=a.default.attributes.diff(ce,Ee)||{}}}var he=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test($.prefix)?2:1;this.quill.deleteText(C.index-he,he,g.default.sources.USER),Object.keys(fe).length>0&&this.quill.formatLine(C.index-he,he,fe,g.default.sources.USER),this.quill.focus()}}function D(C,$){var z=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test($.suffix)?2:1;if(!(C.index>=this.quill.getLength()-z)){var G={},J=0,fe=this.quill.getLine(C.index),Q=O(fe,1),re=Q[0];if($.offset>=re.length()-1){var se=this.quill.getLine(C.index+1),ce=O(se,1),Ee=ce[0];if(Ee){var he=re.formats(),Z=this.quill.getFormat(C.index,1);G=a.default.attributes.diff(he,Z)||{},J=Ee.length()}}this.quill.deleteText(C.index,z,g.default.sources.USER),Object.keys(G).length>0&&this.quill.formatLine(C.index+J-1,z,G,g.default.sources.USER)}}function N(C){var $=this.quill.getLines(C),z={};if($.length>1){var G=$[0].formats(),J=$[$.length-1].formats();z=a.default.attributes.diff(J,G)||{}}this.quill.deleteText(C,g.default.sources.USER),Object.keys(z).length>0&&this.quill.formatLine(C.index,1,z,g.default.sources.USER),this.quill.setSelection(C.index,g.default.sources.SILENT),this.quill.focus()}function j(C,$){var z=this;C.length>0&&this.quill.scroll.deleteAt(C.index,C.length);var G=Object.keys($.format).reduce(function(J,fe){return d.default.query(fe,d.default.Scope.BLOCK)&&!Array.isArray($.format[fe])&&(J[fe]=$.format[fe]),J},{});this.quill.insertText(C.index,`
`,G,g.default.sources.USER),this.quill.setSelection(C.index+1,g.default.sources.SILENT),this.quill.focus(),Object.keys($.format).forEach(function(J){G[J]==null&&(Array.isArray($.format[J])||J!=="link"&&z.quill.format(J,$.format[J],g.default.sources.USER))})}function P(C){return{key:K.keys.TAB,shiftKey:!C,format:{"code-block":!0},handler:function(z){var G=d.default.query("code-block"),J=z.index,fe=z.length,Q=this.quill.scroll.descendant(G,J),re=O(Q,2),se=re[0],ce=re[1];if(se!=null){var Ee=this.quill.getIndex(se),he=se.newlineIndex(ce,!0)+1,Z=se.newlineIndex(Ee+ce+fe),Y=se.domNode.textContent.slice(he,Z).split(`
`);ce=0,Y.forEach(function(ie,ue){C?(se.insertAt(he+ce,G.TAB),ce+=G.TAB.length,ue===0?J+=G.TAB.length:fe+=G.TAB.length):ie.startsWith(G.TAB)&&(se.deleteAt(he+ce,G.TAB.length),ce-=G.TAB.length,ue===0?J-=G.TAB.length:fe-=G.TAB.length),ce+=ie.length+1}),this.quill.update(g.default.sources.USER),this.quill.setSelection(J,fe,g.default.sources.SILENT)}}}}function B(C){return{key:C[0].toUpperCase(),shortKey:!0,handler:function(z,G){this.quill.format(C,!G.format[C],g.default.sources.USER)}}}function F(C){if(typeof C=="string"||typeof C=="number")return F({key:C});if((typeof C=="undefined"?"undefined":m(C))==="object"&&(C=(0,_.default)(C,!1)),typeof C.key=="string")if(K.keys[C.key.toUpperCase()]!=null)C.key=K.keys[C.key.toUpperCase()];else if(C.key.length===1)C.key=C.key.toUpperCase().charCodeAt(0);else return null;return C.shortKey&&(C[H]=C.shortKey,delete C.shortKey),C}s.default=K,s.SHORTKEY=H},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function a(o,d){var r=[],g=!0,S=!1,k=void 0;try{for(var A=o[Symbol.iterator](),M;!(g=(M=A.next()).done)&&(r.push(M.value),!(d&&r.length===d));g=!0);}catch(T){S=!0,k=T}finally{try{!g&&A.return&&A.return()}finally{if(S)throw k}}return r}return function(o,d){if(Array.isArray(o))return o;if(Symbol.iterator in Object(o))return a(o,d);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function a(o,d,r){o===null&&(o=Function.prototype);var g=Object.getOwnPropertyDescriptor(o,d);if(g===void 0){var S=Object.getPrototypeOf(o);return S===null?void 0:a(S,d,r)}else{if("value"in g)return g.value;var k=g.get;return k===void 0?void 0:k.call(r)}},w=function(){function a(o,d){for(var r=0;r<d.length;r++){var g=d[r];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(o,g.key,g)}}return function(o,d,r){return d&&a(o.prototype,d),r&&a(o,r),o}}(),y=t(0),_=e(y),h=t(7),l=e(h);function e(a){return a&&a.__esModule?a:{default:a}}function n(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function u(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var c=function(a){f(o,a),w(o,null,[{key:"value",value:function(){}}]);function o(d,r){n(this,o);var g=u(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,d));return g.selection=r,g.textNode=document.createTextNode(o.CONTENTS),g.domNode.appendChild(g.textNode),g._length=0,g}return w(o,[{key:"detach",value:function(){this.parent!=null&&this.parent.removeChild(this)}},{key:"format",value:function(r,g){if(this._length!==0)return O(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"format",this).call(this,r,g);for(var S=this,k=0;S!=null&&S.statics.scope!==_.default.Scope.BLOCK_BLOT;)k+=S.offset(S.parent),S=S.parent;S!=null&&(this._length=o.CONTENTS.length,S.optimize(),S.formatAt(k,o.CONTENTS.length,r,g),this._length=0)}},{key:"index",value:function(r,g){return r===this.textNode?0:O(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"index",this).call(this,r,g)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){O(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!(this.selection.composing||this.parent==null)){var r=this.textNode,g=this.selection.getNativeRange(),S=void 0,k=void 0,A=void 0;if(g!=null&&g.start.node===r&&g.end.node===r){var M=[r,g.start.offset,g.end.offset];S=M[0],k=M[1],A=M[2]}for(;this.domNode.lastChild!=null&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==o.CONTENTS){var T=this.textNode.data.split(o.CONTENTS).join("");this.next instanceof l.default?(S=this.next.domNode,this.next.insertAt(0,T),this.textNode.data=o.CONTENTS):(this.textNode.data=T,this.parent.insertBefore(_.default.create(this.textNode),this),this.textNode=document.createTextNode(o.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),k!=null){var b=[k,A].map(function(x){return Math.max(0,Math.min(S.data.length,x-1))}),E=m(b,2);return k=E[0],A=E[1],{startNode:S,startOffset:k,endNode:S,endOffset:A}}}}},{key:"update",value:function(r,g){var S=this;if(r.some(function(A){return A.type==="characterData"&&A.target===S.textNode})){var k=this.restore();k&&(g.range=k)}}},{key:"value",value:function(){return""}}]),o}(_.default.Embed);c.blotName="cursor",c.className="ql-cursor",c.tagName="span",c.CONTENTS="\uFEFF",s.default=c},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(0),O=_(m),w=t(4),y=_(w);function _(u){return u&&u.__esModule?u:{default:u}}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}function l(u,f){if(!u)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return f&&(typeof f=="object"||typeof f=="function")?f:u}function e(u,f){if(typeof f!="function"&&f!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof f);u.prototype=Object.create(f&&f.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),f&&(Object.setPrototypeOf?Object.setPrototypeOf(u,f):u.__proto__=f)}var n=function(u){e(f,u);function f(){return h(this,f),l(this,(f.__proto__||Object.getPrototypeOf(f)).apply(this,arguments))}return f}(O.default.Container);n.allowedChildren=[y.default,w.BlockEmbed,n],s.default=n},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.ColorStyle=s.ColorClass=s.ColorAttributor=void 0;var m=function(){function c(a,o){for(var d=0;d<o.length;d++){var r=o[d];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(a,r.key,r)}}return function(a,o,d){return o&&c(a.prototype,o),d&&c(a,d),a}}(),O=function c(a,o,d){a===null&&(a=Function.prototype);var r=Object.getOwnPropertyDescriptor(a,o);if(r===void 0){var g=Object.getPrototypeOf(a);return g===null?void 0:c(g,o,d)}else{if("value"in r)return r.value;var S=r.get;return S===void 0?void 0:S.call(d)}},w=t(0),y=_(w);function _(c){return c&&c.__esModule?c:{default:c}}function h(c,a){if(!(c instanceof a))throw new TypeError("Cannot call a class as a function")}function l(c,a){if(!c)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return a&&(typeof a=="object"||typeof a=="function")?a:c}function e(c,a){if(typeof a!="function"&&a!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof a);c.prototype=Object.create(a&&a.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}),a&&(Object.setPrototypeOf?Object.setPrototypeOf(c,a):c.__proto__=a)}var n=function(c){e(a,c);function a(){return h(this,a),l(this,(a.__proto__||Object.getPrototypeOf(a)).apply(this,arguments))}return m(a,[{key:"value",value:function(d){var r=O(a.prototype.__proto__||Object.getPrototypeOf(a.prototype),"value",this).call(this,d);return r.startsWith("rgb(")?(r=r.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+r.split(",").map(function(g){return("00"+parseInt(g).toString(16)).slice(-2)}).join("")):r}}]),a}(y.default.Attributor.Style),u=new y.default.Attributor.Class("color","ql-color",{scope:y.default.Scope.INLINE}),f=new n("color","color",{scope:y.default.Scope.INLINE});s.ColorAttributor=n,s.ColorClass=u,s.ColorStyle=f},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.sanitize=s.default=void 0;var m=function(){function f(c,a){for(var o=0;o<a.length;o++){var d=a[o];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(c,d.key,d)}}return function(c,a,o){return a&&f(c.prototype,a),o&&f(c,o),c}}(),O=function f(c,a,o){c===null&&(c=Function.prototype);var d=Object.getOwnPropertyDescriptor(c,a);if(d===void 0){var r=Object.getPrototypeOf(c);return r===null?void 0:f(r,a,o)}else{if("value"in d)return d.value;var g=d.get;return g===void 0?void 0:g.call(o)}},w=t(6),y=_(w);function _(f){return f&&f.__esModule?f:{default:f}}function h(f,c){if(!(f instanceof c))throw new TypeError("Cannot call a class as a function")}function l(f,c){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c&&(typeof c=="object"||typeof c=="function")?c:f}function e(f,c){if(typeof c!="function"&&c!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof c);f.prototype=Object.create(c&&c.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),c&&(Object.setPrototypeOf?Object.setPrototypeOf(f,c):f.__proto__=c)}var n=function(f){e(c,f);function c(){return h(this,c),l(this,(c.__proto__||Object.getPrototypeOf(c)).apply(this,arguments))}return m(c,[{key:"format",value:function(o,d){if(o!==this.statics.blotName||!d)return O(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"format",this).call(this,o,d);d=this.constructor.sanitize(d),this.domNode.setAttribute("href",d)}}],[{key:"create",value:function(o){var d=O(c.__proto__||Object.getPrototypeOf(c),"create",this).call(this,o);return o=this.sanitize(o),d.setAttribute("href",o),d.setAttribute("rel","noopener noreferrer"),d.setAttribute("target","_blank"),d}},{key:"formats",value:function(o){return o.getAttribute("href")}},{key:"sanitize",value:function(o){return u(o,this.PROTOCOL_WHITELIST)?o:this.SANITIZED_URL}}]),c}(y.default);n.blotName="link",n.tagName="A",n.SANITIZED_URL="about:blank",n.PROTOCOL_WHITELIST=["http","https","mailto","tel"];function u(f,c){var a=document.createElement("a");a.href=f;var o=a.href.slice(0,a.href.indexOf(":"));return c.indexOf(o)>-1}s.default=n,s.sanitize=u},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(c){return typeof c}:function(c){return c&&typeof Symbol=="function"&&c.constructor===Symbol&&c!==Symbol.prototype?"symbol":typeof c},O=function(){function c(a,o){for(var d=0;d<o.length;d++){var r=o[d];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(a,r.key,r)}}return function(a,o,d){return o&&c(a.prototype,o),d&&c(a,d),a}}(),w=t(23),y=l(w),_=t(107),h=l(_);function l(c){return c&&c.__esModule?c:{default:c}}function e(c,a){if(!(c instanceof a))throw new TypeError("Cannot call a class as a function")}var n=0;function u(c,a){c.setAttribute(a,c.getAttribute(a)!=="true")}var f=function(){function c(a){var o=this;e(this,c),this.select=a,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",function(){o.togglePicker()}),this.label.addEventListener("keydown",function(d){switch(d.keyCode){case y.default.keys.ENTER:o.togglePicker();break;case y.default.keys.ESCAPE:o.escape(),d.preventDefault();break}}),this.select.addEventListener("change",this.update.bind(this))}return O(c,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),u(this.label,"aria-expanded"),u(this.options,"aria-hidden")}},{key:"buildItem",value:function(o){var d=this,r=document.createElement("span");return r.tabIndex="0",r.setAttribute("role","button"),r.classList.add("ql-picker-item"),o.hasAttribute("value")&&r.setAttribute("data-value",o.getAttribute("value")),o.textContent&&r.setAttribute("data-label",o.textContent),r.addEventListener("click",function(){d.selectItem(r,!0)}),r.addEventListener("keydown",function(g){switch(g.keyCode){case y.default.keys.ENTER:d.selectItem(r,!0),g.preventDefault();break;case y.default.keys.ESCAPE:d.escape(),g.preventDefault();break}}),r}},{key:"buildLabel",value:function(){var o=document.createElement("span");return o.classList.add("ql-picker-label"),o.innerHTML=h.default,o.tabIndex="0",o.setAttribute("role","button"),o.setAttribute("aria-expanded","false"),this.container.appendChild(o),o}},{key:"buildOptions",value:function(){var o=this,d=document.createElement("span");d.classList.add("ql-picker-options"),d.setAttribute("aria-hidden","true"),d.tabIndex="-1",d.id="ql-picker-options-"+n,n+=1,this.label.setAttribute("aria-controls",d.id),this.options=d,[].slice.call(this.select.options).forEach(function(r){var g=o.buildItem(r);d.appendChild(g),r.selected===!0&&o.selectItem(g)}),this.container.appendChild(d)}},{key:"buildPicker",value:function(){var o=this;[].slice.call(this.select.attributes).forEach(function(d){o.container.setAttribute(d.name,d.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var o=this;this.close(),setTimeout(function(){return o.label.focus()},1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(o){var d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=this.container.querySelector(".ql-selected");if(o!==r&&(r!=null&&r.classList.remove("ql-selected"),o!=null&&(o.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(o.parentNode.children,o),o.hasAttribute("data-value")?this.label.setAttribute("data-value",o.getAttribute("data-value")):this.label.removeAttribute("data-value"),o.hasAttribute("data-label")?this.label.setAttribute("data-label",o.getAttribute("data-label")):this.label.removeAttribute("data-label"),d))){if(typeof Event=="function")this.select.dispatchEvent(new Event("change"));else if((typeof Event=="undefined"?"undefined":m(Event))==="object"){var g=document.createEvent("Event");g.initEvent("change",!0,!0),this.select.dispatchEvent(g)}this.close()}}},{key:"update",value:function(){var o=void 0;if(this.select.selectedIndex>-1){var d=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];o=this.select.options[this.select.selectedIndex],this.selectItem(d)}else this.selectItem(null);var r=o!=null&&o!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",r)}}]),c}();s.default=f},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(0),O=I(m),w=t(5),y=I(w),_=t(4),h=I(_),l=t(16),e=I(l),n=t(25),u=I(n),f=t(24),c=I(f),a=t(35),o=I(a),d=t(6),r=I(d),g=t(22),S=I(g),k=t(7),A=I(k),M=t(55),T=I(M),b=t(42),E=I(b),x=t(23),q=I(x);function I(H){return H&&H.__esModule?H:{default:H}}y.default.register({"blots/block":h.default,"blots/block/embed":_.BlockEmbed,"blots/break":e.default,"blots/container":u.default,"blots/cursor":c.default,"blots/embed":o.default,"blots/inline":r.default,"blots/scroll":S.default,"blots/text":A.default,"modules/clipboard":T.default,"modules/history":E.default,"modules/keyboard":q.default}),O.default.register(h.default,e.default,c.default,r.default,S.default,A.default),s.default=y.default},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(1),O=function(){function w(y){this.domNode=y,this.domNode[m.DATA_KEY]={blot:this}}return Object.defineProperty(w.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),w.create=function(y){if(this.tagName==null)throw new m.ParchmentError("Blot definition missing tagName");var _;return Array.isArray(this.tagName)?(typeof y=="string"&&(y=y.toUpperCase(),parseInt(y).toString()===y&&(y=parseInt(y))),typeof y=="number"?_=document.createElement(this.tagName[y-1]):this.tagName.indexOf(y)>-1?_=document.createElement(y):_=document.createElement(this.tagName[0])):_=document.createElement(this.tagName),this.className&&_.classList.add(this.className),_},w.prototype.attach=function(){this.parent!=null&&(this.scroll=this.parent.scroll)},w.prototype.clone=function(){var y=this.domNode.cloneNode(!1);return m.create(y)},w.prototype.detach=function(){this.parent!=null&&this.parent.removeChild(this),delete this.domNode[m.DATA_KEY]},w.prototype.deleteAt=function(y,_){var h=this.isolate(y,_);h.remove()},w.prototype.formatAt=function(y,_,h,l){var e=this.isolate(y,_);if(m.query(h,m.Scope.BLOT)!=null&&l)e.wrap(h,l);else if(m.query(h,m.Scope.ATTRIBUTE)!=null){var n=m.create(this.statics.scope);e.wrap(n),n.format(h,l)}},w.prototype.insertAt=function(y,_,h){var l=h==null?m.create("text",_):m.create(_,h),e=this.split(y);this.parent.insertBefore(l,e)},w.prototype.insertInto=function(y,_){_===void 0&&(_=null),this.parent!=null&&this.parent.children.remove(this);var h=null;y.children.insertBefore(this,_),_!=null&&(h=_.domNode),(this.domNode.parentNode!=y.domNode||this.domNode.nextSibling!=h)&&y.domNode.insertBefore(this.domNode,h),this.parent=y,this.attach()},w.prototype.isolate=function(y,_){var h=this.split(y);return h.split(_),h},w.prototype.length=function(){return 1},w.prototype.offset=function(y){return y===void 0&&(y=this.parent),this.parent==null||this==y?0:this.parent.children.offset(this)+this.parent.offset(y)},w.prototype.optimize=function(y){this.domNode[m.DATA_KEY]!=null&&delete this.domNode[m.DATA_KEY].mutations},w.prototype.remove=function(){this.domNode.parentNode!=null&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},w.prototype.replace=function(y){y.parent!=null&&(y.parent.insertBefore(this,y.next),y.remove())},w.prototype.replaceWith=function(y,_){var h=typeof y=="string"?m.create(y,_):y;return h.replace(this),h},w.prototype.split=function(y,_){return y===0?this:this.next},w.prototype.update=function(y,_){},w.prototype.wrap=function(y,_){var h=typeof y=="string"?m.create(y,_):y;return this.parent!=null&&this.parent.insertBefore(h,this.next),h.appendChild(this),h},w.blotName="abstract",w}();s.default=O},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(12),O=t(32),w=t(33),y=t(1),_=function(){function h(l){this.attributes={},this.domNode=l,this.build()}return h.prototype.attribute=function(l,e){e?l.add(this.domNode,e)&&(l.value(this.domNode)!=null?this.attributes[l.attrName]=l:delete this.attributes[l.attrName]):(l.remove(this.domNode),delete this.attributes[l.attrName])},h.prototype.build=function(){var l=this;this.attributes={};var e=m.default.keys(this.domNode),n=O.default.keys(this.domNode),u=w.default.keys(this.domNode);e.concat(n).concat(u).forEach(function(f){var c=y.query(f,y.Scope.ATTRIBUTE);c instanceof m.default&&(l.attributes[c.attrName]=c)})},h.prototype.copy=function(l){var e=this;Object.keys(this.attributes).forEach(function(n){var u=e.attributes[n].value(e.domNode);l.format(n,u)})},h.prototype.move=function(l){var e=this;this.copy(l),Object.keys(this.attributes).forEach(function(n){e.attributes[n].remove(e.domNode)}),this.attributes={}},h.prototype.values=function(){var l=this;return Object.keys(this.attributes).reduce(function(e,n){return e[n]=l.attributes[n].value(l.domNode),e},{})},h}();s.default=_},function(p,s,t){var m=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,l){h.__proto__=l}||function(h,l){for(var e in l)l.hasOwnProperty(e)&&(h[e]=l[e])};return function(h,l){_(h,l);function e(){this.constructor=h}h.prototype=l===null?Object.create(l):(e.prototype=l.prototype,new e)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(12);function w(_,h){var l=_.getAttribute("class")||"";return l.split(/\s+/).filter(function(e){return e.indexOf(h+"-")===0})}var y=function(_){m(h,_);function h(){return _!==null&&_.apply(this,arguments)||this}return h.keys=function(l){return(l.getAttribute("class")||"").split(/\s+/).map(function(e){return e.split("-").slice(0,-1).join("-")})},h.prototype.add=function(l,e){return this.canAdd(l,e)?(this.remove(l),l.classList.add(this.keyName+"-"+e),!0):!1},h.prototype.remove=function(l){var e=w(l,this.keyName);e.forEach(function(n){l.classList.remove(n)}),l.classList.length===0&&l.removeAttribute("class")},h.prototype.value=function(l){var e=w(l,this.keyName)[0]||"",n=e.slice(this.keyName.length+1);return this.canAdd(l,n)?n:""},h}(O.default);s.default=y},function(p,s,t){var m=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,l){h.__proto__=l}||function(h,l){for(var e in l)l.hasOwnProperty(e)&&(h[e]=l[e])};return function(h,l){_(h,l);function e(){this.constructor=h}h.prototype=l===null?Object.create(l):(e.prototype=l.prototype,new e)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(12);function w(_){var h=_.split("-"),l=h.slice(1).map(function(e){return e[0].toUpperCase()+e.slice(1)}).join("");return h[0]+l}var y=function(_){m(h,_);function h(){return _!==null&&_.apply(this,arguments)||this}return h.keys=function(l){return(l.getAttribute("style")||"").split(";").map(function(e){var n=e.split(":");return n[0].trim()})},h.prototype.add=function(l,e){return this.canAdd(l,e)?(l.style[w(this.keyName)]=e,!0):!1},h.prototype.remove=function(l){l.style[w(this.keyName)]="",l.getAttribute("style")||l.removeAttribute("style")},h.prototype.value=function(l){var e=l.style[w(this.keyName)];return this.canAdd(l,e)?e:""},h}(O.default);s.default=y},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function y(_,h){for(var l=0;l<h.length;l++){var e=h[l];e.enumerable=e.enumerable||!1,e.configurable=!0,"value"in e&&(e.writable=!0),Object.defineProperty(_,e.key,e)}}return function(_,h,l){return h&&y(_.prototype,h),l&&y(_,l),_}}();function O(y,_){if(!(y instanceof _))throw new TypeError("Cannot call a class as a function")}var w=function(){function y(_,h){O(this,y),this.quill=_,this.options=h,this.modules={}}return m(y,[{key:"init",value:function(){var h=this;Object.keys(this.options.modules).forEach(function(l){h.modules[l]==null&&h.addModule(l)})}},{key:"addModule",value:function(h){var l=this.quill.constructor.import("modules/"+h);return this.modules[h]=new l(this.quill,this.options.modules[h]||{}),this.modules[h]}}]),y}();w.DEFAULTS={modules:{}},w.themes={default:w},s.default=w},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function a(o,d){for(var r=0;r<d.length;r++){var g=d[r];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(o,g.key,g)}}return function(o,d,r){return d&&a(o.prototype,d),r&&a(o,r),o}}(),O=function a(o,d,r){o===null&&(o=Function.prototype);var g=Object.getOwnPropertyDescriptor(o,d);if(g===void 0){var S=Object.getPrototypeOf(o);return S===null?void 0:a(S,d,r)}else{if("value"in g)return g.value;var k=g.get;return k===void 0?void 0:k.call(r)}},w=t(0),y=l(w),_=t(7),h=l(_);function l(a){return a&&a.__esModule?a:{default:a}}function e(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function n(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function u(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var f="\uFEFF",c=function(a){u(o,a);function o(d){e(this,o);var r=n(this,(o.__proto__||Object.getPrototypeOf(o)).call(this,d));return r.contentNode=document.createElement("span"),r.contentNode.setAttribute("contenteditable",!1),[].slice.call(r.domNode.childNodes).forEach(function(g){r.contentNode.appendChild(g)}),r.leftGuard=document.createTextNode(f),r.rightGuard=document.createTextNode(f),r.domNode.appendChild(r.leftGuard),r.domNode.appendChild(r.contentNode),r.domNode.appendChild(r.rightGuard),r}return m(o,[{key:"index",value:function(r,g){return r===this.leftGuard?0:r===this.rightGuard?1:O(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"index",this).call(this,r,g)}},{key:"restore",value:function(r){var g=void 0,S=void 0,k=r.data.split(f).join("");if(r===this.leftGuard)if(this.prev instanceof h.default){var A=this.prev.length();this.prev.insertAt(A,k),g={startNode:this.prev.domNode,startOffset:A+k.length}}else S=document.createTextNode(k),this.parent.insertBefore(y.default.create(S),this),g={startNode:S,startOffset:k.length};else r===this.rightGuard&&(this.next instanceof h.default?(this.next.insertAt(0,k),g={startNode:this.next.domNode,startOffset:k.length}):(S=document.createTextNode(k),this.parent.insertBefore(y.default.create(S),this.next),g={startNode:S,startOffset:k.length}));return r.data=f,g}},{key:"update",value:function(r,g){var S=this;r.forEach(function(k){if(k.type==="characterData"&&(k.target===S.leftGuard||k.target===S.rightGuard)){var A=S.restore(k.target);A&&(g.range=A)}})}}]),o}(y.default.Embed);s.default=c},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.AlignStyle=s.AlignClass=s.AlignAttribute=void 0;var m=t(0),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}var y={scope:O.default.Scope.BLOCK,whitelist:["right","center","justify"]},_=new O.default.Attributor.Attribute("align","align",y),h=new O.default.Attributor.Class("align","ql-align",y),l=new O.default.Attributor.Style("align","text-align",y);s.AlignAttribute=_,s.AlignClass=h,s.AlignStyle=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.BackgroundStyle=s.BackgroundClass=void 0;var m=t(0),O=y(m),w=t(26);function y(l){return l&&l.__esModule?l:{default:l}}var _=new O.default.Attributor.Class("background","ql-bg",{scope:O.default.Scope.INLINE}),h=new w.ColorAttributor("background","background-color",{scope:O.default.Scope.INLINE});s.BackgroundClass=_,s.BackgroundStyle=h},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.DirectionStyle=s.DirectionClass=s.DirectionAttribute=void 0;var m=t(0),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}var y={scope:O.default.Scope.BLOCK,whitelist:["rtl"]},_=new O.default.Attributor.Attribute("direction","dir",y),h=new O.default.Attributor.Class("direction","ql-direction",y),l=new O.default.Attributor.Style("direction","direction",y);s.DirectionAttribute=_,s.DirectionClass=h,s.DirectionStyle=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.FontClass=s.FontStyle=void 0;var m=function(){function a(o,d){for(var r=0;r<d.length;r++){var g=d[r];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(o,g.key,g)}}return function(o,d,r){return d&&a(o.prototype,d),r&&a(o,r),o}}(),O=function a(o,d,r){o===null&&(o=Function.prototype);var g=Object.getOwnPropertyDescriptor(o,d);if(g===void 0){var S=Object.getPrototypeOf(o);return S===null?void 0:a(S,d,r)}else{if("value"in g)return g.value;var k=g.get;return k===void 0?void 0:k.call(r)}},w=t(0),y=_(w);function _(a){return a&&a.__esModule?a:{default:a}}function h(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function e(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var n={scope:y.default.Scope.INLINE,whitelist:["serif","monospace"]},u=new y.default.Attributor.Class("font","ql-font",n),f=function(a){e(o,a);function o(){return h(this,o),l(this,(o.__proto__||Object.getPrototypeOf(o)).apply(this,arguments))}return m(o,[{key:"value",value:function(r){return O(o.prototype.__proto__||Object.getPrototypeOf(o.prototype),"value",this).call(this,r).replace(/["']/g,"")}}]),o}(y.default.Attributor.Style),c=new f("font","font-family",n);s.FontStyle=c,s.FontClass=u},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.SizeStyle=s.SizeClass=void 0;var m=t(0),O=w(m);function w(h){return h&&h.__esModule?h:{default:h}}var y=new O.default.Attributor.Class("size","ql-size",{scope:O.default.Scope.INLINE,whitelist:["small","large","huge"]}),_=new O.default.Attributor.Style("size","font-size",{scope:O.default.Scope.INLINE,whitelist:["10px","18px","32px"]});s.SizeClass=y,s.SizeStyle=_},function(p,s,t){p.exports={align:{"":t(76),center:t(77),right:t(78),justify:t(79)},background:t(80),blockquote:t(81),bold:t(82),clean:t(83),code:t(58),"code-block":t(58),color:t(84),direction:{"":t(85),rtl:t(86)},float:{center:t(87),full:t(88),left:t(89),right:t(90)},formula:t(91),header:{1:t(92),2:t(93)},italic:t(94),image:t(95),indent:{"+1":t(96),"-1":t(97)},link:t(98),list:{ordered:t(99),bullet:t(100),check:t(101)},script:{sub:t(102),super:t(103)},strike:t(104),underline:t(105),video:t(106)}},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.getLastChangeIndex=s.default=void 0;var m=function(){function d(r,g){for(var S=0;S<g.length;S++){var k=g[S];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(r,k.key,k)}}return function(r,g,S){return g&&d(r.prototype,g),S&&d(r,S),r}}(),O=t(0),w=e(O),y=t(5),_=e(y),h=t(9),l=e(h);function e(d){return d&&d.__esModule?d:{default:d}}function n(d,r){if(!(d instanceof r))throw new TypeError("Cannot call a class as a function")}function u(d,r){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r&&(typeof r=="object"||typeof r=="function")?r:d}function f(d,r){if(typeof r!="function"&&r!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof r);d.prototype=Object.create(r&&r.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),r&&(Object.setPrototypeOf?Object.setPrototypeOf(d,r):d.__proto__=r)}var c=function(d){f(r,d);function r(g,S){n(this,r);var k=u(this,(r.__proto__||Object.getPrototypeOf(r)).call(this,g,S));return k.lastRecorded=0,k.ignoreChange=!1,k.clear(),k.quill.on(_.default.events.EDITOR_CHANGE,function(A,M,T,b){A!==_.default.events.TEXT_CHANGE||k.ignoreChange||(!k.options.userOnly||b===_.default.sources.USER?k.record(M,T):k.transform(M))}),k.quill.keyboard.addBinding({key:"Z",shortKey:!0},k.undo.bind(k)),k.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},k.redo.bind(k)),/Win/i.test(navigator.platform)&&k.quill.keyboard.addBinding({key:"Y",shortKey:!0},k.redo.bind(k)),k}return m(r,[{key:"change",value:function(S,k){if(this.stack[S].length!==0){var A=this.stack[S].pop();this.stack[k].push(A),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(A[S],_.default.sources.USER),this.ignoreChange=!1;var M=o(A[S]);this.quill.setSelection(M)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(S,k){if(S.ops.length!==0){this.stack.redo=[];var A=this.quill.getContents().diff(k),M=Date.now();if(this.lastRecorded+this.options.delay>M&&this.stack.undo.length>0){var T=this.stack.undo.pop();A=A.compose(T.undo),S=T.redo.compose(S)}else this.lastRecorded=M;this.stack.undo.push({redo:S,undo:A}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(S){this.stack.undo.forEach(function(k){k.undo=S.transform(k.undo,!0),k.redo=S.transform(k.redo,!0)}),this.stack.redo.forEach(function(k){k.undo=S.transform(k.undo,!0),k.redo=S.transform(k.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),r}(l.default);c.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};function a(d){var r=d.ops[d.ops.length-1];return r==null?!1:r.insert!=null?typeof r.insert=="string"&&r.insert.endsWith(`
`):r.attributes!=null?Object.keys(r.attributes).some(function(g){return w.default.query(g,w.default.Scope.BLOCK)!=null}):!1}function o(d){var r=d.reduce(function(S,k){return S+=k.delete||0,S},0),g=d.length()-r;return a(d)&&(g-=1),g}s.default=c,s.getLastChangeIndex=o},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.BaseTooltip=void 0;var m=function(){function j(P,B){for(var F=0;F<B.length;F++){var C=B[F];C.enumerable=C.enumerable||!1,C.configurable=!0,"value"in C&&(C.writable=!0),Object.defineProperty(P,C.key,C)}}return function(P,B,F){return B&&j(P.prototype,B),F&&j(P,F),P}}(),O=function j(P,B,F){P===null&&(P=Function.prototype);var C=Object.getOwnPropertyDescriptor(P,B);if(C===void 0){var $=Object.getPrototypeOf(P);return $===null?void 0:j($,B,F)}else{if("value"in C)return C.value;var z=C.get;return z===void 0?void 0:z.call(F)}},w=t(3),y=M(w),_=t(2),h=M(_),l=t(8),e=M(l),n=t(23),u=M(n),f=t(34),c=M(f),a=t(59),o=M(a),d=t(60),r=M(d),g=t(28),S=M(g),k=t(61),A=M(k);function M(j){return j&&j.__esModule?j:{default:j}}function T(j,P){if(!(j instanceof P))throw new TypeError("Cannot call a class as a function")}function b(j,P){if(!j)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return P&&(typeof P=="object"||typeof P=="function")?P:j}function E(j,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof P);j.prototype=Object.create(P&&P.prototype,{constructor:{value:j,enumerable:!1,writable:!0,configurable:!0}}),P&&(Object.setPrototypeOf?Object.setPrototypeOf(j,P):j.__proto__=P)}var x=[!1,"center","right","justify"],q=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],I=[!1,"serif","monospace"],H=["1","2","3",!1],K=["small",!1,"large","huge"],ee=function(j){E(P,j);function P(B,F){T(this,P);var C=b(this,(P.__proto__||Object.getPrototypeOf(P)).call(this,B,F)),$=function z(G){if(!document.body.contains(B.root))return document.body.removeEventListener("click",z);C.tooltip!=null&&!C.tooltip.root.contains(G.target)&&document.activeElement!==C.tooltip.textbox&&!C.quill.hasFocus()&&C.tooltip.hide(),C.pickers!=null&&C.pickers.forEach(function(J){J.container.contains(G.target)||J.close()})};return B.emitter.listenDOM("click",document.body,$),C}return m(P,[{key:"addModule",value:function(F){var C=O(P.prototype.__proto__||Object.getPrototypeOf(P.prototype),"addModule",this).call(this,F);return F==="toolbar"&&this.extendToolbar(C),C}},{key:"buildButtons",value:function(F,C){F.forEach(function($){var z=$.getAttribute("class")||"";z.split(/\s+/).forEach(function(G){if(!!G.startsWith("ql-")&&(G=G.slice(3),C[G]!=null))if(G==="direction")$.innerHTML=C[G][""]+C[G].rtl;else if(typeof C[G]=="string")$.innerHTML=C[G];else{var J=$.value||"";J!=null&&C[G][J]&&($.innerHTML=C[G][J])}})})}},{key:"buildPickers",value:function(F,C){var $=this;this.pickers=F.map(function(G){if(G.classList.contains("ql-align"))return G.querySelector("option")==null&&N(G,x),new r.default(G,C.align);if(G.classList.contains("ql-background")||G.classList.contains("ql-color")){var J=G.classList.contains("ql-background")?"background":"color";return G.querySelector("option")==null&&N(G,q,J==="background"?"#ffffff":"#000000"),new o.default(G,C[J])}else return G.querySelector("option")==null&&(G.classList.contains("ql-font")?N(G,I):G.classList.contains("ql-header")?N(G,H):G.classList.contains("ql-size")&&N(G,K)),new S.default(G)});var z=function(){$.pickers.forEach(function(J){J.update()})};this.quill.on(e.default.events.EDITOR_CHANGE,z)}}]),P}(c.default);ee.DEFAULTS=(0,y.default)(!0,{},c.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var P=this,B=this.container.querySelector("input.ql-image[type=file]");B==null&&(B=document.createElement("input"),B.setAttribute("type","file"),B.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),B.classList.add("ql-image"),B.addEventListener("change",function(){if(B.files!=null&&B.files[0]!=null){var F=new FileReader;F.onload=function(C){var $=P.quill.getSelection(!0);P.quill.updateContents(new h.default().retain($.index).delete($.length).insert({image:C.target.result}),e.default.sources.USER),P.quill.setSelection($.index+1,e.default.sources.SILENT),B.value=""},F.readAsDataURL(B.files[0])}}),this.container.appendChild(B)),B.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var V=function(j){E(P,j);function P(B,F){T(this,P);var C=b(this,(P.__proto__||Object.getPrototypeOf(P)).call(this,B,F));return C.textbox=C.root.querySelector('input[type="text"]'),C.listen(),C}return m(P,[{key:"listen",value:function(){var F=this;this.textbox.addEventListener("keydown",function(C){u.default.match(C,"enter")?(F.save(),C.preventDefault()):u.default.match(C,"escape")&&(F.cancel(),C.preventDefault())})}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"link",C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),C!=null?this.textbox.value=C:F!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+F)||""),this.root.setAttribute("data-mode",F)}},{key:"restoreFocus",value:function(){var F=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=F}},{key:"save",value:function(){var F=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":{var C=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",F,e.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",F,e.default.sources.USER)),this.quill.root.scrollTop=C;break}case"video":F=D(F);case"formula":{if(!F)break;var $=this.quill.getSelection(!0);if($!=null){var z=$.index+$.length;this.quill.insertEmbed(z,this.root.getAttribute("data-mode"),F,e.default.sources.USER),this.root.getAttribute("data-mode")==="formula"&&this.quill.insertText(z+1," ",e.default.sources.USER),this.quill.setSelection(z+2,e.default.sources.USER)}break}}this.textbox.value="",this.hide()}}]),P}(A.default);function D(j){var P=j.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||j.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return P?(P[1]||"https")+"://www.youtube.com/embed/"+P[2]+"?showinfo=0":(P=j.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(P[1]||"https")+"://player.vimeo.com/video/"+P[2]+"/":j}function N(j,P){var B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;P.forEach(function(F){var C=document.createElement("option");F===B?C.setAttribute("selected","selected"):C.setAttribute("value",F),j.appendChild(C)})}s.BaseTooltip=V,s.default=ee},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function O(){this.head=this.tail=null,this.length=0}return O.prototype.append=function(){for(var w=[],y=0;y<arguments.length;y++)w[y]=arguments[y];this.insertBefore(w[0],null),w.length>1&&this.append.apply(this,w.slice(1))},O.prototype.contains=function(w){for(var y,_=this.iterator();y=_();)if(y===w)return!0;return!1},O.prototype.insertBefore=function(w,y){!w||(w.next=y,y!=null?(w.prev=y.prev,y.prev!=null&&(y.prev.next=w),y.prev=w,y===this.head&&(this.head=w)):this.tail!=null?(this.tail.next=w,w.prev=this.tail,this.tail=w):(w.prev=null,this.head=this.tail=w),this.length+=1)},O.prototype.offset=function(w){for(var y=0,_=this.head;_!=null;){if(_===w)return y;y+=_.length(),_=_.next}return-1},O.prototype.remove=function(w){!this.contains(w)||(w.prev!=null&&(w.prev.next=w.next),w.next!=null&&(w.next.prev=w.prev),w===this.head&&(this.head=w.next),w===this.tail&&(this.tail=w.prev),this.length-=1)},O.prototype.iterator=function(w){return w===void 0&&(w=this.head),function(){var y=w;return w!=null&&(w=w.next),y}},O.prototype.find=function(w,y){y===void 0&&(y=!1);for(var _,h=this.iterator();_=h();){var l=_.length();if(w<l||y&&w===l&&(_.next==null||_.next.length()!==0))return[_,w];w-=l}return[null,0]},O.prototype.forEach=function(w){for(var y,_=this.iterator();y=_();)w(y)},O.prototype.forEachAt=function(w,y,_){if(!(y<=0))for(var h=this.find(w),l=h[0],e=h[1],n,u=w-e,f=this.iterator(l);(n=f())&&u<w+y;){var c=n.length();w>u?_(n,w-u,Math.min(y,u+c-w)):_(n,0,Math.min(c,w+y-u)),u+=c}},O.prototype.map=function(w){return this.reduce(function(y,_){return y.push(w(_)),y},[])},O.prototype.reduce=function(w,y){for(var _,h=this.iterator();_=h();)y=w(y,_);return y},O}();s.default=m},function(p,s,t){var m=this&&this.__extends||function(){var l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var u in n)n.hasOwnProperty(u)&&(e[u]=n[u])};return function(e,n){l(e,n);function u(){this.constructor=e}e.prototype=n===null?Object.create(n):(u.prototype=n.prototype,new u)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(17),w=t(1),y={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},_=100,h=function(l){m(e,l);function e(n){var u=l.call(this,n)||this;return u.scroll=u,u.observer=new MutationObserver(function(f){u.update(f)}),u.observer.observe(u.domNode,y),u.attach(),u}return e.prototype.detach=function(){l.prototype.detach.call(this),this.observer.disconnect()},e.prototype.deleteAt=function(n,u){this.update(),n===0&&u===this.length()?this.children.forEach(function(f){f.remove()}):l.prototype.deleteAt.call(this,n,u)},e.prototype.formatAt=function(n,u,f,c){this.update(),l.prototype.formatAt.call(this,n,u,f,c)},e.prototype.insertAt=function(n,u,f){this.update(),l.prototype.insertAt.call(this,n,u,f)},e.prototype.optimize=function(n,u){var f=this;n===void 0&&(n=[]),u===void 0&&(u={}),l.prototype.optimize.call(this,u);for(var c=[].slice.call(this.observer.takeRecords());c.length>0;)n.push(c.pop());for(var a=function(g,S){S===void 0&&(S=!0),!(g==null||g===f)&&g.domNode.parentNode!=null&&(g.domNode[w.DATA_KEY].mutations==null&&(g.domNode[w.DATA_KEY].mutations=[]),S&&a(g.parent))},o=function(g){g.domNode[w.DATA_KEY]==null||g.domNode[w.DATA_KEY].mutations==null||(g instanceof O.default&&g.children.forEach(o),g.optimize(u))},d=n,r=0;d.length>0;r+=1){if(r>=_)throw new Error("[Parchment] Maximum optimize iterations reached");for(d.forEach(function(g){var S=w.find(g.target,!0);S!=null&&(S.domNode===g.target&&(g.type==="childList"?(a(w.find(g.previousSibling,!1)),[].forEach.call(g.addedNodes,function(k){var A=w.find(k,!1);a(A,!1),A instanceof O.default&&A.children.forEach(function(M){a(M,!1)})})):g.type==="attributes"&&a(S.prev)),a(S))}),this.children.forEach(o),d=[].slice.call(this.observer.takeRecords()),c=d.slice();c.length>0;)n.push(c.pop())}},e.prototype.update=function(n,u){var f=this;u===void 0&&(u={}),n=n||this.observer.takeRecords(),n.map(function(c){var a=w.find(c.target,!0);return a==null?null:a.domNode[w.DATA_KEY].mutations==null?(a.domNode[w.DATA_KEY].mutations=[c],a):(a.domNode[w.DATA_KEY].mutations.push(c),null)}).forEach(function(c){c==null||c===f||c.domNode[w.DATA_KEY]==null||c.update(c.domNode[w.DATA_KEY].mutations||[],u)}),this.domNode[w.DATA_KEY].mutations!=null&&l.prototype.update.call(this,this.domNode[w.DATA_KEY].mutations,u),this.optimize(n,u)},e.blotName="scroll",e.defaultChild="block",e.scope=w.Scope.BLOCK_BLOT,e.tagName="DIV",e}(O.default);s.default=h},function(p,s,t){var m=this&&this.__extends||function(){var h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,e){l.__proto__=e}||function(l,e){for(var n in e)e.hasOwnProperty(n)&&(l[n]=e[n])};return function(l,e){h(l,e);function n(){this.constructor=l}l.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(18),w=t(1);function y(h,l){if(Object.keys(h).length!==Object.keys(l).length)return!1;for(var e in h)if(h[e]!==l[e])return!1;return!0}var _=function(h){m(l,h);function l(){return h!==null&&h.apply(this,arguments)||this}return l.formats=function(e){if(e.tagName!==l.tagName)return h.formats.call(this,e)},l.prototype.format=function(e,n){var u=this;e===this.statics.blotName&&!n?(this.children.forEach(function(f){f instanceof O.default||(f=f.wrap(l.blotName,!0)),u.attributes.copy(f)}),this.unwrap()):h.prototype.format.call(this,e,n)},l.prototype.formatAt=function(e,n,u,f){if(this.formats()[u]!=null||w.query(u,w.Scope.ATTRIBUTE)){var c=this.isolate(e,n);c.format(u,f)}else h.prototype.formatAt.call(this,e,n,u,f)},l.prototype.optimize=function(e){h.prototype.optimize.call(this,e);var n=this.formats();if(Object.keys(n).length===0)return this.unwrap();var u=this.next;u instanceof l&&u.prev===this&&y(n,u.formats())&&(u.moveChildren(this),u.remove())},l.blotName="inline",l.scope=w.Scope.INLINE_BLOT,l.tagName="SPAN",l}(O.default);s.default=_},function(p,s,t){var m=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,l){h.__proto__=l}||function(h,l){for(var e in l)l.hasOwnProperty(e)&&(h[e]=l[e])};return function(h,l){_(h,l);function e(){this.constructor=h}h.prototype=l===null?Object.create(l):(e.prototype=l.prototype,new e)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(18),w=t(1),y=function(_){m(h,_);function h(){return _!==null&&_.apply(this,arguments)||this}return h.formats=function(l){var e=w.query(h.blotName).tagName;if(l.tagName!==e)return _.formats.call(this,l)},h.prototype.format=function(l,e){w.query(l,w.Scope.BLOCK)!=null&&(l===this.statics.blotName&&!e?this.replaceWith(h.blotName):_.prototype.format.call(this,l,e))},h.prototype.formatAt=function(l,e,n,u){w.query(n,w.Scope.BLOCK)!=null?this.format(n,u):_.prototype.formatAt.call(this,l,e,n,u)},h.prototype.insertAt=function(l,e,n){if(n==null||w.query(e,w.Scope.INLINE)!=null)_.prototype.insertAt.call(this,l,e,n);else{var u=this.split(l),f=w.create(e,n);u.parent.insertBefore(f,u)}},h.prototype.update=function(l,e){navigator.userAgent.match(/Trident/)?this.build():_.prototype.update.call(this,l,e)},h.blotName="block",h.scope=w.Scope.BLOCK_BLOT,h.tagName="P",h}(O.default);s.default=y},function(p,s,t){var m=this&&this.__extends||function(){var y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,h){_.__proto__=h}||function(_,h){for(var l in h)h.hasOwnProperty(l)&&(_[l]=h[l])};return function(_,h){y(_,h);function l(){this.constructor=_}_.prototype=h===null?Object.create(h):(l.prototype=h.prototype,new l)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(19),w=function(y){m(_,y);function _(){return y!==null&&y.apply(this,arguments)||this}return _.formats=function(h){},_.prototype.format=function(h,l){y.prototype.formatAt.call(this,0,this.length(),h,l)},_.prototype.formatAt=function(h,l,e,n){h===0&&l===this.length()?this.format(e,n):y.prototype.formatAt.call(this,h,l,e,n)},_.prototype.formats=function(){return this.statics.formats(this.domNode)},_}(O.default);s.default=w},function(p,s,t){var m=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,l){h.__proto__=l}||function(h,l){for(var e in l)l.hasOwnProperty(e)&&(h[e]=l[e])};return function(h,l){_(h,l);function e(){this.constructor=h}h.prototype=l===null?Object.create(l):(e.prototype=l.prototype,new e)}}();Object.defineProperty(s,"__esModule",{value:!0});var O=t(19),w=t(1),y=function(_){m(h,_);function h(l){var e=_.call(this,l)||this;return e.text=e.statics.value(e.domNode),e}return h.create=function(l){return document.createTextNode(l)},h.value=function(l){var e=l.data;return e.normalize&&(e=e.normalize()),e},h.prototype.deleteAt=function(l,e){this.domNode.data=this.text=this.text.slice(0,l)+this.text.slice(l+e)},h.prototype.index=function(l,e){return this.domNode===l?e:-1},h.prototype.insertAt=function(l,e,n){n==null?(this.text=this.text.slice(0,l)+e+this.text.slice(l),this.domNode.data=this.text):_.prototype.insertAt.call(this,l,e,n)},h.prototype.length=function(){return this.text.length},h.prototype.optimize=function(l){_.prototype.optimize.call(this,l),this.text=this.statics.value(this.domNode),this.text.length===0?this.remove():this.next instanceof h&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},h.prototype.position=function(l,e){return[this.domNode,l]},h.prototype.split=function(l,e){if(e===void 0&&(e=!1),!e){if(l===0)return this;if(l===this.length())return this.next}var n=w.create(this.domNode.splitText(l));return this.parent.insertBefore(n,this.next),this.text=this.statics.value(this.domNode),n},h.prototype.update=function(l,e){var n=this;l.some(function(u){return u.type==="characterData"&&u.target===n.domNode})&&(this.text=this.statics.value(this.domNode))},h.prototype.value=function(){return this.text},h.blotName="text",h.scope=w.Scope.INLINE_BLOT,h}(O.default);s.default=y},function(p,s,t){var m=document.createElement("div");if(m.classList.toggle("test-class",!1),m.classList.contains("test-class")){var O=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(w,y){return arguments.length>1&&!this.contains(w)==!y?y:O.call(this,w)}}String.prototype.startsWith||(String.prototype.startsWith=function(w,y){return y=y||0,this.substr(y,w.length)===w}),String.prototype.endsWith||(String.prototype.endsWith=function(w,y){var _=this.toString();(typeof y!="number"||!isFinite(y)||Math.floor(y)!==y||y>_.length)&&(y=_.length),y-=w.length;var h=_.indexOf(w,y);return h!==-1&&h===y}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(y){if(this===null)throw new TypeError("Array.prototype.find called on null or undefined");if(typeof y!="function")throw new TypeError("predicate must be a function");for(var _=Object(this),h=_.length>>>0,l=arguments[1],e,n=0;n<h;n++)if(e=_[n],y.call(l,e,n,_))return e}}),document.addEventListener("DOMContentLoaded",function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)})},function(p,s){var t=-1,m=1,O=0;function w(r,g,S){if(r==g)return r?[[O,r]]:[];(S<0||r.length<S)&&(S=null);var k=l(r,g),A=r.substring(0,k);r=r.substring(k),g=g.substring(k),k=e(r,g);var M=r.substring(r.length-k);r=r.substring(0,r.length-k),g=g.substring(0,g.length-k);var T=y(r,g);return A&&T.unshift([O,A]),M&&T.push([O,M]),u(T),S!=null&&(T=a(T,S)),T=o(T),T}function y(r,g){var S;if(!r)return[[m,g]];if(!g)return[[t,r]];var k=r.length>g.length?r:g,A=r.length>g.length?g:r,M=k.indexOf(A);if(M!=-1)return S=[[m,k.substring(0,M)],[O,A],[m,k.substring(M+A.length)]],r.length>g.length&&(S[0][0]=S[2][0]=t),S;if(A.length==1)return[[t,r],[m,g]];var T=n(r,g);if(T){var b=T[0],E=T[1],x=T[2],q=T[3],I=T[4],H=w(b,x),K=w(E,q);return H.concat([[O,I]],K)}return _(r,g)}function _(r,g){for(var S=r.length,k=g.length,A=Math.ceil((S+k)/2),M=A,T=2*A,b=new Array(T),E=new Array(T),x=0;x<T;x++)b[x]=-1,E[x]=-1;b[M+1]=0,E[M+1]=0;for(var q=S-k,I=q%2!=0,H=0,K=0,ee=0,V=0,D=0;D<A;D++){for(var N=-D+H;N<=D-K;N+=2){var j=M+N,P;N==-D||N!=D&&b[j-1]<b[j+1]?P=b[j+1]:P=b[j-1]+1;for(var B=P-N;P<S&&B<k&&r.charAt(P)==g.charAt(B);)P++,B++;if(b[j]=P,P>S)K+=2;else if(B>k)H+=2;else if(I){var F=M+q-N;if(F>=0&&F<T&&E[F]!=-1){var C=S-E[F];if(P>=C)return h(r,g,P,B)}}}for(var $=-D+ee;$<=D-V;$+=2){var F=M+$,C;$==-D||$!=D&&E[F-1]<E[F+1]?C=E[F+1]:C=E[F-1]+1;for(var z=C-$;C<S&&z<k&&r.charAt(S-C-1)==g.charAt(k-z-1);)C++,z++;if(E[F]=C,C>S)V+=2;else if(z>k)ee+=2;else if(!I){var j=M+q-$;if(j>=0&&j<T&&b[j]!=-1){var P=b[j],B=M+P-j;if(C=S-C,P>=C)return h(r,g,P,B)}}}}return[[t,r],[m,g]]}function h(r,g,S,k){var A=r.substring(0,S),M=g.substring(0,k),T=r.substring(S),b=g.substring(k),E=w(A,M),x=w(T,b);return E.concat(x)}function l(r,g){if(!r||!g||r.charAt(0)!=g.charAt(0))return 0;for(var S=0,k=Math.min(r.length,g.length),A=k,M=0;S<A;)r.substring(M,A)==g.substring(M,A)?(S=A,M=S):k=A,A=Math.floor((k-S)/2+S);return A}function e(r,g){if(!r||!g||r.charAt(r.length-1)!=g.charAt(g.length-1))return 0;for(var S=0,k=Math.min(r.length,g.length),A=k,M=0;S<A;)r.substring(r.length-A,r.length-M)==g.substring(g.length-A,g.length-M)?(S=A,M=S):k=A,A=Math.floor((k-S)/2+S);return A}function n(r,g){var S=r.length>g.length?r:g,k=r.length>g.length?g:r;if(S.length<4||k.length*2<S.length)return null;function A(K,ee,V){for(var D=K.substring(V,V+Math.floor(K.length/4)),N=-1,j="",P,B,F,C;(N=ee.indexOf(D,N+1))!=-1;){var $=l(K.substring(V),ee.substring(N)),z=e(K.substring(0,V),ee.substring(0,N));j.length<z+$&&(j=ee.substring(N-z,N)+ee.substring(N,N+$),P=K.substring(0,V-z),B=K.substring(V+$),F=ee.substring(0,N-z),C=ee.substring(N+$))}return j.length*2>=K.length?[P,B,F,C,j]:null}var M=A(S,k,Math.ceil(S.length/4)),T=A(S,k,Math.ceil(S.length/2)),b;if(!M&&!T)return null;T?M?b=M[4].length>T[4].length?M:T:b=T:b=M;var E,x,q,I;r.length>g.length?(E=b[0],x=b[1],q=b[2],I=b[3]):(q=b[0],I=b[1],E=b[2],x=b[3]);var H=b[4];return[E,x,q,I,H]}function u(r){r.push([O,""]);for(var g=0,S=0,k=0,A="",M="",T;g<r.length;)switch(r[g][0]){case m:k++,M+=r[g][1],g++;break;case t:S++,A+=r[g][1],g++;break;case O:S+k>1?(S!==0&&k!==0&&(T=l(M,A),T!==0&&(g-S-k>0&&r[g-S-k-1][0]==O?r[g-S-k-1][1]+=M.substring(0,T):(r.splice(0,0,[O,M.substring(0,T)]),g++),M=M.substring(T),A=A.substring(T)),T=e(M,A),T!==0&&(r[g][1]=M.substring(M.length-T)+r[g][1],M=M.substring(0,M.length-T),A=A.substring(0,A.length-T))),S===0?r.splice(g-k,S+k,[m,M]):k===0?r.splice(g-S,S+k,[t,A]):r.splice(g-S-k,S+k,[t,A],[m,M]),g=g-S-k+(S?1:0)+(k?1:0)+1):g!==0&&r[g-1][0]==O?(r[g-1][1]+=r[g][1],r.splice(g,1)):g++,k=0,S=0,A="",M="";break}r[r.length-1][1]===""&&r.pop();var b=!1;for(g=1;g<r.length-1;)r[g-1][0]==O&&r[g+1][0]==O&&(r[g][1].substring(r[g][1].length-r[g-1][1].length)==r[g-1][1]?(r[g][1]=r[g-1][1]+r[g][1].substring(0,r[g][1].length-r[g-1][1].length),r[g+1][1]=r[g-1][1]+r[g+1][1],r.splice(g-1,1),b=!0):r[g][1].substring(0,r[g+1][1].length)==r[g+1][1]&&(r[g-1][1]+=r[g+1][1],r[g][1]=r[g][1].substring(r[g+1][1].length)+r[g+1][1],r.splice(g+1,1),b=!0)),g++;b&&u(r)}var f=w;f.INSERT=m,f.DELETE=t,f.EQUAL=O,p.exports=f;function c(r,g){if(g===0)return[O,r];for(var S=0,k=0;k<r.length;k++){var A=r[k];if(A[0]===t||A[0]===O){var M=S+A[1].length;if(g===M)return[k+1,r];if(g<M){r=r.slice();var T=g-S,b=[A[0],A[1].slice(0,T)],E=[A[0],A[1].slice(T)];return r.splice(k,1,b,E),[k+1,r]}else S=M}}throw new Error("cursor_pos is out of bounds!")}function a(r,g){var S=c(r,g),k=S[1],A=S[0],M=k[A],T=k[A+1];if(M==null)return r;if(M[0]!==O)return r;if(T!=null&&M[1]+T[1]===T[1]+M[1])return k.splice(A,2,T,M),d(k,A,2);if(T!=null&&T[1].indexOf(M[1])===0){k.splice(A,2,[T[0],M[1]],[0,M[1]]);var b=T[1].slice(M[1].length);return b.length>0&&k.splice(A+2,0,[T[0],b]),d(k,A,3)}else return r}function o(r){for(var g=!1,S=function(T){return T.charCodeAt(0)>=56320&&T.charCodeAt(0)<=57343},k=function(T){return T.charCodeAt(T.length-1)>=55296&&T.charCodeAt(T.length-1)<=56319},A=2;A<r.length;A+=1)r[A-2][0]===O&&k(r[A-2][1])&&r[A-1][0]===t&&S(r[A-1][1])&&r[A][0]===m&&S(r[A][1])&&(g=!0,r[A-1][1]=r[A-2][1].slice(-1)+r[A-1][1],r[A][1]=r[A-2][1].slice(-1)+r[A][1],r[A-2][1]=r[A-2][1].slice(0,-1));if(!g)return r;for(var M=[],A=0;A<r.length;A+=1)r[A][1].length>0&&M.push(r[A]);return M}function d(r,g,S){for(var k=g+S-1;k>=0&&k>=g-1;k--)if(k+1<r.length){var A=r[k],M=r[k+1];A[0]===M[1]&&r.splice(k,2,[A[0],A[1]+M[1]])}return r}},function(p,s){s=p.exports=typeof Object.keys=="function"?Object.keys:t,s.shim=t;function t(m){var O=[];for(var w in m)O.push(w);return O}},function(p,s){var t=function(){return Object.prototype.toString.call(arguments)}()=="[object Arguments]";s=p.exports=t?m:O,s.supported=m;function m(w){return Object.prototype.toString.call(w)=="[object Arguments]"}s.unsupported=O;function O(w){return w&&typeof w=="object"&&typeof w.length=="number"&&Object.prototype.hasOwnProperty.call(w,"callee")&&!Object.prototype.propertyIsEnumerable.call(w,"callee")||!1}},function(p,s){var t=Object.prototype.hasOwnProperty,m="~";function O(){}Object.create&&(O.prototype=Object.create(null),new O().__proto__||(m=!1));function w(_,h,l){this.fn=_,this.context=h,this.once=l||!1}function y(){this._events=new O,this._eventsCount=0}y.prototype.eventNames=function(){var h=[],l,e;if(this._eventsCount===0)return h;for(e in l=this._events)t.call(l,e)&&h.push(m?e.slice(1):e);return Object.getOwnPropertySymbols?h.concat(Object.getOwnPropertySymbols(l)):h},y.prototype.listeners=function(h,l){var e=m?m+h:h,n=this._events[e];if(l)return!!n;if(!n)return[];if(n.fn)return[n.fn];for(var u=0,f=n.length,c=new Array(f);u<f;u++)c[u]=n[u].fn;return c},y.prototype.emit=function(h,l,e,n,u,f){var c=m?m+h:h;if(!this._events[c])return!1;var a=this._events[c],o=arguments.length,d,r;if(a.fn){switch(a.once&&this.removeListener(h,a.fn,void 0,!0),o){case 1:return a.fn.call(a.context),!0;case 2:return a.fn.call(a.context,l),!0;case 3:return a.fn.call(a.context,l,e),!0;case 4:return a.fn.call(a.context,l,e,n),!0;case 5:return a.fn.call(a.context,l,e,n,u),!0;case 6:return a.fn.call(a.context,l,e,n,u,f),!0}for(r=1,d=new Array(o-1);r<o;r++)d[r-1]=arguments[r];a.fn.apply(a.context,d)}else{var g=a.length,S;for(r=0;r<g;r++)switch(a[r].once&&this.removeListener(h,a[r].fn,void 0,!0),o){case 1:a[r].fn.call(a[r].context);break;case 2:a[r].fn.call(a[r].context,l);break;case 3:a[r].fn.call(a[r].context,l,e);break;case 4:a[r].fn.call(a[r].context,l,e,n);break;default:if(!d)for(S=1,d=new Array(o-1);S<o;S++)d[S-1]=arguments[S];a[r].fn.apply(a[r].context,d)}}return!0},y.prototype.on=function(h,l,e){var n=new w(l,e||this),u=m?m+h:h;return this._events[u]?this._events[u].fn?this._events[u]=[this._events[u],n]:this._events[u].push(n):(this._events[u]=n,this._eventsCount++),this},y.prototype.once=function(h,l,e){var n=new w(l,e||this,!0),u=m?m+h:h;return this._events[u]?this._events[u].fn?this._events[u]=[this._events[u],n]:this._events[u].push(n):(this._events[u]=n,this._eventsCount++),this},y.prototype.removeListener=function(h,l,e,n){var u=m?m+h:h;if(!this._events[u])return this;if(!l)return--this._eventsCount===0?this._events=new O:delete this._events[u],this;var f=this._events[u];if(f.fn)f.fn===l&&(!n||f.once)&&(!e||f.context===e)&&(--this._eventsCount===0?this._events=new O:delete this._events[u]);else{for(var c=0,a=[],o=f.length;c<o;c++)(f[c].fn!==l||n&&!f[c].once||e&&f[c].context!==e)&&a.push(f[c]);a.length?this._events[u]=a.length===1?a[0]:a:--this._eventsCount===0?this._events=new O:delete this._events[u]}return this},y.prototype.removeAllListeners=function(h){var l;return h?(l=m?m+h:h,this._events[l]&&(--this._eventsCount===0?this._events=new O:delete this._events[l])):(this._events=new O,this._eventsCount=0),this},y.prototype.off=y.prototype.removeListener,y.prototype.addListener=y.prototype.on,y.prototype.setMaxListeners=function(){return this},y.prefixed=m,y.EventEmitter=y,typeof p!="undefined"&&(p.exports=y)},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.matchText=s.matchSpacing=s.matchNewline=s.matchBlot=s.matchAttributor=s.default=void 0;var m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Z){return typeof Z}:function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},O=function(){function Z(Y,ie){var ue=[],W=!0,te=!1,ae=void 0;try{for(var de=Y[Symbol.iterator](),we;!(W=(we=de.next()).done)&&(ue.push(we.value),!(ie&&ue.length===ie));W=!0);}catch(ye){te=!0,ae=ye}finally{try{!W&&de.return&&de.return()}finally{if(te)throw ae}}return ue}return function(Y,ie){if(Array.isArray(Y))return Y;if(Symbol.iterator in Object(Y))return Z(Y,ie);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),w=function(){function Z(Y,ie){for(var ue=0;ue<ie.length;ue++){var W=ie[ue];W.enumerable=W.enumerable||!1,W.configurable=!0,"value"in W&&(W.writable=!0),Object.defineProperty(Y,W.key,W)}}return function(Y,ie,ue){return ie&&Z(Y.prototype,ie),ue&&Z(Y,ue),Y}}(),y=t(3),_=E(y),h=t(2),l=E(h),e=t(0),n=E(e),u=t(5),f=E(u),c=t(10),a=E(c),o=t(9),d=E(o),r=t(36),g=t(37),S=t(13),k=E(S),A=t(26),M=t(38),T=t(39),b=t(40);function E(Z){return Z&&Z.__esModule?Z:{default:Z}}function x(Z,Y,ie){return Y in Z?Object.defineProperty(Z,Y,{value:ie,enumerable:!0,configurable:!0,writable:!0}):Z[Y]=ie,Z}function q(Z,Y){if(!(Z instanceof Y))throw new TypeError("Cannot call a class as a function")}function I(Z,Y){if(!Z)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return Y&&(typeof Y=="object"||typeof Y=="function")?Y:Z}function H(Z,Y){if(typeof Y!="function"&&Y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof Y);Z.prototype=Object.create(Y&&Y.prototype,{constructor:{value:Z,enumerable:!1,writable:!0,configurable:!0}}),Y&&(Object.setPrototypeOf?Object.setPrototypeOf(Z,Y):Z.__proto__=Y)}var K=(0,a.default)("quill:clipboard"),ee="__ql-matcher",V=[[Node.TEXT_NODE,he],[Node.TEXT_NODE,se],["br",fe],[Node.ELEMENT_NODE,se],[Node.ELEMENT_NODE,J],[Node.ELEMENT_NODE,ce],[Node.ELEMENT_NODE,G],[Node.ELEMENT_NODE,Ee],["li",re],["b",z.bind(z,"bold")],["i",z.bind(z,"italic")],["style",Q]],D=[r.AlignAttribute,M.DirectionAttribute].reduce(function(Z,Y){return Z[Y.keyName]=Y,Z},{}),N=[r.AlignStyle,g.BackgroundStyle,A.ColorStyle,M.DirectionStyle,T.FontStyle,b.SizeStyle].reduce(function(Z,Y){return Z[Y.keyName]=Y,Z},{}),j=function(Z){H(Y,Z);function Y(ie,ue){q(this,Y);var W=I(this,(Y.__proto__||Object.getPrototypeOf(Y)).call(this,ie,ue));return W.quill.root.addEventListener("paste",W.onPaste.bind(W)),W.container=W.quill.addContainer("ql-clipboard"),W.container.setAttribute("contenteditable",!0),W.container.setAttribute("tabindex",-1),W.matchers=[],V.concat(W.options.matchers).forEach(function(te){var ae=O(te,2),de=ae[0],we=ae[1];!ue.matchVisual&&we===ce||W.addMatcher(de,we)}),W}return w(Y,[{key:"addMatcher",value:function(ue,W){this.matchers.push([ue,W])}},{key:"convert",value:function(ue){if(typeof ue=="string")return this.container.innerHTML=ue.replace(/\>\r?\n +\</g,"><"),this.convert();var W=this.quill.getFormat(this.quill.selection.savedRange.index);if(W[k.default.blotName]){var te=this.container.innerText;return this.container.innerHTML="",new l.default().insert(te,x({},k.default.blotName,W[k.default.blotName]))}var ae=this.prepareMatching(),de=O(ae,2),we=de[0],ye=de[1],ve=$(this.container,we,ye);return F(ve,`
`)&&ve.ops[ve.ops.length-1].attributes==null&&(ve=ve.compose(new l.default().retain(ve.length()-1).delete(1))),K.log("convert",this.container.innerHTML,ve),this.container.innerHTML="",ve}},{key:"dangerouslyPasteHTML",value:function(ue,W){var te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:f.default.sources.API;if(typeof ue=="string")this.quill.setContents(this.convert(ue),W),this.quill.setSelection(0,f.default.sources.SILENT);else{var ae=this.convert(W);this.quill.updateContents(new l.default().retain(ue).concat(ae),te),this.quill.setSelection(ue+ae.length(),f.default.sources.SILENT)}}},{key:"onPaste",value:function(ue){var W=this;if(!(ue.defaultPrevented||!this.quill.isEnabled())){var te=this.quill.getSelection(),ae=new l.default().retain(te.index),de=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(f.default.sources.SILENT),setTimeout(function(){ae=ae.concat(W.convert()).delete(te.length),W.quill.updateContents(ae,f.default.sources.USER),W.quill.setSelection(ae.length()-te.length,f.default.sources.SILENT),W.quill.scrollingContainer.scrollTop=de,W.quill.focus()},1)}}},{key:"prepareMatching",value:function(){var ue=this,W=[],te=[];return this.matchers.forEach(function(ae){var de=O(ae,2),we=de[0],ye=de[1];switch(we){case Node.TEXT_NODE:te.push(ye);break;case Node.ELEMENT_NODE:W.push(ye);break;default:[].forEach.call(ue.container.querySelectorAll(we),function(ve){ve[ee]=ve[ee]||[],ve[ee].push(ye)});break}}),[W,te]}}]),Y}(d.default);j.DEFAULTS={matchers:[],matchVisual:!0};function P(Z,Y,ie){return(typeof Y=="undefined"?"undefined":m(Y))==="object"?Object.keys(Y).reduce(function(ue,W){return P(ue,W,Y[W])},Z):Z.reduce(function(ue,W){return W.attributes&&W.attributes[Y]?ue.push(W):ue.insert(W.insert,(0,_.default)({},x({},Y,ie),W.attributes))},new l.default)}function B(Z){if(Z.nodeType!==Node.ELEMENT_NODE)return{};var Y="__ql-computed-style";return Z[Y]||(Z[Y]=window.getComputedStyle(Z))}function F(Z,Y){for(var ie="",ue=Z.ops.length-1;ue>=0&&ie.length<Y.length;--ue){var W=Z.ops[ue];if(typeof W.insert!="string")break;ie=W.insert+ie}return ie.slice(-1*Y.length)===Y}function C(Z){if(Z.childNodes.length===0)return!1;var Y=B(Z);return["block","list-item"].indexOf(Y.display)>-1}function $(Z,Y,ie){return Z.nodeType===Z.TEXT_NODE?ie.reduce(function(ue,W){return W(Z,ue)},new l.default):Z.nodeType===Z.ELEMENT_NODE?[].reduce.call(Z.childNodes||[],function(ue,W){var te=$(W,Y,ie);return W.nodeType===Z.ELEMENT_NODE&&(te=Y.reduce(function(ae,de){return de(W,ae)},te),te=(W[ee]||[]).reduce(function(ae,de){return de(W,ae)},te)),ue.concat(te)},new l.default):new l.default}function z(Z,Y,ie){return P(ie,Z,!0)}function G(Z,Y){var ie=n.default.Attributor.Attribute.keys(Z),ue=n.default.Attributor.Class.keys(Z),W=n.default.Attributor.Style.keys(Z),te={};return ie.concat(ue).concat(W).forEach(function(ae){var de=n.default.query(ae,n.default.Scope.ATTRIBUTE);de!=null&&(te[de.attrName]=de.value(Z),te[de.attrName])||(de=D[ae],de!=null&&(de.attrName===ae||de.keyName===ae)&&(te[de.attrName]=de.value(Z)||void 0),de=N[ae],de!=null&&(de.attrName===ae||de.keyName===ae)&&(de=N[ae],te[de.attrName]=de.value(Z)||void 0))}),Object.keys(te).length>0&&(Y=P(Y,te)),Y}function J(Z,Y){var ie=n.default.query(Z);if(ie==null)return Y;if(ie.prototype instanceof n.default.Embed){var ue={},W=ie.value(Z);W!=null&&(ue[ie.blotName]=W,Y=new l.default().insert(ue,ie.formats(Z)))}else typeof ie.formats=="function"&&(Y=P(Y,ie.blotName,ie.formats(Z)));return Y}function fe(Z,Y){return F(Y,`
`)||Y.insert(`
`),Y}function Q(){return new l.default}function re(Z,Y){var ie=n.default.query(Z);if(ie==null||ie.blotName!=="list-item"||!F(Y,`
`))return Y;for(var ue=-1,W=Z.parentNode;!W.classList.contains("ql-clipboard");)(n.default.query(W)||{}).blotName==="list"&&(ue+=1),W=W.parentNode;return ue<=0?Y:Y.compose(new l.default().retain(Y.length()-1).retain(1,{indent:ue}))}function se(Z,Y){return F(Y,`
`)||(C(Z)||Y.length()>0&&Z.nextSibling&&C(Z.nextSibling))&&Y.insert(`
`),Y}function ce(Z,Y){if(C(Z)&&Z.nextElementSibling!=null&&!F(Y,`

`)){var ie=Z.offsetHeight+parseFloat(B(Z).marginTop)+parseFloat(B(Z).marginBottom);Z.nextElementSibling.offsetTop>Z.offsetTop+ie*1.5&&Y.insert(`
`)}return Y}function Ee(Z,Y){var ie={},ue=Z.style||{};return ue.fontStyle&&B(Z).fontStyle==="italic"&&(ie.italic=!0),ue.fontWeight&&(B(Z).fontWeight.startsWith("bold")||parseInt(B(Z).fontWeight)>=700)&&(ie.bold=!0),Object.keys(ie).length>0&&(Y=P(Y,ie)),parseFloat(ue.textIndent||0)>0&&(Y=new l.default().insert("	").concat(Y)),Y}function he(Z,Y){var ie=Z.data;if(Z.parentNode.tagName==="O:P")return Y.insert(ie.trim());if(ie.trim().length===0&&Z.parentNode.classList.contains("ql-clipboard"))return Y;if(!B(Z.parentNode).whiteSpace.startsWith("pre")){var ue=function(te,ae){return ae=ae.replace(/[^\u00a0]/g,""),ae.length<1&&te?" ":ae};ie=ie.replace(/\r\n/g," ").replace(/\n/g," "),ie=ie.replace(/\s\s+/g,ue.bind(ue,!0)),(Z.previousSibling==null&&C(Z.parentNode)||Z.previousSibling!=null&&C(Z.previousSibling))&&(ie=ie.replace(/^\s+/,ue.bind(ue,!1))),(Z.nextSibling==null&&C(Z.parentNode)||Z.nextSibling!=null&&C(Z.nextSibling))&&(ie=ie.replace(/\s+$/,ue.bind(ue,!1)))}return Y.insert(ie)}s.default=j,s.matchAttributor=G,s.matchBlot=J,s.matchNewline=se,s.matchSpacing=ce,s.matchText=he},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function u(f,c){for(var a=0;a<c.length;a++){var o=c[a];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(f,o.key,o)}}return function(f,c,a){return c&&u(f.prototype,c),a&&u(f,a),f}}(),O=function u(f,c,a){f===null&&(f=Function.prototype);var o=Object.getOwnPropertyDescriptor(f,c);if(o===void 0){var d=Object.getPrototypeOf(f);return d===null?void 0:u(d,c,a)}else{if("value"in o)return o.value;var r=o.get;return r===void 0?void 0:r.call(a)}},w=t(6),y=_(w);function _(u){return u&&u.__esModule?u:{default:u}}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}function l(u,f){if(!u)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return f&&(typeof f=="object"||typeof f=="function")?f:u}function e(u,f){if(typeof f!="function"&&f!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof f);u.prototype=Object.create(f&&f.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),f&&(Object.setPrototypeOf?Object.setPrototypeOf(u,f):u.__proto__=f)}var n=function(u){e(f,u);function f(){return h(this,f),l(this,(f.__proto__||Object.getPrototypeOf(f)).apply(this,arguments))}return m(f,[{key:"optimize",value:function(a){O(f.prototype.__proto__||Object.getPrototypeOf(f.prototype),"optimize",this).call(this,a),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return O(f.__proto__||Object.getPrototypeOf(f),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),f}(y.default);n.blotName="bold",n.tagName=["STRONG","B"],s.default=n},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.addControls=s.default=void 0;var m=function(){function b(E,x){var q=[],I=!0,H=!1,K=void 0;try{for(var ee=E[Symbol.iterator](),V;!(I=(V=ee.next()).done)&&(q.push(V.value),!(x&&q.length===x));I=!0);}catch(D){H=!0,K=D}finally{try{!I&&ee.return&&ee.return()}finally{if(H)throw K}}return q}return function(E,x){if(Array.isArray(E))return E;if(Symbol.iterator in Object(E))return b(E,x);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function b(E,x){for(var q=0;q<x.length;q++){var I=x[q];I.enumerable=I.enumerable||!1,I.configurable=!0,"value"in I&&(I.writable=!0),Object.defineProperty(E,I.key,I)}}return function(E,x,q){return x&&b(E.prototype,x),q&&b(E,q),E}}(),w=t(2),y=a(w),_=t(0),h=a(_),l=t(5),e=a(l),n=t(10),u=a(n),f=t(9),c=a(f);function a(b){return b&&b.__esModule?b:{default:b}}function o(b,E,x){return E in b?Object.defineProperty(b,E,{value:x,enumerable:!0,configurable:!0,writable:!0}):b[E]=x,b}function d(b,E){if(!(b instanceof E))throw new TypeError("Cannot call a class as a function")}function r(b,E){if(!b)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return E&&(typeof E=="object"||typeof E=="function")?E:b}function g(b,E){if(typeof E!="function"&&E!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof E);b.prototype=Object.create(E&&E.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),E&&(Object.setPrototypeOf?Object.setPrototypeOf(b,E):b.__proto__=E)}var S=(0,u.default)("quill:toolbar"),k=function(b){g(E,b);function E(x,q){d(this,E);var I=r(this,(E.__proto__||Object.getPrototypeOf(E)).call(this,x,q));if(Array.isArray(I.options.container)){var H=document.createElement("div");M(H,I.options.container),x.container.parentNode.insertBefore(H,x.container),I.container=H}else typeof I.options.container=="string"?I.container=document.querySelector(I.options.container):I.container=I.options.container;if(!(I.container instanceof HTMLElement)){var K;return K=S.error("Container required for toolbar",I.options),r(I,K)}return I.container.classList.add("ql-toolbar"),I.controls=[],I.handlers={},Object.keys(I.options.handlers).forEach(function(ee){I.addHandler(ee,I.options.handlers[ee])}),[].forEach.call(I.container.querySelectorAll("button, select"),function(ee){I.attach(ee)}),I.quill.on(e.default.events.EDITOR_CHANGE,function(ee,V){ee===e.default.events.SELECTION_CHANGE&&I.update(V)}),I.quill.on(e.default.events.SCROLL_OPTIMIZE,function(){var ee=I.quill.selection.getRange(),V=m(ee,1),D=V[0];I.update(D)}),I}return O(E,[{key:"addHandler",value:function(q,I){this.handlers[q]=I}},{key:"attach",value:function(q){var I=this,H=[].find.call(q.classList,function(ee){return ee.indexOf("ql-")===0});if(!!H){if(H=H.slice(3),q.tagName==="BUTTON"&&q.setAttribute("type","button"),this.handlers[H]==null){if(this.quill.scroll.whitelist!=null&&this.quill.scroll.whitelist[H]==null){S.warn("ignoring attaching to disabled format",H,q);return}if(h.default.query(H)==null){S.warn("ignoring attaching to nonexistent format",H,q);return}}var K=q.tagName==="SELECT"?"change":"click";q.addEventListener(K,function(ee){var V=void 0;if(q.tagName==="SELECT"){if(q.selectedIndex<0)return;var D=q.options[q.selectedIndex];D.hasAttribute("selected")?V=!1:V=D.value||!1}else q.classList.contains("ql-active")?V=!1:V=q.value||!q.hasAttribute("value"),ee.preventDefault();I.quill.focus();var N=I.quill.selection.getRange(),j=m(N,1),P=j[0];if(I.handlers[H]!=null)I.handlers[H].call(I,V);else if(h.default.query(H).prototype instanceof h.default.Embed){if(V=prompt("Enter "+H),!V)return;I.quill.updateContents(new y.default().retain(P.index).delete(P.length).insert(o({},H,V)),e.default.sources.USER)}else I.quill.format(H,V,e.default.sources.USER);I.update(P)}),this.controls.push([H,q])}}},{key:"update",value:function(q){var I=q==null?{}:this.quill.getFormat(q);this.controls.forEach(function(H){var K=m(H,2),ee=K[0],V=K[1];if(V.tagName==="SELECT"){var D=void 0;if(q==null)D=null;else if(I[ee]==null)D=V.querySelector("option[selected]");else if(!Array.isArray(I[ee])){var N=I[ee];typeof N=="string"&&(N=N.replace(/\"/g,'\\"')),D=V.querySelector('option[value="'+N+'"]')}D==null?(V.value="",V.selectedIndex=-1):D.selected=!0}else if(q==null)V.classList.remove("ql-active");else if(V.hasAttribute("value")){var j=I[ee]===V.getAttribute("value")||I[ee]!=null&&I[ee].toString()===V.getAttribute("value")||I[ee]==null&&!V.getAttribute("value");V.classList.toggle("ql-active",j)}else V.classList.toggle("ql-active",I[ee]!=null)})}}]),E}(c.default);k.DEFAULTS={};function A(b,E,x){var q=document.createElement("button");q.setAttribute("type","button"),q.classList.add("ql-"+E),x!=null&&(q.value=x),b.appendChild(q)}function M(b,E){Array.isArray(E[0])||(E=[E]),E.forEach(function(x){var q=document.createElement("span");q.classList.add("ql-formats"),x.forEach(function(I){if(typeof I=="string")A(q,I);else{var H=Object.keys(I)[0],K=I[H];Array.isArray(K)?T(q,H,K):A(q,H,K)}}),b.appendChild(q)})}function T(b,E,x){var q=document.createElement("select");q.classList.add("ql-"+E),x.forEach(function(I){var H=document.createElement("option");I!==!1?H.setAttribute("value",I):H.setAttribute("selected","selected"),q.appendChild(H)}),b.appendChild(q)}k.DEFAULTS={container:null,handlers:{clean:function(){var E=this,x=this.quill.getSelection();if(x!=null)if(x.length==0){var q=this.quill.getFormat();Object.keys(q).forEach(function(I){h.default.query(I,h.default.Scope.INLINE)!=null&&E.quill.format(I,!1)})}else this.quill.removeFormat(x,e.default.sources.USER)},direction:function(E){var x=this.quill.getFormat().align;E==="rtl"&&x==null?this.quill.format("align","right",e.default.sources.USER):!E&&x==="right"&&this.quill.format("align",!1,e.default.sources.USER),this.quill.format("direction",E,e.default.sources.USER)},indent:function(E){var x=this.quill.getSelection(),q=this.quill.getFormat(x),I=parseInt(q.indent||0);if(E==="+1"||E==="-1"){var H=E==="+1"?1:-1;q.direction==="rtl"&&(H*=-1),this.quill.format("indent",I+H,e.default.sources.USER)}},link:function(E){E===!0&&(E=prompt("Enter link URL:")),this.quill.format("link",E,e.default.sources.USER)},list:function(E){var x=this.quill.getSelection(),q=this.quill.getFormat(x);E==="check"?q.list==="checked"||q.list==="unchecked"?this.quill.format("list",!1,e.default.sources.USER):this.quill.format("list","unchecked",e.default.sources.USER):this.quill.format("list",E,e.default.sources.USER)}}},s.default=k,s.addControls=M},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function u(f,c){for(var a=0;a<c.length;a++){var o=c[a];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(f,o.key,o)}}return function(f,c,a){return c&&u(f.prototype,c),a&&u(f,a),f}}(),O=function u(f,c,a){f===null&&(f=Function.prototype);var o=Object.getOwnPropertyDescriptor(f,c);if(o===void 0){var d=Object.getPrototypeOf(f);return d===null?void 0:u(d,c,a)}else{if("value"in o)return o.value;var r=o.get;return r===void 0?void 0:r.call(a)}},w=t(28),y=_(w);function _(u){return u&&u.__esModule?u:{default:u}}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}function l(u,f){if(!u)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return f&&(typeof f=="object"||typeof f=="function")?f:u}function e(u,f){if(typeof f!="function"&&f!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof f);u.prototype=Object.create(f&&f.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),f&&(Object.setPrototypeOf?Object.setPrototypeOf(u,f):u.__proto__=f)}var n=function(u){e(f,u);function f(c,a){h(this,f);var o=l(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,c));return o.label.innerHTML=a,o.container.classList.add("ql-color-picker"),[].slice.call(o.container.querySelectorAll(".ql-picker-item"),0,7).forEach(function(d){d.classList.add("ql-primary")}),o}return m(f,[{key:"buildItem",value:function(a){var o=O(f.prototype.__proto__||Object.getPrototypeOf(f.prototype),"buildItem",this).call(this,a);return o.style.backgroundColor=a.getAttribute("value")||"",o}},{key:"selectItem",value:function(a,o){O(f.prototype.__proto__||Object.getPrototypeOf(f.prototype),"selectItem",this).call(this,a,o);var d=this.label.querySelector(".ql-color-label"),r=a&&a.getAttribute("data-value")||"";d&&(d.tagName==="line"?d.style.stroke=r:d.style.fill=r)}}]),f}(y.default);s.default=n},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function u(f,c){for(var a=0;a<c.length;a++){var o=c[a];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(f,o.key,o)}}return function(f,c,a){return c&&u(f.prototype,c),a&&u(f,a),f}}(),O=function u(f,c,a){f===null&&(f=Function.prototype);var o=Object.getOwnPropertyDescriptor(f,c);if(o===void 0){var d=Object.getPrototypeOf(f);return d===null?void 0:u(d,c,a)}else{if("value"in o)return o.value;var r=o.get;return r===void 0?void 0:r.call(a)}},w=t(28),y=_(w);function _(u){return u&&u.__esModule?u:{default:u}}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}function l(u,f){if(!u)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return f&&(typeof f=="object"||typeof f=="function")?f:u}function e(u,f){if(typeof f!="function"&&f!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof f);u.prototype=Object.create(f&&f.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),f&&(Object.setPrototypeOf?Object.setPrototypeOf(u,f):u.__proto__=f)}var n=function(u){e(f,u);function f(c,a){h(this,f);var o=l(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,c));return o.container.classList.add("ql-icon-picker"),[].forEach.call(o.container.querySelectorAll(".ql-picker-item"),function(d){d.innerHTML=a[d.getAttribute("data-value")||""]}),o.defaultItem=o.container.querySelector(".ql-selected"),o.selectItem(o.defaultItem),o}return m(f,[{key:"selectItem",value:function(a,o){O(f.prototype.__proto__||Object.getPrototypeOf(f.prototype),"selectItem",this).call(this,a,o),a=a||this.defaultItem,this.label.innerHTML=a.innerHTML}}]),f}(y.default);s.default=n},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function y(_,h){for(var l=0;l<h.length;l++){var e=h[l];e.enumerable=e.enumerable||!1,e.configurable=!0,"value"in e&&(e.writable=!0),Object.defineProperty(_,e.key,e)}}return function(_,h,l){return h&&y(_.prototype,h),l&&y(_,l),_}}();function O(y,_){if(!(y instanceof _))throw new TypeError("Cannot call a class as a function")}var w=function(){function y(_,h){var l=this;O(this,y),this.quill=_,this.boundsContainer=h||document.body,this.root=_.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",function(){l.root.style.marginTop=-1*l.quill.root.scrollTop+"px"}),this.hide()}return m(y,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(h){var l=h.left+h.width/2-this.root.offsetWidth/2,e=h.bottom+this.quill.root.scrollTop;this.root.style.left=l+"px",this.root.style.top=e+"px",this.root.classList.remove("ql-flip");var n=this.boundsContainer.getBoundingClientRect(),u=this.root.getBoundingClientRect(),f=0;if(u.right>n.right&&(f=n.right-u.right,this.root.style.left=l+f+"px"),u.left<n.left&&(f=n.left-u.left,this.root.style.left=l+f+"px"),u.bottom>n.bottom){var c=u.bottom-u.top,a=h.bottom-h.top+c;this.root.style.top=e-a+"px",this.root.classList.add("ql-flip")}return f}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),y}();s.default=w},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function T(b,E){var x=[],q=!0,I=!1,H=void 0;try{for(var K=b[Symbol.iterator](),ee;!(q=(ee=K.next()).done)&&(x.push(ee.value),!(E&&x.length===E));q=!0);}catch(V){I=!0,H=V}finally{try{!q&&K.return&&K.return()}finally{if(I)throw H}}return x}return function(b,E){if(Array.isArray(b))return b;if(Symbol.iterator in Object(b))return T(b,E);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function T(b,E,x){b===null&&(b=Function.prototype);var q=Object.getOwnPropertyDescriptor(b,E);if(q===void 0){var I=Object.getPrototypeOf(b);return I===null?void 0:T(I,E,x)}else{if("value"in q)return q.value;var H=q.get;return H===void 0?void 0:H.call(x)}},w=function(){function T(b,E){for(var x=0;x<E.length;x++){var q=E[x];q.enumerable=q.enumerable||!1,q.configurable=!0,"value"in q&&(q.writable=!0),Object.defineProperty(b,q.key,q)}}return function(b,E,x){return E&&T(b.prototype,E),x&&T(b,x),b}}(),y=t(3),_=d(y),h=t(8),l=d(h),e=t(43),n=d(e),u=t(27),f=d(u),c=t(15),a=t(41),o=d(a);function d(T){return T&&T.__esModule?T:{default:T}}function r(T,b){if(!(T instanceof b))throw new TypeError("Cannot call a class as a function")}function g(T,b){if(!T)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:T}function S(T,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);T.prototype=Object.create(b&&b.prototype,{constructor:{value:T,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(T,b):T.__proto__=b)}var k=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],A=function(T){S(b,T);function b(E,x){r(this,b),x.modules.toolbar!=null&&x.modules.toolbar.container==null&&(x.modules.toolbar.container=k);var q=g(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,E,x));return q.quill.container.classList.add("ql-snow"),q}return w(b,[{key:"extendToolbar",value:function(x){x.container.classList.add("ql-snow"),this.buildButtons([].slice.call(x.container.querySelectorAll("button")),o.default),this.buildPickers([].slice.call(x.container.querySelectorAll("select")),o.default),this.tooltip=new M(this.quill,this.options.bounds),x.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},function(q,I){x.handlers.link.call(x,!I.format.link)})}}]),b}(n.default);A.DEFAULTS=(0,_.default)(!0,{},n.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(b){if(b){var E=this.quill.getSelection();if(E==null||E.length==0)return;var x=this.quill.getText(E);/^\S+@\S+\.\S+$/.test(x)&&x.indexOf("mailto:")!==0&&(x="mailto:"+x);var q=this.quill.theme.tooltip;q.edit("link",x)}else this.quill.format("link",!1)}}}}});var M=function(T){S(b,T);function b(E,x){r(this,b);var q=g(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,E,x));return q.preview=q.root.querySelector("a.ql-preview"),q}return w(b,[{key:"listen",value:function(){var x=this;O(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",function(q){x.root.classList.contains("ql-editing")?x.save():x.edit("link",x.preview.textContent),q.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",function(q){if(x.linkRange!=null){var I=x.linkRange;x.restoreFocus(),x.quill.formatText(I,"link",!1,l.default.sources.USER),delete x.linkRange}q.preventDefault(),x.hide()}),this.quill.on(l.default.events.SELECTION_CHANGE,function(q,I,H){if(q!=null){if(q.length===0&&H===l.default.sources.USER){var K=x.quill.scroll.descendant(f.default,q.index),ee=m(K,2),V=ee[0],D=ee[1];if(V!=null){x.linkRange=new c.Range(q.index-D,V.length());var N=f.default.formats(V.domNode);x.preview.textContent=N,x.preview.setAttribute("href",N),x.show(),x.position(x.quill.getBounds(x.linkRange));return}}else delete x.linkRange;x.hide()}})}},{key:"show",value:function(){O(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),b}(e.BaseTooltip);M.TEMPLATE=['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),s.default=A},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(29),O=W(m),w=t(36),y=t(38),_=t(64),h=t(65),l=W(h),e=t(66),n=W(e),u=t(67),f=W(u),c=t(37),a=t(26),o=t(39),d=t(40),r=t(56),g=W(r),S=t(68),k=W(S),A=t(27),M=W(A),T=t(69),b=W(T),E=t(70),x=W(E),q=t(71),I=W(q),H=t(72),K=W(H),ee=t(73),V=W(ee),D=t(13),N=W(D),j=t(74),P=W(j),B=t(75),F=W(B),C=t(57),$=W(C),z=t(41),G=W(z),J=t(28),fe=W(J),Q=t(59),re=W(Q),se=t(60),ce=W(se),Ee=t(61),he=W(Ee),Z=t(108),Y=W(Z),ie=t(62),ue=W(ie);function W(te){return te&&te.__esModule?te:{default:te}}O.default.register({"attributors/attribute/direction":y.DirectionAttribute,"attributors/class/align":w.AlignClass,"attributors/class/background":c.BackgroundClass,"attributors/class/color":a.ColorClass,"attributors/class/direction":y.DirectionClass,"attributors/class/font":o.FontClass,"attributors/class/size":d.SizeClass,"attributors/style/align":w.AlignStyle,"attributors/style/background":c.BackgroundStyle,"attributors/style/color":a.ColorStyle,"attributors/style/direction":y.DirectionStyle,"attributors/style/font":o.FontStyle,"attributors/style/size":d.SizeStyle},!0),O.default.register({"formats/align":w.AlignClass,"formats/direction":y.DirectionClass,"formats/indent":_.IndentClass,"formats/background":c.BackgroundStyle,"formats/color":a.ColorStyle,"formats/font":o.FontClass,"formats/size":d.SizeClass,"formats/blockquote":l.default,"formats/code-block":N.default,"formats/header":n.default,"formats/list":f.default,"formats/bold":g.default,"formats/code":D.Code,"formats/italic":k.default,"formats/link":M.default,"formats/script":b.default,"formats/strike":x.default,"formats/underline":I.default,"formats/image":K.default,"formats/video":V.default,"formats/list/item":u.ListItem,"modules/formula":P.default,"modules/syntax":F.default,"modules/toolbar":$.default,"themes/bubble":Y.default,"themes/snow":ue.default,"ui/icons":G.default,"ui/picker":fe.default,"ui/icon-picker":ce.default,"ui/color-picker":re.default,"ui/tooltip":he.default},!0),s.default=O.default},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.IndentClass=void 0;var m=function(){function f(c,a){for(var o=0;o<a.length;o++){var d=a[o];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(c,d.key,d)}}return function(c,a,o){return a&&f(c.prototype,a),o&&f(c,o),c}}(),O=function f(c,a,o){c===null&&(c=Function.prototype);var d=Object.getOwnPropertyDescriptor(c,a);if(d===void 0){var r=Object.getPrototypeOf(c);return r===null?void 0:f(r,a,o)}else{if("value"in d)return d.value;var g=d.get;return g===void 0?void 0:g.call(o)}},w=t(0),y=_(w);function _(f){return f&&f.__esModule?f:{default:f}}function h(f,c){if(!(f instanceof c))throw new TypeError("Cannot call a class as a function")}function l(f,c){if(!f)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return c&&(typeof c=="object"||typeof c=="function")?c:f}function e(f,c){if(typeof c!="function"&&c!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof c);f.prototype=Object.create(c&&c.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}),c&&(Object.setPrototypeOf?Object.setPrototypeOf(f,c):f.__proto__=c)}var n=function(f){e(c,f);function c(){return h(this,c),l(this,(c.__proto__||Object.getPrototypeOf(c)).apply(this,arguments))}return m(c,[{key:"add",value:function(o,d){if(d==="+1"||d==="-1"){var r=this.value(o)||0;d=d==="+1"?r+1:r-1}return d===0?(this.remove(o),!0):O(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"add",this).call(this,o,d)}},{key:"canAdd",value:function(o,d){return O(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"canAdd",this).call(this,o,d)||O(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"canAdd",this).call(this,o,parseInt(d))}},{key:"value",value:function(o){return parseInt(O(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"value",this).call(this,o))||void 0}}]),c}(y.default.Attributor.Class),u=new n("indent","ql-indent",{scope:y.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});s.IndentClass=u},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(4),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}function y(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function _(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function h(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var l=function(e){h(n,e);function n(){return y(this,n),_(this,(n.__proto__||Object.getPrototypeOf(n)).apply(this,arguments))}return n}(O.default);l.blotName="blockquote",l.tagName="blockquote",s.default=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function n(u,f){for(var c=0;c<f.length;c++){var a=f[c];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(u,a.key,a)}}return function(u,f,c){return f&&n(u.prototype,f),c&&n(u,c),u}}(),O=t(4),w=y(O);function y(n){return n&&n.__esModule?n:{default:n}}function _(n,u){if(!(n instanceof u))throw new TypeError("Cannot call a class as a function")}function h(n,u){if(!n)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return u&&(typeof u=="object"||typeof u=="function")?u:n}function l(n,u){if(typeof u!="function"&&u!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof u);n.prototype=Object.create(u&&u.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),u&&(Object.setPrototypeOf?Object.setPrototypeOf(n,u):n.__proto__=u)}var e=function(n){l(u,n);function u(){return _(this,u),h(this,(u.__proto__||Object.getPrototypeOf(u)).apply(this,arguments))}return m(u,null,[{key:"formats",value:function(c){return this.tagName.indexOf(c.tagName)+1}}]),u}(w.default);e.blotName="header",e.tagName=["H1","H2","H3","H4","H5","H6"],s.default=e},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.ListItem=void 0;var m=function(){function r(g,S){for(var k=0;k<S.length;k++){var A=S[k];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(g,A.key,A)}}return function(g,S,k){return S&&r(g.prototype,S),k&&r(g,k),g}}(),O=function r(g,S,k){g===null&&(g=Function.prototype);var A=Object.getOwnPropertyDescriptor(g,S);if(A===void 0){var M=Object.getPrototypeOf(g);return M===null?void 0:r(M,S,k)}else{if("value"in A)return A.value;var T=A.get;return T===void 0?void 0:T.call(k)}},w=t(0),y=n(w),_=t(4),h=n(_),l=t(25),e=n(l);function n(r){return r&&r.__esModule?r:{default:r}}function u(r,g,S){return g in r?Object.defineProperty(r,g,{value:S,enumerable:!0,configurable:!0,writable:!0}):r[g]=S,r}function f(r,g){if(!(r instanceof g))throw new TypeError("Cannot call a class as a function")}function c(r,g){if(!r)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:r}function a(r,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);r.prototype=Object.create(g&&g.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(r,g):r.__proto__=g)}var o=function(r){a(g,r);function g(){return f(this,g),c(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return m(g,[{key:"format",value:function(k,A){k===d.blotName&&!A?this.replaceWith(y.default.create(this.statics.scope)):O(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"format",this).call(this,k,A)}},{key:"remove",value:function(){this.prev==null&&this.next==null?this.parent.remove():O(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(k,A){return this.parent.isolate(this.offset(this.parent),this.length()),k===this.parent.statics.blotName?(this.parent.replaceWith(k,A),this):(this.parent.unwrap(),O(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"replaceWith",this).call(this,k,A))}}],[{key:"formats",value:function(k){return k.tagName===this.tagName?void 0:O(g.__proto__||Object.getPrototypeOf(g),"formats",this).call(this,k)}}]),g}(h.default);o.blotName="list-item",o.tagName="LI";var d=function(r){a(g,r),m(g,null,[{key:"create",value:function(k){var A=k==="ordered"?"OL":"UL",M=O(g.__proto__||Object.getPrototypeOf(g),"create",this).call(this,A);return(k==="checked"||k==="unchecked")&&M.setAttribute("data-checked",k==="checked"),M}},{key:"formats",value:function(k){if(k.tagName==="OL")return"ordered";if(k.tagName==="UL")return k.hasAttribute("data-checked")?k.getAttribute("data-checked")==="true"?"checked":"unchecked":"bullet"}}]);function g(S){f(this,g);var k=c(this,(g.__proto__||Object.getPrototypeOf(g)).call(this,S)),A=function(T){if(T.target.parentNode===S){var b=k.statics.formats(S),E=y.default.find(T.target);b==="checked"?E.format("list","unchecked"):b==="unchecked"&&E.format("list","checked")}};return S.addEventListener("touchstart",A),S.addEventListener("mousedown",A),k}return m(g,[{key:"format",value:function(k,A){this.children.length>0&&this.children.tail.format(k,A)}},{key:"formats",value:function(){return u({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(k,A){if(k instanceof o)O(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"insertBefore",this).call(this,k,A);else{var M=A==null?this.length():A.offset(this),T=this.split(M);T.parent.insertBefore(k,T)}}},{key:"optimize",value:function(k){O(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"optimize",this).call(this,k);var A=this.next;A!=null&&A.prev===this&&A.statics.blotName===this.statics.blotName&&A.domNode.tagName===this.domNode.tagName&&A.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(A.moveChildren(this),A.remove())}},{key:"replace",value:function(k){if(k.statics.blotName!==this.statics.blotName){var A=y.default.create(this.statics.defaultChild);k.moveChildren(A),this.appendChild(A)}O(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"replace",this).call(this,k)}}]),g}(e.default);d.blotName="list",d.scope=y.default.Scope.BLOCK_BLOT,d.tagName=["OL","UL"],d.defaultChild="list-item",d.allowedChildren=[o],s.ListItem=o,s.default=d},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(56),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}function y(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function _(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function h(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var l=function(e){h(n,e);function n(){return y(this,n),_(this,(n.__proto__||Object.getPrototypeOf(n)).apply(this,arguments))}return n}(O.default);l.blotName="italic",l.tagName=["EM","I"],s.default=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function u(f,c){for(var a=0;a<c.length;a++){var o=c[a];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(f,o.key,o)}}return function(f,c,a){return c&&u(f.prototype,c),a&&u(f,a),f}}(),O=function u(f,c,a){f===null&&(f=Function.prototype);var o=Object.getOwnPropertyDescriptor(f,c);if(o===void 0){var d=Object.getPrototypeOf(f);return d===null?void 0:u(d,c,a)}else{if("value"in o)return o.value;var r=o.get;return r===void 0?void 0:r.call(a)}},w=t(6),y=_(w);function _(u){return u&&u.__esModule?u:{default:u}}function h(u,f){if(!(u instanceof f))throw new TypeError("Cannot call a class as a function")}function l(u,f){if(!u)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return f&&(typeof f=="object"||typeof f=="function")?f:u}function e(u,f){if(typeof f!="function"&&f!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof f);u.prototype=Object.create(f&&f.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),f&&(Object.setPrototypeOf?Object.setPrototypeOf(u,f):u.__proto__=f)}var n=function(u){e(f,u);function f(){return h(this,f),l(this,(f.__proto__||Object.getPrototypeOf(f)).apply(this,arguments))}return m(f,null,[{key:"create",value:function(a){return a==="super"?document.createElement("sup"):a==="sub"?document.createElement("sub"):O(f.__proto__||Object.getPrototypeOf(f),"create",this).call(this,a)}},{key:"formats",value:function(a){if(a.tagName==="SUB")return"sub";if(a.tagName==="SUP")return"super"}}]),f}(y.default);n.blotName="script",n.tagName=["SUB","SUP"],s.default=n},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(6),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}function y(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function _(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function h(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var l=function(e){h(n,e);function n(){return y(this,n),_(this,(n.__proto__||Object.getPrototypeOf(n)).apply(this,arguments))}return n}(O.default);l.blotName="strike",l.tagName="S",s.default=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=t(6),O=w(m);function w(e){return e&&e.__esModule?e:{default:e}}function y(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}function _(e,n){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n&&(typeof n=="object"||typeof n=="function")?n:e}function h(e,n){if(typeof n!="function"&&n!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof n);e.prototype=Object.create(n&&n.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),n&&(Object.setPrototypeOf?Object.setPrototypeOf(e,n):e.__proto__=n)}var l=function(e){h(n,e);function n(){return y(this,n),_(this,(n.__proto__||Object.getPrototypeOf(n)).apply(this,arguments))}return n}(O.default);l.blotName="underline",l.tagName="U",s.default=l},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function c(a,o){for(var d=0;d<o.length;d++){var r=o[d];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(a,r.key,r)}}return function(a,o,d){return o&&c(a.prototype,o),d&&c(a,d),a}}(),O=function c(a,o,d){a===null&&(a=Function.prototype);var r=Object.getOwnPropertyDescriptor(a,o);if(r===void 0){var g=Object.getPrototypeOf(a);return g===null?void 0:c(g,o,d)}else{if("value"in r)return r.value;var S=r.get;return S===void 0?void 0:S.call(d)}},w=t(0),y=h(w),_=t(27);function h(c){return c&&c.__esModule?c:{default:c}}function l(c,a){if(!(c instanceof a))throw new TypeError("Cannot call a class as a function")}function e(c,a){if(!c)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return a&&(typeof a=="object"||typeof a=="function")?a:c}function n(c,a){if(typeof a!="function"&&a!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof a);c.prototype=Object.create(a&&a.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}),a&&(Object.setPrototypeOf?Object.setPrototypeOf(c,a):c.__proto__=a)}var u=["alt","height","width"],f=function(c){n(a,c);function a(){return l(this,a),e(this,(a.__proto__||Object.getPrototypeOf(a)).apply(this,arguments))}return m(a,[{key:"format",value:function(d,r){u.indexOf(d)>-1?r?this.domNode.setAttribute(d,r):this.domNode.removeAttribute(d):O(a.prototype.__proto__||Object.getPrototypeOf(a.prototype),"format",this).call(this,d,r)}}],[{key:"create",value:function(d){var r=O(a.__proto__||Object.getPrototypeOf(a),"create",this).call(this,d);return typeof d=="string"&&r.setAttribute("src",this.sanitize(d)),r}},{key:"formats",value:function(d){return u.reduce(function(r,g){return d.hasAttribute(g)&&(r[g]=d.getAttribute(g)),r},{})}},{key:"match",value:function(d){return/\.(jpe?g|gif|png)$/.test(d)||/^data:image\/.+;base64/.test(d)}},{key:"sanitize",value:function(d){return(0,_.sanitize)(d,["http","https","data"])?d:"//:0"}},{key:"value",value:function(d){return d.getAttribute("src")}}]),a}(y.default.Embed);f.blotName="image",f.tagName="IMG",s.default=f},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0});var m=function(){function c(a,o){for(var d=0;d<o.length;d++){var r=o[d];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(a,r.key,r)}}return function(a,o,d){return o&&c(a.prototype,o),d&&c(a,d),a}}(),O=function c(a,o,d){a===null&&(a=Function.prototype);var r=Object.getOwnPropertyDescriptor(a,o);if(r===void 0){var g=Object.getPrototypeOf(a);return g===null?void 0:c(g,o,d)}else{if("value"in r)return r.value;var S=r.get;return S===void 0?void 0:S.call(d)}},w=t(4),y=t(27),_=h(y);function h(c){return c&&c.__esModule?c:{default:c}}function l(c,a){if(!(c instanceof a))throw new TypeError("Cannot call a class as a function")}function e(c,a){if(!c)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return a&&(typeof a=="object"||typeof a=="function")?a:c}function n(c,a){if(typeof a!="function"&&a!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof a);c.prototype=Object.create(a&&a.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}),a&&(Object.setPrototypeOf?Object.setPrototypeOf(c,a):c.__proto__=a)}var u=["height","width"],f=function(c){n(a,c);function a(){return l(this,a),e(this,(a.__proto__||Object.getPrototypeOf(a)).apply(this,arguments))}return m(a,[{key:"format",value:function(d,r){u.indexOf(d)>-1?r?this.domNode.setAttribute(d,r):this.domNode.removeAttribute(d):O(a.prototype.__proto__||Object.getPrototypeOf(a.prototype),"format",this).call(this,d,r)}}],[{key:"create",value:function(d){var r=O(a.__proto__||Object.getPrototypeOf(a),"create",this).call(this,d);return r.setAttribute("frameborder","0"),r.setAttribute("allowfullscreen",!0),r.setAttribute("src",this.sanitize(d)),r}},{key:"formats",value:function(d){return u.reduce(function(r,g){return d.hasAttribute(g)&&(r[g]=d.getAttribute(g)),r},{})}},{key:"sanitize",value:function(d){return _.default.sanitize(d)}},{key:"value",value:function(d){return d.getAttribute("src")}}]),a}(w.BlockEmbed);f.blotName="video",f.className="ql-video",f.tagName="IFRAME",s.default=f},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.FormulaBlot=void 0;var m=function(){function d(r,g){for(var S=0;S<g.length;S++){var k=g[S];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(r,k.key,k)}}return function(r,g,S){return g&&d(r.prototype,g),S&&d(r,S),r}}(),O=function d(r,g,S){r===null&&(r=Function.prototype);var k=Object.getOwnPropertyDescriptor(r,g);if(k===void 0){var A=Object.getPrototypeOf(r);return A===null?void 0:d(A,g,S)}else{if("value"in k)return k.value;var M=k.get;return M===void 0?void 0:M.call(S)}},w=t(35),y=n(w),_=t(5),h=n(_),l=t(9),e=n(l);function n(d){return d&&d.__esModule?d:{default:d}}function u(d,r){if(!(d instanceof r))throw new TypeError("Cannot call a class as a function")}function f(d,r){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r&&(typeof r=="object"||typeof r=="function")?r:d}function c(d,r){if(typeof r!="function"&&r!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof r);d.prototype=Object.create(r&&r.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),r&&(Object.setPrototypeOf?Object.setPrototypeOf(d,r):d.__proto__=r)}var a=function(d){c(r,d);function r(){return u(this,r),f(this,(r.__proto__||Object.getPrototypeOf(r)).apply(this,arguments))}return m(r,null,[{key:"create",value:function(S){var k=O(r.__proto__||Object.getPrototypeOf(r),"create",this).call(this,S);return typeof S=="string"&&(window.katex.render(S,k,{throwOnError:!1,errorColor:"#f00"}),k.setAttribute("data-value",S)),k}},{key:"value",value:function(S){return S.getAttribute("data-value")}}]),r}(y.default);a.blotName="formula",a.className="ql-formula",a.tagName="SPAN";var o=function(d){c(r,d),m(r,null,[{key:"register",value:function(){h.default.register(a,!0)}}]);function r(){u(this,r);var g=f(this,(r.__proto__||Object.getPrototypeOf(r)).call(this));if(window.katex==null)throw new Error("Formula module requires KaTeX.");return g}return r}(e.default);s.FormulaBlot=a,s.default=o},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.CodeToken=s.CodeBlock=void 0;var m=function(){function S(k,A){for(var M=0;M<A.length;M++){var T=A[M];T.enumerable=T.enumerable||!1,T.configurable=!0,"value"in T&&(T.writable=!0),Object.defineProperty(k,T.key,T)}}return function(k,A,M){return A&&S(k.prototype,A),M&&S(k,M),k}}(),O=function S(k,A,M){k===null&&(k=Function.prototype);var T=Object.getOwnPropertyDescriptor(k,A);if(T===void 0){var b=Object.getPrototypeOf(k);return b===null?void 0:S(b,A,M)}else{if("value"in T)return T.value;var E=T.get;return E===void 0?void 0:E.call(M)}},w=t(0),y=f(w),_=t(5),h=f(_),l=t(9),e=f(l),n=t(13),u=f(n);function f(S){return S&&S.__esModule?S:{default:S}}function c(S,k){if(!(S instanceof k))throw new TypeError("Cannot call a class as a function")}function a(S,k){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return k&&(typeof k=="object"||typeof k=="function")?k:S}function o(S,k){if(typeof k!="function"&&k!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof k);S.prototype=Object.create(k&&k.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),k&&(Object.setPrototypeOf?Object.setPrototypeOf(S,k):S.__proto__=k)}var d=function(S){o(k,S);function k(){return c(this,k),a(this,(k.__proto__||Object.getPrototypeOf(k)).apply(this,arguments))}return m(k,[{key:"replaceWith",value:function(M){this.domNode.textContent=this.domNode.textContent,this.attach(),O(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"replaceWith",this).call(this,M)}},{key:"highlight",value:function(M){var T=this.domNode.textContent;this.cachedText!==T&&((T.trim().length>0||this.cachedText==null)&&(this.domNode.innerHTML=M(T),this.domNode.normalize(),this.attach()),this.cachedText=T)}}]),k}(u.default);d.className="ql-syntax";var r=new y.default.Attributor.Class("token","hljs",{scope:y.default.Scope.INLINE}),g=function(S){o(k,S),m(k,null,[{key:"register",value:function(){h.default.register(r,!0),h.default.register(d,!0)}}]);function k(A,M){c(this,k);var T=a(this,(k.__proto__||Object.getPrototypeOf(k)).call(this,A,M));if(typeof T.options.highlight!="function")throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var b=null;return T.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(b),b=setTimeout(function(){T.highlight(),b=null},T.options.interval)}),T.highlight(),T}return m(k,[{key:"highlight",value:function(){var M=this;if(!this.quill.selection.composing){this.quill.update(h.default.sources.USER);var T=this.quill.getSelection();this.quill.scroll.descendants(d).forEach(function(b){b.highlight(M.options.highlight)}),this.quill.update(h.default.sources.SILENT),T!=null&&this.quill.setSelection(T,h.default.sources.SILENT)}}}]),k}(e.default);g.DEFAULTS={highlight:function(){return window.hljs==null?null:function(S){var k=window.hljs.highlightAuto(S);return k.value}}(),interval:1e3},s.CodeBlock=d,s.CodeToken=r,s.default=g},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'},function(p,s){p.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line> <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'},function(p,s){p.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'},function(p,s){p.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'},function(p,s){p.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'},function(p,s){p.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'},function(p,s,t){Object.defineProperty(s,"__esModule",{value:!0}),s.default=s.BubbleTooltip=void 0;var m=function k(A,M,T){A===null&&(A=Function.prototype);var b=Object.getOwnPropertyDescriptor(A,M);if(b===void 0){var E=Object.getPrototypeOf(A);return E===null?void 0:k(E,M,T)}else{if("value"in b)return b.value;var x=b.get;return x===void 0?void 0:x.call(T)}},O=function(){function k(A,M){for(var T=0;T<M.length;T++){var b=M[T];b.enumerable=b.enumerable||!1,b.configurable=!0,"value"in b&&(b.writable=!0),Object.defineProperty(A,b.key,b)}}return function(A,M,T){return M&&k(A.prototype,M),T&&k(A,T),A}}(),w=t(3),y=c(w),_=t(8),h=c(_),l=t(43),e=c(l),n=t(15),u=t(41),f=c(u);function c(k){return k&&k.__esModule?k:{default:k}}function a(k,A){if(!(k instanceof A))throw new TypeError("Cannot call a class as a function")}function o(k,A){if(!k)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return A&&(typeof A=="object"||typeof A=="function")?A:k}function d(k,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof A);k.prototype=Object.create(A&&A.prototype,{constructor:{value:k,enumerable:!1,writable:!0,configurable:!0}}),A&&(Object.setPrototypeOf?Object.setPrototypeOf(k,A):k.__proto__=A)}var r=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],g=function(k){d(A,k);function A(M,T){a(this,A),T.modules.toolbar!=null&&T.modules.toolbar.container==null&&(T.modules.toolbar.container=r);var b=o(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,M,T));return b.quill.container.classList.add("ql-bubble"),b}return O(A,[{key:"extendToolbar",value:function(T){this.tooltip=new S(this.quill,this.options.bounds),this.tooltip.root.appendChild(T.container),this.buildButtons([].slice.call(T.container.querySelectorAll("button")),f.default),this.buildPickers([].slice.call(T.container.querySelectorAll("select")),f.default)}}]),A}(e.default);g.DEFAULTS=(0,y.default)(!0,{},e.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(A){A?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var S=function(k){d(A,k);function A(M,T){a(this,A);var b=o(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,M,T));return b.quill.on(h.default.events.EDITOR_CHANGE,function(E,x,q,I){if(E===h.default.events.SELECTION_CHANGE)if(x!=null&&x.length>0&&I===h.default.sources.USER){b.show(),b.root.style.left="0px",b.root.style.width="",b.root.style.width=b.root.offsetWidth+"px";var H=b.quill.getLines(x.index,x.length);if(H.length===1)b.position(b.quill.getBounds(x));else{var K=H[H.length-1],ee=b.quill.getIndex(K),V=Math.min(K.length()-1,x.index+x.length-ee),D=b.quill.getBounds(new n.Range(ee,V));b.position(D)}}else document.activeElement!==b.textbox&&b.quill.hasFocus()&&b.hide()}),b}return O(A,[{key:"listen",value:function(){var T=this;m(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){T.root.classList.remove("ql-editing")}),this.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!T.root.classList.contains("ql-hidden")){var b=T.quill.getSelection();b!=null&&T.position(T.quill.getBounds(b))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(T){var b=m(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"position",this).call(this,T),E=this.root.querySelector(".ql-tooltip-arrow");if(E.style.marginLeft="",b===0)return b;E.style.marginLeft=-1*b-E.offsetWidth/2+"px"}}]),A}(l.BaseTooltip);S.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),s.BubbleTooltip=S,s.default=g},function(p,s,t){p.exports=t(63)}]).default})})(Ti);var St=lo(Ti.exports),ut=-1,et=1,Qe=0;function nn(i,R,p,s){if(i===R)return i?[[Qe,i]]:[];if(p!=null){var t=Qo(i,R,p);if(t)return t}var m=Dr(i,R),O=i.substring(0,m);i=i.substring(m),R=R.substring(m),m=Br(i,R);var w=i.substring(i.length-m);i=i.substring(0,i.length-m),R=R.substring(0,R.length-m);var y=Vo(i,R);return O&&y.unshift([Qe,O]),w&&y.push([Qe,w]),Ai(y,s),y}function Vo(i,R){var p;if(!i)return[[et,R]];if(!R)return[[ut,i]];var s=i.length>R.length?i:R,t=i.length>R.length?R:i,m=s.indexOf(t);if(m!==-1)return p=[[et,s.substring(0,m)],[Qe,t],[et,s.substring(m+t.length)]],i.length>R.length&&(p[0][0]=p[2][0]=ut),p;if(t.length===1)return[[ut,i],[et,R]];var O=Wo(i,R);if(O){var w=O[0],y=O[1],_=O[2],h=O[3],l=O[4],e=nn(w,_),n=nn(y,h);return e.concat([[Qe,l]],n)}return Ko(i,R)}function Ko(i,R){for(var p=i.length,s=R.length,t=Math.ceil((p+s)/2),m=t,O=2*t,w=new Array(O),y=new Array(O),_=0;_<O;_++)w[_]=-1,y[_]=-1;w[m+1]=0,y[m+1]=0;for(var h=p-s,l=h%2!==0,e=0,n=0,u=0,f=0,c=0;c<t;c++){for(var a=-c+e;a<=c-n;a+=2){var o=m+a,d;a===-c||a!==c&&w[o-1]<w[o+1]?d=w[o+1]:d=w[o-1]+1;for(var r=d-a;d<p&&r<s&&i.charAt(d)===R.charAt(r);)d++,r++;if(w[o]=d,d>p)n+=2;else if(r>s)e+=2;else if(l){var g=m+h-a;if(g>=0&&g<O&&y[g]!==-1){var S=p-y[g];if(d>=S)return oi(i,R,d,r)}}}for(var k=-c+u;k<=c-f;k+=2){var g=m+k,S;k===-c||k!==c&&y[g-1]<y[g+1]?S=y[g+1]:S=y[g-1]+1;for(var A=S-k;S<p&&A<s&&i.charAt(p-S-1)===R.charAt(s-A-1);)S++,A++;if(y[g]=S,S>p)f+=2;else if(A>s)u+=2;else if(!l){var o=m+h-k;if(o>=0&&o<O&&w[o]!==-1){var d=w[o],r=m+d-o;if(S=p-S,d>=S)return oi(i,R,d,r)}}}}return[[ut,i],[et,R]]}function oi(i,R,p,s){var t=i.substring(0,p),m=R.substring(0,s),O=i.substring(p),w=R.substring(s),y=nn(t,m),_=nn(O,w);return y.concat(_)}function Dr(i,R){if(!i||!R||i.charAt(0)!==R.charAt(0))return 0;for(var p=0,s=Math.min(i.length,R.length),t=s,m=0;p<t;)i.substring(m,t)==R.substring(m,t)?(p=t,m=p):s=t,t=Math.floor((s-p)/2+p);return Si(i.charCodeAt(t-1))&&t--,t}function Br(i,R){if(!i||!R||i.slice(-1)!==R.slice(-1))return 0;for(var p=0,s=Math.min(i.length,R.length),t=s,m=0;p<t;)i.substring(i.length-t,i.length-m)==R.substring(R.length-t,R.length-m)?(p=t,m=p):s=t,t=Math.floor((s-p)/2+p);return xi(i.charCodeAt(i.length-t))&&t--,t}function Wo(i,R){var p=i.length>R.length?i:R,s=i.length>R.length?R:i;if(p.length<4||s.length*2<p.length)return null;function t(n,u,f){for(var c=n.substring(f,f+Math.floor(n.length/4)),a=-1,o="",d,r,g,S;(a=u.indexOf(c,a+1))!==-1;){var k=Dr(n.substring(f),u.substring(a)),A=Br(n.substring(0,f),u.substring(0,a));o.length<A+k&&(o=u.substring(a-A,a)+u.substring(a,a+k),d=n.substring(0,f-A),r=n.substring(f+k),g=u.substring(0,a-A),S=u.substring(a+k))}return o.length*2>=n.length?[d,r,g,S,o]:null}var m=t(p,s,Math.ceil(p.length/4)),O=t(p,s,Math.ceil(p.length/2)),w;if(!m&&!O)return null;O?m?w=m[4].length>O[4].length?m:O:w=O:w=m;var y,_,h,l;i.length>R.length?(y=w[0],_=w[1],h=w[2],l=w[3]):(h=w[0],l=w[1],y=w[2],_=w[3]);var e=w[4];return[y,_,h,l,e]}function Ai(i,R){i.push([Qe,""]);for(var p=0,s=0,t=0,m="",O="",w;p<i.length;){if(p<i.length-1&&!i[p][1]){i.splice(p,1);continue}switch(i[p][0]){case et:t++,O+=i[p][1],p++;break;case ut:s++,m+=i[p][1],p++;break;case Qe:var y=p-t-s-1;if(R){if(y>=0&&Pi(i[y][1])){var _=i[y][1].slice(-1);if(i[y][1]=i[y][1].slice(0,-1),m=_+m,O=_+O,!i[y][1]){i.splice(y,1),p--;var h=y-1;i[h]&&i[h][0]===et&&(t++,O=i[h][1]+O,h--),i[h]&&i[h][0]===ut&&(s++,m=i[h][1]+m,h--),y=h}}if(Ni(i[p][1])){var _=i[p][1].charAt(0);i[p][1]=i[p][1].slice(1),m+=_,O+=_}}if(p<i.length-1&&!i[p][1]){i.splice(p,1);break}if(m.length>0||O.length>0){m.length>0&&O.length>0&&(w=Dr(O,m),w!==0&&(y>=0?i[y][1]+=O.substring(0,w):(i.splice(0,0,[Qe,O.substring(0,w)]),p++),O=O.substring(w),m=m.substring(w)),w=Br(O,m),w!==0&&(i[p][1]=O.substring(O.length-w)+i[p][1],O=O.substring(0,O.length-w),m=m.substring(0,m.length-w)));var l=t+s;m.length===0&&O.length===0?(i.splice(p-l,l),p=p-l):m.length===0?(i.splice(p-l,l,[et,O]),p=p-l+1):O.length===0?(i.splice(p-l,l,[ut,m]),p=p-l+1):(i.splice(p-l,l,[ut,m],[et,O]),p=p-l+2)}p!==0&&i[p-1][0]===Qe?(i[p-1][1]+=i[p][1],i.splice(p,1)):p++,t=0,s=0,m="",O="";break}}i[i.length-1][1]===""&&i.pop();var e=!1;for(p=1;p<i.length-1;)i[p-1][0]===Qe&&i[p+1][0]===Qe&&(i[p][1].substring(i[p][1].length-i[p-1][1].length)===i[p-1][1]?(i[p][1]=i[p-1][1]+i[p][1].substring(0,i[p][1].length-i[p-1][1].length),i[p+1][1]=i[p-1][1]+i[p+1][1],i.splice(p-1,1),e=!0):i[p][1].substring(0,i[p+1][1].length)==i[p+1][1]&&(i[p-1][1]+=i[p+1][1],i[p][1]=i[p][1].substring(i[p+1][1].length)+i[p+1][1],i.splice(p+1,1),e=!0)),p++;e&&Ai(i,R)}function Si(i){return i>=55296&&i<=56319}function xi(i){return i>=56320&&i<=57343}function Ni(i){return xi(i.charCodeAt(0))}function Pi(i){return Si(i.charCodeAt(i.length-1))}function Go(i){for(var R=[],p=0;p<i.length;p++)i[p][1].length>0&&R.push(i[p]);return R}function Er(i,R,p,s){return Pi(i)||Ni(s)?null:Go([[Qe,i],[ut,R],[et,p],[Qe,s]])}function Qo(i,R,p){var s=typeof p=="number"?{index:p,length:0}:p.oldRange,t=typeof p=="number"?null:p.newRange,m=i.length,O=R.length;if(s.length===0&&(t===null||t.length===0)){var w=s.index,y=i.slice(0,w),_=i.slice(w),h=t?t.index:null;e:{var l=w+O-m;if(h!==null&&h!==l||l<0||l>O)break e;var e=R.slice(0,l),n=R.slice(l);if(n!==_)break e;var u=Math.min(w,l),f=y.slice(0,u),c=e.slice(0,u);if(f!==c)break e;var a=y.slice(u),o=e.slice(u);return Er(f,a,o,_)}e:{if(h!==null&&h!==w)break e;var d=w,e=R.slice(0,d),n=R.slice(d);if(e!==y)break e;var r=Math.min(m-d,O-d),g=_.slice(_.length-r),S=n.slice(n.length-r);if(g!==S)break e;var a=_.slice(0,_.length-r),o=n.slice(0,n.length-r);return Er(y,a,o,g)}}if(s.length>0&&t&&t.length===0){e:{var f=i.slice(0,s.index),g=i.slice(s.index+s.length),u=f.length,r=g.length;if(O<u+r)break e;var c=R.slice(0,u),S=R.slice(O-r);if(f!==c||g!==S)break e;var a=i.slice(u,m-r),o=R.slice(u,O-r);return Er(f,a,o,g)}}return null}function Pn(i,R,p){return nn(i,R,p,!0)}Pn.INSERT=et;Pn.DELETE=ut;Pn.EQUAL=Qe;var Zo=Pn,Tn={exports:{}};(function(i,R){var p=200,s="__lodash_hash_undefined__",t=9007199254740991,m="[object Arguments]",O="[object Array]",w="[object Boolean]",y="[object Date]",_="[object Error]",h="[object Function]",l="[object GeneratorFunction]",e="[object Map]",n="[object Number]",u="[object Object]",f="[object Promise]",c="[object RegExp]",a="[object Set]",o="[object String]",d="[object Symbol]",r="[object WeakMap]",g="[object ArrayBuffer]",S="[object DataView]",k="[object Float32Array]",A="[object Float64Array]",M="[object Int8Array]",T="[object Int16Array]",b="[object Int32Array]",E="[object Uint8Array]",x="[object Uint8ClampedArray]",q="[object Uint16Array]",I="[object Uint32Array]",H=/[\\^$.*+?()[\]{}|]/g,K=/\w*$/,ee=/^\[object .+?Constructor\]$/,V=/^(?:0|[1-9]\d*)$/,D={};D[m]=D[O]=D[g]=D[S]=D[w]=D[y]=D[k]=D[A]=D[M]=D[T]=D[b]=D[e]=D[n]=D[u]=D[c]=D[a]=D[o]=D[d]=D[E]=D[x]=D[q]=D[I]=!0,D[_]=D[h]=D[r]=!1;var N=typeof Be=="object"&&Be&&Be.Object===Object&&Be,j=typeof self=="object"&&self&&self.Object===Object&&self,P=N||j||Function("return this")(),B=R&&!R.nodeType&&R,F=B&&!0&&i&&!i.nodeType&&i,C=F&&F.exports===B;function $(v,L){return v.set(L[0],L[1]),v}function z(v,L){return v.add(L),v}function G(v,L){for(var U=-1,X=v?v.length:0;++U<X&&L(v[U],U,v)!==!1;);return v}function J(v,L){for(var U=-1,X=L.length,_e=v.length;++U<X;)v[_e+U]=L[U];return v}function fe(v,L,U,X){var _e=-1,pe=v?v.length:0;for(X&&pe&&(U=v[++_e]);++_e<pe;)U=L(U,v[_e],_e,v);return U}function Q(v,L){for(var U=-1,X=Array(v);++U<v;)X[U]=L(U);return X}function re(v,L){return v==null?void 0:v[L]}function se(v){var L=!1;if(v!=null&&typeof v.toString!="function")try{L=!!(v+"")}catch{}return L}function ce(v){var L=-1,U=Array(v.size);return v.forEach(function(X,_e){U[++L]=[_e,X]}),U}function Ee(v,L){return function(U){return v(L(U))}}function he(v){var L=-1,U=Array(v.size);return v.forEach(function(X){U[++L]=X}),U}var Z=Array.prototype,Y=Function.prototype,ie=Object.prototype,ue=P["__core-js_shared__"],W=function(){var v=/[^.]+$/.exec(ue&&ue.keys&&ue.keys.IE_PROTO||"");return v?"Symbol(src)_1."+v:""}(),te=Y.toString,ae=ie.hasOwnProperty,de=ie.toString,we=RegExp("^"+te.call(ae).replace(H,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ye=C?P.Buffer:void 0,ve=P.Symbol,Ne=P.Uint8Array,be=Ee(Object.getPrototypeOf,Object),Ce=Object.create,vt=ie.propertyIsEnumerable,ne=Z.splice,ge=Object.getOwnPropertySymbols,Oe=ye?ye.isBuffer:void 0,Pe=Ee(Object.keys,Object),Le=Ye(P,"DataView"),Fe=Ye(P,"Map"),Ve=Ye(P,"Promise"),tt=Ye(P,"Set"),Bt=Ye(P,"WeakMap"),bt=Ye(Object,"create"),Ft=Ke(Le),_t=Ke(Fe),Ut=Ke(Ve),$t=Ke(tt),Ht=Ke(Bt),pt=ve?ve.prototype:void 0,an=pt?pt.valueOf:void 0;function st(v){var L=-1,U=v?v.length:0;for(this.clear();++L<U;){var X=v[L];this.set(X[0],X[1])}}function Ln(){this.__data__=bt?bt(null):{}}function Rn(v){return this.has(v)&&delete this.__data__[v]}function Cn(v){var L=this.__data__;if(bt){var U=L[v];return U===s?void 0:U}return ae.call(L,v)?L[v]:void 0}function ln(v){var L=this.__data__;return bt?L[v]!==void 0:ae.call(L,v)}function zt(v,L){var U=this.__data__;return U[v]=bt&&L===void 0?s:L,this}st.prototype.clear=Ln,st.prototype.delete=Rn,st.prototype.get=Cn,st.prototype.has=ln,st.prototype.set=zt;function Ie(v){var L=-1,U=v?v.length:0;for(this.clear();++L<U;){var X=v[L];this.set(X[0],X[1])}}function Mn(){this.__data__=[]}function In(v){var L=this.__data__,U=Nt(L,v);if(U<0)return!1;var X=L.length-1;return U==X?L.pop():ne.call(L,U,1),!0}function jn(v){var L=this.__data__,U=Nt(L,v);return U<0?void 0:L[U][1]}function Dn(v){return Nt(this.__data__,v)>-1}function Bn(v,L){var U=this.__data__,X=Nt(U,v);return X<0?U.push([v,L]):U[X][1]=L,this}Ie.prototype.clear=Mn,Ie.prototype.delete=In,Ie.prototype.get=jn,Ie.prototype.has=Dn,Ie.prototype.set=Bn;function Ue(v){var L=-1,U=v?v.length:0;for(this.clear();++L<U;){var X=v[L];this.set(X[0],X[1])}}function Fn(){this.__data__={hash:new st,map:new(Fe||Ie),string:new st}}function Un(v){return wt(this,v).delete(v)}function $n(v){return wt(this,v).get(v)}function Hn(v){return wt(this,v).has(v)}function zn(v,L){return wt(this,v).set(v,L),this}Ue.prototype.clear=Fn,Ue.prototype.delete=Un,Ue.prototype.get=$n,Ue.prototype.has=Hn,Ue.prototype.set=zn;function We(v){this.__data__=new Ie(v)}function Vn(){this.__data__=new Ie}function Kn(v){return this.__data__.delete(v)}function Wn(v){return this.__data__.get(v)}function Gn(v){return this.__data__.has(v)}function Qn(v,L){var U=this.__data__;if(U instanceof Ie){var X=U.__data__;if(!Fe||X.length<p-1)return X.push([v,L]),this;U=this.__data__=new Ue(X)}return U.set(v,L),this}We.prototype.clear=Vn,We.prototype.delete=Kn,We.prototype.get=Wn,We.prototype.has=Gn,We.prototype.set=Qn;function xt(v,L){var U=Gt(v)||qt(v)?Q(v.length,String):[],X=U.length,_e=!!X;for(var pe in v)(L||ae.call(v,pe))&&!(_e&&(pe=="length"||sr(pe,X)))&&U.push(pe);return U}function un(v,L,U){var X=v[L];(!(ae.call(v,L)&&hn(X,U))||U===void 0&&!(L in v))&&(v[L]=U)}function Nt(v,L){for(var U=v.length;U--;)if(hn(v[U][0],L))return U;return-1}function nt(v,L){return v&&Wt(L,Zt(L),v)}function Vt(v,L,U,X,_e,pe,Te){var Se;if(X&&(Se=pe?X(v,_e,pe,Te):X(v)),Se!==void 0)return Se;if(!it(v))return v;var Re=Gt(v);if(Re){if(Se=lr(v),!L)return ir(v,Se)}else{var xe=ct(v),$e=xe==h||xe==l;if(vn(v))return Pt(v,L);if(xe==u||xe==m||$e&&!pe){if(se(v))return pe?v:{};if(Se=rt($e?{}:v),!L)return or(v,nt(Se,v))}else{if(!D[xe])return pe?v:{};Se=ur(v,xe,Vt,L)}}Te||(Te=new We);var Ge=Te.get(v);if(Ge)return Ge;if(Te.set(v,Se),!Re)var Me=U?ar(v):Zt(v);return G(Me||v,function(He,je){Me&&(je=He,He=v[je]),un(Se,je,Vt(He,L,U,X,je,v,Te))}),Se}function Zn(v){return it(v)?Ce(v):{}}function Yn(v,L,U){var X=L(v);return Gt(v)?X:J(X,U(v))}function Xn(v){return de.call(v)}function Jn(v){if(!it(v)||cr(v))return!1;var L=Qt(v)||se(v)?we:ee;return L.test(Ke(v))}function er(v){if(!cn(v))return Pe(v);var L=[];for(var U in Object(v))ae.call(v,U)&&U!="constructor"&&L.push(U);return L}function Pt(v,L){if(L)return v.slice();var U=new v.constructor(v.length);return v.copy(U),U}function Kt(v){var L=new v.constructor(v.byteLength);return new Ne(L).set(new Ne(v)),L}function Ot(v,L){var U=L?Kt(v.buffer):v.buffer;return new v.constructor(U,v.byteOffset,v.byteLength)}function sn(v,L,U){var X=L?U(ce(v),!0):ce(v);return fe(X,$,new v.constructor)}function fn(v){var L=new v.constructor(v.source,K.exec(v));return L.lastIndex=v.lastIndex,L}function tr(v,L,U){var X=L?U(he(v),!0):he(v);return fe(X,z,new v.constructor)}function nr(v){return an?Object(an.call(v)):{}}function rr(v,L){var U=L?Kt(v.buffer):v.buffer;return new v.constructor(U,v.byteOffset,v.length)}function ir(v,L){var U=-1,X=v.length;for(L||(L=Array(X));++U<X;)L[U]=v[U];return L}function Wt(v,L,U,X){U||(U={});for(var _e=-1,pe=L.length;++_e<pe;){var Te=L[_e],Se=X?X(U[Te],v[Te],Te,U,v):void 0;un(U,Te,Se===void 0?v[Te]:Se)}return U}function or(v,L){return Wt(v,ft(v),L)}function ar(v){return Yn(v,Zt,ft)}function wt(v,L){var U=v.__data__;return fr(L)?U[typeof L=="string"?"string":"hash"]:U.map}function Ye(v,L){var U=re(v,L);return Jn(U)?U:void 0}var ft=ge?Ee(ge,Object):hr,ct=Xn;(Le&&ct(new Le(new ArrayBuffer(1)))!=S||Fe&&ct(new Fe)!=e||Ve&&ct(Ve.resolve())!=f||tt&&ct(new tt)!=a||Bt&&ct(new Bt)!=r)&&(ct=function(v){var L=de.call(v),U=L==u?v.constructor:void 0,X=U?Ke(U):void 0;if(X)switch(X){case Ft:return S;case _t:return e;case Ut:return f;case $t:return a;case Ht:return r}return L});function lr(v){var L=v.length,U=v.constructor(L);return L&&typeof v[0]=="string"&&ae.call(v,"index")&&(U.index=v.index,U.input=v.input),U}function rt(v){return typeof v.constructor=="function"&&!cn(v)?Zn(be(v)):{}}function ur(v,L,U,X){var _e=v.constructor;switch(L){case g:return Kt(v);case w:case y:return new _e(+v);case S:return Ot(v,X);case k:case A:case M:case T:case b:case E:case x:case q:case I:return rr(v,X);case e:return sn(v,X,U);case n:case o:return new _e(v);case c:return fn(v);case a:return tr(v,X,U);case d:return nr(v)}}function sr(v,L){return L=L==null?t:L,!!L&&(typeof v=="number"||V.test(v))&&v>-1&&v%1==0&&v<L}function fr(v){var L=typeof v;return L=="string"||L=="number"||L=="symbol"||L=="boolean"?v!=="__proto__":v===null}function cr(v){return!!W&&W in v}function cn(v){var L=v&&v.constructor,U=typeof L=="function"&&L.prototype||ie;return v===U}function Ke(v){if(v!=null){try{return te.call(v)}catch{}try{return v+""}catch{}}return""}function dn(v){return Vt(v,!0,!0)}function hn(v,L){return v===L||v!==v&&L!==L}function qt(v){return dr(v)&&ae.call(v,"callee")&&(!vt.call(v,"callee")||de.call(v)==m)}var Gt=Array.isArray;function Lt(v){return v!=null&&pn(v.length)&&!Qt(v)}function dr(v){return gn(v)&&Lt(v)}var vn=Oe||vr;function Qt(v){var L=it(v)?de.call(v):"";return L==h||L==l}function pn(v){return typeof v=="number"&&v>-1&&v%1==0&&v<=t}function it(v){var L=typeof v;return!!v&&(L=="object"||L=="function")}function gn(v){return!!v&&typeof v=="object"}function Zt(v){return Lt(v)?xt(v):er(v)}function hr(){return[]}function vr(){return!1}i.exports=dn})(Tn,Tn.exports);var An={exports:{}};(function(i,R){var p=200,s="__lodash_hash_undefined__",t=1,m=2,O=9007199254740991,w="[object Arguments]",y="[object Array]",_="[object AsyncFunction]",h="[object Boolean]",l="[object Date]",e="[object Error]",n="[object Function]",u="[object GeneratorFunction]",f="[object Map]",c="[object Number]",a="[object Null]",o="[object Object]",d="[object Promise]",r="[object Proxy]",g="[object RegExp]",S="[object Set]",k="[object String]",A="[object Symbol]",M="[object Undefined]",T="[object WeakMap]",b="[object ArrayBuffer]",E="[object DataView]",x="[object Float32Array]",q="[object Float64Array]",I="[object Int8Array]",H="[object Int16Array]",K="[object Int32Array]",ee="[object Uint8Array]",V="[object Uint8ClampedArray]",D="[object Uint16Array]",N="[object Uint32Array]",j=/[\\^$.*+?()[\]{}|]/g,P=/^\[object .+?Constructor\]$/,B=/^(?:0|[1-9]\d*)$/,F={};F[x]=F[q]=F[I]=F[H]=F[K]=F[ee]=F[V]=F[D]=F[N]=!0,F[w]=F[y]=F[b]=F[h]=F[E]=F[l]=F[e]=F[n]=F[f]=F[c]=F[o]=F[g]=F[S]=F[k]=F[T]=!1;var C=typeof Be=="object"&&Be&&Be.Object===Object&&Be,$=typeof self=="object"&&self&&self.Object===Object&&self,z=C||$||Function("return this")(),G=R&&!R.nodeType&&R,J=G&&!0&&i&&!i.nodeType&&i,fe=J&&J.exports===G,Q=fe&&C.process,re=function(){try{return Q&&Q.binding&&Q.binding("util")}catch{}}(),se=re&&re.isTypedArray;function ce(v,L){for(var U=-1,X=v==null?0:v.length,_e=0,pe=[];++U<X;){var Te=v[U];L(Te,U,v)&&(pe[_e++]=Te)}return pe}function Ee(v,L){for(var U=-1,X=L.length,_e=v.length;++U<X;)v[_e+U]=L[U];return v}function he(v,L){for(var U=-1,X=v==null?0:v.length;++U<X;)if(L(v[U],U,v))return!0;return!1}function Z(v,L){for(var U=-1,X=Array(v);++U<v;)X[U]=L(U);return X}function Y(v){return function(L){return v(L)}}function ie(v,L){return v.has(L)}function ue(v,L){return v==null?void 0:v[L]}function W(v){var L=-1,U=Array(v.size);return v.forEach(function(X,_e){U[++L]=[_e,X]}),U}function te(v,L){return function(U){return v(L(U))}}function ae(v){var L=-1,U=Array(v.size);return v.forEach(function(X){U[++L]=X}),U}var de=Array.prototype,we=Function.prototype,ye=Object.prototype,ve=z["__core-js_shared__"],Ne=we.toString,be=ye.hasOwnProperty,Ce=function(){var v=/[^.]+$/.exec(ve&&ve.keys&&ve.keys.IE_PROTO||"");return v?"Symbol(src)_1."+v:""}(),vt=ye.toString,ne=RegExp("^"+Ne.call(be).replace(j,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ge=fe?z.Buffer:void 0,Oe=z.Symbol,Pe=z.Uint8Array,Le=ye.propertyIsEnumerable,Fe=de.splice,Ve=Oe?Oe.toStringTag:void 0,tt=Object.getOwnPropertySymbols,Bt=ge?ge.isBuffer:void 0,bt=te(Object.keys,Object),Ft=ft(z,"DataView"),_t=ft(z,"Map"),Ut=ft(z,"Promise"),$t=ft(z,"Set"),Ht=ft(z,"WeakMap"),pt=ft(Object,"create"),an=Ke(Ft),st=Ke(_t),Ln=Ke(Ut),Rn=Ke($t),Cn=Ke(Ht),ln=Oe?Oe.prototype:void 0,zt=ln?ln.valueOf:void 0;function Ie(v){var L=-1,U=v==null?0:v.length;for(this.clear();++L<U;){var X=v[L];this.set(X[0],X[1])}}function Mn(){this.__data__=pt?pt(null):{},this.size=0}function In(v){var L=this.has(v)&&delete this.__data__[v];return this.size-=L?1:0,L}function jn(v){var L=this.__data__;if(pt){var U=L[v];return U===s?void 0:U}return be.call(L,v)?L[v]:void 0}function Dn(v){var L=this.__data__;return pt?L[v]!==void 0:be.call(L,v)}function Bn(v,L){var U=this.__data__;return this.size+=this.has(v)?0:1,U[v]=pt&&L===void 0?s:L,this}Ie.prototype.clear=Mn,Ie.prototype.delete=In,Ie.prototype.get=jn,Ie.prototype.has=Dn,Ie.prototype.set=Bn;function Ue(v){var L=-1,U=v==null?0:v.length;for(this.clear();++L<U;){var X=v[L];this.set(X[0],X[1])}}function Fn(){this.__data__=[],this.size=0}function Un(v){var L=this.__data__,U=Pt(L,v);if(U<0)return!1;var X=L.length-1;return U==X?L.pop():Fe.call(L,U,1),--this.size,!0}function $n(v){var L=this.__data__,U=Pt(L,v);return U<0?void 0:L[U][1]}function Hn(v){return Pt(this.__data__,v)>-1}function zn(v,L){var U=this.__data__,X=Pt(U,v);return X<0?(++this.size,U.push([v,L])):U[X][1]=L,this}Ue.prototype.clear=Fn,Ue.prototype.delete=Un,Ue.prototype.get=$n,Ue.prototype.has=Hn,Ue.prototype.set=zn;function We(v){var L=-1,U=v==null?0:v.length;for(this.clear();++L<U;){var X=v[L];this.set(X[0],X[1])}}function Vn(){this.size=0,this.__data__={hash:new Ie,map:new(_t||Ue),string:new Ie}}function Kn(v){var L=Ye(this,v).delete(v);return this.size-=L?1:0,L}function Wn(v){return Ye(this,v).get(v)}function Gn(v){return Ye(this,v).has(v)}function Qn(v,L){var U=Ye(this,v),X=U.size;return U.set(v,L),this.size+=U.size==X?0:1,this}We.prototype.clear=Vn,We.prototype.delete=Kn,We.prototype.get=Wn,We.prototype.has=Gn,We.prototype.set=Qn;function xt(v){var L=-1,U=v==null?0:v.length;for(this.__data__=new We;++L<U;)this.add(v[L])}function un(v){return this.__data__.set(v,s),this}function Nt(v){return this.__data__.has(v)}xt.prototype.add=xt.prototype.push=un,xt.prototype.has=Nt;function nt(v){var L=this.__data__=new Ue(v);this.size=L.size}function Vt(){this.__data__=new Ue,this.size=0}function Zn(v){var L=this.__data__,U=L.delete(v);return this.size=L.size,U}function Yn(v){return this.__data__.get(v)}function Xn(v){return this.__data__.has(v)}function Jn(v,L){var U=this.__data__;if(U instanceof Ue){var X=U.__data__;if(!_t||X.length<p-1)return X.push([v,L]),this.size=++U.size,this;U=this.__data__=new We(X)}return U.set(v,L),this.size=U.size,this}nt.prototype.clear=Vt,nt.prototype.delete=Zn,nt.prototype.get=Yn,nt.prototype.has=Xn,nt.prototype.set=Jn;function er(v,L){var U=qt(v),X=!U&&hn(v),_e=!U&&!X&&Lt(v),pe=!U&&!X&&!_e&&gn(v),Te=U||X||_e||pe,Se=Te?Z(v.length,String):[],Re=Se.length;for(var xe in v)(L||be.call(v,xe))&&!(Te&&(xe=="length"||_e&&(xe=="offset"||xe=="parent")||pe&&(xe=="buffer"||xe=="byteLength"||xe=="byteOffset")||ur(xe,Re)))&&Se.push(xe);return Se}function Pt(v,L){for(var U=v.length;U--;)if(dn(v[U][0],L))return U;return-1}function Kt(v,L,U){var X=L(v);return qt(v)?X:Ee(X,U(v))}function Ot(v){return v==null?v===void 0?M:a:Ve&&Ve in Object(v)?ct(v):cn(v)}function sn(v){return it(v)&&Ot(v)==w}function fn(v,L,U,X,_e){return v===L?!0:v==null||L==null||!it(v)&&!it(L)?v!==v&&L!==L:tr(v,L,U,X,fn,_e)}function tr(v,L,U,X,_e,pe){var Te=qt(v),Se=qt(L),Re=Te?y:rt(v),xe=Se?y:rt(L);Re=Re==w?o:Re,xe=xe==w?o:xe;var $e=Re==o,Ge=xe==o,Me=Re==xe;if(Me&&Lt(v)){if(!Lt(L))return!1;Te=!0,$e=!1}if(Me&&!$e)return pe||(pe=new nt),Te||gn(v)?Wt(v,L,U,X,_e,pe):or(v,L,Re,U,X,_e,pe);if(!(U&t)){var He=$e&&be.call(v,"__wrapped__"),je=Ge&&be.call(L,"__wrapped__");if(He||je){var gt=He?v.value():v,dt=je?L.value():L;return pe||(pe=new nt),_e(gt,dt,U,X,pe)}}return Me?(pe||(pe=new nt),ar(v,L,U,X,_e,pe)):!1}function nr(v){if(!pn(v)||fr(v))return!1;var L=vn(v)?ne:P;return L.test(Ke(v))}function rr(v){return it(v)&&Qt(v.length)&&!!F[Ot(v)]}function ir(v){if(!cr(v))return bt(v);var L=[];for(var U in Object(v))be.call(v,U)&&U!="constructor"&&L.push(U);return L}function Wt(v,L,U,X,_e,pe){var Te=U&t,Se=v.length,Re=L.length;if(Se!=Re&&!(Te&&Re>Se))return!1;var xe=pe.get(v);if(xe&&pe.get(L))return xe==L;var $e=-1,Ge=!0,Me=U&m?new xt:void 0;for(pe.set(v,L),pe.set(L,v);++$e<Se;){var He=v[$e],je=L[$e];if(X)var gt=Te?X(je,He,$e,L,v,pe):X(He,je,$e,v,L,pe);if(gt!==void 0){if(gt)continue;Ge=!1;break}if(Me){if(!he(L,function(dt,Et){if(!ie(Me,Et)&&(He===dt||_e(He,dt,U,X,pe)))return Me.push(Et)})){Ge=!1;break}}else if(!(He===je||_e(He,je,U,X,pe))){Ge=!1;break}}return pe.delete(v),pe.delete(L),Ge}function or(v,L,U,X,_e,pe,Te){switch(U){case E:if(v.byteLength!=L.byteLength||v.byteOffset!=L.byteOffset)return!1;v=v.buffer,L=L.buffer;case b:return!(v.byteLength!=L.byteLength||!pe(new Pe(v),new Pe(L)));case h:case l:case c:return dn(+v,+L);case e:return v.name==L.name&&v.message==L.message;case g:case k:return v==L+"";case f:var Se=W;case S:var Re=X&t;if(Se||(Se=ae),v.size!=L.size&&!Re)return!1;var xe=Te.get(v);if(xe)return xe==L;X|=m,Te.set(v,L);var $e=Wt(Se(v),Se(L),X,_e,pe,Te);return Te.delete(v),$e;case A:if(zt)return zt.call(v)==zt.call(L)}return!1}function ar(v,L,U,X,_e,pe){var Te=U&t,Se=wt(v),Re=Se.length,xe=wt(L),$e=xe.length;if(Re!=$e&&!Te)return!1;for(var Ge=Re;Ge--;){var Me=Se[Ge];if(!(Te?Me in L:be.call(L,Me)))return!1}var He=pe.get(v);if(He&&pe.get(L))return He==L;var je=!0;pe.set(v,L),pe.set(L,v);for(var gt=Te;++Ge<Re;){Me=Se[Ge];var dt=v[Me],Et=L[Me];if(X)var Hr=Te?X(Et,dt,Me,L,v,pe):X(dt,Et,Me,v,L,pe);if(!(Hr===void 0?dt===Et||_e(dt,Et,U,X,pe):Hr)){je=!1;break}gt||(gt=Me=="constructor")}if(je&&!gt){var yn=v.constructor,mn=L.constructor;yn!=mn&&"constructor"in v&&"constructor"in L&&!(typeof yn=="function"&&yn instanceof yn&&typeof mn=="function"&&mn instanceof mn)&&(je=!1)}return pe.delete(v),pe.delete(L),je}function wt(v){return Kt(v,Zt,lr)}function Ye(v,L){var U=v.__data__;return sr(L)?U[typeof L=="string"?"string":"hash"]:U.map}function ft(v,L){var U=ue(v,L);return nr(U)?U:void 0}function ct(v){var L=be.call(v,Ve),U=v[Ve];try{v[Ve]=void 0;var X=!0}catch{}var _e=vt.call(v);return X&&(L?v[Ve]=U:delete v[Ve]),_e}var lr=tt?function(v){return v==null?[]:(v=Object(v),ce(tt(v),function(L){return Le.call(v,L)}))}:hr,rt=Ot;(Ft&&rt(new Ft(new ArrayBuffer(1)))!=E||_t&&rt(new _t)!=f||Ut&&rt(Ut.resolve())!=d||$t&&rt(new $t)!=S||Ht&&rt(new Ht)!=T)&&(rt=function(v){var L=Ot(v),U=L==o?v.constructor:void 0,X=U?Ke(U):"";if(X)switch(X){case an:return E;case st:return f;case Ln:return d;case Rn:return S;case Cn:return T}return L});function ur(v,L){return L=L==null?O:L,!!L&&(typeof v=="number"||B.test(v))&&v>-1&&v%1==0&&v<L}function sr(v){var L=typeof v;return L=="string"||L=="number"||L=="symbol"||L=="boolean"?v!=="__proto__":v===null}function fr(v){return!!Ce&&Ce in v}function cr(v){var L=v&&v.constructor,U=typeof L=="function"&&L.prototype||ye;return v===U}function cn(v){return vt.call(v)}function Ke(v){if(v!=null){try{return Ne.call(v)}catch{}try{return v+""}catch{}}return""}function dn(v,L){return v===L||v!==v&&L!==L}var hn=sn(function(){return arguments}())?sn:function(v){return it(v)&&be.call(v,"callee")&&!Le.call(v,"callee")},qt=Array.isArray;function Gt(v){return v!=null&&Qt(v.length)&&!vn(v)}var Lt=Bt||vr;function dr(v,L){return fn(v,L)}function vn(v){if(!pn(v))return!1;var L=Ot(v);return L==n||L==u||L==_||L==r}function Qt(v){return typeof v=="number"&&v>-1&&v%1==0&&v<=O}function pn(v){var L=typeof v;return v!=null&&(L=="object"||L=="function")}function it(v){return v!=null&&typeof v=="object"}var gn=se?Y(se):rr;function Zt(v){return Gt(v)?er(v):ir(v)}function hr(){return[]}function vr(){return!1}i.exports=dr})(An,An.exports);var Fr={},qi=Be&&Be.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Fr,"__esModule",{value:!0});var Yo=qi(Tn.exports),Xo=qi(An.exports),xr;(function(i){function R(m,O,w){m===void 0&&(m={}),O===void 0&&(O={}),typeof m!="object"&&(m={}),typeof O!="object"&&(O={});var y=Yo.default(O);w||(y=Object.keys(y).reduce(function(h,l){return y[l]!=null&&(h[l]=y[l]),h},{}));for(var _ in m)m[_]!==void 0&&O[_]===void 0&&(y[_]=m[_]);return Object.keys(y).length>0?y:void 0}i.compose=R;function p(m,O){m===void 0&&(m={}),O===void 0&&(O={}),typeof m!="object"&&(m={}),typeof O!="object"&&(O={});var w=Object.keys(m).concat(Object.keys(O)).reduce(function(y,_){return Xo.default(m[_],O[_])||(y[_]=O[_]===void 0?null:O[_]),y},{});return Object.keys(w).length>0?w:void 0}i.diff=p;function s(m,O){m===void 0&&(m={}),O===void 0&&(O={}),m=m||{};var w=Object.keys(O).reduce(function(y,_){return O[_]!==m[_]&&m[_]!==void 0&&(y[_]=O[_]),y},{});return Object.keys(m).reduce(function(y,_){return m[_]!==O[_]&&O[_]===void 0&&(y[_]=null),y},w)}i.invert=s;function t(m,O,w){if(w===void 0&&(w=!1),typeof m!="object")return O;if(typeof O=="object"){if(!w)return O;var y=Object.keys(O).reduce(function(_,h){return m[h]===void 0&&(_[h]=O[h]),_},{});return Object.keys(y).length>0?y:void 0}}i.transform=t})(xr||(xr={}));Fr.default=xr;var qn={},Ur={},Jo=Be&&Be.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(Ur,"__esModule",{value:!0});var ai=Jo(qn),ea=function(){function i(R){this.ops=R,this.index=0,this.offset=0}return i.prototype.hasNext=function(){return this.peekLength()<1/0},i.prototype.next=function(R){R||(R=1/0);var p=this.ops[this.index];if(p){var s=this.offset,t=ai.default.length(p);if(R>=t-s?(R=t-s,this.index+=1,this.offset=0):this.offset+=R,typeof p.delete=="number")return{delete:R};var m={};return p.attributes&&(m.attributes=p.attributes),typeof p.retain=="number"?m.retain=R:typeof p.insert=="string"?m.insert=p.insert.substr(s,R):m.insert=p.insert,m}else return{retain:1/0}},i.prototype.peek=function(){return this.ops[this.index]},i.prototype.peekLength=function(){return this.ops[this.index]?ai.default.length(this.ops[this.index])-this.offset:1/0},i.prototype.peekType=function(){return this.ops[this.index]?typeof this.ops[this.index].delete=="number"?"delete":typeof this.ops[this.index].retain=="number"?"retain":"insert":"retain"},i.prototype.rest=function(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);var R=this.offset,p=this.index,s=this.next(),t=this.ops.slice(this.index);return this.offset=R,this.index=p,[s].concat(t)}else return[]},i}();Ur.default=ea;var ta=Be&&Be.__importDefault||function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(qn,"__esModule",{value:!0});var na=ta(Ur),Nr;(function(i){function R(s){return new na.default(s)}i.iterator=R;function p(s){return typeof s.delete=="number"?s.delete:typeof s.retain=="number"?s.retain:typeof s.insert=="string"?s.insert.length:1}i.length=p})(Nr||(Nr={}));qn.default=Nr;var on=Be&&Be.__importDefault||function(i){return i&&i.__esModule?i:{default:i}},En=on(Zo),ra=on(Tn.exports),kr=on(An.exports),Jt=on(Fr),De=on(qn),ia=String.fromCharCode(0),oa=function(){function i(R){Array.isArray(R)?this.ops=R:R!=null&&Array.isArray(R.ops)?this.ops=R.ops:this.ops=[]}return i.prototype.insert=function(R,p){var s={};return typeof R=="string"&&R.length===0?this:(s.insert=R,p!=null&&typeof p=="object"&&Object.keys(p).length>0&&(s.attributes=p),this.push(s))},i.prototype.delete=function(R){return R<=0?this:this.push({delete:R})},i.prototype.retain=function(R,p){if(R<=0)return this;var s={retain:R};return p!=null&&typeof p=="object"&&Object.keys(p).length>0&&(s.attributes=p),this.push(s)},i.prototype.push=function(R){var p=this.ops.length,s=this.ops[p-1];if(R=ra.default(R),typeof s=="object"){if(typeof R.delete=="number"&&typeof s.delete=="number")return this.ops[p-1]={delete:s.delete+R.delete},this;if(typeof s.delete=="number"&&R.insert!=null&&(p-=1,s=this.ops[p-1],typeof s!="object"))return this.ops.unshift(R),this;if(kr.default(R.attributes,s.attributes)){if(typeof R.insert=="string"&&typeof s.insert=="string")return this.ops[p-1]={insert:s.insert+R.insert},typeof R.attributes=="object"&&(this.ops[p-1].attributes=R.attributes),this;if(typeof R.retain=="number"&&typeof s.retain=="number")return this.ops[p-1]={retain:s.retain+R.retain},typeof R.attributes=="object"&&(this.ops[p-1].attributes=R.attributes),this}}return p===this.ops.length?this.ops.push(R):this.ops.splice(p,0,R),this},i.prototype.chop=function(){var R=this.ops[this.ops.length-1];return R&&R.retain&&!R.attributes&&this.ops.pop(),this},i.prototype.filter=function(R){return this.ops.filter(R)},i.prototype.forEach=function(R){this.ops.forEach(R)},i.prototype.map=function(R){return this.ops.map(R)},i.prototype.partition=function(R){var p=[],s=[];return this.forEach(function(t){var m=R(t)?p:s;m.push(t)}),[p,s]},i.prototype.reduce=function(R,p){return this.ops.reduce(R,p)},i.prototype.changeLength=function(){return this.reduce(function(R,p){return p.insert?R+De.default.length(p):p.delete?R-p.delete:R},0)},i.prototype.length=function(){return this.reduce(function(R,p){return R+De.default.length(p)},0)},i.prototype.slice=function(R,p){R===void 0&&(R=0),p===void 0&&(p=1/0);for(var s=[],t=De.default.iterator(this.ops),m=0;m<p&&t.hasNext();){var O=void 0;m<R?O=t.next(R-m):(O=t.next(p-m),s.push(O)),m+=De.default.length(O)}return new i(s)},i.prototype.compose=function(R){var p=De.default.iterator(this.ops),s=De.default.iterator(R.ops),t=[],m=s.peek();if(m!=null&&typeof m.retain=="number"&&m.attributes==null){for(var O=m.retain;p.peekType()==="insert"&&p.peekLength()<=O;)O-=p.peekLength(),t.push(p.next());m.retain-O>0&&s.next(m.retain-O)}for(var w=new i(t);p.hasNext()||s.hasNext();)if(s.peekType()==="insert")w.push(s.next());else if(p.peekType()==="delete")w.push(p.next());else{var y=Math.min(p.peekLength(),s.peekLength()),_=p.next(y),h=s.next(y);if(typeof h.retain=="number"){var l={};typeof _.retain=="number"?l.retain=y:l.insert=_.insert;var e=Jt.default.compose(_.attributes,h.attributes,typeof _.retain=="number");if(e&&(l.attributes=e),w.push(l),!s.hasNext()&&kr.default(w.ops[w.ops.length-1],l)){var n=new i(p.rest());return w.concat(n).chop()}}else typeof h.delete=="number"&&typeof _.retain=="number"&&w.push(h)}return w.chop()},i.prototype.concat=function(R){var p=new i(this.ops.slice());return R.ops.length>0&&(p.push(R.ops[0]),p.ops=p.ops.concat(R.ops.slice(1))),p},i.prototype.diff=function(R,p){if(this.ops===R.ops)return new i;var s=[this,R].map(function(y){return y.map(function(_){if(_.insert!=null)return typeof _.insert=="string"?_.insert:ia;var h=y===R?"on":"with";throw new Error("diff() called "+h+" non-document")}).join("")}),t=new i,m=En.default(s[0],s[1],p),O=De.default.iterator(this.ops),w=De.default.iterator(R.ops);return m.forEach(function(y){for(var _=y[1].length;_>0;){var h=0;switch(y[0]){case En.default.INSERT:h=Math.min(w.peekLength(),_),t.push(w.next(h));break;case En.default.DELETE:h=Math.min(_,O.peekLength()),O.next(h),t.delete(h);break;case En.default.EQUAL:h=Math.min(O.peekLength(),w.peekLength(),_);var l=O.next(h),e=w.next(h);kr.default(l.insert,e.insert)?t.retain(h,Jt.default.diff(l.attributes,e.attributes)):t.push(e).delete(h);break}_-=h}}),t.chop()},i.prototype.eachLine=function(R,p){p===void 0&&(p=`
`);for(var s=De.default.iterator(this.ops),t=new i,m=0;s.hasNext();){if(s.peekType()!=="insert")return;var O=s.peek(),w=De.default.length(O)-s.peekLength(),y=typeof O.insert=="string"?O.insert.indexOf(p,w)-w:-1;if(y<0)t.push(s.next());else if(y>0)t.push(s.next(y));else{if(R(t,s.next(1).attributes||{},m)===!1)return;m+=1,t=new i}}t.length()>0&&R(t,{},m)},i.prototype.invert=function(R){var p=new i;return this.reduce(function(s,t){if(t.insert)p.delete(De.default.length(t));else{if(t.retain&&t.attributes==null)return p.retain(t.retain),s+t.retain;if(t.delete||t.retain&&t.attributes){var m=t.delete||t.retain,O=R.slice(s,s+m);return O.forEach(function(w){t.delete?p.push(w):t.retain&&t.attributes&&p.retain(De.default.length(w),Jt.default.invert(t.attributes,w.attributes))}),s+m}}return s},0),p.chop()},i.prototype.transform=function(R,p){if(p===void 0&&(p=!1),p=!!p,typeof R=="number")return this.transformPosition(R,p);for(var s=R,t=De.default.iterator(this.ops),m=De.default.iterator(s.ops),O=new i;t.hasNext()||m.hasNext();)if(t.peekType()==="insert"&&(p||m.peekType()!=="insert"))O.retain(De.default.length(t.next()));else if(m.peekType()==="insert")O.push(m.next());else{var w=Math.min(t.peekLength(),m.peekLength()),y=t.next(w),_=m.next(w);if(y.delete)continue;_.delete?O.push(_):O.retain(w,Jt.default.transform(y.attributes,_.attributes,p))}return O.chop()},i.prototype.transformPosition=function(R,p){p===void 0&&(p=!1),p=!!p;for(var s=De.default.iterator(this.ops),t=0;s.hasNext()&&t<=R;){var m=s.peekLength(),O=s.peekType();if(s.next(),O==="delete"){R-=Math.min(m,R-t);continue}else O==="insert"&&(t<R||!p)&&(R+=m);t+=m}return R},i.Op=De.default,i.AttributeMap=Jt.default,i}(),Li=oa;/*!
 * VueQuill @vueup/vue-quill v1.2.0
 * https://vueup.github.io/vue-quill/
 * 
 * Includes quill v1.3.7
 * https://quilljs.com/
 * 
 * Copyright (c) 2023 Ahmad Luthfi Masruri
 * Released under the MIT license
 * Date: 2023-05-12T08:44:03.742Z
 */const li={essential:[[{header:[1,2,3,4,5,6,!1]}],["bold","italic","underline"],[{list:"ordered"},{list:"bullet"},{align:[]}],["blockquote","code-block","link"],[{color:[]},"clean"]],minimal:[[{header:1},{header:2}],["bold","italic","underline"],[{list:"ordered"},{list:"bullet"},{align:[]}]],full:[["bold","italic","underline","strike"],["blockquote","code-block"],[{header:1},{header:2}],[{list:"ordered"},{list:"bullet"}],[{script:"sub"},{script:"super"}],[{indent:"-1"},{indent:"+1"}],[{direction:"rtl"}],[{size:["small",!1,"large","huge"]}],[{header:[1,2,3,4,5,6,!1]}],[{color:[]},{background:[]}],[{font:[]}],[{align:[]}],["link","video","image"],["clean"]]},aa=Vi({name:"QuillEditor",inheritAttrs:!1,props:{content:{type:[String,Object]},contentType:{type:String,default:"delta",validator:i=>["delta","html","text"].includes(i)},enable:{type:Boolean,default:!0},readOnly:{type:Boolean,default:!1},placeholder:{type:String,required:!1},theme:{type:String,default:"snow",validator:i=>["snow","bubble",""].includes(i)},toolbar:{type:[String,Array,Object],required:!1,validator:i=>typeof i=="string"&&i!==""?i.charAt(0)==="#"?!0:Object.keys(li).indexOf(i)!==-1:!0},modules:{type:Object,required:!1},options:{type:Object,required:!1},globalOptions:{type:Object,required:!1}},emits:["textChange","selectionChange","editorChange","update:content","focus","blur","ready"],setup:(i,R)=>{rn(()=>{m()}),Sn(()=>{p=null});let p,s;const t=ke(),m=()=>{var b;if(!!t.value){if(s=O(),i.modules)if(Array.isArray(i.modules))for(const E of i.modules)St.register(`modules/${E.name}`,E.module);else St.register(`modules/${i.modules.name}`,i.modules.module);p=new St(t.value,s),d(i.content),p.on("text-change",l),p.on("selection-change",n),p.on("editor-change",u),i.theme!=="bubble"&&t.value.classList.remove("ql-bubble"),i.theme!=="snow"&&t.value.classList.remove("ql-snow"),(b=p.getModule("toolbar"))===null||b===void 0||b.container.addEventListener("mousedown",E=>{E.preventDefault()}),R.emit("ready",p)}},O=()=>{const b={};if(i.theme!==""&&(b.theme=i.theme),i.readOnly&&(b.readOnly=i.readOnly),i.placeholder&&(b.placeholder=i.placeholder),i.toolbar&&i.toolbar!==""&&(b.modules={toolbar:(()=>{if(typeof i.toolbar=="object")return i.toolbar;if(typeof i.toolbar=="string")return i.toolbar.charAt(0)==="#"?i.toolbar:li[i.toolbar]})()}),i.modules){const E=(()=>{var x,q;const I={};if(Array.isArray(i.modules))for(const H of i.modules)I[H.name]=(x=H.options)!==null&&x!==void 0?x:{};else I[i.modules.name]=(q=i.modules.options)!==null&&q!==void 0?q:{};return I})();b.modules=Object.assign({},b.modules,E)}return Object.assign({},i.globalOptions,i.options,b)},w=b=>typeof b=="object"&&b?b.slice():b,y=b=>Object.values(b.ops).some(E=>!E.retain||Object.keys(E).length!==1);let _;const h=b=>{if(typeof _==typeof b){if(b===_)return!0;if(typeof b=="object"&&b&&typeof _=="object"&&_)return!y(_.diff(b))}return!1},l=(b,E,x)=>{_=w(o()),h(i.content)||R.emit("update:content",_),R.emit("textChange",{delta:b,oldContents:E,source:x})},e=ke(),n=(b,E,x)=>{e.value=!!(p!=null&&p.hasFocus()),R.emit("selectionChange",{range:b,oldRange:E,source:x})};ze(e,b=>{b?R.emit("focus",t):R.emit("blur",t)});const u=(...b)=>{b[0]==="text-change"&&R.emit("editorChange",{name:b[0],delta:b[1],oldContents:b[2],source:b[3]}),b[0]==="selection-change"&&R.emit("editorChange",{name:b[0],range:b[1],oldRange:b[2],source:b[3]})},f=()=>t.value,c=()=>{var b;return(b=p==null?void 0:p.getModule("toolbar"))===null||b===void 0?void 0:b.container},a=()=>{if(p)return p;throw`The quill editor hasn't been instantiated yet,
                  make sure to call this method when the editor ready
                  or use v-on:ready="onReady(quill)" event instead.`},o=(b,E)=>i.contentType==="html"?S():i.contentType==="text"?r(b,E):p==null?void 0:p.getContents(b,E),d=(b,E="api")=>{const x=b||(i.contentType==="delta"?new Li:"");i.contentType==="html"?k(x):i.contentType==="text"?g(x,E):p==null||p.setContents(x,E),_=w(x)},r=(b,E)=>{var x;return(x=p==null?void 0:p.getText(b,E))!==null&&x!==void 0?x:""},g=(b,E="api")=>{p==null||p.setText(b,E)},S=()=>{var b;return(b=p==null?void 0:p.root.innerHTML)!==null&&b!==void 0?b:""},k=b=>{p&&(p.root.innerHTML=b)},A=(b,E="api")=>{const x=p==null?void 0:p.clipboard.convert(b);x&&(p==null||p.setContents(x,E))},M=()=>{p==null||p.focus()},T=()=>{tn(()=>{var b;!R.slots.toolbar&&p&&((b=p.getModule("toolbar"))===null||b===void 0||b.container.remove()),m()})};return ze(()=>i.content,b=>{if(!p||!b||h(b))return;const E=p.getSelection();E&&tn(()=>p==null?void 0:p.setSelection(E)),d(b)},{deep:!0}),ze(()=>i.enable,b=>{p&&p.enable(b)}),{editor:t,getEditor:f,getToolbar:c,getQuill:a,getContents:o,setContents:d,getHTML:S,setHTML:k,pasteHTML:A,focus:M,getText:r,setText:g,reinit:T}},render(){var i,R;return[(R=(i=this.$slots).toolbar)===null||R===void 0?void 0:R.call(i),le("div",{ref:"editor",...this.$attrs})]}});const kn=qr();function Ri(){return _n.is.mac||_n.is.ios?kn.richTextTypes.supportedMacFonts:_n.is.win?kn.richTextTypes.supportedWinFonts:_n.is.linux?kn.richTextTypes.supportedLinuxFonts:kn.richTextTypes.supportedCommonFonts}function la(i){let R=i.indexOf("<font");for(;R!==-1;){let s=i.indexOf(">",R+5),t="",m="",O=i.indexOf("face=",R+5);O!==-1&&O<s&&(t=ui(i,O+5,s),t!==""&&($r(t)||(t=ua(t))));let w=i.indexOf("color=",R+5);w!==-1&&w<s&&(m=ui(i,w+6,s)),i.indexOf("size=",R+5);let y='<span style="';t!==""&&(y=y+"font-family:"+t.toLowerCase()+'";'),m!==""&&(y=y+" color:"+m+";"),y=y+">",i=i.substring(0,R)+y+i.substr(s+1,i.length-(s+1)),R=R+y.length,R=i.indexOf("<font")}let p=sa("</font");return i=i.replace(p,"</span"),i}function $r(i){return Ri().includes(i.toLowerCase())}function ua(i){return $r(i)?i:serifFonts.includes(i.toLowerCase())?serifFonts[0]:sansSerifFonts.includes(i.toLowerCase())?sansSerifFonts[0]:monospaceFonts.includes(i.toLowerCase())?monospaceFonts[0]:scriptFonts.includes(i.toLowerCase())?scriptFonts[0]:"arial"}function ui(i,R,p){let s=R,t=-1,m=-1;for(;s<=p&&m==-1;)(i[s]==="'"||i[s]==='"')&&(t===-1?t=s:m=s),s=s+1;if(t!==-1&&m!==-1){let O=m-(t+1);return i.substr(t+1,O)}return""}function sa(i){return i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}const Mt=17,fa={__name:"RichTextEditor",props:{height:{type:Number,required:!0},width:{type:Number,required:!0},recordID:String},emits:["finish-edit"],setup(i,{emit:R}){const p=ke(null),s=di(),t=qr();Lr(),Rr();const m=i,O=R,w=P=>{O("finish-edit",P)};Pr("editorData");const y=zr({content:"<p> Test </p>",contentType:"html",changed:!1,loading:!1,saveTimeout:null}),_=()=>{l("ql-toolbar");const P=29;let B=m.height-P;return"overflow: auto; height:"+B+"px; max-height:"+B+"px;"};ze(()=>m.recordID,P=>{console.log("Watch props.recordID function called with args:",P),h()});const h=()=>{s.bodyContent(m.recordID).then(P=>{const B=e();y.loading=!0,B.setContents([]);let F=la(P);B.clipboard.dangerouslyPasteHTML(0,F),y.loading=!1}).catch(P=>{console.log(P)})},l=P=>{let B=document.getElementsByClassName(P);return B.length>0?B[0]:null};rn(()=>{h()});const e=()=>p.value.getQuill(),n=()=>{let P=St.import("attributors/style/font");P.whitelist=Ri(),St.register(P,!0);var B=St.import("attributors/style/size");B.whitelist=t.editorConfig.fontSizes,St.register(B,!0);let F=0;for(F=0;F<t.editorConfig.fontList.length;F++){let C=t.editorConfig.fontList[F];$r(C)&&t.editorConfig.supportedFontList.push(C)}},u=zr({backgroundColour:"",linkURL:"https://",editRange:null,actionRange:null,textColor:"#000000",showColor:!1}),f=P=>{const B=P.range;r(B)},c=(P,B,F)=>{y.loading||(y.changed=!0,y.saveTimeout===null&&(y.saveTimeout=setTimeout(function(){a()},1e4)))},a=()=>{y.changed&&bi(m.recordID)&&(y.saveTimeout!==null&&(clearTimeout(y.saveTimeout),y.saveTimeout=null),s.saveBodyChanges(m.recordID,y.content))},o=[{icon:"icon-icons8-decreasefont",action:"decreaseFont",tooltip:"decreaseSize"},{icon:"icon-icons8-increasefont",action:"increaseFont",tooltip:"increaseSize"},{icon:"icon-icons8-subscript",action:"sub",tooltip:"subscript"},{icon:"icon-icons8-superscript",action:"super",tooltip:"superscript"}],d=[{icon:"icon-icons8-bold",action:"bold",tooltip:"bold"},{icon:"icon-icons8-Italic",action:"italic",tooltip:"italic"},{icon:"icon-icons8-underline",action:"underline",tooltip:"underline"},{icon:"icon-icons8-strikethrough",action:"strike",tooltip:"strikethrough"}],r=P=>{let B=e();P&&B.getFormat(P)},g=P=>s.database.highlighting[P].color,S=()=>e().getSelection(),k=()=>{let P=e(),B=S();if(B){let F=P.getFormat(B);if(typeof F.size!="undefined"){let C=t.editorConfig.fontSizes.indexOf(F.size);C!==-1&&(C=C+1,C<t.editorConfig.fontSizes.length&&(F.size=t.editorConfig.fontSizes[C],P.formatText(B.index,B.length,"size",t.editorConfig.fontSizes[C])))}else P.formatText(B.index,B.length,"size","13px")}},A=()=>{let P=e(),B=S();if(B){let F=P.getFormat(B);if(typeof F.size!="undefined"){let C=t.editorConfig.fontSizes.indexOf(F.size);C!==-1&&(C=C-1,C>0&&(F.size=t.editorConfig.fontSizes[C],P.formatText(B.index,B.length,"size",t.editorConfig.fontSizes[C])))}else P.formatText(B.index,B.length,"size","11px")}},M=(P,B,F,C)=>{let $=e(),z=B==null?S():B;if(z){let J=$.getFormat(z)[P];J!=="undefined"&&J===F?$.formatText(z.index,z.length,P,C):$.formatText(z.index,z.length,P,F)}r(z)},T=(P,B)=>{let F=e();var C=null;let $=B==null?S():B;return $&&(C=F.getFormat($)[P]),C},b=P=>{P=="decreaseFont"?A():P=="increaseFont"?k():P=="sub"||P=="super"?M("script",null,P,""):(P=="bold"||P=="italic"||P=="underline"||P=="strike")&&M(P,null,!0,!1)},E=P=>{e();let B=S();B&&B.length>0?u.editRange=B:u.editRange=null},x=P=>{E();const B=t.settings.defaultHighlight;let F=s.database.highlighting[B];if(u.editRange!=null&&u.editRange.length>0){let $=S();var C=F.color;T("background",$)==F.color&&(C=""),M("background",u.editRange,C,"")}},q=P=>{let B=P==-1?{color:""}:s.database.highlighting[P];u.editRange!=null&&u.editRange.length>0&&(M("background",u.editRange,B.color,""),u.backgroundColour=B.color,P!=-1&&(t.settings.defaultHighlight=P),setTimeout(function(){e().setSelection(u.actionRange)},500))};function I(P){let B=e(),F=S();if(F&&F.length>0){u.editRange=F;let C=B.getFormat(F);typeof C.link!="undefined"?u.linkURL=C.link:u.linkURL="https://"}else u.linkURL="https://",u.editRange=null}const H=()=>{if(u.editRange&&u.editRange.length>0){let P=e();typeof P.getFormat(u.editRange).link!="undefined"&&P.formatText(u.editRange.index,u.editRange.length,"link","")}u.editRange=null};function K(P){let B=Wi(u.linkURL);return B&&ee(),B}function ee(P,B){if(u.linkURL!=="https://"||u.linkURL!==""){if(u.editRange&&u.editRange.length>0){let F=e();const C=new Li().retain(u.editRange.index).retain(u.editRange.length,{link:u.linkURL});F.updateContents(C)}}else H()}const V=()=>{let P=S();if(u.actionRange=P,P){let F=e().getFormat(P);if(typeof F.color!="undefined"){u.textColor=F.color;return}}u.textColor="#000000",u.showColor=!0},D=P=>{if(u.actionRange!==null){let B=e();B.formatText(u.actionRange.index,u.actionRange.length,"color",P),B.setSelection(u.actionRange)}},N=()=>{let P=S();P&&P.length>0&&(u.editRange=P)},j=P=>{let B=u.editRange;if(B){let F=e();F.formatText(B.index,B.length,"font",P.toLowerCase()),F.setSelection(B.index,B.length)}u.editRange=null};return(P,B)=>{const F=Vr("q-item-tile"),C=Vr("q-item-main"),$=Ki("close-overlay");return Ze(),At("div",null,[me(pi,{class:Xe(qe(Je)("toolbar-light editor-toolbar","toolbar-dark editor-toolbar"))},{default:Ae(()=>[(Ze(),At(On,null,wn(o,z=>me(lt,{key:z.action,flat:"",dense:"",onClick:G=>b(z.action)},{default:Ae(()=>[me(yt,{name:z.icon,size:"17px",class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["name","class"]),me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t(z.tooltip)),1)]),_:2},1024)]),_:2},1032,["onClick"])),64)),(Ze(),At(On,null,wn(d,z=>me(lt,{key:z.action,flat:"",dense:"",onClick:G=>b(z.action)},{default:Ae(()=>[me(yt,{name:z.icon,size:"17px",class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["name","class"]),me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t(z.tooltip)),1)]),_:2},1024)]),_:2},1032,["onClick"])),64)),me(so,{color:y.highlightIconColor,onClick:x,onBeforeShow:E,icon:"icon-icons8-highlight",size:"12px","auto-close":"",dense:"",flat:"","no-icon-animation":"",split:""},{default:Ae(()=>[me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t("highlightText")),1)]),_:1}),me(Qr,null,{default:Ae(()=>[(Ze(!0),At(On,null,wn(qe(s).database.highlighting,(z,G)=>Ar((Ze(),It(_r,{key:G,onClick:J=>q(G),clickable:"",dense:""},{default:Ae(()=>[me(Rt,{avatar:""},{default:Ae(()=>[me(qe(Yr),{color:g(G),fill:g(G)},null,8,["color","fill"])]),_:2},1024),me(Rt,null,{default:Ae(()=>[ot(at(z.description),1)]),_:2},1024),u.backgroundColour===z.color?(Ze(),It(Rt,{key:0,side:""},{default:Ae(()=>[me(qe(Zr),{size:Mt,class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"])]),_:1})):Kr("",!0)]),_:2},1032,["onClick"])),[[$]])),128)),me(fo),me(_r,{clickable:"",onClick:B[0]||(B[0]=z=>q(-1)),dense:""},{default:Ae(()=>[me(Rt,{avatar:""},{default:Ae(()=>[me(qe(Yr),{color:qe(t).iconColor},null,8,["color"])]),_:1}),me(Rt,null,{default:Ae(()=>[ot(at(P.$t("off")),1)]),_:1}),u.backgroundColour===""?(Ze(),It(Rt,{key:0,side:""},{default:Ae(()=>[me(qe(Zr),{size:Mt,class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"])]),_:1})):Kr("",!0)]),_:1})]),_:1})]),_:1},8,["color"]),me(lt,{flat:"",dense:"",onClick:P.addImage},{default:Ae(()=>[me(qe(go),{size:Mt,class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"]),me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t("addImage")),1)]),_:1})]),_:1},8,["onClick"]),me(lt,{flat:"",dense:""},{default:Ae(()=>[me(qe(yo),{size:Mt,class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"]),me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t("addImage")),1)]),_:1}),me(bo,{modelValue:u.linkURL,"onUpdate:modelValue":B[2]||(B[2]=z=>u.linkURL=z),anchor:"top left",onBeforeShow:I,validate:K,onSave:ee,"label-set":P.$t("ok"),"label-cancel":P.$t("cancel"),buttons:"",persistent:""},{default:Ae(()=>[me(vo,{modelValue:u.linkURL,"onUpdate:modelValue":B[1]||(B[1]=z=>u.linkURL=z),dense:"",autofocus:""},null,8,["modelValue"])]),_:1},8,["modelValue","label-set","label-cancel"])]),_:1}),me(lt,{flat:"",dense:"",onClick:N},{default:Ae(()=>[me(yt,{name:"icon-icons8-choosefont",size:"17px",class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"]),me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t("font")),1)]),_:1}),me(Mr,{"auto-close":""},{default:Ae(()=>[me(Qr,{dense:""},{default:Ae(()=>[(Ze(!0),At(On,null,wn(qe(t).editorConfig.supportedFontList,(z,G)=>Ar((Ze(),It(_r,{class:"DTFontList",key:G,clickable:"",onClick:J=>j(z),dense:""},{default:Ae(()=>[me(C,null,{default:Ae(()=>[me(F,{label:""},{default:Ae(()=>[ot(at(z),1)]),_:2},1024)]),_:2},1024)]),_:2},1032,["onClick"])),[[co]])),128))]),_:1})]),_:1})]),_:1}),me(lt,{flat:"",dense:"",onClick:V},{default:Ae(()=>[me(qe(mo),{size:Mt,class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"]),me(Tt,{class:"DTTooltip",delay:1e3},{default:Ae(()=>[ot(at(P.$t("textColour")),1)]),_:1}),me(zo,{"transition-show":"scale","transition-hide":"scale"},{default:Ae(()=>[me(Ho,{modelValue:u.textColor,"onUpdate:modelValue":B[3]||(B[3]=z=>u.textColor=z),class:"DTColourPicker",onChange:D},null,8,["modelValue"])]),_:1})]),_:1}),me(vi),me(lt,{flat:"",dense:"",onClick:B[4]||(B[4]=z=>w("finshedit"))},{default:Ae(()=>[me(qe(_i),{size:Mt,"stroke-width":"1.5",color:qe(t).defaultStyles.iconColorBlue},null,8,["color"])]),_:1})]),_:1},8,["class"]),me(qe(aa),{content:y.content,"onUpdate:content":B[5]||(B[5]=z=>y.content=z),"content-type":y.contentType,ref_key:"editor",ref:p,id:"DTRichTextEditorID",onReady:n,onSelectionChange:f,onTextChange:c,theme:"",style:hi(_()),toolbar:""},null,8,["content","content-type","style"])])}}};var ca=uo(fa,[["__scopeId","data-v-3c765e84"]]);const da=17,ha={__name:"RecordToolbar",props:{height:{type:Number,required:!0},width:{type:Number,required:!0},recordID:String},emits:["action-edit"],setup(i,{emit:R}){qr(),Lr(),Rr();const p=i,s=R,t=ke(!1);ze(()=>p.recordID,w=>{m()}),rn(()=>{m()});const m=()=>{t.value=!bi(p.recordID)||ho(p.recordID)},O=w=>{s("action-edit",w)};return(w,y)=>(Ze(),It(pi,{class:Xe(qe(Je)("toolbar-light editor-toolbar","toolbar-dark editor-toolbar-dark"))},{default:Ae(()=>[me(vi),me(lt,{flat:"",dense:"",onClick:y[0]||(y[0]=_=>O("edit")),disable:t.value},{default:Ae(()=>[me(qe(_i),{size:da,"stroke-width":"1.5",class:Xe(qe(Je)("toolbar-icon-light","toolbar-icon-dark"))},null,8,["class"])]),_:1},8,["disable"])]),_:1},8,["class"]))}},va={key:1},Oa={__name:"RichTextViewer",props:{height:{type:Number,required:!0},width:{type:Number,required:!0},recordID:String},setup(i){ke(null),di(),Lr(),Rr();const R=i,p=ke(100);ze(()=>R.recordID,_=>{m.value=!1}),ze(()=>R.height,_=>{s()}),rn(()=>{s()});const s=()=>{p.value=R.height-O.value},t=Pr("editorData"),m=ke(!1),O=ke(29),w=()=>{m.value=!m.value},y=()=>"overflow: auto; height:"+R.height+"px; max-height:"+R.height+"px;";return(_,h)=>(Ze(),At("div",{style:hi(y())},[m.value?(Ze(),It(ca,{key:0,width:R.width,height:R.height,recordID:qe(t).recordID,onFinishEdit:h[0]||(h[0]=l=>w())},null,8,["width","height","recordID"])):(Ze(),At("div",va,[me(ha,{onActionEdit:h[1]||(h[1]=l=>w()),width:R.width,height:O.value,recordID:qe(t).recordID},null,8,["width","height","recordID"]),me(po,{width:R.width,height:p.value,recordID:qe(t).recordID},null,8,["width","height","recordID"])]))],4))}};export{Oa as default};
