diff --git a/dist/js/field.js b/dist/js/field.js index 76283de..0eb5777 100644 --- a/dist/js/field.js +++ b/dist/js/field.js @@ -1,2 +1,2 @@ /*! For license information please see field.js.LICENSE.txt */ -!function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=22)}([function(t,e,n){"use strict";function r(t){this.content=t}n.r(e),n.d(e,"ContentMatch",(function(){return D})),n.d(e,"DOMParser",(function(){return tt})),n.d(e,"DOMSerializer",(function(){return ft})),n.d(e,"Fragment",(function(){return o})),n.d(e,"Mark",(function(){return l})),n.d(e,"MarkType",(function(){return Y})),n.d(e,"Node",(function(){return A})),n.d(e,"NodeRange",(function(){return C})),n.d(e,"NodeType",(function(){return H})),n.d(e,"ReplaceError",(function(){return f})),n.d(e,"ResolvedPos",(function(){return w})),n.d(e,"Schema",(function(){return Z})),n.d(e,"Slice",(function(){return p})),r.prototype={constructor:r,find:function(t){for(var e=0;e>1}},r.from=function(t){if(t instanceof r)return t;var e=[];if(t)for(var n in t)e.push(n,t[n]);return new r(e)};var i=r;var o=function(t,e){if(this.content=t,this.size=e||0,null==e)for(var n=0;nt&&!1!==n(a,r+s,i,o)&&a.content.size){var c=s+1;a.nodesBetween(Math.max(0,t-c),Math.min(a.content.size,e-c),n,r+c)}s=u}},o.prototype.descendants=function(t){this.nodesBetween(0,this.size,t)},o.prototype.textBetween=function(t,e,n,r){var i="",o=!0;return this.nodesBetween(t,e,(function(s,a){s.isText?(i+=s.text.slice(Math.max(t,a)-a,e-a),o=!n):s.isLeaf&&r?(i+=r,o=!n):!o&&s.isBlock&&(i+=n,o=!0)}),0),i},o.prototype.append=function(t){if(!t.size)return this;if(!this.size)return t;var e=this.lastChild,n=t.firstChild,r=this.content.slice(),i=0;for(e.isText&&e.sameMarkup(n)&&(r[r.length-1]=e.withText(e.text+n.text),i=1);it)for(var i=0,s=0;st&&((se)&&(a=a.isText?a.cut(Math.max(0,t-s),Math.min(a.text.length,e-s)):a.cut(Math.max(0,t-s-1),Math.min(a.content.size,e-s-1))),n.push(a),r+=a.nodeSize),s=u}return new o(n,r)},o.prototype.cutByIndex=function(t,e){return t==e?o.empty:0==t&&e==this.content.length?this:new o(this.content.slice(t,e))},o.prototype.replaceChild=function(t,e){var n=this.content[t];if(n==e)return this;var r=this.content.slice(),i=this.size+e.nodeSize-n.nodeSize;return r[t]=e,new o(r,i)},o.prototype.addToStart=function(t){return new o([t].concat(this.content),this.size+t.nodeSize)},o.prototype.addToEnd=function(t){return new o(this.content.concat(t),this.size+t.nodeSize)},o.prototype.eq=function(t){if(this.content.length!=t.content.length)return!1;for(var e=0;ethis.size||t<0)throw new RangeError("Position "+t+" outside of fragment ("+this+")");for(var n=0,r=0;;n++){var i=r+this.child(n).nodeSize;if(i>=t)return i==t||e>0?u(n+1,i):u(n,r);r=i}},o.prototype.toString=function(){return"<"+this.toStringInner()+">"},o.prototype.toStringInner=function(){return this.content.join(", ")},o.prototype.toJSON=function(){return this.content.length?this.content.map((function(t){return t.toJSON()})):null},o.fromJSON=function(t,e){if(!e)return o.empty;if(!Array.isArray(e))throw new RangeError("Invalid input for Fragment.fromJSON");return new o(e.map(t.nodeFromJSON))},o.fromArray=function(t){if(!t.length)return o.empty;for(var e,n=0,r=0;rthis.type.rank&&(e||(e=t.slice(0,r)),e.push(this),n=!0),e&&e.push(i)}}return e||(e=t.slice()),n||e.push(this),e},l.prototype.removeFromSet=function(t){for(var e=0;et.depth)throw new f("Inserted content deeper than insertion position");if(t.depth-n.openStart!=e.depth-n.openEnd)throw new f("Inconsistent open depths");return function t(e,n,r,i){var s=e.index(i),a=e.node(i);if(s==n.index(i)&&i=0;i--)r=e.node(i).copy(o.from(r));return{start:r.resolveNoCache(t.openStart+n),end:r.resolveNoCache(r.content.size-t.openEnd-n)}}(r,e),l=c.start,f=c.end;return y(a,function t(e,n,r,i,s){var a=e.depth>s&&v(e,n,s+1),u=i.depth>s&&v(r,i,s+1),c=[];g(null,e,s,c),a&&u&&n.index(s)==r.index(s)?(_(a,u),m(y(a,t(e,n,r,i,s+1)),c)):(a&&m(y(a,b(e,n,s+1)),c),g(n,r,s,c),u&&m(y(u,b(r,i,s+1)),c));return g(i,null,s,c),new o(c)}(e,l,f,n,i))}var p=e.parent,h=p.content;return y(p,h.cut(0,e.parentOffset).append(r.content).append(h.cut(n.parentOffset)))}return y(a,b(e,n,i))}(t,e,n,0)}function _(t,e){if(!e.type.compatibleContent(t.type))throw new f("Cannot join "+e.type.name+" onto "+t.type.name)}function v(t,e,n){var r=t.node(n);return _(r,e.node(n)),r}function m(t,e){var n=e.length-1;n>=0&&t.isText&&t.sameMarkup(e[n])?e[n]=t.withText(e[n].text+t.text):e.push(t)}function g(t,e,n,r){var i=(e||t).node(n),o=0,s=e?e.index(n):i.childCount;t&&(o=t.index(n),t.depth>n?o++:t.textOffset&&(m(t.nodeAfter,r),o++));for(var a=o;an)&&m(y(v(t,e,n+1),b(t,e,n+1)),r);return g(e,null,n,r),new o(r)}h.size.get=function(){return this.content.size-this.openStart-this.openEnd},p.prototype.insertAt=function(t,e){var n=function t(e,n,r,i){var o=e.findIndex(n),s=o.index,a=o.offset,u=e.maybeChild(s);if(a==n||u.isText)return i&&!i.canReplace(s,s,r)?null:e.cut(0,n).append(r).append(e.cut(n));var c=t(u.content,n-a-1,r);return c&&e.replaceChild(s,u.copy(c))}(this.content,t+this.openStart,e,null);return n&&new p(n,this.openStart,this.openEnd)},p.prototype.removeBetween=function(t,e){return new p(function t(e,n,r){var i=e.findIndex(n),o=i.index,s=i.offset,a=e.maybeChild(o),u=e.findIndex(r),c=u.index,l=u.offset;if(s==n||a.isText){if(l!=r&&!e.child(c).isText)throw new RangeError("Removing non-flat range");return e.cut(0,n).append(e.cut(r))}if(o!=c)throw new RangeError("Removing non-flat range");return e.replaceChild(o,a.copy(t(a.content,n-s-1,r-s-1)))}(this.content,t+this.openStart,e+this.openStart),this.openStart,this.openEnd)},p.prototype.eq=function(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd},p.prototype.toString=function(){return this.content+"("+this.openStart+","+this.openEnd+")"},p.prototype.toJSON=function(){if(!this.content.size)return null;var t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t},p.fromJSON=function(t,e){if(!e)return p.empty;var n=e.openStart||0,r=e.openEnd||0;if("number"!=typeof n||"number"!=typeof r)throw new RangeError("Invalid input for Slice.fromJSON");return new p(o.fromJSON(t,e.content),n,r)},p.maxOpen=function(t,e){void 0===e&&(e=!0);for(var n=0,r=0,i=t.firstChild;i&&!i.isLeaf&&(e||!i.type.spec.isolating);i=i.firstChild)n++;for(var o=t.lastChild;o&&!o.isLeaf&&(e||!o.type.spec.isolating);o=o.lastChild)r++;return new p(t,n,r)},Object.defineProperties(p.prototype,h),p.empty=new p(o.empty,0,0);var w=function(t,e,n){this.pos=t,this.path=e,this.depth=e.length/3-1,this.parentOffset=n},x={parent:{configurable:!0},doc:{configurable:!0},textOffset:{configurable:!0},nodeAfter:{configurable:!0},nodeBefore:{configurable:!0}};w.prototype.resolveDepth=function(t){return null==t?this.depth:t<0?this.depth+t:t},x.parent.get=function(){return this.node(this.depth)},x.doc.get=function(){return this.node(0)},w.prototype.node=function(t){return this.path[3*this.resolveDepth(t)]},w.prototype.index=function(t){return this.path[3*this.resolveDepth(t)+1]},w.prototype.indexAfter=function(t){return t=this.resolveDepth(t),this.index(t)+(t!=this.depth||this.textOffset?1:0)},w.prototype.start=function(t){return 0==(t=this.resolveDepth(t))?0:this.path[3*t-1]+1},w.prototype.end=function(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size},w.prototype.before=function(t){if(!(t=this.resolveDepth(t)))throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[3*t-1]},w.prototype.after=function(t){if(!(t=this.resolveDepth(t)))throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[3*t-1]+this.path[3*t].nodeSize},x.textOffset.get=function(){return this.pos-this.path[this.path.length-1]},x.nodeAfter.get=function(){var t=this.parent,e=this.index(this.depth);if(e==t.childCount)return null;var n=this.pos-this.path[this.path.length-1],r=t.child(e);return n?t.child(e).cut(n):r},x.nodeBefore.get=function(){var t=this.index(this.depth),e=this.pos-this.path[this.path.length-1];return e?this.parent.child(t).cut(0,e):0==t?null:this.parent.child(t-1)},w.prototype.posAtIndex=function(t,e){e=this.resolveDepth(e);for(var n=this.path[3*e],r=0==e?0:this.path[3*e-1]+1,i=0;i0;e--)if(this.start(e)<=t&&this.end(e)>=t)return e;return 0},w.prototype.blockRange=function(t,e){if(void 0===t&&(t=this),t.pos=0;n--)if(t.pos<=this.end(n)&&(!e||e(this.node(n))))return new C(this,t,n)},w.prototype.sameParent=function(t){return this.pos-this.parentOffset==t.pos-t.parentOffset},w.prototype.max=function(t){return t.pos>this.pos?t:this},w.prototype.min=function(t){return t.pos=0&&e<=t.content.size))throw new RangeError("Position "+e+" out of range");for(var n=[],r=0,i=e,o=t;;){var s=o.content.findIndex(i),a=s.index,u=s.offset,c=i-u;if(n.push(o,a,r+u),!c)break;if((o=o.child(a)).isText)break;i=c-1,r+=u+1}return new w(e,n,i)},w.resolveCached=function(t,e){for(var n=0;nt&&this.nodesBetween(t,e,(function(t){return n.isInSet(t.marks)&&(r=!0),!r})),r},E.isBlock.get=function(){return this.type.isBlock},E.isTextblock.get=function(){return this.type.isTextblock},E.inlineContent.get=function(){return this.type.inlineContent},E.isInline.get=function(){return this.type.isInline},E.isText.get=function(){return this.type.isText},E.isLeaf.get=function(){return this.type.isLeaf},E.isAtom.get=function(){return this.type.isAtom},A.prototype.toString=function(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);var t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),R(this.marks,t)},A.prototype.contentMatchAt=function(t){var e=this.type.contentMatch.matchFragment(this.content,0,t);if(!e)throw new Error("Called contentMatchAt on a node with invalid content");return e},A.prototype.canReplace=function(t,e,n,r,i){void 0===n&&(n=o.empty),void 0===r&&(r=0),void 0===i&&(i=n.childCount);var s=this.contentMatchAt(t).matchFragment(n,r,i),a=s&&s.matchFragment(this.content,e);if(!a||!a.validEnd)return!1;for(var u=r;u=0;n--)e=t[n].type.name+"("+e+")";return e}var D=function(t){this.validEnd=t,this.next=[],this.wrapCache=[]},P={inlineContent:{configurable:!0},defaultType:{configurable:!0},edgeCount:{configurable:!0}};D.parse=function(t,e){var n=new j(t,e);if(null==n.next)return D.empty;var r=I(n);n.next&&n.err("Unexpected trailing text");var i=function(t){var e=Object.create(null);return function n(r){var i=[];r.forEach((function(e){t[e].forEach((function(e){var n=e.term,r=e.to;if(n){var o=i.indexOf(n),s=o>-1&&i[o+1];W(t,r).forEach((function(t){s||i.push(n,s=[]),-1==s.indexOf(t)&&s.push(t)}))}}))}));for(var o=e[r.join(",")]=new D(r.indexOf(t.length-1)>-1),s=0;s>1},D.prototype.edge=function(t){var e=t<<1;if(e>=this.next.length)throw new RangeError("There's no "+t+"th edge in this content match");return{type:this.next[e],next:this.next[e+1]}},D.prototype.toString=function(){var t=[];return function e(n){t.push(n);for(var r=1;r"+t.indexOf(e.next[i+1]);return r})).join("\n")},Object.defineProperties(D.prototype,P),D.empty=new D(!0);var j=function(t,e){this.string=t,this.nodeTypes=e,this.inline=null,this.pos=0,this.tokens=t.split(/\s*(?=\b|\W|$)/),""==this.tokens[this.tokens.length-1]&&this.tokens.pop(),""==this.tokens[0]&&this.tokens.unshift()},$={next:{configurable:!0}};function I(t){var e=[];do{e.push(z(t))}while(t.eat("|"));return 1==e.length?e[0]:{type:"choice",exprs:e}}function z(t){var e=[];do{e.push(L(t))}while(t.next&&")"!=t.next&&"|"!=t.next);return 1==e.length?e[0]:{type:"seq",exprs:e}}function L(t){for(var e=function(t){if(t.eat("(")){var e=I(t);return t.eat(")")||t.err("Missing closing paren"),e}if(!/\W/.test(t.next)){var n=function(t,e){var n=t.nodeTypes,r=n[e];if(r)return[r];var i=[];for(var o in n){var s=n[o];s.groups.indexOf(e)>-1&&i.push(s)}0==i.length&&t.err("No node type or group '"+e+"' found");return i}(t,t.next).map((function(e){return null==t.inline?t.inline=e.isInline:t.inline!=e.isInline&&t.err("Mixing inline and block content"),{type:"name",value:e}}));return t.pos++,1==n.length?n[0]:{type:"choice",exprs:n}}t.err("Unexpected token '"+t.next+"'")}(t);;)if(t.eat("+"))e={type:"plus",expr:e};else if(t.eat("*"))e={type:"star",expr:e};else if(t.eat("?"))e={type:"opt",expr:e};else{if(!t.eat("{"))break;e=B(t,e)}return e}function F(t){/\D/.test(t.next)&&t.err("Expected number, got '"+t.next+"'");var e=Number(t.next);return t.pos++,e}function B(t,e){var n=F(t),r=n;return t.eat(",")&&(r="}"!=t.next?F(t):-1),t.eat("}")||t.err("Unclosed braced range"),{type:"range",min:n,max:r,expr:e}}function V(t,e){return e-t}function W(t,e){var n=[];return function e(r){var i=t[r];if(1==i.length&&!i[0].term)return e(i[0].to);n.push(r);for(var o=0;o-1},H.prototype.allowsMarks=function(t){if(null==this.markSet)return!0;for(var e=0;e-1};var Z=function(t){for(var e in this.spec={},t)this.spec[e]=t[e];this.spec.nodes=i.from(t.nodes),this.spec.marks=i.from(t.marks),this.nodes=H.compile(this.spec.nodes,this),this.marks=Y.compile(this.spec.marks,this);var n=Object.create(null);for(var r in this.nodes){if(r in this.marks)throw new RangeError(r+" can not be both a node and a mark");var o=this.nodes[r],s=o.spec.content||"",a=o.spec.marks;o.contentMatch=n[s]||(n[s]=D.parse(s,this.nodes)),o.inlineContent=o.contentMatch.inlineContent,o.markSet="_"==a?null:a?Q(this,a.split(" ")):""!=a&&o.inlineContent?null:[]}for(var u in this.marks){var c=this.marks[u],l=c.spec.excludes;c.excluded=null==l?[c]:""==l?[]:Q(this,l.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached=Object.create(null),this.cached.wrappings=Object.create(null)};function Q(t,e){for(var n=[],r=0;r-1)&&n.push(s=u)}if(!s)throw new SyntaxError("Unknown mark type: '"+e[r]+"'")}return n}Z.prototype.node=function(t,e,n,r){if("string"==typeof t)t=this.nodeType(t);else{if(!(t instanceof H))throw new RangeError("Invalid node type: "+t);if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}return t.createChecked(e,n,r)},Z.prototype.text=function(t,e){var n=this.nodes.text;return new N(n,n.defaultAttrs,t,l.setFrom(e))},Z.prototype.mark=function(t,e){return"string"==typeof t&&(t=this.marks[t]),t.create(e)},Z.prototype.nodeFromJSON=function(t){return A.fromJSON(this,t)},Z.prototype.markFromJSON=function(t){return l.fromJSON(this,t)},Z.prototype.nodeType=function(t){var e=this.nodes[t];if(!e)throw new RangeError("Unknown node type: "+t);return e};var tt=function(t,e){var n=this;this.schema=t,this.rules=e,this.tags=[],this.styles=[],e.forEach((function(t){t.tag?n.tags.push(t):t.style&&n.styles.push(t)})),this.normalizeLists=!this.tags.some((function(e){if(!/^(ul|ol)\b/.test(e.tag)||!e.node)return!1;var n=t.nodes[e.node];return n.contentMatch.matchType(n)}))};tt.prototype.parse=function(t,e){void 0===e&&(e={});var n=new st(this,e,!1);return n.addAll(t,null,e.from,e.to),n.finish()},tt.prototype.parseSlice=function(t,e){void 0===e&&(e={});var n=new st(this,e,!0);return n.addAll(t,null,e.from,e.to),p.maxOpen(n.finish())},tt.prototype.matchTag=function(t,e){for(var n=0;nt.length&&(61!=i.style.charCodeAt(t.length)||i.style.slice(t.length+1)!=e))){if(i.getAttrs){var o=i.getAttrs(e);if(!1===o)continue;i.attrs=o}return i}}},tt.schemaRules=function(t){var e=[];function n(t){for(var n=null==t.priority?50:t.priority,r=0;r=0;r--){var i=this.nodes[r],o=i.findWrapping(t);if(o&&(!e||e.length>o.length)&&(e=o,n=i,!o.length))break;if(i.solid)break}if(!e)return!1;this.sync(n);for(var s=0;sthis.open){for(;e>this.open;e--)this.nodes[e-1].content.push(this.nodes[e].finish(t));this.nodes.length=this.open+1}},st.prototype.finish=function(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(this.isOpen||this.options.topOpen)},st.prototype.sync=function(t){for(var e=this.open;e>=0;e--)if(this.nodes[e]==t)return void(this.open=e)},at.currentPos.get=function(){this.closeExtra();for(var t=0,e=this.open;e>=0;e--){for(var n=this.nodes[e].content,r=n.length-1;r>=0;r--)t+=n[r].nodeSize;e&&t++}return t},st.prototype.findAtPoint=function(t,e){if(this.find)for(var n=0;n-1)return t.split(/\s*\|\s*/).some(this.matchesContext,this);var n=t.split("/"),r=this.options.context,i=!(this.isOpen||r&&r.parent.type!=this.nodes[0].type),o=-(r?r.depth+1:0)+(i?0:1),s=function(t,a){for(;t>=0;t--){var u=n[t];if(""==u){if(t==n.length-1||0==t)continue;for(;a>=o;a--)if(s(t-1,a))return!0;return!1}var c=a>0||0==a&&i?e.nodes[a].type:r&&a>=o?r.node(a-o).type:null;if(!c||c.name!=u&&-1==c.groups.indexOf(u))return!1;a--}return!0};return s(n.length-1,this.open)},st.prototype.textblockFromContext=function(){var t=this.options.context;if(t)for(var e=t.depth;e>=0;e--){var n=t.node(e).contentMatchAt(t.indexAfter(e)).defaultType;if(n&&n.isTextblock&&n.defaultAttrs)return n}for(var r in this.parser.schema.nodes){var i=this.parser.schema.nodes[r];if(i.isTextblock&&i.defaultAttrs)return i}},st.prototype.addPendingMark=function(t){this.top.pendingMarks=t.addToSet(this.top.pendingMarks)},st.prototype.removePendingMark=function(t,e){for(var n=this.open;n>=0;n--){var r=this.nodes[n];if(r.pendingMarks.lastIndexOf(t)>-1?r.pendingMarks=t.removeFromSet(r.pendingMarks):r.activeMarks=t.removeFromSet(r.activeMarks),r==e)break}},Object.defineProperties(st.prototype,at);var ft=function(t,e){this.nodes=t||{},this.marks=e||{}};function pt(t){var e={};for(var n in t){var r=t[n].spec.toDOM;r&&(e[n]=r)}return e}function ht(t){return t.document||window.document}ft.prototype.serializeFragment=function(t,e,n){var r=this;void 0===e&&(e={}),n||(n=ht(e).createDocumentFragment());var i=n,o=null;return t.forEach((function(t){if(o||t.marks.length){o||(o=[]);for(var n=0,s=0;n=0;r--){var i=this.serializeMark(t.marks[r],t.isInline,e);i&&((i.contentDOM||i.dom).appendChild(n),n=i.dom)}return n},ft.prototype.serializeMark=function(t,e,n){void 0===n&&(n={});var r=this.marks[t.type.name];return r&&ft.renderSpec(ht(n),r(t,e))},ft.renderSpec=function(t,e,n){if(void 0===n&&(n=null),"string"==typeof e)return{dom:t.createTextNode(e)};if(null!=e.nodeType)return{dom:e};var r=e[0],i=r.indexOf(" ");i>0&&(n=r.slice(0,i),r=r.slice(i+1));var o=null,s=n?t.createElementNS(n,r):t.createElement(r),a=e[1],u=1;if(a&&"object"==typeof a&&null==a.nodeType&&!Array.isArray(a))for(var c in u=2,a)if(null!=a[c]){var l=c.indexOf(" ");l>0?s.setAttributeNS(c.slice(0,l),c.slice(l+1),a[c]):s.setAttribute(c,a[c])}for(var f=u;fu)throw new RangeError("Content hole must be the only child of its parent node");return{dom:s,contentDOM:s}}var h=ft.renderSpec(t,p,n),d=h.dom,_=h.contentDOM;if(s.appendChild(d),_){if(o)throw new RangeError("Multiple content holes");o=_}}return{dom:s,contentDOM:o}},ft.fromSchema=function(t){return t.cached.domSerializer||(t.cached.domSerializer=new ft(this.nodesFromSchema(t),this.marksFromSchema(t)))},ft.nodesFromSchema=function(t){var e=pt(t.nodes);return e.text||(e.text=function(t){return t.text}),e},ft.marksFromSchema=function(t){return pt(t.marks)}},function(t,e,n){"use strict";n.r(e),n.d(e,"AllSelection",(function(){return h})),n.d(e,"EditorState",(function(){return x})),n.d(e,"NodeSelection",(function(){return f})),n.d(e,"Plugin",(function(){return O})),n.d(e,"PluginKey",(function(){return M})),n.d(e,"Selection",(function(){return s})),n.d(e,"SelectionRange",(function(){return u})),n.d(e,"TextSelection",(function(){return c})),n.d(e,"Transaction",(function(){return m}));var r=n(0),i=n(2),o=Object.create(null),s=function(t,e,n){this.ranges=n||[new u(t.min(e),t.max(e))],this.$anchor=t,this.$head=e},a={anchor:{configurable:!0},head:{configurable:!0},from:{configurable:!0},to:{configurable:!0},$from:{configurable:!0},$to:{configurable:!0},empty:{configurable:!0}};a.anchor.get=function(){return this.$anchor.pos},a.head.get=function(){return this.$head.pos},a.from.get=function(){return this.$from.pos},a.to.get=function(){return this.$to.pos},a.$from.get=function(){return this.ranges[0].$from},a.$to.get=function(){return this.ranges[0].$to},a.empty.get=function(){for(var t=this.ranges,e=0;e=0;i--){var o=e<0?_(t.node(0),t.node(i),t.before(i+1),t.index(i),e,n):_(t.node(0),t.node(i),t.after(i+1),t.index(i)+1,e,n);if(o)return o}},s.near=function(t,e){return void 0===e&&(e=1),this.findFrom(t,e)||this.findFrom(t,-e)||new h(t.node(0))},s.atStart=function(t){return _(t,t,0,0,1)||new h(t)},s.atEnd=function(t){return _(t,t,t.content.size,t.childCount,-1)||new h(t)},s.fromJSON=function(t,e){if(!e||!e.type)throw new RangeError("Invalid input for Selection.fromJSON");var n=o[e.type];if(!n)throw new RangeError("No selection type "+e.type+" defined");return n.fromJSON(t,e)},s.jsonID=function(t,e){if(t in o)throw new RangeError("Duplicate use of selection JSON ID "+t);return o[t]=e,e.prototype.jsonID=t,e},s.prototype.getBookmark=function(){return c.between(this.$anchor,this.$head).getBookmark()},Object.defineProperties(s.prototype,a),s.prototype.visible=!0;var u=function(t,e){this.$from=t,this.$to=e},c=function(t){function e(e,n){void 0===n&&(n=e),t.call(this,e,n)}t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e;var n={$cursor:{configurable:!0}};return n.$cursor.get=function(){return this.$anchor.pos==this.$head.pos?this.$head:null},e.prototype.map=function(n,r){var i=n.resolve(r.map(this.head));if(!i.parent.inlineContent)return t.near(i);var o=n.resolve(r.map(this.anchor));return new e(o.parent.inlineContent?o:i,i)},e.prototype.replace=function(e,n){if(void 0===n&&(n=r.Slice.empty),t.prototype.replace.call(this,e,n),n==r.Slice.empty){var i=this.$from.marksAcross(this.$to);i&&e.ensureMarks(i)}},e.prototype.eq=function(t){return t instanceof e&&t.anchor==this.anchor&&t.head==this.head},e.prototype.getBookmark=function(){return new l(this.anchor,this.head)},e.prototype.toJSON=function(){return{type:"text",anchor:this.anchor,head:this.head}},e.fromJSON=function(t,n){if("number"!=typeof n.anchor||"number"!=typeof n.head)throw new RangeError("Invalid input for TextSelection.fromJSON");return new e(t.resolve(n.anchor),t.resolve(n.head))},e.create=function(t,e,n){void 0===n&&(n=e);var r=t.resolve(e);return new this(r,n==e?r:t.resolve(n))},e.between=function(n,r,i){var o=n.pos-r.pos;if(i&&!o||(i=o>=0?1:-1),!r.parent.inlineContent){var s=t.findFrom(r,i,!0)||t.findFrom(r,-i,!0);if(!s)return t.near(r,i);r=s.$head}return n.parent.inlineContent||(0==o||(n=(t.findFrom(n,-i,!0)||t.findFrom(n,i,!0)).$anchor).pos0?0:1);i>0?s=0;s+=i){var a=e.child(s);if(a.isAtom){if(!o&&f.isSelectable(a))return f.create(t,n-(i<0?a.nodeSize:0))}else{var u=_(t,a,n+i,i<0?a.childCount:0,i,o);if(u)return u}n+=a.nodeSize*i}}function v(t,e,n){var r=t.steps.length-1;if(!(r0},e.prototype.setStoredMarks=function(t){return this.storedMarks=t,this.updated|=2,this},e.prototype.ensureMarks=function(t){return r.Mark.sameSet(this.storedMarks||this.selection.$from.marks(),t)||this.setStoredMarks(t),this},e.prototype.addStoredMark=function(t){return this.ensureMarks(t.addToSet(this.storedMarks||this.selection.$head.marks()))},e.prototype.removeStoredMark=function(t){return this.ensureMarks(t.removeFromSet(this.storedMarks||this.selection.$head.marks()))},n.storedMarksSet.get=function(){return(2&this.updated)>0},e.prototype.addStep=function(e,n){t.prototype.addStep.call(this,e,n),this.updated=-3&this.updated,this.storedMarks=null},e.prototype.setTime=function(t){return this.time=t,this},e.prototype.replaceSelection=function(t){return this.selection.replace(this,t),this},e.prototype.replaceSelectionWith=function(t,e){var n=this.selection;return!1!==e&&(t=t.mark(this.storedMarks||(n.empty?n.$from.marks():n.$from.marksAcross(n.$to)||r.Mark.none))),n.replaceWith(this,t),this},e.prototype.deleteSelection=function(){return this.selection.replace(this),this},e.prototype.insertText=function(t,e,n){void 0===n&&(n=e);var r=this.doc.type.schema;if(null==e)return t?this.replaceSelectionWith(r.text(t),!0):this.deleteSelection();if(!t)return this.deleteRange(e,n);var i=this.storedMarks;if(!i){var o=this.doc.resolve(e);i=n==e?o.marks():o.marksAcross(this.doc.resolve(n))}return this.replaceRangeWith(e,n,r.text(t,i)),this.selection.empty||this.setSelection(s.near(this.selection.$to)),this},e.prototype.setMeta=function(t,e){return this.meta["string"==typeof t?t:t.key]=e,this},e.prototype.getMeta=function(t){return this.meta["string"==typeof t?t:t.key]},n.isGeneric.get=function(){for(var t in this.meta)return!1;return!0},e.prototype.scrollIntoView=function(){return this.updated|=4,this},n.scrolledIntoView.get=function(){return(4&this.updated)>0},Object.defineProperties(e.prototype,n),e}(i.e);function g(t,e){return e&&t?t.bind(e):t}var y=function(t,e,n){this.name=t,this.init=g(e.init,n),this.apply=g(e.apply,n)},b=[new y("doc",{init:function(t){return t.doc||t.schema.topNodeType.createAndFill()},apply:function(t){return t.doc}}),new y("selection",{init:function(t,e){return t.selection||s.atStart(e.doc)},apply:function(t){return t.selection}}),new y("storedMarks",{init:function(t){return t.storedMarks||null},apply:function(t,e,n,r){return r.selection.$cursor?t.storedMarks:null}}),new y("scrollToSelection",{init:function(){return 0},apply:function(t,e){return t.scrolledIntoView?e+1:e}})],w=function(t,e){var n=this;this.schema=t,this.fields=b.concat(),this.plugins=[],this.pluginsByKey=Object.create(null),e&&e.forEach((function(t){if(n.pluginsByKey[t.key])throw new RangeError("Adding different instances of a keyed plugin ("+t.key+")");n.plugins.push(t),n.pluginsByKey[t.key]=t,t.spec.state&&n.fields.push(new y(t.key,t.spec.state,t))}))},x=function(t){this.config=t},k={schema:{configurable:!0},plugins:{configurable:!0},tr:{configurable:!0}};k.schema.get=function(){return this.config.schema},k.plugins.get=function(){return this.config.plugins},x.prototype.apply=function(t){return this.applyTransaction(t).state},x.prototype.filterTransaction=function(t,e){void 0===e&&(e=-1);for(var n=0;n-1&&S.splice(e,1)},Object.defineProperties(x.prototype,k);var S=[];var O=function(t){this.props={},t.props&&function t(e,n,r){for(var i in e){var o=e[i];o instanceof Function?o=o.bind(n):"handleDOMEvents"==i&&(o=t(o,n,{})),r[i]=o}return r}(t.props,this,this.props),this.spec=t,this.key=t.key?t.key.key:T("plugin")};O.prototype.getState=function(t){return t[this.key]};var C=Object.create(null);function T(t){return t in C?t+"$"+ ++C[t]:(C[t]=0,t+"$")}var M=function(t){void 0===t&&(t="key"),this.key=T(t)};M.prototype.get=function(t){return t.config.pluginsByKey[this.key]},M.prototype.getState=function(t){return t[this.key]}},function(t,e,n){"use strict";n.d(e,"a",(function(){return u})),n.d(e,"b",(function(){return m})),n.d(e,"c",(function(){return v})),n.d(e,"d",(function(){return d})),n.d(e,"e",(function(){return l})),n.d(e,"f",(function(){return S})),n.d(e,"g",(function(){return k})),n.d(e,"h",(function(){return T})),n.d(e,"i",(function(){return w})),n.d(e,"j",(function(){return C})),n.d(e,"k",(function(){return b}));var r=n(0),i=Math.pow(2,16);function o(t){return 65535&t}var s=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=null),this.pos=t,this.deleted=e,this.recover=n},a=function(t,e){void 0===e&&(e=!1),this.ranges=t,this.inverted=e};a.prototype.recover=function(t){var e=0,n=o(t);if(!this.inverted)for(var r=0;rt)break;var l=this.ranges[u+o],f=this.ranges[u+a],p=c+l;if(t<=p){var h=c+r+((l?t==c?-1:t==p?1:e:e)<0?0:f);if(n)return h;var d=t==(e<0?c:p)?null:u/3+(t-c)*i;return new s(h,e<0?t!=c:t!=p,d)}r+=f-l}return n?t+r:new s(t+r)},a.prototype.touches=function(t,e){for(var n=0,r=o(e),i=this.inverted?2:1,s=this.inverted?1:2,a=0;at)break;var c=this.ranges[a+i];if(t<=u+c&&a==3*r)return!0;n+=this.ranges[a+s]-c}return!1},a.prototype.forEach=function(t){for(var e=this.inverted?2:1,n=this.inverted?1:2,r=0,i=0;r=0;e--){var r=t.getMirror(e);this.appendMap(t.maps[e].invert(),null!=r&&r>e?n-r-1:null)}},u.prototype.invert=function(){var t=new u;return t.appendMappingInverted(this),t},u.prototype.map=function(t,e){if(void 0===e&&(e=1),this.mirror)return this._map(t,e,!0);for(var n=this.from;ni&&a0},l.prototype.addStep=function(t,e){this.docs.push(this.doc),this.steps.push(t),this.mapping.appendMap(t.getMap()),this.doc=e},Object.defineProperties(l.prototype,f);var h=Object.create(null),d=function(){};d.prototype.apply=function(t){return p()},d.prototype.getMap=function(){return a.empty},d.prototype.invert=function(t){return p()},d.prototype.map=function(t){return p()},d.prototype.merge=function(t){return null},d.prototype.toJSON=function(){return p()},d.fromJSON=function(t,e){if(!e||!e.stepType)throw new RangeError("Invalid input for Step.fromJSON");var n=h[e.stepType];if(!n)throw new RangeError("No step type "+e.stepType+" defined");return n.fromJSON(t,e)},d.jsonID=function(t,e){if(t in h)throw new RangeError("Duplicate use of step JSON ID "+t);return h[t]=e,e.prototype.jsonID=t,e};var _=function(t,e){this.doc=t,this.failed=e};_.ok=function(t){return new _(t,null)},_.fail=function(t){return new _(null,t)},_.fromReplace=function(t,e,n,i){try{return _.ok(t.replace(e,n,i))}catch(t){if(t instanceof r.ReplaceError)return _.fail(t.message);throw t}};var v=function(t){function e(e,n,r,i){t.call(this),this.from=e,this.to=n,this.slice=r,this.structure=!!i}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.apply=function(t){return this.structure&&g(t,this.from,this.to)?_.fail("Structure replace would overwrite content"):_.fromReplace(t,this.from,this.to,this.slice)},e.prototype.getMap=function(){return new a([this.from,this.to-this.from,this.slice.size])},e.prototype.invert=function(t){return new e(this.from,this.from+this.slice.size,t.slice(this.from,this.to))},e.prototype.map=function(t){var n=t.mapResult(this.from,1),r=t.mapResult(this.to,-1);return n.deleted&&r.deleted?null:new e(n.pos,Math.max(n.pos,r.pos),this.slice)},e.prototype.merge=function(t){if(!(t instanceof e)||t.structure!=this.structure)return null;if(this.from+this.slice.size!=t.from||this.slice.openEnd||t.slice.openStart){if(t.to!=this.from||this.slice.openStart||t.slice.openEnd)return null;var n=this.slice.size+t.slice.size==0?r.Slice.empty:new r.Slice(t.slice.content.append(this.slice.content),t.slice.openStart,this.slice.openEnd);return new e(t.from,this.to,n,this.structure)}var i=this.slice.size+t.slice.size==0?r.Slice.empty:new r.Slice(this.slice.content.append(t.slice.content),this.slice.openStart,t.slice.openEnd);return new e(this.from,this.to+(t.to-t.from),i,this.structure)},e.prototype.toJSON=function(){var t={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t},e.fromJSON=function(t,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new e(n.from,n.to,r.Slice.fromJSON(t,n.slice),!!n.structure)},e}(d);d.jsonID("replace",v);var m=function(t){function e(e,n,r,i,o,s,a){t.call(this),this.from=e,this.to=n,this.gapFrom=r,this.gapTo=i,this.slice=o,this.insert=s,this.structure=!!a}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.apply=function(t){if(this.structure&&(g(t,this.from,this.gapFrom)||g(t,this.gapTo,this.to)))return _.fail("Structure gap-replace would overwrite content");var e=t.slice(this.gapFrom,this.gapTo);if(e.openStart||e.openEnd)return _.fail("Gap is not a flat range");var n=this.slice.insertAt(this.insert,e.content);return n?_.fromReplace(t,this.from,this.to,n):_.fail("Content does not fit in gap")},e.prototype.getMap=function(){return new a([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])},e.prototype.invert=function(t){var n=this.gapTo-this.gapFrom;return new e(this.from,this.from+this.slice.size+n,this.from+this.insert,this.from+this.insert+n,t.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)},e.prototype.map=function(t){var n=t.mapResult(this.from,1),r=t.mapResult(this.to,-1),i=t.map(this.gapFrom,-1),o=t.map(this.gapTo,1);return n.deleted&&r.deleted||ir.pos?null:new e(n.pos,r.pos,i,o,this.slice,this.insert,this.structure)},e.prototype.toJSON=function(){var t={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t},e.fromJSON=function(t,n){if("number"!=typeof n.from||"number"!=typeof n.to||"number"!=typeof n.gapFrom||"number"!=typeof n.gapTo||"number"!=typeof n.insert)throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new e(n.from,n.to,n.gapFrom,n.gapTo,r.Slice.fromJSON(t,n.slice),n.insert,!!n.structure)},e}(d);function g(t,e,n){for(var r=t.resolve(e),i=n-e,o=r.depth;i>0&&o>0&&r.indexAfter(o)==r.node(o).childCount;)o--,i--;if(i>0)for(var s=r.node(o).maybeChild(r.indexAfter(o));i>0;){if(!s||s.isLeaf)return!0;s=s.firstChild,i--}return!1}function y(t,e,n){return(0==e||t.canReplace(e,t.childCount))&&(n==t.childCount||t.canReplace(0,n))}function b(t){for(var e=t.parent.content.cutByIndex(t.startIndex,t.endIndex),n=t.depth;;--n){var r=t.$from.node(n),i=t.$from.index(n),o=t.$to.indexAfter(n);if(no;a--,u--){var c=i.node(a),l=i.index(a);if(c.type.spec.isolating)return!1;var f=c.content.cutByIndex(l,c.childCount),p=r&&r[u]||c;if(p!=c&&(f=f.replaceChild(0,p.type.create(p.attrs))),!c.canReplace(l+1,c.childCount)||!p.type.validContent(f))return!1}var h=i.indexAfter(o),d=r&&r[0];return i.node(o).canReplaceWith(h,h,d?d.type:i.node(o+1).type)}function S(t,e){var n=t.resolve(e),r=n.index();return O(n.nodeBefore,n.nodeAfter)&&n.parent.canReplace(r,r+1)}function O(t,e){return t&&e&&!t.isLeaf&&t.canAppend(e)}function C(t,e,n){void 0===n&&(n=-1);for(var r=t.resolve(e),i=r.depth;;i--){var o=void 0,s=void 0,a=r.index(i);if(i==r.depth?(o=r.nodeBefore,s=r.nodeAfter):n>0?(o=r.node(i+1),a++,s=r.node(i).maybeChild(a)):(o=r.node(i).maybeChild(a-1),s=r.node(i+1)),o&&!o.isTextblock&&O(o,s)&&r.node(i).canReplace(a,a+1))return e;if(0==i)break;e=n<0?r.before(i):r.after(i)}}function T(t,e,n){var r=t.resolve(e);if(!n.content.size)return e;for(var i=n.content,o=0;o=0;a--){var u=a==r.depth?0:r.pos<=(r.start(a+1)+r.end(a+1))/2?-1:1,c=r.index(a)+(u>0?1:0);if(1==s?r.node(a).canReplace(c,c,i):r.node(a).contentMatchAt(c).findWrapping(i.firstChild.type))return 0==u?r.pos:u<0?r.before(a+1):r.after(a+1)}return null}function M(t,e,n){for(var i=[],o=0;oe;p--)h||n.index(p)>0?(h=!0,l=r.Fragment.from(n.node(p).copy(l)),f++):u--;for(var d=r.Fragment.empty,_=0,v=o,g=!1;v>e;v--)g||i.after(v+1)=0;i--)n=r.Fragment.from(e[i].type.create(e[i].attrs,n));var o=t.start,s=t.end;return this.step(new m(o,s,o,s,new r.Slice(n,0,0),e.length,!0))},l.prototype.setBlockType=function(t,e,n,i){var o=this;if(void 0===e&&(e=t),!n.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");var s=this.steps.length;return this.doc.nodesBetween(t,e,(function(t,e){if(t.isTextblock&&!t.hasMarkup(n,i)&&function(t,e,n){var r=t.resolve(e),i=r.index();return r.parent.canReplaceWith(i,i+1,n)}(o.doc,o.mapping.slice(s).map(e),n)){o.clearIncompatible(o.mapping.slice(s).map(e,1),n);var a=o.mapping.slice(s),u=a.map(e,1),c=a.map(e+t.nodeSize,1);return o.step(new m(u,c,u+1,c-1,new r.Slice(r.Fragment.from(n.create(i,null,t.marks)),0,0),1,!0)),!1}})),this},l.prototype.setNodeMarkup=function(t,e,n,i){var o=this.doc.nodeAt(t);if(!o)throw new RangeError("No node at given position");e||(e=o.type);var s=e.create(n,null,i||o.marks);if(o.isLeaf)return this.replaceWith(t,t+o.nodeSize,s);if(!e.validContent(o.content))throw new RangeError("Invalid content for node type "+e.name);return this.step(new m(t,t+o.nodeSize,t+1,t+o.nodeSize-1,new r.Slice(r.Fragment.from(s),0,0),1,!0))},l.prototype.split=function(t,e,n){void 0===e&&(e=1);for(var i=this.doc.resolve(t),o=r.Fragment.empty,s=r.Fragment.empty,a=i.depth,u=i.depth-e,c=e-1;a>u;a--,c--){o=r.Fragment.from(i.node(a).copy(o));var l=n&&n[c];s=r.Fragment.from(l?l.type.create(l.attrs,s):i.node(a).copy(s))}return this.step(new v(t,t,new r.Slice(o.append(s),e,e),!0))},l.prototype.join=function(t,e){void 0===e&&(e=1);var n=new v(t-e,t+e,r.Slice.empty,!0);return this.step(n)};var A=function(t){function e(e,n,r){t.call(this),this.from=e,this.to=n,this.mark=r}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.apply=function(t){var e=this,n=t.slice(this.from,this.to),i=t.resolve(this.from),o=i.node(i.sharedDepth(this.to)),s=new r.Slice(M(n.content,(function(t,n){return n.type.allowsMarkType(e.mark.type)?t.mark(e.mark.addToSet(t.marks)):t}),o),n.openStart,n.openEnd);return _.fromReplace(t,this.from,this.to,s)},e.prototype.invert=function(){return new E(this.from,this.to,this.mark)},e.prototype.map=function(t){var n=t.mapResult(this.from,1),r=t.mapResult(this.to,-1);return n.deleted&&r.deleted||n.pos>=r.pos?null:new e(n.pos,r.pos,this.mark)},e.prototype.merge=function(t){if(t instanceof e&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from)return new e(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark)},e.prototype.toJSON=function(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}},e.fromJSON=function(t,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new e(n.from,n.to,t.markFromJSON(n.mark))},e}(d);d.jsonID("addMark",A);var E=function(t){function e(e,n,r){t.call(this),this.from=e,this.to=n,this.mark=r}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.apply=function(t){var e=this,n=t.slice(this.from,this.to),i=new r.Slice(M(n.content,(function(t){return t.mark(e.mark.removeFromSet(t.marks))})),n.openStart,n.openEnd);return _.fromReplace(t,this.from,this.to,i)},e.prototype.invert=function(){return new A(this.from,this.to,this.mark)},e.prototype.map=function(t){var n=t.mapResult(this.from,1),r=t.mapResult(this.to,-1);return n.deleted&&r.deleted||n.pos>=r.pos?null:new e(n.pos,r.pos,this.mark)},e.prototype.merge=function(t){if(t instanceof e&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from)return new e(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark)},e.prototype.toJSON=function(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}},e.fromJSON=function(t,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new e(n.from,n.to,t.markFromJSON(n.mark))},e}(d);function N(t,e,n){return!n.openStart&&!n.openEnd&&t.start()==e.start()&&t.parent.canReplace(t.index(),e.index(),n.content)}d.jsonID("removeMark",E),l.prototype.addMark=function(t,e,n){var r=this,i=[],o=[],s=null,a=null;return this.doc.nodesBetween(t,e,(function(r,u,c){if(r.isInline){var l=r.marks;if(!n.isInSet(l)&&c.type.allowsMarkType(n.type)){for(var f=Math.max(u,t),p=Math.min(u+r.nodeSize,e),h=n.addToSet(l),d=0;d=0;h--)this.step(o[h]);return this},l.prototype.replace=function(t,e,n){void 0===e&&(e=t),void 0===n&&(n=r.Slice.empty);var i=function(t,e,n,i){if(void 0===n&&(n=e),void 0===i&&(i=r.Slice.empty),e==n&&!i.size)return null;var o=t.resolve(e),s=t.resolve(n);return N(o,s,i)?new v(e,n,i):new R(o,s,i).fit()}(this.doc,t,e,n);return i&&this.step(i),this},l.prototype.replaceWith=function(t,e,n){return this.replace(t,e,new r.Slice(r.Fragment.from(n),0,0))},l.prototype.delete=function(t,e){return this.replace(t,e,r.Slice.empty)},l.prototype.insert=function(t,e){return this.replaceWith(t,t,e)};var R=function(t,e,n){this.$to=e,this.$from=t,this.unplaced=n,this.frontier=[];for(var i=0;i<=t.depth;i++){var o=t.node(i);this.frontier.push({type:o.type,match:o.contentMatchAt(t.indexAfter(i))})}this.placed=r.Fragment.empty;for(var s=t.depth;s>0;s--)this.placed=r.Fragment.from(t.node(s).copy(this.placed))},D={depth:{configurable:!0}};function P(t,e,n){return 0==e?t.cutByIndex(n):t.replaceChild(0,t.firstChild.copy(P(t.firstChild.content,e-1,n)))}function j(t,e,n){return 0==e?t.append(n):t.replaceChild(t.childCount-1,t.lastChild.copy(j(t.lastChild.content,e-1,n)))}function $(t,e){for(var n=0;n1&&(i=i.replaceChild(0,I(i.firstChild,e-1,1==i.childCount?n-1:0))),e>0&&(i=t.type.contentMatch.fillBefore(i).append(i),n<=0&&(i=i.append(t.type.contentMatch.matchFragment(i).fillBefore(r.Fragment.empty,!0)))),t.copy(i)}function z(t,e,n,r,i){var o=t.node(e),s=i?t.indexAfter(e):t.index(e);if(s==o.childCount&&!n.compatibleContent(o.type))return null;var a=r.fillBefore(o.content,!0,s);return a&&!function(t,e,n){for(var r=n;ri){var a=o.contentMatchAt(0),u=a.fillBefore(t).append(t);t=u.append(a.matchFragment(u).fillBefore(r.Fragment.empty,!0))}return t}function F(t,e){for(var n=[],r=Math.min(t.depth,e.depth);r>=0;r--){var i=t.start(r);if(ie.pos+(e.depth-r)||t.node(r).type.spec.isolating||e.node(r).type.spec.isolating)break;i==e.start(r)&&n.push(r)}return n}D.depth.get=function(){return this.frontier.length-1},R.prototype.fit=function(){for(;this.unplaced.size;){var t=this.findFittable();t?this.placeNodes(t):this.openMore()||this.dropNode()}var e=this.mustMoveInline(),n=this.placed.size-this.depth-this.$from.depth,i=this.$from,o=this.close(e<0?this.$to:i.doc.resolve(e));if(!o)return null;for(var s=this.placed,a=i.depth,u=o.depth;a&&u&&1==s.childCount;)s=s.firstChild.content,a--,u--;var c=new r.Slice(s,a,u);return e>-1?new m(i.pos,e,this.$to.pos,this.$to.end(),c,n):c.size||i.pos!=this.$to.pos?new v(i.pos,o.pos,c):void 0},R.prototype.findFittable=function(){for(var t=1;t<=2;t++)for(var e=this.unplaced.openStart;e>=0;e--)for(var n=void 0,i=(e?(n=$(this.unplaced.content,e-1).firstChild).content:this.unplaced.content).firstChild,o=this.depth;o>=0;o--){var s=this.frontier[o],a=s.type,u=s.match,c=void 0,l=void 0;if(1==t&&(i?u.matchType(i.type)||(l=u.fillBefore(r.Fragment.from(i),!1)):a.compatibleContent(n.type)))return{sliceDepth:e,frontierDepth:o,parent:n,inject:l};if(2==t&&i&&(c=u.findWrapping(i.type)))return{sliceDepth:e,frontierDepth:o,parent:n,wrap:c};if(n&&u.matchType(n.type))break}},R.prototype.openMore=function(){var t=this.unplaced,e=t.content,n=t.openStart,i=t.openEnd,o=$(e,n);return!(!o.childCount||o.firstChild.isLeaf)&&(this.unplaced=new r.Slice(e,n+1,Math.max(i,o.size+n>=e.size-i?n+1:0)),!0)},R.prototype.dropNode=function(){var t=this.unplaced,e=t.content,n=t.openStart,i=t.openEnd,o=$(e,n);if(o.childCount<=1&&n>0){var s=e.size-n<=n+o.size;this.unplaced=new r.Slice(P(e,n-1,1),n-1,s?n-1:i)}else this.unplaced=new r.Slice(P(e,n,1),n,i)},R.prototype.placeNodes=function(t){for(var e=t.sliceDepth,n=t.frontierDepth,i=t.parent,o=t.inject,s=t.wrap;this.depth>n;)this.closeFrontierNode();if(s)for(var a=0;a1||0==l||g.content.size)&&(d=y,p.push(I(g.mark(_.allowedMarks(g.marks)),1==f?l:0,f==c.childCount?m:-1)))}var b=f==c.childCount;b||(m=-1),this.placed=j(this.placed,n,r.Fragment.from(p)),this.frontier[n].match=d,b&&m<0&&i&&i.type==this.frontier[this.depth].type&&this.frontier.length>1&&this.closeFrontierNode();for(var w=0,x=c;w1&&r==this.$to.end(--n);)++r;return r},R.prototype.findCloseLevel=function(t){t:for(var e=Math.min(this.depth,t.depth);e>=0;e--){var n=this.frontier[e],r=n.match,i=n.type,o=e=0;a--){var u=this.frontier[a],c=u.match,l=z(t,a,u.type,c,!0);if(!l||l.childCount)continue t}return{depth:e,fit:s,move:o?t.doc.resolve(t.after(e+1)):t}}}},R.prototype.close=function(t){var e=this.findCloseLevel(t);if(!e)return null;for(;this.depth>e.depth;)this.closeFrontierNode();e.fit.childCount&&(this.placed=j(this.placed,e.depth,e.fit)),t=e.move;for(var n=e.depth+1;n<=t.depth;n++){var r=t.node(n),i=r.type.contentMatch.fillBefore(r.content,!0,t.index(n));this.openFrontierNode(r.type,r.attrs,i)}return t},R.prototype.openFrontierNode=function(t,e,n){var i=this.frontier[this.depth];i.match=i.match.matchType(t),this.placed=j(this.placed,this.depth,r.Fragment.from(t.create(e,n))),this.frontier.push({type:t,match:t.contentMatch})},R.prototype.closeFrontierNode=function(){var t=this.frontier.pop().match.fillBefore(r.Fragment.empty,!0);t.childCount&&(this.placed=j(this.placed,this.frontier.length,t))},Object.defineProperties(R.prototype,D),l.prototype.replaceRange=function(t,e,n){if(!n.size)return this.deleteRange(t,e);var i=this.doc.resolve(t),o=this.doc.resolve(e);if(N(i,o,n))return this.step(new v(t,e,n));var s=F(i,this.doc.resolve(e));0==s[s.length-1]&&s.pop();var a=-(i.depth+1);s.unshift(a);for(var u=i.depth,c=i.pos-1;u>0;u--,c--){var l=i.node(u).type.spec;if(l.defining||l.isolating)break;s.indexOf(u)>-1?a=u:i.before(u)==c&&s.splice(1,0,-u)}for(var f=s.indexOf(a),p=[],h=n.openStart,d=n.content,_=0;;_++){var m=d.firstChild;if(p.push(m),_==n.openStart)break;d=m.content}h>0&&p[h-1].type.spec.defining&&i.node(f).type!=p[h-1].type?h-=1:h>=2&&p[h-1].isTextblock&&p[h-2].type.spec.defining&&i.node(f).type!=p[h-2].type&&(h-=2);for(var g=n.openStart;g>=0;g--){var y=(g+h+1)%(n.openStart+1),b=p[y];if(b)for(var w=0;w=0&&(this.replace(t,e,n),!(this.steps.length>C));T--){var M=s[T];T<0||(t=i.before(M),e=o.after(M))}return this},l.prototype.replaceRangeWith=function(t,e,n){if(!n.isInline&&t==e&&this.doc.resolve(t).parent.content.size){var i=function(t,e,n){var r=t.resolve(e);if(r.parent.canReplaceWith(r.index(),r.index(),n))return e;if(0==r.parentOffset)for(var i=r.depth-1;i>=0;i--){var o=r.index(i);if(r.node(i).canReplaceWith(o,o,n))return r.before(i+1);if(o>0)return null}if(r.parentOffset==r.parent.content.size)for(var s=r.depth-1;s>=0;s--){var a=r.indexAfter(s);if(r.node(s).canReplaceWith(a,a,n))return r.after(s+1);if(a0&&(a||n.node(s-1).canReplace(n.index(s-1),r.indexAfter(s-1))))return this.delete(n.before(s),r.after(s))}for(var u=1;u<=n.depth&&u<=r.depth;u++)if(t-n.start(u)==n.depth-u&&e>n.end(u)&&r.end(u)-e!=r.depth-u)return this.delete(n.before(u),e);return this.delete(t,e)}},function(t,e,n){"use strict";n.r(e),n.d(e,"CellSelection",(function(){return P})),n.d(e,"TableMap",(function(){return d})),n.d(e,"TableView",(function(){return Ct})),n.d(e,"__clipCells",(function(){return L})),n.d(e,"__insertCells",(function(){return V})),n.d(e,"__pastedCells",(function(){return I})),n.d(e,"addColSpan",(function(){return R})),n.d(e,"addColumn",(function(){return rt})),n.d(e,"addColumnAfter",(function(){return ot})),n.d(e,"addColumnBefore",(function(){return it})),n.d(e,"addRow",(function(){return ct})),n.d(e,"addRowAfter",(function(){return ft})),n.d(e,"addRowBefore",(function(){return lt})),n.d(e,"cellAround",(function(){return w})),n.d(e,"colCount",(function(){return M})),n.d(e,"columnIsHeader",(function(){return D})),n.d(e,"columnResizing",(function(){return At})),n.d(e,"columnResizingPluginKey",(function(){return Mt})),n.d(e,"deleteColumn",(function(){return at})),n.d(e,"deleteRow",(function(){return ht})),n.d(e,"deleteTable",(function(){return Ot})),n.d(e,"findCell",(function(){return T})),n.d(e,"fixTables",(function(){return et})),n.d(e,"fixTablesKey",(function(){return tt})),n.d(e,"goToNextCell",(function(){return St})),n.d(e,"handlePaste",(function(){return G})),n.d(e,"inSameTable",(function(){return C})),n.d(e,"isInTable",(function(){return x})),n.d(e,"mergeCells",(function(){return _t})),n.d(e,"moveCellForward",(function(){return O})),n.d(e,"nextCell",(function(){return A})),n.d(e,"pointsAtCell",(function(){return S})),n.d(e,"removeColSpan",(function(){return N})),n.d(e,"removeColumn",(function(){return st})),n.d(e,"removeRow",(function(){return pt})),n.d(e,"rowIsHeader",(function(){return ut})),n.d(e,"selectedRect",(function(){return nt})),n.d(e,"selectionCell",(function(){return k})),n.d(e,"setAttr",(function(){return E})),n.d(e,"setCellAttr",(function(){return gt})),n.d(e,"splitCell",(function(){return vt})),n.d(e,"splitCellWithType",(function(){return mt})),n.d(e,"tableEditing",(function(){return jt})),n.d(e,"tableEditingKey",(function(){return b})),n.d(e,"tableNodeTypes",(function(){return y})),n.d(e,"tableNodes",(function(){return g})),n.d(e,"toggleHeader",(function(){return bt})),n.d(e,"toggleHeaderCell",(function(){return kt})),n.d(e,"toggleHeaderColumn",(function(){return xt})),n.d(e,"toggleHeaderRow",(function(){return wt})),n.d(e,"updateColumnsOnResize",(function(){return Tt}));var r,i,o=n(1),s=n(0),a=n(8),u=n(4),c=n(2);if("undefined"!=typeof WeakMap){var l=new WeakMap;r=function(t){return l.get(t)},i=function(t,e){return l.set(t,e),e}}else{var f=[],p=0;r=function(t){for(var e=0;er&&(o+=c.attrs.colspan)}for(var l=0;l1&&(n=!0)}-1==e?e=o:e!=o&&(e=Math.max(e,o))}return e}(t),n=t.childCount,r=[],i=0,o=null,s=[],a=0,u=e*n;a=n){(o||(o=[])).push({type:"overlong_rowspan",pos:l,n:g-b});break}for(var w=i+b*e,x=0;x0;e--)if("row"==t.node(e).type.spec.tableRole)return t.node(0).resolve(t.before(e+1));return null}function x(t){for(var e=t.selection.$head,n=e.depth;n>0;n--)if("row"==e.node(n).type.spec.tableRole)return!0;return!1}function k(t){var e=t.selection;return e.$anchorCell?e.$anchorCell.pos>e.$headCell.pos?e.$anchorCell:e.$headCell:e.node&&"cell"==e.node.type.spec.tableRole?e.$anchor:w(e.$head)||function(t){for(var e=t.nodeAfter,n=t.pos;e;e=e.firstChild,n++){var r=e.type.spec.tableRole;if("cell"==r||"header_cell"==r)return t.doc.resolve(n)}for(var i=t.nodeBefore,o=t.pos;i;i=i.lastChild,o--){var s=i.type.spec.tableRole;if("cell"==s||"header_cell"==s)return t.doc.resolve(o-i.nodeSize)}}(e.$head)}function S(t){return"row"==t.parent.type.spec.tableRole&&t.nodeAfter}function O(t){return t.node(0).resolve(t.pos+t.nodeAfter.nodeSize)}function C(t,e){return t.depth==e.depth&&t.pos>=e.start(-1)&&t.pos<=e.end(-1)}function T(t){return d.get(t.node(-1)).findCell(t.pos-t.start(-1))}function M(t){return d.get(t.node(-1)).colCount(t.pos-t.start(-1))}function A(t,e,n){var r=t.start(-1),i=d.get(t.node(-1)).nextCell(t.pos-r,e,n);return null==i?null:t.node(0).resolve(r+i)}function E(t,e,n){var r={};for(var i in t)r[i]=t[i];return r[e]=n,r}function N(t,e,n){void 0===n&&(n=1);var r=E(t,"colspan",t.colspan-n);return r.colwidth&&(r.colwidth=r.colwidth.slice(),r.colwidth.splice(e,n),r.colwidth.some((function(t){return t>0}))||(r.colwidth=null)),r}function R(t,e,n){void 0===n&&(n=1);var r=E(t,"colspan",t.colspan+n);if(r.colwidth){r.colwidth=r.colwidth.slice();for(var i=0;i0||v>0){var m=h.attrs;_>0&&(m=N(m,0,_)),v>0&&(m=N(m,m.colspan-v,v)),h=p.leftr.bottom){var g=E(h.attrs,"rowspan",Math.min(p.bottom,r.bottom)-Math.max(p.top,r.top));h=p.top0)return!1;var n=t+this.$anchorCell.nodeAfter.attrs.rowspan,r=e+this.$headCell.nodeAfter.attrs.rowspan;return Math.max(n,r)==this.$headCell.node(-1).childCount},e.colSelection=function(t,n){void 0===n&&(n=t);var r=d.get(t.node(-1)),i=t.start(-1),o=r.findCell(t.pos-i),s=r.findCell(n.pos-i),a=t.node(0);return o.top<=s.top?(o.top>0&&(t=a.resolve(i+r.map[o.left])),s.bottom0&&(n=a.resolve(i+r.map[s.left])),o.bottom0)return!1;var i=n+this.$anchorCell.nodeAfter.attrs.colspan,o=r+this.$headCell.nodeAfter.attrs.colspan;return Math.max(i,o)==t.width},e.prototype.eq=function(t){return t instanceof e&&t.$anchorCell.pos==this.$anchorCell.pos&&t.$headCell.pos==this.$headCell.pos},e.rowSelection=function(t,n){void 0===n&&(n=t);var r=d.get(t.node(-1)),i=t.start(-1),o=r.findCell(t.pos-i),s=r.findCell(n.pos-i),a=t.node(0);return o.left<=s.left?(o.left>0&&(t=a.resolve(i+r.map[o.top*r.width])),s.right0&&(n=a.resolve(i+r.map[s.top*r.width])),o.right0&&r>0||"table"==e.firstChild.type.spec.tableRole);)n--,r--,e=e.firstChild.content;var i=e.firstChild,o=i.type.spec.tableRole,a=i.type.schema,u=[];if("row"==o)for(var c=0;c=0;o--)for(var a=i.child(o).attrs,u=a.rowspan,c=a.colspan,l=r;l=e.length&&e.push(s.Fragment.empty),n[h]e&&(d=d.type.create(N(d.attrs,d.attrs.colspan,p+d.attrs.colspan-e),d.content)),f.push(d),p+=d.attrs.colspan;for(var _=1;_n&&(x=x.type.create(E(x.attrs,"rowspan",Math.max(1,n-x.attrs.rowspan)),x.content)),y.push(x)}v.push(s.Fragment.from(y))}o=v,i=n}return{width:r,height:i,rows:o}}function F(t,e,n,r,i,o,s,a){if(0==s||s==e.height)return!1;for(var u=!1,c=i;ce.width)for(var f=0,p=0;fe.height){for(var m=[],g=0,b=(e.height-1)*e.width;g=e.width)&&n.nodeAt(e.map[b+g]).type==l.header_cell;m.push(w?c||(c=l.header_cell.createAndFill()):u||(u=l.cell.createAndFill()))}for(var x=l.row.create(null,s.Fragment.from(m)),k=[],S=e.height;S=0;i--){var s=r.node(i);if((n<0?r.index(i):r.indexAfter(i))!=(n<0?0:s.childCount))return null;if("cell"==s.type.spec.tableRole||"header_cell"==s.type.spec.tableRole){var a=r.before(i),u="vert"==e?n>0?"down":"up":n>0?"right":"left";return t.endOfTextblock(u)?a:null}}return null}function Z(t,e){for(;e&&e!=t.dom;e=e.parentNode)if("TD"==e.nodeName||"TH"==e.nodeName)return e}function Q(t,e){var n=t.posAtCoords({left:e.clientX,top:e.clientY});return n&&n?w(t.state.doc.resolve(n.pos)):null}var tt=new o.PluginKey("fix-tables");function et(t,e){var n,r=function(e,r){"table"==e.type.spec.tableRole&&(n=function(t,e,n,r){var i=d.get(e);if(!i.problems)return r;r||(r=t.tr);for(var o,s,a=[],u=0;u0){var k="cell";b.firstChild&&(k=b.firstChild.type.spec.tableRole);for(var S=[],O=0;O0?-1:0;D(r,o,n+s)&&(s=0==n||n==r.width?null:0);for(var a=0;a0&&n0&&r.map[u-1]==c||n0?-1:0;ut(r,o,n+c)&&(c=0==n||n==r.height?null:0);for(var l=0,f=r.width*n;l0&&n0&&p==r.map[f-r.width]){var h=i.nodeAt(p).attrs;t.setNodeMarkup(t.mapping.slice(c).map(p+o),null,E(h,"rowspan",h.rowspan-1)),l+=h.colspan-1}else if(n0&&i[s]==i[s-1]||e.right0&&i[o]==i[o-n]||e.bottom0;e--){var n=t.node(e).type.spec.tableRole;if("cell"===n||"header_cell"===n)return t.node(e)}return null}(o.$from)))return!1;i=w(o.$from).pos}if(1==r.attrs.colspan&&1==r.attrs.rowspan)return!1;if(n){var s=r.attrs,a=[],u=s.colwidth;s.rowspan>1&&(s=E(s,"rowspan",1)),s.colspan>1&&(s=E(s,"colspan",1));for(var c,l=nt(e),f=e.tr,p=0;p=0;r--){var o=t.node(-1).child(r);if(o.childCount)return i-1-o.lastChild.nodeSize;i-=o.nodeSize}}else{if(t.index()0;r--){if("table"==n.node(r).type.spec.tableRole)return e&&e(t.tr.delete(n.before(r),n.after(r)).scrollIntoView()),!0}return!1}var Ct=function(t,e){this.node=t,this.cellMinWidth=e,this.dom=document.createElement("div"),this.dom.className="tableWrapper",this.table=this.dom.appendChild(document.createElement("table")),this.colgroup=this.table.appendChild(document.createElement("colgroup")),Tt(t,this.colgroup,this.table,e),this.contentDOM=this.table.appendChild(document.createElement("tbody"))};function Tt(t,e,n,r,i,o){for(var s=0,a=!0,u=e.firstChild,c=t.firstChild,l=0,f=0;l-1?{class:"resize-cursor"}:null},handleDOMEvents:{mousemove:function(t,n){!function(t,e,n,r,i){var o=Mt.getState(t.state);if(!o.dragging){var s=function(t){for(;t&&"TD"!=t.nodeName&&"TH"!=t.nodeName;)t=t.classList.contains("ProseMirror")?null:t.parentNode;return t}(e.target),a=-1;if(s){var u=s.getBoundingClientRect(),c=u.left,l=u.right;e.clientX-c<=n?a=Nt(t,e,"left"):l-e.clientX<=n&&(a=Nt(t,e,"right"))}if(a!=o.activeHandle){if(!i&&-1!==a){var f=t.state.doc.resolve(a),p=f.node(-1),h=d.get(p),_=f.start(-1);if(h.colCount(f.pos-_)+f.nodeAfter.attrs.colspan-1==h.width-1)return}Dt(t,a)}}}(t,n,e,0,i)},mouseleave:function(t){!function(t){var e=Mt.getState(t.state);e.activeHandle>-1&&!e.dragging&&Dt(t,-1)}(t)},mousedown:function(t,e){!function(t,e,n){var r=Mt.getState(t.state);if(-1==r.activeHandle||r.dragging)return!1;var i=t.state.doc.nodeAt(r.activeHandle),o=function(t,e,n){var r=n.colspan,i=n.colwidth,o=i&&i[i.length-1];if(o)return o;var s=t.domAtPos(e),a=s.node.childNodes[s.offset].offsetWidth,u=r;if(i)for(var c=0;c-1)return function(t,e){for(var n=[],r=t.doc.resolve(e),i=r.node(-1),o=d.get(i),s=r.start(-1),a=o.colCount(r.pos-s)+r.nodeAfter.attrs.colspan,c=0;c=0&&!(e.after(o+1)=0&&!(n.before(s+1)>n.start(s));s--,i--);return r==i&&/row|table/.test(e.node(o).type.spec.tableRole)}(s)?r=o.TextSelection.create(a,s.from):s instanceof o.TextSelection&&function(t){for(var e,n,r=t.$from,i=t.$to,o=r.depth;o>0;o--){var s=r.node(o);if("cell"===s.type.spec.tableRole||"header_cell"===s.type.spec.tableRole){e=s;break}}for(var a=i.depth;a>0;a--){var u=i.node(a);if("cell"===u.type.spec.tableRole||"header_cell"===u.type.spec.tableRole){n=u;break}}return e!==n&&0===i.parentOffset}(s)&&(r=o.TextSelection.create(a,s.$from.start(),s.$from.end()));return r&&(e||(e=t.tr)).setSelection(r),e}(r,et(r,n),e)}})}Et.prototype.apply=function(t){var e=this,n=t.getMeta(Mt);if(n&&null!=n.setHandle)return new Et(n.setHandle,null);if(n&&void 0!==n.setDragging)return new Et(e.activeHandle,n.setDragging);if(e.activeHandle>-1&&t.docChanged){var r=t.mapping.map(e.activeHandle,-1);S(t.doc.resolve(r))||(r=null),e=new Et(r,e.dragging)}return e}},function(t,e,n){"use strict";n.d(e,"a",(function(){return xe})),n.d(e,"b",(function(){return Ce}));var r=n(1),i=n(0),o=n(2),s={};if("undefined"!=typeof navigator&&"undefined"!=typeof document){var a=/Edge\/(\d+)/.exec(navigator.userAgent),u=/MSIE \d/.test(navigator.userAgent),c=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);s.mac=/Mac/.test(navigator.platform);var l=s.ie=!!(u||c||a);s.ie_version=u?document.documentMode||6:c?+c[1]:a?+a[1]:null,s.gecko=!l&&/gecko\/(\d+)/i.test(navigator.userAgent),s.gecko_version=s.gecko&&+(/Firefox\/(\d+)/.exec(navigator.userAgent)||[0,0])[1];var f=!l&&/Chrome\/(\d+)/.exec(navigator.userAgent);s.chrome=!!f,s.chrome_version=f&&+f[1],s.ios=!l&&/AppleWebKit/.test(navigator.userAgent)&&/Mobile\/\w+/.test(navigator.userAgent),s.android=/Android \d/.test(navigator.userAgent),s.webkit="webkitFontSmoothing"in document.documentElement.style,s.safari=/Apple Computer/.test(navigator.vendor),s.webkit_version=s.webkit&&+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]}var p=function(t){for(var e=0;;e++)if(!(t=t.previousSibling))return e},h=function(t){var e=t.parentNode;return e&&11==e.nodeType?e.host:e},d=function(t,e,n){var r=document.createRange();return r.setEnd(t,null==n?t.nodeValue.length:n),r.setStart(t,e||0),r},_=function(t,e,n,r){return n&&(m(t,e,n,r,-1)||m(t,e,n,r,1))},v=/^(img|br|input|textarea|hr)$/i;function m(t,e,n,r,i){for(;;){if(t==n&&e==r)return!0;if(e==(i<0?0:g(t))){var o=t.parentNode;if(1!=o.nodeType||y(t)||v.test(t.nodeName)||"false"==t.contentEditable)return!1;e=p(t)+(i<0?0:1),t=o}else{if(1!=t.nodeType)return!1;if("false"==(t=t.childNodes[e+(i<0?-1:0)]).contentEditable)return!1;e=i<0?g(t):0}}}function g(t){return 3==t.nodeType?t.nodeValue.length:t.childNodes.length}function y(t){for(var e,n=t;n&&!(e=n.pmViewDesc);n=n.parentNode);return e&&e.node&&e.node.isBlock&&(e.dom==t||e.contentDOM==t)}var b=function(t){var e=t.isCollapsed;return e&&s.chrome&&t.rangeCount&&!t.getRangeAt(0).collapsed&&(e=!1),e};function w(t,e){var n=document.createEvent("Event");return n.initEvent("keydown",!0,!0),n.keyCode=t,n.key=n.code=e,n}function x(t){return{left:0,right:t.documentElement.clientWidth,top:0,bottom:t.documentElement.clientHeight}}function k(t,e){return"number"==typeof t?t:t[e]}function S(t){var e=t.getBoundingClientRect();return{left:e.left,right:e.left+t.clientWidth,top:e.top,bottom:e.top+t.clientHeight}}function O(t,e,n){for(var r=t.someProp("scrollThreshold")||0,i=t.someProp("scrollMargin")||5,o=t.dom.ownerDocument,s=n||t.dom;s;s=h(s))if(1==s.nodeType){var a=s==o.body||1!=s.nodeType,u=a?x(o):S(s),c=0,l=0;if(e.topu.bottom-k(r,"bottom")&&(l=e.bottom-u.bottom+k(i,"bottom")),e.leftu.right-k(r,"right")&&(c=e.right-u.right+k(i,"right")),c||l)if(a)o.defaultView.scrollBy(c,l);else{var f=s.scrollLeft,p=s.scrollTop;l&&(s.scrollTop+=l),c&&(s.scrollLeft+=c);var d=s.scrollLeft-f,_=s.scrollTop-p;e={left:e.left-d,top:e.top-_,right:e.right-d,bottom:e.bottom-_}}if(a)break}}function C(t){for(var e=[],n=t.ownerDocument;t&&(e.push({dom:t,top:t.scrollTop,left:t.scrollLeft}),t!=n);t=h(t));return e}function T(t,e){for(var n=0;n=a){s=Math.max(p.bottom,s),a=Math.min(p.top,a);var h=p.left>e.left?p.left-e.left:p.right=(p.left+p.right)/2?1:0));continue}}!n&&(e.left>=p.right&&e.top>=p.top||e.left>=p.left&&e.top>=p.bottom)&&(o=c+1)}}return n&&3==n.nodeType?function(t,e){for(var n=t.nodeValue.length,r=document.createRange(),i=0;i=(o.left+o.right)/2?1:0)}}return{node:t,offset:0}}(n,r):!n||i&&1==n.nodeType?{node:t,offset:o}:A(n,r)}function E(t,e){return t.left>=e.left-1&&t.left<=e.right+1&&t.top>=e.top-1&&t.top<=e.bottom+1}function N(t,e){var n,r,i,o,a=t.root;if(a.caretPositionFromPoint)try{var u=a.caretPositionFromPoint(e.left,e.top);u&&(i=(n=u).offsetNode,o=n.offset)}catch(t){}if(!i&&a.caretRangeFromPoint){var c=a.caretRangeFromPoint(e.left,e.top);c&&(i=(r=c).startContainer,o=r.startOffset)}var l,f=a.elementFromPoint(e.left,e.top+1);if(!f||!t.dom.contains(1!=f.nodeType?f.parentNode:f)){var p=t.dom.getBoundingClientRect();if(!E(e,p))return null;if(!(f=function t(e,n,r){var i=e.childNodes.length;if(i&&r.tope.top&&o++}i==t.dom&&o==i.childNodes.length-1&&1==i.lastChild.nodeType&&e.top>i.lastChild.getBoundingClientRect().bottom?l=t.state.doc.content.size:0!=o&&1==i.nodeType&&"BR"==i.childNodes[o-1].nodeName||(l=function(t,e,n,r){for(var i=-1,o=e;o!=t.dom;){var s=t.docView.nearestDesc(o,!0);if(!s)return null;if(s.node.isBlock&&s.parent){var a=s.dom.getBoundingClientRect();if(a.left>r.left||a.top>r.top)i=s.posBefore;else{if(!(a.right-1?i:t.docView.posFromDOM(e,n)}(t,i,o,e))}null==l&&(l=function(t,e,n){var r=A(e,n),i=r.node,o=r.offset,s=-1;if(1==i.nodeType&&!i.firstChild){var a=i.getBoundingClientRect();s=a.left!=a.right&&n.left>(a.left+a.right)/2?1:-1}return t.docView.posFromDOM(i,o,s)}(t,f,e));var _=t.docView.nearestDesc(f,!0);return{pos:l,inside:_?_.posAtStart-_.border:-1}}function R(t,e){var n=t.getClientRects();return n.length?n[e<0?0:n.length-1]:t.getBoundingClientRect()}function D(t,e){var n=t.docView.domFromPos(e),r=n.node,i=n.offset;if(3==r.nodeType&&(s.webkit||s.gecko)){var o=R(d(r,i,i),0);if(s.gecko&&i&&/\s/.test(r.nodeValue[i-1])&&i0&&ic.top&&("up"==n?c.bottomo.bottom-1))return!1}}return!0}))}(t,e,n):function(t,e,n){var r=e.selection.$head;if(!r.parent.isTextblock)return!1;var i=r.parentOffset,o=!i,s=i==r.parent.content.size,a=getSelection();return $.test(r.parent.textContent)&&a.modify?j(t,e,(function(){var e=a.getRangeAt(0),i=a.focusNode,o=a.focusOffset,s=a.caretBidiLevel;a.modify("move",n,"character");var u=!(r.depth?t.docView.domAfterPos(r.before()):t.dom).contains(1==a.focusNode.nodeType?a.focusNode:a.focusNode.parentNode)||i==a.focusNode&&o==a.focusOffset;return a.removeAllRanges(),a.addRange(e),null!=s&&(a.caretBidiLevel=s),u})):"left"==n||"backward"==n?o:s}(t,e,n))}var B=function(t,e,n,r){this.parent=t,this.children=e,this.dom=n,n.pmViewDesc=this,this.contentDOM=r,this.dirty=0},V={beforePosition:{configurable:!0},size:{configurable:!0},border:{configurable:!0},posBefore:{configurable:!0},posAtStart:{configurable:!0},posAfter:{configurable:!0},posAtEnd:{configurable:!0},contentLost:{configurable:!0}};B.prototype.matchesWidget=function(){return!1},B.prototype.matchesMark=function(){return!1},B.prototype.matchesNode=function(){return!1},B.prototype.matchesHack=function(){return!1},V.beforePosition.get=function(){return!1},B.prototype.parseRule=function(){return null},B.prototype.stopEvent=function(){return!1},V.size.get=function(){for(var t=0,e=0;e0:a)?this.posAtEnd:this.posAtStart},B.prototype.nearestDesc=function(t,e){for(var n=!0,r=t;r;r=r.parentNode){var i=this.getDesc(r);if(i&&(!e||i.node)){if(!n||!i.nodeDOM||(1==i.nodeDOM.nodeType?i.nodeDOM.contains(1==t.nodeType?t:t.parentNode):i.nodeDOM==t))return i;n=!1}}},B.prototype.getDesc=function(t){for(var e=t.pmViewDesc,n=e;n;n=n.parent)if(n==this)return e},B.prototype.posFromDOM=function(t,e,n){for(var r=t;r;r=r.parentNode){var i=this.getDesc(r);if(i)return i.localPosFromDOM(t,e,n)}return-1},B.prototype.descAt=function(t){for(var e=0,n=0;e=c&&e<=u-a.border&&a.node&&a.contentDOM&&this.contentDOM.contains(a.contentDOM))return a.parseRange(t,e,c);t=o;for(var l=s;l>0;l--){var f=this.children[l-1];if(f.size&&f.dom.parentNode==this.contentDOM&&!f.emptyChildAt(1)){r=p(f.dom)+1;break}t-=f.size}-1==r&&(r=0)}if(r>-1&&(u>e||s==this.children.length-1)){e=u;for(var h=s+1;hu&&oe){var g=f;f=p,p=g}var y=document.createRange();y.setEnd(p.node,p.offset),y.setStart(f.node,f.offset),h.removeAllRanges(),h.addRange(y)}}},B.prototype.ignoreMutation=function(t){return!this.contentDOM&&"selection"!=t.type},V.contentLost.get=function(){return this.contentDOM&&this.contentDOM!=this.dom&&!this.dom.contains(this.contentDOM)},B.prototype.markDirty=function(t,e){for(var n=0,r=0;r=n:tn){var s=n+i.border,a=o-i.border;if(t>=s&&e<=a)return this.dirty=t==n||e==o?2:1,void(t!=s||e!=a||!i.contentLost&&i.dom.parentNode==this.contentDOM?i.markDirty(t-s,e-s):i.dirty=3);i.dirty=3}n=o}this.dirty=2},B.prototype.markParentsDirty=function(){for(var t=1,e=this.parent;e;e=e.parent,t++){var n=1==t?2:1;e.dirty0&&(o=ut(o,0,t,r));for(var a=0;ao;)c.push(i[u++]);var g=o+_.nodeSize;if(_.isText){var y=g;u=0&&!a&&u.syncToMarks(s==n.node.childCount?i.Mark.none:n.node.child(s).marks,r,t),u.placeWidget(e,t,o)}),(function(e,n,i,s){u.syncToMarks(e.marks,r,t),u.findNodeMatch(e,n,i,s)||u.updateNextNode(e,n,i,t,s)||u.addNode(e,n,i,t,o),o+=e.nodeSize})),u.syncToMarks(W,r,t),this.node.isTextblock&&u.addTextblockHacks(),u.destroyRest(),(u.changed||2==this.dirty)&&(a&&this.protectLocalComposition(t,a),function t(e,n,r){for(var i=e.firstChild,o=!1,s=0;se+this.node.content.size)){var s=t.root.getSelection(),a=function(t,e){for(;;){if(3==t.nodeType)return t;if(1==t.nodeType&&e>0){if(t.childNodes.length>e&&3==t.childNodes[e].nodeType)return t.childNodes[e];t=t.childNodes[e-1],e=g(t)}else{if(!(1==t.nodeType&&e=n){var l=u.lastIndexOf(e,r-a);if(l>=0&&l+e.length+a>=n)return a+l}}}return-1}(this.node.content,u,i-e,o-e);return c<0?null:{node:a,pos:c,text:u}}}},e.prototype.protectLocalComposition=function(t,e){var n=e.node,r=e.pos,i=e.text;if(!this.getDesc(n)){for(var o=n;o.parentNode!=this.contentDOM;o=o.parentNode){for(;o.previousSibling;)o.parentNode.removeChild(o.previousSibling);for(;o.nextSibling;)o.parentNode.removeChild(o.nextSibling);o.pmViewDesc&&(o.pmViewDesc=null)}var s=new K(this,o,n,i);t.compositionNodes.push(s),this.children=ut(this.children,r,r+i.length,t,s)}},e.prototype.update=function(t,e,n,r){return!(3==this.dirty||!t.sameMarkup(this.node))&&(this.updateInner(t,e,n,r),!0)},e.prototype.updateInner=function(t,e,n,r){this.updateOuterDeco(e),this.node=t,this.innerDeco=n,this.contentDOM&&this.updateChildren(r,this.posAtStart),this.dirty=0},e.prototype.updateOuterDeco=function(t){if(!it(t,this.outerDeco)){var e=1!=this.nodeDOM.nodeType,n=this.dom;this.dom=et(this.dom,this.nodeDOM,tt(this.outerDeco,this.node,e),tt(t,this.node,e)),this.dom!=n&&(n.pmViewDesc=null,this.dom.pmViewDesc=this),this.outerDeco=t}},e.prototype.selectNode=function(){this.nodeDOM.classList.add("ProseMirror-selectednode"),!this.contentDOM&&this.node.type.spec.draggable||(this.dom.draggable=!0)},e.prototype.deselectNode=function(){this.nodeDOM.classList.remove("ProseMirror-selectednode"),!this.contentDOM&&this.node.type.spec.draggable||this.dom.removeAttribute("draggable")},Object.defineProperties(e.prototype,n),e}(B);function J(t,e,n,r,i){return rt(r,e,t),new H(null,t,e,n,r,r,r,i,0)}var G=function(t){function e(e,n,r,i,o,s,a){t.call(this,e,n,r,i,o,null,s,a)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.parseRule=function(){for(var t=this.nodeDOM.parentNode;t&&t!=this.dom&&!t.pmIsDeco;)t=t.parentNode;return{skip:t||!0}},e.prototype.update=function(t,e,n,r){return!(3==this.dirty||0!=this.dirty&&!this.inParent()||!t.sameMarkup(this.node))&&(this.updateOuterDeco(e),0==this.dirty&&t.text==this.node.text||t.text==this.nodeDOM.nodeValue||(this.nodeDOM.nodeValue=t.text,r.trackWrites==this.nodeDOM&&(r.trackWrites=null)),this.node=t,this.dirty=0,!0)},e.prototype.inParent=function(){for(var t=this.parent.contentDOM,e=this.nodeDOM;e;e=e.parentNode)if(e==t)return!0;return!1},e.prototype.domFromPos=function(t){return{node:this.nodeDOM,offset:t}},e.prototype.localPosFromDOM=function(e,n,r){return e==this.nodeDOM?this.posAtStart+Math.min(n,this.node.text.length):t.prototype.localPosFromDOM.call(this,e,n,r)},e.prototype.ignoreMutation=function(t){return"characterData"!=t.type&&"selection"!=t.type},e.prototype.slice=function(t,n,r){var i=this.node.cut(t,n),o=document.createTextNode(i.text);return new e(this.parent,i,this.outerDeco,this.innerDeco,o,o,r)},e}(H),X=function(t){function e(){t.apply(this,arguments)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.parseRule=function(){return{ignore:!0}},e.prototype.matchesHack=function(){return 0==this.dirty},e}(B),Y=function(t){function e(e,n,r,i,o,s,a,u,c,l){t.call(this,e,n,r,i,o,s,a,c,l),this.spec=u}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e.prototype.update=function(e,n,r,i){if(3==this.dirty)return!1;if(this.spec.update){var o=this.spec.update(e,n);return o&&this.updateInner(e,n,r,i),o}return!(!this.contentDOM&&!e.isLeaf)&&t.prototype.update.call(this,e,n,r,i)},e.prototype.selectNode=function(){this.spec.selectNode?this.spec.selectNode():t.prototype.selectNode.call(this)},e.prototype.deselectNode=function(){this.spec.deselectNode?this.spec.deselectNode():t.prototype.deselectNode.call(this)},e.prototype.setSelection=function(e,n,r,i){this.spec.setSelection?this.spec.setSelection(e,n,r):t.prototype.setSelection.call(this,e,n,r,i)},e.prototype.destroy=function(){this.spec.destroy&&this.spec.destroy(),t.prototype.destroy.call(this)},e.prototype.stopEvent=function(t){return!!this.spec.stopEvent&&this.spec.stopEvent(t)},e.prototype.ignoreMutation=function(e){return this.spec.ignoreMutation?this.spec.ignoreMutation(e):t.prototype.ignoreMutation.call(this,e)},e}(H);function Z(t){t&&(this.nodeName=t)}Z.prototype=Object.create(null);var Q=[new Z];function tt(t,e,n){if(0==t.length)return Q;for(var r=n?Q[0]:new Z,i=[r],o=0;o0&&i>=0;i--){var o=e[i],s=o.node;if(s){if(s!=t.child(r-1))break;n.push(o),--r}}return{nodes:n.reverse(),offset:r}}(t.node.content,t.children);this.preMatched=n.nodes,this.preMatchOffset=n.offset};function at(t,e){return t.type.side-e.type.side}function ut(t,e,n,r,i){for(var o=[],s=0,a=0;s=n||l<=e?o.push(u):(cn&&o.push(u.slice(n-c,u.size,r)))}return o}function ct(t,e){var n=t.root.getSelection(),i=t.state.doc;if(!n.focusNode)return null;var o=t.docView.nearestDesc(n.focusNode),s=o&&0==o.size,a=t.docView.posFromDOM(n.focusNode,n.focusOffset);if(a<0)return null;var u,c,l=i.resolve(a);if(b(n)){for(u=l;o&&!o.node;)o=o.parent;if(o&&o.node.isAtom&&r.NodeSelection.isSelectable(o.node)&&o.parent&&(!o.node.isInline||!function(t,e,n){for(var r=0==e,i=e==g(t);r||i;){if(t==n)return!0;var o=p(t);if(!(t=t.parentNode))return!1;r=r&&0==o,i=i&&o==g(t)}}(n.focusNode,n.focusOffset,o.dom))){var f=o.posBefore;c=new r.NodeSelection(a==f?l:i.resolve(f))}}else{var h=t.docView.posFromDOM(n.anchorNode,n.anchorOffset);if(h<0)return null;u=i.resolve(h)}c||(c=mt(t,u,l,"pointer"==e||t.state.selection.head=this.preMatchOffset?this.preMatched[t-this.preMatchOffset]:null},st.prototype.destroyBetween=function(t,e){if(t!=e){for(var n=t;n>1,o=Math.min(i,t.length);r-1)s>this.index&&(this.changed=!0,this.destroyBetween(this.index,s)),this.top=this.top.children[this.index];else{var u=q.create(this.top,t[i],e,n);this.top.children.splice(this.index,0,u),this.top=u,this.changed=!0}this.index=0,i++}},st.prototype.findNodeMatch=function(t,e,n,r){var i=-1,o=r<0?void 0:this.getPreMatch(r),s=this.top.children;if(o&&o.matchesNode(t,e,n))i=s.indexOf(o);else for(var a=this.index,u=Math.min(s.length,a+5);a-1&&a+this.preMatchOffset!=i)return!1;var u=s.dom;if(!(this.lock&&(u==this.lock||1==u.nodeType&&u.contains(this.lock.parentNode))&&!(t.isText&&s.node&&s.node.isText&&s.nodeDOM.nodeValue==t.text&&3!=s.dirty&&it(e,s.outerDeco)))&&s.update(t,e,n,r))return this.destroyBetween(this.index,o),s.dom!=u&&(this.changed=!0),this.index++,!0;break}}return!1},st.prototype.addNode=function(t,e,n,r,i){this.top.children.splice(this.index++,0,H.create(this.top,t,e,n,r,i)),this.changed=!0},st.prototype.placeWidget=function(t,e,n){var r=this.index0?i.max(o):i.min(o),a=s.parent.inlineContent?s.depth?t.doc.resolve(e>0?s.after():s.before()):null:s;return a&&r.Selection.findFrom(a,e)}function bt(t,e){return t.dispatch(t.state.tr.setSelection(e).scrollIntoView()),!0}function wt(t,e,n){var i=t.state.selection;if(!(i instanceof r.TextSelection)){if(i instanceof r.NodeSelection&&i.node.isInline)return bt(t,new r.TextSelection(e>0?i.$to:i.$from));var o=yt(t.state,e);return!!o&&bt(t,o)}if(!i.empty||n.indexOf("s")>-1)return!1;if(t.endOfTextblock(e>0?"right":"left")){var a=yt(t.state,e);return!!(a&&a instanceof r.NodeSelection)&&bt(t,a)}if(!(s.mac&&n.indexOf("m")>-1)){var u,c=i.$head,l=c.textOffset?null:e<0?c.nodeBefore:c.nodeAfter;if(!l||l.isText)return!1;var f=e<0?c.pos-l.nodeSize:c.pos;return!!(l.isAtom||(u=t.docView.descAt(f))&&!u.contentDOM)&&(r.NodeSelection.isSelectable(l)?bt(t,new r.NodeSelection(e<0?t.state.doc.resolve(c.pos-l.nodeSize):c)):!!s.webkit&&bt(t,new r.TextSelection(t.state.doc.resolve(e<0?f:f+l.nodeSize))))}}function xt(t){return 3==t.nodeType?t.nodeValue.length:t.childNodes.length}function kt(t){var e=t.pmViewDesc;return e&&0==e.size&&(t.nextSibling||"BR"!=t.nodeName)}function St(t){var e=t.root.getSelection(),n=e.focusNode,r=e.focusOffset;if(n){var i,o,a=!1;for(s.gecko&&1==n.nodeType&&r0){if(1!=n.nodeType)break;var u=n.childNodes[r-1];if(kt(u))i=n,o=--r;else{if(3!=u.nodeType)break;r=(n=u).nodeValue.length}}else{if(Ct(n))break;for(var c=n.previousSibling;c&&kt(c);)i=n.parentNode,o=p(c),c=c.previousSibling;if(c)r=xt(n=c);else{if((n=n.parentNode)==t.dom)break;r=0}}a?Tt(t,e,n,r):i&&Tt(t,e,i,o)}}function Ot(t){var e=t.root.getSelection(),n=e.focusNode,r=e.focusOffset;if(n){for(var i,o,s=xt(n);;)if(r-1)return!1;if(s.mac&&n.indexOf("m")>-1)return!1;var o=i.$from,a=i.$to;if(!o.parent.inlineContent||t.endOfTextblock(e<0?"up":"down")){var u=yt(t.state,e);if(u&&u instanceof r.NodeSelection)return bt(t,u)}if(!o.parent.inlineContent){var c=r.Selection.findFrom(e<0?o:a,e);return!c||bt(t,c)}return!1}function At(t,e){if(!(t.state.selection instanceof r.TextSelection))return!0;var n=t.state.selection,i=n.$head,o=n.$anchor,s=n.empty;if(!i.sameParent(o))return!0;if(!s)return!1;if(t.endOfTextblock(e>0?"forward":"backward"))return!0;var a=!i.textOffset&&(e<0?i.nodeBefore:i.nodeAfter);if(a&&!a.isText){var u=t.state.tr;return e<0?u.delete(i.pos-a.nodeSize,i.pos):u.delete(i.pos,i.pos+a.nodeSize),t.dispatch(u),!0}return!1}function Et(t,e,n){t.domObserver.stop(),e.contentEditable=n,t.domObserver.start()}function Nt(t,e){var n=e.keyCode,r=function(t){var e="";return t.ctrlKey&&(e+="c"),t.metaKey&&(e+="m"),t.altKey&&(e+="a"),t.shiftKey&&(e+="s"),e}(e);return 8==n||s.mac&&72==n&&"c"==r?At(t,-1)||St(t):46==n||s.mac&&68==n&&"c"==r?At(t,1)||Ot(t):13==n||27==n||(37==n?wt(t,-1,r)||St(t):39==n?wt(t,1,r)||Ot(t):38==n?Mt(t,-1,r)||St(t):40==n?function(t){if(s.safari&&!(t.state.selection.$head.parentOffset>0)){var e=t.root.getSelection(),n=e.focusNode,r=e.focusOffset;if(n&&1==n.nodeType&&0==r&&n.firstChild&&"false"==n.firstChild.contentEditable){var i=n.firstChild;Et(t,i,!0),setTimeout((function(){return Et(t,i,!1)}),20)}}}(t)||Mt(t,1,r)||Ot(t):r==(s.mac?"m":"c")&&(66==n||73==n||89==n||90==n))}function Rt(t){var e=t.pmViewDesc;if(e)return e.parseRule();if("BR"==t.nodeName&&t.parentNode){if(s.safari&&/^(ul|ol)$/i.test(t.parentNode.nodeName)){var n=document.createElement("div");return n.appendChild(document.createElement("li")),{skip:n}}if(t.parentNode.lastChild==t||s.safari&&/^(tr|table)$/i.test(t.parentNode.nodeName))return{ignore:!0}}else if("IMG"==t.nodeName&&t.getAttribute("mark-placeholder"))return{ignore:!0}}function Dt(t,e,n,o,a){if(e<0){var u=t.lastSelectionTime>Date.now()-50?t.lastSelectionOrigin:null,c=ct(t,u);if(c&&!t.state.selection.eq(c)){var l=t.state.tr.setSelection(c);"pointer"==u?l.setMeta("pointer",!0):"key"==u&&l.scrollIntoView(),t.dispatch(l)}}else{var f=t.state.doc.resolve(e),p=f.sharedDepth(n);e=f.before(p+1),n=t.state.doc.resolve(n).after(p+1);var h,d,_=t.state.selection,v=function(t,e,n){var r=t.docView.parseRange(e,n),o=r.node,a=r.fromOffset,u=r.toOffset,c=r.from,l=r.to,f=t.root.getSelection(),p=null,h=f.anchorNode;if(h&&t.dom.contains(1==h.nodeType?h:h.parentNode)&&(p=[{node:h,offset:f.anchorOffset}],b(f)||p.push({node:f.focusNode,offset:f.focusOffset})),s.chrome&&8===t.lastKeyCode)for(var d=u;d>a;d--){var _=o.childNodes[d-1],v=_.pmViewDesc;if("BR"==_.nodeType&&!v){u=d;break}if(!v||v.size)break}var m=t.state.doc,g=t.someProp("domParser")||i.DOMParser.fromSchema(t.state.schema),y=m.resolve(c),w=null,x=g.parse(o,{topNode:y.parent,topMatch:y.parent.contentMatchAt(y.index()),topOpen:!0,from:a,to:u,preserveWhitespace:!y.parent.type.spec.code||"full",editableContent:!0,findPositions:p,ruleFromNode:Rt,context:y});if(p&&null!=p[0].pos){var k=p[0].pos,S=p[1]&&p[1].pos;null==S&&(S=k),w={anchor:k+c,head:S+c}}return{doc:x,sel:w,from:c,to:l}}(t,e,n),m=t.state.doc,g=m.slice(v.from,v.to);8===t.lastKeyCode&&Date.now()-100=a?o-r:0)+(u-a),a=o}else if(u=u?o-r:0)+(a-u),u=o}return{start:o,endA:a,endB:u}}(g.content,v.doc.content,v.from,h,d);if(!y){if(!(o&&_ instanceof r.TextSelection&&!_.empty&&_.$head.sameParent(_.$anchor))||t.composing||v.sel&&v.sel.anchor!=v.sel.head){if(v.sel){var x=Pt(t,t.state.doc,v.sel);x&&!x.eq(t.state.selection)&&t.dispatch(t.state.tr.setSelection(x))}return}y={start:_.from,endA:_.to,endB:_.to}}t.domChangeCount++,t.state.selection.fromt.state.selection.from&&y.start<=t.state.selection.from+2?y.start=t.state.selection.from:y.endA=t.state.selection.to-2&&(y.endB+=t.state.selection.to-y.endA,y.endA=t.state.selection.to)),s.ie&&s.ie_version<=11&&y.endB==y.start+1&&y.endA==y.start&&y.start>v.from&&"  "==v.doc.textBetween(y.start-v.from-1,y.start-v.from+1)&&(y.start--,y.endA--,y.endB--);var k,S=v.doc.resolveNoCache(y.start-v.from),O=v.doc.resolveNoCache(y.endB-v.from),C=S.sameParent(O)&&S.parent.inlineContent;if((s.ios&&t.lastIOSEnter>Date.now()-225&&(!C||a.some((function(t){return"DIV"==t.nodeName||"P"==t.nodeName})))||!C&&S.posy.start&&function(t,e,n,r,i){if(!r.parent.isTextblock||n-e<=i.pos-r.pos||jt(r,!0,!1)n||jt(s,!0,!1)e.content.size?null:mt(t,e.resolve(n.anchor),e.resolve(n.head))}function jt(t,e,n){for(var r=t.depth,i=e?t.end():t.pos;r>0&&(e||t.indexAfter(r)==t.node(r).childCount);)r--,i++,e=!1;if(n)for(var o=t.node(r).maybeChild(t.indexAfter(r));o&&!o.isLeaf;)o=o.firstChild,i++;return i}function $t(t,e){for(var n=[],r=e.content,o=e.openStart,s=e.openEnd;o>1&&s>1&&1==r.childCount&&1==r.firstChild.childCount;){o--,s--;var a=r.firstChild;n.push(a.type.name,a.type.hasRequiredAttrs()?a.attrs:null),r=a.content}var u=t.someProp("clipboardSerializer")||i.DOMSerializer.fromSchema(t.state.schema),c=Vt(),l=c.createElement("div");l.appendChild(u.serializeFragment(r,{document:c}));for(var f,p=l.firstChild;p&&1==p.nodeType&&(f=Ft[p.nodeName.toLowerCase()]);){for(var h=f.length-1;h>=0;h--){for(var d=c.createElement(f[h]);l.firstChild;)d.appendChild(l.firstChild);l.appendChild(d)}p=l.firstChild}return p&&1==p.nodeType&&p.setAttribute("data-pm-slice",o+" "+s+" "+JSON.stringify(n)),{dom:l,text:t.someProp("clipboardTextSerializer",(function(t){return t(e)}))||e.content.textBetween(0,e.content.size,"\n\n")}}function It(t,e,n,r,o){var s,a,u=o.parent.type.spec.code;if(!n&&!e)return null;var c=e&&(r||u||!n);if(c){if(t.someProp("transformPastedText",(function(t){e=t(e,u||r)})),u)return new i.Slice(i.Fragment.from(t.state.schema.text(e)),0,0);var l=t.someProp("clipboardTextParser",(function(t){return t(e,o,r)}));l?a=l:(s=document.createElement("div"),e.trim().split(/(?:\r\n?|\n)+/).forEach((function(t){s.appendChild(document.createElement("p")).textContent=t})))}else t.someProp("transformPastedHTML",(function(t){n=t(n)})),s=function(t){var e=/(\s*]*>)*/.exec(t);e&&(t=t.slice(e[0].length));var n,r=Vt().createElement("div"),i=/(?:]*>)*<([a-z][^>\s]+)/i.exec(t),o=0;(n=i&&Ft[i[1].toLowerCase()])&&(t=n.map((function(t){return"<"+t+">"})).join("")+t+n.map((function(t){return""})).reverse().join(""),o=n.length);r.innerHTML=t;for(var s=0;s=0;u-=2){var c=r.nodes[n[u]];if(!c||c.hasRequiredAttrs())break;o=i.Fragment.from(c.create(n[u+1],o)),s++,a++}return new i.Slice(o,s,a)}(function(t,e,n){e=0;r--){var o=n(r);if(o)return o.v}return t}(a.content,o),!1),t.someProp("transformPasted",(function(t){a=t(a)})),a}function zt(t,e,n){void 0===n&&(n=0);for(var r=e.length-1;r>=n;r--)t=e[r].create(null,i.Fragment.from(t));return t}function Lt(t,e,n,r,o,s){var a=e<0?t.firstChild:t.lastChild,u=a.content;return o=n&&(u=e<0?a.contentMatchAt(0).fillBefore(u,t.childCount>1||s<=o).append(u):u.append(a.contentMatchAt(a.childCount).fillBefore(i.Fragment.empty,!0))),t.replaceChild(e<0?0:t.childCount-1,a.copy(u))}var Ft={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]},Bt=null;function Vt(){return Bt||(Bt=document.implementation.createHTMLDocument("title"))}var Wt={childList:!0,characterData:!0,characterDataOldValue:!0,attributes:!0,attributeOldValue:!0,subtree:!0},Ut=s.ie&&s.ie_version<=11,Kt=function(){this.anchorNode=this.anchorOffset=this.focusNode=this.focusOffset=null};Kt.prototype.set=function(t){this.anchorNode=t.anchorNode,this.anchorOffset=t.anchorOffset,this.focusNode=t.focusNode,this.focusOffset=t.focusOffset},Kt.prototype.eq=function(t){return t.anchorNode==this.anchorNode&&t.anchorOffset==this.anchorOffset&&t.focusNode==this.focusNode&&t.focusOffset==this.focusOffset};var qt=function(t,e){var n=this;this.view=t,this.handleDOMChange=e,this.queue=[],this.flushingSoon=-1,this.observer=window.MutationObserver&&new window.MutationObserver((function(t){for(var e=0;et.target.nodeValue.length}))?n.flushSoon():n.flush()})),this.currentSelection=new Kt,Ut&&(this.onCharData=function(t){n.queue.push({target:t.target,type:"characterData",oldValue:t.prevValue}),n.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.suppressingSelectionUpdates=!1};qt.prototype.flushSoon=function(){var t=this;this.flushingSoon<0&&(this.flushingSoon=window.setTimeout((function(){t.flushingSoon=-1,t.flush()}),20))},qt.prototype.forceFlush=function(){this.flushingSoon>-1&&(window.clearTimeout(this.flushingSoon),this.flushingSoon=-1,this.flush())},qt.prototype.start=function(){this.observer&&this.observer.observe(this.view.dom,Wt),Ut&&this.view.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.connectSelection()},qt.prototype.stop=function(){var t=this;if(this.observer){var e=this.observer.takeRecords();if(e.length){for(var n=0;n-1)){var t=this.observer?this.observer.takeRecords():[];this.queue.length&&(t=this.queue.concat(t),this.queue.length=0);var e=this.view.root.getSelection(),n=!this.suppressingSelectionUpdates&&!this.currentSelection.eq(e)&>(this.view)&&!this.ignoreSelectionChange(e),r=-1,i=-1,o=!1,a=[];if(this.view.editable)for(var u=0;u1){var l=a.filter((function(t){return"BR"==t.nodeName}));if(2==l.length){var f=l[0],p=l[1];f.parentNode&&f.parentNode.parentNode==p.parentNode?p.remove():f.remove()}}(r>-1||n)&&(r>-1&&(this.view.docView.markDirty(r,i),function(t){if(Ht)return;Ht=!0,"normal"==getComputedStyle(t.dom).whiteSpace&&console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package.")}(this.view)),this.handleDOMChange(r,i,o,a),this.view.docView.dirty?this.view.updateState(this.view.state):this.currentSelection.eq(e)||lt(this.view))}},qt.prototype.registerMutation=function(t,e){if(e.indexOf(t.target)>-1)return null;var n=this.view.docView.nearestDesc(t.target);if("attributes"==t.type&&(n==this.view.docView||"contenteditable"==t.attributeName||"style"==t.attributeName&&!t.oldValue&&!t.target.getAttribute("style")))return null;if(!n||n.ignoreMutation(t))return null;if("childList"==t.type){var r=t.previousSibling,i=t.nextSibling;if(s.ie&&s.ie_version<=11&&t.addedNodes.length)for(var o=0;oo.depth?e(t,n,o.nodeAfter,o.before(r),i,!0):e(t,n,o.node(r),o.before(r),i,!1)})))return{v:!0}},a=o.depth+1;a>0;a--){var u=s(a);if(u)return u.v}return!1}function ee(t,e,n){t.focused||t.focus();var r=t.state.tr.setSelection(e);"pointer"==n&&r.setMeta("pointer",!0),t.dispatch(r)}function ne(t,e,n,i,o){return te(t,"handleClickOn",e,n,i)||t.someProp("handleClick",(function(n){return n(t,e,i)}))||(o?function(t,e){if(-1==e)return!1;var n,i,o=t.state.selection;o instanceof r.NodeSelection&&(n=o.node);for(var s=t.state.doc.resolve(e),a=s.depth+1;a>0;a--){var u=a>s.depth?s.nodeAfter:s.node(a);if(r.NodeSelection.isSelectable(u)){i=n&&o.$from.depth>0&&a>=o.$from.depth&&s.before(o.$from.depth+1)==o.$from.pos?s.before(o.$from.depth):s.before(a);break}}return null!=i&&(ee(t,r.NodeSelection.create(t.state.doc,i),"pointer"),!0)}(t,n):function(t,e){if(-1==e)return!1;var n=t.state.doc.resolve(e),i=n.nodeAfter;return!!(i&&i.isAtom&&r.NodeSelection.isSelectable(i))&&(ee(t,new r.NodeSelection(n),"pointer"),!0)}(t,n))}function re(t,e,n,r){return te(t,"handleDoubleClickOn",e,n,r)||t.someProp("handleDoubleClick",(function(n){return n(t,e,r)}))}function ie(t,e,n,i){return te(t,"handleTripleClickOn",e,n,i)||t.someProp("handleTripleClick",(function(n){return n(t,e,i)}))||function(t,e){var n=t.state.doc;if(-1==e)return!!n.inlineContent&&(ee(t,r.TextSelection.create(n,0,n.content.size),"pointer"),!0);for(var i=n.resolve(e),o=i.depth+1;o>0;o--){var s=o>i.depth?i.nodeAfter:i.node(o),a=i.before(o);if(s.inlineContent)ee(t,r.TextSelection.create(n,a+1,a+1+s.content.size),"pointer");else{if(!r.NodeSelection.isSelectable(s))continue;ee(t,r.NodeSelection.create(n,a),"pointer")}return!0}}(t,n)}function oe(t){return pe(t)}Gt.keydown=function(t,e){if(t.shiftKey=16==e.keyCode||e.shiftKey,!ue(t,e))if(t.domObserver.forceFlush(),t.lastKeyCode=e.keyCode,t.lastKeyCodeTime=Date.now(),!s.ios||13!=e.keyCode||e.ctrlKey||e.altKey||e.metaKey)t.someProp("handleKeyDown",(function(n){return n(t,e)}))||Nt(t,e)?e.preventDefault():Xt(t,"key");else{var n=Date.now();t.lastIOSEnter=n,t.lastIOSEnterFallbackTimeout=setTimeout((function(){t.lastIOSEnter==n&&(t.someProp("handleKeyDown",(function(e){return e(t,w(13,"Enter"))})),t.lastIOSEnter=0)}),200)}},Gt.keyup=function(t,e){16==e.keyCode&&(t.shiftKey=!1)},Gt.keypress=function(t,e){if(!(ue(t,e)||!e.charCode||e.ctrlKey&&!e.altKey||s.mac&&e.metaKey))if(t.someProp("handleKeyPress",(function(n){return n(t,e)})))e.preventDefault();else{var n=t.state.selection;if(!(n instanceof r.TextSelection&&n.$from.sameParent(n.$to))){var i=String.fromCharCode(e.charCode);t.someProp("handleTextInput",(function(e){return e(t,n.$from.pos,n.$to.pos,i)}))||t.dispatch(t.state.tr.insertText(i).scrollIntoView()),e.preventDefault()}}};var se=s.mac?"metaKey":"ctrlKey";Jt.mousedown=function(t,e){t.shiftKey=e.shiftKey;var n=oe(t),r=Date.now(),i="singleClick";r-t.lastClick.time<500&&function(t,e){var n=e.x-t.clientX,r=e.y-t.clientY;return n*n+r*r<100}(e,t.lastClick)&&!e[se]&&("singleClick"==t.lastClick.type?i="doubleClick":"doubleClick"==t.lastClick.type&&(i="tripleClick")),t.lastClick={time:r,x:e.clientX,y:e.clientY,type:i};var o=t.posAtCoords(Qt(e));o&&("singleClick"==i?t.mouseDown=new ae(t,o,e,n):("doubleClick"==i?re:ie)(t,o.pos,o.inside,e)?e.preventDefault():Xt(t,"pointer"))};var ae=function(t,e,n,i){var o,a,u=this;if(this.view=t,this.startDoc=t.state.doc,this.pos=e,this.event=n,this.flushed=i,this.selectNode=n[se],this.allowDefault=n.shiftKey,e.inside>-1)o=t.state.doc.nodeAt(e.inside),a=e.inside;else{var c=t.state.doc.resolve(e.pos);o=c.parent,a=c.depth?c.before():0}this.mightDrag=null;var l=i?null:n.target,f=l?t.docView.nearestDesc(l,!0):null;this.target=f?f.dom:null,(o.type.spec.draggable&&!1!==o.type.spec.selectable||t.state.selection instanceof r.NodeSelection&&a==t.state.selection.from)&&(this.mightDrag={node:o,pos:a,addAttr:this.target&&!this.target.draggable,setUneditable:this.target&&s.gecko&&!this.target.hasAttribute("contentEditable")}),this.target&&this.mightDrag&&(this.mightDrag.addAttr||this.mightDrag.setUneditable)&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&(this.target.draggable=!0),this.mightDrag.setUneditable&&setTimeout((function(){return u.target.setAttribute("contentEditable","false")}),20),this.view.domObserver.start()),t.root.addEventListener("mouseup",this.up=this.up.bind(this)),t.root.addEventListener("mousemove",this.move=this.move.bind(this)),Xt(t,"pointer")};function ue(t,e){return!!t.composing||!!(s.safari&&Math.abs(e.timeStamp-t.compositionEndedAt)<500)&&(t.compositionEndedAt=-2e8,!0)}ae.prototype.done=function(){this.view.root.removeEventListener("mouseup",this.up),this.view.root.removeEventListener("mousemove",this.move),this.mightDrag&&this.target&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&this.target.removeAttribute("draggable"),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.view.mouseDown=null},ae.prototype.up=function(t){if(this.done(),this.view.dom.contains(3==t.target.nodeType?t.target.parentNode:t.target)){var e=this.pos;this.view.state.doc!=this.startDoc&&(e=this.view.posAtCoords(Qt(t))),this.allowDefault||!e?Xt(this.view,"pointer"):ne(this.view,e.pos,e.inside,t,this.selectNode)?t.preventDefault():this.flushed||s.safari&&this.mightDrag&&!this.mightDrag.node.isAtom||s.chrome&&!(this.view.state.selection instanceof r.TextSelection)&&(e.pos==this.view.state.selection.from||e.pos==this.view.state.selection.to)?(ee(this.view,r.Selection.near(this.view.state.doc.resolve(e.pos)),"pointer"),t.preventDefault()):Xt(this.view,"pointer")}},ae.prototype.move=function(t){!this.allowDefault&&(Math.abs(this.event.x-t.clientX)>4||Math.abs(this.event.y-t.clientY)>4)&&(this.allowDefault=!0),Xt(this.view,"pointer")},Jt.touchdown=function(t){oe(t),Xt(t,"pointer")},Jt.contextmenu=function(t){return oe(t)};var ce=s.android?5e3:-1;function le(t,e){clearTimeout(t.composingTimeout),e>-1&&(t.composingTimeout=setTimeout((function(){return pe(t)}),e))}function fe(t){for(t.composing=!1;t.compositionNodes.length>0;)t.compositionNodes.pop().markParentsDirty()}function pe(t,e){if(t.domObserver.forceFlush(),fe(t),e||t.docView.dirty){var n=ct(t);return n&&!n.eq(t.state.selection)?t.dispatch(t.state.tr.setSelection(n)):t.updateState(t.state),!0}return!1}Gt.compositionstart=Gt.compositionupdate=function(t){if(!t.composing){t.domObserver.flush();var e=t.state,n=e.selection.$from;if(e.selection.empty&&(e.storedMarks||!n.textOffset&&n.parentOffset&&n.nodeBefore.marks.some((function(t){return!1===t.type.spec.inclusive}))))t.markCursor=t.state.storedMarks||n.marks(),pe(t,!0),t.markCursor=null;else if(pe(t),s.gecko&&e.selection.empty&&n.parentOffset&&!n.textOffset&&n.nodeBefore.marks.length)for(var r=t.root.getSelection(),i=r.focusNode,o=r.focusOffset;i&&1==i.nodeType&&0!=o;){var a=o<0?i.lastChild:i.childNodes[o-1];if(!a)break;if(3==a.nodeType){r.collapse(a,a.nodeValue.length);break}i=a,o=-1}t.composing=!0}le(t,ce)},Gt.compositionend=function(t,e){t.composing&&(t.composing=!1,t.compositionEndedAt=e.timeStamp,le(t,20))};var he=s.ie&&s.ie_version<15||s.ios&&s.webkit_version<604;function de(t,e,n,r){var o=It(t,e,n,t.shiftKey,t.state.selection.$from);if(!t.someProp("handlePaste",(function(e){return e(t,r,o||i.Slice.empty)}))&&o){var s=function(t){return 0==t.openStart&&0==t.openEnd&&1==t.content.childCount?t.content.firstChild:null}(o),a=s?t.state.tr.replaceSelectionWith(s,t.shiftKey):t.state.tr.replaceSelection(o);t.dispatch(a.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste"))}}Jt.copy=Gt.cut=function(t,e){var n=t.state.selection,r="cut"==e.type;if(!n.empty){var i=he?null:e.clipboardData,o=$t(t,n.content()),s=o.dom,a=o.text;i?(e.preventDefault(),i.clearData(),i.setData("text/html",s.innerHTML),i.setData("text/plain",a)):function(t,e){if(t.dom.parentNode){var n=t.dom.parentNode.appendChild(document.createElement("div"));n.appendChild(e),n.style.cssText="position: fixed; left: -10000px; top: 10px";var r=getSelection(),i=document.createRange();i.selectNodeContents(e),t.dom.blur(),r.removeAllRanges(),r.addRange(i),setTimeout((function(){n.parentNode&&n.parentNode.removeChild(n),t.focus()}),50)}}(t,s),r&&t.dispatch(t.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))}},Gt.paste=function(t,e){var n=he?null:e.clipboardData,r=n&&n.getData("text/html"),i=n&&n.getData("text/plain");n&&(r||i||n.files.length)?(de(t,i,r,e),e.preventDefault()):function(t,e){if(t.dom.parentNode){var n=t.shiftKey||t.state.selection.$from.parent.type.spec.code,r=t.dom.parentNode.appendChild(document.createElement(n?"textarea":"div"));n||(r.contentEditable="true"),r.style.cssText="position: fixed; left: -10000px; top: 10px",r.focus(),setTimeout((function(){t.focus(),r.parentNode&&r.parentNode.removeChild(r),n?de(t,r.value,null,e):de(t,r.textContent,r.innerHTML,e)}),50)}}(t,e)};var _e=function(t,e){this.slice=t,this.move=e},ve=s.mac?"altKey":"ctrlKey";for(var me in Jt.dragstart=function(t,e){var n=t.mouseDown;if(n&&n.done(),e.dataTransfer){var i=t.state.selection,o=i.empty?null:t.posAtCoords(Qt(e));if(o&&o.pos>=i.from&&o.pos<=(i instanceof r.NodeSelection?i.to-1:i.to));else if(n&&n.mightDrag)t.dispatch(t.state.tr.setSelection(r.NodeSelection.create(t.state.doc,n.mightDrag.pos)));else if(e.target&&1==e.target.nodeType){var s=t.docView.nearestDesc(e.target,!0);if(!s||!s.node.type.spec.draggable||s==t.docView)return;t.dispatch(t.state.tr.setSelection(r.NodeSelection.create(t.state.doc,s.posBefore)))}var a=t.state.selection.content(),u=$t(t,a),c=u.dom,l=u.text;e.dataTransfer.clearData(),e.dataTransfer.setData(he?"Text":"text/html",c.innerHTML),he||e.dataTransfer.setData("text/plain",l),t.dragging=new _e(a,!e[ve])}},Jt.dragend=function(t){window.setTimeout((function(){return t.dragging=null}),50)},Gt.dragover=Gt.dragenter=function(t,e){return e.preventDefault()},Gt.drop=function(t,e){var n=t.dragging;if(t.dragging=null,e.dataTransfer){var s=t.posAtCoords(Qt(e));if(s){var a=t.state.doc.resolve(s.pos);if(a){var u=n&&n.slice||It(t,e.dataTransfer.getData(he?"Text":"text/plain"),he?null:e.dataTransfer.getData("text/html"),!1,a),c=n&&!e[ve];if(t.someProp("handleDrop",(function(n){return n(t,e,u||i.Slice.empty,c)})))e.preventDefault();else if(u){e.preventDefault();var l=u?Object(o.h)(t.state.doc,a.pos,u):a.pos;null==l&&(l=a.pos);var f=t.state.tr;c&&f.deleteSelection();var p=f.mapping.map(l),h=0==u.openStart&&0==u.openEnd&&1==u.content.childCount,d=f.doc;if(h?f.replaceRangeWith(p,p,u.content.firstChild):f.replaceRange(p,p,u),!f.doc.eq(d)){var _=f.doc.resolve(p);if(h&&r.NodeSelection.isSelectable(u.content.firstChild)&&_.nodeAfter&&_.nodeAfter.sameMarkup(u.content.firstChild))f.setSelection(new r.NodeSelection(_));else{var v=f.mapping.map(l);f.mapping.maps[f.mapping.maps.length-1].forEach((function(t,e,n,r){return v=r})),f.setSelection(mt(t,_,f.doc.resolve(v)))}t.focus(),t.dispatch(f.setMeta("uiEvent","drop"))}}}}}},Jt.focus=function(t){t.focused||(t.domObserver.stop(),t.dom.classList.add("ProseMirror-focused"),t.domObserver.start(),t.focused=!0,setTimeout((function(){t.docView&&t.hasFocus()&&!t.domObserver.currentSelection.eq(t.root.getSelection())&<(t)}),20))},Jt.blur=function(t){t.focused&&(t.domObserver.stop(),t.dom.classList.remove("ProseMirror-focused"),t.domObserver.start(),t.domObserver.currentSelection.set({}),t.focused=!1)},Jt.beforeinput=function(t,e){if(s.chrome&&s.android&&"deleteContentBackward"==e.inputType){var n=t.domChangeCount;setTimeout((function(){if(t.domChangeCount==n&&(t.dom.blur(),t.focus(),!t.someProp("handleKeyDown",(function(e){return e(t,w(8,"Backspace"))})))){var e=t.state.selection.$cursor;e&&e.pos>0&&t.dispatch(t.state.tr.delete(e.pos-1,e.pos).scrollIntoView())}}),50)}},Gt)Jt[me]=Gt[me];function ge(t,e){if(t==e)return!0;for(var n in t)if(t[n]!==e[n])return!1;for(var r in e)if(!(r in t))return!1;return!0}var ye=function(t,e){this.spec=e||Oe,this.side=this.spec.side||0,this.toDOM=t};ye.prototype.map=function(t,e,n,r){var i=t.mapResult(e.from+r,this.side<0?-1:1),o=i.pos;return i.deleted?null:new xe(o-n,o-n,this)},ye.prototype.valid=function(){return!0},ye.prototype.eq=function(t){return this==t||t instanceof ye&&(this.spec.key&&this.spec.key==t.spec.key||this.toDOM==t.toDOM&&ge(this.spec,t.spec))};var be=function(t,e){this.spec=e||Oe,this.attrs=t};be.prototype.map=function(t,e,n,r){var i=t.map(e.from+r,this.spec.inclusiveStart?-1:1)-n,o=t.map(e.to+r,this.spec.inclusiveEnd?1:-1)-n;return i>=o?null:new xe(i,o,this)},be.prototype.valid=function(t,e){return e.from=t&&(!i||i(s.spec))&&n.push(s.copy(s.from+r,s.to+r))}for(var a=0;at){var u=this.children[a]+1;this.children[a+2].findInner(t-u,e-u,n,r+u,i)}},Ce.prototype.map=function(t,e,n){return this==Te||0==t.maps.length?this:this.mapInner(t,e,0,0,n||Oe)},Ce.prototype.mapInner=function(t,e,n,r,i){for(var o,s=0;su+o||(e>=a[s]+o?a[s+1]=-1:n>=i&&(c=r-n-(e-t))&&(a[s]+=c,a[s+1]+=c))}},c=0;c=r.content.size){l=!0;continue}var d=n.map(t[f+1]+o,-1)-i,_=r.content.findIndex(h),v=_.index,m=_.offset,g=r.maybeChild(v);if(g&&m==h&&m+g.nodeSize==d){var y=a[f+2].mapInner(n,g,p+1,t[f]+o+1,s);y!=Te?(a[f]=h,a[f+1]=d,a[f+2]=y):(a[f+1]=-2,l=!0)}else l=!0}if(l){var b=Re(function(t,e,n,r,i,o,s){function a(t,e){for(var o=0;os&&c.to=t){this.children[i]==t&&(n=this.children[i+2]);break}for(var o=t+1,s=o+e.content.size,a=0;ao&&u.type instanceof be){var c=Math.max(o,u.from)-o,l=Math.min(s,u.to)-o;cn&&s.to0;)e++;t.splice(e,0,n)}function $e(t){var e=[];return t.someProp("decorations",(function(n){var r=n(t.state);r&&r!=Te&&e.push(r)})),t.cursorWrapper&&e.push(Ce.create(t.state.doc,[t.cursorWrapper.deco])),Me.from(e)}Me.prototype.forChild=function(t,e){if(e.isLeaf)return Ce.empty;for(var n=[],r=0;ri.scrollToSelection?"to selection":"preserve",p=o||!this.docView.matchesNode(t.doc,l,c);!p&&t.selection.eq(i.selection)||(a=!0);var h,d,v,m,g,y,b,w,x,k,S,M="preserve"==f&&a&&null==this.dom.style.overflowAnchor&&function(t){for(var e,n,r=t.dom.getBoundingClientRect(),i=Math.max(0,r.top),o=(r.left+r.right)/2,s=i+1;s=i-20){e=a,n=u.top;break}}}return{refDOM:e,refTop:n,stack:C(t.dom)}}(this);if(a){this.domObserver.stop();var A=p&&(s.ie||s.chrome)&&!this.composing&&!i.selection.empty&&!t.selection.empty&&(m=i.selection,g=t.selection,y=Math.min(m.$anchor.sharedDepth(m.head),g.$anchor.sharedDepth(g.head)),m.$anchor.start(y)!=g.$anchor.start(y));if(p){var E=s.chrome?this.trackWrites=this.root.getSelection().focusNode:null;!o&&this.docView.update(t.doc,l,c,this)||(this.docView.updateOuterDeco([]),this.docView.destroy(),this.docView=J(t.doc,l,c,this.dom,this)),E&&!this.trackWrites&&(A=!0)}A||!(this.mouseDown&&this.domObserver.currentSelection.eq(this.root.getSelection())&&(h=this,d=h.docView.domFromPos(h.state.selection.anchor),v=h.root.getSelection(),_(d.node,d.offset,v.anchorNode,v.anchorOffset)))?lt(this,A):(_t(this,t.selection),this.domObserver.setCurSelection()),this.domObserver.start()}if(this.updatePluginViews(i),"reset"==f)this.dom.scrollTop=0;else if("to selection"==f){var N=this.root.getSelection().focusNode;this.someProp("handleScrollToSelection",(function(t){return t(n)}))||(t.selection instanceof r.NodeSelection?O(this,this.docView.domAfterPos(t.selection.from).getBoundingClientRect(),N):O(this,this.coordsAtPos(t.selection.head),N))}else M&&(w=(b=M).refDOM,x=b.refTop,k=b.stack,S=w?w.getBoundingClientRect().top:0,T(k,0==S?0:S-x))},Ie.prototype.destroyPluginViews=function(){for(var t;t=this.pluginViews.pop();)t.destroy&&t.destroy()},Ie.prototype.updatePluginViews=function(t){if(t&&t.plugins==this.state.plugins)for(var e=0;e-1;i--){var o=n[i],s=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(s)>-1&&(r=o)}return m.head.insertBefore(e,r),t}}function X(){for(var t=12,e="";t-- >0;)e+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return e}function Y(t){return"".concat(t).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function Z(t){return Object.keys(t||{}).reduce((function(e,n){return e+"".concat(n,": ").concat(t[n],";")}),"")}function Q(t){return t.size!==J.size||t.x!==J.x||t.y!==J.y||t.rotate!==J.rotate||t.flipX||t.flipY}function tt(t){var e=t.transform,n=t.containerWidth,r=t.iconWidth,i={transform:"translate(".concat(n/2," 256)")},o="translate(".concat(32*e.x,", ").concat(32*e.y,") "),s="scale(".concat(e.size/16*(e.flipX?-1:1),", ").concat(e.size/16*(e.flipY?-1:1),") "),a="rotate(".concat(e.rotate," 0 0)");return{outer:i,inner:{transform:"".concat(o," ").concat(s," ").concat(a)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}var et={x:0,y:0,width:"100%",height:"100%"};function nt(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return t.attributes&&(t.attributes.fill||e)&&(t.attributes.fill="black"),t}function rt(t){var e=t.icons,n=e.main,r=e.mask,i=t.prefix,o=t.iconName,s=t.transform,u=t.symbol,c=t.title,l=t.maskId,f=t.titleId,p=t.extra,h=t.watchable,d=void 0!==h&&h,_=r.found?r:n,v=_.width,m=_.height,g="fa-w-".concat(Math.ceil(v/m*16)),y=[C.replacementClass,o?"".concat(C.familyPrefix,"-").concat(o):"",g].filter((function(t){return-1===p.classes.indexOf(t)})).concat(p.classes).join(" "),b={children:[],attributes:a({},p.attributes,{"data-prefix":i,"data-icon":o,class:y,role:p.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(v," ").concat(m)})};d&&(b.attributes["data-fa-i2svg"]=""),c&&b.children.push({tag:"title",attributes:{id:b.attributes["aria-labelledby"]||"title-".concat(f||X())},children:[c]});var w=a({},b,{prefix:i,iconName:o,main:n,mask:r,maskId:l,transform:s,symbol:u,styles:p.styles}),x=r.found&&n.found?function(t){var e,n=t.children,r=t.attributes,i=t.main,o=t.mask,s=t.maskId,u=t.transform,c=i.width,l=i.icon,f=o.width,p=o.icon,h=tt({transform:u,containerWidth:f,iconWidth:c}),d={tag:"rect",attributes:a({},et,{fill:"white"})},_=l.children?{children:l.children.map(nt)}:{},v={tag:"g",attributes:a({},h.inner),children:[nt(a({tag:l.tag,attributes:a({},l.attributes,h.path)},_))]},m={tag:"g",attributes:a({},h.outer),children:[v]},g="mask-".concat(s||X()),y="clip-".concat(s||X()),b={tag:"mask",attributes:a({},et,{id:g,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[d,m]},w={tag:"defs",children:[{tag:"clipPath",attributes:{id:y},children:(e=p,"g"===e.tag?e.children:[e])},b]};return n.push(w,{tag:"rect",attributes:a({fill:"currentColor","clip-path":"url(#".concat(y,")"),mask:"url(#".concat(g,")")},et)}),{children:n,attributes:r}}(w):function(t){var e=t.children,n=t.attributes,r=t.main,i=t.transform,o=Z(t.styles);if(o.length>0&&(n.style=o),Q(i)){var s=tt({transform:i,containerWidth:r.width,iconWidth:r.width});e.push({tag:"g",attributes:a({},s.outer),children:[{tag:"g",attributes:a({},s.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:a({},r.icon.attributes,s.path)}]}]})}else e.push(r.icon);return{children:e,attributes:n}}(w),k=x.children,S=x.attributes;return w.children=k,w.attributes=S,u?function(t){var e=t.prefix,n=t.iconName,r=t.children,i=t.attributes,o=t.symbol;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:a({},i,{id:!0===o?"".concat(e,"-").concat(C.familyPrefix,"-").concat(n):o}),children:r}]}]}(w):function(t){var e=t.children,n=t.main,r=t.mask,i=t.attributes,o=t.styles,s=t.transform;if(Q(s)&&n.found&&!r.found){var u={x:n.width/n.height/2,y:.5};i.style=Z(a({},o,{"transform-origin":"".concat(u.x+s.x/16,"em ").concat(u.y+s.y/16,"em")}))}return[{tag:"svg",attributes:i,children:e}]}(w)}function it(t){var e=t.content,n=t.width,r=t.height,i=t.transform,o=t.title,s=t.extra,u=t.watchable,c=void 0!==u&&u,l=a({},s.attributes,o?{title:o}:{},{class:s.classes.join(" ")});c&&(l["data-fa-i2svg"]="");var f=a({},s.styles);Q(i)&&(f.transform=function(t){var e=t.transform,n=t.width,r=void 0===n?16:n,i=t.height,o=void 0===i?16:i,s=t.startCentered,a=void 0!==s&&s,u="";return u+=a&&b?"translate(".concat(e.x/H-r/2,"em, ").concat(e.y/H-o/2,"em) "):a?"translate(calc(-50% + ".concat(e.x/H,"em), calc(-50% + ").concat(e.y/H,"em)) "):"translate(".concat(e.x/H,"em, ").concat(e.y/H,"em) "),u+="scale(".concat(e.size/H*(e.flipX?-1:1),", ").concat(e.size/H*(e.flipY?-1:1),") "),u+="rotate(".concat(e.rotate,"deg) ")}({transform:i,startCentered:!0,width:n,height:r}),f["-webkit-transform"]=f.transform);var p=Z(f);p.length>0&&(l.style=p);var h=[];return h.push({tag:"span",attributes:l,children:[e]}),o&&h.push({tag:"span",attributes:{class:"sr-only"},children:[o]}),h}var ot=function(){},st=(C.measurePerformance&&g&&g.mark&&g.measure,function(t,e,n,r){var i,o,s,a=Object.keys(t),u=a.length,c=void 0!==r?function(t,e){return function(n,r,i,o){return t.call(e,n,r,i,o)}}(e,r):e;for(void 0===n?(i=1,s=t[a[0]]):(i=0,s=n);i2&&void 0!==arguments[2]?arguments[2]:{},r=n.skipHooks,i=void 0!==r&&r,o=Object.keys(e).reduce((function(t,n){var r=e[n];return!!r.icon?t[r.iconName]=r.icon:t[n]=r,t}),{});"function"!=typeof M.hooks.addPack||i?M.styles[t]=a({},M.styles[t]||{},o):M.hooks.addPack(t,o),"fas"===t&&at("fa",e)}var ut=M.styles,ct=M.shims,lt=function(){var t=function(t){return st(ut,(function(e,n,r){return e[r]=st(n,t,{}),e}),{})};t((function(t,e,n){return e[3]&&(t[e[3]]=n),t})),t((function(t,e,n){var r=e[2];return t[n]=n,r.forEach((function(e){t[e]=n})),t}));var e="far"in ut;st(ct,(function(t,n){var r=n[0],i=n[1],o=n[2];return"far"!==i||e||(i="fas"),t[r]={prefix:i,iconName:o},t}),{})};lt();M.styles;function ft(t,e,n){if(t&&t[e]&&t[e][n])return{prefix:e,iconName:n,icon:t[e][n]}}function pt(t){var e=t.tag,n=t.attributes,r=void 0===n?{}:n,i=t.children,o=void 0===i?[]:i;return"string"==typeof t?Y(t):"<".concat(e," ").concat(function(t){return Object.keys(t||{}).reduce((function(e,n){return e+"".concat(n,'="').concat(Y(t[n]),'" ')}),"").trim()}(r),">").concat(o.map(pt).join(""),"")}var ht=function(t){var e={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return t?t.toLowerCase().split(" ").reduce((function(t,e){var n=e.toLowerCase().split("-"),r=n[0],i=n.slice(1).join("-");if(r&&"h"===i)return t.flipX=!0,t;if(r&&"v"===i)return t.flipY=!0,t;if(i=parseFloat(i),isNaN(i))return t;switch(r){case"grow":t.size=t.size+i;break;case"shrink":t.size=t.size-i;break;case"left":t.x=t.x-i;break;case"right":t.x=t.x+i;break;case"up":t.y=t.y-i;break;case"down":t.y=t.y+i;break;case"rotate":t.rotate=t.rotate+i}return t}),e):e};function dt(t){this.name="MissingIcon",this.message=t||"Icon unavailable",this.stack=(new Error).stack}dt.prototype=Object.create(Error.prototype),dt.prototype.constructor=dt;var _t={fill:"currentColor"},vt={attributeType:"XML",repeatCount:"indefinite",dur:"2s"},mt={tag:"path",attributes:a({},_t,{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})},gt=a({},vt,{attributeName:"opacity"});a({},_t,{cx:"256",cy:"364",r:"28"}),a({},vt,{attributeName:"r",values:"28;14;28;28;14;28;"}),a({},gt,{values:"1;0;1;1;0;1;"}),a({},_t,{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),a({},gt,{values:"1;0;0;0;0;1;"}),a({},_t,{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),a({},gt,{values:"0;0;1;1;0;0;"}),M.styles;function yt(t){var e=t[0],n=t[1],r=u(t.slice(4),1)[0];return{found:!0,width:e,height:n,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(C.familyPrefix,"-").concat(k.GROUP)},children:[{tag:"path",attributes:{class:"".concat(C.familyPrefix,"-").concat(k.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(C.familyPrefix,"-").concat(k.PRIMARY),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}M.styles;function bt(){var t="svg-inline--fa",e=C.familyPrefix,n=C.replacementClass,r='svg:not(:root).svg-inline--fa {\n overflow: visible;\n}\n\n.svg-inline--fa {\n display: inline-block;\n font-size: inherit;\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.225em;\n}\n.svg-inline--fa.fa-w-1 {\n width: 0.0625em;\n}\n.svg-inline--fa.fa-w-2 {\n width: 0.125em;\n}\n.svg-inline--fa.fa-w-3 {\n width: 0.1875em;\n}\n.svg-inline--fa.fa-w-4 {\n width: 0.25em;\n}\n.svg-inline--fa.fa-w-5 {\n width: 0.3125em;\n}\n.svg-inline--fa.fa-w-6 {\n width: 0.375em;\n}\n.svg-inline--fa.fa-w-7 {\n width: 0.4375em;\n}\n.svg-inline--fa.fa-w-8 {\n width: 0.5em;\n}\n.svg-inline--fa.fa-w-9 {\n width: 0.5625em;\n}\n.svg-inline--fa.fa-w-10 {\n width: 0.625em;\n}\n.svg-inline--fa.fa-w-11 {\n width: 0.6875em;\n}\n.svg-inline--fa.fa-w-12 {\n width: 0.75em;\n}\n.svg-inline--fa.fa-w-13 {\n width: 0.8125em;\n}\n.svg-inline--fa.fa-w-14 {\n width: 0.875em;\n}\n.svg-inline--fa.fa-w-15 {\n width: 0.9375em;\n}\n.svg-inline--fa.fa-w-16 {\n width: 1em;\n}\n.svg-inline--fa.fa-w-17 {\n width: 1.0625em;\n}\n.svg-inline--fa.fa-w-18 {\n width: 1.125em;\n}\n.svg-inline--fa.fa-w-19 {\n width: 1.1875em;\n}\n.svg-inline--fa.fa-w-20 {\n width: 1.25em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-border {\n height: 1.5em;\n}\n.svg-inline--fa.fa-li {\n width: 2em;\n}\n.svg-inline--fa.fa-fw {\n width: 1.25em;\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: #ff253a;\n border-radius: 1em;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: #fff;\n height: 1.5em;\n line-height: 1;\n max-width: 5em;\n min-width: 1.5em;\n overflow: hidden;\n padding: 0.25em;\n right: 0;\n text-overflow: ellipsis;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: 0;\n right: 0;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: 0;\n left: 0;\n right: auto;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n right: 0;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: 0;\n right: auto;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-lg {\n font-size: 1.3333333333em;\n line-height: 0.75em;\n vertical-align: -0.0667em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: 2.5em;\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';if("fa"!==e||n!==t){var i=new RegExp("\\.".concat("fa","\\-"),"g"),o=new RegExp("\\--".concat("fa","\\-"),"g"),s=new RegExp("\\.".concat(t),"g");r=r.replace(i,".".concat(e,"-")).replace(o,"--".concat(e,"-")).replace(s,".".concat(n))}return r}function wt(){C.autoAddCss&&!Ct&&(G(bt()),Ct=!0)}function xt(t,e){return Object.defineProperty(t,"abstract",{get:e}),Object.defineProperty(t,"html",{get:function(){return t.abstract.map((function(t){return pt(t)}))}}),Object.defineProperty(t,"node",{get:function(){if(y){var e=m.createElement("div");return e.innerHTML=t.html,e.children}}}),t}function kt(t){var e=t.prefix,n=void 0===e?"fa":e,r=t.iconName;if(r)return ft(Ot.definitions,n,r)||ft(M.styles,n,r)}var St,Ot=new(function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.definitions={}}var e,n,r;return e=t,(n=[{key:"add",value:function(){for(var t=this,e=arguments.length,n=new Array(e),r=0;r1&&void 0!==arguments[1]?arguments[1]:{},n=e.transform,r=void 0===n?J:n,i=e.symbol,o=void 0!==i&&i,s=e.mask,u=void 0===s?null:s,c=e.maskId,l=void 0===c?null:c,f=e.title,p=void 0===f?null:f,h=e.titleId,d=void 0===h?null:h,_=e.classes,v=void 0===_?[]:_,m=e.attributes,g=void 0===m?{}:m,y=e.styles,b=void 0===y?{}:y;if(t){var w=t.prefix,x=t.iconName,k=t.icon;return xt(a({type:"icon"},t),(function(){return wt(),C.autoA11y&&(p?g["aria-labelledby"]="".concat(C.replacementClass,"-title-").concat(d||X()):(g["aria-hidden"]="true",g.focusable="false")),rt({icons:{main:yt(k),mask:u?yt(u.icon):{found:!1,width:null,height:null,icon:{}}},prefix:w,iconName:x,transform:a({},J,r),symbol:o,title:p,maskId:l,titleId:d,extra:{attributes:g,styles:b,classes:v}})}))}},function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(t||{}).icon?t:kt(t||{}),r=e.mask;return r&&(r=(r||{}).icon?r:kt(r||{})),St(n,a({},e,{mask:r}))}),At=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.transform,r=void 0===n?J:n,i=e.title,o=void 0===i?null:i,s=e.classes,u=void 0===s?[]:s,l=e.attributes,f=void 0===l?{}:l,p=e.styles,h=void 0===p?{}:p;return xt({type:"text",content:t},(function(){return wt(),it({content:t,transform:a({},J,r),title:o,extra:{attributes:f,styles:h,classes:["".concat(C.familyPrefix,"-layers-text")].concat(c(u))}})}))}}).call(this,n(10),n(21).setImmediate)},function(t,e,n){"use strict";function r(t,e,n,r,i,o,s,a){var u,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),o&&(c._scopeId="data-v-"+o),s?(u=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(s)},c._ssrRegister=u):i&&(u=a?function(){i.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:i),u)if(c.functional){c._injectStyles=u;var l=c.render;c.render=function(t,e){return u.call(e),l(t,e)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,u):[u]}return{exports:t,options:c}}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),i=n(0),o=n(3),s=function(t,e){return function(n){Array.isArray(t)||(t=[t]);for(var r=0,i=t.length;r1&&void 0!==arguments[1]?arguments[1]:1;return function(n){var i=r.Selection.findFrom(n.doc.resolve(t),e,!0);return i?n.setSelection(i):n}},c=function(t){return t.type&&t.type.spec.selectable},l=function(t,e,n){return function(t){return c(t)&&t.type.isLeaf}(t)?n.setSelection(new r.NodeSelection(n.doc.resolve(e))):u(e)(n)},f=function(t,e,n){return function(r){var i="number"==typeof e,o=r.selection.$from,u=i?r.doc.resolve(e):p(r.selection)?r.doc.resolve(o.pos+1):o,f=u.parent;if(p(r.selection)&&n&&r!==(r=a(t)(r)))return r;if(b(f)&&r!==(r=s(f.type,t)(r))){var h=c(t)?u.before(u.depth):u.pos;return l(t,h,r)}if(y(u,t)){r.insert(u.pos,t);var _=i?u.pos:c(t)?r.selection.$anchor.pos-1:r.selection.$anchor.pos;return d(l(t,_,r))}for(var v=u.depth;v>0;v--){var m=u.after(v),g=r.doc.resolve(m);if(y(g,t))return r.insert(m,t),d(l(t,m,r))}return r}},p=function(t){return t instanceof r.NodeSelection},h=function(t,e){return Array.isArray(t)&&t.indexOf(e.type)>-1||e.type===t},d=function(t){return Object.assign(Object.create(t),t).setTime(Date.now())},_=function(t,e){return function(n){var r=n.doc.nodeAt(t),i=n.doc.resolve(t);if(v(i,e)){var o=(n=n.replaceWith(t,t+r.nodeSize,e)).selection.$from.pos-1;return n=u(Math.max(o,0),-1)(n),n=u(n.selection.$from.start())(n),d(n)}return n}},v=function(t,e){var n=t.node(t.depth);return n&&n.type.validContent(e instanceof i.Fragment?e:i.Fragment.from(e))},m=function(t){return function(e){var n=e.doc.nodeAt(t);return d(e.delete(t,t+n.nodeSize))}},g=function(t){if(t.cached.tableNodeTypes)return t.cached.tableNodeTypes;var e={};return Object.keys(t.nodes).forEach((function(n){var r=t.nodes[n];r.spec.tableRole&&(e[r.spec.tableRole]=r)})),t.cached.tableNodeTypes=e,e},y=function(t,e){var n=t.index();return e instanceof i.Fragment?t.parent.canReplace(n,n,e):e instanceof i.Node&&t.parent.canReplaceWith(n,n,e.type)},b=function(t){return!t||"paragraph"===t.type.name&&2===t.nodeSize},w=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return e?t.createChecked(null,e):t.createAndFill()},x=function(t){return function(e){for(var n=o.TableMap.get(e.$anchorCell.node(-1)),r=e.$anchorCell.start(-1),i=n.cellsInRect(t),s=n.cellsInRect(n.rectBetween(e.$anchorCell.pos-r,e.$headCell.pos-r)),a=0,u=i.length;an[0]?-1:1,o=t.splice(e[0],e.length),s=o.length%2==0?1:0,a=void 0;return a=-1===r&&1===i?n[0]-1:1===r&&-1===i?n[n.length-1]-s+1:-1===i?n[0]:n[n.length-1]-s,t.splice.apply(t,[a,0].concat(o)),t},T=function(t,e,n,r){var i="Target position is invalid, you can't move the "+r+" "+t+" to "+e+", the target can't be split. You could use tryToFit option.";if(1===(t>e?-1:1)){if(-1!==n.slice(0,n.length-1).indexOf(e))throw new Error(i)}else if(-1!==n.slice(1).indexOf(e))throw new Error(i);return!0},M=function(t){return function(e){var n=e.$from;return A(n,t)}},A=function(t,e){for(var n=t.depth;n>0;n--){var r=t.node(n);if(e(r))return{pos:n>0?t.before(n):0,start:t.start(n),depth:n,node:r}}},E=function(t,e){return function(n){var r=M(t)(n);if(r)return P(r.pos,e)}},N=function(t){return function(e){return!!M(t)(e)}},R=function(t){return function(e){return M((function(e){return h(t,e)}))(e)}},D=function(t){var e=t.$from.nodeBefore,n=r.Selection.findFrom(t.$from,-1);if(n&&e){var i=R(e.type)(n);return i?i.pos:n.$from.pos}},P=function(t,e){var n=e(t),r=n.node.childNodes[n.offset];return n.node.nodeType===Node.TEXT_NODE?n.node.parentNode:r&&r.nodeType!==Node.TEXT_NODE?r:n.node},j=function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!t)throw new Error('Invalid "node" parameter');var n=[];return t.descendants((function(t,r){if(n.push({node:t,pos:r}),!e)return!1})),n},$=function(t,e,n){if(!t)throw new Error('Invalid "node" parameter');if(!e)throw new Error('Invalid "predicate" parameter');return j(t,n).filter((function(t){return e(t.node)}))},I=function(t,e,n){return $(t,(function(t){return t.type===e}),n)};var z=function(t){return M((function(t){return t.type.spec.tableRole&&"table"===t.type.spec.tableRole}))(t)},L=function(t){return t instanceof o.CellSelection},F=function(t){if(L(t)){var e=o.TableMap.get(t.$anchorCell.node(-1));return x({left:0,right:e.width,top:0,bottom:e.height})(t)}return!1},B=function(t){return function(e){var n=z(e);if(n){var r=o.TableMap.get(n.node);return(Array.isArray(t)?t:Array.from([t])).reduce((function(t,e){if(e>=0&&e<=r.width-1){var i=r.cellsInRect({left:e,right:e+1,top:0,bottom:r.height});return t.concat(i.map((function(t){var e=n.node.nodeAt(t),r=t+n.start;return{pos:r,start:r+1,node:e}})))}}),[])}}},V=function(t){return function(e){var n=z(e);if(n){var r=o.TableMap.get(n.node);return(Array.isArray(t)?t:Array.from([t])).reduce((function(t,e){if(e>=0&&e<=r.height-1){var i=r.cellsInRect({left:0,right:r.width,top:e,bottom:e+1});return t.concat(i.map((function(t){var e=n.node.nodeAt(t),r=t+n.start;return{pos:r,start:r+1,node:e}})))}}),[])}}},W=function(t){return function(e,n){return function(r){var i=z(r.selection),s="row"===t;if(i){var a=o.TableMap.get(i.node);if(e>=0&&e<(s?a.height:a.width)){var u=s?0:e,c=s?e:0,l=s?a.width:e+1,f=s?e+1:a.height;if(n){var p=Y(r.selection.$from);if(!p)return r;var h=a.findCell(p.pos-i.start);s?(c=Math.min(c,h.top),f=Math.max(f,h.bottom)):(u=Math.min(u,h.left),l=Math.max(l,h.right))}var _=a.cellsInRect({left:u,top:c,right:s?l:u+1,bottom:s?c+1:f}),v=f-c==1?_:a.cellsInRect({left:s?u:l-1,top:s?f-1:c,right:l,bottom:f}),m=i.start+_[0],g=i.start+v[v.length-1],y=r.doc.resolve(m),b=r.doc.resolve(g);return d(r.setSelection(new o.CellSelection(b,y)))}}return r}}},U=W("column"),K=W("row"),q=function(t){return function(e){var n=z(e.selection);if(n){var r=o.TableMap.get(n.node);if(t>=0&&t<=r.height){for(var i=n.node,s=g(i.type.schema),a=n.start,u=0;u1&&n+i>t}))(e);h.push.apply(h,function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e=0;_--)d(_);h.length&&h.forEach((function(t){e=X(t,{rowspan:t.node.attrs.rowspan+1})(e)}))}return f(s.row.create(c.attrs,l),a)(e)}}return e}},H=function(t){return function(e){var n=z(e.selection);if(n){var r=o.TableMap.get(n.node);if(0===t&&1===r.width)return G(e);if(t>=0&&t<=r.width)return o.removeColumn(e,{map:r,tableStart:n.start,table:n.node},t),d(e)}return e}},J=function(t){return function(e){var n=z(e.selection);if(n){var r=o.TableMap.get(n.node);if(0===t&&1===r.height)return G(e);if(t>=0&&t<=r.height)return o.removeRow(e,{map:r,tableStart:n.start,table:n.node},t),d(e)}return e}},G=function(t){for(var e=t.selection.$from,n=e.depth;n>0;n--){if("table"===e.node(n).type.spec.tableRole)return d(t.delete(e.before(n),e.after(n)))}return t},X=function(t,e){return function(n){return t?(n.setNodeMarkup(t.pos,null,Object.assign({},t.node.attrs,e)),d(n)):n}},Y=function(t){return A(t,(function(t){return t.type.spec.tableRole&&/cell/i.test(t.type.spec.tableRole)}))},Z=function(t){var e=Y(t);if(e){var n=function(t){return A(t,(function(t){return t.type.spec.tableRole&&/table/i.test(t.type.spec.tableRole)}))}(t),r=o.TableMap.get(n.node),i=e.pos-n.start;return r.rectBetween(i,i)}},Q=function(t,e){return function(n){var r=[],i=V(t)(n.selection);if(i)for(var o=i.length-1;o>=0;o--)e(i[o],n)&&r.push(i[o]);return r}},tt=function(t){return function(e){for(var n=t,r=t,i=function(t){var i=B(t)(e.selection);i&&i.forEach((function(e){var i=e.node.attrs.colspan+t-1;i>=n&&(n=t),i>r&&(r=i)}))},o=t;o>=0;o--)i(o);var s=function(t){var n=B(t)(e.selection);n&&n.forEach((function(e){var n=e.node.attrs.colspan+t-1;e.node.attrs.colspan>1&&n>r&&(r=n)}))};for(o=t;o<=r;o++)s(o);var a=[];for(o=n;o<=r;o++){var u=B(o)(e.selection);u&&u.length&&a.push(o)}n=a[0],r=a[a.length-1];for(var c=B(n)(e.selection),l=V(0)(e.selection),f=e.doc.resolve(c[c.length-1].pos),p=void 0,h=r;h>=n;h--){var d=B(h)(e.selection);if(d&&d.length){for(var _=l.length-1;_>=0;_--)if(l[_].pos===d[0].pos){p=d[0];break}if(p)break}}return{$anchor:f,$head:e.doc.resolve(p.pos),indexes:a}}},et=function(t){return function(e){for(var n=t,r=t,i=function(t){V(t)(e.selection).forEach((function(e){var i=e.node.attrs.rowspan+t-1;i>=n&&(n=t),i>r&&(r=i)}))},o=t;o>=0;o--)i(o);var s=function(t){V(t)(e.selection).forEach((function(e){var n=e.node.attrs.rowspan+t-1;e.node.attrs.rowspan>1&&n>r&&(r=n)}))};for(o=t;o<=r;o++)s(o);var a=[];for(o=n;o<=r;o++){var u=V(o)(e.selection);u&&u.length&&a.push(o)}n=a[0],r=a[a.length-1];for(var c=V(n)(e.selection),l=B(0)(e.selection),f=e.doc.resolve(c[c.length-1].pos),p=void 0,h=r;h>=n;h--){var d=V(h)(e.selection);if(d&&d.length){for(var _=l.length-1;_>=0;_--)if(l[_].pos===d[0].pos){p=d[0];break}if(p)break}}return{$anchor:f,$head:e.doc.resolve(p.pos),indexes:a}}};e.isNodeSelection=p,e.canInsert=y,e.convertTableNodeToArrayOfRows=S,e.convertArrayOfRowsToTableNode=O,e.findParentNode=M,e.findParentNodeClosestToPos=A,e.findParentDomRef=E,e.hasParentNode=N,e.findParentNodeOfType=R,e.findParentNodeOfTypeClosestToPos=function(t,e){return A(t,(function(t){return h(e,t)}))},e.hasParentNodeOfType=function(t){return function(e){return N((function(e){return h(t,e)}))(e)}},e.findParentDomRefOfType=function(t,e){return function(n){return E((function(e){return h(t,e)}),e)(n)}},e.findSelectedNodeOfType=function(t){return function(e){if(p(e)){var n=e.node,r=e.$from;if(h(t,n))return{node:n,pos:r.pos,depth:r.depth}}}},e.findPositionOfNodeBefore=D,e.findDomRefAtPos=P,e.flatten=j,e.findChildren=$,e.findTextNodes=function(t,e){return $(t,(function(t){return t.isText}),e)},e.findInlineNodes=function(t,e){return $(t,(function(t){return t.isInline}),e)},e.findBlockNodes=function(t,e){return $(t,(function(t){return t.isBlock}),e)},e.findChildrenByAttr=function(t,e,n){return $(t,(function(t){return!!e(t.attrs)}),n)},e.findChildrenByType=I,e.findChildrenByMark=function(t,e,n){return $(t,(function(t){return e.isInSet(t.marks)}),n)},e.contains=function(t,e){return!!I(t,e).length},e.findTable=z,e.isCellSelection=L,e.getSelectionRect=function(t){if(L(t)){var e=t.$anchorCell.start(-1);return o.TableMap.get(t.$anchorCell.node(-1)).rectBetween(t.$anchorCell.pos-e,t.$headCell.pos-e)}},e.isColumnSelected=function(t){return function(e){if(L(e)){var n=o.TableMap.get(e.$anchorCell.node(-1));return x({left:t,right:t+1,top:0,bottom:n.height})(e)}return!1}},e.isRowSelected=function(t){return function(e){if(L(e)){var n=o.TableMap.get(e.$anchorCell.node(-1));return x({left:0,right:n.width,top:t,bottom:t+1})(e)}return!1}},e.isTableSelected=F,e.getCellsInColumn=B,e.getCellsInRow=V,e.getCellsInTable=function(t){var e=z(t);if(e){var n=o.TableMap.get(e.node);return n.cellsInRect({left:0,right:n.width,top:0,bottom:n.height}).map((function(t){var n=e.node.nodeAt(t),r=t+e.start;return{pos:r,start:r+1,node:n}}))}},e.selectColumn=U,e.selectRow=K,e.selectTable=function(t){var e=z(t.selection);if(e){var n=o.TableMap.get(e.node).map;if(n&&n.length){var r=e.start+n[0],i=e.start+n[n.length-1],s=t.doc.resolve(r),a=t.doc.resolve(i);return d(t.setSelection(new o.CellSelection(a,s)))}}return t},e.emptyCell=function(t,e){return function(n){if(t){var r=g(e).cell.createAndFill().content;if(!t.node.content.eq(r))return n.replaceWith(t.pos+1,t.pos+t.node.nodeSize,r),d(n)}return n}},e.addColumnAt=function(t){return function(e){var n=z(e.selection);if(n){var r=o.TableMap.get(n.node);if(t>=0&&t<=r.width)return d(o.addColumn(e,{map:r,tableStart:n.start,table:n.node},t))}return e}},e.moveRow=function(t,e,n){return function(r){var i=Object.assign({tryToFit:!1,direction:0},n),o=z(r.selection);if(!o)return r;var s=et(t)(r).indexes,a=et(e)(r).indexes;if(s.indexOf(e)>-1)return r;!i.tryToFit&&a.length>1&&T(t,e,a,"row");var u=function(t,e,n,r){var i=S(t.node);return i=C(i,e,n,r),O(t.node,i)}(o,s,a,i.direction);return d(r).replaceWith(o.pos,o.pos+o.node.nodeSize,u)}},e.moveColumn=function(t,e,n){return function(r){var i=Object.assign({tryToFit:!1,direction:0},n),o=z(r.selection);if(!o)return r;var s=tt(t)(r).indexes,a=tt(e)(r).indexes;if(s.indexOf(e)>-1)return r;!i.tryToFit&&a.length>1&&T(t,e,a,"column");var u=function(t,e,n,r){var i=k(S(t.node));return i=C(i,e,n,r),i=k(i),O(t.node,i)}(o,s,a,i.direction);return d(r).replaceWith(o.pos,o.pos+o.node.nodeSize,u)}},e.addRowAt=function(t,e){return function(n){var r=z(n.selection);if(r){var i=o.TableMap.get(r.node),s=t-1;if(e&&s>=0)return d(q(s)(n));if(t>=0&&t<=i.height)return d(o.addRow(n,{map:i,tableStart:r.start,table:r.node},t))}return n}},e.cloneRowAt=q,e.removeColumnAt=H,e.removeRowAt=J,e.removeTable=G,e.removeSelectedColumns=function(t){var e=t.selection;if(F(e))return G(t);if(L(e)){var n=z(e);if(n){var r=o.TableMap.get(n.node),i=r.rectBetween(e.$anchorCell.pos-n.start,e.$headCell.pos-n.start);if(0==i.left&&i.right==r.width)return!1;for(var s=Object.assign({},i,{map:r,table:n.node,tableStart:n.start}),a=s.right-1;o.removeColumn(t,s,a),a!==s.left;a--)s.table=s.tableStart?t.doc.nodeAt(s.tableStart-1):t.doc,s.map=o.TableMap.get(s.table);return d(t)}}return t},e.removeSelectedRows=function(t){var e=t.selection;if(F(e))return G(t);if(L(e)){var n=z(e);if(n){var r=o.TableMap.get(n.node),i=r.rectBetween(e.$anchorCell.pos-n.start,e.$headCell.pos-n.start);if(0==i.top&&i.bottom==r.height)return!1;for(var s=Object.assign({},i,{map:r,table:n.node,tableStart:n.start}),a=s.bottom-1;o.removeRow(t,s,a),a!==s.top;a--)s.table=s.tableStart?t.doc.nodeAt(s.tableStart-1):t.doc,s.map=o.TableMap.get(s.table);return d(t)}}return t},e.removeColumnClosestToPos=function(t){return function(e){var n=Z(t);return n?H(n.left)(u(t.pos)(e)):e}},e.removeRowClosestToPos=function(t){return function(e){var n=Z(t);return n?J(n.top)(u(t.pos)(e)):e}},e.forEachCellInColumn=function(t,e,n){return function(i){var o=B(t)(i.selection);if(o){for(var s=o.length-1;s>=0;s--)i=e(o[s],i);if(n){var a=i.doc.resolve(i.mapping.map(o[o.length-1].pos));i.setSelection(r.Selection.near(a))}return d(i)}return i}},e.forEachCellInRow=function(t,e,n){return function(i){var o=V(t)(i.selection);if(o){for(var s=o.length-1;s>=0;s--)i=e(o[s],i);if(n){var a=i.doc.resolve(i.mapping.map(o[o.length-1].pos));i.setSelection(r.Selection.near(a))}}return i}},e.setCellAttrs=X,e.createTable=function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:3,r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,o=g(t),s=o.cell,a=o.header_cell,u=o.row,c=o.table,l=[],f=[],p=0;p",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"',229:"Q"},o="undefined"!=typeof navigator&&/Chrome\/(\d+)/.exec(navigator.userAgent),s="undefined"!=typeof navigator&&/Apple Computer/.test(navigator.vendor),a="undefined"!=typeof navigator&&/Gecko\/\d+/.test(navigator.userAgent),u="undefined"!=typeof navigator&&/Mac/.test(navigator.platform),c="undefined"!=typeof navigator&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent),l=o&&(u||+o[1]<57)||a&&u,f=0;f<10;f++)r[48+f]=r[96+f]=String(f);for(f=1;f<=24;f++)r[f+111]="F"+f;for(f=65;f<=90;f++)r[f]=String.fromCharCode(f+32),i[f]=String.fromCharCode(f);for(var p in r)i.hasOwnProperty(p)||(i[p]=r[p]);var h=n(1),d="undefined"!=typeof navigator&&/Mac/.test(navigator.platform);function _(t){var e,n,r,i,o=t.split(/-(?!$)/),s=o[o.length-1];"Space"==s&&(s=" ");for(var a=0;a127)&&(o=r[n.keyCode])&&o!=a){var p=e[v(o,n,!0)];if(p&&p(t.state,t.dispatch,t))return!0}else if(u&&n.shiftKey){var h=e[v(a,n,!0)];if(h&&h(t.state,t.dispatch,t))return!0}return!1}}},function(t,e,n){"use strict";(function(t){n.d(e,"a",(function(){return m}));var r=n(5),i="undefined"!=typeof window?window:void 0!==t?t:"undefined"!=typeof self?self:{};var o=function(t,e){return t(e={exports:{}},e.exports),e.exports}((function(t){!function(e){var n=function(t,e,r){if(!u(e)||l(e)||f(e)||p(e)||a(e))return e;var i,o=0,s=0;if(c(e))for(i=[],s=e.length;o=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n};function l(t){return t.split(";").map((function(t){return t.trim()})).filter((function(t){return t})).reduce((function(t,e){var n=e.indexOf(":"),r=o.camelize(e.slice(0,n)),i=e.slice(n+1).trim();return t[r]=i,t}),{})}function f(t){return t.split(/\s+/).reduce((function(t,e){return t[e]=!0,t}),{})}function p(){for(var t=arguments.length,e=Array(t),n=0;n2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=(e.children||[]).map(h.bind(null,t)),o=Object.keys(e.attributes||{}).reduce((function(t,n){var r=e.attributes[n];switch(n){case"class":t.class=f(r);break;case"style":t.style=l(r);break;default:t.attrs[n]=r}return t}),{class:{},style:{},attrs:{}}),s=r.class,a=void 0===s?{}:s,d=r.style,_=void 0===d?{}:d,v=r.attrs,m=void 0===v?{}:v,g=c(r,["class","style","attrs"]);return"string"==typeof e?e:t(e.tag,u({class:p(o.class,a),style:u({},o.style,_),attrs:u({},o.attrs,m)},g,{props:n}),i)}var d=!1;try{d=!0}catch(t){}function _(t,e){return Array.isArray(e)&&e.length>0||!Array.isArray(e)&&e?a({},t,e):{}}function v(t){return null===t?null:"object"===(void 0===t?"undefined":s(t))&&t.prefix&&t.iconName?t:Array.isArray(t)&&2===t.length?{prefix:t[0],iconName:t[1]}:"string"==typeof t?{prefix:"fas",iconName:t}:void 0}var m={name:"FontAwesomeIcon",functional:!0,props:{border:{type:Boolean,default:!1},fixedWidth:{type:Boolean,default:!1},flip:{type:String,default:null,validator:function(t){return["horizontal","vertical","both"].indexOf(t)>-1}},icon:{type:[Object,Array,String],required:!0},mask:{type:[Object,Array,String],default:null},listItem:{type:Boolean,default:!1},pull:{type:String,default:null,validator:function(t){return["right","left"].indexOf(t)>-1}},pulse:{type:Boolean,default:!1},rotation:{type:[String,Number],default:null,validator:function(t){return[90,180,270].indexOf(parseInt(t,10))>-1}},swapOpacity:{type:Boolean,default:!1},size:{type:String,default:null,validator:function(t){return["lg","xs","sm","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"].indexOf(t)>-1}},spin:{type:Boolean,default:!1},transform:{type:[String,Object],default:null},symbol:{type:[Boolean,String],default:!1},title:{type:String,default:null},inverse:{type:Boolean,default:!1}},render:function(t,e){var n=e.props,i=n.icon,o=n.mask,s=n.symbol,c=n.title,l=v(i),f=_("classes",function(t){var e,n=(e={"fa-spin":t.spin,"fa-pulse":t.pulse,"fa-fw":t.fixedWidth,"fa-border":t.border,"fa-li":t.listItem,"fa-inverse":t.inverse,"fa-flip-horizontal":"horizontal"===t.flip||"both"===t.flip,"fa-flip-vertical":"vertical"===t.flip||"both"===t.flip},a(e,"fa-"+t.size,null!==t.size),a(e,"fa-rotate-"+t.rotation,null!==t.rotation),a(e,"fa-pull-"+t.pull,null!==t.pull),a(e,"fa-swap-opacity",t.swapOpacity),e);return Object.keys(n).map((function(t){return n[t]?t:null})).filter((function(t){return t}))}(n)),p=_("transform","string"==typeof n.transform?r.d.transform(n.transform):n.transform),m=_("mask",v(o)),g=Object(r.b)(l,u({},f,p,m,{symbol:s,title:c}));if(!g)return function(){var t;!d&&console&&"function"==typeof console.error&&(t=console).error.apply(t,arguments)}("Could not find one or more icon(s)",l,m);var y=g.abstract;return h.bind(null,t)(y[0],{},e.data)}};Boolean,Boolean}).call(this,n(10))},function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){t.exports=n(35)},function(t,e,n){var r=n(33);"string"==typeof r&&(r=[[t.i,r,""]]);var i={hmr:!0,transform:void 0,insertInto:void 0};n(20)(r,i);r.locals&&(t.exports=r.locals)},function(t,e,n){var r=n(42);"string"==typeof r&&(r=[[t.i,r,""]]);var i={hmr:!0,transform:void 0,insertInto:void 0};n(20)(r,i);r.locals&&(t.exports=r.locals)},function(t,e,n){var r,i;i=function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=0)}([function(t,e,n){"use strict";var r=n(1).Beautifier,i=n(5).Options;t.exports=function(t,e){return new r(t,e).beautify()},t.exports.defaultOptions=function(){return new i}},function(t,e,n){"use strict";var r=n(2).Output,i=n(3).Token,o=n(4),s=n(5).Options,a=n(7).Tokenizer,u=n(7).line_starters,c=n(7).positionable_operators,l=n(7).TOKEN;function f(t,e){return-1!==e.indexOf(t)}function p(t,e){return t&&t.type===l.RESERVED&&t.text===e}function h(t,e){return t&&t.type===l.RESERVED&&f(t.text,e)}var d=["case","return","do","if","throw","else","await","break","continue","async"],_=function(t){for(var e={},n=0;nn&&(n=t.line_indent_level)),{mode:e,parent:t,last_token:t?t.last_token:new i(l.START_BLOCK,""),last_word:t?t.last_word:"",declaration_statement:!1,declaration_assignment:!1,multiline_frame:!1,inline_frame:!1,if_block:!1,else_block:!1,do_block:!1,do_while:!1,import_block:!1,in_case_statement:!1,in_case:!1,case_body:!1,indentation_level:n,alignment:0,line_indent_level:t?t.line_indent_level:n,start_line_index:this._output.get_line_number(),ternary_depth:0}},T.prototype._reset=function(t){var e=t.match(/^[\t ]*/)[0];this._last_last_text="",this._output=new r(this._options,e),this._output.raw=this._options.test_output_raw,this._flag_store=[],this.set_mode(m);var n=new a(t,this._options);return this._tokens=n.tokenize(),t},T.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var t=this._reset(this._source_text),e=this._options.eol;"auto"===this._options.eol&&(e="\n",t&&o.lineBreak.test(t||"")&&(e=t.match(o.lineBreak)[0]));for(var n=this._tokens.next();n;)this.handle_token(n),this._last_last_text=this._flags.last_token.text,this._flags.last_token=n,n=this._tokens.next();return this._output.get_code(e)},T.prototype.handle_token=function(t,e){t.type===l.START_EXPR?this.handle_start_expr(t):t.type===l.END_EXPR?this.handle_end_expr(t):t.type===l.START_BLOCK?this.handle_start_block(t):t.type===l.END_BLOCK?this.handle_end_block(t):t.type===l.WORD||t.type===l.RESERVED?this.handle_word(t):t.type===l.SEMICOLON?this.handle_semicolon(t):t.type===l.STRING?this.handle_string(t):t.type===l.EQUALS?this.handle_equals(t):t.type===l.OPERATOR?this.handle_operator(t):t.type===l.COMMA?this.handle_comma(t):t.type===l.BLOCK_COMMENT?this.handle_block_comment(t,e):t.type===l.COMMENT?this.handle_comment(t,e):t.type===l.DOT?this.handle_dot(t):t.type===l.EOF?this.handle_eof(t):(t.type,l.UNKNOWN,this.handle_unknown(t,e))},T.prototype.handle_whitespace_and_comments=function(t,e){var n=t.newlines,r=this._options.keep_array_indentation&&O(this._flags.mode);if(t.comments_before)for(var i=t.comments_before.next();i;)this.handle_whitespace_and_comments(i,e),this.handle_token(i,e),i=t.comments_before.next();if(r)for(var o=0;o0,e);else if(this._options.max_preserve_newlines&&n>this._options.max_preserve_newlines&&(n=this._options.max_preserve_newlines),this._options.preserve_newlines&&n>1){this.print_newline(!1,e);for(var s=1;s0&&(!this._flags.parent||this._flags.indentation_level>this._flags.parent.indentation_level)&&(this._flags.indentation_level-=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},T.prototype.set_mode=function(t){this._flags?(this._flag_store.push(this._flags),this._previous_flags=this._flags):this._previous_flags=this.create_flags(null,t),this._flags=this.create_flags(this._previous_flags,t),this._output.set_indent(this._flags.indentation_level,this._flags.alignment)},T.prototype.restore_mode=function(){this._flag_store.length>0&&(this._previous_flags=this._flags,this._flags=this._flag_store.pop(),this._previous_flags.mode===g&&S(this._output,this._previous_flags),this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},T.prototype.start_of_object_property=function(){return this._flags.parent.mode===y&&this._flags.mode===g&&(":"===this._flags.last_token.text&&0===this._flags.ternary_depth||h(this._flags.last_token,["get","set"]))},T.prototype.start_of_statement=function(t){var e=!1;return!!(e=(e=(e=(e=(e=(e=(e=e||h(this._flags.last_token,["var","let","const"])&&t.type===l.WORD)||p(this._flags.last_token,"do"))||!(this._flags.parent.mode===y&&this._flags.mode===g)&&h(this._flags.last_token,M)&&!t.newlines)||p(this._flags.last_token,"else")&&!(p(t,"if")&&!t.comments_before))||this._flags.last_token.type===l.END_EXPR&&(this._previous_flags.mode===w||this._previous_flags.mode===x))||this._flags.last_token.type===l.WORD&&this._flags.mode===m&&!this._flags.in_case&&!("--"===t.text||"++"===t.text)&&"function"!==this._last_last_text&&t.type!==l.WORD&&t.type!==l.RESERVED)||this._flags.mode===y&&(":"===this._flags.last_token.text&&0===this._flags.ternary_depth||h(this._flags.last_token,["get","set"])))&&(this.set_mode(g),this.indent(),this.handle_whitespace_and_comments(t,!0),this.start_of_object_property()||this.allow_wrap_or_preserved_newline(t,h(t,["do","for","if","while"])),!0)},T.prototype.handle_start_expr=function(t){this.start_of_statement(t)||this.handle_whitespace_and_comments(t);var e=k;if("["===t.text){if(this._flags.last_token.type===l.WORD||")"===this._flags.last_token.text)return h(this._flags.last_token,u)&&(this._output.space_before_token=!0),this.print_token(t),this.set_mode(e),this.indent(),void(this._options.space_in_paren&&(this._output.space_before_token=!0));e=b,O(this._flags.mode)&&("["!==this._flags.last_token.text&&(","!==this._flags.last_token.text||"]"!==this._last_last_text&&"}"!==this._last_last_text)||this._options.keep_array_indentation||this.print_newline()),f(this._flags.last_token.type,[l.START_EXPR,l.END_EXPR,l.WORD,l.OPERATOR])||(this._output.space_before_token=!0)}else{if(this._flags.last_token.type===l.RESERVED)"for"===this._flags.last_token.text?(this._output.space_before_token=this._options.space_before_conditional,e=w):f(this._flags.last_token.text,["if","while"])?(this._output.space_before_token=this._options.space_before_conditional,e=x):f(this._flags.last_word,["await","async"])?this._output.space_before_token=!0:"import"===this._flags.last_token.text&&""===t.whitespace_before?this._output.space_before_token=!1:(f(this._flags.last_token.text,u)||"catch"===this._flags.last_token.text)&&(this._output.space_before_token=!0);else if(this._flags.last_token.type===l.EQUALS||this._flags.last_token.type===l.OPERATOR)this.start_of_object_property()||this.allow_wrap_or_preserved_newline(t);else if(this._flags.last_token.type===l.WORD){this._output.space_before_token=!1;var n=this._tokens.peek(-3);if(this._options.space_after_named_function&&n){var r=this._tokens.peek(-4);h(n,["async","function"])||"*"===n.text&&h(r,["async","function"])?this._output.space_before_token=!0:this._flags.mode===y&&("{"!==n.text&&","!==n.text&&("*"!==n.text||"{"!==r.text&&","!==r.text)||(this._output.space_before_token=!0))}}else this.allow_wrap_or_preserved_newline(t);(this._flags.last_token.type===l.RESERVED&&("function"===this._flags.last_word||"typeof"===this._flags.last_word)||"*"===this._flags.last_token.text&&(f(this._last_last_text,["function","yield"])||this._flags.mode===y&&f(this._last_last_text,["{",","])))&&(this._output.space_before_token=this._options.space_after_anon_function)}";"===this._flags.last_token.text||this._flags.last_token.type===l.START_BLOCK?this.print_newline():this._flags.last_token.type!==l.END_EXPR&&this._flags.last_token.type!==l.START_EXPR&&this._flags.last_token.type!==l.END_BLOCK&&"."!==this._flags.last_token.text&&this._flags.last_token.type!==l.COMMA||this.allow_wrap_or_preserved_newline(t,t.newlines),this.print_token(t),this.set_mode(e),this._options.space_in_paren&&(this._output.space_before_token=!0),this.indent()},T.prototype.handle_end_expr=function(t){for(;this._flags.mode===g;)this.restore_mode();this.handle_whitespace_and_comments(t),this._flags.multiline_frame&&this.allow_wrap_or_preserved_newline(t,"]"===t.text&&O(this._flags.mode)&&!this._options.keep_array_indentation),this._options.space_in_paren&&(this._flags.last_token.type!==l.START_EXPR||this._options.space_in_empty_paren?this._output.space_before_token=!0:(this._output.trim(),this._output.space_before_token=!1)),this.deindent(),this.print_token(t),this.restore_mode(),S(this._output,this._previous_flags),this._flags.do_while&&this._previous_flags.mode===x&&(this._previous_flags.mode=k,this._flags.do_block=!1,this._flags.do_while=!1)},T.prototype.handle_start_block=function(t){this.handle_whitespace_and_comments(t);var e=this._tokens.peek(),n=this._tokens.peek(1);"switch"===this._flags.last_word&&this._flags.last_token.type===l.END_EXPR?(this.set_mode(m),this._flags.in_case_statement=!0):this._flags.case_body?this.set_mode(m):n&&(f(n.text,[":",","])&&f(e.type,[l.STRING,l.WORD,l.RESERVED])||f(e.text,["get","set","..."])&&f(n.type,[l.WORD,l.RESERVED]))?f(this._last_last_text,["class","interface"])?this.set_mode(m):this.set_mode(y):this._flags.last_token.type===l.OPERATOR&&"=>"===this._flags.last_token.text?this.set_mode(m):f(this._flags.last_token.type,[l.EQUALS,l.START_EXPR,l.COMMA,l.OPERATOR])||h(this._flags.last_token,["return","throw","import","default"])?this.set_mode(y):this.set_mode(m);var r=!e.comments_before&&"}"===e.text,i=r&&"function"===this._flags.last_word&&this._flags.last_token.type===l.END_EXPR;if(this._options.brace_preserve_inline){var o=0,s=null;this._flags.inline_frame=!0;do{if(o+=1,(s=this._tokens.peek(o-1)).newlines){this._flags.inline_frame=!1;break}}while(s.type!==l.EOF&&(s.type!==l.END_BLOCK||s.opened!==t))}("expand"===this._options.brace_style||"none"===this._options.brace_style&&t.newlines)&&!this._flags.inline_frame?this._flags.last_token.type!==l.OPERATOR&&(i||this._flags.last_token.type===l.EQUALS||h(this._flags.last_token,d)&&"else"!==this._flags.last_token.text)?this._output.space_before_token=!0:this.print_newline(!1,!0):(!O(this._previous_flags.mode)||this._flags.last_token.type!==l.START_EXPR&&this._flags.last_token.type!==l.COMMA||((this._flags.last_token.type===l.COMMA||this._options.space_in_paren)&&(this._output.space_before_token=!0),(this._flags.last_token.type===l.COMMA||this._flags.last_token.type===l.START_EXPR&&this._flags.inline_frame)&&(this.allow_wrap_or_preserved_newline(t),this._previous_flags.multiline_frame=this._previous_flags.multiline_frame||this._flags.multiline_frame,this._flags.multiline_frame=!1)),this._flags.last_token.type!==l.OPERATOR&&this._flags.last_token.type!==l.START_EXPR&&(this._flags.last_token.type!==l.START_BLOCK||this._flags.inline_frame?this._output.space_before_token=!0:this.print_newline())),this.print_token(t),this.indent(),r||this._options.brace_preserve_inline&&this._flags.inline_frame||this.print_newline()},T.prototype.handle_end_block=function(t){for(this.handle_whitespace_and_comments(t);this._flags.mode===g;)this.restore_mode();var e=this._flags.last_token.type===l.START_BLOCK;this._flags.inline_frame&&!e?this._output.space_before_token=!0:"expand"===this._options.brace_style?e||this.print_newline():e||(O(this._flags.mode)&&this._options.keep_array_indentation?(this._options.keep_array_indentation=!1,this.print_newline(),this._options.keep_array_indentation=!0):this.print_newline()),this.restore_mode(),this.print_token(t)},T.prototype.handle_word=function(t){if(t.type===l.RESERVED&&(f(t.text,["set","get"])&&this._flags.mode!==y||"import"===t.text&&"("===this._tokens.peek().text||f(t.text,["as","from"])&&!this._flags.import_block||this._flags.mode===y&&":"===this._tokens.peek().text)&&(t.type=l.WORD),this.start_of_statement(t)?h(this._flags.last_token,["var","let","const"])&&t.type===l.WORD&&(this._flags.declaration_statement=!0):!t.newlines||C(this._flags.mode)||this._flags.last_token.type===l.OPERATOR&&"--"!==this._flags.last_token.text&&"++"!==this._flags.last_token.text||this._flags.last_token.type===l.EQUALS||!this._options.preserve_newlines&&h(this._flags.last_token,["var","let","const","set","get"])?this.handle_whitespace_and_comments(t):(this.handle_whitespace_and_comments(t),this.print_newline()),this._flags.do_block&&!this._flags.do_while){if(p(t,"while"))return this._output.space_before_token=!0,this.print_token(t),this._output.space_before_token=!0,void(this._flags.do_while=!0);this.print_newline(),this._flags.do_block=!1}if(this._flags.if_block)if(!this._flags.else_block&&p(t,"else"))this._flags.else_block=!0;else{for(;this._flags.mode===g;)this.restore_mode();this._flags.if_block=!1,this._flags.else_block=!1}if(this._flags.in_case_statement&&h(t,["case","default"]))return this.print_newline(),this._flags.last_token.type!==l.END_BLOCK&&(this._flags.case_body||this._options.jslint_happy)&&this.deindent(),this._flags.case_body=!1,this.print_token(t),void(this._flags.in_case=!0);if(this._flags.last_token.type!==l.COMMA&&this._flags.last_token.type!==l.START_EXPR&&this._flags.last_token.type!==l.EQUALS&&this._flags.last_token.type!==l.OPERATOR||this.start_of_object_property()||this.allow_wrap_or_preserved_newline(t),p(t,"function"))return(f(this._flags.last_token.text,["}",";"])||this._output.just_added_newline()&&!f(this._flags.last_token.text,["(","[","{",":","=",","])&&this._flags.last_token.type!==l.OPERATOR)&&(this._output.just_added_blankline()||t.comments_before||(this.print_newline(),this.print_newline(!0))),this._flags.last_token.type===l.RESERVED||this._flags.last_token.type===l.WORD?h(this._flags.last_token,["get","set","new","export"])||h(this._flags.last_token,M)||p(this._flags.last_token,"default")&&"export"===this._last_last_text||"declare"===this._flags.last_token.text?this._output.space_before_token=!0:this.print_newline():this._flags.last_token.type===l.OPERATOR||"="===this._flags.last_token.text?this._output.space_before_token=!0:(this._flags.multiline_frame||!C(this._flags.mode)&&!O(this._flags.mode))&&this.print_newline(),this.print_token(t),void(this._flags.last_word=t.text);var e="NONE";this._flags.last_token.type===l.END_BLOCK?this._previous_flags.inline_frame?e="SPACE":h(t,["else","catch","finally","from"])?"expand"===this._options.brace_style||"end-expand"===this._options.brace_style||"none"===this._options.brace_style&&t.newlines?e="NEWLINE":(e="SPACE",this._output.space_before_token=!0):e="NEWLINE":this._flags.last_token.type===l.SEMICOLON&&this._flags.mode===m?e="NEWLINE":this._flags.last_token.type===l.SEMICOLON&&C(this._flags.mode)?e="SPACE":this._flags.last_token.type===l.STRING?e="NEWLINE":this._flags.last_token.type===l.RESERVED||this._flags.last_token.type===l.WORD||"*"===this._flags.last_token.text&&(f(this._last_last_text,["function","yield"])||this._flags.mode===y&&f(this._last_last_text,["{",","]))?e="SPACE":this._flags.last_token.type===l.START_BLOCK?e=this._flags.inline_frame?"SPACE":"NEWLINE":this._flags.last_token.type===l.END_EXPR&&(this._output.space_before_token=!0,e="NEWLINE"),h(t,u)&&")"!==this._flags.last_token.text&&(e=this._flags.inline_frame||"else"===this._flags.last_token.text||"export"===this._flags.last_token.text?"SPACE":"NEWLINE"),h(t,["else","catch","finally"])?(this._flags.last_token.type!==l.END_BLOCK||this._previous_flags.mode!==m||"expand"===this._options.brace_style||"end-expand"===this._options.brace_style||"none"===this._options.brace_style&&t.newlines)&&!this._flags.inline_frame?this.print_newline():(this._output.trim(!0),"}"!==this._output.current_line.last()&&this.print_newline(),this._output.space_before_token=!0):"NEWLINE"===e?h(this._flags.last_token,d)||"declare"===this._flags.last_token.text&&h(t,["var","let","const"])?this._output.space_before_token=!0:this._flags.last_token.type!==l.END_EXPR?this._flags.last_token.type===l.START_EXPR&&h(t,["var","let","const"])||":"===this._flags.last_token.text||(p(t,"if")&&p(t.previous,"else")?this._output.space_before_token=!0:this.print_newline()):h(t,u)&&")"!==this._flags.last_token.text&&this.print_newline():this._flags.multiline_frame&&O(this._flags.mode)&&","===this._flags.last_token.text&&"}"===this._last_last_text?this.print_newline():"SPACE"===e&&(this._output.space_before_token=!0),!t.previous||t.previous.type!==l.WORD&&t.previous.type!==l.RESERVED||(this._output.space_before_token=!0),this.print_token(t),this._flags.last_word=t.text,t.type===l.RESERVED&&("do"===t.text?this._flags.do_block=!0:"if"===t.text?this._flags.if_block=!0:"import"===t.text?this._flags.import_block=!0:this._flags.import_block&&p(t,"from")&&(this._flags.import_block=!1))},T.prototype.handle_semicolon=function(t){this.start_of_statement(t)?this._output.space_before_token=!1:this.handle_whitespace_and_comments(t);for(var e=this._tokens.peek();!(this._flags.mode!==g||this._flags.if_block&&p(e,"else")||this._flags.do_block);)this.restore_mode();this._flags.import_block&&(this._flags.import_block=!1),this.print_token(t)},T.prototype.handle_string=function(t){this.start_of_statement(t)?this._output.space_before_token=!0:(this.handle_whitespace_and_comments(t),this._flags.last_token.type===l.RESERVED||this._flags.last_token.type===l.WORD||this._flags.inline_frame?this._output.space_before_token=!0:this._flags.last_token.type===l.COMMA||this._flags.last_token.type===l.START_EXPR||this._flags.last_token.type===l.EQUALS||this._flags.last_token.type===l.OPERATOR?this.start_of_object_property()||this.allow_wrap_or_preserved_newline(t):this.print_newline()),this.print_token(t)},T.prototype.handle_equals=function(t){this.start_of_statement(t)||this.handle_whitespace_and_comments(t),this._flags.declaration_statement&&(this._flags.declaration_assignment=!0),this._output.space_before_token=!0,this.print_token(t),this._output.space_before_token=!0},T.prototype.handle_comma=function(t){this.handle_whitespace_and_comments(t,!0),this.print_token(t),this._output.space_before_token=!0,this._flags.declaration_statement?(C(this._flags.parent.mode)&&(this._flags.declaration_assignment=!1),this._flags.declaration_assignment?(this._flags.declaration_assignment=!1,this.print_newline(!1,!0)):this._options.comma_first&&this.allow_wrap_or_preserved_newline(t)):this._flags.mode===y||this._flags.mode===g&&this._flags.parent.mode===y?(this._flags.mode===g&&this.restore_mode(),this._flags.inline_frame||this.print_newline()):this._options.comma_first&&this.allow_wrap_or_preserved_newline(t)},T.prototype.handle_operator=function(t){var e="*"===t.text&&(h(this._flags.last_token,["function","yield"])||f(this._flags.last_token.type,[l.START_BLOCK,l.COMMA,l.END_BLOCK,l.SEMICOLON])),n=f(t.text,["-","+"])&&(f(this._flags.last_token.type,[l.START_BLOCK,l.START_EXPR,l.EQUALS,l.OPERATOR])||f(this._flags.last_token.text,u)||","===this._flags.last_token.text);if(this.start_of_statement(t));else{var r=!e;this.handle_whitespace_and_comments(t,r)}if(h(this._flags.last_token,d))return this._output.space_before_token=!0,void this.print_token(t);if("*"!==t.text||this._flags.last_token.type!==l.DOT)if("::"!==t.text){if(this._flags.last_token.type===l.OPERATOR&&f(this._options.operator_position,v)&&this.allow_wrap_or_preserved_newline(t),":"===t.text&&this._flags.in_case)return this.print_token(t),this._flags.in_case=!1,this._flags.case_body=!0,void(this._tokens.peek().type!==l.START_BLOCK?(this.indent(),this.print_newline()):this._output.space_before_token=!0);var i=!0,o=!0,s=!1;if(":"===t.text?0===this._flags.ternary_depth?i=!1:(this._flags.ternary_depth-=1,s=!0):"?"===t.text&&(this._flags.ternary_depth+=1),!n&&!e&&this._options.preserve_newlines&&f(t.text,c)){var a=":"===t.text,p=a&&s,y=a&&!s;switch(this._options.operator_position){case _.before_newline:return this._output.space_before_token=!y,this.print_token(t),a&&!p||this.allow_wrap_or_preserved_newline(t),void(this._output.space_before_token=!0);case _.after_newline:return this._output.space_before_token=!0,!a||p?this._tokens.peek().newlines?this.print_newline(!1,!0):this.allow_wrap_or_preserved_newline(t):this._output.space_before_token=!1,this.print_token(t),void(this._output.space_before_token=!0);case _.preserve_newline:return y||this.allow_wrap_or_preserved_newline(t),i=!(this._output.just_added_newline()||y),this._output.space_before_token=i,this.print_token(t),void(this._output.space_before_token=!0)}}if(e){this.allow_wrap_or_preserved_newline(t),i=!1;var b=this._tokens.peek();o=b&&f(b.type,[l.WORD,l.RESERVED])}else"..."===t.text?(this.allow_wrap_or_preserved_newline(t),i=this._flags.last_token.type===l.START_BLOCK,o=!1):(f(t.text,["--","++","!","~"])||n)&&(this._flags.last_token.type!==l.COMMA&&this._flags.last_token.type!==l.START_EXPR||this.allow_wrap_or_preserved_newline(t),i=!1,o=!1,!t.newlines||"--"!==t.text&&"++"!==t.text||this.print_newline(!1,!0),";"===this._flags.last_token.text&&C(this._flags.mode)&&(i=!0),this._flags.last_token.type===l.RESERVED?i=!0:this._flags.last_token.type===l.END_EXPR?i=!("]"===this._flags.last_token.text&&("--"===t.text||"++"===t.text)):this._flags.last_token.type===l.OPERATOR&&(i=f(t.text,["--","-","++","+"])&&f(this._flags.last_token.text,["--","-","++","+"]),f(t.text,["+","-"])&&f(this._flags.last_token.text,["--","++"])&&(o=!0)),(this._flags.mode!==m||this._flags.inline_frame)&&this._flags.mode!==g||"{"!==this._flags.last_token.text&&";"!==this._flags.last_token.text||this.print_newline());this._output.space_before_token=this._output.space_before_token||i,this.print_token(t),this._output.space_before_token=o}else this.print_token(t);else this.print_token(t)},T.prototype.handle_block_comment=function(t,e){return this._output.raw?(this._output.add_raw_token(t),void(t.directives&&"end"===t.directives.preserve&&(this._output.raw=this._options.test_output_raw))):t.directives?(this.print_newline(!1,e),this.print_token(t),"start"===t.directives.preserve&&(this._output.raw=!0),void this.print_newline(!1,!0)):o.newline.test(t.text)||t.newlines?void this.print_block_commment(t,e):(this._output.space_before_token=!0,this.print_token(t),void(this._output.space_before_token=!0))},T.prototype.print_block_commment=function(t,e){var n,r=function(t){for(var e=[],n=(t=t.replace(o.allLineBreaks,"\n")).indexOf("\n");-1!==n;)e.push(t.substring(0,n)),n=(t=t.substring(n+1)).indexOf("\n");return t.length&&e.push(t),e}(t.text),i=!1,s=!1,a=t.whitespace_before,u=a.length;if(this.print_newline(!1,e),this.print_token_line_indentation(t),this._output.add_token(r[0]),this.print_newline(!1,e),r.length>1){for(i=function(t,e){for(var n=0;n0&&(e=new Array(t.indent_level+1).join(this.__indent_string)),this.__base_string=e,this.__base_string_length=e.length}function o(t,e){this.__indent_cache=new i(t,e),this.raw=!1,this._end_with_newline=t.end_with_newline,this.indent_size=t.indent_size,this.wrap_line_length=t.wrap_line_length,this.indent_empty_lines=t.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new r(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}r.prototype.clone_empty=function(){var t=new r(this.__parent);return t.set_indent(this.__indent_count,this.__alignment_count),t},r.prototype.item=function(t){return t<0?this.__items[this.__items.length+t]:this.__items[t]},r.prototype.has_match=function(t){for(var e=this.__items.length-1;e>=0;e--)if(this.__items[e].match(t))return!0;return!1},r.prototype.set_indent=function(t,e){this.is_empty()&&(this.__indent_count=t||0,this.__alignment_count=e||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},r.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},r.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},r.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var t=this.__parent.current_line;return t.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),t.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),t.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count," "===t.__items[0]&&(t.__items.splice(0,1),t.__character_count-=1),!0}return!1},r.prototype.is_empty=function(){return 0===this.__items.length},r.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},r.prototype.push=function(t){this.__items.push(t);var e=t.lastIndexOf("\n");-1!==e?this.__character_count=t.length-e:this.__character_count+=t.length},r.prototype.pop=function(){var t=null;return this.is_empty()||(t=this.__items.pop(),this.__character_count-=t.length),t},r.prototype._remove_indent=function(){this.__indent_count>0&&(this.__indent_count-=1,this.__character_count-=this.__parent.indent_size)},r.prototype._remove_wrap_indent=function(){this.__wrap_point_indent_count>0&&(this.__wrap_point_indent_count-=1)},r.prototype.trim=function(){for(;" "===this.last();)this.__items.pop(),this.__character_count-=1},r.prototype.toString=function(){var t="";return this.is_empty()?this.__parent.indent_empty_lines&&(t=this.__parent.get_indent_string(this.__indent_count)):(t=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),t+=this.__items.join("")),t},i.prototype.get_indent_size=function(t,e){var n=this.__base_string_length;return e=e||0,t<0&&(n=0),n+=t*this.__indent_size,n+=e},i.prototype.get_indent_string=function(t,e){var n=this.__base_string;return e=e||0,t<0&&(t=0,n=""),e+=t*this.__indent_size,this.__ensure_cache(e),n+=this.__cache[e]},i.prototype.__ensure_cache=function(t){for(;t>=this.__cache.length;)this.__add_column()},i.prototype.__add_column=function(){var t=this.__cache.length,e=0,n="";this.__indent_size&&t>=this.__indent_size&&(t-=(e=Math.floor(t/this.__indent_size))*this.__indent_size,n=new Array(e+1).join(this.__indent_string)),t&&(n+=new Array(t+1).join(" ")),this.__cache.push(n)},o.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},o.prototype.get_line_number=function(){return this.__lines.length},o.prototype.get_indent_string=function(t,e){return this.__indent_cache.get_indent_string(t,e)},o.prototype.get_indent_size=function(t,e){return this.__indent_cache.get_indent_size(t,e)},o.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},o.prototype.add_new_line=function(t){return!(this.is_empty()||!t&&this.just_added_newline()||(this.raw||this.__add_outputline(),0))},o.prototype.get_code=function(t){this.trim(!0);var e=this.current_line.pop();e&&("\n"===e[e.length-1]&&(e=e.replace(/\n+$/g,"")),this.current_line.push(e)),this._end_with_newline&&this.__add_outputline();var n=this.__lines.join("\n");return"\n"!==t&&(n=n.replace(/[\n]/g,t)),n},o.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},o.prototype.set_indent=function(t,e){return t=t||0,e=e||0,this.next_line.set_indent(t,e),this.__lines.length>1?(this.current_line.set_indent(t,e),!0):(this.current_line.set_indent(),!1)},o.prototype.add_raw_token=function(t){for(var e=0;e1&&this.current_line.is_empty();)this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null},o.prototype.just_added_newline=function(){return this.current_line.is_empty()},o.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()},o.prototype.ensure_empty_line_above=function(t,e){for(var n=this.__lines.length-2;n>=0;){var i=this.__lines[n];if(i.is_empty())break;if(0!==i.item(0).indexOf(t)&&i.item(-1)!==e){this.__lines.splice(n+1,0,new r(this)),this.previous_line=this.__lines[this.__lines.length-2];break}n--}},t.exports.Output=o},function(t,e,n){"use strict";t.exports.Token=function(t,e,n,r){this.type=t,this.text=e,this.comments_before=null,this.newlines=n||0,this.whitespace_before=r||"",this.parent=null,this.next=null,this.previous=null,this.opened=null,this.closed=null,this.directives=null}},function(t,e,n){"use strict";var r="\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05d0-\\u05ea\\u05f0-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u08a0\\u08a2-\\u08ac\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0977\\u0979-\\u097f\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c33\\u0c35-\\u0c39\\u0c3d\\u0c58\\u0c59\\u0c60\\u0c61\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d05-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d60\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e87\\u0e88\\u0e8a\\u0e8d\\u0e94-\\u0e97\\u0e99-\\u0e9f\\u0ea1-\\u0ea3\\u0ea5\\u0ea7\\u0eaa\\u0eab\\u0ead-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f4\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f0\\u1700-\\u170c\\u170e-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1877\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191c\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19c1-\\u19c7\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4b\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1ce9-\\u1cec\\u1cee-\\u1cf1\\u1cf5\\u1cf6\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2119-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u212d\\u212f-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2c2e\\u2c30-\\u2c5e\\u2c60-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u2e2f\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309d-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312d\\u3131-\\u318e\\u31a0-\\u31ba\\u31f0-\\u31ff\\u3400-\\u4db5\\u4e00-\\u9fcc\\ua000-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua697\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua78e\\ua790-\\ua793\\ua7a0-\\ua7aa\\ua7f8-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa80-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uabc0-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc",i="\\u0300-\\u036f\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u0620-\\u0649\\u0672-\\u06d3\\u06e7-\\u06e8\\u06fb-\\u06fc\\u0730-\\u074a\\u0800-\\u0814\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0840-\\u0857\\u08e4-\\u08fe\\u0900-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962-\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09d7\\u09df-\\u09e0\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2-\\u0ae3\\u0ae6-\\u0aef\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b56\\u0b57\\u0b5f-\\u0b60\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c01-\\u0c03\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62-\\u0c63\\u0c66-\\u0c6f\\u0c82\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2-\\u0ce3\\u0ce6-\\u0cef\\u0d02\\u0d03\\u0d46-\\u0d48\\u0d57\\u0d62-\\u0d63\\u0d66-\\u0d6f\\u0d82\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0df2\\u0df3\\u0e34-\\u0e3a\\u0e40-\\u0e45\\u0e50-\\u0e59\\u0eb4-\\u0eb9\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f41-\\u0f47\\u0f71-\\u0f84\\u0f86-\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u1000-\\u1029\\u1040-\\u1049\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u170e-\\u1710\\u1720-\\u1730\\u1740-\\u1750\\u1772\\u1773\\u1780-\\u17b2\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u1810-\\u1819\\u1920-\\u192b\\u1930-\\u193b\\u1951-\\u196d\\u19b0-\\u19c0\\u19c8-\\u19c9\\u19d0-\\u19d9\\u1a00-\\u1a15\\u1a20-\\u1a53\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1b46-\\u1b4b\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c00-\\u1c22\\u1c40-\\u1c49\\u1c5b-\\u1c7d\\u1cd0-\\u1cd2\\u1d00-\\u1dbe\\u1e01-\\u1f15\\u200c\\u200d\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2d81-\\u2d96\\u2de0-\\u2dff\\u3021-\\u3028\\u3099\\u309a\\ua640-\\ua66d\\ua674-\\ua67d\\ua69f\\ua6f0-\\ua6f1\\ua7f8-\\ua800\\ua806\\ua80b\\ua823-\\ua827\\ua880-\\ua881\\ua8b4-\\ua8c4\\ua8d0-\\ua8d9\\ua8f3-\\ua8f7\\ua900-\\ua909\\ua926-\\ua92d\\ua930-\\ua945\\ua980-\\ua983\\ua9b3-\\ua9c0\\uaa00-\\uaa27\\uaa40-\\uaa41\\uaa4c-\\uaa4d\\uaa50-\\uaa59\\uaa7b\\uaae0-\\uaae9\\uaaf2-\\uaaf3\\uabc0-\\uabe1\\uabec\\uabed\\uabf0-\\uabf9\\ufb20-\\ufb28\\ufe00-\\ufe0f\\ufe20-\\ufe26\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f",o="(?:\\\\u[0-9a-fA-F]{4}|[\\x23\\x24\\x40\\x41-\\x5a\\x5f\\x61-\\x7a"+r+"])";e.identifier=new RegExp(o+"(?:\\\\u[0-9a-fA-F]{4}|[\\x24\\x30-\\x39\\x41-\\x5a\\x5f\\x61-\\x7a\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05d0-\\u05ea\\u05f0-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u08a0\\u08a2-\\u08ac\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0977\\u0979-\\u097f\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c33\\u0c35-\\u0c39\\u0c3d\\u0c58\\u0c59\\u0c60\\u0c61\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d05-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d60\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e87\\u0e88\\u0e8a\\u0e8d\\u0e94-\\u0e97\\u0e99-\\u0e9f\\u0ea1-\\u0ea3\\u0ea5\\u0ea7\\u0eaa\\u0eab\\u0ead-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f4\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f0\\u1700-\\u170c\\u170e-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1877\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191c\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19c1-\\u19c7\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4b\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1ce9-\\u1cec\\u1cee-\\u1cf1\\u1cf5\\u1cf6\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2119-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u212d\\u212f-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2c2e\\u2c30-\\u2c5e\\u2c60-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u2e2f\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309d-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312d\\u3131-\\u318e\\u31a0-\\u31ba\\u31f0-\\u31ff\\u3400-\\u4db5\\u4e00-\\u9fcc\\ua000-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua697\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua78e\\ua790-\\ua793\\ua7a0-\\ua7aa\\ua7f8-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa80-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uabc0-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc\\u0300-\\u036f\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u0620-\\u0649\\u0672-\\u06d3\\u06e7-\\u06e8\\u06fb-\\u06fc\\u0730-\\u074a\\u0800-\\u0814\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0840-\\u0857\\u08e4-\\u08fe\\u0900-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962-\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09d7\\u09df-\\u09e0\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2-\\u0ae3\\u0ae6-\\u0aef\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b56\\u0b57\\u0b5f-\\u0b60\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c01-\\u0c03\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62-\\u0c63\\u0c66-\\u0c6f\\u0c82\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2-\\u0ce3\\u0ce6-\\u0cef\\u0d02\\u0d03\\u0d46-\\u0d48\\u0d57\\u0d62-\\u0d63\\u0d66-\\u0d6f\\u0d82\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0df2\\u0df3\\u0e34-\\u0e3a\\u0e40-\\u0e45\\u0e50-\\u0e59\\u0eb4-\\u0eb9\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f41-\\u0f47\\u0f71-\\u0f84\\u0f86-\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u1000-\\u1029\\u1040-\\u1049\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u170e-\\u1710\\u1720-\\u1730\\u1740-\\u1750\\u1772\\u1773\\u1780-\\u17b2\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u1810-\\u1819\\u1920-\\u192b\\u1930-\\u193b\\u1951-\\u196d\\u19b0-\\u19c0\\u19c8-\\u19c9\\u19d0-\\u19d9\\u1a00-\\u1a15\\u1a20-\\u1a53\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1b46-\\u1b4b\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c00-\\u1c22\\u1c40-\\u1c49\\u1c5b-\\u1c7d\\u1cd0-\\u1cd2\\u1d00-\\u1dbe\\u1e01-\\u1f15\\u200c\\u200d\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2d81-\\u2d96\\u2de0-\\u2dff\\u3021-\\u3028\\u3099\\u309a\\ua640-\\ua66d\\ua674-\\ua67d\\ua69f\\ua6f0-\\ua6f1\\ua7f8-\\ua800\\ua806\\ua80b\\ua823-\\ua827\\ua880-\\ua881\\ua8b4-\\ua8c4\\ua8d0-\\ua8d9\\ua8f3-\\ua8f7\\ua900-\\ua909\\ua926-\\ua92d\\ua930-\\ua945\\ua980-\\ua983\\ua9b3-\\ua9c0\\uaa00-\\uaa27\\uaa40-\\uaa41\\uaa4c-\\uaa4d\\uaa50-\\uaa59\\uaa7b\\uaae0-\\uaae9\\uaaf2-\\uaaf3\\uabc0-\\uabe1\\uabec\\uabed\\uabf0-\\uabf9\\ufb20-\\ufb28\\ufe00-\\ufe0f\\ufe20-\\ufe26\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f])*","g"),e.identifierStart=new RegExp(o),e.identifierMatch=new RegExp("(?:\\\\u[0-9a-fA-F]{4}|[\\x24\\x30-\\x39\\x41-\\x5a\\x5f\\x61-\\x7a"+r+i+"])+"),e.newline=/[\n\r\u2028\u2029]/,e.lineBreak=new RegExp("\r\n|"+e.newline.source),e.allLineBreaks=new RegExp(e.lineBreak.source,"g")},function(t,e,n){"use strict";var r=n(6).Options,i=["before-newline","after-newline","preserve-newline"];function o(t){r.call(this,t,"js");var e=this.raw_options.brace_style||null;"expand-strict"===e?this.raw_options.brace_style="expand":"collapse-preserve-inline"===e?this.raw_options.brace_style="collapse,preserve-inline":void 0!==this.raw_options.braces_on_own_line&&(this.raw_options.brace_style=this.raw_options.braces_on_own_line?"expand":"collapse");var n=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_preserve_inline=!1,this.brace_style="collapse";for(var o=0;o>> === !== << && >= ** != == <= >> || ?? |> < / - + > : & % ? ^ | *".split(" "),m=">>>= ... >>= <<= === >>> !== **= => ^= :: /= << <= == && -= >= >> != -- += ** || ?? ++ %= &= *= |= |> = ! ? > < : / ^ - + * & % ~ |";m=(m="\\?\\.(?!\\d) "+(m=m.replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&"))).replace(/ /g,"|");var g,y=new RegExp(m),b="continue,try,throw,return,var,let,const,if,switch,case,default,for,while,break,function,import,export".split(","),w=b.concat(["do","in","of","else","get","set","new","catch","finally","typeof","yield","async","await","from","as"]),x=new RegExp("^(?:"+w.join("|")+")$"),k=function(t,e){i.call(this,t,e),this._patterns.whitespace=this._patterns.whitespace.matching(/\u00A0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff/.source,/\u2028\u2029/.source);var n=new u(this._input),r=new c(this._input).read_options(this._options);this.__patterns={template:r,identifier:r.starting_with(a.identifier).matching(a.identifierMatch),number:n.matching(h),punct:n.matching(y),comment:n.starting_with(/\/\//).until(/[\n\r\u2028\u2029]/),block_comment:n.starting_with(/\/\*/).until_after(/\*\//),html_comment_start:n.matching(//),include:n.starting_with(/#include/).until_after(a.lineBreak),shebang:n.starting_with(/#!/).until_after(a.lineBreak),xml:n.matching(/[\s\S]*?<(\/?)([-a-zA-Z:0-9_.]+|{[\s\S]+?}|!\[CDATA\[[\s\S]*?\]\])(\s+{[\s\S]+?}|\s+[-a-zA-Z:0-9_.]+|\s+[-a-zA-Z:0-9_.]+\s*=\s*('[^']*'|"[^"]*"|{[\s\S]+?}))*\s*(\/?)\s*>/),single_quote:r.until(/['\\\n\r\u2028\u2029]/),double_quote:r.until(/["\\\n\r\u2028\u2029]/),template_text:r.until(/[`\\$]/),template_expression:r.until(/[`}\\]/)}};(k.prototype=new i)._is_comment=function(t){return t.type===f.COMMENT||t.type===f.BLOCK_COMMENT||t.type===f.UNKNOWN},k.prototype._is_opening=function(t){return t.type===f.START_BLOCK||t.type===f.START_EXPR},k.prototype._is_closing=function(t,e){return(t.type===f.END_BLOCK||t.type===f.END_EXPR)&&e&&("]"===t.text&&"["===e.text||")"===t.text&&"("===e.text||"}"===t.text&&"{"===e.text)},k.prototype._reset=function(){g=!1},k.prototype._get_next_token=function(t,e){var n=null;this._readWhitespace();var r=this._input.peek();return null===r?this._create_token(f.EOF,""):n=(n=(n=(n=(n=(n=(n=(n=(n=n||this._read_non_javascript(r))||this._read_string(r))||this._read_word(t))||this._read_singles(r))||this._read_comment(r))||this._read_regexp(r,t))||this._read_xml(r,t))||this._read_punctuation())||this._create_token(f.UNKNOWN,this._input.next())},k.prototype._read_word=function(t){var e;return""!==(e=this.__patterns.identifier.read())?(e=e.replace(a.allLineBreaks,"\n"),t.type!==f.DOT&&(t.type!==f.RESERVED||"set"!==t.text&&"get"!==t.text)&&x.test(e)?"in"===e||"of"===e?this._create_token(f.OPERATOR,e):this._create_token(f.RESERVED,e):this._create_token(f.WORD,e)):""!==(e=this.__patterns.number.read())?this._create_token(f.WORD,e):void 0},k.prototype._read_singles=function(t){var e=null;return"("===t||"["===t?e=this._create_token(f.START_EXPR,t):")"===t||"]"===t?e=this._create_token(f.END_EXPR,t):"{"===t?e=this._create_token(f.START_BLOCK,t):"}"===t?e=this._create_token(f.END_BLOCK,t):";"===t?e=this._create_token(f.SEMICOLON,t):"."===t&&_.test(this._input.peek(1))?e=this._create_token(f.DOT,t):","===t&&(e=this._create_token(f.COMMA,t)),e&&this._input.next(),e},k.prototype._read_punctuation=function(){var t=this.__patterns.punct.read();if(""!==t)return"="===t?this._create_token(f.EQUALS,t):"?."===t?this._create_token(f.DOT,t):this._create_token(f.OPERATOR,t)},k.prototype._read_non_javascript=function(t){var e="";if("#"===t){if(this._is_first_token()&&(e=this.__patterns.shebang.read()))return this._create_token(f.UNKNOWN,e.trim()+"\n");if(e=this.__patterns.include.read())return this._create_token(f.UNKNOWN,e.trim()+"\n");t=this._input.next();var n="#";if(this._input.hasNext()&&this._input.testChar(d)){do{n+=t=this._input.next()}while(this._input.hasNext()&&"#"!==t&&"="!==t);return"#"===t||("["===this._input.peek()&&"]"===this._input.peek(1)?(n+="[]",this._input.next(),this._input.next()):"{"===this._input.peek()&&"}"===this._input.peek(1)&&(n+="{}",this._input.next(),this._input.next())),this._create_token(f.WORD,n)}this._input.back()}else if("<"===t&&this._is_first_token()){if(e=this.__patterns.html_comment_start.read()){for(;this._input.hasNext()&&!this._input.testChar(a.newline);)e+=this._input.next();return g=!0,this._create_token(f.COMMENT,e)}}else if(g&&"-"===t&&(e=this.__patterns.html_comment_end.read()))return g=!1,this._create_token(f.COMMENT,e);return null},k.prototype._read_comment=function(t){var e=null;if("/"===t){var n="";if("*"===this._input.peek(1)){n=this.__patterns.block_comment.read();var r=p.get_directives(n);r&&"start"===r.ignore&&(n+=p.readIgnored(this._input)),n=n.replace(a.allLineBreaks,"\n"),(e=this._create_token(f.BLOCK_COMMENT,n)).directives=r}else"/"===this._input.peek(1)&&(n=this.__patterns.comment.read(),e=this._create_token(f.COMMENT,n))}return e},k.prototype._read_string=function(t){if("`"===t||"'"===t||'"'===t){var e=this._input.next();return this.has_char_escapes=!1,e+="`"===t?this._read_string_recursive("`",!0,"${"):this._read_string_recursive(t),this.has_char_escapes&&this._options.unescape_strings&&(e=function(t){for(var e="",n=0,i=new r(t),o=null;i.hasNext();)if((o=i.match(/([\s]|[^\\]|\\\\)+/g))&&(e+=o[0]),"\\"===i.peek()){if(i.next(),"x"===i.peek())o=i.match(/x([0-9A-Fa-f]{2})/g);else{if("u"!==i.peek()){e+="\\",i.hasNext()&&(e+=i.next());continue}o=i.match(/u([0-9A-Fa-f]{4})/g)}if(!o)return t;if((n=parseInt(o[1],16))>126&&n<=255&&0===o[0].indexOf("x"))return t;if(n>=0&&n<32){e+="\\"+o[0];continue}e+=34===n||39===n||92===n?"\\"+String.fromCharCode(n):String.fromCharCode(n)}return e}(e)),this._input.peek()===t&&(e+=this._input.next()),e=e.replace(a.allLineBreaks,"\n"),this._create_token(f.STRING,e)}return null},k.prototype._allow_regexp_or_xml=function(t){return t.type===f.RESERVED&&l(t.text,["return","case","throw","else","do","typeof","yield"])||t.type===f.END_EXPR&&")"===t.text&&t.opened.previous.type===f.RESERVED&&l(t.opened.previous.text,["if","while","for"])||l(t.type,[f.COMMENT,f.START_EXPR,f.START_BLOCK,f.START,f.END_BLOCK,f.OPERATOR,f.EQUALS,f.EOF,f.SEMICOLON,f.COMMA])},k.prototype._read_regexp=function(t,e){if("/"===t&&this._allow_regexp_or_xml(e)){for(var n=this._input.next(),r=!1,i=!1;this._input.hasNext()&&(r||i||this._input.peek()!==t)&&!this._input.testChar(a.newline);)n+=this._input.peek(),r?r=!1:(r="\\"===this._input.peek(),"["===this._input.peek()?i=!0:"]"===this._input.peek()&&(i=!1)),this._input.next();return this._input.peek()===t&&(n+=this._input.next(),n+=this._input.read(a.identifier)),this._create_token(f.STRING,n)}return null},k.prototype._read_xml=function(t,e){if(this._options.e4x&&"<"===t&&this._allow_regexp_or_xml(e)){var n="",r=this.__patterns.xml.read_match();if(r){for(var i=r[2].replace(/^{\s+/,"{").replace(/\s+}$/,"}"),o=0===i.indexOf("{"),s=0;r;){var u=!!r[1],c=r[2];if(!(r[r.length-1]||"![CDATA["===c.slice(0,8))&&(c===i||o&&c.replace(/^{\s+/,"{").replace(/\s+}$/,"}"))&&(u?--s:++s),n+=r[0],s<=0)break;r=this.__patterns.xml.read_match()}return r||(n+=this._input.match(/[\s\S]*/g)[0]),n=n.replace(a.allLineBreaks,"\n"),this._create_token(f.STRING,n)}}return null},k.prototype._read_string_recursive=function(t,e,n){var r,i;"'"===t?i=this.__patterns.single_quote:'"'===t?i=this.__patterns.double_quote:"`"===t?i=this.__patterns.template_text:"}"===t&&(i=this.__patterns.template_expression);for(var o=i.read(),s="";this._input.hasNext();){if((s=this._input.next())===t||!e&&a.newline.test(s)){this._input.back();break}"\\"===s&&this._input.hasNext()?("x"===(r=this._input.peek())||"u"===r?this.has_char_escapes=!0:"\r"===r&&"\n"===this._input.peek(1)&&this._input.next(),s+=this._input.next()):n&&("${"===n&&"$"===s&&"{"===this._input.peek()&&(s+=this._input.next()),n===s&&(s+="`"===t?this._read_string_recursive("}",e,"`"):this._read_string_recursive("`",e,"${"),this._input.hasNext()&&(s+=this._input.next()))),o+=s+=i.read()}return o},t.exports.Tokenizer=k,t.exports.TOKEN=f,t.exports.positionable_operators=v.slice(),t.exports.line_starters=b.slice()},function(t,e,n){"use strict";var r=RegExp.prototype.hasOwnProperty("sticky");function i(t){this.__input=t||"",this.__input_length=this.__input.length,this.__position=0}i.prototype.restart=function(){this.__position=0},i.prototype.back=function(){this.__position>0&&(this.__position-=1)},i.prototype.hasNext=function(){return this.__position=0&&t=0&&e=t.length&&this.__input.substring(e-t.length,e).toLowerCase()===t},t.exports.InputScanner=i},function(t,e,n){"use strict";var r=n(8).InputScanner,i=n(3).Token,o=n(10).TokenStream,s=n(11).WhitespacePattern,a={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"},u=function(t,e){this._input=new r(t),this._options=e||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new s(this._input)};u.prototype.tokenize=function(){var t;this._input.restart(),this.__tokens=new o,this._reset();for(var e=new i(a.START,""),n=null,r=[],s=new o;e.type!==a.EOF;){for(t=this._get_next_token(e,n);this._is_comment(t);)s.add(t),t=this._get_next_token(e,n);s.isEmpty()||(t.comments_before=s,s=new o),t.parent=n,this._is_opening(t)?(r.push(n),n=t):n&&this._is_closing(t,n)&&(t.opened=n,n.closed=t,n=r.pop(),t.parent=n),t.previous=e,e.next=t,this.__tokens.add(t),e=t}return this.__tokens},u.prototype._is_first_token=function(){return this.__tokens.isEmpty()},u.prototype._reset=function(){},u.prototype._get_next_token=function(t,e){this._readWhitespace();var n=this._input.read(/.+/g);return n?this._create_token(a.RAW,n):this._create_token(a.EOF,"")},u.prototype._is_comment=function(t){return!1},u.prototype._is_opening=function(t){return!1},u.prototype._is_closing=function(t,e){return!1},u.prototype._create_token=function(t,e){return new i(t,e,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token)},u.prototype._readWhitespace=function(){return this._patterns.whitespace.read()},t.exports.Tokenizer=u,t.exports.TOKEN=a},function(t,e,n){"use strict";function r(t){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=t}r.prototype.restart=function(){this.__position=0},r.prototype.isEmpty=function(){return 0===this.__tokens_length},r.prototype.hasNext=function(){return this.__position=0&&t/),erb:n.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:n.starting_with(/{%/).until_after(/%}/),django_value:n.starting_with(/{{/).until_after(/}}/),django_comment:n.starting_with(/{#/).until_after(/#}/)}}o.prototype=new r,o.prototype._create=function(){return new o(this._input,this)},o.prototype._update=function(){this.__set_templated_pattern()},o.prototype.disable=function(t){var e=this._create();return e._disabled[t]=!0,e._update(),e},o.prototype.read_options=function(t){var e=this._create();for(var n in i)e._disabled[n]=-1===t.templating.indexOf(n);return e._update(),e},o.prototype.exclude=function(t){var e=this._create();return e._excluded[t]=!0,e._update(),e},o.prototype.read=function(){var t="";t=this._match_pattern?this._input.read(this._starting_pattern):this._input.read(this._starting_pattern,this.__template_pattern);for(var e=this._read_template();e;)this._match_pattern?e+=this._input.read(this._match_pattern):e+=this._input.readUntil(this.__template_pattern),t+=e,e=this._read_template();return this._until_after&&(t+=this._input.readUntilAfter(this._until_pattern)),t},o.prototype.__set_templated_pattern=function(){var t=[];this._disabled.php||t.push(this.__patterns.php._starting_pattern.source),this._disabled.handlebars||t.push(this.__patterns.handlebars._starting_pattern.source),this._disabled.erb||t.push(this.__patterns.erb._starting_pattern.source),this._disabled.django||(t.push(this.__patterns.django._starting_pattern.source),t.push(this.__patterns.django_value._starting_pattern.source),t.push(this.__patterns.django_comment._starting_pattern.source)),this._until_pattern&&t.push(this._until_pattern.source),this.__template_pattern=this._input.get_regexp("(?:"+t.join("|")+")")},o.prototype._read_template=function(){var t="",e=this._input.peek();if("<"===e){var n=this._input.peek(1);this._disabled.php||this._excluded.php||"?"!==n||(t=t||this.__patterns.php.read()),this._disabled.erb||this._excluded.erb||"%"!==n||(t=t||this.__patterns.erb.read())}else"{"===e&&(this._disabled.handlebars||this._excluded.handlebars||(t=(t=(t=t||this.__patterns.handlebars_comment.read())||this.__patterns.handlebars_unescaped.read())||this.__patterns.handlebars.read()),this._disabled.django||(this._excluded.django||this._excluded.handlebars||(t=t||this.__patterns.django_value.read()),this._excluded.django||(t=(t=t||this.__patterns.django_comment.read())||this.__patterns.django.read())));return t},t.exports.TemplatablePattern=o}]),void 0===(r=function(){return{js_beautify:i}}.apply(e,[]))||(t.exports=r)},function(t,e,n){var r,i;i=function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=15)}([,,function(t,e,n){"use strict";function r(t){this.__parent=t,this.__character_count=0,this.__indent_count=-1,this.__alignment_count=0,this.__wrap_point_index=0,this.__wrap_point_character_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}function i(t,e){this.__cache=[""],this.__indent_size=t.indent_size,this.__indent_string=t.indent_char,t.indent_with_tabs||(this.__indent_string=new Array(t.indent_size+1).join(t.indent_char)),e=e||"",t.indent_level>0&&(e=new Array(t.indent_level+1).join(this.__indent_string)),this.__base_string=e,this.__base_string_length=e.length}function o(t,e){this.__indent_cache=new i(t,e),this.raw=!1,this._end_with_newline=t.end_with_newline,this.indent_size=t.indent_size,this.wrap_line_length=t.wrap_line_length,this.indent_empty_lines=t.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new r(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}r.prototype.clone_empty=function(){var t=new r(this.__parent);return t.set_indent(this.__indent_count,this.__alignment_count),t},r.prototype.item=function(t){return t<0?this.__items[this.__items.length+t]:this.__items[t]},r.prototype.has_match=function(t){for(var e=this.__items.length-1;e>=0;e--)if(this.__items[e].match(t))return!0;return!1},r.prototype.set_indent=function(t,e){this.is_empty()&&(this.__indent_count=t||0,this.__alignment_count=e||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},r.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},r.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},r.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var t=this.__parent.current_line;return t.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),t.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),t.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count," "===t.__items[0]&&(t.__items.splice(0,1),t.__character_count-=1),!0}return!1},r.prototype.is_empty=function(){return 0===this.__items.length},r.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},r.prototype.push=function(t){this.__items.push(t);var e=t.lastIndexOf("\n");-1!==e?this.__character_count=t.length-e:this.__character_count+=t.length},r.prototype.pop=function(){var t=null;return this.is_empty()||(t=this.__items.pop(),this.__character_count-=t.length),t},r.prototype._remove_indent=function(){this.__indent_count>0&&(this.__indent_count-=1,this.__character_count-=this.__parent.indent_size)},r.prototype._remove_wrap_indent=function(){this.__wrap_point_indent_count>0&&(this.__wrap_point_indent_count-=1)},r.prototype.trim=function(){for(;" "===this.last();)this.__items.pop(),this.__character_count-=1},r.prototype.toString=function(){var t="";return this.is_empty()?this.__parent.indent_empty_lines&&(t=this.__parent.get_indent_string(this.__indent_count)):(t=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),t+=this.__items.join("")),t},i.prototype.get_indent_size=function(t,e){var n=this.__base_string_length;return e=e||0,t<0&&(n=0),n+=t*this.__indent_size,n+=e},i.prototype.get_indent_string=function(t,e){var n=this.__base_string;return e=e||0,t<0&&(t=0,n=""),e+=t*this.__indent_size,this.__ensure_cache(e),n+=this.__cache[e]},i.prototype.__ensure_cache=function(t){for(;t>=this.__cache.length;)this.__add_column()},i.prototype.__add_column=function(){var t=this.__cache.length,e=0,n="";this.__indent_size&&t>=this.__indent_size&&(t-=(e=Math.floor(t/this.__indent_size))*this.__indent_size,n=new Array(e+1).join(this.__indent_string)),t&&(n+=new Array(t+1).join(" ")),this.__cache.push(n)},o.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},o.prototype.get_line_number=function(){return this.__lines.length},o.prototype.get_indent_string=function(t,e){return this.__indent_cache.get_indent_string(t,e)},o.prototype.get_indent_size=function(t,e){return this.__indent_cache.get_indent_size(t,e)},o.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},o.prototype.add_new_line=function(t){return!(this.is_empty()||!t&&this.just_added_newline()||(this.raw||this.__add_outputline(),0))},o.prototype.get_code=function(t){this.trim(!0);var e=this.current_line.pop();e&&("\n"===e[e.length-1]&&(e=e.replace(/\n+$/g,"")),this.current_line.push(e)),this._end_with_newline&&this.__add_outputline();var n=this.__lines.join("\n");return"\n"!==t&&(n=n.replace(/[\n]/g,t)),n},o.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},o.prototype.set_indent=function(t,e){return t=t||0,e=e||0,this.next_line.set_indent(t,e),this.__lines.length>1?(this.current_line.set_indent(t,e),!0):(this.current_line.set_indent(),!1)},o.prototype.add_raw_token=function(t){for(var e=0;e1&&this.current_line.is_empty();)this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null},o.prototype.just_added_newline=function(){return this.current_line.is_empty()},o.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()},o.prototype.ensure_empty_line_above=function(t,e){for(var n=this.__lines.length-2;n>=0;){var i=this.__lines[n];if(i.is_empty())break;if(0!==i.item(0).indexOf(t)&&i.item(-1)!==e){this.__lines.splice(n+1,0,new r(this)),this.previous_line=this.__lines[this.__lines.length-2];break}n--}},t.exports.Output=o},,,,function(t,e,n){"use strict";function r(t,e){this.raw_options=i(t,e),this.disabled=this._get_boolean("disabled"),this.eol=this._get_characters("eol","auto"),this.end_with_newline=this._get_boolean("end_with_newline"),this.indent_size=this._get_number("indent_size",4),this.indent_char=this._get_characters("indent_char"," "),this.indent_level=this._get_number("indent_level"),this.preserve_newlines=this._get_boolean("preserve_newlines",!0),this.max_preserve_newlines=this._get_number("max_preserve_newlines",32786),this.preserve_newlines||(this.max_preserve_newlines=0),this.indent_with_tabs=this._get_boolean("indent_with_tabs","\t"===this.indent_char),this.indent_with_tabs&&(this.indent_char="\t",1===this.indent_size&&(this.indent_size=4)),this.wrap_line_length=this._get_number("wrap_line_length",this._get_number("max_char")),this.indent_empty_lines=this._get_boolean("indent_empty_lines"),this.templating=this._get_selection_list("templating",["auto","none","django","erb","handlebars","php"],["auto"])}function i(t,e){var n,r={};for(n in t=o(t))n!==e&&(r[n]=t[n]);if(e&&t[e])for(n in t[e])r[n]=t[e][n];return r}function o(t){var e,n={};for(e in t)n[e.replace(/-/g,"_")]=t[e];return n}r.prototype._get_array=function(t,e){var n=this.raw_options[t],r=e||[];return"object"==typeof n?null!==n&&"function"==typeof n.concat&&(r=n.concat()):"string"==typeof n&&(r=n.split(/[^a-zA-Z0-9_\/\-]+/)),r},r.prototype._get_boolean=function(t,e){var n=this.raw_options[t];return void 0===n?!!e:!!n},r.prototype._get_characters=function(t,e){var n=this.raw_options[t],r=e||"";return"string"==typeof n&&(r=n.replace(/\\r/,"\r").replace(/\\n/,"\n").replace(/\\t/,"\t")),r},r.prototype._get_number=function(t,e){var n=this.raw_options[t];e=parseInt(e,10),isNaN(e)&&(e=0);var r=parseInt(n,10);return isNaN(r)&&(r=e),r},r.prototype._get_selection=function(t,e,n){var r=this._get_selection_list(t,e,n);if(1!==r.length)throw new Error("Invalid Option Value: The option '"+t+"' can only be one of the following values:\n"+e+"\nYou passed in: '"+this.raw_options[t]+"'");return r[0]},r.prototype._get_selection_list=function(t,e,n){if(!e||0===e.length)throw new Error("Selection list cannot be empty.");if(n=n||[e[0]],!this._is_valid_selection(n,e))throw new Error("Invalid Default Value!");var r=this._get_array(t,n);if(!this._is_valid_selection(r,e))throw new Error("Invalid Option Value: The option '"+t+"' can contain only the following values:\n"+e+"\nYou passed in: '"+this.raw_options[t]+"'");return r},r.prototype._is_valid_selection=function(t,e){return t.length&&e.length&&!t.some((function(t){return-1===e.indexOf(t)}))},t.exports.Options=r,t.exports.normalizeOpts=o,t.exports.mergeOpts=i},,function(t,e,n){"use strict";var r=RegExp.prototype.hasOwnProperty("sticky");function i(t){this.__input=t||"",this.__input_length=this.__input.length,this.__position=0}i.prototype.restart=function(){this.__position=0},i.prototype.back=function(){this.__position>0&&(this.__position-=1)},i.prototype.hasNext=function(){return this.__position=0&&t=0&&e=t.length&&this.__input.substring(e-t.length,e).toLowerCase()===t},t.exports.InputScanner=i},,,,,function(t,e,n){"use strict";function r(t,e){t="string"==typeof t?t:t.source,e="string"==typeof e?e:e.source,this.__directives_block_pattern=new RegExp(t+/ beautify( \w+[:]\w+)+ /.source+e,"g"),this.__directive_pattern=/ (\w+)[:](\w+)/g,this.__directives_end_ignore_pattern=new RegExp(t+/\sbeautify\signore:end\s/.source+e,"g")}r.prototype.get_directives=function(t){if(!t.match(this.__directives_block_pattern))return null;var e={};this.__directive_pattern.lastIndex=0;for(var n=this.__directive_pattern.exec(t);n;)e[n[1]]=n[2],n=this.__directive_pattern.exec(t);return e},r.prototype.readIgnored=function(t){return t.readUntilAfter(this.__directives_end_ignore_pattern)},t.exports.Directives=r},,function(t,e,n){"use strict";var r=n(16).Beautifier,i=n(17).Options;t.exports=function(t,e){return new r(t,e).beautify()},t.exports.defaultOptions=function(){return new i}},function(t,e,n){"use strict";var r=n(17).Options,i=n(2).Output,o=n(8).InputScanner,s=new(0,n(13).Directives)(/\/\*/,/\*\//),a=/\r\n|[\r\n]/,u=/\r\n|[\r\n]/g,c=/\s/,l=/(?:\s|\n)+/g,f=/\/\*(?:[\s\S]*?)((?:\*\/)|$)/g,p=/\/\/(?:[^\n\r\u2028\u2029]*)/g;function h(t,e){this._source_text=t||"",this._options=new r(e),this._ch=null,this._input=null,this.NESTED_AT_RULE={"@page":!0,"@font-face":!0,"@keyframes":!0,"@media":!0,"@supports":!0,"@document":!0},this.CONDITIONAL_GROUP_RULE={"@media":!0,"@supports":!0,"@document":!0}}h.prototype.eatString=function(t){var e="";for(this._ch=this._input.next();this._ch;){if(e+=this._ch,"\\"===this._ch)e+=this._input.next();else if(-1!==t.indexOf(this._ch)||"\n"===this._ch)break;this._ch=this._input.next()}return e},h.prototype.eatWhitespace=function(t){for(var e=c.test(this._input.peek()),n=!0;c.test(this._input.peek());)this._ch=this._input.next(),t&&"\n"===this._ch&&(this._options.preserve_newlines||n)&&(n=!1,this._output.add_new_line(!0));return e},h.prototype.foundNestedPseudoClass=function(){for(var t=0,e=1,n=this._input.peek(e);n;){if("{"===n)return!0;if("("===n)t+=1;else if(")"===n){if(0===t)return!1;t-=1}else if(";"===n||"}"===n)return!1;e++,n=this._input.peek(e)}return!1},h.prototype.print_string=function(t){this._output.set_indent(this._indentLevel),this._output.non_breaking_space=!0,this._output.add_token(t)},h.prototype.preserveSingleSpace=function(t){t&&(this._output.space_before_token=!0)},h.prototype.indent=function(){this._indentLevel++},h.prototype.outdent=function(){this._indentLevel>0&&this._indentLevel--},h.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var t=this._source_text,e=this._options.eol;"auto"===e&&(e="\n",t&&a.test(t||"")&&(e=t.match(a)[0]));var n=(t=t.replace(u,"\n")).match(/^[\t ]*/)[0];this._output=new i(this._options,n),this._input=new o(t),this._indentLevel=0,this._nestedLevel=0,this._ch=null;for(var r,h,d=0,_=!1,v=!1,m=!1,g=!1,y=!1,b=this._ch;r=""!==this._input.read(l),h=b,this._ch=this._input.next(),"\\"===this._ch&&this._input.hasNext()&&(this._ch+=this._input.next()),b=this._ch,this._ch;)if("/"===this._ch&&"*"===this._input.peek()){this._output.add_new_line(),this._input.back();var w=this._input.read(f),x=s.get_directives(w);x&&"start"===x.ignore&&(w+=s.readIgnored(this._input)),this.print_string(w),this.eatWhitespace(!0),this._output.add_new_line()}else if("/"===this._ch&&"/"===this._input.peek())this._output.space_before_token=!0,this._input.back(),this.print_string(this._input.read(p)),this.eatWhitespace(!0);else if("@"===this._ch)if(this.preserveSingleSpace(r),"{"===this._input.peek())this.print_string(this._ch+this.eatString("}"));else{this.print_string(this._ch);var k=this._input.peekUntilAfter(/[: ,;{}()[\]\/='"]/g);k.match(/[ :]$/)&&(k=this.eatString(": ").replace(/\s$/,""),this.print_string(k),this._output.space_before_token=!0),"extend"===(k=k.replace(/\s$/,""))?g=!0:"import"===k&&(y=!0),k in this.NESTED_AT_RULE?(this._nestedLevel+=1,k in this.CONDITIONAL_GROUP_RULE&&(m=!0)):_||0!==d||-1===k.indexOf(":")||(v=!0,this.indent())}else"#"===this._ch&&"{"===this._input.peek()?(this.preserveSingleSpace(r),this.print_string(this._ch+this.eatString("}"))):"{"===this._ch?(v&&(v=!1,this.outdent()),m?(m=!1,_=this._indentLevel>=this._nestedLevel):_=this._indentLevel>=this._nestedLevel-1,this._options.newline_between_rules&&_&&this._output.previous_line&&"{"!==this._output.previous_line.item(-1)&&this._output.ensure_empty_line_above("/",","),this._output.space_before_token=!0,"expand"===this._options.brace_style?(this._output.add_new_line(),this.print_string(this._ch),this.indent(),this._output.set_indent(this._indentLevel)):(this.indent(),this.print_string(this._ch)),this.eatWhitespace(!0),this._output.add_new_line()):"}"===this._ch?(this.outdent(),this._output.add_new_line(),"{"===h&&this._output.trim(!0),y=!1,g=!1,v&&(this.outdent(),v=!1),this.print_string(this._ch),_=!1,this._nestedLevel&&this._nestedLevel--,this.eatWhitespace(!0),this._output.add_new_line(),this._options.newline_between_rules&&!this._output.just_added_blankline()&&"}"!==this._input.peek()&&this._output.add_new_line(!0)):":"===this._ch?!_&&!m||this._input.lookBack("&")||this.foundNestedPseudoClass()||this._input.lookBack("(")||g||0!==d?(this._input.lookBack(" ")&&(this._output.space_before_token=!0),":"===this._input.peek()?(this._ch=this._input.next(),this.print_string("::")):this.print_string(":")):(this.print_string(":"),v||(v=!0,this._output.space_before_token=!0,this.eatWhitespace(!0),this.indent())):'"'===this._ch||"'"===this._ch?(this.preserveSingleSpace(r),this.print_string(this._ch+this.eatString(this._ch)),this.eatWhitespace(!0)):";"===this._ch?0===d?(v&&(this.outdent(),v=!1),g=!1,y=!1,this.print_string(this._ch),this.eatWhitespace(!0),"/"!==this._input.peek()&&this._output.add_new_line()):(this.print_string(this._ch),this.eatWhitespace(!0),this._output.space_before_token=!0):"("===this._ch?this._input.lookBack("url")?(this.print_string(this._ch),this.eatWhitespace(),d++,this.indent(),this._ch=this._input.next(),")"===this._ch||'"'===this._ch||"'"===this._ch?this._input.back():this._ch&&(this.print_string(this._ch+this.eatString(")")),d&&(d--,this.outdent()))):(this.preserveSingleSpace(r),this.print_string(this._ch),this.eatWhitespace(),d++,this.indent()):")"===this._ch?(d&&(d--,this.outdent()),this.print_string(this._ch)):","===this._ch?(this.print_string(this._ch),this.eatWhitespace(!0),!this._options.selector_separator_newline||v||0!==d||y?this._output.space_before_token=!0:this._output.add_new_line()):">"!==this._ch&&"+"!==this._ch&&"~"!==this._ch||v||0!==d?"]"===this._ch?this.print_string(this._ch):"["===this._ch?(this.preserveSingleSpace(r),this.print_string(this._ch)):"="===this._ch?(this.eatWhitespace(),this.print_string("="),c.test(this._ch)&&(this._ch="")):"!"!==this._ch||this._input.lookBack("\\")?(this.preserveSingleSpace(r),this.print_string(this._ch)):(this.print_string(" "),this.print_string(this._ch)):this._options.space_around_combinator?(this._output.space_before_token=!0,this.print_string(this._ch),this._output.space_before_token=!0):(this.print_string(this._ch),this.eatWhitespace(),this._ch&&c.test(this._ch)&&(this._ch=""));return this._output.get_code(e)},t.exports.Beautifier=h},function(t,e,n){"use strict";var r=n(6).Options;function i(t){r.call(this,t,"css"),this.selector_separator_newline=this._get_boolean("selector_separator_newline",!0),this.newline_between_rules=this._get_boolean("newline_between_rules",!0);var e=this._get_boolean("space_around_selector_separator");this.space_around_combinator=this._get_boolean("space_around_combinator")||e;var n=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_style="collapse";for(var i=0;i=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};r.forEach(["delete","get","head"],(function(t){u.headers[t]={}})),r.forEach(["post","put","patch"],(function(t){u.headers[t]=r.merge(o)})),t.exports=u}).call(e,n(77))},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(116),o=(r=i)&&r.__esModule?r:{default:r};e.default=function(t,e,n){return e in t?(0,o.default)(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}},function(t,e){t.exports=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){var r=n(9),i=n(1).document,o=r(i)&&r(i.createElement);t.exports=function(t){return o?i.createElement(t):{}}},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e){t.exports=!0},function(t,e,n){"use strict";var r=n(14);function i(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw TypeError("Bad Promise constructor");e=t,n=r})),this.resolve=r(e),this.reject=r(n)}t.exports.f=function(t){return new i(t)}},function(t,e,n){var r=n(11).f,i=n(17),o=n(2)("toStringTag");t.exports=function(t,e,n){t&&!i(t=n?t:t.prototype,o)&&r(t,o,{configurable:!0,value:e})}},function(t,e,n){var r=n(62)("keys"),i=n(67);t.exports=function(t){return r[t]||(r[t]=i(t))}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(56),i=n(27);t.exports=function(t){return r(i(t))}},function(t,e,n){var r=n(12).Symbol;t.exports=r},function(t,e,n){var r=n(173),i=n(192);t.exports=function(t,e){var n=i(t,e);return r(n)?n:void 0}},function(t,e){t.exports=function(t,e){return t===e||t!=t&&e!=e}},function(t,e){t.exports=function(t){return t}},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.mapProps=void 0;var r,i=n(237),o=(r=i)&&r.__esModule?r:{default:r},s={showHelpText:{type:Boolean,default:!1},shownViaNewRelationModal:{type:Boolean,default:!1},resourceId:{type:[Number,String]},resourceName:{type:String},field:{type:Object,required:!0},viaResource:{type:String,required:!1},viaResourceId:{type:[String,Number],required:!1},viaRelationship:{type:String,required:!1}};e.mapProps=function(t){return o.default.pick(s,t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=["1/2","1/3","2/3","1/4","3/4","1/5","2/5","3/5","4/5","1/6","5/6"]},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(157);Object.defineProperty(e,"default",{enumerable:!0,get:function(){return o(r).default}}),Object.defineProperty(e,"Form",{enumerable:!0,get:function(){return o(r).default}});var i=n(68);function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"Errors",{enumerable:!0,get:function(){return o(i).default}})},function(t,e,n){"use strict";(function(e){var r=n(0),i=n(104),o=n(107),s=n(113),a=n(111),u=n(47),c="undefined"!=typeof window&&window.btoa&&window.btoa.bind(window)||n(106);t.exports=function(t){return new Promise((function(l,f){var p=t.data,h=t.headers;r.isFormData(p)&&delete h["Content-Type"];var d=new XMLHttpRequest,_="onreadystatechange",v=!1;if("test"===e.env.NODE_ENV||"undefined"==typeof window||!window.XDomainRequest||"withCredentials"in d||a(t.url)||(d=new window.XDomainRequest,_="onload",v=!0,d.onprogress=function(){},d.ontimeout=function(){}),t.auth){var m=t.auth.username||"",g=t.auth.password||"";h.Authorization="Basic "+c(m+":"+g)}if(d.open(t.method.toUpperCase(),o(t.url,t.params,t.paramsSerializer),!0),d.timeout=t.timeout,d[_]=function(){if(d&&(4===d.readyState||v)&&(0!==d.status||d.responseURL&&0===d.responseURL.indexOf("file:"))){var e="getAllResponseHeaders"in d?s(d.getAllResponseHeaders()):null,n={data:t.responseType&&"text"!==t.responseType?d.response:d.responseText,status:1223===d.status?204:d.status,statusText:1223===d.status?"No Content":d.statusText,headers:e,config:t,request:d};i(l,f,n),d=null}},d.onerror=function(){f(u("Network Error",t,null,d)),d=null},d.ontimeout=function(){f(u("timeout of "+t.timeout+"ms exceeded",t,"ECONNABORTED",d)),d=null},r.isStandardBrowserEnv()){var y=n(109),b=(t.withCredentials||a(t.url))&&t.xsrfCookieName?y.read(t.xsrfCookieName):void 0;b&&(h[t.xsrfHeaderName]=b)}if("setRequestHeader"in d&&r.forEach(h,(function(t,e){void 0===p&&"content-type"===e.toLowerCase()?delete h[e]:d.setRequestHeader(e,t)})),t.withCredentials&&(d.withCredentials=!0),t.responseType)try{d.responseType=t.responseType}catch(e){if("json"!==t.responseType)throw e}"function"==typeof t.onDownloadProgress&&d.addEventListener("progress",t.onDownloadProgress),"function"==typeof t.onUploadProgress&&d.upload&&d.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){d&&(d.abort(),f(t),d=null)})),void 0===p&&(p=null),d.send(p)}))}}).call(e,n(77))},function(t,e,n){"use strict";function r(t){this.message=t}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,t.exports=r},function(t,e,n){"use strict";t.exports=function(t){return!(!t||!t.__CANCEL__)}},function(t,e,n){"use strict";var r=n(103);t.exports=function(t,e,n,i,o){var s=new Error(t);return r(s,e,n,i,o)}},function(t,e,n){"use strict";t.exports=function(t,e){return function(){for(var n=new Array(arguments.length),r=0;rn;)e.push(arguments[n++]);return m[++v]=function(){a("function"==typeof t?t:Function(t),e)},r(v),v},h=function(t){delete m[t]},"process"==n(15)(f)?r=function(t){f.nextTick(s(g,t,1))}:_&&_.now?r=function(t){_.now(s(g,t,1))}:d?(o=(i=new d).port2,i.port1.onmessage=y,r=s(o.postMessage,o,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(t){l.postMessage(t+"","*")},l.addEventListener("message",y,!1)):r="onreadystatechange"in c("script")?function(t){u.appendChild(c("script")).onreadystatechange=function(){u.removeChild(this),g.call(t)}}:function(t){setTimeout(s(g,t,1),0)}),t.exports={set:p,clear:h}},function(t,e,n){var r=n(34),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},function(t,e,n){var r=n(27);t.exports=function(t){return Object(r(t))}},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};i(this,t),this.record(e)}return r(t,[{key:"all",value:function(){return this.errors}},{key:"has",value:function(t){var e=this.errors.hasOwnProperty(t);return e||(e=Object.keys(this.errors).filter((function(e){return e.startsWith(t+".")||e.startsWith(t+"[")})).length>0),e}},{key:"first",value:function(t){return this.get(t)[0]}},{key:"get",value:function(t){return this.errors[t]||[]}},{key:"any",value:function(){return Object.keys(this.errors).length>0}},{key:"record",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.errors=t}},{key:"clear",value:function(t){if(t){var e=Object.assign({},this.errors);Object.keys(e).filter((function(e){return e===t||e.startsWith(t+".")||e.startsWith(t+"[")})).forEach((function(t){return delete e[t]})),this.errors=e}else this.errors={}}}]),t}();e.default=o},function(t,e,n){var r=n(180),i=n(232),o=n(13),s=n(233),a=n(72),u=n(234),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var n=o(t),l=!n&&i(t),f=!n&&!l&&s(t),p=!n&&!l&&!f&&u(t),h=n||l||f||p,d=h?r(t.length,String):[],_=d.length;for(var v in t)!e&&!c.call(t,v)||h&&("length"==v||f&&("offset"==v||"parent"==v)||p&&("buffer"==v||"byteLength"==v||"byteOffset"==v)||a(v,_))||d.push(v);return d}},function(t,e,n){(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.exports=n}).call(e,n(78))},function(t,e){var n=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");t.exports=function(t){return n.test(t)}},function(t,e){var n=/^(?:0|[1-9]\d*)$/;t.exports=function(t,e){var r=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==r||"symbol"!=r&&n.test(t))&&t>-1&&t%1==0&&t-1&&t%1==0&&t<=9007199254740991}},function(t,e,n){var r=n(181);t.exports=function(t){return null==t?"":r(t)}},function(t,e){var n,r,i=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(t){n=o}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(t){r=s}}();var u,c=[],l=!1,f=-1;function p(){l&&u&&(l=!1,u.length?c=u.concat(c):f=-1,c.length&&h())}function h(){if(!l){var t=a(p);l=!0;for(var e=c.length;e;){for(u=c,c=[];++f1)for(var n=1;n1&&void 0!==arguments[1]?arguments[1]:null;return this.viaManyToMany?this.detachResources(t):Nova.request({url:"/nova-api/"+this.resourceName,method:"delete",params:(0,o.default)({},this.queryString,{resources:s(t)})}).then(n||function(){e.deleteModalOpen=!1,e.getResources()})},deleteSelectedResources:function(){this.deleteResources(this.selectedResources)},deleteAllMatchingResources:function(){var t=this;return this.viaManyToMany?this.detachAllMatchingResources():Nova.request({url:this.deleteAllMatchingResourcesEndpoint,method:"delete",params:(0,o.default)({},this.queryString,{resources:"all"})}).then((function(){t.deleteModalOpen=!1,t.getResources()}))},detachResources:function(t){var e=this;return Nova.request({url:"/nova-api/"+this.resourceName+"/detach",method:"delete",params:(0,o.default)({},this.queryString,{resources:s(t)})}).then((function(){e.deleteModalOpen=!1,e.getResources()}))},detachAllMatchingResources:function(){var t=this;return Nova.request({url:"/nova-api/"+this.resourceName+"/detach",method:"delete",params:(0,o.default)({},this.queryString,{resources:"all"})}).then((function(){t.deleteModalOpen=!1,t.getResources()}))},forceDeleteResources:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return Nova.request({url:"/nova-api/"+this.resourceName+"/force",method:"delete",params:(0,o.default)({},this.queryString,{resources:s(t)})}).then(n||function(){e.deleteModalOpen=!1,e.getResources()})},forceDeleteSelectedResources:function(){this.forceDeleteResources(this.selectedResources)},forceDeleteAllMatchingResources:function(){var t=this;return Nova.request({url:this.forceDeleteSelectedResourcesEndpoint,method:"delete",params:(0,o.default)({},this.queryString,{resources:"all"})}).then((function(){t.deleteModalOpen=!1,t.getResources()}))},restoreResources:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return Nova.request({url:"/nova-api/"+this.resourceName+"/restore",method:"put",params:(0,o.default)({},this.queryString,{resources:s(t)})}).then(n||function(){e.restoreModalOpen=!1,e.getResources()})},restoreSelectedResources:function(){this.restoreResources(this.selectedResources)},restoreAllMatchingResources:function(){var t=this;return Nova.request({url:this.restoreAllMatchingResourcesEndpoint,method:"put",params:(0,o.default)({},this.queryString,{resources:"all"})}).then((function(){t.restoreModalOpen=!1,t.getResources()}))}},computed:{deleteAllMatchingResourcesEndpoint:function(){return this.lens?"/nova-api/"+this.resourceName+"/lens/"+this.lens:"/nova-api/"+this.resourceName},forceDeleteSelectedResourcesEndpoint:function(){return this.lens?"/nova-api/"+this.resourceName+"/lens/"+this.lens+"/force":"/nova-api/"+this.resourceName+"/force"},restoreAllMatchingResourcesEndpoint:function(){return this.lens?"/nova-api/"+this.resourceName+"/lens/"+this.lens+"/restore":"/nova-api/"+this.resourceName+"/restore"},queryString:function(){return{search:this.currentSearch,filters:this.encodedFilters,trashed:this.currentTrashed,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i,o,s=c(n(52)),a=c(n(26)),u=c(n(51));function c(t){return t&&t.__esModule?t:{default:t}}c(n(229)),c(n(231)),e.default={methods:{clearSelectedFilters:(o=(0,u.default)(s.default.mark((function t(e){var n;return s.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!e){t.next=5;break}return t.next=3,this.$store.dispatch(this.resourceName+"/resetFilterState",{resourceName:this.resourceName,lens:e});case 3:t.next=7;break;case 5:return t.next=7,this.$store.dispatch(this.resourceName+"/resetFilterState",{resourceName:this.resourceName});case 7:this.updateQueryString((n={},(0,a.default)(n,this.pageParameter,1),(0,a.default)(n,this.filterParameter,""),n));case 8:case"end":return t.stop()}}),t,this)}))),function(t){return o.apply(this,arguments)}),filterChanged:function(){var t;this.updateQueryString((t={},(0,a.default)(t,this.pageParameter,1),(0,a.default)(t,this.filterParameter,this.$store.getters[this.resourceName+"/currentEncodedFilters"]),t))},initializeFilters:(i=(0,u.default)(s.default.mark((function t(e){return s.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return this.$store.commit(this.resourceName+"/clearFilters"),t.next=3,this.$store.dispatch(this.resourceName+"/fetchFilters",{resourceName:this.resourceName,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,lens:e});case 3:return t.next=5,this.initializeState(e);case 5:case"end":return t.stop()}}),t,this)}))),function(t){return i.apply(this,arguments)}),initializeState:(r=(0,u.default)(s.default.mark((function t(e){return s.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!this.initialEncodedFilters){t.next=5;break}return t.next=3,this.$store.dispatch(this.resourceName+"/initializeCurrentFilterValuesFromQueryString",this.initialEncodedFilters);case 3:t.next=7;break;case 5:return t.next=7,this.$store.dispatch(this.resourceName+"/resetFilterState",{resourceName:this.resourceName,lens:e});case 7:case"end":return t.stop()}}),t,this)}))),function(t){return r.apply(this,arguments)})},computed:{filterParameter:function(){return this.resourceName+"_filter"}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(41);e.default={props:(0,r.mapProps)(["shownViaNewRelationModal","field","viaResource","viaResourceId","viaRelationship","resourceName","showHelpText"]),data:function(){return{value:""}},mounted:function(){var t=this;this.setInitialValue(),this.field.fill=this.fill,Nova.$on(this.field.attribute+"-value",(function(e){t.value=e}))},destroyed:function(){Nova.$off(this.field.attribute+"-value")},methods:{setInitialValue:function(){this.value=void 0!==this.field.value&&null!==this.field.value?this.field.value:""},fill:function(t){t.append(this.field.attribute,String(this.value))},handleChange:function(t){this.value=t.target.value,Nova.$emit(this.field.attribute+"-change",this.value)}},computed:{isReadonly:function(){return this.field.readonly||_.get(this.field,"extraAttributes.readonly")}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(43);e.default={props:{errors:{default:function(){return new r.Errors}}},data:function(){return{errorClass:"border-danger"}},computed:{errorClasses:function(){return this.hasError?[this.errorClass]:[]},fieldAttribute:function(){return this.field.attribute},validationKey:function(){return this.field.validationKey},hasError:function(){return this.errors.has(this.validationKey)},firstError:function(){if(this.hasError)return this.errors.first(this.validationKey)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=a(n(52)),o=a(n(51)),s=a(n(42));function a(t){return t&&t.__esModule?t:{default:t}}e.default={props:{loadCards:{type:Boolean,default:!0}},data:function(){return{cards:[]}},created:function(){this.fetchCards()},watch:{cardsEndpoint:function(){this.fetchCards()}},methods:{fetchCards:(r=(0,o.default)(i.default.mark((function t(){var e,n;return i.default.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!this.loadCards){t.next=6;break}return t.next=3,Nova.request().get(this.cardsEndpoint,{params:this.extraCardParams});case 3:e=t.sent,n=e.data,this.cards=n;case 6:case"end":return t.stop()}}),t,this)}))),function(){return r.apply(this,arguments)})},computed:{shouldShowCards:function(){return this.cards.length>0},smallCards:function(){return _.filter(this.cards,(function(t){return-1!==s.default.indexOf(t.width)}))},largeCards:function(){return _.filter(this.cards,(function(t){return"full"==t.width}))},extraCardParams:function(){return null}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={methods:{toAppTimezone:function(t){return t?moment.tz(t,this.userTimezone).clone().tz(Nova.config.timezone).format("YYYY-MM-DD HH:mm:ss"):t},fromAppTimezone:function(t){return t?moment.tz(t,Nova.config.timezone).clone().tz(this.userTimezone).format("YYYY-MM-DD HH:mm:ss"):t},localizeDateTimeField:function(t){if(!t.value)return t.value;var e=moment.tz(t.value,Nova.config.timezone).clone().tz(this.userTimezone);return t.format?e.format(t.format):this.usesTwelveHourTime?e.format("YYYY-MM-DD h:mm:ss A"):e.format("YYYY-MM-DD HH:mm:ss")},localizeDateField:function(t){if(!t.value)return t.value;var e=moment.tz(t.value,Nova.config.timezone).clone().tz(this.userTimezone);return t.format?e.format(t.format):e.format("YYYY-MM-DD")}},computed:{userTimezone:function(){return Nova.config.userTimezone?Nova.config.userTimezone:moment.tz.guess()},usesTwelveHourTime:function(){return _.endsWith((new Date).toLocaleString(),"AM")||_.endsWith((new Date).toLocaleString(),"PM")}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(228),o=(r=i)&&r.__esModule?r:{default:r};e.default={methods:{updateQueryString:function(t){this.$router.push({query:(0,o.default)(t,this.$route.query)})}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={computed:{resourceInformation:function(){var t=this;return _.find(Nova.config.resources,(function(e){return e.uriKey==t.resourceName}))},viaResourceInformation:function(){var t=this;if(this.viaResource)return _.find(Nova.config.resources,(function(e){return e.uriKey==t.viaResource}))},authorizedToCreate:function(){return this.resourceInformation.authorizedToCreate}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(26),o=(r=i)&&r.__esModule?r:{default:r};e.default={methods:{selectPreviousPage:function(){this.updateQueryString((0,o.default)({},this.pageParameter,this.currentPage-1))},selectNextPage:function(){this.updateQueryString((0,o.default)({},this.pageParameter,this.currentPage+1))}},computed:{currentPage:function(){return parseInt(this.$route.query[this.pageParameter]||1)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(26),o=(r=i)&&r.__esModule?r:{default:r};e.default={data:function(){return{perPage:25}},methods:{initializePerPageFromQueryString:function(){this.perPage=this.currentPerPage},perPageChanged:function(){this.updateQueryString((0,o.default)({},this.perPageParameter,this.perPage))}},computed:{currentPerPage:function(){return this.$route.query[this.perPageParameter]||25}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(227),o=(r=i)&&r.__esModule?r:{default:r};e.default={data:function(){return{search:"",selectedResource:"",availableResources:[]}},methods:{selectResource:function(t){this.selectedResource=t},handleSearchCleared:function(){this.availableResources=[]},clearSelection:function(){this.selectedResource="",this.availableResources=[]},performSearch:function(t){var e=this;this.search=t;var n=t.trim();""!=n&&this.debouncer((function(){e.getAvailableResources(n)}),500)},debouncer:(0,o.default)((function(t){return t()}),500)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={beforeRouteLeave:function(t,e,n){this.canLeave||window.confirm(this.__("Do you really want to leave? You have unsaved changes."))?n():n(!1)},data:function(){return{canLeave:!0}},methods:{updateFormStatus:function(){this.canLeave=!1}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={data:function(){return{withTrashed:!1}},methods:{toggleWithTrashed:function(){this.withTrashed=!this.withTrashed},enableWithTrashed:function(){this.withTrashed=!0},disableWithTrashed:function(){this.withTrashed=!1}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){return(0,o.default)(t)};var r,i=n(242),o=(r=i)&&r.__esModule?r:{default:r}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(50),o=(r=i)&&r.__esModule?r:{default:r};e.default=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100;return o.default.all([t,new o.default((function(t){setTimeout((function(){return t()}),e)}))]).then((function(t){return t[0]}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e){return t>1||0==t?r.Inflector.pluralize(e):r.Inflector.singularize(e)};var r=n(49)},function(t,e,n){"use strict";var r={uncountableWords:["equipment","information","rice","money","species","series","fish","sheep","moose","deer","news"],pluralRules:[[new RegExp("(m)an$","gi"),"$1en"],[new RegExp("(pe)rson$","gi"),"$1ople"],[new RegExp("(child)$","gi"),"$1ren"],[new RegExp("^(ox)$","gi"),"$1en"],[new RegExp("(ax|test)is$","gi"),"$1es"],[new RegExp("(octop|vir)us$","gi"),"$1i"],[new RegExp("(alias|status)$","gi"),"$1es"],[new RegExp("(bu)s$","gi"),"$1ses"],[new RegExp("(buffal|tomat|potat)o$","gi"),"$1oes"],[new RegExp("([ti])um$","gi"),"$1a"],[new RegExp("sis$","gi"),"ses"],[new RegExp("(?:([^f])fe|([lr])f)$","gi"),"$1$2ves"],[new RegExp("(hive)$","gi"),"$1s"],[new RegExp("([^aeiouy]|qu)y$","gi"),"$1ies"],[new RegExp("(x|ch|ss|sh)$","gi"),"$1es"],[new RegExp("(matr|vert|ind)ix|ex$","gi"),"$1ices"],[new RegExp("([m|l])ouse$","gi"),"$1ice"],[new RegExp("(quiz)$","gi"),"$1zes"],[new RegExp("s$","gi"),"s"],[new RegExp("$","gi"),"s"]],singularRules:[[new RegExp("(m)en$","gi"),"$1an"],[new RegExp("(pe)ople$","gi"),"$1rson"],[new RegExp("(child)ren$","gi"),"$1"],[new RegExp("([ti])a$","gi"),"$1um"],[new RegExp("((a)naly|(b)a|(d)iagno|(p)arenthe|(p)rogno|(s)ynop|(t)he)ses$","gi"),"$1$2sis"],[new RegExp("(hive)s$","gi"),"$1"],[new RegExp("(tive)s$","gi"),"$1"],[new RegExp("(curve)s$","gi"),"$1"],[new RegExp("([lr])ves$","gi"),"$1f"],[new RegExp("([^fo])ves$","gi"),"$1fe"],[new RegExp("([^aeiouy]|qu)ies$","gi"),"$1y"],[new RegExp("(s)eries$","gi"),"$1eries"],[new RegExp("(m)ovies$","gi"),"$1ovie"],[new RegExp("(x|ch|ss|sh)es$","gi"),"$1"],[new RegExp("([m|l])ice$","gi"),"$1ouse"],[new RegExp("(bus)es$","gi"),"$1"],[new RegExp("(o)es$","gi"),"$1"],[new RegExp("(shoe)s$","gi"),"$1"],[new RegExp("(cris|ax|test)es$","gi"),"$1is"],[new RegExp("(octop|vir)i$","gi"),"$1us"],[new RegExp("(alias|status)es$","gi"),"$1"],[new RegExp("^(ox)en","gi"),"$1"],[new RegExp("(vert|ind)ices$","gi"),"$1ex"],[new RegExp("(matr)ices$","gi"),"$1ix"],[new RegExp("(quiz)zes$","gi"),"$1"],[new RegExp("s$","gi"),""]],nonTitlecasedWords:["and","or","nor","a","an","the","so","but","to","of","at","by","from","into","on","onto","off","out","in","over","with","for"],idSuffix:new RegExp("(_ids|_id)$","g"),underbar:new RegExp("_","g"),spaceOrUnderbar:new RegExp("[ _]","g"),uppercase:new RegExp("([A-Z])","g"),underbarPrefix:new RegExp("^_"),applyRules:function(t,e,n,r){if(r)t=r;else if(!(n.indexOf(t.toLowerCase())>-1))for(var i=0;i>8-s%1*8)){if((n=i.charCodeAt(s+=3/4))>255)throw new r;e=e<<8|n}return o}},function(t,e,n){"use strict";var r=n(0);function i(t){return encodeURIComponent(t).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}t.exports=function(t,e,n){if(!e)return t;var o;if(n)o=n(e);else if(r.isURLSearchParams(e))o=e.toString();else{var s=[];r.forEach(e,(function(t,e){null!=t&&(r.isArray(t)?e+="[]":t=[t],r.forEach(t,(function(t){r.isDate(t)?t=t.toISOString():r.isObject(t)&&(t=JSON.stringify(t)),s.push(i(e)+"="+i(t))})))})),o=s.join("&")}return o&&(t+=(-1===t.indexOf("?")?"?":"&")+o),t}},function(t,e,n){"use strict";t.exports=function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}},function(t,e,n){"use strict";var r=n(0);t.exports=r.isStandardBrowserEnv()?{write:function(t,e,n,i,o,s){var a=[];a.push(t+"="+encodeURIComponent(e)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(i)&&a.push("path="+i),r.isString(o)&&a.push("domain="+o),!0===s&&a.push("secure"),document.cookie=a.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(t,e,n){"use strict";t.exports=function(t){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t)}},function(t,e,n){"use strict";var r=n(0);t.exports=r.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function i(t){var r=t;return e&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return t=i(window.location.href),function(e){var n=r.isString(e)?i(e):e;return n.protocol===t.protocol&&n.host===t.host}}():function(){return!0}},function(t,e,n){"use strict";var r=n(0);t.exports=function(t,e){r.forEach(t,(function(n,r){r!==e&&r.toUpperCase()===e.toUpperCase()&&(t[e]=n,delete t[r])}))}},function(t,e,n){"use strict";var r=n(0),i=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];t.exports=function(t){var e,n,o,s={};return t?(r.forEach(t.split("\n"),(function(t){if(o=t.indexOf(":"),e=r.trim(t.substr(0,o)).toLowerCase(),n=r.trim(t.substr(o+1)),e){if(s[e]&&i.indexOf(e)>=0)return;s[e]="set-cookie"===e?(s[e]?s[e]:[]).concat([n]):s[e]?s[e]+", "+n:n}})),s):s}},function(t,e,n){"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},function(t,e,n){t.exports={default:n(118),__esModule:!0}},function(t,e,n){t.exports={default:n(119),__esModule:!0}},function(t,e,n){"use strict";e.__esModule=!0;var r,i=n(115),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default||function(t){for(var e=1;el;)if((a=u[l++])!=a)return!0}else for(;c>l;l++)if((t||l in u)&&u[l]===n)return t||l||0;return!t&&-1}}},function(t,e,n){var r=n(16),i=n(128),o=n(127),s=n(4),a=n(65),u=n(147),c={},l={};(e=t.exports=function(t,e,n,f,p){var h,d,_,v,m=p?function(){return t}:u(t),g=r(n,f,e?2:1),y=0;if("function"!=typeof m)throw TypeError(t+" is not iterable!");if(o(m)){for(h=a(t.length);h>y;y++)if((v=e?g(s(d=t[y])[0],d[1]):g(t[y]))===c||v===l)return v}else for(_=m.call(t);!(d=_.next()).done;)if((v=i(_,g,d.value,e))===c||v===l)return v}).BREAK=c,e.RETURN=l},function(t,e,n){t.exports=!n(5)&&!n(29)((function(){return 7!=Object.defineProperty(n(28)("div"),"a",{get:function(){return 7}}).a}))},function(t,e){t.exports=function(t,e,n){var r=void 0===n;switch(e.length){case 0:return r?t():t.call(n);case 1:return r?t(e[0]):t.call(n,e[0]);case 2:return r?t(e[0],e[1]):t.call(n,e[0],e[1]);case 3:return r?t(e[0],e[1],e[2]):t.call(n,e[0],e[1],e[2]);case 4:return r?t(e[0],e[1],e[2],e[3]):t.call(n,e[0],e[1],e[2],e[3])}return t.apply(n,e)}},function(t,e,n){var r=n(10),i=n(2)("iterator"),o=Array.prototype;t.exports=function(t){return void 0!==t&&(r.Array===t||o[i]===t)}},function(t,e,n){var r=n(4);t.exports=function(t,e,n,i){try{return i?e(r(n)[0],n[1]):e(n)}catch(e){var o=t.return;throw void 0!==o&&r(o.call(t)),e}}},function(t,e,n){"use strict";var r=n(134),i=n(61),o=n(32),s={};n(7)(s,n(2)("iterator"),(function(){return this})),t.exports=function(t,e,n){t.prototype=r(s,{next:i(1,n)}),o(t,e+" Iterator")}},function(t,e,n){var r=n(2)("iterator"),i=!1;try{var o=[7][r]();o.return=function(){i=!0},Array.from(o,(function(){throw 2}))}catch(t){}t.exports=function(t,e){if(!e&&!i)return!1;var n=!1;try{var o=[7],s=o[r]();s.next=function(){return{done:n=!0}},o[r]=function(){return s},t(o)}catch(t){}return n}},function(t,e){t.exports=function(t,e){return{value:e,done:!!t}}},function(t,e,n){var r=n(1),i=n(64).set,o=r.MutationObserver||r.WebKitMutationObserver,s=r.process,a=r.Promise,u="process"==n(15)(s);t.exports=function(){var t,e,n,c=function(){var r,i;for(u&&(r=s.domain)&&r.exit();t;){i=t.fn,t=t.next;try{i()}catch(r){throw t?n():e=void 0,r}}e=void 0,r&&r.enter()};if(u)n=function(){s.nextTick(c)};else if(!o||r.navigator&&r.navigator.standalone)if(a&&a.resolve){var l=a.resolve(void 0);n=function(){l.then(c)}}else n=function(){i.call(r,c)};else{var f=!0,p=document.createTextNode("");new o(c).observe(p,{characterData:!0}),n=function(){p.data=f=!f}}return function(r){var i={fn:r,next:void 0};e&&(e.next=i),t||(t=i,n()),e=i}}},function(t,e,n){"use strict";var r=n(58),i=n(136),o=n(139),s=n(66),a=n(56),u=Object.assign;t.exports=!u||n(29)((function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach((function(t){e[t]=t})),7!=u({},t)[n]||Object.keys(u({},e)).join("")!=r}))?function(t,e){for(var n=s(t),u=arguments.length,c=1,l=i.f,f=o.f;u>c;)for(var p,h=a(arguments[c++]),d=l?r(h).concat(l(h)):r(h),_=d.length,v=0;_>v;)f.call(h,p=d[v++])&&(n[p]=h[p]);return n}:u},function(t,e,n){var r=n(4),i=n(135),o=n(54),s=n(33)("IE_PROTO"),a=function(){},u=function(){var t,e=n(28)("iframe"),r=o.length;for(e.style.display="none",n(55).appendChild(e),e.src="javascript:",(t=e.contentWindow.document).open(),t.write("