(window.textWebpackJsonp=window.textWebpackJsonp||[]).push([[195],[function(e,t,n){"use strict";var r=n(6),o=n(18),i=Object.prototype.toString;function s(e){return"[object Array]"===i.call(e)}function a(e){return null!==e&&"object"==typeof e}function c(e){return"[object Function]"===i.call(e)}function l(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),s(e))for(var n=0,r=e.length;n=200&&e<300}};c.headers={common:{Accept:"application/json, text/plain, */*"}},r.forEach(["delete","get","head"],function(e){c.headers[e]={}}),r.forEach(["post","put","patch"],function(e){c.headers[e]=r.merge(i)}),e.exports=c}).call(this,n(16))},function(e,t,n){"use strict";var r=n(0),o=n(24),i=n(7),s=n(26),a=n(27),c=n(11);e.exports=function(e){return new Promise(function(t,l){var u=e.data,p=e.headers;r.isFormData(u)&&delete p["Content-Type"];var f=new XMLHttpRequest;if(e.auth){var h=e.auth.username||"",d=e.auth.password||"";p.Authorization="Basic "+btoa(h+":"+d)}if(f.open(e.method.toUpperCase(),i(e.url,e.params,e.paramsSerializer),!0),f.timeout=e.timeout,f.onreadystatechange=function(){if(f&&4===f.readyState&&(0!==f.status||f.responseURL&&0===f.responseURL.indexOf("file:"))){var n="getAllResponseHeaders"in f?s(f.getAllResponseHeaders()):null,r={data:e.responseType&&"text"!==e.responseType?f.response:f.responseText,status:f.status,statusText:f.statusText,headers:n,config:e,request:f};o(t,l,r),f=null}},f.onabort=function(){f&&(l(c("Request aborted",e,"ECONNABORTED",f)),f=null)},f.onerror=function(){l(c("Network Error",e,null,f)),f=null},f.ontimeout=function(){l(c("timeout of "+e.timeout+"ms exceeded",e,"ECONNABORTED",f)),f=null},r.isStandardBrowserEnv()){var m=n(28),v=(e.withCredentials||a(e.url))&&e.xsrfCookieName?m.read(e.xsrfCookieName):void 0;v&&(p[e.xsrfHeaderName]=v)}if("setRequestHeader"in f&&r.forEach(p,function(e,t){void 0===u&&"content-type"===t.toLowerCase()?delete p[t]:f.setRequestHeader(t,e)}),e.withCredentials&&(f.withCredentials=!0),e.responseType)try{f.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&f.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&f.upload&&f.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){f&&(f.abort(),l(e),f=null)}),void 0===u&&(u=null),f.send(u)})}},function(e,t,n){"use strict";var r=n(25);e.exports=function(e,t,n,o,i){var s=new Error(e);return r(s,t,n,o,i)}},function(e,t,n){"use strict";var r=n(0);e.exports=function(e,t){t=t||{};var n={};return r.forEach(["url","method","params","data"],function(e){void 0!==t[e]&&(n[e]=t[e])}),r.forEach(["headers","auth","proxy"],function(o){r.isObject(t[o])?n[o]=r.deepMerge(e[o],t[o]):void 0!==t[o]?n[o]=t[o]:r.isObject(e[o])?n[o]=r.deepMerge(e[o]):void 0!==e[o]&&(n[o]=e[o])}),r.forEach(["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","maxContentLength","validateStatus","maxRedirects","httpAgent","httpsAgent","cancelToken","socketPath"],function(r){void 0!==t[r]?n[r]=t[r]:void 0!==e[r]&&(n[r]=e[r])}),n}},function(e,t,n){"use strict";function r(e){this.message=e}r.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},r.prototype.__CANCEL__=!0,e.exports=r},function(e,t,n){e.exports=n(17)},,function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(e){r=s}}();var c,l=[],u=!1,p=-1;function f(){u&&c&&(u=!1,c.length?l=c.concat(l):p=-1,l.length&&h())}function h(){if(!u){var e=a(f);u=!0;for(var t=l.length;t;){for(c=l,l=[];++p1)for(var n=1;n * @license MIT */ e.exports=function(e){return null!=e&&null!=e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}},function(e,t,n){"use strict";var r=n(0),o=n(7),i=n(20),s=n(21),a=n(12);function c(e){this.defaults=e,this.interceptors={request:new i,response:new i}}c.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=a(this.defaults,e)).method=e.method?e.method.toLowerCase():"get";var t=[s,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n},c.prototype.getUri=function(e){return e=a(this.defaults,e),o(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},r.forEach(["delete","get","head","options"],function(e){c.prototype[e]=function(t,n){return this.request(r.merge(n||{},{method:e,url:t}))}}),r.forEach(["post","put","patch"],function(e){c.prototype[e]=function(t,n,o){return this.request(r.merge(o||{},{method:e,url:t,data:n}))}}),e.exports=c},function(e,t,n){"use strict";var r=n(0);function o(){this.handlers=[]}o.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},o.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},o.prototype.forEach=function(e){r.forEach(this.handlers,function(t){null!==t&&e(t)})},e.exports=o},function(e,t,n){"use strict";var r=n(0),o=n(22),i=n(8),s=n(9),a=n(29),c=n(30);function l(e){e.cancelToken&&e.cancelToken.throwIfRequested()}e.exports=function(e){return l(e),e.baseURL&&!a(e.url)&&(e.url=c(e.baseURL,e.url)),e.headers=e.headers||{},e.data=o(e.data,e.headers,e.transformRequest),e.headers=r.merge(e.headers.common||{},e.headers[e.method]||{},e.headers||{}),r.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]}),(e.adapter||s.adapter)(e).then(function(t){return l(e),t.data=o(t.data,t.headers,e.transformResponse),t},function(t){return i(t)||(l(e),t&&t.response&&(t.response.data=o(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})}},function(e,t,n){"use strict";var r=n(0);e.exports=function(e,t,n){return r.forEach(n,function(n){e=n(e,t)}),e}},function(e,t,n){"use strict";var r=n(0);e.exports=function(e,t){r.forEach(e,function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])})}},function(e,t,n){"use strict";var r=n(11);e.exports=function(e,t,n){var o=n.config.validateStatus;!o||o(n.status)?e(n):t(r("Request failed with status code "+n.status,n.config,null,n.request,n))}},function(e,t,n){"use strict";e.exports=function(e,t,n,r,o){return e.config=t,n&&(e.code=n),e.request=r,e.response=o,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}},function(e,t,n){"use strict";var r=n(0),o=["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"];e.exports=function(e){var t,n,i,s={};return e?(r.forEach(e.split("\n"),function(e){if(i=e.indexOf(":"),t=r.trim(e.substr(0,i)).toLowerCase(),n=r.trim(e.substr(i+1)),t){if(s[t]&&o.indexOf(t)>=0)return;s[t]="set-cookie"===t?(s[t]?s[t]:[]).concat([n]):s[t]?s[t]+", "+n:n}}),s):s}},function(e,t,n){"use strict";var r=n(0);e.exports=r.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function o(e){var r=e;return t&&(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 e=o(window.location.href),function(t){var n=r.isString(t)?o(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0}},function(e,t,n){"use strict";var r=n(0);e.exports=r.isStandardBrowserEnv()?{write:function(e,t,n,o,i,s){var a=[];a.push(e+"="+encodeURIComponent(t)),r.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),r.isString(o)&&a.push("path="+o),r.isString(i)&&a.push("domain="+i),!0===s&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(e,t,n){"use strict";e.exports=function(e){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(e)}},function(e,t,n){"use strict";e.exports=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}},function(e,t,n){"use strict";var r=n(13);function o(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var n=this;e(function(e){n.reason||(n.reason=new r(e),t(n.reason))})}o.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},o.source=function(){var e;return{token:new o(function(t){e=t}),cancel:e}},e.exports=o},function(e,t,n){"use strict";e.exports=function(e){return function(t){return e.apply(null,t)}}},,,,,,,function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(44),o=n(43),i=n(41);function s(e,t){return!e.selection.empty&&(t&&t(e.tr.deleteSelection().scrollIntoView()),!0)}function a(e,t,n){var o=e.selection.$cursor;if(!o||(n?!n.endOfTextblock("backward",e):o.parentOffset>0))return!1;var s=u(o);if(!s){var a=o.blockRange(),l=a&&r.liftTarget(a);return null!=l&&(t&&t(e.tr.lift(a,l).scrollIntoView()),!0)}var p=s.nodeBefore;if(!p.type.spec.isolating&&w(e,s,t))return!0;if(0==o.parent.content.size&&(c(p,"end")||i.NodeSelection.isSelectable(p))){if(t){var f=e.tr.deleteRange(o.before(),o.after());f.setSelection(c(p,"end")?i.Selection.findFrom(f.doc.resolve(f.mapping.map(s.pos,-1)),-1):i.NodeSelection.create(f.doc,s.pos-p.nodeSize)),t(f.scrollIntoView())}return!0}return!(!p.isAtom||s.depth!=o.depth-1)&&(t&&t(e.tr.delete(s.pos-p.nodeSize,s.pos).scrollIntoView()),!0)}function c(e,t){for(;e;e="start"==t?e.firstChild:e.lastChild)if(e.isTextblock)return!0;return!1}function l(e,t,n){var r=e.selection.$cursor;if(!r||(n?!n.endOfTextblock("backward",e):r.parentOffset>0))return!1;var o=u(r),s=o&&o.nodeBefore;return!(!s||!i.NodeSelection.isSelectable(s))&&(t&&t(e.tr.setSelection(i.NodeSelection.create(e.doc,o.pos-s.nodeSize)).scrollIntoView()),!0)}function u(e){if(!e.parent.type.spec.isolating)for(var t=e.depth-1;t>=0;t--){if(e.index(t)>0)return e.doc.resolve(e.before(t+1));if(e.node(t).type.spec.isolating)break}return null}function p(e,t,n){var r=e.selection.$cursor;if(!r||(n?!n.endOfTextblock("forward",e):r.parentOffset=0;t--){var n=e.node(t);if(e.index(t)+11&&n.after()!=n.end(-1)){var o=n.before();if(r.canSplit(e.doc,o))return t&&t(e.tr.split(o).scrollIntoView()),!0}var i=n.blockRange(),s=i&&r.liftTarget(i);return null!=s&&(t&&t(e.tr.lift(i,s).scrollIntoView()),!0)}function y(e,t){var n=e.selection,s=n.$from,a=n.$to;if(e.selection instanceof i.NodeSelection&&e.selection.node.isBlock)return!(!s.parentOffset||!r.canSplit(e.doc,s.pos))&&(t&&t(e.tr.split(s.pos).scrollIntoView()),!0);if(!s.parent.isBlock)return!1;if(t){var c=a.parentOffset==a.parent.content.size,l=e.tr;e.selection instanceof i.TextSelection&&l.deleteSelection();var u=0==s.depth?null:s.node(-1).contentMatchAt(s.indexAfter(-1)).defaultType,p=c&&u?[{type:u}]:null,f=r.canSplit(l.doc,l.mapping.map(s.pos),1,p);p||f||!r.canSplit(l.doc,l.mapping.map(s.pos),1,u&&[{type:u}])||(p=[{type:u}],f=!0),f&&(l.split(l.mapping.map(s.pos),1,p),c||s.parentOffset||s.parent.type==u||!s.node(-1).canReplace(s.index(-1),s.indexAfter(-1),o.Fragment.from(u.create(),s.parent))||l.setNodeMarkup(l.mapping.map(s.before()),u)),t(l.scrollIntoView())}return!0}function b(e,t){return t&&t(e.tr.setSelection(new i.AllSelection(e.doc))),!0}function w(e,t,n){var s,a,c=t.nodeBefore,l=t.nodeAfter;if(c.type.spec.isolating||l.type.spec.isolating)return!1;if(function(e,t,n){var o=t.nodeBefore,i=t.nodeAfter,s=t.index();return!!(o&&i&&o.type.compatibleContent(i.type))&&(!o.content.size&&t.parent.canReplace(s-1,s)?(n&&n(e.tr.delete(t.pos-o.nodeSize,t.pos).scrollIntoView()),!0):!(!t.parent.canReplace(s,s+1)||!i.isTextblock&&!r.canJoin(e.doc,t.pos))&&(n&&n(e.tr.clearIncompatible(t.pos,o.type,o.contentMatchAt(o.childCount)).join(t.pos).scrollIntoView()),!0))}(e,t,n))return!0;if(t.parent.canReplace(t.index(),t.index()+1)&&(s=(a=c.contentMatchAt(c.childCount)).findWrapping(l.type))&&a.matchType(s[0]||l.type).validEnd){if(n){for(var u=t.pos+l.nodeSize,p=o.Fragment.empty,f=s.length-1;f>=0;f--)p=o.Fragment.from(s[f].create(null,p));p=o.Fragment.from(c.copy(p));var h=e.tr.step(new r.ReplaceAroundStep(t.pos-1,u,t.pos,u,new o.Slice(p,1,0),s.length,!0)),d=u+2*s.length;r.canJoin(h.doc,d)&&h.join(d),n(h.scrollIntoView())}return!0}var m=i.Selection.findFrom(t,1),v=m&&m.$from.blockRange(m.$to),g=v&&r.liftTarget(v);return null!=g&&g>=t.depth&&(n&&n(e.tr.lift(v,g).scrollIntoView()),!0)}function k(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];return function(t,n,r){for(var o=0;o-1}}return function(n,o){return e(n,o&&function(e,t){return function(n){if(!n.isGeneric)return e(n);for(var o=[],i=0;i=0;b--)r.canJoin(n.doc,c[b])&&n.join(c[b]);e(n)}}(o,t))}},t.chainCommands=k,t.pcBaseKeymap=C,t.macBaseKeymap=S,t.baseKeymap=A},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty;function o(e,t){return r.call(e,t)}function i(e){return!(e>=55296&&e<=57343)&&(!(e>=64976&&e<=65007)&&(65535!=(65535&e)&&65534!=(65535&e)&&(!(e>=0&&e<=8)&&(11!==e&&(!(e>=14&&e<=31)&&(!(e>=127&&e<=159)&&!(e>1114111)))))))}function s(e){if(e>65535){var t=55296+((e-=65536)>>10),n=56320+(1023&e);return String.fromCharCode(t,n)}return String.fromCharCode(e)}var a=/\\([!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~])/g,c=new RegExp(a.source+"|"+/&([a-z#][a-z0-9]{1,31});/gi.source,"gi"),l=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i,u=n(74);var p=/[&<>"]/,f=/[&<>"]/g,h={"&":"&","<":"<",">":">",'"':"""};function d(e){return h[e]}var m=/[.?*+^$[\]\\(){}|-]/g;var v=n(57);t.lib={},t.lib.mdurl=n(75),t.lib.ucmicro=n(289),t.assign=function(e){return Array.prototype.slice.call(arguments,1).forEach(function(t){if(t){if("object"!=typeof t)throw new TypeError(t+"must be object");Object.keys(t).forEach(function(n){e[n]=t[n]})}}),e},t.isString=function(e){return"[object String]"===function(e){return Object.prototype.toString.call(e)}(e)},t.has=o,t.unescapeMd=function(e){return e.indexOf("\\")<0?e:e.replace(a,"$1")},t.unescapeAll=function(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(c,function(e,t,n){return t||function(e,t){var n=0;return o(u,t)?u[t]:35===t.charCodeAt(0)&&l.test(t)&&i(n="x"===t[1].toLowerCase()?parseInt(t.slice(2),16):parseInt(t.slice(1),10))?s(n):e}(e,n)})},t.isValidEntityCode=i,t.fromCodePoint=s,t.escapeHtml=function(e){return p.test(e)?e.replace(f,d):e},t.arrayReplaceAt=function(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))},t.isSpace=function(e){switch(e){case 9:case 32:return!0}return!1},t.isWhiteSpace=function(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1},t.isMdAsciiPunct=function(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}},t.isPunctChar=function(e){return v.test(e)},t.escapeRE=function(e){return e.replace(m,"\\$&")},t.normalizeReference=function(e){return e.trim().replace(/\s+/g," ").toUpperCase()}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(43),o=n(44),i=Object.create(null),s=function(e,t,n){this.ranges=n||[new c(e.min(t),e.max(t))],this.$anchor=e,this.$head=t},a={anchor:{},head:{},from:{},to:{},$from:{},$to:{},empty:{}};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 e=this.ranges,t=0;t=0;o--){var i=t<0?m(e.node(0),e.node(o),e.before(o+1),e.index(o),t,n):m(e.node(0),e.node(o),e.after(o+1),e.index(o)+1,t,n);if(i)return i}},s.near=function(e,t){return void 0===t&&(t=1),this.findFrom(e,t)||this.findFrom(e,-t)||new h(e.node(0))},s.atStart=function(e){return m(e,e,0,0,1)||new h(e)},s.atEnd=function(e){return m(e,e,e.content.size,e.childCount,-1)||new h(e)},s.fromJSON=function(e,t){if(!t||!t.type)throw new RangeError("Invalid input for Selection.fromJSON");var n=i[t.type];if(!n)throw new RangeError("No selection type "+t.type+" defined");return n.fromJSON(e,t)},s.jsonID=function(e,t){if(e in i)throw new RangeError("Duplicate use of selection JSON ID "+e);return i[e]=t,t.prototype.jsonID=e,t},s.prototype.getBookmark=function(){return l.between(this.$anchor,this.$head).getBookmark()},Object.defineProperties(s.prototype,a),s.prototype.visible=!0;var c=function(e,t){this.$from=e,this.$to=t},l=function(e){function t(t,n){void 0===n&&(n=t),e.call(this,t,n)}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={$cursor:{}};return n.$cursor.get=function(){return this.$anchor.pos==this.$head.pos?this.$head:null},t.prototype.map=function(n,r){var o=n.resolve(r.map(this.head));if(!o.parent.inlineContent)return e.near(o);var i=n.resolve(r.map(this.anchor));return new t(i.parent.inlineContent?i:o,o)},t.prototype.replace=function(t,n){if(void 0===n&&(n=r.Slice.empty),e.prototype.replace.call(this,t,n),n==r.Slice.empty){var o=this.$from.marksAcross(this.$to);o&&t.ensureMarks(o)}},t.prototype.eq=function(e){return e instanceof t&&e.anchor==this.anchor&&e.head==this.head},t.prototype.getBookmark=function(){return new u(this.anchor,this.head)},t.prototype.toJSON=function(){return{type:"text",anchor:this.anchor,head:this.head}},t.fromJSON=function(e,n){if("number"!=typeof n.anchor||"number"!=typeof n.head)throw new RangeError("Invalid input for TextSelection.fromJSON");return new t(e.resolve(n.anchor),e.resolve(n.head))},t.create=function(e,t,n){void 0===n&&(n=t);var r=e.resolve(t);return new this(r,n==t?r:e.resolve(n))},t.between=function(n,r,o){var i=n.pos-r.pos;if(o&&!i||(o=i>=0?1:-1),!r.parent.inlineContent){var s=e.findFrom(r,o,!0)||e.findFrom(r,-o,!0);if(!s)return e.near(r,o);r=s.$head}return n.parent.inlineContent||(0==i?n=r:(n=(e.findFrom(n,-o,!0)||e.findFrom(n,o,!0)).$anchor).pos0?0:1);o>0?s=0;s+=o){var a=t.child(s);if(a.isAtom){if(!i&&p.isSelectable(a))return p.create(e,n-(o<0?a.nodeSize:0))}else{var c=m(e,a,n+o,o<0?a.childCount:0,o,i);if(c)return c}n+=a.nodeSize*o}}function v(e,t,n){var r=e.steps.length-1;if(!(r0},t.prototype.setStoredMarks=function(e){return this.storedMarks=e,this.updated|=2,this},t.prototype.ensureMarks=function(e){return r.Mark.sameSet(this.storedMarks||this.selection.$from.marks(),e)||this.setStoredMarks(e),this},t.prototype.addStoredMark=function(e){return this.ensureMarks(e.addToSet(this.storedMarks||this.selection.$head.marks()))},t.prototype.removeStoredMark=function(e){return this.ensureMarks(e.removeFromSet(this.storedMarks||this.selection.$head.marks()))},n.storedMarksSet.get=function(){return(2&this.updated)>0},t.prototype.addStep=function(t,n){e.prototype.addStep.call(this,t,n),this.updated=-3&this.updated,this.storedMarks=null},t.prototype.setTime=function(e){return this.time=e,this},t.prototype.replaceSelection=function(e){return this.selection.replace(this,e),this},t.prototype.replaceSelectionWith=function(e,t){var n=this.selection;return!1!==t&&(e=e.mark(this.storedMarks||(n.empty?n.$from.marks():n.$from.marksAcross(n.$to)||r.Mark.none))),n.replaceWith(this,e),this},t.prototype.deleteSelection=function(){return this.selection.replace(this),this},t.prototype.insertText=function(e,t,n){void 0===n&&(n=t);var r=this.doc.type.schema;if(null==t)return e?this.replaceSelectionWith(r.text(e),!0):this.deleteSelection();if(!e)return this.deleteRange(t,n);var o=this.storedMarks;if(!o){var i=this.doc.resolve(t);o=n==t?i.marks():i.marksAcross(this.doc.resolve(n))}return this.replaceRangeWith(t,n,r.text(e,o)),this.selection.empty||this.setSelection(s.near(this.selection.$to)),this},t.prototype.setMeta=function(e,t){return this.meta["string"==typeof e?e:e.key]=t,this},t.prototype.getMeta=function(e){return this.meta["string"==typeof e?e:e.key]},n.isGeneric.get=function(){for(var e in this.meta)return!1;return!0},t.prototype.scrollIntoView=function(){return this.updated|=4,this},n.scrolledIntoView.get=function(){return(4&this.updated)>0},Object.defineProperties(t.prototype,n),t}(o.Transform);function y(e,t){return t&&e?e.bind(t):e}var b=function(e,t,n){this.name=e,this.init=y(t.init,n),this.apply=y(t.apply,n)},w=[new b("doc",{init:function(e){return e.doc||e.schema.topNodeType.createAndFill()},apply:function(e){return e.doc}}),new b("selection",{init:function(e,t){return e.selection||s.atStart(t.doc)},apply:function(e){return e.selection}}),new b("storedMarks",{init:function(e){return e.storedMarks||null},apply:function(e,t,n,r){return r.selection.$cursor?e.storedMarks:null}}),new b("scrollToSelection",{init:function(){return 0},apply:function(e,t){return e.scrolledIntoView?t+1:t}})],k=function(e,t){var n=this;this.schema=e,this.fields=w.concat(),this.plugins=[],this.pluginsByKey=Object.create(null),t&&t.forEach(function(e){if(n.pluginsByKey[e.key])throw new RangeError("Adding different instances of a keyed plugin ("+e.key+")");n.plugins.push(e),n.pluginsByKey[e.key]=e,e.spec.state&&n.fields.push(new b(e.key,e.spec.state,e))})},x=function(e){this.config=e},_={schema:{},plugins:{},tr:{}};_.schema.get=function(){return this.config.schema},_.plugins.get=function(){return this.config.plugins},x.prototype.apply=function(e){return this.applyTransaction(e).state},x.prototype.filterTransaction=function(e,t){void 0===t&&(t=-1);for(var n=0;n-1&&C.splice(t,1)},Object.defineProperties(x.prototype,_);var C=[];var S=function(e){this.props={},e.props&&function e(t,n,r){for(var o in t){var i=t[o];i instanceof Function?i=i.bind(n):"handleDOMEvents"==o&&(i=e(i,n,{})),r[o]=i}return r}(e.props,this,this.props),this.spec=e,this.key=e.key?e.key.key:A("plugin")};S.prototype.getState=function(e){return e[this.key]};var O=Object.create(null);function A(e){return e in O?e+"$"+ ++O[e]:(O[e]=0,e+"$")}var E=function(e){void 0===e&&(e="key"),this.key=A(e)};E.prototype.get=function(e){return e.config.pluginsByKey[this.key]},E.prototype.getState=function(e){return e[this.key]},t.Selection=s,t.SelectionRange=c,t.TextSelection=l,t.NodeSelection=p,t.AllSelection=h,t.Transaction=g,t.EditorState=x,t.Plugin=S,t.PluginKey=E},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(44),o=n(43),i=["ol",0],s=["ul",0],a=["li",0],c={attrs:{order:{default:1}},parseDOM:[{tag:"ol",getAttrs:function(e){return{order:e.hasAttribute("start")?+e.getAttribute("start"):1}}}],toDOM:function(e){return 1==e.attrs.order?i:["ol",{start:e.attrs.order},0]}},l={parseDOM:[{tag:"ul"}],toDOM:function(){return s}},u={parseDOM:[{tag:"li"}],toDOM:function(){return a},defining:!0};function p(e,t){var n={};for(var r in e)n[r]=e[r];for(var o in t)n[o]=t[o];return n}t.orderedList=c,t.bulletList=l,t.listItem=u,t.addListNodes=function(e,t,n){return e.append({ordered_list:p(c,{content:"list_item+",group:n}),bullet_list:p(l,{content:"list_item+",group:n}),list_item:p(u,{content:t})})},t.wrapInList=function(e,t){return function(n,i){var s=n.selection,a=s.$from,c=s.$to,l=a.blockRange(c),u=!1,p=l;if(!l)return!1;if(l.depth>=2&&a.node(l.depth-1).type.compatibleContent(e)&&0==l.startIndex){if(0==a.index(l.depth-1))return!1;var f=n.doc.resolve(l.start-2);p=new o.NodeRange(f,f,l.depth),l.endIndex=0;c--)a=o.Fragment.from(n[c].type.create(n[c].attrs,a));e.step(new r.ReplaceAroundStep(t.start-(i?2:0),t.end,t.start,t.end,new o.Slice(a,0,0),n.length,!0));for(var l=0,u=0;u0,f=s.depth-(p?1:2);f>=s.depth-3;f--)u=o.Fragment.from(s.node(f).copy(u));u=u.append(o.Fragment.from(e.createAndFill()));var h=t.tr.replace(s.before(p?null:-1),s.after(-3),new o.Slice(u,p?3:2,2));h.setSelection(t.selection.constructor.near(h.doc.resolve(s.pos+(p?3:2)))),n(h.scrollIntoView())}return!0}var d=a.pos==s.end()?l.contentMatchAt(s.indexAfter(-1)).defaultType:null,m=t.tr.delete(s.pos,a.pos),v=d&&[null,{type:d}];return!!r.canSplit(m.doc,s.pos,2,v)&&(n&&n(m.split(s.pos,2,v).scrollIntoView()),!0)}},t.liftListItem=function(e){return function(t,n){var i=t.selection,s=i.$from,a=i.$to,c=s.blockRange(a,function(t){return t.childCount&&t.firstChild.type==e});return!!c&&(!n||(s.node(c.depth-1).type==e?function(e,t,n,i){var s=e.tr,a=i.end,c=i.$to.end(i.depth);al;c--)a-=s.child(c).nodeSize,i.delete(a-1,a+1);var u=i.doc.resolve(n.start),p=u.nodeAfter,f=0==n.startIndex,h=n.endIndex==s.childCount,d=u.node(-1),m=u.index(-1);if(!d.canReplace(m+(f?0:1),m+1,p.content.append(h?o.Fragment.empty:o.Fragment.from(s))))return!1;var v=u.pos,g=v+p.nodeSize;return i.step(new r.ReplaceAroundStep(v-(f?1:0),g+(h?1:0),v+1,g-1,new o.Slice((f?o.Fragment.empty:o.Fragment.from(s.copy(o.Fragment.empty))).append(h?o.Fragment.empty:o.Fragment.from(s.copy(o.Fragment.empty))),f?0:1,h?0:1),f?0:1)),t(i.scrollIntoView()),!0}(t,n,c)))}},t.sinkListItem=function(e){return function(t,n){var i=t.selection,s=i.$from,a=i.$to,c=s.blockRange(a,function(t){return t.childCount&&t.firstChild.type==e});if(!c)return!1;var l=c.startIndex;if(0==l)return!1;var u=c.parent,p=u.child(l-1);if(p.type!=e)return!1;if(n){var f=p.lastChild&&p.lastChild.type==u.type,h=o.Fragment.from(f?e.create():null),d=new o.Slice(o.Fragment.from(e.create(null,o.Fragment.from(u.type.create(null,h)))),f?3:1,0),m=c.start,v=c.end;n(t.tr.step(new r.ReplaceAroundStep(m-(f?3:1),v,m,v,d,1,!0)).scrollIntoView())}return!0}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o=(r=n(271))&&"object"==typeof r&&"default"in r?r.default:r;var i=function(e,t){if(this.content=e,this.size=t||0,null==t)for(var n=0;ne&&!1!==n(a,r+s,o,i)&&a.content.size){var l=s+1;a.nodesBetween(Math.max(0,e-l),Math.min(a.content.size,t-l),n,r+l)}s=c}},i.prototype.descendants=function(e){this.nodesBetween(0,this.size,e)},i.prototype.textBetween=function(e,t,n,r){var o="",i=!0;return this.nodesBetween(e,t,function(s,a){s.isText?(o+=s.text.slice(Math.max(e,a)-a,t-a),i=!n):s.isLeaf&&r?(o+=r,i=!n):!i&&s.isBlock&&(o+=n,i=!0)},0),o},i.prototype.append=function(e){if(!e.size)return this;if(!this.size)return e;var t=this.lastChild,n=e.firstChild,r=this.content.slice(),o=0;for(t.isText&&t.sameMarkup(n)&&(r[r.length-1]=t.withText(t.text+n.text),o=1);oe)for(var o=0,s=0;se&&((st)&&(a=a.isText?a.cut(Math.max(0,e-s),Math.min(a.text.length,t-s)):a.cut(Math.max(0,e-s-1),Math.min(a.content.size,t-s-1))),n.push(a),r+=a.nodeSize),s=c}return new i(n,r)},i.prototype.cutByIndex=function(e,t){return e==t?i.empty:0==e&&t==this.content.length?this:new i(this.content.slice(e,t))},i.prototype.replaceChild=function(e,t){var n=this.content[e];if(n==t)return this;var r=this.content.slice(),o=this.size+t.nodeSize-n.nodeSize;return r[e]=t,new i(r,o)},i.prototype.addToStart=function(e){return new i([e].concat(this.content),this.size+e.nodeSize)},i.prototype.addToEnd=function(e){return new i(this.content.concat(e),this.size+e.nodeSize)},i.prototype.eq=function(e){if(this.content.length!=e.content.length)return!1;for(var t=0;tthis.size||e<0)throw new RangeError("Position "+e+" outside of fragment ("+this+")");for(var n=0,r=0;;n++){var o=r+this.child(n).nodeSize;if(o>=e)return o==e||t>0?c(n+1,o):c(n,r);r=o}},i.prototype.toString=function(){return"<"+this.toStringInner()+">"},i.prototype.toStringInner=function(){return this.content.join(", ")},i.prototype.toJSON=function(){return this.content.length?this.content.map(function(e){return e.toJSON()}):null},i.fromJSON=function(e,t){if(!t)return i.empty;if(!Array.isArray(t))throw new RangeError("Invalid input for Fragment.fromJSON");return new i(t.map(e.nodeFromJSON))},i.fromArray=function(e){if(!e.length)return i.empty;for(var t,n=0,r=0;rthis.type.rank&&(t||(t=e.slice(0,r)),t.push(this),n=!0),t&&t.push(o)}}return t||(t=e.slice()),n||t.push(this),t},u.prototype.removeFromSet=function(e){for(var t=0;te.depth)throw new p("Inserted content deeper than insertion position");if(e.depth-n.openStart!=t.depth-n.openEnd)throw new p("Inconsistent open depths");return function e(t,n,r,o){var s=t.index(o),a=t.node(o);if(s==n.index(o)&&o=0;o--)r=t.node(o).copy(i.from(r));return{start:r.resolveNoCache(e.openStart+n),end:r.resolveNoCache(r.content.size-e.openEnd-n)}}(r,t),u=l.start,p=l.end;return b(a,function e(t,n,r,o,s){var a=t.depth>s&&v(t,n,s+1);var c=o.depth>s&&v(r,o,s+1);var l=[];y(null,t,s,l);a&&c&&n.index(s)==r.index(s)?(m(a,c),g(b(a,e(t,n,r,o,s+1)),l)):(a&&g(b(a,w(t,n,s+1)),l),y(n,r,s,l),c&&g(b(c,w(r,o,s+1)),l));y(o,null,s,l);return new i(l)}(t,u,p,n,o))}var f=t.parent,h=f.content;return b(f,h.cut(0,t.parentOffset).append(r.content).append(h.cut(n.parentOffset)))}return b(a,w(t,n,o))}(e,t,n,0)}function m(e,t){if(!t.type.compatibleContent(e.type))throw new p("Cannot join "+t.type.name+" onto "+e.type.name)}function v(e,t,n){var r=e.node(n);return m(r,t.node(n)),r}function g(e,t){var n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function y(e,t,n,r){var o=(t||e).node(n),i=0,s=t?t.index(n):o.childCount;e&&(i=e.index(n),e.depth>n?i++:e.textOffset&&(g(e.nodeAfter,r),i++));for(var a=i;an)&&g(b(v(e,t,n+1),w(e,t,n+1)),r);return y(t,null,n,r),new i(r)}h.size.get=function(){return this.content.size-this.openStart-this.openEnd},f.prototype.insertAt=function(e,t){var n=function e(t,n,r,o){var i=t.findIndex(n);var s=i.index;var a=i.offset;var c=t.maybeChild(s);if(a==n||c.isText)return o&&!o.canReplace(s,s,r)?null:t.cut(0,n).append(r).append(t.cut(n));var l=e(c.content,n-a-1,r);return l&&t.replaceChild(s,c.copy(l))}(this.content,e+this.openStart,t,null);return n&&new f(n,this.openStart,this.openEnd)},f.prototype.removeBetween=function(e,t){return new f(function e(t,n,r){var o=t.findIndex(n);var i=o.index;var s=o.offset;var a=t.maybeChild(i);var c=t.findIndex(r);var l=c.index;var u=c.offset;if(s==n||a.isText){if(u!=r&&!t.child(l).isText)throw new RangeError("Removing non-flat range");return t.cut(0,n).append(t.cut(r))}if(i!=l)throw new RangeError("Removing non-flat range");return t.replaceChild(i,a.copy(e(a.content,n-s-1,r-s-1)))}(this.content,e+this.openStart,t+this.openStart),this.openStart,this.openEnd)},f.prototype.eq=function(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd},f.prototype.toString=function(){return this.content+"("+this.openStart+","+this.openEnd+")"},f.prototype.toJSON=function(){if(!this.content.size)return null;var e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e},f.fromJSON=function(e,t){if(!t)return f.empty;var n=t.openStart||0,r=t.openEnd||0;if("number"!=typeof n||"number"!=typeof r)throw new RangeError("Invalid input for Slice.fromJSON");return new f(i.fromJSON(e,t.content),t.openStart||0,t.openEnd||0)},f.maxOpen=function(e,t){void 0===t&&(t=!0);for(var n=0,r=0,o=e.firstChild;o&&!o.isLeaf&&(t||!o.type.spec.isolating);o=o.firstChild)n++;for(var i=e.lastChild;i&&!i.isLeaf&&(t||!i.type.spec.isolating);i=i.lastChild)r++;return new f(e,n,r)},Object.defineProperties(f.prototype,h),f.empty=new f(i.empty,0,0);var k=function(e,t,n){this.pos=e,this.path=t,this.depth=t.length/3-1,this.parentOffset=n},x={parent:{},doc:{},textOffset:{},nodeAfter:{},nodeBefore:{}};k.prototype.resolveDepth=function(e){return null==e?this.depth:e<0?this.depth+e:e},x.parent.get=function(){return this.node(this.depth)},x.doc.get=function(){return this.node(0)},k.prototype.node=function(e){return this.path[3*this.resolveDepth(e)]},k.prototype.index=function(e){return this.path[3*this.resolveDepth(e)+1]},k.prototype.indexAfter=function(e){return e=this.resolveDepth(e),this.index(e)+(e!=this.depth||this.textOffset?1:0)},k.prototype.start=function(e){return 0==(e=this.resolveDepth(e))?0:this.path[3*e-1]+1},k.prototype.end=function(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size},k.prototype.before=function(e){if(!(e=this.resolveDepth(e)))throw new RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]},k.prototype.after=function(e){if(!(e=this.resolveDepth(e)))throw new RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[3*e-1]+this.path[3*e].nodeSize},x.textOffset.get=function(){return this.pos-this.path[this.path.length-1]},x.nodeAfter.get=function(){var e=this.parent,t=this.index(this.depth);if(t==e.childCount)return null;var n=this.pos-this.path[this.path.length-1],r=e.child(t);return n?e.child(t).cut(n):r},x.nodeBefore.get=function(){var e=this.index(this.depth),t=this.pos-this.path[this.path.length-1];return t?this.parent.child(e).cut(0,t):0==e?null:this.parent.child(e-1)},k.prototype.marks=function(){var e=this.parent,t=this.index();if(0==e.content.size)return u.none;if(this.textOffset)return e.child(t).marks;var n=e.maybeChild(t-1),r=e.maybeChild(t);if(!n){var o=n;n=r,r=o}for(var i=n.marks,s=0;s0;t--)if(this.start(t)<=e&&this.end(t)>=e)return t;return 0},k.prototype.blockRange=function(e,t){if(void 0===e&&(e=this),e.pos=0;n--)if(e.pos<=this.end(n)&&(!t||t(this.node(n))))return new O(this,e,n)},k.prototype.sameParent=function(e){return this.pos-this.parentOffset==e.pos-e.parentOffset},k.prototype.max=function(e){return e.pos>this.pos?e:this},k.prototype.min=function(e){return e.pos=0&&t<=e.content.size))throw new RangeError("Position "+t+" out of range");for(var n=[],r=0,o=t,i=e;;){var s=i.content.findIndex(o),a=s.index,c=s.offset,l=o-c;if(n.push(i,a,r+c),!l)break;if((i=i.child(a)).isText)break;o=l-1,r+=c+1}return new k(t,n,o)},k.resolveCached=function(e,t){for(var n=0;n<_.length;n++){var r=_[n];if(r.pos==t&&r.doc==e)return r}var o=_[C]=k.resolve(e,t);return C=(C+1)%S,o},Object.defineProperties(k.prototype,x);var _=[],C=0,S=12,O=function(e,t,n){this.$from=e,this.$to=t,this.depth=n},A={start:{},end:{},parent:{},startIndex:{},endIndex:{}};A.start.get=function(){return this.$from.before(this.depth+1)},A.end.get=function(){return this.$to.after(this.depth+1)},A.parent.get=function(){return this.$from.node(this.depth)},A.startIndex.get=function(){return this.$from.index(this.depth)},A.endIndex.get=function(){return this.$to.indexAfter(this.depth)},Object.defineProperties(O.prototype,A);var E=Object.create(null),M=function(e,t,n,r){this.type=e,this.attrs=t,this.content=n||i.empty,this.marks=r||u.none},T={nodeSize:{},childCount:{},textContent:{},firstChild:{},lastChild:{},isBlock:{},isTextblock:{},inlineContent:{},isInline:{},isText:{},isLeaf:{},isAtom:{}};T.nodeSize.get=function(){return this.isLeaf?1:2+this.content.size},T.childCount.get=function(){return this.content.childCount},M.prototype.child=function(e){return this.content.child(e)},M.prototype.maybeChild=function(e){return this.content.maybeChild(e)},M.prototype.forEach=function(e){this.content.forEach(e)},M.prototype.nodesBetween=function(e,t,n,r){void 0===r&&(r=0),this.content.nodesBetween(e,t,n,r,this)},M.prototype.descendants=function(e){this.nodesBetween(0,this.content.size,e)},T.textContent.get=function(){return this.textBetween(0,this.content.size,"")},M.prototype.textBetween=function(e,t,n,r){return this.content.textBetween(e,t,n,r)},T.firstChild.get=function(){return this.content.firstChild},T.lastChild.get=function(){return this.content.lastChild},M.prototype.eq=function(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)},M.prototype.sameMarkup=function(e){return this.hasMarkup(e.type,e.attrs,e.marks)},M.prototype.hasMarkup=function(e,t,n){return this.type==e&&l(this.attrs,t||e.defaultAttrs||E)&&u.sameSet(this.marks,n||u.none)},M.prototype.copy=function(e){return void 0===e&&(e=null),e==this.content?this:new this.constructor(this.type,this.attrs,e,this.marks)},M.prototype.mark=function(e){return e==this.marks?this:new this.constructor(this.type,this.attrs,this.content,e)},M.prototype.cut=function(e,t){return 0==e&&t==this.content.size?this:this.copy(this.content.cut(e,t))},M.prototype.slice=function(e,t,n){if(void 0===t&&(t=this.content.size),void 0===n&&(n=!1),e==t)return f.empty;var r=this.resolve(e),o=this.resolve(t),i=n?0:r.sharedDepth(t),s=r.start(i),a=r.node(i).content.cut(r.pos-s,o.pos-s);return new f(a,r.depth-i,o.depth-i)},M.prototype.replace=function(e,t,n){return d(this.resolve(e),this.resolve(t),n)},M.prototype.nodeAt=function(e){for(var t=this;;){var n=t.content.findIndex(e),r=n.index,o=n.offset;if(!(t=t.maybeChild(r)))return null;if(o==e||t.isText)return t;e-=o+1}},M.prototype.childAfter=function(e){var t=this.content.findIndex(e),n=t.index,r=t.offset;return{node:this.content.maybeChild(n),index:n,offset:r}},M.prototype.childBefore=function(e){if(0==e)return{node:null,index:0,offset:0};var t=this.content.findIndex(e),n=t.index,r=t.offset;if(re&&this.nodesBetween(e,t,function(e){return n.isInSet(e.marks)&&(r=!0),!r}),r},T.isBlock.get=function(){return this.type.isBlock},T.isTextblock.get=function(){return this.type.isTextblock},T.inlineContent.get=function(){return this.type.inlineContent},T.isInline.get=function(){return this.type.isInline},T.isText.get=function(){return this.type.isText},T.isLeaf.get=function(){return this.type.isLeaf},T.isAtom.get=function(){return this.type.isAtom},M.prototype.toString=function(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);var e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),N(this.marks,e)},M.prototype.contentMatchAt=function(e){var t=this.type.contentMatch.matchFragment(this.content,0,e);if(!t)throw new Error("Called contentMatchAt on a node with invalid content");return t},M.prototype.canReplace=function(e,t,n,r,o){void 0===n&&(n=i.empty),void 0===r&&(r=0),void 0===o&&(o=n.childCount);var s=this.contentMatchAt(e).matchFragment(n,r,o),a=s&&s.matchFragment(this.content,t);if(!a||!a.validEnd)return!1;for(var c=r;c=0;n--)t=e[n].type.name+"("+t+")";return t}var R=function(e){this.validEnd=e,this.next=[],this.wrapCache=[]},I={inlineContent:{},defaultType:{},edgeCount:{}};R.parse=function(e,t){var n=new P(e,t);if(null==n.next)return R.empty;var r=j(n);n.next&&n.err("Unexpected trailing text");var o=function(e){var t=Object.create(null);return function n(r){var o=[];r.forEach(function(t){e[t].forEach(function(t){var n=t.term,r=t.to;if(n){var i=o.indexOf(n),s=i>-1&&o[i+1];V(e,r).forEach(function(e){s||o.push(n,s=[]),-1==s.indexOf(e)&&s.push(e)})}})});var i=t[r.join(",")]=new R(r.indexOf(e.length-1)>-1);for(var s=0;s>1},R.prototype.edge=function(e){var t=e<<1;if(t>this.next.length)throw new RangeError("There's no "+e+"th edge in this content match");return{type:this.next[t],next:this.next[t+1]}},R.prototype.toString=function(){var e=[];return function t(n){e.push(n);for(var r=1;r"+e.indexOf(t.next[o+1]);return r}).join("\n")},Object.defineProperties(R.prototype,I),R.empty=new R(!0);var P=function(e,t){this.string=e,this.nodeTypes=t,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),""==this.tokens[this.tokens.length-1]&&this.tokens.pop(),""==this.tokens[0]&&this.tokens.unshift()},z={next:{}};function j(e){var t=[];do{t.push(F(e))}while(e.eat("|"));return 1==t.length?t[0]:{type:"choice",exprs:t}}function F(e){var t=[];do{t.push(L(e))}while(e.next&&")"!=e.next&&"|"!=e.next);return 1==t.length?t[0]:{type:"seq",exprs:t}}function L(e){for(var t=function(e){if(e.eat("(")){var t=j(e);return e.eat(")")||e.err("Missing closing paren"),t}if(!/\W/.test(e.next)){var n=function(e,t){var n=e.nodeTypes,r=n[t];if(r)return[r];var o=[];for(var i in n){var s=n[i];s.groups.indexOf(t)>-1&&o.push(s)}0==o.length&&e.err("No node type or group '"+t+"' found");return o}(e,e.next).map(function(t){return null==e.inline?e.inline=t.isInline:e.inline!=t.isInline&&e.err("Mixing inline and block content"),{type:"name",value:t}});return e.pos++,1==n.length?n[0]:{type:"choice",exprs:n}}e.err("Unexpected token '"+e.next+"'")}(e);;)if(e.eat("+"))t={type:"plus",expr:t};else if(e.eat("*"))t={type:"star",expr:t};else if(e.eat("?"))t={type:"opt",expr:t};else{if(!e.eat("{"))break;t=B(e,t)}return t}function $(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");var t=Number(e.next);return e.pos++,t}function B(e,t){var n=$(e),r=n;return e.eat(",")&&(r="}"!=e.next?$(e):-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:n,max:r,expr:t}}function q(e,t){return e-t}function V(e,t){var n=[];return function t(r){var o=e[r];if(1==o.length&&!o[0].term)return t(o[0].to);n.push(r);for(var i=0;i-1},J.prototype.allowsMarks=function(e){if(null==this.markSet)return!0;for(var t=0;t-1};var Y=function(e){for(var t in this.spec={},e)this.spec[t]=e[t];this.spec.nodes=o.from(e.nodes),this.spec.marks=o.from(e.marks),this.nodes=J.compile(this.spec.nodes,this),this.marks=X.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 i=this.nodes[r],s=i.spec.content||"",a=i.spec.marks;i.contentMatch=n[s]||(n[s]=R.parse(s,this.nodes)),i.inlineContent=i.contentMatch.inlineContent,i.markSet="_"==a?null:a?Q(this,a.split(" ")):""!=a&&i.inlineContent?null:[]}for(var c in this.marks){var l=this.marks[c],u=l.spec.excludes;l.excluded=null==u?[l]:""==u?[]:Q(this,u.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(e,t){for(var n=[],r=0;r-1)&&n.push(s=c)}if(!s)throw new SyntaxError("Unknown mark type: '"+t[r]+"'")}return n}Y.prototype.node=function(e,t,n,r){if("string"==typeof e)e=this.nodeType(e);else{if(!(e instanceof J))throw new RangeError("Invalid node type: "+e);if(e.schema!=this)throw new RangeError("Node type from different schema used ("+e.name+")")}return e.createChecked(t,n,r)},Y.prototype.text=function(e,t){var n=this.nodes.text;return new D(n,n.defaultAttrs,e,u.setFrom(t))},Y.prototype.mark=function(e,t){return"string"==typeof e&&(e=this.marks[e]),e.create(t)},Y.prototype.nodeFromJSON=function(e){return M.fromJSON(this,e)},Y.prototype.markFromJSON=function(e){return u.fromJSON(this,e)},Y.prototype.nodeType=function(e){var t=this.nodes[e];if(!t)throw new RangeError("Unknown node type: "+e);return t};var ee=function(e,t){var n=this;this.schema=e,this.rules=t,this.tags=[],this.styles=[],t.forEach(function(e){e.tag?n.tags.push(e):e.style&&n.styles.push(e)})};ee.prototype.parse=function(e,t){void 0===t&&(t={});var n=new ce(this,t,!1);return n.addAll(e,null,t.from,t.to),n.finish()},ee.prototype.parseSlice=function(e,t){void 0===t&&(t={});var n=new ce(this,t,!0);return n.addAll(e,null,t.from,t.to),f.maxOpen(n.finish())},ee.prototype.matchTag=function(e,t){for(var n=0;ne.length&&(61!=o.style.charCodeAt(e.length)||o.style.slice(e.length+1)!=t))){if(o.getAttrs){var i=o.getAttrs(t);if(!1===i)continue;o.attrs=i}return o}}},ee.schemaRules=function(e){var t=[];function n(e){for(var n=null==e.priority?50:e.priority,r=0;r=0;r--){var o=this.nodes[r],i=o.findWrapping(e);if(i&&(!t||t.length>i.length)&&(t=i,n=o,!i.length))break;if(o.solid)break}if(!t)return!1;this.sync(n);for(var s=0;sthis.open){for(;t>this.open;t--)this.nodes[t-1].content.push(this.nodes[t].finish(e));this.nodes.length=this.open+1}},ce.prototype.finish=function(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(this.isOpen||this.options.topOpen)},ce.prototype.sync=function(e){for(var t=this.open;t>=0;t--)if(this.nodes[t]==e)return void(this.open=t)},ce.prototype.addPendingMark=function(e){this.pendingMarks.push(e)},ce.prototype.removePendingMark=function(e){var t=this.pendingMarks.lastIndexOf(e);if(t>-1)this.pendingMarks.splice(t,1);else{var n=this.top;n.activeMarks=e.removeFromSet(n.activeMarks)}},le.currentPos.get=function(){this.closeExtra();for(var e=0,t=this.open;t>=0;t--){for(var n=this.nodes[t].content,r=n.length-1;r>=0;r--)e+=n[r].nodeSize;t&&e++}return e},ce.prototype.findAtPoint=function(e,t){if(this.find)for(var n=0;n-1)return e.split(/\s*\|\s*/).some(this.matchesContext,this);var n=e.split("/"),r=this.options.context,o=!(this.isOpen||r&&r.parent.type!=this.nodes[0].type),i=-(r?r.depth+1:0)+(o?0:1),s=function(e,a){for(;e>=0;e--){var c=n[e];if(""==c){if(e==n.length-1||0==e)continue;for(;a>=i;a--)if(s(e-1,a))return!0;return!1}var l=a>0||0==a&&o?t.nodes[a].type:r&&a>=i?r.node(a-i).type:null;if(!l||l.name!=c&&-1==l.groups.indexOf(c))return!1;a--}return!0};return s(n.length-1,this.open)},ce.prototype.textblockFromContext=function(){var e=this.options.context;if(e)for(var t=e.depth;t>=0;t--){var n=e.node(t).contentMatchAt(e.indexAfter(t)).defaultType;if(n&&n.isTextblock&&n.defaultAttrs)return n}for(var r in this.parser.schema.nodes){var o=this.parser.schema.nodes[r];if(o.isTextblock&&o.defaultAttrs)return o}},Object.defineProperties(ce.prototype,le);var fe=function(e,t){this.nodes=e||{},this.marks=t||{}};function he(e){var t={};for(var n in e){var r=e[n].spec.toDOM;r&&(t[n]=r)}return t}function de(e){return e.document||window.document}fe.prototype.serializeFragment=function(e,t,n){var r=this;void 0===t&&(t={}),n||(n=de(t).createDocumentFragment());var o=n,i=null;return e.forEach(function(e){if(i||e.marks.length){i||(i=[]);for(var n=0,s=0;n=0;r--){var o=this.serializeMark(e.marks[r],e.isInline,t);o&&((o.contentDOM||o.dom).appendChild(n),n=o.dom)}return n},fe.prototype.serializeMark=function(e,t,n){void 0===n&&(n={});var r=this.marks[e.type.name];return r&&fe.renderSpec(de(n),r(e,t))},fe.renderSpec=function(e,t){if("string"==typeof t)return{dom:e.createTextNode(t)};if(null!=t.nodeType)return{dom:t};var n=e.createElement(t[0]),r=null,o=t[1],i=1;if(o&&"object"==typeof o&&null==o.nodeType&&!Array.isArray(o))for(var s in i=2,o)null!=o[s]&&n.setAttribute(s,o[s]);for(var a=i;ai)throw new RangeError("Content hole must be the only child of its parent node");return{dom:n,contentDOM:n}}var l=fe.renderSpec(e,c),u=l.dom,p=l.contentDOM;if(n.appendChild(u),p){if(r)throw new RangeError("Multiple content holes");r=p}}return{dom:n,contentDOM:r}},fe.fromSchema=function(e){return e.cached.domSerializer||(e.cached.domSerializer=new fe(this.nodesFromSchema(e),this.marksFromSchema(e)))},fe.nodesFromSchema=function(e){var t=he(e.nodes);return t.text||(t.text=function(e){return e.text}),t},fe.marksFromSchema=function(e){return he(e.marks)},t.Node=M,t.ResolvedPos=k,t.NodeRange=O,t.Fragment=i,t.Slice=f,t.ReplaceError=p,t.Mark=u,t.Schema=Y,t.NodeType=J,t.MarkType=X,t.ContentMatch=R,t.DOMParser=ee,t.DOMSerializer=fe},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(43),o=65535,i=Math.pow(2,16);function s(e){return e&o}var a=function(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=null),this.pos=e,this.deleted=t,this.recover=n},c=function(e,t){void 0===t&&(t=!1),this.ranges=e,this.inverted=t};c.prototype.recover=function(e){var t=0,n=s(e);if(!this.inverted)for(var r=0;re)break;var u=this.ranges[c+o],p=this.ranges[c+s],f=l+u;if(e<=f){var h=l+r+((u?e==l?-1:e==f?1:t:t)<0?0:p);if(n)return h;var d=c/3+(e-l)*i;return new a(h,t<0?e!=l:e!=f,d)}r+=p-u}return n?e+r:new a(e+r)},c.prototype.touches=function(e,t){for(var n=0,r=s(t),o=this.inverted?2:1,i=this.inverted?1:2,a=0;ae)break;var l=this.ranges[a+o];if(e<=c+l&&a==3*r)return!0;n+=this.ranges[a+i]-l}return!1},c.prototype.forEach=function(e){for(var t=this.inverted?2:1,n=this.inverted?1:2,r=0,o=0;r=0;t--){var r=e.getMirror(t);this.appendMap(e.maps[t].invert(),null!=r&&r>t?n-r-1:null)}},l.prototype.invert=function(){var e=new l;return e.appendMappingInverted(this),e},l.prototype.map=function(e,t){if(void 0===t&&(t=1),this.mirror)return this._map(e,t,!0);for(var n=this.from;ni&&u0},p.prototype.addStep=function(e,t){this.docs.push(this.doc),this.steps.push(e),this.mapping.appendMap(e.getMap()),this.doc=t},Object.defineProperties(p.prototype,f);var d=Object.create(null),m=function(){};m.prototype.apply=function(e){return h()},m.prototype.getMap=function(){return c.empty},m.prototype.invert=function(e){return h()},m.prototype.map=function(e){return h()},m.prototype.merge=function(e){return null},m.prototype.toJSON=function(){return h()},m.fromJSON=function(e,t){if(!t||!t.stepType)throw new RangeError("Invalid input for Step.fromJSON");var n=d[t.stepType];if(!n)throw new RangeError("No step type "+t.stepType+" defined");return n.fromJSON(e,t)},m.jsonID=function(e,t){if(e in d)throw new RangeError("Duplicate use of step JSON ID "+e);return d[e]=t,t.prototype.jsonID=e,t};var v=function(e,t){this.doc=e,this.failed=t};v.ok=function(e){return new v(e,null)},v.fail=function(e){return new v(null,e)},v.fromReplace=function(e,t,n,o){try{return v.ok(e.replace(t,n,o))}catch(e){if(e instanceof r.ReplaceError)return v.fail(e.message);throw e}};var g=function(e){function t(t,n,r,o){e.call(this),this.from=t,this.to=n,this.slice=r,this.structure=!!o}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.apply=function(e){return this.structure&&b(e,this.from,this.to)?v.fail("Structure replace would overwrite content"):v.fromReplace(e,this.from,this.to,this.slice)},t.prototype.getMap=function(){return new c([this.from,this.to-this.from,this.slice.size])},t.prototype.invert=function(e){return new t(this.from,this.from+this.slice.size,e.slice(this.from,this.to))},t.prototype.map=function(e){var n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1);return n.deleted&&r.deleted?null:new t(n.pos,Math.max(n.pos,r.pos),this.slice)},t.prototype.merge=function(e){if(!(e instanceof t)||e.structure!=this.structure)return null;if(this.from+this.slice.size!=e.from||this.slice.openEnd||e.slice.openStart){if(e.to!=this.from||this.slice.openStart||e.slice.openEnd)return null;var n=this.slice.size+e.slice.size==0?r.Slice.empty:new r.Slice(e.slice.content.append(this.slice.content),e.slice.openStart,this.slice.openEnd);return new t(e.from,this.to,n,this.structure)}var o=this.slice.size+e.slice.size==0?r.Slice.empty:new r.Slice(this.slice.content.append(e.slice.content),this.slice.openStart,e.slice.openEnd);return new t(this.from,this.to+(e.to-e.from),o,this.structure)},t.prototype.toJSON=function(){var e={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e},t.fromJSON=function(e,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new t(n.from,n.to,r.Slice.fromJSON(e,n.slice),!!n.structure)},t}(m);m.jsonID("replace",g);var y=function(e){function t(t,n,r,o,i,s,a){e.call(this),this.from=t,this.to=n,this.gapFrom=r,this.gapTo=o,this.slice=i,this.insert=s,this.structure=!!a}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.apply=function(e){if(this.structure&&(b(e,this.from,this.gapFrom)||b(e,this.gapTo,this.to)))return v.fail("Structure gap-replace would overwrite content");var t=e.slice(this.gapFrom,this.gapTo);if(t.openStart||t.openEnd)return v.fail("Gap is not a flat range");var n=this.slice.insertAt(this.insert,t.content);return n?v.fromReplace(e,this.from,this.to,n):v.fail("Content does not fit in gap")},t.prototype.getMap=function(){return new c([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])},t.prototype.invert=function(e){var n=this.gapTo-this.gapFrom;return new t(this.from,this.from+this.slice.size+n,this.from+this.insert,this.from+this.insert+n,e.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)},t.prototype.map=function(e){var n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1),o=e.map(this.gapFrom,-1),i=e.map(this.gapTo,1);return n.deleted&&r.deleted||or.pos?null:new t(n.pos,r.pos,o,i,this.slice,this.insert,this.structure)},t.prototype.toJSON=function(){var e={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e},t.fromJSON=function(e,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 t(n.from,n.to,n.gapFrom,n.gapTo,r.Slice.fromJSON(e,n.slice),n.insert,!!n.structure)},t}(m);function b(e,t,n){for(var r=e.resolve(t),o=n-t,i=r.depth;o>0&&i>0&&r.indexAfter(i)==r.node(i).childCount;)i--,o--;if(o>0)for(var s=r.node(i).maybeChild(r.indexAfter(i));o>0;){if(!s||s.isLeaf)return!0;s=s.firstChild,o--}return!1}function w(e,t,n){return(0==t||e.canReplace(t,e.childCount))&&(n==e.childCount||e.canReplace(0,n))}function k(e){return{type:e,attrs:null}}function x(e,t){return e&&t&&!e.isLeaf&&e.canAppend(t)}function _(e,t,n){var r=e.resolve(t);if(r.parent.canReplaceWith(r.index(),r.index(),n))return t;if(0==r.parentOffset)for(var o=r.depth-1;o>=0;o--){var i=r.index(o);if(r.node(o).canReplaceWith(i,i,n))return r.before(o+1);if(i>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(at;f--)h||n.index(f)>0?(h=!0,u=r.Fragment.from(n.node(f).copy(u)),p++):c--;for(var d=r.Fragment.empty,m=0,v=i,g=!1;v>t;v--)g||o.after(v+1)=0;o--)n=r.Fragment.from(t[o].type.create(t[o].attrs,n));var i=e.start,s=e.end;return this.step(new y(i,s,i,s,new r.Slice(n,0,0),t.length,!0))},p.prototype.setBlockType=function(e,t,n,o){var i=this;if(void 0===t&&(t=e),!n.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");var s=this.steps.length;return this.doc.nodesBetween(e,t,function(e,t){if(e.isTextblock&&!e.hasMarkup(n,o)&&function(e,t,n){var r=e.resolve(t),o=r.index();return r.parent.canReplaceWith(o,o+1,n)}(i.doc,i.mapping.slice(s).map(t),n)){i.clearIncompatible(i.mapping.slice(s).map(t,1),n);var a=i.mapping.slice(s),c=a.map(t,1),l=a.map(t+e.nodeSize,1);return i.step(new y(c,l,c+1,l-1,new r.Slice(r.Fragment.from(n.create(o,null,e.marks)),0,0),1,!0)),!1}}),this},p.prototype.setNodeMarkup=function(e,t,n,o){var i=this.doc.nodeAt(e);if(!i)throw new RangeError("No node at given position");t||(t=i.type);var s=t.create(n,null,o||i.marks);if(i.isLeaf)return this.replaceWith(e,e+i.nodeSize,s);if(!t.validContent(i.content))throw new RangeError("Invalid content for node type "+t.name);return this.step(new y(e,e+i.nodeSize,e+1,e+i.nodeSize-1,new r.Slice(r.Fragment.from(s),0,0),1,!0))},p.prototype.split=function(e,t,n){void 0===t&&(t=1);for(var o=this.doc.resolve(e),i=r.Fragment.empty,s=r.Fragment.empty,a=o.depth,c=o.depth-t,l=t-1;a>c;a--,l--){i=r.Fragment.from(o.node(a).copy(i));var u=n&&n[l];s=r.Fragment.from(u?u.type.create(u.attrs,s):o.node(a).copy(s))}return this.step(new g(e,e,new r.Slice(i.append(s),t,t,!0)))},p.prototype.join=function(e,t){void 0===t&&(t=1);var n=new g(e-t,e+t,r.Slice.empty,!0);return this.step(n)};var S=function(e){function t(t,n,r){e.call(this),this.from=t,this.to=n,this.mark=r}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.apply=function(e){var t=this,n=e.slice(this.from,this.to),o=e.resolve(this.from),i=o.node(o.sharedDepth(this.to)),s=new r.Slice(C(n.content,function(e,n){return n.type.allowsMarkType(t.mark.type)?e.mark(t.mark.addToSet(e.marks)):e},i),n.openStart,n.openEnd);return v.fromReplace(e,this.from,this.to,s)},t.prototype.invert=function(){return new O(this.from,this.to,this.mark)},t.prototype.map=function(e){var n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1);return n.deleted&&r.deleted||n.pos>=r.pos?null:new t(n.pos,r.pos,this.mark)},t.prototype.merge=function(e){if(e instanceof t&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from)return new t(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark)},t.prototype.toJSON=function(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}},t.fromJSON=function(e,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new t(n.from,n.to,e.markFromJSON(n.mark))},t}(m);m.jsonID("addMark",S);var O=function(e){function t(t,n,r){e.call(this),this.from=t,this.to=n,this.mark=r}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.apply=function(e){var t=this,n=e.slice(this.from,this.to),o=new r.Slice(C(n.content,function(e){return e.mark(t.mark.removeFromSet(e.marks))}),n.openStart,n.openEnd);return v.fromReplace(e,this.from,this.to,o)},t.prototype.invert=function(){return new S(this.from,this.to,this.mark)},t.prototype.map=function(e){var n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1);return n.deleted&&r.deleted||n.pos>=r.pos?null:new t(n.pos,r.pos,this.mark)},t.prototype.merge=function(e){if(e instanceof t&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from)return new t(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark)},t.prototype.toJSON=function(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}},t.fromJSON=function(e,n){if("number"!=typeof n.from||"number"!=typeof n.to)throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new t(n.from,n.to,e.markFromJSON(n.mark))},t}(m);function A(e,t,n,o){if(void 0===n&&(n=t),void 0===o&&(o=r.Slice.empty),t==n&&!o.size)return null;var i=e.resolve(t),s=e.resolve(n);if(T(i,s,o))return new g(t,n,o);var a=function(e,t){var n=function e(t,n,o,i){var s=r.Fragment.empty,a=0,c=o[n];if(t.depth>n){var l=e(t,n+1,o,i||c);a=l.openEnd+1,s=r.Fragment.from(t.node(n+1).copy(l.content))}c&&(s=s.append(c.content),a=c.openEnd);i&&(s=s.append(t.node(n).contentMatchAt(t.indexAfter(n)).fillBefore(r.Fragment.empty,!0)),a=0);return{content:s,openEnd:a}}(e,0,t,!1),o=n.content,i=n.openEnd;return new r.Slice(o,e.depth,i||0)}(i,function(e,t){for(var n=new D(e),r=1;t.size&&r<=3;r++)t=n.placeSlice(t.content,t.openStart,t.openEnd,r);for(;n.open.length;)n.closeNode();return n.placed}(i,o)),c=M(i,s,a);if(!c)return null;if(a.size!=c.size&&function(e,t,n){if(!t.parent.isTextblock)return!1;var r,o=n.openEnd?function(e,t){for(var n=1;n1&&u==s.end(--l);)++u;var p=M(i,e.resolve(u),a);if(p)return new y(t,u,n,s.end(),p,a.size)}return c.size||t!=n?new g(t,n,c):null}function E(e,t,n,o,i,s,a){var c,l=e.childCount,u=l-(a>0?1:0),p=s<0?t:n.node(i);c=s<0?p.contentMatchAt(u):1==l&&a>0?p.contentMatchAt(s?n.index(i):n.indexAfter(i)):p.contentMatchAt(n.indexAfter(i)).matchFragment(e,l>0&&s?1:0,u);var f=o.node(i);if(a>0&&i0&&1==l&&(d=null),d){var m=E(e.lastChild.content,e.lastChild,n,o,i+1,1==l?s-1:-1,a-1);if(m){var v=e.lastChild.copy(m);return d.size?e.cutByIndex(0,l-1).append(d).addToEnd(v):e.replaceChild(l-1,v)}}}a>0&&(c=c.matchType((1==l&&s>0?n.node(i+1):e.lastChild).type));var g=o.index(i);if(g==f.childCount&&!f.type.compatibleContent(t.type))return null;for(var y=c.fillBefore(f.content,!0,g),b=g;y&&b0){var w=function e(t,n,o,i,s){var a,c=t.content,l=c.childCount;a=s>=0?o.node(i).contentMatchAt(o.indexAfter(i)).matchFragment(c,s>0?1:0,l):t.contentMatchAt(l);if(n>0){var u=e(c.lastChild,n-1,o,i+1,1==l?s-1:-1);c=c.replaceChild(l-1,u)}return t.copy(c.append(a.fillBefore(r.Fragment.empty,!0)))}(e.lastChild,a-1,n,i+1,1==l?s-1:-1);e=e.replaceChild(l-1,w)}return e=e.append(y),o.depth>i&&(e=e.addToEnd(function e(t,n){var r=t.node(n);var o=r.contentMatchAt(0).fillBefore(r.content,!0,t.index(n));t.depth>n&&(o=o.addToEnd(e(t,n+1)));return r.copy(o)}(o,i+1))),e}function M(e,t,n){var o=E(n.content,e.node(0),e,t,0,n.openStart,n.openEnd);return o?function(e,t,n){for(;t>0&&n>0&&1==e.childCount;)e=e.firstChild.content,t--,n--;return new r.Slice(e,t,n)}(o,n.openStart,t.depth):null}function T(e,t,n){return!n.openStart&&!n.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),n.content)}m.jsonID("removeMark",O),p.prototype.addMark=function(e,t,n){var r=this,o=[],i=[],s=null,a=null;return this.doc.nodesBetween(e,t,function(r,c,l){if(r.isInline){var u=r.marks;if(!n.isInSet(u)&&l.type.allowsMarkType(n.type)){for(var p=Math.max(c,e),f=Math.min(c+r.nodeSize,t),h=n.addToSet(u),d=0;d=0;h--)this.step(i[h]);return this},p.prototype.replace=function(e,t,n){void 0===t&&(t=e),void 0===n&&(n=r.Slice.empty);var o=A(this.doc,e,t,n);return o&&this.step(o),this},p.prototype.replaceWith=function(e,t,n){return this.replace(e,t,new r.Slice(r.Fragment.from(n),0,0))},p.prototype.delete=function(e,t){return this.replace(e,t,r.Slice.empty)},p.prototype.insert=function(e,t){return this.replaceWith(e,e,t)};var D=function(e){this.open=[];for(var t=0;t<=e.depth;t++){var n=e.node(t),o=n.contentMatchAt(e.indexAfter(t));this.open.push({parent:n,match:o,content:r.Fragment.empty,wrapper:!1,openEnd:0,depth:t})}this.placed=[]};function N(e,t,n){var r=e.content;if(t>1){var o=N(e.firstChild,t-1,1==e.childCount?n-1:0);r=e.content.replaceChild(0,o)}var i=e.type.contentMatch.fillBefore(r,0==n);return e.copy(i.append(r))}function R(e,t,n,r,o){if(tr&&(e=o.contentMatchAt(0).fillBefore(e,!0).append(e)),e}function I(e,t){for(var n=[],r=Math.min(e.depth,t.depth);r>=0;r--){var o=e.start(r);if(ot.pos+(t.depth-r)||e.node(r).type.spec.isolating||t.node(r).type.spec.isolating)break;o==t.start(r)&&n.push(r)}return n}D.prototype.placeSlice=function(e,t,n,o,i){if(t>0){var s=e.firstChild,a=this.placeSlice(s.content,Math.max(0,t-1),n&&1==e.childCount?n-1:0,o,s);a.content!=s.content&&(a.content.size?(e=e.replaceChild(0,s.copy(a.content)),t=a.openStart+1):(1==e.childCount&&(n=0),e=e.cutByIndex(1),t=0))}var c=this.placeContent(e,t,n,o,i);if(o>2&&c.size&&0==t){for(var l=0;l=0;u--){var p=this.open[u],f=void 0;if(o>1&&(f=p.match.findWrapping(a.type))&&(!i||!f.length||f[f.length-1]!=i.type)){for(;this.open.length-1>u;)this.closeNode();for(var h=0;hu;)this.closeNode();a=a.mark(p.parent.type.allowedMarks(a.marks)),t&&(a=N(a,t,l?n:0),t=0),this.addNode(p,a,l?n:0),p.match=d,l&&(n=0),c=!0;break}if(!c)break}return this.open.length>1&&(s>0&&s==e.childCount||i&&this.open[this.open.length-1].parent.type==i.type)&&this.closeNode(),new r.Slice(e.cutByIndex(s),t,n)},D.prototype.addNode=function(e,t,n){var o,i;e.content=(o=e.content,i=e.openEnd,i?o.replaceChild(o.childCount-1,function e(t,n){var o=t.content;if(n>1){var i=e(t.lastChild,n-1);o=t.content.replaceChild(t.childCount-1,i)}var s=t.contentMatchAt(t.childCount).fillBefore(r.Fragment.empty,!0);return t.copy(o.append(s))}(o.lastChild,i)):o).addToEnd(t),e.openEnd=n},D.prototype.closeNode=function(){var e=this.open.pop();0==e.content.size||(e.wrapper?this.addNode(this.open[this.open.length-1],e.parent.copy(e.content),e.openEnd+1):this.placed[e.depth]={depth:e.depth,content:e.content,openEnd:e.openEnd})},p.prototype.replaceRange=function(e,t,n){if(!n.size)return this.deleteRange(e,t);var o=this.doc.resolve(e),i=this.doc.resolve(t);if(T(o,i,n))return this.step(new g(e,t,n));var s=I(o,this.doc.resolve(t));0==s[s.length-1]&&s.pop();var a=-(o.depth+1);s.unshift(a);for(var c=o.depth,l=o.pos-1;c>0;c--,l--){var u=o.node(c).type.spec;if(u.defining||u.isolating)break;s.indexOf(c)>-1?a=c:o.before(c)==l&&s.splice(1,0,-c)}for(var p=s.indexOf(a),f=[],h=n.openStart,d=n.content,m=0;;m++){var v=d.firstChild;if(f.push(v),m==n.openStart)break;d=v.content}h>0&&f[h-1].type.spec.defining&&o.node(p).type!=f[h-1].type?h-=1:h>=2&&f[h-1].isTextblock&&f[h-2].type.spec.defining&&o.node(p).type!=f[h-2].type&&(h-=2);for(var y=n.openStart;y>=0;y--){var b=(y+h+1)%(n.openStart+1),w=f[b];if(w)for(var k=0;k0&&(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 c=1;c<=n.depth;c++)if(e-n.start(c)==n.depth-c&&t>n.end(c))return this.delete(n.before(c),t);return this.delete(e,t)},t.Transform=p,t.TransformError=u,t.Step=m,t.StepResult=v,t.joinPoint=function(e,t,n){void 0===n&&(n=-1);for(var r=e.resolve(t),o=r.depth;;o--){var i=void 0,s=void 0;if(o==r.depth?(i=r.nodeBefore,s=r.nodeAfter):n>0?(i=r.node(o+1),s=r.node(o).maybeChild(r.index(o)+1)):(i=r.node(o).maybeChild(r.index(o)-1),s=r.node(o+1)),i&&!i.isTextblock&&x(i,s))return t;if(0==o)break;t=n<0?r.before(o):r.after(o)}},t.canJoin=function(e,t){var n=e.resolve(t),r=n.index();return x(n.nodeBefore,n.nodeAfter)&&n.parent.canReplace(r,r+1)},t.canSplit=function(e,t,n,r){void 0===n&&(n=1);var o=e.resolve(t),i=o.depth-n,s=r&&r[r.length-1]||o.parent;if(i<0||o.parent.type.spec.isolating||!o.parent.canReplace(o.index(),o.parent.childCount)||!s.type.validContent(o.parent.content.cutByIndex(o.index(),o.parent.childCount)))return!1;for(var a=o.depth-1,c=n-2;a>i;a--,c--){var l=o.node(a),u=o.index(a);if(l.type.spec.isolating)return!1;var p=l.content.cutByIndex(u,l.childCount),f=r&&r[c]||l;if(f!=l&&(p=p.replaceChild(0,f.type.create(f.attrs))),!l.canReplace(u+1,l.childCount)||!f.type.validContent(p))return!1}var h=o.indexAfter(i),d=r&&r[0];return o.node(i).canReplaceWith(h,h,d?d.type:o.node(i+1).type)},t.insertPoint=_,t.dropPoint=function(e,t,n){var r=e.resolve(t);if(!n.content.size)return t;for(var o=n.content,i=0;i=0;a--){var c=a==r.depth?0:r.pos<=(r.start(a+1)+r.end(a+1))/2?-1:1,l=r.index(a)+(c>0?1:0);if(1==s?r.node(a).canReplace(l,l,o):r.node(a).contentMatchAt(l).findWrapping(o.firstChild.type))return 0==c?r.pos:c<0?r.before(a+1):r.after(a+1)}return null},t.liftTarget=function(e){for(var t=e.parent.content.cutByIndex(e.startIndex,e.endIndex),n=e.depth;;--n){var r=e.$from.node(n),o=e.$from.index(n),i=e.$to.indexAfter(n);if(n0&&(i=t[0].slice(s-a,s)+i,r=o)}return e.tr.insertText(i,r,o)}):t};var s=500;function a(e,t,n,r,o,i){if(e.composing)return!1;var a=e.state,c=a.doc.resolve(t);if(c.parent.type.spec.code)return!1;for(var l=c.parent.textBetween(Math.max(0,c.parentOffset-s),c.parentOffset,null,"")+r,u=0;u=0;c--)s.step(a.steps[c].invert(a.docs[c]));var l=s.doc.resolve(i.from).marks();t(s.replaceWith(i.from,i.to,e.schema.text(i.text,l)))}return!0}}return!1},t.emDash=c,t.ellipsis=l,t.openDoubleQuote=u,t.closeDoubleQuote=p,t.openSingleQuote=f,t.closeSingleQuote=h,t.smartQuotes=d,t.wrappingInputRule=function(e,t,n,r){return new i(e,function(e,i,s,a){var c=n instanceof Function?n(i):n,l=e.tr.delete(s,a),u=l.doc.resolve(s).blockRange(),p=u&&o.findWrapping(u,t,c);if(!p)return null;l.wrap(u,p);var f=l.doc.resolve(s-1).nodeBefore;return f&&f.type==t&&o.canJoin(l.doc,s-1)&&(!r||r(i,f))&&l.join(s-1),l})},t.textblockTypeInputRule=function(e,t,n){return new i(e,function(e,r,o,i){var s=e.doc.resolve(o),a=n instanceof Function?n(r):n;return s.node(-1).canReplaceWith(s.index(-1),s.indexAfter(-1),t)?e.tr.delete(o,i).setBlockType(o,o,t,a):null})}},function(e,t,n){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map(function(t){var n=function(e,t){var n=e[1]||"",r=e[3];if(!r)return n;if(t&&"function"==typeof btoa){var o=(s=r,a=btoa(unescape(encodeURIComponent(JSON.stringify(s)))),c="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(c," */")),i=r.sources.map(function(e){return"/*# sourceURL=".concat(r.sourceRoot).concat(e," */")});return[n].concat(i).concat([o]).join("\n")}var s,a,c;return[n].join("\n")}(t,e);return t[2]?"@media ".concat(t[2],"{").concat(n,"}"):n}).join("")},t.i=function(e,n){"string"==typeof e&&(e=[[null,e,""]]);for(var r={},o=0;on.parts.length&&(r.parts.length=n.parts.length)}else{var s=[];for(o=0;o2&&void 0!==arguments[2]?arguments[2]:{},r=Object(p.findSelectedNodeOfType)(t)(e.selection)||Object(p.findParentNode)(function(e){return e.type===t})(e.selection);return Object.keys(n).length&&r?r.node.hasMarkup(t,n):!!r}var m=n(15);n(42); /*! * tiptap v1.24.2 * (c) 2019 Scrumpy UG (limited liability) * @license MIT */ function v(e){return(v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function g(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function y(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(!e||!t)return!1;var n=e.parent.childAfter(e.parentOffset);if(!n.node)return!1;var r=n.node.marks.find(function(e){return e.type===t});if(!r)return!1;for(var o=e.index(),i=e.start()+n.offset,s=o+1,a=i+n.node.nodeSize;o>0&&r.isInSet(e.parent.child(o-1).marks);)o-=1,i-=e.parent.child(o).nodeSize;for(;s1?n-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:{};g(this,e),this.options=x({},this.defaultOptions,{},t)}return b(e,[{key:"init",value:function(){return null}},{key:"bindEditor",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.editor=e}},{key:"inputRules",value:function(){return[]}},{key:"pasteRules",value:function(){return[]}},{key:"keys",value:function(){return{}}},{key:"name",get:function(){return null}},{key:"type",get:function(){return"extension"}},{key:"update",get:function(){return function(){}}},{key:"defaultOptions",get:function(){return{}}},{key:"plugins",get:function(){return[]}}]),e}(),R=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1?arguments[1]:void 0;g(this,e),t.forEach(function(e){e.bindEditor(n),e.init()}),this.extensions=t}return b(e,[{key:"keymaps",value:function(e){var t=e.schema,n=this.extensions.filter(function(e){return["extension"].includes(e.type)}).filter(function(e){return e.keys}).map(function(e){return e.keys({schema:t})}),r=this.extensions.filter(function(e){return["node","mark"].includes(e.type)}).filter(function(e){return e.keys}).map(function(e){return e.keys({type:t["".concat(e.type,"s")][e.name],schema:t})});return[].concat(E(n),E(r)).map(function(e){return Object(c.keymap)(e)})}},{key:"inputRules",value:function(e){var t=e.schema,n=e.excludedExtensions;if(!(n instanceof Array)&&n)return[];var r=n instanceof Array?this.extensions.filter(function(e){return!n.includes(e.name)}):this.extensions,o=r.filter(function(e){return["extension"].includes(e.type)}).filter(function(e){return e.inputRules}).map(function(e){return e.inputRules({schema:t})}),i=r.filter(function(e){return["node","mark"].includes(e.type)}).filter(function(e){return e.inputRules}).map(function(e){return e.inputRules({type:t["".concat(e.type,"s")][e.name],schema:t})});return[].concat(E(o),E(i)).reduce(function(e,t){return[].concat(E(e),E(t))},[])}},{key:"pasteRules",value:function(e){var t=e.schema,n=e.excludedExtensions;if(!(n instanceof Array)&&n)return[];var r=n instanceof Array?this.extensions.filter(function(e){return!n.includes(e.name)}):this.extensions,o=r.filter(function(e){return["extension"].includes(e.type)}).filter(function(e){return e.pasteRules}).map(function(e){return e.pasteRules({schema:t})}),i=r.filter(function(e){return["node","mark"].includes(e.type)}).filter(function(e){return e.pasteRules}).map(function(e){return e.pasteRules({type:t["".concat(e.type,"s")][e.name],schema:t})});return[].concat(E(o),E(i)).reduce(function(e,t){return[].concat(E(e),E(t))},[])}},{key:"commands",value:function(e){var t=e.schema,n=e.view;return this.extensions.filter(function(e){return e.commands}).reduce(function(e,r){var o=r.name,i=r.type,s={},a=r.commands(x({schema:t},["node","mark"].includes(i)?{type:t["".concat(i,"s")][o]}:{})),c=function(e,t){return!!n.editable&&(n.focus(),e(t)(n.state,n.dispatch,n))},l=function(e,t){Array.isArray(t)?s[e]=function(e){return t.forEach(function(t){return c(t,e)})}:"function"==typeof t&&(s[e]=function(e){return c(t,e)})};return"object"===v(a)?Object.entries(a).forEach(function(e){var t=A(e,2),n=t[0],r=t[1];l(n,r)}):l(o,a),x({},e,{},s)},{})}},{key:"nodes",get:function(){return this.extensions.filter(function(e){return"node"===e.type}).reduce(function(e,t){return x({},e,w({},t.name,t.schema))},{})}},{key:"options",get:function(){var e=this.view;return this.extensions.reduce(function(t,n){return x({},t,w({},n.name,new Proxy(n.options,{set:function(t,r,o){var i=t[r]!==o;return Object.assign(t,w({},r,o)),i&&n.update(e),!0}})))},{})}},{key:"marks",get:function(){return this.extensions.filter(function(e){return"mark"===e.type}).reduce(function(e,t){return x({},e,w({},t.name,t.schema))},{})}},{key:"plugins",get:function(){return this.extensions.filter(function(e){return e.plugins}).reduce(function(e,t){var n=t.plugins;return[].concat(E(e),E(n))},[])}}]),e}();function I(e){var t=document.createElement("style");t.type="text/css",t.textContent=e;var n=document.head,r=n.firstChild;r?n.insertBefore(t,r):n.appendChild(t)}var P=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return g(this,t),O(this,C(t).call(this,e))}return _(t,N),b(t,[{key:"command",value:function(){return function(){}}},{key:"type",get:function(){return"mark"}},{key:"view",get:function(){return null}},{key:"schema",get:function(){return null}}]),t}();function z(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return Math.min(Math.max(parseInt(e,10),t),n)}var j=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return g(this,t),O(this,C(t).call(this,e))}return _(t,N),b(t,[{key:"command",value:function(){return function(){}}},{key:"type",get:function(){return"node"}},{key:"view",get:function(){return null}},{key:"schema",get:function(){return null}}]),t}(),F=function(e){function t(){return g(this,t),O(this,C(t).apply(this,arguments))}return _(t,j),b(t,[{key:"name",get:function(){return"doc"}},{key:"schema",get:function(){return{content:"block+"}}}]),t}(),L=function(e){function t(){return g(this,t),O(this,C(t).apply(this,arguments))}return _(t,j),b(t,[{key:"commands",value:function(e){var t=e.type;return function(){return Object(l.setBlockType)(t)}}},{key:"name",get:function(){return"paragraph"}},{key:"schema",get:function(){return{content:"inline*",group:"block",draggable:!1,parseDOM:[{tag:"p"}],toDOM:function(){return["p",0]}}}}]),t}(),$=function(e){function t(){return g(this,t),O(this,C(t).apply(this,arguments))}return _(t,j),b(t,[{key:"name",get:function(){return"text"}},{key:"schema",get:function(){return{group:"inline"}}}]),t}(),B='.ProseMirror {\n position: relative;\n}\n\n.ProseMirror {\n word-wrap: break-word;\n white-space: pre-wrap;\n -webkit-font-variant-ligatures: none;\n font-variant-ligatures: none;\n}\n\n.ProseMirror pre {\n white-space: pre-wrap;\n}\n\n.ProseMirror-gapcursor {\n display: none;\n pointer-events: none;\n position: absolute;\n}\n\n.ProseMirror-gapcursor:after {\n content: "";\n display: block;\n position: absolute;\n top: -2px;\n width: 20px;\n border-top: 1px solid black;\n animation: ProseMirror-cursor-blink 1.1s steps(2, start) infinite;\n}\n\n@keyframes ProseMirror-cursor-blink {\n to {\n visibility: hidden;\n }\n}\n\n.ProseMirror-hideselection *::selection {\n background: transparent;\n}\n\n.ProseMirror-hideselection *::-moz-selection {\n background: transparent;\n}\n\n.ProseMirror-hideselection * {\n caret-color: transparent;\n}\n\n.ProseMirror-focused .ProseMirror-gapcursor {\n display: block;\n}\n',q=function(e){function t(){var e,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return g(this,t),(e=O(this,C(t).call(this))).defaultOptions={editorProps:{},editable:!0,autoFocus:null,extensions:[],content:"",topNode:"doc",emptyDocument:{type:"doc",content:[{type:"paragraph"}]},useBuiltInExtensions:!0,disableInputRules:!1,disablePasteRules:!1,dropCursor:{},parseOptions:{},injectCSS:!0,onInit:function(){},onTransaction:function(){},onUpdate:function(){},onFocus:function(){},onBlur:function(){},onPaste:function(){},onDrop:function(){}},e.events=["init","transaction","update","focus","blur","paste","drop"],e.init(n),e}return _(t,D),b(t,[{key:"init",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.setOptions(x({},this.defaultOptions,{},t)),this.focused=!1,this.selection={from:0,to:0},this.element=document.createElement("div"),this.extensions=this.createExtensions(),this.nodes=this.createNodes(),this.marks=this.createMarks(),this.schema=this.createSchema(),this.plugins=this.createPlugins(),this.keymaps=this.createKeymaps(),this.inputRules=this.createInputRules(),this.pasteRules=this.createPasteRules(),this.view=this.createView(),this.commands=this.createCommands(),this.setActiveNodesAndMarks(),this.options.injectCSS&&I(B),null!==this.options.autoFocus&&this.focus(this.options.autoFocus),this.events.forEach(function(t){e.on(t,e.options[M("on ".concat(t))]||function(){})}),this.emit("init",{view:this.view,state:this.state}),this.extensions.view=this.view}},{key:"setOptions",value:function(e){this.options=x({},this.options,{},e),this.view&&this.state&&this.view.updateState(this.state)}},{key:"createExtensions",value:function(){return new R([].concat(E(this.builtInExtensions),E(this.options.extensions)),this)}},{key:"createPlugins",value:function(){return this.extensions.plugins}},{key:"createKeymaps",value:function(){return this.extensions.keymaps({schema:this.schema})}},{key:"createInputRules",value:function(){return this.extensions.inputRules({schema:this.schema,excludedExtensions:this.options.disableInputRules})}},{key:"createPasteRules",value:function(){return this.extensions.pasteRules({schema:this.schema,excludedExtensions:this.options.disablePasteRules})}},{key:"createCommands",value:function(){return this.extensions.commands({schema:this.schema,view:this.view})}},{key:"createNodes",value:function(){return this.extensions.nodes}},{key:"createMarks",value:function(){return this.extensions.marks}},{key:"createSchema",value:function(){return new i.Schema({topNode:this.options.topNode,nodes:this.nodes,marks:this.marks})}},{key:"createState",value:function(){var e=this;return r.EditorState.create({schema:this.schema,doc:this.createDocument(this.options.content),plugins:[].concat(E(this.plugins),[Object(u.inputRules)({rules:this.inputRules})],E(this.pasteRules),E(this.keymaps),[Object(c.keymap)({Backspace:u.undoInputRule}),Object(c.keymap)(l.baseKeymap),Object(s.dropCursor)(this.options.dropCursor),Object(a.gapCursor)(),new r.Plugin({key:new r.PluginKey("editable"),props:{editable:function(){return e.options.editable}}}),new r.Plugin({props:{attributes:{tabindex:0},handleDOMEvents:{focus:function(t,n){e.focused=!0,e.emit("focus",{event:n,state:t.state,view:t});var r=e.state.tr.setMeta("focused",!0);e.view.dispatch(r)},blur:function(t,n){e.focused=!1,e.emit("blur",{event:n,state:t.state,view:t});var r=e.state.tr.setMeta("focused",!1);e.view.dispatch(r)}}}}),new r.Plugin({props:this.options.editorProps})])})}},{key:"createDocument",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.parseOptions;if(null===e)return this.schema.nodeFromJSON(this.options.emptyDocument);if("object"===v(e))try{return this.schema.nodeFromJSON(e)}catch(t){return console.warn("[tiptap warn]: Invalid content.","Passed value:",e,"Error:",t),this.schema.nodeFromJSON(this.options.emptyDocument)}if("string"==typeof e){var n=document.createElement("div");return n.innerHTML=e.trim(),i.DOMParser.fromSchema(this.schema).parse(n,t)}return!1}},{key:"createView",value:function(){var e=this;return new o.EditorView(this.element,{state:this.createState(),handlePaste:function(){for(var t=arguments.length,n=new Array(t),r=0;r0&&void 0!==arguments[0]?arguments[0]:null;e&&this.view.setProps({nodeViews:this.initNodeViews({parent:e,extensions:[].concat(E(this.builtInExtensions),E(this.options.extensions))})})}},{key:"initNodeViews",value:function(e){var t=this,n=e.parent;return e.extensions.filter(function(e){return["node","mark"].includes(e.type)}).filter(function(e){return e.view}).reduce(function(e,r){return x({},e,w({},r.name,function(e,o,i,s){var a=r.view;return new T(a,{editor:t,extension:r,parent:n,node:e,view:o,getPos:i,decorations:s})}))},{})}},{key:"dispatchTransaction",value:function(e){var t=this.state.apply(e);this.view.updateState(t),this.selection={from:this.state.selection.from,to:this.state.selection.to},this.setActiveNodesAndMarks(),this.emit("transaction",{getHTML:this.getHTML.bind(this),getJSON:this.getJSON.bind(this),state:this.state,transaction:e}),e.docChanged&&!e.getMeta("preventUpdate")&&this.emitUpdate(e)}},{key:"emitUpdate",value:function(e){this.emit("update",{getHTML:this.getHTML.bind(this),getJSON:this.getJSON.bind(this),state:this.state,transaction:e})}},{key:"resolveSelection",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(this.selection&&null===e)return this.selection;if("start"===e||!0===e)return{from:0,to:0};if("end"===e){var t=this.state.doc;return{from:t.content.size,to:t.content.size}}return{from:e,to:e}}},{key:"focus",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(!(this.view.focused&&null===t||!1===t)){var n=this.resolveSelection(t),r=n.from,o=n.to;this.setSelection(r,o),setTimeout(function(){return e.view.focus()},10)}}},{key:"setSelection",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.state,o=n.doc,i=n.tr,s=z(e,0,o.content.size),a=z(t,0,o.content.size),c=r.TextSelection.create(o,s,a),l=i.setSelection(c);this.view.dispatch(l)}},{key:"blur",value:function(){this.view.dom.blur()}},{key:"getSchemaJSON",value:function(){return JSON.parse(JSON.stringify({nodes:this.extensions.nodes,marks:this.extensions.marks}))}},{key:"getHTML",value:function(){var e=document.createElement("div"),t=i.DOMSerializer.fromSchema(this.schema).serializeFragment(this.state.doc.content);return e.appendChild(t),e.innerHTML}},{key:"getJSON",value:function(){return this.state.doc.toJSON()}},{key:"setContent",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2?arguments[2]:void 0,o=this.state,i=o.doc,s=o.tr,a=this.createDocument(e,n),c=r.TextSelection.create(i,0,i.content.size),l=s.setSelection(c).replaceSelectionWith(a,!1).setMeta("preventUpdate",!t);this.view.dispatch(l)}},{key:"clearContent",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.setContent(this.options.emptyDocument,e)}},{key:"setActiveNodesAndMarks",value:function(){var e=this;this.activeMarks=Object.entries(this.schema.marks).reduce(function(t,n){var r=A(n,2),o=r[0],i=r[1];return x({},t,w({},o,function(){arguments.length>0&&void 0!==arguments[0]&&arguments[0];return h(e.state,i)}))},{}),this.activeMarkAttrs=Object.entries(this.schema.marks).reduce(function(t,n){var r=A(n,2),o=r[0],i=r[1];return x({},t,w({},o,function(e,t){var n=e.selection,r=n.from,o=n.to,i=[];e.doc.nodesBetween(r,o,function(e){i=[].concat(f(i),f(e.marks))});var s=i.find(function(e){return e.type.name===t.name});return s?s.attrs:{}}(e.state,i)))},{}),this.activeNodes=Object.entries(this.schema.nodes).reduce(function(t,n){var r=A(n,2),o=r[0],i=r[1];return x({},t,w({},o,function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return d(e.state,i,t)}))},{})}},{key:"getMarkAttrs",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return this.activeMarkAttrs[e]}},{key:"registerPlugin",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(e){var t=this.state.reconfigure({plugins:this.state.plugins.concat([e])});this.view.updateState(t)}}},{key:"unregisterPlugin",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;if(e&&this.view.docView){var t=this.state.reconfigure({plugins:this.state.plugins.filter(function(t){return!t.key.startsWith("".concat(e,"$"))})});this.view.updateState(t)}}},{key:"destroy",value:function(){this.view&&this.view.destroy()}},{key:"builtInExtensions",get:function(){return this.options.useBuiltInExtensions?[new F,new $,new L]:[]}},{key:"state",get:function(){return this.view?this.view.state:null}},{key:"isActive",get:function(){return Object.entries(x({},this.activeMarks,{},this.activeNodes)).reduce(function(e,t){var n=A(t,2),r=n[0],o=n[1];return x({},e,w({},r,function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return o(e)}))},{})}}]),t}(),V={props:{editor:{default:null,type:Object}},watch:{editor:{immediate:!0,handler:function(e){var t=this;e&&e.element&&this.$nextTick(function(){t.$el.appendChild(e.element.firstChild),e.setParentComponent(t)})}}},render:function(e){return e("div")},beforeDestroy:function(){this.editor.element=this.$el}},U=function(){function e(t){var n=t.options;g(this,e),this.options=n,this.options.element.addEventListener("mousedown",this.handleClick)}return b(e,[{key:"handleClick",value:function(e){e.preventDefault()}},{key:"destroy",value:function(){this.options.element.removeEventListener("mousedown",this.handleClick)}}]),e}();var H={props:{editor:{default:null,type:Object}},watch:{editor:{immediate:!0,handler:function(e){var t=this;e&&this.$nextTick(function(){var n;e.registerPlugin((n={editor:e,element:t.$el},new r.Plugin({key:new r.PluginKey("menu_bar"),view:function(e){return new U({editorView:e,options:n})}})))})}}},render:function(){return this.editor?this.$scopedSlots.default({focused:this.editor.view.focused,focus:this.editor.focus,commands:this.editor.commands,isActive:this.editor.isActive,getMarkAttrs:this.editor.getMarkAttrs.bind(this.editor)}):null}};function W(e,t,n){var r=document.createRange();return r.setEnd(e,null==n?e.nodeValue.length:n),r.setStart(e,t||0),r}function J(e,t){var n=e.getClientRects();return n.length?n[t<0?0:n.length-1]:e.getBoundingClientRect()}function G(e,t){var n,r,o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=e.docView.domFromPos(t),s=i.node,a=i.offset;if(3===s.nodeType)o&&a1&&void 0!==arguments[1]?arguments[1]:1;return function(n){var o=r.Selection.findFrom(n.doc.resolve(e),t,!0);return o?n.setSelection(o):n}},l=function(e){return e.type&&e.type.spec.selectable},u=function(e,t,n){return function(e){return l(e)&&e.type.isLeaf}(e)?n.setSelection(new r.NodeSelection(n.doc.resolve(t))):c(t)(n)},p=function(e,t,n){return function(r){var o="number"==typeof t,i=r.selection.$from,c=o?r.doc.resolve(t):f(r.selection)?r.doc.resolve(i.pos+1):i,p=c.parent;if(f(r.selection)&&n&&r!==(r=a(e)(r)))return r;if(w(p)&&r!==(r=s(p.type,e)(r))){var h=l(e)?c.before(c.depth):c.pos;return u(e,h,r)}if(b(c,e)){r.insert(c.pos,e);var m=o?c.pos:l(e)?r.selection.$anchor.pos-1:r.selection.$anchor.pos;return d(u(e,m,r))}for(var v=c.depth;v>0;v--){var g=c.after(v),y=r.doc.resolve(g);if(b(y,e))return r.insert(g,e),d(u(e,g,r))}return r}},f=function(e){return e instanceof r.NodeSelection},h=function(e,t){return Array.isArray(e)&&e.indexOf(t.type)>-1||t.type===e},d=function(e){return Object.assign(Object.create(e),e).setTime(Date.now())},m=function(e,t){return function(n){var r=n.doc.nodeAt(e),o=n.doc.resolve(e);if(v(o,t)){var i=(n=n.replaceWith(e,e+r.nodeSize,t)).selection.$from.pos-1;return n=c(Math.max(i,0),-1)(n),n=c(n.selection.$from.start())(n),d(n)}return n}},v=function(e,t){var n=e.node(e.depth);return n&&n.type.validContent(t instanceof o.Fragment?t:o.Fragment.from(t))},g=function(e){return function(t){var n=t.doc.nodeAt(e);return d(t.delete(e,e+n.nodeSize))}},y=function(e){if(e.cached.tableNodeTypes)return e.cached.tableNodeTypes;var t={};return Object.keys(e.nodes).forEach(function(n){var r=e.nodes[n];r.spec.tableRole&&(t[r.spec.tableRole]=r)}),e.cached.tableNodeTypes=t,t},b=function(e,t){var n=e.index();return t instanceof o.Fragment?e.parent.canReplace(n,n,t):t instanceof o.Node&&e.parent.canReplaceWith(n,n,t.type)},w=function(e){return!e||"paragraph"===e.type.name&&2===e.nodeSize},k=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;return t?e.createChecked(null,t):e.createAndFill()},x=function(e){return function(t){for(var n=i.TableMap.get(t.$anchorCell.node(-1)),r=t.$anchorCell.start(-1),o=n.cellsInRect(e),s=n.cellsInRect(n.rectBetween(t.$anchorCell.pos-r,t.$headCell.pos-r)),a=0,c=o.length;an[0]?-1:1,i=e.splice(t[0],t.length),s=i.length%2==0?1:0,a=void 0;return a=-1===r&&1===o?n[0]-1:1===r&&-1===o?n[n.length-1]-s+1:-1===o?n[0]:n[n.length-1]-s,e.splice.apply(e,[a,0].concat(i)),e},A=function(e,t,n,r){var o="Target position is invalid, you can't move the "+r+" "+e+" to "+t+", the target can't be split. You could use tryToFit option.";if(1===(e>t?-1:1)){if(-1!==n.slice(0,n.length-1).indexOf(t))throw new Error(o)}else if(-1!==n.slice(1).indexOf(t))throw new Error(o);return!0},E=function(e){return function(t){var n=t.$from;return M(n,e)}},M=function(e,t){for(var n=e.depth;n>0;n--){var r=e.node(n);if(t(r))return{pos:n>0?e.before(n):0,start:e.start(n),depth:n,node:r}}},T=function(e,t){return function(n){var r=E(e)(n);if(r)return I(r.pos,t)}},D=function(e){return function(t){return!!E(e)(t)}},N=function(e){return function(t){return E(function(t){return h(e,t)})(t)}},R=function(e){var t=e.$from.nodeBefore,n=r.Selection.findFrom(e.$from,-1);if(n&&t){var o=N(t.type)(n);return o?o.pos:n.$from.pos}},I=function(e,t){var n=t(e),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},P=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!e)throw new Error('Invalid "node" parameter');var n=[];return e.descendants(function(e,r){if(n.push({node:e,pos:r}),!t)return!1}),n},z=function(e,t,n){if(!e)throw new Error('Invalid "node" parameter');if(!t)throw new Error('Invalid "predicate" parameter');return P(e,n).filter(function(e){return t(e.node)})},j=function(e,t,n){return z(e,function(e){return e.type===t},n)};var F=function(e){return E(function(e){return e.type.spec.tableRole&&"table"===e.type.spec.tableRole})(e)},L=function(e){return e instanceof i.CellSelection},$=function(e){if(L(e)){var t=i.TableMap.get(e.$anchorCell.node(-1));return x({left:0,right:t.width,top:0,bottom:t.height})(e)}return!1},B=function(e){return function(t){var n=F(t);if(n){var r=i.TableMap.get(n.node);return(Array.isArray(e)?e:Array.from([e])).reduce(function(e,t){if(t>=0&&t<=r.width-1){var o=r.cellsInRect({left:t,right:t+1,top:0,bottom:r.height});return e.concat(o.map(function(e){var t=n.node.nodeAt(e),r=e+n.start;return{pos:r,start:r+1,node:t}}))}},[])}}},q=function(e){return function(t){var n=F(t);if(n){var r=i.TableMap.get(n.node);return(Array.isArray(e)?e:Array.from([e])).reduce(function(e,t){if(t>=0&&t<=r.height-1){var o=r.cellsInRect({left:0,right:r.width,top:t,bottom:t+1});return e.concat(o.map(function(e){var t=n.node.nodeAt(e),r=e+n.start;return{pos:r,start:r+1,node:t}}))}},[])}}},V=function(e){return function(t,n){return function(r){var o=F(r.selection),s="row"===e;if(o){var a=i.TableMap.get(o.node);if(t>=0&&t<(s?a.height:a.width)){var c=s?0:t,l=s?t:0,u=s?a.width:t+1,p=s?t+1:a.height;if(n){var f=X(r.selection.$from);if(!f)return r;var h=a.findCell(f.pos-o.start);s?(l=Math.min(l,h.top),p=Math.max(p,h.bottom)):(c=Math.min(c,h.left),u=Math.max(u,h.right))}var m=a.cellsInRect({left:c,top:l,right:s?u:c+1,bottom:s?l+1:p}),v=p-l==1?m:a.cellsInRect({left:s?c:u-1,top:s?p-1:l,right:u,bottom:p}),g=o.start+m[0],y=o.start+v[v.length-1],b=r.doc.resolve(g),w=r.doc.resolve(y);return d(r.setSelection(new i.CellSelection(w,b)))}}return r}}},U=V("column"),H=V("row"),W=function(e){return function(t){var n=F(t.selection);if(n){var r=i.TableMap.get(n.node);if(e>=0&&e<=r.height){for(var o=n.node,s=y(o.type.schema),a=n.start,c=0;c1&&n+o>e})(t);h.push.apply(h,function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t=0;m--)d(m);h.length&&h.forEach(function(e){t=Z(e,{rowspan:e.node.attrs.rowspan+1})(t)})}return p(s.row.create(l.attrs,u),a)(t)}}return t}},J=function(e){return function(t){var n=F(t.selection);if(n){var r=i.TableMap.get(n.node);if(0===e&&1===r.width)return K(t);if(e>=0&&e<=r.width)return i.removeColumn(t,{map:r,tableStart:n.start,table:n.node},e),d(t)}return t}},G=function(e){return function(t){var n=F(t.selection);if(n){var r=i.TableMap.get(n.node);if(0===e&&1===r.height)return K(t);if(e>=0&&e<=r.height)return i.removeRow(t,{map:r,tableStart:n.start,table:n.node},e),d(t)}return t}},K=function(e){for(var t=e.selection.$from,n=t.depth;n>0;n--){if("table"===t.node(n).type.spec.tableRole)return d(e.delete(t.before(n),t.after(n)))}return e},Z=function(e,t){return function(n){return e?(n.setNodeMarkup(e.pos,null,Object.assign({},e.node.attrs,t)),d(n)):n}},X=function(e){return M(e,function(e){return e.type.spec.tableRole&&/cell/i.test(e.type.spec.tableRole)})},Y=function(e){var t=X(e);if(t){var n=function(e){return M(e,function(e){return e.type.spec.tableRole&&/table/i.test(e.type.spec.tableRole)})}(e),r=i.TableMap.get(n.node),o=t.pos-n.start;return r.rectBetween(o,o)}},Q=function(e,t){return function(n){var r=[],o=q(e)(n.selection);if(o)for(var i=o.length-1;i>=0;i--)t(o[i],n)&&r.push(o[i]);return r}},ee=function(e){return function(t){for(var n=e,r=e,o=function(e){var o=B(e)(t.selection);o&&o.forEach(function(t){var o=t.node.attrs.colspan+e-1;o>=n&&(n=e),o>r&&(r=o)})},i=e;i>=0;i--)o(i);var s=function(e){var n=B(e)(t.selection);n&&n.forEach(function(t){var n=t.node.attrs.colspan+e-1;t.node.attrs.colspan>1&&n>r&&(r=n)})};for(i=e;i<=r;i++)s(i);var a=[];for(i=n;i<=r;i++){var c=B(i)(t.selection);c&&c.length&&a.push(i)}n=a[0],r=a[a.length-1];for(var l=B(n)(t.selection),u=q(0)(t.selection),p=t.doc.resolve(l[l.length-1].pos),f=void 0,h=r;h>=n;h--){var d=B(h)(t.selection);if(d&&d.length){for(var m=u.length-1;m>=0;m--)if(u[m].pos===d[0].pos){f=d[0];break}if(f)break}}return{$anchor:p,$head:t.doc.resolve(f.pos),indexes:a}}},te=function(e){return function(t){for(var n=e,r=e,o=function(e){q(e)(t.selection).forEach(function(t){var o=t.node.attrs.rowspan+e-1;o>=n&&(n=e),o>r&&(r=o)})},i=e;i>=0;i--)o(i);var s=function(e){q(e)(t.selection).forEach(function(t){var n=t.node.attrs.rowspan+e-1;t.node.attrs.rowspan>1&&n>r&&(r=n)})};for(i=e;i<=r;i++)s(i);var a=[];for(i=n;i<=r;i++){var c=q(i)(t.selection);c&&c.length&&a.push(i)}n=a[0],r=a[a.length-1];for(var l=q(n)(t.selection),u=B(0)(t.selection),p=t.doc.resolve(l[l.length-1].pos),f=void 0,h=r;h>=n;h--){var d=q(h)(t.selection);if(d&&d.length){for(var m=u.length-1;m>=0;m--)if(u[m].pos===d[0].pos){f=d[0];break}if(f)break}}return{$anchor:p,$head:t.doc.resolve(f.pos),indexes:a}}};t.isNodeSelection=f,t.canInsert=b,t.convertTableNodeToArrayOfRows=C,t.convertArrayOfRowsToTableNode=S,t.findParentNode=E,t.findParentNodeClosestToPos=M,t.findParentDomRef=T,t.hasParentNode=D,t.findParentNodeOfType=N,t.findParentNodeOfTypeClosestToPos=function(e,t){return M(e,function(e){return h(t,e)})},t.hasParentNodeOfType=function(e){return function(t){return D(function(t){return h(e,t)})(t)}},t.findParentDomRefOfType=function(e,t){return function(n){return T(function(t){return h(e,t)},t)(n)}},t.findSelectedNodeOfType=function(e){return function(t){if(f(t)){var n=t.node,r=t.$from;if(h(e,n))return{node:n,pos:r.pos,depth:r.depth}}}},t.findPositionOfNodeBefore=R,t.findDomRefAtPos=I,t.flatten=P,t.findChildren=z,t.findTextNodes=function(e,t){return z(e,function(e){return e.isText},t)},t.findInlineNodes=function(e,t){return z(e,function(e){return e.isInline},t)},t.findBlockNodes=function(e,t){return z(e,function(e){return e.isBlock},t)},t.findChildrenByAttr=function(e,t,n){return z(e,function(e){return!!t(e.attrs)},n)},t.findChildrenByType=j,t.findChildrenByMark=function(e,t,n){return z(e,function(e){return t.isInSet(e.marks)},n)},t.contains=function(e,t){return!!j(e,t).length},t.findTable=F,t.isCellSelection=L,t.getSelectionRect=function(e){if(L(e)){var t=e.$anchorCell.start(-1);return i.TableMap.get(e.$anchorCell.node(-1)).rectBetween(e.$anchorCell.pos-t,e.$headCell.pos-t)}},t.isColumnSelected=function(e){return function(t){if(L(t)){var n=i.TableMap.get(t.$anchorCell.node(-1));return x({left:e,right:e+1,top:0,bottom:n.height})(t)}return!1}},t.isRowSelected=function(e){return function(t){if(L(t)){var n=i.TableMap.get(t.$anchorCell.node(-1));return x({left:0,right:n.width,top:e,bottom:e+1})(t)}return!1}},t.isTableSelected=$,t.getCellsInColumn=B,t.getCellsInRow=q,t.getCellsInTable=function(e){var t=F(e);if(t){var n=i.TableMap.get(t.node);return n.cellsInRect({left:0,right:n.width,top:0,bottom:n.height}).map(function(e){var n=t.node.nodeAt(e),r=e+t.start;return{pos:r,start:r+1,node:n}})}},t.selectColumn=U,t.selectRow=H,t.selectTable=function(e){var t=F(e.selection);if(t){var n=i.TableMap.get(t.node).map;if(n&&n.length){var r=t.start+n[0],o=t.start+n[n.length-1],s=e.doc.resolve(r),a=e.doc.resolve(o);return d(e.setSelection(new i.CellSelection(a,s)))}}return e},t.emptyCell=function(e,t){return function(n){if(e){var r=y(t).cell.createAndFill().content;if(!e.node.content.eq(r))return n.replaceWith(e.pos+1,e.pos+e.node.nodeSize,r),d(n)}return n}},t.addColumnAt=function(e){return function(t){var n=F(t.selection);if(n){var r=i.TableMap.get(n.node);if(e>=0&&e<=r.width)return d(i.addColumn(t,{map:r,tableStart:n.start,table:n.node},e))}return t}},t.moveRow=function(e,t,n){return function(r){var o=Object.assign({tryToFit:!1,direction:0},n),i=F(r.selection);if(!i)return r;var s=te(e)(r).indexes,a=te(t)(r).indexes;if(s.indexOf(t)>-1)return r;!o.tryToFit&&a.length>1&&A(e,t,a,"row");var c=function(e,t,n,r){var o=C(e.node);return o=O(o,t,n,r),S(e.node,o)}(i,s,a,o.direction);return d(r).replaceWith(i.pos,i.pos+i.node.nodeSize,c)}},t.moveColumn=function(e,t,n){return function(r){var o=Object.assign({tryToFit:!1,direction:0},n),i=F(r.selection);if(!i)return r;var s=ee(e)(r).indexes,a=ee(t)(r).indexes;if(s.indexOf(t)>-1)return r;!o.tryToFit&&a.length>1&&A(e,t,a,"column");var c=function(e,t,n,r){var o=_(C(e.node));return o=O(o,t,n,r),o=_(o),S(e.node,o)}(i,s,a,o.direction);return d(r).replaceWith(i.pos,i.pos+i.node.nodeSize,c)}},t.addRowAt=function(e,t){return function(n){var r=F(n.selection);if(r){var o=i.TableMap.get(r.node),s=e-1;if(t&&s>=0)return d(W(s)(n));if(e>=0&&e<=o.height)return d(i.addRow(n,{map:o,tableStart:r.start,table:r.node},e))}return n}},t.cloneRowAt=W,t.removeColumnAt=J,t.removeRowAt=G,t.removeTable=K,t.removeSelectedColumns=function(e){var t=e.selection;if($(t))return K(e);if(L(t)){var n=F(t);if(n){var r=i.TableMap.get(n.node),o=r.rectBetween(t.$anchorCell.pos-n.start,t.$headCell.pos-n.start);if(0==o.left&&o.right==r.width)return!1;for(var s=Object.assign({},o,{map:r,table:n.node,tableStart:n.start}),a=s.right-1;i.removeColumn(e,s,a),a!==s.left;a--)s.table=s.tableStart?e.doc.nodeAt(s.tableStart-1):e.doc,s.map=i.TableMap.get(s.table);return d(e)}}return e},t.removeSelectedRows=function(e){var t=e.selection;if($(t))return K(e);if(L(t)){var n=F(t);if(n){var r=i.TableMap.get(n.node),o=r.rectBetween(t.$anchorCell.pos-n.start,t.$headCell.pos-n.start);if(0==o.top&&o.bottom==r.height)return!1;for(var s=Object.assign({},o,{map:r,table:n.node,tableStart:n.start}),a=s.bottom-1;i.removeRow(e,s,a),a!==s.top;a--)s.table=s.tableStart?e.doc.nodeAt(s.tableStart-1):e.doc,s.map=i.TableMap.get(s.table);return d(e)}}return e},t.removeColumnClosestToPos=function(e){return function(t){var n=Y(e);return n?J(n.left)(c(e.pos)(t)):t}},t.removeRowClosestToPos=function(e){return function(t){var n=Y(e);return n?G(n.top)(c(e.pos)(t)):t}},t.forEachCellInColumn=function(e,t,n){return function(o){var i=B(e)(o.selection);if(i){for(var s=i.length-1;s>=0;s--)o=t(i[s],o);if(n){var a=o.doc.resolve(o.mapping.map(i[i.length-1].pos));o.setSelection(r.Selection.near(a))}return d(o)}return o}},t.forEachCellInRow=function(e,t,n){return function(o){var i=q(e)(o.selection);if(i){for(var s=i.length-1;s>=0;s--)o=t(i[s],o);if(n){var a=o.doc.resolve(o.mapping.map(i[i.length-1].pos));o.setSelection(r.Selection.near(a))}}return o}},t.setCellAttrs=Z,t.createTable=function(e){for(var t=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],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,i=y(e),s=i.cell,a=i.header_cell,c=i.row,l=i.table,u=[],p=[],f=0;f=0){o=1;break}var s=n&&window.Promise?function(e){var t=!1;return function(){t||(t=!0,window.Promise.resolve().then(function(){t=!1,e()}))}}:function(e){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1,e()},o))}};function a(e){return e&&"[object Function]"==={}.toString.call(e)}function c(e,t){if(1!==e.nodeType)return[];var n=e.ownerDocument.defaultView.getComputedStyle(e,null);return t?n[t]:n}function l(e){return"HTML"===e.nodeName?e:e.parentNode||e.host}function u(e){if(!e)return document.body;switch(e.nodeName){case"HTML":case"BODY":return e.ownerDocument.body;case"#document":return e.body}var t=c(e),n=t.overflow,r=t.overflowX,o=t.overflowY;return/(auto|scroll|overlay)/.test(n+o+r)?e:u(l(e))}var p=n&&!(!window.MSInputMethodContext||!document.documentMode),f=n&&/MSIE 10/.test(navigator.userAgent);function h(e){return 11===e?p:10===e?f:p||f}function d(e){if(!e)return document.documentElement;for(var t=h(10)?document.body:null,n=e.offsetParent||null;n===t&&e.nextElementSibling;)n=(e=e.nextElementSibling).offsetParent;var r=n&&n.nodeName;return r&&"BODY"!==r&&"HTML"!==r?-1!==["TH","TD","TABLE"].indexOf(n.nodeName)&&"static"===c(n,"position")?d(n):n:e?e.ownerDocument.documentElement:document.documentElement}function m(e){return null!==e.parentNode?m(e.parentNode):e}function v(e,t){if(!(e&&e.nodeType&&t&&t.nodeType))return document.documentElement;var n=e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,r=n?e:t,o=n?t:e,i=document.createRange();i.setStart(r,0),i.setEnd(o,0);var s,a,c=i.commonAncestorContainer;if(e!==c&&t!==c||r.contains(o))return"BODY"===(a=(s=c).nodeName)||"HTML"!==a&&d(s.firstElementChild)!==s?d(c):c;var l=m(e);return l.host?v(l.host,t):v(e,m(t).host)}function g(e){var t="top"===(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"top")?"scrollTop":"scrollLeft",n=e.nodeName;if("BODY"===n||"HTML"===n){var r=e.ownerDocument.documentElement;return(e.ownerDocument.scrollingElement||r)[t]}return e[t]}function y(e,t){var n="x"===t?"Left":"Top",r="Left"===n?"Right":"Bottom";return parseFloat(e["border"+n+"Width"],10)+parseFloat(e["border"+r+"Width"],10)}function b(e,t,n,r){return Math.max(t["offset"+e],t["scroll"+e],n["client"+e],n["offset"+e],n["scroll"+e],h(10)?parseInt(n["offset"+e])+parseInt(r["margin"+("Height"===e?"Top":"Left")])+parseInt(r["margin"+("Height"===e?"Bottom":"Right")]):0)}function w(e){var t=e.body,n=e.documentElement,r=h(10)&&getComputedStyle(n);return{height:b("Height",t,n,r),width:b("Width",t,n,r)}}var k=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},x=function(){function e(e,t){for(var n=0;n2&&void 0!==arguments[2]&&arguments[2],r=h(10),o="HTML"===t.nodeName,i=O(e),s=O(t),a=u(e),l=c(t),p=parseFloat(l.borderTopWidth,10),f=parseFloat(l.borderLeftWidth,10);n&&o&&(s.top=Math.max(s.top,0),s.left=Math.max(s.left,0));var d=S({top:i.top-s.top-p,left:i.left-s.left-f,width:i.width,height:i.height});if(d.marginTop=0,d.marginLeft=0,!r&&o){var m=parseFloat(l.marginTop,10),v=parseFloat(l.marginLeft,10);d.top-=p-m,d.bottom-=p-m,d.left-=f-v,d.right-=f-v,d.marginTop=m,d.marginLeft=v}return(r&&!n?t.contains(a):t===a&&"BODY"!==a.nodeName)&&(d=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=g(t,"top"),o=g(t,"left"),i=n?-1:1;return e.top+=r*i,e.bottom+=r*i,e.left+=o*i,e.right+=o*i,e}(d,t)),d}function E(e){if(!e||!e.parentElement||h())return document.documentElement;for(var t=e.parentElement;t&&"none"===c(t,"transform");)t=t.parentElement;return t||document.documentElement}function M(e,t,n,r){var o=arguments.length>4&&void 0!==arguments[4]&&arguments[4],i={top:0,left:0},s=o?E(e):v(e,t);if("viewport"===r)i=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=e.ownerDocument.documentElement,r=A(e,n),o=Math.max(n.clientWidth,window.innerWidth||0),i=Math.max(n.clientHeight,window.innerHeight||0),s=t?0:g(n),a=t?0:g(n,"left");return S({top:s-r.top+r.marginTop,left:a-r.left+r.marginLeft,width:o,height:i})}(s,o);else{var a=void 0;"scrollParent"===r?"BODY"===(a=u(l(t))).nodeName&&(a=e.ownerDocument.documentElement):a="window"===r?e.ownerDocument.documentElement:r;var p=A(a,s,o);if("HTML"!==a.nodeName||function e(t){var n=t.nodeName;if("BODY"===n||"HTML"===n)return!1;if("fixed"===c(t,"position"))return!0;var r=l(t);return!!r&&e(r)}(s))i=p;else{var f=w(e.ownerDocument),h=f.height,d=f.width;i.top+=p.top-p.marginTop,i.bottom=h+p.top,i.left+=p.left-p.marginLeft,i.right=d+p.left}}var m="number"==typeof(n=n||0);return i.left+=m?n:n.left||0,i.top+=m?n:n.top||0,i.right-=m?n:n.right||0,i.bottom-=m?n:n.bottom||0,i}function T(e,t,n,r,o){var i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;if(-1===e.indexOf("auto"))return e;var s=M(n,r,i,o),a={top:{width:s.width,height:t.top-s.top},right:{width:s.right-t.right,height:s.height},bottom:{width:s.width,height:s.bottom-t.bottom},left:{width:t.left-s.left,height:s.height}},c=Object.keys(a).map(function(e){return C({key:e},a[e],{area:(t=a[e],t.width*t.height)});var t}).sort(function(e,t){return t.area-e.area}),l=c.filter(function(e){var t=e.width,r=e.height;return t>=n.clientWidth&&r>=n.clientHeight}),u=l.length>0?l[0].key:c[0].key,p=e.split("-")[1];return u+(p?"-"+p:"")}function D(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return A(n,r?E(t):v(t,n),r)}function N(e){var t=e.ownerDocument.defaultView.getComputedStyle(e),n=parseFloat(t.marginTop||0)+parseFloat(t.marginBottom||0),r=parseFloat(t.marginLeft||0)+parseFloat(t.marginRight||0);return{width:e.offsetWidth+r,height:e.offsetHeight+n}}function R(e){var t={left:"right",right:"left",bottom:"top",top:"bottom"};return e.replace(/left|right|bottom|top/g,function(e){return t[e]})}function I(e,t,n){n=n.split("-")[0];var r=N(e),o={width:r.width,height:r.height},i=-1!==["right","left"].indexOf(n),s=i?"top":"left",a=i?"left":"top",c=i?"height":"width",l=i?"width":"height";return o[s]=t[s]+t[c]/2-r[c]/2,o[a]=n===a?t[a]-r[l]:t[R(a)],o}function P(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function z(e,t,n){return(void 0===n?e:e.slice(0,function(e,t,n){if(Array.prototype.findIndex)return e.findIndex(function(e){return e[t]===n});var r=P(e,function(e){return e[t]===n});return e.indexOf(r)}(e,"name",n))).forEach(function(e){e.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var n=e.function||e.fn;e.enabled&&a(n)&&(t.offsets.popper=S(t.offsets.popper),t.offsets.reference=S(t.offsets.reference),t=n(t,e))}),t}function j(e,t){return e.some(function(e){var n=e.name;return e.enabled&&n===t})}function F(e){for(var t=[!1,"ms","Webkit","Moz","O"],n=e.charAt(0).toUpperCase()+e.slice(1),r=0;r1&&void 0!==arguments[1]&&arguments[1],n=H.indexOf(e),r=H.slice(n+1).concat(H.slice(0,n));return t?r.reverse():r}var J="flip",G="clockwise",K="counterclockwise",Z={placement:"bottom",positionFixed:!1,eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(e){var t=e.placement,n=t.split("-")[0],r=t.split("-")[1];if(r){var o=e.offsets,i=o.reference,s=o.popper,a=-1!==["bottom","top"].indexOf(n),c=a?"left":"top",l=a?"width":"height",u={start:_({},c,i[c]),end:_({},c,i[c]+i[l]-s[l])};e.offsets.popper=C({},s,u[r])}return e}},offset:{order:200,enabled:!0,fn:function(e,t){var n,r=t.offset,o=e.placement,i=e.offsets,s=i.popper,a=i.reference,c=o.split("-")[0];return n=$(+r)?[+r,0]:function(e,t,n,r){var o=[0,0],i=-1!==["right","left"].indexOf(r),s=e.split(/(\+|\-)/).map(function(e){return e.trim()}),a=s.indexOf(P(s,function(e){return-1!==e.search(/,|\s/)}));s[a]&&-1===s[a].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var c=/\s*,\s*|\s+/,l=-1!==a?[s.slice(0,a).concat([s[a].split(c)[0]]),[s[a].split(c)[1]].concat(s.slice(a+1))]:[s];return(l=l.map(function(e,r){var o=(1===r?!i:i)?"height":"width",s=!1;return e.reduce(function(e,t){return""===e[e.length-1]&&-1!==["+","-"].indexOf(t)?(e[e.length-1]=t,s=!0,e):s?(e[e.length-1]+=t,s=!1,e):e.concat(t)},[]).map(function(e){return function(e,t,n,r){var o=e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),i=+o[1],s=o[2];if(!i)return e;if(0===s.indexOf("%")){var a=void 0;switch(s){case"%p":a=n;break;case"%":case"%r":default:a=r}return S(a)[t]/100*i}return"vh"===s||"vw"===s?("vh"===s?Math.max(document.documentElement.clientHeight,window.innerHeight||0):Math.max(document.documentElement.clientWidth,window.innerWidth||0))/100*i:i}(e,o,t,n)})})).forEach(function(e,t){e.forEach(function(n,r){$(n)&&(o[t]+=n*("-"===e[r-1]?-1:1))})}),o}(r,s,a,c),"left"===c?(s.top+=n[0],s.left-=n[1]):"right"===c?(s.top+=n[0],s.left+=n[1]):"top"===c?(s.left+=n[0],s.top-=n[1]):"bottom"===c&&(s.left+=n[0],s.top+=n[1]),e.popper=s,e},offset:0},preventOverflow:{order:300,enabled:!0,fn:function(e,t){var n=t.boundariesElement||d(e.instance.popper);e.instance.reference===n&&(n=d(n));var r=F("transform"),o=e.instance.popper.style,i=o.top,s=o.left,a=o[r];o.top="",o.left="",o[r]="";var c=M(e.instance.popper,e.instance.reference,t.padding,n,e.positionFixed);o.top=i,o.left=s,o[r]=a,t.boundaries=c;var l=t.priority,u=e.offsets.popper,p={primary:function(e){var n=u[e];return u[e]c[e]&&!t.escapeWithReference&&(r=Math.min(u[n],c[e]-("right"===e?u.width:u.height))),_({},n,r)}};return l.forEach(function(e){var t=-1!==["left","top"].indexOf(e)?"primary":"secondary";u=C({},u,p[t](e))}),e.offsets.popper=u,e},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(e){var t=e.offsets,n=t.popper,r=t.reference,o=e.placement.split("-")[0],i=Math.floor,s=-1!==["top","bottom"].indexOf(o),a=s?"right":"bottom",c=s?"left":"top",l=s?"width":"height";return n[a]i(r[a])&&(e.offsets.popper[c]=i(r[a])),e}},arrow:{order:500,enabled:!0,fn:function(e,t){var n;if(!V(e.instance.modifiers,"arrow","keepTogether"))return e;var r=t.element;if("string"==typeof r){if(!(r=e.instance.popper.querySelector(r)))return e}else if(!e.instance.popper.contains(r))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),e;var o=e.placement.split("-")[0],i=e.offsets,s=i.popper,a=i.reference,l=-1!==["left","right"].indexOf(o),u=l?"height":"width",p=l?"Top":"Left",f=p.toLowerCase(),h=l?"left":"top",d=l?"bottom":"right",m=N(r)[u];a[d]-ms[d]&&(e.offsets.popper[f]+=a[f]+m-s[d]),e.offsets.popper=S(e.offsets.popper);var v=a[f]+a[u]/2-m/2,g=c(e.instance.popper),y=parseFloat(g["margin"+p],10),b=parseFloat(g["border"+p+"Width"],10),w=v-e.offsets.popper[f]-y-b;return w=Math.max(Math.min(s[u]-m,w),0),e.arrowElement=r,e.offsets.arrow=(_(n={},f,Math.round(w)),_(n,h,""),n),e},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(e,t){if(j(e.instance.modifiers,"inner"))return e;if(e.flipped&&e.placement===e.originalPlacement)return e;var n=M(e.instance.popper,e.instance.reference,t.padding,t.boundariesElement,e.positionFixed),r=e.placement.split("-")[0],o=R(r),i=e.placement.split("-")[1]||"",s=[];switch(t.behavior){case J:s=[r,o];break;case G:s=W(r);break;case K:s=W(r,!0);break;default:s=t.behavior}return s.forEach(function(a,c){if(r!==a||s.length===c+1)return e;r=e.placement.split("-")[0],o=R(r);var l=e.offsets.popper,u=e.offsets.reference,p=Math.floor,f="left"===r&&p(l.right)>p(u.left)||"right"===r&&p(l.left)p(u.top)||"bottom"===r&&p(l.top)p(n.right),m=p(l.top)p(n.bottom),g="left"===r&&h||"right"===r&&d||"top"===r&&m||"bottom"===r&&v,y=-1!==["top","bottom"].indexOf(r),b=!!t.flipVariations&&(y&&"start"===i&&h||y&&"end"===i&&d||!y&&"start"===i&&m||!y&&"end"===i&&v),w=!!t.flipVariationsByContent&&(y&&"start"===i&&d||y&&"end"===i&&h||!y&&"start"===i&&v||!y&&"end"===i&&m),k=b||w;(f||g||k)&&(e.flipped=!0,(f||g)&&(r=s[c+1]),k&&(i="end"===i?"start":"start"===i?"end":i),e.placement=r+(i?"-"+i:""),e.offsets.popper=C({},e.offsets.popper,I(e.instance.popper,e.offsets.reference,e.placement)),e=z(e.instance.modifiers,e,"flip"))}),e},behavior:"flip",padding:5,boundariesElement:"viewport",flipVariations:!1,flipVariationsByContent:!1},inner:{order:700,enabled:!1,fn:function(e){var t=e.placement,n=t.split("-")[0],r=e.offsets,o=r.popper,i=r.reference,s=-1!==["left","right"].indexOf(n),a=-1===["top","left"].indexOf(n);return o[s?"left":"top"]=i[n]-(a?o[s?"width":"height"]:0),e.placement=R(t),e.offsets.popper=S(o),e}},hide:{order:800,enabled:!0,fn:function(e){if(!V(e.instance.modifiers,"hide","preventOverflow"))return e;var t=e.offsets.reference,n=P(e.instance.modifiers,function(e){return"preventOverflow"===e.name}).boundaries;if(t.bottomn.right||t.top>n.bottom||t.right2&&void 0!==arguments[2]?arguments[2]:{};k(this,e),this.scheduleUpdate=function(){return requestAnimationFrame(r.update)},this.update=s(this.update.bind(this)),this.options=C({},e.Defaults,o),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=t&&t.jquery?t[0]:t,this.popper=n&&n.jquery?n[0]:n,this.options.modifiers={},Object.keys(C({},e.Defaults.modifiers,o.modifiers)).forEach(function(t){r.options.modifiers[t]=C({},e.Defaults.modifiers[t]||{},o.modifiers?o.modifiers[t]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(e){return C({name:e},r.options.modifiers[e])}).sort(function(e,t){return e.order-t.order}),this.modifiers.forEach(function(e){e.enabled&&a(e.onLoad)&&e.onLoad(r.reference,r.popper,r.options,e,r.state)}),this.update();var i=this.options.eventsEnabled;i&&this.enableEventListeners(),this.state.eventsEnabled=i}return x(e,[{key:"update",value:function(){return function(){if(!this.state.isDestroyed){var e={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};e.offsets.reference=D(this.state,this.popper,this.reference,this.options.positionFixed),e.placement=T(this.options.placement,e.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),e.originalPlacement=e.placement,e.positionFixed=this.options.positionFixed,e.offsets.popper=I(this.popper,e.offsets.reference,e.placement),e.offsets.popper.position=this.options.positionFixed?"fixed":"absolute",e=z(this.modifiers,e),this.state.isCreated?this.options.onUpdate(e):(this.state.isCreated=!0,this.options.onCreate(e))}}.call(this)}},{key:"destroy",value:function(){return function(){return this.state.isDestroyed=!0,j(this.modifiers,"applyStyle")&&(this.popper.removeAttribute("x-placement"),this.popper.style.position="",this.popper.style.top="",this.popper.style.left="",this.popper.style.right="",this.popper.style.bottom="",this.popper.style.willChange="",this.popper.style[F("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}.call(this)}},{key:"enableEventListeners",value:function(){return function(){this.state.eventsEnabled||(this.state=function(e,t,n,r){n.updateBound=r,L(e).addEventListener("resize",n.updateBound,{passive:!0});var o=u(e);return function e(t,n,r,o){var i="BODY"===t.nodeName,s=i?t.ownerDocument.defaultView:t;s.addEventListener(n,r,{passive:!0}),i||e(u(s.parentNode),n,r,o),o.push(s)}(o,"scroll",n.updateBound,n.scrollParents),n.scrollElement=o,n.eventsEnabled=!0,n}(this.reference,this.options,this.state,this.scheduleUpdate))}.call(this)}},{key:"disableEventListeners",value:function(){return function(){var e,t;this.state.eventsEnabled&&(cancelAnimationFrame(this.scheduleUpdate),this.state=(e=this.reference,t=this.state,L(e).removeEventListener("resize",t.updateBound),t.scrollParents.forEach(function(e){e.removeEventListener("scroll",t.updateBound)}),t.updateBound=null,t.scrollParents=[],t.scrollElement=null,t.eventsEnabled=!1,t))}.call(this)}}]),e}();X.Utils=("undefined"!=typeof window?window:e).PopperUtils,X.placements=U,X.Defaults=Z,t.a=X}).call(this,n(15))},2:function(e,t,n){"use strict";function r(e,t){for(var n=[],r={},o=0;on.parts.length&&(r.parts.length=n.parts.length)}else{var s=[];for(o=0;o0)return parseInt(e.substring(t+5,e.indexOf(".",t)),10);if(e.indexOf("Trident/")>0){var n=e.indexOf("rv:");return parseInt(e.substring(n+3,e.indexOf(".",n)),10)}var r=e.indexOf("Edge/");return r>0?parseInt(e.substring(r+5,e.indexOf(".",r)),10):-1}())})(),this.$nextTick(function(){e._w=e.$el.offsetWidth,e._h=e.$el.offsetHeight});var t=document.createElement("object");this._resizeObject=t,t.setAttribute("aria-hidden","true"),t.setAttribute("tabindex",-1),t.onload=this.addResizeHandlers,t.type="text/html",r&&this.$el.appendChild(t),t.data="about:blank",r||this.$el.appendChild(t)},beforeDestroy:function(){this.removeResizeHandlers()}},i={version:"0.4.5",install:function(e){e.component("resize-observer",o),e.component("ResizeObserver",o)}},s=null;"undefined"!=typeof window?s=window.Vue:void 0!==e&&(s=e.Vue),s&&s.use(i)}).call(this,n(15))},32:function(e,t,n){var r=n(33);"string"==typeof r&&(r=[[e.i,r,""]]),r.locals&&(e.exports=r.locals),(0,n(2).default)("cb7584ea",r,!0,{})},33:function(e,t,n){(e.exports=n(1)(!1)).push([e.i,"@charset \"UTF-8\";\n/**\n * @copyright Copyright (c) 2019 John Molakvoæ \n *\n * @author John Molakvoæ \n *\n * @license GNU AGPL version 3 or any later version\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see .\n *\n */\n/**\n* @copyright Copyright (c) 2016, John Molakvoæ \n* @copyright Copyright (c) 2016, Robin Appelman \n* @copyright Copyright (c) 2016, Jan-Christoph Borchardt \n* @copyright Copyright (c) 2016, Erik Pellikka \n* @copyright Copyright (c) 2015, Vincent Petry \n*\n* Bootstrap v3.3.5 (http://getbootstrap.com)\n* Copyright 2011-2015 Twitter, Inc.\n* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)\n*/\n.vue-tooltip[data-v-c9fcf01] {\n position: absolute;\n z-index: 100000;\n right: auto;\n left: auto;\n display: block;\n margin: 0;\n /* default to top */\n margin-top: -3px;\n padding: 10px 0;\n text-align: left;\n text-align: start;\n white-space: normal;\n text-decoration: none;\n letter-spacing: normal;\n word-spacing: normal;\n text-transform: none;\n word-wrap: normal;\n word-break: normal;\n opacity: 0;\n text-shadow: none;\n font-family: 'Nunito', 'Open Sans', Frutiger, Calibri, 'Myriad Pro', Myriad, sans-serif;\n font-size: 12px;\n font-weight: normal;\n font-style: normal;\n line-height: 1.6;\n line-break: auto;\n filter: drop-shadow(0 1px 10px var(--color-box-shadow)); }\n .vue-tooltip[data-v-c9fcf01][x-placement^='top'] .tooltip-arrow {\n bottom: 0;\n left: calc(50% - 10px) !important;\n margin-top: 0;\n margin-bottom: 0;\n border-width: 10px 10px 0 10px;\n border-right-color: transparent;\n border-bottom-color: transparent;\n border-left-color: transparent; }\n .vue-tooltip[data-v-c9fcf01][x-placement^='bottom'] .tooltip-arrow {\n top: 0;\n left: calc(50% - 10px) !important;\n margin-top: 0;\n margin-bottom: 0;\n border-width: 0 10px 10px 10px;\n border-top-color: transparent;\n border-right-color: transparent;\n border-left-color: transparent; }\n .vue-tooltip[data-v-c9fcf01][x-placement^='right'] .tooltip-arrow {\n top: calc(50% - 10px) !important;\n right: 100%;\n margin-right: 0;\n margin-left: 0;\n border-width: 10px 10px 10px 0;\n border-top-color: transparent;\n border-bottom-color: transparent;\n border-left-color: transparent; }\n .vue-tooltip[data-v-c9fcf01][x-placement^='left'] .tooltip-arrow {\n top: calc(50% - 10px) !important;\n left: 100%;\n margin-right: 0;\n margin-left: 0;\n border-width: 10px 0 10px 10px;\n border-top-color: transparent;\n border-right-color: transparent;\n border-bottom-color: transparent; }\n .vue-tooltip[data-v-c9fcf01][aria-hidden='true'] {\n visibility: hidden;\n transition: opacity .15s, visibility .15s;\n opacity: 0; }\n .vue-tooltip[data-v-c9fcf01][aria-hidden='false'] {\n visibility: visible;\n transition: opacity .15s;\n opacity: 1; }\n .vue-tooltip[data-v-c9fcf01] .tooltip-inner {\n max-width: 350px;\n padding: 5px 8px;\n text-align: center;\n color: var(--color-main-text);\n border-radius: var(--border-radius);\n background-color: var(--color-main-background); }\n .vue-tooltip[data-v-c9fcf01] .tooltip-arrow {\n position: absolute;\n z-index: 1;\n width: 0;\n height: 0;\n margin: 0;\n border-style: solid;\n border-color: var(--color-main-background); }\n",""])},5:function(e,t,n){"use strict";(function(e){n.d(t,"a",function(){return Dt});var r=n(16),o=n(21);function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e,t){for(var n=0;n
',trigger:"hover focus",offset:0},v=[],g=function(){function e(t,n){var r=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),a(this,"_events",[]),a(this,"_setTooltipNodeEvent",function(e,t,n,o){var i=e.relatedreference||e.toElement||e.relatedTarget;return!!r._tooltipNode.contains(i)&&(r._tooltipNode.addEventListener(e.type,function n(i){var s=i.relatedreference||i.toElement||i.relatedTarget;r._tooltipNode.removeEventListener(e.type,n),t.contains(s)||r._scheduleHide(t,o.delay,o,i)}),!0)}),n=c({},m,n),t.jquery&&(t=t[0]),this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.reference=t,this.options=n,this._isOpen=!1,this._init()}var t,n;return t=e,(n=[{key:"show",value:function(){this._show(this.reference,this.options)}},{key:"hide",value:function(){this._hide()}},{key:"dispose",value:function(){this._dispose()}},{key:"toggle",value:function(){return this._isOpen?this.hide():this.show()}},{key:"setClasses",value:function(e){this._classes=e}},{key:"setContent",value:function(e){this.options.title=e,this._tooltipNode&&this._setContent(e,this.options)}},{key:"setOptions",value:function(e){var t=!1,n=e&&e.classes||O.options.defaultClass;this._classes!==n&&(this.setClasses(n),t=!0),e=k(e);var r=!1,o=!1;for(var i in this.options.offset===e.offset&&this.options.placement===e.placement||(r=!0),(this.options.template!==e.template||this.options.trigger!==e.trigger||this.options.container!==e.container||t)&&(o=!0),e)this.options[i]=e[i];if(this._tooltipNode)if(o){var s=this._isOpen;this.dispose(),this._init(),s&&this.show()}else r&&this.popperInstance.update()}},{key:"_init",value:function(){var e="string"==typeof this.options.trigger?this.options.trigger.split(" "):[];this._isDisposed=!1,this._enableDocumentTouch=-1===e.indexOf("manual"),e=e.filter(function(e){return-1!==["click","hover","focus"].indexOf(e)}),this._setEventListeners(this.reference,e,this.options),this.$_originalTitle=this.reference.getAttribute("title"),this.reference.removeAttribute("title"),this.reference.setAttribute("data-original-title",this.$_originalTitle)}},{key:"_create",value:function(e,t){var n=window.document.createElement("div");n.innerHTML=t.trim();var r=n.childNodes[0];return r.id="tooltip_".concat(Math.random().toString(36).substr(2,10)),r.setAttribute("aria-hidden","true"),this.options.autoHide&&-1!==this.options.trigger.indexOf("hover")&&(r.addEventListener("mouseenter",this.hide),r.addEventListener("click",this.hide)),r}},{key:"_setContent",value:function(e,t){var n=this;this.asyncContent=!1,this._applyContent(e,t).then(function(){n.popperInstance.update()})}},{key:"_applyContent",value:function(e,t){var n=this;return new Promise(function(r,o){var i=t.html,s=n._tooltipNode;if(s){var a=s.querySelector(n.options.innerSelector);if(1===e.nodeType){if(i){for(;a.firstChild;)a.removeChild(a.firstChild);a.appendChild(e)}}else{if("function"==typeof e){var c=e();return void(c&&"function"==typeof c.then?(n.asyncContent=!0,t.loadingClass&&p(s,t.loadingClass),t.loadingContent&&n._applyContent(t.loadingContent,t),c.then(function(e){return t.loadingClass&&f(s,t.loadingClass),n._applyContent(e,t)}).then(r).catch(o)):n._applyContent(c,t).then(r).catch(o))}i?a.innerHTML=e:a.innerText=e}r()}})}},{key:"_show",value:function(e,t){if(!t||"string"!=typeof t.container||document.querySelector(t.container)){clearTimeout(this._disposeTimer),delete(t=Object.assign({},t)).offset;var n=!0;this._tooltipNode&&(p(this._tooltipNode,this._classes),n=!1);var r=this._ensureShown(e,t);return n&&this._tooltipNode&&p(this._tooltipNode,this._classes),p(e,["v-tooltip-open"]),r}}},{key:"_ensureShown",value:function(e,t){var n=this;if(this._isOpen)return this;if(this._isOpen=!0,v.push(this),this._tooltipNode)return this._tooltipNode.style.display="",this._tooltipNode.setAttribute("aria-hidden","false"),this.popperInstance.enableEventListeners(),this.popperInstance.update(),this.asyncContent&&this._setContent(t.title,t),this;var o=e.getAttribute("title")||t.title;if(!o)return this;var i=this._create(e,t.template);this._tooltipNode=i,e.setAttribute("aria-describedby",i.id);var s=this._findContainer(t.container,e);this._append(i,s);var a=c({},t.popperOptions,{placement:t.placement});return a.modifiers=c({},a.modifiers,{arrow:{element:this.options.arrowSelector}}),t.boundariesElement&&(a.modifiers.preventOverflow={boundariesElement:t.boundariesElement}),this.popperInstance=new r.a(e,i,a),this._setContent(o,t),requestAnimationFrame(function(){!n._isDisposed&&n.popperInstance?(n.popperInstance.update(),requestAnimationFrame(function(){n._isDisposed?n.dispose():n._isOpen&&i.setAttribute("aria-hidden","false")})):n.dispose()}),this}},{key:"_noLongerOpen",value:function(){var e=v.indexOf(this);-1!==e&&v.splice(e,1)}},{key:"_hide",value:function(){var e=this;if(!this._isOpen)return this;this._isOpen=!1,this._noLongerOpen(),this._tooltipNode.style.display="none",this._tooltipNode.setAttribute("aria-hidden","true"),this.popperInstance.disableEventListeners(),clearTimeout(this._disposeTimer);var t=O.options.disposeTimeout;return null!==t&&(this._disposeTimer=setTimeout(function(){e._tooltipNode&&(e._tooltipNode.removeEventListener("mouseenter",e.hide),e._tooltipNode.removeEventListener("click",e.hide),e._removeTooltipNode())},t)),f(this.reference,["v-tooltip-open"]),this}},{key:"_removeTooltipNode",value:function(){if(this._tooltipNode){var e=this._tooltipNode.parentNode;e&&(e.removeChild(this._tooltipNode),this.reference.removeAttribute("aria-describedby")),this._tooltipNode=null}}},{key:"_dispose",value:function(){var e=this;return this._isDisposed=!0,this.reference.removeAttribute("data-original-title"),this.$_originalTitle&&this.reference.setAttribute("title",this.$_originalTitle),this._events.forEach(function(t){var n=t.func,r=t.event;e.reference.removeEventListener(r,n)}),this._events=[],this._tooltipNode?(this._hide(),this._tooltipNode.removeEventListener("mouseenter",this.hide),this._tooltipNode.removeEventListener("click",this.hide),this.popperInstance.destroy(),this.popperInstance.options.removeOnDestroy||this._removeTooltipNode()):this._noLongerOpen(),this}},{key:"_findContainer",value:function(e,t){return"string"==typeof e?e=window.document.querySelector(e):!1===e&&(e=t.parentNode),e}},{key:"_append",value:function(e,t){t.appendChild(e)}},{key:"_setEventListeners",value:function(e,t,n){var r=this,o=[],i=[];t.forEach(function(e){switch(e){case"hover":o.push("mouseenter"),i.push("mouseleave"),r.options.hideOnTargetClick&&i.push("click");break;case"focus":o.push("focus"),i.push("blur"),r.options.hideOnTargetClick&&i.push("click");break;case"click":o.push("click"),i.push("click")}}),o.forEach(function(t){var o=function(t){!0!==r._isOpen&&(t.usedByTooltip=!0,r._scheduleShow(e,n.delay,n,t))};r._events.push({event:t,func:o}),e.addEventListener(t,o)}),i.forEach(function(t){var o=function(t){!0!==t.usedByTooltip&&r._scheduleHide(e,n.delay,n,t)};r._events.push({event:t,func:o}),e.addEventListener(t,o)})}},{key:"_onDocumentTouch",value:function(e){this._enableDocumentTouch&&this._scheduleHide(this.reference,this.options.delay,this.options,e)}},{key:"_scheduleShow",value:function(e,t,n){var r=this,o=t&&t.show||t||0;clearTimeout(this._scheduleTimer),this._scheduleTimer=window.setTimeout(function(){return r._show(e,n)},o)}},{key:"_scheduleHide",value:function(e,t,n,r){var o=this,i=t&&t.hide||t||0;clearTimeout(this._scheduleTimer),this._scheduleTimer=window.setTimeout(function(){if(!1!==o._isOpen&&document.body.contains(o._tooltipNode)){if("mouseleave"===r.type&&o._setTooltipNodeEvent(r,e,t,n))return;o._hide(e,n)}},i)}}])&&s(t.prototype,n),e}();"undefined"!=typeof document&&document.addEventListener("touchstart",function(e){for(var t=0;t
',defaultArrowSelector:".tooltip-arrow, .tooltip__arrow",defaultInnerSelector:".tooltip-inner, .tooltip__inner",defaultDelay:0,defaultTrigger:"hover focus",defaultOffset:0,defaultContainer:"body",defaultBoundariesElement:void 0,defaultPopperOptions:{},defaultLoadingClass:"tooltip-loading",defaultLoadingContent:"...",autoHide:!0,defaultHideOnTargetClick:!0,disposeTimeout:5e3,popover:{defaultPlacement:"bottom",defaultClass:"vue-popover-theme",defaultBaseClass:"tooltip popover",defaultWrapperClass:"wrapper",defaultInnerClass:"tooltip-inner popover-inner",defaultArrowClass:"tooltip-arrow popover-arrow",defaultOpenClass:"open",defaultDelay:0,defaultTrigger:"click",defaultOffset:0,defaultContainer:"body",defaultBoundariesElement:void 0,defaultPopperOptions:{},defaultAutoHide:!0,defaultHandleResize:!0}};function k(e){var t={placement:void 0!==e.placement?e.placement:O.options.defaultPlacement,delay:void 0!==e.delay?e.delay:O.options.defaultDelay,html:void 0!==e.html?e.html:O.options.defaultHtml,template:void 0!==e.template?e.template:O.options.defaultTemplate,arrowSelector:void 0!==e.arrowSelector?e.arrowSelector:O.options.defaultArrowSelector,innerSelector:void 0!==e.innerSelector?e.innerSelector:O.options.defaultInnerSelector,trigger:void 0!==e.trigger?e.trigger:O.options.defaultTrigger,offset:void 0!==e.offset?e.offset:O.options.defaultOffset,container:void 0!==e.container?e.container:O.options.defaultContainer,boundariesElement:void 0!==e.boundariesElement?e.boundariesElement:O.options.defaultBoundariesElement,autoHide:void 0!==e.autoHide?e.autoHide:O.options.autoHide,hideOnTargetClick:void 0!==e.hideOnTargetClick?e.hideOnTargetClick:O.options.defaultHideOnTargetClick,loadingClass:void 0!==e.loadingClass?e.loadingClass:O.options.defaultLoadingClass,loadingContent:void 0!==e.loadingContent?e.loadingContent:O.options.defaultLoadingContent,popperOptions:c({},void 0!==e.popperOptions?e.popperOptions:O.options.defaultPopperOptions)};if(t.offset){var n=i(t.offset),r=t.offset;("number"===n||"string"===n&&-1===r.indexOf(","))&&(r="0, ".concat(r)),t.popperOptions.modifiers||(t.popperOptions.modifiers={}),t.popperOptions.modifiers.offset={offset:r}}return t.trigger&&-1!==t.trigger.indexOf("click")&&(t.hideOnTargetClick=!1),t}function x(e,t){for(var n=e.placement,r=0;r2&&void 0!==arguments[2]?arguments[2]:{},r=_(t),o=void 0!==t.classes?t.classes:O.options.defaultClass,i=c({title:r},k(c({},t,{placement:x(t,n)}))),s=e._tooltip=new g(e,i);s.setClasses(o),s._vueEl=e;var a=void 0!==t.targetClasses?t.targetClasses:O.options.defaultTargetClass;return e._tooltipTargetClasses=a,p(e,a),s}(e,r,o),void 0!==r.show&&r.show!==e._tooltipOldShow&&(e._tooltipOldShow=r.show,r.show?n.show():n.hide())):C(e)}var O={options:w,bind:S,update:S,unbind:function(e){C(e)}};function A(e){e.addEventListener("click",M),e.addEventListener("touchstart",T,!!h&&{passive:!0})}function E(e){e.removeEventListener("click",M),e.removeEventListener("touchstart",T),e.removeEventListener("touchend",D),e.removeEventListener("touchcancel",N)}function M(e){var t=e.currentTarget;e.closePopover=!t.$_vclosepopover_touch,e.closeAllPopover=t.$_closePopoverModifiers&&!!t.$_closePopoverModifiers.all}function T(e){if(1===e.changedTouches.length){var t=e.currentTarget;t.$_vclosepopover_touch=!0;var n=e.changedTouches[0];t.$_vclosepopover_touchPoint=n,t.addEventListener("touchend",D),t.addEventListener("touchcancel",N)}}function D(e){var t=e.currentTarget;if(t.$_vclosepopover_touch=!1,1===e.changedTouches.length){var n=e.changedTouches[0],r=t.$_vclosepopover_touchPoint;e.closePopover=Math.abs(n.screenY-r.screenY)<20&&Math.abs(n.screenX-r.screenX)<20,e.closeAllPopover=t.$_closePopoverModifiers&&!!t.$_closePopoverModifiers.all}}function N(e){e.currentTarget.$_vclosepopover_touch=!1}var R={bind:function(e,t){var n=t.value,r=t.modifiers;e.$_closePopoverModifiers=r,(void 0===n||n)&&A(e)},update:function(e,t){var n=t.value,r=t.oldValue,o=t.modifiers;e.$_closePopoverModifiers=o,n!==r&&(void 0===n||n?A(e):E(e))},unbind:function(e){E(e)}};function I(e){var t=O.options.popover[e];return void 0===t?O.options[e]:t}var P=!1;"undefined"!=typeof window&&"undefined"!=typeof navigator&&(P=/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream);var z=[],j=function(){};"undefined"!=typeof window&&(j=window.Element);var F={name:"VPopover",components:{ResizeObserver:o.a},props:{open:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},placement:{type:String,default:function(){return I("defaultPlacement")}},delay:{type:[String,Number,Object],default:function(){return I("defaultDelay")}},offset:{type:[String,Number],default:function(){return I("defaultOffset")}},trigger:{type:String,default:function(){return I("defaultTrigger")}},container:{type:[String,Object,j,Boolean],default:function(){return I("defaultContainer")}},boundariesElement:{type:[String,j],default:function(){return I("defaultBoundariesElement")}},popperOptions:{type:Object,default:function(){return I("defaultPopperOptions")}},popoverClass:{type:[String,Array],default:function(){return I("defaultClass")}},popoverBaseClass:{type:[String,Array],default:function(){return O.options.popover.defaultBaseClass}},popoverInnerClass:{type:[String,Array],default:function(){return O.options.popover.defaultInnerClass}},popoverWrapperClass:{type:[String,Array],default:function(){return O.options.popover.defaultWrapperClass}},popoverArrowClass:{type:[String,Array],default:function(){return O.options.popover.defaultArrowClass}},autoHide:{type:Boolean,default:function(){return O.options.popover.defaultAutoHide}},handleResize:{type:Boolean,default:function(){return O.options.popover.defaultHandleResize}},openGroup:{type:String,default:null},openClass:{type:[String,Array],default:function(){return O.options.popover.defaultOpenClass}}},data:function(){return{isOpen:!1,id:Math.random().toString(36).substr(2,10)}},computed:{cssClass:function(){return a({},this.openClass,this.isOpen)},popoverId:function(){return"popover_".concat(this.id)}},watch:{open:function(e){e?this.show():this.hide()},disabled:function(e,t){e!==t&&(e?this.hide():this.open&&this.show())},container:function(e){if(this.isOpen&&this.popperInstance){var t=this.$refs.popover,n=this.$refs.trigger,r=this.$_findContainer(this.container,n);if(!r)return void console.warn("No container for popover",this);r.appendChild(t),this.popperInstance.scheduleUpdate()}},trigger:function(e){this.$_removeEventListeners(),this.$_addEventListeners()},placement:function(e){var t=this;this.$_updatePopper(function(){t.popperInstance.options.placement=e})},offset:"$_restartPopper",boundariesElement:"$_restartPopper",popperOptions:{handler:"$_restartPopper",deep:!0}},created:function(){this.$_isDisposed=!1,this.$_mounted=!1,this.$_events=[],this.$_preventOpen=!1},mounted:function(){var e=this.$refs.popover;e.parentNode&&e.parentNode.removeChild(e),this.$_init(),this.open&&this.show()},deactivated:function(){this.hide()},beforeDestroy:function(){this.dispose()},methods:{show:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.event,r=(t.skipDelay,t.force),o=void 0!==r&&r;!o&&this.disabled||(this.$_scheduleShow(n),this.$emit("show")),this.$emit("update:open",!0),this.$_beingShowed=!0,requestAnimationFrame(function(){e.$_beingShowed=!1})},hide:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.event;e.skipDelay,this.$_scheduleHide(t),this.$emit("hide"),this.$emit("update:open",!1)},dispose:function(){if(this.$_isDisposed=!0,this.$_removeEventListeners(),this.hide({skipDelay:!0}),this.popperInstance&&(this.popperInstance.destroy(),!this.popperInstance.options.removeOnDestroy)){var e=this.$refs.popover;e.parentNode&&e.parentNode.removeChild(e)}this.$_mounted=!1,this.popperInstance=null,this.isOpen=!1,this.$emit("dispose")},$_init:function(){-1===this.trigger.indexOf("manual")&&this.$_addEventListeners()},$_show:function(){var e=this,t=this.$refs.trigger,n=this.$refs.popover;if(clearTimeout(this.$_disposeTimer),!this.isOpen){if(this.popperInstance&&(this.isOpen=!0,this.popperInstance.enableEventListeners(),this.popperInstance.scheduleUpdate()),!this.$_mounted){var o=this.$_findContainer(this.container,t);if(!o)return void console.warn("No container for popover",this);o.appendChild(n),this.$_mounted=!0}if(!this.popperInstance){var i=c({},this.popperOptions,{placement:this.placement});if(i.modifiers=c({},i.modifiers,{arrow:c({},i.modifiers&&i.modifiers.arrow,{element:this.$refs.arrow})}),this.offset){var s=this.$_getOffset();i.modifiers.offset=c({},i.modifiers&&i.modifiers.offset,{offset:s})}this.boundariesElement&&(i.modifiers.preventOverflow=c({},i.modifiers&&i.modifiers.preventOverflow,{boundariesElement:this.boundariesElement})),this.popperInstance=new r.a(t,n,i),requestAnimationFrame(function(){if(e.hidden)return e.hidden=!1,void e.$_hide();!e.$_isDisposed&&e.popperInstance?(e.popperInstance.scheduleUpdate(),requestAnimationFrame(function(){if(e.hidden)return e.hidden=!1,void e.$_hide();e.$_isDisposed?e.dispose():e.isOpen=!0})):e.dispose()})}var a=this.openGroup;if(a)for(var l,u=0;u1&&void 0!==arguments[1]&&arguments[1];if(clearTimeout(this.$_scheduleTimer),e)this.$_show();else{var t=parseInt(this.delay&&this.delay.show||this.delay||0);this.$_scheduleTimer=setTimeout(this.$_show.bind(this),t)}},$_scheduleHide:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(clearTimeout(this.$_scheduleTimer),n)this.$_hide();else{var r=parseInt(this.delay&&this.delay.hide||this.delay||0);this.$_scheduleTimer=setTimeout(function(){if(e.isOpen){if(t&&"mouseleave"===t.type&&e.$_setTooltipNodeEvent(t))return;e.$_hide()}},r)}},$_setTooltipNodeEvent:function(e){var t=this,n=this.$refs.trigger,r=this.$refs.popover,o=e.relatedreference||e.toElement||e.relatedTarget;return!!r.contains(o)&&(r.addEventListener(e.type,function o(i){var s=i.relatedreference||i.toElement||i.relatedTarget;r.removeEventListener(e.type,o),n.contains(s)||t.hide({event:i})}),!0)},$_removeEventListeners:function(){var e=this.$refs.trigger;this.$_events.forEach(function(t){var n=t.func,r=t.event;e.removeEventListener(r,n)}),this.$_events=[]},$_updatePopper:function(e){this.popperInstance&&(e(),this.isOpen&&this.popperInstance.scheduleUpdate())},$_restartPopper:function(){if(this.popperInstance){var e=this.isOpen;this.dispose(),this.$_isDisposed=!1,this.$_init(),e&&this.show({skipDelay:!0,force:!0})}},$_handleGlobalClose:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.$_beingShowed||(this.hide({event:e}),e.closePopover?this.$emit("close-directive"):this.$emit("auto-hide"),n&&(this.$_preventOpen=!0,setTimeout(function(){t.$_preventOpen=!1},300)))},$_handleResize:function(){this.isOpen&&this.popperInstance&&(this.popperInstance.scheduleUpdate(),this.$emit("resize"))}}};function L(e){for(var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=function(n){var r=z[n];if(r.$refs.popover){var o=r.$refs.popover.contains(e.target);requestAnimationFrame(function(){(e.closeAllPopover||e.closePopover&&o||r.autoHide&&!o)&&r.$_handleGlobalClose(e,t)})}},r=0;r-1},W.prototype.set=function(e,t){var n=this.__data__,r=U(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};var J=W,G="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};function K(e,t){return e(t={exports:{}},t.exports),t.exports}var Z,X="object"==typeof G&&G&&G.Object===Object&&G,Y="object"==typeof self&&self&&self.Object===Object&&self,Q=X||Y||Function("return this")(),ee=Q.Symbol,te=Object.prototype,ne=te.hasOwnProperty,re=te.toString,oe=ee?ee.toStringTag:void 0,ie=Object.prototype.toString,se=ee?ee.toStringTag:void 0,ae=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":se&&se in Object(e)?function(e){var t=ne.call(e,oe),n=e[oe];try{e[oe]=void 0;var r=!0}catch(e){}var o=re.call(e);return r&&(t?e[oe]=n:delete e[oe]),o}(e):function(e){return ie.call(e)}(e)},ce=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},le=function(e){if(!ce(e))return!1;var t=ae(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},ue=Q["__core-js_shared__"],pe=(Z=/[^.]+$/.exec(ue&&ue.keys&&ue.keys.IE_PROTO||""))?"Symbol(src)_1."+Z:"",fe=Function.prototype.toString,he=/^\[object .+?Constructor\]$/,de=Function.prototype,me=Object.prototype,ve=de.toString,ge=me.hasOwnProperty,ye=RegExp("^"+ve.call(ge).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),be=function(e){return!(!ce(e)||function(e){return!!pe&&pe in e}(e))&&(le(e)?ye:he).test(function(e){if(null!=e){try{return fe.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))},we=function(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return be(n)?n:void 0},ke=we(Q,"Map"),xe=we(Object,"create"),_e=Object.prototype.hasOwnProperty,Ce=Object.prototype.hasOwnProperty;function Se(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e<=9007199254740991},Ye=function(e){return null!=e&&Xe(e.length)&&!le(e)},Qe=function(){return!1},et=K(function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,o=r&&r.exports===n?Q.Buffer:void 0,i=(o?o.isBuffer:void 0)||Qe;e.exports=i}),tt=Function.prototype,nt=Object.prototype,rt=tt.toString,ot=nt.hasOwnProperty,it=rt.call(Object),st={};st["[object Float32Array]"]=st["[object Float64Array]"]=st["[object Int8Array]"]=st["[object Int16Array]"]=st["[object Int32Array]"]=st["[object Uint8Array]"]=st["[object Uint8ClampedArray]"]=st["[object Uint16Array]"]=st["[object Uint32Array]"]=!0,st["[object Arguments]"]=st["[object Array]"]=st["[object ArrayBuffer]"]=st["[object Boolean]"]=st["[object DataView]"]=st["[object Date]"]=st["[object Error]"]=st["[object Function]"]=st["[object Map]"]=st["[object Number]"]=st["[object Object]"]=st["[object RegExp]"]=st["[object Set]"]=st["[object String]"]=st["[object WeakMap]"]=!1;var at=K(function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,o=r&&r.exports===n&&X.process,i=function(){try{return r&&r.require&&r.require("util").types||o&&o.binding&&o.binding("util")}catch(e){}}();e.exports=i}),ct=at&&at.isTypedArray,lt=ct?function(e){return function(t){return e(t)}}(ct):function(e){return Ue(e)&&Xe(e.length)&&!!st[ae(e)]},ut=function(e,t){if("__proto__"!=t)return e[t]},pt=Object.prototype.hasOwnProperty,ft=function(e,t,n){var r=e[t];pt.call(e,t)&&V(r,n)&&(void 0!==n||t in e)||Re(e,t,n)},ht=/^(?:0|[1-9]\d*)$/,dt=function(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&ht.test(e))&&e>-1&&e%1==0&&e0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(Ot),Mt=function(e,t){return Et(function(e,t,n){return t=Ct(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=Ct(r.length-t,0),s=Array(i);++o1?n[o-1]:void 0,s=o>2?n[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,s&&function(e,t,n){if(!ce(n))return!1;var r=typeof t;return!!("number"==r?Ye(n)&&dt(t,n.length):"string"==r&&t in n)&&V(n[t],e)}(n[0],n[1],s)&&(i=o<3?void 0:i,o=1),t=Object(t);++r1&&void 0!==arguments[1]?arguments[1]:{};if(!e.installed){e.installed=!0;var r={};Tt(r,w,n),Nt.options=r,O.options=r,t.directive("tooltip",O),t.directive("close-popover",R),t.component("v-popover",q)}},get enabled(){return y.enabled},set enabled(e){y.enabled=e}},Rt=null;"undefined"!=typeof window?Rt=window.Vue:void 0!==e&&(Rt=e.Vue),Rt&&Rt.use(Nt)}).call(this,n(15))},6:function(e,t,n){"use strict";n.r(t);var r=n(5);n(32), /** * @copyright Copyright (c) 2019 Julius Härtl * * @author Julius Härtl * @author John Molakvoæ * * @license GNU AGPL version 3 or any later version * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as * published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . * */ r.a.options.defaultTemplate=''),r.a.options.defaultHtml=!1,t.default=r.a}})},,function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(41),o=n(43),i=n(44),s={};if("undefined"!=typeof navigator&&"undefined"!=typeof document){var a=/Edge\/(\d+)/.exec(navigator.userAgent),c=/MSIE \d/.test(navigator.userAgent),l=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);s.mac=/Mac/.test(navigator.platform);var u=s.ie=!!(c||l||a);s.ie_version=c?document.documentMode||6:l?+l[1]:a?+a[1]:null,s.gecko=!u&&/gecko\/(\d+)/i.test(navigator.userAgent),s.gecko_version=s.gecko&&+(/Firefox\/(\d+)/.exec(navigator.userAgent)||[0,0])[1];var p=!u&&/Chrome\/(\d+)/.exec(navigator.userAgent);s.chrome=!!p,s.chrome_version=p&&+p[1],s.ios=!u&&/AppleWebKit/.test(navigator.userAgent)&&/Mobile\/\w+/.test(navigator.userAgent),s.android=/Android \d/.test(navigator.userAgent),s.webkit=!u&&"WebkitAppearance"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 f=function(e){for(var t=0;;t++)if(!(e=e.previousSibling))return t},h=function(e){var t=e.parentNode;return t&&11==t.nodeType?t.host:t},d=function(e,t,n){var r=document.createRange();return r.setEnd(e,null==n?e.nodeValue.length:n),r.setStart(e,t||0),r},m=function(e,t,n,r){return n&&(g(e,t,n,r,-1)||g(e,t,n,r,1))},v=/^(img|br|input|textarea|hr)$/i;function g(e,t,n,r,o){for(;;){if(e==n&&t==r)return!0;if(t==(o<0?0:y(e))){var i=e.parentNode;if(1!=i.nodeType||(s=void 0,(s=e.pmViewDesc)&&s.node&&s.node.isBlock)||v.test(e.nodeName)||"false"==e.contentEditable)return!1;t=f(e)+(o<0?0:1),e=i}else{if(1!=e.nodeType)return!1;e=e.childNodes[t+(o<0?-1:0)],t=o<0?y(e):0}}var s}function y(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}var b=function(e){var t=e.isCollapsed;return t&&s.chrome&&e.rangeCount&&!e.getRangeAt(0).collapsed&&(t=!1),t};function w(e,t){var n=document.createEvent("Event");return n.initEvent("keydown",!0,!0),n.keyCode=e,n.key=n.code=t,n}function k(e){return{left:0,right:e.innerWidth,top:0,bottom:e.innerHeight}}function x(e,t){return"number"==typeof e?e:e[t]}function _(e,t,n){for(var r=e.someProp("scrollThreshold")||0,o=e.someProp("scrollMargin")||5,i=e.dom.ownerDocument,s=i.defaultView,a=n||e.dom;a;a=h(a))if(1==a.nodeType){var c=a==i.body||1!=a.nodeType,l=c?k(s):a.getBoundingClientRect(),u=0,p=0;if(t.topl.bottom-x(r,"bottom")&&(p=t.bottom-l.bottom+x(o,"bottom")),t.leftl.right-x(r,"right")&&(u=t.right-l.right+x(o,"right")),(u||p)&&(c?s.scrollBy(u,p):(p&&(a.scrollTop+=p),u&&(a.scrollLeft+=u))),c)break}}function C(e,t){for(var n,r,o=2e8,i=0,s=t.top,a=t.top,c=e.firstChild,l=0;c;c=c.nextSibling,l++){var u=void 0;if(1==c.nodeType)u=c.getClientRects();else{if(3!=c.nodeType)continue;u=d(c).getClientRects()}for(var p=0;p=a){s=Math.max(f.bottom,s),a=Math.min(f.top,a);var h=f.left>t.left?f.left-t.left:f.right=(f.left+f.right)/2?1:0));continue}}!n&&(t.left>=f.right&&t.top>=f.top||t.left>=f.left&&t.top>=f.bottom)&&(i=l+1)}}return n&&3==n.nodeType?function(e,t){for(var n=e.nodeValue.length,r=document.createRange(),o=0;o=(i.left+i.right)/2?1:0)}}return{node:e,offset:0}}(n,r):!n||o&&1==n.nodeType?{node:e,offset:i}:C(n,r)}function S(e,t){return e.left>=t.left-1&&e.left<=t.right+1&&e.top>=t.top-1&&e.top<=t.bottom+1}function O(e,t){var n,r,o=e.root;if(o.caretPositionFromPoint){var i,s=o.caretPositionFromPoint(t.left,t.top);if(s)n=(i=s).offsetNode,r=i.offset}if(!n&&o.caretRangeFromPoint){var a,c=o.caretRangeFromPoint(t.left,t.top);if(c)n=(a=c).startContainer,r=a.startOffset}var l,u=o.elementFromPoint(t.left,t.top+1);if(!u||!e.dom.contains(1!=u.nodeType?u.parentNode:u)){var p=e.dom.getBoundingClientRect();if(!S(t,p))return null;if(!(u=function e(t,n,r){var o=t.childNodes.length;if(o&&r.topn.lastChild.getBoundingClientRect().bottom?l=e.state.doc.content.size:0!=r&&1==n.nodeType&&"BR"==n.childNodes[r-1].nodeName||(l=function(e,t,n,r){for(var o=-1,i=t;i!=e.dom;){var s=e.docView.nearestDesc(i,!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)o=s.posBefore;else{if(!(a.right-1?o:e.docView.posFromDOM(t,n)}(e,n,r,t))),null==l&&(l=function(e,t,n){var r=C(t,n),o=r.node,i=r.offset,s=-1;if(1==o.nodeType&&!o.firstChild){var a=o.getBoundingClientRect();s=a.left!=a.right&&n.left>(a.left+a.right)/2?1:-1}return e.docView.posFromDOM(o,i,s)}(e,u,t));var f=e.docView.nearestDesc(u,!0);return{pos:l,inside:f?f.posAtStart-f.border:-1}}function A(e,t){var n=e.getClientRects();return n.length?n[t<0?0:n.length-1]:e.getBoundingClientRect()}function E(e,t){var n=e.docView.domFromPos(t),r=n.node,o=n.offset;if(3==r.nodeType&&(s.chrome||s.gecko)){var i=A(d(r,o,o),0);if(s.gecko&&o&&/\s/.test(r.nodeValue[o-1])&&o0&&ol.top&&("up"==n?l.bottomi.bottom-1))return!1}}return!0})}(e,t,n):function(e,t,n){var r=t.selection.$head;if(!r.parent.isTextblock)return!1;var o=r.parentOffset,i=!o,s=o==r.parent.content.size,a=getSelection();return D.test(r.parent.textContent)&&a.modify?T(e,t,function(){var t=a.getRangeAt(0),o=a.focusNode,i=a.focusOffset,s=a.caretBidiLevel;a.modify("move",n,"character");var c=!(r.depth?e.docView.domAfterPos(r.before()):e.dom).contains(1==a.focusNode.nodeType?a.focusNode:a.focusNode.parentNode)||o==a.focusNode&&i==a.focusOffset;return a.removeAllRanges(),a.addRange(t),null!=s&&(a.caretBidiLevel=s),c}):"left"==n||"backward"==n?i:s}(e,t,n))}var z=function(e,t,n,r){this.parent=e,this.children=t,this.dom=n,n.pmViewDesc=this,this.contentDOM=r,this.dirty=0},j={beforePosition:{},size:{},border:{},posBefore:{},posAtStart:{},posAfter:{},posAtEnd:{},contentLost:{}};z.prototype.matchesWidget=function(){return!1},z.prototype.matchesMark=function(){return!1},z.prototype.matchesNode=function(){return!1},z.prototype.matchesHack=function(){return!1},j.beforePosition.get=function(){return!1},z.prototype.parseRule=function(){return null},z.prototype.stopEvent=function(){return!1},j.size.get=function(){for(var e=0,t=0;t0:r)?this.posAtEnd:this.posAtStart},z.prototype.nearestDesc=function(e,t){for(var n=!0,r=e;r;r=r.parentNode){var o=this.getDesc(r);if(o&&(!t||o.node)){if(!n||!o.nodeDOM||(1==o.nodeDOM.nodeType?o.nodeDOM.contains(e):o.nodeDOM==e))return o;n=!1}}},z.prototype.getDesc=function(e){for(var t=e.pmViewDesc,n=t;n;n=n.parent)if(n==this)return t},z.prototype.posFromDOM=function(e,t,n){for(var r=e;;r=r.parentNode){var o=this.getDesc(r);if(o)return o.localPosFromDOM(e,t,n)}},z.prototype.descAt=function(e){for(var t=0,n=0;t=l&&t<=c-a.border&&a.node&&a.contentDOM&&this.contentDOM.contains(a.contentDOM))return a.parseRange(e,t,l);e=i;for(var u=s;u>0;u--){var p=this.children[u-1];if(p.size&&p.dom.parentNode==this.contentDOM&&!p.emptyChildAt(1)){r=f(p.dom)+1;break}e-=p.size}-1==r&&(r=0)}if(r>-1&&t<=c){t=c;for(var h=s+1;ha&&it){var d=u;u=p,p=d}h.setEnd(p.node,p.offset),h.setStart(u.node,u.offset)}f.removeAllRanges(),f.addRange(h),f.extend&&f.extend(p.node,p.offset)}},z.prototype.ignoreMutation=function(e){return!this.contentDOM},j.contentLost.get=function(){return this.contentDOM&&this.contentDOM!=this.dom&&!this.dom.contains(this.contentDOM)},z.prototype.markDirty=function(e,t){for(var n=0,r=0;r=n:en){var s=n+o.border,a=i-o.border;if(e>=s&&t<=a)return this.dirty=e==n||t==i?2:1,void(e==s&&t==a&&o.contentLost?o.dirty=3:o.markDirty(e-s,t-s));o.dirty=3}n=i}this.dirty=2},z.prototype.markParentsDirty=function(){for(var e=this.parent;e;e=e.parent){e.dirty<2&&(e.dirty=2)}},Object.defineProperties(z.prototype,j);var F=[],L=function(e){function t(t,n,r,o){var i,s=n.type.toDOM;if("function"==typeof s&&(s=s(r,function(){return i?i.parent?i.parent.posBeforeChild(i):void 0:o})),!n.type.spec.raw){if(1!=s.nodeType){var a=document.createElement("span");a.appendChild(s),s=a}s.contentEditable=!1,s.classList.add("ProseMirror-widget")}e.call(this,t,F,s,null),this.widget=n,i=this}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={beforePosition:{}};return n.beforePosition.get=function(){return this.widget.type.side<0},t.prototype.matchesWidget=function(e){return 0==this.dirty&&e.type.eq(this.widget.type)},t.prototype.parseRule=function(){return{ignore:!0}},t.prototype.stopEvent=function(e){var t=this.widget.spec.stopEvent;return!!t&&t(e)},Object.defineProperties(t.prototype,n),t}(z),$=function(e){function t(t,n,r,o){e.call(this,t,F,n,null),this.textDOM=r,this.text=o}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={size:{}};return n.size.get=function(){return this.text.length},t.prototype.localPosFromDOM=function(e,t){return e!=this.textDOM?this.posAtStart+(t?this.size:0):this.posAtStart+t},t.prototype.domFromPos=function(e){return{node:this.textDOM,offset:e}},t.prototype.ignoreMutation=function(e){return"characterData"===e.type&&e.target.nodeValue==e.oldValue},Object.defineProperties(t.prototype,n),t}(z),B=function(e){function t(t,n,r,o){e.call(this,t,[],r,o),this.mark=n}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.create=function(e,n,r,i){var s=i.nodeViews[n.type.name],a=s&&s(n,i,r);return a&&a.dom||(a=o.DOMSerializer.renderSpec(document,n.type.spec.toDOM(n,r))),new t(e,n,a.dom,a.contentDOM||a.dom)},t.prototype.parseRule=function(){return{mark:this.mark.type.name,attrs:this.mark.attrs,contentElement:this.contentDOM}},t.prototype.matchesMark=function(e){return 3!=this.dirty&&this.mark.eq(e)},t.prototype.markDirty=function(t,n){if(e.prototype.markDirty.call(this,t,n),0!=this.dirty){for(var r=this.parent;!r.node;)r=r.parent;r.dirty0&&(i=re(i,0,e,r));for(var a=0;a=0&&a.syncToMarks(s==n.node.childCount?o.Mark.none:n.node.child(s).marks,r,e),a.placeWidget(t,e,i)},function(t,n,o,s){a.syncToMarks(t.marks,r,e),a.findNodeMatch(t,n,o,s)||a.updateNextNode(t,n,o,e,s)||a.addNode(t,n,o,e,i),i+=t.nodeSize}),a.syncToMarks(F,r,e),this.node.isTextblock&&a.addTextblockHacks(),a.destroyRest(),(a.changed||2==this.dirty)&&(s&&this.protectLocalComposition(e,s),this.renderChildren())},t.prototype.renderChildren=function(){!function e(t,n){var r=t.firstChild;for(var o=0;ot+this.node.content.size)){var s=e.root.getSelection(),a=function(e,t){for(;;){if(3==e.nodeType)return e;if(1==e.nodeType&&t>0){if(e.childNodes.length>t&&3==e.childNodes[t].nodeType)return e.childNodes[t];e=e.childNodes[t-1],t=y(e)}else{if(!(1==e.nodeType&&t=r){for(var l=c-o.length,u=o.lastIndexOf(t);u>-1&&l+u>n;)u=o.lastIndexOf(t,u-1);if(u>-1&&l+u+t.length>=r)return l+u;if(c>r)break}}else o="";s=c}return-1}(this.node.content,c,o-t,i-t);return l<0?null:{node:a,pos:l,text:c}}}},t.prototype.protectLocalComposition=function(e,t){var n=t.node,r=t.pos,o=t.text;if(!this.getDesc(n)){for(var i=n;i.parentNode!=this.contentDOM;i=i.parentNode){for(;i.previousSibling;)i.parentNode.removeChild(i.previousSibling);for(;i.nextSibling;)i.parentNode.removeChild(i.nextSibling);i.pmViewDesc&&(i.pmViewDesc=null)}var s=new $(this,i,n,o);e.compositionNodes.push(s),this.children=re(this.children,r,r+o.length,e,s)}},t.prototype.update=function(e,t,n,r){return!(3==this.dirty||!e.sameMarkup(this.node))&&(this.updateInner(e,t,n,r),!0)},t.prototype.updateInner=function(e,t,n,r){this.updateOuterDeco(t),this.node=e,this.innerDeco=n,this.contentDOM&&this.updateChildren(r,this.posAtStart),this.dirty=0},t.prototype.updateOuterDeco=function(e){if(!Q(e,this.outerDeco)){var t=1!=this.nodeDOM.nodeType,n=this.dom;this.dom=Z(this.dom,this.nodeDOM,K(this.outerDeco,this.node,t),K(e,this.node,t)),this.dom!=n&&(n.pmViewDesc=null,this.dom.pmViewDesc=this),this.outerDeco=e}},t.prototype.selectNode=function(){this.nodeDOM.classList.add("ProseMirror-selectednode"),!this.contentDOM&&this.node.type.spec.draggable||(this.dom.draggable=!0)},t.prototype.deselectNode=function(){this.nodeDOM.classList.remove("ProseMirror-selectednode"),!this.contentDOM&&this.node.type.spec.draggable||(this.dom.draggable=!1)},Object.defineProperties(t.prototype,n),t}(z);function V(e,t,n,r,o){return Y(r,t,e),new q(null,e,t,n,r,r,r,o,0)}var U=function(e){function t(t,n,r,o,i,s,a){e.call(this,t,n,r,o,i,null,s,a)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parseRule=function(){var e=this.nodeDOM.parentNode;return e?{skip:e}:{ignore:!0}},t.prototype.update=function(e,t){return!(3==this.dirty||0!=this.dirty&&!this.inParent()||!e.sameMarkup(this.node))&&(this.updateOuterDeco(t),0==this.dirty&&e.text==this.node.text||e.text==this.nodeDOM.nodeValue||(this.nodeDOM.nodeValue=e.text),this.node=e,this.dirty=0,!0)},t.prototype.inParent=function(){for(var e=this.parent.contentDOM,t=this.nodeDOM;t;t=t.parentNode)if(t==e)return!0;return!1},t.prototype.domFromPos=function(e){return{node:this.nodeDOM,offset:e}},t.prototype.localPosFromDOM=function(t,n,r){return t==this.nodeDOM?this.posAtStart+Math.min(n,this.node.text.length):e.prototype.localPosFromDOM.call(this,t,n,r)},t.prototype.ignoreMutation=function(e){return"characterData"!=e.type&&"selection"!=e.type},t.prototype.slice=function(e,n,r){var o=this.node.cut(e,n),i=document.createTextNode(o.text);return new t(this.parent,o,this.outerDeco,this.innerDeco,i,i,r)},t}(q),H=function(e){function t(){e.apply(this,arguments)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.parseRule=function(){return{ignore:!0}},t.prototype.matchesHack=function(){return 0==this.dirty},t}(z),W=function(e){function t(t,n,r,o,i,s,a,c,l,u){e.call(this,t,n,r,o,i,s,a,l,u),this.spec=c}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.update=function(t,n,r,o){if(3==this.dirty)return!1;if(this.spec.update){var i=this.spec.update(t,n);return i&&this.updateInner(t,n,r,o),i}return!(!this.contentDOM&&!t.isLeaf)&&e.prototype.update.call(this,t,n,r,o)},t.prototype.selectNode=function(){this.spec.selectNode?this.spec.selectNode():e.prototype.selectNode.call(this)},t.prototype.deselectNode=function(){this.spec.deselectNode?this.spec.deselectNode():e.prototype.deselectNode.call(this)},t.prototype.setSelection=function(t,n,r,o){this.spec.setSelection?this.spec.setSelection(t,n,r):e.prototype.setSelection.call(this,t,n,r,o)},t.prototype.destroy=function(){this.spec.destroy&&this.spec.destroy(),e.prototype.destroy.call(this)},t.prototype.stopEvent=function(e){return!!this.spec.stopEvent&&this.spec.stopEvent(e)},t.prototype.ignoreMutation=function(t){return this.spec.ignoreMutation?this.spec.ignoreMutation(t):e.prototype.ignoreMutation.call(this,t)},t}(q);function J(e){e&&(this.nodeName=e)}J.prototype=Object.create(null);var G=[new J];function K(e,t,n){if(0==e.length)return G;for(var r=n?G[0]:new J,o=[r],i=0;i0&&o>=0;o--){var i=t[o],s=i.node;if(s){if(s!=e.child(r-1))break;n.push(i),--r}}return{nodes:n.reverse(),offset:r}}(e.node.content,e.children);this.preMatched=n.nodes,this.preMatchOffset=n.offset};function ne(e,t){return e.type.side-t.type.side}function re(e,t,n,r,o){for(var i=[],s=0,a=0;s=n||u<=t?i.push(c):(ln&&i.push(c.slice(n-l,c.size,r)))}return i}function oe(e,t){var n=e.selection,o=n.$anchor,i=n.$head,s=t>0?o.max(i):o.min(i),a=s.parent.inlineContent?s.depth?e.doc.resolve(t>0?s.after():s.before()):null:s;return a&&r.Selection.findFrom(a,t)}function ie(e,t){return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()),!0}function se(e,t,n){var o=e.state.selection;if(o instanceof r.TextSelection){if(!o.empty||n.indexOf("s")>-1)return!1;if(e.endOfTextblock(t>0?"right":"left")){var i=oe(e.state,t);return!!(i&&i instanceof r.NodeSelection)&&ie(e,i)}var a,c=o.$head,l=c.textOffset?null:t<0?c.nodeBefore:c.nodeAfter;if(!l||l.isText)return!1;var u=t<0?c.pos-l.nodeSize:c.pos;return!!(l.isAtom||(a=e.docView.descAt(u))&&!a.contentDOM)&&(r.NodeSelection.isSelectable(l)?ie(e,new r.NodeSelection(t<0?e.state.doc.resolve(c.pos-l.nodeSize):c)):!!s.webkit&&ie(e,new r.TextSelection(e.state.doc.resolve(t<0?u:u+l.nodeSize))))}if(o instanceof r.NodeSelection&&o.node.isInline)return ie(e,new r.TextSelection(t>0?o.$to:o.$from));var p=oe(e.state,t);return!!p&&ie(e,p)}function ae(e){return 3==e.nodeType?e.nodeValue.length:e.childNodes.length}function ce(e){var t=e.pmViewDesc;return t&&0==t.size&&(e.nextSibling||"BR"!=e.nodeName)}function le(e){var t=e.root.getSelection(),n=t.focusNode,r=t.focusOffset;if(n){var o,i,a=!1;for(s.gecko&&1==n.nodeType&&r0){if(1!=n.nodeType)break;var c=n.childNodes[r-1];if(ce(c))o=n,i=--r;else{if(3!=c.nodeType)break;r=(n=c).nodeValue.length}}else{if(pe(n))break;for(var l=n.previousSibling;l&&ce(l);)o=n.parentNode,i=f(l),l=l.previousSibling;if(l)r=ae(n=l);else{if((n=n.parentNode)==e.dom)break;r=0}}a?fe(e,t,n,r):o&&fe(e,t,o,i)}}function ue(e){var t=e.root.getSelection(),n=t.focusNode,r=t.focusOffset;if(n){for(var o,i,s=ae(n);;)if(r-1)return!1;var i=o.$from,s=o.$to;if(!i.parent.inlineContent||e.endOfTextblock(t<0?"up":"down")){var a=oe(e.state,t);if(a&&a instanceof r.NodeSelection)return ie(e,a)}if(!i.parent.inlineContent){var c=r.Selection.findFrom(t<0?i:s,t);return!c||ie(e,c)}return!1}function de(e,t){if(!(e.state.selection instanceof r.TextSelection))return!0;var n=e.state.selection,o=n.$head,i=n.$anchor,s=n.empty;if(!o.sameParent(i))return!0;if(!s)return!1;if(e.endOfTextblock(t>0?"forward":"backward"))return!0;var a=!o.textOffset&&(t<0?o.nodeBefore:o.nodeAfter);if(a&&!a.isText){var c=e.state.tr;return t<0?c.delete(o.pos-a.nodeSize,o.pos):c.delete(o.pos,o.pos+a.nodeSize),e.dispatch(c),!0}return!1}function me(e,t,n){e.domObserver.stop(),t.contentEditable=n,e.domObserver.start()}function ve(e,t){var n=t.keyCode,r=function(e){var t="";return e.ctrlKey&&(t+="c"),e.metaKey&&(t+="m"),e.altKey&&(t+="a"),e.shiftKey&&(t+="s"),t}(t);return 8==n||s.mac&&72==n&&"c"==r?de(e,-1)||le(e):46==n||s.mac&&68==n&&"c"==r?de(e,1)||ue(e):13==n||27==n||(37==n?se(e,-1,r)||le(e):39==n?se(e,1,r)||ue(e):38==n?he(e,-1,r)||le(e):40==n?function(e){if(s.chrome&&!(e.state.selection.$head.parentOffset>0)){var t=e.root.getSelection(),n=t.focusNode,r=t.focusOffset;if(n&&1==n.nodeType&&0==r&&n.firstChild&&"false"==n.firstChild.contentEditable){var o=n.firstChild;me(e,o,!0),setTimeout(function(){return me(e,o,!1)},20)}}}(e)||he(e,1,r)||ue(e):r==(s.mac?"m":"c")&&(66==n||73==n||89==n||90==n))}function ge(e,t,n){var o=e.state.selection;if(we(e,o),e.editable&&!e.hasFocus()){if(!t)return;s.gecko&&s.gecko_version<=55&&(e.domObserver.disconnectSelection(),e.dom.focus(),e.domObserver.connectSelection())}else if(!(e.editable||_e(e)&&document.activeElement.contains(e.dom)||t))return;if(e.domObserver.disconnectSelection(),e.cursorWrapper)!function(e){var t=e.root.getSelection(),n=document.createRange(),r=e.cursorWrapper.dom,o="IMG"==r.nodeName;o?n.setEnd(r.parentNode,f(r)+1):n.setEnd(r,0);n.collapse(!1),t.removeAllRanges(),t.addRange(n),!o&&!e.state.selection.visible&&s.ie&&s.ie_version<=11&&(r.disabled=!0,r.disabled=!1)}(e);else{var i,a,c=o.anchor,l=o.head;!ye||o instanceof r.TextSelection||(o.$from.parent.inlineContent||(i=be(e,o.from)),o.empty||o.$from.parent.inlineContent||(a=be(e,o.to))),e.docView.setSelection(c,l,e.root,n),ye&&(i&&(i.contentEditable="false"),a&&(a.contentEditable="false")),o.visible?e.dom.classList.remove("ProseMirror-hideselection"):c!=l&&(e.dom.classList.add("ProseMirror-hideselection"),"onselectionchange"in document&&function(e){var t=e.dom.ownerDocument;t.removeEventListener("selectionchange",e.hideSelectionGuard);var n=e.root.getSelection(),r=n.anchorNode,o=n.anchorOffset;t.addEventListener("selectionchange",e.hideSelectionGuard=function(){n.anchorNode==r&&n.anchorOffset==o||(t.removeEventListener("selectionchange",e.hideSelectionGuard),e.dom.classList.remove("ProseMirror-hideselection"))})}(e))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}te.prototype.getPreMatch=function(e){return e>=this.preMatchOffset?this.preMatched[e-this.preMatchOffset]:null},te.prototype.destroyBetween=function(e,t){if(e!=t){for(var n=e;n>1,i=Math.min(o,e.length);r-1)s>this.index&&(this.changed=!0,this.destroyBetween(this.index,s)),this.top=this.top.children[this.index];else{var c=B.create(this.top,e[o],t,n);this.top.children.splice(this.index,0,c),this.top=c,this.changed=!0}this.index=0,o++}},te.prototype.findNodeMatch=function(e,t,n,r){var o=-1,i=r<0?void 0:this.getPreMatch(r),s=this.top.children;if(i&&i.matchesNode(e,t,n))o=s.indexOf(i);else for(var a=this.index,c=Math.min(s.length,a+5);a-1&&s+this.preMatchOffset!=o)return!1;var a=i.dom;if(!(this.lock&&(a==this.lock||1==a.nodeType&&a.contains(this.lock.parentNode))&&!(e.isText&&i.node&&i.node.isText&&i.nodeDOM.nodeValue==e.text&&3!=i.dirty&&Q(t,i.outerDeco)))&&i.update(e,t,n,r))return i.dom!=a&&(this.changed=!0),this.index++,!0}return!1},te.prototype.addNode=function(e,t,n,r,o){this.top.children.splice(this.index++,0,q.create(this.top,e,t,n,r,o)),this.changed=!0},te.prototype.placeWidget=function(e,t,n){if(this.indexDate.now()-50?e.lastSelectionOrigin:null,c=function(e,t){var n,o,i=e.root.getSelection(),s=e.state.doc,a=e.docView.nearestDesc(i.focusNode),c=a&&0==a.size,l=e.docView.posFromDOM(i.focusNode,i.focusOffset),u=s.resolve(l);if(b(i)){for(n=u;a&&!a.node;)a=a.parent;if(a&&a.node.isAtom&&r.NodeSelection.isSelectable(a.node)&&a.parent){var p=a.posBefore;o=new r.NodeSelection(l==p?u:s.resolve(p))}}else n=s.resolve(e.docView.posFromDOM(i.anchorNode,i.anchorOffset));return o||(o=xe(e,n,u,"pointer"==t||e.state.selection.heada;d--){var m=i.childNodes[d-1],v=m.pmViewDesc;if("BR"==m.nodeType&&!v){c=d;break}if(!v||v.size)break}var g=e.state.doc,y=e.someProp("domParser")||o.DOMParser.fromSchema(e.state.schema),w=g.resolve(l),k=null,x=y.parse(i,{topNode:w.parent,topMatch:w.parent.contentMatchAt(w.index()),topOpen:!0,from:a,to:c,preserveWhitespace:!w.parent.type.spec.code||"full",editableContent:!0,findPositions:f,ruleFromNode:Ce(y,w),context:w});if(f&&null!=f[0].pos){var _=f[0].pos,C=f[1]&&f[1].pos;null==C&&(C=_),k={anchor:_+l,head:C+l}}return{doc:x,sel:k,from:l,to:u}}(e,t,n),v=e.state.doc,g=v.slice(m.from,m.to);8===e.lastKeyCode&&Date.now()-100=a?i-r:0)+(c-a),a=i}else if(c=c?i-r:0)+(a-c),c=i}return{start:i,endA:a,endB:c}}(g.content,m.doc.content,m.from,f,h);if(y){e.domChangeCount++,e.state.selection.frome.state.selection.from&&y.start<=e.state.selection.from+2?y.start=e.state.selection.from:y.endA=e.state.selection.to-2&&(y.endB+=e.state.selection.to-y.endA,y.endA=e.state.selection.to));var k,x=m.doc.resolveNoCache(y.start-m.from),_=m.doc.resolveNoCache(y.endB-m.from);if(!(!x.sameParent(_)&&x.posy.start&&function(e,t,n,r,o){if(!r.parent.isTextblock||n-t<=o.pos-r.pos||Ae(r,!0,!1)n||Ae(s,!0,!1)t.content.size?null:xe(e,t.resolve(n.anchor),t.resolve(n.head))}function Ae(e,t,n){for(var r=e.depth,o=t?e.end():e.pos;r>0&&(t||e.indexAfter(r)==e.node(r).childCount);)r--,o++,t=!1;if(n)for(var i=e.node(r).maybeChild(e.indexAfter(r));i&&!i.isLeaf;)i=i.firstChild,o++;return o}function Ee(e,t){for(var n=[],r=t.content,i=t.openStart,s=t.openEnd;i>1&&s>1&&1==r.childCount&&1==r.firstChild.childCount;){i--,s--;var a=r.firstChild;n.push(a.type.name,a.type.hasRequiredAttrs()?a.attrs:null),r=a.content}var c=e.someProp("clipboardSerializer")||o.DOMSerializer.fromSchema(e.state.schema),l=document.createElement("div");l.appendChild(c.serializeFragment(r));for(var u,p=l.firstChild;p&&1==p.nodeType&&(u=Ne[p.nodeName.toLowerCase()]);){for(var f=u.length-1;f>=0;f--){for(var h=document.createElement(u[f]);l.firstChild;)h.appendChild(l.firstChild);l.appendChild(h)}p=l.firstChild}return p&&1==p.nodeType&&p.setAttribute("data-pm-slice",i+" "+s+" "+JSON.stringify(n)),{dom:l,text:e.someProp("clipboardTextSerializer",function(e){return e(t)})||t.content.textBetween(0,t.content.size,"\n\n")}}function Me(e,t,n,r,i){var s,a,c=i.parent.type.spec.code;if(!n&&!t)return null;var l=t&&(r||c||!n);if(l){if(e.someProp("transformPastedText",function(e){t=e(t)}),c)return new o.Slice(o.Fragment.from(e.state.schema.text(t)),0,0);var u=e.someProp("clipboardTextParser",function(e){return e(t,i)});u?a=u:(s=document.createElement("div"),t.trim().split(/(?:\r\n?|\n)+/).forEach(function(e){s.appendChild(document.createElement("p")).textContent=e}))}else e.someProp("transformPastedHTML",function(e){n=e(n)}),s=function(e){var t=/(\s*]*>)*/.exec(e);t&&(e=e.slice(t[0].length));var n,r=(Re||(Re=document.implementation.createHTMLDocument("title"))).createElement("div"),o=/(?:]*>)*<([a-z][^>\s]+)/i.exec(e),i=0;(n=o&&Ne[o[1].toLowerCase()])&&(e=n.map(function(e){return"<"+e+">"}).join("")+e+n.map(function(e){return""}).reverse().join(""),i=n.length);r.innerHTML=e;for(var s=0;s=0;c-=2){var l=r.nodes[n[c]];if(!l||l.hasRequiredAttrs())break;i=o.Fragment.from(l.create(n[c+1],i)),s++,a++}return new o.Slice(i,s,a)}(function(e,t,n){t=0;r--){var i=n(r);if(i)return i.v}return e}(a.content,i),!1),e.someProp("transformPasted",function(e){a=e(a)}),a}function Te(e,t,n){void 0===n&&(n=0);for(var r=t.length-1;r>=n;r--)e=t[r].create(null,o.Fragment.from(e));return e}function De(e,t,n,r,i,s){var a=t<0?e.firstChild:e.lastChild,c=a.content;return i=n&&(c=t<0?a.contentMatchAt(0).fillBefore(c,e.childCount>1||s<=i).append(c):c.append(a.contentMatchAt(a.childCount).fillBefore(o.Fragment.empty,!0))),e.replaceChild(t<0?0:e.childCount-1,a.copy(c))}var Ne={thead:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]},Re=null;var Ie={childList:!0,characterData:!0,attributes:!0,subtree:!0,characterDataOldValue:!0},Pe=s.ie&&s.ie_version<=11,ze=function(){this.anchorNode=this.anchorOffset=this.focusNode=this.focusOffset=null};ze.prototype.set=function(e){this.anchorNode=e.anchorNode,this.anchorOffset=e.anchorOffset,this.focusNode=e.focusNode,this.focusOffset=e.focusOffset},ze.prototype.eq=function(e){return e.anchorNode==this.anchorNode&&e.anchorOffset==this.anchorOffset&&e.focusNode==this.focusNode&&e.focusOffset==this.focusOffset};var je=function(e,t){var n=this;this.view=e,this.handleDOMChange=t,this.observer=window.MutationObserver&&new window.MutationObserver(function(e){s.ie&&s.ie_version<=11&&e.some(function(e){return"childList"==e.type&&1==e.removedNodes.length&&e.removedNodes[0].parentNode==e.target})?setTimeout(function(){return n.flush(e)},10):n.flush(e)}),this.currentSelection=new ze,this.queue=[],Pe&&(this.onCharData=function(e){n.queue.push({target:e.target,type:"characterData",oldValue:e.prevValue}),window.setTimeout(function(){return n.flush()},20)}),this.onSelectionChange=this.onSelectionChange.bind(this),this.suppressingSelectionUpdates=!1};je.prototype.start=function(){this.observer&&this.observer.observe(this.view.dom,Ie),Pe&&this.view.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.connectSelection()},je.prototype.stop=function(){var e=this,t=this.observer.takeRecords();if(t.length){for(var n=0;n-1||n)&&(r>-1&&this.view.docView.markDirty(r,o),this.handleDOMChange(r,o,i),this.view.docView.dirty?this.view.updateState(this.view.state):this.currentSelection.eq(t)||ge(this.view))}},je.prototype.registerMutation=function(e){var t=this.view.docView.nearestDesc(e.target);if("attributes"==e.type&&(t==this.view.docView||"contenteditable"==e.attributeName||"style"==e.attributeName&&!e.oldValue&&!e.target.getAttribute("style")))return null;if(!t||t.ignoreMutation(e))return null;if("childList"==e.type){var n=e.previousSibling&&e.previousSibling.parentNode==e.target?f(e.previousSibling)+1:0,r=t.localPosFromDOM(e.target,n,-1),o=e.nextSibling&&e.nextSibling.parentNode==e.target?f(e.nextSibling):e.target.childNodes.length;return{from:r,to:t.localPosFromDOM(e.target,o,1)}}return"attributes"==e.type?{from:t.posAtStart-t.border,to:t.posAtEnd+t.border}:{from:t.posAtStart,to:t.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}};var Fe={},Le={};function $e(e,t){e.lastSelectionOrigin=t,e.lastSelectionTime=Date.now()}function Be(e){e.someProp("handleDOMEvents",function(t){for(var n in t)e.eventHandlers[n]||e.dom.addEventListener(n,e.eventHandlers[n]=function(t){return qe(e,t)})})}function qe(e,t){return e.someProp("handleDOMEvents",function(n){var r=n[t.type];return!!r&&(r(e,t)||t.defaultPrevented)})}function Ve(e){return{left:e.clientX,top:e.clientY}}function Ue(e,t,n,r,o){if(-1==r)return!1;for(var i=e.state.doc.resolve(r),s=function(r){if(e.someProp(t,function(t){return r>i.depth?t(e,n,i.nodeAfter,i.before(r),o,!0):t(e,n,i.node(r),i.before(r),o,!1)}))return{v:!0}},a=i.depth+1;a>0;a--){var c=s(a);if(c)return c.v}return!1}function He(e,t,n){e.focused||e.focus();var r=e.state.tr.setSelection(t);"pointer"==n&&r.setMeta("pointer",!0),e.dispatch(r)}function We(e,t,n,o,i){return Ue(e,"handleClickOn",t,n,o)||e.someProp("handleClick",function(n){return n(e,t,o)})||(i?function(e,t){if(-1==t)return!1;var n,o,i=e.state.selection;i instanceof r.NodeSelection&&(n=i.node);for(var s=e.state.doc.resolve(t),a=s.depth+1;a>0;a--){var c=a>s.depth?s.nodeAfter:s.node(a);if(r.NodeSelection.isSelectable(c)){o=n&&i.$from.depth>0&&a>=i.$from.depth&&s.before(i.$from.depth+1)==i.$from.pos?s.before(i.$from.depth):s.before(a);break}}return null!=o&&(He(e,r.NodeSelection.create(e.state.doc,o),"pointer"),!0)}(e,n):function(e,t){if(-1==t)return!1;var n=e.state.doc.resolve(t),o=n.nodeAfter;return!!(o&&o.isAtom&&r.NodeSelection.isSelectable(o))&&(He(e,new r.NodeSelection(n),"pointer"),!0)}(e,n))}function Je(e,t,n,o){return Ue(e,"handleTripleClickOn",t,n,o)||e.someProp("handleTripleClick",function(n){return n(e,t,o)})||function(e,t){var n=e.state.doc;if(-1==t)return!!n.inlineContent&&(He(e,r.TextSelection.create(n,0,n.content.size),"pointer"),!0);for(var o=n.resolve(t),i=o.depth+1;i>0;i--){var s=i>o.depth?o.nodeAfter:o.node(i),a=o.before(i);if(s.inlineContent)He(e,r.TextSelection.create(n,a+1,a+1+s.content.size),"pointer");else{if(!r.NodeSelection.isSelectable(s))continue;He(e,r.NodeSelection.create(n,a),"pointer")}return!0}}(e,n)}function Ge(e){return et(e)}Le.keydown=function(e,t){e.shiftKey=16==t.keyCode||t.shiftKey,Xe(e,t)||(e.lastKeyCode=t.keyCode,e.lastKeyCodeTime=Date.now(),e.someProp("handleKeyDown",function(n){return n(e,t)})||ve(e,t)?t.preventDefault():$e(e,"key"))},Le.keyup=function(e,t){16==t.keyCode&&(e.shiftKey=!1)},Le.keypress=function(e,t){if(!(Xe(e,t)||!t.charCode||t.ctrlKey&&!t.altKey||s.mac&&t.metaKey))if(e.someProp("handleKeyPress",function(n){return n(e,t)}))t.preventDefault();else{var n=e.state.selection;if(!(n instanceof r.TextSelection&&n.$from.sameParent(n.$to))){var o=String.fromCharCode(t.charCode);e.someProp("handleTextInput",function(t){return t(e,n.$from.pos,n.$to.pos,o)})||e.dispatch(e.state.tr.insertText(o).scrollIntoView()),t.preventDefault()}}};var Ke=s.mac?"metaKey":"ctrlKey";Fe.mousedown=function(e,t){e.shiftKey=t.shiftKey;var n=Ge(e),r=Date.now(),o="singleClick";r-e.lastClick.time<500&&function(e,t){var n=t.x-e.clientX,r=t.y-e.clientY;return n*n+r*r<100}(t,e.lastClick)&&!t[Ke]&&("singleClick"==e.lastClick.type?o="doubleClick":"doubleClick"==e.lastClick.type&&(o="tripleClick")),e.lastClick={time:r,x:t.clientX,y:t.clientY,type:o};var i=e.posAtCoords(Ve(t));i&&("singleClick"==o?e.mouseDown=new Ze(e,i,t,n):("doubleClick"==o?function(e,t,n,r){return Ue(e,"handleDoubleClickOn",t,n,r)||e.someProp("handleDoubleClick",function(n){return n(e,t,r)})}:Je)(e,i.pos,i.inside,t)?t.preventDefault():$e(e,"pointer"))};var Ze=function(e,t,n,o){var i,a,c=this;if(this.view=e,this.startDoc=e.state.doc,this.pos=t,this.event=n,this.flushed=o,this.selectNode=n[Ke],this.allowDefault=n.shiftKey,t.inside>-1)i=e.state.doc.nodeAt(t.inside),a=t.inside;else{var l=e.state.doc.resolve(t.pos);i=l.parent,a=l.depth?l.before():0}this.mightDrag=null;var u=o?null:n.target,p=u?e.docView.nearestDesc(u,!0):null;this.target=p?p.dom:null,(i.type.spec.draggable&&!1!==i.type.spec.selectable||e.state.selection instanceof r.NodeSelection&&a==e.state.selection.from)&&(this.mightDrag={node:i,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 c.target.setAttribute("contentEditable","false")},20),this.view.domObserver.start()),e.root.addEventListener("mouseup",this.up=this.up.bind(this)),e.root.addEventListener("mousemove",this.move=this.move.bind(this)),$e(e,"pointer")};function Xe(e,t){return!!e.composing||!!(s.safari&&Math.abs(t.timeStamp-e.compositionEndedAt)<500)&&(e.compositionEndedAt=-2e8,!0)}Ze.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.draggable=!1),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.view.mouseDown=null},Ze.prototype.up=function(e){if(this.done(),this.view.dom.contains(3==e.target.nodeType?e.target.parentNode:e.target)){var t=this.pos;this.view.state.doc!=this.startDoc&&(t=this.view.posAtCoords(Ve(e))),this.allowDefault||!t?$e(this.view,"pointer"):We(this.view,t.pos,t.inside,e,this.selectNode)?e.preventDefault():!this.flushed&&(!s.chrome||this.view.state.selection instanceof r.TextSelection||t.pos!=this.view.state.selection.from&&t.pos!=this.view.state.selection.to)?$e(this.view,"pointer"):(He(this.view,r.Selection.near(this.view.state.doc.resolve(t.pos)),"pointer"),e.preventDefault())}},Ze.prototype.move=function(e){!this.allowDefault&&(Math.abs(this.event.x-e.clientX)>4||Math.abs(this.event.y-e.clientY)>4)&&(this.allowDefault=!0),$e(this.view,"pointer")},Fe.touchdown=function(e){Ge(e),$e(e,"pointer")},Fe.contextmenu=function(e){return Ge(e)};var Ye=s.android?5e3:-1;function Qe(e,t){clearTimeout(e.composingTimeout),t>-1&&(e.composingTimeout=setTimeout(function(){return et(e)},t))}function et(e,t){for(e.composing=!1;e.compositionNodes.length>0;)e.compositionNodes.pop().markParentsDirty();return!(!t&&!e.docView.dirty)&&(e.updateState(e.state),!0)}Le.compositionstart=Le.compositionupdate=function(e){if(!e.composing){e.domObserver.flush();var t=e.state,n=t.selection.$from;if(t.selection.empty&&(t.storedMarks||!n.textOffset&&n.parentOffset&&n.nodeBefore.marks.some(function(e){return!1===e.type.spec.inclusive})))e.markCursor=e.state.storedMarks||n.marks(),et(e,!0),e.markCursor=null;else if(et(e),s.gecko&&t.selection.empty&&n.parentOffset&&!n.textOffset&&n.nodeBefore.marks.length)for(var r=e.root.getSelection(),o=r.focusNode,i=r.focusOffset;o&&1==o.nodeType&&0!=i;){var a=i<0?o.lastChild:o.childNodes[i-1];if(3==a.nodeType){r.collapse(a,a.nodeValue.length);break}o=a,i=-1}e.composing=!0}Qe(e,Ye)},Le.compositionend=function(e,t){e.composing&&(e.composing=!1,e.compositionEndedAt=t.timeStamp,Qe(e,20))};var tt=s.ie&&s.ie_version<15||s.ios&&s.webkit_version<604;function nt(e,t,n,r){var i=Me(e,t,n,e.shiftKey,e.state.selection.$from);if(e.someProp("handlePaste",function(t){return t(e,r,i||o.Slice.empty)})||!i)return!0;var s=function(e){return 0==e.openStart&&0==e.openEnd&&1==e.content.childCount?e.content.firstChild:null}(i),a=s?e.state.tr.replaceSelectionWith(s,e.shiftKey):e.state.tr.replaceSelection(i);return e.dispatch(a.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste")),!0}Fe.copy=Le.cut=function(e,t){var n=e.state.selection,r="cut"==t.type;if(!n.empty){var o=tt?null:t.clipboardData,i=Ee(e,n.content()),s=i.dom,a=i.text;o?(t.preventDefault(),o.clearData(),o.setData("text/html",s.innerHTML),o.setData("text/plain",a)):function(e,t){var n=t.ownerDocument,r=n.body.appendChild(n.createElement("div"));r.appendChild(t),r.style.cssText="position: fixed; left: -10000px; top: 10px";var o=getSelection(),i=n.createRange();i.selectNodeContents(t),e.dom.blur(),o.removeAllRanges(),o.addRange(i),setTimeout(function(){n.body.removeChild(r),e.focus()},50)}(e,s),r&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))}},Le.paste=function(e,t){var n=tt?null:t.clipboardData;n&&(nt(e,n.getData("text/plain"),n.getData("text/html"),t)||n.files.length>0)?t.preventDefault():function(e,t){var n=e.dom.ownerDocument,r=e.shiftKey||e.state.selection.$from.parent.type.spec.code,o=n.body.appendChild(n.createElement(r?"textarea":"div"));r||(o.contentEditable="true"),o.style.cssText="position: fixed; left: -10000px; top: 10px",o.focus(),setTimeout(function(){e.focus(),n.body.removeChild(o),r?nt(e,o.value,null,t):nt(e,o.textContent,o.innerHTML,t)},50)}(e,t)};var rt=function(e,t){this.slice=e,this.move=t},ot=s.mac?"altKey":"ctrlKey";for(var it in Fe.dragstart=function(e,t){var n=e.mouseDown;if(n&&n.done(),t.dataTransfer){var o=e.state.selection,i=o.empty?null:e.posAtCoords(Ve(t));if(i&&i.pos>=o.from&&i.pos<=(o instanceof r.NodeSelection?o.to-1:o.to));else if(n&&n.mightDrag)e.dispatch(e.state.tr.setSelection(r.NodeSelection.create(e.state.doc,n.mightDrag.pos)));else if(t.target&&1==t.target.nodeType){var s=e.docView.nearestDesc(t.target,!0);if(!s||!s.node.type.spec.draggable||s==e.docView)return;e.dispatch(e.state.tr.setSelection(r.NodeSelection.create(e.state.doc,s.posBefore)))}var a=e.state.selection.content(),c=Ee(e,a),l=c.dom,u=c.text;t.dataTransfer.clearData(),t.dataTransfer.setData(tt?"Text":"text/html",l.innerHTML),tt||t.dataTransfer.setData("text/plain",u),e.dragging=new rt(a,!t[ot])}},Fe.dragend=function(e){window.setTimeout(function(){return e.dragging=null},50)},Le.dragover=Le.dragenter=function(e,t){return t.preventDefault()},Le.drop=function(e,t){var n=e.dragging;if(e.dragging=null,t.dataTransfer){var o=e.posAtCoords(Ve(t));if(o){var s=e.state.doc.resolve(o.pos);if(s){var a=n&&n.slice||Me(e,t.dataTransfer.getData(tt?"Text":"text/plain"),tt?null:t.dataTransfer.getData("text/html"),!1,s);if(a&&(t.preventDefault(),!e.someProp("handleDrop",function(r){return r(e,t,a,n&&n.move)}))){var c=a?i.dropPoint(e.state.doc,s.pos,a):s.pos;null==c&&(c=s.pos);var l=e.state.tr;n&&n.move&&l.deleteSelection();var u=l.mapping.map(c),p=0==a.openStart&&0==a.openEnd&&1==a.content.childCount,f=l.doc;if(p?l.replaceRangeWith(u,u,a.content.firstChild):l.replaceRange(u,u,a),!l.doc.eq(f)){var h=l.doc.resolve(u);p&&r.NodeSelection.isSelectable(a.content.firstChild)&&h.nodeAfter&&h.nodeAfter.sameMarkup(a.content.firstChild)?l.setSelection(new r.NodeSelection(h)):l.setSelection(xe(e,h,l.doc.resolve(l.mapping.map(c)))),e.focus(),e.dispatch(l.setMeta("uiEvent","drop"))}}}}}},Fe.focus=function(e){e.focused||(e.domObserver.stop(),e.dom.classList.add("ProseMirror-focused"),e.domObserver.start(),e.focused=!0)},Fe.blur=function(e){e.focused&&(e.domObserver.stop(),e.dom.classList.remove("ProseMirror-focused"),e.domObserver.start(),e.focused=!1)},Fe.beforeinput=function(e,t){if(s.chrome&&s.android&&"deleteContentBackward"==t.inputType){var n=e.domChangeCount;setTimeout(function(){if(e.domChangeCount==n&&(e.dom.blur(),e.focus(),!e.someProp("handleKeyDown",function(t){return t(e,w(8,"Backspace"))}))){var t=e.state.selection.$cursor;t&&t.pos>0&&e.dispatch(e.state.tr.delete(t.pos-1,t.pos).scrollIntoView())}},50)}},Le)Fe[it]=Le[it];function st(e,t){if(e==t)return!0;for(var n in e)if(e[n]!==t[n])return!1;for(var r in t)if(!(r in e))return!1;return!0}var at=function(e,t){this.spec=t||ht,this.side=this.spec.side||0,this.toDOM=e};at.prototype.map=function(e,t,n,r){var o=e.mapResult(t.from+r,this.side<0?-1:1),i=o.pos;return o.deleted?null:new ut(i-n,i-n,this)},at.prototype.valid=function(){return!0},at.prototype.eq=function(e){return this==e||e instanceof at&&(this.spec.key&&this.spec.key==e.spec.key||this.toDOM==e.toDOM&&st(this.spec,e.spec))};var ct=function(e,t){this.spec=t||ht,this.attrs=e};ct.prototype.map=function(e,t,n,r){var o=e.map(t.from+r,this.spec.inclusiveStart?-1:1)-n,i=e.map(t.to+r,this.spec.inclusiveEnd?1:-1)-n;return o>=i?null:new ut(o,i,this)},ct.prototype.valid=function(e,t){return t.from=e&&(!o||o(s.spec))&&n.push(s.copy(s.from+r,s.to+r))}for(var a=0;ae){var c=this.children[a]+1;this.children[a+2].findInner(e-c,t-c,n,r+c,o)}},dt.prototype.map=function(e,t,n){return this==mt||0==e.maps.length?this:this.mapInner(e,t,0,0,n||ht)},dt.prototype.mapInner=function(e,t,n,r,o){for(var i,s=0;sc+i||(t>=a[s]+i?a[s+1]=-1:(l=r-n-(t-e)+(i-o))&&(a[s]+=l,a[s+1]+=l))}},l=0;l=r.content.size){u=!0;continue}var d=n.map(e[p+1]+i,-1)-o,m=r.content.findIndex(h),v=m.index,g=m.offset,y=r.maybeChild(v);if(y&&g==h&&g+y.nodeSize==d){var b=a[p+2].mapInner(n,y,f+1,a[p]+i+1,s);b!=mt?(a[p]=h,a[p+1]=d,a[p+2]=b):(a[p+1]=-2,u=!0)}else u=!0}if(u){var w=wt(function(e,t,n,r,o,i,s){function a(e,t){for(var i=0;is&&l.to=e){this.children[o]==e&&(n=this.children[o+2]);break}for(var i=e+1,s=i+t.content.size,a=0;ai&&c.type instanceof ct){var l=Math.max(i,c.from)-i,u=Math.min(s,c.to)-i;ln&&s.to0;)t++;e.splice(t,0,n)}function Ct(e){var t=[];return e.someProp("decorations",function(n){var r=n(e.state);r&&r!=mt&&t.push(r)}),e.cursorWrapper&&t.push(dt.create(e.state.doc,[e.cursorWrapper.deco])),vt.from(t)}vt.prototype.forChild=function(e,t){if(t.isLeaf)return dt.empty;for(var n=[],r=0;ro.scrollToSelection?"to selection":"preserve",v=i||!this.docView.matchesNode(e.doc,f,p),g=v||!e.selection.eq(o.selection),y="preserve"==d&&g&&null==this.dom.style.overflowAnchor&&function(e){for(var t,n,r=e.dom.getBoundingClientRect(),o=Math.max(0,r.top),i=e.dom.ownerDocument,s=(r.left+r.right)/2,a=o+1;a=o-20){t=c,n=l.top;break}}}for(var u=[],p=e.dom;p&&(u.push({dom:p,top:p.scrollTop,left:p.scrollLeft}),p!=i.body);p=h(p));return{refDOM:t,refTop:n,stack:u}}(this);if(g){this.domObserver.stop();var b=!1;if(v){var w=s.chrome&&Tt(this.root);!i&&this.docView.update(e.doc,f,p,this)||(this.docView.destroy(),this.docView=V(e.doc,f,p,this.dom,this)),w&&(b=!this.composing&&function(e,t){var n=Tt(t);if(!n||3==n[0].nodeType)return!1;for(var r=0;r":Object(o.s)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.u)(/^\s*>\s$/,t)]}},{key:"name",get:function(){return"blockquote"}},{key:"schema",get:function(){return{content:"block*",group:"block",defining:!0,draggable:!1,parseDOM:[{tag:"blockquote"}],toDOM:function(){return["blockquote",0]}}}}]),t}(),A=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type,n=e.schema;return function(){return Object(o.q)(t,n.nodes.list_item)}}},{key:"keys",value:function(e){var t=e.type,n=e.schema;return{"Shift-Ctrl-8":Object(o.q)(t,n.nodes.list_item)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.u)(/^\s*([-+*])\s$/,t)]}},{key:"name",get:function(){return"bullet_list"}},{key:"schema",get:function(){return{content:"list_item+",group:"block",parseDOM:[{tag:"ul"}],toDOM:function(){return["ul",0]}}}}]),t}(),E=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type,n=e.schema;return function(){return Object(o.p)(t,n.nodes.paragraph)}}},{key:"keys",value:function(e){var t=e.type;return{"Shift-Ctrl-\\":Object(o.k)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.o)(/^```$/,t)]}},{key:"name",get:function(){return"code_block"}},{key:"schema",get:function(){return{content:"text*",marks:"",group:"block",code:!0,defining:!0,draggable:!1,parseDOM:[{tag:"pre",preserveWhitespace:"full"}],toDOM:function(){return["pre",["code",0]]}}}}]),t}();function M(e){var t=e.doc,n=e.name,r=[],o=Object(c.findBlockNodes)(t).filter(function(e){return e.node.type.name===n});return o.forEach(function(e){var t=e.pos+1;(function e(t){return t.reduce(function(t,n){return t.concat(Array.isArray(n)?e(n):n)},[])})(function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return t.map(function(t){var r=[].concat(S(n),S(t.properties?t.properties.className:[]));return t.children?e(t.children,r):{text:t.value,classes:r}})}(s.a.highlightAuto(e.node.textContent).value)).map(function(e){var n=t,r=n+e.text.length;return t=r,b({},e,{from:n,to:r})}).forEach(function(e){var t=a.Decoration.inline(e.from,e.to,{class:e.classes.join(" ")});r.push(t)})}),a.DecorationSet.create(t,r)}var T=function(e){function t(){var e,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};d(this,t),e=_(this,k(t).call(this,n));try{Object.entries(e.options.languages).forEach(function(e){var t=C(e,2),n=t[0],r=t[1];s.a.registerLanguage(n,r)})}catch(e){throw new Error("Invalid syntax highlight definitions: define at least one highlight.js language mapping")}return e}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type,n=e.schema;return function(){return Object(o.p)(t,n.nodes.paragraph)}}},{key:"keys",value:function(e){var t=e.type;return{"Shift-Ctrl-\\":Object(o.k)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.o)(/^```$/,t)]}},{key:"name",get:function(){return"code_block"}},{key:"defaultOptions",get:function(){return{languages:{}}}},{key:"schema",get:function(){return{content:"text*",marks:"",group:"block",code:!0,defining:!0,draggable:!1,parseDOM:[{tag:"pre",preserveWhitespace:"full"}],toDOM:function(){return["pre",["code",0]]}}}},{key:"plugins",get:function(){return[(e={name:this.name},t=e.name,new r.h({name:new r.i("highlight"),state:{init:function(e,n){return M({doc:n.doc,name:t})},apply:function(e,n,r,o){var i=o.selection.$head.parent.type.name,s=r.selection.$head.parent.type.name;return e.docChanged&&[i,s].includes(t)?M({doc:e.doc,name:t}):n.map(e.mapping,e.doc)}},props:{decorations:function(e){return this.getState(e)}}}))];var e,t}}]),t}(),D=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"keys",value:function(e){var t=e.type,n=Object(o.a)(o.b,function(e,n){return n(e.tr.replaceSelectionWith(t.create()).scrollIntoView()),!0});return{"Mod-Enter":n,"Shift-Enter":n}}},{key:"name",get:function(){return"hard_break"}},{key:"schema",get:function(){return{inline:!0,group:"inline",selectable:!1,parseDOM:[{tag:"br"}],toDOM:function(){return["br"]}}}}]),t}(),N=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type,n=e.schema;return function(e){return Object(o.p)(t,n.nodes.paragraph,e)}}},{key:"keys",value:function(e){var t=e.type;return this.options.levels.reduce(function(e,n){return b({},e,{},g({},"Shift-Ctrl-".concat(n),Object(o.k)(t,{level:n})))},{})}},{key:"inputRules",value:function(e){var t=e.type;return this.options.levels.map(function(e){return Object(o.o)(new RegExp("^(#{1,".concat(e,"})\\s$")),t,function(){return{level:e}})})}},{key:"name",get:function(){return"heading"}},{key:"defaultOptions",get:function(){return{levels:[1,2,3,4,5,6]}}},{key:"schema",get:function(){return{attrs:{level:{default:1}},content:"inline*",group:"block",defining:!0,draggable:!1,parseDOM:this.options.levels.map(function(e){return{tag:"h".concat(e),attrs:{level:e}}}),toDOM:function(e){return["h".concat(e.attrs.level),0]}}}}]),t}(),R=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type;return function(){return function(e,n){return n(e.tr.replaceSelectionWith(t.create()))}}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.g)(/^(?:---|___\s|\*\*\*\s)$/,t)]}},{key:"name",get:function(){return"horizontal_rule"}},{key:"schema",get:function(){return{group:"block",parseDOM:[{tag:"hr"}],toDOM:function(){return["hr"]}}}}]),t}(),I=/!\[(.+|:?)\]\((\S+)(?:(?:\s+)["'](\S+)["'])?\)/,P=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type;return function(e){return function(n,r){var o=n.selection,i=o.$cursor?o.$cursor.pos:o.$to.pos,s=t.create(e);r(n.tr.insert(i,s))}}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.g)(I,t,function(e){var t=C(e,4),n=t[1];return{src:t[2],alt:n,title:t[3]}})]}},{key:"name",get:function(){return"image"}},{key:"schema",get:function(){return{inline:!0,attrs:{src:{},alt:{default:null},title:{default:null}},group:"inline",draggable:!0,parseDOM:[{tag:"img[src]",getAttrs:function(e){return{src:e.getAttribute("src"),title:e.getAttribute("title"),alt:e.getAttribute("alt")}}}],toDOM:function(e){return["img",e.attrs]}}}},{key:"plugins",get:function(){return[new r.h({props:{handleDOMEvents:{drop:function(e,t){if(t.dataTransfer&&t.dataTransfer.files&&t.dataTransfer.files.length){var n=Array.from(t.dataTransfer.files).filter(function(e){return/image/i.test(e.type)});if(0!==n.length){t.preventDefault();var r=e.state.schema,o=e.posAtCoords({left:t.clientX,top:t.clientY});n.forEach(function(t){var n=new FileReader;n.onload=function(t){var n=r.nodes.image.create({src:t.target.result}),i=e.state.tr.insert(o.pos,n);e.dispatch(i)},n.readAsDataURL(t)})}}}}}})]}}]),t}(),z=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"keys",value:function(e){var t=e.type;return{Enter:Object(o.m)(t),Tab:Object(o.l)(t),"Shift-Tab":Object(o.d)(t)}}},{key:"name",get:function(){return"list_item"}},{key:"schema",get:function(){return{content:"paragraph block*",defining:!0,draggable:!1,parseDOM:[{tag:"li"}],toDOM:function(){return["li",0]}}}}]),t}();var j=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["g"]),v(t,[{key:"commands",value:function(e){var t=e.type,n=e.schema;return function(){return Object(o.q)(t,n.nodes.list_item)}}},{key:"keys",value:function(e){var t=e.type,n=e.schema;return{"Shift-Ctrl-9":Object(o.q)(t,n.nodes.list_item)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.u)(/^(\d+)\.\s$/,t,function(e){return{order:+e[1]}},function(e,t){return t.childCount+t.attrs.order===+e[1]})]}},{key:"name",get:function(){return"ordered_list"}},{key:"schema",get:function(){return{attrs:{order:{default:1}},content:"list_item+",group:"block",parseDOM:[{tag:"ol",getAttrs:function(e){return{order:e.hasAttribute("start")?+e.getAttribute("start"):1}}}],toDOM:function(e){return 1===e.attrs.order?["ol",0]:["ol",{start:e.attrs.order},0]}}}}]),t}(),F=(Object(l.tableNodes)({tableGroup:"block",cellContent:"block+",cellAttributes:{background:{default:null,getFromDOM:function(e){return e.style.backgroundColor||null},setDOMAttr:function(e,t){if(e){var n={style:"".concat(t.style||"","background-color: ").concat(e,";")};Object.assign(t,n)}}}}}),function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["f"]),v(t,[{key:"keys",value:function(e){var t=e.type;return{"Mod-b":Object(o.r)(t)}}},{key:"commands",value:function(e){var t=e.type;return function(){return Object(o.r)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.e)(/(?:\*\*|__)([^*_]+)(?:\*\*|__)$/,t)]}},{key:"pasteRules",value:function(e){var t=e.type;return[Object(o.f)(/(?:\*\*|__)([^*_]+)(?:\*\*|__)/g,t)]}},{key:"name",get:function(){return"bold"}},{key:"schema",get:function(){return{parseDOM:[{tag:"strong"},{tag:"b",getAttrs:function(e){return"normal"!==e.style.fontWeight&&null}},{style:"font-weight",getAttrs:function(e){return/^(bold(er)?|[5-9]\d{2,})$/.test(e)&&null}}],toDOM:function(){return["strong",0]}}}}]),t}()),L=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["f"]),v(t,[{key:"keys",value:function(e){var t=e.type;return{"Mod-`":Object(o.r)(t)}}},{key:"commands",value:function(e){var t=e.type;return function(){return Object(o.r)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.e)(/(?:`)([^`]+)(?:`)$/,t)]}},{key:"pasteRules",value:function(e){var t=e.type;return[Object(o.f)(/(?:`)([^`]+)(?:`)/g,t)]}},{key:"name",get:function(){return"code"}},{key:"schema",get:function(){return{excludes:"_",parseDOM:[{tag:"code"}],toDOM:function(){return["code",0]}}}}]),t}(),$=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["f"]),v(t,[{key:"keys",value:function(e){var t=e.type;return{"Mod-i":Object(o.r)(t)}}},{key:"commands",value:function(e){var t=e.type;return function(){return Object(o.r)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.e)(/(?:^|[^_])(_([^_]+)_)$/,t),Object(o.e)(/(?:^|[^*])(\*([^*]+)\*)$/,t)]}},{key:"pasteRules",value:function(e){var t=e.type;return[Object(o.f)(/_([^_]+)_/g,t),Object(o.f)(/\*([^*]+)\*/g,t)]}},{key:"name",get:function(){return"italic"}},{key:"schema",get:function(){return{parseDOM:[{tag:"i"},{tag:"em"},{style:"font-style=italic"}],toDOM:function(){return["em",0]}}}}]),t}(),B=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["f"]),v(t,[{key:"commands",value:function(e){var t=e.type;return function(e){return e.href?Object(o.t)(t,e):Object(o.i)(t)}}},{key:"pasteRules",value:function(e){var t=e.type;return[Object(o.h)(/https?:\/\/(www\.)?[-a-zA-Z0-9@:%._+~#=]{2,256}\.[a-zA-Z]{2,}\b([-a-zA-Z0-9@:%_+.~#?&\/\/=]*)/g,t,function(e){return{href:e}})]}},{key:"name",get:function(){return"link"}},{key:"schema",get:function(){return{attrs:{href:{default:null}},inclusive:!1,parseDOM:[{tag:"a[href]",getAttrs:function(e){return{href:e.getAttribute("href")}}}],toDOM:function(e){return["a",b({},e.attrs,{rel:"noopener noreferrer nofollow"}),0]}}}},{key:"plugins",get:function(){return[new r.h({props:{handleClick:function(e,t,n){var r=e.state.schema,o=Object(u.a)(e.state,r.marks.link);o.href&&n.target instanceof HTMLAnchorElement&&(n.stopPropagation(),window.open(o.href))}}})]}}]),t}(),q=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["f"]),v(t,[{key:"keys",value:function(e){var t=e.type;return{"Mod-d":Object(o.r)(t)}}},{key:"commands",value:function(e){var t=e.type;return function(){return Object(o.r)(t)}}},{key:"inputRules",value:function(e){var t=e.type;return[Object(o.e)(/~([^~]+)~$/,t)]}},{key:"pasteRules",value:function(e){var t=e.type;return[Object(o.f)(/~([^~]+)~/g,t)]}},{key:"name",get:function(){return"strike"}},{key:"schema",get:function(){return{parseDOM:[{tag:"s"},{tag:"del"},{tag:"strike"},{style:"text-decoration",getAttrs:function(e){return"line-through"===e}}],toDOM:function(){return["s",0]}}}}]),t}(),V=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["e"]),v(t,[{key:"init",value:function(){var e=this;this.getSendableSteps=this.debounce(function(t){var n=Object(f.sendableSteps)(t);n&&e.options.onSendable({editor:e.editor,sendable:{version:n.version,steps:n.steps.map(function(e){return e.toJSON()}),clientID:n.clientID}})},this.options.debounce),this.editor.on("transaction",function(t){var n=t.state;e.getSendableSteps(n)})}},{key:"debounce",value:function(e,t){var n;return function(){for(var r=arguments.length,o=new Array(r),i=0;ir||s.dispatch(Object(f.receiveTransaction)(i,n.map(function(e){return p.Step.fromJSON(a,e.step)}),n.map(function(e){return e.clientID})))}}}},{key:"plugins",get:function(){return[Object(f.collab)({version:this.options.version,clientID:this.options.clientID})]}}]),t}(),U=function(e){function t(){return d(this,t),_(this,k(t).apply(this,arguments))}return w(t,r["e"]),v(t,[{key:"keys",value:function(){return{"Mod-z":h.undo,"Mod-y":h.redo,"Shift-Mod-z":h.redo}}},{key:"commands",value:function(){return{undo:function(){return h.undo},redo:function(){return h.redo}}}},{key:"name",get:function(){return"history"}},{key:"defaultOptions",get:function(){return{depth:"",newGroupDelay:""}}},{key:"plugins",get:function(){return[Object(h.history)({depth:this.options.depth,newGroupDelay:this.options.newGroupDelay})]}}]),t}()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(41),o=function(e,t,n){this.step=e,this.inverted=t,this.origin=n};function i(e,t,n){for(var r=e.length-1;r>=0;r--)n.step(e[r].inverted);for(var i=0;i=0&&(n=this.attrs[t][1]),n},r.prototype.attrJoin=function(e,t){var n=this.attrIndex(e);n<0?this.attrPush([e,t]):this.attrs[n][1]=this.attrs[n][1]+" "+t},e.exports=r},,,,,,,,,,function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(14).default.create({headers:{requesttoken:OC.requestToken}});t.default=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o,i=n(41),s=n(52),a=n(43),c=n(44),l=n(55);if("undefined"!=typeof WeakMap){var u=new WeakMap;r=function(e){return u.get(e)},o=function(e,t){return u.set(e,t),t}}else{var p=[],f=0;r=function(e){for(var t=0;tr&&(i+=l.attrs.colspan)}for(var u=0;u1&&(n=!0)}-1==t?t=i:t!=i&&(t=Math.max(t,i))}return t}(e),n=e.childCount,r=[],o=0,i=null,s=[],a=0,c=t*n;a=n){(i||(i=[])).push({type:"overlong_rowspan",pos:u,n:y-w});break}for(var k=o+w*t,x=0;x0;t--)if("row"==e.node(t).type.spec.tableRole)return e.node(0).resolve(e.before(t+1));return null}function y(e){for(var t=e.selection.$head,n=t.depth;n>0;n--)if("row"==t.node(n).type.spec.tableRole)return!0;return!1}function b(e){var t=e.selection;return t.$anchorCell?t.$anchorCell.pos>t.$headCell.pos?t.$anchorCell:t.$headCell:t.node&&"cell"==t.node.type.spec.tableRole?t.$anchor:g(t.$head)||function(e){for(var t=e.nodeAfter,n=e.pos;t;t=t.firstChild,n++){var r=t.type.spec.tableRole;if("cell"==r||"header_cell"==r)return e.doc.resolve(n)}for(var o=e.nodeBefore,i=e.pos;o;o=o.lastChild,i--){var s=o.type.spec.tableRole;if("cell"==s||"header_cell"==s)return e.doc.resolve(i-o.nodeSize)}}(t.$head)}function w(e){return"row"==e.parent.type.spec.tableRole&&e.nodeAfter}function k(e){return e.node(0).resolve(e.pos+e.nodeAfter.nodeSize)}function x(e,t){return e.depth==t.depth&&e.pos>=t.start(-1)&&e.pos<=t.end(-1)}function _(e,t,n){var r=e.start(-1),o=d.get(e.node(-1)).nextCell(e.pos-r,t,n);return null==o?null:e.node(0).resolve(r+o)}function C(e,t,n){var r={};for(var o in e)r[o]=e[o];return r[t]=n,r}function S(e,t,n){void 0===n&&(n=1);var r=C(e,"colspan",e.colspan-n);return r.colwidth&&(r.colwidth=r.colwidth.slice(),r.colwidth.splice(t,n),r.colwidth.some(function(e){return e>0})||(r.colwidth=null)),r}function O(e,t,n){void 0===n&&(n=1);var r=C(e,"colspan",e.colspan+n);if(r.colwidth){r.colwidth=r.colwidth.slice();for(var o=0;o0||v>0){var g=h.attrs;m>0&&(g=S(g,0,m)),v>0&&(g=S(g,g.colspan-v,v)),h=f.leftr.bottom){var y=C(h.attrs,"rowspan",Math.min(f.bottom,r.bottom)-Math.max(f.top,r.top));h=f.top0)return!1;var n=e+this.$anchorCell.nodeAfter.attrs.rowspan,r=t+this.$headCell.nodeAfter.attrs.rowspan;return Math.max(n,r)==this.$headCell.node(-1).childCount},t.colSelection=function(e,n){void 0===n&&(n=e);var r=d.get(e.node(-1)),o=e.start(-1),i=r.findCell(e.pos-o),s=r.findCell(n.pos-o),a=e.node(0);return i.top<=s.top?(i.top>0&&(e=a.resolve(o+r.map[i.left])),s.bottom0&&(n=a.resolve(o+r.map[s.left])),i.bottom0)return!1;var o=n+this.$anchorCell.nodeAfter.attrs.colspan,i=r+this.$headCell.nodeAfter.attrs.colspan;return Math.max(o,i)==e.width},t.prototype.eq=function(e){return e instanceof t&&e.$anchorCell.pos==this.$anchorCell.pos&&e.$headCell.pos==this.$headCell.pos},t.rowSelection=function(e,n){void 0===n&&(n=e);var r=d.get(e.node(-1)),o=e.start(-1),i=r.findCell(e.pos-o),s=r.findCell(n.pos-o),a=e.node(0);return i.left<=s.left?(i.left>0&&(e=a.resolve(o+r.map[i.top*r.width])),s.right0&&(n=a.resolve(o+r.map[s.top*r.width])),i.right0&&r>0||"table"==t.firstChild.type.spec.tableRole);)n--,r--,t=t.firstChild.content;var o=t.firstChild,i=o.type.spec.tableRole,s=o.type.schema,c=[];if("row"==i)for(var l=0;l=0;i--)for(var s=o.child(i).attrs,c=s.rowspan,l=s.colspan,u=r;u=t.length&&t.push(a.Fragment.empty),n[h]t&&(d=d.type.create(S(d.attrs,d.attrs.colspan,f+d.attrs.colspan-t),d.content)),p.push(d),f+=d.attrs.colspan;for(var m=1;mn&&(x=x.type.create(C(x.attrs,"rowspan",n-x.attrs.rowspan),x.content)),b.push(x)}v.push(a.Fragment.from(b))}i=v,o=n}return{width:r,height:o,rows:i}}function z(e,t,n,r,o,i,s,a){if(0==s||s==t.height)return!1;for(var c=!1,l=o;lt.width)for(var p=0,f=0;pt.height){for(var g=[],y=0,b=(t.height-1)*t.width;y=t.width)&&n.nodeAt(t.map[b+y]).type==u.header_cell;g.push(w?l||(l=u.header_cell.createAndFill()):c||(c=u.cell.createAndFill()))}for(var k=u.row.create(null,a.Fragment.from(g)),x=[],_=t.height;_=0;o--){var s=r.node(o);if((n<0?r.index(o):r.indexAfter(o))!=(n<0?0:s.childCount))return null;if("cell"==s.type.spec.tableRole||"header_cell"==s.type.spec.tableRole){var a=r.before(o),c="vert"==t?n>0?"down":"up":n>0?"right":"left";return e.endOfTextblock(c)?a:null}}return null}function G(e,t){for(;t&&t!=e.dom;t=t.parentNode)if("TD"==t.nodeName||"TH"==t.nodeName)return t}function K(e,t){var n=e.posAtCoords({left:t.clientX,top:t.clientY});return n&&n?g(e.state.doc.resolve(n.pos)):null}function Z(e,t){var n,r=function(t,r){"table"==t.type.spec.tableRole&&(n=function(e,t,n,r){var o=d.get(t);if(!o.problems)return r;r||(r=e.tr);for(var i,s,a=[],c=0;c0){var x="cell";b.firstChild&&(x=b.firstChild.type.spec.tableRole);for(var _=[],O=0;O0?-1:0;(function(e,t,n){for(var r=N(t.type.schema).header_cell,o=0;o0&&n0&&r.map[c-1]==l||n0?-1:0;(function(e,t,n){for(var r=N(t.type.schema).header_cell,o=0;o0&&n0&&f==r.map[p-r.width]){var h=o.nodeAt(f).attrs;e.setNodeMarkup(e.mapping.slice(l).map(f+i),null,C(h,"rowspan",h.rowspan-1)),u+=h.colspan-1}else if(n0;t--){var n=e.node(t).type.spec.tableRole;if("cell"===n||"header_cell"===n)return e.node(t)}return null}(i.$from)))return!1;o=g(i.$from).pos}if(1==r.attrs.colspan&&1==r.attrs.rowspan)return!1;if(n){var s=r.attrs,a=[],c=s.colwidth;s.rowspan>1&&(s=C(s,"rowspan",1)),s.colspan>1&&(s=C(s,"colspan",1));for(var l,u=X(t),p=t.tr,f=0;f-1&&e.docChanged){var r=e.mapping.map(t.activeHandle,-1);w(e.doc.resolve(r))||(r=null),t=new fe(r,t.dragging)}return t},t.tableEditing=function(e){void 0===e&&(e={});var t=e.allowTableNodeSelection;return void 0===t&&(t=!1),new i.Plugin({key:v,state:{init:function(){return null},apply:function(e,t){var n=e.getMeta(v);if(null!=n)return-1==n?null:n;if(null==t||!e.docChanged)return t;var r=e.mapping.mapResult(t),o=r.deleted,i=r.pos;return o?null:i}},props:{decorations:M,handleDOMEvents:{mousedown:W},createSelectionBetween:function(e){if(null!=v.getState(e.state))return e.state.selection},handleTripleClick:U,handleKeyDown:L,handlePaste:H},appendTransaction:function(e,n,r){return function(e,t,n){var r,o,s=(t||e).selection,a=(t||e).doc;if(s instanceof i.NodeSelection&&(o=s.node.type.spec.tableRole)){if("cell"==o||"header_cell"==o)r=A.create(a,s.from);else if("row"==o){var c=a.resolve(s.from+1);r=A.rowSelection(c,c)}else if(!n){var l=d.get(s.node),u=s.from+1,p=u+l.map[l.width*l.height-1];r=A.create(a,u+1,p)}}else s instanceof i.TextSelection&&function(e){var t=e.$from,n=e.$to;if(t.pos==n.pos||t.pos=0&&!(t.after(i+1)=0&&!(n.before(s+1)>n.start(s));s--,o--);return r==o&&/row|table/.test(t.node(i).type.spec.tableRole)}(s)?r=i.TextSelection.create(a,s.from):s instanceof i.TextSelection&&function(e){for(var t,n,r=e.$from,o=e.$to,i=r.depth;i>0;i--){var s=r.node(i);if("cell"===s.type.spec.tableRole||"header_cell"===s.type.spec.tableRole){t=s;break}}for(var a=o.depth;a>0;a--){var c=o.node(a);if("cell"===c.type.spec.tableRole||"header_cell"===c.type.spec.tableRole){n=c;break}}return t!==n&&0===o.parentOffset}(s)&&(r=i.TextSelection.create(a,s.$from.start(),s.$from.end()));return r&&(t||(t=e.tr)).setSelection(r),t}(r,Z(r,n),t)}})},t.fixTables=Z,t.handlePaste=H,t.cellAround=g,t.isInTable=y,t.selectionCell=b,t.moveCellForward=k,t.inSameTable=x,t.findCell=function(e){return d.get(e.node(-1)).findCell(e.pos-e.start(-1))},t.colCount=function(e){return d.get(e.node(-1)).colCount(e.pos-e.start(-1))},t.nextCell=_,t.tableNodes=function(e){var t=e.cellAttributes||{},n={colspan:{default:1},rowspan:{default:1},colwidth:{default:null}};for(var r in t)n[r]={default:t[r].default};return{table:{content:"table_row+",tableRole:"table",isolating:!0,group:e.tableGroup,parseDOM:[{tag:"table"}],toDOM:function(){return["table",["tbody",0]]}},table_row:{content:"(table_cell | table_header)*",tableRole:"row",parseDOM:[{tag:"tr"}],toDOM:function(){return["tr",0]}},table_cell:{content:e.cellContent,attrs:n,tableRole:"cell",isolating:!0,parseDOM:[{tag:"td",getAttrs:function(e){return T(e,t)}}],toDOM:function(e){return["td",D(e,t),0]}},table_header:{content:e.cellContent,attrs:n,tableRole:"header_cell",isolating:!0,parseDOM:[{tag:"th",getAttrs:function(e){return T(e,t)}}],toDOM:function(e){return["th",D(e,t),0]}}}},t.CellSelection=A,t.TableMap=d,t.columnResizing=function(e){void 0===e&&(e={});var t=e.handleWidth;void 0===t&&(t=5);var n=e.cellMinWidth;void 0===n&&(n=25);var r=e.View;void 0===r&&(r=le);var o=e.lastColumnResizable;return void 0===o&&(o=!0),new i.Plugin({key:pe,state:{init:function(e,t){return this.spec.props.nodeViews[N(t.schema).table.name]=function(e,t){return new r(e,n,t)},new fe(-1,!1)},apply:function(e,t){return t.apply(e)}},props:{attributes:function(e){return pe.getState(e).activeHandle>-1?{class:"resize-cursor"}:null},handleDOMEvents:{mousemove:function(e,n){!function(e,t,n,r,o){var i=pe.getState(e.state);if(!i.dragging){var s=function(e){for(;e&&"TD"!=e.nodeName&&"TH"!=e.nodeName;)e=e.classList.contains("ProseMirror")?null:e.parentNode;return e}(t.target),a=-1;if(s){var c=s.getBoundingClientRect(),l=c.left,u=c.right;t.clientX-l<=n?a=he(e,t,"left"):u-t.clientX<=n&&(a=he(e,t,"right"))}if(a!=i.activeHandle){if(!o&&-1!==a){var p=e.state.doc.resolve(a),f=p.node(-1),h=d.get(f),m=p.start(-1);if(h.colCount(p.pos-m)+p.nodeAfter.attrs.colspan-1==h.width-1)return}me(e,a)}}}(e,n,t,0,o)},mouseleave:function(e){!function(e){var t=pe.getState(e.state);t.activeHandle>-1&&!t.dragging&&me(e,-1)}(e)},mousedown:function(e,t){!function(e,t,n){var r=pe.getState(e.state);if(-1==r.activeHandle||r.dragging)return!1;var o=e.state.doc.nodeAt(r.activeHandle),i=function(e,t,n){var r=n.colspan,o=n.colwidth,i=o&&o[o.length-1];if(i)return i;var s=e.domAtPos(t),a=s.node.childNodes[s.offset].offsetWidth,c=r;if(o)for(var l=0;l-1)return function(e,t){for(var n=[],r=e.doc.resolve(t),o=r.node(-1),i=d.get(o),a=r.start(-1),c=i.colCount(r.pos-a)+r.nodeAfter.attrs.colspan,l=0;l0&&o[s]==o[s-1]||t.right0&&o[i]==o[i-n]||t.bottom=0;r--){var i=e.node(-1).child(r);if(i.childCount)return o-1-i.lastChild.nodeSize;o-=i.nodeSize}}else{if(e.index()0;r--){if("table"==n.node(r).type.spec.tableRole)return t&&t(e.tr.delete(n.before(r),n.after(r)).scrollIntoView()),!0}return!1}},function(e,t,n){"use strict";n.d(t,"c",function(){return u}),n.d(t,"e",function(){return f}),n.d(t,"f",function(){return m}),n.d(t,"g",function(){return h}),n.d(t,"h",function(){return d}),n.d(t,"i",function(){return v}),n.d(t,"j",function(){return g}),n.d(t,"n",function(){return y}),n.d(t,"p",function(){return b}),n.d(t,"q",function(){return k}),n.d(t,"s",function(){return x}),n.d(t,"t",function(){return _});var r=n(39);n.d(t,"a",function(){return r.chainCommands}),n.d(t,"b",function(){return r.exitCode}),n.d(t,"k",function(){return r.setBlockType}),n.d(t,"r",function(){return r.toggleMark});var o=n(42);n.d(t,"d",function(){return o.liftListItem}),n.d(t,"l",function(){return o.sinkListItem}),n.d(t,"m",function(){return o.splitListItem});var i=n(45);n.d(t,"o",function(){return i.textblockTypeInputRule}),n.d(t,"u",function(){return i.wrappingInputRule});var s=n(41),a=n(43),c=n(72),l=n(49); /*! * tiptap-commands v1.10.12 * (c) 2019 Scrumpy UG (limited liability) * @license MIT */ function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return function(t,n){var r=t.selection.$from.pos.pos;return n(t.tr.insertText(e,r)),!0}}function p(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);tf}).length)return!1;mf&&a.delete(f,d),l=(u=f)+r[c].length}return a.addMark(u,l,t.create(s)),a.removeStoredMark(t),a})}function h(e,t,n){return new i.InputRule(e,function(e,r,o,i){var s=n instanceof Function?n(r):n,a=e.tr;return r[0]&&a.replaceWith(o-1,i,t.create(s)),a})}function d(e,t,n){return new s.Plugin({props:{transformPasted:function(r){return new a.Slice(function r(o){var i=[];return o.forEach(function(o){if(o.isText){var s,a=o.text,c=0;do{if(s=e.exec(a)){var l=s.index,u=l+s[0].length,p=n instanceof Function?n(s[0]):n;l>0&&i.push(o.cut(c,l)),i.push(o.cut(l,u).mark(t.create(p).addToSet(o.marks))),c=u}}while(s);c0&&i.push(o.cut(c,u)),i.push(o.cut(f,h).mark(t.create(d).addToSet(o.marks))),c=p}c0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return function(r,o){var i=r.selection,s=i.$from,a=i.$to,c=s.index(),l=e?e.from:s.pos,u=e?e.to:a.pos;return!!s.parent.canReplaceWith(c,c,t)&&(o&&o(r.tr.replaceWith(l,u,t.create(n))),!0)}}function y(e){return function(t,n){var r=t.selection,o=r.$from,i=r.$to,s=r.node;if(s&&s.isBlock||o.depth<2||!o.sameParent(i))return!1;var c=o.node(-1);if(c.type!=e)return!1;if(0==o.parent.content.size){if(2==o.depth||o.node(-3).type!=e||o.index(-2)!=o.node(-2).childCount-1)return!1;if(n){for(var l=a.Fragment.empty,u=o.index(-1)>0,p=o.depth-(u?1:2);p>=o.depth-3;p--)l=a.Fragment.from(o.node(p).copy(l));l=l.append(a.Fragment.from(e.createAndFill()));var f=t.tr.replace(o.before(u?null:-1),o.after(-3),new a.Slice(l,u?3:2,2));f.setSelection(t.selection.constructor.near(f.doc.resolve(o.pos+(u?3:2)))),n(f.scrollIntoView())}return!0}var h=i.pos==o.end()?c.contentMatchAt(o.indexAfter(-1)).defaultType:null,d=t.tr.delete(o.pos,i.pos),m=h&&[{type:e},{type:h}];return m||(m=[{type:e},null]),!!function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3?arguments[3]:void 0,o=e.resolve(t),i=o.depth-n,s=r&&r[r.length-1]||o.parent;if(i<0||o.parent.type.spec.isolating||!o.parent.canReplace(o.index(),o.parent.childCount)||!s.type.validContent(o.parent.content.cutByIndex(o.index(),o.parent.childCount)))return!1;for(var a=o.depth-1,c=n-2;a>i;a--,c--){var l=o.node(a),u=o.index(a);if(l.type.spec.isolating)return!1;var p=l.content.cutByIndex(u,l.childCount),f=r&&r[c]||l;if(f!=l&&(p=p.replaceChild(0,f.type.create(f.attrs))),!l.canReplace(u+1,l.childCount))return!1}var h=o.indexAfter(i),d=r&&r[0];return o.node(i).canReplaceWith(h,h,d?d.type:o.node(i+1).type)}(d.doc,o.pos,2,m)&&(n&&n(d.split(o.pos,2,m).scrollIntoView()),!0)}}function b(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return function(o,i,s){return Object(c.c)(o,e,n)?Object(r.setBlockType)(t)(o,i,s):Object(r.setBlockType)(e,n)(o,i,s)}}function w(e,t){return e.type===t.nodes.bullet_list||e.type===t.nodes.ordered_list||e.type===t.nodes.todo_list}function k(e,t){return function(n,r,i){var s=n.schema,a=n.selection,c=a.$from,u=a.$to,p=c.blockRange(u);if(!p)return!1;var f=Object(l.findParentNode)(function(e){return w(e,s)})(a);if(p.depth>=1&&f&&p.depth-f.depth<=1){if(f.node.type===e)return Object(o.liftListItem)(t)(n,r,i);if(w(f.node,s)&&e.validContent(f.node.content)){var h=n.tr;return h.setNodeMarkup(f.pos,e),r&&r(h),!1}}return Object(o.wrapInList)(e)(n,r,i)}}function x(e){return function(t,n,o){return Object(c.c)(t,e)?Object(r.lift)(t,n):Object(r.wrapIn)(e)(t,n,o)}}function _(e,t){return function(n,r){var o=n.selection,i=o.from,s=o.to;return r(n.tr.addMark(i,s,e.create(t)))}}},function(e,t,n){"use strict";n.d(t,"a",function(){return i}),n.d(t,"b",function(){return s}),n.d(t,"c",function(){return a});var r=n(49); /*! * tiptap-utils v1.6.1 * (c) 2019 Scrumpy UG (limited liability) * @license MIT */ function o(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t2&&void 0!==arguments[2]?arguments[2]:{},o=Object(r.findSelectedNodeOfType)(t)(e.selection)||Object(r.findParentNode)(function(e){return e.type===t})(e.selection);return Object.keys(n).length&&o?o.node.hasMarkup(t,n):!!o}},function(e,t,n){"use strict";e.exports=n(283)},function(e,t,n){"use strict";e.exports=n(284)},function(e,t,n){"use strict";e.exports.encode=n(285),e.exports.decode=n(286),e.exports.format=n(287),e.exports.parse=n(288)},function(e,t){e.exports=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/},function(e,t){e.exports=/[\0-\x1F\x7F-\x9F]/},function(e,t){e.exports=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/},function(e,t,n){"use strict";var r="<[A-Za-z][A-Za-z0-9\\-]*(?:\\s+[a-zA-Z_:][a-zA-Z0-9:._-]*(?:\\s*=\\s*(?:[^\"'=<>`\\x00-\\x20]+|'[^']*'|\"[^\"]*\"))?)*\\s*\\/?>",o="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",i=new RegExp("^(?:"+r+"|"+o+"|\x3c!----\x3e|\x3c!--(?:-?[^>-])(?:-?[^-])*--\x3e|<[?].*?[?]>|]*>|)"),s=new RegExp("^(?:"+r+"|"+o+")");e.exports.HTML_TAG_RE=i,e.exports.HTML_OPEN_CLOSE_TAG_RE=s},function(e,t,n){"use strict";e.exports.tokenize=function(e,t){var n,r,o,i,s=e.pos,a=e.src.charCodeAt(s);if(t)return!1;if(126!==a)return!1;if(o=(r=e.scanDelims(e.pos,!0)).length,i=String.fromCharCode(a),o<2)return!1;for(o%2&&(e.push("text","",0).content=i,o--),n=0;n=0;t--)95!==(n=a[t]).marker&&42!==n.marker||-1!==n.end&&(r=a[n.end],s=t>0&&a[t-1].end===n.end+1&&a[t-1].token===n.token-1&&a[n.end+1].token===r.token+1&&a[t-1].marker===n.marker,i=String.fromCharCode(n.marker),(o=e.tokens[n.token]).type=s?"strong_open":"em_open",o.tag=s?"strong":"em",o.nesting=1,o.markup=s?i+i:i,o.content="",(o=e.tokens[r.token]).type=s?"strong_close":"em_close",o.tag=s?"strong":"em",o.nesting=-1,o.markup=s?i+i:i,o.content="",s&&(e.tokens[a[t-1].token].content="",e.tokens[a[n.end+1].token].content="",t--))}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t){function n(e){this.content=e}n.prototype={constructor:n,find:function(e){for(var t=0;t>1}},n.from=function(e){if(e instanceof n)return e;var t=[];if(e)for(var r in e)t.push(r,e[r]);return new n(t)},e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(41),o=n(44);var i=function(e,t){var n=this;this.editorView=e,this.width=t.width||1,this.color=t.color||"black",this.cursorPos=null,this.element=null,this.timeout=null,this.handlers=["dragover","dragend","drop","dragleave"].map(function(t){var r=function(e){return n[t](e)};return e.dom.addEventListener(t,r),{name:t,handler:r}})};i.prototype.destroy=function(){var e=this;this.handlers.forEach(function(t){var n=t.name,r=t.handler;return e.editorView.dom.removeEventListener(n,r)})},i.prototype.update=function(e,t){null!=this.cursorPos&&t.doc!=e.state.doc&&this.updateOverlay()},i.prototype.setCursor=function(e){e!=this.cursorPos&&(this.cursorPos=e,null==e?(this.element.remove(),this.element=null):this.updateOverlay())},i.prototype.updateOverlay=function(){var e,t=this.editorView.state.doc.resolve(this.cursorPos);if(!t.parent.inlineContent){var n=t.nodeBefore,r=t.nodeAfter;if(n||r){var o=this.editorView.nodeDOM(this.cursorPos-(n?n.nodeSize:0)).getBoundingClientRect(),i=n?o.bottom:o.top;n&&r&&(i=(i+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2),e={left:o.left,right:o.right,top:i-this.width/2,bottom:i+this.width/2}}}if(!e){var s=this.editorView.coordsAtPos(this.cursorPos);e={left:s.left-this.width/2,right:s.left+this.width/2,top:s.top,bottom:s.bottom}}var a=this.editorView.dom.offsetParent;this.element||(this.element=a.appendChild(document.createElement("div")),this.element.style.cssText="position: absolute; z-index: 50; pointer-events: none; background-color: "+this.color);var c=a==document.body&&"static"==getComputedStyle(a).position?{left:-pageXOffset,top:-pageYOffset}:a.getBoundingClientRect();this.element.style.left=e.left-c.left+"px",this.element.style.top=e.top-c.top+"px",this.element.style.width=e.right-e.left+"px",this.element.style.height=e.bottom-e.top+"px"},i.prototype.scheduleRemoval=function(e){var t=this;clearTimeout(this.timeout),this.timeout=setTimeout(function(){return t.setCursor(null)},e)},i.prototype.dragover=function(e){var t=this.editorView.posAtCoords({left:e.clientX,top:e.clientY});if(t){var n=t.pos;this.editorView.dragging&&this.editorView.dragging.slice&&null==(n=o.dropPoint(this.editorView.state.doc,n,this.editorView.dragging.slice))&&(n=t.pos),this.setCursor(n),this.scheduleRemoval(5e3)}},i.prototype.dragend=function(){this.scheduleRemoval(20)},i.prototype.drop=function(){this.scheduleRemoval(20)},i.prototype.dragleave=function(e){e.target!=this.editorView.dom&&this.editorView.dom.contains(e.relatedTarget)||this.setCursor(null)},t.dropCursor=function(e){return void 0===e&&(e={}),new r.Plugin({view:function(t){return new i(t,e)}})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(55),o=n(41),i=n(52),s=n(43),a=function(e){function t(t){e.call(this,t,t)}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.map=function(n,r){var o=n.resolve(r.map(this.head));return t.valid(o)?new t(o):e.near(o)},t.prototype.content=function(){return s.Slice.empty},t.prototype.eq=function(e){return e instanceof t&&e.head==this.head},t.prototype.toJSON=function(){return{type:"gapcursor",pos:this.head}},t.fromJSON=function(e,n){if("number"!=typeof n.pos)throw new RangeError("Invalid input for GapCursor.fromJSON");return new t(e.resolve(n.pos))},t.prototype.getBookmark=function(){return new c(this.anchor)},t.valid=function(e){var t=e.parent;if(t.isTextblock||!function(e){for(var t=e.depth;t>=0;t--){var n=e.index(t);if(0!=n)for(var r=e.node(t).child(n-1);;r=r.lastChild){if(0==r.childCount&&!r.inlineContent||r.isAtom||r.type.spec.isolating)return!0;if(r.inlineContent)return!1}}return!0}(e)||!function(e){for(var t=e.depth;t>=0;t--){var n=e.indexAfter(t),r=e.node(t);if(n!=r.childCount)for(var o=r.child(n);;o=o.firstChild){if(0==o.childCount&&!o.inlineContent||o.isAtom||o.type.spec.isolating)return!0;if(o.inlineContent)return!1}}return!0}(e))return!1;var n=t.type.spec.allowGapCursor;if(null!=n)return n;var r=t.contentMatchAt(e.index()).defaultType;return r&&r.isTextblock},t.findFrom=function(e,n,r){if(!r&&t.valid(e))return e;for(var o=e.pos,i=null,s=e.depth;;s--){var a=e.node(s);if(n>0?e.indexAfter(s)0){i=a.maybeChild(n>0?e.indexAfter(s):e.index(s)-1);break}if(0==s)return null;o+=n;var c=e.doc.resolve(o);if(t.valid(c))return c}for(;i=n>0?i.firstChild:i.lastChild;){o+=n;var l=e.doc.resolve(o);if(t.valid(l))return l}return null},t}(o.Selection);a.prototype.visible=!1,o.Selection.jsonID("gapcursor",a);var c=function(e){this.pos=e};c.prototype.map=function(e){return new c(e.map(this.pos))},c.prototype.resolve=function(e){var t=e.resolve(this.pos);return a.valid(t)?new a(t):o.Selection.near(t)};var l=r.keydownHandler({ArrowLeft:u("horiz",-1),ArrowRight:u("horiz",1),ArrowUp:u("vert",-1),ArrowDown:u("vert",1)});function u(e,t){var n="vert"==e?t>0?"down":"up":t>0?"right":"left";return function(e,r,i){var s=e.selection,c=t>0?s.$to:s.$from,l=s.empty;if(s instanceof o.TextSelection){if(!i.endOfTextblock(n))return!1;l=!1,c=e.doc.resolve(t>0?c.after():c.before())}var u=a.findFrom(c,t,l);return!!u&&(r&&r(e.tr.setSelection(new a(u))),!0)}}function p(e,t,n){if(e.someProp("editable",function(t){return!1===t(e.state)}))return!1;var r=e.state.doc.resolve(t);if(!a.valid(r))return!1;var i=e.posAtCoords({left:n.clientX,top:n.clientY}).inside;return!(i>-1&&o.NodeSelection.isSelectable(e.state.doc.nodeAt(i)))&&(e.dispatch(e.state.tr.setSelection(new a(r))),!0)}function f(e){if(!(e.selection instanceof a))return null;var t=document.createElement("div");return t.className="ProseMirror-gapcursor",i.DecorationSet.create(e.doc,[i.Decoration.widget(e.selection.head,t,{key:"gapcursor"})])}t.gapCursor=function(){return new o.Plugin({props:{decorations:f,createSelectionBetween:function(e,t,n){if(t.pos==n.pos&&a.valid(n))return new a(n)},handleClick:p,handleKeyDown:l}})},t.GapCursor=a},function(e,t){for(var n={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",229:"q"},r={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:";",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"',229:"Q"},o="undefined"!=typeof navigator&&/Chrome\/(\d+)/.exec(navigator.userAgent),i="undefined"!=typeof navigator&&/Apple Computer/.test(navigator.vendor),s="undefined"!=typeof navigator&&/Gecko\/\d+/.test(navigator.userAgent),a="undefined"!=typeof navigator&&/Mac/.test(navigator.platform),c=o&&(a||+o[1]<57)||s&&a,l=0;l<10;l++)n[48+l]=n[96+l]=String(l);for(l=1;l<=24;l++)n[l+111]="F"+l;for(l=65;l<=90;l++)n[l]=String.fromCharCode(l+32),r[l]=String.fromCharCode(l);for(var u in n)r.hasOwnProperty(u)||(r[u]=n[u]);function p(e){var t=!(c&&(e.ctrlKey||e.altKey||e.metaKey)||i&&e.shiftKey&&e.key&&1==e.key.length)&&e.key||(e.shiftKey?r:n)[e.keyCode]||e.key||"Unidentified";return"Esc"==t&&(t="Escape"),"Del"==t&&(t="Delete"),"Left"==t&&(t="ArrowLeft"),"Up"==t&&(t="ArrowUp"),"Right"==t&&(t="ArrowRight"),"Down"==t&&(t="ArrowDown"),t}e.exports=p,p.base=n,p.shift=r},function(e,t,n){"use strict";var r=n(276),o=n(277);function i(){}i.prototype=r;var s=new i;e.exports=s,s.highlight=function(e,t,n){var r=(n||{}).prefix;null==r&&(r=u);return k(w(e,t,!0,r))},s.highlightAuto=y,s.registerLanguage=function(e,t){var n=t(s);v[e]=n,m.push(e),n.aliases&&b(e,n.aliases)},s.listLanguages=function(){return m.concat()},s.registerAlias=b,s.getLanguage=C;var a=r.inherit,c={}.hasOwnProperty,l=[].concat,u="hljs-",p="case_insensitive",f="cached_variants",h=" ",d="|",m=[],v={},g={};function y(e,t){var n,r,i,s,a=t||{},c=a.subset||m,l=a.prefix,p=c.length,f=-1;if(null==l&&(l=u),"string"!=typeof e)throw o("Expected `string` for value, got `%s`",e);for(r=k({}),n=k({});++fr.relevance&&(r=i),i.relevance>n.relevance&&(r=n,n=i));return r.language&&(n.secondBest=r),n}function b(e,t){var n,r,o,i,s=e;for(n in t&&((s={})[e]=t),s)for(o=(r="string"==typeof(r=s[n])?[r]:r).length,i=-1;++i");return M+=t,t.length||1}function N(e,t){var n;e.className&&(n=j(e.className,[])),e.returnBegin?M="":e.excludeBegin?(P(t,g),M=""):M=t,n&&(g.push(n),E.push(g),g=n.children),u=Object.create(e,{parent:{value:u}})}function R(){var e=u.subLanguage?function(){var e,t="string"==typeof u.subLanguage;if(t&&!v[u.subLanguage])return P(M,[]);e=t?w(u.subLanguage,M,!0,r,A[u.subLanguage]):y(M,{subset:0===u.subLanguage.length?void 0:u.subLanguage,prefix:r});if(!e.language)return[z(M)];u.relevance>0&&(T+=e.relevance);t&&(A[u.subLanguage]=e.top);return[j(e.language,e.value,!0)]}():function(){var e,t,n,r,o=[];if(!u.keywords)return P(M,o);e=0,u.lexemesRe.lastIndex=0,t=u.lexemesRe.exec(M);for(;t;)P(M.substring(e,t.index),o),(r=F(u,t))?(T+=r[1],n=j(r[0],[]),o.push(n),P(t[0],n.children)):P(t[0],o),e=u.lexemesRe.lastIndex,t=u.lexemesRe.exec(M);return P(M.substr(e),o),o}();return M="",e}function I(e,t){for(var n,r=e.length,o=-1;++o]+>|\t|)+|(?:\n)))/gm,l="",u={classPrefix:"hljs-",tabReplace:null,useBR:!1,languages:void 0};function p(e){return e.replace(/&/g,"&").replace(//g,">")}function f(e){return e.nodeName.toLowerCase()}function h(e,t){var n=e&&e.exec(t);return n&&0===n.index}function d(e){return s.test(e)}function m(e){var t,n={},r=Array.prototype.slice.call(arguments,1);for(t in e)n[t]=e[t];return r.forEach(function(e){for(t in e)n[t]=e[t]}),n}function v(e){var t=[];return function e(n,r){for(var o=n.firstChild;o;o=o.nextSibling)3===o.nodeType?r+=o.nodeValue.length:1===o.nodeType&&(t.push({event:"start",offset:r,node:o}),r=e(o,r),f(o).match(/br|hr|img|input/)||t.push({event:"stop",offset:r,node:o}));return r}(e,0),t}function g(e){if(t&&!e.langApiRestored){for(var n in e.langApiRestored=!0,t)e[n]&&(e[t[n]]=e[n]);(e.contains||[]).concat(e.variants||[]).forEach(g)}}function y(e){function t(e){return e&&e.source||e}function n(n,r){return new RegExp(t(n),"m"+(e.case_insensitive?"i":"")+(r?"g":""))}!function o(i,s){if(!i.compiled){if(i.compiled=!0,i.keywords=i.keywords||i.beginKeywords,i.keywords){var a={},c=function(t,n){e.case_insensitive&&(n=n.toLowerCase()),n.split(" ").forEach(function(e){var n=e.split("|");a[n[0]]=[t,n[1]?Number(n[1]):1]})};"string"==typeof i.keywords?c("keyword",i.keywords):r(i.keywords).forEach(function(e){c(e,i.keywords[e])}),i.keywords=a}i.lexemesRe=n(i.lexemes||/\w+/,!0),s&&(i.beginKeywords&&(i.begin="\\b("+i.beginKeywords.split(" ").join("|")+")\\b"),i.begin||(i.begin=/\B|\b/),i.beginRe=n(i.begin),i.endSameAsBegin&&(i.end=i.begin),i.end||i.endsWithParent||(i.end=/\B|\b/),i.end&&(i.endRe=n(i.end)),i.terminator_end=t(i.end)||"",i.endsWithParent&&s.terminator_end&&(i.terminator_end+=(i.end?"|":"")+s.terminator_end)),i.illegal&&(i.illegalRe=n(i.illegal)),null==i.relevance&&(i.relevance=1),i.contains||(i.contains=[]),i.contains=Array.prototype.concat.apply([],i.contains.map(function(e){return function(e){return e.variants&&!e.cached_variants&&(e.cached_variants=e.variants.map(function(t){return m(e,{variants:null},t)})),e.cached_variants||e.endsWithParent&&[m(e)]||[e]}("self"===e?i:e)})),i.contains.forEach(function(e){o(e,i)}),i.starts&&o(i.starts,s);var l=i.contains.map(function(e){return e.beginKeywords?"\\.?(?:"+e.begin+")\\.?":e.begin}).concat([i.terminator_end,i.illegal]).map(t).filter(Boolean);i.terminators=l.length?n(function(e,n){for(var r=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./,o=0,i="",s=0;s0&&(i+=n);c.length>0;){var l=r.exec(c);if(null==l){i+=c;break}i+=c.substring(0,l.index),c=c.substring(l.index+l[0].length),"\\"==l[0][0]&&l[1]?i+="\\"+String(Number(l[1])+a):(i+=l[0],"("==l[0]&&o++)}}return i}(l,"|"),!0):{exec:function(){return null}}}}(e)}function b(e,t,n,r){function i(e){return new RegExp(e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"),"m")}function s(e,t){var n=m.case_insensitive?t[0].toLowerCase():t[0];return e.keywords.hasOwnProperty(n)&&e.keywords[n]}function a(e,t,n,r){var o='')+t+(n?"":l):t}function c(){x+=null!=g.subLanguage?function(){var e="string"==typeof g.subLanguage;if(e&&!o[g.subLanguage])return p(_);var t=e?b(g.subLanguage,_,!0,k[g.subLanguage]):w(_,g.subLanguage.length?g.subLanguage:void 0);return g.relevance>0&&(S+=t.relevance),e&&(k[g.subLanguage]=t.top),a(t.language,t.value,!1,!0)}():function(){var e,t,n,r;if(!g.keywords)return p(_);for(r="",t=0,g.lexemesRe.lastIndex=0,n=g.lexemesRe.exec(_);n;)r+=p(_.substring(t,n.index)),(e=s(g,n))?(S+=e[1],r+=a(e[0],p(n[0]))):r+=p(n[0]),t=g.lexemesRe.lastIndex,n=g.lexemesRe.exec(_);return r+p(_.substr(t))}(),_=""}function f(e){x+=e.className?a(e.className,"",!0):"",g=Object.create(e,{parent:{value:g}})}function d(e,t){if(_+=e,null==t)return c(),0;var r=function(e,t){var n,r;for(n=0,r=t.contains.length;n")+'"');return _+=t,t.length||1}var m=C(e);if(!m)throw new Error('Unknown language: "'+e+'"');y(m);var v,g=r||m,k={},x="";for(v=g;v!==m;v=v.parent)v.className&&(x=a(v.className,"",!0)+x);var _="",S=0;try{for(var O,A,E=0;g.terminators.lastIndex=E,O=g.terminators.exec(t);)A=d(t.substring(E,O.index),O[0]),E=O.index+A;for(d(t.substr(E)),v=g;v.parent;v=v.parent)v.className&&(x+=l);return{relevance:S,value:x,language:e,top:g}}catch(e){if(e.message&&-1!==e.message.indexOf("Illegal"))return{relevance:0,value:p(t)};throw e}}function w(e,t){t=t||u.languages||r(o);var n={relevance:0,value:p(e)},i=n;return t.filter(C).filter(S).forEach(function(t){var r=b(t,e,!1);r.language=t,r.relevance>i.relevance&&(i=r),r.relevance>n.relevance&&(i=n,n=r)}),i.language&&(n.second_best=i),n}function k(e){return u.tabReplace||u.useBR?e.replace(c,function(e,t){return u.useBR&&"\n"===e?"
":u.tabReplace?t.replace(/\t/g,u.tabReplace):""}):e}function x(e){var t,r,o,s,c,l=function(e){var t,n,r,o,i=e.className+" ";if(i+=e.parentNode?e.parentNode.className:"",n=a.exec(i))return C(n[1])?n[1]:"no-highlight";for(t=0,r=(i=i.split(/\s+/)).length;t/g,"\n"):t=e,c=t.textContent,o=l?b(l,c,!0):w(c),(r=v(t)).length&&((s=document.createElementNS("http://www.w3.org/1999/xhtml","div")).innerHTML=o.value,o.value=function(e,t,r){var o=0,i="",s=[];function a(){return e.length&&t.length?e[0].offset!==t[0].offset?e[0].offset"}function l(e){i+=""}function u(e){("start"===e.event?c:l)(e.node)}for(;e.length||t.length;){var h=a();if(i+=p(r.substring(o,h[0].offset)),o=h[0].offset,h===e){s.reverse().forEach(l);do{u(h.splice(0,1)[0]),h=a()}while(h===e&&h.length&&h[0].offset===o);s.reverse().forEach(c)}else"start"===h[0].event?s.push(h[0].node):s.pop(),u(h.splice(0,1)[0])}return i+p(r.substr(o))}(r,v(s),c)),o.value=k(o.value),e.innerHTML=o.value,e.className=function(e,t,n){var r=t?i[t]:n,o=[e.trim()];return e.match(/\bhljs\b/)||o.push("hljs"),-1===e.indexOf(r)&&o.push(r),o.join(" ").trim()}(e.className,l,o.language),e.result={language:o.language,re:o.relevance},o.second_best&&(e.second_best={language:o.second_best.language,re:o.second_best.relevance}))}function _(){if(!_.called){_.called=!0;var e=document.querySelectorAll("pre code");n.forEach.call(e,x)}}function C(e){return e=(e||"").toLowerCase(),o[e]||o[i[e]]}function S(e){var t=C(e);return t&&!t.disableAutodetect}return e.highlight=b,e.highlightAuto=w,e.fixMarkup=k,e.highlightBlock=x,e.configure=function(e){u=m(u,e)},e.initHighlighting=_,e.initHighlightingOnLoad=function(){addEventListener("DOMContentLoaded",_,!1),addEventListener("load",_,!1)},e.registerLanguage=function(t,n){var r=o[t]=n(e);g(r),r.aliases&&r.aliases.forEach(function(e){i[e]=t})},e.listLanguages=function(){return r(o)},e.getLanguage=C,e.autoDetection=S,e.inherit=m,e.IDENT_RE="[a-zA-Z]\\w*",e.UNDERSCORE_IDENT_RE="[a-zA-Z_]\\w*",e.NUMBER_RE="\\b\\d+(\\.\\d+)?",e.C_NUMBER_RE="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",e.BINARY_NUMBER_RE="\\b(0b[01]+)",e.RE_STARTERS_RE="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",e.BACKSLASH_ESCAPE={begin:"\\\\[\\s\\S]",relevance:0},e.APOS_STRING_MODE={className:"string",begin:"'",end:"'",illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},e.QUOTE_STRING_MODE={className:"string",begin:'"',end:'"',illegal:"\\n",contains:[e.BACKSLASH_ESCAPE]},e.PHRASAL_WORDS_MODE={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},e.COMMENT=function(t,n,r){var o=e.inherit({className:"comment",begin:t,end:n,contains:[]},r||{});return o.contains.push(e.PHRASAL_WORDS_MODE),o.contains.push({className:"doctag",begin:"(?:TODO|FIXME|NOTE|BUG|XXX):",relevance:0}),o},e.C_LINE_COMMENT_MODE=e.COMMENT("//","$"),e.C_BLOCK_COMMENT_MODE=e.COMMENT("/\\*","\\*/"),e.HASH_COMMENT_MODE=e.COMMENT("#","$"),e.NUMBER_MODE={className:"number",begin:e.NUMBER_RE,relevance:0},e.C_NUMBER_MODE={className:"number",begin:e.C_NUMBER_RE,relevance:0},e.BINARY_NUMBER_MODE={className:"number",begin:e.BINARY_NUMBER_RE,relevance:0},e.CSS_NUMBER_MODE={className:"number",begin:e.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},e.REGEXP_MODE={className:"regexp",begin:/\//,end:/\/[gimuy]*/,illegal:/\n/,contains:[e.BACKSLASH_ESCAPE,{begin:/\[/,end:/\]/,relevance:0,contains:[e.BACKSLASH_ESCAPE]}]},e.TITLE_MODE={className:"title",begin:e.IDENT_RE,relevance:0},e.UNDERSCORE_TITLE_MODE={className:"title",begin:e.UNDERSCORE_IDENT_RE,relevance:0},e.METHOD_GUARD={begin:"\\.\\s*"+e.UNDERSCORE_IDENT_RE,relevance:0},e},i="object"==typeof window&&window||"object"==typeof self&&self,t.nodeType?i&&(i.hljs=o({}),void 0===(r=function(){return i.hljs}.apply(t,[]))||(e.exports=r)):o(t)},function(e,t,n){"use strict";var r=n(278),o=i(Error);function i(e){return t.displayName=e.displayName||e.name,t;function t(t){return t&&(t=r.apply(null,arguments)),new e(t)}}e.exports=o,o.eval=i(EvalError),o.range=i(RangeError),o.reference=i(ReferenceError),o.syntax=i(SyntaxError),o.type=i(TypeError),o.uri=i(URIError),o.create=i},function(e,t,n){!function(){var t;function n(e){for(var t,n,r,o,i=1,s=[].slice.call(arguments),a=0,c=e.length,l="",u=!1,p=!1,f=function(){return s[i++]},h=function(){for(var n="";/\d/.test(e[a]);)n+=e[a++],t=e[a];return n.length>0?parseInt(n):null};au&&(v=y,(m=s).forEach(function(e,t){if(e.selection&&0==v--)return g=t,!1}),s=m.slice(g),i-=y),new a(s.append(o),i)},a.prototype.remapping=function(e,t){var n=new i.Mapping;return this.items.forEach(function(t,r){var o=null!=t.mirrorOffset&&r-t.mirrorOffset>=e?o=n.maps.length-t.mirrorOffset:null;n.appendMap(t.map,o)},e,t),n},a.prototype.addMaps=function(e){return 0==this.eventCount?this:new a(this.items.append(e.map(function(e){return new c(e)})),this.eventCount)},a.prototype.rebased=function(e,t){if(!this.eventCount)return this;var n=[],r=Math.max(0,this.items.length-t),o=e.mapping,i=e.steps.length,s=this.eventCount;this.items.forEach(function(e){e.selection&&s--},r);var l=t;this.items.forEach(function(t){var r=o.getMirror(--l);if(null!=r){i=Math.min(i,r);var a=o.maps[r];if(t.step){var u=e.steps[r].invert(e.docs[r]),p=t.selection&&t.selection.map(o.slice(l+1,r));p&&s++,n.push(new c(a,u,p))}else n.push(new c(a))}},r);for(var u=[],p=t;p500&&(h=h.compress(this.items.length-n.length)),h},a.prototype.emptyItemCount=function(){var e=0;return this.items.forEach(function(t){t.step||e++}),e},a.prototype.compress=function(e){void 0===e&&(e=this.items.length);var t=this.remapping(0,e),n=t.maps.length,r=[],i=0;return this.items.forEach(function(o,s){if(s>=e)r.push(o),o.selection&&i++;else if(o.step){var a=o.step.map(t.slice(n)),l=a&&a.getMap();if(n--,l&&t.appendMap(l,n),a){var u=o.selection&&o.selection.map(t.slice(n));u&&i++;var p,f=new c(l.invert(),a,u),h=r.length-1;(p=r.length&&r[h].merge(f))?r[h]=p:r.push(f)}}else o.map&&n--},this.items.length,0),new a(o.from(r.reverse()),i)},a.empty=new a(o.empty,0);var c=function(e,t,n,r){this.map=e,this.step=t,this.selection=n,this.mirrorOffset=r};c.prototype.merge=function(e){if(this.step&&e.step&&!e.selection){var t=e.step.merge(this.step);if(t)return new c(t.getMap().invert(),t,this.selection)}};var l=function(e,t,n,r){this.done=e,this.undone=t,this.prevRanges=n,this.prevTime=r},u=20;function p(e){var t=[];return e.forEach(function(e,n,r,o){return t.push(r,o)}),t}function f(e,t){if(!e)return null;for(var n=[],r=0;r=t[o]&&(n=!0)}),n}(n,e.prevRanges),u=s?f(e.prevRanges,n.mapping):p(n.mapping.maps[n.steps.length-1]);return new l(e.done.addTransform(n,c?t.selection.getBookmark():null,r,v(t)),a.empty,u,n.time)}(n,r,t,e)}},config:e})},t.undo=function(e,t){var n=g.getState(e);return!(!n||0==n.done.eventCount)&&(t&&h(n,e,t,!1),!0)},t.redo=function(e,t){var n=g.getState(e);return!(!n||0==n.undone.eventCount)&&(t&&h(n,e,t,!0),!0)},t.undoDepth=function(e){var t=g.getState(e);return t?t.done.eventCount:0},t.redoDepth=function(e){var t=g.getState(e);return t?t.undone.eventCount:0}},function(e,t){var n=function(){};n.prototype.append=function(e){return e.length?(e=n.from(e),!this.length&&e||e.length<200&&this.leafAppend(e)||this.length<200&&e.leafPrepend(this)||this.appendInner(e)):this},n.prototype.prepend=function(e){return e.length?n.from(e).append(this):this},n.prototype.appendInner=function(e){return new o(this,e)},n.prototype.slice=function(e,t){return void 0===e&&(e=0),void 0===t&&(t=this.length),e>=t?n.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,t))},n.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},n.prototype.forEach=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=this.length),t<=n?this.forEachInner(e,t,n,0):this.forEachInvertedInner(e,t,n,0)},n.prototype.map=function(e,t,n){void 0===t&&(t=0),void 0===n&&(n=this.length);var r=[];return this.forEach(function(t,n){return r.push(e(t,n))},t,n),r},n.from=function(e){return e instanceof n?e:e&&e.length?new r(e):n.empty};var r=function(e){function t(t){e.call(this),this.values=t}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{},depth:{}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(e,n){return 0==e&&n==this.length?this:new t(this.values.slice(e,n))},t.prototype.getInner=function(e){return this.values[e]},t.prototype.forEachInner=function(e,t,n,r){for(var o=t;o=n;o--)if(!1===e(this.values[o],r+o))return!1},t.prototype.leafAppend=function(e){if(this.length+e.length<=200)return new t(this.values.concat(e.flatten()))},t.prototype.leafPrepend=function(e){if(this.length+e.length<=200)return new t(e.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}(n);n.empty=new r([]);var o=function(e){function t(t,n){e.call(this),this.left=t,this.right=n,this.length=t.length+n.length,this.depth=Math.max(t.depth,n.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(e){return eo&&!1===this.right.forEachInner(e,Math.max(t-o,0),Math.min(this.length,n)-o,r+o))&&void 0)},t.prototype.forEachInvertedInner=function(e,t,n,r){var o=this.left.length;return!(t>o&&!1===this.right.forEachInvertedInner(e,t-o,Math.max(n,o)-o,r+o))&&(!(n=n?this.right.slice(e-n,t-n):this.left.slice(e,n).append(this.right.slice(0,t-n))},t.prototype.leafAppend=function(e){var n=this.right.leafAppend(e);if(n)return new t(this.left,n)},t.prototype.leafPrepend=function(e){var n=this.left.leafPrepend(e);if(n)return new t(n,this.right)},t.prototype.appendInner=function(e){return this.left.depth>=Math.max(this.right.depth,e.depth)+1?new t(this.left,new t(this.right,e)):new t(this,e)},t}(n);e.exports=n},,,function(e,t,n){"use strict";var r=n(40),o=n(291),i=n(295),s=n(296),a=n(304),c=n(318),l=n(331),u=n(75),p=n(333),f={default:n(335),zero:n(336),commonmark:n(337)},h=/^(vbscript|javascript|file|data):/,d=/^data:image\/(gif|png|jpeg|webp);/;function m(e){var t=e.trim().toLowerCase();return!h.test(t)||!!d.test(t)}var v=["http:","https:","mailto:"];function g(e){var t=u.parse(e,!0);if(t.hostname&&(!t.protocol||v.indexOf(t.protocol)>=0))try{t.hostname=p.toASCII(t.hostname)}catch(e){}return u.encode(u.format(t))}function y(e){var t=u.parse(e,!0);if(t.hostname&&(!t.protocol||v.indexOf(t.protocol)>=0))try{t.hostname=p.toUnicode(t.hostname)}catch(e){}return u.decode(u.format(t))}function b(e,t){if(!(this instanceof b))return new b(e,t);t||r.isString(e)||(t=e||{},e="default"),this.inline=new c,this.block=new a,this.core=new s,this.renderer=new i,this.linkify=new l,this.validateLink=m,this.normalizeLink=g,this.normalizeLinkText=y,this.utils=r,this.helpers=r.assign({},o),this.options={},this.configure(e),t&&this.set(t)}b.prototype.set=function(e){return r.assign(this.options,e),this},b.prototype.configure=function(e){var t,n=this;if(r.isString(e)&&!(e=f[t=e]))throw new Error('Wrong `markdown-it` preset "'+t+'", check name');if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&n.set(e.options),e.components&&Object.keys(e.components).forEach(function(t){e.components[t].rules&&n[t].ruler.enableOnly(e.components[t].rules),e.components[t].rules2&&n[t].ruler2.enableOnly(e.components[t].rules2)}),this},b.prototype.enable=function(e,t){var n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(t){n=n.concat(this[t].ruler.enable(e,!0))},this),n=n.concat(this.inline.ruler2.enable(e,!0));var r=e.filter(function(e){return n.indexOf(e)<0});if(r.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+r);return this},b.prototype.disable=function(e,t){var n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach(function(t){n=n.concat(this[t].ruler.disable(e,!0))},this),n=n.concat(this.inline.ruler2.disable(e,!0));var r=e.filter(function(e){return n.indexOf(e)<0});if(r.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+r);return this},b.prototype.use=function(e){var t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},b.prototype.parse=function(e,t){if("string"!=typeof e)throw new Error("Input data should be a String");var n=new this.core.State(e,this,t);return this.core.process(n),n.tokens},b.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},b.prototype.parseInline=function(e,t){var n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens},b.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)},e.exports=b},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"\'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\\"","QUOT":"\\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}')},function(e,t,n){"use strict";var r={};function o(e,t,n){var i,s,a,c,l,u="";for("string"!=typeof t&&(n=t,t=o.defaultChars),void 0===n&&(n=!0),l=function(e){var t,n,o=r[e];if(o)return o;for(o=r[e]=[],t=0;t<128;t++)n=String.fromCharCode(t),/^[0-9a-z]$/i.test(n)?o.push(n):o.push("%"+("0"+t.toString(16).toUpperCase()).slice(-2));for(t=0;t=55296&&a<=57343){if(a>=55296&&a<=56319&&i+1=56320&&c<=57343){u+=encodeURIComponent(e[i]+e[i+1]),i++;continue}u+="%EF%BF%BD"}else u+=encodeURIComponent(e[i]);return u}o.defaultChars=";/?:@&=+$,-_.!~*'()#",o.componentChars="-_.!~*'()",e.exports=o},function(e,t,n){"use strict";var r={};function o(e,t){var n;return"string"!=typeof t&&(t=o.defaultChars),n=function(e){var t,n,o=r[e];if(o)return o;for(o=r[e]=[],t=0;t<128;t++)n=String.fromCharCode(t),o.push(n);for(t=0;t=55296&&c<=57343?"���":String.fromCharCode(c),t+=6):240==(248&o)&&t+91114111?l+="����":(c-=65536,l+=String.fromCharCode(55296+(c>>10),56320+(1023&c))),t+=9):l+="�";return l})}o.defaultChars=";/?:@&=+$,#",o.componentChars="",e.exports=o},function(e,t,n){"use strict";e.exports=function(e){var t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||""}},function(e,t,n){"use strict";function r(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}var o=/^([a-z0-9.+-]+:)/i,i=/:[0-9]*$/,s=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,a=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),c=["'"].concat(a),l=["%","/","?",";","#"].concat(c),u=["/","?","#"],p=/^[+a-z0-9A-Z_-]{0,63}$/,f=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,h={javascript:!0,"javascript:":!0},d={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};r.prototype.parse=function(e,t){var n,r,i,a,c,m=e;if(m=m.trim(),!t&&1===e.split("#").length){var v=s.exec(m);if(v)return this.pathname=v[1],v[2]&&(this.search=v[2]),this}var g=o.exec(m);if(g&&(i=(g=g[0]).toLowerCase(),this.protocol=g,m=m.substr(g.length)),(t||g||m.match(/^\/\/[^@\/]+@[^@\/]+/))&&(!(c="//"===m.substr(0,2))||g&&h[g]||(m=m.substr(2),this.slashes=!0)),!h[g]&&(c||g&&!d[g])){var y,b,w=-1;for(n=0;n127?S+="x":S+=C[O];if(!S.match(p)){var E=_.slice(0,n),M=_.slice(n+1),T=C.match(f);T&&(E.push(T[1]),M.unshift(T[2])),M.length&&(m=M.join(".")+m),this.hostname=E.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),x&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}var D=m.indexOf("#");-1!==D&&(this.hash=m.substr(D),m=m.slice(0,D));var N=m.indexOf("?");return-1!==N&&(this.search=m.substr(N),m=m.slice(0,N)),m&&(this.pathname=m),d[i]&&this.hostname&&!this.pathname&&(this.pathname=""),this},r.prototype.parseHost=function(e){var t=i.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)},e.exports=function(e,t){if(e&&e instanceof r)return e;var n=new r;return n.parse(e,t),n}},function(e,t,n){"use strict";t.Any=n(76),t.Cc=n(77),t.Cf=n(290),t.P=n(57),t.Z=n(78)},function(e,t){e.exports=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/},function(e,t,n){"use strict";t.parseLinkLabel=n(292),t.parseLinkDestination=n(293),t.parseLinkTitle=n(294)},function(e,t,n){"use strict";e.exports=function(e,t,n){var r,o,i,s,a=-1,c=e.posMax,l=e.pos;for(e.pos=t+1,r=1;e.pos=n)return c;if(34!==(i=e.charCodeAt(t))&&39!==i&&40!==i)return c;for(t++,40===i&&(i=41);t"+i(e[t].content)+""},s.code_block=function(e,t,n,r,o){var s=e[t];return""+i(e[t].content)+"\n"},s.fence=function(e,t,n,r,s){var a,c,l,u,p=e[t],f=p.info?o(p.info).trim():"",h="";return f&&(h=f.split(/\s+/g)[0]),0===(a=n.highlight&&n.highlight(p.content,h)||i(p.content)).indexOf(""+a+"\n"):"
"+a+"
\n"},s.image=function(e,t,n,r,o){var i=e[t];return i.attrs[i.attrIndex("alt")][1]=o.renderInlineAsText(i.children,n,r),o.renderToken(e,t,n)},s.hardbreak=function(e,t,n){return n.xhtmlOut?"
\n":"
\n"},s.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?"
\n":"
\n":"\n"},s.text=function(e,t){return i(e[t].content)},s.html_block=function(e,t){return e[t].content},s.html_inline=function(e,t){return e[t].content},a.prototype.renderAttrs=function(e){var t,n,r;if(!e.attrs)return"";for(r="",t=0,n=e.attrs.length;t\n":">")},a.prototype.renderInline=function(e,t,n){for(var r,o="",i=this.rules,s=0,a=e.length;s/i.test(e)}e.exports=function(e){var t,n,i,s,a,c,l,u,p,f,h,d,m,v,g,y,b,w,k=e.tokens;if(e.md.options.linkify)for(n=0,i=k.length;n=0;t--)if("link_close"!==(c=s[t]).type){if("html_inline"===c.type&&(w=c.content,/^\s]/i.test(w)&&m>0&&m--,o(c.content)&&m++),!(m>0)&&"text"===c.type&&e.md.linkify.test(c.content)){for(p=c.content,b=e.md.linkify.match(p),l=[],d=c.level,h=0,u=0;uh&&((a=new e.Token("text","",0)).content=p.slice(h,f),a.level=d,l.push(a)),(a=new e.Token("link_open","a",1)).attrs=[["href",g]],a.level=d++,a.markup="linkify",a.info="auto",l.push(a),(a=new e.Token("text","",0)).content=y,a.level=d,l.push(a),(a=new e.Token("link_close","a",-1)).level=--d,a.markup="linkify",a.info="auto",l.push(a),h=b[u].lastIndex);h=0;t--)"text"!==(n=e[t]).type||r||(n.content=n.content.replace(i,a)),"link_open"===n.type&&"auto"===n.info&&r--,"link_close"===n.type&&"auto"===n.info&&r++}function l(e){var t,n,o=0;for(t=e.length-1;t>=0;t--)"text"!==(n=e[t]).type||o||r.test(n.content)&&(n.content=n.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---([^-]|$)/gm,"$1—$2").replace(/(^|\s)--(\s|$)/gm,"$1–$2").replace(/(^|[^-\s])--([^-\s]|$)/gm,"$1–$2")),"link_open"===n.type&&"auto"===n.info&&o--,"link_close"===n.type&&"auto"===n.info&&o++}e.exports=function(e){var t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)"inline"===e.tokens[t].type&&(o.test(e.tokens[t].content)&&c(e.tokens[t].children),r.test(e.tokens[t].content)&&l(e.tokens[t].children))}},function(e,t,n){"use strict";var r=n(40).isWhiteSpace,o=n(40).isPunctChar,i=n(40).isMdAsciiPunct,s=/['"]/,a=/['"]/g,c="’";function l(e,t,n){return e.substr(0,t)+n+e.substr(t+1)}function u(e,t){var n,s,u,p,f,h,d,m,v,g,y,b,w,k,x,_,C,S,O,A,E;for(O=[],n=0;n=0&&!(O[C].level<=d);C--);if(O.length=C+1,"text"===s.type){f=0,h=(u=s.content).length;e:for(;f=0)v=u.charCodeAt(p.index-1);else for(C=n-1;C>=0&&("softbreak"!==e[C].type&&"hardbreak"!==e[C].type);C--)if("text"===e[C].type){v=e[C].content.charCodeAt(e[C].content.length-1);break}if(g=32,f=48&&v<=57&&(_=x=!1),x&&_&&(x=!1,_=b),x||_){if(_)for(C=O.length-1;C>=0&&(m=O[C],!(O[C].level=0;t--)"inline"===e.tokens[t].type&&s.test(e.tokens[t].content)&&u(e.tokens[t].children,e)}},function(e,t,n){"use strict";var r=n(59);function o(e,t,n){this.src=e,this.env=n,this.tokens=[],this.inlineMode=!1,this.md=t}o.prototype.Token=r,e.exports=o},function(e,t,n){"use strict";var r=n(58),o=[["table",n(305),["paragraph","reference"]],["code",n(306)],["fence",n(307),["paragraph","reference","blockquote","list"]],["blockquote",n(308),["paragraph","reference","blockquote","list"]],["hr",n(309),["paragraph","reference","blockquote","list"]],["list",n(310),["paragraph","reference","blockquote"]],["reference",n(311)],["heading",n(312),["paragraph","reference","blockquote"]],["lheading",n(313)],["html_block",n(314),["paragraph","reference","blockquote"]],["paragraph",n(316)]];function i(){this.ruler=new r;for(var e=0;e=n))&&!(e.sCount[s]=c){e.line=n;break}for(r=0;rn)return!1;if(p=t+1,e.sCount[p]=4)return!1;if((l=e.bMarks[p]+e.tShift[p])>=e.eMarks[p])return!1;if(124!==(a=e.src.charCodeAt(l++))&&45!==a&&58!==a)return!1;for(;l=4)return!1;if((h=(f=i(c.replace(/^\||\|$/g,""))).length)>m.length)return!1;if(s)return!0;for((d=e.push("table_open","table",1)).map=g=[t,0],(d=e.push("thead_open","thead",1)).map=[t,t+1],(d=e.push("tr_open","tr",1)).map=[t,t+1],u=0;u=4);p++){for(f=i(c.replace(/^\||\|$/g,"")),d=e.push("tr_open","tr",1),u=0;u=4))break;o=++r}return e.line=o,(i=e.push("code_block","code",0)).content=e.getLines(t,o,4+e.blkIndent,!0),i.map=[t,e.line],!0}},function(e,t,n){"use strict";e.exports=function(e,t,n,r){var o,i,s,a,c,l,u,p=!1,f=e.bMarks[t]+e.tShift[t],h=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(f+3>h)return!1;if(126!==(o=e.src.charCodeAt(f))&&96!==o)return!1;if(c=f,(i=(f=e.skipChars(f,o))-c)<3)return!1;if(u=e.src.slice(c,f),(s=e.src.slice(f,h)).indexOf(String.fromCharCode(o))>=0)return!1;if(r)return!0;for(a=t;!(++a>=n)&&!((f=c=e.bMarks[a]+e.tShift[a])<(h=e.eMarks[a])&&e.sCount[a]=4||(f=e.skipChars(f,o))-c=4)return!1;if(62!==e.src.charCodeAt(O++))return!1;if(o)return!0;for(c=h=e.sCount[t]+O-(e.bMarks[t]+e.tShift[t]),32===e.src.charCodeAt(O)?(O++,c++,h++,i=!1,w=!0):9===e.src.charCodeAt(O)?(w=!0,(e.bsCount[t]+h)%4==3?(O++,c++,h++,i=!1):i=!0):w=!1,d=[e.bMarks[t]],e.bMarks[t]=O;O=A,y=[e.sCount[t]],e.sCount[t]=h-c,b=[e.tShift[t]],e.tShift[t]=O-e.bMarks[t],x=e.md.block.ruler.getRules("blockquote"),g=e.parentType,e.parentType="blockquote",C=!1,f=t+1;f=(A=e.eMarks[f])));f++)if(62!==e.src.charCodeAt(O++)||C){if(u)break;for(k=!1,a=0,l=x.length;a=A,m.push(e.bsCount[f]),e.bsCount[f]=e.sCount[f]+1+(w?1:0),y.push(e.sCount[f]),e.sCount[f]=h-c,b.push(e.tShift[f]),e.tShift[f]=O-e.bMarks[f]}for(v=e.blkIndent,e.blkIndent=0,(_=e.push("blockquote_open","blockquote",1)).markup=">",_.map=p=[t,0],e.md.block.tokenize(e,t,f),(_=e.push("blockquote_close","blockquote",-1)).markup=">",e.lineMax=S,e.parentType=g,p[1]=e.line,a=0;a=4)return!1;if(42!==(i=e.src.charCodeAt(l++))&&45!==i&&95!==i)return!1;for(s=1;l=s)return-1;if((n=e.src.charCodeAt(i++))<48||n>57)return-1;for(;;){if(i>=s)return-1;if(!((n=e.src.charCodeAt(i++))>=48&&n<=57)){if(41===n||46===n)break;return-1}if(i-o>=10)return-1}return i=4)return!1;if(r&&"paragraph"===e.parentType&&e.tShift[t]>=e.blkIndent&&(I=!0),(E=i(e,t))>=0){if(f=!0,T=e.bMarks[t]+e.tShift[t],y=Number(e.src.substr(T,E-T-1)),I&&1!==y)return!1}else{if(!((E=o(e,t))>=0))return!1;f=!1}if(I&&e.skipSpaces(E)>=e.eMarks[t])return!1;if(g=e.src.charCodeAt(E-1),r)return!0;for(v=e.tokens.length,f?(R=e.push("ordered_list_open","ol",1),1!==y&&(R.attrs=[["start",y]])):R=e.push("bullet_list_open","ul",1),R.map=m=[t,0],R.markup=String.fromCharCode(g),w=t,M=!1,N=e.md.block.ruler.getRules("list"),C=e.parentType,e.parentType="list";w=b?1:k-p)>4&&(u=1),l=p+u,(R=e.push("list_item_open","li",1)).markup=String.fromCharCode(g),R.map=h=[t,0],x=e.blkIndent,O=e.tight,S=e.tShift[t],_=e.sCount[t],e.blkIndent=l,e.tight=!0,e.tShift[t]=a-e.bMarks[t],e.sCount[t]=k,a>=b&&e.isEmpty(t+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,t,n,!0),e.tight&&!M||(P=!1),M=e.line-t>1&&e.isEmpty(e.line-1),e.blkIndent=x,e.tShift[t]=S,e.sCount[t]=_,e.tight=O,(R=e.push("list_item_close","li",-1)).markup=String.fromCharCode(g),w=t=e.line,h[1]=w,a=e.bMarks[t],w>=n)break;if(e.sCount[w]=4)return!1;if(91!==e.src.charCodeAt(_))return!1;for(;++_3||e.sCount[S]<0)){for(b=!1,p=0,f=w.length;p=4)return!1;if(35!==(i=e.src.charCodeAt(l))||l>=u)return!1;for(s=1,i=e.src.charCodeAt(++l);35===i&&l6||ll&&r(e.src.charCodeAt(a-1))&&(u=a),e.line=t+1,(c=e.push("heading_open","h"+String(s),1)).markup="########".slice(0,s),c.map=[t,e.line],(c=e.push("inline","",0)).content=e.src.slice(l,u).trim(),c.map=[t,e.line],c.children=[],(c=e.push("heading_close","h"+String(s),-1)).markup="########".slice(0,s),!0))}},function(e,t,n){"use strict";e.exports=function(e,t,n){var r,o,i,s,a,c,l,u,p,f,h=t+1,d=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;for(f=e.parentType,e.parentType="paragraph";h3)){if(e.sCount[h]>=e.blkIndent&&(c=e.bMarks[h]+e.tShift[h])<(l=e.eMarks[h])&&(45===(p=e.src.charCodeAt(c))||61===p)&&(c=e.skipChars(c,p),(c=e.skipSpaces(c))>=l)){u=61===p?1:2;break}if(!(e.sCount[h]<0)){for(o=!1,i=0,s=d.length;i|$))/i,/<\/(script|pre|style)>/i,!0],[/^/,!0],[/^<\?/,/\?>/,!0],[/^/,!0],[/^/,!0],[new RegExp("^|$))","i"),/^$/,!0],[new RegExp(o.source+"\\s*$"),/^$/,!1]];e.exports=function(e,t,n,r){var o,s,a,c,l=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(!e.md.options.html)return!1;if(60!==e.src.charCodeAt(l))return!1;for(c=e.src.slice(l,u),o=0;o3||e.sCount[c]<0)){for(r=!1,o=0,i=l.length;o0&&this.level++,this.tokens.push(o),o},i.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},i.prototype.skipEmptyLines=function(e){for(var t=this.lineMax;et;)if(!o(this.src.charCodeAt(--e)))return e+1;return e},i.prototype.skipChars=function(e,t){for(var n=this.src.length;en;)if(t!==this.src.charCodeAt(--e))return e+1;return e},i.prototype.getLines=function(e,t,n,r){var i,s,a,c,l,u,p,f=e;if(e>=t)return"";for(u=new Array(t-e),i=0;fn?new Array(s-n+1).join(" ")+this.src.slice(c,l):this.src.slice(c,l)}return u.join("")},i.prototype.Token=r,e.exports=i},function(e,t,n){"use strict";var r=n(58),o=[["text",n(319)],["newline",n(320)],["escape",n(321)],["backticks",n(322)],["strikethrough",n(80).tokenize],["emphasis",n(81).tokenize],["link",n(323)],["image",n(324)],["autolink",n(325)],["html_inline",n(326)],["entity",n(327)]],i=[["balance_pairs",n(328)],["strikethrough",n(80).postProcess],["emphasis",n(81).postProcess],["text_collapse",n(329)]];function s(){var e;for(this.ruler=new r,e=0;e=i)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},s.prototype.parse=function(e,t,n,r){var o,i,s,a=new this.State(e,t,n,r);for(this.tokenize(a),s=(i=this.ruler2.getRules("")).length,o=0;o=0&&32===e.pending.charCodeAt(n)?n>=1&&32===e.pending.charCodeAt(n-1)?(e.pending=e.pending.replace(/ +$/,""),e.push("hardbreak","br",0)):(e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0)):e.push("softbreak","br",0)),i++;i?@[]^_`{|}~-".split("").forEach(function(e){o[e.charCodeAt(0)]=1}),e.exports=function(e,t){var n,i=e.pos,s=e.posMax;if(92!==e.src.charCodeAt(i))return!1;if(++i=m)return!1;for(v=l,(u=e.md.helpers.parseLinkDestination(e.src,l,e.posMax)).ok&&(h=e.md.normalizeLink(u.str),e.md.validateLink(h)?l=u.pos:h=""),v=l;l=m||41!==e.src.charCodeAt(l))&&(g=!0),l++}if(g){if(void 0===e.env.references)return!1;if(l=0?s=e.src.slice(v,l++):l=a+1):l=a+1,s||(s=e.src.slice(c,a)),!(p=e.env.references[r(s)]))return e.pos=d,!1;h=p.href,f=p.title}return t||(e.pos=c,e.posMax=a,e.push("link_open","a",1).attrs=n=[["href",h]],f&&n.push(["title",f]),e.md.inline.tokenize(e),e.push("link_close","a",-1)),e.pos=l,e.posMax=m,!0}},function(e,t,n){"use strict";var r=n(40).normalizeReference,o=n(40).isSpace;e.exports=function(e,t){var n,i,s,a,c,l,u,p,f,h,d,m,v,g="",y=e.pos,b=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;if(l=e.pos+2,(c=e.md.helpers.parseLinkLabel(e,e.pos+1,!1))<0)return!1;if((u=c+1)=b)return!1;for(v=u,(f=e.md.helpers.parseLinkDestination(e.src,u,e.posMax)).ok&&(g=e.md.normalizeLink(f.str),e.md.validateLink(g)?u=f.pos:g=""),v=u;u=b||41!==e.src.charCodeAt(u))return e.pos=y,!1;u++}else{if(void 0===e.env.references)return!1;if(u=0?a=e.src.slice(v,u++):u=c+1):u=c+1,a||(a=e.src.slice(l,c)),!(p=e.env.references[r(a)]))return e.pos=y,!1;g=p.href,h=p.title}return t||(s=e.src.slice(l,c),e.md.inline.parse(s,e.md,e.env,m=[]),(d=e.push("image","img",0)).attrs=n=[["src",g],["alt",""]],d.children=m,d.content=s,h&&n.push(["title",h])),e.pos=u,e.posMax=b,!0}},function(e,t,n){"use strict";var r=/^<([a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)>/,o=/^<([a-zA-Z][a-zA-Z0-9+.\-]{1,31}):([^<>\x00-\x20]*)>/;e.exports=function(e,t){var n,i,s,a,c,l,u=e.pos;return 60===e.src.charCodeAt(u)&&(!((n=e.src.slice(u)).indexOf(">")<0)&&(o.test(n)?(a=(i=n.match(o))[0].slice(1,-1),c=e.md.normalizeLink(a),!!e.md.validateLink(c)&&(t||((l=e.push("link_open","a",1)).attrs=[["href",c]],l.markup="autolink",l.info="auto",(l=e.push("text","",0)).content=e.md.normalizeLinkText(a),(l=e.push("link_close","a",-1)).markup="autolink",l.info="auto"),e.pos+=i[0].length,!0)):!!r.test(n)&&(a=(s=n.match(r))[0].slice(1,-1),c=e.md.normalizeLink("mailto:"+a),!!e.md.validateLink(c)&&(t||((l=e.push("link_open","a",1)).attrs=[["href",c]],l.markup="autolink",l.info="auto",(l=e.push("text","",0)).content=e.md.normalizeLinkText(a),(l=e.push("link_close","a",-1)).markup="autolink",l.info="auto"),e.pos+=s[0].length,!0))))}},function(e,t,n){"use strict";var r=n(79).HTML_TAG_RE;e.exports=function(e,t){var n,o,i,s=e.pos;return!!e.md.options.html&&(i=e.posMax,!(60!==e.src.charCodeAt(s)||s+2>=i)&&(!(33!==(n=e.src.charCodeAt(s+1))&&63!==n&&47!==n&&!function(e){var t=32|e;return t>=97&&t<=122}(n))&&(!!(o=e.src.slice(s).match(r))&&(t||(e.push("html_inline","",0).content=e.src.slice(s,s+o[0].length)),e.pos+=o[0].length,!0))))}},function(e,t,n){"use strict";var r=n(74),o=n(40).has,i=n(40).isValidEntityCode,s=n(40).fromCodePoint,a=/^&#((?:x[a-f0-9]{1,8}|[0-9]{1,8}));/i,c=/^&([a-z][a-z0-9]{1,31});/i;e.exports=function(e,t){var n,l,u=e.pos,p=e.posMax;if(38!==e.src.charCodeAt(u))return!1;if(u+1=0;){if((o=i[n]).open&&o.marker===r.marker&&o.end<0&&o.level===r.level)if(!((o.close||r.open)&&void 0!==o.length&&void 0!==r.length&&(o.length+r.length)%3==0)){r.jump=t-n,r.open=!1,o.end=t,o.jump=0;break}n-=o.jump+1}}},function(e,t,n){"use strict";e.exports=function(e){var t,n,r=0,o=e.tokens,i=e.tokens.length;for(t=n=0;t0&&this.level++,this.pendingLevel=this.level,this.tokens.push(o),o},a.prototype.scanDelims=function(e,t){var n,r,a,c,l,u,p,f,h,d=e,m=!0,v=!0,g=this.posMax,y=this.src.charCodeAt(e);for(n=e>0?this.src.charCodeAt(e-1):32;d=3&&":"===e[t-3]?0:t>=3&&"/"===e[t-3]?0:r.match(n.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,n){var r=e.slice(t);return n.re.mailto||(n.re.mailto=new RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(r)?r.match(n.re.mailto)[0].length:0}}},l="a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]",u="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");function p(e){var t=e.re=n(332)(e.__opts__),r=e.__tlds__.slice();function a(e){return e.replace("%TLDS%",t.src_tlds)}e.onCompile(),e.__tlds_replaced__||r.push(l),r.push(t.src_xn),t.src_tlds=r.join("|"),t.email_fuzzy=RegExp(a(t.tpl_email_fuzzy),"i"),t.link_fuzzy=RegExp(a(t.tpl_link_fuzzy),"i"),t.link_no_ip_fuzzy=RegExp(a(t.tpl_link_no_ip_fuzzy),"i"),t.host_fuzzy_test=RegExp(a(t.tpl_host_fuzzy_test),"i");var c=[];function u(e,t){throw new Error('(LinkifyIt) Invalid schema "'+e+'": '+t)}e.__compiled__={},Object.keys(e.__schemas__).forEach(function(t){var n=e.__schemas__[t];if(null!==n){var r={validate:null,link:null};if(e.__compiled__[t]=r,"[object Object]"===o(n))return!function(e){return"[object RegExp]"===o(e)}(n.validate)?i(n.validate)?r.validate=n.validate:u(t,n):r.validate=function(e){return function(t,n){var r=t.slice(n);return e.test(r)?r.match(e)[0].length:0}}(n.validate),void(i(n.normalize)?r.normalize=n.normalize:n.normalize?u(t,n):r.normalize=function(e,t){t.normalize(e)});!function(e){return"[object String]"===o(e)}(n)?u(t,n):c.push(t)}}),c.forEach(function(t){e.__compiled__[e.__schemas__[t]]&&(e.__compiled__[t].validate=e.__compiled__[e.__schemas__[t]].validate,e.__compiled__[t].normalize=e.__compiled__[e.__schemas__[t]].normalize)}),e.__compiled__[""]={validate:null,normalize:function(e,t){t.normalize(e)}};var p=Object.keys(e.__compiled__).filter(function(t){return t.length>0&&e.__compiled__[t]}).map(s).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+p+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><|]|"+t.src_ZPCc+"))("+p+")","ig"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),function(e){e.__index__=-1,e.__text_cache__=""}(e)}function f(e,t){var n=e.__index__,r=e.__last_index__,o=e.__text_cache__.slice(n,r);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=r+t,this.raw=o,this.text=o,this.url=o}function h(e,t){var n=new f(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function d(e,t){if(!(this instanceof d))return new d(e,t);var n;t||(n=e,Object.keys(n||{}).reduce(function(e,t){return e||a.hasOwnProperty(t)},!1)&&(t=e,e={})),this.__opts__=r({},a,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=r({},c,e),this.__compiled__={},this.__tlds__=u,this.__tlds_replaced__=!1,this.re={},p(this)}d.prototype.add=function(e,t){return this.__schemas__[e]=t,p(this),this},d.prototype.set=function(e){return this.__opts__=r(this.__opts__,e),this},d.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;var t,n,r,o,i,s,a,c;if(this.re.schema_test.test(e))for((a=this.re.schema_search).lastIndex=0;null!==(t=a.exec(e));)if(o=this.testSchemaAt(e,t[2],a.lastIndex)){this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+o;break}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(c=e.search(this.re.host_fuzzy_test))>=0&&(this.__index__<0||c=0&&null!==(r=e.match(this.re.email_fuzzy))&&(i=r.index+r[1].length,s=r.index+r[0].length,(this.__index__<0||ithis.__last_index__)&&(this.__schema__="mailto:",this.__index__=i,this.__last_index__=s)),this.__index__>=0},d.prototype.pretest=function(e){return this.re.pretest.test(e)},d.prototype.testSchemaAt=function(e,t,n){return this.__compiled__[t.toLowerCase()]?this.__compiled__[t.toLowerCase()].validate(e,n,this):0},d.prototype.match=function(e){var t=0,n=[];this.__index__>=0&&this.__text_cache__===e&&(n.push(h(this,t)),t=this.__last_index__);for(var r=t?e.slice(t):e;this.test(r);)n.push(h(this,t)),r=r.slice(this.__last_index__),t+=this.__last_index__;return n.length?n:null},d.prototype.tlds=function(e,t){return e=Array.isArray(e)?e:[e],t?(this.__tlds__=this.__tlds__.concat(e).sort().filter(function(e,t,n){return e!==n[t-1]}).reverse(),p(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,p(this),this)},d.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},d.prototype.onCompile=function(){},e.exports=d},function(e,t,n){"use strict";e.exports=function(e){var t={};t.src_Any=n(76).source,t.src_Cc=n(77).source,t.src_Z=n(78).source,t.src_P=n(57).source,t.src_ZPCc=[t.src_Z,t.src_P,t.src_Cc].join("|"),t.src_ZCc=[t.src_Z,t.src_Cc].join("|");return t.src_pseudo_letter="(?:(?![><|]|"+t.src_ZPCc+")"+t.src_Any+")",t.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",t.src_auth="(?:(?:(?!"+t.src_ZCc+"|[@/\\[\\]()]).)+@)?",t.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",t.src_host_terminator="(?=$|[><|]|"+t.src_ZPCc+")(?!-|_|:\\d|\\.-|\\.(?!$|"+t.src_ZPCc+"))",t.src_path="(?:[/?#](?:(?!"+t.src_ZCc+"|[><|]|[()[\\]{}.,\"'?!\\-]).|\\[(?:(?!"+t.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+t.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+t.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+t.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+t.src_ZCc+"|[']).)+\\'|\\'(?="+t.src_pseudo_letter+"|[-]).|\\.{2,4}[a-zA-Z0-9%/]|\\.(?!"+t.src_ZCc+"|[.]).|"+(e&&e["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+"\\,(?!"+t.src_ZCc+").|\\!(?!"+t.src_ZCc+"|[!]).|\\?(?!"+t.src_ZCc+"|[?]).)+|\\/)?",t.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',t.src_xn="xn--[a-z0-9\\-]{1,59}",t.src_domain_root="(?:"+t.src_xn+"|"+t.src_pseudo_letter+"{1,63})",t.src_domain="(?:"+t.src_xn+"|(?:"+t.src_pseudo_letter+")|(?:"+t.src_pseudo_letter+"(?:-|"+t.src_pseudo_letter+"){0,61}"+t.src_pseudo_letter+"))",t.src_host="(?:(?:(?:(?:"+t.src_domain+")\\.)*"+t.src_domain+"))",t.tpl_host_fuzzy="(?:"+t.src_ip4+"|(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%)))",t.tpl_host_no_ip_fuzzy="(?:(?:(?:"+t.src_domain+")\\.)+(?:%TLDS%))",t.src_host_strict=t.src_host+t.src_host_terminator,t.tpl_host_fuzzy_strict=t.tpl_host_fuzzy+t.src_host_terminator,t.src_host_port_strict=t.src_host+t.src_port+t.src_host_terminator,t.tpl_host_port_fuzzy_strict=t.tpl_host_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_port_no_ip_fuzzy_strict=t.tpl_host_no_ip_fuzzy+t.src_port+t.src_host_terminator,t.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+t.src_ZPCc+"|>|$))",t.tpl_email_fuzzy='(^|[><|]|"|\\(|'+t.src_ZCc+")("+t.src_email_name+"@"+t.tpl_host_fuzzy_strict+")",t.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_fuzzy_strict+t.src_path+")",t.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`||]|"+t.src_ZPCc+"))((?![$+<=>^`||])"+t.tpl_host_port_no_ip_fuzzy_strict+t.src_path+")",t}},function(e,t,n){(function(e,r){var o;/*! https://mths.be/punycode v1.4.1 by @mathias */!function(i){t&&t.nodeType,e&&e.nodeType;var s="object"==typeof r&&r;s.global!==s&&s.window!==s&&s.self;var a,c=2147483647,l=36,u=1,p=26,f=38,h=700,d=72,m=128,v="-",g=/^xn--/,y=/[^\x20-\x7E]/,b=/[\x2E\u3002\uFF0E\uFF61]/g,w={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},k=l-u,x=Math.floor,_=String.fromCharCode;function C(e){throw new RangeError(w[e])}function S(e,t){for(var n=e.length,r=[];n--;)r[n]=t(e[n]);return r}function O(e,t){var n=e.split("@"),r="";return n.length>1&&(r=n[0]+"@",e=n[1]),r+S((e=e.replace(b,".")).split("."),t).join(".")}function A(e){for(var t,n,r=[],o=0,i=e.length;o=55296&&t<=56319&&o65535&&(t+=_((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=_(e)}).join("")}function M(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function T(e,t,n){var r=0;for(e=n?x(e/h):e>>1,e+=x(e/t);e>k*p>>1;r+=l)e=x(e/k);return x(r+(k+1)*e/(e+f))}function D(e){var t,n,r,o,i,s,a,f,h,g,y,b=[],w=e.length,k=0,_=m,S=d;for((n=e.lastIndexOf(v))<0&&(n=0),r=0;r=128&&C("not-basic"),b.push(e.charCodeAt(r));for(o=n>0?n+1:0;o=w&&C("invalid-input"),((f=(y=e.charCodeAt(o++))-48<10?y-22:y-65<26?y-65:y-97<26?y-97:l)>=l||f>x((c-k)/s))&&C("overflow"),k+=f*s,!(f<(h=a<=S?u:a>=S+p?p:a-S));a+=l)s>x(c/(g=l-h))&&C("overflow"),s*=g;S=T(k-i,t=b.length+1,0==i),x(k/t)>c-_&&C("overflow"),_+=x(k/t),k%=t,b.splice(k++,0,_)}return E(b)}function N(e){var t,n,r,o,i,s,a,f,h,g,y,b,w,k,S,O=[];for(b=(e=A(e)).length,t=m,n=0,i=d,s=0;s=t&&yx((c-n)/(w=r+1))&&C("overflow"),n+=(a-t)*w,t=a,s=0;sc&&C("overflow"),y==t){for(f=n,h=l;!(f<(g=h<=i?u:h>=i+p?p:h-i));h+=l)S=f-g,k=l-g,O.push(_(M(g+S%k,0))),f=x(S/k);O.push(_(M(f,0))),i=T(n,w,r==o),n=0,++r}++n,++t}return O.join("")}a={version:"1.4.1",ucs2:{decode:A,encode:E},decode:D,encode:N,toASCII:function(e){return O(e,function(e){return y.test(e)?"xn--"+N(e):e})},toUnicode:function(e){return O(e,function(e){return g.test(e)?D(e.slice(4).toLowerCase()):e})}},void 0===(o=function(){return a}.call(t,n,t,e))||(e.exports=o)}()}).call(this,n(334)(e),n(51))},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){"use strict";e.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}}},function(e,t,n){"use strict";e.exports={options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","text_collapse"]}}}},function(e,t,n){"use strict";e.exports={options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","text_collapse"]}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o=n(43),i=(r=n(73))&&"object"==typeof r&&"default"in r?r.default:r,s=new o.Schema({nodes:{doc:{content:"block+"},paragraph:{content:"inline*",group:"block",parseDOM:[{tag:"p"}],toDOM:function(){return["p",0]}},blockquote:{content:"block+",group:"block",parseDOM:[{tag:"blockquote"}],toDOM:function(){return["blockquote",0]}},horizontal_rule:{group:"block",parseDOM:[{tag:"hr"}],toDOM:function(){return["div",["hr"]]}},heading:{attrs:{level:{default:1}},content:"inline*",group:"block",defining:!0,parseDOM:[{tag:"h1",attrs:{level:1}},{tag:"h2",attrs:{level:2}},{tag:"h3",attrs:{level:3}},{tag:"h4",attrs:{level:4}},{tag:"h5",attrs:{level:5}},{tag:"h6",attrs:{level:6}}],toDOM:function(e){return["h"+e.attrs.level,0]}},code_block:{content:"text*",group:"block",code:!0,defining:!0,attrs:{params:{default:""}},parseDOM:[{tag:"pre",preserveWhitespace:!0,getAttrs:function(e){return{params:e.getAttribute("data-params")||""}}}],toDOM:function(e){return["pre",e.attrs.params?{"data-params":e.attrs.params}:{},["code",0]]}},ordered_list:{content:"list_item+",group:"block",attrs:{order:{default:1},tight:{default:!1}},parseDOM:[{tag:"ol",getAttrs:function(e){return{order:e.hasAttribute("start")?+e.getAttribute("start"):1,tight:e.hasAttribute("data-tight")}}}],toDOM:function(e){return["ol",{start:1==e.attrs.order?null:e.attrs.order,"data-tight":e.attrs.tight?"true":null},0]}},bullet_list:{content:"list_item+",group:"block",attrs:{tight:{default:!1}},parseDOM:[{tag:"ul",getAttrs:function(e){return{tight:e.hasAttribute("data-tight")}}}],toDOM:function(e){return["ul",{"data-tight":e.attrs.tight?"true":null},0]}},list_item:{content:"paragraph block*",defining:!0,parseDOM:[{tag:"li"}],toDOM:function(){return["li",0]}},text:{group:"inline",toDOM:function(e){return e.text}},image:{inline:!0,attrs:{src:{},alt:{default:null},title:{default:null}},group:"inline",draggable:!0,parseDOM:[{tag:"img[src]",getAttrs:function(e){return{src:e.getAttribute("src"),title:e.getAttribute("title"),alt:e.getAttribute("alt")}}}],toDOM:function(e){return["img",e.attrs]}},hard_break:{inline:!0,group:"inline",selectable:!1,parseDOM:[{tag:"br"}],toDOM:function(){return["br"]}}},marks:{em:{parseDOM:[{tag:"i"},{tag:"em"},{style:"font-style",getAttrs:function(e){return"italic"==e&&null}}],toDOM:function(){return["em"]}},strong:{parseDOM:[{tag:"b"},{tag:"strong"},{style:"font-weight",getAttrs:function(e){return/^(bold(er)?|[5-9]\d{2,})$/.test(e)&&null}}],toDOM:function(){return["strong"]}},link:{attrs:{href:{},title:{default:null}},inclusive:!1,parseDOM:[{tag:"a[href]",getAttrs:function(e){return{href:e.getAttribute("href"),title:e.getAttribute("title")}}}],toDOM:function(e){return["a",e.attrs]}},code:{parseDOM:[{tag:"code"}],toDOM:function(){return["code"]}}}});var a=function(e,t){this.schema=e,this.stack=[{type:e.topNodeType,content:[]}],this.marks=o.Mark.none,this.tokenHandlers=t};function c(e,t){return e.getAttrs?e.getAttrs(t):e.attrs instanceof Function?e.attrs(t):e.attrs}function l(e){return"code_inline"==e||"code_block"==e||"fence"==e}function u(e){return"\n"==e[e.length-1]?e.slice(0,e.length-1):e}function p(){}a.prototype.top=function(){return this.stack[this.stack.length-1]},a.prototype.push=function(e){this.stack.length&&this.top().content.push(e)},a.prototype.addText=function(e){if(e){var t,n=this.top().content,r=n[n.length-1],i=this.schema.text(e,this.marks);r&&(t=function(e,t){if(e.isText&&t.isText&&o.Mark.sameSet(e.marks,t.marks))return e.withText(e.text+t.text)}(r,i))?n[n.length-1]=t:n.push(i)}},a.prototype.openMark=function(e){this.marks=e.addToSet(this.marks)},a.prototype.closeMark=function(e){this.marks=e.removeFromSet(this.marks)},a.prototype.parseTokens=function(e){for(var t=0;t ",null,t,function(){return e.renderContent(t)})},code_block:function(e,t){e.write("```"+(t.attrs.params||"")+"\n"),e.text(t.textContent,!1),e.ensureNewLine(),e.write("```"),e.closeBlock(t)},heading:function(e,t){e.write(e.repeat("#",t.attrs.level)+" "),e.renderInline(t),e.closeBlock(t)},horizontal_rule:function(e,t){e.write(t.attrs.markup||"---"),e.closeBlock(t)},bullet_list:function(e,t){e.renderList(t," ",function(){return(t.attrs.bullet||"*")+" "})},ordered_list:function(e,t){var n=t.attrs.order||1,r=String(n+t.childCount-1).length,o=e.repeat(" ",r+2);e.renderList(t,o,function(t){var o=String(n+t);return e.repeat(" ",r-o.length)+o+". "})},list_item:function(e,t){e.renderContent(t)},paragraph:function(e,t){e.renderInline(t),e.closeBlock(t)},image:function(e,t){e.write("!["+e.esc(t.attrs.alt||"")+"]("+e.esc(t.attrs.src)+(t.attrs.title?" "+e.quote(t.attrs.title):"")+")")},hard_break:function(e,t,n,r){for(var o=r+1;o":"]("+e.esc(t.attrs.href)+(t.attrs.title?" "+e.quote(t.attrs.title):"")+")"}},code:{open:function(e,t,n,r){return v(n.child(r),-1)},close:function(e,t,n,r){return v(n.child(r-1),1)},escape:!1}});function v(e,t){var n,r=/`+/g,o=0;if(e.isText)for(;n=r.exec(e.text);)o=Math.max(o,n[0].length);for(var i=o>0&&t>0?" `":"`",s=0;s0&&t<0&&(i+=" "),i}function g(e,t,n,r){if(e.attrs.title)return!1;var o=t.child(n+(r<0?-1:0));if(!o.isText||o.text!=e.attrs.href||o.marks[o.marks.length-1]!=e)return!1;if(n==(r<0?1:t.childCount-1))return!0;var i=t.child(n+(r<0?-2:1));return!e.isInSet(i.marks)}var y=function(e,t,n){this.nodes=e,this.marks=t,this.delim=this.out="",this.closed=!1,this.inTightList=!1,this.options=n||{},void 0===this.options.tightLists&&(this.options.tightLists=!1)};y.prototype.flushClose=function(e){if(this.closed){if(this.atBlank()||(this.out+="\n"),null==e&&(e=2),e>1){var t=this.delim,n=/\s+$/.exec(t);n&&(t=t.slice(0,t.length-n[0].length));for(var r=1;ry?a=a.slice(0,y).concat(g).concat(a.slice(y,v)).concat(a.slice(v+1,m)):y>v&&(a=a.slice(0,v).concat(a.slice(v+1,y)).concat(g).concat(a.slice(y,m)));continue e}}}for(var w=0;w