@mmlogic/components 0.3.5 → 0.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{collection/utils/cell-renderer.js → mosterdcomponents/cell-renderer-CbRwLOo8.js} +9 -3
- package/dist/mosterdcomponents/cell-renderer-CbRwLOo8.js.map +1 -0
- package/dist/{esm/index.js → mosterdcomponents/client-layout-D88nn5zf.js} +4 -1
- package/dist/mosterdcomponents/client-layout-D88nn5zf.js.map +1 -0
- package/dist/{collection/utils/format.js → mosterdcomponents/format-BAfsQfy1.js} +12 -7
- package/dist/mosterdcomponents/format-BAfsQfy1.js.map +1 -0
- package/dist/{collection/utils/i18n.js → mosterdcomponents/i18n-hoGGKbKU.js} +6 -1
- package/dist/mosterdcomponents/i18n-hoGGKbKU.js.map +1 -0
- package/dist/mosterdcomponents/index-B_tPFIvS.js +4585 -0
- package/dist/mosterdcomponents/index-B_tPFIvS.js.map +1 -0
- package/dist/mosterdcomponents/index-I5SuYv7a.js +4 -0
- package/dist/mosterdcomponents/index-I5SuYv7a.js.map +1 -0
- package/dist/mosterdcomponents/index.esm.js +5 -1
- package/dist/mosterdcomponents/index.esm.js.map +1 -0
- package/dist/mosterdcomponents/mosterdcomponents.css +180 -1
- package/dist/mosterdcomponents/mosterdcomponents.esm.js +50 -1
- package/dist/mosterdcomponents/mosterdcomponents.esm.js.map +1 -0
- package/dist/mosterdcomponents/mrd-boolean-field.entry.js +37 -0
- package/dist/mosterdcomponents/mrd-boolean-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-currency-field.entry.js +67 -0
- package/dist/mosterdcomponents/mrd-currency-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-date-field.entry.js +46 -0
- package/dist/mosterdcomponents/mrd-date-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-datetime-field.entry.js +78 -0
- package/dist/mosterdcomponents/mrd-datetime-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-email-field.entry.js +50 -0
- package/dist/mosterdcomponents/mrd-email-field.entry.js.map +1 -0
- package/dist/{collection/components/mrd-field/mrd-field.js → mosterdcomponents/mrd-field.entry.js} +28 -179
- package/dist/mosterdcomponents/mrd-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-file-field.entry.js +108 -0
- package/dist/mosterdcomponents/mrd-file-field.entry.js.map +1 -0
- package/dist/{collection/components/mrd-form/mrd-form.js → mosterdcomponents/mrd-form.entry.js} +31 -308
- package/dist/mosterdcomponents/mrd-form.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-hyperlink-field.entry.js +87 -0
- package/dist/mosterdcomponents/mrd-hyperlink-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-image-field.entry.js +122 -0
- package/dist/mosterdcomponents/mrd-image-field.entry.js.map +1 -0
- package/dist/{collection/components/mrd-layout-section/mrd-layout-section.js → mosterdcomponents/mrd-layout-section.entry.js} +31 -418
- package/dist/mosterdcomponents/mrd-layout-section.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-list-field.entry.js +107 -0
- package/dist/mosterdcomponents/mrd-list-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-longtext-field.entry.js +47 -0
- package/dist/mosterdcomponents/mrd-longtext-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-number-field.entry.js +87 -0
- package/dist/mosterdcomponents/mrd-number-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-relation-field.entry.js +267 -0
- package/dist/mosterdcomponents/mrd-relation-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-secret-field.entry.js +49 -0
- package/dist/mosterdcomponents/mrd-secret-field.entry.js.map +1 -0
- package/dist/{collection/components/mrd-table/mrd-table.js → mosterdcomponents/mrd-table.entry.js} +32 -394
- package/dist/mosterdcomponents/mrd-table.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-text-field.entry.js +47 -0
- package/dist/mosterdcomponents/mrd-text-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-textarea-field.entry.js +86 -0
- package/dist/mosterdcomponents/mrd-textarea-field.entry.js.map +1 -0
- package/dist/mosterdcomponents/mrd-time-field.entry.js +46 -0
- package/dist/mosterdcomponents/mrd-time-field.entry.js.map +1 -0
- package/dist/{esm/quill-CiuCgGz_.js → mosterdcomponents/quill-C9pgw_k-.js} +16282 -1397
- package/dist/mosterdcomponents/quill-C9pgw_k-.js.map +1 -0
- package/dist/{collection/utils/validation.js → mosterdcomponents/validation-ixb43cqU.js} +12 -5
- package/dist/mosterdcomponents/validation-ixb43cqU.js.map +1 -0
- package/package.json +1 -1
- package/dist/cjs/app-globals-V2Kpy_OQ.js +0 -5
- package/dist/cjs/index-BPj2cBXs.js +0 -1570
- package/dist/cjs/index.cjs.js +0 -66
- package/dist/cjs/loader.cjs.js +0 -13
- package/dist/cjs/mosterdcomponents.cjs.js +0 -25
- package/dist/cjs/mrd-boolean-field_20.cjs.entry.js +0 -3961
- package/dist/cjs/quill-DmFfnC1f.js +0 -16272
- package/dist/collection/collection-manifest.json +0 -32
- package/dist/collection/components/mrd-boolean-field/mrd-boolean-field.js +0 -199
- package/dist/collection/components/mrd-boolean-field/mrd-boolean-field.scss +0 -77
- package/dist/collection/components/mrd-currency-field/mrd-currency-field.js +0 -248
- package/dist/collection/components/mrd-currency-field/mrd-currency-field.scss +0 -100
- package/dist/collection/components/mrd-date-field/mrd-date-field.js +0 -206
- package/dist/collection/components/mrd-date-field/mrd-date-field.scss +0 -66
- package/dist/collection/components/mrd-datetime-field/mrd-datetime-field.js +0 -240
- package/dist/collection/components/mrd-datetime-field/mrd-datetime-field.scss +0 -66
- package/dist/collection/components/mrd-email-field/mrd-email-field.js +0 -230
- package/dist/collection/components/mrd-email-field/mrd-email-field.scss +0 -69
- package/dist/collection/components/mrd-field/mrd-field.scss +0 -118
- package/dist/collection/components/mrd-file-field/mrd-file-field.js +0 -341
- package/dist/collection/components/mrd-file-field/mrd-file-field.scss +0 -153
- package/dist/collection/components/mrd-form/mrd-form.scss +0 -148
- package/dist/collection/components/mrd-hyperlink-field/mrd-hyperlink-field.js +0 -291
- package/dist/collection/components/mrd-hyperlink-field/mrd-hyperlink-field.scss +0 -91
- package/dist/collection/components/mrd-image-field/mrd-image-field.js +0 -356
- package/dist/collection/components/mrd-image-field/mrd-image-field.scss +0 -190
- package/dist/collection/components/mrd-layout-section/mrd-layout-section.scss +0 -445
- package/dist/collection/components/mrd-list-field/mrd-list-field.js +0 -313
- package/dist/collection/components/mrd-list-field/mrd-list-field.scss +0 -109
- package/dist/collection/components/mrd-longtext-field/mrd-longtext-field.js +0 -227
- package/dist/collection/components/mrd-longtext-field/mrd-longtext-field.scss +0 -78
- package/dist/collection/components/mrd-number-field/mrd-number-field.js +0 -316
- package/dist/collection/components/mrd-number-field/mrd-number-field.scss +0 -77
- package/dist/collection/components/mrd-relation-field/mrd-relation-field.js +0 -707
- package/dist/collection/components/mrd-relation-field/mrd-relation-field.scss +0 -266
- package/dist/collection/components/mrd-secret-field/mrd-secret-field.js +0 -229
- package/dist/collection/components/mrd-secret-field/mrd-secret-field.scss +0 -73
- package/dist/collection/components/mrd-table/mrd-table.scss +0 -809
- package/dist/collection/components/mrd-text-field/mrd-text-field.js +0 -227
- package/dist/collection/components/mrd-text-field/mrd-text-field.scss +0 -69
- package/dist/collection/components/mrd-textarea-field/mrd-textarea-field.js +0 -267
- package/dist/collection/components/mrd-textarea-field/mrd-textarea-field.scss +0 -135
- package/dist/collection/components/mrd-time-field/mrd-time-field.js +0 -206
- package/dist/collection/components/mrd-time-field/mrd-time-field.scss +0 -66
- package/dist/collection/dev/api.js +0 -145
- package/dist/collection/dev/app.js +0 -890
- package/dist/collection/dev/auth.js +0 -156
- package/dist/collection/dev/example-data.js +0 -403
- package/dist/collection/dev/sprites.svg +0 -55
- package/dist/collection/index.js +0 -1
- package/dist/collection/types/client-layout.js +0 -64
- package/dist/collection/types/index.js +0 -1
- package/dist/components/client-layout.js +0 -1
- package/dist/components/format.js +0 -1
- package/dist/components/i18n.js +0 -1
- package/dist/components/index.js +0 -1
- package/dist/components/mrd-boolean-field.js +0 -1
- package/dist/components/mrd-boolean-field2.js +0 -1
- package/dist/components/mrd-currency-field.js +0 -1
- package/dist/components/mrd-currency-field2.js +0 -1
- package/dist/components/mrd-date-field.js +0 -1
- package/dist/components/mrd-date-field2.js +0 -1
- package/dist/components/mrd-datetime-field.js +0 -1
- package/dist/components/mrd-datetime-field2.js +0 -1
- package/dist/components/mrd-email-field.js +0 -1
- package/dist/components/mrd-email-field2.js +0 -1
- package/dist/components/mrd-field.js +0 -1
- package/dist/components/mrd-field2.js +0 -1
- package/dist/components/mrd-file-field.js +0 -1
- package/dist/components/mrd-file-field2.js +0 -1
- package/dist/components/mrd-form.js +0 -1
- package/dist/components/mrd-hyperlink-field.js +0 -1
- package/dist/components/mrd-hyperlink-field2.js +0 -1
- package/dist/components/mrd-image-field.js +0 -1
- package/dist/components/mrd-image-field2.js +0 -1
- package/dist/components/mrd-layout-section.js +0 -1
- package/dist/components/mrd-list-field.js +0 -1
- package/dist/components/mrd-list-field2.js +0 -1
- package/dist/components/mrd-longtext-field.js +0 -1
- package/dist/components/mrd-longtext-field2.js +0 -1
- package/dist/components/mrd-number-field.js +0 -1
- package/dist/components/mrd-number-field2.js +0 -1
- package/dist/components/mrd-relation-field.js +0 -1
- package/dist/components/mrd-relation-field2.js +0 -1
- package/dist/components/mrd-secret-field.js +0 -1
- package/dist/components/mrd-secret-field2.js +0 -1
- package/dist/components/mrd-table.js +0 -1
- package/dist/components/mrd-table2.js +0 -1
- package/dist/components/mrd-text-field.js +0 -1
- package/dist/components/mrd-text-field2.js +0 -1
- package/dist/components/mrd-textarea-field.js +0 -1
- package/dist/components/mrd-textarea-field2.js +0 -1
- package/dist/components/mrd-time-field.js +0 -1
- package/dist/components/mrd-time-field2.js +0 -1
- package/dist/components/quill.js +0 -1
- package/dist/components/validation.js +0 -1
- package/dist/esm/app-globals-DQuL1Twl.js +0 -3
- package/dist/esm/index-_tsCCkAi.js +0 -1561
- package/dist/esm/loader.js +0 -11
- package/dist/esm/mosterdcomponents.js +0 -21
- package/dist/esm/mrd-boolean-field_20.entry.js +0 -3940
- package/dist/index.cjs.js +0 -1
- package/dist/index.js +0 -1
- package/dist/mosterdcomponents/p-CiuCgGz_.js +0 -1
- package/dist/mosterdcomponents/p-DQuL1Twl.js +0 -1
- package/dist/mosterdcomponents/p-_tsCCkAi.js +0 -2
- package/dist/mosterdcomponents/p-e477187c.entry.js +0 -1
package/dist/index.cjs.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require('./cjs/index.cjs.js');
|
package/dist/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './esm/index.js';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var t="object"==typeof global&&global&&global.Object===Object&&global,e="object"==typeof self&&self&&self.Object===Object&&self,i=t||e||Function("return this")(),n=i.Symbol,s=Object.prototype,r=s.hasOwnProperty,o=s.toString,l=n?n.toStringTag:void 0,c=Object.prototype.toString,u=n?n.toStringTag:void 0;function h(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":u&&u in Object(t)?function(t){var e=r.call(t,l),i=t[l];try{t[l]=void 0;var n=!0}catch(t){}var s=o.call(t);return n&&(e?t[l]=i:delete t[l]),s}(t):function(t){return c.call(t)}(t)}function a(t){return null!=t&&"object"==typeof t}var f=Array.isArray;function d(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function p(t){return t}function b(t){if(!d(t))return!1;var e=h(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}var v,y=i["__core-js_shared__"],m=(v=/[^.]+$/.exec(y&&y.keys&&y.keys.IE_PROTO||""))?"Symbol(src)_1."+v:"",w=Function.prototype.toString;function g(t){if(null!=t){try{return w.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var x=/^\[object .+?Constructor\]$/,k=RegExp("^"+Function.prototype.toString.call(Object.prototype.hasOwnProperty).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function j(t,e){var i=function(t,e){return null==t?void 0:t[e]}(t,e);return function(t){return!(!d(t)||(e=t,m&&m in e))&&(b(t)?k:x).test(g(t));var e}(i)?i:void 0}var A,q,O,M=j(i,"WeakMap"),E=Object.create,T=function(){function t(){}return function(e){if(!d(e))return{};if(E)return E(e);t.prototype=e;var i=new t;return t.prototype=void 0,i}}(),N=Date.now,L=function(){try{var t=j(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),$=L?function(t,e){return L(t,"toString",{configurable:!0,enumerable:!1,value:(i=e,function(){return i}),writable:!0});var i}:p,_=(A=$,q=0,O=0,function(){var t=N(),e=16-(t-O);if(O=t,e>0){if(++q>=800)return arguments[0]}else q=0;return A.apply(void 0,arguments)}),S=/^(?:0|[1-9]\d*)$/;function C(t,e){var i=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==i||"symbol"!=i&&S.test(t))&&t>-1&&t%1==0&&t<e}function B(t,e,i){"__proto__"==e&&L?L(t,e,{configurable:!0,enumerable:!0,value:i,writable:!0}):t[e]=i}function R(t,e){return t===e||t!=t&&e!=e}var I=Object.prototype.hasOwnProperty;function D(t,e,i){var n=t[e];I.call(t,e)&&R(n,i)&&(void 0!==i||e in t)||B(t,e,i)}var V=Math.max;function H(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}function P(t){return null!=t&&H(t.length)&&!b(t)}var F=Object.prototype;function U(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||F)}function Z(t){return a(t)&&"[object Arguments]"==h(t)}var K=Object.prototype,z=K.hasOwnProperty,W=K.propertyIsEnumerable,G=Z(function(){return arguments}())?Z:function(t){return a(t)&&z.call(t,"callee")&&!W.call(t,"callee")},Q="object"==typeof exports&&exports&&!exports.nodeType&&exports,Y=Q&&"object"==typeof module&&module&&!module.nodeType&&module,X=Y&&Y.exports===Q?i.Buffer:void 0,J=(X?X.isBuffer:void 0)||function(){return!1},tt={};function et(t){return function(e){return t(e)}}tt["[object Float32Array]"]=tt["[object Float64Array]"]=tt["[object Int8Array]"]=tt["[object Int16Array]"]=tt["[object Int32Array]"]=tt["[object Uint8Array]"]=tt["[object Uint8ClampedArray]"]=tt["[object Uint16Array]"]=tt["[object Uint32Array]"]=!0,tt["[object Arguments]"]=tt["[object Array]"]=tt["[object ArrayBuffer]"]=tt["[object Boolean]"]=tt["[object DataView]"]=tt["[object Date]"]=tt["[object Error]"]=tt["[object Function]"]=tt["[object Map]"]=tt["[object Number]"]=tt["[object Object]"]=tt["[object RegExp]"]=tt["[object Set]"]=tt["[object String]"]=tt["[object WeakMap]"]=!1;var it="object"==typeof exports&&exports&&!exports.nodeType&&exports,nt=it&&"object"==typeof module&&module&&!module.nodeType&&module,st=nt&&nt.exports===it&&t.process,rt=function(){try{return nt&&nt.require&&nt.require("util").types||st&&st.binding&&st.binding("util")}catch(t){}}(),ot=rt&&rt.isTypedArray,lt=ot?et(ot):function(t){return a(t)&&H(t.length)&&!!tt[h(t)]},ct=Object.prototype.hasOwnProperty;function ut(t,e){var i=f(t),n=!i&&G(t),s=!i&&!n&&J(t),r=!i&&!n&&!s&<(t),o=i||n||s||r,l=o?function(t,e){for(var i=-1,n=Array(t);++i<t;)n[i]=e(i);return n}(t.length,String):[],c=l.length;for(var u in t)!e&&!ct.call(t,u)||o&&("length"==u||s&&("offset"==u||"parent"==u)||r&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||C(u,c))||l.push(u);return l}function ht(t,e){return function(i){return t(e(i))}}var at=ht(Object.keys,Object),ft=Object.prototype.hasOwnProperty;function dt(t){return P(t)?ut(t):function(t){if(!U(t))return at(t);var e=[];for(var i in Object(t))ft.call(t,i)&&"constructor"!=i&&e.push(i);return e}(t)}var pt=Object.prototype.hasOwnProperty;function bt(t){return P(t)?ut(t,!0):function(t){if(!d(t))return function(t){var e=[];if(null!=t)for(var i in Object(t))e.push(i);return e}(t);var e=U(t),i=[];for(var n in t)("constructor"!=n||!e&&pt.call(t,n))&&i.push(n);return i}(t)}var vt=j(Object,"create"),yt=Object.prototype.hasOwnProperty,mt=Object.prototype.hasOwnProperty;function wt(t){var e=-1,i=null==t?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function gt(t,e){for(var i=t.length;i--;)if(R(t[i][0],e))return i;return-1}wt.prototype.clear=function(){this.__data__=vt?vt(null):{},this.size=0},wt.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},wt.prototype.get=function(t){var e=this.__data__;if(vt){var i=e[t];return"__lodash_hash_undefined__"===i?void 0:i}return yt.call(e,t)?e[t]:void 0},wt.prototype.has=function(t){var e=this.__data__;return vt?void 0!==e[t]:mt.call(e,t)},wt.prototype.set=function(t,e){var i=this.__data__;return this.size+=this.has(t)?0:1,i[t]=vt&&void 0===e?"__lodash_hash_undefined__":e,this};var xt=Array.prototype.splice;function kt(t){var e=-1,i=null==t?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}kt.prototype.clear=function(){this.__data__=[],this.size=0},kt.prototype.delete=function(t){var e=this.__data__,i=gt(e,t);return!(i<0||(i==e.length-1?e.pop():xt.call(e,i,1),--this.size,0))},kt.prototype.get=function(t){var e=this.__data__,i=gt(e,t);return i<0?void 0:e[i][1]},kt.prototype.has=function(t){return gt(this.__data__,t)>-1},kt.prototype.set=function(t,e){var i=this.__data__,n=gt(i,t);return n<0?(++this.size,i.push([t,e])):i[n][1]=e,this};var jt=j(i,"Map");function At(t,e){var i,n,s=t.__data__;return("string"==(n=typeof(i=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==i:null===i)?s["string"==typeof e?"string":"hash"]:s.map}function qt(t){var e=-1,i=null==t?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}qt.prototype.clear=function(){this.size=0,this.__data__={hash:new wt,map:new(jt||kt),string:new wt}},qt.prototype.delete=function(t){var e=At(this,t).delete(t);return this.size-=e?1:0,e},qt.prototype.get=function(t){return At(this,t).get(t)},qt.prototype.has=function(t){return At(this,t).has(t)},qt.prototype.set=function(t,e){var i=At(this,t),n=i.size;return i.set(t,e),this.size+=i.size==n?0:1,this};var Ot=ht(Object.getPrototypeOf,Object),Mt=Function.prototype.toString,Et=Object.prototype.hasOwnProperty,Tt=Mt.call(Object);function Nt(t){var e=this.__data__=new kt(t);this.size=e.size}Nt.prototype.clear=function(){this.__data__=new kt,this.size=0},Nt.prototype.delete=function(t){var e=this.__data__,i=e.delete(t);return this.size=e.size,i},Nt.prototype.get=function(t){return this.__data__.get(t)},Nt.prototype.has=function(t){return this.__data__.has(t)},Nt.prototype.set=function(t,e){var i=this.__data__;if(i instanceof kt){var n=i.__data__;if(!jt||n.length<199)return n.push([t,e]),this.size=++i.size,this;i=this.__data__=new qt(n)}return i.set(t,e),this.size=i.size,this};var Lt="object"==typeof exports&&exports&&!exports.nodeType&&exports,$t=Lt&&"object"==typeof module&&module&&!module.nodeType&&module,_t=$t&&$t.exports===Lt?i.Buffer:void 0,St=_t?_t.allocUnsafe:void 0;function Ct(t,e){if(e)return t.slice();var i=t.length,n=St?St(i):new t.constructor(i);return t.copy(n),n}var Bt=Object.prototype.propertyIsEnumerable,Rt=Object.getOwnPropertySymbols,It=Rt?function(t){return null==t?[]:(t=Object(t),function(e){for(var i=-1,n=null==e?0:e.length,s=0,r=[];++i<n;){var o=e[i];Bt.call(t,o)&&(r[s++]=o)}return r}(Rt(t)))}:function(){return[]};function Dt(t){return function(t,e,i){var n=dt(t);return f(t)?n:function(t,e){for(var i=-1,n=e.length,s=t.length;++i<n;)t[s+i]=e[i];return t}(n,i(t))}(t,0,It)}var Vt=j(i,"DataView"),Ht=j(i,"Promise"),Pt=j(i,"Set"),Ft="[object Map]",Ut="[object Promise]",Zt="[object Set]",Kt="[object WeakMap]",zt="[object DataView]",Wt=g(Vt),Gt=g(jt),Qt=g(Ht),Yt=g(Pt),Xt=g(M),Jt=h;(Vt&&Jt(new Vt(new ArrayBuffer(1)))!=zt||jt&&Jt(new jt)!=Ft||Ht&&Jt(Ht.resolve())!=Ut||Pt&&Jt(new Pt)!=Zt||M&&Jt(new M)!=Kt)&&(Jt=function(t){var e=h(t),i="[object Object]"==e?t.constructor:void 0,n=i?g(i):"";if(n)switch(n){case Wt:return zt;case Gt:return Ft;case Qt:return Ut;case Yt:return Zt;case Xt:return Kt}return e});var te=Object.prototype.hasOwnProperty,ee=i.Uint8Array;function ie(t){var e=new t.constructor(t.byteLength);return new ee(e).set(new ee(t)),e}var ne=/\w*$/,se=n?n.prototype:void 0,re=se?se.valueOf:void 0;function oe(t,e){var i=e?ie(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.length)}function le(t){return"function"!=typeof t.constructor||U(t)?{}:T(Ot(t))}var ce=rt&&rt.isMap,ue=ce?et(ce):function(t){return a(t)&&"[object Map]"==Jt(t)},he=rt&&rt.isSet,ae=he?et(he):function(t){return a(t)&&"[object Set]"==Jt(t)},fe="[object Arguments]",de="[object Function]",pe="[object Object]",be={};function ve(t,e,i,n,s,r){var o,l=1&e;if(void 0!==o)return o;if(!d(t))return t;var c=f(t);if(c)o=function(t){var e=t.length,i=new t.constructor(e);return e&&"string"==typeof t[0]&&te.call(t,"index")&&(i.index=t.index,i.input=t.input),i}(t);else{var u=Jt(t),h=u==de||"[object GeneratorFunction]"==u;if(J(t))return Ct(t,l);if(u==pe||u==fe||h&&!s)o=h?{}:le(t);else{if(!be[u])return s?t:{};o=function(t,e,i){var n,s,r,o,l=t.constructor;switch(e){case"[object ArrayBuffer]":return ie(t);case"[object Boolean]":case"[object Date]":return new l(+t);case"[object DataView]":return o=ie((r=t).buffer),new r.constructor(o,r.byteOffset,r.byteLength);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return oe(t,i);case"[object Map]":case"[object Set]":return new l;case"[object Number]":case"[object String]":return new l(t);case"[object RegExp]":return(s=new(n=t).constructor(n.source,ne.exec(n))).lastIndex=n.lastIndex,s;case"[object Symbol]":return re?Object(re.call(t)):{}}}(t,u,l)}}r||(r=new Nt);var a=r.get(t);if(a)return a;r.set(t,o),ae(t)?t.forEach((function(n){o.add(ve(n,e,i,0,t,r))})):ue(t)&&t.forEach((function(n,s){o.set(s,ve(n,e,i,0,t,r))}));var p=c?void 0:Dt(t);return function(t,e){for(var i=-1,n=null==t?0:t.length;++i<n&&!1!==e(t[i],i););}(p||t,(function(n,s){p&&(n=t[s=n]),D(o,s,ve(n,e,i,0,t,r))})),o}function ye(t){return ve(t,5)}function me(t){var e=-1,i=null==t?0:t.length;for(this.__data__=new qt;++e<i;)this.add(t[e])}function we(t,e){for(var i=-1,n=null==t?0:t.length;++i<n;)if(e(t[i],i,t))return!0;return!1}function ge(t,e,i,n,s,r){var o=1&i,l=t.length,c=e.length;if(l!=c&&!(o&&c>l))return!1;var u=r.get(t),h=r.get(e);if(u&&h)return u==e&&h==t;var a=-1,f=!0,d=2&i?new me:void 0;for(r.set(t,e),r.set(e,t);++a<l;){var p=t[a],b=e[a];if(n)var v=o?n(b,p,a,e,t,r):n(p,b,a,t,e,r);if(void 0!==v){if(v)continue;f=!1;break}if(d){if(!we(e,(function(t,e){if(!d.has(e)&&(p===t||s(p,t,i,n,r)))return d.push(e)}))){f=!1;break}}else if(p!==b&&!s(p,b,i,n,r)){f=!1;break}}return r.delete(t),r.delete(e),f}function xe(t){var e=-1,i=Array(t.size);return t.forEach((function(t,n){i[++e]=[n,t]})),i}function ke(t){var e=-1,i=Array(t.size);return t.forEach((function(t){i[++e]=t})),i}be[fe]=be["[object Array]"]=be["[object ArrayBuffer]"]=be["[object DataView]"]=be["[object Boolean]"]=be["[object Date]"]=be["[object Float32Array]"]=be["[object Float64Array]"]=be["[object Int8Array]"]=be["[object Int16Array]"]=be["[object Int32Array]"]=be["[object Map]"]=be["[object Number]"]=be[pe]=be["[object RegExp]"]=be["[object Set]"]=be["[object String]"]=be["[object Symbol]"]=be["[object Uint8Array]"]=be["[object Uint8ClampedArray]"]=be["[object Uint16Array]"]=be["[object Uint32Array]"]=!0,be["[object Error]"]=be[de]=be["[object WeakMap]"]=!1,me.prototype.add=me.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},me.prototype.has=function(t){return this.__data__.has(t)};var je=n?n.prototype:void 0,Ae=je?je.valueOf:void 0,qe=Object.prototype.hasOwnProperty,Oe="[object Arguments]",Me="[object Array]",Ee="[object Object]",Te=Object.prototype.hasOwnProperty;function Ne(t,e,i,n,s){return t===e||(null==t||null==e||!a(t)&&!a(e)?t!=t&&e!=e:function(t,e,i,n,s,r){var o=f(t),l=f(e),c=o?Me:Jt(t),u=l?Me:Jt(e),h=(c=c==Oe?Ee:c)==Ee,a=(u=u==Oe?Ee:u)==Ee,d=c==u;if(d&&J(t)){if(!J(e))return!1;o=!0,h=!1}if(d&&!h)return r||(r=new Nt),o||lt(t)?ge(t,e,i,n,s,r):function(t,e,i,n,s,r,o){switch(i){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!r(new ee(t),new ee(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return R(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var l=xe;case"[object Set]":if(l||(l=ke),t.size!=e.size&&!(1&n))return!1;var c=o.get(t);if(c)return c==e;n|=2,o.set(t,e);var u=ge(l(t),l(e),n,s,r,o);return o.delete(t),u;case"[object Symbol]":if(Ae)return Ae.call(t)==Ae.call(e)}return!1}(t,e,c,i,n,s,r);if(!(1&i)){var p=h&&Te.call(t,"__wrapped__"),b=a&&Te.call(e,"__wrapped__");if(p||b){var v=p?t.value():t,y=b?e.value():e;return r||(r=new Nt),s(v,y,i,n,r)}}return!!d&&(r||(r=new Nt),function(t,e,i,n,s,r){var o=1&i,l=Dt(t),c=l.length;if(c!=Dt(e).length&&!o)return!1;for(var u=c;u--;){var h=l[u];if(!(o?h in e:qe.call(e,h)))return!1}var a=r.get(t),f=r.get(e);if(a&&f)return a==e&&f==t;var d=!0;r.set(t,e),r.set(e,t);for(var p=o;++u<c;){var b=t[h=l[u]],v=e[h];if(n)var y=o?n(v,b,h,e,t,r):n(b,v,h,t,e,r);if(!(void 0===y?b===v||s(b,v,i,n,r):y)){d=!1;break}p||(p="constructor"==h)}if(d&&!p){var m=t.constructor,w=e.constructor;m==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof m&&m instanceof m&&"function"==typeof w&&w instanceof w||(d=!1)}return r.delete(t),r.delete(e),d}(t,e,i,n,s,r))}(t,e,i,n,Ne,s))}function Le(t,e,i){(void 0!==i&&!R(t[e],i)||void 0===i&&!(e in t))&&B(t,e,i)}function $e(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}function _e(t,e,i,n,s,r,o){var l=$e(t,i),c=$e(e,i),u=o.get(c);if(u)Le(t,i,u);else{var p,v=r?r(l,c,i+"",t,e,o):void 0,y=void 0===v;if(y){var m=f(c),w=!m&&J(c),g=!m&&!w&<(c);v=c,m||w||g?f(l)?v=l:a(p=l)&&P(p)?v=function(t,e){var i=-1,n=t.length;for(e||(e=Array(n));++i<n;)e[i]=t[i];return e}(l):w?(y=!1,v=Ct(c,!0)):g?(y=!1,v=oe(c,!0)):v=[]:function(t){if(!a(t)||"[object Object]"!=h(t))return!1;var e=Ot(t);if(null===e)return!0;var i=Et.call(e,"constructor")&&e.constructor;return"function"==typeof i&&i instanceof i&&Mt.call(i)==Tt}(c)||G(c)?(v=l,G(l)?v=function(t){return function(t,e,i){var n=!i;i||(i={});for(var s=-1,r=e.length;++s<r;){var o=e[s],l=void 0;void 0===l&&(l=t[o]),n?B(i,o,l):D(i,o,l)}return i}(t,bt(t))}(l):d(l)&&!b(l)||(v=le(c))):y=!1}y&&(o.set(c,v),s(v,c,n,r,o),o.delete(c)),Le(t,i,v)}}function Se(t,e,i,n,s){t!==e&&function(t,e,i){for(var n=-1,s=Object(t),r=i(t),o=r.length;o--;){var l=r[++n];if(!1===e(s[l],l,s))break}}(e,(function(r,o){if(s||(s=new Nt),d(r))_e(t,e,o,i,Se,n,s);else{var l=n?n($e(t,o),r,o+"",t,e,s):void 0;void 0===l&&(l=r),Le(t,o,l)}}),bt)}function Ce(t,e){return Ne(t,e)}var Be,Re=(Be=function(t,e,i){Se(t,e,i)},function(t,e){return _(function(t,e,i){return e=V(void 0===e?t.length-1:e,0),function(){for(var n=arguments,s=-1,r=V(n.length-e,0),o=Array(r);++s<r;)o[s]=n[e+s];s=-1;for(var l=Array(e+1);++s<e;)l[s]=n[s];return l[e]=i(o),function(t,e,i){switch(i.length){case 0:return t.call(e);case 1:return t.call(e,i[0]);case 2:return t.call(e,i[0],i[1]);case 3:return t.call(e,i[0],i[1],i[2])}return t.apply(e,i)}(t,this,l)}}(t,e,p),t+"")}((function(t,e){var i=-1,n=e.length,s=n>1?e[n-1]:void 0,r=n>2?e[2]:void 0;for(s=Be.length>3&&"function"==typeof s?(n--,s):void 0,r&&function(t,e,i){if(!d(i))return!1;var n=typeof e;return!!("number"==n?P(i)&&C(e,i.length):"string"==n&&e in i)&&R(i[e],t)}(e[0],e[1],r)&&(s=n<3?void 0:s,n=1),t=Object(t);++i<n;){var o=e[i];o&&Be(t,o,i)}return t}))),Ie=(t=>(t[t.TYPE=3]="TYPE",t[t.LEVEL=12]="LEVEL",t[t.ATTRIBUTE=13]="ATTRIBUTE",t[t.BLOT=14]="BLOT",t[t.INLINE=7]="INLINE",t[t.BLOCK=11]="BLOCK",t[t.BLOCK_BLOT=10]="BLOCK_BLOT",t[t.INLINE_BLOT=6]="INLINE_BLOT",t[t.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",t[t.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",t[t.ANY=15]="ANY",t))(Ie||{});class De{constructor(t,e,i={}){this.attrName=t,this.keyName=e,this.scope=null!=i.scope?i.scope&Ie.LEVEL|Ie.TYPE&Ie.ATTRIBUTE:Ie.ATTRIBUTE,null!=i.whitelist&&(this.whitelist=i.whitelist)}static keys(t){return Array.from(t.attributes).map((t=>t.name))}add(t,e){return!!this.canAdd(t,e)&&(t.setAttribute(this.keyName,e),!0)}canAdd(t,e){return null==this.whitelist||("string"==typeof e?this.whitelist.indexOf(e.replace(/["']/g,""))>-1:this.whitelist.indexOf(e)>-1)}remove(t){t.removeAttribute(this.keyName)}value(t){const e=t.getAttribute(this.keyName);return this.canAdd(t,e)&&e?e:""}}class Ve extends Error{constructor(t){super(t="[Parchment] "+t),this.message=t,this.name=this.constructor.name}}const He=class t{constructor(){this.attributes={},this.classes={},this.tags={},this.types={}}static find(t,e=!1){if(null==t)return null;if(this.blots.has(t))return this.blots.get(t)||null;if(e){let i=null;try{i=t.parentNode}catch{return null}return this.find(i,e)}return null}create(e,i,n){const s=this.query(i);if(null==s)throw new Ve(`Unable to create ${i} blot`);const r=s,o=i instanceof Node||i.nodeType===Node.TEXT_NODE?i:r.create(n),l=new r(e,o,n);return t.blots.set(l.domNode,l),l}find(e,i=!1){return t.find(e,i)}query(t,e=Ie.ANY){let i;return"string"==typeof t?i=this.types[t]||this.attributes[t]:t instanceof Text||t.nodeType===Node.TEXT_NODE?i=this.types.text:"number"==typeof t?t&Ie.LEVEL&Ie.BLOCK?i=this.types.block:t&Ie.LEVEL&Ie.INLINE&&(i=this.types.inline):t instanceof Element&&((t.getAttribute("class")||"").split(/\s+/).some((t=>(i=this.classes[t],!!i))),i=i||this.tags[t.tagName]),null==i?null:"scope"in i&&e&Ie.LEVEL&i.scope&&e&Ie.TYPE&i.scope?i:null}register(...t){return t.map((t=>{const e="blotName"in t,i="attrName"in t;if(!e&&!i)throw new Ve("Invalid definition");if(e&&"abstract"===t.blotName)throw new Ve("Cannot register abstract class");return this.types[e?t.blotName:i?t.attrName:void 0]=t,i?"string"==typeof t.keyName&&(this.attributes[t.keyName]=t):e&&(t.className&&(this.classes[t.className]=t),t.tagName&&(t.tagName=Array.isArray(t.tagName)?t.tagName.map((t=>t.toUpperCase())):t.tagName.toUpperCase(),(Array.isArray(t.tagName)?t.tagName:[t.tagName]).forEach((e=>{(null==this.tags[e]||null==t.className)&&(this.tags[e]=t)})))),t}))}};He.blots=new WeakMap;let Pe=He;function Fe(t,e){return(t.getAttribute("class")||"").split(/\s+/).filter((t=>0===t.indexOf(`${e}-`)))}const Ue=class extends De{static keys(t){return(t.getAttribute("class")||"").split(/\s+/).map((t=>t.split("-").slice(0,-1).join("-")))}add(t,e){return!!this.canAdd(t,e)&&(this.remove(t),t.classList.add(`${this.keyName}-${e}`),!0)}remove(t){Fe(t,this.keyName).forEach((e=>{t.classList.remove(e)})),0===t.classList.length&&t.removeAttribute("class")}value(t){const e=(Fe(t,this.keyName)[0]||"").slice(this.keyName.length+1);return this.canAdd(t,e)?e:""}};function Ze(t){const e=t.split("-"),i=e.slice(1).map((t=>t[0].toUpperCase()+t.slice(1))).join("");return e[0]+i}const Ke=class extends De{static keys(t){return(t.getAttribute("style")||"").split(";").map((t=>t.split(":")[0].trim()))}add(t,e){return!!this.canAdd(t,e)&&(t.style[Ze(this.keyName)]=e,!0)}remove(t){t.style[Ze(this.keyName)]="",t.getAttribute("style")||t.removeAttribute("style")}value(t){const e=t.style[Ze(this.keyName)];return this.canAdd(t,e)?e:""}},ze=class{constructor(t){this.attributes={},this.domNode=t,this.build()}attribute(t,e){e?t.add(this.domNode,e)&&(null!=t.value(this.domNode)?this.attributes[t.attrName]=t:delete this.attributes[t.attrName]):(t.remove(this.domNode),delete this.attributes[t.attrName])}build(){this.attributes={};const t=Pe.find(this.domNode);if(null==t)return;const e=De.keys(this.domNode),i=Ue.keys(this.domNode),n=Ke.keys(this.domNode);e.concat(i).concat(n).forEach((e=>{const i=t.scroll.query(e,Ie.ATTRIBUTE);i instanceof De&&(this.attributes[i.attrName]=i)}))}copy(t){Object.keys(this.attributes).forEach((e=>{const i=this.attributes[e].value(this.domNode);t.format(e,i)}))}move(t){this.copy(t),Object.keys(this.attributes).forEach((t=>{this.attributes[t].remove(this.domNode)})),this.attributes={}}values(){return Object.keys(this.attributes).reduce(((t,e)=>(t[e]=this.attributes[e].value(this.domNode),t)),{})}},We=class{constructor(t,e){this.scroll=t,this.domNode=e,Pe.blots.set(e,this),this.prev=null,this.next=null}static create(t){if(null==this.tagName)throw new Ve("Blot definition missing tagName");let e,i;return Array.isArray(this.tagName)?("string"==typeof t?(i=t.toUpperCase(),parseInt(i,10).toString()===i&&(i=parseInt(i,10))):"number"==typeof t&&(i=t),e="number"==typeof i?document.createElement(this.tagName[i-1]):i&&this.tagName.indexOf(i)>-1?document.createElement(i):document.createElement(this.tagName[0])):e=document.createElement(this.tagName),this.className&&e.classList.add(this.className),e}get statics(){return this.constructor}attach(){}clone(){const t=this.domNode.cloneNode(!1);return this.scroll.create(t)}detach(){null!=this.parent&&this.parent.removeChild(this),Pe.blots.delete(this.domNode)}deleteAt(t,e){this.isolate(t,e).remove()}formatAt(t,e,i,n){const s=this.isolate(t,e);if(null!=this.scroll.query(i,Ie.BLOT)&&n)s.wrap(i,n);else if(null!=this.scroll.query(i,Ie.ATTRIBUTE)){const t=this.scroll.create(this.statics.scope);s.wrap(t),t.format(i,n)}}insertAt(t,e,i){const n=null==i?this.scroll.create("text",e):this.scroll.create(e,i),s=this.split(t);this.parent.insertBefore(n,s||void 0)}isolate(t,e){const i=this.split(t);if(null==i)throw new Error("Attempt to isolate at end");return i.split(e),i}length(){return 1}offset(t=this.parent){return null==this.parent||this===t?0:this.parent.children.offset(this)+this.parent.offset(t)}optimize(t){this.statics.requiredContainer&&!(this.parent instanceof this.statics.requiredContainer)&&this.wrap(this.statics.requiredContainer.blotName)}remove(){null!=this.domNode.parentNode&&this.domNode.parentNode.removeChild(this.domNode),this.detach()}replaceWith(t,e){const i="string"==typeof t?this.scroll.create(t,e):t;return null!=this.parent&&(this.parent.insertBefore(i,this.next||void 0),this.remove()),i}split(t,e){return 0===t?this:this.next}update(t,e){}wrap(t,e){const i="string"==typeof t?this.scroll.create(t,e):t;if(null!=this.parent&&this.parent.insertBefore(i,this.next||void 0),"function"!=typeof i.appendChild)throw new Ve(`Cannot wrap ${t}`);return i.appendChild(this),i}};We.blotName="abstract";let Ge=We;const Qe=class extends Ge{static value(t){return!0}index(t,e){return this.domNode===t||this.domNode.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(e,1):-1}position(t,e){let i=Array.from(this.parent.domNode.childNodes).indexOf(this.domNode);return t>0&&(i+=1),[this.parent.domNode,i]}value(){return{[this.statics.blotName]:this.statics.value(this.domNode)||!0}}};Qe.scope=Ie.INLINE_BLOT;const Ye=Qe;class Xe{constructor(){this.head=null,this.tail=null,this.length=0}append(...t){if(this.insertBefore(t[0],null),t.length>1){const e=t.slice(1);this.append(...e)}}at(t){const e=this.iterator();let i=e();for(;i&&t>0;)t-=1,i=e();return i}contains(t){const e=this.iterator();let i=e();for(;i;){if(i===t)return!0;i=e()}return!1}indexOf(t){const e=this.iterator();let i=e(),n=0;for(;i;){if(i===t)return n;n+=1,i=e()}return-1}insertBefore(t,e){null!=t&&(this.remove(t),t.next=e,null!=e?(t.prev=e.prev,null!=e.prev&&(e.prev.next=t),e.prev=t,e===this.head&&(this.head=t)):null!=this.tail?(this.tail.next=t,t.prev=this.tail,this.tail=t):(t.prev=null,this.head=this.tail=t),this.length+=1)}offset(t){let e=0,i=this.head;for(;null!=i;){if(i===t)return e;e+=i.length(),i=i.next}return-1}remove(t){this.contains(t)&&(null!=t.prev&&(t.prev.next=t.next),null!=t.next&&(t.next.prev=t.prev),t===this.head&&(this.head=t.next),t===this.tail&&(this.tail=t.prev),this.length-=1)}iterator(t=this.head){return()=>{const e=t;return null!=t&&(t=t.next),e}}find(t,e=!1){const i=this.iterator();let n=i();for(;n;){const s=n.length();if(t<s||e&&t===s&&(null==n.next||0!==n.next.length()))return[n,t];t-=s,n=i()}return[null,0]}forEach(t){const e=this.iterator();let i=e();for(;i;)t(i),i=e()}forEachAt(t,e,i){if(e<=0)return;const[n,s]=this.find(t);let r=t-s;const o=this.iterator(n);let l=o();for(;l&&r<t+e;){const n=l.length();t>r?i(l,t-r,Math.min(e,r+n-t)):i(l,0,Math.min(n,t+e-r)),r+=n,l=o()}}map(t){return this.reduce(((e,i)=>(e.push(t(i)),e)),[])}reduce(t,e){const i=this.iterator();let n=i();for(;n;)e=t(e,n),n=i();return e}}function Je(t,e){const i=e.find(t);if(i)return i;try{return e.create(t)}catch{const i=e.create(Ie.INLINE);return Array.from(t.childNodes).forEach((t=>{i.domNode.appendChild(t)})),t.parentNode&&t.parentNode.replaceChild(i.domNode,t),i.attach(),i}}const ti=class t extends Ge{constructor(t,e){super(t,e),this.uiNode=null,this.build()}appendChild(t){this.insertBefore(t)}attach(){super.attach(),this.children.forEach((t=>{t.attach()}))}attachUI(e){null!=this.uiNode&&this.uiNode.remove(),this.uiNode=e,t.uiClass&&this.uiNode.classList.add(t.uiClass),this.uiNode.setAttribute("contenteditable","false"),this.domNode.insertBefore(this.uiNode,this.domNode.firstChild)}build(){this.children=new Xe,Array.from(this.domNode.childNodes).filter((t=>t!==this.uiNode)).reverse().forEach((t=>{try{const e=Je(t,this.scroll);this.insertBefore(e,this.children.head||void 0)}catch(t){if(t instanceof Ve)return;throw t}}))}deleteAt(t,e){if(0===t&&e===this.length())return this.remove();this.children.forEachAt(t,e,((t,e,i)=>{t.deleteAt(e,i)}))}descendant(e,i=0){const[n,s]=this.children.find(i);return null==e.blotName&&e(n)||null!=e.blotName&&n instanceof e?[n,s]:n instanceof t?n.descendant(e,s):[null,-1]}descendants(e,i=0,n=Number.MAX_VALUE){let s=[],r=n;return this.children.forEachAt(i,n,((i,n,o)=>{(null==e.blotName&&e(i)||null!=e.blotName&&i instanceof e)&&s.push(i),i instanceof t&&(s=s.concat(i.descendants(e,n,r))),r-=o})),s}detach(){this.children.forEach((t=>{t.detach()})),super.detach()}enforceAllowedChildren(){let e=!1;this.children.forEach((i=>{e||this.statics.allowedChildren.some((t=>i instanceof t))||(i.statics.scope===Ie.BLOCK_BLOT?(null!=i.next&&this.splitAfter(i),null!=i.prev&&this.splitAfter(i.prev),i.parent.unwrap(),e=!0):i instanceof t?i.unwrap():i.remove())}))}formatAt(t,e,i,n){this.children.forEachAt(t,e,((t,e,s)=>{t.formatAt(e,s,i,n)}))}insertAt(t,e,i){const[n,s]=this.children.find(t);if(n)n.insertAt(s,e,i);else{const t=null==i?this.scroll.create("text",e):this.scroll.create(e,i);this.appendChild(t)}}insertBefore(t,e){null!=t.parent&&t.parent.children.remove(t);let i=null;this.children.insertBefore(t,e||null),t.parent=this,null!=e&&(i=e.domNode),(this.domNode.parentNode!==t.domNode||this.domNode.nextSibling!==i)&&this.domNode.insertBefore(t.domNode,i),t.attach()}length(){return this.children.reduce(((t,e)=>t+e.length()),0)}moveChildren(t,e){this.children.forEach((i=>{t.insertBefore(i,e)}))}optimize(t){if(super.optimize(t),this.enforceAllowedChildren(),null!=this.uiNode&&this.uiNode!==this.domNode.firstChild&&this.domNode.insertBefore(this.uiNode,this.domNode.firstChild),0===this.children.length)if(null!=this.statics.defaultChild){const t=this.scroll.create(this.statics.defaultChild.blotName);this.appendChild(t)}else this.remove()}path(e,i=!1){const[n,s]=this.children.find(e,i),r=[[this,e]];return n instanceof t?r.concat(n.path(s,i)):(null!=n&&r.push([n,s]),r)}removeChild(t){this.children.remove(t)}replaceWith(e,i){const n="string"==typeof e?this.scroll.create(e,i):e;return n instanceof t&&this.moveChildren(n),super.replaceWith(n)}split(t,e=!1){if(!e){if(0===t)return this;if(t===this.length())return this.next}const i=this.clone();return this.parent&&this.parent.insertBefore(i,this.next||void 0),this.children.forEachAt(t,this.length(),((t,n)=>{const s=t.split(n,e);null!=s&&i.appendChild(s)})),i}splitAfter(t){const e=this.clone();for(;null!=t.next;)e.appendChild(t.next);return this.parent&&this.parent.insertBefore(e,this.next||void 0),e}unwrap(){this.parent&&this.moveChildren(this.parent,this.next||void 0),this.remove()}update(t,e){const i=[],n=[];t.forEach((t=>{t.target===this.domNode&&"childList"===t.type&&(i.push(...t.addedNodes),n.push(...t.removedNodes))})),n.forEach((t=>{if(null!=t.parentNode&&"IFRAME"!==t.tagName&&document.body.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)return;const e=this.scroll.find(t);null!=e&&(null==e.domNode.parentNode||e.domNode.parentNode===this.domNode)&&e.detach()})),i.filter((t=>t.parentNode===this.domNode&&t!==this.uiNode)).sort(((t,e)=>t===e?0:t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1)).forEach((t=>{let e=null;null!=t.nextSibling&&(e=this.scroll.find(t.nextSibling));const i=Je(t,this.scroll);(i.next!==e||null==i.next)&&(null!=i.parent&&i.parent.removeChild(this),this.insertBefore(i,e||void 0))})),this.enforceAllowedChildren()}};ti.uiClass="";const ei=ti,ii=class t extends ei{static create(t){return super.create(t)}static formats(e,i){const n=i.query(t.blotName);if(null==n||e.tagName!==n.tagName){if("string"==typeof this.tagName)return!0;if(Array.isArray(this.tagName))return e.tagName.toLowerCase()}}constructor(t,e){super(t,e),this.attributes=new ze(this.domNode)}format(e,i){if(e!==this.statics.blotName||i){const t=this.scroll.query(e,Ie.INLINE);if(null==t)return;t instanceof De?this.attributes.attribute(t,i):i&&(e!==this.statics.blotName||this.formats()[e]!==i)&&this.replaceWith(e,i)}else this.children.forEach((e=>{e instanceof t||(e=e.wrap(t.blotName,!0)),this.attributes.copy(e)})),this.unwrap()}formats(){const t=this.attributes.values(),e=this.statics.formats(this.domNode,this.scroll);return null!=e&&(t[this.statics.blotName]=e),t}formatAt(t,e,i,n){null!=this.formats()[i]||this.scroll.query(i,Ie.ATTRIBUTE)?this.isolate(t,e).format(i,n):super.formatAt(t,e,i,n)}optimize(e){super.optimize(e);const i=this.formats();if(0===Object.keys(i).length)return this.unwrap();const n=this.next;n instanceof t&&n.prev===this&&function(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(const i in t)if(t[i]!==e[i])return!1;return!0}(i,n.formats())&&(n.moveChildren(this),n.remove())}replaceWith(t,e){const i=super.replaceWith(t,e);return this.attributes.copy(i),i}update(t,e){super.update(t,e),t.some((t=>t.target===this.domNode&&"attributes"===t.type))&&this.attributes.build()}wrap(e,i){const n=super.wrap(e,i);return n instanceof t&&this.attributes.move(n),n}};ii.allowedChildren=[ii,Ye],ii.blotName="inline",ii.scope=Ie.INLINE_BLOT,ii.tagName="SPAN";const ni=ii,si=class t extends ei{static create(t){return super.create(t)}static formats(e,i){const n=i.query(t.blotName);if(null==n||e.tagName!==n.tagName){if("string"==typeof this.tagName)return!0;if(Array.isArray(this.tagName))return e.tagName.toLowerCase()}}constructor(t,e){super(t,e),this.attributes=new ze(this.domNode)}format(e,i){const n=this.scroll.query(e,Ie.BLOCK);null!=n&&(n instanceof De?this.attributes.attribute(n,i):e!==this.statics.blotName||i?i&&(e!==this.statics.blotName||this.formats()[e]!==i)&&this.replaceWith(e,i):this.replaceWith(t.blotName))}formats(){const t=this.attributes.values(),e=this.statics.formats(this.domNode,this.scroll);return null!=e&&(t[this.statics.blotName]=e),t}formatAt(t,e,i,n){null!=this.scroll.query(i,Ie.BLOCK)?this.format(i,n):super.formatAt(t,e,i,n)}insertAt(t,e,i){if(null==i||null!=this.scroll.query(e,Ie.INLINE))super.insertAt(t,e,i);else{const n=this.split(t);if(null==n)throw new Error("Attempt to insertAt after block boundaries");{const t=this.scroll.create(e,i);n.parent.insertBefore(t,n)}}}replaceWith(t,e){const i=super.replaceWith(t,e);return this.attributes.copy(i),i}update(t,e){super.update(t,e),t.some((t=>t.target===this.domNode&&"attributes"===t.type))&&this.attributes.build()}};si.blotName="block",si.scope=Ie.BLOCK_BLOT,si.tagName="P",si.allowedChildren=[ni,si,Ye];const ri=si,oi=class extends ei{checkMerge(){return null!==this.next&&this.next.statics.blotName===this.statics.blotName}deleteAt(t,e){super.deleteAt(t,e),this.enforceAllowedChildren()}formatAt(t,e,i,n){super.formatAt(t,e,i,n),this.enforceAllowedChildren()}insertAt(t,e,i){super.insertAt(t,e,i),this.enforceAllowedChildren()}optimize(t){super.optimize(t),this.children.length>0&&null!=this.next&&this.checkMerge()&&(this.next.moveChildren(this),this.next.remove())}};oi.blotName="container",oi.scope=Ie.BLOCK_BLOT;const li=oi,ci=class extends Ye{static formats(t,e){}format(t,e){super.formatAt(0,this.length(),t,e)}formatAt(t,e,i,n){0===t&&e===this.length()?this.format(i,n):super.formatAt(t,e,i,n)}formats(){return this.statics.formats(this.domNode,this.scroll)}},ui={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},hi=class extends ei{constructor(t,e){super(null,e),this.registry=t,this.scroll=this,this.build(),this.observer=new MutationObserver((t=>{this.update(t)})),this.observer.observe(this.domNode,ui),this.attach()}create(t,e){return this.registry.create(this,t,e)}find(t,e=!1){const i=this.registry.find(t,e);return i?i.scroll===this?i:e?this.find(i.scroll.domNode.parentNode,!0):null:null}query(t,e=Ie.ANY){return this.registry.query(t,e)}register(...t){return this.registry.register(...t)}build(){null!=this.scroll&&super.build()}detach(){super.detach(),this.observer.disconnect()}deleteAt(t,e){this.update(),0===t&&e===this.length()?this.children.forEach((t=>{t.remove()})):super.deleteAt(t,e)}formatAt(t,e,i,n){this.update(),super.formatAt(t,e,i,n)}insertAt(t,e,i){this.update(),super.insertAt(t,e,i)}optimize(t=[],e={}){super.optimize(e);const i=e.mutationsMap||new WeakMap;let n=Array.from(this.observer.takeRecords());for(;n.length>0;)t.push(n.pop());const s=(t,e=!0)=>{null==t||t===this||null!=t.domNode.parentNode&&(i.has(t.domNode)||i.set(t.domNode,[]),e&&s(t.parent))},r=t=>{i.has(t.domNode)&&(t instanceof ei&&t.children.forEach(r),i.delete(t.domNode),t.optimize(e))};let o=t;for(let e=0;o.length>0;e+=1){if(e>=100)throw new Error("[Parchment] Maximum optimize iterations reached");for(o.forEach((t=>{const e=this.find(t.target,!0);null!=e&&(e.domNode===t.target&&("childList"===t.type?(s(this.find(t.previousSibling,!1)),Array.from(t.addedNodes).forEach((t=>{const e=this.find(t,!1);s(e,!1),e instanceof ei&&e.children.forEach((t=>{s(t,!1)}))}))):"attributes"===t.type&&s(e.prev)),s(e))})),this.children.forEach(r),o=Array.from(this.observer.takeRecords()),n=o.slice();n.length>0;)t.push(n.pop())}}update(t,e={}){t=t||this.observer.takeRecords();const i=new WeakMap;t.map((t=>{const e=this.find(t.target,!0);return null==e?null:i.has(e.domNode)?(i.get(e.domNode).push(t),null):(i.set(e.domNode,[t]),e)})).forEach((t=>{null!=t&&t!==this&&i.has(t.domNode)&&t.update(i.get(t.domNode)||[],e)})),e.mutationsMap=i,i.has(this.domNode)&&super.update(i.get(this.domNode),e),this.optimize(t,e)}};hi.blotName="scroll",hi.defaultChild=ri,hi.allowedChildren=[ri,li],hi.scope=Ie.BLOCK_BLOT,hi.tagName="DIV";const ai=hi,fi=class t extends Ye{static create(t){return document.createTextNode(t)}static value(t){return t.data}constructor(t,e){super(t,e),this.text=this.statics.value(this.domNode)}deleteAt(t,e){this.domNode.data=this.text=this.text.slice(0,t)+this.text.slice(t+e)}index(t,e){return this.domNode===t?e:-1}insertAt(t,e,i){null==i?(this.text=this.text.slice(0,t)+e+this.text.slice(t),this.domNode.data=this.text):super.insertAt(t,e,i)}length(){return this.text.length}optimize(e){super.optimize(e),this.text=this.statics.value(this.domNode),0===this.text.length?this.remove():this.next instanceof t&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())}position(t,e=!1){return[this.domNode,t]}split(t,e=!1){if(!e){if(0===t)return this;if(t===this.length())return this.next}const i=this.scroll.create(this.domNode.splitText(t));return this.parent.insertBefore(i,this.next||void 0),this.text=this.statics.value(this.domNode),i}update(t,e){t.some((t=>"characterData"===t.type&&t.target===this.domNode))&&(this.text=this.statics.value(this.domNode))}value(){return this.text}};fi.blotName="text",fi.scope=Ie.INLINE_BLOT;const di=fi;var pi=Object.freeze({__proto__:null,Attributor:De,AttributorStore:ze,BlockBlot:ri,ClassAttributor:Ue,ContainerBlot:li,EmbedBlot:ci,InlineBlot:ni,LeafBlot:Ye,ParentBlot:ei,Registry:Pe,Scope:Ie,ScrollBlot:ai,StyleAttributor:Ke,TextBlot:di}),bi="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function vi(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var yi,mi,wi={exports:{}};var gi,xi={exports:{}};function ki(){return gi||(gi=1,function(t,e){var i="__lodash_hash_undefined__",n=9007199254740991,s="[object Arguments]",r="[object Boolean]",o="[object Date]",l="[object Function]",c="[object GeneratorFunction]",u="[object Map]",h="[object Number]",a="[object Object]",f="[object Promise]",d="[object RegExp]",p="[object Set]",b="[object String]",v="[object Symbol]",y="[object WeakMap]",m="[object ArrayBuffer]",w="[object DataView]",g="[object Float32Array]",x="[object Float64Array]",k="[object Int8Array]",j="[object Int16Array]",A="[object Int32Array]",q="[object Uint8Array]",O="[object Uint8ClampedArray]",M="[object Uint16Array]",E="[object Uint32Array]",T=/\w*$/,N=/^\[object .+?Constructor\]$/,L=/^(?:0|[1-9]\d*)$/,$={};$[s]=$["[object Array]"]=$[m]=$[w]=$[r]=$[o]=$[g]=$[x]=$[k]=$[j]=$[A]=$[u]=$[h]=$[a]=$[d]=$[p]=$[b]=$[v]=$[q]=$[O]=$[M]=$[E]=!0,$["[object Error]"]=$[l]=$[y]=!1;var _="object"==typeof self&&self&&self.Object===Object&&self,S="object"==typeof bi&&bi&&bi.Object===Object&&bi||_||Function("return this")(),C=e&&!e.nodeType&&e,B=C&&t&&!t.nodeType&&t,R=B&&B.exports===C;function I(t,e){return t.set(e[0],e[1]),t}function D(t,e){return t.add(e),t}function V(t,e,i){for(var n=-1,s=t?t.length:0;++n<s;)i=e(i,t[n],n,t);return i}function H(t){var e=!1;if(null!=t&&"function"!=typeof t.toString)try{e=!!(t+"")}catch(t){}return e}function P(t){var e=-1,i=Array(t.size);return t.forEach((function(t,n){i[++e]=[n,t]})),i}function F(t,e){return function(i){return t(e(i))}}function U(t){var e=-1,i=Array(t.size);return t.forEach((function(t){i[++e]=t})),i}var Z=Array.prototype,K=Function.prototype,z=Object.prototype,W=S["__core-js_shared__"],G=function(){var t=/[^.]+$/.exec(W&&W.keys&&W.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),Q=K.toString,Y=z.hasOwnProperty,X=z.toString,J=RegExp("^"+Q.call(Y).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),tt=R?S.Buffer:void 0,et=S.Symbol,it=S.Uint8Array,nt=F(Object.getPrototypeOf,Object),st=Object.create,rt=z.propertyIsEnumerable,ot=Z.splice,lt=Object.getOwnPropertySymbols,ct=tt?tt.isBuffer:void 0,ut=F(Object.keys,Object),ht=_t(S,"DataView"),at=_t(S,"Map"),ft=_t(S,"Promise"),dt=_t(S,"Set"),pt=_t(S,"WeakMap"),bt=_t(Object,"create"),vt=It(ht),yt=It(at),mt=It(ft),wt=It(dt),gt=It(pt),xt=et?et.prototype:void 0,kt=xt?xt.valueOf:void 0;function jt(t){var e=-1,i=t?t.length:0;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function At(t){var e=-1,i=t?t.length:0;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function qt(t){var e=-1,i=t?t.length:0;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function Ot(t){this.__data__=new At(t)}function Mt(t,e,i){var n=t[e];Y.call(t,e)&&Dt(n,i)&&(void 0!==i||e in t)||(t[e]=i)}function Et(t,e){for(var i=t.length;i--;)if(Dt(t[i][0],e))return i;return-1}function Tt(t,e,i,n,f,y,N){var L;if(n&&(L=y?n(t,f,y,N):n(t)),void 0!==L)return L;if(!Ut(t))return t;var _=Vt(t);if(_){if(L=function(t){var e=t.length,i=t.constructor(e);return e&&"string"==typeof t[0]&&Y.call(t,"index")&&(i.index=t.index,i.input=t.input),i}(t),!e)return function(t,e){var i=-1,n=t.length;for(e||(e=Array(n));++i<n;)e[i]=t[i];return e}(t,L)}else{var S=Ct(t),C=S==l||S==c;if(Pt(t))return function(t,e){if(e)return t.slice();var i=new t.constructor(t.length);return t.copy(i),i}(t,e);if(S==a||S==s||C&&!y){if(H(t))return y?t:{};if(L=function(t){return"function"!=typeof t.constructor||Rt(t)?{}:Ut(e=nt(t))?st(e):{};var e}(C?{}:t),!e)return function(t,e){return Lt(t,St(t),e)}(t,function(t,e){return t&&Lt(e,Zt(e),t)}(L,t))}else{if(!$[S])return y?t:{};L=function(t,e,i,n){var s=t.constructor;switch(e){case m:return Nt(t);case r:case o:return new s(+t);case w:return function(t,e){var i=e?Nt(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.byteLength)}(t,n);case g:case x:case k:case j:case A:case q:case O:case M:case E:return function(t,e){var i=e?Nt(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.length)}(t,n);case u:return function(t,e,i){return V(e?i(P(t),!0):P(t),I,new t.constructor)}(t,n,i);case h:case b:return new s(t);case d:return function(t){var e=new t.constructor(t.source,T.exec(t));return e.lastIndex=t.lastIndex,e}(t);case p:return function(t,e,i){return V(e?i(U(t),!0):U(t),D,new t.constructor)}(t,n,i);case v:return kt?Object(kt.call(t)):{}}}(t,S,Tt,e)}}N||(N=new Ot);var B=N.get(t);if(B)return B;if(N.set(t,L),!_)var R=i?function(t){return function(t,e,i){var n=e(t);return Vt(t)?n:function(t,e){for(var i=-1,n=e.length,s=t.length;++i<n;)t[s+i]=e[i];return t}(n,i(t))}(t,Zt,St)}(t):Zt(t);return function(t,e){for(var i=-1,n=t?t.length:0;++i<n&&!1!==e(t[i],i););}(R||t,(function(s,r){R&&(s=t[r=s]),Mt(L,r,Tt(s,e,i,n,r,t,N))})),L}function Nt(t){var e=new t.constructor(t.byteLength);return new it(e).set(new it(t)),e}function Lt(t,e,i){i||(i={});for(var n=-1,s=e.length;++n<s;){var r=e[n];Mt(i,r,t[r])}return i}function $t(t,e){var i,n,s=t.__data__;return("string"==(n=typeof(i=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==i:null===i)?s["string"==typeof e?"string":"hash"]:s.map}function _t(t,e){var i=function(t,e){return null==t?void 0:t[e]}(t,e);return function(t){return!(!Ut(t)||function(t){return!!G&&G in t}(t))&&(Ft(t)||H(t)?J:N).test(It(t))}(i)?i:void 0}jt.prototype.clear=function(){this.__data__=bt?bt(null):{}},jt.prototype.delete=function(t){return this.has(t)&&delete this.__data__[t]},jt.prototype.get=function(t){var e=this.__data__;if(bt){var n=e[t];return n===i?void 0:n}return Y.call(e,t)?e[t]:void 0},jt.prototype.has=function(t){var e=this.__data__;return bt?void 0!==e[t]:Y.call(e,t)},jt.prototype.set=function(t,e){return this.__data__[t]=bt&&void 0===e?i:e,this},At.prototype.clear=function(){this.__data__=[]},At.prototype.delete=function(t){var e=this.__data__,i=Et(e,t);return!(i<0||(i==e.length-1?e.pop():ot.call(e,i,1),0))},At.prototype.get=function(t){var e=this.__data__,i=Et(e,t);return i<0?void 0:e[i][1]},At.prototype.has=function(t){return Et(this.__data__,t)>-1},At.prototype.set=function(t,e){var i=this.__data__,n=Et(i,t);return n<0?i.push([t,e]):i[n][1]=e,this},qt.prototype.clear=function(){this.__data__={hash:new jt,map:new(at||At),string:new jt}},qt.prototype.delete=function(t){return $t(this,t).delete(t)},qt.prototype.get=function(t){return $t(this,t).get(t)},qt.prototype.has=function(t){return $t(this,t).has(t)},qt.prototype.set=function(t,e){return $t(this,t).set(t,e),this},Ot.prototype.clear=function(){this.__data__=new At},Ot.prototype.delete=function(t){return this.__data__.delete(t)},Ot.prototype.get=function(t){return this.__data__.get(t)},Ot.prototype.has=function(t){return this.__data__.has(t)},Ot.prototype.set=function(t,e){var i=this.__data__;if(i instanceof At){var n=i.__data__;if(!at||n.length<199)return n.push([t,e]),this;i=this.__data__=new qt(n)}return i.set(t,e),this};var St=lt?F(lt,Object):function(){return[]},Ct=function(t){return X.call(t)};function Bt(t,e){return!!(e=null==e?n:e)&&("number"==typeof t||L.test(t))&&t>-1&&t%1==0&&t<e}function Rt(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||z)}function It(t){if(null!=t){try{return Q.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Dt(t,e){return t===e||t!=t&&e!=e}(ht&&Ct(new ht(new ArrayBuffer(1)))!=w||at&&Ct(new at)!=u||ft&&Ct(ft.resolve())!=f||dt&&Ct(new dt)!=p||pt&&Ct(new pt)!=y)&&(Ct=function(t){var e=X.call(t),i=e==a?t.constructor:void 0,n=i?It(i):void 0;if(n)switch(n){case vt:return w;case yt:return u;case mt:return f;case wt:return p;case gt:return y}return e});var Vt=Array.isArray;function Ht(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=n}(t.length)&&!Ft(t)}var Pt=ct||function(){return!1};function Ft(t){var e=Ut(t)?X.call(t):"";return e==l||e==c}function Ut(t){var e=typeof t;return!!t&&("object"==e||"function"==e)}function Zt(t){return Ht(t)?function(t){var e=Vt(t)||function(t){return function(t){return function(t){return!!t&&"object"==typeof t}(t)&&Ht(t)}(t)&&Y.call(t,"callee")&&(!rt.call(t,"callee")||X.call(t)==s)}(t)?function(t,e){for(var i=-1,n=Array(t);++i<t;)n[i]=e(i);return n}(t.length,String):[],i=e.length,n=!!i;for(var r in t)!Y.call(t,r)||n&&("length"==r||Bt(r,i))||e.push(r);return e}(t):function(t){if(!Rt(t))return ut(t);var e=[];for(var i in Object(t))Y.call(t,i)&&"constructor"!=i&&e.push(i);return e}(t)}t.exports=function(t){return Tt(t,!0,!0)}}(xi,xi.exports)),xi.exports}var ji,Ai={exports:{}};function qi(){return ji||(ji=1,function(t,e){var i="__lodash_hash_undefined__",n=9007199254740991,s="[object Arguments]",r="[object Array]",o="[object Boolean]",l="[object Date]",c="[object Error]",u="[object Function]",h="[object Map]",a="[object Number]",f="[object Object]",d="[object Promise]",p="[object RegExp]",b="[object Set]",v="[object String]",y="[object WeakMap]",m="[object ArrayBuffer]",w="[object DataView]",g=/^\[object .+?Constructor\]$/,x=/^(?:0|[1-9]\d*)$/,k={};k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k[s]=k[r]=k[m]=k[o]=k[w]=k[l]=k[c]=k[u]=k[h]=k[a]=k[f]=k[p]=k[b]=k[v]=k[y]=!1;var j="object"==typeof bi&&bi&&bi.Object===Object&&bi,A="object"==typeof self&&self&&self.Object===Object&&self,q=j||A||Function("return this")(),O=e&&!e.nodeType&&e,M=O&&t&&!t.nodeType&&t,E=M&&M.exports===O,T=E&&j.process,N=function(){try{return T&&T.binding&&T.binding("util")}catch(t){}}(),L=N&&N.isTypedArray;function $(t,e){for(var i=-1,n=null==t?0:t.length;++i<n;)if(e(t[i],i,t))return!0;return!1}function _(t){var e=-1,i=Array(t.size);return t.forEach((function(t,n){i[++e]=[n,t]})),i}function S(t){var e=-1,i=Array(t.size);return t.forEach((function(t){i[++e]=t})),i}var C=Array.prototype,B=Object.prototype,R=q["__core-js_shared__"],I=Function.prototype.toString,D=B.hasOwnProperty,V=function(){var t=/[^.]+$/.exec(R&&R.keys&&R.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}(),H=B.toString,P=RegExp("^"+I.call(D).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),F=E?q.Buffer:void 0,U=q.Symbol,Z=q.Uint8Array,K=B.propertyIsEnumerable,z=C.splice,W=U?U.toStringTag:void 0,G=Object.getOwnPropertySymbols,Q=F?F.isBuffer:void 0,Y=function(t,e){return function(i){return t(e(i))}}(Object.keys,Object),X=jt(q,"DataView"),J=jt(q,"Map"),tt=jt(q,"Promise"),et=jt(q,"Set"),it=jt(q,"WeakMap"),nt=jt(Object,"create"),st=Mt(X),rt=Mt(J),ot=Mt(tt),lt=Mt(et),ct=Mt(it),ut=U?U.prototype:void 0,ht=ut?ut.valueOf:void 0;function at(t){var e=-1,i=null==t?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function ft(t){var e=-1,i=null==t?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function dt(t){var e=-1,i=null==t?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}function pt(t){var e=-1,i=null==t?0:t.length;for(this.__data__=new dt;++e<i;)this.add(t[e])}function bt(t){var e=this.__data__=new ft(t);this.size=e.size}function vt(t,e){for(var i=t.length;i--;)if(Et(t[i][0],e))return i;return-1}function yt(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":W&&W in Object(t)?function(t){var e=D.call(t,W),i=t[W];try{t[W]=void 0;var n=!0}catch(t){}var s=H.call(t);return n&&(e?t[W]=i:delete t[W]),s}(t):function(t){return H.call(t)}(t)}function mt(t){return Ct(t)&&yt(t)==s}function wt(t,e,i,n,u){return t===e||(null==t||null==e||!Ct(t)&&!Ct(e)?t!=t&&e!=e:function(t,e,i,n,u,d){var y=Nt(t),g=Nt(e),x=y?r:qt(t),k=g?r:qt(e),j=(x=x==s?f:x)==f,A=(k=k==s?f:k)==f,q=x==k;if(q&&Lt(t)){if(!Lt(e))return!1;y=!0,j=!1}if(q&&!j)return d||(d=new bt),y||Bt(t)?gt(t,e,i,n,u,d):function(t,e,i,n,s,r,u){switch(i){case w:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case m:return!(t.byteLength!=e.byteLength||!r(new Z(t),new Z(e)));case o:case l:case a:return Et(+t,+e);case c:return t.name==e.name&&t.message==e.message;case p:case v:return t==e+"";case h:var f=_;case b:if(f||(f=S),t.size!=e.size&&!(1&n))return!1;var d=u.get(t);if(d)return d==e;n|=2,u.set(t,e);var y=gt(f(t),f(e),n,s,r,u);return u.delete(t),y;case"[object Symbol]":if(ht)return ht.call(t)==ht.call(e)}return!1}(t,e,x,i,n,u,d);if(!(1&i)){var O=j&&D.call(t,"__wrapped__"),M=A&&D.call(e,"__wrapped__");if(O||M){var E=O?t.value():t,T=M?e.value():e;return d||(d=new bt),u(E,T,i,n,d)}}return!!q&&(d||(d=new bt),function(t,e,i,n,s,r){var o=1&i,l=xt(t),c=l.length;if(c!=xt(e).length&&!o)return!1;for(var u=c;u--;){var h=l[u];if(!(o?h in e:D.call(e,h)))return!1}var a=r.get(t);if(a&&r.get(e))return a==e;var f=!0;r.set(t,e),r.set(e,t);for(var d=o;++u<c;){var p=t[h=l[u]],b=e[h];if(n)var v=o?n(b,p,h,e,t,r):n(p,b,h,t,e,r);if(!(void 0===v?p===b||s(p,b,i,n,r):v)){f=!1;break}d||(d="constructor"==h)}if(f&&!d){var y=t.constructor,m=e.constructor;y==m||!("constructor"in t)||!("constructor"in e)||"function"==typeof y&&y instanceof y&&"function"==typeof m&&m instanceof m||(f=!1)}return r.delete(t),r.delete(e),f}(t,e,i,n,u,d))}(t,e,i,n,wt,u))}function gt(t,e,i,n,s,r){var o=1&i,l=t.length,c=e.length;if(l!=c&&!(o&&c>l))return!1;var u=r.get(t);if(u&&r.get(e))return u==e;var h=-1,a=!0,f=2&i?new pt:void 0;for(r.set(t,e),r.set(e,t);++h<l;){var d=t[h],p=e[h];if(n)var b=o?n(p,d,h,e,t,r):n(d,p,h,t,e,r);if(void 0!==b){if(b)continue;a=!1;break}if(f){if(!$(e,(function(t,e){if(!f.has(e)&&(d===t||s(d,t,i,n,r)))return f.push(e)}))){a=!1;break}}else if(d!==p&&!s(d,p,i,n,r)){a=!1;break}}return r.delete(t),r.delete(e),a}function xt(t){return function(t,e,i){var n=e(t);return Nt(t)?n:function(t,e){for(var i=-1,n=e.length,s=t.length;++i<n;)t[s+i]=e[i];return t}(n,i(t))}(t,Rt,At)}function kt(t,e){var i,n,s=t.__data__;return("string"==(n=typeof(i=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==i:null===i)?s["string"==typeof e?"string":"hash"]:s.map}function jt(t,e){var i=function(t,e){return null==t?void 0:t[e]}(t,e);return function(t){return!(!St(t)||function(t){return!!V&&V in t}(t))&&($t(t)?P:g).test(Mt(t))}(i)?i:void 0}at.prototype.clear=function(){this.__data__=nt?nt(null):{},this.size=0},at.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},at.prototype.get=function(t){var e=this.__data__;if(nt){var n=e[t];return n===i?void 0:n}return D.call(e,t)?e[t]:void 0},at.prototype.has=function(t){var e=this.__data__;return nt?void 0!==e[t]:D.call(e,t)},at.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=nt&&void 0===e?i:e,this},ft.prototype.clear=function(){this.__data__=[],this.size=0},ft.prototype.delete=function(t){var e=this.__data__,i=vt(e,t);return!(i<0||(i==e.length-1?e.pop():z.call(e,i,1),--this.size,0))},ft.prototype.get=function(t){var e=this.__data__,i=vt(e,t);return i<0?void 0:e[i][1]},ft.prototype.has=function(t){return vt(this.__data__,t)>-1},ft.prototype.set=function(t,e){var i=this.__data__,n=vt(i,t);return n<0?(++this.size,i.push([t,e])):i[n][1]=e,this},dt.prototype.clear=function(){this.size=0,this.__data__={hash:new at,map:new(J||ft),string:new at}},dt.prototype.delete=function(t){var e=kt(this,t).delete(t);return this.size-=e?1:0,e},dt.prototype.get=function(t){return kt(this,t).get(t)},dt.prototype.has=function(t){return kt(this,t).has(t)},dt.prototype.set=function(t,e){var i=kt(this,t),n=i.size;return i.set(t,e),this.size+=i.size==n?0:1,this},pt.prototype.add=pt.prototype.push=function(t){return this.__data__.set(t,i),this},pt.prototype.has=function(t){return this.__data__.has(t)},bt.prototype.clear=function(){this.__data__=new ft,this.size=0},bt.prototype.delete=function(t){var e=this.__data__,i=e.delete(t);return this.size=e.size,i},bt.prototype.get=function(t){return this.__data__.get(t)},bt.prototype.has=function(t){return this.__data__.has(t)},bt.prototype.set=function(t,e){var i=this.__data__;if(i instanceof ft){var n=i.__data__;if(!J||n.length<199)return n.push([t,e]),this.size=++i.size,this;i=this.__data__=new dt(n)}return i.set(t,e),this.size=i.size,this};var At=G?function(t){return null==t?[]:(t=Object(t),function(e){for(var i=-1,n=null==e?0:e.length,s=0,r=[];++i<n;){var o=e[i];K.call(t,o)&&(r[s++]=o)}return r}(G(t)))}:function(){return[]},qt=yt;function Ot(t,e){return!!(e=null==e?n:e)&&("number"==typeof t||x.test(t))&&t>-1&&t%1==0&&t<e}function Mt(t){if(null!=t){try{return I.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function Et(t,e){return t===e||t!=t&&e!=e}(X&&qt(new X(new ArrayBuffer(1)))!=w||J&&qt(new J)!=h||tt&&qt(tt.resolve())!=d||et&&qt(new et)!=b||it&&qt(new it)!=y)&&(qt=function(t){var e=yt(t),i=e==f?t.constructor:void 0,n=i?Mt(i):"";if(n)switch(n){case st:return w;case rt:return h;case ot:return d;case lt:return b;case ct:return y}return e});var Tt=mt(function(){return arguments}())?mt:function(t){return Ct(t)&&D.call(t,"callee")&&!K.call(t,"callee")},Nt=Array.isArray,Lt=Q||function(){return!1};function $t(t){if(!St(t))return!1;var e=yt(t);return e==u||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}function _t(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=n}function St(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function Ct(t){return null!=t&&"object"==typeof t}var Bt=L?function(t){return function(e){return t(e)}}(L):function(t){return Ct(t)&&_t(t.length)&&!!k[yt(t)]};function Rt(t){return null!=(e=t)&&_t(e.length)&&!$t(e)?function(t){var e=Nt(t),i=!e&&Tt(t),n=!e&&!i&&Lt(t),s=!e&&!i&&!n&&Bt(t),r=e||i||n||s,o=r?function(t,e){for(var i=-1,n=Array(t);++i<t;)n[i]=e(i);return n}(t.length,String):[],l=o.length;for(var c in t)!D.call(t,c)||r&&("length"==c||n&&("offset"==c||"parent"==c)||s&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||Ot(c,l))||o.push(c);return o}(t):function(t){if((e=t)!==("function"==typeof(i=e&&e.constructor)&&i.prototype||B))return Y(t);var e,i,n=[];for(var s in Object(t))D.call(t,s)&&"constructor"!=s&&n.push(s);return n}(t);var e}t.exports=function(t,e){return wt(t,e)}}(Ai,Ai.exports)),Ai.exports}var Oi,Mi,Ei={},Ti={};function Ni(){return Mi||(Mi=1,Object.defineProperty(Ti,"__esModule",{value:!0}),function(t){t.length=function(t){return"number"==typeof t.delete?t.delete:"number"==typeof t.retain?t.retain:"object"==typeof t.retain&&null!==t.retain?1:"string"==typeof t.insert?t.insert.length:1}}(t||(t={})),Ti.default=t),Ti;var t}var Li,$i,_i={},Si=($i||($i=1,function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.AttributeMap=e.OpIterator=e.Op=void 0;const i=function(){if(mi)return yi;mi=1;var t=-1;function e(f,d,p,b,y){if(f===d)return f?[[0,f]]:[];if(null!=p){var m=function(t,e,i){var n="number"==typeof i?{index:i,length:0}:i.oldRange,s="number"==typeof i?null:i.newRange,r=t.length,o=e.length;if(0===n.length&&(null===s||0===s.length)){var l=n.index,c=t.slice(0,l),u=t.slice(l),h=s?s.index:null,a=l+o-r;if((null===h||h===a)&&!(a<0||a>o)){var f=e.slice(0,a);if((b=e.slice(a))===u){var d=Math.min(l,a);if((m=c.slice(0,d))===(g=f.slice(0,d)))return v(m,c.slice(d),f.slice(d),u)}}if(null===h||h===l){var p=l,b=(f=e.slice(0,p),e.slice(p));if(f===c){var y=Math.min(r-p,o-p);if((w=u.slice(u.length-y))===(x=b.slice(b.length-y)))return v(c,u.slice(0,u.length-y),b.slice(0,b.length-y),w)}}}if(n.length>0&&s&&0===s.length){var m=t.slice(0,n.index),w=t.slice(n.index+n.length);if(!(o<(d=m.length)+(y=w.length))){var g=e.slice(0,d),x=e.slice(o-y);if(m===g&&w===x)return v(m,t.slice(d,r-y),e.slice(d,o-y),w)}}return null}(f,d,p);if(m)return m}var w=n(f,d),g=f.substring(0,w);w=r(f=f.substring(w),d=d.substring(w));var x=f.substring(f.length-w),k=function(s,o){var l;if(!s)return[[1,o]];if(!o)return[[t,s]];var c=s.length>o.length?s:o,u=s.length>o.length?o:s,h=c.indexOf(u);if(-1!==h)return l=[[1,c.substring(0,h)],[0,u],[1,c.substring(h+u.length)]],s.length>o.length&&(l[0][0]=l[2][0]=t),l;if(1===u.length)return[[t,s],[1,o]];var a=function(t,e){var i=t.length>e.length?t:e,s=t.length>e.length?e:t;if(i.length<4||2*s.length<i.length)return null;function o(t,e,i){for(var s,o,l,c,u=t.substring(i,i+Math.floor(t.length/4)),h=-1,a="";-1!==(h=e.indexOf(u,h+1));){var f=n(t.substring(i),e.substring(h)),d=r(t.substring(0,i),e.substring(0,h));a.length<d+f&&(a=e.substring(h-d,h)+e.substring(h,h+f),s=t.substring(0,i-d),o=t.substring(i+f),l=e.substring(0,h-d),c=e.substring(h+f))}return 2*a.length>=t.length?[s,o,l,c,a]:null}var l,c,u,h,a,f=o(i,s,Math.ceil(i.length/4)),d=o(i,s,Math.ceil(i.length/2));return f||d?(l=d?f&&f[4].length>d[4].length?f:d:f,t.length>e.length?(c=l[0],u=l[1],h=l[2],a=l[3]):(h=l[0],a=l[1],c=l[2],u=l[3]),[c,u,h,a,l[4]]):null}(s,o);if(a){var f=a[1],d=a[3],p=a[4],b=e(a[0],a[2]),v=e(f,d);return b.concat([[0,p]],v)}return function(e,n){for(var s=e.length,r=n.length,o=Math.ceil((s+r)/2),l=o,c=2*o,u=new Array(c),h=new Array(c),a=0;a<c;a++)u[a]=-1,h[a]=-1;u[l+1]=0,h[l+1]=0;for(var f=s-r,d=f%2!=0,p=0,b=0,v=0,y=0,m=0;m<o;m++){for(var w=-m+p;w<=m-b;w+=2){for(var g=l+w,x=(O=w===-m||w!==m&&u[g-1]<u[g+1]?u[g+1]:u[g-1]+1)-w;O<s&&x<r&&e.charAt(O)===n.charAt(x);)O++,x++;if(u[g]=O,O>s)b+=2;else if(x>r)p+=2;else if(d&&(A=l+f-w)>=0&&A<c&&-1!==h[A]&&O>=(j=s-h[A]))return i(e,n,O,x)}for(var k=-m+v;k<=m-y;k+=2){for(var j,A=l+k,q=(j=k===-m||k!==m&&h[A-1]<h[A+1]?h[A+1]:h[A-1]+1)-k;j<s&&q<r&&e.charAt(s-j-1)===n.charAt(r-q-1);)j++,q++;if(h[A]=j,j>s)y+=2;else if(q>r)v+=2;else if(!d){var O;if((g=l+f-k)>=0&&g<c&&-1!==u[g]&&(x=l+(O=u[g])-g,O>=(j=s-j)))return i(e,n,O,x)}}}return[[t,e],[1,n]]}(s,o)}(f=f.substring(0,f.length-w),d=d.substring(0,d.length-w));return g&&k.unshift([0,g]),x&&k.push([0,x]),a(k,y),b&&function(e){for(var i=!1,n=[],f=0,d=null,p=0,b=0,v=0,y=0,m=0;p<e.length;)0==e[p][0]?(n[f++]=p,b=y,v=m,y=0,m=0,d=e[p][1]):(1==e[p][0]?y+=e[p][1].length:m+=e[p][1].length,d&&d.length<=Math.max(b,v)&&d.length<=Math.max(y,m)&&(e.splice(n[f-1],0,[t,d]),e[n[f-1]+1][0]=1,f--,p=--f>0?n[f-1]:-1,b=0,v=0,y=0,m=0,d=null,i=!0)),p++;for(i&&a(e),function(t){function e(t,e){if(!t||!e)return 6;var i=t.charAt(t.length-1),n=e.charAt(0),s=i.match(o),r=n.match(o),a=s&&i.match(l),f=r&&n.match(l),d=a&&i.match(c),p=f&&n.match(c),b=d&&t.match(u),v=p&&e.match(h);return b||v?5:d||p?4:s&&!a&&f?3:a||f?2:s||r?1:0}for(var i=1;i<t.length-1;){if(0==t[i-1][0]&&0==t[i+1][0]){var n=t[i-1][1],s=t[i][1],a=t[i+1][1],f=r(n,s);if(f){var d=s.substring(s.length-f);n=n.substring(0,n.length-f),s=d+s.substring(0,s.length-f),a=d+a}for(var p=n,b=s,v=a,y=e(n,s)+e(s,a);s.charAt(0)===a.charAt(0);){n+=s.charAt(0),s=s.substring(1)+a.charAt(0),a=a.substring(1);var m=e(n,s)+e(s,a);m>=y&&(y=m,p=n,b=s,v=a)}t[i-1][1]!=p&&(p?t[i-1][1]=p:(t.splice(i-1,1),i--),t[i][1]=b,v?t[i+1][1]=v:(t.splice(i+1,1),i--))}i++}}(e),p=1;p<e.length;){if(e[p-1][0]==t&&1==e[p][0]){var w=e[p-1][1],g=e[p][1],x=s(w,g),k=s(g,w);x>=k?(x>=w.length/2||x>=g.length/2)&&(e.splice(p,0,[0,g.substring(0,x)]),e[p-1][1]=w.substring(0,w.length-x),e[p+1][1]=g.substring(x),p++):(k>=w.length/2||k>=g.length/2)&&(e.splice(p,0,[0,w.substring(0,k)]),e[p-1][0]=1,e[p-1][1]=g.substring(0,g.length-k),e[p+1][0]=t,e[p+1][1]=w.substring(k),p++),p++}p++}}(k),k}function i(t,i,n,s){var r=t.substring(0,n),o=i.substring(0,s),l=t.substring(n),c=i.substring(s),u=e(r,o),h=e(l,c);return u.concat(h)}function n(t,e){if(!t||!e||t.charAt(0)!==e.charAt(0))return 0;for(var i=0,n=Math.min(t.length,e.length),s=n,r=0;i<s;)t.substring(r,s)==e.substring(r,s)?r=i=s:n=s,s=Math.floor((n-i)/2+i);return f(t.charCodeAt(s-1))&&s--,s}function s(t,e){var i=t.length,n=e.length;if(0==i||0==n)return 0;i>n?t=t.substring(i-n):i<n&&(e=e.substring(0,i));var s=Math.min(i,n);if(t==e)return s;for(var r=0,o=1;;){var l=t.substring(s-o),c=e.indexOf(l);if(-1==c)return r;o+=c,0!=c&&t.substring(s-o)!=e.substring(0,o)||(r=o,o++)}}function r(t,e){if(!t||!e||t.slice(-1)!==e.slice(-1))return 0;for(var i=0,n=Math.min(t.length,e.length),s=n,r=0;i<s;)t.substring(t.length-s,t.length-r)==e.substring(e.length-s,e.length-r)?r=i=s:n=s,s=Math.floor((n-i)/2+i);return d(t.charCodeAt(t.length-s))&&s--,s}var o=/[^a-zA-Z0-9]/,l=/\s/,c=/[\r\n]/,u=/\n\r?\n$/,h=/^\r?\n\r?\n/;function a(e,i){e.push([0,""]);for(var s,o=0,l=0,c=0,u="",h="";o<e.length;)if(o<e.length-1&&!e[o][1])e.splice(o,1);else switch(e[o][0]){case 1:c++,h+=e[o][1],o++;break;case t:l++,u+=e[o][1],o++;break;case 0:var f=o-c-l-1;if(i){if(f>=0&&b(e[f][1])){var d=e[f][1].slice(-1);if(e[f][1]=e[f][1].slice(0,-1),u=d+u,h=d+h,!e[f][1]){e.splice(f,1),o--;var v=f-1;e[v]&&1===e[v][0]&&(c++,h=e[v][1]+h,v--),e[v]&&e[v][0]===t&&(l++,u=e[v][1]+u,v--),f=v}}p(e[o][1])&&(d=e[o][1].charAt(0),e[o][1]=e[o][1].slice(1),u+=d,h+=d)}if(o<e.length-1&&!e[o][1]){e.splice(o,1);break}if(u.length>0||h.length>0){u.length>0&&h.length>0&&(0!==(s=n(h,u))&&(f>=0?e[f][1]+=h.substring(0,s):(e.splice(0,0,[0,h.substring(0,s)]),o++),h=h.substring(s),u=u.substring(s)),0!==(s=r(h,u))&&(e[o][1]=h.substring(h.length-s)+e[o][1],h=h.substring(0,h.length-s),u=u.substring(0,u.length-s)));var y=c+l;0===u.length&&0===h.length?(e.splice(o-y,y),o-=y):0===u.length?(e.splice(o-y,y,[1,h]),o=o-y+1):0===h.length?(e.splice(o-y,y,[t,u]),o=o-y+1):(e.splice(o-y,y,[t,u],[1,h]),o=o-y+2)}0!==o&&0===e[o-1][0]?(e[o-1][1]+=e[o][1],e.splice(o,1)):o++,c=0,l=0,u="",h=""}""===e[e.length-1][1]&&e.pop();var m=!1;for(o=1;o<e.length-1;)0===e[o-1][0]&&0===e[o+1][0]&&(e[o][1].substring(e[o][1].length-e[o-1][1].length)===e[o-1][1]?(e[o][1]=e[o-1][1]+e[o][1].substring(0,e[o][1].length-e[o-1][1].length),e[o+1][1]=e[o-1][1]+e[o+1][1],e.splice(o-1,1),m=!0):e[o][1].substring(0,e[o+1][1].length)==e[o+1][1]&&(e[o-1][1]+=e[o+1][1],e[o][1]=e[o][1].substring(e[o+1][1].length)+e[o+1][1],e.splice(o+1,1),m=!0)),o++;m&&a(e,i)}function f(t){return t>=55296&&t<=56319}function d(t){return t>=56320&&t<=57343}function p(t){return d(t.charCodeAt(0))}function b(t){return f(t.charCodeAt(t.length-1))}function v(e,i,n,s){return b(e)||p(s)?null:function(t){for(var e=[],i=0;i<t.length;i++)t[i][1].length>0&&e.push(t[i]);return e}([[0,e],[t,i],[1,n],[0,s]])}function y(t,i,n,s){return e(t,i,n,s,!0)}return y.INSERT=1,y.DELETE=t,y.EQUAL=0,yi=y}(),n=ki(),s=qi(),r=function(){if(Oi)return Ei;Oi=1,Object.defineProperty(Ei,"__esModule",{value:!0});const t=ki(),e=qi();var i;return function(i){i.compose=function(e={},i={},n=!1){"object"!=typeof e&&(e={}),"object"!=typeof i&&(i={});let s=t(i);n||(s=Object.keys(s).reduce(((t,e)=>(null!=s[e]&&(t[e]=s[e]),t)),{}));for(const t in e)void 0!==e[t]&&void 0===i[t]&&(s[t]=e[t]);return Object.keys(s).length>0?s:void 0},i.diff=function(t={},i={}){"object"!=typeof t&&(t={}),"object"!=typeof i&&(i={});const n=Object.keys(t).concat(Object.keys(i)).reduce(((n,s)=>(e(t[s],i[s])||(n[s]=void 0===i[s]?null:i[s]),n)),{});return Object.keys(n).length>0?n:void 0},i.invert=function(t={},e={}){t=t||{};const i=Object.keys(e).reduce(((i,n)=>(e[n]!==t[n]&&void 0!==t[n]&&(i[n]=e[n]),i)),{});return Object.keys(t).reduce(((i,n)=>(t[n]!==e[n]&&void 0===e[n]&&(i[n]=null),i)),i)},i.transform=function(t,e,i=!1){if("object"!=typeof t)return e;if("object"!=typeof e)return;if(!i)return e;const n=Object.keys(e).reduce(((i,n)=>(void 0===t[n]&&(i[n]=e[n]),i)),{});return Object.keys(n).length>0?n:void 0}}(i||(i={})),Ei.default=i,Ei}();e.AttributeMap=r.default;const o=Ni();e.Op=o.default;const l=function(){if(Li)return _i;Li=1,Object.defineProperty(_i,"__esModule",{value:!0});const t=Ni();return _i.default=class{constructor(t){this.ops=t,this.index=0,this.offset=0}hasNext(){return this.peekLength()<1/0}next(e){e||(e=1/0);const i=this.ops[this.index];if(i){const n=this.offset,s=t.default.length(i);if(e>=s-n?(e=s-n,this.index+=1,this.offset=0):this.offset+=e,"number"==typeof i.delete)return{delete:e};{const t={};return i.attributes&&(t.attributes=i.attributes),"number"==typeof i.retain?t.retain=e:"object"==typeof i.retain&&null!==i.retain?t.retain=i.retain:t.insert="string"==typeof i.insert?i.insert.substr(n,e):i.insert,t}}return{retain:1/0}}peek(){return this.ops[this.index]}peekLength(){return this.ops[this.index]?t.default.length(this.ops[this.index])-this.offset:1/0}peekType(){const t=this.ops[this.index];return t?"number"==typeof t.delete?"delete":"number"==typeof t.retain||"object"==typeof t.retain&&null!==t.retain?"retain":"insert":"retain"}rest(){if(this.hasNext()){if(0===this.offset)return this.ops.slice(this.index);{const t=this.offset,e=this.index,i=this.next(),n=this.ops.slice(this.index);return this.offset=t,this.index=e,[i].concat(n)}}return[]}},_i}();e.OpIterator=l.default;const c=String.fromCharCode(0),u=(t,e)=>{if("object"!=typeof t||null===t)throw new Error("cannot retain a "+typeof t);if("object"!=typeof e||null===e)throw new Error("cannot retain a "+typeof e);const i=Object.keys(t)[0];if(!i||i!==Object.keys(e)[0])throw new Error(`embed types not matched: ${i} != ${Object.keys(e)[0]}`);return[i,t[i],e[i]]};class h{constructor(t){this.ops=Array.isArray(t)?t:null!=t&&Array.isArray(t.ops)?t.ops:[]}static registerEmbed(t,e){this.handlers[t]=e}static unregisterEmbed(t){delete this.handlers[t]}static getHandler(t){const e=this.handlers[t];if(!e)throw new Error(`no handlers for embed type "${t}"`);return e}insert(t,e){const i={};return"string"==typeof t&&0===t.length?this:(i.insert=t,null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(i.attributes=e),this.push(i))}delete(t){return t<=0?this:this.push({delete:t})}retain(t,e){if("number"==typeof t&&t<=0)return this;const i={retain:t};return null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(i.attributes=e),this.push(i)}push(t){let e=this.ops.length,i=this.ops[e-1];if(t=n(t),"object"==typeof i){if("number"==typeof t.delete&&"number"==typeof i.delete)return this.ops[e-1]={delete:i.delete+t.delete},this;if("number"==typeof i.delete&&null!=t.insert&&(e-=1,i=this.ops[e-1],"object"!=typeof i))return this.ops.unshift(t),this;if(s(t.attributes,i.attributes)){if("string"==typeof t.insert&&"string"==typeof i.insert)return this.ops[e-1]={insert:i.insert+t.insert},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this;if("number"==typeof t.retain&&"number"==typeof i.retain)return this.ops[e-1]={retain:i.retain+t.retain},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this}}return e===this.ops.length?this.ops.push(t):this.ops.splice(e,0,t),this}chop(){const t=this.ops[this.ops.length-1];return t&&"number"==typeof t.retain&&!t.attributes&&this.ops.pop(),this}filter(t){return this.ops.filter(t)}forEach(t){this.ops.forEach(t)}map(t){return this.ops.map(t)}partition(t){const e=[],i=[];return this.forEach((n=>{(t(n)?e:i).push(n)})),[e,i]}reduce(t,e){return this.ops.reduce(t,e)}changeLength(){return this.reduce(((t,e)=>e.insert?t+o.default.length(e):e.delete?t-e.delete:t),0)}length(){return this.reduce(((t,e)=>t+o.default.length(e)),0)}slice(t=0,e=1/0){const i=[],n=new l.default(this.ops);let s=0;for(;s<e&&n.hasNext();){let r;s<t?r=n.next(t-s):(r=n.next(e-s),i.push(r)),s+=o.default.length(r)}return new h(i)}compose(t){const e=new l.default(this.ops),i=new l.default(t.ops),n=[],o=i.peek();if(null!=o&&"number"==typeof o.retain&&null==o.attributes){let t=o.retain;for(;"insert"===e.peekType()&&e.peekLength()<=t;)t-=e.peekLength(),n.push(e.next());o.retain-t>0&&i.next(o.retain-t)}const c=new h(n);for(;e.hasNext()||i.hasNext();)if("insert"===i.peekType())c.push(i.next());else if("delete"===e.peekType())c.push(e.next());else{const t=Math.min(e.peekLength(),i.peekLength()),n=e.next(t),o=i.next(t);if(o.retain){const l={};if("number"==typeof n.retain)l.retain="number"==typeof o.retain?t:o.retain;else if("number"==typeof o.retain)null==n.retain?l.insert=n.insert:l.retain=n.retain;else{const t=null==n.retain?"insert":"retain",[e,i,s]=u(n[t],o.retain),r=h.getHandler(e);l[t]={[e]:r.compose(i,s,"retain"===t)}}const a=r.default.compose(n.attributes,o.attributes,"number"==typeof n.retain);if(a&&(l.attributes=a),c.push(l),!i.hasNext()&&s(c.ops[c.ops.length-1],l)){const t=new h(e.rest());return c.concat(t).chop()}}else"number"==typeof o.delete&&("number"==typeof n.retain||"object"==typeof n.retain&&null!==n.retain)&&c.push(o)}return c.chop()}concat(t){const e=new h(this.ops.slice());return t.ops.length>0&&(e.push(t.ops[0]),e.ops=e.ops.concat(t.ops.slice(1))),e}diff(t,e){if(this.ops===t.ops)return new h;const n=[this,t].map((e=>e.map((i=>{if(null!=i.insert)return"string"==typeof i.insert?i.insert:c;throw new Error("diff() called "+(e===t?"on":"with")+" non-document")})).join(""))),o=new h,u=i(n[0],n[1],e,!0),a=new l.default(this.ops),f=new l.default(t.ops);return u.forEach((t=>{let e=t[1].length;for(;e>0;){let n=0;switch(t[0]){case i.INSERT:n=Math.min(f.peekLength(),e),o.push(f.next(n));break;case i.DELETE:n=Math.min(e,a.peekLength()),a.next(n),o.delete(n);break;case i.EQUAL:n=Math.min(a.peekLength(),f.peekLength(),e);const t=a.next(n),l=f.next(n);s(t.insert,l.insert)?o.retain(n,r.default.diff(t.attributes,l.attributes)):o.push(l).delete(n)}e-=n}})),o.chop()}eachLine(t,e="\n"){const i=new l.default(this.ops);let n=new h,s=0;for(;i.hasNext();){if("insert"!==i.peekType())return;const r=i.peek(),l=o.default.length(r)-i.peekLength(),c="string"==typeof r.insert?r.insert.indexOf(e,l)-l:-1;if(c<0)n.push(i.next());else if(c>0)n.push(i.next(c));else{if(!1===t(n,i.next(1).attributes||{},s))return;s+=1,n=new h}}n.length()>0&&t(n,{},s)}invert(t){const e=new h;return this.reduce(((i,n)=>{if(n.insert)e.delete(o.default.length(n));else{if("number"==typeof n.retain&&null==n.attributes)return e.retain(n.retain),i+n.retain;if(n.delete||"number"==typeof n.retain){const s=n.delete||n.retain;return t.slice(i,i+s).forEach((t=>{n.delete?e.push(t):n.retain&&n.attributes&&e.retain(o.default.length(t),r.default.invert(n.attributes,t.attributes))})),i+s}if("object"==typeof n.retain&&null!==n.retain){const s=t.slice(i,i+1),o=new l.default(s.ops).next(),[c,a,f]=u(n.retain,o.insert),d=h.getHandler(c);return e.retain({[c]:d.invert(a,f)},r.default.invert(n.attributes,o.attributes)),i+1}}return i}),0),e.chop()}transform(t,e=!1){if(e=!!e,"number"==typeof t)return this.transformPosition(t,e);const i=t,n=new l.default(this.ops),s=new l.default(i.ops),c=new h;for(;n.hasNext()||s.hasNext();)if("insert"!==n.peekType()||!e&&"insert"===s.peekType())if("insert"===s.peekType())c.push(s.next());else{const t=Math.min(n.peekLength(),s.peekLength()),i=n.next(t),o=s.next(t);if(i.delete)continue;if(o.delete)c.push(o);else{const n=i.retain,s=o.retain;let l="object"==typeof s&&null!==s?s:t;if("object"==typeof n&&null!==n&&"object"==typeof s&&null!==s){const t=Object.keys(n)[0];if(t===Object.keys(s)[0]){const i=h.getHandler(t);i&&(l={[t]:i.transform(n[t],s[t],e)})}}c.retain(l,r.default.transform(i.attributes,o.attributes,e))}}else c.retain(o.default.length(n.next()));return c.chop()}transformPosition(t,e=!1){e=!!e;const i=new l.default(this.ops);let n=0;for(;i.hasNext()&&n<=t;){const s=i.peekLength(),r=i.peekType();i.next(),"delete"!==r?("insert"===r&&(n<t||!e)&&(t+=s),n+=s):t-=Math.min(s,t-n)}return t}}h.Op=o.default,h.OpIterator=l.default,h.AttributeMap=r.default,h.handlers={},e.default=h,t.exports=h,t.exports.default=h}(wi,wi.exports)),wi.exports),Ci=vi(Si);class Bi extends ci{static value(){}optimize(){(this.prev||this.next)&&this.remove()}length(){return 0}value(){return""}}Bi.blotName="break",Bi.tagName="BR";let Ri=class extends di{};const Ii={"&":"&","<":"<",">":">",'"':""","'":"'"};function Di(t){return t.replace(/[&<>"']/g,(t=>Ii[t]))}class Vi extends ni{static allowedChildren=[Vi,Bi,ci,Ri];static order=["cursor","inline","link","underline","strike","italic","bold","script","code"];static compare(t,e){const i=Vi.order.indexOf(t),n=Vi.order.indexOf(e);return i>=0||n>=0?i-n:t===e?0:t<e?-1:1}formatAt(t,e,i,n){if(Vi.compare(this.statics.blotName,i)<0&&this.scroll.query(i,Ie.BLOT)){const s=this.isolate(t,e);n&&s.wrap(i,n)}else super.formatAt(t,e,i,n)}optimize(t){if(super.optimize(t),this.parent instanceof Vi&&Vi.compare(this.statics.blotName,this.parent.statics.blotName)>0){const t=this.parent.isolate(this.offset(),this.length());this.moveChildren(t),t.wrap(this)}}}class Hi extends ri{cache={};delta(){return null==this.cache.delta&&(this.cache.delta=Fi(this)),this.cache.delta}deleteAt(t,e){super.deleteAt(t,e),this.cache={}}formatAt(t,e,i,n){e<=0||(this.scroll.query(i,Ie.BLOCK)?t+e===this.length()&&this.format(i,n):super.formatAt(t,Math.min(e,this.length()-t-1),i,n),this.cache={})}insertAt(t,e,i){if(null!=i)return super.insertAt(t,e,i),void(this.cache={});if(0===e.length)return;const n=e.split("\n"),s=n.shift();s.length>0&&(t<this.length()-1||null==this.children.tail?super.insertAt(Math.min(t,this.length()-1),s):this.children.tail.insertAt(this.children.tail.length(),s),this.cache={});let r=this;n.reduce(((t,e)=>(r=r.split(t,!0),r.insertAt(0,e),e.length)),t+s.length)}insertBefore(t,e){const{head:i}=this.children;super.insertBefore(t,e),i instanceof Bi&&i.remove(),this.cache={}}length(){return null==this.cache.length&&(this.cache.length=super.length()+1),this.cache.length}moveChildren(t,e){super.moveChildren(t,e),this.cache={}}optimize(t){super.optimize(t),this.cache={}}path(t){return super.path(t,!0)}removeChild(t){super.removeChild(t),this.cache={}}split(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e&&(0===t||t>=this.length()-1)){const e=this.clone();return 0===t?(this.parent.insertBefore(e,this),this):(this.parent.insertBefore(e,this.next),e)}const i=super.split(t,e);return this.cache={},i}}Hi.blotName="block",Hi.tagName="P",Hi.defaultChild=Bi,Hi.allowedChildren=[Bi,Vi,ci,Ri];class Pi extends ci{attach(){super.attach(),this.attributes=new ze(this.domNode)}delta(){return(new Ci).insert(this.value(),{...this.formats(),...this.attributes.values()})}format(t,e){const i=this.scroll.query(t,Ie.BLOCK_ATTRIBUTE);null!=i&&this.attributes.attribute(i,e)}formatAt(t,e,i,n){this.format(i,n)}insertAt(t,e,i){if(null!=i)return void super.insertAt(t,e,i);const n=e.split("\n"),s=n.pop(),r=n.map((t=>{const e=this.scroll.create(Hi.blotName);return e.insertAt(0,t),e})),o=this.split(t);r.forEach((t=>{this.parent.insertBefore(t,o)})),s&&this.parent.insertBefore(this.scroll.create("text",s),o)}}function Fi(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return t.descendants(Ye).reduce(((t,i)=>0===i.length()?t:t.insert(i.value(),Ui(i,{},e))),new Ci).insert("\n",Ui(t))}function Ui(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return null==t?e:("formats"in t&&"function"==typeof t.formats&&(e={...e,...t.formats()},i&&delete e["code-token"]),null==t.parent||"scroll"===t.parent.statics.blotName||t.parent.statics.scope!==t.statics.scope?e:Ui(t.parent,e,i))}Pi.scope=Ie.BLOCK_BLOT;class Zi extends ci{static blotName="cursor";static className="ql-cursor";static tagName="span";static CONTENTS="\ufeff";static value(){}constructor(t,e,i){super(t,e),this.selection=i,this.textNode=document.createTextNode(Zi.CONTENTS),this.domNode.appendChild(this.textNode),this.savedLength=0}detach(){null!=this.parent&&this.parent.removeChild(this)}format(t,e){if(0!==this.savedLength)return void super.format(t,e);let i=this,n=0;for(;null!=i&&i.statics.scope!==Ie.BLOCK_BLOT;)n+=i.offset(i.parent),i=i.parent;null!=i&&(this.savedLength=Zi.CONTENTS.length,i.optimize(),i.formatAt(n,Zi.CONTENTS.length,t,e),this.savedLength=0)}index(t,e){return t===this.textNode?0:super.index(t,e)}length(){return this.savedLength}position(){return[this.textNode,this.textNode.data.length]}remove(){super.remove(),this.parent=null}restore(){if(this.selection.composing||null==this.parent)return null;const t=this.selection.getNativeRange();for(;null!=this.domNode.lastChild&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);const e=this.prev instanceof Ri?this.prev:null,i=e?e.length():0,n=this.next instanceof Ri?this.next:null,s=n?n.text:"",{textNode:r}=this,o=r.data.split(Zi.CONTENTS).join("");let l;if(r.data=Zi.CONTENTS,e)l=e,(o||n)&&(e.insertAt(e.length(),o+s),n&&n.remove());else if(n)l=n,n.insertAt(0,o);else{const t=document.createTextNode(o);l=this.scroll.create(t),this.parent.insertBefore(l,this)}if(this.remove(),t){const s=(t,s)=>e&&t===e.domNode?s:t===r?i+s-1:n&&t===n.domNode?i+o.length+s:null,c=s(t.start.node,t.start.offset),u=s(t.end.node,t.end.offset);if(null!==c&&null!==u)return{startNode:l.domNode,startOffset:c,endNode:l.domNode,endOffset:u}}return null}update(t,e){if(t.some((t=>"characterData"===t.type&&t.target===this.textNode))){const t=this.restore();t&&(e.range=t)}}optimize(t){super.optimize(t);let{parent:e}=this;for(;e;){if("A"===e.domNode.tagName){this.savedLength=Zi.CONTENTS.length,e.isolate(this.offset(e),this.length()).unwrap(),this.savedLength=0;break}e=e.parent}}value(){return""}}var Ki,zi={exports:{}},Wi=(Ki||(Ki=1,function(t){var e=Object.prototype.hasOwnProperty,i="~";function n(){}function s(t,e,i){this.fn=t,this.context=e,this.once=i||!1}function r(t,e,n,r,o){if("function"!=typeof n)throw new TypeError("The listener must be a function");var l=new s(n,r||t,o),c=i?i+e:e;return t._events[c]?t._events[c].fn?t._events[c]=[t._events[c],l]:t._events[c].push(l):(t._events[c]=l,t._eventsCount++),t}function o(t,e){0==--t._eventsCount?t._events=new n:delete t._events[e]}function l(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(i=!1)),l.prototype.eventNames=function(){var t,n,s=[];if(0===this._eventsCount)return s;for(n in t=this._events)e.call(t,n)&&s.push(i?n.slice(1):n);return Object.getOwnPropertySymbols?s.concat(Object.getOwnPropertySymbols(t)):s},l.prototype.listeners=function(t){var e=this._events[i?i+t:t];if(!e)return[];if(e.fn)return[e.fn];for(var n=0,s=e.length,r=new Array(s);n<s;n++)r[n]=e[n].fn;return r},l.prototype.listenerCount=function(t){var e=this._events[i?i+t:t];return e?e.fn?1:e.length:0},l.prototype.emit=function(t,e,n,s,r,o){var l=i?i+t:t;if(!this._events[l])return!1;var c,u,h=this._events[l],a=arguments.length;if(h.fn){switch(h.once&&this.removeListener(t,h.fn,void 0,!0),a){case 1:return h.fn.call(h.context),!0;case 2:return h.fn.call(h.context,e),!0;case 3:return h.fn.call(h.context,e,n),!0;case 4:return h.fn.call(h.context,e,n,s),!0;case 5:return h.fn.call(h.context,e,n,s,r),!0;case 6:return h.fn.call(h.context,e,n,s,r,o),!0}for(u=1,c=new Array(a-1);u<a;u++)c[u-1]=arguments[u];h.fn.apply(h.context,c)}else{var f,d=h.length;for(u=0;u<d;u++)switch(h[u].once&&this.removeListener(t,h[u].fn,void 0,!0),a){case 1:h[u].fn.call(h[u].context);break;case 2:h[u].fn.call(h[u].context,e);break;case 3:h[u].fn.call(h[u].context,e,n);break;case 4:h[u].fn.call(h[u].context,e,n,s);break;default:if(!c)for(f=1,c=new Array(a-1);f<a;f++)c[f-1]=arguments[f];h[u].fn.apply(h[u].context,c)}}return!0},l.prototype.on=function(t,e,i){return r(this,t,e,i,!1)},l.prototype.once=function(t,e,i){return r(this,t,e,i,!0)},l.prototype.removeListener=function(t,e,n,s){var r=i?i+t:t;if(!this._events[r])return this;if(!e)return o(this,r),this;var l=this._events[r];if(l.fn)l.fn!==e||s&&!l.once||n&&l.context!==n||o(this,r);else{for(var c=0,u=[],h=l.length;c<h;c++)(l[c].fn!==e||s&&!l[c].once||n&&l[c].context!==n)&&u.push(l[c]);u.length?this._events[r]=1===u.length?u[0]:u:o(this,r)}return this},l.prototype.removeAllListeners=function(t){var e;return t?this._events[e=i?i+t:t]&&o(this,e):(this._events=new n,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=i,l.EventEmitter=l,t.exports=l}(zi)),zi.exports),Gi=vi(Wi),Qi=new WeakMap;const Yi=["error","warn","log","info"];let Xi="warn";function Ji(t){if(Xi&&Yi.indexOf(t)<=Yi.indexOf(Xi)){for(var e=arguments.length,i=new Array(e>1?e-1:0),n=1;n<e;n++)i[n-1]=arguments[n];console[t](...i)}}function tn(t){return Yi.reduce(((e,i)=>(e[i]=Ji.bind(console,i,t),e)),{})}Ji.level=tn.level=t=>{Xi=t};const en=tn("quill:events");["selectionchange","mousedown","mouseup","click"].forEach((t=>{document.addEventListener(t,(function(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];Array.from(document.querySelectorAll(".ql-container")).forEach((t=>{const i=Qi.get(t);i&&i.emitter&&i.emitter.handleDOM(...e)}))}))}));class nn extends Gi{static events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_BLOT_MOUNT:"scroll-blot-mount",SCROLL_BLOT_UNMOUNT:"scroll-blot-unmount",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SCROLL_EMBED_UPDATE:"scroll-embed-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change",COMPOSITION_BEFORE_START:"composition-before-start",COMPOSITION_START:"composition-start",COMPOSITION_BEFORE_END:"composition-before-end",COMPOSITION_END:"composition-end"};static sources={API:"api",SILENT:"silent",USER:"user"};constructor(){super(),this.domListeners={},this.on("error",en.error)}emit(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return en.log.call(en,...e),super.emit(...e)}handleDOM(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),n=1;n<e;n++)i[n-1]=arguments[n];(this.domListeners[t.type]||[]).forEach((e=>{let{node:n,handler:s}=e;(t.target===n||n.contains(t.target))&&s(t,...i)}))}listenDOM(t,e,i){this.domListeners[t]||(this.domListeners[t]=[]),this.domListeners[t].push({node:e,handler:i})}}const sn=tn("quill:selection");class rn{constructor(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;this.index=t,this.length=e}}class on{constructor(t,e){this.emitter=e,this.scroll=t,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=this.scroll.create("cursor",this),this.savedRange=new rn(0,0),this.lastRange=this.savedRange,this.lastNative=null,this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,(()=>{this.mouseDown||this.composing||setTimeout(this.update.bind(this,nn.sources.USER),1)})),this.emitter.on(nn.events.SCROLL_BEFORE_UPDATE,(()=>{if(!this.hasFocus())return;const t=this.getNativeRange();null!=t&&t.start.node!==this.cursor.textNode&&this.emitter.once(nn.events.SCROLL_UPDATE,((e,i)=>{try{this.root.contains(t.start.node)&&this.root.contains(t.end.node)&&this.setNativeRange(t.start.node,t.start.offset,t.end.node,t.end.offset);const n=i.some((t=>"characterData"===t.type||"childList"===t.type||"attributes"===t.type&&t.target===this.root));this.update(n?nn.sources.SILENT:e)}catch(t){}}))})),this.emitter.on(nn.events.SCROLL_OPTIMIZE,((t,e)=>{if(e.range){const{startNode:t,startOffset:i,endNode:n,endOffset:s}=e.range;this.setNativeRange(t,i,n,s),this.update(nn.sources.SILENT)}})),this.update(nn.sources.SILENT)}handleComposition(){this.emitter.on(nn.events.COMPOSITION_BEFORE_START,(()=>{this.composing=!0})),this.emitter.on(nn.events.COMPOSITION_END,(()=>{if(this.composing=!1,this.cursor.parent){const t=this.cursor.restore();if(!t)return;setTimeout((()=>{this.setNativeRange(t.startNode,t.startOffset,t.endNode,t.endOffset)}),1)}}))}handleDragging(){this.emitter.listenDOM("mousedown",document.body,(()=>{this.mouseDown=!0})),this.emitter.listenDOM("mouseup",document.body,(()=>{this.mouseDown=!1,this.update(nn.sources.USER)}))}focus(){this.hasFocus()||(this.root.focus({preventScroll:!0}),this.setRange(this.savedRange))}format(t,e){this.scroll.update();const i=this.getNativeRange();if(null!=i&&i.native.collapsed&&!this.scroll.query(t,Ie.BLOCK)){if(i.start.node!==this.cursor.textNode){const t=this.scroll.find(i.start.node,!1);if(null==t)return;if(t instanceof Ye){const e=t.split(i.start.offset);t.parent.insertBefore(this.cursor,e)}else t.insertBefore(this.cursor,i.start.node);this.cursor.attach()}this.cursor.format(t,e),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}getBounds(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;const i=this.scroll.length();let n;t=Math.min(t,i-1),e=Math.min(t+e,i-1)-t;let[s,r]=this.scroll.leaf(t);if(null==s)return null;if(e>0&&r===s.length()){const[e]=this.scroll.leaf(t+1);if(e){const[i]=this.scroll.line(t),[n]=this.scroll.line(t+1);i===n&&(s=e,r=0)}}[n,r]=s.position(r,!0);const o=document.createRange();if(e>0)return o.setStart(n,r),[s,r]=this.scroll.leaf(t+e),null==s?null:([n,r]=s.position(r,!0),o.setEnd(n,r),o.getBoundingClientRect());let l,c="left";if(n instanceof Text){if(!n.data.length)return null;r<n.data.length?(o.setStart(n,r),o.setEnd(n,r+1)):(o.setStart(n,r-1),o.setEnd(n,r),c="right"),l=o.getBoundingClientRect()}else{if(!(s.domNode instanceof Element))return null;l=s.domNode.getBoundingClientRect(),r>0&&(c="right")}return{bottom:l.top+l.height,height:l.height,left:l[c],right:l[c],top:l.top,width:0}}getNativeRange(){const t=document.getSelection();if(null==t||t.rangeCount<=0)return null;const e=t.getRangeAt(0);if(null==e)return null;const i=this.normalizeNative(e);return sn.info("getNativeRange",i),i}getRange(){const t=this.scroll.domNode;if("isConnected"in t&&!t.isConnected)return[null,null];const e=this.getNativeRange();return null==e?[null,null]:[this.normalizedToRange(e),e]}hasFocus(){return document.activeElement===this.root||null!=document.activeElement&&ln(this.root,document.activeElement)}normalizedToRange(t){const e=[[t.start.node,t.start.offset]];t.native.collapsed||e.push([t.end.node,t.end.offset]);const i=e.map((t=>{const[e,i]=t,n=this.scroll.find(e,!0),s=n.offset(this.scroll);return 0===i?s:n instanceof Ye?s+n.index(e,i):s+n.length()})),n=Math.min(Math.max(...i),this.scroll.length()-1),s=Math.min(n,...i);return new rn(s,n-s)}normalizeNative(t){if(!ln(this.root,t.startContainer)||!t.collapsed&&!ln(this.root,t.endContainer))return null;const e={start:{node:t.startContainer,offset:t.startOffset},end:{node:t.endContainer,offset:t.endOffset},native:t};return[e.start,e.end].forEach((t=>{let{node:e,offset:i}=t;for(;!(e instanceof Text)&&e.childNodes.length>0;)if(e.childNodes.length>i)e=e.childNodes[i],i=0;else{if(e.childNodes.length!==i)break;e=e.lastChild,i=e instanceof Text?e.data.length:e.childNodes.length>0?e.childNodes.length:e.childNodes.length+1}t.node=e,t.offset=i})),e}rangeToNative(t){const e=this.scroll.length(),i=(t,i)=>{t=Math.min(e-1,t);const[n,s]=this.scroll.leaf(t);return n?n.position(s,i):[null,-1]};return[...i(t.index,!1),...i(t.index+t.length,!0)]}setNativeRange(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e,s=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(sn.info("setNativeRange",t,e,i,n),null!=t&&(null==this.root.parentNode||null==t.parentNode||null==i.parentNode))return;const r=document.getSelection();if(null!=r)if(null!=t){this.hasFocus()||this.root.focus({preventScroll:!0});const{native:o}=this.getNativeRange()||{};if(null==o||s||t!==o.startContainer||e!==o.startOffset||i!==o.endContainer||n!==o.endOffset){t instanceof Element&&"BR"===t.tagName&&(e=Array.from(t.parentNode.childNodes).indexOf(t),t=t.parentNode),i instanceof Element&&"BR"===i.tagName&&(n=Array.from(i.parentNode.childNodes).indexOf(i),i=i.parentNode);const s=document.createRange();s.setStart(t,e),s.setEnd(i,n),r.removeAllRanges(),r.addRange(s)}}else r.removeAllRanges(),this.root.blur()}setRange(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:nn.sources.API;if("string"==typeof e&&(i=e,e=!1),sn.info("setRange",t),null!=t){const i=this.rangeToNative(t);this.setNativeRange(...i,e)}else this.setNativeRange(null);this.update(i)}update(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:nn.sources.USER;const e=this.lastRange,[i,n]=this.getRange();if(this.lastRange=i,this.lastNative=n,null!=this.lastRange&&(this.savedRange=this.lastRange),!Ce(e,this.lastRange)){if(!this.composing&&null!=n&&n.native.collapsed&&n.start.node!==this.cursor.textNode){const t=this.cursor.restore();t&&this.setNativeRange(t.startNode,t.startOffset,t.endNode,t.endOffset)}const i=[nn.events.SELECTION_CHANGE,ye(this.lastRange),ye(e),t];this.emitter.emit(nn.events.EDITOR_CHANGE,...i),t!==nn.sources.SILENT&&this.emitter.emit(...i)}}}function ln(t,e){return t.contains(e)}const cn=/^[ -~]*$/;class un{constructor(t){this.scroll=t,this.delta=this.getDelta()}applyDelta(t){this.scroll.update();let e=this.scroll.length();this.scroll.batchStart();const i=pn(t),n=new Ci;return function(t){const e=[];return t.forEach((t=>{"string"==typeof t.insert?t.insert.split("\n").forEach(((i,n)=>{n&&e.push({insert:"\n",attributes:t.attributes}),i&&e.push({insert:i,attributes:t.attributes})})):e.push(t)})),e}(i.ops.slice()).reduce(((t,i)=>{const s=Si.Op.length(i);let r=i.attributes||{},o=!1,l=!1;if(null!=i.insert){if(n.retain(s),"string"==typeof i.insert){const n=i.insert;l=!n.endsWith("\n")&&(e<=t||!!this.scroll.descendant(Pi,t)[0]),this.scroll.insertAt(t,n);const[s,o]=this.scroll.line(t);let c=Re({},Ui(s));if(s instanceof Hi){const[t]=s.descendant(Ye,o);t&&(c=Re(c,Ui(t)))}r=Si.AttributeMap.diff(c,r)||{}}else if("object"==typeof i.insert){const n=Object.keys(i.insert)[0];if(null==n)return t;const s=null!=this.scroll.query(n,Ie.INLINE);if(s)(e<=t||this.scroll.descendant(Pi,t)[0])&&(l=!0);else if(t>0){const[e,i]=this.scroll.descendant(Ye,t-1);e instanceof Ri?"\n"!==e.value()[i]&&(o=!0):e instanceof ci&&e.statics.scope===Ie.INLINE_BLOT&&(o=!0)}if(this.scroll.insertAt(t,n,i.insert[n]),s){const[e]=this.scroll.descendant(Ye,t);if(e){const t=Re({},Ui(e));r=Si.AttributeMap.diff(t,r)||{}}}}e+=s}else if(n.push(i),null!==i.retain&&"object"==typeof i.retain){const e=Object.keys(i.retain)[0];if(null==e)return t;this.scroll.updateEmbedAt(t,e,i.retain[e])}Object.keys(r).forEach((e=>{this.scroll.formatAt(t,s,e,r[e])}));const c=o?1:0,u=l?1:0;return e+=c+u,n.retain(c),n.delete(u),t+s+c+u}),0),n.reduce(((t,e)=>"number"==typeof e.delete?(this.scroll.deleteAt(t,e.delete),t):t+Si.Op.length(e)),0),this.scroll.batchEnd(),this.scroll.optimize(),this.update(i)}deleteText(t,e){return this.scroll.deleteAt(t,e),this.update((new Ci).retain(t).delete(e))}formatLine(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.scroll.update(),Object.keys(i).forEach((n=>{this.scroll.lines(t,Math.max(e,1)).forEach((t=>{t.format(n,i[n])}))})),this.scroll.optimize();const n=(new Ci).retain(t).retain(e,ye(i));return this.update(n)}formatText(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Object.keys(i).forEach((n=>{this.scroll.formatAt(t,e,n,i[n])}));const n=(new Ci).retain(t).retain(e,ye(i));return this.update(n)}getContents(t,e){return this.delta.slice(t,t+e)}getDelta(){return this.scroll.lines().reduce(((t,e)=>t.concat(e.delta())),new Ci)}getFormat(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=[],n=[];0===e?this.scroll.path(t).forEach((t=>{const[e]=t;e instanceof Hi?i.push(e):e instanceof Ye&&n.push(e)})):(i=this.scroll.lines(t,e),n=this.scroll.descendants(Ye,t,e));const[s,r]=[i,n].map((t=>{const e=t.shift();if(null==e)return{};let i=Ui(e);for(;Object.keys(i).length>0;){const e=t.shift();if(null==e)return i;i=fn(Ui(e),i)}return i}));return{...s,...r}}getHTML(t,e){const[i,n]=this.scroll.line(t);if(i){const s=i.length();return i.length()>=n+e&&(0!==n||e!==s)?an(i,n,e,!0):an(this.scroll,t,e,!0)}return""}getText(t,e){return this.getContents(t,e).filter((t=>"string"==typeof t.insert)).map((t=>t.insert)).join("")}insertContents(t,e){const i=pn(e),n=(new Ci).retain(t).concat(i);return this.scroll.insertContents(t,i),this.update(n)}insertEmbed(t,e,i){return this.scroll.insertAt(t,e,i),this.update((new Ci).retain(t).insert({[e]:i}))}insertText(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e=e.replace(/\r\n/g,"\n").replace(/\r/g,"\n"),this.scroll.insertAt(t,e),Object.keys(i).forEach((n=>{this.scroll.formatAt(t,e.length,n,i[n])})),this.update((new Ci).retain(t).insert(e,ye(i)))}isBlank(){if(0===this.scroll.children.length)return!0;if(this.scroll.children.length>1)return!1;const t=this.scroll.children.head;return t?.statics.blotName===Hi.blotName&&(!(t.children.length>1)&&t.children.head instanceof Bi)}removeFormat(t,e){const i=this.getText(t,e),[n,s]=this.scroll.line(t+e);let r=0,o=new Ci;null!=n&&(r=n.length()-s,o=n.delta().slice(s,s+r-1).insert("\n"));const l=this.getContents(t,e+r).diff((new Ci).insert(i).concat(o)),c=(new Ci).retain(t).concat(l);return this.applyDelta(c)}update(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0;const n=this.delta;if(1===e.length&&"characterData"===e[0].type&&e[0].target.data.match(cn)&&this.scroll.find(e[0].target)){const s=this.scroll.find(e[0].target),r=Ui(s),o=s.offset(this.scroll),l=e[0].oldValue.replace(Zi.CONTENTS,""),c=(new Ci).insert(l),u=(new Ci).insert(s.value()),h=i&&{oldRange:bn(i.oldRange,-o),newRange:bn(i.newRange,-o)};t=(new Ci).retain(o).concat(c.diff(u,h)).reduce(((t,e)=>e.insert?t.insert(e.insert,r):t.push(e)),new Ci),this.delta=n.compose(t)}else this.delta=this.getDelta(),t&&Ce(n.compose(t),this.delta)||(t=n.diff(this.delta,i));return t}}function hn(t,e,i){if(0===t.length){const[t]=dn(i.pop());return e<=0?`</li></${t}>`:`</li></${t}>${hn([],e-1,i)}`}const[{child:n,offset:s,length:r,indent:o,type:l},...c]=t,[u,h]=dn(l);if(o>e)return i.push(l),o===e+1?`<${u}><li${h}>${an(n,s,r)}${hn(c,o,i)}`:`<${u}><li>${hn(t,e+1,i)}`;if(o===e&&l===i[i.length-1])return`</li><li${h}>${an(n,s,r)}${hn(c,o,i)}`;const[a]=dn(i.pop());return`</li></${a}>${hn(t,e-1,i)}`}function an(t,e,i){let n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if("html"in t&&"function"==typeof t.html)return t.html(e,i);if(t instanceof Ri)return Di(t.value().slice(e,e+i)).replaceAll(" "," ");if(t instanceof ei){if("list-container"===t.statics.blotName){const n=[];return t.children.forEachAt(e,i,((t,e,i)=>{const s="formats"in t&&"function"==typeof t.formats?t.formats():{};n.push({child:t,offset:e,length:i,indent:s.indent||0,type:s.list})})),hn(n,-1,[])}const s=[];if(t.children.forEachAt(e,i,((t,e,i)=>{s.push(an(t,e,i))})),n||"list"===t.statics.blotName)return s.join("");const{outerHTML:r,innerHTML:o}=t.domNode,[l,c]=r.split(`>${o}<`);return"<table"===l?`<table style="border: 1px solid #000;">${s.join("")}<${c}`:`${l}>${s.join("")}<${c}`}return t.domNode instanceof Element?t.domNode.outerHTML:""}function fn(t,e){return Object.keys(e).reduce(((i,n)=>{if(null==t[n])return i;const s=e[n];return i[n]=s===t[n]?s:Array.isArray(s)?s.indexOf(t[n])<0?s.concat([t[n]]):s:[s,t[n]],i}),{})}function dn(t){const e="ordered"===t?"ol":"ul";switch(t){case"checked":return[e,' data-list="checked"'];case"unchecked":return[e,' data-list="unchecked"'];default:return[e,""]}}function pn(t){return t.reduce(((t,e)=>{if("string"==typeof e.insert){const i=e.insert.replace(/\r\n/g,"\n").replace(/\r/g,"\n");return t.insert(i,e.attributes)}return t.push(e)}),new Ci)}function bn(t,e){let{index:i,length:n}=t;return new rn(i+e,n)}class vn{static DEFAULTS={};constructor(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.quill=t,this.options=e}}const yn="\ufeff";class mn extends ci{constructor(t,e){super(t,e),this.contentNode=document.createElement("span"),this.contentNode.setAttribute("contenteditable","false"),Array.from(this.domNode.childNodes).forEach((t=>{this.contentNode.appendChild(t)})),this.leftGuard=document.createTextNode(yn),this.rightGuard=document.createTextNode(yn),this.domNode.appendChild(this.leftGuard),this.domNode.appendChild(this.contentNode),this.domNode.appendChild(this.rightGuard)}index(t,e){return t===this.leftGuard?0:t===this.rightGuard?1:super.index(t,e)}restore(t){let e,i=null;const n=t.data.split(yn).join("");if(t===this.leftGuard)if(this.prev instanceof Ri){const t=this.prev.length();this.prev.insertAt(t,n),i={startNode:this.prev.domNode,startOffset:t+n.length}}else e=document.createTextNode(n),this.parent.insertBefore(this.scroll.create(e),this),i={startNode:e,startOffset:n.length};else t===this.rightGuard&&(this.next instanceof Ri?(this.next.insertAt(0,n),i={startNode:this.next.domNode,startOffset:n.length}):(e=document.createTextNode(n),this.parent.insertBefore(this.scroll.create(e),this.next),i={startNode:e,startOffset:n.length}));return t.data=yn,i}update(t,e){t.forEach((t=>{if("characterData"===t.type&&(t.target===this.leftGuard||t.target===this.rightGuard)){const i=this.restore(t.target);i&&(e.range=i)}}))}}class wn{isComposing=!1;constructor(t,e){this.scroll=t,this.emitter=e,this.setupListeners()}setupListeners(){this.scroll.domNode.addEventListener("compositionstart",(t=>{this.isComposing||this.handleCompositionStart(t)})),this.scroll.domNode.addEventListener("compositionend",(t=>{this.isComposing&&queueMicrotask((()=>{this.handleCompositionEnd(t)}))}))}handleCompositionStart(t){const e=t.target instanceof Node?this.scroll.find(t.target,!0):null;!e||e instanceof mn||(this.emitter.emit(nn.events.COMPOSITION_BEFORE_START,t),this.scroll.batchStart(),this.emitter.emit(nn.events.COMPOSITION_START,t),this.isComposing=!0)}handleCompositionEnd(t){this.emitter.emit(nn.events.COMPOSITION_BEFORE_END,t),this.scroll.batchEnd(),this.emitter.emit(nn.events.COMPOSITION_END,t),this.isComposing=!1}}class gn{static DEFAULTS={modules:{}};static themes={default:gn};modules={};constructor(t,e){this.quill=t,this.options=e}init(){Object.keys(this.options.modules).forEach((t=>{null==this.modules[t]&&this.addModule(t)}))}addModule(t){const e=this.quill.constructor.import(`modules/${t}`);return this.modules[t]=new e(this.quill,this.options.modules[t]||{}),this.modules[t]}}const xn=t=>{const e=t.getBoundingClientRect(),i="offsetWidth"in t&&Math.abs(e.width)/t.offsetWidth||1,n="offsetHeight"in t&&Math.abs(e.height)/t.offsetHeight||1;return{top:e.top,right:e.left+t.clientWidth*i,bottom:e.top+t.clientHeight*n,left:e.left}},kn=t=>{const e=parseInt(t,10);return Number.isNaN(e)?0:e},jn=(t,e,i,n,s,r)=>t<i&&e>n?0:t<i?-(i-t+s):e>n?e-t>n-i?t+s-i:e-n+r:0,An=["block","break","cursor","inline","scroll","text"],qn=tn("quill"),On=new Pe;ei.uiClass="ql-ui";class Mn{static DEFAULTS={bounds:null,modules:{clipboard:!0,keyboard:!0,history:!0,uploader:!0},placeholder:"",readOnly:!1,registry:On,theme:"default"};static events=nn.events;static sources=nn.sources;static version="2.0.3";static imports={delta:Ci,parchment:pi,"core/module":vn,"core/theme":gn};static debug(t){!0===t&&(t="log"),tn.level(t)}static find(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return Qi.get(t)||On.find(t,e)}static import(t){return null==this.imports[t]&&qn.error(`Cannot import ${t}. Are you sure it was registered?`),this.imports[t]}static register(){if("string"!=typeof(arguments.length<=0?void 0:arguments[0])){const t=arguments.length<=0?void 0:arguments[0],e=!!(arguments.length<=1?void 0:arguments[1]),i="attrName"in t?t.attrName:t.blotName;"string"==typeof i?this.register(`formats/${i}`,t,e):Object.keys(t).forEach((i=>{this.register(i,t[i],e)}))}else{const t=arguments.length<=0?void 0:arguments[0],e=arguments.length<=1?void 0:arguments[1];null==this.imports[t]||!!(arguments.length<=2?void 0:arguments[2])||qn.warn(`Overwriting ${t} with`,e),this.imports[t]=e,(t.startsWith("blots/")||t.startsWith("formats/"))&&e&&"boolean"!=typeof e&&"abstract"!==e.blotName&&On.register(e),"function"==typeof e.register&&e.register(On)}}constructor(t){if(this.options=function(t,e){const i=En(t);if(!i)throw new Error("Invalid Quill container");const n=!e.theme||e.theme===Mn.DEFAULTS.theme?gn:Mn.import(`themes/${e.theme}`);if(!n)throw new Error(`Invalid theme ${e.theme}. Did you register it?`);const{modules:s,...r}=Mn.DEFAULTS,{modules:o,...l}=n.DEFAULTS;let c=Tn(e.modules);null!=c&&c.toolbar&&c.toolbar.constructor!==Object&&(c={...c,toolbar:{container:c.toolbar}});const u=Re({},Tn(s),Tn(o),c),h={...r,...Nn(l),...Nn(e)};let a=e.registry;return a?e.formats&&qn.warn('Ignoring "formats" option because "registry" is specified'):a=e.formats?((t,e,i)=>{const n=new Pe;return An.forEach((t=>{const i=e.query(t);i&&n.register(i)})),t.forEach((t=>{let s=e.query(t);s||i.error(`Cannot register "${t}" specified in "formats" config. Are you sure it was registered?`);let r=0;for(;s;)if(n.register(s),s="blotName"in s?s.requiredContainer??null:null,r+=1,r>100){i.error(`Cycle detected in registering blot requiredContainer: "${t}"`);break}})),n})(e.formats,h.registry,qn):h.registry,{...h,registry:a,container:i,theme:n,modules:Object.entries(u).reduce(((t,e)=>{let[i,n]=e;if(!n)return t;const s=Mn.import(`modules/${i}`);return null==s?(qn.error(`Cannot load ${i} module. Are you sure you registered it?`),t):{...t,[i]:Re({},s.DEFAULTS||{},n)}}),{}),bounds:En(h.bounds)}}(t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}),this.container=this.options.container,null==this.container)return void qn.error("Invalid Quill container",t);this.options.debug&&Mn.debug(this.options.debug);const e=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",Qi.set(this.container,this),this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.emitter=new nn;const i=ai.blotName,n=this.options.registry.query(i);if(!n||!("blotName"in n))throw new Error(`Cannot initialize Quill without "${i}" blot`);if(this.scroll=new n(this.options.registry,this.root,{emitter:this.emitter}),this.editor=new un(this.scroll),this.selection=new on(this.scroll,this.emitter),this.composition=new wn(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.uploader=this.theme.addModule("uploader"),this.theme.addModule("input"),this.theme.addModule("uiNode"),this.theme.init(),this.emitter.on(nn.events.EDITOR_CHANGE,(t=>{t===nn.events.TEXT_CHANGE&&this.root.classList.toggle("ql-blank",this.editor.isBlank())})),this.emitter.on(nn.events.SCROLL_UPDATE,((t,e)=>{const i=this.selection.lastRange,[n]=this.selection.getRange(),s=i&&n?{oldRange:i,newRange:n}:void 0;Ln.call(this,(()=>this.editor.update(null,e,s)),t)})),this.emitter.on(nn.events.SCROLL_EMBED_UPDATE,((t,e)=>{const i=this.selection.lastRange,[n]=this.selection.getRange(),s=i&&n?{oldRange:i,newRange:n}:void 0;Ln.call(this,(()=>{const i=(new Ci).retain(t.offset(this)).retain({[t.statics.blotName]:e});return this.editor.update(i,[],s)}),Mn.sources.USER)})),e){const t=this.clipboard.convert({html:`${e}<p><br></p>`,text:"\n"});this.setContents(t)}this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable(),this.allowReadOnlyEdits=!1}addContainer(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if("string"==typeof t){const e=t;(t=document.createElement("div")).classList.add(e)}return this.container.insertBefore(t,e),t}blur(){this.selection.setRange(null)}deleteText(t,e,i){return[t,e,,i]=$n(t,e,i),Ln.call(this,(()=>this.editor.deleteText(t,e)),i,t,-1*e)}disable(){this.enable(!1)}editReadOnly(t){this.allowReadOnlyEdits=!0;const e=t();return this.allowReadOnlyEdits=!1,e}enable(){let t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.scroll.enable(t),this.container.classList.toggle("ql-disabled",!t)}focus(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.selection.focus(),t.preventScroll||this.scrollSelectionIntoView()}format(t,e){return Ln.call(this,(()=>{const i=this.getSelection(!0);let n=new Ci;if(null==i)return n;if(this.scroll.query(t,Ie.BLOCK))n=this.editor.formatLine(i.index,i.length,{[t]:e});else{if(0===i.length)return this.selection.format(t,e),n;n=this.editor.formatText(i.index,i.length,{[t]:e})}return this.setSelection(i,nn.sources.SILENT),n}),arguments.length>2&&void 0!==arguments[2]?arguments[2]:nn.sources.API)}formatLine(t,e,i,n,s){let r;return[t,e,r,s]=$n(t,e,i,n,s),Ln.call(this,(()=>this.editor.formatLine(t,e,r)),s,t,0)}formatText(t,e,i,n,s){let r;return[t,e,r,s]=$n(t,e,i,n,s),Ln.call(this,(()=>this.editor.formatText(t,e,r)),s,t,0)}getBounds(t){let e=null;if(e="number"==typeof t?this.selection.getBounds(t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0):this.selection.getBounds(t.index,t.length),!e)return null;const i=this.container.getBoundingClientRect();return{bottom:e.bottom-i.top,height:e.height,left:e.left-i.left,right:e.right-i.left,top:e.top-i.top,width:e.width}}getContents(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-t;return[t,e]=$n(t,e),this.editor.getContents(t,e)}getFormat(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getSelection(!0);return"number"==typeof t?this.editor.getFormat(t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0):this.editor.getFormat(t.index,t.length)}getIndex(t){return t.offset(this.scroll)}getLength(){return this.scroll.length()}getLeaf(t){return this.scroll.leaf(t)}getLine(t){return this.scroll.line(t)}getLines(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE;return"number"!=typeof t?this.scroll.lines(t.index,t.length):this.scroll.lines(t,e)}getModule(t){return this.theme.modules[t]}getSelection(){return arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&this.focus(),this.update(),this.selection.getRange()[0]}getSemanticHTML(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1?arguments[1]:void 0;return"number"==typeof t&&(e=e??this.getLength()-t),[t,e]=$n(t,e),this.editor.getHTML(t,e)}getText(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1?arguments[1]:void 0;return"number"==typeof t&&(e=e??this.getLength()-t),[t,e]=$n(t,e),this.editor.getText(t,e)}hasFocus(){return this.selection.hasFocus()}insertEmbed(t,e,i){return Ln.call(this,(()=>this.editor.insertEmbed(t,e,i)),arguments.length>3&&void 0!==arguments[3]?arguments[3]:Mn.sources.API,t)}insertText(t,e,i,n,s){let r;return[t,,r,s]=$n(t,0,i,n,s),Ln.call(this,(()=>this.editor.insertText(t,e,r)),s,t,e.length)}isEnabled(){return this.scroll.isEnabled()}off(){return this.emitter.off(...arguments)}on(){return this.emitter.on(...arguments)}once(){return this.emitter.once(...arguments)}removeFormat(t,e,i){return[t,e,,i]=$n(t,e,i),Ln.call(this,(()=>this.editor.removeFormat(t,e)),i,t)}scrollRectIntoView(t){((t,e)=>{const i=t.ownerDocument;let n=e,s=t;for(;s;){const t=s===i.body,e=t?{top:0,right:window.visualViewport?.width??i.documentElement.clientWidth,bottom:window.visualViewport?.height??i.documentElement.clientHeight,left:0}:xn(s),o=getComputedStyle(s),l=jn(n.left,n.right,e.left,e.right,kn(o.scrollPaddingLeft),kn(o.scrollPaddingRight)),c=jn(n.top,n.bottom,e.top,e.bottom,kn(o.scrollPaddingTop),kn(o.scrollPaddingBottom));if(l||c)if(t)i.defaultView?.scrollBy(l,c);else{const{scrollLeft:t,scrollTop:e}=s;c&&(s.scrollTop+=c),l&&(s.scrollLeft+=l);const i=s.scrollLeft-t,r=s.scrollTop-e;n={left:n.left-i,top:n.top-r,right:n.right-i,bottom:n.bottom-r}}s=t||"fixed"===o.position?null:(r=s).parentElement||r.getRootNode().host||null}var r})(this.root,t)}scrollIntoView(){console.warn("Quill#scrollIntoView() has been deprecated and will be removed in the near future. Please use Quill#scrollSelectionIntoView() instead."),this.scrollSelectionIntoView()}scrollSelectionIntoView(){const t=this.selection.lastRange,e=t&&this.selection.getBounds(t.index,t.length);e&&this.scrollRectIntoView(e)}setContents(t){return Ln.call(this,(()=>{t=new Ci(t);const e=this.getLength(),i=this.editor.deleteText(0,e),n=this.editor.insertContents(0,t),s=this.editor.deleteText(this.getLength()-1,1);return i.compose(n).compose(s)}),arguments.length>1&&void 0!==arguments[1]?arguments[1]:nn.sources.API)}setSelection(t,e,i){null==t?this.selection.setRange(null,e||Mn.sources.API):([t,e,,i]=$n(t,e,i),this.selection.setRange(new rn(Math.max(0,t),e),i),i!==nn.sources.SILENT&&this.scrollSelectionIntoView())}setText(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:nn.sources.API;const i=(new Ci).insert(t);return this.setContents(i,e)}update(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:nn.sources.USER;const e=this.scroll.update(t);return this.selection.update(t),e}updateContents(t){return Ln.call(this,(()=>(t=new Ci(t),this.editor.applyDelta(t))),arguments.length>1&&void 0!==arguments[1]?arguments[1]:nn.sources.API,!0)}}function En(t){return"string"==typeof t?document.querySelector(t):t}function Tn(t){return Object.entries(t??{}).reduce(((t,e)=>{let[i,n]=e;return{...t,[i]:!0===n?{}:n}}),{})}function Nn(t){return Object.fromEntries(Object.entries(t).filter((t=>void 0!==t[1])))}function Ln(t,e,i,n){if(!this.isEnabled()&&e===nn.sources.USER&&!this.allowReadOnlyEdits)return new Ci;let s=null==i?null:this.getSelection();const r=this.editor.delta,o=t();if(null!=s&&(!0===i&&(i=s.index),null==n?s=_n(s,o,e):0!==n&&(s=_n(s,i,n,e)),this.setSelection(s,nn.sources.SILENT)),o.length()>0){const t=[nn.events.TEXT_CHANGE,o,r,e];this.emitter.emit(nn.events.EDITOR_CHANGE,...t),e!==nn.sources.SILENT&&this.emitter.emit(...t)}return o}function $n(t,e,i,n,s){let r={};return"number"==typeof t.index&&"number"==typeof t.length?"number"!=typeof e?(s=n,n=i,i=e,e=t.length,t=t.index):(e=t.length,t=t.index):"number"!=typeof e&&(s=n,n=i,i=e,e=0),"object"==typeof i?(r=i,s=n):"string"==typeof i&&(null!=n?r[i]=n:s=i),[t,e,r,s=s||nn.sources.API]}function _n(t,e,i,n){const s="number"==typeof i?i:0;if(null==t)return null;let r,o;return[r,o]=[t.index,t.index+t.length].map(e&&"function"==typeof e.transformPosition?t=>e.transformPosition(t,n!==nn.sources.USER):t=>t<e||t===e&&n===nn.sources.USER?t:s>=0?t+s:Math.max(e,t+s)),new rn(r,o-r)}class Sn extends li{}function Cn(t){return t instanceof Hi||t instanceof Pi}function Bn(t){return"function"==typeof t.updateContent}function Rn(t,e,i){i.reduce(((e,i)=>{const n=Si.Op.length(i);let s=i.attributes||{};if(null!=i.insert)if("string"==typeof i.insert){t.insertAt(e,i.insert);const[n]=t.descendant(Ye,e),r=Ui(n);s=Si.AttributeMap.diff(r,s)||{}}else if("object"==typeof i.insert){const n=Object.keys(i.insert)[0];if(null==n)return e;if(t.insertAt(e,n,i.insert[n]),null!=t.scroll.query(n,Ie.INLINE)){const[i]=t.descendant(Ye,e),n=Ui(i);s=Si.AttributeMap.diff(n,s)||{}}}return Object.keys(s).forEach((i=>{t.formatAt(e,n,i,s[i])})),e+n}),e)}const In={scope:Ie.BLOCK,whitelist:["right","center","justify"]},Dn=new De("align","align",In),Vn=new Ue("align","ql-align",In),Hn=new Ke("align","text-align",In);class Pn extends Ke{value(t){let e=super.value(t);return e.startsWith("rgb(")?(e=e.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),`#${e.split(",").map((t=>`00${parseInt(t,10).toString(16)}`.slice(-2))).join("")}`):e}}const Fn=new Ue("color","ql-color",{scope:Ie.INLINE}),Un=new Pn("color","color",{scope:Ie.INLINE}),Zn=new Ue("background","ql-bg",{scope:Ie.INLINE}),Kn=new Pn("background","background-color",{scope:Ie.INLINE});class zn extends Sn{static create(t){const e=super.create(t);return e.setAttribute("spellcheck","false"),e}code(t,e){return this.children.map((t=>t.length()<=1?"":t.domNode.innerText)).join("\n").slice(t,t+e)}html(t,e){return`<pre>\n${Di(this.code(t,e))}\n</pre>`}}class Wn extends Hi{static TAB=" ";static register(){Mn.register(zn)}}class Gn extends Vi{}Gn.blotName="code",Gn.tagName="CODE",Wn.blotName="code-block",Wn.className="ql-code-block",Wn.tagName="DIV",zn.blotName="code-block-container",zn.className="ql-code-block-container",zn.tagName="DIV",zn.allowedChildren=[Wn],Wn.allowedChildren=[Ri,Bi,Zi],Wn.requiredContainer=zn;const Qn={scope:Ie.BLOCK,whitelist:["rtl"]},Yn=new De("direction","dir",Qn),Xn=new Ue("direction","ql-direction",Qn),Jn=new Ke("direction","direction",Qn),ts={scope:Ie.INLINE,whitelist:["serif","monospace"]},es=new Ue("font","ql-font",ts),is=new class extends Ke{value(t){return super.value(t).replace(/["']/g,"")}}("font","font-family",ts),ns=new Ue("size","ql-size",{scope:Ie.INLINE,whitelist:["small","large","huge"]}),ss=new Ke("size","font-size",{scope:Ie.INLINE,whitelist:["10px","18px","32px"]}),rs=tn("quill:keyboard"),os=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey";class ls extends vn{static match(t,e){return!["altKey","ctrlKey","metaKey","shiftKey"].some((i=>!!e[i]!==t[i]&&null!==e[i]))&&(e.key===t.key||e.key===t.which)}constructor(t,e){super(t,e),this.bindings={},Object.keys(this.options.bindings).forEach((t=>{this.options.bindings[t]&&this.addBinding(this.options.bindings[t])})),this.addBinding({key:"Enter",shiftKey:null},this.handleEnter),this.addBinding({key:"Enter",metaKey:null,ctrlKey:null,altKey:null},(()=>{})),/Firefox/i.test(navigator.userAgent)?(this.addBinding({key:"Backspace"},{collapsed:!0},this.handleBackspace),this.addBinding({key:"Delete"},{collapsed:!0},this.handleDelete)):(this.addBinding({key:"Backspace"},{collapsed:!0,prefix:/^.?$/},this.handleBackspace),this.addBinding({key:"Delete"},{collapsed:!0,suffix:/^.?$/},this.handleDelete)),this.addBinding({key:"Backspace"},{collapsed:!1},this.handleDeleteRange),this.addBinding({key:"Delete"},{collapsed:!1},this.handleDeleteRange),this.addBinding({key:"Backspace",altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},this.handleBackspace),this.listen()}addBinding(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const n=function(t){if("string"==typeof t||"number"==typeof t)t={key:t};else{if("object"!=typeof t)return null;t=ye(t)}return t.shortKey&&(t[os]=t.shortKey,delete t.shortKey),t}(t);null!=n?("function"==typeof e&&(e={handler:e}),"function"==typeof i&&(i={handler:i}),(Array.isArray(n.key)?n.key:[n.key]).forEach((t=>{const s={...n,key:t,...e,...i};this.bindings[s.key]=this.bindings[s.key]||[],this.bindings[s.key].push(s)}))):rs.warn("Attempted to add invalid keyboard binding",n)}listen(){this.quill.root.addEventListener("keydown",(t=>{if(t.defaultPrevented||t.isComposing)return;if(229===t.keyCode&&("Enter"===t.key||"Backspace"===t.key))return;const e=(this.bindings[t.key]||[]).concat(this.bindings[t.which]||[]).filter((e=>ls.match(t,e)));if(0===e.length)return;const i=Mn.find(t.target,!0);if(i&&i.scroll!==this.quill.scroll)return;const n=this.quill.getSelection();if(null==n||!this.quill.hasFocus())return;const[s,r]=this.quill.getLine(n.index),[o,l]=this.quill.getLeaf(n.index),[c,u]=0===n.length?[o,l]:this.quill.getLeaf(n.index+n.length),h=o instanceof di?o.value().slice(0,l):"",a=c instanceof di?c.value().slice(u):"",f={collapsed:0===n.length,empty:0===n.length&&s.length()<=1,format:this.quill.getFormat(n),line:s,offset:r,prefix:h,suffix:a,event:t};e.some((t=>{if(null!=t.collapsed&&t.collapsed!==f.collapsed)return!1;if(null!=t.empty&&t.empty!==f.empty)return!1;if(null!=t.offset&&t.offset!==f.offset)return!1;if(Array.isArray(t.format)){if(t.format.every((t=>null==f.format[t])))return!1}else if("object"==typeof t.format&&!Object.keys(t.format).every((e=>!0===t.format[e]?null!=f.format[e]:!1===t.format[e]?null==f.format[e]:Ce(t.format[e],f.format[e]))))return!1;return!(null!=t.prefix&&!t.prefix.test(f.prefix)||null!=t.suffix&&!t.suffix.test(f.suffix)||!0===t.handler.call(this,n,f,t))}))&&t.preventDefault()}))}handleBackspace(t,e){const i=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(e.prefix)?2:1;if(0===t.index||this.quill.getLength()<=1)return;let n={};const[s]=this.quill.getLine(t.index);let r=(new Ci).retain(t.index-i).delete(i);if(0===e.offset){const[e]=this.quill.getLine(t.index-1);if(e&&!("block"===e.statics.blotName&&e.length()<=1)){const e=s.formats(),i=this.quill.getFormat(t.index-1,1);if(n=Si.AttributeMap.diff(e,i)||{},Object.keys(n).length>0){const e=(new Ci).retain(t.index+s.length()-2).retain(1,n);r=r.compose(e)}}}this.quill.updateContents(r,Mn.sources.USER),this.quill.focus()}handleDelete(t,e){const i=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(e.suffix)?2:1;if(t.index>=this.quill.getLength()-i)return;let n={};const[s]=this.quill.getLine(t.index);let r=(new Ci).retain(t.index).delete(i);if(e.offset>=s.length()-1){const[e]=this.quill.getLine(t.index+1);if(e){const i=s.formats(),o=this.quill.getFormat(t.index,1);n=Si.AttributeMap.diff(i,o)||{},Object.keys(n).length>0&&(r=r.retain(e.length()-1).retain(1,n))}}this.quill.updateContents(r,Mn.sources.USER),this.quill.focus()}handleDeleteRange(t){ds({range:t,quill:this.quill}),this.quill.focus()}handleEnter(t,e){const i=Object.keys(e.format).reduce(((t,i)=>(this.quill.scroll.query(i,Ie.BLOCK)&&!Array.isArray(e.format[i])&&(t[i]=e.format[i]),t)),{}),n=(new Ci).retain(t.index).delete(t.length).insert("\n",i);this.quill.updateContents(n,Mn.sources.USER),this.quill.setSelection(t.index+1,Mn.sources.SILENT),this.quill.focus()}}const cs={bindings:{bold:as("bold"),italic:as("italic"),underline:as("underline"),indent:{key:"Tab",format:["blockquote","indent","list"],handler(t,e){return!(!e.collapsed||0===e.offset)||(this.quill.format("indent","+1",Mn.sources.USER),!1)}},outdent:{key:"Tab",shiftKey:!0,format:["blockquote","indent","list"],handler(t,e){return!(!e.collapsed||0===e.offset)||(this.quill.format("indent","-1",Mn.sources.USER),!1)}},"outdent backspace":{key:"Backspace",collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler(t,e){null!=e.format.indent?this.quill.format("indent","-1",Mn.sources.USER):null!=e.format.list&&this.quill.format("list",!1,Mn.sources.USER)}},"indent code-block":us(!0),"outdent code-block":us(!1),"remove tab":{key:"Tab",shiftKey:!0,collapsed:!0,prefix:/\t$/,handler(t){this.quill.deleteText(t.index-1,1,Mn.sources.USER)}},tab:{key:"Tab",handler(t,e){if(e.format.table)return!0;this.quill.history.cutoff();const i=(new Ci).retain(t.index).delete(t.length).insert("\t");return this.quill.updateContents(i,Mn.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index+1,Mn.sources.SILENT),!1}},"blockquote empty enter":{key:"Enter",collapsed:!0,format:["blockquote"],empty:!0,handler(){this.quill.format("blockquote",!1,Mn.sources.USER)}},"list empty enter":{key:"Enter",collapsed:!0,format:["list"],empty:!0,handler(t,e){const i={list:!1};e.format.indent&&(i.indent=!1),this.quill.formatLine(t.index,t.length,i,Mn.sources.USER)}},"checklist enter":{key:"Enter",collapsed:!0,format:{list:"checked"},handler(t){const[e,i]=this.quill.getLine(t.index),n={...e.formats(),list:"checked"},s=(new Ci).retain(t.index).insert("\n",n).retain(e.length()-i-1).retain(1,{list:"unchecked"});this.quill.updateContents(s,Mn.sources.USER),this.quill.setSelection(t.index+1,Mn.sources.SILENT),this.quill.scrollSelectionIntoView()}},"header enter":{key:"Enter",collapsed:!0,format:["header"],suffix:/^$/,handler(t,e){const[i,n]=this.quill.getLine(t.index),s=(new Ci).retain(t.index).insert("\n",e.format).retain(i.length()-n-1).retain(1,{header:null});this.quill.updateContents(s,Mn.sources.USER),this.quill.setSelection(t.index+1,Mn.sources.SILENT),this.quill.scrollSelectionIntoView()}},"table backspace":{key:"Backspace",format:["table"],collapsed:!0,offset:0,handler(){}},"table delete":{key:"Delete",format:["table"],collapsed:!0,suffix:/^$/,handler(){}},"table enter":{key:"Enter",shiftKey:null,format:["table"],handler(t){const e=this.quill.getModule("table");if(e){const[i,n,s,r]=e.getTable(t),o=function(t,e,i,n){return null==e.prev&&null==e.next?null==i.prev&&null==i.next?0===n?-1:1:null==i.prev?-1:1:null==e.prev?-1:null==e.next?1:null}(0,n,s,r);if(null==o)return;let l=i.offset();if(o<0){const e=(new Ci).retain(l).insert("\n");this.quill.updateContents(e,Mn.sources.USER),this.quill.setSelection(t.index+1,t.length,Mn.sources.SILENT)}else if(o>0){l+=i.length();const t=(new Ci).retain(l).insert("\n");this.quill.updateContents(t,Mn.sources.USER),this.quill.setSelection(l,Mn.sources.USER)}}}},"table tab":{key:"Tab",shiftKey:null,format:["table"],handler(t,e){const{event:i,line:n}=e,s=n.offset(this.quill.scroll);this.quill.setSelection(i.shiftKey?s-1:s+n.length(),Mn.sources.USER)}},"list autofill":{key:" ",shiftKey:null,collapsed:!0,format:{"code-block":!1,blockquote:!1,table:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler(t,e){if(null==this.quill.scroll.query("list"))return!0;const{length:i}=e.prefix,[n,s]=this.quill.getLine(t.index);if(s>i)return!0;let r;switch(e.prefix.trim()){case"[]":case"[ ]":r="unchecked";break;case"[x]":r="checked";break;case"-":case"*":r="bullet";break;default:r="ordered"}this.quill.insertText(t.index," ",Mn.sources.USER),this.quill.history.cutoff();const o=(new Ci).retain(t.index-s).delete(i+1).retain(n.length()-2-s).retain(1,{list:r});return this.quill.updateContents(o,Mn.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index-i,Mn.sources.SILENT),!1}},"code exit":{key:"Enter",collapsed:!0,format:["code-block"],prefix:/^$/,suffix:/^\s*$/,handler(t){const[e,i]=this.quill.getLine(t.index);let n=2,s=e;for(;null!=s&&s.length()<=1&&s.formats()["code-block"];)if(s=s.prev,n-=1,n<=0){const n=(new Ci).retain(t.index+e.length()-i-2).retain(1,{"code-block":null}).delete(1);return this.quill.updateContents(n,Mn.sources.USER),this.quill.setSelection(t.index-1,Mn.sources.SILENT),!1}return!0}},"embed left":hs("ArrowLeft",!1),"embed left shift":hs("ArrowLeft",!0),"embed right":hs("ArrowRight",!1),"embed right shift":hs("ArrowRight",!0),"table down":fs(!1),"table up":fs(!0)}};function us(t){return{key:"Tab",shiftKey:!t,format:{"code-block":!0},handler(e,i){let{event:n}=i;const s=this.quill.scroll.query("code-block"),{TAB:r}=s;if(0===e.length&&!n.shiftKey)return this.quill.insertText(e.index,r,Mn.sources.USER),void this.quill.setSelection(e.index+r.length,Mn.sources.SILENT);const o=0===e.length?this.quill.getLines(e.index,1):this.quill.getLines(e);let{index:l,length:c}=e;o.forEach(((e,i)=>{t?(e.insertAt(0,r),0===i?l+=r.length:c+=r.length):e.domNode.textContent.startsWith(r)&&(e.deleteAt(0,r.length),0===i?l-=r.length:c-=r.length)})),this.quill.update(Mn.sources.USER),this.quill.setSelection(l,c,Mn.sources.SILENT)}}}function hs(t,e){const i="ArrowLeft"===t?"prefix":"suffix";return{key:t,shiftKey:e,altKey:null,[i]:/^$/,handler(i){let{index:n}=i;"ArrowRight"===t&&(n+=i.length+1);const[s]=this.quill.getLeaf(n);return!(s instanceof ci&&("ArrowLeft"===t?e?this.quill.setSelection(i.index-1,i.length+1,Mn.sources.USER):this.quill.setSelection(i.index-1,Mn.sources.USER):e?this.quill.setSelection(i.index,i.length+1,Mn.sources.USER):this.quill.setSelection(i.index+i.length+1,Mn.sources.USER),1))}}}function as(t){return{key:t[0],shortKey:!0,handler(e,i){this.quill.format(t,!i.format[t],Mn.sources.USER)}}}function fs(t){return{key:t?"ArrowUp":"ArrowDown",collapsed:!0,format:["table"],handler(e,i){const n=t?"prev":"next",s=i.line,r=s.parent[n];if(null!=r){if("table-row"===r.statics.blotName){let t=r.children.head,e=s;for(;null!=e.prev;)e=e.prev,t=t.next;const n=t.offset(this.quill.scroll)+Math.min(i.offset,t.length()-1);this.quill.setSelection(n,0,Mn.sources.USER)}}else{const e=s.table()[n];null!=e&&this.quill.setSelection(t?e.offset(this.quill.scroll)+e.length()-1:e.offset(this.quill.scroll),0,Mn.sources.USER)}return!1}}}function ds(t){let{quill:e,range:i}=t;const n=e.getLines(i);let s={};if(n.length>1){const t=n[0].formats(),e=n[n.length-1].formats();s=Si.AttributeMap.diff(e,t)||{}}e.deleteText(i,Mn.sources.USER),Object.keys(s).length>0&&e.formatLine(i.index,1,s,Mn.sources.USER),e.setSelection(i.index,Mn.sources.SILENT)}ls.DEFAULTS=cs;const ps=/font-weight:\s*normal/,bs=["P","OL","UL"],vs=t=>t&&bs.includes(t.tagName),ys=/\bmso-list:[^;]*ignore/i,ms=/\bmso-list:[^;]*\bl(\d+)/i,ws=/\bmso-list:[^;]*\blevel(\d+)/i,gs=[function(t){"urn:schemas-microsoft-com:office:word"===t.documentElement.getAttribute("xmlns:w")&&(t=>{const e=Array.from(t.querySelectorAll("[style*=mso-list]")),i=[],n=[];e.forEach((t=>{(t.getAttribute("style")||"").match(ys)?i.push(t):n.push(t)})),i.forEach((t=>t.parentNode?.removeChild(t)));const s=t.documentElement.innerHTML,r=n.map((t=>((t,e)=>{const i=t.getAttribute("style"),n=i?.match(ms);if(!n)return null;const s=Number(n[1]),r=i?.match(ws),o=r?Number(r[1]):1,l=new RegExp(`@list l${s}:level${o}\\s*\\{[^\\}]*mso-level-number-format:\\s*([\\w-]+)`,"i"),c=e.match(l);return{id:s,indent:o,type:c&&"bullet"===c[1]?"bullet":"ordered",element:t}})(t,s))).filter((t=>t));for(;r.length;){const t=[];let e=r.shift();for(;e;)t.push(e),e=r.length&&r[0]?.element===e.element.nextElementSibling&&r[0].id===e.id?r.shift():null;const i=document.createElement("ul");t.forEach((t=>{const e=document.createElement("li");e.setAttribute("data-list",t.type),t.indent>1&&e.setAttribute("class","ql-indent-"+(t.indent-1)),e.innerHTML=t.element.innerHTML,i.appendChild(e)}));const n=t[0]?.element,{parentNode:s}=n??{};n&&s?.replaceChild(i,n),t.slice(1).forEach((t=>{let{element:e}=t;s?.removeChild(e)}))}})(t)},function(t){t.querySelector('[id^="docs-internal-guid-"]')&&((t=>{Array.from(t.querySelectorAll('b[style*="font-weight"]')).filter((t=>t.getAttribute("style")?.match(ps))).forEach((e=>{const i=t.createDocumentFragment();i.append(...e.childNodes),e.parentNode?.replaceChild(i,e)}))})(t),(t=>{Array.from(t.querySelectorAll("br")).filter((t=>vs(t.previousElementSibling)&&vs(t.nextElementSibling))).forEach((t=>{t.parentNode?.removeChild(t)}))})(t))}],xs=tn("quill:clipboard"),ks=[[Node.TEXT_NODE,function(t,e,i){let n=t.data;if("O:P"===t.parentElement?.tagName)return e.insert(n.trim());if(!Ts(t)){if(0===n.trim().length&&n.includes("\n")&&!function(t,e){return t.previousElementSibling&&t.nextElementSibling&&!Ms(t.previousElementSibling,e)&&!Ms(t.nextElementSibling,e)}(t,i))return e;n=n.replace(/[^\S\u00a0]/g," "),n=n.replace(/ {2,}/g," "),(null==t.previousSibling&&null!=t.parentElement&&Ms(t.parentElement,i)||t.previousSibling instanceof Element&&Ms(t.previousSibling,i))&&(n=n.replace(/^ /,"")),(null==t.nextSibling&&null!=t.parentElement&&Ms(t.parentElement,i)||t.nextSibling instanceof Element&&Ms(t.nextSibling,i))&&(n=n.replace(/ $/,"")),n=n.replaceAll(" "," ")}return e.insert(n)}],[Node.TEXT_NODE,$s],["br",function(t,e){return Os(e,"\n")||e.insert("\n"),e}],[Node.ELEMENT_NODE,$s],[Node.ELEMENT_NODE,function(t,e,i){const n=i.query(t);if(null==n)return e;if(n.prototype instanceof ci){const e={},s=n.value(t);if(null!=s)return e[n.blotName]=s,(new Ci).insert(e,n.formats(t,i))}else if(n.prototype instanceof ri&&!Os(e,"\n")&&e.insert("\n"),"blotName"in n&&"formats"in n&&"function"==typeof n.formats)return qs(e,n.blotName,n.formats(t,i),i);return e}],[Node.ELEMENT_NODE,function(t,e,i){const n=De.keys(t),s=Ue.keys(t),r=Ke.keys(t),o={};return n.concat(s).concat(r).forEach((e=>{let n=i.query(e,Ie.ATTRIBUTE);null!=n&&(o[n.attrName]=n.value(t),o[n.attrName])||(n=js[e],null==n||n.attrName!==e&&n.keyName!==e||(o[n.attrName]=n.value(t)||void 0),n=As[e],null==n||n.attrName!==e&&n.keyName!==e||(n=As[e],o[n.attrName]=n.value(t)||void 0))})),Object.entries(o).reduce(((t,e)=>{let[n,s]=e;return qs(t,n,s,i)}),e)}],[Node.ELEMENT_NODE,function(t,e,i){const n={},s=t.style||{};return"italic"===s.fontStyle&&(n.italic=!0),"underline"===s.textDecoration&&(n.underline=!0),"line-through"===s.textDecoration&&(n.strike=!0),(s.fontWeight?.startsWith("bold")||parseInt(s.fontWeight,10)>=700)&&(n.bold=!0),e=Object.entries(n).reduce(((t,e)=>{let[n,s]=e;return qs(t,n,s,i)}),e),parseFloat(s.textIndent||0)>0?(new Ci).insert("\t").concat(e):e}],["li",function(t,e,i){const n=i.query(t);if(null==n||"list"!==n.blotName||!Os(e,"\n"))return e;let s=-1,r=t.parentNode;for(;null!=r;)["OL","UL"].includes(r.tagName)&&(s+=1),r=r.parentNode;return s<=0?e:e.reduce(((t,e)=>e.insert?e.attributes&&"number"==typeof e.attributes.indent?t.push(e):t.insert(e.insert,{indent:s,...e.attributes||{}}):t),new Ci)}],["ol, ul",function(t,e,i){let n="OL"===t.tagName?"ordered":"bullet";const s=t.getAttribute("data-checked");return s&&(n="true"===s?"checked":"unchecked"),qs(e,"list",n,i)}],["pre",function(t,e,i){const n=i.query("code-block");return qs(e,"code-block",!n||!("formats"in n)||"function"!=typeof n.formats||n.formats(t,i),i)}],["tr",function(t,e,i){const n="TABLE"===t.parentElement?.tagName?t.parentElement:t.parentElement?.parentElement;return null!=n?qs(e,"table",Array.from(n.querySelectorAll("tr")).indexOf(t)+1,i):e}],["b",Ls("bold")],["i",Ls("italic")],["strike",Ls("strike")],["style",function(){return new Ci}]],js=[Dn,Yn].reduce(((t,e)=>(t[e.keyName]=e,t)),{}),As=[Hn,Kn,Un,Jn,is,ss].reduce(((t,e)=>(t[e.keyName]=e,t)),{});function qs(t,e,i,n){return n.query(e)?t.reduce(((t,n)=>n.insert?n.attributes&&n.attributes[e]?t.push(n):t.insert(n.insert,{...i?{[e]:i}:{},...n.attributes}):t),new Ci):t}function Os(t,e){let i="";for(let n=t.ops.length-1;n>=0&&i.length<e.length;--n){const e=t.ops[n];if("string"!=typeof e.insert)break;i=e.insert+i}return i.slice(-1*e.length)===e}function Ms(t,e){if(!(t instanceof Element))return!1;const i=e.query(t);return!(i&&i.prototype instanceof ci)&&["address","article","blockquote","canvas","dd","div","dl","dt","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","iframe","li","main","nav","ol","output","p","pre","section","table","td","tr","ul","video"].includes(t.tagName.toLowerCase())}const Es=new WeakMap;function Ts(t){return null!=t&&(Es.has(t)||Es.set(t,"PRE"===t.tagName||Ts(t.parentNode)),Es.get(t))}function Ns(t,e,i,n,s){return e.nodeType===e.TEXT_NODE?n.reduce(((i,n)=>n(e,i,t)),new Ci):e.nodeType===e.ELEMENT_NODE?Array.from(e.childNodes||[]).reduce(((r,o)=>{let l=Ns(t,o,i,n,s);return o.nodeType===e.ELEMENT_NODE&&(l=i.reduce(((e,i)=>i(o,e,t)),l),l=(s.get(o)||[]).reduce(((e,i)=>i(o,e,t)),l)),r.concat(l)}),new Ci):new Ci}function Ls(t){return(e,i,n)=>qs(i,t,!0,n)}function $s(t,e,i){if(!Os(e,"\n")){if(Ms(t,i)&&(t.childNodes.length>0||t instanceof HTMLParagraphElement))return e.insert("\n");if(e.length()>0&&t.nextSibling){let n=t.nextSibling;for(;null!=n;){if(Ms(n,i))return e.insert("\n");const t=i.query(n);if(t&&t.prototype instanceof Pi)return e.insert("\n");n=n.firstChild}}}return e}function _s(t,e){let i=e;for(let e=t.length-1;e>=0;e-=1){const n=t[e];t[e]={delta:i.transform(n.delta,!0),range:n.range&&Ss(n.range,i)},i=n.delta.transform(i),0===t[e].delta.length()&&t.splice(e,1)}}function Ss(t,e){if(!t)return t;const i=e.transformPosition(t.index);return{index:i,length:e.transformPosition(t.index+t.length)-i}}class Cs extends vn{constructor(t,e){super(t,e),t.root.addEventListener("drop",(e=>{e.preventDefault();let i=null;if(document.caretRangeFromPoint)i=document.caretRangeFromPoint(e.clientX,e.clientY);else if(document.caretPositionFromPoint){const t=document.caretPositionFromPoint(e.clientX,e.clientY);i=document.createRange(),i.setStart(t.offsetNode,t.offset),i.setEnd(t.offsetNode,t.offset)}const n=i&&t.selection.normalizeNative(i);if(n){const i=t.selection.normalizedToRange(n);e.dataTransfer?.files&&this.upload(i,e.dataTransfer.files)}}))}upload(t,e){const i=[];Array.from(e).forEach((t=>{t&&this.options.mimetypes?.includes(t.type)&&i.push(t)})),i.length>0&&this.options.handler.call(this,t,i)}}Cs.DEFAULTS={mimetypes:["image/png","image/jpeg"],handler(t,e){if(!this.quill.scroll.query("image"))return;const i=e.map((t=>new Promise((e=>{const i=new FileReader;i.onload=()=>{e(i.result)},i.readAsDataURL(t)}))));Promise.all(i).then((e=>{const i=e.reduce(((t,e)=>t.insert({image:e})),(new Ci).retain(t.index).delete(t.length));this.quill.updateContents(i,nn.sources.USER),this.quill.setSelection(t.index+e.length,nn.sources.SILENT)}))}};const Bs=["insertText","insertReplacementText"],Rs=/Mac/i.test(navigator.platform);Mn.register({"blots/block":Hi,"blots/block/embed":Pi,"blots/break":Bi,"blots/container":Sn,"blots/cursor":Zi,"blots/embed":mn,"blots/inline":Vi,"blots/scroll":class extends ai{static blotName="scroll";static className="ql-editor";static tagName="DIV";static defaultChild=Hi;static allowedChildren=[Hi,Pi,Sn];constructor(t,e,i){let{emitter:n}=i;super(t,e),this.emitter=n,this.batch=!1,this.optimize(),this.enable(),this.domNode.addEventListener("dragstart",(t=>this.handleDragStart(t)))}batchStart(){Array.isArray(this.batch)||(this.batch=[])}batchEnd(){if(!this.batch)return;const t=this.batch;this.batch=!1,this.update(t)}emitMount(t){this.emitter.emit(nn.events.SCROLL_BLOT_MOUNT,t)}emitUnmount(t){this.emitter.emit(nn.events.SCROLL_BLOT_UNMOUNT,t)}emitEmbedUpdate(t,e){this.emitter.emit(nn.events.SCROLL_EMBED_UPDATE,t,e)}deleteAt(t,e){const[i,n]=this.line(t),[s]=this.line(t+e);if(super.deleteAt(t,e),null!=s&&i!==s&&n>0){if(i instanceof Pi||s instanceof Pi)return void this.optimize();i.moveChildren(s,s.children.head instanceof Bi?null:s.children.head),i.remove()}this.optimize()}enable(){this.domNode.setAttribute("contenteditable",arguments.length>0&&void 0!==arguments[0]&&!arguments[0]?"false":"true")}formatAt(t,e,i,n){super.formatAt(t,e,i,n),this.optimize()}insertAt(t,e,i){if(t>=this.length())if(null==i||null==this.scroll.query(e,Ie.BLOCK)){const t=this.scroll.create(this.statics.defaultChild.blotName);this.appendChild(t),null==i&&e.endsWith("\n")?t.insertAt(0,e.slice(0,-1),i):t.insertAt(0,e,i)}else{const t=this.scroll.create(e,i);this.appendChild(t)}else super.insertAt(t,e,i);this.optimize()}insertBefore(t,e){if(t.statics.scope===Ie.INLINE_BLOT){const i=this.scroll.create(this.statics.defaultChild.blotName);i.appendChild(t),super.insertBefore(i,e)}else super.insertBefore(t,e)}insertContents(t,e){const i=this.deltaToRenderBlocks(e.concat((new Ci).insert("\n"))),n=i.pop();if(null==n)return;this.batchStart();const s=i.shift();if(s){const e="block"===s.type&&(0===s.delta.length()||!this.descendant(Pi,t)[0]&&t<this.length()),i="block"===s.type?s.delta:(new Ci).insert({[s.key]:s.value});Rn(this,t,i);const n="block"===s.type?1:0,r=t+i.length()+n;e&&this.insertAt(r-1,"\n");const o=Ui(this.line(t)[0]),l=Si.AttributeMap.diff(o,s.attributes)||{};Object.keys(l).forEach((t=>{this.formatAt(r-1,1,t,l[t])})),t=r}let[r,o]=this.children.find(t);i.length&&(r&&(r=r.split(o),o=0),i.forEach((t=>{if("block"===t.type)Rn(this.createBlock(t.attributes,r||void 0),0,t.delta);else{const e=this.create(t.key,t.value);this.insertBefore(e,r||void 0),Object.keys(t.attributes).forEach((i=>{e.format(i,t.attributes[i])}))}}))),"block"===n.type&&n.delta.length()&&Rn(this,r?r.offset(r.scroll)+o:this.length(),n.delta),this.batchEnd(),this.optimize()}isEnabled(){return"true"===this.domNode.getAttribute("contenteditable")}leaf(t){const e=this.path(t).pop();if(!e)return[null,-1];const[i,n]=e;return i instanceof Ye?[i,n]:[null,-1]}line(t){return t===this.length()?this.line(t-1):this.descendant(Cn,t)}lines(){const t=(e,i,n)=>{let s=[],r=n;return e.children.forEachAt(i,n,((e,i,n)=>{Cn(e)?s.push(e):e instanceof li&&(s=s.concat(t(e,i,r))),r-=n})),s};return t(this,arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE)}optimize(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.batch||(super.optimize(t,e),t.length>0&&this.emitter.emit(nn.events.SCROLL_OPTIMIZE,t,e))}path(t){return super.path(t).slice(1)}remove(){}update(t){if(this.batch)return void(Array.isArray(t)&&(this.batch=this.batch.concat(t)));let e=nn.sources.USER;"string"==typeof t&&(e=t),Array.isArray(t)||(t=this.observer.takeRecords()),(t=t.filter((t=>{let{target:e}=t;const i=this.find(e,!0);return i&&!Bn(i)}))).length>0&&this.emitter.emit(nn.events.SCROLL_BEFORE_UPDATE,e,t),super.update(t.concat([])),t.length>0&&this.emitter.emit(nn.events.SCROLL_UPDATE,e,t)}updateEmbedAt(t,e,i){const[n]=this.descendant((t=>t instanceof Pi),t);n&&n.statics.blotName===e&&Bn(n)&&n.updateContent(i)}handleDragStart(t){t.preventDefault()}deltaToRenderBlocks(t){const e=[];let i=new Ci;return t.forEach((t=>{const n=t?.insert;if(n)if("string"==typeof n){const s=n.split("\n");s.slice(0,-1).forEach((n=>{i.insert(n,t.attributes),e.push({type:"block",delta:i,attributes:t.attributes??{}}),i=new Ci}));const r=s[s.length-1];r&&i.insert(r,t.attributes)}else{const s=Object.keys(n)[0];if(!s)return;this.query(s,Ie.INLINE)?i.push(t):(i.length()&&e.push({type:"block",delta:i,attributes:{}}),i=new Ci,e.push({type:"blockEmbed",key:s,value:n[s],attributes:t.attributes??{}}))}})),i.length()&&e.push({type:"block",delta:i,attributes:{}}),e}createBlock(t,e){let i;const n={};Object.entries(t).forEach((t=>{let[e,s]=t;null!=this.query(e,Ie.BLOCK&Ie.BLOT)?i=e:n[e]=s}));const s=this.create(i||this.statics.defaultChild.blotName,i?t[i]:void 0);this.insertBefore(s,e||void 0);const r=s.length();return Object.entries(n).forEach((t=>{let[e,i]=t;s.formatAt(0,r,e,i)})),s}},"blots/text":Ri,"modules/clipboard":class extends vn{static DEFAULTS={matchers:[]};constructor(t,e){super(t,e),this.quill.root.addEventListener("copy",(t=>this.onCaptureCopy(t,!1))),this.quill.root.addEventListener("cut",(t=>this.onCaptureCopy(t,!0))),this.quill.root.addEventListener("paste",this.onCapturePaste.bind(this)),this.matchers=[],ks.concat(this.options.matchers??[]).forEach((t=>{let[e,i]=t;this.addMatcher(e,i)}))}addMatcher(t,e){this.matchers.push([t,e])}convert(t){let{html:e,text:i}=t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(n[Wn.blotName])return(new Ci).insert(i||"",{[Wn.blotName]:n[Wn.blotName]});if(!e)return(new Ci).insert(i||"",n);const s=this.convertHTML(e);return Os(s,"\n")&&(null==s.ops[s.ops.length-1].attributes||n.table)?s.compose((new Ci).retain(s.length()-1).delete(1)):s}normalizeHTML(t){(t=>{t.documentElement&&gs.forEach((e=>{e(t)}))})(t)}convertHTML(t){const e=(new DOMParser).parseFromString(t,"text/html");this.normalizeHTML(e);const i=e.body,n=new WeakMap,[s,r]=this.prepareMatching(i,n);return Ns(this.quill.scroll,i,s,r,n)}dangerouslyPasteHTML(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Mn.sources.API;if("string"==typeof t){const i=this.convert({html:t,text:""});this.quill.setContents(i,e),this.quill.setSelection(0,Mn.sources.SILENT)}else{const n=this.convert({html:e,text:""});this.quill.updateContents((new Ci).retain(t).concat(n),i),this.quill.setSelection(t+n.length(),Mn.sources.SILENT)}}onCaptureCopy(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t.defaultPrevented)return;t.preventDefault();const[i]=this.quill.selection.getRange();if(null==i)return;const{html:n,text:s}=this.onCopy(i,e);t.clipboardData?.setData("text/plain",s),t.clipboardData?.setData("text/html",n),e&&ds({range:i,quill:this.quill})}normalizeURIList(t){return t.split(/\r?\n/).filter((t=>"#"!==t[0])).join("\n")}onCapturePaste(t){if(t.defaultPrevented||!this.quill.isEnabled())return;t.preventDefault();const e=this.quill.getSelection(!0);if(null==e)return;const i=t.clipboardData?.getData("text/html");let n=t.clipboardData?.getData("text/plain");if(!i&&!n){const e=t.clipboardData?.getData("text/uri-list");e&&(n=this.normalizeURIList(e))}const s=Array.from(t.clipboardData?.files||[]);if(!i&&s.length>0)this.quill.uploader.upload(e,s);else{if(i&&s.length>0){const t=(new DOMParser).parseFromString(i,"text/html");if(1===t.body.childElementCount&&"IMG"===t.body.firstElementChild?.tagName)return void this.quill.uploader.upload(e,s)}this.onPaste(e,{html:i,text:n})}}onCopy(t){const e=this.quill.getText(t);return{html:this.quill.getSemanticHTML(t),text:e}}onPaste(t,e){let{text:i,html:n}=e;const s=this.quill.getFormat(t.index),r=this.convert({text:i,html:n},s);xs.log("onPaste",r,{text:i,html:n});const o=(new Ci).retain(t.index).delete(t.length).concat(r);this.quill.updateContents(o,Mn.sources.USER),this.quill.setSelection(o.length()-t.length,Mn.sources.SILENT),this.quill.scrollSelectionIntoView()}prepareMatching(t,e){const i=[],n=[];return this.matchers.forEach((s=>{const[r,o]=s;switch(r){case Node.TEXT_NODE:n.push(o);break;case Node.ELEMENT_NODE:i.push(o);break;default:Array.from(t.querySelectorAll(r)).forEach((t=>{if(e.has(t)){const i=e.get(t);i?.push(o)}else e.set(t,[o])}))}})),[i,n]}},"modules/history":class extends vn{static DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};lastRecorded=0;ignoreChange=!1;stack={undo:[],redo:[]};currentRange=null;constructor(t,e){super(t,e),this.quill.on(Mn.events.EDITOR_CHANGE,((t,e,i,n)=>{t===Mn.events.SELECTION_CHANGE?e&&n!==Mn.sources.SILENT&&(this.currentRange=e):t===Mn.events.TEXT_CHANGE&&(this.ignoreChange||(this.options.userOnly&&n!==Mn.sources.USER?this.transform(e):this.record(e,i)),this.currentRange=Ss(this.currentRange,e))})),this.quill.keyboard.addBinding({key:"z",shortKey:!0},this.undo.bind(this)),this.quill.keyboard.addBinding({key:["z","Z"],shortKey:!0,shiftKey:!0},this.redo.bind(this)),/Win/i.test(navigator.platform)&&this.quill.keyboard.addBinding({key:"y",shortKey:!0},this.redo.bind(this)),this.quill.root.addEventListener("beforeinput",(t=>{"historyUndo"===t.inputType?(this.undo(),t.preventDefault()):"historyRedo"===t.inputType&&(this.redo(),t.preventDefault())}))}change(t,e){if(0===this.stack[t].length)return;const i=this.stack[t].pop();if(!i)return;const n=this.quill.getContents(),s=i.delta.invert(n);this.stack[e].push({delta:s,range:Ss(i.range,s)}),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(i.delta,Mn.sources.USER),this.ignoreChange=!1,this.restoreSelection(i)}clear(){this.stack={undo:[],redo:[]}}cutoff(){this.lastRecorded=0}record(t,e){if(0===t.ops.length)return;this.stack.redo=[];let i=t.invert(e),n=this.currentRange;const s=Date.now();if(this.lastRecorded+this.options.delay>s&&this.stack.undo.length>0){const t=this.stack.undo.pop();t&&(i=i.compose(t.delta),n=t.range)}else this.lastRecorded=s;0!==i.length()&&(this.stack.undo.push({delta:i,range:n}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift())}redo(){this.change("redo","undo")}transform(t){_s(this.stack.undo,t),_s(this.stack.redo,t)}undo(){this.change("undo","redo")}restoreSelection(t){if(t.range)this.quill.setSelection(t.range,Mn.sources.USER);else{const e=function(t,e){const i=e.reduce(((t,e)=>t+(e.delete||0)),0);let n=e.length()-i;return function(t,e){const i=e.ops[e.ops.length-1];return null!=i&&(null!=i.insert?"string"==typeof i.insert&&i.insert.endsWith("\n"):null!=i.attributes&&Object.keys(i.attributes).some((e=>null!=t.query(e,Ie.BLOCK))))}(t,e)&&(n-=1),n}(this.quill.scroll,t.delta);this.quill.setSelection(e,Mn.sources.USER)}}},"modules/keyboard":ls,"modules/uploader":Cs,"modules/input":class extends vn{constructor(t,e){super(t,e),t.root.addEventListener("beforeinput",(t=>{this.handleBeforeInput(t)})),/Android/i.test(navigator.userAgent)||t.on(Mn.events.COMPOSITION_BEFORE_START,(()=>{this.handleCompositionStart()}))}deleteRange(t){ds({range:t,quill:this.quill})}replaceText(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(0===t.length)return!1;if(e){const i=this.quill.getFormat(t.index,1);this.deleteRange(t),this.quill.updateContents((new Ci).retain(t.index).insert(e,i),Mn.sources.USER)}else this.deleteRange(t);return this.quill.setSelection(t.index+e.length,0,Mn.sources.SILENT),!0}handleBeforeInput(t){if(this.quill.composition.isComposing||t.defaultPrevented||!Bs.includes(t.inputType))return;const e=t.getTargetRanges?t.getTargetRanges()[0]:null;if(!e||!0===e.collapsed)return;const i=function(t){return"string"==typeof t.data?t.data:t.dataTransfer?.types.includes("text/plain")?t.dataTransfer.getData("text/plain"):null}(t);if(null==i)return;const n=this.quill.selection.normalizeNative(e),s=n?this.quill.selection.normalizedToRange(n):null;s&&this.replaceText(s,i)&&t.preventDefault()}handleCompositionStart(){const t=this.quill.getSelection();t&&this.replaceText(t)}},"modules/uiNode":class extends vn{isListening=!1;selectionChangeDeadline=0;constructor(t,e){super(t,e),this.handleArrowKeys(),this.handleNavigationShortcuts()}handleArrowKeys(){this.quill.keyboard.addBinding({key:["ArrowLeft","ArrowRight"],offset:0,shiftKey:null,handler(t,e){let{line:i,event:n}=e;if(!(i instanceof ei&&i.uiNode))return!0;const s="rtl"===getComputedStyle(i.domNode).direction;return!!(s&&"ArrowRight"!==n.key||!s&&"ArrowLeft"!==n.key)||(this.quill.setSelection(t.index-1,t.length+(n.shiftKey?1:0),Mn.sources.USER),!1)}})}handleNavigationShortcuts(){this.quill.root.addEventListener("keydown",(t=>{!t.defaultPrevented&&(t=>"ArrowLeft"===t.key||"ArrowRight"===t.key||"ArrowUp"===t.key||"ArrowDown"===t.key||"Home"===t.key||!(!Rs||"a"!==t.key||!0!==t.ctrlKey))(t)&&this.ensureListeningToSelectionChange()}))}ensureListeningToSelectionChange(){this.selectionChangeDeadline=Date.now()+100,this.isListening||(this.isListening=!0,document.addEventListener("selectionchange",(()=>{this.isListening=!1,Date.now()<=this.selectionChangeDeadline&&this.handleSelectionChange()}),{once:!0}))}handleSelectionChange(){const t=document.getSelection();if(!t)return;const e=t.getRangeAt(0);if(!0!==e.collapsed||0!==e.startOffset)return;const i=this.quill.scroll.find(e.startContainer);if(!(i instanceof ei&&i.uiNode))return;const n=document.createRange();n.setStartAfter(i.uiNode),n.setEndAfter(i.uiNode),t.removeAllRanges(),t.addRange(n)}}});const Is=new class extends Ue{add(t,e){let i=0;if("+1"===e||"-1"===e){const n=this.value(t)||0;i="+1"===e?n+1:n-1}else"number"==typeof e&&(i=e);return 0===i?(this.remove(t),!0):super.add(t,i.toString())}canAdd(t,e){return super.canAdd(t,e)||super.canAdd(t,parseInt(e,10))}value(t){return parseInt(super.value(t),10)||void 0}}("indent","ql-indent",{scope:Ie.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});class Ds extends Sn{}Ds.blotName="list-container",Ds.tagName="OL";class Vs extends Hi{static create(t){const e=super.create();return e.setAttribute("data-list",t),e}static formats(t){return t.getAttribute("data-list")||void 0}static register(){Mn.register(Ds)}constructor(t,e){super(t,e);const i=e.ownerDocument.createElement("span"),n=i=>{if(!t.isEnabled())return;const n=this.statics.formats(e,t);"checked"===n?(this.format("list","unchecked"),i.preventDefault()):"unchecked"===n&&(this.format("list","checked"),i.preventDefault())};i.addEventListener("mousedown",n),i.addEventListener("touchstart",n),this.attachUI(i)}format(t,e){t===this.statics.blotName&&e?this.domNode.setAttribute("data-list",e):super.format(t,e)}}Vs.blotName="list",Vs.tagName="LI",Ds.allowedChildren=[Vs],Vs.requiredContainer=Ds;class Hs extends Vi{static blotName="bold";static tagName=["STRONG","B"];static create(){return super.create()}static formats(){return!0}optimize(t){super.optimize(t),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}class Ps extends Vi{static blotName="link";static tagName="A";static SANITIZED_URL="about:blank";static PROTOCOL_WHITELIST=["http","https","mailto","tel","sms"];static create(t){const e=super.create(t);return e.setAttribute("href",this.sanitize(t)),e.setAttribute("rel","noopener noreferrer"),e.setAttribute("target","_blank"),e}static formats(t){return t.getAttribute("href")}static sanitize(t){return Fs(t,this.PROTOCOL_WHITELIST)?t:this.SANITIZED_URL}format(t,e){t===this.statics.blotName&&e?this.domNode.setAttribute("href",this.constructor.sanitize(e)):super.format(t,e)}}function Fs(t,e){const i=document.createElement("a");i.href=t;const n=i.href.slice(0,i.href.indexOf(":"));return e.indexOf(n)>-1}const Us=["alt","height","width"],Zs=["height","width"],Ks=new Ue("code-token","hljs",{scope:Ie.INLINE});class zs extends Vi{static formats(t,e){for(;null!=t&&t!==e.domNode;){if(t.classList&&t.classList.contains(Wn.className))return super.formats(t,e);t=t.parentNode}}constructor(t,e,i){super(t,e,i),Ks.add(this.domNode,i)}format(t,e){t!==zs.blotName?super.format(t,e):e?Ks.add(this.domNode,e):(Ks.remove(this.domNode),this.domNode.classList.remove(this.statics.className))}optimize(){super.optimize(...arguments),Ks.value(this.domNode)||this.unwrap()}}zs.blotName="code-token",zs.className="ql-token";class Ws extends Wn{static create(t){const e=super.create(t);return"string"==typeof t&&e.setAttribute("data-language",t),e}static formats(t){return t.getAttribute("data-language")||"plain"}static register(){}format(t,e){t===this.statics.blotName&&e?this.domNode.setAttribute("data-language",e):super.format(t,e)}replaceWith(t,e){return this.formatAt(0,this.length(),zs.blotName,!1),super.replaceWith(t,e)}}class Gs extends zn{attach(){super.attach(),this.forceNext=!1,this.scroll.emitMount(this)}format(t,e){t===Ws.blotName&&(this.forceNext=!0,this.children.forEach((i=>{i.format(t,e)})))}formatAt(t,e,i,n){i===Ws.blotName&&(this.forceNext=!0),super.formatAt(t,e,i,n)}highlight(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(null==this.children.head)return;const i=`${Array.from(this.domNode.childNodes).filter((t=>t!==this.uiNode)).map((t=>t.textContent)).join("\n")}\n`,n=Ws.formats(this.children.head.domNode);if(e||this.forceNext||this.cachedText!==i){if(i.trim().length>0||null==this.cachedText){const e=this.children.reduce(((t,e)=>t.concat(Fi(e,!1))),new Ci),s=t(i,n);e.diff(s).reduce(((t,e)=>{let{retain:i,attributes:n}=e;return i?(n&&Object.keys(n).forEach((e=>{[Ws.blotName,zs.blotName].includes(e)&&this.formatAt(t,i,e,n[e])})),t+i):t}),0)}this.cachedText=i,this.forceNext=!1}}html(t,e){const[i]=this.children.find(t);return`<pre data-language="${i?Ws.formats(i.domNode):"plain"}">\n${Di(this.code(t,e))}\n</pre>`}optimize(t){if(super.optimize(t),null!=this.parent&&null!=this.children.head&&null!=this.uiNode){const t=Ws.formats(this.children.head.domNode);t!==this.uiNode.value&&(this.uiNode.value=t)}}}Gs.allowedChildren=[Ws],Ws.requiredContainer=Gs,Ws.allowedChildren=[zs,Zi,Ri,Bi];class Qs extends vn{static register(){Mn.register(zs,!0),Mn.register(Ws,!0),Mn.register(Gs,!0)}constructor(t,e){if(super(t,e),null==this.options.hljs)throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");this.languages=this.options.languages.reduce(((t,e)=>{let{key:i}=e;return t[i]=!0,t}),{}),this.highlightBlot=this.highlightBlot.bind(this),this.initListener(),this.initTimer()}initListener(){this.quill.on(Mn.events.SCROLL_BLOT_MOUNT,(t=>{if(!(t instanceof Gs))return;const e=this.quill.root.ownerDocument.createElement("select");this.options.languages.forEach((t=>{let{key:i,label:n}=t;const s=e.ownerDocument.createElement("option");s.textContent=n,s.setAttribute("value",i),e.appendChild(s)})),e.addEventListener("change",(()=>{t.format(Ws.blotName,e.value),this.quill.root.focus(),this.highlight(t,!0)})),null==t.uiNode&&(t.attachUI(e),t.children.head&&(e.value=Ws.formats(t.children.head.domNode)))}))}initTimer(){let t=null;this.quill.on(Mn.events.SCROLL_OPTIMIZE,(()=>{t&&clearTimeout(t),t=setTimeout((()=>{this.highlight(),t=null}),this.options.interval)}))}highlight(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(this.quill.selection.composing)return;this.quill.update(Mn.sources.USER);const i=this.quill.getSelection();(null==t?this.quill.scroll.descendants(Gs):[t]).forEach((t=>{t.highlight(this.highlightBlot,e)})),this.quill.update(Mn.sources.SILENT),null!=i&&this.quill.setSelection(i,Mn.sources.SILENT)}highlightBlot(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"plain";if(e=this.languages[e]?e:"plain","plain"===e)return Di(t).split("\n").reduce(((t,i,n)=>(0!==n&&t.insert("\n",{[Wn.blotName]:e}),t.insert(i))),new Ci);const i=this.quill.root.ownerDocument.createElement("div");return i.classList.add(Wn.className),i.innerHTML=((t,e,i)=>{if("string"==typeof t.versionString){const n=t.versionString.split(".")[0];if(parseInt(n,10)>=11)return t.highlight(i,{language:e}).value}return t.highlight(e,i).value})(this.options.hljs,e,t),Ns(this.quill.scroll,i,[(t,e)=>{const i=Ks.value(t);return i?e.compose((new Ci).retain(e.length(),{[zs.blotName]:i})):e}],[(t,i)=>t.data.split("\n").reduce(((t,i,n)=>(0!==n&&t.insert("\n",{[Wn.blotName]:e}),t.insert(i))),i)],new WeakMap)}}Qs.DEFAULTS={hljs:window.hljs,interval:1e3,languages:[{key:"plain",label:"Plain"},{key:"bash",label:"Bash"},{key:"cpp",label:"C++"},{key:"cs",label:"C#"},{key:"css",label:"CSS"},{key:"diff",label:"Diff"},{key:"xml",label:"HTML/XML"},{key:"java",label:"Java"},{key:"javascript",label:"JavaScript"},{key:"markdown",label:"Markdown"},{key:"php",label:"PHP"},{key:"python",label:"Python"},{key:"ruby",label:"Ruby"},{key:"sql",label:"SQL"}]};class Ys extends Hi{static blotName="table";static tagName="TD";static create(t){const e=super.create();return e.setAttribute("data-row",t||er()),e}static formats(t){if(t.hasAttribute("data-row"))return t.getAttribute("data-row")}cellOffset(){return this.parent?this.parent.children.indexOf(this):-1}format(t,e){t===Ys.blotName&&e?this.domNode.setAttribute("data-row",e):super.format(t,e)}row(){return this.parent}rowOffset(){return this.row()?this.row().rowOffset():-1}table(){return this.row()&&this.row().table()}}class Xs extends Sn{static blotName="table-row";static tagName="TR";checkMerge(){if(super.checkMerge()&&null!=this.next.children.head){const t=this.children.head.formats(),e=this.children.tail.formats(),i=this.next.children.head.formats(),n=this.next.children.tail.formats();return t.table===e.table&&t.table===i.table&&t.table===n.table}return!1}optimize(t){super.optimize(t),this.children.forEach((t=>{if(null==t.next)return;const e=t.formats(),i=t.next.formats();if(e.table!==i.table){const e=this.splitAfter(t);e&&e.optimize(),this.prev&&this.prev.optimize()}}))}rowOffset(){return this.parent?this.parent.children.indexOf(this):-1}table(){return this.parent&&this.parent.parent}}class Js extends Sn{static blotName="table-body";static tagName="TBODY"}class tr extends Sn{static blotName="table-container";static tagName="TABLE";balanceCells(){const t=this.descendants(Xs),e=t.reduce(((t,e)=>Math.max(e.children.length,t)),0);t.forEach((t=>{new Array(e-t.children.length).fill(0).forEach((()=>{let e;null!=t.children.head&&(e=Ys.formats(t.children.head.domNode));const i=this.scroll.create(Ys.blotName,e);t.appendChild(i),i.optimize()}))}))}cells(t){return this.rows().map((e=>e.children.at(t)))}deleteColumn(t){const[e]=this.descendant(Js);null!=e&&null!=e.children.head&&e.children.forEach((e=>{const i=e.children.at(t);null!=i&&i.remove()}))}insertColumn(t){const[e]=this.descendant(Js);null!=e&&null!=e.children.head&&e.children.forEach((e=>{const i=e.children.at(t),n=Ys.formats(e.children.head.domNode),s=this.scroll.create(Ys.blotName,n);e.insertBefore(s,i)}))}insertRow(t){const[e]=this.descendant(Js);if(null==e||null==e.children.head)return;const i=er(),n=this.scroll.create(Xs.blotName);e.children.head.children.forEach((()=>{const t=this.scroll.create(Ys.blotName,i);n.appendChild(t)}));const s=e.children.at(t);e.insertBefore(n,s)}rows(){const t=this.children.head;return null==t?[]:t.children.map((t=>t))}}function er(){return`row-${Math.random().toString(36).slice(2,6)}`}tr.allowedChildren=[Js],Js.requiredContainer=tr,Js.allowedChildren=[Xs],Xs.requiredContainer=Js,Xs.allowedChildren=[Ys],Ys.requiredContainer=Xs;const ir=tn("quill:toolbar");class nr extends vn{constructor(t,e){if(super(t,e),Array.isArray(this.options.container)){const e=document.createElement("div");e.setAttribute("role","toolbar"),function(t,e){Array.isArray(e[0])||(e=[e]),e.forEach((e=>{const i=document.createElement("span");i.classList.add("ql-formats"),e.forEach((t=>{if("string"==typeof t)sr(i,t);else{const e=Object.keys(t)[0],n=t[e];Array.isArray(n)?function(t,e,i){const n=document.createElement("select");n.classList.add(`ql-${e}`),i.forEach((t=>{const e=document.createElement("option");!1!==t?e.setAttribute("value",String(t)):e.setAttribute("selected","selected"),n.appendChild(e)})),t.appendChild(n)}(i,e,n):sr(i,e,n)}})),t.appendChild(i)}))}(e,this.options.container),t.container?.parentNode?.insertBefore(e,t.container),this.container=e}else this.container="string"==typeof this.options.container?document.querySelector(this.options.container):this.options.container;this.container instanceof HTMLElement?(this.container.classList.add("ql-toolbar"),this.controls=[],this.handlers={},this.options.handlers&&Object.keys(this.options.handlers).forEach((t=>{const e=this.options.handlers?.[t];e&&this.addHandler(t,e)})),Array.from(this.container.querySelectorAll("button, select")).forEach((t=>{this.attach(t)})),this.quill.on(Mn.events.EDITOR_CHANGE,(()=>{const[t]=this.quill.selection.getRange();this.update(t)}))):ir.error("Container required for toolbar",this.options)}addHandler(t,e){this.handlers[t]=e}attach(t){let e=Array.from(t.classList).find((t=>0===t.indexOf("ql-")));e&&(e=e.slice(3),"BUTTON"===t.tagName&&t.setAttribute("type","button"),null!=this.handlers[e]||null!=this.quill.scroll.query(e)?(t.addEventListener("SELECT"===t.tagName?"change":"click",(i=>{let n;if("SELECT"===t.tagName){if(t.selectedIndex<0)return;const e=t.options[t.selectedIndex];n=!e.hasAttribute("selected")&&(e.value||!1)}else n=!t.classList.contains("ql-active")&&(t.value||!t.hasAttribute("value")),i.preventDefault();this.quill.focus();const[s]=this.quill.selection.getRange();if(null!=this.handlers[e])this.handlers[e].call(this,n);else if(this.quill.scroll.query(e).prototype instanceof ci){if(n=prompt(`Enter ${e}`),!n)return;this.quill.updateContents((new Ci).retain(s.index).delete(s.length).insert({[e]:n}),Mn.sources.USER)}else this.quill.format(e,n,Mn.sources.USER);this.update(s)})),this.controls.push([e,t])):ir.warn("ignoring attaching to nonexistent format",e,t))}update(t){const e=null==t?{}:this.quill.getFormat(t);this.controls.forEach((i=>{const[n,s]=i;if("SELECT"===s.tagName){let i=null;if(null==t)i=null;else if(null==e[n])i=s.querySelector("option[selected]");else if(!Array.isArray(e[n])){let t=e[n];"string"==typeof t&&(t=t.replace(/"/g,'\\"')),i=s.querySelector(`option[value="${t}"]`)}null==i?(s.value="",s.selectedIndex=-1):i.selected=!0}else if(null==t)s.classList.remove("ql-active"),s.setAttribute("aria-pressed","false");else if(s.hasAttribute("value")){const t=e[n],i=t===s.getAttribute("value")||null!=t&&t.toString()===s.getAttribute("value")||null==t&&!s.getAttribute("value");s.classList.toggle("ql-active",i),s.setAttribute("aria-pressed",i.toString())}else{const t=null!=e[n];s.classList.toggle("ql-active",t),s.setAttribute("aria-pressed",t.toString())}}))}}function sr(t,e,i){const n=document.createElement("button");n.setAttribute("type","button"),n.classList.add(`ql-${e}`),n.setAttribute("aria-pressed","false"),null!=i?(n.value=i,n.setAttribute("aria-label",`${e}: ${i}`)):n.setAttribute("aria-label",e),t.appendChild(n)}nr.DEFAULTS={},nr.DEFAULTS={container:null,handlers:{clean(){const t=this.quill.getSelection();if(null!=t)if(0===t.length){const t=this.quill.getFormat();Object.keys(t).forEach((t=>{null!=this.quill.scroll.query(t,Ie.INLINE)&&this.quill.format(t,!1,Mn.sources.USER)}))}else this.quill.removeFormat(t.index,t.length,Mn.sources.USER)},direction(t){const{align:e}=this.quill.getFormat();"rtl"===t&&null==e?this.quill.format("align","right",Mn.sources.USER):t||"right"!==e||this.quill.format("align",!1,Mn.sources.USER),this.quill.format("direction",t,Mn.sources.USER)},indent(t){const e=this.quill.getSelection(),i=this.quill.getFormat(e),n=parseInt(i.indent||0,10);if("+1"===t||"-1"===t){let e="+1"===t?1:-1;"rtl"===i.direction&&(e*=-1),this.quill.format("indent",n+e,Mn.sources.USER)}},link(t){!0===t&&(t=prompt("Enter link URL:")),this.quill.format("link",t,Mn.sources.USER)},list(t){const e=this.quill.getSelection(),i=this.quill.getFormat(e);this.quill.format("list","check"===t?"checked"!==i.list&&"unchecked"!==i.list&&"unchecked":t,Mn.sources.USER)}}};const rr='<svg viewbox="0 0 18 18"><polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"/><polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"/><line class="ql-stroke" x1="10" x2="8" y1="5" y2="13"/></svg>';var or={align:{"":'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="3" x2="15" y1="9" y2="9"/><line class="ql-stroke" x1="3" x2="13" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="9" y1="4" y2="4"/></svg>',center:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="15" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="14" x2="4" y1="14" y2="14"/><line class="ql-stroke" x1="12" x2="6" y1="4" y2="4"/></svg>',right:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="15" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="15" x2="5" y1="14" y2="14"/><line class="ql-stroke" x1="15" x2="9" y1="4" y2="4"/></svg>',justify:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="15" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="15" x2="3" y1="14" y2="14"/><line class="ql-stroke" x1="15" x2="3" y1="4" y2="4"/></svg>'},background:'<svg viewbox="0 0 18 18"><g class="ql-fill ql-color-label"><polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"/><rect height="1" width="1" x="4" y="4"/><polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"/><rect height="1" width="1" x="2" y="6"/><rect height="1" width="1" x="3" y="5"/><rect height="1" width="1" x="4" y="7"/><polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"/><rect height="1" width="1" x="2" y="12"/><rect height="1" width="1" x="2" y="9"/><rect height="1" width="1" x="2" y="15"/><polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"/><rect height="1" width="1" x="3" y="8"/><path d="M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z"/><path d="M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z"/><path d="M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z"/><rect height="1" width="1" x="12" y="2"/><rect height="1" width="1" x="11" y="3"/><path d="M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z"/><rect height="1" width="1" x="2" y="3"/><rect height="1" width="1" x="6" y="2"/><rect height="1" width="1" x="3" y="2"/><rect height="1" width="1" x="5" y="3"/><rect height="1" width="1" x="9" y="2"/><rect height="1" width="1" x="15" y="14"/><polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"/><rect height="1" width="1" x="13" y="7"/><rect height="1" width="1" x="15" y="5"/><rect height="1" width="1" x="14" y="6"/><rect height="1" width="1" x="15" y="8"/><rect height="1" width="1" x="14" y="9"/><path d="M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z"/><rect height="1" width="1" x="14" y="3"/><polygon points="12 6.868 12 6 11.62 6 12 6.868"/><rect height="1" width="1" x="15" y="2"/><rect height="1" width="1" x="12" y="5"/><rect height="1" width="1" x="13" y="4"/><polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"/><rect height="1" width="1" x="9" y="14"/><rect height="1" width="1" x="8" y="15"/><path d="M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z"/><rect height="1" width="1" x="5" y="15"/><path d="M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z"/><rect height="1" width="1" x="11" y="15"/><path d="M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z"/><rect height="1" width="1" x="14" y="15"/><rect height="1" width="1" x="15" y="11"/></g><polyline class="ql-stroke" points="5.5 13 9 5 12.5 13"/><line class="ql-stroke" x1="11.63" x2="6.38" y1="11" y2="11"/></svg>',blockquote:'<svg viewbox="0 0 18 18"><rect class="ql-fill ql-stroke" height="3" width="3" x="4" y="5"/><rect class="ql-fill ql-stroke" height="3" width="3" x="11" y="5"/><path class="ql-even ql-fill ql-stroke" d="M7,8c0,4.031-3,5-3,5"/><path class="ql-even ql-fill ql-stroke" d="M14,8c0,4.031-3,5-3,5"/></svg>',bold:'<svg viewbox="0 0 18 18"><path class="ql-stroke" d="M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z"/><path class="ql-stroke" d="M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z"/></svg>',clean:'<svg class="" viewbox="0 0 18 18"><line class="ql-stroke" x1="5" x2="13" y1="3" y2="3"/><line class="ql-stroke" x1="6" x2="9.35" y1="12" y2="3"/><line class="ql-stroke" x1="11" x2="15" y1="11" y2="15"/><line class="ql-stroke" x1="15" x2="11" y1="11" y2="15"/><rect class="ql-fill" height="1" rx="0.5" ry="0.5" width="7" x="2" y="14"/></svg>',code:rr,"code-block":rr,color:'<svg viewbox="0 0 18 18"><line class="ql-color-label ql-stroke ql-transparent" x1="3" x2="15" y1="15" y2="15"/><polyline class="ql-stroke" points="5.5 11 9 3 12.5 11"/><line class="ql-stroke" x1="11.63" x2="6.38" y1="9" y2="9"/></svg>',direction:{"":'<svg viewbox="0 0 18 18"><polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"/><line class="ql-stroke ql-fill" x1="15" x2="11" y1="4" y2="4"/><path class="ql-fill" d="M11,3a3,3,0,0,0,0,6h1V3H11Z"/><rect class="ql-fill" height="11" width="1" x="11" y="4"/><rect class="ql-fill" height="11" width="1" x="13" y="4"/></svg>',rtl:'<svg viewbox="0 0 18 18"><polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"/><line class="ql-stroke ql-fill" x1="9" x2="5" y1="4" y2="4"/><path class="ql-fill" d="M5,3A3,3,0,0,0,5,9H6V3H5Z"/><rect class="ql-fill" height="11" width="1" x="5" y="4"/><rect class="ql-fill" height="11" width="1" x="7" y="4"/></svg>'},formula:'<svg viewbox="0 0 18 18"><path class="ql-fill" d="M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z"/><rect class="ql-fill" height="1.6" rx="0.8" ry="0.8" width="5" x="5.15" y="6.2"/><path class="ql-fill" d="M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z"/></svg>',header:{1:'<svg viewBox="0 0 18 18"><path class="ql-fill" d="M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z"/></svg>',2:'<svg viewBox="0 0 18 18"><path class="ql-fill" d="M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z"/></svg>',3:'<svg viewBox="0 0 18 18"><path class="ql-fill" d="M16.65186,12.30664a2.6742,2.6742,0,0,1-2.915,2.68457,3.96592,3.96592,0,0,1-2.25537-.6709.56007.56007,0,0,1-.13232-.83594L11.64648,13c.209-.34082.48389-.36328.82471-.1543a2.32654,2.32654,0,0,0,1.12256.33008c.71484,0,1.12207-.35156,1.12207-.78125,0-.61523-.61621-.86816-1.46338-.86816H13.2085a.65159.65159,0,0,1-.68213-.41895l-.05518-.10937a.67114.67114,0,0,1,.14307-.78125l.71533-.86914a8.55289,8.55289,0,0,1,.68213-.7373V8.58887a3.93913,3.93913,0,0,1-.748.05469H11.9873a.54085.54085,0,0,1-.605-.60547V7.59863a.54085.54085,0,0,1,.605-.60547h3.75146a.53773.53773,0,0,1,.60547.59375v.17676a1.03723,1.03723,0,0,1-.27539.748L14.74854,10.0293A2.31132,2.31132,0,0,1,16.65186,12.30664ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z"/></svg>',4:'<svg viewBox="0 0 18 18"><path class="ql-fill" d="M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm7.05371,7.96582v.38477c0,.39648-.165.60547-.46191.60547h-.47314v1.29785a.54085.54085,0,0,1-.605.60547h-.69336a.54085.54085,0,0,1-.605-.60547V12.95605H11.333a.5412.5412,0,0,1-.60547-.60547v-.15332a1.199,1.199,0,0,1,.22021-.748l2.56348-4.05957a.7819.7819,0,0,1,.72607-.39648h1.27637a.54085.54085,0,0,1,.605.60547v3.7627h.33008A.54055.54055,0,0,1,17.05371,11.96582ZM14.28125,8.7207h-.022a4.18969,4.18969,0,0,1-.38525.81348l-1.188,1.80469v.02246h1.5293V9.60059A7.04058,7.04058,0,0,1,14.28125,8.7207Z"/></svg>',5:'<svg viewBox="0 0 18 18"><path class="ql-fill" d="M16.74023,12.18555a2.75131,2.75131,0,0,1-2.91553,2.80566,3.908,3.908,0,0,1-2.25537-.68164.54809.54809,0,0,1-.13184-.8252L11.73438,13c.209-.34082.48389-.36328.8252-.1543a2.23757,2.23757,0,0,0,1.1001.33008,1.01827,1.01827,0,0,0,1.1001-.96777c0-.61621-.53906-.97949-1.25439-.97949a2.15554,2.15554,0,0,0-.64893.09961,1.15209,1.15209,0,0,1-.814.01074l-.12109-.04395a.64116.64116,0,0,1-.45117-.71484l.231-3.00391a.56666.56666,0,0,1,.62744-.583H15.541a.54085.54085,0,0,1,.605.60547v.43945a.54085.54085,0,0,1-.605.60547H13.41748l-.04395.72559a1.29306,1.29306,0,0,1-.04395.30859h.022a2.39776,2.39776,0,0,1,.57227-.07715A2.53266,2.53266,0,0,1,16.74023,12.18555ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z"/></svg>',6:'<svg viewBox="0 0 18 18"><path class="ql-fill" d="M14.51758,9.64453a1.85627,1.85627,0,0,0-1.24316.38477H13.252a1.73532,1.73532,0,0,1,1.72754-1.4082,2.66491,2.66491,0,0,1,.5498.06641c.35254.05469.57227.01074.70508-.40723l.16406-.5166a.53393.53393,0,0,0-.373-.75977,4.83723,4.83723,0,0,0-1.17773-.14258c-2.43164,0-3.7627,2.17773-3.7627,4.43359,0,2.47559,1.60645,3.69629,3.19043,3.69629A2.70585,2.70585,0,0,0,16.96,12.19727,2.43861,2.43861,0,0,0,14.51758,9.64453Zm-.23047,3.58691c-.67187,0-1.22168-.81445-1.22168-1.45215,0-.47363.30762-.583.72559-.583.96875,0,1.27734.59375,1.27734,1.12207A.82182.82182,0,0,1,14.28711,13.23145ZM10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Z"/></svg>'},italic:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="7" x2="13" y1="4" y2="4"/><line class="ql-stroke" x1="5" x2="11" y1="14" y2="14"/><line class="ql-stroke" x1="8" x2="10" y1="14" y2="4"/></svg>',image:'<svg viewbox="0 0 18 18"><rect class="ql-stroke" height="10" width="12" x="3" y="4"/><circle class="ql-fill" cx="6" cy="7" r="1"/><polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"/></svg>',indent:{"+1":'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="3" x2="15" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="9" x2="15" y1="9" y2="9"/><polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"/></svg>',"-1":'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="3" x2="15" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="9" x2="15" y1="9" y2="9"/><polyline class="ql-stroke" points="5 7 5 11 3 9 5 7"/></svg>'},link:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="7" x2="11" y1="7" y2="11"/><path class="ql-even ql-stroke" d="M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z"/><path class="ql-even ql-stroke" d="M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z"/></svg>',list:{bullet:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="6" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="6" x2="15" y1="9" y2="9"/><line class="ql-stroke" x1="6" x2="15" y1="14" y2="14"/><line class="ql-stroke" x1="3" x2="3" y1="4" y2="4"/><line class="ql-stroke" x1="3" x2="3" y1="9" y2="9"/><line class="ql-stroke" x1="3" x2="3" y1="14" y2="14"/></svg>',check:'<svg class="" viewbox="0 0 18 18"><line class="ql-stroke" x1="9" x2="15" y1="4" y2="4"/><polyline class="ql-stroke" points="3 4 4 5 6 3"/><line class="ql-stroke" x1="9" x2="15" y1="14" y2="14"/><polyline class="ql-stroke" points="3 14 4 15 6 13"/><line class="ql-stroke" x1="9" x2="15" y1="9" y2="9"/><polyline class="ql-stroke" points="3 9 4 10 6 8"/></svg>',ordered:'<svg viewbox="0 0 18 18"><line class="ql-stroke" x1="7" x2="15" y1="4" y2="4"/><line class="ql-stroke" x1="7" x2="15" y1="9" y2="9"/><line class="ql-stroke" x1="7" x2="15" y1="14" y2="14"/><line class="ql-stroke ql-thin" x1="2.5" x2="4.5" y1="5.5" y2="5.5"/><path class="ql-fill" d="M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z"/><path class="ql-stroke ql-thin" d="M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156"/><path class="ql-stroke ql-thin" d="M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109"/></svg>'},script:{sub:'<svg viewbox="0 0 18 18"><path class="ql-fill" d="M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z"/><path class="ql-fill" d="M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z"/></svg>',super:'<svg viewbox="0 0 18 18"><path class="ql-fill" d="M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z"/><path class="ql-fill" d="M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z"/></svg>'},strike:'<svg viewbox="0 0 18 18"><line class="ql-stroke ql-thin" x1="15.5" x2="2.5" y1="8.5" y2="9.5"/><path class="ql-fill" d="M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z"/><path class="ql-fill" d="M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z"/></svg>',table:'<svg viewbox="0 0 18 18"><rect class="ql-stroke" height="12" width="12" x="3" y="3"/><rect class="ql-fill" height="2" width="3" x="5" y="5"/><rect class="ql-fill" height="2" width="4" x="9" y="5"/><g class="ql-fill ql-transparent"><rect height="2" width="3" x="5" y="8"/><rect height="2" width="4" x="9" y="8"/><rect height="2" width="3" x="5" y="11"/><rect height="2" width="4" x="9" y="11"/></g></svg>',underline:'<svg viewbox="0 0 18 18"><path class="ql-stroke" d="M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3"/><rect class="ql-fill" height="1" rx="0.5" ry="0.5" width="12" x="3" y="15"/></svg>',video:'<svg viewbox="0 0 18 18"><rect class="ql-stroke" height="12" width="12" x="3" y="3"/><rect class="ql-fill" height="12" width="1" x="5" y="3"/><rect class="ql-fill" height="12" width="1" x="12" y="3"/><rect class="ql-fill" height="2" width="8" x="5" y="8"/><rect class="ql-fill" height="1" width="3" x="3" y="5"/><rect class="ql-fill" height="1" width="3" x="3" y="7"/><rect class="ql-fill" height="1" width="3" x="3" y="10"/><rect class="ql-fill" height="1" width="3" x="3" y="12"/><rect class="ql-fill" height="1" width="3" x="12" y="5"/><rect class="ql-fill" height="1" width="3" x="12" y="7"/><rect class="ql-fill" height="1" width="3" x="12" y="10"/><rect class="ql-fill" height="1" width="3" x="12" y="12"/></svg>'};let lr=0;function cr(t,e){t.setAttribute(e,`${!("true"===t.getAttribute(e))}`)}class ur{constructor(t){this.select=t,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",(()=>{this.togglePicker()})),this.label.addEventListener("keydown",(t=>{switch(t.key){case"Enter":this.togglePicker();break;case"Escape":this.escape(),t.preventDefault()}})),this.select.addEventListener("change",this.update.bind(this))}togglePicker(){this.container.classList.toggle("ql-expanded"),cr(this.label,"aria-expanded"),cr(this.options,"aria-hidden")}buildItem(t){const e=document.createElement("span");e.tabIndex="0",e.setAttribute("role","button"),e.classList.add("ql-picker-item");const i=t.getAttribute("value");return i&&e.setAttribute("data-value",i),t.textContent&&e.setAttribute("data-label",t.textContent),e.addEventListener("click",(()=>{this.selectItem(e,!0)})),e.addEventListener("keydown",(t=>{switch(t.key){case"Enter":this.selectItem(e,!0),t.preventDefault();break;case"Escape":this.escape(),t.preventDefault()}})),e}buildLabel(){const t=document.createElement("span");return t.classList.add("ql-picker-label"),t.innerHTML='<svg viewbox="0 0 18 18"><polygon class="ql-stroke" points="7 11 9 13 11 11 7 11"/><polygon class="ql-stroke" points="7 7 9 5 11 7 7 7"/></svg>',t.tabIndex="0",t.setAttribute("role","button"),t.setAttribute("aria-expanded","false"),this.container.appendChild(t),t}buildOptions(){const t=document.createElement("span");t.classList.add("ql-picker-options"),t.setAttribute("aria-hidden","true"),t.tabIndex="-1",t.id=`ql-picker-options-${lr}`,lr+=1,this.label.setAttribute("aria-controls",t.id),this.options=t,Array.from(this.select.options).forEach((e=>{const i=this.buildItem(e);t.appendChild(i),!0===e.selected&&this.selectItem(i)})),this.container.appendChild(t)}buildPicker(){Array.from(this.select.attributes).forEach((t=>{this.container.setAttribute(t.name,t.value)})),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}escape(){this.close(),setTimeout((()=>this.label.focus()),1)}close(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}selectItem(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const i=this.container.querySelector(".ql-selected");t!==i&&(null!=i&&i.classList.remove("ql-selected"),null!=t&&(t.classList.add("ql-selected"),this.select.selectedIndex=Array.from(t.parentNode.children).indexOf(t),t.hasAttribute("data-value")?this.label.setAttribute("data-value",t.getAttribute("data-value")):this.label.removeAttribute("data-value"),t.hasAttribute("data-label")?this.label.setAttribute("data-label",t.getAttribute("data-label")):this.label.removeAttribute("data-label"),e&&(this.select.dispatchEvent(new Event("change")),this.close())))}update(){let t;if(this.select.selectedIndex>-1){const e=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];t=this.select.options[this.select.selectedIndex],this.selectItem(e)}else this.selectItem(null);const e=null!=t&&t!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",e)}}class hr extends ur{constructor(t,e){super(t),this.label.innerHTML=e,this.container.classList.add("ql-color-picker"),Array.from(this.container.querySelectorAll(".ql-picker-item")).slice(0,7).forEach((t=>{t.classList.add("ql-primary")}))}buildItem(t){const e=super.buildItem(t);return e.style.backgroundColor=t.getAttribute("value")||"",e}selectItem(t,e){super.selectItem(t,e);const i=this.label.querySelector(".ql-color-label"),n=t&&t.getAttribute("data-value")||"";i&&("line"===i.tagName?i.style.stroke=n:i.style.fill=n)}}class ar extends ur{constructor(t,e){super(t),this.container.classList.add("ql-icon-picker"),Array.from(this.container.querySelectorAll(".ql-picker-item")).forEach((t=>{t.innerHTML=e[t.getAttribute("data-value")||""]})),this.defaultItem=this.container.querySelector(".ql-selected"),this.selectItem(this.defaultItem)}selectItem(t,e){super.selectItem(t,e);const i=t||this.defaultItem;if(null!=i){if(this.label.innerHTML===i.innerHTML)return;this.label.innerHTML=i.innerHTML}}}class fr{constructor(t,e){this.quill=t,this.boundsContainer=e||document.body,this.root=t.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,(t=>{const{overflowY:e}=getComputedStyle(t,null);return"visible"!==e&&"clip"!==e})(this.quill.root)&&this.quill.root.addEventListener("scroll",(()=>{this.root.style.marginTop=-1*this.quill.root.scrollTop+"px"})),this.hide()}hide(){this.root.classList.add("ql-hidden")}position(t){const e=t.left+t.width/2-this.root.offsetWidth/2,i=t.bottom+this.quill.root.scrollTop;this.root.style.left=`${e}px`,this.root.style.top=`${i}px`,this.root.classList.remove("ql-flip");const n=this.boundsContainer.getBoundingClientRect(),s=this.root.getBoundingClientRect();let r=0;return s.right>n.right&&(r=n.right-s.right,this.root.style.left=`${e+r}px`),s.left<n.left&&(r=n.left-s.left,this.root.style.left=`${e+r}px`),s.bottom>n.bottom&&(this.root.style.top=i-(t.bottom-t.top+(s.bottom-s.top))+"px",this.root.classList.add("ql-flip")),r}show(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}const dr=[!1,"center","right","justify"],pr=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],br=[!1,"serif","monospace"],vr=["1","2","3",!1],yr=["small",!1,"large","huge"];class mr extends gn{constructor(t,e){super(t,e);const i=e=>{document.body.contains(t.root)?(null==this.tooltip||this.tooltip.root.contains(e.target)||document.activeElement===this.tooltip.textbox||this.quill.hasFocus()||this.tooltip.hide(),null!=this.pickers&&this.pickers.forEach((t=>{t.container.contains(e.target)||t.close()}))):document.body.removeEventListener("click",i)};t.emitter.listenDOM("click",document.body,i)}addModule(t){const e=super.addModule(t);return"toolbar"===t&&this.extendToolbar(e),e}buildButtons(t,e){Array.from(t).forEach((t=>{(t.getAttribute("class")||"").split(/\s+/).forEach((i=>{if(i.startsWith("ql-")&&(i=i.slice(3),null!=e[i]))if("direction"===i)t.innerHTML=e[i][""]+e[i].rtl;else if("string"==typeof e[i])t.innerHTML=e[i];else{const n=t.value||"";null!=n&&e[i][n]&&(t.innerHTML=e[i][n])}}))}))}buildPickers(t,e){this.pickers=Array.from(t).map((t=>{if(t.classList.contains("ql-align")&&(null==t.querySelector("option")&&gr(t,dr),"object"==typeof e.align))return new ar(t,e.align);if(t.classList.contains("ql-background")||t.classList.contains("ql-color")){const i=t.classList.contains("ql-background")?"background":"color";return null==t.querySelector("option")&&gr(t,pr,"background"===i?"#ffffff":"#000000"),new hr(t,e[i])}return null==t.querySelector("option")&&(t.classList.contains("ql-font")?gr(t,br):t.classList.contains("ql-header")?gr(t,vr):t.classList.contains("ql-size")&&gr(t,yr)),new ur(t)})),this.quill.on(nn.events.EDITOR_CHANGE,(()=>{this.pickers.forEach((t=>{t.update()}))}))}}mr.DEFAULTS=Re({},gn.DEFAULTS,{modules:{toolbar:{handlers:{formula(){this.quill.theme.tooltip.edit("formula")},image(){let t=this.container.querySelector("input.ql-image[type=file]");null==t&&(t=document.createElement("input"),t.setAttribute("type","file"),t.setAttribute("accept",this.quill.uploader.options.mimetypes.join(", ")),t.classList.add("ql-image"),t.addEventListener("change",(()=>{const e=this.quill.getSelection(!0);this.quill.uploader.upload(e,t.files),t.value=""})),this.container.appendChild(t)),t.click()},video(){this.quill.theme.tooltip.edit("video")}}}}});class wr extends fr{constructor(t,e){super(t,e),this.textbox=this.root.querySelector('input[type="text"]'),this.listen()}listen(){this.textbox.addEventListener("keydown",(t=>{"Enter"===t.key?(this.save(),t.preventDefault()):"Escape"===t.key&&(this.cancel(),t.preventDefault())}))}cancel(){this.hide(),this.restoreFocus()}edit(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"link",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),null==this.textbox)return;null!=e?this.textbox.value=e:t!==this.root.getAttribute("data-mode")&&(this.textbox.value="");const i=this.quill.getBounds(this.quill.selection.savedRange);null!=i&&this.position(i),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute(`data-${t}`)||""),this.root.setAttribute("data-mode",t)}restoreFocus(){this.quill.focus({preventScroll:!0})}save(){let{value:t}=this.textbox;switch(this.root.getAttribute("data-mode")){case"link":{const{scrollTop:e}=this.quill.root;this.linkRange?(this.quill.formatText(this.linkRange,"link",t,nn.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",t,nn.sources.USER)),this.quill.root.scrollTop=e;break}case"video":t=function(t){let e=t.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||t.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return e?`${e[1]||"https"}://www.youtube.com/embed/${e[2]}?showinfo=0`:(e=t.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?`${e[1]||"https"}://player.vimeo.com/video/${e[2]}/`:t}(t);case"formula":{if(!t)break;const e=this.quill.getSelection(!0);if(null!=e){const i=e.index+e.length;this.quill.insertEmbed(i,this.root.getAttribute("data-mode"),t,nn.sources.USER),"formula"===this.root.getAttribute("data-mode")&&this.quill.insertText(i+1," ",nn.sources.USER),this.quill.setSelection(i+2,nn.sources.USER)}break}}this.textbox.value="",this.hide()}}function gr(t,e){let i=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e.forEach((e=>{const n=document.createElement("option");e===i?n.setAttribute("selected","selected"):n.setAttribute("value",String(e)),t.appendChild(n)}))}const xr=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]];class kr extends wr{static TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join("");constructor(t,e){super(t,e),this.quill.on(nn.events.EDITOR_CHANGE,((t,e,i,n)=>{if(t===nn.events.SELECTION_CHANGE)if(null!=e&&e.length>0&&n===nn.sources.USER){this.show(),this.root.style.left="0px",this.root.style.width="",this.root.style.width=`${this.root.offsetWidth}px`;const t=this.quill.getLines(e.index,e.length);if(1===t.length){const t=this.quill.getBounds(e);null!=t&&this.position(t)}else{const i=t[t.length-1],n=this.quill.getIndex(i),s=Math.min(i.length()-1,e.index+e.length-n),r=this.quill.getBounds(new rn(n,s));null!=r&&this.position(r)}}else document.activeElement!==this.textbox&&this.quill.hasFocus()&&this.hide()}))}listen(){super.listen(),this.root.querySelector(".ql-close").addEventListener("click",(()=>{this.root.classList.remove("ql-editing")})),this.quill.on(nn.events.SCROLL_OPTIMIZE,(()=>{setTimeout((()=>{if(this.root.classList.contains("ql-hidden"))return;const t=this.quill.getSelection();if(null!=t){const e=this.quill.getBounds(t);null!=e&&this.position(e)}}),1)}))}cancel(){this.show()}position(t){const e=super.position(t),i=this.root.querySelector(".ql-tooltip-arrow");return i.style.marginLeft="",0!==e&&(i.style.marginLeft=-1*e-i.offsetWidth/2+"px"),e}}class jr extends mr{constructor(t,e){null!=e.modules.toolbar&&null==e.modules.toolbar.container&&(e.modules.toolbar.container=xr),super(t,e),this.quill.container.classList.add("ql-bubble")}extendToolbar(t){this.tooltip=new kr(this.quill,this.options.bounds),null!=t.container&&(this.tooltip.root.appendChild(t.container),this.buildButtons(t.container.querySelectorAll("button"),or),this.buildPickers(t.container.querySelectorAll("select"),or))}}jr.DEFAULTS=Re({},mr.DEFAULTS,{modules:{toolbar:{handlers:{link(t){t?this.quill.theme.tooltip.edit():this.quill.format("link",!1,Mn.sources.USER)}}}}});const Ar=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]];class qr extends wr{static TEMPLATE=['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join("");preview=this.root.querySelector("a.ql-preview");listen(){super.listen(),this.root.querySelector("a.ql-action").addEventListener("click",(t=>{this.root.classList.contains("ql-editing")?this.save():this.edit("link",this.preview.textContent),t.preventDefault()})),this.root.querySelector("a.ql-remove").addEventListener("click",(t=>{if(null!=this.linkRange){const t=this.linkRange;this.restoreFocus(),this.quill.formatText(t,"link",!1,nn.sources.USER),delete this.linkRange}t.preventDefault(),this.hide()})),this.quill.on(nn.events.SELECTION_CHANGE,((t,e,i)=>{if(null!=t){if(0===t.length&&i===nn.sources.USER){const[e,i]=this.quill.scroll.descendant(Ps,t.index);if(null!=e){this.linkRange=new rn(t.index-i,e.length());const n=Ps.formats(e.domNode);this.preview.textContent=n,this.preview.setAttribute("href",n),this.show();const s=this.quill.getBounds(this.linkRange);return void(null!=s&&this.position(s))}}else delete this.linkRange;this.hide()}}))}show(){super.show(),this.root.removeAttribute("data-mode")}}class Or extends mr{constructor(t,e){null!=e.modules.toolbar&&null==e.modules.toolbar.container&&(e.modules.toolbar.container=Ar),super(t,e),this.quill.container.classList.add("ql-snow")}extendToolbar(t){null!=t.container&&(t.container.classList.add("ql-snow"),this.buildButtons(t.container.querySelectorAll("button"),or),this.buildPickers(t.container.querySelectorAll("select"),or),this.tooltip=new qr(this.quill,this.options.bounds),t.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"k",shortKey:!0},((e,i)=>{t.handlers.link.call(t,!i.format.link)})))}}Or.DEFAULTS=Re({},mr.DEFAULTS,{modules:{toolbar:{handlers:{link(t){if(t){const t=this.quill.getSelection();if(null==t||0===t.length)return;let e=this.quill.getText(t);/^\S+@\S+\.\S+$/.test(e)&&0!==e.indexOf("mailto:")&&(e=`mailto:${e}`);const{tooltip:i}=this.quill.theme;i.edit("link",e)}else this.quill.format("link",!1,Mn.sources.USER)}}}}}),Mn.register({"attributors/attribute/direction":Yn,"attributors/class/align":Vn,"attributors/class/background":Zn,"attributors/class/color":Fn,"attributors/class/direction":Xn,"attributors/class/font":es,"attributors/class/size":ns,"attributors/style/align":Hn,"attributors/style/background":Kn,"attributors/style/color":Un,"attributors/style/direction":Jn,"attributors/style/font":is,"attributors/style/size":ss},!0),Mn.register({"formats/align":Vn,"formats/direction":Xn,"formats/indent":Is,"formats/background":Kn,"formats/color":Un,"formats/font":es,"formats/size":ns,"formats/blockquote":class extends Hi{static blotName="blockquote";static tagName="blockquote"},"formats/code-block":Wn,"formats/header":class extends Hi{static blotName="header";static tagName=["H1","H2","H3","H4","H5","H6"];static formats(t){return this.tagName.indexOf(t.tagName)+1}},"formats/list":Vs,"formats/bold":Hs,"formats/code":Gn,"formats/italic":class extends Hs{static blotName="italic";static tagName=["EM","I"]},"formats/link":Ps,"formats/script":class extends Vi{static blotName="script";static tagName=["SUB","SUP"];static create(t){return"super"===t?document.createElement("sup"):"sub"===t?document.createElement("sub"):super.create(t)}static formats(t){return"SUB"===t.tagName?"sub":"SUP"===t.tagName?"super":void 0}},"formats/strike":class extends Hs{static blotName="strike";static tagName=["S","STRIKE"]},"formats/underline":class extends Vi{static blotName="underline";static tagName="U"},"formats/formula":class extends mn{static blotName="formula";static className="ql-formula";static tagName="SPAN";static create(t){if(null==window.katex)throw new Error("Formula module requires KaTeX.");const e=super.create(t);return"string"==typeof t&&(window.katex.render(t,e,{throwOnError:!1,errorColor:"#f00"}),e.setAttribute("data-value",t)),e}static value(t){return t.getAttribute("data-value")}html(){const{formula:t}=this.value();return`<span>${t}</span>`}},"formats/image":class extends ci{static blotName="image";static tagName="IMG";static create(t){const e=super.create(t);return"string"==typeof t&&e.setAttribute("src",this.sanitize(t)),e}static formats(t){return Us.reduce(((e,i)=>(t.hasAttribute(i)&&(e[i]=t.getAttribute(i)),e)),{})}static match(t){return/\.(jpe?g|gif|png)$/.test(t)||/^data:image\/.+;base64/.test(t)}static sanitize(t){return Fs(t,["http","https","data"])?t:"//:0"}static value(t){return t.getAttribute("src")}format(t,e){Us.indexOf(t)>-1?e?this.domNode.setAttribute(t,e):this.domNode.removeAttribute(t):super.format(t,e)}},"formats/video":class extends Pi{static blotName="video";static className="ql-video";static tagName="IFRAME";static create(t){const e=super.create(t);return e.setAttribute("frameborder","0"),e.setAttribute("allowfullscreen","true"),e.setAttribute("src",this.sanitize(t)),e}static formats(t){return Zs.reduce(((e,i)=>(t.hasAttribute(i)&&(e[i]=t.getAttribute(i)),e)),{})}static sanitize(t){return Ps.sanitize(t)}static value(t){return t.getAttribute("src")}format(t,e){Zs.indexOf(t)>-1?e?this.domNode.setAttribute(t,e):this.domNode.removeAttribute(t):super.format(t,e)}html(){const{video:t}=this.value();return`<a href="${t}">${t}</a>`}},"modules/syntax":Qs,"modules/table":class extends vn{static register(){Mn.register(Ys),Mn.register(Xs),Mn.register(Js),Mn.register(tr)}constructor(){super(...arguments),this.listenBalanceCells()}balanceTables(){this.quill.scroll.descendants(tr).forEach((t=>{t.balanceCells()}))}deleteColumn(){const[t,,e]=this.getTable();null!=e&&(t.deleteColumn(e.cellOffset()),this.quill.update(Mn.sources.USER))}deleteRow(){const[,t]=this.getTable();null!=t&&(t.remove(),this.quill.update(Mn.sources.USER))}deleteTable(){const[t]=this.getTable();if(null==t)return;const e=t.offset();t.remove(),this.quill.update(Mn.sources.USER),this.quill.setSelection(e,Mn.sources.SILENT)}getTable(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.quill.getSelection();if(null==t)return[null,null,null,-1];const[e,i]=this.quill.getLine(t.index);if(null==e||e.statics.blotName!==Ys.blotName)return[null,null,null,-1];const n=e.parent;return[n.parent.parent,n,e,i]}insertColumn(t){const e=this.quill.getSelection();if(!e)return;const[i,n,s]=this.getTable(e);if(null==s)return;const r=s.cellOffset();i.insertColumn(r+t),this.quill.update(Mn.sources.USER);let o=n.rowOffset();0===t&&(o+=1),this.quill.setSelection(e.index+o,e.length,Mn.sources.SILENT)}insertColumnLeft(){this.insertColumn(0)}insertColumnRight(){this.insertColumn(1)}insertRow(t){const e=this.quill.getSelection();if(!e)return;const[i,n,s]=this.getTable(e);if(null==s)return;const r=n.rowOffset();i.insertRow(r+t),this.quill.update(Mn.sources.USER),t>0?this.quill.setSelection(e,Mn.sources.SILENT):this.quill.setSelection(e.index+n.children.length,e.length,Mn.sources.SILENT)}insertRowAbove(){this.insertRow(0)}insertRowBelow(){this.insertRow(1)}insertTable(t,e){const i=this.quill.getSelection();if(null==i)return;const n=new Array(t).fill(0).reduce((t=>{const i=new Array(e).fill("\n").join("");return t.insert(i,{table:er()})}),(new Ci).retain(i.index));this.quill.updateContents(n,Mn.sources.USER),this.quill.setSelection(i.index,Mn.sources.SILENT),this.balanceTables()}listenBalanceCells(){this.quill.on(Mn.events.SCROLL_OPTIMIZE,(t=>{t.some((t=>!!["TD","TR","TBODY","TABLE"].includes(t.target.tagName)&&(this.quill.once(Mn.events.TEXT_CHANGE,((t,e,i)=>{i===Mn.sources.USER&&this.balanceTables()})),!0)))}))}},"modules/toolbar":nr,"themes/bubble":jr,"themes/snow":Or,"ui/icons":or,"ui/picker":ur,"ui/icon-picker":ar,"ui/color-picker":hr,"ui/tooltip":fr},!0);var Mr=Si.AttributeMap,Er=Si.Op;export{Mr as AttributeMap,Ci as Delta,vn as Module,Er as Op,pi as Parchment,rn as Range,Mn as default}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const o=()=>{};export{o as g}
|