From 76d14fbaa0a240c34c4e92052f5a7e253b63022e Mon Sep 17 00:00:00 2001 From: TeamCity Date: Tue, 17 Sep 2024 17:25:30 +0000 Subject: [PATCH] Update spec version --- release/spec-html/resources/js/main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/spec-html/resources/js/main.js b/release/spec-html/resources/js/main.js index e020a7d5..92b8d36a 100644 --- a/release/spec-html/resources/js/main.js +++ b/release/spec-html/resources/js/main.js @@ -1,2 +1,2 @@ /*! For license information please see main.js.LICENSE.txt */ -define("main",[],(()=>{return t={651:t=>{window,t.exports=function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=159)}([function(t,e,n){t.exports=function(){"use strict";var t=navigator.userAgent,e=navigator.platform,n=/gecko\/\d/i.test(t),r=/MSIE \d/.test(t),i=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(t),o=/Edge\/(\d+)/.exec(t),a=r||i||o,s=a&&(r?document.documentMode||6:+(o||i)[1]),l=!o&&/WebKit\//.test(t),c=l&&/Qt\/\d+\.\d+/.test(t),u=!o&&/Chrome\//.test(t),p=/Opera\//.test(t),f=/Apple Computer/.test(navigator.vendor),h=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(t),d=/PhantomJS/.test(t),m=!o&&/AppleWebKit/.test(t)&&/Mobile\/\w+/.test(t),g=/Android/.test(t),y=m||g||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(t),v=m||/Mac/.test(e),_=/\bCrOS\b/.test(t),b=/win/i.test(e),x=p&&t.match(/Version\/(\d*\.\d*)/);x&&(x=Number(x[1])),x&&x>=15&&(p=!1,l=!0);var $=v&&(c||p&&(null==x||x<12.11)),w=n||a&&s>=9;function k(t){return new RegExp("(^|\\s)"+t+"(?:$|\\s)\\s*")}var C,S=function(t,e){var n=t.className,r=k(e).exec(n);if(r){var i=n.slice(r.index+r[0].length);t.className=n.slice(0,r.index)+(i?r[1]+i:"")}};function E(t){for(var e=t.childNodes.length;e>0;--e)t.removeChild(t.firstChild);return t}function T(t,e){return E(t).appendChild(e)}function O(t,e,n,r){var i=document.createElement(t);if(n&&(i.className=n),r&&(i.style.cssText=r),"string"==typeof e)i.appendChild(document.createTextNode(e));else if(e)for(var o=0;o=e)return a+(e-o);a+=s-o,a+=n-a%n,o=s+1}}m?M=function(t){t.selectionStart=0,t.selectionEnd=t.value.length}:a&&(M=function(t){try{t.select()}catch(t){}});var D=function(){this.id=null};function q(t,e){for(var n=0;n=e)return r+Math.min(a,e-i);if(i+=o-r,r=o+1,(i+=n-i%n)>=e)return r}}var W=[""];function K(t){for(;W.length<=t;)W.push(G(W)+" ");return W[t]}function G(t){return t[t.length-1]}function J(t,e){for(var n=[],r=0;r"€"&&(t.toUpperCase()!=t.toLowerCase()||Z.test(t))}function tt(t,e){return e?!!(e.source.indexOf("\\w")>-1&&Q(t))||e.test(t):Q(t)}function et(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e])return!1;return!0}var nt=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function rt(t){return t.charCodeAt(0)>=768&&nt.test(t)}function it(t,e,n){for(;(n<0?e>0:en?-1:1;;){if(e==n)return e;var i=(e+n)/2,o=r<0?Math.ceil(i):Math.floor(i);if(o==e)return t(o)?e:n;t(o)?n=o:e=o+r}}var at=null;function st(t,e,n){var r;at=null;for(var i=0;ie)return i;o.to==e&&(o.from!=o.to&&"before"==n?r=i:at=i),o.from==e&&(o.from!=o.to&&"before"!=n?r=i:at=i)}return null!=r?r:at}var lt=function(){var t=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,e=/[stwN]/,n=/[LRr]/,r=/[Lb1n]/,i=/[1n]/;function o(t,e,n){this.level=t,this.from=e,this.to=n}return function(a,s){var l,c="ltr"==s?"L":"R";if(0==a.length||"ltr"==s&&!t.test(a))return!1;for(var u=a.length,p=[],f=0;f-1&&(r[e]=i.slice(0,o).concat(i.slice(o+1)))}}}function dt(t,e){var n=ft(t,e);if(n.length)for(var r=Array.prototype.slice.call(arguments,2),i=0;i0}function vt(t){t.prototype.on=function(t,e){pt(this,t,e)},t.prototype.off=function(t,e){ht(this,t,e)}}function _t(t){t.preventDefault?t.preventDefault():t.returnValue=!1}function bt(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0}function xt(t){return null!=t.defaultPrevented?t.defaultPrevented:0==t.returnValue}function $t(t){_t(t),bt(t)}function wt(t){return t.target||t.srcElement}function kt(t){var e=t.which;return null==e&&(1&t.button?e=1:2&t.button?e=3:4&t.button&&(e=2)),v&&t.ctrlKey&&1==e&&(e=3),e}var Ct,St,Et=function(){if(a&&s<9)return!1;var t=O("div");return"draggable"in t||"dragDrop"in t}();function Tt(t){if(null==Ct){var e=O("span","​");T(t,O("span",[e,document.createTextNode("x")])),0!=t.firstChild.offsetHeight&&(Ct=e.offsetWidth<=1&&e.offsetHeight>2&&!(a&&s<8))}var n=Ct?O("span","​"):O("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function Ot(t){if(null!=St)return St;var e=T(t,document.createTextNode("AخA")),n=C(e,0,1).getBoundingClientRect(),r=C(e,1,2).getBoundingClientRect();return E(t),!(!n||n.left==n.right)&&(St=r.right-n.right<3)}var Nt,zt=3!="\n\nb".split(/\n/).length?function(t){for(var e=0,n=[],r=t.length;e<=r;){var i=t.indexOf("\n",e);-1==i&&(i=t.length);var o=t.slice(e,"\r"==t.charAt(i-1)?i-1:i),a=o.indexOf("\r");-1!=a?(n.push(o.slice(0,a)),e+=a+1):(n.push(o),e=i+1)}return n}:function(t){return t.split(/\r\n?|\n/)},jt=window.getSelection?function(t){try{return t.selectionStart!=t.selectionEnd}catch(t){return!1}}:function(t){var e;try{e=t.ownerDocument.selection.createRange()}catch(t){}return!(!e||e.parentElement()!=t)&&0!=e.compareEndPoints("StartToEnd",e)},At="oncopy"in(Nt=O("div"))||(Nt.setAttribute("oncopy","return;"),"function"==typeof Nt.oncopy),Lt=null,Mt={},Pt={};function It(t){if("string"==typeof t&&Pt.hasOwnProperty(t))t=Pt[t];else if(t&&"string"==typeof t.name&&Pt.hasOwnProperty(t.name)){var e=Pt[t.name];"string"==typeof e&&(e={name:e}),(t=X(e,t)).name=e.name}else{if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+xml$/.test(t))return It("application/xml");if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+json$/.test(t))return It("application/json")}return"string"==typeof t?{name:t}:t||{name:"null"}}function Rt(t,e){e=It(e);var n=Mt[e.name];if(!n)return Rt(t,"text/plain");var r=n(t,e);if(Dt.hasOwnProperty(e.name)){var i=Dt[e.name];for(var o in i)i.hasOwnProperty(o)&&(r.hasOwnProperty(o)&&(r["_"+o]=r[o]),r[o]=i[o])}if(r.name=e.name,e.helperType&&(r.helperType=e.helperType),e.modeProps)for(var a in e.modeProps)r[a]=e.modeProps[a];return r}var Dt={};function qt(t,e){I(e,Dt.hasOwnProperty(t)?Dt[t]:Dt[t]={})}function Ft(t,e){if(!0===e)return e;if(t.copyState)return t.copyState(e);var n={};for(var r in e){var i=e[r];i instanceof Array&&(i=i.concat([])),n[r]=i}return n}function Bt(t,e){for(var n;t.innerMode&&(n=t.innerMode(e))&&n.mode!=t;)e=n.state,t=n.mode;return n||{mode:t,state:e}}function Ht(t,e,n){return!t.startState||t.startState(e,n)}var Vt=function(t,e,n){this.pos=this.start=0,this.string=t,this.tabSize=e||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};function Ut(t,e){if((e-=t.first)<0||e>=t.size)throw new Error("There is no line "+(e+t.first)+" in the document.");for(var n=t;!n.lines;)for(var r=0;;++r){var i=n.children[r],o=i.chunkSize();if(e=t.first&&en?Qt(n,Ut(t,n).text.length):function(t,e){var n=t.ch;return null==n||n>e?Qt(t.line,e):n<0?Qt(t.line,0):t}(e,Ut(t,e.line).text.length)}function se(t,e){for(var n=[],r=0;r=this.string.length},Vt.prototype.sol=function(){return this.pos==this.lineStart},Vt.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Vt.prototype.next=function(){if(this.pose},Vt.prototype.eatSpace=function(){for(var t=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>t},Vt.prototype.skipToEnd=function(){this.pos=this.string.length},Vt.prototype.skipTo=function(t){var e=this.string.indexOf(t,this.pos);if(e>-1)return this.pos=e,!0},Vt.prototype.backUp=function(t){this.pos-=t},Vt.prototype.column=function(){return this.lastColumnPos0?null:(r&&!1!==e&&(this.pos+=r[0].length),r)}var i=function(t){return n?t.toLowerCase():t};if(i(this.string.substr(this.pos,t.length))==i(t))return!1!==e&&(this.pos+=t.length),!0},Vt.prototype.current=function(){return this.string.slice(this.start,this.pos)},Vt.prototype.hideFirstChars=function(t,e){this.lineStart+=t;try{return e()}finally{this.lineStart-=t}},Vt.prototype.lookAhead=function(t){var e=this.lineOracle;return e&&e.lookAhead(t)},Vt.prototype.baseToken=function(){var t=this.lineOracle;return t&&t.baseToken(this.pos)};var le=function(t,e){this.state=t,this.lookAhead=e},ce=function(t,e,n,r){this.state=e,this.doc=t,this.line=n,this.maxLookAhead=r||0,this.baseTokens=null,this.baseTokenPos=1};function ue(t,e,n,r){var i=[t.state.modeGen],o={};_e(t,e.text,t.doc.mode,n,(function(t,e){return i.push(t,e)}),o,r);for(var a=n.state,s=function(r){n.baseTokens=i;var s=t.state.overlays[r],l=1,c=0;n.state=!0,_e(t,e.text,s.mode,n,(function(t,e){for(var n=l;ct&&i.splice(l,1,t,i[l+1],r),l+=2,c=Math.min(t,r)}if(e)if(s.opaque)i.splice(n,l-n,t,"overlay "+e),l=n+2;else for(;nt.options.maxHighlightLength&&Ft(t.doc.mode,r.state),o=ue(t,e,r);i&&(r.state=i),e.stateAfter=r.save(!i),e.styles=o.styles,o.classes?e.styleClasses=o.classes:e.styleClasses&&(e.styleClasses=null),n===t.doc.highlightFrontier&&(t.doc.modeFrontier=Math.max(t.doc.modeFrontier,++t.doc.highlightFrontier))}return e.styles}function fe(t,e,n){var r=t.doc,i=t.display;if(!r.mode.startState)return new ce(r,!0,e);var o=function(t,e,n){for(var r,i,o=t.doc,a=n?-1:e-(t.doc.mode.innerMode?1e3:100),s=e;s>a;--s){if(s<=o.first)return o.first;var l=Ut(o,s-1),c=l.stateAfter;if(c&&(!n||s+(c instanceof le?c.lookAhead:0)<=o.modeFrontier))return s;var u=R(l.text,null,t.options.tabSize);(null==i||r>u)&&(i=s-1,r=u)}return i}(t,e,n),a=o>r.first&&Ut(r,o-1).stateAfter,s=a?ce.fromSaved(r,a,o):new ce(r,Ht(r.mode),o);return r.iter(o,e,(function(n){he(t,n.text,s);var r=s.line;n.stateAfter=r==e-1||r%5==0||r>=i.viewFrom&&re.start)return o}throw new Error("Mode "+t.name+" failed to advance stream.")}ce.prototype.lookAhead=function(t){var e=this.doc.getLine(this.line+t);return null!=e&&t>this.maxLookAhead&&(this.maxLookAhead=t),e},ce.prototype.baseToken=function(t){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=t;)this.baseTokenPos+=2;var e=this.baseTokens[this.baseTokenPos+1];return{type:e&&e.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-t}},ce.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},ce.fromSaved=function(t,e,n){return e instanceof le?new ce(t,Ft(t.mode,e.state),n,e.lookAhead):new ce(t,Ft(t.mode,e),n)},ce.prototype.save=function(t){var e=!1!==t?Ft(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new le(e,this.maxLookAhead):e};var ge=function(t,e,n){this.start=t.start,this.end=t.pos,this.string=t.current(),this.type=e||null,this.state=n};function ye(t,e,n,r){var i,o,a=t.doc,s=a.mode,l=Ut(a,(e=ae(a,e)).line),c=fe(t,e.line,n),u=new Vt(l.text,t.options.tabSize,c);for(r&&(o=[]);(r||u.post.options.maxHighlightLength?(s=!1,a&&he(t,e,r,p.pos),p.pos=e.length,l=null):l=ve(me(n,p,r.state,f),o),f){var h=f[0].name;h&&(l="m-"+(l?h+" "+l:h))}if(!s||u!=l){for(;c=e:o.to>e);(r||(r=[])).push(new $e(a,o.from,s?null:o.to))}}return r}(n,i,a),l=function(t,e,n){var r;if(t)for(var i=0;i=e:o.to>e)||o.from==e&&"bookmark"==a.type&&(!n||o.marker.insertLeft)){var s=null==o.from||(a.inclusiveLeft?o.from<=e:o.from0&&s)for(var _=0;_e)&&(!n||ze(n,o.marker)<0)&&(n=o.marker)}return n}function Pe(t,e,n,r,i){var o=Ut(t,e),a=xe&&o.markedSpans;if(a)for(var s=0;s=0&&p<=0||u<=0&&p>=0)&&(u<=0&&(l.marker.inclusiveRight&&i.inclusiveLeft?te(c.to,n)>=0:te(c.to,n)>0)||u>=0&&(l.marker.inclusiveRight&&i.inclusiveLeft?te(c.from,r)<=0:te(c.from,r)<0)))return!0}}}function Ie(t){for(var e;e=Ae(t);)t=e.find(-1,!0).line;return t}function Re(t,e){var n=Ut(t,e),r=Ie(n);return n==r?e:Jt(r)}function De(t,e){if(e>t.lastLine())return e;var n,r=Ut(t,e);if(!qe(t,r))return e;for(;n=Le(r);)r=n.find(1,!0).line;return Jt(r)+1}function qe(t,e){var n=xe&&e.markedSpans;if(n)for(var r=void 0,i=0;ie.maxLineLength&&(e.maxLineLength=n,e.maxLine=t)}))}var Ue=function(t,e,n){this.text=t,Te(this,e),this.height=n?n(this):1};function We(t){t.parent=null,Ee(t)}Ue.prototype.lineNo=function(){return Jt(this)},vt(Ue);var Ke={},Ge={};function Je(t,e){if(!t||/^\s*$/.test(t))return null;var n=e.addModeClass?Ge:Ke;return n[t]||(n[t]=t.replace(/\S+/g,"cm-$&"))}function Ye(t,e){var n=N("span",null,null,l?"padding-right: .1px":null),r={pre:N("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:t,trailingSpace:!1,splitSpaces:t.getOption("lineWrapping")};e.measure={};for(var i=0;i<=(e.rest?e.rest.length:0);i++){var o=i?e.rest[i-1]:e.line,a=void 0;r.pos=0,r.addToken=Ze,Ot(t.display.measure)&&(a=ct(o,t.doc.direction))&&(r.addToken=Qe(r.addToken,a)),r.map=[],en(o,r,pe(t,o,e!=t.display.externalMeasured&&Jt(o))),o.styleClasses&&(o.styleClasses.bgClass&&(r.bgClass=L(o.styleClasses.bgClass,r.bgClass||"")),o.styleClasses.textClass&&(r.textClass=L(o.styleClasses.textClass,r.textClass||""))),0==r.map.length&&r.map.push(0,0,r.content.appendChild(Tt(t.display.measure))),0==i?(e.measure.map=r.map,e.measure.cache={}):((e.measure.maps||(e.measure.maps=[])).push(r.map),(e.measure.caches||(e.measure.caches=[])).push({}))}if(l){var s=r.content.lastChild;(/\bcm-tab\b/.test(s.className)||s.querySelector&&s.querySelector(".cm-tab"))&&(r.content.className="cm-tab-wrap-hack")}return dt(t,"renderLine",t,e.line,r.pre),r.pre.className&&(r.textClass=L(r.pre.className,r.textClass||"")),r}function Xe(t){var e=O("span","•","cm-invalidchar");return e.title="\\u"+t.charCodeAt(0).toString(16),e.setAttribute("aria-label",e.title),e}function Ze(t,e,n,r,i,o,l){if(e){var c,u=t.splitSpaces?function(t,e){if(t.length>1&&!/ /.test(t))return t;for(var n=e,r="",i=0;ic&&p.from<=c);f++);if(p.to>=u)return t(n,r,i,o,a,s,l);t(n,r.slice(0,p.to-c),i,o,null,s,l),o=null,r=r.slice(p.to-c),c=p.to}}}function tn(t,e,n,r){var i=!r&&n.widgetNode;i&&t.map.push(t.pos,t.pos+e,i),!r&&t.cm.display.input.needsContentAttribute&&(i||(i=t.content.appendChild(document.createElement("span"))),i.setAttribute("cm-marker",n.id)),i&&(t.cm.display.input.setUneditable(i),t.content.appendChild(i)),t.pos+=e,t.trailingSpace=!1}function en(t,e,n){var r=t.markedSpans,i=t.text,o=0;if(r)for(var a,s,l,c,u,p,f,h=i.length,d=0,m=1,g="",y=0;;){if(y==d){l=c=u=s="",f=null,p=null,y=1/0;for(var v=[],_=void 0,b=0;bd||$.collapsed&&x.to==d&&x.from==d)){if(null!=x.to&&x.to!=d&&y>x.to&&(y=x.to,c=""),$.className&&(l+=" "+$.className),$.css&&(s=(s?s+";":"")+$.css),$.startStyle&&x.from==d&&(u+=" "+$.startStyle),$.endStyle&&x.to==y&&(_||(_=[])).push($.endStyle,x.to),$.title&&((f||(f={})).title=$.title),$.attributes)for(var w in $.attributes)(f||(f={}))[w]=$.attributes[w];$.collapsed&&(!p||ze(p.marker,$)<0)&&(p=x)}else x.from>d&&y>x.from&&(y=x.from)}if(_)for(var k=0;k<_.length;k+=2)_[k+1]==y&&(c+=" "+_[k]);if(!p||p.from==d)for(var C=0;C=h)break;for(var S=Math.min(h,y);;){if(g){var E=d+g.length;if(!p){var T=E>S?g.slice(0,S-d):g;e.addToken(e,T,a?a+l:l,u,d+T.length==y?c:"",s,f)}if(E>=S){g=g.slice(S-d),d=S;break}d=E,u=""}g=i.slice(o,o=n[m++]),a=Je(n[m++],e.cm.options)}}else for(var O=1;On)return{map:t.measure.maps[i],cache:t.measure.caches[i],before:!0}}function On(t,e,n,r){return jn(t,zn(t,e),n,r)}function Nn(t,e){if(e>=t.display.viewFrom&&e=n.lineN&&e2&&o.push((l.bottom+c.top)/2-n.top)}}o.push(n.bottom-n.top)}}(t,e.view,e.rect),e.hasHeights=!0),(o=function(t,e,n,r){var i,o=Mn(e.map,n,r),l=o.node,c=o.start,u=o.end,p=o.collapse;if(3==l.nodeType){for(var f=0;f<4;f++){for(;c&&rt(e.line.text.charAt(o.coverStart+c));)--c;for(;o.coverStart+u1}(t))return e;var n=screen.logicalXDPI/screen.deviceXDPI,r=screen.logicalYDPI/screen.deviceYDPI;return{left:e.left*n,right:e.right*n,top:e.top*r,bottom:e.bottom*r}}(t.display.measure,i))}else{var h;c>0&&(p=r="right"),i=t.options.lineWrapping&&(h=l.getClientRects()).length>1?h["right"==r?h.length-1:0]:l.getBoundingClientRect()}if(a&&s<9&&!c&&(!i||!i.left&&!i.right)){var d=l.parentNode.getClientRects()[0];i=d?{left:d.left,right:d.left+er(t.display),top:d.top,bottom:d.bottom}:Ln}for(var m=i.top-e.rect.top,g=i.bottom-e.rect.top,y=(m+g)/2,v=e.view.measure.heights,_=0;_e)&&(i=(o=l-s)-1,e>=l&&(a="right")),null!=i){if(r=t[c+2],s==l&&n==(r.insertLeft?"left":"right")&&(a=n),"left"==n&&0==i)for(;c&&t[c-2]==t[c-3]&&t[c-1].insertLeft;)r=t[2+(c-=3)],a="left";if("right"==n&&i==l-s)for(;c=0&&(n=t[i]).left==n.right;i--);return n}function In(t){if(t.measure&&(t.measure.cache={},t.measure.heights=null,t.rest))for(var e=0;e=r.text.length?(l=r.text.length,c="before"):l<=0&&(l=0,c="after"),!s)return a("before"==c?l-1:l,"before"==c);function u(t,e,n){return a(n?t-1:t,1==s[e].level!=n)}var p=st(s,l,c),f=at,h=u(l,p,"before"==c);return null!=f&&(h.other=u(l,f,"before"!=c)),h}function Kn(t,e){var n=0;e=ae(t.doc,e),t.options.lineWrapping||(n=er(t.display)*e.ch);var r=Ut(t.doc,e.line),i=Be(r)+$n(t.display);return{left:n,right:n,top:i,bottom:i+r.height}}function Gn(t,e,n,r,i){var o=Qt(t,e,n);return o.xRel=i,r&&(o.outside=r),o}function Jn(t,e,n){var r=t.doc;if((n+=t.display.viewOffset)<0)return Gn(r.first,0,null,-1,-1);var i=Yt(r,n),o=r.first+r.size-1;if(i>o)return Gn(r.first+r.size-1,Ut(r,o).text.length,null,1,1);e<0&&(e=0);for(var a=Ut(r,i);;){var s=Qn(t,a,i,e,n),l=Me(a,s.ch+(s.xRel>0||s.outside>0?1:0));if(!l)return s;var c=l.find(1);if(c.line==i)return c;a=Ut(r,i=c.line)}}function Yn(t,e,n,r){r-=Bn(e);var i=e.text.length,o=ot((function(e){return jn(t,n,e-1).bottom<=r}),i,0);return i=ot((function(e){return jn(t,n,e).top>r}),o,i),{begin:o,end:i}}function Xn(t,e,n,r){return n||(n=zn(t,e)),Yn(t,e,n,Hn(t,e,jn(t,n,r),"line").top)}function Zn(t,e,n,r){return!(t.bottom<=n)&&(t.top>n||(r?t.left:t.right)>e)}function Qn(t,e,n,r,i){i-=Be(e);var o=zn(t,e),a=Bn(e),s=0,l=e.text.length,c=!0,u=ct(e,t.doc.direction);if(u){var p=(t.options.lineWrapping?function(t,e,n,r,i,o,a){var s=Yn(t,e,r,a),l=s.begin,c=s.end;/\s/.test(e.text.charAt(c-1))&&c--;for(var u=null,p=null,f=0;f=c||h.to<=l)){var d=jn(t,r,1!=h.level?Math.min(c,h.to)-1:Math.max(l,h.from)).right,m=dm)&&(u=h,p=m)}}return u||(u=i[i.length-1]),u.fromc&&(u={from:u.from,to:c,level:u.level}),u}:function(t,e,n,r,i,o,a){var s=ot((function(s){var l=i[s],c=1!=l.level;return Zn(Wn(t,Qt(n,c?l.to:l.from,c?"before":"after"),"line",e,r),o,a,!0)}),0,i.length-1),l=i[s];if(s>0){var c=1!=l.level,u=Wn(t,Qt(n,c?l.from:l.to,c?"after":"before"),"line",e,r);Zn(u,o,a,!0)&&u.top>a&&(l=i[s-1])}return l})(t,e,n,o,u,r,i);s=(c=1!=p.level)?p.from:p.to-1,l=c?p.to:p.from-1}var f,h,d=null,m=null,g=ot((function(e){var n=jn(t,o,e);return n.top+=a,n.bottom+=a,!!Zn(n,r,i,!1)&&(n.top<=i&&n.left<=r&&(d=e,m=n),!0)}),s,l),y=!1;if(m){var v=r-m.left=b.bottom?1:0}return Gn(n,g=it(e.text,g,1),h,y,r-f)}function tr(t){if(null!=t.cachedTextHeight)return t.cachedTextHeight;if(null==An){An=O("pre",null,"CodeMirror-line-like");for(var e=0;e<49;++e)An.appendChild(document.createTextNode("x")),An.appendChild(O("br"));An.appendChild(document.createTextNode("x"))}T(t.measure,An);var n=An.offsetHeight/50;return n>3&&(t.cachedTextHeight=n),E(t.measure),n||1}function er(t){if(null!=t.cachedCharWidth)return t.cachedCharWidth;var e=O("span","xxxxxxxxxx"),n=O("pre",[e],"CodeMirror-line-like");T(t.measure,n);var r=e.getBoundingClientRect(),i=(r.right-r.left)/10;return i>2&&(t.cachedCharWidth=i),i||10}function nr(t){for(var e=t.display,n={},r={},i=e.gutters.clientLeft,o=e.gutters.firstChild,a=0;o;o=o.nextSibling,++a){var s=t.display.gutterSpecs[a].className;n[s]=o.offsetLeft+o.clientLeft+i,r[s]=o.clientWidth}return{fixedPos:rr(e),gutterTotalWidth:e.gutters.offsetWidth,gutterLeft:n,gutterWidth:r,wrapperWidth:e.wrapper.clientWidth}}function rr(t){return t.scroller.getBoundingClientRect().left-t.sizer.getBoundingClientRect().left}function ir(t){var e=tr(t.display),n=t.options.lineWrapping,r=n&&Math.max(5,t.display.scroller.clientWidth/er(t.display)-3);return function(i){if(qe(t.doc,i))return 0;var o=0;if(i.widgets)for(var a=0;a=t.display.viewTo)return null;if((e-=t.display.viewFrom)<0)return null;for(var n=t.display.view,r=0;re)&&(i.updateLineNumbers=e),t.curOp.viewChanged=!0,e>=i.viewTo)xe&&Re(t.doc,e)i.viewFrom?ur(t):(i.viewFrom+=r,i.viewTo+=r);else if(e<=i.viewFrom&&n>=i.viewTo)ur(t);else if(e<=i.viewFrom){var o=pr(t,n,n+r,1);o?(i.view=i.view.slice(o.index),i.viewFrom=o.lineN,i.viewTo+=r):ur(t)}else if(n>=i.viewTo){var a=pr(t,e,e,-1);a?(i.view=i.view.slice(0,a.index),i.viewTo=a.lineN):ur(t)}else{var s=pr(t,e,e,-1),l=pr(t,n,n+r,1);s&&l?(i.view=i.view.slice(0,s.index).concat(rn(t,s.lineN,l.lineN)).concat(i.view.slice(l.index)),i.viewTo+=r):ur(t)}var c=i.externalMeasured;c&&(n=i.lineN&&e=r.viewTo)){var o=r.view[sr(t,e)];if(null!=o.node){var a=o.changes||(o.changes=[]);-1==q(a,n)&&a.push(n)}}}function ur(t){t.display.viewFrom=t.display.viewTo=t.doc.first,t.display.view=[],t.display.viewOffset=0}function pr(t,e,n,r){var i,o=sr(t,e),a=t.display.view;if(!xe||n==t.doc.first+t.doc.size)return{index:o,lineN:n};for(var s=t.display.viewFrom,l=0;l0){if(o==a.length-1)return null;i=s+a[o].size-e,o++}else i=s-e;e+=i,n+=i}for(;Re(t.doc,n)!=n;){if(o==(r<0?0:a.length-1))return null;n+=r*a[o-(r<0?1:0)].size,o+=r}return{index:o,lineN:n}}function fr(t){for(var e=t.display.view,n=0,r=0;r=t.display.viewTo||s.to().linee||e==n&&a.to==e)&&(r(Math.max(a.from,e),Math.min(a.to,n),1==a.level?"rtl":"ltr",o),i=!0)}i||r(e,n,"ltr")}(m,n||0,null==r?f:r,(function(t,e,i,p){var g="ltr"==i,y=h(t,g?"left":"right"),v=h(e-1,g?"right":"left"),_=null==n&&0==t,b=null==r&&e==f,x=0==p,$=!m||p==m.length-1;if(v.top-y.top<=3){var w=(c?b:_)&&$,k=(c?_:b)&&x?s:(g?y:v).left,C=w?l:(g?v:y).right;u(k,y.top,C-k,y.bottom)}else{var S,E,T,O;g?(S=c&&_&&x?s:y.left,E=c?l:d(t,i,"before"),T=c?s:d(e,i,"after"),O=c&&b&&$?l:v.right):(S=c?d(t,i,"before"):s,E=!c&&_&&x?l:y.right,T=!c&&b&&$?s:v.left,O=c?d(e,i,"after"):l),u(S,y.top,E-S,y.bottom),y.bottom0?e.blinker=setInterval((function(){return e.cursorDiv.style.visibility=(n=!n)?"":"hidden"}),t.options.cursorBlinkRate):t.options.cursorBlinkRate<0&&(e.cursorDiv.style.visibility="hidden")}}function _r(t){t.state.focused||(t.display.input.focus(),xr(t))}function br(t){t.state.delayingBlurEvent=!0,setTimeout((function(){t.state.delayingBlurEvent&&(t.state.delayingBlurEvent=!1,$r(t))}),100)}function xr(t,e){t.state.delayingBlurEvent&&(t.state.delayingBlurEvent=!1),"nocursor"!=t.options.readOnly&&(t.state.focused||(dt(t,"focus",t,e),t.state.focused=!0,A(t.display.wrapper,"CodeMirror-focused"),t.curOp||t.display.selForContextMenu==t.doc.sel||(t.display.input.reset(),l&&setTimeout((function(){return t.display.input.reset(!0)}),20)),t.display.input.receivedFocus()),vr(t))}function $r(t,e){t.state.delayingBlurEvent||(t.state.focused&&(dt(t,"blur",t,e),t.state.focused=!1,S(t.display.wrapper,"CodeMirror-focused")),clearInterval(t.display.blinker),setTimeout((function(){t.state.focused||(t.display.shift=!1)}),150))}function wr(t){for(var e=t.display,n=e.lineDiv.offsetTop,r=0;r.005||f<-.005)&&(Gt(i.line,l),kr(i.line),i.rest))for(var h=0;ht.display.sizerWidth){var d=Math.ceil(c/er(t.display));d>t.display.maxLineLength&&(t.display.maxLineLength=d,t.display.maxLine=i.line,t.display.maxLineChanged=!0)}}}}function kr(t){if(t.widgets)for(var e=0;e=a&&(o=Yt(e,Be(Ut(e,l))-t.wrapper.clientHeight),a=l)}return{from:o,to:Math.max(a,o+1)}}function Sr(t,e){var n=t.display,r=tr(t.display);e.top<0&&(e.top=0);var i=t.curOp&&null!=t.curOp.scrollTop?t.curOp.scrollTop:n.scroller.scrollTop,o=En(t),a={};e.bottom-e.top>o&&(e.bottom=e.top+o);var s=t.doc.height+wn(n),l=e.tops-r;if(e.topi+o){var u=Math.min(e.top,(c?s:e.bottom)-o);u!=i&&(a.scrollTop=u)}var p=t.curOp&&null!=t.curOp.scrollLeft?t.curOp.scrollLeft:n.scroller.scrollLeft,f=Sn(t)-(t.options.fixedGutter?n.gutters.offsetWidth:0),h=e.right-e.left>f;return h&&(e.right=e.left+f),e.left<10?a.scrollLeft=0:e.leftf+p-3&&(a.scrollLeft=e.right+(h?0:10)-f),a}function Er(t,e){null!=e&&(Nr(t),t.curOp.scrollTop=(null==t.curOp.scrollTop?t.doc.scrollTop:t.curOp.scrollTop)+e)}function Tr(t){Nr(t);var e=t.getCursor();t.curOp.scrollToPos={from:e,to:e,margin:t.options.cursorScrollMargin}}function Or(t,e,n){null==e&&null==n||Nr(t),null!=e&&(t.curOp.scrollLeft=e),null!=n&&(t.curOp.scrollTop=n)}function Nr(t){var e=t.curOp.scrollToPos;e&&(t.curOp.scrollToPos=null,zr(t,Kn(t,e.from),Kn(t,e.to),e.margin))}function zr(t,e,n,r){var i=Sr(t,{left:Math.min(e.left,n.left),top:Math.min(e.top,n.top)-r,right:Math.max(e.right,n.right),bottom:Math.max(e.bottom,n.bottom)+r});Or(t,i.scrollLeft,i.scrollTop)}function jr(t,e){Math.abs(t.doc.scrollTop-e)<2||(n||ii(t,{top:e}),Ar(t,e,!0),n&&ii(t),Qr(t,100))}function Ar(t,e,n){e=Math.min(t.display.scroller.scrollHeight-t.display.scroller.clientHeight,e),(t.display.scroller.scrollTop!=e||n)&&(t.doc.scrollTop=e,t.display.scrollbars.setScrollTop(e),t.display.scroller.scrollTop!=e&&(t.display.scroller.scrollTop=e))}function Lr(t,e,n,r){e=Math.min(e,t.display.scroller.scrollWidth-t.display.scroller.clientWidth),(n?e==t.doc.scrollLeft:Math.abs(t.doc.scrollLeft-e)<2)&&!r||(t.doc.scrollLeft=e,si(t),t.display.scroller.scrollLeft!=e&&(t.display.scroller.scrollLeft=e),t.display.scrollbars.setScrollLeft(e))}function Mr(t){var e=t.display,n=e.gutters.offsetWidth,r=Math.round(t.doc.height+wn(t.display));return{clientHeight:e.scroller.clientHeight,viewHeight:e.wrapper.clientHeight,scrollWidth:e.scroller.scrollWidth,clientWidth:e.scroller.clientWidth,viewWidth:e.wrapper.clientWidth,barLeft:t.options.fixedGutter?n:0,docHeight:r,scrollHeight:r+Cn(t)+e.barHeight,nativeBarWidth:e.nativeBarWidth,gutterWidth:n}}var Pr=function(t,e,n){this.cm=n;var r=this.vert=O("div",[O("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),i=this.horiz=O("div",[O("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");r.tabIndex=i.tabIndex=-1,t(r),t(i),pt(r,"scroll",(function(){r.clientHeight&&e(r.scrollTop,"vertical")})),pt(i,"scroll",(function(){i.clientWidth&&e(i.scrollLeft,"horizontal")})),this.checkedZeroWidth=!1,a&&s<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Pr.prototype.update=function(t){var e=t.scrollWidth>t.clientWidth+1,n=t.scrollHeight>t.clientHeight+1,r=t.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=e?r+"px":"0";var i=t.viewHeight-(e?r:0);this.vert.firstChild.style.height=Math.max(0,t.scrollHeight-t.clientHeight+i)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(e){this.horiz.style.display="block",this.horiz.style.right=n?r+"px":"0",this.horiz.style.left=t.barLeft+"px";var o=t.viewWidth-t.barLeft-(n?r:0);this.horiz.firstChild.style.width=Math.max(0,t.scrollWidth-t.clientWidth+o)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&t.clientHeight>0&&(0==r&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?r:0,bottom:e?r:0}},Pr.prototype.setScrollLeft=function(t){this.horiz.scrollLeft!=t&&(this.horiz.scrollLeft=t),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Pr.prototype.setScrollTop=function(t){this.vert.scrollTop!=t&&(this.vert.scrollTop=t),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Pr.prototype.zeroWidthHack=function(){var t=v&&!h?"12px":"18px";this.horiz.style.height=this.vert.style.width=t,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new D,this.disableVert=new D},Pr.prototype.enableZeroWidthBar=function(t,e,n){t.style.pointerEvents="auto",e.set(1e3,(function r(){var i=t.getBoundingClientRect();("vert"==n?document.elementFromPoint(i.right-1,(i.top+i.bottom)/2):document.elementFromPoint((i.right+i.left)/2,i.bottom-1))!=t?t.style.pointerEvents="none":e.set(1e3,r)}))},Pr.prototype.clear=function(){var t=this.horiz.parentNode;t.removeChild(this.horiz),t.removeChild(this.vert)};var Ir=function(){};function Rr(t,e){e||(e=Mr(t));var n=t.display.barWidth,r=t.display.barHeight;Dr(t,e);for(var i=0;i<4&&n!=t.display.barWidth||r!=t.display.barHeight;i++)n!=t.display.barWidth&&t.options.lineWrapping&&wr(t),Dr(t,Mr(t)),n=t.display.barWidth,r=t.display.barHeight}function Dr(t,e){var n=t.display,r=n.scrollbars.update(e);n.sizer.style.paddingRight=(n.barWidth=r.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=r.bottom)+"px",n.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=r.bottom+"px",n.scrollbarFiller.style.width=r.right+"px"):n.scrollbarFiller.style.display="",r.bottom&&t.options.coverGutterNextToScrollbar&&t.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=r.bottom+"px",n.gutterFiller.style.width=e.gutterWidth+"px"):n.gutterFiller.style.display=""}Ir.prototype.update=function(){return{bottom:0,right:0}},Ir.prototype.setScrollLeft=function(){},Ir.prototype.setScrollTop=function(){},Ir.prototype.clear=function(){};var qr={native:Pr,null:Ir};function Fr(t){t.display.scrollbars&&(t.display.scrollbars.clear(),t.display.scrollbars.addClass&&S(t.display.wrapper,t.display.scrollbars.addClass)),t.display.scrollbars=new qr[t.options.scrollbarStyle]((function(e){t.display.wrapper.insertBefore(e,t.display.scrollbarFiller),pt(e,"mousedown",(function(){t.state.focused&&setTimeout((function(){return t.display.input.focus()}),0)})),e.setAttribute("cm-not-content","true")}),(function(e,n){"horizontal"==n?Lr(t,e):jr(t,e)}),t),t.display.scrollbars.addClass&&A(t.display.wrapper,t.display.scrollbars.addClass)}var Br=0;function Hr(t){var e;t.curOp={cm:t,viewChanged:!1,startHeight:t.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Br},e=t.curOp,on?on.ops.push(e):e.ownsGroup=on={ops:[e],delayedCallbacks:[]}}function Vr(t){var e=t.curOp;e&&function(t){var e=t.ownsGroup;if(e)try{!function(t){var e=t.delayedCallbacks,n=0;do{for(;n=n.viewTo)||n.maxLineChanged&&e.options.lineWrapping,t.update=t.mustUpdate&&new ei(e,t.mustUpdate&&{top:t.scrollTop,ensure:t.scrollToPos},t.forceUpdate)}function Wr(t){var e=t.cm,n=e.display;t.updatedDisplay&&wr(e),t.barMeasure=Mr(e),n.maxLineChanged&&!e.options.lineWrapping&&(t.adjustWidthTo=On(e,n.maxLine,n.maxLine.text.length).left+3,e.display.sizerWidth=t.adjustWidthTo,t.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+t.adjustWidthTo+Cn(e)+e.display.barWidth),t.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+t.adjustWidthTo-Sn(e))),(t.updatedDisplay||t.selectionChanged)&&(t.preparedSelection=n.input.prepareSelection())}function Kr(t){var e=t.cm;null!=t.adjustWidthTo&&(e.display.sizer.style.minWidth=t.adjustWidthTo+"px",t.maxScrollLeft1&&(a=!0)),null!=c.scrollLeft&&(Lr(t,c.scrollLeft),Math.abs(t.doc.scrollLeft-p)>1&&(a=!0)),!a)break}return i}(e,ae(r,t.scrollToPos.from),ae(r,t.scrollToPos.to),t.scrollToPos.margin);!function(t,e){if(!mt(t,"scrollCursorIntoView")){var n=t.display,r=n.sizer.getBoundingClientRect(),i=null;if(e.top+r.top<0?i=!0:e.bottom+r.top>(window.innerHeight||document.documentElement.clientHeight)&&(i=!1),null!=i&&!d){var o=O("div","​",null,"position: absolute;\n top: "+(e.top-n.viewOffset-$n(t.display))+"px;\n height: "+(e.bottom-e.top+Cn(t)+n.barHeight)+"px;\n left: "+e.left+"px; width: "+Math.max(2,e.right-e.left)+"px;");t.display.lineSpace.appendChild(o),o.scrollIntoView(i),t.display.lineSpace.removeChild(o)}}}(e,i)}var o=t.maybeHiddenMarkers,a=t.maybeUnhiddenMarkers;if(o)for(var s=0;s=t.display.viewTo)){var n=+new Date+t.options.workTime,r=fe(t,e.highlightFrontier),i=[];e.iter(r.line,Math.min(e.first+e.size,t.display.viewTo+500),(function(o){if(r.line>=t.display.viewFrom){var a=o.styles,s=o.text.length>t.options.maxHighlightLength?Ft(e.mode,r.state):null,l=ue(t,o,r,!0);s&&(r.state=s),o.styles=l.styles;var c=o.styleClasses,u=l.classes;u?o.styleClasses=u:c&&(o.styleClasses=null);for(var p=!a||a.length!=o.styles.length||c!=u&&(!c||!u||c.bgClass!=u.bgClass||c.textClass!=u.textClass),f=0;!p&&fn)return Qr(t,t.options.workDelay),!0})),e.highlightFrontier=r.line,e.modeFrontier=Math.max(e.modeFrontier,r.line),i.length&&Jr(t,(function(){for(var e=0;e=n.viewFrom&&e.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==fr(t))return!1;li(t)&&(ur(t),e.dims=nr(t));var i=r.first+r.size,o=Math.max(e.visible.from-t.options.viewportMargin,r.first),a=Math.min(i,e.visible.to+t.options.viewportMargin);n.viewFroma&&n.viewTo-a<20&&(a=Math.min(i,n.viewTo)),xe&&(o=Re(t.doc,o),a=De(t.doc,a));var s=o!=n.viewFrom||a!=n.viewTo||n.lastWrapHeight!=e.wrapperHeight||n.lastWrapWidth!=e.wrapperWidth;!function(t,e,n){var r=t.display;0==r.view.length||e>=r.viewTo||n<=r.viewFrom?(r.view=rn(t,e,n),r.viewFrom=e):(r.viewFrom>e?r.view=rn(t,e,r.viewFrom).concat(r.view):r.viewFromn&&(r.view=r.view.slice(0,sr(t,n)))),r.viewTo=n}(t,o,a),n.viewOffset=Be(Ut(t.doc,n.viewFrom)),t.display.mover.style.top=n.viewOffset+"px";var c=fr(t);if(!s&&0==c&&!e.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var u=function(t){if(t.hasFocus())return null;var e=j();if(!e||!z(t.display.lineDiv,e))return null;var n={activeElt:e};if(window.getSelection){var r=window.getSelection();r.anchorNode&&r.extend&&z(t.display.lineDiv,r.anchorNode)&&(n.anchorNode=r.anchorNode,n.anchorOffset=r.anchorOffset,n.focusNode=r.focusNode,n.focusOffset=r.focusOffset)}return n}(t);return c>4&&(n.lineDiv.style.display="none"),function(t,e,n){var r=t.display,i=t.options.lineNumbers,o=r.lineDiv,a=o.firstChild;function s(e){var n=e.nextSibling;return l&&v&&t.display.currentWheelTarget==e?e.style.display="none":e.parentNode.removeChild(e),n}for(var c=r.view,u=r.viewFrom,p=0;p-1&&(h=!1),cn(t,f,u,n)),h&&(E(f.lineNumber),f.lineNumber.appendChild(document.createTextNode(Zt(t.options,u)))),a=f.node.nextSibling}else{var d=gn(t,f,u,n);o.insertBefore(d,a)}u+=f.size}for(;a;)a=s(a)}(t,n.updateLineNumbers,e.dims),c>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,function(t){if(t&&t.activeElt&&t.activeElt!=j()&&(t.activeElt.focus(),t.anchorNode&&z(document.body,t.anchorNode)&&z(document.body,t.focusNode))){var e=window.getSelection(),n=document.createRange();n.setEnd(t.anchorNode,t.anchorOffset),n.collapse(!1),e.removeAllRanges(),e.addRange(n),e.extend(t.focusNode,t.focusOffset)}}(u),E(n.cursorDiv),E(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,s&&(n.lastWrapHeight=e.wrapperHeight,n.lastWrapWidth=e.wrapperWidth,Qr(t,400)),n.updateLineNumbers=null,!0}function ri(t,e){for(var n=e.viewport,r=!0;(r&&t.options.lineWrapping&&e.oldDisplayWidth!=Sn(t)||(n&&null!=n.top&&(n={top:Math.min(t.doc.height+wn(t.display)-En(t),n.top)}),e.visible=Cr(t.display,t.doc,n),!(e.visible.from>=t.display.viewFrom&&e.visible.to<=t.display.viewTo)))&&ni(t,e);r=!1){wr(t);var i=Mr(t);hr(t),Rr(t,i),ai(t,i),e.force=!1}e.signal(t,"update",t),t.display.viewFrom==t.display.reportedViewFrom&&t.display.viewTo==t.display.reportedViewTo||(e.signal(t,"viewportChange",t,t.display.viewFrom,t.display.viewTo),t.display.reportedViewFrom=t.display.viewFrom,t.display.reportedViewTo=t.display.viewTo)}function ii(t,e){var n=new ei(t,e);if(ni(t,n)){wr(t),ri(t,n);var r=Mr(t);hr(t),Rr(t,r),ai(t,r),n.finish()}}function oi(t){var e=t.gutters.offsetWidth;t.sizer.style.marginLeft=e+"px"}function ai(t,e){t.display.sizer.style.minHeight=e.docHeight+"px",t.display.heightForcer.style.top=e.docHeight+"px",t.display.gutters.style.height=e.docHeight+t.display.barHeight+Cn(t)+"px"}function si(t){var e=t.display,n=e.view;if(e.alignWidgets||e.gutters.firstChild&&t.options.fixedGutter){for(var r=rr(e)-e.scroller.scrollLeft+t.doc.scrollLeft,i=e.gutters.offsetWidth,o=r+"px",a=0;as.clientWidth,u=s.scrollHeight>s.clientHeight;if(i&&c||o&&u){if(o&&v&&l)t:for(var f=e.target,h=a.view;f!=s;f=f.parentNode)for(var d=0;d=0&&te(t,r.to())<=0)return n}return-1};var _i=function(t,e){this.anchor=t,this.head=e};function bi(t,e,n){var r=t&&t.options.selectionsMayTouch,i=e[n];e.sort((function(t,e){return te(t.from(),e.from())})),n=q(e,i);for(var o=1;o0:l>=0){var c=ie(s.from(),a.from()),u=re(s.to(),a.to()),p=s.empty()?a.from()==a.head:s.from()==s.head;o<=n&&--n,e.splice(--o,2,new _i(p?u:c,p?c:u))}}return new vi(e,n)}function xi(t,e){return new vi([new _i(t,e||t)],0)}function $i(t){return t.text?Qt(t.from.line+t.text.length-1,G(t.text).length+(1==t.text.length?t.from.ch:0)):t.to}function wi(t,e){if(te(t,e.from)<0)return t;if(te(t,e.to)<=0)return $i(e);var n=t.line+e.text.length-(e.to.line-e.from.line)-1,r=t.ch;return t.line==e.to.line&&(r+=$i(e).ch-e.to.ch),Qt(n,r)}function ki(t,e){for(var n=[],r=0;r1&&t.remove(s.line+1,d-1),t.insert(s.line+1,y)}sn(t,"change",t,e)}function Ni(t,e,n){!function t(r,i,o){if(r.linked)for(var a=0;as-(t.cm?t.cm.options.historyEventDelay:500)||"*"==e.origin.charAt(0)))&&(o=function(t,e){return e?(Mi(t.done),G(t.done)):t.done.length&&!G(t.done).ranges?G(t.done):t.done.length>1&&!t.done[t.done.length-2].ranges?(t.done.pop(),G(t.done)):void 0}(i,i.lastOp==r)))a=G(o.changes),0==te(e.from,e.to)&&0==te(e.from,a.to)?a.to=$i(e):o.changes.push(Li(t,e));else{var l=G(i.done);for(l&&l.ranges||Ii(t.sel,i.done),o={changes:[Li(t,e)],generation:i.generation},i.done.push(o);i.done.length>i.undoDepth;)i.done.shift(),i.done[0].ranges||i.done.shift()}i.done.push(n),i.generation=++i.maxGeneration,i.lastModTime=i.lastSelTime=s,i.lastOp=i.lastSelOp=r,i.lastOrigin=i.lastSelOrigin=e.origin,a||dt(t,"historyAdded")}function Ii(t,e){var n=G(e);n&&n.ranges&&n.equals(t)||e.push(t)}function Ri(t,e,n,r){var i=e["spans_"+t.id],o=0;t.iter(Math.max(t.first,n),Math.min(t.first+t.size,r),(function(n){n.markedSpans&&((i||(i=e["spans_"+t.id]={}))[o]=n.markedSpans),++o}))}function Di(t){if(!t)return null;for(var e,n=0;n-1&&(G(s)[p]=c[p],delete c[p])}}}return r}function Bi(t,e,n,r){if(r){var i=t.anchor;if(n){var o=te(e,i)<0;o!=te(n,i)<0?(i=e,e=n):o!=te(e,n)<0&&(e=n)}return new _i(i,e)}return new _i(n||e,e)}function Hi(t,e,n,r,i){null==i&&(i=t.cm&&(t.cm.display.shift||t.extend)),Gi(t,new vi([Bi(t.sel.primary(),e,n,i)],0),r)}function Vi(t,e,n){for(var r=[],i=t.cm&&(t.cm.display.shift||t.extend),o=0;o=e.ch:s.to>e.ch))){if(i&&(dt(l,"beforeCursorEnter"),l.explicitlyCleared)){if(o.markedSpans){--a;continue}break}if(!l.atomic)continue;if(n){var p=l.find(r<0?1:-1),f=void 0;if((r<0?u:c)&&(p=eo(t,p,-r,p&&p.line==e.line?o:null)),p&&p.line==e.line&&(f=te(p,n))&&(r<0?f<0:f>0))return Qi(t,p,e,r,i)}var h=l.find(r<0?-1:1);return(r<0?c:u)&&(h=eo(t,h,r,h.line==e.line?o:null)),h?Qi(t,h,e,r,i):null}}return e}function to(t,e,n,r,i){var o=r||1;return Qi(t,e,n,o,i)||!i&&Qi(t,e,n,o,!0)||Qi(t,e,n,-o,i)||!i&&Qi(t,e,n,-o,!0)||(t.cantEdit=!0,Qt(t.first,0))}function eo(t,e,n,r){return n<0&&0==e.ch?e.line>t.first?ae(t,Qt(e.line-1)):null:n>0&&e.ch==(r||Ut(t,e.line)).text.length?e.line0)){var u=[l,1],p=te(c.from,s.from),f=te(c.to,s.to);(p<0||!a.inclusiveLeft&&!p)&&u.push({from:c.from,to:s.from}),(f>0||!a.inclusiveRight&&!f)&&u.push({from:s.to,to:c.to}),i.splice.apply(i,u),l+=u.length-3}}return i}(t,e.from,e.to);if(r)for(var i=r.length-1;i>=0;--i)oo(t,{from:r[i].from,to:r[i].to,text:i?[""]:e.text,origin:e.origin});else oo(t,e)}}function oo(t,e){if(1!=e.text.length||""!=e.text[0]||0!=te(e.from,e.to)){var n=ki(t,e);Pi(t,e,n,t.cm?t.cm.curOp.id:NaN),lo(t,e,n,Ce(t,e));var r=[];Ni(t,(function(t,n){n||-1!=q(r,t.history)||(fo(t.history,e),r.push(t.history)),lo(t,e,null,Ce(t,e))}))}}function ao(t,e,n){var r=t.cm&&t.cm.state.suppressEdits;if(!r||n){for(var i,o=t.history,a=t.sel,s="undo"==e?o.done:o.undone,l="undo"==e?o.undone:o.done,c=0;c=0;--h){var d=f(h);if(d)return d.v}}}}function so(t,e){if(0!=e&&(t.first+=e,t.sel=new vi(J(t.sel.ranges,(function(t){return new _i(Qt(t.anchor.line+e,t.anchor.ch),Qt(t.head.line+e,t.head.ch))})),t.sel.primIndex),t.cm)){lr(t.cm,t.first,t.first-e,e);for(var n=t.cm.display,r=n.viewFrom;rt.lastLine())){if(e.from.lineo&&(e={from:e.from,to:Qt(o,Ut(t,o).text.length),text:[e.text[0]],origin:e.origin}),e.removed=Wt(t,e.from,e.to),n||(n=ki(t,e)),t.cm?function(t,e,n){var r=t.doc,i=t.display,o=e.from,a=e.to,s=!1,l=o.line;t.options.lineWrapping||(l=Jt(Ie(Ut(r,o.line))),r.iter(l,a.line+1,(function(t){if(t==i.maxLine)return s=!0,!0}))),r.sel.contains(e.from,e.to)>-1&>(t),Oi(r,e,n,ir(t)),t.options.lineWrapping||(r.iter(l,o.line+e.text.length,(function(t){var e=He(t);e>i.maxLineLength&&(i.maxLine=t,i.maxLineLength=e,i.maxLineChanged=!0,s=!1)})),s&&(t.curOp.updateMaxLine=!0)),function(t,e){if(t.modeFrontier=Math.min(t.modeFrontier,e),!(t.highlightFrontiern;r--){var i=Ut(t,r).stateAfter;if(i&&(!(i instanceof le)||r+i.lookAhead1||!(this.children[0]instanceof mo))){var s=[];this.collapse(s),this.children=[new mo(s)],this.children[0].parent=this}},collapse:function(t){for(var e=0;e50){for(var a=i.lines.length%25+25,s=a;s10);t.parent.maybeSpill()}},iterN:function(t,e,n){for(var r=0;r0||0==a&&!1!==o.clearWhenEmpty)return o;if(o.replacedWith&&(o.collapsed=!0,o.widgetNode=N("span",[o.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||o.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(o.widgetNode.insertLeft=!0)),o.collapsed){if(Pe(t,e.line,e,n,o)||e.line!=n.line&&Pe(t,n.line,e,n,o))throw new Error("Inserting collapsed marker partially overlapping an existing one");xe=!0}o.addToHistory&&Pi(t,{from:e,to:n,origin:"markText"},t.sel,NaN);var s,l=e.line,c=t.cm;if(t.iter(l,n.line+1,(function(t){c&&o.collapsed&&!c.options.lineWrapping&&Ie(t)==c.display.maxLine&&(s=!0),o.collapsed&&l!=e.line&&Gt(t,0),function(t,e){t.markedSpans=t.markedSpans?t.markedSpans.concat([e]):[e],e.marker.attachLine(t)}(t,new $e(o,l==e.line?e.ch:null,l==n.line?n.ch:null)),++l})),o.collapsed&&t.iter(e.line,n.line+1,(function(e){qe(t,e)&&Gt(e,0)})),o.clearOnEnter&&pt(o,"beforeCursorEnter",(function(){return o.clear()})),o.readOnly&&(be=!0,(t.history.done.length||t.history.undone.length)&&t.clearHistory()),o.collapsed&&(o.id=++_o,o.atomic=!0),c){if(s&&(c.curOp.updateMaxLine=!0),o.collapsed)lr(c,e.line,n.line+1);else if(o.className||o.startStyle||o.endStyle||o.css||o.attributes||o.title)for(var u=e.line;u<=n.line;u++)cr(c,u,"text");o.atomic&&Xi(c.doc),sn(c,"markerAdded",c,o)}return o}bo.prototype.clear=function(){if(!this.explicitlyCleared){var t=this.doc.cm,e=t&&!t.curOp;if(e&&Hr(t),yt(this,"clear")){var n=this.find();n&&sn(this,"clear",n.from,n.to)}for(var r=null,i=null,o=0;ot.display.maxLineLength&&(t.display.maxLine=c,t.display.maxLineLength=u,t.display.maxLineChanged=!0)}null!=r&&t&&this.collapsed&&lr(t,r,i+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,t&&Xi(t.doc)),t&&sn(t,"markerCleared",t,this,r,i),e&&Vr(t),this.parent&&this.parent.clear()}},bo.prototype.find=function(t,e){var n,r;null==t&&"bookmark"==this.type&&(t=1);for(var i=0;i=0;l--)io(this,r[l]);s?Ki(this,s):this.cm&&Tr(this.cm)})),undo:Zr((function(){ao(this,"undo")})),redo:Zr((function(){ao(this,"redo")})),undoSelection:Zr((function(){ao(this,"undo",!0)})),redoSelection:Zr((function(){ao(this,"redo",!0)})),setExtending:function(t){this.extend=t},getExtending:function(){return this.extend},historySize:function(){for(var t=this.history,e=0,n=0,r=0;r=t.ch)&&e.push(i.marker.parent||i.marker)}return e},findMarks:function(t,e,n){t=ae(this,t),e=ae(this,e);var r=[],i=t.line;return this.iter(t.line,e.line+1,(function(o){var a=o.markedSpans;if(a)for(var s=0;s=l.to||null==l.from&&i!=t.line||null!=l.from&&i==e.line&&l.from>=e.ch||n&&!n(l.marker)||r.push(l.marker.parent||l.marker)}++i})),r},getAllMarks:function(){var t=[];return this.iter((function(e){var n=e.markedSpans;if(n)for(var r=0;rt)return e=t,!0;t-=o,++n})),ae(this,Qt(n,e))},indexFromPos:function(t){var e=(t=ae(this,t)).ch;if(t.linee&&(e=t.from),null!=t.to&&t.to-1)return e.state.draggingText(t),void setTimeout((function(){return e.display.input.focus()}),20);try{var u=t.dataTransfer.getData("Text");if(u){var p;if(e.state.draggingText&&!e.state.draggingText.copy&&(p=e.listSelections()),Ji(e.doc,xi(n,n)),p)for(var f=0;f=0;e--)co(t.doc,"",r[e].from,r[e].to,"+delete");Tr(t)}))}function Wo(t,e,n){var r=it(t.text,e+n,n);return r<0||r>t.text.length?null:r}function Ko(t,e,n){var r=Wo(t,e.ch,n);return null==r?null:new Qt(e.line,r,n<0?"after":"before")}function Go(t,e,n,r,i){if(t){var o=ct(n,e.doc.direction);if(o){var a,s=i<0?G(o):o[0],l=i<0==(1==s.level)?"after":"before";if(s.level>0||"rtl"==e.doc.direction){var c=zn(e,n);a=i<0?n.text.length-1:0;var u=jn(e,c,a).top;a=ot((function(t){return jn(e,c,t).top==u}),i<0==(1==s.level)?s.from:s.to-1,a),"before"==l&&(a=Wo(n,a,1))}else a=i<0?s.to:s.from;return new Qt(r,a,l)}}return new Qt(r,i<0?n.text.length:0,i<0?"before":"after")}Io.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Io.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Io.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Io.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Io.default=v?Io.macDefault:Io.pcDefault;var Jo={selectAll:no,singleSelection:function(t){return t.setSelection(t.getCursor("anchor"),t.getCursor("head"),B)},killLine:function(t){return Uo(t,(function(e){if(e.empty()){var n=Ut(t.doc,e.head.line).text.length;return e.head.ch==n&&e.head.line0)i=new Qt(i.line,i.ch+1),t.replaceRange(o.charAt(i.ch-1)+o.charAt(i.ch-2),Qt(i.line,i.ch-2),i,"+transpose");else if(i.line>t.doc.first){var a=Ut(t.doc,i.line-1).text;a&&(i=new Qt(i.line,1),t.replaceRange(o.charAt(0)+t.doc.lineSeparator()+a.charAt(a.length-1),Qt(i.line-1,a.length-1),i,"+transpose"))}n.push(new _i(i,i))}t.setSelections(n)}))},newlineAndIndent:function(t){return Jr(t,(function(){for(var e=t.listSelections(),n=e.length-1;n>=0;n--)t.replaceRange(t.doc.lineSeparator(),e[n].anchor,e[n].head,"+input");e=t.listSelections();for(var r=0;r-1&&(te((i=c.ranges[i]).from(),e)<0||e.xRel>0)&&(te(i.to(),e)>0||e.xRel<0)?function(t,e,n,r){var i=t.display,o=!1,c=Yr(t,(function(e){l&&(i.scroller.draggable=!1),t.state.draggingText=!1,ht(i.wrapper.ownerDocument,"mouseup",c),ht(i.wrapper.ownerDocument,"mousemove",u),ht(i.scroller,"dragstart",p),ht(i.scroller,"drop",c),o||(_t(e),r.addNew||Hi(t.doc,n,null,null,r.extend),l||a&&9==s?setTimeout((function(){i.wrapper.ownerDocument.body.focus(),i.input.focus()}),20):i.input.focus())})),u=function(t){o=o||Math.abs(e.clientX-t.clientX)+Math.abs(e.clientY-t.clientY)>=10},p=function(){return o=!0};l&&(i.scroller.draggable=!0),t.state.draggingText=c,c.copy=!r.moveOnDrag,i.scroller.dragDrop&&i.scroller.dragDrop(),pt(i.wrapper.ownerDocument,"mouseup",c),pt(i.wrapper.ownerDocument,"mousemove",u),pt(i.scroller,"dragstart",p),pt(i.scroller,"drop",c),br(t),setTimeout((function(){return i.input.focus()}),20)}(t,r,e,o):function(t,e,n,r){var i=t.display,o=t.doc;_t(e);var a,s,l=o.sel,c=l.ranges;if(r.addNew&&!r.extend?(s=o.sel.contains(n),a=s>-1?c[s]:new _i(n,n)):(a=o.sel.primary(),s=o.sel.primIndex),"rectangle"==r.unit)r.addNew||(a=new _i(n,n)),n=ar(t,e,!0,!0),s=-1;else{var u=pa(t,n,r.unit);a=r.extend?Bi(a,u.anchor,u.head,r.extend):u}r.addNew?-1==s?(s=c.length,Gi(o,bi(t,c.concat([a]),s),{scroll:!1,origin:"*mouse"})):c.length>1&&c[s].empty()&&"char"==r.unit&&!r.extend?(Gi(o,bi(t,c.slice(0,s).concat(c.slice(s+1)),0),{scroll:!1,origin:"*mouse"}),l=o.sel):Ui(o,s,a,H):(s=0,Gi(o,new vi([a],0),H),l=o.sel);var p=n;function f(e){if(0!=te(p,e))if(p=e,"rectangle"==r.unit){for(var i=[],c=t.options.tabSize,u=R(Ut(o,n.line).text,n.ch,c),f=R(Ut(o,e.line).text,e.ch,c),h=Math.min(u,f),d=Math.max(u,f),m=Math.min(n.line,e.line),g=Math.min(t.lastLine(),Math.max(n.line,e.line));m<=g;m++){var y=Ut(o,m).text,v=U(y,h,c);h==d?i.push(new _i(Qt(m,v),Qt(m,v))):y.length>v&&i.push(new _i(Qt(m,v),Qt(m,U(y,d,c))))}i.length||i.push(new _i(n,n)),Gi(o,bi(t,l.ranges.slice(0,s).concat(i),s),{origin:"*mouse",scroll:!1}),t.scrollIntoView(e)}else{var _,b=a,x=pa(t,e,r.unit),$=b.anchor;te(x.anchor,$)>0?(_=x.head,$=ie(b.from(),x.anchor)):(_=x.anchor,$=re(b.to(),x.head));var w=l.ranges.slice(0);w[s]=function(t,e){var n=e.anchor,r=e.head,i=Ut(t.doc,n.line);if(0==te(n,r)&&n.sticky==r.sticky)return e;var o=ct(i);if(!o)return e;var a=st(o,n.ch,n.sticky),s=o[a];if(s.from!=n.ch&&s.to!=n.ch)return e;var l,c=a+(s.from==n.ch==(1!=s.level)?0:1);if(0==c||c==o.length)return e;if(r.line!=n.line)l=(r.line-n.line)*("ltr"==t.doc.direction?1:-1)>0;else{var u=st(o,r.ch,r.sticky),p=u-a||(r.ch-n.ch)*(1==s.level?-1:1);l=u==c-1||u==c?p<0:p>0}var f=o[c+(l?-1:0)],h=l==(1==f.level),d=h?f.from:f.to,m=h?"after":"before";return n.ch==d&&n.sticky==m?e:new _i(new Qt(n.line,d,m),r)}(t,new _i(ae(o,$),_)),Gi(o,bi(t,w,s),H)}}var h=i.wrapper.getBoundingClientRect(),d=0;function m(e){t.state.selectingText=!1,d=1/0,e&&(_t(e),i.input.focus()),ht(i.wrapper.ownerDocument,"mousemove",g),ht(i.wrapper.ownerDocument,"mouseup",y),o.history.lastSelOrigin=null}var g=Yr(t,(function(e){0!==e.buttons&&kt(e)?function e(n){var a=++d,s=ar(t,n,!0,"rectangle"==r.unit);if(s)if(0!=te(s,p)){t.curOp.focus=j(),f(s);var l=Cr(i,o);(s.line>=l.to||s.lineh.bottom?20:0;c&&setTimeout(Yr(t,(function(){d==a&&(i.scroller.scrollTop+=c,e(n))})),50)}}(e):m(e)})),y=Yr(t,m);t.state.selectingText=y,pt(i.wrapper.ownerDocument,"mousemove",g),pt(i.wrapper.ownerDocument,"mouseup",y)}(t,r,e,o)}(e,r,o,t):wt(t)==n.scroller&&_t(t):2==i?(r&&Hi(e.doc,r),setTimeout((function(){return n.input.focus()}),20)):3==i&&(w?e.display.input.onContextMenu(t):br(e)))}}function pa(t,e,n){if("char"==n)return new _i(e,e);if("word"==n)return t.findWordAt(e);if("line"==n)return new _i(Qt(e.line,0),ae(t.doc,Qt(e.line+1,0)));var r=n(t,e);return new _i(r.from,r.to)}function fa(t,e,n,r){var i,o;if(e.touches)i=e.touches[0].clientX,o=e.touches[0].clientY;else try{i=e.clientX,o=e.clientY}catch(e){return!1}if(i>=Math.floor(t.display.gutters.getBoundingClientRect().right))return!1;r&&_t(e);var a=t.display,s=a.lineDiv.getBoundingClientRect();if(o>s.bottom||!yt(t,n))return xt(e);o-=s.top-a.viewOffset;for(var l=0;l=i)return dt(t,n,t,Yt(t.doc,o),t.display.gutterSpecs[l].className,e),xt(e)}}function ha(t,e){return fa(t,e,"gutterClick",!0)}function da(t){t.display.wrapper.className=t.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+t.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Dn(t)}ca.prototype.compare=function(t,e,n){return this.time+400>t&&0==te(e,this.pos)&&n==this.button};var ma={toString:function(){return"CodeMirror.Init"}},ga={},ya={};function va(t,e,n){if(!e!=!(n&&n!=ma)){var r=t.display.dragFunctions,i=e?pt:ht;i(t.display.scroller,"dragstart",r.start),i(t.display.scroller,"dragenter",r.enter),i(t.display.scroller,"dragover",r.over),i(t.display.scroller,"dragleave",r.leave),i(t.display.scroller,"drop",r.drop)}}function _a(t){t.options.lineWrapping?(A(t.display.wrapper,"CodeMirror-wrap"),t.display.sizer.style.minWidth="",t.display.sizerWidth=null):(S(t.display.wrapper,"CodeMirror-wrap"),Ve(t)),or(t),lr(t),Dn(t),setTimeout((function(){return Rr(t)}),100)}function ba(t,e){var n=this;if(!(this instanceof ba))return new ba(t,e);this.options=e=e?I(e):{},I(ga,e,!1);var r=e.value;"string"==typeof r?r=new So(r,e.mode,null,e.lineSeparator,e.direction):e.mode&&(r.modeOption=e.mode),this.doc=r;var i=new ba.inputStyles[e.inputStyle](this),o=this.display=new fi(t,r,i,e);for(var c in o.wrapper.CodeMirror=this,da(this),e.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Fr(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new D,keySeq:null,specialChars:null},e.autofocus&&!y&&o.input.focus(),a&&s<11&&setTimeout((function(){return n.display.input.reset(!0)}),20),function(t){var e=t.display;pt(e.scroller,"mousedown",Yr(t,ua)),pt(e.scroller,"dblclick",a&&s<11?Yr(t,(function(e){if(!mt(t,e)){var n=ar(t,e);if(n&&!ha(t,e)&&!xn(t.display,e)){_t(e);var r=t.findWordAt(n);Hi(t.doc,r.anchor,r.head)}}})):function(e){return mt(t,e)||_t(e)}),pt(e.scroller,"contextmenu",(function(e){return function(t,e){xn(t.display,e)||function(t,e){return!!yt(t,"gutterContextMenu")&&fa(t,e,"gutterContextMenu",!1)}(t,e)||mt(t,e,"contextmenu")||w||t.display.input.onContextMenu(e)}(t,e)}));var n,r={end:0};function i(){e.activeTouch&&(n=setTimeout((function(){return e.activeTouch=null}),1e3),(r=e.activeTouch).end=+new Date)}function o(t,e){if(null==e.left)return!0;var n=e.left-t.left,r=e.top-t.top;return n*n+r*r>400}pt(e.scroller,"touchstart",(function(i){if(!mt(t,i)&&!function(t){if(1!=t.touches.length)return!1;var e=t.touches[0];return e.radiusX<=1&&e.radiusY<=1}(i)&&!ha(t,i)){e.input.ensurePolled(),clearTimeout(n);var o=+new Date;e.activeTouch={start:o,moved:!1,prev:o-r.end<=300?r:null},1==i.touches.length&&(e.activeTouch.left=i.touches[0].pageX,e.activeTouch.top=i.touches[0].pageY)}})),pt(e.scroller,"touchmove",(function(){e.activeTouch&&(e.activeTouch.moved=!0)})),pt(e.scroller,"touchend",(function(n){var r=e.activeTouch;if(r&&!xn(e,n)&&null!=r.left&&!r.moved&&new Date-r.start<300){var a,s=t.coordsChar(e.activeTouch,"page");a=!r.prev||o(r,r.prev)?new _i(s,s):!r.prev.prev||o(r,r.prev.prev)?t.findWordAt(s):new _i(Qt(s.line,0),ae(t.doc,Qt(s.line+1,0))),t.setSelection(a.anchor,a.head),t.focus(),_t(n)}i()})),pt(e.scroller,"touchcancel",i),pt(e.scroller,"scroll",(function(){e.scroller.clientHeight&&(jr(t,e.scroller.scrollTop),Lr(t,e.scroller.scrollLeft,!0),dt(t,"scroll",t))})),pt(e.scroller,"mousewheel",(function(e){return yi(t,e)})),pt(e.scroller,"DOMMouseScroll",(function(e){return yi(t,e)})),pt(e.wrapper,"scroll",(function(){return e.wrapper.scrollTop=e.wrapper.scrollLeft=0})),e.dragFunctions={enter:function(e){mt(t,e)||$t(e)},over:function(e){mt(t,e)||(function(t,e){var n=ar(t,e);if(n){var r=document.createDocumentFragment();mr(t,n,r),t.display.dragCursor||(t.display.dragCursor=O("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),t.display.lineSpace.insertBefore(t.display.dragCursor,t.display.cursorDiv)),T(t.display.dragCursor,r)}}(t,e),$t(e))},start:function(e){return function(t,e){if(a&&(!t.state.draggingText||+new Date-Eo<100))$t(e);else if(!mt(t,e)&&!xn(t.display,e)&&(e.dataTransfer.setData("Text",t.getSelection()),e.dataTransfer.effectAllowed="copyMove",e.dataTransfer.setDragImage&&!f)){var n=O("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",p&&(n.width=n.height=1,t.display.wrapper.appendChild(n),n._top=n.offsetTop),e.dataTransfer.setDragImage(n,0,0),p&&n.parentNode.removeChild(n)}}(t,e)},drop:Yr(t,To),leave:function(e){mt(t,e)||Oo(t)}};var l=e.input.getField();pt(l,"keyup",(function(e){return oa.call(t,e)})),pt(l,"keydown",Yr(t,ia)),pt(l,"keypress",Yr(t,aa)),pt(l,"focus",(function(e){return xr(t,e)})),pt(l,"blur",(function(e){return $r(t,e)}))}(this),function(){var t;zo||(pt(window,"resize",(function(){null==t&&(t=setTimeout((function(){t=null,No(jo)}),100))})),pt(window,"blur",(function(){return No($r)})),zo=!0)}(),Hr(this),this.curOp.forceUpdate=!0,zi(this,r),e.autofocus&&!y||this.hasFocus()?setTimeout(P(xr,this),20):$r(this),ya)ya.hasOwnProperty(c)&&ya[c](n,e[c],ma);li(this),e.finishInit&&e.finishInit(this);for(var u=0;u150)){if(!r)return;n="prev"}}else c=0,n="not";"prev"==n?c=e>o.first?R(Ut(o,e-1).text,null,a):0:"add"==n?c=l+t.options.indentUnit:"subtract"==n?c=l-t.options.indentUnit:"number"==typeof n&&(c=l+n),c=Math.max(0,c);var p="",f=0;if(t.options.indentWithTabs)for(var h=Math.floor(c/a);h;--h)f+=a,p+="\t";if(fa,l=zt(e),c=null;if(s&&r.ranges.length>1)if(wa&&wa.text.join("\n")==e){if(r.ranges.length%wa.text.length==0){c=[];for(var u=0;u=0;f--){var h=r.ranges[f],d=h.from(),m=h.to();h.empty()&&(n&&n>0?d=Qt(d.line,d.ch-n):t.state.overwrite&&!s?m=Qt(m.line,Math.min(Ut(o,m.line).text.length,m.ch+G(l).length)):s&&wa&&wa.lineWise&&wa.text.join("\n")==e&&(d=m=Qt(d.line,0)));var g={from:d,to:m,text:c?c[f%c.length]:l,origin:i||(s?"paste":t.state.cutIncoming>a?"cut":"+input")};io(t.doc,g),sn(t,"inputRead",t,g)}e&&!s&&Ea(t,e),Tr(t),t.curOp.updateInput<2&&(t.curOp.updateInput=p),t.curOp.typing=!0,t.state.pasteIncoming=t.state.cutIncoming=-1}function Sa(t,e){var n=t.clipboardData&&t.clipboardData.getData("Text");if(n)return t.preventDefault(),e.isReadOnly()||e.options.disableInput||Jr(e,(function(){return Ca(e,n,0,null,"paste")})),!0}function Ea(t,e){if(t.options.electricChars&&t.options.smartIndent)for(var n=t.doc.sel,r=n.ranges.length-1;r>=0;r--){var i=n.ranges[r];if(!(i.head.ch>100||r&&n.ranges[r-1].head.line==i.head.line)){var o=t.getModeAt(i.head),a=!1;if(o.electricChars){for(var s=0;s-1){a=$a(t,i.head.line,"smart");break}}else o.electricInput&&o.electricInput.test(Ut(t.doc,i.head.line).text.slice(0,i.head.ch))&&(a=$a(t,i.head.line,"smart"));a&&sn(t,"electricInput",t,i.head.line)}}}function Ta(t){for(var e=[],n=[],r=0;r=e.text.length?(n.ch=e.text.length,n.sticky="before"):n.ch<=0&&(n.ch=0,n.sticky="after");var o=st(i,n.ch,n.sticky),a=i[o];if("ltr"==t.doc.direction&&a.level%2==0&&(r>0?a.to>n.ch:a.from=a.from&&f>=u.begin)){var h=p?"before":"after";return new Qt(n.line,f,h)}}var d=function(t,e,r){for(var o=function(t,e){return e?new Qt(n.line,l(t,1),"before"):new Qt(n.line,t,"after")};t>=0&&t0==(1!=a.level),c=s?r.begin:l(r.end,-1);if(a.from<=c&&c0?u.end:l(u.begin,-1);return null==g||r>0&&g==e.text.length||!(m=d(r>0?0:i.length-1,r,c(g)))?null:m}(t.cm,s,e,n):Ko(s,e,n))){if(r||(a=e.line+n)=t.first+t.size||(e=new Qt(a,e.ch,e.sticky),!(s=Ut(t,a))))return!1;e=Go(i,t.cm,s,e.line,n)}else e=o;return!0}if("char"==r)l();else if("column"==r)l(!0);else if("word"==r||"group"==r)for(var c=null,u="group"==r,p=t.cm&&t.cm.getHelper(e,"wordChars"),f=!0;!(n<0)||l(!f);f=!1){var h=s.text.charAt(e.ch)||"\n",d=tt(h,p)?"w":u&&"\n"==h?"n":!u||/\s/.test(h)?null:"p";if(!u||f||d||(d="s"),c&&c!=d){n<0&&(n=1,l(),e.sticky="after");break}if(d&&(c=d),n>0&&!l(!f))break}var m=to(t,e,o,a,!0);return ee(o,m)&&(m.hitSide=!0),m}function ja(t,e,n,r){var i,o,a=t.doc,s=e.left;if("page"==r){var l=Math.min(t.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),c=Math.max(l-.5*tr(t.display),3);i=(n>0?e.bottom:e.top)+n*c}else"line"==r&&(i=n>0?e.bottom+3:e.top-3);for(;(o=Jn(t,s,i)).outside;){if(n<0?i<=0:i>=a.height){o.hitSide=!0;break}i+=5*n}return o}var Aa=function(t){this.cm=t,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new D,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function La(t,e){var n=Nn(t,e.line);if(!n||n.hidden)return null;var r=Ut(t.doc,e.line),i=Tn(n,r,e.line),o=ct(r,t.doc.direction),a="left";o&&(a=st(o,e.ch)%2?"right":"left");var s=Mn(i.map,e.ch,a);return s.offset="right"==s.collapse?s.end:s.start,s}function Ma(t,e){return e&&(t.bad=!0),t}function Pa(t,e,n){var r;if(e==t.display.lineDiv){if(!(r=t.display.lineDiv.childNodes[n]))return Ma(t.clipPos(Qt(t.display.viewTo-1)),!0);e=null,n=0}else for(r=e;;r=r.parentNode){if(!r||r==t.display.lineDiv)return null;if(r.parentNode&&r.parentNode==t.display.lineDiv)break}for(var i=0;i=e.display.viewTo||o.line=e.display.viewFrom&&La(e,i)||{node:l[0].measure.map[2],offset:0},u=o.liner.firstLine()&&(a=Qt(a.line-1,Ut(r.doc,a.line-1).length)),s.ch==Ut(r.doc,s.line).text.length&&s.linei.viewTo-1)return!1;a.line==i.viewFrom||0==(t=sr(r,a.line))?(e=Jt(i.view[0].line),n=i.view[0].node):(e=Jt(i.view[t].line),n=i.view[t-1].node.nextSibling);var l,c,u=sr(r,s.line);if(u==i.view.length-1?(l=i.viewTo-1,c=i.lineDiv.lastChild):(l=Jt(i.view[u+1].line)-1,c=i.view[u+1].node.previousSibling),!n)return!1;for(var p=r.doc.splitLines(function(t,e,n,r,i){var o="",a=!1,s=t.doc.lineSeparator(),l=!1;function c(){a&&(o+=s,l&&(o+=s),a=l=!1)}function u(t){t&&(c(),o+=t)}function p(e){if(1==e.nodeType){var n=e.getAttribute("cm-text");if(n)return void u(n);var o,f=e.getAttribute("cm-marker");if(f){var h=t.findMarks(Qt(r,0),Qt(i+1,0),(g=+f,function(t){return t.id==g}));return void(h.length&&(o=h[0].find(0))&&u(Wt(t.doc,o.from,o.to).join(s)))}if("false"==e.getAttribute("contenteditable"))return;var d=/^(pre|div|p|li|table|br)$/i.test(e.nodeName);if(!/^br$/i.test(e.nodeName)&&0==e.textContent.length)return;d&&c();for(var m=0;m1&&f.length>1;)if(G(p)==G(f))p.pop(),f.pop(),l--;else{if(p[0]!=f[0])break;p.shift(),f.shift(),e++}for(var h=0,d=0,m=p[0],g=f[0],y=Math.min(m.length,g.length);ha.ch&&v.charCodeAt(v.length-d-1)==_.charCodeAt(_.length-d-1);)h--,d++;p[p.length-1]=v.slice(0,v.length-d).replace(/^\u200b+/,""),p[0]=p[0].slice(h).replace(/\u200b+$/,"");var x=Qt(e,h),$=Qt(l,f.length?G(f).length-d:0);return p.length>1||p[0]||te(x,$)?(co(r.doc,p,x,$,"+input"),!0):void 0},Aa.prototype.ensurePolled=function(){this.forceCompositionEnd()},Aa.prototype.reset=function(){this.forceCompositionEnd()},Aa.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Aa.prototype.readFromDOMSoon=function(){var t=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout((function(){if(t.readDOMTimeout=null,t.composing){if(!t.composing.done)return;t.composing=null}t.updateFromDOM()}),80))},Aa.prototype.updateFromDOM=function(){var t=this;!this.cm.isReadOnly()&&this.pollContent()||Jr(this.cm,(function(){return lr(t.cm)}))},Aa.prototype.setUneditable=function(t){t.contentEditable="false"},Aa.prototype.onKeyPress=function(t){0==t.charCode||this.composing||(t.preventDefault(),this.cm.isReadOnly()||Yr(this.cm,Ca)(this.cm,String.fromCharCode(null==t.charCode?t.keyCode:t.charCode),0))},Aa.prototype.readOnlyChanged=function(t){this.div.contentEditable=String("nocursor"!=t)},Aa.prototype.onContextMenu=function(){},Aa.prototype.resetPosition=function(){},Aa.prototype.needsContentAttribute=!0;var Ra=function(t){this.cm=t,this.prevInput="",this.pollingFast=!1,this.polling=new D,this.hasSelection=!1,this.composing=null};Ra.prototype.init=function(t){var e=this,n=this,r=this.cm;this.createField(t);var i=this.textarea;function o(t){if(!mt(r,t)){if(r.somethingSelected())ka({lineWise:!1,text:r.getSelections()});else{if(!r.options.lineWiseCopyCut)return;var e=Ta(r);ka({lineWise:!0,text:e.text}),"cut"==t.type?r.setSelections(e.ranges,null,B):(n.prevInput="",i.value=e.text.join("\n"),M(i))}"cut"==t.type&&(r.state.cutIncoming=+new Date)}}t.wrapper.insertBefore(this.wrapper,t.wrapper.firstChild),m&&(i.style.width="0px"),pt(i,"input",(function(){a&&s>=9&&e.hasSelection&&(e.hasSelection=null),n.poll()})),pt(i,"paste",(function(t){mt(r,t)||Sa(t,r)||(r.state.pasteIncoming=+new Date,n.fastPoll())})),pt(i,"cut",o),pt(i,"copy",o),pt(t.scroller,"paste",(function(e){if(!xn(t,e)&&!mt(r,e)){if(!i.dispatchEvent)return r.state.pasteIncoming=+new Date,void n.focus();var o=new Event("paste");o.clipboardData=e.clipboardData,i.dispatchEvent(o)}})),pt(t.lineSpace,"selectstart",(function(e){xn(t,e)||_t(e)})),pt(i,"compositionstart",(function(){var t=r.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:t,range:r.markText(t,r.getCursor("to"),{className:"CodeMirror-composing"})}})),pt(i,"compositionend",(function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)}))},Ra.prototype.createField=function(t){this.wrapper=Na(),this.textarea=this.wrapper.firstChild},Ra.prototype.prepareSelection=function(){var t=this.cm,e=t.display,n=t.doc,r=dr(t);if(t.options.moveInputWithCursor){var i=Wn(t,n.sel.primary().head,"div"),o=e.wrapper.getBoundingClientRect(),a=e.lineDiv.getBoundingClientRect();r.teTop=Math.max(0,Math.min(e.wrapper.clientHeight-10,i.top+a.top-o.top)),r.teLeft=Math.max(0,Math.min(e.wrapper.clientWidth-10,i.left+a.left-o.left))}return r},Ra.prototype.showSelection=function(t){var e=this.cm.display;T(e.cursorDiv,t.cursors),T(e.selectionDiv,t.selection),null!=t.teTop&&(this.wrapper.style.top=t.teTop+"px",this.wrapper.style.left=t.teLeft+"px")},Ra.prototype.reset=function(t){if(!this.contextMenuPending&&!this.composing){var e=this.cm;if(e.somethingSelected()){this.prevInput="";var n=e.getSelection();this.textarea.value=n,e.state.focused&&M(this.textarea),a&&s>=9&&(this.hasSelection=n)}else t||(this.prevInput=this.textarea.value="",a&&s>=9&&(this.hasSelection=null))}},Ra.prototype.getField=function(){return this.textarea},Ra.prototype.supportsTouch=function(){return!1},Ra.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!y||j()!=this.textarea))try{this.textarea.focus()}catch(t){}},Ra.prototype.blur=function(){this.textarea.blur()},Ra.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ra.prototype.receivedFocus=function(){this.slowPoll()},Ra.prototype.slowPoll=function(){var t=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,(function(){t.poll(),t.cm.state.focused&&t.slowPoll()}))},Ra.prototype.fastPoll=function(){var t=!1,e=this;e.pollingFast=!0,e.polling.set(20,(function n(){e.poll()||t?(e.pollingFast=!1,e.slowPoll()):(t=!0,e.polling.set(60,n))}))},Ra.prototype.poll=function(){var t=this,e=this.cm,n=this.textarea,r=this.prevInput;if(this.contextMenuPending||!e.state.focused||jt(n)&&!r&&!this.composing||e.isReadOnly()||e.options.disableInput||e.state.keySeq)return!1;var i=n.value;if(i==r&&!e.somethingSelected())return!1;if(a&&s>=9&&this.hasSelection===i||v&&/[\uf700-\uf7ff]/.test(i))return e.display.input.reset(),!1;if(e.doc.sel==e.display.selForContextMenu){var o=i.charCodeAt(0);if(8203!=o||r||(r="​"),8666==o)return this.reset(),this.cm.execCommand("undo")}for(var l=0,c=Math.min(r.length,i.length);l1e3||i.indexOf("\n")>-1?n.value=t.prevInput="":t.prevInput=i,t.composing&&(t.composing.range.clear(),t.composing.range=e.markText(t.composing.start,e.getCursor("to"),{className:"CodeMirror-composing"}))})),!0},Ra.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ra.prototype.onKeyPress=function(){a&&s>=9&&(this.hasSelection=null),this.fastPoll()},Ra.prototype.onContextMenu=function(t){var e=this,n=e.cm,r=n.display,i=e.textarea;e.contextMenuPending&&e.contextMenuPending();var o=ar(n,t),c=r.scroller.scrollTop;if(o&&!p){n.options.resetSelectionOnContextMenu&&-1==n.doc.sel.contains(o)&&Yr(n,Gi)(n.doc,xi(o),B);var u,f=i.style.cssText,h=e.wrapper.style.cssText,d=e.wrapper.offsetParent.getBoundingClientRect();if(e.wrapper.style.cssText="position: static",i.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(t.clientY-d.top-5)+"px; left: "+(t.clientX-d.left-5)+"px;\n z-index: 1000; background: "+(a?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",l&&(u=window.scrollY),r.input.focus(),l&&window.scrollTo(null,u),r.input.reset(),n.somethingSelected()||(i.value=e.prevInput=" "),e.contextMenuPending=y,r.selForContextMenu=n.doc.sel,clearTimeout(r.detectingSelectAll),a&&s>=9&&g(),w){$t(t);var m=function(){ht(window,"mouseup",m),setTimeout(y,20)};pt(window,"mouseup",m)}else setTimeout(y,50)}function g(){if(null!=i.selectionStart){var t=n.somethingSelected(),o="​"+(t?i.value:"");i.value="⇚",i.value=o,e.prevInput=t?"":"​",i.selectionStart=1,i.selectionEnd=o.length,r.selForContextMenu=n.doc.sel}}function y(){if(e.contextMenuPending==y&&(e.contextMenuPending=!1,e.wrapper.style.cssText=h,i.style.cssText=f,a&&s<9&&r.scrollbars.setScrollTop(r.scroller.scrollTop=c),null!=i.selectionStart)){(!a||a&&s<9)&&g();var t=0,o=function(){r.selForContextMenu==n.doc.sel&&0==i.selectionStart&&i.selectionEnd>0&&"​"==e.prevInput?Yr(n,no)(n):t++<10?r.detectingSelectAll=setTimeout(o,500):(r.selForContextMenu=null,r.input.reset())};r.detectingSelectAll=setTimeout(o,200)}}},Ra.prototype.readOnlyChanged=function(t){t||this.reset(),this.textarea.disabled="nocursor"==t},Ra.prototype.setUneditable=function(){},Ra.prototype.needsContentAttribute=!1,function(t){var e=t.optionHandlers;function n(n,r,i,o){t.defaults[n]=r,i&&(e[n]=o?function(t,e,n){n!=ma&&i(t,e,n)}:i)}t.defineOption=n,t.Init=ma,n("value","",(function(t,e){return t.setValue(e)}),!0),n("mode",null,(function(t,e){t.doc.modeOption=e,Si(t)}),!0),n("indentUnit",2,Si,!0),n("indentWithTabs",!1),n("smartIndent",!0),n("tabSize",4,(function(t){Ei(t),Dn(t),lr(t)}),!0),n("lineSeparator",null,(function(t,e){if(t.doc.lineSep=e,e){var n=[],r=t.doc.first;t.doc.iter((function(t){for(var i=0;;){var o=t.text.indexOf(e,i);if(-1==o)break;i=o+e.length,n.push(Qt(r,o))}r++}));for(var i=n.length-1;i>=0;i--)co(t.doc,e,n[i],Qt(n[i].line,n[i].ch+e.length))}})),n("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,(function(t,e,n){t.state.specialChars=new RegExp(e.source+(e.test("\t")?"":"|\t"),"g"),n!=ma&&t.refresh()})),n("specialCharPlaceholder",Xe,(function(t){return t.refresh()}),!0),n("electricChars",!0),n("inputStyle",y?"contenteditable":"textarea",(function(){throw new Error("inputStyle can not (yet) be changed in a running editor")}),!0),n("spellcheck",!1,(function(t,e){return t.getInputField().spellcheck=e}),!0),n("autocorrect",!1,(function(t,e){return t.getInputField().autocorrect=e}),!0),n("autocapitalize",!1,(function(t,e){return t.getInputField().autocapitalize=e}),!0),n("rtlMoveVisually",!b),n("wholeLineUpdateBefore",!0),n("theme","default",(function(t){da(t),pi(t)}),!0),n("keyMap","default",(function(t,e,n){var r=Vo(e),i=n!=ma&&Vo(n);i&&i.detach&&i.detach(t,r),r.attach&&r.attach(t,i||null)})),n("extraKeys",null),n("configureMouse",null),n("lineWrapping",!1,_a,!0),n("gutters",[],(function(t,e){t.display.gutterSpecs=ci(e,t.options.lineNumbers),pi(t)}),!0),n("fixedGutter",!0,(function(t,e){t.display.gutters.style.left=e?rr(t.display)+"px":"0",t.refresh()}),!0),n("coverGutterNextToScrollbar",!1,(function(t){return Rr(t)}),!0),n("scrollbarStyle","native",(function(t){Fr(t),Rr(t),t.display.scrollbars.setScrollTop(t.doc.scrollTop),t.display.scrollbars.setScrollLeft(t.doc.scrollLeft)}),!0),n("lineNumbers",!1,(function(t,e){t.display.gutterSpecs=ci(t.options.gutters,e),pi(t)}),!0),n("firstLineNumber",1,pi,!0),n("lineNumberFormatter",(function(t){return t}),pi,!0),n("showCursorWhenSelecting",!1,hr,!0),n("resetSelectionOnContextMenu",!0),n("lineWiseCopyCut",!0),n("pasteLinesPerSelection",!0),n("selectionsMayTouch",!1),n("readOnly",!1,(function(t,e){"nocursor"==e&&($r(t),t.display.input.blur()),t.display.input.readOnlyChanged(e)})),n("disableInput",!1,(function(t,e){e||t.display.input.reset()}),!0),n("dragDrop",!0,va),n("allowDropFileTypes",null),n("cursorBlinkRate",530),n("cursorScrollMargin",0),n("cursorHeight",1,hr,!0),n("singleCursorHeightPerLine",!0,hr,!0),n("workTime",100),n("workDelay",100),n("flattenSpans",!0,Ei,!0),n("addModeClass",!1,Ei,!0),n("pollInterval",100),n("undoDepth",200,(function(t,e){return t.doc.history.undoDepth=e})),n("historyEventDelay",1250),n("viewportMargin",10,(function(t){return t.refresh()}),!0),n("maxHighlightLength",1e4,Ei,!0),n("moveInputWithCursor",!0,(function(t,e){e||t.display.input.resetPosition()})),n("tabindex",null,(function(t,e){return t.display.input.getField().tabIndex=e||""})),n("autofocus",null),n("direction","ltr",(function(t,e){return t.doc.setDirection(e)}),!0),n("phrases",null)}(ba),function(t){var e=t.optionHandlers,n=t.helpers={};t.prototype={constructor:t,focus:function(){window.focus(),this.display.input.focus()},setOption:function(t,n){var r=this.options,i=r[t];r[t]==n&&"mode"!=t||(r[t]=n,e.hasOwnProperty(t)&&Yr(this,e[t])(this,n,i),dt(this,"optionChange",this,t))},getOption:function(t){return this.options[t]},getDoc:function(){return this.doc},addKeyMap:function(t,e){this.state.keyMaps[e?"push":"unshift"](Vo(t))},removeKeyMap:function(t){for(var e=this.state.keyMaps,n=0;nn&&($a(this,i.head.line,t,!0),n=i.head.line,r==this.doc.sel.primIndex&&Tr(this));else{var o=i.from(),a=i.to(),s=Math.max(n,o.line);n=Math.min(this.lastLine(),a.line-(a.ch?0:1))+1;for(var l=s;l0&&Ui(this.doc,r,new _i(o,c[r].to()),B)}}})),getTokenAt:function(t,e){return ye(this,t,e)},getLineTokens:function(t,e){return ye(this,Qt(t),e,!0)},getTokenTypeAt:function(t){t=ae(this.doc,t);var e,n=pe(this,Ut(this.doc,t.line)),r=0,i=(n.length-1)/2,o=t.ch;if(0==o)e=n[2];else for(;;){var a=r+i>>1;if((a?n[2*a-1]:0)>=o)i=a;else{if(!(n[2*a+1]o&&(t=o,i=!0),r=Ut(this.doc,t)}else r=t;return Hn(this,r,{top:0,left:0},e||"page",n||i).top+(i?this.doc.height-Be(r):0)},defaultTextHeight:function(){return tr(this.display)},defaultCharWidth:function(){return er(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(t,e,n,r,i){var o,a=this.display,s=(t=Wn(this,ae(this.doc,t))).bottom,l=t.left;if(e.style.position="absolute",e.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(e),a.sizer.appendChild(e),"over"==r)s=t.top;else if("above"==r||"near"==r){var c=Math.max(a.wrapper.clientHeight,this.doc.height),u=Math.max(a.sizer.clientWidth,a.lineSpace.clientWidth);("above"==r||t.bottom+e.offsetHeight>c)&&t.top>e.offsetHeight?s=t.top-e.offsetHeight:t.bottom+e.offsetHeight<=c&&(s=t.bottom),l+e.offsetWidth>u&&(l=u-e.offsetWidth)}e.style.top=s+"px",e.style.left=e.style.right="","right"==i?(l=a.sizer.clientWidth-e.offsetWidth,e.style.right="0px"):("left"==i?l=0:"middle"==i&&(l=(a.sizer.clientWidth-e.offsetWidth)/2),e.style.left=l+"px"),n&&(null!=(o=Sr(this,{left:l,top:s,right:l+e.offsetWidth,bottom:s+e.offsetHeight})).scrollTop&&jr(this,o.scrollTop),null!=o.scrollLeft&&Lr(this,o.scrollLeft))},triggerOnKeyDown:Xr(ia),triggerOnKeyPress:Xr(aa),triggerOnKeyUp:oa,triggerOnMouseDown:Xr(ua),execCommand:function(t){if(Jo.hasOwnProperty(t))return Jo[t].call(null,this)},triggerElectric:Xr((function(t){Ea(this,t)})),findPosH:function(t,e,n,r){var i=1;e<0&&(i=-1,e=-e);for(var o=ae(this.doc,t),a=0;a0&&a(e.charAt(n-1));)--n;for(;r.5)&&or(this),dt(this,"refresh",this)})),swapDoc:Xr((function(t){var e=this.doc;return e.cm=null,this.state.selectingText&&this.state.selectingText(),zi(this,t),Dn(this),this.display.input.reset(),Or(this,t.scrollLeft,t.scrollTop),this.curOp.forceScroll=!0,sn(this,"swapDoc",this,e),e})),phrase:function(t){var e=this.options.phrases;return e&&Object.prototype.hasOwnProperty.call(e,t)?e[t]:t},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},vt(t),t.registerHelper=function(e,r,i){n.hasOwnProperty(e)||(n[e]=t[e]={_global:[]}),n[e][r]=i},t.registerGlobalHelper=function(e,r,i,o){t.registerHelper(e,r,o),n[e]._global.push({pred:i,val:o})}}(ba);var Da="iter insert remove copy getEditor constructor".split(" ");for(var qa in So.prototype)So.prototype.hasOwnProperty(qa)&&q(Da,qa)<0&&(ba.prototype[qa]=function(t){return function(){return t.apply(this.doc,arguments)}}(So.prototype[qa]));return vt(So),ba.inputStyles={textarea:Ra,contenteditable:Aa},ba.defineMode=function(t){ba.defaults.mode||"null"==t||(ba.defaults.mode=t),function(t,e){arguments.length>2&&(e.dependencies=Array.prototype.slice.call(arguments,2)),Mt[t]=e}.apply(this,arguments)},ba.defineMIME=function(t,e){Pt[t]=e},ba.defineMode("null",(function(){return{token:function(t){return t.skipToEnd()}}})),ba.defineMIME("text/plain","null"),ba.defineExtension=function(t,e){ba.prototype[t]=e},ba.defineDocExtension=function(t,e){So.prototype[t]=e},ba.fromTextArea=function(t,e){if((e=e?I(e):{}).value=t.value,!e.tabindex&&t.tabIndex&&(e.tabindex=t.tabIndex),!e.placeholder&&t.placeholder&&(e.placeholder=t.placeholder),null==e.autofocus){var n=j();e.autofocus=n==t||null!=t.getAttribute("autofocus")&&n==document.body}function r(){t.value=s.getValue()}var i;if(t.form&&(pt(t.form,"submit",r),!e.leaveSubmitMethodAlone)){var o=t.form;i=o.submit;try{var a=o.submit=function(){r(),o.submit=i,o.submit(),o.submit=a}}catch(t){}}e.finishInit=function(n){n.save=r,n.getTextArea=function(){return t},n.toTextArea=function(){n.toTextArea=isNaN,r(),t.parentNode.removeChild(n.getWrapperElement()),t.style.display="",t.form&&(ht(t.form,"submit",r),e.leaveSubmitMethodAlone||"function"!=typeof t.form.submit||(t.form.submit=i))}},t.style.display="none";var s=ba((function(e){return t.parentNode.insertBefore(e,t.nextSibling)}),e);return s},function(t){t.off=ht,t.on=pt,t.wheelEventPixels=gi,t.Doc=So,t.splitLines=zt,t.countColumn=R,t.findColumn=U,t.isWordChar=Q,t.Pass=F,t.signal=dt,t.Line=Ue,t.changeEnd=$i,t.scrollbarModel=qr,t.Pos=Qt,t.cmpPos=te,t.modes=Mt,t.mimeModes=Pt,t.resolveMode=It,t.getMode=Rt,t.modeExtensions=Dt,t.extendMode=qt,t.copyState=Ft,t.startState=Ht,t.innerMode=Bt,t.commands=Jo,t.keyMap=Io,t.keyName=Ho,t.isModifierKey=Fo,t.lookupKey=qo,t.normalizeKeyMap=Do,t.StringStream=Vt,t.SharedTextMarker=$o,t.TextMarker=bo,t.LineWidget=yo,t.e_preventDefault=_t,t.e_stopPropagation=bt,t.e_stop=$t,t.addClass=A,t.contains=z,t.rmClass=S,t.keyNames=Ao}(ba),ba.version="5.49.0",ba}()},function(t,e){var n=t.exports={version:"2.6.9"};"number"==typeof __e&&(__e=n)},function(t,e,n){var r=n(3),i=n(1),o=n(28),a=n(22),s=n(16),l=function(t,e,n){var c,u,p,f=t&l.F,h=t&l.G,d=t&l.S,m=t&l.P,g=t&l.B,y=t&l.W,v=h?i:i[e]||(i[e]={}),_=v.prototype,b=h?r:d?r[e]:(r[e]||{}).prototype;for(c in h&&(n=e),n)(u=!f&&b&&void 0!==b[c])&&s(v,c)||(p=u?b[c]:n[c],v[c]=h&&"function"!=typeof b[c]?n[c]:g&&u?o(p,r):y&&b[c]==p?function(t){var e=function(e,n,r){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,n)}return new t(e,n,r)}return t.apply(this,arguments)};return e.prototype=t.prototype,e}(p):m&&"function"==typeof p?o(Function.call,p):p,m&&((v.virtual||(v.virtual={}))[c]=p,t&l.R&&_&&!_[c]&&a(_,c,p)))};l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,t.exports=l},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e,n){var r=n(70)("wks"),i=n(50),o=n(3).Symbol,a="function"==typeof o;(t.exports=function(t){return r[t]||(r[t]=a&&o[t]||(a?o:i)("Symbol."+t))}).store=r},function(t,e){t.exports=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}},function(t,e,n){var r=n(118);function i(t,e){for(var n=0;n=0?r=setTimeout(l,e-c):(r=null,n||(s=t.apply(o,i),o=i=null))}null==e&&(e=100);var c=function(){o=this,i=arguments,a=Date.now();var c=n&&!r;return r||(r=setTimeout(l,e)),c&&(s=t.apply(o,i),o=i=null),s};return c.clear=function(){r&&(clearTimeout(r),r=null)},c.flush=function(){r&&(s=t.apply(o,i),o=i=null,clearTimeout(r),r=null)},c}n.debounce=n,t.exports=n},function(t,e,n){var r=n(49);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,i){return t.call(e,n,r,i)}}return function(){return t.apply(e,arguments)}}},function(t,e,n){var r=n(112),i=n(76);t.exports=Object.keys||function(t){return r(t,i)}},function(t,e,n){var r=n(52);t.exports=function(t){return Object(r(t))}},function(t,e,n){var r=n(54),i=Math.min;t.exports=function(t){return t>0?i(r(t),9007199254740991):0}},function(t,e){t.exports=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t}},function(t,e,n){"use strict";var r=n(93),i=n(18),o=n(191),a=n(81),s=n(31),l=n(82),c=n(87),u=n(13),p=Math.min,f=[].push,h=!u((function(){RegExp(4294967295,"y")}));n(86)("split",2,(function(t,e,n,u){var d;return d="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,e){var i=String(this);if(void 0===t&&0===e)return[];if(!r(t))return n.call(i,t,e);for(var o,a,s,l=[],u=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),p=0,h=void 0===e?4294967295:e>>>0,d=new RegExp(t.source,u+"g");(o=c.call(d,i))&&!((a=d.lastIndex)>p&&(l.push(i.slice(p,o.index)),o.length>1&&o.index=h));)d.lastIndex===o.index&&d.lastIndex++;return p===i.length?!s&&d.test("")||l.push(""):l.push(i.slice(p)),l.length>h?l.slice(0,h):l}:"0".split(void 0,0).length?function(t,e){return void 0===t&&0===e?[]:n.call(this,t,e)}:n,[function(n,r){var i=t(this),o=null==n?void 0:n[e];return void 0!==o?o.call(n,i,r):d.call(String(i),n,r)},function(t,e){var r=u(d,t,this,e,d!==n);if(r.done)return r.value;var c=i(t),f=String(this),m=o(c,RegExp),g=c.unicode,y=(c.ignoreCase?"i":"")+(c.multiline?"m":"")+(c.unicode?"u":"")+(h?"y":"g"),v=new m(h?c:"^(?:"+c.source+")",y),_=void 0===e?4294967295:e>>>0;if(0===_)return[];if(0===f.length)return null===l(v,f)?[f]:[];for(var b=0,x=0,$=[];x=e.length?{value:void 0,done:!0}:(t=r(e,n),this._i+=t.length,{value:t,done:!1})}))},function(t,e,n){!function(e){function n(){this.parent=null,this.nested=[],this.nodes=[],this.filters=null,this.directives=null,this.context=null,this.unbind=null,this.onRender=null,this.onUpdate=null,this.onRemove=null,this.noCache=!1}function r(){this.items=Object.create(null),this.length=0,this.next=0}function i(t,e,n,r){if(r){var i={__index__:n};return i[r.value]=t[n],r.key&&(i[r.key]=n),i}return t[n]}function o(t,e,n,r){if(r){var i={__index__:n};return i[r.value]=t[e[n]],r.key&&(i[r.key]=e[n]),i}return t[e[n]]}n.render=function(t,e,n){var r;return r=n&&n.noCache?new t:t.pool.pop()||new t,8==e.nodeType?r.insertBefore(e):r.appendTo(e),n&&(n.parent&&(r.parent=n.parent),n.context&&(r.context=n.context),n.filters&&(r.filters=n.filters),n.directives&&(r.directives=n.directives),n.noCache&&(r.noCache=n.noCache)),r.onRender&&r.onRender(),r},n.prerender=function(t,e){for(;e--;)t.pool.push(new t)},n.loop=function(t,e,r,a,s,l){var c,u,p,f,h,d,m=r.length;for(c in Array.isArray(s)?(h=i,d=s.length):(h=o,d=(f=Object.keys(s)).length),p=m-d,r.items){if(!(p-- >0))break;r.items[c].remove()}for(c in u=0,r.items)r.items[c].__state__=h(s,f,u,l),u++;for(u=m,p=d;u0?r:n)(t)}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e,n){"use strict";var r=n(18);t.exports=function(){var t=r(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},function(t,e,n){var r=n(45),i=n(122);t.exports=n(12)?function(t,e,n){return r.f(t,e,i(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e,n){n(197);for(var r=n(3),i=n(22),o=n(34),a=n(4)("toStringTag"),s="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),l=0;l=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(a[n]=t[n])}return a}},function(t,e,n){var r=n(117),i=n(108),o=n(37),a=n(172);t.exports=function(t){for(var e=1;e0?i(r(t),9007199254740991):0}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(70)("keys"),i=n(50);t.exports=function(t){return r[t]||(r[t]=i(t))}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e,n){var r=n(7),i=n(165),o=n(76),a=n(75)("IE_PROTO"),s=function(){},l=function(){var t,e=n(68)("iframe"),r=o.length;for(e.style.display="none",n(115).appendChild(e),e.src="javascript:",(t=e.contentWindow.document).open(),t.write("