kcal/public/js/quill.module.js

2 lines
157 KiB
JavaScript

/*! For license information please see quill.module.js.LICENSE.txt */
(()=>{var t={9742:(t,e)=>{"use strict";e.byteLength=function(t){var e=a(t),r=e[0],n=e[1];return 3*(r+n)/4-n},e.toByteArray=function(t){var e,r,o=a(t),s=o[0],l=o[1],u=new i(function(t,e,r){return 3*(e+r)/4-r}(0,s,l)),c=0,h=l>0?s-4:s;for(r=0;r<h;r+=4)e=n[t.charCodeAt(r)]<<18|n[t.charCodeAt(r+1)]<<12|n[t.charCodeAt(r+2)]<<6|n[t.charCodeAt(r+3)],u[c++]=e>>16&255,u[c++]=e>>8&255,u[c++]=255&e;2===l&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,u[c++]=255&e);1===l&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,u[c++]=e>>8&255,u[c++]=255&e);return u},e.fromByteArray=function(t){for(var e,n=t.length,i=n%3,o=[],s=16383,l=0,a=n-i;l<a;l+=s)o.push(u(t,l,l+s>a?a:l+s));1===i?(e=t[n-1],o.push(r[e>>2]+r[e<<4&63]+"==")):2===i&&(e=(t[n-2]<<8)+t[n-1],o.push(r[e>>10]+r[e>>4&63]+r[e<<2&63]+"="));return o.join("")};for(var r=[],n=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,l=o.length;s<l;++s)r[s]=o[s],n[o.charCodeAt(s)]=s;function a(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function u(t,e,n){for(var i,o,s=[],l=e;l<n;l+=3)i=(t[l]<<16&16711680)+(t[l+1]<<8&65280)+(255&t[l+2]),s.push(r[(o=i)>>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return s.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},8764:(t,e,r)=>{"use strict";var n=r(9742),i=r(645),o=r(5826);function s(){return a.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function l(t,e){if(s()<e)throw new RangeError("Invalid typed array length");return a.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(e)).__proto__=a.prototype:(null===t&&(t=new a(e)),t.length=e),t}function a(t,e,r){if(!(a.TYPED_ARRAY_SUPPORT||this instanceof a))return new a(t,e,r);if("number"==typeof t){if("string"==typeof e)throw new Error("If encoding is specified then the first argument must be a string");return h(this,t)}return u(this,t,e,r)}function u(t,e,r,n){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&e instanceof ArrayBuffer?function(t,e,r,n){if(e.byteLength,r<0||e.byteLength<r)throw new RangeError("'offset' is out of bounds");if(e.byteLength<r+(n||0))throw new RangeError("'length' is out of bounds");e=void 0===r&&void 0===n?new Uint8Array(e):void 0===n?new Uint8Array(e,r):new Uint8Array(e,r,n);a.TYPED_ARRAY_SUPPORT?(t=e).__proto__=a.prototype:t=f(t,e);return t}(t,e,r,n):"string"==typeof e?function(t,e,r){"string"==typeof r&&""!==r||(r="utf8");if(!a.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|d(e,r),i=(t=l(t,n)).write(e,r);i!==n&&(t=t.slice(0,i));return t}(t,e,r):function(t,e){if(a.isBuffer(e)){var r=0|p(e.length);return 0===(t=l(t,r)).length||e.copy(t,0,0,r),t}if(e){if("undefined"!=typeof ArrayBuffer&&e.buffer instanceof ArrayBuffer||"length"in e)return"number"!=typeof e.length||(n=e.length)!=n?l(t,0):f(t,e);if("Buffer"===e.type&&o(e.data))return f(t,e.data)}var n;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(t,e)}function c(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function h(t,e){if(c(e),t=l(t,e<0?0:0|p(e)),!a.TYPED_ARRAY_SUPPORT)for(var r=0;r<e;++r)t[r]=0;return t}function f(t,e){var r=e.length<0?0:0|p(e.length);t=l(t,r);for(var n=0;n<r;n+=1)t[n]=255&e[n];return t}function p(t){if(t>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|t}function d(t,e){if(a.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var n=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return F(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return K(t).length;default:if(n)return F(t).length;e=(""+e).toLowerCase(),n=!0}}function y(t,e,r){var n=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return L(this,e,r);case"utf8":case"utf-8":return T(this,e,r);case"ascii":return _(this,e,r);case"latin1":case"binary":return k(this,e,r);case"base64":return S(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return q(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}function g(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function m(t,e,r,n,i){if(0===t.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof e&&(e=a.from(e,n)),a.isBuffer(e))return 0===e.length?-1:b(t,e,r,n,i);if("number"==typeof e)return e&=255,a.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):b(t,[e],r,n,i);throw new TypeError("val must be string, number or Buffer")}function b(t,e,r,n,i){var o,s=1,l=t.length,a=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return-1;s=2,l/=2,a/=2,r/=2}function u(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(i){var c=-1;for(o=r;o<l;o++)if(u(t,o)===u(e,-1===c?0:o-c)){if(-1===c&&(c=o),o-c+1===a)return c*s}else-1!==c&&(o-=o-c),c=-1}else for(r+a>l&&(r=l-a),o=r;o>=0;o--){for(var h=!0,f=0;f<a;f++)if(u(t,o+f)!==u(e,f)){h=!1;break}if(h)return o}return-1}function v(t,e,r,n){r=Number(r)||0;var i=t.length-r;n?(n=Number(n))>i&&(n=i):n=i;var o=e.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var s=0;s<n;++s){var l=parseInt(e.substr(2*s,2),16);if(isNaN(l))return s;t[r+s]=l}return s}function E(t,e,r,n){return Y(F(e,t.length-r),t,r,n)}function A(t,e,r,n){return Y(function(t){for(var e=[],r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(e),t,r,n)}function N(t,e,r,n){return A(t,e,r,n)}function x(t,e,r,n){return Y(K(e),t,r,n)}function w(t,e,r,n){return Y(function(t,e){for(var r,n,i,o=[],s=0;s<t.length&&!((e-=2)<0);++s)n=(r=t.charCodeAt(s))>>8,i=r%256,o.push(i),o.push(n);return o}(e,t.length-r),t,r,n)}function S(t,e,r){return 0===e&&r===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(e,r))}function T(t,e,r){r=Math.min(t.length,r);for(var n=[],i=e;i<r;){var o,s,l,a,u=t[i],c=null,h=u>239?4:u>223?3:u>191?2:1;if(i+h<=r)switch(h){case 1:u<128&&(c=u);break;case 2:128==(192&(o=t[i+1]))&&(a=(31&u)<<6|63&o)>127&&(c=a);break;case 3:o=t[i+1],s=t[i+2],128==(192&o)&&128==(192&s)&&(a=(15&u)<<12|(63&o)<<6|63&s)>2047&&(a<55296||a>57343)&&(c=a);break;case 4:o=t[i+1],s=t[i+2],l=t[i+3],128==(192&o)&&128==(192&s)&&128==(192&l)&&(a=(15&u)<<18|(63&o)<<12|(63&s)<<6|63&l)>65535&&a<1114112&&(c=a)}null===c?(c=65533,h=1):c>65535&&(c-=65536,n.push(c>>>10&1023|55296),c=56320|1023&c),n.push(c),i+=h}return function(t){var e=t.length;if(e<=O)return String.fromCharCode.apply(String,t);var r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=O));return r}(n)}e.Buffer=a,e.SlowBuffer=function(t){+t!=t&&(t=0);return a.alloc(+t)},e.INSPECT_MAX_BYTES=50,a.TYPED_ARRAY_SUPPORT=void 0!==r.g.TYPED_ARRAY_SUPPORT?r.g.TYPED_ARRAY_SUPPORT:function(){try{var t=new Uint8Array(1);return t.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===t.foo()&&"function"==typeof t.subarray&&0===t.subarray(1,1).byteLength}catch(t){return!1}}(),e.kMaxLength=s(),a.poolSize=8192,a._augment=function(t){return t.__proto__=a.prototype,t},a.from=function(t,e,r){return u(null,t,e,r)},a.TYPED_ARRAY_SUPPORT&&(a.prototype.__proto__=Uint8Array.prototype,a.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&a[Symbol.species]===a&&Object.defineProperty(a,Symbol.species,{value:null,configurable:!0})),a.alloc=function(t,e,r){return function(t,e,r,n){return c(e),e<=0?l(t,e):void 0!==r?"string"==typeof n?l(t,e).fill(r,n):l(t,e).fill(r):l(t,e)}(null,t,e,r)},a.allocUnsafe=function(t){return h(null,t)},a.allocUnsafeSlow=function(t){return h(null,t)},a.isBuffer=function(t){return!(null==t||!t._isBuffer)},a.compare=function(t,e){if(!a.isBuffer(t)||!a.isBuffer(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var r=t.length,n=e.length,i=0,o=Math.min(r,n);i<o;++i)if(t[i]!==e[i]){r=t[i],n=e[i];break}return r<n?-1:n<r?1:0},a.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},a.concat=function(t,e){if(!o(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return a.alloc(0);var r;if(void 0===e)for(e=0,r=0;r<t.length;++r)e+=t[r].length;var n=a.allocUnsafe(e),i=0;for(r=0;r<t.length;++r){var s=t[r];if(!a.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(n,i),i+=s.length}return n},a.byteLength=d,a.prototype._isBuffer=!0,a.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)g(this,e,e+1);return this},a.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)g(this,e,e+3),g(this,e+1,e+2);return this},a.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)g(this,e,e+7),g(this,e+1,e+6),g(this,e+2,e+5),g(this,e+3,e+4);return this},a.prototype.toString=function(){var t=0|this.length;return 0===t?"":0===arguments.length?T(this,0,t):y.apply(this,arguments)},a.prototype.equals=function(t){if(!a.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===a.compare(this,t)},a.prototype.inspect=function(){var t="",r=e.INSPECT_MAX_BYTES;return this.length>0&&(t=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(t+=" ... ")),"<Buffer "+t+">"},a.prototype.compare=function(t,e,r,n,i){if(!a.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),e<0||r>t.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&e>=r)return 0;if(n>=i)return-1;if(e>=r)return 1;if(this===t)return 0;for(var o=(i>>>=0)-(n>>>=0),s=(r>>>=0)-(e>>>=0),l=Math.min(o,s),u=this.slice(n,i),c=t.slice(e,r),h=0;h<l;++h)if(u[h]!==c[h]){o=u[h],s=c[h];break}return o<s?-1:s<o?1:0},a.prototype.includes=function(t,e,r){return-1!==this.indexOf(t,e,r)},a.prototype.indexOf=function(t,e,r){return m(this,t,e,r,!0)},a.prototype.lastIndexOf=function(t,e,r){return m(this,t,e,r,!1)},a.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e|=0,isFinite(r)?(r|=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-e;if((void 0===r||r>i)&&(r=i),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return v(this,t,e,r);case"utf8":case"utf-8":return E(this,t,e,r);case"ascii":return A(this,t,e,r);case"latin1":case"binary":return N(this,t,e,r);case"base64":return x(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return w(this,t,e,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var O=4096;function _(t,e,r){var n="";r=Math.min(t.length,r);for(var i=e;i<r;++i)n+=String.fromCharCode(127&t[i]);return n}function k(t,e,r){var n="";r=Math.min(t.length,r);for(var i=e;i<r;++i)n+=String.fromCharCode(t[i]);return n}function L(t,e,r){var n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);for(var i="",o=e;o<r;++o)i+=M(t[o]);return i}function q(t,e,r){for(var n=t.slice(e,r),i="",o=0;o<n.length;o+=2)i+=String.fromCharCode(n[o]+256*n[o+1]);return i}function R(t,e,r){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}function C(t,e,r,n,i,o){if(!a.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||e<o)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}function P(t,e,r,n){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-r,2);i<o;++i)t[r+i]=(e&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function I(t,e,r,n){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-r,4);i<o;++i)t[r+i]=e>>>8*(n?i:3-i)&255}function j(t,e,r,n,i,o){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function B(t,e,r,n,o){return o||j(t,0,r,4),i.write(t,e,r,n,23,4),r+4}function U(t,e,r,n,o){return o||j(t,0,r,8),i.write(t,e,r,n,52,8),r+8}a.prototype.slice=function(t,e){var r,n=this.length;if((t=~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),(e=void 0===e?n:~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),e<t&&(e=t),a.TYPED_ARRAY_SUPPORT)(r=this.subarray(t,e)).__proto__=a.prototype;else{var i=e-t;r=new a(i,void 0);for(var o=0;o<i;++o)r[o]=this[o+t]}return r},a.prototype.readUIntLE=function(t,e,r){t|=0,e|=0,r||R(t,e,this.length);for(var n=this[t],i=1,o=0;++o<e&&(i*=256);)n+=this[t+o]*i;return n},a.prototype.readUIntBE=function(t,e,r){t|=0,e|=0,r||R(t,e,this.length);for(var n=this[t+--e],i=1;e>0&&(i*=256);)n+=this[t+--e]*i;return n},a.prototype.readUInt8=function(t,e){return e||R(t,1,this.length),this[t]},a.prototype.readUInt16LE=function(t,e){return e||R(t,2,this.length),this[t]|this[t+1]<<8},a.prototype.readUInt16BE=function(t,e){return e||R(t,2,this.length),this[t]<<8|this[t+1]},a.prototype.readUInt32LE=function(t,e){return e||R(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},a.prototype.readUInt32BE=function(t,e){return e||R(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},a.prototype.readIntLE=function(t,e,r){t|=0,e|=0,r||R(t,e,this.length);for(var n=this[t],i=1,o=0;++o<e&&(i*=256);)n+=this[t+o]*i;return n>=(i*=128)&&(n-=Math.pow(2,8*e)),n},a.prototype.readIntBE=function(t,e,r){t|=0,e|=0,r||R(t,e,this.length);for(var n=e,i=1,o=this[t+--n];n>0&&(i*=256);)o+=this[t+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*e)),o},a.prototype.readInt8=function(t,e){return e||R(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},a.prototype.readInt16LE=function(t,e){e||R(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},a.prototype.readInt16BE=function(t,e){e||R(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},a.prototype.readInt32LE=function(t,e){return e||R(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},a.prototype.readInt32BE=function(t,e){return e||R(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},a.prototype.readFloatLE=function(t,e){return e||R(t,4,this.length),i.read(this,t,!0,23,4)},a.prototype.readFloatBE=function(t,e){return e||R(t,4,this.length),i.read(this,t,!1,23,4)},a.prototype.readDoubleLE=function(t,e){return e||R(t,8,this.length),i.read(this,t,!0,52,8)},a.prototype.readDoubleBE=function(t,e){return e||R(t,8,this.length),i.read(this,t,!1,52,8)},a.prototype.writeUIntLE=function(t,e,r,n){(t=+t,e|=0,r|=0,n)||C(this,t,e,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[e]=255&t;++o<r&&(i*=256);)this[e+o]=t/i&255;return e+r},a.prototype.writeUIntBE=function(t,e,r,n){(t=+t,e|=0,r|=0,n)||C(this,t,e,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[e+i]=255&t;--i>=0&&(o*=256);)this[e+i]=t/o&255;return e+r},a.prototype.writeUInt8=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,1,255,0),a.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},a.prototype.writeUInt16LE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,2,65535,0),a.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):P(this,t,e,!0),e+2},a.prototype.writeUInt16BE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,2,65535,0),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):P(this,t,e,!1),e+2},a.prototype.writeUInt32LE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,4,4294967295,0),a.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):I(this,t,e,!0),e+4},a.prototype.writeUInt32BE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,4,4294967295,0),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):I(this,t,e,!1),e+4},a.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e|=0,!n){var i=Math.pow(2,8*r-1);C(this,t,e,r,i-1,-i)}var o=0,s=1,l=0;for(this[e]=255&t;++o<r&&(s*=256);)t<0&&0===l&&0!==this[e+o-1]&&(l=1),this[e+o]=(t/s>>0)-l&255;return e+r},a.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e|=0,!n){var i=Math.pow(2,8*r-1);C(this,t,e,r,i-1,-i)}var o=r-1,s=1,l=0;for(this[e+o]=255&t;--o>=0&&(s*=256);)t<0&&0===l&&0!==this[e+o+1]&&(l=1),this[e+o]=(t/s>>0)-l&255;return e+r},a.prototype.writeInt8=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,1,127,-128),a.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},a.prototype.writeInt16LE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,2,32767,-32768),a.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):P(this,t,e,!0),e+2},a.prototype.writeInt16BE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,2,32767,-32768),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):P(this,t,e,!1),e+2},a.prototype.writeInt32LE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,4,2147483647,-2147483648),a.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):I(this,t,e,!0),e+4},a.prototype.writeInt32BE=function(t,e,r){return t=+t,e|=0,r||C(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),a.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):I(this,t,e,!1),e+4},a.prototype.writeFloatLE=function(t,e,r){return B(this,t,e,!0,r)},a.prototype.writeFloatBE=function(t,e,r){return B(this,t,e,!1,r)},a.prototype.writeDoubleLE=function(t,e,r){return U(this,t,e,!0,r)},a.prototype.writeDoubleBE=function(t,e,r){return U(this,t,e,!1,r)},a.prototype.copy=function(t,e,r,n){if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e<n-r&&(n=t.length-e+r);var i,o=n-r;if(this===t&&r<e&&e<n)for(i=o-1;i>=0;--i)t[i+e]=this[i+r];else if(o<1e3||!a.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)t[i+e]=this[i+r];else Uint8Array.prototype.set.call(t,this.subarray(r,r+o),e);return o},a.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),1===t.length){var i=t.charCodeAt(0);i<256&&(t=i)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!a.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof t&&(t&=255);if(e<0||this.length<e||this.length<r)throw new RangeError("Out of range index");if(r<=e)return this;var o;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o<r;++o)this[o]=t;else{var s=a.isBuffer(t)?t:F(new a(t,n).toString()),l=s.length;for(o=0;o<r-e;++o)this[o+e]=s[o%l]}return this};var D=/[^+\/0-9A-Za-z-_]/g;function M(t){return t<16?"0"+t.toString(16):t.toString(16)}function F(t,e){var r;e=e||1/0;for(var n=t.length,i=null,o=[],s=0;s<n;++s){if((r=t.charCodeAt(s))>55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(s+1===n){(e-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;o.push(r)}else if(r<2048){if((e-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function K(t){return n.toByteArray(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(D,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function Y(t,e,r,n){for(var i=0;i<n&&!(i+r>=e.length||i>=t.length);++i)e[i+r]=t[i];return i}},1924:(t,e,r)=>{"use strict";var n=r(210),i=r(5559),o=i(n("String.prototype.indexOf"));t.exports=function(t,e){var r=n(t,!!e);return"function"==typeof r&&o(t,".prototype.")>-1?i(r):r}},5559:(t,e,r)=>{"use strict";var n=r(8612),i=r(210),o=i("%Function.prototype.apply%"),s=i("%Function.prototype.call%"),l=i("%Reflect.apply%",!0)||n.call(s,o),a=i("%Object.getOwnPropertyDescriptor%",!0),u=i("%Object.defineProperty%",!0),c=i("%Math.max%");if(u)try{u({},"a",{value:1})}catch(t){u=null}t.exports=function(t){var e=l(n,s,arguments);if(a&&u){var r=a(e,"length");r.configurable&&u(e,"length",{value:1+c(0,t.length-(arguments.length-1))})}return e};var h=function(){return l(n,o,arguments)};u?u(t.exports,"apply",{value:h}):t.exports.apply=h},6313:(t,e,r)=>{var n=r(8764).Buffer,i=function(){"use strict";function t(t,e){return null!=e&&t instanceof e}var e,r,i;try{e=Map}catch(t){e=function(){}}try{r=Set}catch(t){r=function(){}}try{i=Promise}catch(t){i=function(){}}function o(s,a,u,c,h){"object"==typeof a&&(u=a.depth,c=a.prototype,h=a.includeNonEnumerable,a=a.circular);var f=[],p=[],d=void 0!==n;return void 0===a&&(a=!0),void 0===u&&(u=1/0),function s(u,y){if(null===u)return null;if(0===y)return u;var g,m;if("object"!=typeof u)return u;if(t(u,e))g=new e;else if(t(u,r))g=new r;else if(t(u,i))g=new i((function(t,e){u.then((function(e){t(s(e,y-1))}),(function(t){e(s(t,y-1))}))}));else if(o.__isArray(u))g=[];else if(o.__isRegExp(u))g=new RegExp(u.source,l(u)),u.lastIndex&&(g.lastIndex=u.lastIndex);else if(o.__isDate(u))g=new Date(u.getTime());else{if(d&&n.isBuffer(u))return g=n.allocUnsafe?n.allocUnsafe(u.length):new n(u.length),u.copy(g),g;t(u,Error)?g=Object.create(u):void 0===c?(m=Object.getPrototypeOf(u),g=Object.create(m)):(g=Object.create(c),m=c)}if(a){var b=f.indexOf(u);if(-1!=b)return p[b];f.push(u),p.push(g)}for(var v in t(u,e)&&u.forEach((function(t,e){var r=s(e,y-1),n=s(t,y-1);g.set(r,n)})),t(u,r)&&u.forEach((function(t){var e=s(t,y-1);g.add(e)})),u){var E;m&&(E=Object.getOwnPropertyDescriptor(m,v)),E&&null==E.set||(g[v]=s(u[v],y-1))}if(Object.getOwnPropertySymbols){var A=Object.getOwnPropertySymbols(u);for(v=0;v<A.length;v++){var N=A[v];(!(w=Object.getOwnPropertyDescriptor(u,N))||w.enumerable||h)&&(g[N]=s(u[N],y-1),w.enumerable||Object.defineProperty(g,N,{enumerable:!1}))}}if(h){var x=Object.getOwnPropertyNames(u);for(v=0;v<x.length;v++){var w,S=x[v];(w=Object.getOwnPropertyDescriptor(u,S))&&w.enumerable||(g[S]=s(u[S],y-1),Object.defineProperty(g,S,{enumerable:!1}))}}return g}(s,u)}function s(t){return Object.prototype.toString.call(t)}function l(t){var e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),e}return o.clonePrototype=function(t){if(null===t)return null;var e=function(){};return e.prototype=t,new e},o.__objToStr=s,o.__isDate=function(t){return"object"==typeof t&&"[object Date]"===s(t)},o.__isArray=function(t){return"object"==typeof t&&"[object Array]"===s(t)},o.__isRegExp=function(t){return"object"==typeof t&&"[object RegExp]"===s(t)},o.__getRegExpFlags=l,o}();t.exports&&(t.exports=i)},251:(t,e,r)=>{var n=r(2215),i=r(2584),o=r(609),s=r(8420),l=r(2847),a=r(8923),u=Date.prototype.getTime;function c(t,e,r){var p=r||{};return!!(p.strict?o(t,e):t===e)||(!t||!e||"object"!=typeof t&&"object"!=typeof e?p.strict?o(t,e):t==e:function(t,e,r){var o,p;if(typeof t!=typeof e)return!1;if(h(t)||h(e))return!1;if(t.prototype!==e.prototype)return!1;if(i(t)!==i(e))return!1;var d=s(t),y=s(e);if(d!==y)return!1;if(d||y)return t.source===e.source&&l(t)===l(e);if(a(t)&&a(e))return u.call(t)===u.call(e);var g=f(t),m=f(e);if(g!==m)return!1;if(g||m){if(t.length!==e.length)return!1;for(o=0;o<t.length;o++)if(t[o]!==e[o])return!1;return!0}if(typeof t!=typeof e)return!1;try{var b=n(t),v=n(e)}catch(t){return!1}if(b.length!==v.length)return!1;for(b.sort(),v.sort(),o=b.length-1;o>=0;o--)if(b[o]!=v[o])return!1;for(o=b.length-1;o>=0;o--)if(!c(t[p=b[o]],e[p],r))return!1;return!0}(t,e,p))}function h(t){return null==t}function f(t){return!(!t||"object"!=typeof t||"number"!=typeof t.length)&&("function"==typeof t.copy&&"function"==typeof t.slice&&!(t.length>0&&"number"!=typeof t[0]))}t.exports=c},4289:(t,e,r)=>{"use strict";var n=r(2215),i="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),o=Object.prototype.toString,s=Array.prototype.concat,l=Object.defineProperty,a=l&&function(){var t={};try{for(var e in l(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),u=function(t,e,r,n){var i;(!(e in t)||"function"==typeof(i=n)&&"[object Function]"===o.call(i)&&n())&&(a?l(t,e,{configurable:!0,enumerable:!1,value:r,writable:!0}):t[e]=r)},c=function(t,e){var r=arguments.length>2?arguments[2]:{},o=n(e);i&&(o=s.call(o,Object.getOwnPropertySymbols(e)));for(var l=0;l<o.length;l+=1)u(t,o[l],e[o[l]],r[o[l]])};c.supportsDescriptors=!!a,t.exports=c},6729:t=>{"use strict";var e=Object.prototype.hasOwnProperty,r="~";function n(){}function i(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function o(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(r=!1)),o.prototype.eventNames=function(){var t,n,i=[];if(0===this._eventsCount)return i;for(n in t=this._events)e.call(t,n)&&i.push(r?n.slice(1):n);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(t)):i},o.prototype.listeners=function(t,e){var n=r?r+t:t,i=this._events[n];if(e)return!!i;if(!i)return[];if(i.fn)return[i.fn];for(var o=0,s=i.length,l=new Array(s);o<s;o++)l[o]=i[o].fn;return l},o.prototype.emit=function(t,e,n,i,o,s){var l=r?r+t:t;if(!this._events[l])return!1;var a,u,c=this._events[l],h=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),h){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,n),!0;case 4:return c.fn.call(c.context,e,n,i),!0;case 5:return c.fn.call(c.context,e,n,i,o),!0;case 6:return c.fn.call(c.context,e,n,i,o,s),!0}for(u=1,a=new Array(h-1);u<h;u++)a[u-1]=arguments[u];c.fn.apply(c.context,a)}else{var f,p=c.length;for(u=0;u<p;u++)switch(c[u].once&&this.removeListener(t,c[u].fn,void 0,!0),h){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,e);break;case 3:c[u].fn.call(c[u].context,e,n);break;case 4:c[u].fn.call(c[u].context,e,n,i);break;default:if(!a)for(f=1,a=new Array(h-1);f<h;f++)a[f-1]=arguments[f];c[u].fn.apply(c[u].context,a)}}return!0},o.prototype.on=function(t,e,n){var o=new i(e,n||this),s=r?r+t:t;return this._events[s]?this._events[s].fn?this._events[s]=[this._events[s],o]:this._events[s].push(o):(this._events[s]=o,this._eventsCount++),this},o.prototype.once=function(t,e,n){var o=new i(e,n||this,!0),s=r?r+t:t;return this._events[s]?this._events[s].fn?this._events[s]=[this._events[s],o]:this._events[s].push(o):(this._events[s]=o,this._eventsCount++),this},o.prototype.removeListener=function(t,e,i,o){var s=r?r+t:t;if(!this._events[s])return this;if(!e)return 0==--this._eventsCount?this._events=new n:delete this._events[s],this;var l=this._events[s];if(l.fn)l.fn!==e||o&&!l.once||i&&l.context!==i||(0==--this._eventsCount?this._events=new n:delete this._events[s]);else{for(var a=0,u=[],c=l.length;a<c;a++)(l[a].fn!==e||o&&!l[a].once||i&&l[a].context!==i)&&u.push(l[a]);u.length?this._events[s]=1===u.length?u[0]:u:0==--this._eventsCount?this._events=new n:delete this._events[s]}return this},o.prototype.removeAllListeners=function(t){var e;return t?(e=r?r+t:t,this._events[e]&&(0==--this._eventsCount?this._events=new n:delete this._events[e])):(this._events=new n,this._eventsCount=0),this},o.prototype.off=o.prototype.removeListener,o.prototype.addListener=o.prototype.on,o.prototype.setMaxListeners=function(){return this},o.prefixed=r,o.EventEmitter=o,t.exports=o},4470:t=>{"use strict";var e=Object.prototype.hasOwnProperty,r=Object.prototype.toString,n=Object.defineProperty,i=Object.getOwnPropertyDescriptor,o=function(t){return"function"==typeof Array.isArray?Array.isArray(t):"[object Array]"===r.call(t)},s=function(t){if(!t||"[object Object]"!==r.call(t))return!1;var n,i=e.call(t,"constructor"),o=t.constructor&&t.constructor.prototype&&e.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!i&&!o)return!1;for(n in t);return void 0===n||e.call(t,n)},l=function(t,e){n&&"__proto__"===e.name?n(t,e.name,{enumerable:!0,configurable:!0,value:e.newValue,writable:!0}):t[e.name]=e.newValue},a=function(t,r){if("__proto__"===r){if(!e.call(t,r))return;if(i)return i(t,r).value}return t[r]};t.exports=function t(){var e,r,n,i,u,c,h=arguments[0],f=1,p=arguments.length,d=!1;for("boolean"==typeof h&&(d=h,h=arguments[1]||{},f=2),(null==h||"object"!=typeof h&&"function"!=typeof h)&&(h={});f<p;++f)if(null!=(e=arguments[f]))for(r in e)n=a(h,r),h!==(i=a(e,r))&&(d&&i&&(s(i)||(u=o(i)))?(u?(u=!1,c=n&&o(n)?n:[]):c=n&&s(n)?n:{},l(h,{name:r,newValue:t(d,c,i)})):void 0!==i&&l(h,{name:r,newValue:i}));return h}},7529:t=>{var e=-1;function r(t,l,u){if(t==l)return t?[[0,t]]:[];(u<0||t.length<u)&&(u=null);var c=i(t,l),h=t.substring(0,c);c=o(t=t.substring(c),l=l.substring(c));var f=t.substring(t.length-c),p=function(t,s){var l;if(!t)return[[1,s]];if(!s)return[[e,t]];var a=t.length>s.length?t:s,u=t.length>s.length?s:t,c=a.indexOf(u);if(-1!=c)return l=[[1,a.substring(0,c)],[0,u],[1,a.substring(c+u.length)]],t.length>s.length&&(l[0][0]=l[2][0]=e),l;if(1==u.length)return[[e,t],[1,s]];var h=function(t,e){var r=t.length>e.length?t:e,n=t.length>e.length?e:t;if(r.length<4||2*n.length<r.length)return null;function s(t,e,r){for(var n,s,l,a,u=t.substring(r,r+Math.floor(t.length/4)),c=-1,h="";-1!=(c=e.indexOf(u,c+1));){var f=i(t.substring(r),e.substring(c)),p=o(t.substring(0,r),e.substring(0,c));h.length<p+f&&(h=e.substring(c-p,c)+e.substring(c,c+f),n=t.substring(0,r-p),s=t.substring(r+f),l=e.substring(0,c-p),a=e.substring(c+f))}return 2*h.length>=t.length?[n,s,l,a,h]:null}var l,a,u,c,h,f=s(r,n,Math.ceil(r.length/4)),p=s(r,n,Math.ceil(r.length/2));if(!f&&!p)return null;l=p?f&&f[4].length>p[4].length?f:p:f;t.length>e.length?(a=l[0],u=l[1],c=l[2],h=l[3]):(c=l[0],h=l[1],a=l[2],u=l[3]);var d=l[4];return[a,u,c,h,d]}(t,s);if(h){var f=h[0],p=h[1],d=h[2],y=h[3],g=h[4],m=r(f,d),b=r(p,y);return m.concat([[0,g]],b)}return function(t,r){for(var i=t.length,o=r.length,s=Math.ceil((i+o)/2),l=s,a=2*s,u=new Array(a),c=new Array(a),h=0;h<a;h++)u[h]=-1,c[h]=-1;u[l+1]=0,c[l+1]=0;for(var f=i-o,p=f%2!=0,d=0,y=0,g=0,m=0,b=0;b<s;b++){for(var v=-b+d;v<=b-y;v+=2){for(var E=l+v,A=(T=v==-b||v!=b&&u[E-1]<u[E+1]?u[E+1]:u[E-1]+1)-v;T<i&&A<o&&t.charAt(T)==r.charAt(A);)T++,A++;if(u[E]=T,T>i)y+=2;else if(A>o)d+=2;else if(p){if((w=l+f-v)>=0&&w<a&&-1!=c[w])if(T>=(x=i-c[w]))return n(t,r,T,A)}}for(var N=-b+g;N<=b-m;N+=2){for(var x,w=l+N,S=(x=N==-b||N!=b&&c[w-1]<c[w+1]?c[w+1]:c[w-1]+1)-N;x<i&&S<o&&t.charAt(i-x-1)==r.charAt(o-S-1);)x++,S++;if(c[w]=x,x>i)m+=2;else if(S>o)g+=2;else if(!p){if((E=l+f-N)>=0&&E<a&&-1!=u[E]){var T;A=l+(T=u[E])-E;if(T>=(x=i-x))return n(t,r,T,A)}}}}return[[e,t],[1,r]]}(t,s)}(t=t.substring(0,t.length-c),l=l.substring(0,l.length-c));return h&&p.unshift([0,h]),f&&p.push([0,f]),s(p),null!=u&&(p=function(t,r){var n=function(t,r){if(0===r)return[0,t];for(var n=0,i=0;i<t.length;i++){var o=t[i];if(o[0]===e||0===o[0]){var s=n+o[1].length;if(r===s)return[i+1,t];if(r<s){t=t.slice();var l=r-n,a=[o[0],o[1].slice(0,l)],u=[o[0],o[1].slice(l)];return t.splice(i,1,a,u),[i+1,t]}n=s}}throw new Error("cursor_pos is out of bounds!")}(t,r),i=n[1],o=n[0],s=i[o],l=i[o+1];if(null==s)return t;if(0!==s[0])return t;if(null!=l&&s[1]+l[1]===l[1]+s[1])return i.splice(o,2,l,s),a(i,o,2);if(null!=l&&0===l[1].indexOf(s[1])){i.splice(o,2,[l[0],s[1]],[0,s[1]]);var u=l[1].slice(s[1].length);return u.length>0&&i.splice(o+2,0,[l[0],u]),a(i,o,3)}return t}(p,u)),p=function(t){for(var r=!1,n=function(t){return t.charCodeAt(0)>=56320&&t.charCodeAt(0)<=57343},i=function(t){return t.charCodeAt(t.length-1)>=55296&&t.charCodeAt(t.length-1)<=56319},o=2;o<t.length;o+=1)0===t[o-2][0]&&i(t[o-2][1])&&t[o-1][0]===e&&n(t[o-1][1])&&1===t[o][0]&&n(t[o][1])&&(r=!0,t[o-1][1]=t[o-2][1].slice(-1)+t[o-1][1],t[o][1]=t[o-2][1].slice(-1)+t[o][1],t[o-2][1]=t[o-2][1].slice(0,-1));if(!r)return t;var s=[];for(o=0;o<t.length;o+=1)t[o][1].length>0&&s.push(t[o]);return s}(p)}function n(t,e,n,i){var o=t.substring(0,n),s=e.substring(0,i),l=t.substring(n),a=e.substring(i),u=r(o,s),c=r(l,a);return u.concat(c)}function i(t,e){if(!t||!e||t.charAt(0)!=e.charAt(0))return 0;for(var r=0,n=Math.min(t.length,e.length),i=n,o=0;r<i;)t.substring(o,i)==e.substring(o,i)?o=r=i:n=i,i=Math.floor((n-r)/2+r);return i}function o(t,e){if(!t||!e||t.charAt(t.length-1)!=e.charAt(e.length-1))return 0;for(var r=0,n=Math.min(t.length,e.length),i=n,o=0;r<i;)t.substring(t.length-i,t.length-o)==e.substring(e.length-i,e.length-o)?o=r=i:n=i,i=Math.floor((n-r)/2+r);return i}function s(t){t.push([0,""]);for(var r,n=0,l=0,a=0,u="",c="";n<t.length;)switch(t[n][0]){case 1:a++,c+=t[n][1],n++;break;case e:l++,u+=t[n][1],n++;break;case 0:l+a>1?(0!==l&&0!==a&&(0!==(r=i(c,u))&&(n-l-a>0&&0==t[n-l-a-1][0]?t[n-l-a-1][1]+=c.substring(0,r):(t.splice(0,0,[0,c.substring(0,r)]),n++),c=c.substring(r),u=u.substring(r)),0!==(r=o(c,u))&&(t[n][1]=c.substring(c.length-r)+t[n][1],c=c.substring(0,c.length-r),u=u.substring(0,u.length-r))),0===l?t.splice(n-a,l+a,[1,c]):0===a?t.splice(n-l,l+a,[e,u]):t.splice(n-l-a,l+a,[e,u],[1,c]),n=n-l-a+(l?1:0)+(a?1:0)+1):0!==n&&0==t[n-1][0]?(t[n-1][1]+=t[n][1],t.splice(n,1)):n++,a=0,l=0,u="",c=""}""===t[t.length-1][1]&&t.pop();var h=!1;for(n=1;n<t.length-1;)0==t[n-1][0]&&0==t[n+1][0]&&(t[n][1].substring(t[n][1].length-t[n-1][1].length)==t[n-1][1]?(t[n][1]=t[n-1][1]+t[n][1].substring(0,t[n][1].length-t[n-1][1].length),t[n+1][1]=t[n-1][1]+t[n+1][1],t.splice(n-1,1),h=!0):t[n][1].substring(0,t[n+1][1].length)==t[n+1][1]&&(t[n-1][1]+=t[n+1][1],t[n][1]=t[n][1].substring(t[n+1][1].length)+t[n+1][1],t.splice(n+1,1),h=!0)),n++;h&&s(t)}var l=r;function a(t,e,r){for(var n=e+r-1;n>=0&&n>=e-1;n--)if(n+1<t.length){var i=t[n],o=t[n+1];i[0]===o[1]&&t.splice(n,2,[i[0],i[1]+o[1]])}return t}l.INSERT=1,l.DELETE=e,l.EQUAL=0,t.exports=l},4284:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/align-center.svg?f9afebbb6ae4c2964aa7cb35a8eb0d9d"},3249:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/align-justify.svg?90285f1f11db1912e9645c4a5e525344"},7778:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/align-left.svg?0f8ad7994ca19d6495042555af243eef"},1394:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/align-right.svg?626a3d25131f64ad41bfff6ad1ef10f5"},4188:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/background.svg?82e25f0bd823d4d4fb1e7f4ab0a78ff8"},1364:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/blockquote.svg?928aa5af401fb29fa07515a942ddd4d4"},6:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/bold.svg?7781b6114a3fb65a98f0b178c0d67578"},764:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/clean.svg?d59691df45537ae1a2637d373cdb3c90"},8737:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/code.svg?ea85b5c2863ee647d7bf543564349f8d"},761:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/color.svg?6c2b4048a0fa0cd5f2c5d920eb95ee48"},7073:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/direction-ltr.svg?d8052e6399cfca6a8a71de21b82bad55"},377:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/direction-rtl.svg?1375883b2f1e6de4a4621aca550cbd1d"},6861:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/float-center.svg?5793f183d1a93dc6f65ee9872c887088"},1911:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/float-full.svg?928ea0b8deb9e17786f2bbcd77324de2"},9378:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/float-left.svg?917812e3f874fe7614bdc5302f157012"},6824:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/float-right.svg?a595de253808219158737e11e9172a1a"},5377:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/formula.svg?513e689177d9c7b25d1f232b2497570c"},1239:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/header-2.svg?34914793e4453a1d65d78b933b421fce"},2390:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/header.svg?8c2dc93d4be101f76bae77761ec90c8e"},4485:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/image.svg?bffb79ce0fc8b41e9e6ce90bea00618b"},2195:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/indent.svg?b5fc7f81a004c4855833c500b0c538db"},3225:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/italic.svg?ff0ddc3f7d3244531d0a87389f6e151a"},895:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/link.svg?5c302e73950bc52c1afb8cf4f3ceb707"},1815:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/list-bullet.svg?cb92933c891e9914f1ac99ea79305cd4"},6097:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/list-check.svg?b70fb56c61cdc4dfdacbc1d7914368a6"},6929:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/list-ordered.svg?3e184f964f06cafa0ae283d1ad5b6cd8"},4439:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/outdent.svg?dd7145d26d6ba4aed3ebd11dc181d507"},8497:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/strike.svg?248ad333a3ad0b651e533dfadb12dde0"},7664:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/subscript.svg?9d8ea7c3c97df4bc024f7dab9248f7ce"},448:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/superscript.svg?3bed5966c174cea3f1047990c82290a3"},5479:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/underline.svg?585c47324c8f9d8c076d8d7bb452efaa"},7981:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n="/images/vendor/quill/icons/video.svg?eaeee04ce09d795ae77deaff36281c80"},7648:t=>{"use strict";var e="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";t.exports=function(t){var o=this;if("function"!=typeof o||n.call(o)!==i)throw new TypeError(e+o);for(var s,l=r.call(arguments,1),a=function(){if(this instanceof s){var e=o.apply(this,l.concat(r.call(arguments)));return Object(e)===e?e:this}return o.apply(t,l.concat(r.call(arguments)))},u=Math.max(0,o.length-l.length),c=[],h=0;h<u;h++)c.push("$"+h);if(s=Function("binder","return function ("+c.join(",")+"){ return binder.apply(this,arguments); }")(a),o.prototype){var f=function(){};f.prototype=o.prototype,s.prototype=new f,f.prototype=null}return s}},8612:(t,e,r)=>{"use strict";var n=r(7648);t.exports=Function.prototype.bind||n},210:(t,e,r)=>{"use strict";var n,i=SyntaxError,o=Function,s=TypeError,l=function(t){try{return o('"use strict"; return ('+t+").constructor;")()}catch(t){}},a=Object.getOwnPropertyDescriptor;if(a)try{a({},"")}catch(t){a=null}var u=function(){throw new s},c=a?function(){try{return u}catch(t){try{return a(arguments,"callee").get}catch(t){return u}}}():u,h=r(1405)(),f=Object.getPrototypeOf||function(t){return t.__proto__},p={},d="undefined"==typeof Uint8Array?n:f(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":h?f([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":p,"%AsyncGenerator%":p,"%AsyncGeneratorFunction%":p,"%AsyncIteratorPrototype%":p,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":p,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":h?f(f([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&h?f((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&h?f((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":h?f(""[Symbol.iterator]()):n,"%Symbol%":h?Symbol:n,"%SyntaxError%":i,"%ThrowTypeError%":c,"%TypedArray%":d,"%TypeError%":s,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},g=function t(e){var r;if("%AsyncFunction%"===e)r=l("async function () {}");else if("%GeneratorFunction%"===e)r=l("function* () {}");else if("%AsyncGeneratorFunction%"===e)r=l("async function* () {}");else if("%AsyncGenerator%"===e){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===e){var i=t("%AsyncGenerator%");i&&(r=f(i.prototype))}return y[e]=r,r},m={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},b=r(8612),v=r(7642),E=b.call(Function.call,Array.prototype.concat),A=b.call(Function.apply,Array.prototype.splice),N=b.call(Function.call,String.prototype.replace),x=b.call(Function.call,String.prototype.slice),w=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,S=/\\(\\)?/g,T=function(t){var e=x(t,0,1),r=x(t,-1);if("%"===e&&"%"!==r)throw new i("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==e)throw new i("invalid intrinsic syntax, expected opening `%`");var n=[];return N(t,w,(function(t,e,r,i){n[n.length]=r?N(i,S,"$1"):e||t})),n},O=function(t,e){var r,n=t;if(v(m,n)&&(n="%"+(r=m[n])[0]+"%"),v(y,n)){var o=y[n];if(o===p&&(o=g(n)),void 0===o&&!e)throw new s("intrinsic "+t+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new i("intrinsic "+t+" does not exist!")};t.exports=function(t,e){if("string"!=typeof t||0===t.length)throw new s("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof e)throw new s('"allowMissing" argument must be a boolean');var r=T(t),n=r.length>0?r[0]:"",o=O("%"+n+"%",e),l=o.name,u=o.value,c=!1,h=o.alias;h&&(n=h[0],A(r,E([0,1],h)));for(var f=1,p=!0;f<r.length;f+=1){var d=r[f],g=x(d,0,1),m=x(d,-1);if(('"'===g||"'"===g||"`"===g||'"'===m||"'"===m||"`"===m)&&g!==m)throw new i("property names with quotes must have matching quotes");if("constructor"!==d&&p||(c=!0),v(y,l="%"+(n+="."+d)+"%"))u=y[l];else if(null!=u){if(!(d in u)){if(!e)throw new s("base intrinsic for "+t+" exists, but the property is not available.");return}if(a&&f+1>=r.length){var b=a(u,d);u=(p=!!b)&&"get"in b&&!("originalValue"in b.get)?b.get:u[d]}else p=v(u,d),u=u[d];p&&!c&&(y[l]=u)}}return u}},1405:(t,e,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,i=r(5419);t.exports=function(){return"function"==typeof n&&("function"==typeof Symbol&&("symbol"==typeof n("foo")&&("symbol"==typeof Symbol("bar")&&i())))}},5419:t=>{"use strict";t.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var t={},e=Symbol("test"),r=Object(e);if("string"==typeof e)return!1;if("[object Symbol]"!==Object.prototype.toString.call(e))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(e in t[e]=42,t)return!1;if("function"==typeof Object.keys&&0!==Object.keys(t).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(t).length)return!1;var n=Object.getOwnPropertySymbols(t);if(1!==n.length||n[0]!==e)return!1;if(!Object.prototype.propertyIsEnumerable.call(t,e))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var i=Object.getOwnPropertyDescriptor(t,e);if(42!==i.value||!0!==i.enumerable)return!1}return!0}},7642:(t,e,r)=>{"use strict";var n=r(8612);t.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},645:(t,e)=>{e.read=function(t,e,r,n,i){var o,s,l=8*i-n-1,a=(1<<l)-1,u=a>>1,c=-7,h=r?i-1:0,f=r?-1:1,p=t[e+h];for(h+=f,o=p&(1<<-c)-1,p>>=-c,c+=l;c>0;o=256*o+t[e+h],h+=f,c-=8);for(s=o&(1<<-c)-1,o>>=-c,c+=n;c>0;s=256*s+t[e+h],h+=f,c-=8);if(0===o)o=1-u;else{if(o===a)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,n),o-=u}return(p?-1:1)*s*Math.pow(2,o-n)},e.write=function(t,e,r,n,i,o){var s,l,a,u=8*o-i-1,c=(1<<u)-1,h=c>>1,f=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=n?0:o-1,d=n?1:-1,y=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(l=isNaN(e)?1:0,s=c):(s=Math.floor(Math.log(e)/Math.LN2),e*(a=Math.pow(2,-s))<1&&(s--,a*=2),(e+=s+h>=1?f/a:f*Math.pow(2,1-h))*a>=2&&(s++,a/=2),s+h>=c?(l=0,s=c):s+h>=1?(l=(e*a-1)*Math.pow(2,i),s+=h):(l=e*Math.pow(2,h-1)*Math.pow(2,i),s=0));i>=8;t[r+p]=255&l,p+=d,l/=256,i-=8);for(s=s<<i|l,u+=i;u>0;t[r+p]=255&s,p+=d,s/=256,u-=8);t[r+p-d]|=128*y}},2584:(t,e,r)=>{"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,i=r(1924)("Object.prototype.toString"),o=function(t){return!(n&&t&&"object"==typeof t&&Symbol.toStringTag in t)&&"[object Arguments]"===i(t)},s=function(t){return!!o(t)||null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Array]"!==i(t)&&"[object Function]"===i(t.callee)},l=function(){return o(arguments)}();o.isLegacyArguments=s,t.exports=l?o:s},8923:t=>{"use strict";var e=Date.prototype.getDay,r=Object.prototype.toString,n="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag;t.exports=function(t){return"object"==typeof t&&null!==t&&(n?function(t){try{return e.call(t),!0}catch(t){return!1}}(t):"[object Date]"===r.call(t))}},8420:(t,e,r)=>{"use strict";var n,i,o,s,l=r(1924),a=r(1405)()&&"symbol"==typeof Symbol.toStringTag;if(a){n=l("Object.prototype.hasOwnProperty"),i=l("RegExp.prototype.exec"),o={};var u=function(){throw o};s={toString:u,valueOf:u},"symbol"==typeof Symbol.toPrimitive&&(s[Symbol.toPrimitive]=u)}var c=l("Object.prototype.toString"),h=Object.getOwnPropertyDescriptor;t.exports=a?function(t){if(!t||"object"!=typeof t)return!1;var e=h(t,"lastIndex");if(!(e&&n(e,"value")))return!1;try{i(t,s)}catch(t){return t===o}}:function(t){return!(!t||"object"!=typeof t&&"function"!=typeof t)&&"[object RegExp]"===c(t)}},5826:t=>{var e={}.toString;t.exports=Array.isArray||function(t){return"[object Array]"==e.call(t)}},4244:t=>{"use strict";var e=function(t){return t!=t};t.exports=function(t,r){return 0===t&&0===r?1/t==1/r:t===r||!(!e(t)||!e(r))}},609:(t,e,r)=>{"use strict";var n=r(4289),i=r(5559),o=r(4244),s=r(5624),l=r(2281),a=i(s(),Object);n(a,{getPolyfill:s,implementation:o,shim:l}),t.exports=a},5624:(t,e,r)=>{"use strict";var n=r(4244);t.exports=function(){return"function"==typeof Object.is?Object.is:n}},2281:(t,e,r)=>{"use strict";var n=r(5624),i=r(4289);t.exports=function(){var t=n();return i(Object,{is:t},{is:function(){return Object.is!==t}}),t}},8987:(t,e,r)=>{"use strict";var n;if(!Object.keys){var i=Object.prototype.hasOwnProperty,o=Object.prototype.toString,s=r(1414),l=Object.prototype.propertyIsEnumerable,a=!l.call({toString:null},"toString"),u=l.call((function(){}),"prototype"),c=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],h=function(t){var e=t.constructor;return e&&e.prototype===t},f={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},p=function(){if("undefined"==typeof window)return!1;for(var t in window)try{if(!f["$"+t]&&i.call(window,t)&&null!==window[t]&&"object"==typeof window[t])try{h(window[t])}catch(t){return!0}}catch(t){return!0}return!1}();n=function(t){var e=null!==t&&"object"==typeof t,r="[object Function]"===o.call(t),n=s(t),l=e&&"[object String]"===o.call(t),f=[];if(!e&&!r&&!n)throw new TypeError("Object.keys called on a non-object");var d=u&&r;if(l&&t.length>0&&!i.call(t,0))for(var y=0;y<t.length;++y)f.push(String(y));if(n&&t.length>0)for(var g=0;g<t.length;++g)f.push(String(g));else for(var m in t)d&&"prototype"===m||!i.call(t,m)||f.push(String(m));if(a)for(var b=function(t){if("undefined"==typeof window||!p)return h(t);try{return h(t)}catch(t){return!1}}(t),v=0;v<c.length;++v)b&&"constructor"===c[v]||!i.call(t,c[v])||f.push(c[v]);return f}}t.exports=n},2215:(t,e,r)=>{"use strict";var n=Array.prototype.slice,i=r(1414),o=Object.keys,s=o?function(t){return o(t)}:r(8987),l=Object.keys;s.shim=function(){Object.keys?function(){var t=Object.keys(arguments);return t&&t.length===arguments.length}(1,2)||(Object.keys=function(t){return i(t)?l(n.call(t)):l(t)}):Object.keys=s;return Object.keys||s},t.exports=s},1414:t=>{"use strict";var e=Object.prototype.toString;t.exports=function(t){var r=e.call(t),n="[object Arguments]"===r;return n||(n="[object Array]"!==r&&null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Function]"===e.call(t.callee)),n}},347:function(t){var e;"undefined"!=typeof self&&self,e=function(){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var i=e[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:n})},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=9)}([function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(e){var r=this;return e="[Parchment] "+e,(r=t.call(this,e)||this).message=e,r.name=r.constructor.name,r}return i(e,t),e}(Error);e.ParchmentError=o;var s,l={},a={},u={},c={};function h(t,e){var r;if(void 0===e&&(e=s.ANY),"string"==typeof t)r=c[t]||l[t];else if(t instanceof Text||t.nodeType===Node.TEXT_NODE)r=c.text;else if("number"==typeof t)t&s.LEVEL&s.BLOCK?r=c.block:t&s.LEVEL&s.INLINE&&(r=c.inline);else if(t instanceof HTMLElement){var n=(t.getAttribute("class")||"").split(/\s+/);for(var i in n)if(r=a[n[i]])break;r=r||u[t.tagName]}return null==r?null:e&s.LEVEL&r.scope&&e&s.TYPE&r.scope?r:null}e.DATA_KEY="__blot",function(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"}(s=e.Scope||(e.Scope={})),e.create=function(t,e){var r=h(t);if(null==r)throw new o("Unable to create "+t+" blot");var n=r,i=t instanceof Node||t.nodeType===Node.TEXT_NODE?t:n.create(e);return new n(i,e)},e.find=function t(r,n){return void 0===n&&(n=!1),null==r?null:null!=r[e.DATA_KEY]?r[e.DATA_KEY].blot:n?t(r.parentNode,n):null},e.query=h,e.register=function t(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];if(e.length>1)return e.map((function(e){return t(e)}));var n=e[0];if("string"!=typeof n.blotName&&"string"!=typeof n.attrName)throw new o("Invalid definition");if("abstract"===n.blotName)throw new o("Cannot register abstract class");if(c[n.blotName||n.attrName]=n,"string"==typeof n.keyName)l[n.keyName]=n;else if(null!=n.className&&(a[n.className]=n),null!=n.tagName){Array.isArray(n.tagName)?n.tagName=n.tagName.map((function(t){return t.toUpperCase()})):n.tagName=n.tagName.toUpperCase();var i=Array.isArray(n.tagName)?n.tagName:[n.tagName];i.forEach((function(t){null!=u[t]&&null!=n.className||(u[t]=n)}))}return n}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=r(0),i=function(){function t(t,e,r){void 0===r&&(r={}),this.attrName=t,this.keyName=e;var i=n.Scope.TYPE&n.Scope.ATTRIBUTE;null!=r.scope?this.scope=r.scope&n.Scope.LEVEL|i:this.scope=n.Scope.ATTRIBUTE,null!=r.whitelist&&(this.whitelist=r.whitelist)}return t.keys=function(t){return[].map.call(t.attributes,(function(t){return t.name}))},t.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(t.setAttribute(this.keyName,e),!0)},t.prototype.canAdd=function(t,e){return null!=n.query(t,n.Scope.BLOT&(this.scope|n.Scope.TYPE))&&(null==this.whitelist||("string"==typeof e?this.whitelist.indexOf(e.replace(/["']/g,""))>-1:this.whitelist.indexOf(e)>-1))},t.prototype.remove=function(t){t.removeAttribute(this.keyName)},t.prototype.value=function(t){var e=t.getAttribute(this.keyName);return this.canAdd(t,e)&&e?e:""},t}();e.default=i},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(11),s=r(5),l=r(0),a=function(t){function e(e){var r=t.call(this,e)||this;return r.build(),r}return i(e,t),e.prototype.appendChild=function(t){this.insertBefore(t)},e.prototype.attach=function(){t.prototype.attach.call(this),this.children.forEach((function(t){t.attach()}))},e.prototype.build=function(){var t=this;this.children=new o.default,[].slice.call(this.domNode.childNodes).reverse().forEach((function(e){try{var r=u(e);t.insertBefore(r,t.children.head||void 0)}catch(t){if(t instanceof l.ParchmentError)return;throw t}}))},e.prototype.deleteAt=function(t,e){if(0===t&&e===this.length())return this.remove();this.children.forEachAt(t,e,(function(t,e,r){t.deleteAt(e,r)}))},e.prototype.descendant=function(t,r){var n=this.children.find(r),i=n[0],o=n[1];return null==t.blotName&&t(i)||null!=t.blotName&&i instanceof t?[i,o]:i instanceof e?i.descendant(t,o):[null,-1]},e.prototype.descendants=function(t,r,n){void 0===r&&(r=0),void 0===n&&(n=Number.MAX_VALUE);var i=[],o=n;return this.children.forEachAt(r,n,(function(r,n,s){(null==t.blotName&&t(r)||null!=t.blotName&&r instanceof t)&&i.push(r),r instanceof e&&(i=i.concat(r.descendants(t,n,o))),o-=s})),i},e.prototype.detach=function(){this.children.forEach((function(t){t.detach()})),t.prototype.detach.call(this)},e.prototype.formatAt=function(t,e,r,n){this.children.forEachAt(t,e,(function(t,e,i){t.formatAt(e,i,r,n)}))},e.prototype.insertAt=function(t,e,r){var n=this.children.find(t),i=n[0],o=n[1];if(i)i.insertAt(o,e,r);else{var s=null==r?l.create("text",e):l.create(e,r);this.appendChild(s)}},e.prototype.insertBefore=function(t,e){if(null!=this.statics.allowedChildren&&!this.statics.allowedChildren.some((function(e){return t instanceof e})))throw new l.ParchmentError("Cannot insert "+t.statics.blotName+" into "+this.statics.blotName);t.insertInto(this,e)},e.prototype.length=function(){return this.children.reduce((function(t,e){return t+e.length()}),0)},e.prototype.moveChildren=function(t,e){this.children.forEach((function(r){t.insertBefore(r,e)}))},e.prototype.optimize=function(e){if(t.prototype.optimize.call(this,e),0===this.children.length)if(null!=this.statics.defaultChild){var r=l.create(this.statics.defaultChild);this.appendChild(r),r.optimize(e)}else this.remove()},e.prototype.path=function(t,r){void 0===r&&(r=!1);var n=this.children.find(t,r),i=n[0],o=n[1],s=[[this,t]];return i instanceof e?s.concat(i.path(o,r)):(null!=i&&s.push([i,o]),s)},e.prototype.removeChild=function(t){this.children.remove(t)},e.prototype.replace=function(r){r instanceof e&&r.moveChildren(this),t.prototype.replace.call(this,r)},e.prototype.split=function(t,e){if(void 0===e&&(e=!1),!e){if(0===t)return this;if(t===this.length())return this.next}var r=this.clone();return this.parent.insertBefore(r,this.next),this.children.forEachAt(t,this.length(),(function(t,n,i){t=t.split(n,e),r.appendChild(t)})),r},e.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},e.prototype.update=function(t,e){var r=this,n=[],i=[];t.forEach((function(t){t.target===r.domNode&&"childList"===t.type&&(n.push.apply(n,t.addedNodes),i.push.apply(i,t.removedNodes))})),i.forEach((function(t){if(!(null!=t.parentNode&&"IFRAME"!==t.tagName&&document.body.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var e=l.find(t);null!=e&&(null!=e.domNode.parentNode&&e.domNode.parentNode!==r.domNode||e.detach())}})),n.filter((function(t){return t.parentNode==r.domNode})).sort((function(t,e){return t===e?0:t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1})).forEach((function(t){var e=null;null!=t.nextSibling&&(e=l.find(t.nextSibling));var n=u(t);n.next==e&&null!=n.next||(null!=n.parent&&n.parent.removeChild(r),r.insertBefore(n,e||void 0))}))},e}(s.default);function u(t){var e=l.find(t);if(null==e)try{e=l.create(t)}catch(r){e=l.create(l.Scope.INLINE),[].slice.call(t.childNodes).forEach((function(t){e.domNode.appendChild(t)})),t.parentNode&&t.parentNode.replaceChild(e.domNode,t),e.attach()}return e}e.default=a},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(1),s=r(6),l=r(2),a=r(0),u=function(t){function e(e){var r=t.call(this,e)||this;return r.attributes=new s.default(r.domNode),r}return i(e,t),e.formats=function(t){return"string"==typeof this.tagName||(Array.isArray(this.tagName)?t.tagName.toLowerCase():void 0)},e.prototype.format=function(t,e){var r=a.query(t);r instanceof o.default?this.attributes.attribute(r,e):e&&(null==r||t===this.statics.blotName&&this.formats()[t]===e||this.replaceWith(t,e))},e.prototype.formats=function(){var t=this.attributes.values(),e=this.statics.formats(this.domNode);return null!=e&&(t[this.statics.blotName]=e),t},e.prototype.replaceWith=function(e,r){var n=t.prototype.replaceWith.call(this,e,r);return this.attributes.copy(n),n},e.prototype.update=function(e,r){var n=this;t.prototype.update.call(this,e,r),e.some((function(t){return t.target===n.domNode&&"attributes"===t.type}))&&this.attributes.build()},e.prototype.wrap=function(r,n){var i=t.prototype.wrap.call(this,r,n);return i instanceof e&&i.statics.scope===this.statics.scope&&this.attributes.move(i),i},e}(l.default);e.default=u},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(5),s=r(0),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.value=function(t){return!0},e.prototype.index=function(t,e){return this.domNode===t||this.domNode.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(e,1):-1},e.prototype.position=function(t,e){var r=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return t>0&&(r+=1),[this.parent.domNode,r]},e.prototype.value=function(){return(t={})[this.statics.blotName]=this.statics.value(this.domNode)||!0,t;var t},e.scope=s.Scope.INLINE_BLOT,e}(o.default);e.default=l},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=r(0),i=function(){function t(t){this.domNode=t,this.domNode[n.DATA_KEY]={blot:this}}return Object.defineProperty(t.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),t.create=function(t){if(null==this.tagName)throw new n.ParchmentError("Blot definition missing tagName");var e;return Array.isArray(this.tagName)?("string"==typeof t&&(t=t.toUpperCase(),parseInt(t).toString()===t&&(t=parseInt(t))),e="number"==typeof t?document.createElement(this.tagName[t-1]):this.tagName.indexOf(t)>-1?document.createElement(t):document.createElement(this.tagName[0])):e=document.createElement(this.tagName),this.className&&e.classList.add(this.className),e},t.prototype.attach=function(){null!=this.parent&&(this.scroll=this.parent.scroll)},t.prototype.clone=function(){var t=this.domNode.cloneNode(!1);return n.create(t)},t.prototype.detach=function(){null!=this.parent&&this.parent.removeChild(this),delete this.domNode[n.DATA_KEY]},t.prototype.deleteAt=function(t,e){this.isolate(t,e).remove()},t.prototype.formatAt=function(t,e,r,i){var o=this.isolate(t,e);if(null!=n.query(r,n.Scope.BLOT)&&i)o.wrap(r,i);else if(null!=n.query(r,n.Scope.ATTRIBUTE)){var s=n.create(this.statics.scope);o.wrap(s),s.format(r,i)}},t.prototype.insertAt=function(t,e,r){var i=null==r?n.create("text",e):n.create(e,r),o=this.split(t);this.parent.insertBefore(i,o)},t.prototype.insertInto=function(t,e){void 0===e&&(e=null),null!=this.parent&&this.parent.children.remove(this);var r=null;t.children.insertBefore(this,e),null!=e&&(r=e.domNode),this.domNode.parentNode==t.domNode&&this.domNode.nextSibling==r||t.domNode.insertBefore(this.domNode,r),this.parent=t,this.attach()},t.prototype.isolate=function(t,e){var r=this.split(t);return r.split(e),r},t.prototype.length=function(){return 1},t.prototype.offset=function(t){return void 0===t&&(t=this.parent),null==this.parent||this==t?0:this.parent.children.offset(this)+this.parent.offset(t)},t.prototype.optimize=function(t){null!=this.domNode[n.DATA_KEY]&&delete this.domNode[n.DATA_KEY].mutations},t.prototype.remove=function(){null!=this.domNode.parentNode&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},t.prototype.replace=function(t){null!=t.parent&&(t.parent.insertBefore(this,t.next),t.remove())},t.prototype.replaceWith=function(t,e){var r="string"==typeof t?n.create(t,e):t;return r.replace(this),r},t.prototype.split=function(t,e){return 0===t?this:this.next},t.prototype.update=function(t,e){},t.prototype.wrap=function(t,e){var r="string"==typeof t?n.create(t,e):t;return null!=this.parent&&this.parent.insertBefore(r,this.next),r.appendChild(this),r},t.blotName="abstract",t}();e.default=i},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=r(1),i=r(7),o=r(8),s=r(0),l=function(){function t(t){this.attributes={},this.domNode=t,this.build()}return t.prototype.attribute=function(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])},t.prototype.build=function(){var t=this;this.attributes={};var e=n.default.keys(this.domNode),r=i.default.keys(this.domNode),l=o.default.keys(this.domNode);e.concat(r).concat(l).forEach((function(e){var r=s.query(e,s.Scope.ATTRIBUTE);r instanceof n.default&&(t.attributes[r.attrName]=r)}))},t.prototype.copy=function(t){var e=this;Object.keys(this.attributes).forEach((function(r){var n=e.attributes[r].value(e.domNode);t.format(r,n)}))},t.prototype.move=function(t){var e=this;this.copy(t),Object.keys(this.attributes).forEach((function(t){e.attributes[t].remove(e.domNode)})),this.attributes={}},t.prototype.values=function(){var t=this;return Object.keys(this.attributes).reduce((function(e,r){return e[r]=t.attributes[r].value(t.domNode),e}),{})},t}();e.default=l},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});function o(t,e){return(t.getAttribute("class")||"").split(/\s+/).filter((function(t){return 0===t.indexOf(e+"-")}))}Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.keys=function(t){return(t.getAttribute("class")||"").split(/\s+/).map((function(t){return t.split("-").slice(0,-1).join("-")}))},e.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(this.remove(t),t.classList.add(this.keyName+"-"+e),!0)},e.prototype.remove=function(t){o(t,this.keyName).forEach((function(e){t.classList.remove(e)})),0===t.classList.length&&t.removeAttribute("class")},e.prototype.value=function(t){var e=(o(t,this.keyName)[0]||"").slice(this.keyName.length+1);return this.canAdd(t,e)?e:""},e}(r(1).default);e.default=s},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});function o(t){var e=t.split("-"),r=e.slice(1).map((function(t){return t[0].toUpperCase()+t.slice(1)})).join("");return e[0]+r}Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.keys=function(t){return(t.getAttribute("style")||"").split(";").map((function(t){return t.split(":")[0].trim()}))},e.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(t.style[o(this.keyName)]=e,!0)},e.prototype.remove=function(t){t.style[o(this.keyName)]="",t.getAttribute("style")||t.removeAttribute("style")},e.prototype.value=function(t){var e=t.style[o(this.keyName)];return this.canAdd(t,e)?e:""},e}(r(1).default);e.default=s},function(t,e,r){t.exports=r(10)},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=r(2),i=r(3),o=r(4),s=r(12),l=r(13),a=r(14),u=r(15),c=r(16),h=r(1),f=r(7),p=r(8),d=r(6),y=r(0),g={Scope:y.Scope,create:y.create,find:y.find,query:y.query,register:y.register,Container:n.default,Format:i.default,Leaf:o.default,Embed:u.default,Scroll:s.default,Block:a.default,Inline:l.default,Text:c.default,Attributor:{Attribute:h.default,Class:f.default,Style:p.default,Store:d.default}};e.default=g},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){function t(){this.head=this.tail=null,this.length=0}return t.prototype.append=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.insertBefore(t[0],null),t.length>1&&this.append.apply(this,t.slice(1))},t.prototype.contains=function(t){for(var e,r=this.iterator();e=r();)if(e===t)return!0;return!1},t.prototype.insertBefore=function(t,e){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)},t.prototype.offset=function(t){for(var e=0,r=this.head;null!=r;){if(r===t)return e;e+=r.length(),r=r.next}return-1},t.prototype.remove=function(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)},t.prototype.iterator=function(t){return void 0===t&&(t=this.head),function(){var e=t;return null!=t&&(t=t.next),e}},t.prototype.find=function(t,e){void 0===e&&(e=!1);for(var r,n=this.iterator();r=n();){var i=r.length();if(t<i||e&&t===i&&(null==r.next||0!==r.next.length()))return[r,t];t-=i}return[null,0]},t.prototype.forEach=function(t){for(var e,r=this.iterator();e=r();)t(e)},t.prototype.forEachAt=function(t,e,r){if(!(e<=0))for(var n,i=this.find(t),o=i[0],s=t-i[1],l=this.iterator(o);(n=l())&&s<t+e;){var a=n.length();t>s?r(n,t-s,Math.min(e,s+a-t)):r(n,0,Math.min(a,t+e-s)),s+=a}},t.prototype.map=function(t){return this.reduce((function(e,r){return e.push(t(r)),e}),[])},t.prototype.reduce=function(t,e){for(var r,n=this.iterator();r=n();)e=t(e,r);return e},t}();e.default=n},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(2),s=r(0),l={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},a=function(t){function e(e){var r=t.call(this,e)||this;return r.scroll=r,r.observer=new MutationObserver((function(t){r.update(t)})),r.observer.observe(r.domNode,l),r.attach(),r}return i(e,t),e.prototype.detach=function(){t.prototype.detach.call(this),this.observer.disconnect()},e.prototype.deleteAt=function(e,r){this.update(),0===e&&r===this.length()?this.children.forEach((function(t){t.remove()})):t.prototype.deleteAt.call(this,e,r)},e.prototype.formatAt=function(e,r,n,i){this.update(),t.prototype.formatAt.call(this,e,r,n,i)},e.prototype.insertAt=function(e,r,n){this.update(),t.prototype.insertAt.call(this,e,r,n)},e.prototype.optimize=function(e,r){var n=this;void 0===e&&(e=[]),void 0===r&&(r={}),t.prototype.optimize.call(this,r);for(var i=[].slice.call(this.observer.takeRecords());i.length>0;)e.push(i.pop());for(var l=function(t,e){void 0===e&&(e=!0),null!=t&&t!==n&&null!=t.domNode.parentNode&&(null==t.domNode[s.DATA_KEY].mutations&&(t.domNode[s.DATA_KEY].mutations=[]),e&&l(t.parent))},a=function(t){null!=t.domNode[s.DATA_KEY]&&null!=t.domNode[s.DATA_KEY].mutations&&(t instanceof o.default&&t.children.forEach(a),t.optimize(r))},u=e,c=0;u.length>0;c+=1){if(c>=100)throw new Error("[Parchment] Maximum optimize iterations reached");for(u.forEach((function(t){var e=s.find(t.target,!0);null!=e&&(e.domNode===t.target&&("childList"===t.type?(l(s.find(t.previousSibling,!1)),[].forEach.call(t.addedNodes,(function(t){var e=s.find(t,!1);l(e,!1),e instanceof o.default&&e.children.forEach((function(t){l(t,!1)}))}))):"attributes"===t.type&&l(e.prev)),l(e))})),this.children.forEach(a),i=(u=[].slice.call(this.observer.takeRecords())).slice();i.length>0;)e.push(i.pop())}},e.prototype.update=function(e,r){var n=this;void 0===r&&(r={}),(e=e||this.observer.takeRecords()).map((function(t){var e=s.find(t.target,!0);return null==e?null:null==e.domNode[s.DATA_KEY].mutations?(e.domNode[s.DATA_KEY].mutations=[t],e):(e.domNode[s.DATA_KEY].mutations.push(t),null)})).forEach((function(t){null!=t&&t!==n&&null!=t.domNode[s.DATA_KEY]&&t.update(t.domNode[s.DATA_KEY].mutations||[],r)})),null!=this.domNode[s.DATA_KEY].mutations&&t.prototype.update.call(this,this.domNode[s.DATA_KEY].mutations,r),this.optimize(e,r)},e.blotName="scroll",e.defaultChild="block",e.scope=s.Scope.BLOCK_BLOT,e.tagName="DIV",e}(o.default);e.default=a},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(3),s=r(0),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.formats=function(r){if(r.tagName!==e.tagName)return t.formats.call(this,r)},e.prototype.format=function(r,n){var i=this;r!==this.statics.blotName||n?t.prototype.format.call(this,r,n):(this.children.forEach((function(t){t instanceof o.default||(t=t.wrap(e.blotName,!0)),i.attributes.copy(t)})),this.unwrap())},e.prototype.formatAt=function(e,r,n,i){null!=this.formats()[n]||s.query(n,s.Scope.ATTRIBUTE)?this.isolate(e,r).format(n,i):t.prototype.formatAt.call(this,e,r,n,i)},e.prototype.optimize=function(r){t.prototype.optimize.call(this,r);var n=this.formats();if(0===Object.keys(n).length)return this.unwrap();var i=this.next;i instanceof e&&i.prev===this&&function(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(var r in t)if(t[r]!==e[r])return!1;return!0}(n,i.formats())&&(i.moveChildren(this),i.remove())},e.blotName="inline",e.scope=s.Scope.INLINE_BLOT,e.tagName="SPAN",e}(o.default);e.default=l},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(3),s=r(0),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.formats=function(r){var n=s.query(e.blotName).tagName;if(r.tagName!==n)return t.formats.call(this,r)},e.prototype.format=function(r,n){null!=s.query(r,s.Scope.BLOCK)&&(r!==this.statics.blotName||n?t.prototype.format.call(this,r,n):this.replaceWith(e.blotName))},e.prototype.formatAt=function(e,r,n,i){null!=s.query(n,s.Scope.BLOCK)?this.format(n,i):t.prototype.formatAt.call(this,e,r,n,i)},e.prototype.insertAt=function(e,r,n){if(null==n||null!=s.query(r,s.Scope.INLINE))t.prototype.insertAt.call(this,e,r,n);else{var i=this.split(e),o=s.create(r,n);i.parent.insertBefore(o,i)}},e.prototype.update=function(e,r){navigator.userAgent.match(/Trident/)?this.build():t.prototype.update.call(this,e,r)},e.blotName="block",e.scope=s.Scope.BLOCK_BLOT,e.tagName="P",e}(o.default);e.default=l},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.formats=function(t){},e.prototype.format=function(e,r){t.prototype.formatAt.call(this,0,this.length(),e,r)},e.prototype.formatAt=function(e,r,n,i){0===e&&r===this.length()?this.format(n,i):t.prototype.formatAt.call(this,e,r,n,i)},e.prototype.formats=function(){return this.statics.formats(this.domNode)},e}(r(4).default);e.default=o},function(t,e,r){"use strict";var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},function(t,e){function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var o=r(4),s=r(0),l=function(t){function e(e){var r=t.call(this,e)||this;return r.text=r.statics.value(r.domNode),r}return i(e,t),e.create=function(t){return document.createTextNode(t)},e.value=function(t){var e=t.data;return e.normalize&&(e=e.normalize()),e},e.prototype.deleteAt=function(t,e){this.domNode.data=this.text=this.text.slice(0,t)+this.text.slice(t+e)},e.prototype.index=function(t,e){return this.domNode===t?e:-1},e.prototype.insertAt=function(e,r,n){null==n?(this.text=this.text.slice(0,e)+r+this.text.slice(e),this.domNode.data=this.text):t.prototype.insertAt.call(this,e,r,n)},e.prototype.length=function(){return this.text.length},e.prototype.optimize=function(r){t.prototype.optimize.call(this,r),this.text=this.statics.value(this.domNode),0===this.text.length?this.remove():this.next instanceof e&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},e.prototype.position=function(t,e){return void 0===e&&(e=!1),[this.domNode,t]},e.prototype.split=function(t,e){if(void 0===e&&(e=!1),!e){if(0===t)return this;if(t===this.length())return this.next}var r=s.create(this.domNode.splitText(t));return this.parent.insertBefore(r,this.next),this.text=this.statics.value(this.domNode),r},e.prototype.update=function(t,e){var r=this;t.some((function(t){return"characterData"===t.type&&t.target===r.domNode}))&&(this.text=this.statics.value(this.domNode))},e.prototype.value=function(){return this.text},e.blotName="text",e.scope=s.Scope.INLINE_BLOT,e}(o.default);e.default=l}])},t.exports=e()},4175:(t,e,r)=>{var n=r(7529),i=r(251),o=r(4470),s=r(6910),l=String.fromCharCode(0),a=function(t){Array.isArray(t)?this.ops=t:null!=t&&Array.isArray(t.ops)?this.ops=t.ops:this.ops=[]};a.prototype.insert=function(t,e){var r={};return 0===t.length?this:(r.insert=t,null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(r.attributes=e),this.push(r))},a.prototype.delete=function(t){return t<=0?this:this.push({delete:t})},a.prototype.retain=function(t,e){if(t<=0)return this;var r={retain:t};return null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(r.attributes=e),this.push(r)},a.prototype.push=function(t){var e=this.ops.length,r=this.ops[e-1];if(t=o(!0,{},t),"object"==typeof r){if("number"==typeof t.delete&&"number"==typeof r.delete)return this.ops[e-1]={delete:r.delete+t.delete},this;if("number"==typeof r.delete&&null!=t.insert&&(e-=1,"object"!=typeof(r=this.ops[e-1])))return this.ops.unshift(t),this;if(i(t.attributes,r.attributes)){if("string"==typeof t.insert&&"string"==typeof r.insert)return this.ops[e-1]={insert:r.insert+t.insert},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this;if("number"==typeof t.retain&&"number"==typeof r.retain)return this.ops[e-1]={retain:r.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},a.prototype.chop=function(){var t=this.ops[this.ops.length-1];return t&&t.retain&&!t.attributes&&this.ops.pop(),this},a.prototype.filter=function(t){return this.ops.filter(t)},a.prototype.forEach=function(t){this.ops.forEach(t)},a.prototype.map=function(t){return this.ops.map(t)},a.prototype.partition=function(t){var e=[],r=[];return this.forEach((function(n){(t(n)?e:r).push(n)})),[e,r]},a.prototype.reduce=function(t,e){return this.ops.reduce(t,e)},a.prototype.changeLength=function(){return this.reduce((function(t,e){return e.insert?t+s.length(e):e.delete?t-e.delete:t}),0)},a.prototype.length=function(){return this.reduce((function(t,e){return t+s.length(e)}),0)},a.prototype.slice=function(t,e){t=t||0,"number"!=typeof e&&(e=1/0);for(var r=[],n=s.iterator(this.ops),i=0;i<e&&n.hasNext();){var o;i<t?o=n.next(t-i):(o=n.next(e-i),r.push(o)),i+=s.length(o)}return new a(r)},a.prototype.compose=function(t){var e=s.iterator(this.ops),r=s.iterator(t.ops),n=[],o=r.peek();if(null!=o&&"number"==typeof o.retain&&null==o.attributes){for(var l=o.retain;"insert"===e.peekType()&&e.peekLength()<=l;)l-=e.peekLength(),n.push(e.next());o.retain-l>0&&r.next(o.retain-l)}for(var u=new a(n);e.hasNext()||r.hasNext();)if("insert"===r.peekType())u.push(r.next());else if("delete"===e.peekType())u.push(e.next());else{var c=Math.min(e.peekLength(),r.peekLength()),h=e.next(c),f=r.next(c);if("number"==typeof f.retain){var p={};"number"==typeof h.retain?p.retain=c:p.insert=h.insert;var d=s.attributes.compose(h.attributes,f.attributes,"number"==typeof h.retain);if(d&&(p.attributes=d),u.push(p),!r.hasNext()&&i(u.ops[u.ops.length-1],p)){var y=new a(e.rest());return u.concat(y).chop()}}else"number"==typeof f.delete&&"number"==typeof h.retain&&u.push(f)}return u.chop()},a.prototype.concat=function(t){var e=new a(this.ops.slice());return t.ops.length>0&&(e.push(t.ops[0]),e.ops=e.ops.concat(t.ops.slice(1))),e},a.prototype.diff=function(t,e){if(this.ops===t.ops)return new a;var r=[this,t].map((function(e){return e.map((function(r){if(null!=r.insert)return"string"==typeof r.insert?r.insert:l;throw new Error("diff() called "+(e===t?"on":"with")+" non-document")})).join("")})),o=new a,u=n(r[0],r[1],e),c=s.iterator(this.ops),h=s.iterator(t.ops);return u.forEach((function(t){for(var e=t[1].length;e>0;){var r=0;switch(t[0]){case n.INSERT:r=Math.min(h.peekLength(),e),o.push(h.next(r));break;case n.DELETE:r=Math.min(e,c.peekLength()),c.next(r),o.delete(r);break;case n.EQUAL:r=Math.min(c.peekLength(),h.peekLength(),e);var l=c.next(r),a=h.next(r);i(l.insert,a.insert)?o.retain(r,s.attributes.diff(l.attributes,a.attributes)):o.push(a).delete(r)}e-=r}})),o.chop()},a.prototype.eachLine=function(t,e){e=e||"\n";for(var r=s.iterator(this.ops),n=new a,i=0;r.hasNext();){if("insert"!==r.peekType())return;var o=r.peek(),l=s.length(o)-r.peekLength(),u="string"==typeof o.insert?o.insert.indexOf(e,l)-l:-1;if(u<0)n.push(r.next());else if(u>0)n.push(r.next(u));else{if(!1===t(n,r.next(1).attributes||{},i))return;i+=1,n=new a}}n.length()>0&&t(n,{},i)},a.prototype.transform=function(t,e){if(e=!!e,"number"==typeof t)return this.transformPosition(t,e);for(var r=s.iterator(this.ops),n=s.iterator(t.ops),i=new a;r.hasNext()||n.hasNext();)if("insert"!==r.peekType()||!e&&"insert"===n.peekType())if("insert"===n.peekType())i.push(n.next());else{var o=Math.min(r.peekLength(),n.peekLength()),l=r.next(o),u=n.next(o);if(l.delete)continue;u.delete?i.push(u):i.retain(o,s.attributes.transform(l.attributes,u.attributes,e))}else i.retain(s.length(r.next()));return i.chop()},a.prototype.transformPosition=function(t,e){e=!!e;for(var r=s.iterator(this.ops),n=0;r.hasNext()&&n<=t;){var i=r.peekLength(),o=r.peekType();r.next(),"delete"!==o?("insert"===o&&(n<t||!e)&&(t+=i),n+=i):t-=Math.min(i,t-n)}return t},t.exports=a},6910:(t,e,r)=>{var n=r(251),i=r(4470),o={attributes:{compose:function(t,e,r){"object"!=typeof t&&(t={}),"object"!=typeof e&&(e={});var n=i(!0,{},e);for(var o in r||(n=Object.keys(n).reduce((function(t,e){return null!=n[e]&&(t[e]=n[e]),t}),{})),t)void 0!==t[o]&&void 0===e[o]&&(n[o]=t[o]);return Object.keys(n).length>0?n:void 0},diff:function(t,e){"object"!=typeof t&&(t={}),"object"!=typeof e&&(e={});var r=Object.keys(t).concat(Object.keys(e)).reduce((function(r,i){return n(t[i],e[i])||(r[i]=void 0===e[i]?null:e[i]),r}),{});return Object.keys(r).length>0?r:void 0},transform:function(t,e,r){if("object"!=typeof t)return e;if("object"==typeof e){if(!r)return e;var n=Object.keys(e).reduce((function(r,n){return void 0===t[n]&&(r[n]=e[n]),r}),{});return Object.keys(n).length>0?n:void 0}}},iterator:function(t){return new s(t)},length:function(t){return"number"==typeof t.delete?t.delete:"number"==typeof t.retain?t.retain:"string"==typeof t.insert?t.insert.length:1}};function s(t){this.ops=t,this.index=0,this.offset=0}s.prototype.hasNext=function(){return this.peekLength()<1/0},s.prototype.next=function(t){t||(t=1/0);var e=this.ops[this.index];if(e){var r=this.offset,n=o.length(e);if(t>=n-r?(t=n-r,this.index+=1,this.offset=0):this.offset+=t,"number"==typeof e.delete)return{delete:t};var i={};return e.attributes&&(i.attributes=e.attributes),"number"==typeof e.retain?i.retain=t:"string"==typeof e.insert?i.insert=e.insert.substr(r,t):i.insert=e.insert,i}return{retain:1/0}},s.prototype.peek=function(){return this.ops[this.index]},s.prototype.peekLength=function(){return this.ops[this.index]?o.length(this.ops[this.index])-this.offset:1/0},s.prototype.peekType=function(){return this.ops[this.index]?"number"==typeof this.ops[this.index].delete?"delete":"number"==typeof this.ops[this.index].retain?"retain":"insert":"retain"},s.prototype.rest=function(){if(this.hasNext()){if(0===this.offset)return this.ops.slice(this.index);var t=this.offset,e=this.index,r=this.next(),n=this.ops.slice(this.index);return this.offset=t,this.index=e,[r].concat(n)}return[]},t.exports=o},8299:()=>{let t=document.createElement("div");if(t.classList.toggle("test-class",!1),t.classList.contains("test-class")){let t=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(e,r){return arguments.length>1&&!this.contains(e)==!r?r:t.call(this,e)}}String.prototype.startsWith||(String.prototype.startsWith=function(t,e){return e=e||0,this.substr(e,t.length)===t}),String.prototype.endsWith||(String.prototype.endsWith=function(t,e){var r=this.toString();("number"!=typeof e||!isFinite(e)||Math.floor(e)!==e||e>r.length)&&(e=r.length),e-=t.length;var n=r.indexOf(t,e);return-1!==n&&n===e}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(t){if(null===this)throw new TypeError("Array.prototype.find called on null or undefined");if("function"!=typeof t)throw new TypeError("predicate must be a function");for(var e,r=Object(this),n=r.length>>>0,i=arguments[1],o=0;o<n;o++)if(e=r[o],t.call(i,e,o,r))return e}}),document.addEventListener("DOMContentLoaded",(function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)}))},3964:(t,e,r)=>{t.exports={align:{"":r(7778),center:r(4284),right:r(1394),justify:r(3249)},background:r(4188),blockquote:r(1364),bold:r(6),clean:r(764),code:r(8737),"code-block":r(8737),color:r(761),direction:{"":r(7073),rtl:r(377)},float:{center:r(6861),full:r(1911),left:r(9378),right:r(6824)},formula:r(5377),header:{1:r(2390),2:r(1239)},italic:r(3225),image:r(4485),indent:{"+1":r(2195),"-1":r(4439)},link:r(895),list:{ordered:r(6929),bullet:r(1815),check:r(6097)},script:{sub:r(7664),super:r(448)},strike:r(8497),underline:r(5479),video:r(7981)}},3697:t=>{"use strict";var e=Object,r=TypeError;t.exports=function(){if(null!=this&&this!==e(this))throw new r("RegExp.prototype.flags getter called on non-object");var t="";return this.global&&(t+="g"),this.ignoreCase&&(t+="i"),this.multiline&&(t+="m"),this.dotAll&&(t+="s"),this.unicode&&(t+="u"),this.sticky&&(t+="y"),t}},2847:(t,e,r)=>{"use strict";var n=r(4289),i=r(5559),o=r(3697),s=r(1721),l=r(2753),a=i(o);n(a,{getPolyfill:s,implementation:o,shim:l}),t.exports=a},1721:(t,e,r)=>{"use strict";var n=r(3697),i=r(4289).supportsDescriptors,o=Object.getOwnPropertyDescriptor,s=TypeError;t.exports=function(){if(!i)throw new s("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");if("gim"===/a/gim.flags){var t=o(RegExp.prototype,"flags");if(t&&"function"==typeof t.get&&"boolean"==typeof/a/.dotAll)return t.get}return n}},2753:(t,e,r)=>{"use strict";var n=r(4289).supportsDescriptors,i=r(1721),o=Object.getOwnPropertyDescriptor,s=Object.defineProperty,l=TypeError,a=Object.getPrototypeOf,u=/a/;t.exports=function(){if(!n||!a)throw new l("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");var t=i(),e=a(u),r=o(e,"flags");return r&&r.get===t||s(e,"flags",{configurable:!0,enumerable:!1,get:t}),t}}},e={};function r(n){var i=e[n];if(void 0!==i)return i.exports;var o=e[n]={exports:{}};return t[n].call(o.exports,o,o.exports,r),o.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},(()=>{"use strict";var t=r(347),e=r.n(t),n=(r(8299),r(4175)),i=r.n(n),o=r(6910),s=r.n(o),l=r(4470),a=r.n(l);class u extends e().Embed{static value(){}insertInto(t,e){0===t.children.length?super.insertInto(t,e):this.remove()}length(){return 0}value(){return""}}u.blotName="break",u.tagName="BR";const c=u;class h extends e().Text{}const f=h;class p extends e().Inline{static compare(t,e){let r=p.order.indexOf(t),n=p.order.indexOf(e);return r>=0||n>=0?r-n:t===e?0:t<e?-1:1}formatAt(t,r,n,i){if(p.compare(this.statics.blotName,n)<0&&e().query(n,e().Scope.BLOT)){let e=this.isolate(t,r);i&&e.wrap(n,i)}else super.formatAt(t,r,n,i)}optimize(t){if(super.optimize(t),this.parent instanceof p&&p.compare(this.statics.blotName,this.parent.statics.blotName)>0){let t=this.parent.isolate(this.offset(),this.length());this.moveChildren(t),t.wrap(this)}}}p.allowedChildren=[p,e().Embed,f],p.order=["cursor","inline","underline","strike","italic","bold","script","link","code"];const d=p;class y extends e().Embed{attach(){super.attach(),this.attributes=new(e().Attributor.Store)(this.domNode)}delta(){return(new(i())).insert(this.value(),a()(this.formats(),this.attributes.values()))}format(t,r){let n=e().query(t,e().Scope.BLOCK_ATTRIBUTE);null!=n&&this.attributes.attribute(n,r)}formatAt(t,e,r,n){this.format(r,n)}insertAt(t,r,n){if("string"==typeof r&&r.endsWith("\n")){let n=e().create(g.blotName);this.parent.insertBefore(n,0===t?this:this.next),n.insertAt(0,r.slice(0,-1))}else super.insertAt(t,r,n)}}y.scope=e().Scope.BLOCK_BLOT;class g extends e().Block{constructor(t){super(t),this.cache={}}delta(){return null==this.cache.delta&&(this.cache.delta=this.descendants(e().Leaf).reduce(((t,e)=>0===e.length()?t:t.insert(e.value(),m(e))),new(i())).insert("\n",m(this))),this.cache.delta}deleteAt(t,e){super.deleteAt(t,e),this.cache={}}formatAt(t,r,n,i){r<=0||(e().query(n,e().Scope.BLOCK)?t+r===this.length()&&this.format(n,i):super.formatAt(t,Math.min(r,this.length()-t-1),n,i),this.cache={})}insertAt(t,e,r){if(null!=r)return super.insertAt(t,e,r);if(0===e.length)return;let n=e.split("\n"),i=n.shift();i.length>0&&(t<this.length()-1||null==this.children.tail?super.insertAt(Math.min(t,this.length()-1),i):this.children.tail.insertAt(this.children.tail.length(),i),this.cache={});let o=this;n.reduce((function(t,e){return o=o.split(t,!0),o.insertAt(0,e),e.length}),t+i.length)}insertBefore(t,e){let r=this.children.head;super.insertBefore(t,e),r instanceof c&&r.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,e=!1){if(e&&(0===t||t>=this.length()-1)){let e=this.clone();return 0===t?(this.parent.insertBefore(e,this),this):(this.parent.insertBefore(e,this.next),e)}{let r=super.split(t,e);return this.cache={},r}}}function m(t,e={}){return null==t?e:("function"==typeof t.formats&&(e=a()(e,t.formats())),null==t.parent||"scroll"==t.parent.blotName||t.parent.statics.scope!==t.statics.scope?e:m(t.parent,e))}g.blotName="block",g.tagName="P",g.defaultChild="break",g.allowedChildren=[d,e().Embed,f];class b extends d{}b.blotName="code",b.tagName="CODE";class v extends g{static create(t){let e=super.create(t);return e.setAttribute("spellcheck",!1),e}static formats(){return!0}delta(){let t=this.domNode.textContent;return t.endsWith("\n")&&(t=t.slice(0,-1)),t.split("\n").reduce(((t,e)=>t.insert(e).insert("\n",this.formats())),new(i()))}format(t,e){if(t===this.statics.blotName&&e)return;let[r]=this.descendant(f,this.length()-1);null!=r&&r.deleteAt(r.length()-1,1),super.format(t,e)}formatAt(t,r,n,i){if(0===r)return;if(null==e().query(n,e().Scope.BLOCK)||n===this.statics.blotName&&i===this.statics.formats(this.domNode))return;let o=this.newlineIndex(t);if(o<0||o>=t+r)return;let s=this.newlineIndex(t,!0)+1,l=o-s+1,a=this.isolate(s,l),u=a.next;a.format(n,i),u instanceof v&&u.formatAt(0,t-s+r-l,n,i)}insertAt(t,e,r){if(null!=r)return;let[n,i]=this.descendant(f,t);n.insertAt(i,e)}length(){let t=this.domNode.textContent.length;return this.domNode.textContent.endsWith("\n")?t:t+1}newlineIndex(t,e=!1){if(e)return this.domNode.textContent.slice(0,t).lastIndexOf("\n");{let e=this.domNode.textContent.slice(t).indexOf("\n");return e>-1?t+e:-1}}optimize(t){this.domNode.textContent.endsWith("\n")||this.appendChild(e().create("text","\n")),super.optimize(t);let r=this.next;null!=r&&r.prev===this&&r.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===r.statics.formats(r.domNode)&&(r.optimize(t),r.moveChildren(this),r.remove())}replace(t){super.replace(t),[].slice.call(this.domNode.querySelectorAll("*")).forEach((function(t){let r=e().find(t);null==r?t.parentNode.removeChild(t):r instanceof e().Embed?r.remove():r.unwrap()}))}}v.blotName="code-block",v.tagName="PRE",v.TAB=" ";class E extends e().Embed{static value(){}constructor(t,e){super(t),this.selection=e,this.textNode=document.createTextNode(E.CONTENTS),this.domNode.appendChild(this.textNode),this._length=0}detach(){null!=this.parent&&this.parent.removeChild(this)}format(t,r){if(0!==this._length)return super.format(t,r);let n=this,i=0;for(;null!=n&&n.statics.scope!==e().Scope.BLOCK_BLOT;)i+=n.offset(n.parent),n=n.parent;null!=n&&(this._length=E.CONTENTS.length,n.optimize(),n.formatAt(i,E.CONTENTS.length,t,r),this._length=0)}index(t,e){return t===this.textNode?0:super.index(t,e)}length(){return this._length}position(){return[this.textNode,this.textNode.data.length]}remove(){super.remove(),this.parent=null}restore(){if(this.selection.composing||null==this.parent)return;let t,r,n,i=this.textNode,o=this.selection.getNativeRange();for(null!=o&&o.start.node===i&&o.end.node===i&&([t,r,n]=[i,o.start.offset,o.end.offset]);null!=this.domNode.lastChild&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==E.CONTENTS){let r=this.textNode.data.split(E.CONTENTS).join("");this.next instanceof f?(t=this.next.domNode,this.next.insertAt(0,r),this.textNode.data=E.CONTENTS):(this.textNode.data=r,this.parent.insertBefore(e().create(this.textNode),this),this.textNode=document.createTextNode(E.CONTENTS),this.domNode.appendChild(this.textNode))}return this.remove(),null!=r?([r,n]=[r,n].map((function(e){return Math.max(0,Math.min(t.data.length,e-1))})),{startNode:t,startOffset:r,endNode:t,endOffset:n}):void 0}update(t,e){if(t.some((t=>"characterData"===t.type&&t.target===this.textNode))){let t=this.restore();t&&(e.range=t)}}value(){return""}}E.blotName="cursor",E.className="ql-cursor",E.tagName="span",E.CONTENTS="\ufeff";const A=E;var N=r(6313),x=r.n(N),w=r(251),S=r.n(w);const T=/^[ -~]*$/;function O(t,e){return Object.keys(e).reduce((function(r,n){return null==t[n]||(e[n]===t[n]?r[n]=e[n]:Array.isArray(e[n])?e[n].indexOf(t[n])<0&&(r[n]=e[n].concat([t[n]])):r[n]=[e[n],t[n]]),r}),{})}const _=class{constructor(t){this.scroll=t,this.delta=this.getDelta()}applyDelta(t){let r=!1;this.scroll.update();let n=this.scroll.length();return this.scroll.batchStart(),(t=function(t){return t.reduce((function(t,e){if(1===e.insert){let r=x()(e.attributes);return delete r.image,t.insert({image:e.attributes.image},r)}if(null==e.attributes||!0!==e.attributes.list&&!0!==e.attributes.bullet||((e=x()(e)).attributes.list?e.attributes.list="ordered":(e.attributes.list="bullet",delete e.attributes.bullet)),"string"==typeof e.insert){let r=e.insert.replace(/\r\n/g,"\n").replace(/\r/g,"\n");return t.insert(r,e.attributes)}return t.push(e)}),new(i()))}(t)).reduce(((t,i)=>{let o=i.retain||i.delete||i.insert.length||1,l=i.attributes||{};if(null!=i.insert){if("string"==typeof i.insert){let o=i.insert;o.endsWith("\n")&&r&&(r=!1,o=o.slice(0,-1)),t>=n&&!o.endsWith("\n")&&(r=!0),this.scroll.insertAt(t,o);let[u,c]=this.scroll.line(t),h=a()({},m(u));if(u instanceof g){let[t]=u.descendant(e().Leaf,c);h=a()(h,m(t))}l=s().attributes.diff(h,l)||{}}else if("object"==typeof i.insert){let e=Object.keys(i.insert)[0];if(null==e)return t;this.scroll.insertAt(t,e,i.insert[e])}n+=o}return Object.keys(l).forEach((e=>{this.scroll.formatAt(t,o,e,l[e])})),t+o}),0),t.reduce(((t,e)=>"number"==typeof e.delete?(this.scroll.deleteAt(t,e.delete),t):t+(e.retain||e.insert.length||1)),0),this.scroll.batchEnd(),this.update(t)}deleteText(t,e){return this.scroll.deleteAt(t,e),this.update((new(i())).retain(t).delete(e))}formatLine(t,e,r={}){return this.scroll.update(),Object.keys(r).forEach((n=>{if(null!=this.scroll.whitelist&&!this.scroll.whitelist[n])return;let i=this.scroll.lines(t,Math.max(e,1)),o=e;i.forEach((e=>{let i=e.length();if(e instanceof v){let i=t-e.offset(this.scroll),s=e.newlineIndex(i+o)-i+1;e.formatAt(i,s,n,r[n])}else e.format(n,r[n]);o-=i}))})),this.scroll.optimize(),this.update((new(i())).retain(t).retain(e,x()(r)))}formatText(t,e,r={}){return Object.keys(r).forEach((n=>{this.scroll.formatAt(t,e,n,r[n])})),this.update((new(i())).retain(t).retain(e,x()(r)))}getContents(t,e){return this.delta.slice(t,t+e)}getDelta(){return this.scroll.lines().reduce(((t,e)=>t.concat(e.delta())),new(i()))}getFormat(t,r=0){let n=[],i=[];0===r?this.scroll.path(t).forEach((function(t){let[r]=t;r instanceof g?n.push(r):r instanceof e().Leaf&&i.push(r)})):(n=this.scroll.lines(t,r),i=this.scroll.descendants(e().Leaf,t,r));let o=[n,i].map((function(t){if(0===t.length)return{};let e=m(t.shift());for(;Object.keys(e).length>0;){let r=t.shift();if(null==r)return e;e=O(m(r),e)}return e}));return a().apply(a(),o)}getText(t,e){return this.getContents(t,e).filter((function(t){return"string"==typeof t.insert})).map((function(t){return t.insert})).join("")}insertEmbed(t,e,r){return this.scroll.insertAt(t,e,r),this.update((new(i())).retain(t).insert({[e]:r}))}insertText(t,e,r={}){return e=e.replace(/\r\n/g,"\n").replace(/\r/g,"\n"),this.scroll.insertAt(t,e),Object.keys(r).forEach((n=>{this.scroll.formatAt(t,e.length,n,r[n])})),this.update((new(i())).retain(t).insert(e,x()(r)))}isBlank(){if(0==this.scroll.children.length)return!0;if(this.scroll.children.length>1)return!1;let t=this.scroll.children.head;return t.statics.blotName===g.blotName&&(!(t.children.length>1)&&t.children.head instanceof c)}removeFormat(t,e){let r=this.getText(t,e),[n,o]=this.scroll.line(t+e),s=0,l=new(i());null!=n&&(s=n instanceof v?n.newlineIndex(o)-o+1:n.length()-o,l=n.delta().slice(o,o+s-1).insert("\n"));let a=this.getContents(t,e+s).diff((new(i())).insert(r).concat(l)),u=(new(i())).retain(t).concat(a);return this.applyDelta(u)}update(t,r=[],n){let o=this.delta;if(1===r.length&&"characterData"===r[0].type&&r[0].target.data.match(T)&&e().find(r[0].target)){let s=e().find(r[0].target),l=m(s),a=s.offset(this.scroll),u=r[0].oldValue.replace(A.CONTENTS,""),c=(new(i())).insert(u),h=(new(i())).insert(s.value());t=(new(i())).retain(a).concat(c.diff(h,n)).reduce((function(t,e){return e.insert?t.insert(e.insert,l):t.push(e)}),new(i())),this.delta=o.compose(t)}else this.delta=this.getDelta(),t&&S()(o.compose(t),this.delta)||(t=o.diff(this.delta,n));return t}};var k=r(6729),L=r.n(k);let q=["error","warn","log","info"],R="warn";function C(t,...e){q.indexOf(t)<=q.indexOf(R)&&console[t](...e)}function P(t){return q.reduce((function(e,r){return e[r]=C.bind(console,r,t),e}),{})}C.level=P.level=function(t){R=t};const I=P;let j=I("quill:events");["selectionchange","mousedown","mouseup","click"].forEach((function(t){document.addEventListener(t,((...t)=>{[].slice.call(document.querySelectorAll(".ql-container")).forEach((e=>{e.__quill&&e.__quill.emitter&&e.__quill.emitter.handleDOM(...t)}))}))}));class B extends(L()){constructor(){super(),this.listeners={},this.on("error",j.error)}emit(){j.log.apply(j,arguments),super.emit.apply(this,arguments)}handleDOM(t,...e){(this.listeners[t.type]||[]).forEach((function({node:r,handler:n}){(t.target===r||r.contains(t.target))&&n(t,...e)}))}listenDOM(t,e,r){this.listeners[t]||(this.listeners[t]=[]),this.listeners[t].push({node:e,handler:r})}}B.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},B.sources={API:"api",SILENT:"silent",USER:"user"};const U=B;class D{constructor(t,e={}){this.quill=t,this.options=e}}D.DEFAULTS={};const M=D;let F=I("quill:selection");class K{constructor(t,e=0){this.index=t,this.length=e}}class Y{constructor(t,r){this.emitter=r,this.scroll=t,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=e().create("cursor",this),this.lastRange=this.savedRange=new K(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,(()=>{this.mouseDown||setTimeout(this.update.bind(this,U.sources.USER),1)})),this.emitter.on(U.events.EDITOR_CHANGE,((t,e)=>{t===U.events.TEXT_CHANGE&&e.length()>0&&this.update(U.sources.SILENT)})),this.emitter.on(U.events.SCROLL_BEFORE_UPDATE,(()=>{if(!this.hasFocus())return;let t=this.getNativeRange();null!=t&&t.start.node!==this.cursor.textNode&&this.emitter.once(U.events.SCROLL_UPDATE,(()=>{try{this.setNativeRange(t.start.node,t.start.offset,t.end.node,t.end.offset)}catch(t){}}))})),this.emitter.on(U.events.SCROLL_OPTIMIZE,((t,e)=>{if(e.range){const{startNode:t,startOffset:r,endNode:n,endOffset:i}=e.range;this.setNativeRange(t,r,n,i)}})),this.update(U.sources.SILENT)}handleComposition(){this.root.addEventListener("compositionstart",(()=>{this.composing=!0})),this.root.addEventListener("compositionend",(()=>{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(U.sources.USER)}))}focus(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}format(t,r){if(null!=this.scroll.whitelist&&!this.scroll.whitelist[t])return;this.scroll.update();let n=this.getNativeRange();if(null!=n&&n.native.collapsed&&!e().query(t,e().Scope.BLOCK)){if(n.start.node!==this.cursor.textNode){let t=e().find(n.start.node,!1);if(null==t)return;if(t instanceof e().Leaf){let e=t.split(n.start.offset);t.parent.insertBefore(this.cursor,e)}else t.insertBefore(this.cursor,n.start.node);this.cursor.attach()}this.cursor.format(t,r),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}getBounds(t,e=0){let r=this.scroll.length();t=Math.min(t,r-1),e=Math.min(t+e,r-1)-t;let n,[i,o]=this.scroll.leaf(t);if(null==i)return null;[n,o]=i.position(o,!0);let s=document.createRange();if(e>0)return s.setStart(n,o),[i,o]=this.scroll.leaf(t+e),null==i?null:([n,o]=i.position(o,!0),s.setEnd(n,o),s.getBoundingClientRect());{let t,e="left";return n instanceof Text?(o<n.data.length?(s.setStart(n,o),s.setEnd(n,o+1)):(s.setStart(n,o-1),s.setEnd(n,o),e="right"),t=s.getBoundingClientRect()):(t=i.domNode.getBoundingClientRect(),o>0&&(e="right")),{bottom:t.top+t.height,height:t.height,left:t[e],right:t[e],top:t.top,width:0}}}getNativeRange(){let t=document.getSelection();if(null==t||t.rangeCount<=0)return null;let e=t.getRangeAt(0);if(null==e)return null;let r=this.normalizeNative(e);return F.info("getNativeRange",r),r}getRange(){let t=this.getNativeRange();return null==t?[null,null]:[this.normalizedToRange(t),t]}hasFocus(){return document.activeElement===this.root}normalizedToRange(t){let r=[[t.start.node,t.start.offset]];t.native.collapsed||r.push([t.end.node,t.end.offset]);let n=r.map((t=>{let[r,n]=t,i=e().find(r,!0),o=i.offset(this.scroll);return 0===n?o:i instanceof e().Container?o+i.length():o+i.index(r,n)})),i=Math.min(Math.max(...n),this.scroll.length()-1),o=Math.min(i,...n);return new K(o,i-o)}normalizeNative(t){if(!z(this.root,t.startContainer)||!t.collapsed&&!z(this.root,t.endContainer))return null;let e={start:{node:t.startContainer,offset:t.startOffset},end:{node:t.endContainer,offset:t.endOffset},native:t};return[e.start,e.end].forEach((function(t){let e=t.node,r=t.offset;for(;!(e instanceof Text)&&e.childNodes.length>0;)if(e.childNodes.length>r)e=e.childNodes[r],r=0;else{if(e.childNodes.length!==r)break;e=e.lastChild,r=e instanceof Text?e.data.length:e.childNodes.length+1}t.node=e,t.offset=r})),e}rangeToNative(t){let e=t.collapsed?[t.index]:[t.index,t.index+t.length],r=[],n=this.scroll.length();return e.forEach(((t,e)=>{t=Math.min(n-1,t);let i,[o,s]=this.scroll.leaf(t);[i,s]=o.position(s,0!==e),r.push(i,s)})),r.length<2&&(r=r.concat(r)),r}scrollIntoView(t){let e=this.lastRange;if(null==e)return;let r=this.getBounds(e.index,e.length);if(null==r)return;let n=this.scroll.length()-1,[i]=this.scroll.line(Math.min(e.index,n)),o=i;if(e.length>0&&([o]=this.scroll.line(Math.min(e.index+e.length,n))),null==i||null==o)return;let s=t.getBoundingClientRect();r.top<s.top?t.scrollTop-=s.top-r.top:r.bottom>s.bottom&&(t.scrollTop+=r.bottom-s.bottom)}setNativeRange(t,e,r=t,n=e,i=!1){if(F.info("setNativeRange",t,e,r,n),null!=t&&(null==this.root.parentNode||null==t.parentNode||null==r.parentNode))return;let o=document.getSelection();if(null!=o)if(null!=t){this.hasFocus()||this.root.focus();let s=(this.getNativeRange()||{}).native;if(null==s||i||t!==s.startContainer||e!==s.startOffset||r!==s.endContainer||n!==s.endOffset){"BR"==t.tagName&&(e=[].indexOf.call(t.parentNode.childNodes,t),t=t.parentNode),"BR"==r.tagName&&(n=[].indexOf.call(r.parentNode.childNodes,r),r=r.parentNode);let i=document.createRange();i.setStart(t,e),i.setEnd(r,n),o.removeAllRanges(),o.addRange(i)}}else o.removeAllRanges(),this.root.blur(),document.body.focus()}setRange(t,e=!1,r=U.sources.API){if("string"==typeof e&&(r=e,e=!1),F.info("setRange",t),null!=t){let r=this.rangeToNative(t);this.setNativeRange(...r,e)}else this.setNativeRange(null);this.update(r)}update(t=U.sources.USER){let e=this.lastRange,[r,n]=this.getRange();if(this.lastRange=r,null!=this.lastRange&&(this.savedRange=this.lastRange),!S()(e,this.lastRange)){!this.composing&&null!=n&&n.native.collapsed&&n.start.node!==this.cursor.textNode&&this.cursor.restore();let r=[U.events.SELECTION_CHANGE,x()(this.lastRange),x()(e),t];this.emitter.emit(U.events.EDITOR_CHANGE,...r),t!==U.sources.SILENT&&this.emitter.emit(...r)}}}function z(t,e){try{e.parentNode}catch(t){return!1}return e instanceof Text&&(e=e.parentNode),t.contains(e)}class ${constructor(t,e){this.quill=t,this.options=e,this.modules={}}init(){Object.keys(this.options.modules).forEach((t=>{null==this.modules[t]&&this.addModule(t)}))}addModule(t){let e=this.quill.constructor.import(`modules/${t}`);return this.modules[t]=new e(this.quill,this.options.modules[t]||{}),this.modules[t]}}$.DEFAULTS={modules:{}},$.themes={default:$};const W=$;let G=I("quill");class H{static debug(t){!0===t&&(t="log"),I.level(t)}static find(t){return t.__quill||e().find(t)}static import(t){return null==this.imports[t]&&G.error(`Cannot import ${t}. Are you sure it was registered?`),this.imports[t]}static register(t,r,n=!1){if("string"!=typeof t){let e=t.attrName||t.blotName;"string"==typeof e?this.register("formats/"+e,t,r):Object.keys(t).forEach((e=>{this.register(e,t[e],r)}))}else null==this.imports[t]||n||G.warn(`Overwriting ${t} with`,r),this.imports[t]=r,(t.startsWith("blots/")||t.startsWith("formats/"))&&"abstract"!==r.blotName?e().register(r):t.startsWith("modules")&&"function"==typeof r.register&&r.register()}constructor(t,r={}){if(this.options=function(t,e){if((e=a()(!0,{container:t,modules:{clipboard:!0,keyboard:!0,history:!0}},e)).theme&&e.theme!==H.DEFAULTS.theme){if(e.theme=H.import(`themes/${e.theme}`),null==e.theme)throw new Error(`Invalid theme ${e.theme}. Did you register it?`)}else e.theme=W;let r=a()(!0,{},e.theme.DEFAULTS);[r,e].forEach((function(t){t.modules=t.modules||{},Object.keys(t.modules).forEach((function(e){!0===t.modules[e]&&(t.modules[e]={})}))}));let n=Object.keys(r.modules).concat(Object.keys(e.modules)).reduce((function(t,e){let r=H.import(`modules/${e}`);return null==r?G.error(`Cannot load ${e} module. Are you sure you registered it?`):t[e]=r.DEFAULTS||{},t}),{});null!=e.modules&&e.modules.toolbar&&e.modules.toolbar.constructor!==Object&&(e.modules.toolbar={container:e.modules.toolbar});return e=a()(!0,{},H.DEFAULTS,{modules:n},r,e),["bounds","container","scrollingContainer"].forEach((function(t){"string"==typeof e[t]&&(e[t]=document.querySelector(e[t]))})),e.modules=Object.keys(e.modules).reduce((function(t,r){return e.modules[r]&&(t[r]=e.modules[r]),t}),{}),e}(t,r),this.container=this.options.container,null==this.container)return G.error("Invalid Quill container",t);this.options.debug&&H.debug(this.options.debug);let n=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new U,this.scroll=e().create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new _(this.scroll),this.selection=new Y(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(U.events.EDITOR_CHANGE,(t=>{t===U.events.TEXT_CHANGE&&this.root.classList.toggle("ql-blank",this.editor.isBlank())})),this.emitter.on(U.events.SCROLL_UPDATE,((t,e)=>{let r=this.selection.lastRange,n=r&&0===r.length?r.index:void 0;V.call(this,(()=>this.editor.update(null,e,n)),t)}));let i=this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">${n}<p><br></p></div>`);this.setContents(i),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}addContainer(t,e=null){if("string"==typeof t){let e=t;(t=document.createElement("div")).classList.add(e)}return this.container.insertBefore(t,e),t}blur(){this.selection.setRange(null)}deleteText(t,e,r){return[t,e,,r]=X(t,e,r),V.call(this,(()=>this.editor.deleteText(t,e)),r,t,-1*e)}disable(){this.enable(!1)}enable(t=!0){this.scroll.enable(t),this.container.classList.toggle("ql-disabled",!t)}focus(){let t=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=t,this.scrollIntoView()}format(t,r,n=U.sources.API){return V.call(this,(()=>{let n=this.getSelection(!0),o=new(i());if(null==n)return o;if(e().query(t,e().Scope.BLOCK))o=this.editor.formatLine(n.index,n.length,{[t]:r});else{if(0===n.length)return this.selection.format(t,r),o;o=this.editor.formatText(n.index,n.length,{[t]:r})}return this.setSelection(n,U.sources.SILENT),o}),n)}formatLine(t,e,r,n,i){let o;return[t,e,o,i]=X(t,e,r,n,i),V.call(this,(()=>this.editor.formatLine(t,e,o)),i,t,0)}formatText(t,e,r,n,i){let o;return[t,e,o,i]=X(t,e,r,n,i),V.call(this,(()=>this.editor.formatText(t,e,o)),i,t,0)}getBounds(t,e=0){let r;r="number"==typeof t?this.selection.getBounds(t,e):this.selection.getBounds(t.index,t.length);let n=this.container.getBoundingClientRect();return{bottom:r.bottom-n.top,height:r.height,left:r.left-n.left,right:r.right-n.left,top:r.top-n.top,width:r.width}}getContents(t=0,e=this.getLength()-t){return[t,e]=X(t,e),this.editor.getContents(t,e)}getFormat(t=this.getSelection(!0),e=0){return"number"==typeof t?this.editor.getFormat(t,e):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(t=0,e=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(t=!1){return t&&this.focus(),this.update(),this.selection.getRange()[0]}getText(t=0,e=this.getLength()-t){return[t,e]=X(t,e),this.editor.getText(t,e)}hasFocus(){return this.selection.hasFocus()}insertEmbed(t,e,r,n=H.sources.API){return V.call(this,(()=>this.editor.insertEmbed(t,e,r)),n,t)}insertText(t,e,r,n,i){let o;return[t,,o,i]=X(t,0,r,n,i),V.call(this,(()=>this.editor.insertText(t,e,o)),i,t,e.length)}isEnabled(){return!this.container.classList.contains("ql-disabled")}off(){return this.emitter.off.apply(this.emitter,arguments)}on(){return this.emitter.on.apply(this.emitter,arguments)}once(){return this.emitter.once.apply(this.emitter,arguments)}pasteHTML(t,e,r){this.clipboard.dangerouslyPasteHTML(t,e,r)}removeFormat(t,e,r){return[t,e,,r]=X(t,e,r),V.call(this,(()=>this.editor.removeFormat(t,e)),r,t)}scrollIntoView(){this.selection.scrollIntoView(this.scrollingContainer)}setContents(t,e=U.sources.API){return V.call(this,(()=>{t=new(i())(t);let e=this.getLength(),r=this.editor.deleteText(0,e),n=this.editor.applyDelta(t),o=n.ops[n.ops.length-1];return null!=o&&"string"==typeof o.insert&&"\n"===o.insert[o.insert.length-1]&&(this.editor.deleteText(this.getLength()-1,1),n.delete(1)),r.compose(n)}),e)}setSelection(t,e,r){null==t?this.selection.setRange(null,e||H.sources.API):([t,e,,r]=X(t,e,r),this.selection.setRange(new K(t,e),r),r!==U.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer))}setText(t,e=U.sources.API){let r=(new(i())).insert(t);return this.setContents(r,e)}update(t=U.sources.USER){let e=this.scroll.update(t);return this.selection.update(t),e}updateContents(t,e=U.sources.API){return V.call(this,(()=>(t=new(i())(t),this.editor.applyDelta(t,e))),e,!0)}}function V(t,e,r,n){if(this.options.strict&&!this.isEnabled()&&e===U.sources.USER)return new(i());let o=null==r?null:this.getSelection(),s=this.editor.delta,l=t();if(null!=o&&(!0===r&&(r=o.index),null==n?o=Z(o,l,e):0!==n&&(o=Z(o,r,n,e)),this.setSelection(o,U.sources.SILENT)),l.length()>0){let t=[U.events.TEXT_CHANGE,l,s,e];this.emitter.emit(U.events.EDITOR_CHANGE,...t),e!==U.sources.SILENT&&this.emitter.emit(...t)}return l}function X(t,e,r,n,i){let o={};return"number"==typeof t.index&&"number"==typeof t.length?"number"!=typeof e?(i=n,n=r,r=e,e=t.length,t=t.index):(e=t.length,t=t.index):"number"!=typeof e&&(i=n,n=r,r=e,e=0),"object"==typeof r?(o=r,i=n):"string"==typeof r&&(null!=n?o[r]=n:i=r),[t,e,o,i=i||U.sources.API]}function Z(t,e,r,n){if(null==t)return null;let o,s;return e instanceof i()?[o,s]=[t.index,t.index+t.length].map((function(t){return e.transformPosition(t,n!==U.sources.USER)})):[o,s]=[t.index,t.index+t.length].map((function(t){return t<e||t===e&&n===U.sources.USER?t:r>=0?t+r:Math.max(e,t+r)})),new K(o,s-o)}H.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},H.events=U.events,H.sources=U.sources,H.version="undefined"==typeof QUILL_VERSION?"dev":QUILL_VERSION,H.imports={delta:i(),parchment:e(),"core/module":M,"core/theme":W};class J extends e().Container{}J.allowedChildren=[g,y,J];const Q=J,tt="\ufeff";class et extends e().Embed{constructor(t){super(t),this.contentNode=document.createElement("span"),this.contentNode.setAttribute("contenteditable",!1),[].slice.call(this.domNode.childNodes).forEach((t=>{this.contentNode.appendChild(t)})),this.leftGuard=document.createTextNode(tt),this.rightGuard=document.createTextNode(tt),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 r,n,i=t.data.split(tt).join("");if(t===this.leftGuard)if(this.prev instanceof f){let t=this.prev.length();this.prev.insertAt(t,i),r={startNode:this.prev.domNode,startOffset:t+i.length}}else n=document.createTextNode(i),this.parent.insertBefore(e().create(n),this),r={startNode:n,startOffset:i.length};else t===this.rightGuard&&(this.next instanceof f?(this.next.insertAt(0,i),r={startNode:this.next.domNode,startOffset:i.length}):(n=document.createTextNode(i),this.parent.insertBefore(e().create(n),this.next),r={startNode:n,startOffset:i.length}));return t.data=tt,r}update(t,e){t.forEach((t=>{if("characterData"===t.type&&(t.target===this.leftGuard||t.target===this.rightGuard)){let r=this.restore(t.target);r&&(e.range=r)}}))}}const rt=et;function nt(t){return t instanceof g||t instanceof y}class it extends e().Scroll{constructor(t,e){super(t),this.emitter=e.emitter,Array.isArray(e.whitelist)&&(this.whitelist=e.whitelist.reduce((function(t,e){return t[e]=!0,t}),{})),this.domNode.addEventListener("DOMNodeInserted",(function(){})),this.optimize(),this.enable()}batchStart(){this.batch=!0}batchEnd(){this.batch=!1,this.optimize()}deleteAt(t,e){let[r,n]=this.line(t),[i]=this.line(t+e);if(super.deleteAt(t,e),null!=i&&r!==i&&n>0){if(r instanceof y||i instanceof y)return void this.optimize();if(r instanceof v){let t=r.newlineIndex(r.length(),!0);if(t>-1&&(r=r.split(t+1),r===i))return void this.optimize()}else if(i instanceof v){let t=i.newlineIndex(0);t>-1&&i.split(t+1)}let t=i.children.head instanceof c?null:i.children.head;r.moveChildren(i,t),r.remove()}this.optimize()}enable(t=!0){this.domNode.setAttribute("contenteditable",t)}formatAt(t,e,r,n){(null==this.whitelist||this.whitelist[r])&&(super.formatAt(t,e,r,n),this.optimize())}insertAt(t,r,n){if(null==n||null==this.whitelist||this.whitelist[r]){if(t>=this.length())if(null==n||null==e().query(r,e().Scope.BLOCK)){let t=e().create(this.statics.defaultChild);this.appendChild(t),null==n&&r.endsWith("\n")&&(r=r.slice(0,-1)),t.insertAt(0,r,n)}else{let t=e().create(r,n);this.appendChild(t)}else super.insertAt(t,r,n);this.optimize()}}insertBefore(t,r){if(t.statics.scope===e().Scope.INLINE_BLOT){let r=e().create(this.statics.defaultChild);r.appendChild(t),t=r}super.insertBefore(t,r)}leaf(t){return this.path(t).pop()||[null,-1]}line(t){return t===this.length()?this.line(t-1):this.descendant(nt,t)}lines(t=0,r=Number.MAX_VALUE){let n=(t,r,i)=>{let o=[],s=i;return t.children.forEachAt(r,i,(function(t,r,i){nt(t)?o.push(t):t instanceof e().Container&&(o=o.concat(n(t,r,s))),s-=i})),o};return n(this,t,r)}optimize(t=[],e={}){!0!==this.batch&&(super.optimize(t,e),t.length>0&&this.emitter.emit(U.events.SCROLL_OPTIMIZE,t,e))}path(t){return super.path(t).slice(1)}update(t){if(!0===this.batch)return;let e=U.sources.USER;"string"==typeof t&&(e=t),Array.isArray(t)||(t=this.observer.takeRecords()),t.length>0&&this.emitter.emit(U.events.SCROLL_BEFORE_UPDATE,e,t),super.update(t.concat([])),t.length>0&&this.emitter.emit(U.events.SCROLL_UPDATE,e,t)}}it.blotName="scroll",it.className="ql-editor",it.tagName="DIV",it.defaultChild="block",it.allowedChildren=[g,y,Q];const ot=it;let st={scope:e().Scope.BLOCK,whitelist:["right","center","justify"]},lt=new(e().Attributor.Attribute)("align","align",st),at=(new(e().Attributor.Class)("align","ql-align",st),new(e().Attributor.Style)("align","text-align",st));class ut extends e().Attributor.Style{value(t){let e=super.value(t);return e.startsWith("rgb(")?(e=e.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+e.split(",").map((function(t){return("00"+parseInt(t).toString(16)).slice(-2)})).join("")):e}}new(e().Attributor.Class)("color","ql-color",{scope:e().Scope.INLINE});let ct=new ut("color","color",{scope:e().Scope.INLINE}),ht=(new(e().Attributor.Class)("background","ql-bg",{scope:e().Scope.INLINE}),new ut("background","background-color",{scope:e().Scope.INLINE})),ft={scope:e().Scope.BLOCK,whitelist:["rtl"]},pt=new(e().Attributor.Attribute)("direction","dir",ft),dt=(new(e().Attributor.Class)("direction","ql-direction",ft),new(e().Attributor.Style)("direction","direction",ft)),yt={scope:e().Scope.INLINE,whitelist:["serif","monospace"]};new(e().Attributor.Class)("font","ql-font",yt);class gt extends e().Attributor.Style{value(t){return super.value(t).replace(/["']/g,"")}}let mt=new gt("font","font-family",yt),bt=(new(e().Attributor.Class)("size","ql-size",{scope:e().Scope.INLINE,whitelist:["small","large","huge"]}),new(e().Attributor.Style)("size","font-size",{scope:e().Scope.INLINE,whitelist:["10px","18px","32px"]})),vt=I("quill:clipboard");const Et="__ql-matcher",At=[[Node.TEXT_NODE,function(t,e){let r=t.data;if("O:P"===t.parentNode.tagName)return e.insert(r.trim());if(0===r.trim().length&&t.parentNode.classList.contains("ql-clipboard"))return e;if(!Tt(t.parentNode).whiteSpace.startsWith("pre")){let e=function(t,e){return(e=e.replace(/[^\u00a0]/g,"")).length<1&&t?" ":e};r=r.replace(/\r\n/g," ").replace(/\n/g," "),r=r.replace(/\s\s+/g,e.bind(e,!0)),(null==t.previousSibling&&_t(t.parentNode)||null!=t.previousSibling&&_t(t.previousSibling))&&(r=r.replace(/^\s+/,e.bind(e,!1))),(null==t.nextSibling&&_t(t.parentNode)||null!=t.nextSibling&&_t(t.nextSibling))&&(r=r.replace(/\s+$/,e.bind(e,!1)))}return e.insert(r)}],[Node.TEXT_NODE,qt],["br",function(t,e){Ot(e,"\n")||e.insert("\n");return e}],[Node.ELEMENT_NODE,qt],[Node.ELEMENT_NODE,function(t,r){let n=e().query(t);if(null==n)return r;if(n.prototype instanceof e().Embed){let e={},o=n.value(t);null!=o&&(e[n.blotName]=o,r=(new(i())).insert(e,n.formats(t)))}else"function"==typeof n.formats&&(r=St(r,n.blotName,n.formats(t)));return r}],[Node.ELEMENT_NODE,Rt],[Node.ELEMENT_NODE,function(t,r){let n=e().Attributor.Attribute.keys(t),i=e().Attributor.Class.keys(t),o=e().Attributor.Style.keys(t),s={};n.concat(i).concat(o).forEach((r=>{let n=e().query(r,e().Scope.ATTRIBUTE);null!=n&&(s[n.attrName]=n.value(t),s[n.attrName])||(n=Nt[r],null==n||n.attrName!==r&&n.keyName!==r||(s[n.attrName]=n.value(t)||void 0),n=xt[r],null==n||n.attrName!==r&&n.keyName!==r||(n=xt[r],s[n.attrName]=n.value(t)||void 0))})),Object.keys(s).length>0&&(r=St(r,s));return r}],[Node.ELEMENT_NODE,function(t,e){let r={},n=t.style||{};n.fontStyle&&"italic"===Tt(t).fontStyle&&(r.italic=!0);n.fontWeight&&(Tt(t).fontWeight.startsWith("bold")||parseInt(Tt(t).fontWeight)>=700)&&(r.bold=!0);Object.keys(r).length>0&&(e=St(e,r));parseFloat(n.textIndent||0)>0&&(e=(new(i())).insert("\t").concat(e));return e}],["li",function(t,r){let n=e().query(t);if(null==n||"list-item"!==n.blotName||!Ot(r,"\n"))return r;let o=-1,s=t.parentNode;for(;!s.classList.contains("ql-clipboard");)"list"===(e().query(s)||{}).blotName&&(o+=1),s=s.parentNode;return o<=0?r:r.compose((new(i())).retain(r.length()-1).retain(1,{indent:o}))}],["b",Lt.bind(Lt,"bold")],["i",Lt.bind(Lt,"italic")],["style",function(){return new(i())}]],Nt=[lt,pt].reduce((function(t,e){return t[e.keyName]=e,t}),{}),xt=[at,ht,ct,dt,mt,bt].reduce((function(t,e){return t[e.keyName]=e,t}),{});class wt extends M{constructor(t,e){super(t,e),this.quill.root.addEventListener("paste",this.onPaste.bind(this)),this.container=this.quill.addContainer("ql-clipboard"),this.container.setAttribute("contenteditable",!0),this.container.setAttribute("tabindex",-1),this.matchers=[],At.concat(this.options.matchers).forEach((([t,r])=>{(e.matchVisual||r!==Rt)&&this.addMatcher(t,r)}))}addMatcher(t,e){this.matchers.push([t,e])}convert(t){if("string"==typeof t)return this.container.innerHTML=t.replace(/\>\r?\n +\</g,"><"),this.convert();const e=this.quill.getFormat(this.quill.selection.savedRange.index);if(e[v.blotName]){const t=this.container.innerText;return this.container.innerHTML="",(new(i())).insert(t,{[v.blotName]:e[v.blotName]})}let[r,n]=this.prepareMatching(),o=kt(this.container,r,n);return Ot(o,"\n")&&null==o.ops[o.ops.length-1].attributes&&(o=o.compose((new(i())).retain(o.length()-1).delete(1))),vt.log("convert",this.container.innerHTML,o),this.container.innerHTML="",o}dangerouslyPasteHTML(t,e,r=H.sources.API){if("string"==typeof t)this.quill.setContents(this.convert(t),e),this.quill.setSelection(0,H.sources.SILENT);else{let n=this.convert(e);this.quill.updateContents((new(i())).retain(t).concat(n),r),this.quill.setSelection(t+n.length(),H.sources.SILENT)}}onPaste(t){if(t.defaultPrevented||!this.quill.isEnabled())return;let e=this.quill.getSelection(),r=(new(i())).retain(e.index),n=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(H.sources.SILENT),setTimeout((()=>{r=r.concat(this.convert()).delete(e.length),this.quill.updateContents(r,H.sources.USER),this.quill.setSelection(r.length()-e.length,H.sources.SILENT),this.quill.scrollingContainer.scrollTop=n,this.quill.focus()}),1)}prepareMatching(){let t=[],e=[];return this.matchers.forEach((r=>{let[n,i]=r;switch(n){case Node.TEXT_NODE:e.push(i);break;case Node.ELEMENT_NODE:t.push(i);break;default:[].forEach.call(this.container.querySelectorAll(n),(t=>{t[Et]=t[Et]||[],t[Et].push(i)}))}})),[t,e]}}function St(t,e,r){return"object"==typeof e?Object.keys(e).reduce((function(t,r){return St(t,r,e[r])}),t):t.reduce((function(t,n){return n.attributes&&n.attributes[e]?t.push(n):t.insert(n.insert,a()({},{[e]:r},n.attributes))}),new(i()))}function Tt(t){if(t.nodeType!==Node.ELEMENT_NODE)return{};const e="__ql-computed-style";return t[e]||(t[e]=window.getComputedStyle(t))}function Ot(t,e){let r="";for(let n=t.ops.length-1;n>=0&&r.length<e.length;--n){let e=t.ops[n];if("string"!=typeof e.insert)break;r=e.insert+r}return r.slice(-1*e.length)===e}function _t(t){if(0===t.childNodes.length)return!1;let e=Tt(t);return["block","list-item"].indexOf(e.display)>-1}function kt(t,e,r){return t.nodeType===t.TEXT_NODE?r.reduce((function(e,r){return r(t,e)}),new(i())):t.nodeType===t.ELEMENT_NODE?[].reduce.call(t.childNodes||[],((n,i)=>{let o=kt(i,e,r);return i.nodeType===t.ELEMENT_NODE&&(o=e.reduce((function(t,e){return e(i,t)}),o),o=(i[Et]||[]).reduce((function(t,e){return e(i,t)}),o)),n.concat(o)}),new(i())):new(i())}function Lt(t,e,r){return St(r,t,!0)}function qt(t,e){return Ot(e,"\n")||(_t(t)||e.length()>0&&t.nextSibling&&_t(t.nextSibling))&&e.insert("\n"),e}function Rt(t,e){if(_t(t)&&null!=t.nextElementSibling&&!Ot(e,"\n\n")){let r=t.offsetHeight+parseFloat(Tt(t).marginTop)+parseFloat(Tt(t).marginBottom);t.nextElementSibling.offsetTop>t.offsetTop+1.5*r&&e.insert("\n")}return e}wt.DEFAULTS={matchers:[],matchVisual:!0};class Ct extends M{constructor(t,e){super(t,e),this.lastRecorded=0,this.ignoreChange=!1,this.clear(),this.quill.on(H.events.EDITOR_CHANGE,((t,e,r,n)=>{t!==H.events.TEXT_CHANGE||this.ignoreChange||(this.options.userOnly&&n!==H.sources.USER?this.transform(e):this.record(e,r))})),this.quill.keyboard.addBinding({key:"Z",shortKey:!0},this.undo.bind(this)),this.quill.keyboard.addBinding({key:"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))}change(t,r){if(0===this.stack[t].length)return;let n=this.stack[t].pop();this.stack[r].push(n),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(n[t],H.sources.USER),this.ignoreChange=!1;let i=function(t){let r=t.reduce((function(t,e){return t+=e.delete||0}),0),n=t.length()-r;(function(t){let r=t.ops[t.ops.length-1];if(null==r)return!1;if(null!=r.insert)return"string"==typeof r.insert&&r.insert.endsWith("\n");if(null!=r.attributes)return Object.keys(r.attributes).some((function(t){return null!=e().query(t,e().Scope.BLOCK)}));return!1})(t)&&(n-=1);return n}(n[t]);this.quill.setSelection(i)}clear(){this.stack={undo:[],redo:[]}}cutoff(){this.lastRecorded=0}record(t,e){if(0===t.ops.length)return;this.stack.redo=[];let r=this.quill.getContents().diff(e),n=Date.now();if(this.lastRecorded+this.options.delay>n&&this.stack.undo.length>0){let e=this.stack.undo.pop();r=r.compose(e.undo),t=e.redo.compose(t)}else this.lastRecorded=n;this.stack.undo.push({redo:t,undo:r}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}redo(){this.change("redo","undo")}transform(t){this.stack.undo.forEach((function(e){e.undo=t.transform(e.undo,!0),e.redo=t.transform(e.redo,!0)})),this.stack.redo.forEach((function(e){e.undo=t.transform(e.undo,!0),e.redo=t.transform(e.redo,!0)}))}undo(){this.change("undo","redo")}}Ct.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};let Pt=I("quill:keyboard");const It=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey";class jt extends M{static match(t,e){return e=zt(e),!["altKey","ctrlKey","metaKey","shiftKey"].some((function(r){return!!e[r]!==t[r]&&null!==e[r]}))&&e.key===(t.which||t.keyCode)}constructor(t,e){super(t,e),this.bindings={},Object.keys(this.options.bindings).forEach((e=>{("list autofill"!==e||null==t.scroll.whitelist||t.scroll.whitelist.list)&&this.options.bindings[e]&&this.addBinding(this.options.bindings[e])})),this.addBinding({key:jt.keys.ENTER,shiftKey:null},Ft),this.addBinding({key:jt.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},(function(){})),/Firefox/i.test(navigator.userAgent)?(this.addBinding({key:jt.keys.BACKSPACE},{collapsed:!0},Ut),this.addBinding({key:jt.keys.DELETE},{collapsed:!0},Dt)):(this.addBinding({key:jt.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},Ut),this.addBinding({key:jt.keys.DELETE},{collapsed:!0,suffix:/^.?$/},Dt)),this.addBinding({key:jt.keys.BACKSPACE},{collapsed:!1},Mt),this.addBinding({key:jt.keys.DELETE},{collapsed:!1},Mt),this.addBinding({key:jt.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},Ut),this.listen()}addBinding(t,e={},r={}){let n=zt(t);if(null==n||null==n.key)return Pt.warn("Attempted to add invalid keyboard binding",n);"function"==typeof e&&(e={handler:e}),"function"==typeof r&&(r={handler:r}),n=a()(n,e,r),this.bindings[n.key]=this.bindings[n.key]||[],this.bindings[n.key].push(n)}listen(){this.quill.root.addEventListener("keydown",(t=>{if(t.defaultPrevented)return;let r=t.which||t.keyCode,n=(this.bindings[r]||[]).filter((function(e){return jt.match(t,e)}));if(0===n.length)return;let i=this.quill.getSelection();if(null==i||!this.quill.hasFocus())return;let[o,s]=this.quill.getLine(i.index),[l,a]=this.quill.getLeaf(i.index),[u,c]=0===i.length?[l,a]:this.quill.getLeaf(i.index+i.length),h=l instanceof e().Text?l.value().slice(0,a):"",f=u instanceof e().Text?u.value().slice(c):"",p={collapsed:0===i.length,empty:0===i.length&&o.length()<=1,format:this.quill.getFormat(i),offset:s,prefix:h,suffix:f};n.some((t=>{if(null!=t.collapsed&&t.collapsed!==p.collapsed)return!1;if(null!=t.empty&&t.empty!==p.empty)return!1;if(null!=t.offset&&t.offset!==p.offset)return!1;if(Array.isArray(t.format)){if(t.format.every((function(t){return null==p.format[t]})))return!1}else if("object"==typeof t.format&&!Object.keys(t.format).every((function(e){return!0===t.format[e]?null!=p.format[e]:!1===t.format[e]?null==p.format[e]:S()(t.format[e],p.format[e])})))return!1;return!(null!=t.prefix&&!t.prefix.test(p.prefix))&&(!(null!=t.suffix&&!t.suffix.test(p.suffix))&&!0!==t.handler.call(this,i,p))}))&&t.preventDefault()}))}}function Bt(t,r){const n=t===jt.keys.LEFT?"prefix":"suffix";return{key:t,shiftKey:r,altKey:null,[n]:/^$/,handler:function(n){let i=n.index;t===jt.keys.RIGHT&&(i+=n.length+1);const[o]=this.quill.getLeaf(i);return!(o instanceof e().Embed)||(t===jt.keys.LEFT?r?this.quill.setSelection(n.index-1,n.length+1,H.sources.USER):this.quill.setSelection(n.index-1,H.sources.USER):r?this.quill.setSelection(n.index,n.length+1,H.sources.USER):this.quill.setSelection(n.index+n.length+1,H.sources.USER),!1)}}}function Ut(t,e){if(0===t.index||this.quill.getLength()<=1)return;let[r]=this.quill.getLine(t.index),n={};if(0===e.offset){let[e]=this.quill.getLine(t.index-1);if(null!=e&&e.length()>1){let e=r.formats(),i=this.quill.getFormat(t.index-1,1);n=s().attributes.diff(e,i)||{}}}let i=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(e.prefix)?2:1;this.quill.deleteText(t.index-i,i,H.sources.USER),Object.keys(n).length>0&&this.quill.formatLine(t.index-i,i,n,H.sources.USER),this.quill.focus()}function Dt(t,e){let r=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(e.suffix)?2:1;if(t.index>=this.quill.getLength()-r)return;let n={},i=0,[o]=this.quill.getLine(t.index);if(e.offset>=o.length()-1){let[e]=this.quill.getLine(t.index+1);if(e){let r=o.formats(),l=this.quill.getFormat(t.index,1);n=s().attributes.diff(r,l)||{},i=e.length()}}this.quill.deleteText(t.index,r,H.sources.USER),Object.keys(n).length>0&&this.quill.formatLine(t.index+i-1,r,n,H.sources.USER)}function Mt(t){let e=this.quill.getLines(t),r={};if(e.length>1){let t=e[0].formats(),n=e[e.length-1].formats();r=s().attributes.diff(n,t)||{}}this.quill.deleteText(t,H.sources.USER),Object.keys(r).length>0&&this.quill.formatLine(t.index,1,r,H.sources.USER),this.quill.setSelection(t.index,H.sources.SILENT),this.quill.focus()}function Ft(t,r){t.length>0&&this.quill.scroll.deleteAt(t.index,t.length);let n=Object.keys(r.format).reduce((function(t,n){return e().query(n,e().Scope.BLOCK)&&!Array.isArray(r.format[n])&&(t[n]=r.format[n]),t}),{});this.quill.insertText(t.index,"\n",n,H.sources.USER),this.quill.setSelection(t.index+1,H.sources.SILENT),this.quill.focus(),Object.keys(r.format).forEach((t=>{null==n[t]&&(Array.isArray(r.format[t])||"link"!==t&&this.quill.format(t,r.format[t],H.sources.USER))}))}function Kt(t){return{key:jt.keys.TAB,shiftKey:!t,format:{"code-block":!0},handler:function(r){let n=e().query("code-block"),i=r.index,o=r.length,[s,l]=this.quill.scroll.descendant(n,i);if(null==s)return;let a=this.quill.getIndex(s),u=s.newlineIndex(l,!0)+1,c=s.newlineIndex(a+l+o),h=s.domNode.textContent.slice(u,c).split("\n");l=0,h.forEach(((e,r)=>{t?(s.insertAt(u+l,n.TAB),l+=n.TAB.length,0===r?i+=n.TAB.length:o+=n.TAB.length):e.startsWith(n.TAB)&&(s.deleteAt(u+l,n.TAB.length),l-=n.TAB.length,0===r?i-=n.TAB.length:o-=n.TAB.length),l+=e.length+1})),this.quill.update(H.sources.USER),this.quill.setSelection(i,o,H.sources.SILENT)}}}function Yt(t){return{key:t[0].toUpperCase(),shortKey:!0,handler:function(e,r){this.quill.format(t,!r.format[t],H.sources.USER)}}}function zt(t){if("string"==typeof t||"number"==typeof t)return zt({key:t});if("object"==typeof t&&(t=x()(t,!1)),"string"==typeof t.key)if(null!=jt.keys[t.key.toUpperCase()])t.key=jt.keys[t.key.toUpperCase()];else{if(1!==t.key.length)return null;t.key=t.key.toUpperCase().charCodeAt(0)}return t.shortKey&&(t[It]=t.shortKey,delete t.shortKey),t}jt.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},jt.DEFAULTS={bindings:{bold:Yt("bold"),italic:Yt("italic"),underline:Yt("underline"),indent:{key:jt.keys.TAB,format:["blockquote","indent","list"],handler:function(t,e){if(e.collapsed&&0!==e.offset)return!0;this.quill.format("indent","+1",H.sources.USER)}},outdent:{key:jt.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function(t,e){if(e.collapsed&&0!==e.offset)return!0;this.quill.format("indent","-1",H.sources.USER)}},"outdent backspace":{key:jt.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function(t,e){null!=e.format.indent?this.quill.format("indent","-1",H.sources.USER):null!=e.format.list&&this.quill.format("list",!1,H.sources.USER)}},"indent code-block":Kt(!0),"outdent code-block":Kt(!1),"remove tab":{key:jt.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function(t){this.quill.deleteText(t.index-1,1,H.sources.USER)}},tab:{key:jt.keys.TAB,handler:function(t){this.quill.history.cutoff();let e=(new(i())).retain(t.index).delete(t.length).insert("\t");this.quill.updateContents(e,H.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index+1,H.sources.SILENT)}},"list empty enter":{key:jt.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function(t,e){this.quill.format("list",!1,H.sources.USER),e.format.indent&&this.quill.format("indent",!1,H.sources.USER)}},"checklist enter":{key:jt.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function(t){let[e,r]=this.quill.getLine(t.index),n=a()({},e.formats(),{list:"checked"}),o=(new(i())).retain(t.index).insert("\n",n).retain(e.length()-r-1).retain(1,{list:"unchecked"});this.quill.updateContents(o,H.sources.USER),this.quill.setSelection(t.index+1,H.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:jt.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function(t,e){let[r,n]=this.quill.getLine(t.index),o=(new(i())).retain(t.index).insert("\n",e.format).retain(r.length()-n-1).retain(1,{header:null});this.quill.updateContents(o,H.sources.USER),this.quill.setSelection(t.index+1,H.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function(t,e){let r,n=e.prefix.length,[o,s]=this.quill.getLine(t.index);if(s>n)return!0;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," ",H.sources.USER),this.quill.history.cutoff();let l=(new(i())).retain(t.index-s).delete(n+1).retain(o.length()-2-s).retain(1,{list:r});this.quill.updateContents(l,H.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index-n,H.sources.SILENT)}},"code exit":{key:jt.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function(t){const[e,r]=this.quill.getLine(t.index),n=(new(i())).retain(t.index+e.length()-r-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(n,H.sources.USER)}},"embed left":Bt(jt.keys.LEFT,!1),"embed left shift":Bt(jt.keys.LEFT,!0),"embed right":Bt(jt.keys.RIGHT,!1),"embed right shift":Bt(jt.keys.RIGHT,!0)}},H.register({"blots/block":g,"blots/block/embed":y,"blots/break":c,"blots/container":Q,"blots/cursor":A,"blots/embed":rt,"blots/inline":d,"blots/scroll":ot,"blots/text":f,"modules/clipboard":wt,"modules/history":Ct,"modules/keyboard":jt}),e().register(g,c,A,d,ot,f);const $t=H;let Wt=I("quill:toolbar");class Gt extends M{constructor(t,e){if(super(t,e),Array.isArray(this.options.container)){let e=document.createElement("div");!function(t,e){Array.isArray(e[0])||(e=[e]);e.forEach((function(e){let r=document.createElement("span");r.classList.add("ql-formats"),e.forEach((function(t){if("string"==typeof t)Ht(r,t);else{let e=Object.keys(t)[0],n=t[e];Array.isArray(n)?function(t,e,r){let n=document.createElement("select");n.classList.add("ql-"+e),r.forEach((function(t){let e=document.createElement("option");!1!==t?e.setAttribute("value",t):e.setAttribute("selected","selected"),n.appendChild(e)})),t.appendChild(n)}(r,e,n):Ht(r,e,n)}})),t.appendChild(r)}))}(e,this.options.container),t.container.parentNode.insertBefore(e,t.container),this.container=e}else"string"==typeof this.options.container?this.container=document.querySelector(this.options.container):this.container=this.options.container;if(!(this.container instanceof HTMLElement))return Wt.error("Container required for toolbar",this.options);this.container.classList.add("ql-toolbar"),this.controls=[],this.handlers={},Object.keys(this.options.handlers).forEach((t=>{this.addHandler(t,this.options.handlers[t])})),[].forEach.call(this.container.querySelectorAll("button, select"),(t=>{this.attach(t)})),this.quill.on(H.events.EDITOR_CHANGE,((t,e)=>{t===H.events.SELECTION_CHANGE&&this.update(e)})),this.quill.on(H.events.SCROLL_OPTIMIZE,(()=>{let[t]=this.quill.selection.getRange();this.update(t)}))}addHandler(t,e){this.handlers[t]=e}attach(t){let r=[].find.call(t.classList,(t=>0===t.indexOf("ql-")));if(!r)return;if(r=r.slice("ql-".length),"BUTTON"===t.tagName&&t.setAttribute("type","button"),null==this.handlers[r]){if(null!=this.quill.scroll.whitelist&&null==this.quill.scroll.whitelist[r])return void Wt.warn("ignoring attaching to disabled format",r,t);if(null==e().query(r))return void Wt.warn("ignoring attaching to nonexistent format",r,t)}let n="SELECT"===t.tagName?"change":"click";t.addEventListener(n,(n=>{let o;if("SELECT"===t.tagName){if(t.selectedIndex<0)return;let e=t.options[t.selectedIndex];o=!e.hasAttribute("selected")&&(e.value||!1)}else o=!t.classList.contains("ql-active")&&(t.value||!t.hasAttribute("value")),n.preventDefault();this.quill.focus();let[s]=this.quill.selection.getRange();if(null!=this.handlers[r])this.handlers[r].call(this,o);else if(e().query(r).prototype instanceof e().Embed){if(o=prompt(`Enter ${r}`),!o)return;this.quill.updateContents((new(i())).retain(s.index).delete(s.length).insert({[r]:o}),H.sources.USER)}else this.quill.format(r,o,H.sources.USER);this.update(s)})),this.controls.push([r,t])}update(t){let e=null==t?{}:this.quill.getFormat(t);this.controls.forEach((function(r){let[n,i]=r;if("SELECT"===i.tagName){let r;if(null==t)r=null;else if(null==e[n])r=i.querySelector("option[selected]");else if(!Array.isArray(e[n])){let t=e[n];"string"==typeof t&&(t=t.replace(/\"/g,'\\"')),r=i.querySelector(`option[value="${t}"]`)}null==r?(i.value="",i.selectedIndex=-1):r.selected=!0}else if(null==t)i.classList.remove("ql-active");else if(i.hasAttribute("value")){let t=e[n]===i.getAttribute("value")||null!=e[n]&&e[n].toString()===i.getAttribute("value")||null==e[n]&&!i.getAttribute("value");i.classList.toggle("ql-active",t)}else i.classList.toggle("ql-active",null!=e[n])}))}}function Ht(t,e,r){let n=document.createElement("button");n.setAttribute("type","button"),n.classList.add("ql-"+e),null!=r&&(n.value=r),t.appendChild(n)}Gt.DEFAULTS={},Gt.DEFAULTS={container:null,handlers:{clean:function(){let t=this.quill.getSelection();if(null!=t)if(0==t.length){let t=this.quill.getFormat();Object.keys(t).forEach((t=>{null!=e().query(t,e().Scope.INLINE)&&this.quill.format(t,!1)}))}else this.quill.removeFormat(t,H.sources.USER)},direction:function(t){let e=this.quill.getFormat().align;"rtl"===t&&null==e?this.quill.format("align","right",H.sources.USER):t||"right"!==e||this.quill.format("align",!1,H.sources.USER),this.quill.format("direction",t,H.sources.USER)},indent:function(t){let e=this.quill.getSelection(),r=this.quill.getFormat(e),n=parseInt(r.indent||0);if("+1"===t||"-1"===t){let e="+1"===t?1:-1;"rtl"===r.direction&&(e*=-1),this.quill.format("indent",n+e,H.sources.USER)}},link:function(t){!0===t&&(t=prompt("Enter link URL:")),this.quill.format("link",t,H.sources.USER)},list:function(t){let e=this.quill.getSelection(),r=this.quill.getFormat(e);"check"===t?"checked"===r.list||"unchecked"===r.list?this.quill.format("list",!1,H.sources.USER):this.quill.format("list","unchecked",H.sources.USER):this.quill.format("list",t,H.sources.USER)}}};let Vt=0;function Xt(t,e){t.setAttribute(e,!("true"===t.getAttribute(e)))}const Zt=class{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.keyCode){case jt.keys.ENTER:this.togglePicker();break;case jt.keys.ESCAPE:this.escape(),t.preventDefault()}})),this.select.addEventListener("change",this.update.bind(this))}togglePicker(){this.container.classList.toggle("ql-expanded"),Xt(this.label,"aria-expanded"),Xt(this.options,"aria-hidden")}buildItem(t){let e=document.createElement("span");return e.tabIndex="0",e.setAttribute("role","button"),e.classList.add("ql-picker-item"),t.hasAttribute("value")&&e.setAttribute("data-value",t.getAttribute("value")),t.textContent&&e.setAttribute("data-label",t.textContent),e.addEventListener("click",(()=>{this.selectItem(e,!0)})),e.addEventListener("keydown",(t=>{switch(t.keyCode){case jt.keys.ENTER:this.selectItem(e,!0),t.preventDefault();break;case jt.keys.ESCAPE:this.escape(),t.preventDefault()}})),e}buildLabel(){let t=document.createElement("span");return t.classList.add("ql-picker-label"),t.innerHTML="/images/vendor/quill/icons/dropdown.svg?c6cd8197101656eb7be9a80dcc6fea48",t.tabIndex="0",t.setAttribute("role","button"),t.setAttribute("aria-expanded","false"),this.container.appendChild(t),t}buildOptions(){let t=document.createElement("span");t.classList.add("ql-picker-options"),t.setAttribute("aria-hidden","true"),t.tabIndex="-1",t.id=`ql-picker-options-${Vt}`,Vt+=1,this.label.setAttribute("aria-controls",t.id),this.options=t,[].slice.call(this.select.options).forEach((e=>{let r=this.buildItem(e);t.appendChild(r),!0===e.selected&&this.selectItem(r)})),this.container.appendChild(t)}buildPicker(){[].slice.call(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,e=!1){let r=this.container.querySelector(".ql-selected");if(t!==r&&(null!=r&&r.classList.remove("ql-selected"),null!=t&&(t.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(t.parentNode.children,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))){if("function"==typeof Event)this.select.dispatchEvent(new Event("change"));else if("object"==typeof Event){let t=document.createEvent("Event");t.initEvent("change",!0,!0),this.select.dispatchEvent(t)}this.close()}}update(){let t;if(this.select.selectedIndex>-1){let 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);let e=null!=t&&t!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",e)}};const Jt=class extends Zt{constructor(t,e){super(t),this.label.innerHTML=e,this.container.classList.add("ql-color-picker"),[].slice.call(this.container.querySelectorAll(".ql-picker-item"),0,7).forEach((function(t){t.classList.add("ql-primary")}))}buildItem(t){let e=super.buildItem(t);return e.style.backgroundColor=t.getAttribute("value")||"",e}selectItem(t,e){super.selectItem(t,e);let r=this.label.querySelector(".ql-color-label"),n=t&&t.getAttribute("data-value")||"";r&&("line"===r.tagName?r.style.stroke=n:r.style.fill=n)}};const Qt=class extends Zt{constructor(t,e){super(t),this.container.classList.add("ql-icon-picker"),[].forEach.call(this.container.querySelectorAll(".ql-picker-item"),(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),t=t||this.defaultItem,this.label.innerHTML=t.innerHTML}};const te=class{constructor(t,e){this.quill=t,this.boundsContainer=e||document.body,this.root=t.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&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){let e=t.left+t.width/2-this.root.offsetWidth/2,r=t.bottom+this.quill.root.scrollTop;this.root.style.left=e+"px",this.root.style.top=r+"px",this.root.classList.remove("ql-flip");let n=this.boundsContainer.getBoundingClientRect(),i=this.root.getBoundingClientRect(),o=0;if(i.right>n.right&&(o=n.right-i.right,this.root.style.left=e+o+"px"),i.left<n.left&&(o=n.left-i.left,this.root.style.left=e+o+"px"),i.bottom>n.bottom){let e=i.bottom-i.top,n=t.bottom-t.top+e;this.root.style.top=r-n+"px",this.root.classList.add("ql-flip")}return o}show(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}},ee=[!1,"center","right","justify"],re=["#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"],ne=[!1,"serif","monospace"],ie=["1","2","3",!1],oe=["small",!1,"large","huge"];class se extends W{constructor(t,e){super(t,e);let r=e=>{if(!document.body.contains(t.root))return document.body.removeEventListener("click",r);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((function(t){t.container.contains(e.target)||t.close()}))};t.emitter.listenDOM("click",document.body,r)}addModule(t){let e=super.addModule(t);return"toolbar"===t&&this.extendToolbar(e),e}buildButtons(t,e){t.forEach((t=>{(t.getAttribute("class")||"").split(/\s+/).forEach((r=>{if(r.startsWith("ql-")&&(r=r.slice("ql-".length),null!=e[r]))if("direction"===r)t.innerHTML=e[r][""]+e[r].rtl;else if("string"==typeof e[r])t.innerHTML=e[r];else{let n=t.value||"";null!=n&&e[r][n]&&(t.innerHTML=e[r][n])}}))}))}buildPickers(t,e){this.pickers=t.map((t=>{if(t.classList.contains("ql-align"))return null==t.querySelector("option")&&ae(t,ee),new Qt(t,e.align);if(t.classList.contains("ql-background")||t.classList.contains("ql-color")){let r=t.classList.contains("ql-background")?"background":"color";return null==t.querySelector("option")&&ae(t,re,"background"===r?"#ffffff":"#000000"),new Jt(t,e[r])}return null==t.querySelector("option")&&(t.classList.contains("ql-font")?ae(t,ne):t.classList.contains("ql-header")?ae(t,ie):t.classList.contains("ql-size")&&ae(t,oe)),new Zt(t)}));this.quill.on(U.events.EDITOR_CHANGE,(()=>{this.pickers.forEach((function(t){t.update()}))}))}}se.DEFAULTS=a()(!0,{},W.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){let t=this.container.querySelector("input.ql-image[type=file]");null==t&&(t=document.createElement("input"),t.setAttribute("type","file"),t.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),t.classList.add("ql-image"),t.addEventListener("change",(()=>{if(null!=t.files&&null!=t.files[0]){let e=new FileReader;e.onload=e=>{let r=this.quill.getSelection(!0);this.quill.updateContents((new(i())).retain(r.index).delete(r.length).insert({image:e.target.result}),U.sources.USER),this.quill.setSelection(r.index+1,U.sources.SILENT),t.value=""},e.readAsDataURL(t.files[0])}})),this.container.appendChild(t)),t.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});class le extends te{constructor(t,e){super(t,e),this.textbox=this.root.querySelector('input[type="text"]'),this.listen()}listen(){this.textbox.addEventListener("keydown",(t=>{jt.match(t,"enter")?(this.save(),t.preventDefault()):jt.match(t,"escape")&&(this.cancel(),t.preventDefault())}))}cancel(){this.hide()}edit(t="link",e=null){this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),null!=e?this.textbox.value=e:t!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute(`data-${t}`)||""),this.root.setAttribute("data-mode",t)}restoreFocus(){let t=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=t}save(){let t=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":{let e=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",t,U.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",t,U.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_-]+)/);if(e)return(e[1]||"https")+"://www.youtube.com/embed/"+e[2]+"?showinfo=0";if(e=t.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))return(e[1]||"https")+"://player.vimeo.com/video/"+e[2]+"/";return t}(t);case"formula":{if(!t)break;let e=this.quill.getSelection(!0);if(null!=e){let r=e.index+e.length;this.quill.insertEmbed(r,this.root.getAttribute("data-mode"),t,U.sources.USER),"formula"===this.root.getAttribute("data-mode")&&this.quill.insertText(r+1," ",U.sources.USER),this.quill.setSelection(r+2,U.sources.USER)}break}}this.textbox.value="",this.hide()}}function ae(t,e,r=!1){e.forEach((function(e){let n=document.createElement("option");e===r?n.setAttribute("selected","selected"):n.setAttribute("value",e),t.appendChild(n)}))}class ue extends d{static create(t){let e=super.create(t);return t=this.sanitize(t),e.setAttribute("href",t),e.setAttribute("rel","noopener noreferrer"),e.setAttribute("target","_blank"),e}static formats(t){return t.getAttribute("href")}static sanitize(t){return function(t,e){let r=document.createElement("a");r.href=t;let n=r.href.slice(0,r.href.indexOf(":"));return e.indexOf(n)>-1}(t,this.PROTOCOL_WHITELIST)?t:this.SANITIZED_URL}format(t,e){if(t!==this.statics.blotName||!e)return super.format(t,e);e=this.constructor.sanitize(e),this.domNode.setAttribute("href",e)}}ue.blotName="link",ue.tagName="A",ue.SANITIZED_URL="about:blank",ue.PROTOCOL_WHITELIST=["http","https","mailto","tel"];var ce=r(3964),he=r.n(ce);const fe=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]];class pe extends se{constructor(t,e){null!=e.modules.toolbar&&null==e.modules.toolbar.container&&(e.modules.toolbar.container=fe),super(t,e),this.quill.container.classList.add("ql-snow")}extendToolbar(t){t.container.classList.add("ql-snow"),this.buildButtons([].slice.call(t.container.querySelectorAll("button")),he()),this.buildPickers([].slice.call(t.container.querySelectorAll("select")),he()),this.tooltip=new de(this.quill,this.options.bounds),t.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},(function(e,r){t.handlers.link.call(t,!r.format.link)}))}}pe.DEFAULTS=a()(!0,{},se.DEFAULTS,{modules:{toolbar:{handlers:{link:function(t){if(t){let 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),this.quill.theme.tooltip.edit("link",e)}else this.quill.format("link",!1)}}}}});class de extends le{constructor(t,e){super(t,e),this.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){let t=this.linkRange;this.restoreFocus(),this.quill.formatText(t,"link",!1,U.sources.USER),delete this.linkRange}t.preventDefault(),this.hide()})),this.quill.on(U.events.SELECTION_CHANGE,((t,e,r)=>{if(null!=t){if(0===t.length&&r===U.sources.USER){let[e,r]=this.quill.scroll.descendant(ue,t.index);if(null!=e){this.linkRange=new K(t.index-r,e.length());let n=ue.formats(e.domNode);return this.preview.textContent=n,this.preview.setAttribute("href",n),this.show(),void this.position(this.quill.getBounds(this.linkRange))}}else delete this.linkRange;this.hide()}}))}show(){super.show(),this.root.removeAttribute("data-mode")}}de.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("");const ye=pe;$t.register({"modules/toolbar":Gt,"themes/snow":ye})})()})();