import{i as tt,a as kr}from"./isObject.095d1ac4.js";import{z as Me,R as Se,r as Kn,A as Gn,s as at,j as ge,f as Ie,q as Kr,B as mo}from"./index.4524613b.js";import"./formatNumber.e535a2a3.js";import{T as bo}from"./TextField.489cf1ea.js";var fr;try{fr=Map}catch{}var cr;try{cr=Set}catch{}function Wn(e,n,t){if(!e||typeof e!="object"||typeof e=="function")return e;if(e.nodeType&&"cloneNode"in e)return e.cloneNode(!0);if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);if(Array.isArray(e))return e.map(dr);if(fr&&e instanceof fr)return new Map(Array.from(e.entries()));if(cr&&e instanceof cr)return new Set(Array.from(e.values()));if(e instanceof Object){n.push(e);var r=Object.create(e);t.push(r);for(var i in e){var f=n.findIndex(function(h){return h===e[i]});r[i]=f>-1?t[f]:Wn(e[i],n,t)}return r}return e}function dr(e){return Wn(e,[],[])}const _o=Object.prototype.toString,Oo=Error.prototype.toString,wo=RegExp.prototype.toString,Eo=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",xo=/^Symbol\((.*)\)(.*)$/;function Ao(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function Gr(e,n=!1){if(e==null||e===!0||e===!1)return""+e;const t=typeof e;if(t==="number")return Ao(e);if(t==="string")return n?`"${e}"`:e;if(t==="function")return"[Function "+(e.name||"anonymous")+"]";if(t==="symbol")return Eo.call(e).replace(xo,"Symbol($1)");const r=_o.call(e).slice(8,-1);return r==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):r==="Error"||e instanceof Error?"["+Oo.call(e)+"]":r==="RegExp"?wo.call(e):null}function Et(e,n){let t=Gr(e,n);return t!==null?t:JSON.stringify(e,function(r,i){let f=Gr(this[r],n);return f!==null?f:i},2)}let nt={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:n,value:t,originalValue:r})=>{let i=r!=null&&r!==t,f=`${e} must be a \`${n}\` type, but the final value was: \`${Et(t,!0)}\``+(i?` (cast from the value \`${Et(r,!0)}\`).`:".");return t===null&&(f+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),f},defined:"${path} must be defined"},He={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},To={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},hr={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},ko={isValue:"${path} field must be ${value}"},pr={noUnknown:"${path} field has unspecified keys: ${unknown}"},So={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"};Object.assign(Object.create(null),{mixed:nt,string:He,number:To,date:hr,object:pr,array:So,boolean:ko});var qo=Object.prototype,No=qo.hasOwnProperty;function Po(e,n){return e!=null&&No.call(e,n)}var Lo=Po,Ro=typeof Me=="object"&&Me&&Me.Object===Object&&Me,Zn=Ro,Fo=Zn,Do=typeof self=="object"&&self&&self.Object===Object&&self,jo=Fo||Do||Function("return this")(),Qe=jo,Io=Qe,$o=Io.Symbol,Gt=$o,Wr=Gt,Yn=Object.prototype,Co=Yn.hasOwnProperty,Mo=Yn.toString,_t=Wr?Wr.toStringTag:void 0;function Bo(e){var n=Co.call(e,_t),t=e[_t];try{e[_t]=void 0;var r=!0}catch{}var i=Mo.call(e);return r&&(n?e[_t]=t:delete e[_t]),i}var Uo=Bo,Vo=Object.prototype,Ho=Vo.toString;function zo(e){return Ho.call(e)}var Ko=zo,Zr=Gt,Go=Uo,Wo=Ko,Zo="[object Null]",Yo="[object Undefined]",Yr=Zr?Zr.toStringTag:void 0;function Xo(e){return e==null?e===void 0?Yo:Zo:Yr&&Yr in Object(e)?Go(e):Wo(e)}var xt=Xo;function Qo(e){return e!=null&&typeof e=="object"}var At=Qo,Jo=xt,ea=At,ta="[object Symbol]";function ra(e){return typeof e=="symbol"||ea(e)&&Jo(e)==ta}var Sr=ra,na=tt,ia=Sr,oa=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,aa=/^\w*$/;function la(e,n){if(na(e))return!1;var t=typeof e;return t=="number"||t=="symbol"||t=="boolean"||e==null||ia(e)?!0:aa.test(e)||!oa.test(e)||n!=null&&e in Object(n)}var qr=la,sa=xt,ua=kr,fa="[object AsyncFunction]",ca="[object Function]",da="[object GeneratorFunction]",ha="[object Proxy]";function pa(e){if(!ua(e))return!1;var n=sa(e);return n==ca||n==da||n==fa||n==ha}var Xn=pa,va=Qe,ya=va["__core-js_shared__"],ga=ya,rr=ga,Xr=function(){var e=/[^.]+$/.exec(rr&&rr.keys&&rr.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function ma(e){return!!Xr&&Xr in e}var ba=ma,_a=Function.prototype,Oa=_a.toString;function wa(e){if(e!=null){try{return Oa.call(e)}catch{}try{return e+""}catch{}}return""}var Qn=wa,Ea=Xn,xa=ba,Aa=kr,Ta=Qn,ka=/[\\^$.*+?()[\]{}|]/g,Sa=/^\[object .+?Constructor\]$/,qa=Function.prototype,Na=Object.prototype,Pa=qa.toString,La=Na.hasOwnProperty,Ra=RegExp("^"+Pa.call(La).replace(ka,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Fa(e){if(!Aa(e)||xa(e))return!1;var n=Ea(e)?Ra:Sa;return n.test(Ta(e))}var Da=Fa;function ja(e,n){return e==null?void 0:e[n]}var Ia=ja,$a=Da,Ca=Ia;function Ma(e,n){var t=Ca(e,n);return $a(t)?t:void 0}var lt=Ma,Ba=lt,Ua=Ba(Object,"create"),Wt=Ua,Qr=Wt;function Va(){this.__data__=Qr?Qr(null):{},this.size=0}var Ha=Va;function za(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}var Ka=za,Ga=Wt,Wa="__lodash_hash_undefined__",Za=Object.prototype,Ya=Za.hasOwnProperty;function Xa(e){var n=this.__data__;if(Ga){var t=n[e];return t===Wa?void 0:t}return Ya.call(n,e)?n[e]:void 0}var Qa=Xa,Ja=Wt,el=Object.prototype,tl=el.hasOwnProperty;function rl(e){var n=this.__data__;return Ja?n[e]!==void 0:tl.call(n,e)}var nl=rl,il=Wt,ol="__lodash_hash_undefined__";function al(e,n){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=il&&n===void 0?ol:n,this}var ll=al,sl=Ha,ul=Ka,fl=Qa,cl=nl,dl=ll;function vt(e){var n=-1,t=e==null?0:e.length;for(this.clear();++n-1}var ql=Sl,Nl=Zt;function Pl(e,n){var t=this.__data__,r=Nl(t,e);return r<0?(++this.size,t.push([e,n])):t[r][1]=n,this}var Ll=Pl,Rl=vl,Fl=El,Dl=Tl,jl=ql,Il=Ll;function yt(e){var n=-1,t=e==null?0:e.length;for(this.clear();++n-1&&e%1==0&&e-1&&e%1==0&&e<=Zs}var Rr=Ys,Xs=Sr,Qs=1/0;function Js(e){if(typeof e=="string"||Xs(e))return e;var n=e+"";return n=="0"&&1/e==-Qs?"-0":n}var Qt=Js,eu=ri,tu=ii,ru=tt,nu=oi,iu=Rr,ou=Qt;function au(e,n,t){n=eu(n,e);for(var r=-1,i=n.length,f=!1;++re&&e.__isYupSchema__;class fu{constructor(n,t){if(this.fn=void 0,this.refs=n,this.refs=n,typeof t=="function"){this.fn=t;return}if(!jt(t,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!t.then&&!t.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:i,otherwise:f}=t,h=typeof r=="function"?r:(...O)=>O.every(m=>m===r);this.fn=function(...O){let m=O.pop(),_=O.pop(),p=h(...O)?i:f;if(!!p)return typeof p=="function"?p(_):_.concat(p.resolve(m))}}resolve(n,t){let r=this.refs.map(f=>f.getValue(t==null?void 0:t.value,t==null?void 0:t.parent,t==null?void 0:t.context)),i=this.fn.apply(n,r.concat(n,t));if(i===void 0||i===n)return n;if(!li(i))throw new TypeError("conditions must return a schema object");return i.resolve(t)}}function si(e){return e==null?[]:[].concat(e)}function vr(){return vr=Object.assign||function(e){for(var n=1;nEt(t[f])):typeof n=="function"?n(t):n}static isError(n){return n&&n.name==="ValidationError"}constructor(n,t,r,i){super(),this.value=void 0,this.path=void 0,this.type=void 0,this.errors=void 0,this.params=void 0,this.inner=void 0,this.name="ValidationError",this.value=t,this.path=r,this.type=i,this.errors=[],this.inner=[],si(n).forEach(f=>{Be.isError(f)?(this.errors.push(...f.errors),this.inner=this.inner.concat(f.inner.length?f.inner:f)):this.errors.push(f)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,Be)}}const du=e=>{let n=!1;return(...t)=>{n||(n=!0,e(...t))}};function yr(e,n){let{endEarly:t,tests:r,args:i,value:f,errors:h,sort:O,path:m}=e,_=du(n),p=r.length;const l=[];if(h=h||[],!p)return h.length?_(new Be(h,f,m)):_(null,f);for(let o=0;oO))return!1;var _=f.get(e),p=f.get(n);if(_&&p)return _==n&&p==e;var l=-1,o=!0,a=t&Tc?new wc:void 0;for(f.set(e,n),f.set(n,e);++l=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=n};var pp=/[^.^\]^[]+|(?=\[\]|\.\.)/g,Oi=/^\d+$/,vp=/^\d/,yp=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,gp=/^\s*(['"]?)(.*?)(\1)\s*$/,jr=512,An=new st(jr),Tn=new st(jr),kn=new st(jr),Jt={Cache:st,split:Er,normalizePath:or,setter:function(e){var n=or(e);return Tn.get(e)||Tn.set(e,function(r,i){for(var f=0,h=n.length,O=r;f=0)&&(t[i]=e[i]);return t}function Rt(e){function n(t,r){let{value:i,path:f="",label:h,options:O,originalValue:m,sync:_}=t,p=wp(t,["value","path","label","options","originalValue","sync"]);const{name:l,test:o,params:a,message:y}=e;let{parent:d,context:v}=O;function c(T){return et.isRef(T)?T.getValue(i,d,v):T}function u(T={}){const A=_i(Ct({value:i,originalValue:m,label:h,path:T.path||f},a,T.params),c),k=new Be(Be.formatError(T.message||y,A),i,A.path,T.type||l);return k.params=A,k}let b=Ct({path:f,parent:d,type:l,createError:u,resolve:c,options:O,originalValue:m},p);if(!_){try{Promise.resolve(o.call(b,i,b)).then(T=>{Be.isError(T)?r(T):T?r(null,T):r(u())}).catch(r)}catch(T){r(T)}return}let s;try{var g;if(s=o.call(b,i,b),typeof((g=s)==null?void 0:g.then)=="function")throw new Error(`Validation test of type: "${b.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`)}catch(T){r(T);return}Be.isError(s)?r(s):s?r(null,s):r(u())}return n.OPTIONS=e,n}let Ep=e=>e.substr(0,e.length-1).substr(1);function xp(e,n,t,r=t){let i,f,h;return n?(Jt.forEach(n,(O,m,_)=>{let p=m?Ep(O):O;if(e=e.resolve({context:r,parent:i,value:t}),e.innerType){let l=_?parseInt(p,10):0;if(t&&l>=t.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${O}, in the path: ${n}. because there is no value at that index. `);i=t,t=t&&t[l],e=e.innerType}if(!_){if(!e.fields||!e.fields[p])throw new Error(`The schema does not contain the path: ${n}. (failed at: ${h} which is a type: "${e._type}")`);i=t,t=t&&t[p],e=e.fields[p]}f=p,h=m?"["+O+"]":"."+O}),{schema:e,parent:i,parentPath:f}):{parent:i,parentPath:n,schema:e}}class Mt{constructor(){this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}get size(){return this.list.size+this.refs.size}describe(){const n=[];for(const t of this.list)n.push(t);for(const[,t]of this.refs)n.push(t.describe());return n}toArray(){return Array.from(this.list).concat(Array.from(this.refs.values()))}resolveAll(n){return this.toArray().reduce((t,r)=>t.concat(et.isRef(r)?n(r):r),[])}add(n){et.isRef(n)?this.refs.set(n.key,n):this.list.add(n)}delete(n){et.isRef(n)?this.refs.delete(n.key):this.list.delete(n)}clone(){const n=new Mt;return n.list=new Set(this.list),n.refs=new Map(this.refs),n}merge(n,t){const r=this.clone();return n.list.forEach(i=>r.add(i)),n.refs.forEach(i=>r.add(i)),t.list.forEach(i=>r.delete(i)),t.refs.forEach(i=>r.delete(i)),r}}function Ue(){return Ue=Object.assign||function(e){for(var n=1;n{this.typeError(nt.notType)}),this.type=(n==null?void 0:n.type)||"mixed",this.spec=Ue({strip:!1,strict:!1,abortEarly:!0,recursive:!0,nullable:!1,presence:"optional"},n==null?void 0:n.spec)}get _type(){return this.type}_typeCheck(n){return!0}clone(n){if(this._mutate)return n&&Object.assign(this.spec,n),this;const t=Object.create(Object.getPrototypeOf(this));return t.type=this.type,t._typeError=this._typeError,t._whitelistError=this._whitelistError,t._blacklistError=this._blacklistError,t._whitelist=this._whitelist.clone(),t._blacklist=this._blacklist.clone(),t.exclusiveTests=Ue({},this.exclusiveTests),t.deps=[...this.deps],t.conditions=[...this.conditions],t.tests=[...this.tests],t.transforms=[...this.transforms],t.spec=dr(Ue({},this.spec,n)),t}label(n){let t=this.clone();return t.spec.label=n,t}meta(...n){if(n.length===0)return this.spec.meta;let t=this.clone();return t.spec.meta=Object.assign(t.spec.meta||{},n[0]),t}withMutation(n){let t=this._mutate;this._mutate=!0;let r=n(this);return this._mutate=t,r}concat(n){if(!n||n===this)return this;if(n.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${n.type}`);let t=this,r=n.clone();const i=Ue({},t.spec,r.spec);return r.spec=i,r._typeError||(r._typeError=t._typeError),r._whitelistError||(r._whitelistError=t._whitelistError),r._blacklistError||(r._blacklistError=t._blacklistError),r._whitelist=t._whitelist.merge(n._whitelist,n._blacklist),r._blacklist=t._blacklist.merge(n._blacklist,n._whitelist),r.tests=t.tests,r.exclusiveTests=t.exclusiveTests,r.withMutation(f=>{n.tests.forEach(h=>{f.test(h.OPTIONS)})}),r.transforms=[...t.transforms,...r.transforms],r}isType(n){return this.spec.nullable&&n===null?!0:this._typeCheck(n)}resolve(n){let t=this;if(t.conditions.length){let r=t.conditions;t=t.clone(),t.conditions=[],t=r.reduce((i,f)=>f.resolve(i,n),t),t=t.resolve(n)}return t}cast(n,t={}){let r=this.resolve(Ue({value:n},t)),i=r._cast(n,t);if(n!==void 0&&t.assert!==!1&&r.isType(i)!==!0){let f=Et(n),h=Et(i);throw new TypeError(`The value of ${t.path||"field"} could not be cast to a value that satisfies the schema type: "${r._type}". attempted value: ${f} `+(h!==f?`result of cast: ${h}`:""))}return i}_cast(n,t){let r=n===void 0?n:this.transforms.reduce((i,f)=>f.call(this,i,n,this),n);return r===void 0&&(r=this.getDefault()),r}_validate(n,t={},r){let{sync:i,path:f,from:h=[],originalValue:O=n,strict:m=this.spec.strict,abortEarly:_=this.spec.abortEarly}=t,p=n;m||(p=this._cast(p,Ue({assert:!1},t)));let l={value:p,path:f,options:t,originalValue:O,schema:this,label:this.spec.label,sync:i,from:h},o=[];this._typeError&&o.push(this._typeError);let a=[];this._whitelistError&&a.push(this._whitelistError),this._blacklistError&&a.push(this._blacklistError),yr({args:l,value:p,path:f,sync:i,tests:o,endEarly:_},y=>{if(y)return void r(y,p);yr({tests:this.tests.concat(a),args:l,path:f,sync:i,value:p,endEarly:_},r)})}validate(n,t,r){let i=this.resolve(Ue({},t,{value:n}));return typeof r=="function"?i._validate(n,t,r):new Promise((f,h)=>i._validate(n,t,(O,m)=>{O?h(O):f(m)}))}validateSync(n,t){let r=this.resolve(Ue({},t,{value:n})),i;return r._validate(n,Ue({},t,{sync:!0}),(f,h)=>{if(f)throw f;i=h}),i}isValid(n,t){return this.validate(n,t).then(()=>!0,r=>{if(Be.isError(r))return!1;throw r})}isValidSync(n,t){try{return this.validateSync(n,t),!0}catch(r){if(Be.isError(r))return!1;throw r}}_getDefault(){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this):dr(n)}getDefault(n){return this.resolve(n||{})._getDefault()}default(n){return arguments.length===0?this._getDefault():this.clone({default:n})}strict(n=!0){let t=this.clone();return t.spec.strict=n,t}_isPresent(n){return n!=null}defined(n=nt.defined){return this.test({message:n,name:"defined",exclusive:!0,test(t){return t!==void 0}})}required(n=nt.required){return this.clone({presence:"required"}).withMutation(t=>t.test({message:n,name:"required",exclusive:!0,test(r){return this.schema._isPresent(r)}}))}notRequired(){let n=this.clone({presence:"optional"});return n.tests=n.tests.filter(t=>t.OPTIONS.name!=="required"),n}nullable(n=!0){return this.clone({nullable:n!==!1})}transform(n){let t=this.clone();return t.transforms.push(n),t}test(...n){let t;if(n.length===1?typeof n[0]=="function"?t={test:n[0]}:t=n[0]:n.length===2?t={name:n[0],test:n[1]}:t={name:n[0],message:n[1],test:n[2]},t.message===void 0&&(t.message=nt.default),typeof t.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),i=Rt(t),f=t.exclusive||t.name&&r.exclusiveTests[t.name]===!0;if(t.exclusive&&!t.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return t.name&&(r.exclusiveTests[t.name]=!!t.exclusive),r.tests=r.tests.filter(h=>!(h.OPTIONS.name===t.name&&(f||h.OPTIONS.test===i.OPTIONS.test))),r.tests.push(i),r}when(n,t){!Array.isArray(n)&&typeof n!="string"&&(t=n,n=".");let r=this.clone(),i=si(n).map(f=>new et(f));return i.forEach(f=>{f.isSibling&&r.deps.push(f.key)}),r.conditions.push(new fu(i,t)),r}typeError(n){let t=this.clone();return t._typeError=Rt({message:n,name:"typeError",test(r){return r!==void 0&&!this.schema.isType(r)?this.createError({params:{type:this.schema._type}}):!0}}),t}oneOf(n,t=nt.oneOf){let r=this.clone();return n.forEach(i=>{r._whitelist.add(i),r._blacklist.delete(i)}),r._whitelistError=Rt({message:t,name:"oneOf",test(i){if(i===void 0)return!0;let f=this.schema._whitelist,h=f.resolveAll(this.resolve);return h.includes(i)?!0:this.createError({params:{values:f.toArray().join(", "),resolved:h}})}}),r}notOneOf(n,t=nt.notOneOf){let r=this.clone();return n.forEach(i=>{r._blacklist.add(i),r._whitelist.delete(i)}),r._blacklistError=Rt({message:t,name:"notOneOf",test(i){let f=this.schema._blacklist,h=f.resolveAll(this.resolve);return h.includes(i)?this.createError({params:{values:f.toArray().join(", "),resolved:h}}):!0}}),r}strip(n=!0){let t=this.clone();return t.spec.strip=n,t}describe(){const n=this.clone(),{label:t,meta:r}=n.spec;return{meta:r,label:t,type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(f=>({name:f.OPTIONS.name,params:f.OPTIONS.params})).filter((f,h,O)=>O.findIndex(m=>m.name===f.name)===h)}}}Ce.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])Ce.prototype[`${e}At`]=function(n,t,r={}){const{parent:i,parentPath:f,schema:h}=xp(this,n,t,r.context);return h[e](i&&i[f],Ue({},r,{parent:i,path:n}))};for(const e of["equals","is"])Ce.prototype[e]=Ce.prototype.oneOf;for(const e of["not","nope"])Ce.prototype[e]=Ce.prototype.notOneOf;Ce.prototype.optional=Ce.prototype.notRequired;const Ap=Ce;Ap.prototype;const ze=e=>e==null;let Tp=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,kp=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,Sp=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,qp=e=>ze(e)||e===e.trim(),Np={}.toString();function Pp(){return new wi}class wi extends Ce{constructor(){super({type:"string"}),this.withMutation(()=>{this.transform(function(n){if(this.isType(n)||Array.isArray(n))return n;const t=n!=null&&n.toString?n.toString():n;return t===Np?n:t})})}_typeCheck(n){return n instanceof String&&(n=n.valueOf()),typeof n=="string"}_isPresent(n){return super._isPresent(n)&&!!n.length}length(n,t=He.length){return this.test({message:t,name:"length",exclusive:!0,params:{length:n},test(r){return ze(r)||r.length===this.resolve(n)}})}min(n,t=He.min){return this.test({message:t,name:"min",exclusive:!0,params:{min:n},test(r){return ze(r)||r.length>=this.resolve(n)}})}max(n,t=He.max){return this.test({name:"max",exclusive:!0,message:t,params:{max:n},test(r){return ze(r)||r.length<=this.resolve(n)}})}matches(n,t){let r=!1,i,f;return t&&(typeof t=="object"?{excludeEmptyString:r=!1,message:i,name:f}=t:i=t),this.test({name:f||"matches",message:i||He.matches,params:{regex:n},test:h=>ze(h)||h===""&&r||h.search(n)!==-1})}email(n=He.email){return this.matches(Tp,{name:"email",message:n,excludeEmptyString:!0})}url(n=He.url){return this.matches(kp,{name:"url",message:n,excludeEmptyString:!0})}uuid(n=He.uuid){return this.matches(Sp,{name:"uuid",message:n,excludeEmptyString:!1})}ensure(){return this.default("").transform(n=>n===null?"":n)}trim(n=He.trim){return this.transform(t=>t!=null?t.trim():t).test({message:n,name:"trim",test:qp})}lowercase(n=He.lowercase){return this.transform(t=>ze(t)?t:t.toLowerCase()).test({message:n,name:"string_case",exclusive:!0,test:t=>ze(t)||t===t.toLowerCase()})}uppercase(n=He.uppercase){return this.transform(t=>ze(t)?t:t.toUpperCase()).test({message:n,name:"string_case",exclusive:!0,test:t=>ze(t)||t===t.toUpperCase()})}}Pp.prototype=wi.prototype;var Lp=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;function Rp(e){var n=[1,4,5,6,7,10,11],t=0,r,i;if(i=Lp.exec(e)){for(var f=0,h;h=n[f];++f)i[h]=+i[h]||0;i[2]=(+i[2]||1)-1,i[3]=+i[3]||1,i[7]=i[7]?String(i[7]).substr(0,3):0,(i[8]===void 0||i[8]==="")&&(i[9]===void 0||i[9]==="")?r=+new Date(i[1],i[2],i[3],i[4],i[5],i[6],i[7]):(i[8]!=="Z"&&i[9]!==void 0&&(t=i[10]*60+i[11],i[9]==="+"&&(t=0-t)),r=Date.UTC(i[1],i[2],i[3],i[4],i[5]+t,i[6],i[7]))}else r=Date.parse?Date.parse(e):NaN;return r}let Ei=new Date(""),Fp=e=>Object.prototype.toString.call(e)==="[object Date]";class xi extends Ce{constructor(){super({type:"date"}),this.withMutation(()=>{this.transform(function(n){return this.isType(n)?n:(n=Rp(n),isNaN(n)?Ei:new Date(n))})})}_typeCheck(n){return Fp(n)&&!isNaN(n.getTime())}prepareParam(n,t){let r;if(et.isRef(n))r=n;else{let i=this.cast(n);if(!this._typeCheck(i))throw new TypeError(`\`${t}\` must be a Date or a value that can be \`cast()\` to a Date`);r=i}return r}min(n,t=hr.min){let r=this.prepareParam(n,"min");return this.test({message:t,name:"min",exclusive:!0,params:{min:n},test(i){return ze(i)||i>=this.resolve(r)}})}max(n,t=hr.max){let r=this.prepareParam(n,"max");return this.test({message:t,name:"max",exclusive:!0,params:{max:n},test(i){return ze(i)||i<=this.resolve(r)}})}}xi.INVALID_DATE=Ei;xi.prototype;function Dp(e,n,t,r){var i=-1,f=e==null?0:e.length;for(r&&f&&(t=e[++i]);++ii?0:i+n),t=t>i?i:t,t<0&&(t+=i),i=n>t?0:t-n>>>0,n>>>=0;for(var f=Array(i);++r=r?e:Kv(e,n,t)}var Wv=Gv,Zv="\\ud800-\\udfff",Yv="\\u0300-\\u036f",Xv="\\ufe20-\\ufe2f",Qv="\\u20d0-\\u20ff",Jv=Yv+Xv+Qv,ey="\\ufe0e\\ufe0f",ty="\\u200d",ry=RegExp("["+ty+Zv+Jv+ey+"]");function ny(e){return ry.test(e)}var Ci=ny;function iy(e){return e.split("")}var oy=iy,Mi="\\ud800-\\udfff",ay="\\u0300-\\u036f",ly="\\ufe20-\\ufe2f",sy="\\u20d0-\\u20ff",uy=ay+ly+sy,fy="\\ufe0e\\ufe0f",cy="["+Mi+"]",xr="["+uy+"]",Ar="\\ud83c[\\udffb-\\udfff]",dy="(?:"+xr+"|"+Ar+")",Bi="[^"+Mi+"]",Ui="(?:\\ud83c[\\udde6-\\uddff]){2}",Vi="[\\ud800-\\udbff][\\udc00-\\udfff]",hy="\\u200d",Hi=dy+"?",zi="["+fy+"]?",py="(?:"+hy+"(?:"+[Bi,Ui,Vi].join("|")+")"+zi+Hi+")*",vy=zi+Hi+py,yy="(?:"+[Bi+xr+"?",xr,Ui,Vi,cy].join("|")+")",gy=RegExp(Ar+"(?="+Ar+")|"+yy+vy,"g");function my(e){return e.match(gy)||[]}var by=my,_y=oy,Oy=Ci,wy=by;function Ey(e){return Oy(e)?wy(e):_y(e)}var xy=Ey,Ay=Wv,Ty=Ci,ky=xy,Sy=Tt;function qy(e){return function(n){n=Sy(n);var t=Ty(n)?ky(n):void 0,r=t?t[0]:n.charAt(0),i=t?Ay(t,1).join(""):n.slice(1);return r[e]()+i}}var Ny=qy,Py=Ny,Ly=Py("toUpperCase"),Ry=Ly,Fy=Tt,Dy=Ry;function jy(e){return Dy(Fy(e).toLowerCase())}var Iy=jy,$y=Iy,Cy=$i,My=Cy(function(e,n,t){return n=n.toLowerCase(),e+(t?$y(n):n)}),By=My,Uy=ui,Vy=ci,Hy=bi;function zy(e,n){var t={};return n=Hy(n),Vy(e,function(r,i,f){Uy(t,n(r,i,f),r)}),t}var Ky=zy,$r={exports:{}};$r.exports=function(e){return Ki(Gy(e),e)};$r.exports.array=Ki;function Ki(e,n){var t=e.length,r=new Array(t),i={},f=t,h=Wy(n),O=Zy(e);for(n.forEach(function(_){if(!O.has(_[0])||!O.has(_[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});f--;)i[f]||m(e[f],f,new Set);return r;function m(_,p,l){if(l.has(_)){var o;try{o=", node was:"+JSON.stringify(_)}catch{o=""}throw new Error("Cyclic dependency"+o)}if(!O.has(_))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(_));if(!i[p]){i[p]=!0;var a=h.get(_)||new Set;if(a=Array.from(a),p=a.length){l.add(_);do{var y=a[--p];m(y,O.get(y),l)}while(p);l.delete(_)}r[--t]=_}}}function Gy(e){for(var n=new Set,t=0,r=e.length;t`${h}-${O}`));function f(h,O){let m=Jt.split(h)[0];r.add(m),i.has(`${O}-${m}`)||t.push([O,m])}for(const h in e)if(jt(e,h)){let O=e[h];r.add(h),et.isRef(O)&&O.isSibling?f(O.path,h):li(O)&&"deps"in O&&O.deps.forEach(m=>f(m,h))}return $r.exports.array(Array.from(r),t).reverse()}function Rn(e,n){let t=1/0;return e.some((r,i)=>{var f;if(((f=n.path)==null?void 0:f.indexOf(r))!==-1)return t=i,!0}),t}function Gi(e){return(n,t)=>Rn(e,n)-Rn(e,t)}function dt(){return dt=Object.assign||function(e){for(var n=1;nObject.prototype.toString.call(e)==="[object Object]";function Xy(e,n){let t=Object.keys(e.fields);return Object.keys(n).filter(r=>t.indexOf(r)===-1)}const Qy=Gi([]);class Wi extends Ce{constructor(n){super({type:"object"}),this.fields=Object.create(null),this._sortErrors=Qy,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(r){if(typeof r=="string")try{r=JSON.parse(r)}catch{r=null}return this.isType(r)?r:null}),n&&this.shape(n)})}_typeCheck(n){return Fn(n)||typeof n=="function"}_cast(n,t={}){var r;let i=super._cast(n,t);if(i===void 0)return this.getDefault();if(!this._typeCheck(i))return i;let f=this.fields,h=(r=t.stripUnknown)!=null?r:this.spec.noUnknown,O=this._nodes.concat(Object.keys(i).filter(l=>this._nodes.indexOf(l)===-1)),m={},_=dt({},t,{parent:m,__validating:t.__validating||!1}),p=!1;for(const l of O){let o=f[l],a=jt(i,l);if(o){let y,d=i[l];_.path=(t.path?`${t.path}.`:"")+l,o=o.resolve({value:d,context:t.context,parent:m});let v="spec"in o?o.spec:void 0,c=v==null?void 0:v.strict;if(v!=null&&v.strip){p=p||l in i;continue}y=!t.__validating||!c?o.cast(i[l],_):i[l],y!==void 0&&(m[l]=y)}else a&&!h&&(m[l]=i[l]);m[l]!==i[l]&&(p=!0)}return p?m:i}_validate(n,t={},r){let i=[],{sync:f,from:h=[],originalValue:O=n,abortEarly:m=this.spec.abortEarly,recursive:_=this.spec.recursive}=t;h=[{schema:this,value:O},...h],t.__validating=!0,t.originalValue=O,t.from=h,super._validate(n,t,(p,l)=>{if(p){if(!Be.isError(p)||m)return void r(p,l);i.push(p)}if(!_||!Fn(l)){r(i[0]||null,l);return}O=O||l;let o=this._nodes.map(a=>(y,d)=>{let v=a.indexOf(".")===-1?(t.path?`${t.path}.`:"")+a:`${t.path||""}["${a}"]`,c=this.fields[a];if(c&&"validate"in c){c.validate(l[a],dt({},t,{path:v,from:h,strict:!0,parent:l,originalValue:O[a]}),d);return}d(null)});yr({sync:f,tests:o,value:l,errors:i,endEarly:m,sort:this._sortErrors,path:t.path},r)})}clone(n){const t=super.clone(n);return t.fields=dt({},this.fields),t._nodes=this._nodes,t._excludedEdges=this._excludedEdges,t._sortErrors=this._sortErrors,t}concat(n){let t=super.concat(n),r=t.fields;for(let[i,f]of Object.entries(this.fields)){const h=r[i];h===void 0?r[i]=f:h instanceof Ce&&f instanceof Ce&&(r[i]=f.concat(h))}return t.withMutation(()=>t.shape(r,this._excludedEdges))}getDefaultFromShape(){let n={};return this._nodes.forEach(t=>{const r=this.fields[t];n[t]="default"in r?r.getDefault():void 0}),n}_getDefault(){if("default"in this.spec)return super._getDefault();if(!!this._nodes.length)return this.getDefaultFromShape()}shape(n,t=[]){let r=this.clone(),i=Object.assign(r.fields,n);return r.fields=i,r._sortErrors=Gi(Object.keys(i)),t.length&&(Array.isArray(t[0])||(t=[t]),r._excludedEdges=[...r._excludedEdges,...t]),r._nodes=Yy(i,r._excludedEdges),r}pick(n){const t={};for(const r of n)this.fields[r]&&(t[r]=this.fields[r]);return this.clone().withMutation(r=>(r.fields={},r.shape(t)))}omit(n){const t=this.clone(),r=t.fields;t.fields={};for(const i of n)delete r[i];return t.withMutation(()=>t.shape(r))}from(n,t,r){let i=Jt.getter(n,!0);return this.transform(f=>{if(f==null)return f;let h=f;return jt(f,n)&&(h=dt({},f),r||delete h[n],h[t]=i(f)),h})}noUnknown(n=!0,t=pr.noUnknown){typeof n=="string"&&(t=n,n=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:t,test(i){if(i==null)return!0;const f=Xy(this.schema,i);return!n||f.length===0||this.createError({params:{unknown:f.join(", ")}})}});return r.spec.noUnknown=n,r}unknown(n=!0,t=pr.noUnknown){return this.noUnknown(!n,t)}transformKeys(n){return this.transform(t=>t&&Ky(t,(r,i)=>n(i)))}camelCase(){return this.transformKeys(By)}snakeCase(){return this.transformKeys(Ln)}constantCase(){return this.transformKeys(n=>Ln(n).toUpperCase())}describe(){let n=super.describe();return n.fields=_i(this.fields,t=>t.describe()),n}}function Jy(e){return new Wi(e)}Jy.prototype=Wi.prototype;var kt=e=>e.type==="checkbox",ht=e=>e instanceof Date,$e=e=>e==null;const Zi=e=>typeof e=="object";var Pe=e=>!$e(e)&&!Array.isArray(e)&&Zi(e)&&!ht(e),Yi=e=>Pe(e)&&e.target?kt(e.target)?e.target.checked:e.target.value:e,eg=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,Xi=(e,n)=>e.has(eg(n)),tg=e=>{const n=e.constructor&&e.constructor.prototype;return Pe(n)&&n.hasOwnProperty("isPrototypeOf")},Cr=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Xe(e){let n;const t=Array.isArray(e);if(e instanceof Date)n=new Date(e);else if(e instanceof Set)n=new Set(e);else if(!(Cr&&(e instanceof Blob||e instanceof FileList))&&(t||Pe(e)))if(n=t?[]:{},!Array.isArray(e)&&!tg(e))n=e;else for(const r in e)n[r]=Xe(e[r]);else return e;return n}var St=e=>Array.isArray(e)?e.filter(Boolean):[],ke=e=>e===void 0,se=(e,n,t)=>{if(!n||!Pe(e))return t;const r=St(n.split(/[,[\].]+?/)).reduce((i,f)=>$e(i)?i:i[f],e);return ke(r)||r===e?ke(e[n])?t:e[n]:r};const Bt={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},Ke={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},Ye={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},Qi=Se.createContext(null),er=()=>Se.useContext(Qi),rg=e=>{const{children:n,...t}=e;return Se.createElement(Qi.Provider,{value:t},n)};var Ji=(e,n,t,r=!0)=>{const i={defaultValues:n._defaultValues};for(const f in e)Object.defineProperty(i,f,{get:()=>{const h=f;return n._proxyFormState[h]!==Ke.all&&(n._proxyFormState[h]=!r||Ke.all),t&&(t[h]=!0),e[h]}});return i},Ve=e=>Pe(e)&&!Object.keys(e).length,eo=(e,n,t,r)=>{t(e);const{name:i,...f}=e;return Ve(f)||Object.keys(f).length>=Object.keys(n).length||Object.keys(f).find(h=>n[h]===(!r||Ke.all))},Ft=e=>Array.isArray(e)?e:[e],to=(e,n,t)=>t&&n?e===n:!e||!n||e===n||Ft(e).some(r=>r&&(r.startsWith(n)||n.startsWith(r)));function Mr(e){const n=Se.useRef(e);n.current=e,Se.useEffect(()=>{const t=!e.disabled&&n.current.subject&&n.current.subject.subscribe({next:n.current.next});return()=>{t&&t.unsubscribe()}},[e.disabled])}function ng(e){const n=er(),{control:t=n.control,disabled:r,name:i,exact:f}=e||{},[h,O]=Se.useState(t._formState),m=Se.useRef(!0),_=Se.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1}),p=Se.useRef(i);return p.current=i,Mr({disabled:r,next:l=>m.current&&to(p.current,l.name,f)&&eo(l,_.current,t._updateFormState)&&O({...t._formState,...l}),subject:t._subjects.state}),Se.useEffect(()=>{m.current=!0;const l=t._proxyFormState.isDirty&&t._getDirty();return l!==t._formState.isDirty&&t._subjects.state.next({isDirty:l}),_.current.isValid&&t._updateValid(!0),()=>{m.current=!1}},[t]),Ji(h,t,_.current,!1)}var Ze=e=>typeof e=="string",ro=(e,n,t,r,i)=>Ze(e)?(r&&n.watch.add(e),se(t,e,i)):Array.isArray(e)?e.map(f=>(r&&n.watch.add(f),se(t,f))):(r&&(n.watchAll=!0),t);function ig(e){const n=er(),{control:t=n.control,name:r,defaultValue:i,disabled:f,exact:h}=e||{},O=Se.useRef(r);O.current=r,Mr({disabled:f,subject:t._subjects.values,next:p=>{to(O.current,p.name,h)&&_(Xe(ro(O.current,t._names,p.values||t._formValues,!1,i)))}});const[m,_]=Se.useState(t._getWatch(r,i));return Se.useEffect(()=>t._removeUnmounted()),m}var Br=e=>/^\w*$/.test(e),no=e=>St(e.replace(/["|']|\]/g,"").split(/\.|\[/));function Oe(e,n,t){let r=-1;const i=Br(n)?[n]:no(n),f=i.length,h=f-1;for(;++r{const _=r._options.shouldUnregister||i,p=(l,o)=>{const a=se(r._fields,l);a&&(a._f.mount=o)};if(p(t,!0),_){const l=Xe(se(r._options.defaultValues,t));Oe(r._defaultValues,t,l),ke(se(r._formValues,t))&&Oe(r._formValues,t,l)}return()=>{(f?_&&!r._state.action:_)?r.unregister(t):p(t,!1)}},[t,r,f,i]),{field:{name:t,value:h,onChange:Se.useCallback(_=>m.current.onChange({target:{value:Yi(_),name:t},type:Bt.CHANGE}),[t]),onBlur:Se.useCallback(()=>m.current.onBlur({target:{value:se(r._formValues,t),name:t},type:Bt.BLUR}),[t,r]),ref:_=>{const p=se(r._fields,t);p&&_&&(p._f.ref={focus:()=>_.focus(),select:()=>_.select(),setCustomValidity:l=>_.setCustomValidity(l),reportValidity:()=>_.reportValidity()})}},formState:O,fieldState:Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!se(O.errors,t)},isDirty:{enumerable:!0,get:()=>!!se(O.dirtyFields,t)},isTouched:{enumerable:!0,get:()=>!!se(O.touchedFields,t)},error:{enumerable:!0,get:()=>se(O.errors,t)}})}}const ag=e=>e.render(og(e));var io=(e,n,t,r,i)=>n?{...t[e],types:{...t[e]&&t[e].types?t[e].types:{},[r]:i||!0}}:{};const Tr=(e,n,t)=>{for(const r of t||Object.keys(e)){const i=se(e,r);if(i){const{_f:f,...h}=i;if(f&&n(f.name)){if(f.ref.focus){f.ref.focus();break}else if(f.refs&&f.refs[0].focus){f.refs[0].focus();break}}else Pe(h)&&Tr(h,n)}}};var Dn=e=>({isOnSubmit:!e||e===Ke.onSubmit,isOnBlur:e===Ke.onBlur,isOnChange:e===Ke.onChange,isOnAll:e===Ke.all,isOnTouch:e===Ke.onTouched}),jn=(e,n,t)=>!t&&(n.watchAll||n.watch.has(e)||[...n.watch].some(r=>e.startsWith(r)&&/^\.\w+/.test(e.slice(r.length)))),lg=(e,n,t)=>{const r=St(se(e,t));return Oe(r,"root",n[t]),Oe(e,t,r),e},pt=e=>typeof e=="boolean",Ur=e=>e.type==="file",Je=e=>typeof e=="function",Ut=e=>{if(!Cr)return!1;const n=e?e.ownerDocument:0;return e instanceof(n&&n.defaultView?n.defaultView.HTMLElement:HTMLElement)},Dt=e=>Ze(e),Vr=e=>e.type==="radio",Vt=e=>e instanceof RegExp;const In={value:!1,isValid:!1},$n={value:!0,isValid:!0};var oo=e=>{if(Array.isArray(e)){if(e.length>1){const n=e.filter(t=>t&&t.checked&&!t.disabled).map(t=>t.value);return{value:n,isValid:!!n.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!ke(e[0].attributes.value)?ke(e[0].value)||e[0].value===""?$n:{value:e[0].value,isValid:!0}:$n:In}return In};const Cn={isValid:!1,value:null};var ao=e=>Array.isArray(e)?e.reduce((n,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:n,Cn):Cn;function Mn(e,n,t="validate"){if(Dt(e)||Array.isArray(e)&&e.every(Dt)||pt(e)&&!e)return{type:t,message:Dt(e)?e:"",ref:n}}var ft=e=>Pe(e)&&!Vt(e)?e:{value:e,message:""},Bn=async(e,n,t,r,i)=>{const{ref:f,refs:h,required:O,maxLength:m,minLength:_,min:p,max:l,pattern:o,validate:a,name:y,valueAsNumber:d,mount:v,disabled:c}=e._f,u=se(n,y);if(!v||c)return{};const b=h?h[0]:f,s=w=>{r&&b.reportValidity&&(b.setCustomValidity(pt(w)?"":w||""),b.reportValidity())},g={},T=Vr(f),A=kt(f),k=T||A,N=(d||Ur(f))&&ke(f.value)&&ke(u)||Ut(f)&&f.value===""||u===""||Array.isArray(u)&&!u.length,x=io.bind(null,y,t,g),E=(w,S,P,F=Ye.maxLength,M=Ye.minLength)=>{const H=w?S:P;g[y]={type:w?F:M,message:H,ref:f,...x(w?F:M,H)}};if(i?!Array.isArray(u)||!u.length:O&&(!k&&(N||$e(u))||pt(u)&&!u||A&&!oo(h).isValid||T&&!ao(h).isValid)){const{value:w,message:S}=Dt(O)?{value:!!O,message:O}:ft(O);if(w&&(g[y]={type:Ye.required,message:S,ref:b,...x(Ye.required,S)},!t))return s(S),g}if(!N&&(!$e(p)||!$e(l))){let w,S;const P=ft(l),F=ft(p);if(!$e(u)&&!isNaN(u)){const M=f.valueAsNumber||u&&+u;$e(P.value)||(w=M>P.value),$e(F.value)||(S=Mnew Date(new Date().toDateString()+" "+D),Q=f.type=="time",C=f.type=="week";Ze(P.value)&&u&&(w=Q?H(u)>H(P.value):C?u>P.value:M>new Date(P.value)),Ze(F.value)&&u&&(S=Q?H(u)+w.value,F=!$e(S.value)&&u.length<+S.value;if((P||F)&&(E(P,w.message,S.message),!t))return s(g[y].message),g}if(o&&!N&&Ze(u)){const{value:w,message:S}=ft(o);if(Vt(w)&&!u.match(w)&&(g[y]={type:Ye.pattern,message:S,ref:f,...x(Ye.pattern,S)},!t))return s(S),g}if(a){if(Je(a)){const w=await a(u,n),S=Mn(w,b);if(S&&(g[y]={...S,...x(Ye.validate,S.message)},!t))return s(S.message),g}else if(Pe(a)){let w={};for(const S in a){if(!Ve(w)&&!t)break;const P=Mn(await a[S](u,n),b,S);P&&(w={...P,...x(S,P.message)},s(P.message),t&&(g[y]=w))}if(!Ve(w)&&(g[y]={ref:b,...w},!t))return g}}return s(!0),g};function sg(e,n){const t=n.slice(0,-1).length;let r=0;for(;r{for(const f of e)f.next&&f.next(i)},subscribe:i=>(e.push(i),{unsubscribe:()=>{e=e.filter(f=>f!==i)}}),unsubscribe:()=>{e=[]}}}var Ht=e=>$e(e)||!Zi(e);function ot(e,n){if(Ht(e)||Ht(n))return e===n;if(ht(e)&&ht(n))return e.getTime()===n.getTime();const t=Object.keys(e),r=Object.keys(n);if(t.length!==r.length)return!1;for(const i of t){const f=e[i];if(!r.includes(i))return!1;if(i!=="ref"){const h=n[i];if(ht(f)&&ht(h)||Pe(f)&&Pe(h)||Array.isArray(f)&&Array.isArray(h)?!ot(f,h):f!==h)return!1}}return!0}var lo=e=>e.type==="select-multiple",fg=e=>Vr(e)||kt(e),lr=e=>Ut(e)&&e.isConnected,so=e=>{for(const n in e)if(Je(e[n]))return!0;return!1};function zt(e,n={}){const t=Array.isArray(e);if(Pe(e)||t)for(const r in e)Array.isArray(e[r])||Pe(e[r])&&!so(e[r])?(n[r]=Array.isArray(e[r])?[]:{},zt(e[r],n[r])):$e(e[r])||(n[r]=!0);return n}function uo(e,n,t){const r=Array.isArray(e);if(Pe(e)||r)for(const i in e)Array.isArray(e[i])||Pe(e[i])&&!so(e[i])?ke(n)||Ht(t[i])?t[i]=Array.isArray(e[i])?zt(e[i],[]):{...zt(e[i])}:uo(e[i],$e(n)?{}:n[i],t[i]):t[i]=!ot(e[i],n[i]);return t}var sr=(e,n)=>uo(e,n,zt(n)),fo=(e,{valueAsNumber:n,valueAsDate:t,setValueAs:r})=>ke(e)?e:n?e===""?NaN:e&&+e:t&&Ze(e)?new Date(e):r?r(e):e;function ur(e){const n=e.ref;if(!(e.refs?e.refs.every(t=>t.disabled):n.disabled))return Ur(n)?n.files:Vr(n)?ao(e.refs).value:lo(n)?[...n.selectedOptions].map(({value:t})=>t):kt(n)?oo(e.refs).value:fo(ke(n.value)?e.ref.value:n.value,e)}var cg=(e,n,t,r)=>{const i={};for(const f of e){const h=se(n,f);h&&Oe(i,f,h._f)}return{criteriaMode:t,names:[...e],fields:i,shouldUseNativeValidation:r}},Ot=e=>ke(e)?e:Vt(e)?e.source:Pe(e)?Vt(e.value)?e.value.source:e.value:e,dg=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate);function Un(e,n,t){const r=se(e,t);if(r||Br(t))return{error:r,name:t};const i=t.split(".");for(;i.length;){const f=i.join("."),h=se(n,f),O=se(e,f);if(h&&!Array.isArray(h)&&t!==f)return{name:t};if(O&&O.type)return{name:f,error:O};i.pop()}return{name:t}}var hg=(e,n,t,r,i)=>i.isOnAll?!1:!t&&i.isOnTouch?!(n||e):(t?r.isOnBlur:i.isOnBlur)?!e:(t?r.isOnChange:i.isOnChange)?e:!0,pg=(e,n)=>!St(se(e,n)).length&&De(e,n);const vg={mode:Ke.onSubmit,reValidateMode:Ke.onChange,shouldFocusError:!0};function yg(e={},n){let t={...vg,...e},r={submitCount:0,isDirty:!1,isLoading:Je(t.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},errors:{}},i={},f=Pe(t.defaultValues)||Pe(t.values)?Xe(t.defaultValues||t.values)||{}:{},h=t.shouldUnregister?{}:Xe(f),O={action:!1,mount:!1,watch:!1},m={mount:new Set,unMount:new Set,array:new Set,watch:new Set},_,p=0;const l={isDirty:!1,dirtyFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},o={values:ar(),array:ar(),state:ar()},a=e.resetOptions&&e.resetOptions.keepDirtyValues,y=Dn(t.mode),d=Dn(t.reValidateMode),v=t.criteriaMode===Ke.all,c=I=>Y=>{clearTimeout(p),p=setTimeout(I,Y)},u=async I=>{if(l.isValid||I){const Y=t.resolver?Ve((await N()).errors):await E(i,!0);Y!==r.isValid&&o.state.next({isValid:Y})}},b=I=>l.isValidating&&o.state.next({isValidating:I}),s=(I,Y=[],X,z,U=!0,G=!0)=>{if(z&&X){if(O.action=!0,G&&Array.isArray(se(i,I))){const te=X(se(i,I),z.argA,z.argB);U&&Oe(i,I,te)}if(G&&Array.isArray(se(r.errors,I))){const te=X(se(r.errors,I),z.argA,z.argB);U&&Oe(r.errors,I,te),pg(r.errors,I)}if(l.touchedFields&&G&&Array.isArray(se(r.touchedFields,I))){const te=X(se(r.touchedFields,I),z.argA,z.argB);U&&Oe(r.touchedFields,I,te)}l.dirtyFields&&(r.dirtyFields=sr(f,h)),o.state.next({name:I,isDirty:S(I,Y),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else Oe(h,I,Y)},g=(I,Y)=>{Oe(r.errors,I,Y),o.state.next({errors:r.errors})},T=(I,Y,X,z)=>{const U=se(i,I);if(U){const G=se(h,I,ke(X)?se(f,I):X);ke(G)||z&&z.defaultChecked||Y?Oe(h,I,Y?G:ur(U._f)):M(I,G),O.mount&&u()}},A=(I,Y,X,z,U)=>{let G=!1,te=!1;const ee={name:I};if(!X||z){l.isDirty&&(te=r.isDirty,r.isDirty=ee.isDirty=S(),G=te!==ee.isDirty);const ue=ot(se(f,I),Y);te=se(r.dirtyFields,I),ue?De(r.dirtyFields,I):Oe(r.dirtyFields,I,!0),ee.dirtyFields=r.dirtyFields,G=G||l.dirtyFields&&te!==!ue}if(X){const ue=se(r.touchedFields,I);ue||(Oe(r.touchedFields,I,X),ee.touchedFields=r.touchedFields,G=G||l.touchedFields&&ue!==X)}return G&&U&&o.state.next(ee),G?ee:{}},k=(I,Y,X,z)=>{const U=se(r.errors,I),G=l.isValid&&pt(Y)&&r.isValid!==Y;if(e.delayError&&X?(_=c(()=>g(I,X)),_(e.delayError)):(clearTimeout(p),_=null,X?Oe(r.errors,I,X):De(r.errors,I)),(X?!ot(U,X):U)||!Ve(z)||G){const te={...z,...G&&pt(Y)?{isValid:Y}:{},errors:r.errors,name:I};r={...r,...te},o.state.next(te)}b(!1)},N=async I=>t.resolver(h,t.context,cg(I||m.mount,i,t.criteriaMode,t.shouldUseNativeValidation)),x=async I=>{const{errors:Y}=await N();if(I)for(const X of I){const z=se(Y,X);z?Oe(r.errors,X,z):De(r.errors,X)}else r.errors=Y;return Y},E=async(I,Y,X={valid:!0})=>{for(const z in I){const U=I[z];if(U){const{_f:G,...te}=U;if(G){const ee=m.array.has(G.name),ue=await Bn(U,h,v,t.shouldUseNativeValidation&&!Y,ee);if(ue[G.name]&&(X.valid=!1,Y))break;!Y&&(se(ue,G.name)?ee?lg(r.errors,ue,G.name):Oe(r.errors,G.name,ue[G.name]):De(r.errors,G.name))}te&&await E(te,Y,X)}}return X.valid},w=()=>{for(const I of m.unMount){const Y=se(i,I);Y&&(Y._f.refs?Y._f.refs.every(X=>!lr(X)):!lr(Y._f.ref))&&L(I)}m.unMount=new Set},S=(I,Y)=>(I&&Y&&Oe(h,I,Y),!ot(q(),f)),P=(I,Y,X)=>ro(I,m,{...O.mount?h:ke(Y)?f:Ze(I)?{[I]:Y}:Y},X,Y),F=I=>St(se(O.mount?h:f,I,e.shouldUnregister?se(f,I,[]):[])),M=(I,Y,X={})=>{const z=se(i,I);let U=Y;if(z){const G=z._f;G&&(!G.disabled&&Oe(h,I,fo(Y,G)),U=Ut(G.ref)&&$e(Y)?"":Y,lo(G.ref)?[...G.ref.options].forEach(te=>te.selected=U.includes(te.value)):G.refs?kt(G.ref)?G.refs.length>1?G.refs.forEach(te=>(!te.defaultChecked||!te.disabled)&&(te.checked=Array.isArray(U)?!!U.find(ee=>ee===te.value):U===te.value)):G.refs[0]&&(G.refs[0].checked=!!U):G.refs.forEach(te=>te.checked=te.value===U):Ur(G.ref)?G.ref.value="":(G.ref.value=U,G.ref.type||o.values.next({name:I,values:{...h}})))}(X.shouldDirty||X.shouldTouch)&&A(I,U,X.shouldTouch,X.shouldDirty,!0),X.shouldValidate&&D(I)},H=(I,Y,X)=>{for(const z in Y){const U=Y[z],G=`${I}.${z}`,te=se(i,G);(m.array.has(I)||!Ht(U)||te&&!te._f)&&!ht(U)?H(G,U,X):M(G,U,X)}},Q=(I,Y,X={})=>{const z=se(i,I),U=m.array.has(I),G=Xe(Y);Oe(h,I,G),U?(o.array.next({name:I,values:{...h}}),(l.isDirty||l.dirtyFields)&&X.shouldDirty&&o.state.next({name:I,dirtyFields:sr(f,h),isDirty:S(I,G)})):z&&!z._f&&!$e(G)?H(I,G,X):M(I,G,X),jn(I,m)&&o.state.next({...r}),o.values.next({name:I,values:{...h}}),!O.mount&&n()},C=async I=>{const Y=I.target;let X=Y.name,z=!0;const U=se(i,X),G=()=>Y.type?ur(U._f):Yi(I);if(U){let te,ee;const ue=G(),he=I.type===Bt.BLUR||I.type===Bt.FOCUS_OUT,ye=!dg(U._f)&&!t.resolver&&!se(r.errors,X)&&!U._f.deps||hg(he,se(r.touchedFields,X),r.isSubmitted,d,y),qe=jn(X,m,he);Oe(h,X,ue),he?(U._f.onBlur&&U._f.onBlur(I),_&&_(0)):U._f.onChange&&U._f.onChange(I);const Re=A(X,ue,he,!1),_e=!Ve(Re)||qe;if(!he&&o.values.next({name:X,type:I.type,values:{...h}}),ye)return l.isValid&&u(),_e&&o.state.next({name:X,...qe?{}:Re});if(!he&&qe&&o.state.next({...r}),b(!0),t.resolver){const{errors:ne}=await N([X]),K=Un(r.errors,i,X),oe=Un(ne,i,K.name||X);te=oe.error,X=oe.name,ee=Ve(ne)}else te=(await Bn(U,h,v,t.shouldUseNativeValidation))[X],z=isNaN(ue)||ue===se(h,X,ue),z&&(te?ee=!1:l.isValid&&(ee=await E(i,!0)));z&&(U._f.deps&&D(U._f.deps),k(X,ee,te,Re))}},D=async(I,Y={})=>{let X,z;const U=Ft(I);if(b(!0),t.resolver){const G=await x(ke(I)?I:U);X=Ve(G),z=I?!U.some(te=>se(G,te)):X}else I?(z=(await Promise.all(U.map(async G=>{const te=se(i,G);return await E(te&&te._f?{[G]:te}:te)}))).every(Boolean),!(!z&&!r.isValid)&&u()):z=X=await E(i);return o.state.next({...!Ze(I)||l.isValid&&X!==r.isValid?{}:{name:I},...t.resolver||!I?{isValid:X}:{},errors:r.errors,isValidating:!1}),Y.shouldFocus&&!z&&Tr(i,G=>G&&se(r.errors,G),I?U:m.mount),z},q=I=>{const Y={...f,...O.mount?h:{}};return ke(I)?Y:Ze(I)?se(Y,I):I.map(X=>se(Y,X))},R=(I,Y)=>({invalid:!!se((Y||r).errors,I),isDirty:!!se((Y||r).dirtyFields,I),isTouched:!!se((Y||r).touchedFields,I),error:se((Y||r).errors,I)}),j=I=>{I&&Ft(I).forEach(Y=>De(r.errors,Y)),o.state.next({errors:I?r.errors:{}})},B=(I,Y,X)=>{const z=(se(i,I,{_f:{}})._f||{}).ref;Oe(r.errors,I,{...Y,ref:z}),o.state.next({name:I,errors:r.errors,isValid:!1}),X&&X.shouldFocus&&z&&z.focus&&z.focus()},V=(I,Y)=>Je(I)?o.values.subscribe({next:X=>I(P(void 0,Y),X)}):P(I,Y,!0),L=(I,Y={})=>{for(const X of I?Ft(I):m.mount)m.mount.delete(X),m.array.delete(X),Y.keepValue||(De(i,X),De(h,X)),!Y.keepError&&De(r.errors,X),!Y.keepDirty&&De(r.dirtyFields,X),!Y.keepTouched&&De(r.touchedFields,X),!t.shouldUnregister&&!Y.keepDefaultValue&&De(f,X);o.values.next({values:{...h}}),o.state.next({...r,...Y.keepDirty?{isDirty:S()}:{}}),!Y.keepIsValid&&u()},$=(I,Y={})=>{let X=se(i,I);const z=pt(Y.disabled);return Oe(i,I,{...X||{},_f:{...X&&X._f?X._f:{ref:{name:I}},name:I,mount:!0,...Y}}),m.mount.add(I),X?z&&Oe(h,I,Y.disabled?void 0:se(h,I,ur(X._f))):T(I,!0,Y.value),{...z?{disabled:Y.disabled}:{},...t.shouldUseNativeValidation?{required:!!Y.required,min:Ot(Y.min),max:Ot(Y.max),minLength:Ot(Y.minLength),maxLength:Ot(Y.maxLength),pattern:Ot(Y.pattern)}:{},name:I,onChange:C,onBlur:C,ref:U=>{if(U){$(I,Y),X=se(i,I);const G=ke(U.value)&&U.querySelectorAll&&U.querySelectorAll("input,select,textarea")[0]||U,te=fg(G),ee=X._f.refs||[];if(te?ee.find(ue=>ue===G):G===X._f.ref)return;Oe(i,I,{_f:{...X._f,...te?{refs:[...ee.filter(lr),G,...Array.isArray(se(f,I))?[{}]:[]],ref:{type:G.type,name:I}}:{ref:G}}}),T(I,!1,void 0,G)}else X=se(i,I,{}),X._f&&(X._f.mount=!1),(t.shouldUnregister||Y.shouldUnregister)&&!(Xi(m.array,I)&&O.action)&&m.unMount.add(I)}}},Z=()=>t.shouldFocusError&&Tr(i,I=>I&&se(r.errors,I),m.mount),W=(I,Y)=>async X=>{X&&(X.preventDefault&&X.preventDefault(),X.persist&&X.persist());let z=Xe(h);if(o.state.next({isSubmitting:!0}),t.resolver){const{errors:U,values:G}=await N();r.errors=U,z=G}else await E(i);De(r.errors,"root"),Ve(r.errors)?(o.state.next({errors:{}}),await I(z,X)):(Y&&await Y({...r.errors},X),Z(),setTimeout(Z)),o.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Ve(r.errors),submitCount:r.submitCount+1,errors:r.errors})},J=(I,Y={})=>{se(i,I)&&(ke(Y.defaultValue)?Q(I,se(f,I)):(Q(I,Y.defaultValue),Oe(f,I,Y.defaultValue)),Y.keepTouched||De(r.touchedFields,I),Y.keepDirty||(De(r.dirtyFields,I),r.isDirty=Y.defaultValue?S(I,se(f,I)):S()),Y.keepError||(De(r.errors,I),l.isValid&&u()),o.state.next({...r}))},le=(I,Y={})=>{const X=I||f,z=Xe(X),U=I&&!Ve(I)?z:f;if(Y.keepDefaultValues||(f=X),!Y.keepValues){if(Y.keepDirtyValues||a)for(const G of m.mount)se(r.dirtyFields,G)?Oe(U,G,se(h,G)):Q(G,se(U,G));else{if(Cr&&ke(I))for(const G of m.mount){const te=se(i,G);if(te&&te._f){const ee=Array.isArray(te._f.refs)?te._f.refs[0]:te._f.ref;if(Ut(ee)){const ue=ee.closest("form");if(ue){ue.reset();break}}}}i={}}h=e.shouldUnregister?Y.keepDefaultValues?Xe(f):{}:z,o.array.next({values:{...U}}),o.values.next({values:{...U}})}m={mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},!O.mount&&n(),O.mount=!l.isValid||!!Y.keepIsValid,O.watch=!!e.shouldUnregister,o.state.next({submitCount:Y.keepSubmitCount?r.submitCount:0,isDirty:Y.keepDirty?r.isDirty:!!(Y.keepDefaultValues&&!ot(I,f)),isSubmitted:Y.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:Y.keepDirtyValues?r.dirtyFields:Y.keepDefaultValues&&I?sr(f,I):{},touchedFields:Y.keepTouched?r.touchedFields:{},errors:Y.keepErrors?r.errors:{},isSubmitting:!1,isSubmitSuccessful:!1})},de=(I,Y)=>le(Je(I)?I(h):I,Y),pe=(I,Y={})=>{const X=se(i,I),z=X&&X._f;if(z){const U=z.refs?z.refs[0]:z.ref;U.focus&&(U.focus(),Y.shouldSelect&&U.select())}},ve=I=>{r={...r,...I}};return Je(t.defaultValues)&&t.defaultValues().then(I=>{de(I,t.resetOptions),o.state.next({isLoading:!1})}),{control:{register:$,unregister:L,getFieldState:R,_executeSchema:N,_getWatch:P,_getDirty:S,_updateValid:u,_removeUnmounted:w,_updateFieldArray:s,_getFieldArray:F,_reset:le,_updateFormState:ve,_subjects:o,_proxyFormState:l,get _fields(){return i},get _formValues(){return h},get _state(){return O},set _state(I){O=I},get _defaultValues(){return f},get _names(){return m},set _names(I){m=I},get _formState(){return r},set _formState(I){r=I},get _options(){return t},set _options(I){t={...t,...I}}},trigger:D,register:$,handleSubmit:W,watch:V,setValue:Q,getValues:q,reset:de,resetField:J,clearErrors:j,unregister:L,setError:B,setFocus:pe,getFieldState:R}}function $g(e={}){const n=Se.useRef(),[t,r]=Se.useState({isDirty:!1,isValidating:!1,isLoading:Je(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},errors:{},defaultValues:Je(e.defaultValues)?void 0:e.defaultValues});n.current||(n.current={...yg(e,()=>r(f=>({...f}))),formState:t});const i=n.current.control;return i._options=e,Mr({subject:i._subjects.state,next:f=>{eo(f,i._proxyFormState,i._updateFormState,!0)&&r({...i._formState})}}),Se.useEffect(()=>{e.values&&!ot(e.values,i._defaultValues)&&i._reset(e.values,i._options.resetOptions)},[e.values,i]),Se.useEffect(()=>{i._state.mount||(i._updateValid(),i._state.mount=!0),i._state.watch&&(i._state.watch=!1,i._subjects.state.next({...i._formState})),i._removeUnmounted()}),n.current.formState=Ji(t,i),n.current}var Vn=function(e,n,t){if(e&&"reportValidity"in e){var r=se(t,n);e.setCustomValidity(r&&r.message||""),e.reportValidity()}},co=function(e,n){var t=function(i){var f=n.fields[i];f&&f.ref&&"reportValidity"in f.ref?Vn(f.ref,i,e):f.refs&&f.refs.forEach(function(h){return Vn(h,i,e)})};for(var r in n.fields)t(r)},gg=function(e,n){n.shouldUseNativeValidation&&co(e,n);var t={};for(var r in e){var i=se(n.fields,r);Oe(t,r,Object.assign(e[r],{ref:i&&i.ref}))}return t},Cg=function(e,n,t){return n===void 0&&(n={}),t===void 0&&(t={}),function(r,i,f){try{return Promise.resolve(function(h,O){try{var m=(n.context,Promise.resolve(e[t.mode==="sync"?"validateSync":"validate"](r,Object.assign({abortEarly:!1},n,{context:i}))).then(function(_){return f.shouldUseNativeValidation&&co({},f),{values:t.rawValues?r:_,errors:{}}}))}catch(_){return O(_)}return m&&m.then?m.then(void 0,O):m}(0,function(h){if(!h.inner)throw h;return{values:{},errors:gg((O=h,m=!f.shouldUseNativeValidation&&f.criteriaMode==="all",(O.inner||[]).reduce(function(_,p){if(_[p.path]||(_[p.path]={message:p.message,type:p.type}),m){var l=_[p.path].types,o=l&&l[p.type];_[p.path]=io(p.path,m,_,p.type,o?[].concat(o,p.message):p.message)}return _},{})),f)};var O,m}))}catch(h){return Promise.reject(h)}}};(()=>{var e={296:(i,f,h)=>{var O=/^\s+|\s+$/g,m=/^[-+]0x[0-9a-f]+$/i,_=/^0b[01]+$/i,p=/^0o[0-7]+$/i,l=parseInt,o=typeof h.g=="object"&&h.g&&h.g.Object===Object&&h.g,a=typeof self=="object"&&self&&self.Object===Object&&self,y=o||a||Function("return this")(),d=Object.prototype.toString,v=Math.max,c=Math.min,u=function(){return y.Date.now()};function b(g){var T=typeof g;return!!g&&(T=="object"||T=="function")}function s(g){if(typeof g=="number")return g;if(function(k){return typeof k=="symbol"||function(N){return!!N&&typeof N=="object"}(k)&&d.call(k)=="[object Symbol]"}(g))return NaN;if(b(g)){var T=typeof g.valueOf=="function"?g.valueOf():g;g=b(T)?T+"":T}if(typeof g!="string")return g===0?g:+g;g=g.replace(O,"");var A=_.test(g);return A||p.test(g)?l(g.slice(2),A?2:8):m.test(g)?NaN:+g}i.exports=function(g,T,A){var k,N,x,E,w,S,P=0,F=!1,M=!1,H=!0;if(typeof g!="function")throw new TypeError("Expected a function");function Q(B){var V=k,L=N;return k=N=void 0,P=B,E=g.apply(L,V)}function C(B){return P=B,w=setTimeout(q,T),F?Q(B):E}function D(B){var V=B-S;return S===void 0||V>=T||V<0||M&&B-P>=x}function q(){var B=u();if(D(B))return R(B);w=setTimeout(q,function(V){var L=T-(V-S);return M?c(L,x-(V-P)):L}(B))}function R(B){return w=void 0,H&&k?Q(B):(k=N=void 0,E)}function j(){var B=u(),V=D(B);if(k=arguments,N=this,S=B,V){if(w===void 0)return C(S);if(M)return w=setTimeout(q,T),Q(S)}return w===void 0&&(w=setTimeout(q,T)),E}return T=s(T)||0,b(A)&&(F=!!A.leading,x=(M="maxWait"in A)?v(s(A.maxWait)||0,T):x,H="trailing"in A?!!A.trailing:H),j.cancel=function(){w!==void 0&&clearTimeout(w),P=0,k=S=N=w=void 0},j.flush=function(){return w===void 0?E:R(u())},j}},96:(i,f,h)=>{var O="Expected a function",m=/^\s+|\s+$/g,_=/^[-+]0x[0-9a-f]+$/i,p=/^0b[01]+$/i,l=/^0o[0-7]+$/i,o=parseInt,a=typeof h.g=="object"&&h.g&&h.g.Object===Object&&h.g,y=typeof self=="object"&&self&&self.Object===Object&&self,d=a||y||Function("return this")(),v=Object.prototype.toString,c=Math.max,u=Math.min,b=function(){return d.Date.now()};function s(T){var A=typeof T;return!!T&&(A=="object"||A=="function")}function g(T){if(typeof T=="number")return T;if(function(N){return typeof N=="symbol"||function(x){return!!x&&typeof x=="object"}(N)&&v.call(N)=="[object Symbol]"}(T))return NaN;if(s(T)){var A=typeof T.valueOf=="function"?T.valueOf():T;T=s(A)?A+"":A}if(typeof T!="string")return T===0?T:+T;T=T.replace(m,"");var k=p.test(T);return k||l.test(T)?o(T.slice(2),k?2:8):_.test(T)?NaN:+T}i.exports=function(T,A,k){var N=!0,x=!0;if(typeof T!="function")throw new TypeError(O);return s(k)&&(N="leading"in k?!!k.leading:N,x="trailing"in k?!!k.trailing:x),function(E,w,S){var P,F,M,H,Q,C,D=0,q=!1,R=!1,j=!0;if(typeof E!="function")throw new TypeError(O);function B(J){var le=P,de=F;return P=F=void 0,D=J,H=E.apply(de,le)}function V(J){return D=J,Q=setTimeout($,w),q?B(J):H}function L(J){var le=J-C;return C===void 0||le>=w||le<0||R&&J-D>=M}function $(){var J=b();if(L(J))return Z(J);Q=setTimeout($,function(le){var de=w-(le-C);return R?u(de,M-(le-D)):de}(J))}function Z(J){return Q=void 0,j&&P?B(J):(P=F=void 0,H)}function W(){var J=b(),le=L(J);if(P=arguments,F=this,C=J,le){if(Q===void 0)return V(C);if(R)return Q=setTimeout($,w),B(C)}return Q===void 0&&(Q=setTimeout($,w)),H}return w=g(w)||0,s(S)&&(q=!!S.leading,M=(R="maxWait"in S)?c(g(S.maxWait)||0,w):M,j="trailing"in S?!!S.trailing:j),W.cancel=function(){Q!==void 0&&clearTimeout(Q),D=0,P=C=F=Q=void 0},W.flush=function(){return Q===void 0?H:Z(b())},W}(T,A,{leading:N,maxWait:A,trailing:x})}},703:(i,f,h)=>{var O=h(414);function m(){}function _(){}_.resetWarningCache=m,i.exports=function(){function p(a,y,d,v,c,u){if(u!==O){var b=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw b.name="Invariant Violation",b}}function l(){return p}p.isRequired=p;var o={array:p,bool:p,func:p,number:p,object:p,string:p,symbol:p,any:p,arrayOf:l,element:p,elementType:p,instanceOf:l,node:p,objectOf:l,oneOf:l,oneOfType:l,shape:l,exact:l,checkPropTypes:_,resetWarningCache:m};return o.PropTypes=o,o}},697:(i,f,h)=>{i.exports=h(703)()},414:i=>{i.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}},n={};function t(i){var f=n[i];if(f!==void 0)return f.exports;var h=n[i]={exports:{}};return e[i](h,h.exports,t),h.exports}t.n=i=>{var f=i&&i.__esModule?()=>i.default:()=>i;return t.d(f,{a:f}),f},t.d=(i,f)=>{for(var h in f)t.o(f,h)&&!t.o(i,h)&&Object.defineProperty(i,h,{enumerable:!0,get:f[h]})},t.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch{if(typeof window=="object")return window}}(),t.o=(i,f)=>Object.prototype.hasOwnProperty.call(i,f),t.r=i=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(i,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(i,"__esModule",{value:!0})};var r={};(()=>{t.r(r),t.d(r,{LazyLoadComponent:()=>Y,LazyLoadImage:()=>_e,trackWindowScroll:()=>q});const i=Kn.exports;var f=t.n(i),h=t(697);const O=Gn.exports;var m=t.n(O);function _(){return typeof window<"u"&&"IntersectionObserver"in window&&"isIntersecting"in window.IntersectionObserverEntry.prototype}function p(ne){return(p=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(K){return typeof K}:function(K){return K&&typeof Symbol=="function"&&K.constructor===Symbol&&K!==Symbol.prototype?"symbol":typeof K})(ne)}function l(ne,K){var oe=Object.keys(ne);if(Object.getOwnPropertySymbols){var ae=Object.getOwnPropertySymbols(ne);K&&(ae=ae.filter(function(Le){return Object.getOwnPropertyDescriptor(ne,Le).enumerable})),oe.push.apply(oe,ae)}return oe}function o(ne,K,oe){return K in ne?Object.defineProperty(ne,K,{value:oe,enumerable:!0,configurable:!0,writable:!0}):ne[K]=oe,ne}function a(ne,K){for(var oe=0;oe"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var re,ie=v(ae);if(Le){var fe=v(this).constructor;re=Reflect.construct(ie,arguments,fe)}else re=ie.apply(this,arguments);return d(this,re)});function we(re){var ie;if(function(ce,me){if(!(ce instanceof me))throw new TypeError("Cannot call a class as a function")}(this,we),(ie=Ge.call(this,re)).supportsObserver=!re.scrollPosition&&re.useIntersectionObserver&&_(),ie.supportsObserver){var fe=re.threshold;ie.observer=function(ce){return u[ce]=u[ce]||new IntersectionObserver(c,{rootMargin:ce+"px"}),u[ce]}(fe)}return ie}return K=we,(oe=[{key:"componentDidMount",value:function(){this.placeholder&&this.observer&&(this.placeholder.onVisible=this.props.onVisible,this.observer.observe(this.placeholder)),this.supportsObserver||this.updateVisibility()}},{key:"componentWillUnmount",value:function(){this.observer&&this.placeholder&&this.observer.unobserve(this.placeholder)}},{key:"componentDidUpdate",value:function(){this.supportsObserver||this.updateVisibility()}},{key:"getPlaceholderBoundingBox",value:function(){var re=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.props.scrollPosition,ie=this.placeholder.getBoundingClientRect(),fe=m().findDOMNode(this.placeholder).style,ce={left:parseInt(fe.getPropertyValue("margin-left"),10)||0,top:parseInt(fe.getPropertyValue("margin-top"),10)||0};return{bottom:re.y+ie.bottom+ce.top,left:re.x+ie.left+ce.left,right:re.x+ie.right+ce.left,top:re.y+ie.top+ce.top}}},{key:"isPlaceholderInViewport",value:function(){if(typeof window>"u"||!this.placeholder)return!1;var re=this.props,ie=re.scrollPosition,fe=re.threshold,ce=this.getPlaceholderBoundingBox(ie),me=ie.y+window.innerHeight,be=ie.x,Ae=ie.x+window.innerWidth,Te=ie.y;return Boolean(Te-fe<=ce.bottom&&me+fe>=ce.top&&be-fe<=ce.right&&Ae+fe>=ce.left)}},{key:"updateVisibility",value:function(){this.isPlaceholderInViewport()&&this.props.onVisible()}},{key:"render",value:function(){var re=this,ie=this.props,fe=ie.className,ce=ie.height,me=ie.placeholder,be=ie.style,Ae=ie.width;if(me&&typeof me.type!="function")return f().cloneElement(me,{ref:function(Ee){return re.placeholder=Ee}});var Te=function(Ee){for(var Fe=1;Fe"u"?0:window.scrollX||window.pageXOffset},D=function(){return typeof window>"u"?0:window.scrollY||window.pageYOffset};const q=function(ne){var K=function(oe){(function(fe,ce){if(typeof ce!="function"&&ce!==null)throw new TypeError("Super expression must either be null or a function");fe.prototype=Object.create(ce&&ce.prototype,{constructor:{value:fe,writable:!0,configurable:!0}}),ce&&F(fe,ce)})(ie,oe);var ae,Le,Ge,we,re=(Ge=ie,we=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var fe,ce=Q(Ge);if(we){var me=Q(this).constructor;fe=Reflect.construct(ce,arguments,me)}else fe=ce.apply(this,arguments);return M(this,fe)});function ie(fe){var ce;if(function(be,Ae){if(!(be instanceof Ae))throw new TypeError("Cannot call a class as a function")}(this,ie),(ce=re.call(this,fe)).useIntersectionObserver=fe.useIntersectionObserver&&_(),ce.useIntersectionObserver)return M(ce);var me=ce.onChangeScroll.bind(H(ce));return fe.delayMethod==="debounce"?ce.delayedScroll=T()(me,fe.delayTime):fe.delayMethod==="throttle"&&(ce.delayedScroll=k()(me,fe.delayTime)),ce.state={scrollPosition:{x:C(),y:D()}},ce.baseComponentRef=f().createRef(),ce}return ae=ie,(Le=[{key:"componentDidMount",value:function(){this.addListeners()}},{key:"componentWillUnmount",value:function(){this.removeListeners()}},{key:"componentDidUpdate",value:function(){typeof window>"u"||this.useIntersectionObserver||x(m().findDOMNode(this.baseComponentRef.current))!==this.scrollElement&&(this.removeListeners(),this.addListeners())}},{key:"addListeners",value:function(){typeof window>"u"||this.useIntersectionObserver||(this.scrollElement=x(m().findDOMNode(this.baseComponentRef.current)),this.scrollElement.addEventListener("scroll",this.delayedScroll,{passive:!0}),window.addEventListener("resize",this.delayedScroll,{passive:!0}),this.scrollElement!==window&&window.addEventListener("scroll",this.delayedScroll,{passive:!0}))}},{key:"removeListeners",value:function(){typeof window>"u"||this.useIntersectionObserver||(this.scrollElement.removeEventListener("scroll",this.delayedScroll),window.removeEventListener("resize",this.delayedScroll),this.scrollElement!==window&&window.removeEventListener("scroll",this.delayedScroll))}},{key:"onChangeScroll",value:function(){this.useIntersectionObserver||this.setState({scrollPosition:{x:C(),y:D()}})}},{key:"render",value:function(){var fe=this.props,ce=(fe.delayMethod,fe.delayTime,function(be,Ae){if(be==null)return{};var Te,Ee,Fe=function(je,ut){if(je==null)return{};var rt,Nt,Hr={},zr=Object.keys(je);for(Nt=0;Nt=0||(Hr[rt]=je[rt]);return Hr}(be,Ae);if(Object.getOwnPropertySymbols){var Ne=Object.getOwnPropertySymbols(be);for(Ee=0;Ee=0||Object.prototype.propertyIsEnumerable.call(be,Te)&&(Fe[Te]=be[Te])}return Fe}(fe,w)),me=this.useIntersectionObserver?null:this.state.scrollPosition;return f().createElement(ne,S({forwardRef:this.baseComponentRef,scrollPosition:me},ce))}}])&&P(ae.prototype,Le),ie}(f().Component);return K.propTypes={delayMethod:h.PropTypes.oneOf(["debounce","throttle"]),delayTime:h.PropTypes.number,useIntersectionObserver:h.PropTypes.bool},K.defaultProps={delayMethod:"throttle",delayTime:300,useIntersectionObserver:!0},K};function R(ne){return(R=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(K){return typeof K}:function(K){return K&&typeof Symbol=="function"&&K.constructor===Symbol&&K!==Symbol.prototype?"symbol":typeof K})(ne)}function j(ne,K){for(var oe=0;oe"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var re,ie=L(ae);if(Le){var fe=L(this).constructor;re=Reflect.construct(ie,arguments,fe)}else re=ie.apply(this,arguments);return V(this,re)});function we(re){return function(ie,fe){if(!(ie instanceof fe))throw new TypeError("Cannot call a class as a function")}(this,we),Ge.call(this,re)}return K=we,(oe=[{key:"render",value:function(){return f().createElement(s,this.props)}}])&&j(K.prototype,oe),we}(f().Component);const Z=q($);function W(ne){return(W=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(K){return typeof K}:function(K){return K&&typeof Symbol=="function"&&K.constructor===Symbol&&K!==Symbol.prototype?"symbol":typeof K})(ne)}function J(ne,K){for(var oe=0;oe"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var re,ie=ve(ae);if(Le){var fe=ve(this).constructor;re=Reflect.construct(ie,arguments,fe)}else re=ie.apply(this,arguments);return de(this,re)});function we(re){var ie;(function(Ae,Te){if(!(Ae instanceof Te))throw new TypeError("Cannot call a class as a function")})(this,we),ie=Ge.call(this,re);var fe=re.afterLoad,ce=re.beforeLoad,me=re.scrollPosition,be=re.visibleByDefault;return ie.state={visible:be},be&&(ce(),fe()),ie.onVisible=ie.onVisible.bind(pe(ie)),ie.isScrollTracked=Boolean(me&&Number.isFinite(me.x)&&me.x>=0&&Number.isFinite(me.y)&&me.y>=0),ie}return K=we,(oe=[{key:"componentDidUpdate",value:function(re,ie){ie.visible!==this.state.visible&&this.props.afterLoad()}},{key:"onVisible",value:function(){this.props.beforeLoad(),this.setState({visible:!0})}},{key:"render",value:function(){if(this.state.visible)return this.props.children;var re=this.props,ie=re.className,fe=re.delayMethod,ce=re.delayTime,me=re.height,be=re.placeholder,Ae=re.scrollPosition,Te=re.style,Ee=re.threshold,Fe=re.useIntersectionObserver,Ne=re.width;return this.isScrollTracked||Fe&&_()?f().createElement(s,{className:ie,height:me,onVisible:this.onVisible,placeholder:be,scrollPosition:Ae,style:Te,threshold:Ee,useIntersectionObserver:Fe,width:Ne}):f().createElement(Z,{className:ie,delayMethod:fe,delayTime:ce,height:me,onVisible:this.onVisible,placeholder:be,style:Te,threshold:Ee,width:Ne})}}])&&J(K.prototype,oe),we}(f().Component);I.propTypes={afterLoad:h.PropTypes.func,beforeLoad:h.PropTypes.func,useIntersectionObserver:h.PropTypes.bool,visibleByDefault:h.PropTypes.bool},I.defaultProps={afterLoad:function(){return{}},beforeLoad:function(){return{}},useIntersectionObserver:!0,visibleByDefault:!1};const Y=I;function X(ne){return(X=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(K){return typeof K}:function(K){return K&&typeof Symbol=="function"&&K.constructor===Symbol&&K!==Symbol.prototype?"symbol":typeof K})(ne)}var z=["afterLoad","beforeLoad","delayMethod","delayTime","effect","placeholder","placeholderSrc","scrollPosition","threshold","useIntersectionObserver","visibleByDefault","wrapperClassName","wrapperProps"];function U(ne,K){var oe=Object.keys(ne);if(Object.getOwnPropertySymbols){var ae=Object.getOwnPropertySymbols(ne);K&&(ae=ae.filter(function(Le){return Object.getOwnPropertyDescriptor(ne,Le).enumerable})),oe.push.apply(oe,ae)}return oe}function G(ne){for(var K=1;K"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}(),function(){var re,ie=qe(ae);if(Le){var fe=qe(this).constructor;re=Reflect.construct(ie,arguments,fe)}else re=ie.apply(this,arguments);return ye(this,re)});function we(re){var ie;return function(fe,ce){if(!(fe instanceof ce))throw new TypeError("Cannot call a class as a function")}(this,we),(ie=Ge.call(this,re)).state={loaded:!1},ie}return K=we,(oe=[{key:"onImageLoad",value:function(){var re=this;return this.state.loaded?null:function(){re.props.afterLoad(),re.setState({loaded:!0})}}},{key:"getImg",value:function(){var re=this.props,ie=(re.afterLoad,re.beforeLoad,re.delayMethod,re.delayTime,re.effect,re.placeholder,re.placeholderSrc,re.scrollPosition,re.threshold,re.useIntersectionObserver,re.visibleByDefault,re.wrapperClassName,re.wrapperProps,function(fe,ce){if(fe==null)return{};var me,be,Ae=function(Ee,Fe){if(Ee==null)return{};var Ne,je,ut={},rt=Object.keys(Ee);for(je=0;je=0||(ut[Ne]=Ee[Ne]);return ut}(fe,ce);if(Object.getOwnPropertySymbols){var Te=Object.getOwnPropertySymbols(fe);for(be=0;be=0||Object.prototype.propertyIsEnumerable.call(fe,me)&&(Ae[me]=fe[me])}return Ae}(re,z));return f().createElement("img",ee({onLoad:this.onImageLoad()},ie))}},{key:"getLazyLoadImage",value:function(){var re=this.props,ie=re.beforeLoad,fe=re.className,ce=re.delayMethod,me=re.delayTime,be=re.height,Ae=re.placeholder,Te=re.scrollPosition,Ee=re.style,Fe=re.threshold,Ne=re.useIntersectionObserver,je=re.visibleByDefault,ut=re.width;return f().createElement(Y,{beforeLoad:ie,className:fe,delayMethod:ce,delayTime:me,height:be,placeholder:Ae,scrollPosition:Te,style:Ee,threshold:Fe,useIntersectionObserver:Ne,visibleByDefault:je,width:ut},this.getImg())}},{key:"getWrappedLazyLoadImage",value:function(re){var ie=this.props,fe=ie.effect,ce=ie.height,me=ie.placeholderSrc,be=ie.width,Ae=ie.wrapperClassName,Te=ie.wrapperProps,Ee=this.state.loaded,Fe=Ee?" lazy-load-image-loaded":"",Ne=Ee||!me?{}:{backgroundImage:"url(".concat(me,")"),backgroundSize:"100% 100%"};return f().createElement("span",ee({className:Ae+" lazy-load-image-background "+fe+Fe,style:G(G({},Ne),{},{color:"transparent",display:"inline-block",height:ce,width:be})},Te),re)}},{key:"render",value:function(){var re=this.props,ie=re.effect,fe=re.placeholderSrc,ce=re.visibleByDefault,me=re.wrapperClassName,be=re.wrapperProps,Ae=this.getLazyLoadImage();return(ie||fe)&&!ce||me||be?this.getWrappedLazyLoadImage(Ae):Ae}}])&&ue(K.prototype,oe),we}(f().Component);Re.propTypes={afterLoad:h.PropTypes.func,beforeLoad:h.PropTypes.func,delayMethod:h.PropTypes.string,delayTime:h.PropTypes.number,effect:h.PropTypes.string,placeholderSrc:h.PropTypes.string,threshold:h.PropTypes.number,useIntersectionObserver:h.PropTypes.bool,visibleByDefault:h.PropTypes.bool,wrapperClassName:h.PropTypes.string,wrapperProps:h.PropTypes.object},Re.defaultProps={afterLoad:function(){return{}},beforeLoad:function(){return{}},delayMethod:"throttle",delayTime:300,effect:"",placeholderSrc:null,threshold:100,useIntersectionObserver:!0,visibleByDefault:!1,wrapperClassName:""};const _e=Re})()})();at("div")(({theme:e})=>({width:144,height:144,margin:"auto",borderRadius:"50%",padding:e.spacing(1),border:`1px dashed ${e.palette.grey[50032]}`}));at("div")({zIndex:0,width:"100%",height:"100%",outline:"none",display:"flex",overflow:"hidden",borderRadius:"50%",position:"relative",alignItems:"center",justifyContent:"center","& > *":{width:"100%",height:"100%"},"&:hover":{cursor:"pointer","& .placeholder":{zIndex:9}}});at("div")(({theme:e})=>({display:"flex",position:"absolute",alignItems:"center",flexDirection:"column",justifyContent:"center",color:e.palette.text.secondary,backgroundColor:e.palette.background.neutral,transition:e.transitions.create("opacity",{easing:e.transitions.easing.easeInOut,duration:e.transitions.duration.shorter}),"&:hover":{opacity:.72}}));at("div")(({theme:e})=>({outline:"none",padding:e.spacing(5,1),borderRadius:e.shape.borderRadius,backgroundColor:e.palette.background.neutral,border:`1px dashed ${e.palette.grey[50032]}`,"&:hover":{opacity:.72,cursor:"pointer"}}));at("div")(({theme:e})=>({outline:"none",overflow:"hidden",position:"relative",padding:e.spacing(5,1),borderRadius:e.shape.borderRadius,transition:e.transitions.create("padding"),backgroundColor:e.palette.background.neutral,border:`1px dashed ${e.palette.grey[50032]}`,"&:hover":{opacity:.72,cursor:"pointer"}}));function Mg({children:e,onSubmit:n,methods:t,encType:r}){return ge(rg,{...t,children:ge("form",{onSubmit:n,encType:r,children:e})})}var mg=Dr;function bg(e,n){return mg(e,n)}var _g=bg,ho={exports:{}};/*! * Quill Editor v1.3.7 * https://quilljs.com/ * Copyright (c) 2014, Jason Chen * Copyright (c) 2013, salesforce.com */(function(e,n){(function(r,i){e.exports=i()})(typeof self<"u"?self:Me,function(){return function(t){var r={};function i(f){if(r[f])return r[f].exports;var h=r[f]={i:f,l:!1,exports:{}};return t[f].call(h.exports,h,h.exports,i),h.l=!0,h.exports}return i.m=t,i.c=r,i.d=function(f,h,O){i.o(f,h)||Object.defineProperty(f,h,{configurable:!1,enumerable:!0,get:O})},i.n=function(f){var h=f&&f.__esModule?function(){return f.default}:function(){return f};return i.d(h,"a",h),h},i.o=function(f,h){return Object.prototype.hasOwnProperty.call(f,h)},i.p="",i(i.s=109)}([function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(17),h=i(18),O=i(19),m=i(45),_=i(46),p=i(47),l=i(48),o=i(49),a=i(12),y=i(32),d=i(33),v=i(31),c=i(1),u={Scope:c.Scope,create:c.create,find:c.find,query:c.query,register:c.register,Container:f.default,Format:h.default,Leaf:O.default,Embed:l.default,Scroll:m.default,Block:p.default,Inline:_.default,Text:o.default,Attributor:{Attribute:a.default,Class:y.default,Style:d.default,Store:v.default}};r.default=u},function(t,r,i){var f=this&&this.__extends||function(){var v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,u){c.__proto__=u}||function(c,u){for(var b in u)u.hasOwnProperty(b)&&(c[b]=u[b])};return function(c,u){v(c,u);function b(){this.constructor=c}c.prototype=u===null?Object.create(u):(b.prototype=u.prototype,new b)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=function(v){f(c,v);function c(u){var b=this;return u="[Parchment] "+u,b=v.call(this,u)||this,b.message=u,b.name=b.constructor.name,b}return c}(Error);r.ParchmentError=h;var O={},m={},_={},p={};r.DATA_KEY="__blot";var l;(function(v){v[v.TYPE=3]="TYPE",v[v.LEVEL=12]="LEVEL",v[v.ATTRIBUTE=13]="ATTRIBUTE",v[v.BLOT=14]="BLOT",v[v.INLINE=7]="INLINE",v[v.BLOCK=11]="BLOCK",v[v.BLOCK_BLOT=10]="BLOCK_BLOT",v[v.INLINE_BLOT=6]="INLINE_BLOT",v[v.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",v[v.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",v[v.ANY=15]="ANY"})(l=r.Scope||(r.Scope={}));function o(v,c){var u=y(v);if(u==null)throw new h("Unable to create "+v+" blot");var b=u,s=v instanceof Node||v.nodeType===Node.TEXT_NODE?v:b.create(c);return new b(s,c)}r.create=o;function a(v,c){return c===void 0&&(c=!1),v==null?null:v[r.DATA_KEY]!=null?v[r.DATA_KEY].blot:c?a(v.parentNode,c):null}r.find=a;function y(v,c){c===void 0&&(c=l.ANY);var u;if(typeof v=="string")u=p[v]||O[v];else if(v instanceof Text||v.nodeType===Node.TEXT_NODE)u=p.text;else if(typeof v=="number")v&l.LEVEL&l.BLOCK?u=p.block:v&l.LEVEL&l.INLINE&&(u=p.inline);else if(v instanceof HTMLElement){var b=(v.getAttribute("class")||"").split(/\s+/);for(var s in b)if(u=m[b[s]],u)break;u=u||_[v.tagName]}return u==null?null:c&l.LEVEL&u.scope&&c&l.TYPE&u.scope?u:null}r.query=y;function d(){for(var v=[],c=0;c1)return v.map(function(s){return d(s)});var u=v[0];if(typeof u.blotName!="string"&&typeof u.attrName!="string")throw new h("Invalid definition");if(u.blotName==="abstract")throw new h("Cannot register abstract class");if(p[u.blotName||u.attrName]=u,typeof u.keyName=="string")O[u.keyName]=u;else if(u.className!=null&&(m[u.className]=u),u.tagName!=null){Array.isArray(u.tagName)?u.tagName=u.tagName.map(function(s){return s.toUpperCase()}):u.tagName=u.tagName.toUpperCase();var b=Array.isArray(u.tagName)?u.tagName:[u.tagName];b.forEach(function(s){(_[s]==null||u.className==null)&&(_[s]=u)})}return u}r.register=d},function(t,r,i){var f=i(51),h=i(11),O=i(3),m=i(20),_=String.fromCharCode(0),p=function(l){Array.isArray(l)?this.ops=l:l!=null&&Array.isArray(l.ops)?this.ops=l.ops:this.ops=[]};p.prototype.insert=function(l,o){var a={};return l.length===0?this:(a.insert=l,o!=null&&typeof o=="object"&&Object.keys(o).length>0&&(a.attributes=o),this.push(a))},p.prototype.delete=function(l){return l<=0?this:this.push({delete:l})},p.prototype.retain=function(l,o){if(l<=0)return this;var a={retain:l};return o!=null&&typeof o=="object"&&Object.keys(o).length>0&&(a.attributes=o),this.push(a)},p.prototype.push=function(l){var o=this.ops.length,a=this.ops[o-1];if(l=O(!0,{},l),typeof a=="object"){if(typeof l.delete=="number"&&typeof a.delete=="number")return this.ops[o-1]={delete:a.delete+l.delete},this;if(typeof a.delete=="number"&&l.insert!=null&&(o-=1,a=this.ops[o-1],typeof a!="object"))return this.ops.unshift(l),this;if(h(l.attributes,a.attributes)){if(typeof l.insert=="string"&&typeof a.insert=="string")return this.ops[o-1]={insert:a.insert+l.insert},typeof l.attributes=="object"&&(this.ops[o-1].attributes=l.attributes),this;if(typeof l.retain=="number"&&typeof a.retain=="number")return this.ops[o-1]={retain:a.retain+l.retain},typeof l.attributes=="object"&&(this.ops[o-1].attributes=l.attributes),this}}return o===this.ops.length?this.ops.push(l):this.ops.splice(o,0,l),this},p.prototype.chop=function(){var l=this.ops[this.ops.length-1];return l&&l.retain&&!l.attributes&&this.ops.pop(),this},p.prototype.filter=function(l){return this.ops.filter(l)},p.prototype.forEach=function(l){this.ops.forEach(l)},p.prototype.map=function(l){return this.ops.map(l)},p.prototype.partition=function(l){var o=[],a=[];return this.forEach(function(y){var d=l(y)?o:a;d.push(y)}),[o,a]},p.prototype.reduce=function(l,o){return this.ops.reduce(l,o)},p.prototype.changeLength=function(){return this.reduce(function(l,o){return o.insert?l+m.length(o):o.delete?l-o.delete:l},0)},p.prototype.length=function(){return this.reduce(function(l,o){return l+m.length(o)},0)},p.prototype.slice=function(l,o){l=l||0,typeof o!="number"&&(o=1/0);for(var a=[],y=m.iterator(this.ops),d=0;d0&&a.next(d.retain-v)}for(var c=new p(y);o.hasNext()||a.hasNext();)if(a.peekType()==="insert")c.push(a.next());else if(o.peekType()==="delete")c.push(o.next());else{var u=Math.min(o.peekLength(),a.peekLength()),b=o.next(u),s=a.next(u);if(typeof s.retain=="number"){var g={};typeof b.retain=="number"?g.retain=u:g.insert=b.insert;var T=m.attributes.compose(b.attributes,s.attributes,typeof b.retain=="number");if(T&&(g.attributes=T),c.push(g),!a.hasNext()&&h(c.ops[c.ops.length-1],g)){var A=new p(o.rest());return c.concat(A).chop()}}else typeof s.delete=="number"&&typeof b.retain=="number"&&c.push(s)}return c.chop()},p.prototype.concat=function(l){var o=new p(this.ops.slice());return l.ops.length>0&&(o.push(l.ops[0]),o.ops=o.ops.concat(l.ops.slice(1))),o},p.prototype.diff=function(l,o){if(this.ops===l.ops)return new p;var a=[this,l].map(function(u){return u.map(function(b){if(b.insert!=null)return typeof b.insert=="string"?b.insert:_;var s=u===l?"on":"with";throw new Error("diff() called "+s+" non-document")}).join("")}),y=new p,d=f(a[0],a[1],o),v=m.iterator(this.ops),c=m.iterator(l.ops);return d.forEach(function(u){for(var b=u[1].length;b>0;){var s=0;switch(u[0]){case f.INSERT:s=Math.min(c.peekLength(),b),y.push(c.next(s));break;case f.DELETE:s=Math.min(b,v.peekLength()),v.next(s),y.delete(s);break;case f.EQUAL:s=Math.min(v.peekLength(),c.peekLength(),b);var g=v.next(s),T=c.next(s);h(g.insert,T.insert)?y.retain(s,m.attributes.diff(g.attributes,T.attributes)):y.push(T).delete(s);break}b-=s}}),y.chop()},p.prototype.eachLine=function(l,o){o=o||` `;for(var a=m.iterator(this.ops),y=new p,d=0;a.hasNext();){if(a.peekType()!=="insert")return;var v=a.peek(),c=m.length(v)-a.peekLength(),u=typeof v.insert=="string"?v.insert.indexOf(o,c)-c:-1;if(u<0)y.push(a.next());else if(u>0)y.push(a.next(u));else{if(l(y,a.next(1).attributes||{},d)===!1)return;d+=1,y=new p}}y.length()>0&&l(y,{},d)},p.prototype.transform=function(l,o){if(o=!!o,typeof l=="number")return this.transformPosition(l,o);for(var a=m.iterator(this.ops),y=m.iterator(l.ops),d=new p;a.hasNext()||y.hasNext();)if(a.peekType()==="insert"&&(o||y.peekType()!=="insert"))d.retain(m.length(a.next()));else if(y.peekType()==="insert")d.push(y.next());else{var v=Math.min(a.peekLength(),y.peekLength()),c=a.next(v),u=y.next(v);if(c.delete)continue;u.delete?d.push(u):d.retain(v,m.attributes.transform(c.attributes,u.attributes,o))}return d.chop()},p.prototype.transformPosition=function(l,o){o=!!o;for(var a=m.iterator(this.ops),y=0;a.hasNext()&&y<=l;){var d=a.peekLength(),v=a.peekType();if(a.next(),v==="delete"){l-=Math.min(d,l-y);continue}else v==="insert"&&(y"u"||i.call(a,v)},p=function(a,y){h&&y.name==="__proto__"?h(a,y.name,{enumerable:!0,configurable:!0,value:y.newValue,writable:!0}):a[y.name]=y.newValue},l=function(a,y){if(y==="__proto__")if(i.call(a,y)){if(O)return O(a,y).value}else return;return a[y]};t.exports=function o(){var a,y,d,v,c,u,b=arguments[0],s=1,g=arguments.length,T=!1;for(typeof b=="boolean"&&(T=b,b=arguments[1]||{},s=2),(b==null||typeof b!="object"&&typeof b!="function")&&(b={});s0&&(P1&&arguments[1]!==void 0?arguments[1]:!1;if(F&&(P===0||P>=this.length()-A)){var M=this.clone();return P===0?(this.parent.insertBefore(M,this),this):(this.parent.insertBefore(M,this.next),M)}else{var H=h(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"split",this).call(this,P,F);return this.cache={},H}}}]),w}(o.default.Block);N.blotName="block",N.tagName="P",N.defaultChild="break",N.allowedChildren=[v.default,o.default.Embed,u.default];function x(E){var w=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return E==null||(typeof E.formats=="function"&&(w=(0,m.default)(w,E.formats())),E.parent==null||E.parent.blotName=="scroll"||E.parent.statics.scope!==E.statics.scope)?w:x(E.parent,w)}r.bubbleFormats=x,r.BlockEmbed=k,r.default=N},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.overload=r.expandConfig=void 0;var f=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},h=function(){function C(D,q){var R=[],j=!0,B=!1,V=void 0;try{for(var L=D[Symbol.iterator](),$;!(j=($=L.next()).done)&&(R.push($.value),!(q&&R.length===q));j=!0);}catch(Z){B=!0,V=Z}finally{try{!j&&L.return&&L.return()}finally{if(B)throw V}}return R}return function(D,q){if(Array.isArray(D))return D;if(Symbol.iterator in Object(D))return C(D,q);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function C(D,q){for(var R=0;R2&&arguments[2]!==void 0?arguments[2]:!1;if(typeof q!="string"){var V=q.attrName||q.blotName;typeof V=="string"?this.register("formats/"+V,q,R):Object.keys(q).forEach(function(L){j.register(L,q[L],R)})}else this.imports[q]!=null&&!B&&S.warn("Overwriting "+q+" with",R),this.imports[q]=R,(q.startsWith("blots/")||q.startsWith("formats/"))&&R.blotName!=="abstract"?c.default.register(R):q.startsWith("modules")&&typeof R.register=="function"&&R.register()}}]);function C(D){var q=this,R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(w(this,C),this.options=F(D,R),this.container=this.options.container,this.container==null)return S.error("Invalid Quill container",D);this.options.debug&&C.debug(this.options.debug);var j=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 a.default,this.scroll=c.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new l.default(this.scroll),this.selection=new b.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(a.default.events.EDITOR_CHANGE,function(V){V===a.default.events.TEXT_CHANGE&&q.root.classList.toggle("ql-blank",q.editor.isBlank())}),this.emitter.on(a.default.events.SCROLL_UPDATE,function(V,L){var $=q.selection.lastRange,Z=$&&$.length===0?$.index:void 0;M.call(q,function(){return q.editor.update(null,L,Z)},V)});var B=this.clipboard.convert(`
`+j+"


");this.setContents(B),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return O(C,[{key:"addContainer",value:function(q){var R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(typeof q=="string"){var j=q;q=document.createElement("div"),q.classList.add(j)}return this.container.insertBefore(q,R),q}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(q,R,j){var B=this,V=H(q,R,j),L=h(V,4);return q=L[0],R=L[1],j=L[3],M.call(this,function(){return B.editor.deleteText(q,R)},j,q,-1*R)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.scroll.enable(q),this.container.classList.toggle("ql-disabled",!q)}},{key:"focus",value:function(){var q=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=q,this.scrollIntoView()}},{key:"format",value:function(q,R){var j=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:a.default.sources.API;return M.call(this,function(){var V=j.getSelection(!0),L=new _.default;if(V==null)return L;if(c.default.query(q,c.default.Scope.BLOCK))L=j.editor.formatLine(V.index,V.length,E({},q,R));else{if(V.length===0)return j.selection.format(q,R),L;L=j.editor.formatText(V.index,V.length,E({},q,R))}return j.setSelection(V,a.default.sources.SILENT),L},B)}},{key:"formatLine",value:function(q,R,j,B,V){var L=this,$=void 0,Z=H(q,R,j,B,V),W=h(Z,4);return q=W[0],R=W[1],$=W[2],V=W[3],M.call(this,function(){return L.editor.formatLine(q,R,$)},V,q,0)}},{key:"formatText",value:function(q,R,j,B,V){var L=this,$=void 0,Z=H(q,R,j,B,V),W=h(Z,4);return q=W[0],R=W[1],$=W[2],V=W[3],M.call(this,function(){return L.editor.formatText(q,R,$)},V,q,0)}},{key:"getBounds",value:function(q){var R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,j=void 0;typeof q=="number"?j=this.selection.getBounds(q,R):j=this.selection.getBounds(q.index,q.length);var B=this.container.getBoundingClientRect();return{bottom:j.bottom-B.top,height:j.height,left:j.left-B.left,right:j.right-B.left,top:j.top-B.top,width:j.width}}},{key:"getContents",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-q,j=H(q,R),B=h(j,2);return q=B[0],R=B[1],this.editor.getContents(q,R)}},{key:"getFormat",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.getSelection(!0),R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return typeof q=="number"?this.editor.getFormat(q,R):this.editor.getFormat(q.index,q.length)}},{key:"getIndex",value:function(q){return q.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(q){return this.scroll.leaf(q)}},{key:"getLine",value:function(q){return this.scroll.line(q)}},{key:"getLines",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;return typeof q!="number"?this.scroll.lines(q.index,q.length):this.scroll.lines(q,R)}},{key:"getModule",value:function(q){return this.theme.modules[q]}},{key:"getSelection",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return q&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-q,j=H(q,R),B=h(j,2);return q=B[0],R=B[1],this.editor.getText(q,R)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(q,R,j){var B=this,V=arguments.length>3&&arguments[3]!==void 0?arguments[3]:C.sources.API;return M.call(this,function(){return B.editor.insertEmbed(q,R,j)},V,q)}},{key:"insertText",value:function(q,R,j,B,V){var L=this,$=void 0,Z=H(q,0,j,B,V),W=h(Z,4);return q=W[0],$=W[2],V=W[3],M.call(this,function(){return L.editor.insertText(q,R,$)},V,q,R.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(q,R,j){this.clipboard.dangerouslyPasteHTML(q,R,j)}},{key:"removeFormat",value:function(q,R,j){var B=this,V=H(q,R,j),L=h(V,4);return q=L[0],R=L[1],j=L[3],M.call(this,function(){return B.editor.removeFormat(q,R)},j,q)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(q){var R=this,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:a.default.sources.API;return M.call(this,function(){q=new _.default(q);var B=R.getLength(),V=R.editor.deleteText(0,B),L=R.editor.applyDelta(q),$=L.ops[L.ops.length-1];$!=null&&typeof $.insert=="string"&&$.insert[$.insert.length-1]===` `&&(R.editor.deleteText(R.getLength()-1,1),L.delete(1));var Z=V.compose(L);return Z},j)}},{key:"setSelection",value:function(q,R,j){if(q==null)this.selection.setRange(null,R||C.sources.API);else{var B=H(q,R,j),V=h(B,4);q=V[0],R=V[1],j=V[3],this.selection.setRange(new u.Range(q,R),j),j!==a.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(q){var R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:a.default.sources.API,j=new _.default().insert(q);return this.setContents(j,R)}},{key:"update",value:function(){var q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:a.default.sources.USER,R=this.scroll.update(q);return this.selection.update(q),R}},{key:"updateContents",value:function(q){var R=this,j=arguments.length>1&&arguments[1]!==void 0?arguments[1]:a.default.sources.API;return M.call(this,function(){return q=new _.default(q),R.editor.applyDelta(q,j)},j,!0)}}]),C}();P.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},P.events=a.default.events,P.sources=a.default.sources,P.version="1.3.7",P.imports={delta:_.default,parchment:c.default,"core/module":d.default,"core/theme":N.default};function F(C,D){if(D=(0,g.default)(!0,{container:C,modules:{clipboard:!0,keyboard:!0,history:!0}},D),!D.theme||D.theme===P.DEFAULTS.theme)D.theme=N.default;else if(D.theme=P.import("themes/"+D.theme),D.theme==null)throw new Error("Invalid theme "+D.theme+". Did you register it?");var q=(0,g.default)(!0,{},D.theme.DEFAULTS);[q,D].forEach(function(B){B.modules=B.modules||{},Object.keys(B.modules).forEach(function(V){B.modules[V]===!0&&(B.modules[V]={})})});var R=Object.keys(q.modules).concat(Object.keys(D.modules)),j=R.reduce(function(B,V){var L=P.import("modules/"+V);return L==null?S.error("Cannot load "+V+" module. Are you sure you registered it?"):B[V]=L.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,{},P.DEFAULTS,{modules:j},q,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,V){return D.modules[V]&&(B[V]=D.modules[V]),B},{}),D}function M(C,D,q,R){if(this.options.strict&&!this.isEnabled()&&D===a.default.sources.USER)return new _.default;var j=q==null?null:this.getSelection(),B=this.editor.delta,V=C();if(j!=null&&(q===!0&&(q=j.index),R==null?j=Q(j,V,D):R!==0&&(j=Q(j,q,R,D)),this.setSelection(j,a.default.sources.SILENT)),V.length()>0){var L,$=[a.default.events.TEXT_CHANGE,V,B,D];if((L=this.emitter).emit.apply(L,[a.default.events.EDITOR_CHANGE].concat($)),D!==a.default.sources.SILENT){var Z;(Z=this.emitter).emit.apply(Z,$)}}return V}function H(C,D,q,R,j){var B={};return typeof C.index=="number"&&typeof C.length=="number"?typeof D!="number"?(j=R,R=q,q=D,D=C.length,C=C.index):(D=C.length,C=C.index):typeof D!="number"&&(j=R,R=q,q=D,D=0),(typeof q>"u"?"undefined":f(q))==="object"?(B=q,j=R):typeof q=="string"&&(R!=null?B[q]=R:j=q),j=j||a.default.sources.API,[C,D,B,j]}function Q(C,D,q,R){if(C==null)return null;var j=void 0,B=void 0;if(D instanceof _.default){var V=[C.index,C.index+C.length].map(function(W){return D.transformPosition(W,R!==a.default.sources.USER)}),L=h(V,2);j=L[0],B=L[1]}else{var $=[C.index,C.index+C.length].map(function(W){return W=0?W+q:Math.max(D,W+q)}),Z=h($,2);j=Z[0],B=Z[1]}return new u.Range(j,B-j)}r.expandConfig=F,r.overload=H,r.default=P},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function v(c,u){for(var b=0;b0){var s=this.parent.isolate(this.offset(),this.length());this.moveChildren(s),s.wrap(this)}}}],[{key:"compare",value:function(b,s){var g=c.order.indexOf(b),T=c.order.indexOf(s);return g>=0||T>=0?g-T:b===s?0:b1?T-1:0),k=1;k1&&arguments[1]!==void 0?arguments[1]:{};f(this,O),this.quill=m,this.options=_};h.DEFAULTS={},r.default=h},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=["error","warn","log","info"],h="warn";function O(_){if(f.indexOf(_)<=f.indexOf(h)){for(var p,l=arguments.length,o=Array(l>1?l-1:0),a=1;a0&&typeof o[0]!="number")}function l(o,a,y){var d,v;if(_(o)||_(a)||o.prototype!==a.prototype)return!1;if(O(o))return O(a)?(o=f.call(o),a=f.call(a),m(o,a,y)):!1;if(p(o)){if(!p(a)||o.length!==a.length)return!1;for(d=0;d=0;d--)if(c[d]!=u[d])return!1;for(d=c.length-1;d>=0;d--)if(v=c[d],!m(o[v],a[v],y))return!1;return typeof o==typeof a}},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(1),h=function(){function O(m,_,p){p===void 0&&(p={}),this.attrName=m,this.keyName=_;var l=f.Scope.TYPE&f.Scope.ATTRIBUTE;p.scope!=null?this.scope=p.scope&f.Scope.LEVEL|l:this.scope=f.Scope.ATTRIBUTE,p.whitelist!=null&&(this.whitelist=p.whitelist)}return O.keys=function(m){return[].map.call(m.attributes,function(_){return _.name})},O.prototype.add=function(m,_){return this.canAdd(m,_)?(m.setAttribute(this.keyName,_),!0):!1},O.prototype.canAdd=function(m,_){var p=f.query(m,f.Scope.BLOT&(this.scope|f.Scope.TYPE));return p==null?!1:this.whitelist==null?!0:typeof _=="string"?this.whitelist.indexOf(_.replace(/["']/g,""))>-1:this.whitelist.indexOf(_)>-1},O.prototype.remove=function(m){m.removeAttribute(this.keyName)},O.prototype.value=function(m){var _=m.getAttribute(this.keyName);return this.canAdd(m,_)&&_?_:""},O}();r.default=h},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.Code=void 0;var f=function(){function k(N,x){var E=[],w=!0,S=!1,P=void 0;try{for(var F=N[Symbol.iterator](),M;!(w=(M=F.next()).done)&&(E.push(M.value),!(x&&E.length===x));w=!0);}catch(H){S=!0,P=H}finally{try{!w&&F.return&&F.return()}finally{if(S)throw P}}return E}return function(N,x){if(Array.isArray(N))return N;if(Symbol.iterator in Object(N))return k(N,x);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(){function k(N,x){for(var E=0;E=E+w)){var M=this.newlineIndex(E,!0)+1,H=F-M+1,Q=this.isolate(M,H),C=Q.next;Q.format(S,P),C instanceof N&&C.formatAt(0,E-M+w-H,S,P)}}}},{key:"insertAt",value:function(E,w,S){if(S==null){var P=this.descendant(c.default,E),F=f(P,2),M=F[0],H=F[1];M.insertAt(H,w)}}},{key:"length",value:function(){var E=this.domNode.textContent.length;return this.domNode.textContent.endsWith(` `)?E:E+1}},{key:"newlineIndex",value:function(E){var w=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(w)return this.domNode.textContent.slice(0,E).lastIndexOf(` `);var S=this.domNode.textContent.slice(E).indexOf(` `);return S>-1?E+S:-1}},{key:"optimize",value:function(E){this.domNode.textContent.endsWith(` `)||this.appendChild(l.default.create("text",` `)),O(N.prototype.__proto__||Object.getPrototypeOf(N.prototype),"optimize",this).call(this,E);var w=this.next;w!=null&&w.prev===this&&w.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===w.statics.formats(w.domNode)&&(w.optimize(E),w.moveChildren(this),w.remove())}},{key:"replace",value:function(E){O(N.prototype.__proto__||Object.getPrototypeOf(N.prototype),"replace",this).call(this,E),[].slice.call(this.domNode.querySelectorAll("*")).forEach(function(w){var S=l.default.find(w);S==null?w.parentNode.removeChild(w):S instanceof l.default.Embed?S.remove():S.unwrap()})}}],[{key:"create",value:function(E){var w=O(N.__proto__||Object.getPrototypeOf(N),"create",this).call(this,E);return w.setAttribute("spellcheck",!1),w}},{key:"formats",value:function(){return!0}}]),N}(a.default);A.blotName="code-block",A.tagName="PRE",A.TAB=" ",r.Code=T,r.default=A},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=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},h=function(){function C(D,q){var R=[],j=!0,B=!1,V=void 0;try{for(var L=D[Symbol.iterator](),$;!(j=($=L.next()).done)&&(R.push($.value),!(q&&R.length===q));j=!0);}catch(Z){B=!0,V=Z}finally{try{!j&&L.return&&L.return()}finally{if(B)throw V}}return R}return function(D,q){if(Array.isArray(D))return D;if(Symbol.iterator in Object(D))return C(D,q);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function C(D,q){for(var R=0;R=B&&!W.endsWith(` `)&&(j=!0),R.scroll.insertAt(V,W);var J=R.scroll.line(V),le=h(J,2),de=le[0],pe=le[1],ve=(0,E.default)({},(0,u.bubbleFormats)(de));if(de instanceof b.default){var I=de.descendant(a.default.Leaf,pe),Y=h(I,1),X=Y[0];ve=(0,E.default)(ve,(0,u.bubbleFormats)(X))}Z=l.default.attributes.diff(ve,Z)||{}}else if(f(L.insert)==="object"){var z=Object.keys(L.insert)[0];if(z==null)return V;R.scroll.insertAt(V,z,L.insert[z])}B+=$}return Object.keys(Z).forEach(function(U){R.scroll.formatAt(V,$,U,Z[U])}),V+$},0),q.reduce(function(V,L){return typeof L.delete=="number"?(R.scroll.deleteAt(V,L.delete),V):V+(L.retain||L.insert.length||1)},0),this.scroll.batchEnd(),this.update(q)}},{key:"deleteText",value:function(q,R){return this.scroll.deleteAt(q,R),this.update(new _.default().retain(q).delete(R))}},{key:"formatLine",value:function(q,R){var j=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.scroll.update(),Object.keys(B).forEach(function(V){if(!(j.scroll.whitelist!=null&&!j.scroll.whitelist[V])){var L=j.scroll.lines(q,Math.max(R,1)),$=R;L.forEach(function(Z){var W=Z.length();if(!(Z instanceof d.default))Z.format(V,B[V]);else{var J=q-Z.offset(j.scroll),le=Z.newlineIndex(J+$)-J+1;Z.formatAt(J,le,V,B[V])}$-=W})}}),this.scroll.optimize(),this.update(new _.default().retain(q).retain(R,(0,A.default)(B)))}},{key:"formatText",value:function(q,R){var j=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Object.keys(B).forEach(function(V){j.scroll.formatAt(q,R,V,B[V])}),this.update(new _.default().retain(q).retain(R,(0,A.default)(B)))}},{key:"getContents",value:function(q,R){return this.delta.slice(q,q+R)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce(function(q,R){return q.concat(R.delta())},new _.default)}},{key:"getFormat",value:function(q){var R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,j=[],B=[];R===0?this.scroll.path(q).forEach(function(L){var $=h(L,1),Z=$[0];Z instanceof b.default?j.push(Z):Z instanceof a.default.Leaf&&B.push(Z)}):(j=this.scroll.lines(q,R),B=this.scroll.descendants(a.default.Leaf,q,R));var V=[j,B].map(function(L){if(L.length===0)return{};for(var $=(0,u.bubbleFormats)(L.shift());Object.keys($).length>0;){var Z=L.shift();if(Z==null)return $;$=H((0,u.bubbleFormats)(Z),$)}return $});return E.default.apply(E.default,V)}},{key:"getText",value:function(q,R){return this.getContents(q,R).filter(function(j){return typeof j.insert=="string"}).map(function(j){return j.insert}).join("")}},{key:"insertEmbed",value:function(q,R,j){return this.scroll.insertAt(q,R,j),this.update(new _.default().retain(q).insert(S({},R,j)))}},{key:"insertText",value:function(q,R){var j=this,B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return R=R.replace(/\r\n/g,` `).replace(/\r/g,` `),this.scroll.insertAt(q,R),Object.keys(B).forEach(function(V){j.scroll.formatAt(q,R.length,V,B[V])}),this.update(new _.default().retain(q).insert(R,(0,A.default)(B)))}},{key:"isBlank",value:function(){if(this.scroll.children.length==0)return!0;if(this.scroll.children.length>1)return!1;var q=this.scroll.children.head;return q.statics.blotName!==b.default.blotName||q.children.length>1?!1:q.children.head instanceof g.default}},{key:"removeFormat",value:function(q,R){var j=this.getText(q,R),B=this.scroll.line(q+R),V=h(B,2),L=V[0],$=V[1],Z=0,W=new _.default;L!=null&&(L instanceof d.default?Z=L.newlineIndex($)-$+1:Z=L.length()-$,W=L.delta().slice($,$+Z-1).insert(` `));var J=this.getContents(q,R+Z),le=J.diff(new _.default().insert(j).concat(W)),de=new _.default().retain(q).concat(le);return this.applyDelta(de)}},{key:"update",value:function(q){var R=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],j=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,B=this.delta;if(R.length===1&&R[0].type==="characterData"&&R[0].target.data.match(F)&&a.default.find(R[0].target)){var V=a.default.find(R[0].target),L=(0,u.bubbleFormats)(V),$=V.offset(this.scroll),Z=R[0].oldValue.replace(c.default.CONTENTS,""),W=new _.default().insert(Z),J=new _.default().insert(V.value()),le=new _.default().retain($).concat(W.diff(J,j));q=le.reduce(function(de,pe){return pe.insert?de.insert(pe.insert,L):de.push(pe)},new _.default),this.delta=B.compose(q)}else this.delta=this.getDelta(),(!q||!(0,N.default)(B.compose(q),this.delta))&&(q=B.diff(this.delta,j));return q}}]),C}();function H(C,D){return Object.keys(D).reduce(function(q,R){return C[R]==null||(D[R]===C[R]?q[R]=D[R]:Array.isArray(D[R])?D[R].indexOf(C[R])<0&&(q[R]=D[R].concat([C[R]])):q[R]=[D[R],C[R]]),q},{})}function Q(C){return C.reduce(function(D,q){if(q.insert===1){var R=(0,A.default)(q.attributes);return delete R.image,D.insert({image:q.attributes.image},R)}if(q.attributes!=null&&(q.attributes.list===!0||q.attributes.bullet===!0)&&(q=(0,A.default)(q),q.attributes.list?q.attributes.list="ordered":(q.attributes.list="bullet",delete q.attributes.bullet)),typeof q.insert=="string"){var j=q.insert.replace(/\r\n/g,` `).replace(/\r/g,` `);return D.insert(j,q.attributes)}return D.push(q)},new _.default)}r.default=M},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.Range=void 0;var f=function(){function k(N,x){var E=[],w=!0,S=!1,P=void 0;try{for(var F=N[Symbol.iterator](),M;!(w=(M=F.next()).done)&&(E.push(M.value),!(x&&E.length===x));w=!0);}catch(H){S=!0,P=H}finally{try{!w&&F.return&&F.return()}finally{if(S)throw P}}return E}return function(N,x){if(Array.isArray(N))return N;if(Symbol.iterator in Object(N))return k(N,x);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(){function k(N,x){for(var E=0;E1&&arguments[1]!==void 0?arguments[1]:0;b(this,k),this.index=N,this.length=x},T=function(){function k(N,x){var E=this;b(this,k),this.emitter=x,this.scroll=N,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=m.default.create("cursor",this),this.lastRange=this.savedRange=new g(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){E.mouseDown||setTimeout(E.update.bind(E,y.default.sources.USER),1)}),this.emitter.on(y.default.events.EDITOR_CHANGE,function(w,S){w===y.default.events.TEXT_CHANGE&&S.length()>0&&E.update(y.default.sources.SILENT)}),this.emitter.on(y.default.events.SCROLL_BEFORE_UPDATE,function(){if(!!E.hasFocus()){var w=E.getNativeRange();w!=null&&w.start.node!==E.cursor.textNode&&E.emitter.once(y.default.events.SCROLL_UPDATE,function(){try{E.setNativeRange(w.start.node,w.start.offset,w.end.node,w.end.offset)}catch{}})}}),this.emitter.on(y.default.events.SCROLL_OPTIMIZE,function(w,S){if(S.range){var P=S.range,F=P.startNode,M=P.startOffset,H=P.endNode,Q=P.endOffset;E.setNativeRange(F,M,H,Q)}}),this.update(y.default.sources.SILENT)}return h(k,[{key:"handleComposition",value:function(){var x=this;this.root.addEventListener("compositionstart",function(){x.composing=!0}),this.root.addEventListener("compositionend",function(){if(x.composing=!1,x.cursor.parent){var E=x.cursor.restore();if(!E)return;setTimeout(function(){x.setNativeRange(E.startNode,E.startOffset,E.endNode,E.endOffset)},1)}})}},{key:"handleDragging",value:function(){var x=this;this.emitter.listenDOM("mousedown",document.body,function(){x.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){x.mouseDown=!1,x.update(y.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(x,E){if(!(this.scroll.whitelist!=null&&!this.scroll.whitelist[x])){this.scroll.update();var w=this.getNativeRange();if(!(w==null||!w.native.collapsed||m.default.query(x,m.default.Scope.BLOCK))){if(w.start.node!==this.cursor.textNode){var S=m.default.find(w.start.node,!1);if(S==null)return;if(S instanceof m.default.Leaf){var P=S.split(w.start.offset);S.parent.insertBefore(this.cursor,P)}else S.insertBefore(this.cursor,w.start.node);this.cursor.attach()}this.cursor.format(x,E),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(x){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,w=this.scroll.length();x=Math.min(x,w-1),E=Math.min(x+E,w-1)-x;var S=void 0,P=this.scroll.leaf(x),F=f(P,2),M=F[0],H=F[1];if(M==null)return null;var Q=M.position(H,!0),C=f(Q,2);S=C[0],H=C[1];var D=document.createRange();if(E>0){D.setStart(S,H);var q=this.scroll.leaf(x+E),R=f(q,2);if(M=R[0],H=R[1],M==null)return null;var j=M.position(H,!0),B=f(j,2);return S=B[0],H=B[1],D.setEnd(S,H),D.getBoundingClientRect()}else{var V="left",L=void 0;return S instanceof Text?(H0&&(V="right")),{bottom:L.top+L.height,height:L.height,left:L[V],right:L[V],top:L.top,width:0}}}},{key:"getNativeRange",value:function(){var x=document.getSelection();if(x==null||x.rangeCount<=0)return null;var E=x.getRangeAt(0);if(E==null)return null;var w=this.normalizeNative(E);return s.info("getNativeRange",w),w}},{key:"getRange",value:function(){var x=this.getNativeRange();if(x==null)return[null,null];var E=this.normalizedToRange(x);return[E,x]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(x){var E=this,w=[[x.start.node,x.start.offset]];x.native.collapsed||w.push([x.end.node,x.end.offset]);var S=w.map(function(M){var H=f(M,2),Q=H[0],C=H[1],D=m.default.find(Q,!0),q=D.offset(E.scroll);return C===0?q:D instanceof m.default.Container?q+D.length():q+D.index(Q,C)}),P=Math.min(Math.max.apply(Math,u(S)),this.scroll.length()-1),F=Math.min.apply(Math,[P].concat(u(S)));return new g(F,P-F)}},{key:"normalizeNative",value:function(x){if(!A(this.root,x.startContainer)||!x.collapsed&&!A(this.root,x.endContainer))return null;var E={start:{node:x.startContainer,offset:x.startOffset},end:{node:x.endContainer,offset:x.endOffset},native:x};return[E.start,E.end].forEach(function(w){for(var S=w.node,P=w.offset;!(S instanceof Text)&&S.childNodes.length>0;)if(S.childNodes.length>P)S=S.childNodes[P],P=0;else if(S.childNodes.length===P)S=S.lastChild,P=S instanceof Text?S.data.length:S.childNodes.length+1;else break;w.node=S,w.offset=P}),E}},{key:"rangeToNative",value:function(x){var E=this,w=x.collapsed?[x.index]:[x.index,x.index+x.length],S=[],P=this.scroll.length();return w.forEach(function(F,M){F=Math.min(P-1,F);var H=void 0,Q=E.scroll.leaf(F),C=f(Q,2),D=C[0],q=C[1],R=D.position(q,M!==0),j=f(R,2);H=j[0],q=j[1],S.push(H,q)}),S.length<2&&(S=S.concat(S)),S}},{key:"scrollIntoView",value:function(x){var E=this.lastRange;if(E!=null){var w=this.getBounds(E.index,E.length);if(w!=null){var S=this.scroll.length()-1,P=this.scroll.line(Math.min(E.index,S)),F=f(P,1),M=F[0],H=M;if(E.length>0){var Q=this.scroll.line(Math.min(E.index+E.length,S)),C=f(Q,1);H=C[0]}if(!(M==null||H==null)){var D=x.getBoundingClientRect();w.topD.bottom&&(x.scrollTop+=w.bottom-D.bottom)}}}}},{key:"setNativeRange",value:function(x,E){var w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:x,S=arguments.length>3&&arguments[3]!==void 0?arguments[3]:E,P=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(s.info("setNativeRange",x,E,w,S),!(x!=null&&(this.root.parentNode==null||x.parentNode==null||w.parentNode==null))){var F=document.getSelection();if(F!=null)if(x!=null){this.hasFocus()||this.root.focus();var M=(this.getNativeRange()||{}).native;if(M==null||P||x!==M.startContainer||E!==M.startOffset||w!==M.endContainer||S!==M.endOffset){x.tagName=="BR"&&(E=[].indexOf.call(x.parentNode.childNodes,x),x=x.parentNode),w.tagName=="BR"&&(S=[].indexOf.call(w.parentNode.childNodes,w),w=w.parentNode);var H=document.createRange();H.setStart(x,E),H.setEnd(w,S),F.removeAllRanges(),F.addRange(H)}}else F.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(x){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,w=arguments.length>2&&arguments[2]!==void 0?arguments[2]:y.default.sources.API;if(typeof E=="string"&&(w=E,E=!1),s.info("setRange",x),x!=null){var S=this.rangeToNative(x);this.setNativeRange.apply(this,u(S).concat([E]))}else this.setNativeRange(null);this.update(w)}},{key:"update",value:function(){var x=arguments.length>0&&arguments[0]!==void 0?arguments[0]:y.default.sources.USER,E=this.lastRange,w=this.getRange(),S=f(w,2),P=S[0],F=S[1];if(this.lastRange=P,this.lastRange!=null&&(this.savedRange=this.lastRange),!(0,o.default)(E,this.lastRange)){var M;!this.composing&&F!=null&&F.native.collapsed&&F.start.node!==this.cursor.textNode&&this.cursor.restore();var H=[y.default.events.SELECTION_CHANGE,(0,p.default)(this.lastRange),(0,p.default)(E),x];if((M=this.emitter).emit.apply(M,[y.default.events.EDITOR_CHANGE].concat(H)),x!==y.default.sources.SILENT){var Q;(Q=this.emitter).emit.apply(Q,H)}}}}]),k}();function A(k,N){try{N.parentNode}catch{return!1}return N instanceof Text&&(N=N.parentNode),k.contains(N)}r.Range=g,r.default=T},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function y(d,v){for(var c=0;c0&&(a+=1),[this.parent.domNode,a]},p.prototype.value=function(){var l;return l={},l[this.statics.blotName]=this.statics.value(this.domNode)||!0,l},p.scope=O.Scope.INLINE_BLOT,p}(h.default);r.default=m},function(t,r,i){var f=i(11),h=i(3),O={attributes:{compose:function(_,p,l){typeof _!="object"&&(_={}),typeof p!="object"&&(p={});var o=h(!0,{},p);l||(o=Object.keys(o).reduce(function(y,d){return o[d]!=null&&(y[d]=o[d]),y},{}));for(var a in _)_[a]!==void 0&&p[a]===void 0&&(o[a]=_[a]);return Object.keys(o).length>0?o:void 0},diff:function(_,p){typeof _!="object"&&(_={}),typeof p!="object"&&(p={});var l=Object.keys(_).concat(Object.keys(p)).reduce(function(o,a){return f(_[a],p[a])||(o[a]=p[a]===void 0?null:p[a]),o},{});return Object.keys(l).length>0?l:void 0},transform:function(_,p,l){if(typeof _!="object")return p;if(typeof p=="object"){if(!l)return p;var o=Object.keys(p).reduce(function(a,y){return _[y]===void 0&&(a[y]=p[y]),a},{});return Object.keys(o).length>0?o:void 0}}},iterator:function(_){return new m(_)},length:function(_){return typeof _.delete=="number"?_.delete:typeof _.retain=="number"?_.retain:typeof _.insert=="string"?_.insert.length:1}};function m(_){this.ops=_,this.index=0,this.offset=0}m.prototype.hasNext=function(){return this.peekLength()<1/0},m.prototype.next=function(_){_||(_=1/0);var p=this.ops[this.index];if(p){var l=this.offset,o=O.length(p);if(_>=o-l?(_=o-l,this.index+=1,this.offset=0):this.offset+=_,typeof p.delete=="number")return{delete:_};var a={};return p.attributes&&(a.attributes=p.attributes),typeof p.retain=="number"?a.retain=_:typeof p.insert=="string"?a.insert=p.insert.substr(l,_):a.insert=p.insert,a}else return{retain:1/0}},m.prototype.peek=function(){return this.ops[this.index]},m.prototype.peekLength=function(){return this.ops[this.index]?O.length(this.ops[this.index])-this.offset:1/0},m.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"},m.prototype.rest=function(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);var _=this.offset,p=this.index,l=this.next(),o=this.ops.slice(this.index);return this.offset=_,this.index=p,[l].concat(o)}else return[]},t.exports=O},function(t,r){var i=function(){function f(d,v){return v!=null&&d instanceof v}var h;try{h=Map}catch{h=function(){}}var O;try{O=Set}catch{O=function(){}}var m;try{m=Promise}catch{m=function(){}}function _(d,v,c,u,b){typeof v=="object"&&(c=v.depth,u=v.prototype,b=v.includeNonEnumerable,v=v.circular);var s=[],g=[],T=typeof Buffer<"u";typeof v>"u"&&(v=!0),typeof c>"u"&&(c=1/0);function A(k,N){if(k===null)return null;if(N===0)return k;var x,E;if(typeof k!="object")return k;if(f(k,h))x=new h;else if(f(k,O))x=new O;else if(f(k,m))x=new m(function(D,q){k.then(function(R){D(A(R,N-1))},function(R){q(A(R,N-1))})});else if(_.__isArray(k))x=[];else if(_.__isRegExp(k))x=new RegExp(k.source,y(k)),k.lastIndex&&(x.lastIndex=k.lastIndex);else if(_.__isDate(k))x=new Date(k.getTime());else{if(T&&Buffer.isBuffer(k))return Buffer.allocUnsafe?x=Buffer.allocUnsafe(k.length):x=new Buffer(k.length),k.copy(x),x;f(k,Error)?x=Object.create(k):typeof u>"u"?(E=Object.getPrototypeOf(k),x=Object.create(E)):(x=Object.create(u),E=u)}if(v){var w=s.indexOf(k);if(w!=-1)return g[w];s.push(k),g.push(x)}f(k,h)&&k.forEach(function(D,q){var R=A(q,N-1),j=A(D,N-1);x.set(R,j)}),f(k,O)&&k.forEach(function(D){var q=A(D,N-1);x.add(q)});for(var S in k){var P;E&&(P=Object.getOwnPropertyDescriptor(E,S)),!(P&&P.set==null)&&(x[S]=A(k[S],N-1))}if(Object.getOwnPropertySymbols)for(var F=Object.getOwnPropertySymbols(k),S=0;S0){if(H instanceof o.BlockEmbed||q instanceof o.BlockEmbed){this.optimize();return}if(H instanceof c.default){var R=H.newlineIndex(H.length(),!0);if(R>-1&&(H=H.split(R+1),H===q)){this.optimize();return}}else if(q instanceof c.default){var j=q.newlineIndex(0);j>-1&&q.split(j+1)}var B=q.children.head instanceof d.default?null:q.children.head;H.moveChildren(q,B),H.remove()}this.optimize()}},{key:"enable",value:function(){var S=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.domNode.setAttribute("contenteditable",S)}},{key:"formatAt",value:function(S,P,F,M){this.whitelist!=null&&!this.whitelist[F]||(O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"formatAt",this).call(this,S,P,F,M),this.optimize())}},{key:"insertAt",value:function(S,P,F){if(!(F!=null&&this.whitelist!=null&&!this.whitelist[P])){if(S>=this.length())if(F==null||_.default.query(P,_.default.Scope.BLOCK)==null){var M=_.default.create(this.statics.defaultChild);this.appendChild(M),F==null&&P.endsWith(` `)&&(P=P.slice(0,-1)),M.insertAt(0,P,F)}else{var H=_.default.create(P,F);this.appendChild(H)}else O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"insertAt",this).call(this,S,P,F);this.optimize()}}},{key:"insertBefore",value:function(S,P){if(S.statics.scope===_.default.Scope.INLINE_BLOT){var F=_.default.create(this.statics.defaultChild);F.appendChild(S),S=F}O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"insertBefore",this).call(this,S,P)}},{key:"leaf",value:function(S){return this.path(S).pop()||[null,-1]}},{key:"line",value:function(S){return S===this.length()?this.line(S-1):this.descendant(k,S)}},{key:"lines",value:function(){var S=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,P=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE,F=function M(H,Q,C){var D=[],q=C;return H.children.forEachAt(Q,C,function(R,j,B){k(R)?D.push(R):R instanceof _.default.Container&&(D=D.concat(M(R,j,q))),q-=B}),D};return F(this,S,P)}},{key:"optimize",value:function(){var S=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],P=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.batch!==!0&&(O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"optimize",this).call(this,S,P),S.length>0&&this.emitter.emit(l.default.events.SCROLL_OPTIMIZE,S,P))}},{key:"path",value:function(S){return O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"path",this).call(this,S).slice(1)}},{key:"update",value:function(S){if(this.batch!==!0){var P=l.default.sources.USER;typeof S=="string"&&(P=S),Array.isArray(S)||(S=this.observer.takeRecords()),S.length>0&&this.emitter.emit(l.default.events.SCROLL_BEFORE_UPDATE,P,S),O(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"update",this).call(this,S.concat([])),S.length>0&&this.emitter.emit(l.default.events.SCROLL_UPDATE,P,S)}}}]),E}(_.default.Scroll);N.blotName="scroll",N.className="ql-editor",N.tagName="DIV",N.defaultChild="block",N.allowedChildren=[a.default,o.BlockEmbed,b.default],r.default=N},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.SHORTKEY=r.default=void 0;var f=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(L){return typeof L}:function(L){return L&&typeof Symbol=="function"&&L.constructor===Symbol&&L!==Symbol.prototype?"symbol":typeof L},h=function(){function L($,Z){var W=[],J=!0,le=!1,de=void 0;try{for(var pe=$[Symbol.iterator](),ve;!(J=(ve=pe.next()).done)&&(W.push(ve.value),!(Z&&W.length===Z));J=!0);}catch(I){le=!0,de=I}finally{try{!J&&pe.return&&pe.return()}finally{if(le)throw de}}return W}return function($,Z){if(Array.isArray($))return $;if(Symbol.iterator in Object($))return L($,Z);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),O=function(){function L($,Z){for(var W=0;W1&&arguments[1]!==void 0?arguments[1]:{},le=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},de=V(W);if(de==null||de.key==null)return F.warn("Attempted to add invalid keyboard binding",de);typeof J=="function"&&(J={handler:J}),typeof le=="function"&&(le={handler:le}),de=(0,a.default)(de,J,le),this.bindings[de.key]=this.bindings[de.key]||[],this.bindings[de.key].push(de)}},{key:"listen",value:function(){var W=this;this.quill.root.addEventListener("keydown",function(J){if(!J.defaultPrevented){var le=J.which||J.keyCode,de=(W.bindings[le]||[]).filter(function(K){return $.match(J,K)});if(de.length!==0){var pe=W.quill.getSelection();if(!(pe==null||!W.quill.hasFocus())){var ve=W.quill.getLine(pe.index),I=h(ve,2),Y=I[0],X=I[1],z=W.quill.getLeaf(pe.index),U=h(z,2),G=U[0],te=U[1],ee=pe.length===0?[G,te]:W.quill.getLeaf(pe.index+pe.length),ue=h(ee,2),he=ue[0],ye=ue[1],qe=G instanceof b.default.Text?G.value().slice(0,te):"",Re=he instanceof b.default.Text?he.value().slice(ye):"",_e={collapsed:pe.length===0,empty:pe.length===0&&Y.length()<=1,format:W.quill.getFormat(pe),offset:X,prefix:qe,suffix:Re},ne=de.some(function(K){if(K.collapsed!=null&&K.collapsed!==_e.collapsed||K.empty!=null&&K.empty!==_e.empty||K.offset!=null&&K.offset!==_e.offset)return!1;if(Array.isArray(K.format)){if(K.format.every(function(oe){return _e.format[oe]==null}))return!1}else if(f(K.format)==="object"&&!Object.keys(K.format).every(function(oe){return K.format[oe]===!0?_e.format[oe]!=null:K.format[oe]===!1?_e.format[oe]==null:(0,l.default)(K.format[oe],_e.format[oe])}))return!1;return K.prefix!=null&&!K.prefix.test(_e.prefix)||K.suffix!=null&&!K.suffix.test(_e.suffix)?!1:K.handler.call(W,pe,_e)!==!0});ne&&J.preventDefault()}}}})}}]),$}(N.default);H.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},H.DEFAULTS={bindings:{bold:B("bold"),italic:B("italic"),underline:B("underline"),indent:{key:H.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:H.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:H.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":j(!0),"outdent code-block":j(!1),"remove tab":{key:H.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function($){this.quill.deleteText($.index-1,1,g.default.sources.USER)}},tab:{key:H.keys.TAB,handler:function($){this.quill.history.cutoff();var Z=new d.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:H.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:H.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function($){var Z=this.quill.getLine($.index),W=h(Z,2),J=W[0],le=W[1],de=(0,a.default)({},J.formats(),{list:"checked"}),pe=new d.default().retain($.index).insert(` `,de).retain(J.length()-le-1).retain(1,{list:"unchecked"});this.quill.updateContents(pe,g.default.sources.USER),this.quill.setSelection($.index+1,g.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:H.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function($,Z){var W=this.quill.getLine($.index),J=h(W,2),le=J[0],de=J[1],pe=new d.default().retain($.index).insert(` `,Z.format).retain(le.length()-de-1).retain(1,{header:null});this.quill.updateContents(pe,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 W=Z.prefix.length,J=this.quill.getLine($.index),le=h(J,2),de=le[0],pe=le[1];if(pe>W)return!0;var ve=void 0;switch(Z.prefix.trim()){case"[]":case"[ ]":ve="unchecked";break;case"[x]":ve="checked";break;case"-":case"*":ve="bullet";break;default:ve="ordered"}this.quill.insertText($.index," ",g.default.sources.USER),this.quill.history.cutoff();var I=new d.default().retain($.index-pe).delete(W+1).retain(de.length()-2-pe).retain(1,{list:ve});this.quill.updateContents(I,g.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection($.index-W,g.default.sources.SILENT)}},"code exit":{key:H.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function($){var Z=this.quill.getLine($.index),W=h(Z,2),J=W[0],le=W[1],de=new d.default().retain($.index+J.length()-le-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(de,g.default.sources.USER)}},"embed left":Q(H.keys.LEFT,!1),"embed left shift":Q(H.keys.LEFT,!0),"embed right":Q(H.keys.RIGHT,!1),"embed right shift":Q(H.keys.RIGHT,!0)}};function Q(L,$){var Z,W=L===H.keys.LEFT?"prefix":"suffix";return Z={key:L,shiftKey:$,altKey:null},E(Z,W,/^$/),E(Z,"handler",function(le){var de=le.index;L===H.keys.RIGHT&&(de+=le.length+1);var pe=this.quill.getLeaf(de),ve=h(pe,1),I=ve[0];return I instanceof b.default.Embed?(L===H.keys.LEFT?$?this.quill.setSelection(le.index-1,le.length+1,g.default.sources.USER):this.quill.setSelection(le.index-1,g.default.sources.USER):$?this.quill.setSelection(le.index,le.length+1,g.default.sources.USER):this.quill.setSelection(le.index+le.length+1,g.default.sources.USER),!1):!0}),Z}function C(L,$){if(!(L.index===0||this.quill.getLength()<=1)){var Z=this.quill.getLine(L.index),W=h(Z,1),J=W[0],le={};if($.offset===0){var de=this.quill.getLine(L.index-1),pe=h(de,1),ve=pe[0];if(ve!=null&&ve.length()>1){var I=J.formats(),Y=this.quill.getFormat(L.index-1,1);le=c.default.attributes.diff(I,Y)||{}}}var X=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test($.prefix)?2:1;this.quill.deleteText(L.index-X,X,g.default.sources.USER),Object.keys(le).length>0&&this.quill.formatLine(L.index-X,X,le,g.default.sources.USER),this.quill.focus()}}function D(L,$){var Z=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test($.suffix)?2:1;if(!(L.index>=this.quill.getLength()-Z)){var W={},J=0,le=this.quill.getLine(L.index),de=h(le,1),pe=de[0];if($.offset>=pe.length()-1){var ve=this.quill.getLine(L.index+1),I=h(ve,1),Y=I[0];if(Y){var X=pe.formats(),z=this.quill.getFormat(L.index,1);W=c.default.attributes.diff(X,z)||{},J=Y.length()}}this.quill.deleteText(L.index,Z,g.default.sources.USER),Object.keys(W).length>0&&this.quill.formatLine(L.index+J-1,Z,W,g.default.sources.USER)}}function q(L){var $=this.quill.getLines(L),Z={};if($.length>1){var W=$[0].formats(),J=$[$.length-1].formats();Z=c.default.attributes.diff(J,W)||{}}this.quill.deleteText(L,g.default.sources.USER),Object.keys(Z).length>0&&this.quill.formatLine(L.index,1,Z,g.default.sources.USER),this.quill.setSelection(L.index,g.default.sources.SILENT),this.quill.focus()}function R(L,$){var Z=this;L.length>0&&this.quill.scroll.deleteAt(L.index,L.length);var W=Object.keys($.format).reduce(function(J,le){return b.default.query(le,b.default.Scope.BLOCK)&&!Array.isArray($.format[le])&&(J[le]=$.format[le]),J},{});this.quill.insertText(L.index,` `,W,g.default.sources.USER),this.quill.setSelection(L.index+1,g.default.sources.SILENT),this.quill.focus(),Object.keys($.format).forEach(function(J){W[J]==null&&(Array.isArray($.format[J])||J!=="link"&&Z.quill.format(J,$.format[J],g.default.sources.USER))})}function j(L){return{key:H.keys.TAB,shiftKey:!L,format:{"code-block":!0},handler:function(Z){var W=b.default.query("code-block"),J=Z.index,le=Z.length,de=this.quill.scroll.descendant(W,J),pe=h(de,2),ve=pe[0],I=pe[1];if(ve!=null){var Y=this.quill.getIndex(ve),X=ve.newlineIndex(I,!0)+1,z=ve.newlineIndex(Y+I+le),U=ve.domNode.textContent.slice(X,z).split(` `);I=0,U.forEach(function(G,te){L?(ve.insertAt(X+I,W.TAB),I+=W.TAB.length,te===0?J+=W.TAB.length:le+=W.TAB.length):G.startsWith(W.TAB)&&(ve.deleteAt(X+I,W.TAB.length),I-=W.TAB.length,te===0?J-=W.TAB.length:le-=W.TAB.length),I+=G.length+1}),this.quill.update(g.default.sources.USER),this.quill.setSelection(J,le,g.default.sources.SILENT)}}}}function B(L){return{key:L[0].toUpperCase(),shortKey:!0,handler:function(Z,W){this.quill.format(L,!W.format[L],g.default.sources.USER)}}}function V(L){if(typeof L=="string"||typeof L=="number")return V({key:L});if((typeof L>"u"?"undefined":f(L))==="object"&&(L=(0,_.default)(L,!1)),typeof L.key=="string")if(H.keys[L.key.toUpperCase()]!=null)L.key=H.keys[L.key.toUpperCase()];else if(L.key.length===1)L.key=L.key.toUpperCase().charCodeAt(0);else return null;return L.shortKey&&(L[M]=L.shortKey,delete L.shortKey),L}r.default=H,r.SHORTKEY=M},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function c(u,b){var s=[],g=!0,T=!1,A=void 0;try{for(var k=u[Symbol.iterator](),N;!(g=(N=k.next()).done)&&(s.push(N.value),!(b&&s.length===b));g=!0);}catch(x){T=!0,A=x}finally{try{!g&&k.return&&k.return()}finally{if(T)throw A}}return s}return function(u,b){if(Array.isArray(u))return u;if(Symbol.iterator in Object(u))return c(u,b);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function c(u,b,s){u===null&&(u=Function.prototype);var g=Object.getOwnPropertyDescriptor(u,b);if(g===void 0){var T=Object.getPrototypeOf(u);return T===null?void 0:c(T,b,s)}else{if("value"in g)return g.value;var A=g.get;return A===void 0?void 0:A.call(s)}},O=function(){function c(u,b){for(var s=0;s-1}r.default=a,r.sanitize=y},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=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},h=function(){function v(c,u){for(var b=0;b1&&arguments[1]!==void 0?arguments[1]:!1,s=this.container.querySelector(".ql-selected");if(u!==s&&(s!=null&&s.classList.remove("ql-selected"),u!=null&&(u.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(u.parentNode.children,u),u.hasAttribute("data-value")?this.label.setAttribute("data-value",u.getAttribute("data-value")):this.label.removeAttribute("data-value"),u.hasAttribute("data-label")?this.label.setAttribute("data-label",u.getAttribute("data-label")):this.label.removeAttribute("data-label"),b))){if(typeof Event=="function")this.select.dispatchEvent(new Event("change"));else if((typeof Event>"u"?"undefined":f(Event))==="object"){var g=document.createEvent("Event");g.initEvent("change",!0,!0),this.select.dispatchEvent(g)}this.close()}}},{key:"update",value:function(){var u=void 0;if(this.select.selectedIndex>-1){var b=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];u=this.select.options[this.select.selectedIndex],this.selectItem(b)}else this.selectItem(null);var s=u!=null&&u!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",s)}}]),v}();r.default=d},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(0),h=F(f),O=i(5),m=F(O),_=i(4),p=F(_),l=i(16),o=F(l),a=i(25),y=F(a),d=i(24),v=F(d),c=i(35),u=F(c),b=i(6),s=F(b),g=i(22),T=F(g),A=i(7),k=F(A),N=i(55),x=F(N),E=i(42),w=F(E),S=i(23),P=F(S);function F(M){return M&&M.__esModule?M:{default:M}}m.default.register({"blots/block":p.default,"blots/block/embed":_.BlockEmbed,"blots/break":o.default,"blots/container":y.default,"blots/cursor":v.default,"blots/embed":u.default,"blots/inline":s.default,"blots/scroll":T.default,"blots/text":k.default,"modules/clipboard":x.default,"modules/history":w.default,"modules/keyboard":P.default}),h.default.register(p.default,o.default,v.default,s.default,T.default,k.default),r.default=m.default},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(1),h=function(){function O(m){this.domNode=m,this.domNode[f.DATA_KEY]={blot:this}}return Object.defineProperty(O.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),O.create=function(m){if(this.tagName==null)throw new f.ParchmentError("Blot definition missing tagName");var _;return Array.isArray(this.tagName)?(typeof m=="string"&&(m=m.toUpperCase(),parseInt(m).toString()===m&&(m=parseInt(m))),typeof m=="number"?_=document.createElement(this.tagName[m-1]):this.tagName.indexOf(m)>-1?_=document.createElement(m):_=document.createElement(this.tagName[0])):_=document.createElement(this.tagName),this.className&&_.classList.add(this.className),_},O.prototype.attach=function(){this.parent!=null&&(this.scroll=this.parent.scroll)},O.prototype.clone=function(){var m=this.domNode.cloneNode(!1);return f.create(m)},O.prototype.detach=function(){this.parent!=null&&this.parent.removeChild(this),delete this.domNode[f.DATA_KEY]},O.prototype.deleteAt=function(m,_){var p=this.isolate(m,_);p.remove()},O.prototype.formatAt=function(m,_,p,l){var o=this.isolate(m,_);if(f.query(p,f.Scope.BLOT)!=null&&l)o.wrap(p,l);else if(f.query(p,f.Scope.ATTRIBUTE)!=null){var a=f.create(this.statics.scope);o.wrap(a),a.format(p,l)}},O.prototype.insertAt=function(m,_,p){var l=p==null?f.create("text",_):f.create(_,p),o=this.split(m);this.parent.insertBefore(l,o)},O.prototype.insertInto=function(m,_){_===void 0&&(_=null),this.parent!=null&&this.parent.children.remove(this);var p=null;m.children.insertBefore(this,_),_!=null&&(p=_.domNode),(this.domNode.parentNode!=m.domNode||this.domNode.nextSibling!=p)&&m.domNode.insertBefore(this.domNode,p),this.parent=m,this.attach()},O.prototype.isolate=function(m,_){var p=this.split(m);return p.split(_),p},O.prototype.length=function(){return 1},O.prototype.offset=function(m){return m===void 0&&(m=this.parent),this.parent==null||this==m?0:this.parent.children.offset(this)+this.parent.offset(m)},O.prototype.optimize=function(m){this.domNode[f.DATA_KEY]!=null&&delete this.domNode[f.DATA_KEY].mutations},O.prototype.remove=function(){this.domNode.parentNode!=null&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},O.prototype.replace=function(m){m.parent!=null&&(m.parent.insertBefore(this,m.next),m.remove())},O.prototype.replaceWith=function(m,_){var p=typeof m=="string"?f.create(m,_):m;return p.replace(this),p},O.prototype.split=function(m,_){return m===0?this:this.next},O.prototype.update=function(m,_){},O.prototype.wrap=function(m,_){var p=typeof m=="string"?f.create(m,_):m;return this.parent!=null&&this.parent.insertBefore(p,this.next),p.appendChild(this),p},O.blotName="abstract",O}();r.default=h},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(12),h=i(32),O=i(33),m=i(1),_=function(){function p(l){this.attributes={},this.domNode=l,this.build()}return p.prototype.attribute=function(l,o){o?l.add(this.domNode,o)&&(l.value(this.domNode)!=null?this.attributes[l.attrName]=l:delete this.attributes[l.attrName]):(l.remove(this.domNode),delete this.attributes[l.attrName])},p.prototype.build=function(){var l=this;this.attributes={};var o=f.default.keys(this.domNode),a=h.default.keys(this.domNode),y=O.default.keys(this.domNode);o.concat(a).concat(y).forEach(function(d){var v=m.query(d,m.Scope.ATTRIBUTE);v instanceof f.default&&(l.attributes[v.attrName]=v)})},p.prototype.copy=function(l){var o=this;Object.keys(this.attributes).forEach(function(a){var y=o.attributes[a].value(o.domNode);l.format(a,y)})},p.prototype.move=function(l){var o=this;this.copy(l),Object.keys(this.attributes).forEach(function(a){o.attributes[a].remove(o.domNode)}),this.attributes={}},p.prototype.values=function(){var l=this;return Object.keys(this.attributes).reduce(function(o,a){return o[a]=l.attributes[a].value(l.domNode),o},{})},p}();r.default=_},function(t,r,i){var f=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,l){p.__proto__=l}||function(p,l){for(var o in l)l.hasOwnProperty(o)&&(p[o]=l[o])};return function(p,l){_(p,l);function o(){this.constructor=p}p.prototype=l===null?Object.create(l):(o.prototype=l.prototype,new o)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(12);function O(_,p){var l=_.getAttribute("class")||"";return l.split(/\s+/).filter(function(o){return o.indexOf(p+"-")===0})}var m=function(_){f(p,_);function p(){return _!==null&&_.apply(this,arguments)||this}return p.keys=function(l){return(l.getAttribute("class")||"").split(/\s+/).map(function(o){return o.split("-").slice(0,-1).join("-")})},p.prototype.add=function(l,o){return this.canAdd(l,o)?(this.remove(l),l.classList.add(this.keyName+"-"+o),!0):!1},p.prototype.remove=function(l){var o=O(l,this.keyName);o.forEach(function(a){l.classList.remove(a)}),l.classList.length===0&&l.removeAttribute("class")},p.prototype.value=function(l){var o=O(l,this.keyName)[0]||"",a=o.slice(this.keyName.length+1);return this.canAdd(l,a)?a:""},p}(h.default);r.default=m},function(t,r,i){var f=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,l){p.__proto__=l}||function(p,l){for(var o in l)l.hasOwnProperty(o)&&(p[o]=l[o])};return function(p,l){_(p,l);function o(){this.constructor=p}p.prototype=l===null?Object.create(l):(o.prototype=l.prototype,new o)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(12);function O(_){var p=_.split("-"),l=p.slice(1).map(function(o){return o[0].toUpperCase()+o.slice(1)}).join("");return p[0]+l}var m=function(_){f(p,_);function p(){return _!==null&&_.apply(this,arguments)||this}return p.keys=function(l){return(l.getAttribute("style")||"").split(";").map(function(o){var a=o.split(":");return a[0].trim()})},p.prototype.add=function(l,o){return this.canAdd(l,o)?(l.style[O(this.keyName)]=o,!0):!1},p.prototype.remove=function(l){l.style[O(this.keyName)]="",l.getAttribute("style")||l.removeAttribute("style")},p.prototype.value=function(l){var o=l.style[O(this.keyName)];return this.canAdd(l,o)?o:""},p}(h.default);r.default=m},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function m(_,p){for(var l=0;lN&&this.stack.undo.length>0){var x=this.stack.undo.pop();k=k.compose(x.undo),T=x.redo.compose(T)}else this.lastRecorded=N;this.stack.undo.push({redo:T,undo:k}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(T){this.stack.undo.forEach(function(A){A.undo=T.transform(A.undo,!0),A.redo=T.transform(A.redo,!0)}),this.stack.redo.forEach(function(A){A.undo=T.transform(A.undo,!0),A.redo=T.transform(A.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),s}(l.default);v.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};function c(b){var s=b.ops[b.ops.length-1];return s==null?!1:s.insert!=null?typeof s.insert=="string"&&s.insert.endsWith(` `):s.attributes!=null?Object.keys(s.attributes).some(function(g){return O.default.query(g,O.default.Scope.BLOCK)!=null}):!1}function u(b){var s=b.reduce(function(T,A){return T+=A.delete||0,T},0),g=b.length()-s;return c(b)&&(g-=1),g}r.default=v,r.getLastChangeIndex=u},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BaseTooltip=void 0;var f=function(){function R(j,B){for(var V=0;V0&&arguments[0]!==void 0?arguments[0]:"link",L=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),L!=null?this.textbox.value=L:V!==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-"+V)||""),this.root.setAttribute("data-mode",V)}},{key:"restoreFocus",value:function(){var V=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=V}},{key:"save",value:function(){var V=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":{var L=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",V,o.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",V,o.default.sources.USER)),this.quill.root.scrollTop=L;break}case"video":V=D(V);case"formula":{if(!V)break;var $=this.quill.getSelection(!0);if($!=null){var Z=$.index+$.length;this.quill.insertEmbed(Z,this.root.getAttribute("data-mode"),V,o.default.sources.USER),this.root.getAttribute("data-mode")==="formula"&&this.quill.insertText(Z+1," ",o.default.sources.USER),this.quill.setSelection(Z+2,o.default.sources.USER)}break}}this.textbox.value="",this.hide()}}]),j}(k.default);function D(R){var j=R.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||R.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return j?(j[1]||"https")+"://www.youtube.com/embed/"+j[2]+"?showinfo=0":(j=R.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(j[1]||"https")+"://player.vimeo.com/video/"+j[2]+"/":R}function q(R,j){var B=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;j.forEach(function(V){var L=document.createElement("option");V===B?L.setAttribute("selected","selected"):L.setAttribute("value",V),R.appendChild(L)})}r.BaseTooltip=C,r.default=Q},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function h(){this.head=this.tail=null,this.length=0}return h.prototype.append=function(){for(var O=[],m=0;m1&&this.append.apply(this,O.slice(1))},h.prototype.contains=function(O){for(var m,_=this.iterator();m=_();)if(m===O)return!0;return!1},h.prototype.insertBefore=function(O,m){!O||(O.next=m,m!=null?(O.prev=m.prev,m.prev!=null&&(m.prev.next=O),m.prev=O,m===this.head&&(this.head=O)):this.tail!=null?(this.tail.next=O,O.prev=this.tail,this.tail=O):(O.prev=null,this.head=this.tail=O),this.length+=1)},h.prototype.offset=function(O){for(var m=0,_=this.head;_!=null;){if(_===O)return m;m+=_.length(),_=_.next}return-1},h.prototype.remove=function(O){!this.contains(O)||(O.prev!=null&&(O.prev.next=O.next),O.next!=null&&(O.next.prev=O.prev),O===this.head&&(this.head=O.next),O===this.tail&&(this.tail=O.prev),this.length-=1)},h.prototype.iterator=function(O){return O===void 0&&(O=this.head),function(){var m=O;return O!=null&&(O=O.next),m}},h.prototype.find=function(O,m){m===void 0&&(m=!1);for(var _,p=this.iterator();_=p();){var l=_.length();if(Oy?_(a,O-y,Math.min(m,y+v-O)):_(a,0,Math.min(v,O+m-y)),y+=v}},h.prototype.map=function(O){return this.reduce(function(m,_){return m.push(O(_)),m},[])},h.prototype.reduce=function(O,m){for(var _,p=this.iterator();_=p();)m=O(m,_);return m},h}();r.default=f},function(t,r,i){var f=this&&this.__extends||function(){var l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,a){o.__proto__=a}||function(o,a){for(var y in a)a.hasOwnProperty(y)&&(o[y]=a[y])};return function(o,a){l(o,a);function y(){this.constructor=o}o.prototype=a===null?Object.create(a):(y.prototype=a.prototype,new y)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(17),O=i(1),m={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},_=100,p=function(l){f(o,l);function o(a){var y=l.call(this,a)||this;return y.scroll=y,y.observer=new MutationObserver(function(d){y.update(d)}),y.observer.observe(y.domNode,m),y.attach(),y}return o.prototype.detach=function(){l.prototype.detach.call(this),this.observer.disconnect()},o.prototype.deleteAt=function(a,y){this.update(),a===0&&y===this.length()?this.children.forEach(function(d){d.remove()}):l.prototype.deleteAt.call(this,a,y)},o.prototype.formatAt=function(a,y,d,v){this.update(),l.prototype.formatAt.call(this,a,y,d,v)},o.prototype.insertAt=function(a,y,d){this.update(),l.prototype.insertAt.call(this,a,y,d)},o.prototype.optimize=function(a,y){var d=this;a===void 0&&(a=[]),y===void 0&&(y={}),l.prototype.optimize.call(this,y);for(var v=[].slice.call(this.observer.takeRecords());v.length>0;)a.push(v.pop());for(var c=function(g,T){T===void 0&&(T=!0),!(g==null||g===d)&&g.domNode.parentNode!=null&&(g.domNode[O.DATA_KEY].mutations==null&&(g.domNode[O.DATA_KEY].mutations=[]),T&&c(g.parent))},u=function(g){g.domNode[O.DATA_KEY]==null||g.domNode[O.DATA_KEY].mutations==null||(g instanceof h.default&&g.children.forEach(u),g.optimize(y))},b=a,s=0;b.length>0;s+=1){if(s>=_)throw new Error("[Parchment] Maximum optimize iterations reached");for(b.forEach(function(g){var T=O.find(g.target,!0);T!=null&&(T.domNode===g.target&&(g.type==="childList"?(c(O.find(g.previousSibling,!1)),[].forEach.call(g.addedNodes,function(A){var k=O.find(A,!1);c(k,!1),k instanceof h.default&&k.children.forEach(function(N){c(N,!1)})})):g.type==="attributes"&&c(T.prev)),c(T))}),this.children.forEach(u),b=[].slice.call(this.observer.takeRecords()),v=b.slice();v.length>0;)a.push(v.pop())}},o.prototype.update=function(a,y){var d=this;y===void 0&&(y={}),a=a||this.observer.takeRecords(),a.map(function(v){var c=O.find(v.target,!0);return c==null?null:c.domNode[O.DATA_KEY].mutations==null?(c.domNode[O.DATA_KEY].mutations=[v],c):(c.domNode[O.DATA_KEY].mutations.push(v),null)}).forEach(function(v){v==null||v===d||v.domNode[O.DATA_KEY]==null||v.update(v.domNode[O.DATA_KEY].mutations||[],y)}),this.domNode[O.DATA_KEY].mutations!=null&&l.prototype.update.call(this,this.domNode[O.DATA_KEY].mutations,y),this.optimize(a,y)},o.blotName="scroll",o.defaultChild="block",o.scope=O.Scope.BLOCK_BLOT,o.tagName="DIV",o}(h.default);r.default=p},function(t,r,i){var f=this&&this.__extends||function(){var p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,o){l.__proto__=o}||function(l,o){for(var a in o)o.hasOwnProperty(a)&&(l[a]=o[a])};return function(l,o){p(l,o);function a(){this.constructor=l}l.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(18),O=i(1);function m(p,l){if(Object.keys(p).length!==Object.keys(l).length)return!1;for(var o in p)if(p[o]!==l[o])return!1;return!0}var _=function(p){f(l,p);function l(){return p!==null&&p.apply(this,arguments)||this}return l.formats=function(o){if(o.tagName!==l.tagName)return p.formats.call(this,o)},l.prototype.format=function(o,a){var y=this;o===this.statics.blotName&&!a?(this.children.forEach(function(d){d instanceof h.default||(d=d.wrap(l.blotName,!0)),y.attributes.copy(d)}),this.unwrap()):p.prototype.format.call(this,o,a)},l.prototype.formatAt=function(o,a,y,d){if(this.formats()[y]!=null||O.query(y,O.Scope.ATTRIBUTE)){var v=this.isolate(o,a);v.format(y,d)}else p.prototype.formatAt.call(this,o,a,y,d)},l.prototype.optimize=function(o){p.prototype.optimize.call(this,o);var a=this.formats();if(Object.keys(a).length===0)return this.unwrap();var y=this.next;y instanceof l&&y.prev===this&&m(a,y.formats())&&(y.moveChildren(this),y.remove())},l.blotName="inline",l.scope=O.Scope.INLINE_BLOT,l.tagName="SPAN",l}(h.default);r.default=_},function(t,r,i){var f=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,l){p.__proto__=l}||function(p,l){for(var o in l)l.hasOwnProperty(o)&&(p[o]=l[o])};return function(p,l){_(p,l);function o(){this.constructor=p}p.prototype=l===null?Object.create(l):(o.prototype=l.prototype,new o)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(18),O=i(1),m=function(_){f(p,_);function p(){return _!==null&&_.apply(this,arguments)||this}return p.formats=function(l){var o=O.query(p.blotName).tagName;if(l.tagName!==o)return _.formats.call(this,l)},p.prototype.format=function(l,o){O.query(l,O.Scope.BLOCK)!=null&&(l===this.statics.blotName&&!o?this.replaceWith(p.blotName):_.prototype.format.call(this,l,o))},p.prototype.formatAt=function(l,o,a,y){O.query(a,O.Scope.BLOCK)!=null?this.format(a,y):_.prototype.formatAt.call(this,l,o,a,y)},p.prototype.insertAt=function(l,o,a){if(a==null||O.query(o,O.Scope.INLINE)!=null)_.prototype.insertAt.call(this,l,o,a);else{var y=this.split(l),d=O.create(o,a);y.parent.insertBefore(d,y)}},p.prototype.update=function(l,o){navigator.userAgent.match(/Trident/)?this.build():_.prototype.update.call(this,l,o)},p.blotName="block",p.scope=O.Scope.BLOCK_BLOT,p.tagName="P",p}(h.default);r.default=m},function(t,r,i){var f=this&&this.__extends||function(){var m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,p){_.__proto__=p}||function(_,p){for(var l in p)p.hasOwnProperty(l)&&(_[l]=p[l])};return function(_,p){m(_,p);function l(){this.constructor=_}_.prototype=p===null?Object.create(p):(l.prototype=p.prototype,new l)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(19),O=function(m){f(_,m);function _(){return m!==null&&m.apply(this,arguments)||this}return _.formats=function(p){},_.prototype.format=function(p,l){m.prototype.formatAt.call(this,0,this.length(),p,l)},_.prototype.formatAt=function(p,l,o,a){p===0&&l===this.length()?this.format(o,a):m.prototype.formatAt.call(this,p,l,o,a)},_.prototype.formats=function(){return this.statics.formats(this.domNode)},_}(h.default);r.default=O},function(t,r,i){var f=this&&this.__extends||function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,l){p.__proto__=l}||function(p,l){for(var o in l)l.hasOwnProperty(o)&&(p[o]=l[o])};return function(p,l){_(p,l);function o(){this.constructor=p}p.prototype=l===null?Object.create(l):(o.prototype=l.prototype,new o)}}();Object.defineProperty(r,"__esModule",{value:!0});var h=i(19),O=i(1),m=function(_){f(p,_);function p(l){var o=_.call(this,l)||this;return o.text=o.statics.value(o.domNode),o}return p.create=function(l){return document.createTextNode(l)},p.value=function(l){var o=l.data;return o.normalize&&(o=o.normalize()),o},p.prototype.deleteAt=function(l,o){this.domNode.data=this.text=this.text.slice(0,l)+this.text.slice(l+o)},p.prototype.index=function(l,o){return this.domNode===l?o:-1},p.prototype.insertAt=function(l,o,a){a==null?(this.text=this.text.slice(0,l)+o+this.text.slice(l),this.domNode.data=this.text):_.prototype.insertAt.call(this,l,o,a)},p.prototype.length=function(){return this.text.length},p.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 p&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},p.prototype.position=function(l,o){return[this.domNode,l]},p.prototype.split=function(l,o){if(o===void 0&&(o=!1),!o){if(l===0)return this;if(l===this.length())return this.next}var a=O.create(this.domNode.splitText(l));return this.parent.insertBefore(a,this.next),this.text=this.statics.value(this.domNode),a},p.prototype.update=function(l,o){var a=this;l.some(function(y){return y.type==="characterData"&&y.target===a.domNode})&&(this.text=this.statics.value(this.domNode))},p.prototype.value=function(){return this.text},p.blotName="text",p.scope=O.Scope.INLINE_BLOT,p}(h.default);r.default=m},function(t,r,i){var f=document.createElement("div");if(f.classList.toggle("test-class",!1),f.classList.contains("test-class")){var h=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(O,m){return arguments.length>1&&!this.contains(O)==!m?m:h.call(this,O)}}String.prototype.startsWith||(String.prototype.startsWith=function(O,m){return m=m||0,this.substr(m,O.length)===O}),String.prototype.endsWith||(String.prototype.endsWith=function(O,m){var _=this.toString();(typeof m!="number"||!isFinite(m)||Math.floor(m)!==m||m>_.length)&&(m=_.length),m-=O.length;var p=_.indexOf(O,m);return p!==-1&&p===m}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(m){if(this===null)throw new TypeError("Array.prototype.find called on null or undefined");if(typeof m!="function")throw new TypeError("predicate must be a function");for(var _=Object(this),p=_.length>>>0,l=arguments[1],o,a=0;ag.length?s:g,k=s.length>g.length?g:s,N=A.indexOf(k);if(N!=-1)return T=[[f,A.substring(0,N)],[h,k],[f,A.substring(N+k.length)]],s.length>g.length&&(T[0][0]=T[2][0]=i),T;if(k.length==1)return[[i,s],[f,g]];var x=a(s,g);if(x){var E=x[0],w=x[1],S=x[2],P=x[3],F=x[4],M=O(E,S),H=O(w,P);return M.concat([[h,F]],H)}return _(s,g)}function _(s,g){for(var T=s.length,A=g.length,k=Math.ceil((T+A)/2),N=k,x=2*k,E=new Array(x),w=new Array(x),S=0;ST)H+=2;else if(B>A)M+=2;else if(F){var V=N+P-q;if(V>=0&&V=L)return p(s,g,j,B)}}}for(var $=-D+Q;$<=D-C;$+=2){var V=N+$,L;$==-D||$!=D&&w[V-1]T)C+=2;else if(Z>A)Q+=2;else if(!F){var R=N+P-$;if(R>=0&&R=L)return p(s,g,j,B)}}}}return[[i,s],[f,g]]}function p(s,g,T,A){var k=s.substring(0,T),N=g.substring(0,A),x=s.substring(T),E=g.substring(A),w=O(k,N),S=O(x,E);return w.concat(S)}function l(s,g){if(!s||!g||s.charAt(0)!=g.charAt(0))return 0;for(var T=0,A=Math.min(s.length,g.length),k=A,N=0;Tg.length?s:g,A=s.length>g.length?g:s;if(T.length<4||A.length*2=H.length?[j,B,V,L,R]:null}var N=k(T,A,Math.ceil(T.length/4)),x=k(T,A,Math.ceil(T.length/2)),E;if(!N&&!x)return null;x?N?E=N[4].length>x[4].length?N:x:E=x:E=N;var w,S,P,F;s.length>g.length?(w=E[0],S=E[1],P=E[2],F=E[3]):(P=E[0],F=E[1],w=E[2],S=E[3]);var M=E[4];return[w,S,P,F,M]}function y(s){s.push([h,""]);for(var g=0,T=0,A=0,k="",N="",x;g1?(T!==0&&A!==0&&(x=l(N,k),x!==0&&(g-T-A>0&&s[g-T-A-1][0]==h?s[g-T-A-1][1]+=N.substring(0,x):(s.splice(0,0,[h,N.substring(0,x)]),g++),N=N.substring(x),k=k.substring(x)),x=o(N,k),x!==0&&(s[g][1]=N.substring(N.length-x)+s[g][1],N=N.substring(0,N.length-x),k=k.substring(0,k.length-x))),T===0?s.splice(g-A,T+A,[f,N]):A===0?s.splice(g-T,T+A,[i,k]):s.splice(g-T-A,T+A,[i,k],[f,N]),g=g-T-A+(T?1:0)+(A?1:0)+1):g!==0&&s[g-1][0]==h?(s[g-1][1]+=s[g][1],s.splice(g,1)):g++,A=0,T=0,k="",N="";break}s[s.length-1][1]===""&&s.pop();var E=!1;for(g=1;g0&&A.splice(k+2,0,[x[0],E]),b(A,k,3)}else return s}function u(s){for(var g=!1,T=function(x){return x.charCodeAt(0)>=56320&&x.charCodeAt(0)<=57343},A=function(x){return x.charCodeAt(x.length-1)>=55296&&x.charCodeAt(x.length-1)<=56319},k=2;k0&&N.push(s[k]);return N}function b(s,g,T){for(var A=g+T-1;A>=0&&A>=g-1;A--)if(A+1\r?\n +\<"),this.convert();var ee=this.quill.getFormat(this.quill.selection.savedRange.index);if(ee[A.default.blotName]){var ue=this.container.innerText;return this.container.innerHTML="",new l.default().insert(ue,S({},A.default.blotName,ee[A.default.blotName]))}var he=this.prepareMatching(),ye=h(he,2),qe=ye[0],Re=ye[1],_e=$(this.container,qe,Re);return V(_e,` `)&&_e.ops[_e.ops.length-1].attributes==null&&(_e=_e.compose(new l.default().retain(_e.length()-1).delete(1))),H.log("convert",this.container.innerHTML,_e),this.container.innerHTML="",_e}},{key:"dangerouslyPasteHTML",value:function(te,ee){var ue=arguments.length>2&&arguments[2]!==void 0?arguments[2]:d.default.sources.API;if(typeof te=="string")this.quill.setContents(this.convert(te),ee),this.quill.setSelection(0,d.default.sources.SILENT);else{var he=this.convert(ee);this.quill.updateContents(new l.default().retain(te).concat(he),ue),this.quill.setSelection(te+he.length(),d.default.sources.SILENT)}}},{key:"onPaste",value:function(te){var ee=this;if(!(te.defaultPrevented||!this.quill.isEnabled())){var ue=this.quill.getSelection(),he=new l.default().retain(ue.index),ye=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(d.default.sources.SILENT),setTimeout(function(){he=he.concat(ee.convert()).delete(ue.length),ee.quill.updateContents(he,d.default.sources.USER),ee.quill.setSelection(he.length()-ue.length,d.default.sources.SILENT),ee.quill.scrollingContainer.scrollTop=ye,ee.quill.focus()},1)}}},{key:"prepareMatching",value:function(){var te=this,ee=[],ue=[];return this.matchers.forEach(function(he){var ye=h(he,2),qe=ye[0],Re=ye[1];switch(qe){case Node.TEXT_NODE:ue.push(Re);break;case Node.ELEMENT_NODE:ee.push(Re);break;default:[].forEach.call(te.container.querySelectorAll(qe),function(_e){_e[Q]=_e[Q]||[],_e[Q].push(Re)});break}}),[ee,ue]}}]),U}(b.default);R.DEFAULTS={matchers:[],matchVisual:!0};function j(z,U,G){return(typeof U>"u"?"undefined":f(U))==="object"?Object.keys(U).reduce(function(te,ee){return j(te,ee,U[ee])},z):z.reduce(function(te,ee){return ee.attributes&&ee.attributes[U]?te.push(ee):te.insert(ee.insert,(0,_.default)({},S({},U,G),ee.attributes))},new l.default)}function B(z){if(z.nodeType!==Node.ELEMENT_NODE)return{};var U="__ql-computed-style";return z[U]||(z[U]=window.getComputedStyle(z))}function V(z,U){for(var G="",te=z.ops.length-1;te>=0&&G.length-1}function $(z,U,G){return z.nodeType===z.TEXT_NODE?G.reduce(function(te,ee){return ee(z,te)},new l.default):z.nodeType===z.ELEMENT_NODE?[].reduce.call(z.childNodes||[],function(te,ee){var ue=$(ee,U,G);return ee.nodeType===z.ELEMENT_NODE&&(ue=U.reduce(function(he,ye){return ye(ee,he)},ue),ue=(ee[Q]||[]).reduce(function(he,ye){return ye(ee,he)},ue)),te.concat(ue)},new l.default):new l.default}function Z(z,U,G){return j(G,z,!0)}function W(z,U){var G=a.default.Attributor.Attribute.keys(z),te=a.default.Attributor.Class.keys(z),ee=a.default.Attributor.Style.keys(z),ue={};return G.concat(te).concat(ee).forEach(function(he){var ye=a.default.query(he,a.default.Scope.ATTRIBUTE);ye!=null&&(ue[ye.attrName]=ye.value(z),ue[ye.attrName])||(ye=D[he],ye!=null&&(ye.attrName===he||ye.keyName===he)&&(ue[ye.attrName]=ye.value(z)||void 0),ye=q[he],ye!=null&&(ye.attrName===he||ye.keyName===he)&&(ye=q[he],ue[ye.attrName]=ye.value(z)||void 0))}),Object.keys(ue).length>0&&(U=j(U,ue)),U}function J(z,U){var G=a.default.query(z);if(G==null)return U;if(G.prototype instanceof a.default.Embed){var te={},ee=G.value(z);ee!=null&&(te[G.blotName]=ee,U=new l.default().insert(te,G.formats(z)))}else typeof G.formats=="function"&&(U=j(U,G.blotName,G.formats(z)));return U}function le(z,U){return V(U,` `)||U.insert(` `),U}function de(){return new l.default}function pe(z,U){var G=a.default.query(z);if(G==null||G.blotName!=="list-item"||!V(U,` `))return U;for(var te=-1,ee=z.parentNode;!ee.classList.contains("ql-clipboard");)(a.default.query(ee)||{}).blotName==="list"&&(te+=1),ee=ee.parentNode;return te<=0?U:U.compose(new l.default().retain(U.length()-1).retain(1,{indent:te}))}function ve(z,U){return V(U,` `)||(L(z)||U.length()>0&&z.nextSibling&&L(z.nextSibling))&&U.insert(` `),U}function I(z,U){if(L(z)&&z.nextElementSibling!=null&&!V(U,` `)){var G=z.offsetHeight+parseFloat(B(z).marginTop)+parseFloat(B(z).marginBottom);z.nextElementSibling.offsetTop>z.offsetTop+G*1.5&&U.insert(` `)}return U}function Y(z,U){var G={},te=z.style||{};return te.fontStyle&&B(z).fontStyle==="italic"&&(G.italic=!0),te.fontWeight&&(B(z).fontWeight.startsWith("bold")||parseInt(B(z).fontWeight)>=700)&&(G.bold=!0),Object.keys(G).length>0&&(U=j(U,G)),parseFloat(te.textIndent||0)>0&&(U=new l.default().insert(" ").concat(U)),U}function X(z,U){var G=z.data;if(z.parentNode.tagName==="O:P")return U.insert(G.trim());if(G.trim().length===0&&z.parentNode.classList.contains("ql-clipboard"))return U;if(!B(z.parentNode).whiteSpace.startsWith("pre")){var te=function(ue,he){return he=he.replace(/[^\u00a0]/g,""),he.length<1&&ue?" ":he};G=G.replace(/\r\n/g," ").replace(/\n/g," "),G=G.replace(/\s\s+/g,te.bind(te,!0)),(z.previousSibling==null&&L(z.parentNode)||z.previousSibling!=null&&L(z.previousSibling))&&(G=G.replace(/^\s+/,te.bind(te,!1))),(z.nextSibling==null&&L(z.parentNode)||z.nextSibling!=null&&L(z.nextSibling))&&(G=G.replace(/\s+$/,te.bind(te,!1)))}return U.insert(G)}r.default=R,r.matchAttributor=W,r.matchBlot=J,r.matchNewline=ve,r.matchSpacing=I,r.matchText=X},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function y(d,v){for(var c=0;c '},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function y(d,v){for(var c=0;ca.right&&(d=a.right-y.right,this.root.style.left=l+d+"px"),y.lefta.bottom){var v=y.bottom-y.top,c=p.bottom-p.top+v;this.root.style.top=o-c+"px",this.root.classList.add("ql-flip")}return d}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),m}();r.default=O},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function x(E,w){var S=[],P=!0,F=!1,M=void 0;try{for(var H=E[Symbol.iterator](),Q;!(P=(Q=H.next()).done)&&(S.push(Q.value),!(w&&S.length===w));P=!0);}catch(C){F=!0,M=C}finally{try{!P&&H.return&&H.return()}finally{if(F)throw M}}return S}return function(E,w){if(Array.isArray(E))return E;if(Symbol.iterator in Object(E))return x(E,w);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function x(E,w,S){E===null&&(E=Function.prototype);var P=Object.getOwnPropertyDescriptor(E,w);if(P===void 0){var F=Object.getPrototypeOf(E);return F===null?void 0:x(F,w,S)}else{if("value"in P)return P.value;var M=P.get;return M===void 0?void 0:M.call(S)}},O=function(){function x(E,w){for(var S=0;S','','',''].join(""),r.default=k},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(29),h=ee(f),O=i(36),m=i(38),_=i(64),p=i(65),l=ee(p),o=i(66),a=ee(o),y=i(67),d=ee(y),v=i(37),c=i(26),u=i(39),b=i(40),s=i(56),g=ee(s),T=i(68),A=ee(T),k=i(27),N=ee(k),x=i(69),E=ee(x),w=i(70),S=ee(w),P=i(71),F=ee(P),M=i(72),H=ee(M),Q=i(73),C=ee(Q),D=i(13),q=ee(D),R=i(74),j=ee(R),B=i(75),V=ee(B),L=i(57),$=ee(L),Z=i(41),W=ee(Z),J=i(28),le=ee(J),de=i(59),pe=ee(de),ve=i(60),I=ee(ve),Y=i(61),X=ee(Y),z=i(108),U=ee(z),G=i(62),te=ee(G);function ee(ue){return ue&&ue.__esModule?ue:{default:ue}}h.default.register({"attributors/attribute/direction":m.DirectionAttribute,"attributors/class/align":O.AlignClass,"attributors/class/background":v.BackgroundClass,"attributors/class/color":c.ColorClass,"attributors/class/direction":m.DirectionClass,"attributors/class/font":u.FontClass,"attributors/class/size":b.SizeClass,"attributors/style/align":O.AlignStyle,"attributors/style/background":v.BackgroundStyle,"attributors/style/color":c.ColorStyle,"attributors/style/direction":m.DirectionStyle,"attributors/style/font":u.FontStyle,"attributors/style/size":b.SizeStyle},!0),h.default.register({"formats/align":O.AlignClass,"formats/direction":m.DirectionClass,"formats/indent":_.IndentClass,"formats/background":v.BackgroundStyle,"formats/color":c.ColorStyle,"formats/font":u.FontClass,"formats/size":b.SizeClass,"formats/blockquote":l.default,"formats/code-block":q.default,"formats/header":a.default,"formats/list":d.default,"formats/bold":g.default,"formats/code":D.Code,"formats/italic":A.default,"formats/link":N.default,"formats/script":E.default,"formats/strike":S.default,"formats/underline":F.default,"formats/image":H.default,"formats/video":C.default,"formats/list/item":y.ListItem,"modules/formula":j.default,"modules/syntax":V.default,"modules/toolbar":$.default,"themes/bubble":U.default,"themes/snow":te.default,"ui/icons":W.default,"ui/picker":le.default,"ui/icon-picker":I.default,"ui/color-picker":pe.default,"ui/tooltip":X.default},!0),r.default=h.default},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.IndentClass=void 0;var f=function(){function d(v,c){for(var u=0;u0&&this.children.tail.format(A,k)}},{key:"formats",value:function(){return y({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(A,k){if(A instanceof u)h(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"insertBefore",this).call(this,A,k);else{var N=k==null?this.length():k.offset(this),x=this.split(N);x.parent.insertBefore(A,x)}}},{key:"optimize",value:function(A){h(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"optimize",this).call(this,A);var k=this.next;k!=null&&k.prev===this&&k.statics.blotName===this.statics.blotName&&k.domNode.tagName===this.domNode.tagName&&k.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(k.moveChildren(this),k.remove())}},{key:"replace",value:function(A){if(A.statics.blotName!==this.statics.blotName){var k=m.default.create(this.statics.defaultChild);A.moveChildren(k),this.appendChild(k)}h(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"replace",this).call(this,A)}}]),g}(o.default);b.blotName="list",b.scope=m.default.Scope.BLOCK_BLOT,b.tagName=["OL","UL"],b.defaultChild="list-item",b.allowedChildren=[u],r.ListItem=u,r.default=b},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=i(56),h=O(f);function O(o){return o&&o.__esModule?o:{default:o}}function m(o,a){if(!(o instanceof a))throw new TypeError("Cannot call a class as a function")}function _(o,a){if(!o)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return a&&(typeof a=="object"||typeof a=="function")?a:o}function p(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof a);o.prototype=Object.create(a&&a.prototype,{constructor:{value:o,enumerable:!1,writable:!0,configurable:!0}}),a&&(Object.setPrototypeOf?Object.setPrototypeOf(o,a):o.__proto__=a)}var l=function(o){p(a,o);function a(){return m(this,a),_(this,(a.__proto__||Object.getPrototypeOf(a)).apply(this,arguments))}return a}(h.default);l.blotName="italic",l.tagName=["EM","I"],r.default=l},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function y(d,v){for(var c=0;c-1?s?this.domNode.setAttribute(b,s):this.domNode.removeAttribute(b):h(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"format",this).call(this,b,s)}}],[{key:"create",value:function(b){var s=h(c.__proto__||Object.getPrototypeOf(c),"create",this).call(this,b);return typeof b=="string"&&s.setAttribute("src",this.sanitize(b)),s}},{key:"formats",value:function(b){return y.reduce(function(s,g){return b.hasAttribute(g)&&(s[g]=b.getAttribute(g)),s},{})}},{key:"match",value:function(b){return/\.(jpe?g|gif|png)$/.test(b)||/^data:image\/.+;base64/.test(b)}},{key:"sanitize",value:function(b){return(0,_.sanitize)(b,["http","https","data"])?b:"//:0"}},{key:"value",value:function(b){return b.getAttribute("src")}}]),c}(m.default.Embed);d.blotName="image",d.tagName="IMG",r.default=d},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0});var f=function(){function v(c,u){for(var b=0;b-1?s?this.domNode.setAttribute(b,s):this.domNode.removeAttribute(b):h(c.prototype.__proto__||Object.getPrototypeOf(c.prototype),"format",this).call(this,b,s)}}],[{key:"create",value:function(b){var s=h(c.__proto__||Object.getPrototypeOf(c),"create",this).call(this,b);return s.setAttribute("frameborder","0"),s.setAttribute("allowfullscreen",!0),s.setAttribute("src",this.sanitize(b)),s}},{key:"formats",value:function(b){return y.reduce(function(s,g){return b.hasAttribute(g)&&(s[g]=b.getAttribute(g)),s},{})}},{key:"sanitize",value:function(b){return _.default.sanitize(b)}},{key:"value",value:function(b){return b.getAttribute("src")}}]),c}(O.BlockEmbed);d.blotName="video",d.className="ql-video",d.tagName="IFRAME",r.default=d},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.FormulaBlot=void 0;var f=function(){function b(s,g){for(var T=0;T0||this.cachedText==null)&&(this.domNode.innerHTML=N(x),this.domNode.normalize(),this.attach()),this.cachedText=x)}}]),A}(y.default);b.className="ql-syntax";var s=new m.default.Attributor.Class("token","hljs",{scope:m.default.Scope.INLINE}),g=function(T){u(A,T),f(A,null,[{key:"register",value:function(){p.default.register(s,!0),p.default.register(b,!0)}}]);function A(k,N){v(this,A);var x=c(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,k,N));if(typeof x.options.highlight!="function")throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var E=null;return x.quill.on(p.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(E),E=setTimeout(function(){x.highlight(),E=null},x.options.interval)}),x.highlight(),x}return f(A,[{key:"highlight",value:function(){var N=this;if(!this.quill.selection.composing){this.quill.update(p.default.sources.USER);var x=this.quill.getSelection();this.quill.scroll.descendants(b).forEach(function(E){E.highlight(N.options.highlight)}),this.quill.update(p.default.sources.SILENT),x!=null&&this.quill.setSelection(x,p.default.sources.SILENT)}}}]),A}(o.default);g.DEFAULTS={highlight:function(){return window.hljs==null?null:function(T){var A=window.hljs.highlightAuto(T);return A.value}}(),interval:1e3},r.CodeBlock=b,r.CodeToken=s,r.default=g},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r){t.exports=' '},function(t,r,i){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BubbleTooltip=void 0;var f=function A(k,N,x){k===null&&(k=Function.prototype);var E=Object.getOwnPropertyDescriptor(k,N);if(E===void 0){var w=Object.getPrototypeOf(k);return w===null?void 0:A(w,N,x)}else{if("value"in E)return E.value;var S=E.get;return S===void 0?void 0:S.call(x)}},h=function(){function A(k,N){for(var x=0;x0&&F===p.default.sources.USER){E.show(),E.root.style.left="0px",E.root.style.width="",E.root.style.width=E.root.offsetWidth+"px";var M=E.quill.getLines(S.index,S.length);if(M.length===1)E.position(E.quill.getBounds(S));else{var H=M[M.length-1],Q=E.quill.getIndex(H),C=Math.min(H.length()-1,S.index+S.length-Q),D=E.quill.getBounds(new a.Range(Q,C));E.position(D)}}else document.activeElement!==E.textbox&&E.quill.hasFocus()&&E.hide()}),E}return h(k,[{key:"listen",value:function(){var x=this;f(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){x.root.classList.remove("ql-editing")}),this.quill.on(p.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!x.root.classList.contains("ql-hidden")){var E=x.quill.getSelection();E!=null&&x.position(x.quill.getBounds(E))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(x){var E=f(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"position",this).call(this,x),w=this.root.querySelector(".ql-tooltip-arrow");if(w.style.marginLeft="",E===0)return E;w.style.marginLeft=-1*E-w.offsetWidth/2+"px"}}]),k}(l.BaseTooltip);T.TEMPLATE=['','
','','',"
"].join(""),r.BubbleTooltip=T,r.default=g},function(t,r,i){t.exports=i(63)}]).default})})(ho);var Og=Me&&Me.__extends||function(){var e=function(n,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var f in i)i.hasOwnProperty(f)&&(r[f]=i[f])},e(n,t)};return function(n,t){e(n,t);function r(){this.constructor=n}n.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}}(),Kt=Me&&Me.__assign||function(){return Kt=Object.assign||function(e){for(var n,t=1,r=arguments.length;t1)throw new Error("The Quill editing area can only be composed of a single React element.");if(We.default.Children.count(t.children)){var i=We.default.Children.only(t.children);if(((r=i)===null||r===void 0?void 0:r.type)==="textarea")throw new Error("Quill does not support editing on a