@whyour/qinglong 0.3.2 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README-en.md +47 -88
- package/README.md +48 -87
- package/package.json +5 -1
- package/sample/notify.js +19 -9
- package/sample/notify.py +89 -47
- package/shell/api.sh +15 -15
- package/shell/otask.sh +1 -1
- package/shell/update.sh +12 -13
- package/static/build/api/system.js +1 -2
- package/static/build/api/user.js +5 -1
- package/static/build/config/serverEnv.js +1 -1
- package/static/build/data/dependence.js +1 -1
- package/static/build/data/notify.js +2 -0
- package/static/build/data/open.js +1 -8
- package/static/build/loaders/express.js +1 -9
- package/static/build/loaders/initFile.js +24 -6
- package/static/build/loaders/sentry.js +7 -1
- package/static/build/schedule/addCron.js +2 -2
- package/static/build/schedule/health.js +2 -2
- package/static/build/services/cron.js +50 -44
- package/static/build/services/dependence.js +82 -79
- package/static/build/services/env.js +1 -1
- package/static/build/services/notify.js +5 -5
- package/static/build/services/open.js +1 -1
- package/static/build/services/schedule.js +42 -40
- package/static/build/services/subscription.js +7 -13
- package/static/build/services/system.js +2 -2
- package/static/build/shared/pLimit.js +16 -0
- package/static/build/shared/runCron.js +29 -0
- package/static/dist/{1571.a97c18af.async.js → 1571.68121491.async.js} +3 -3
- package/static/dist/{9371.27629d57.async.js → 1654.e06fbac5.async.js} +1 -1
- package/static/dist/2260.d9fbd460.async.js +1 -0
- package/static/dist/2536.a60b8e3c.async.js +1 -0
- package/static/dist/{2618.2d258f44.async.js → 2618.1484edc2.async.js} +2 -2
- package/static/dist/2715.80e099e1.async.js +1 -0
- package/static/dist/{3490.8aaeafbb.async.js → 3490.8d2d9399.async.js} +1 -1
- package/static/dist/3639.58c3a3f1.async.js +5 -0
- package/static/dist/3800.5488ae14.async.js +2 -0
- package/static/dist/3820.faa46a6a.async.js +1 -0
- package/static/dist/4124.8cba8410.async.js +1 -0
- package/static/dist/4163.a1d279c3.async.js +1 -0
- package/static/dist/4346.5ab6fdc1.async.js +1 -0
- package/static/dist/{4378.70f18b85.async.js → 4378.70083a42.async.js} +2 -2
- package/static/dist/4491.96ee9a9f.async.js +4 -0
- package/static/dist/4804.183d71af.async.js +27 -0
- package/static/dist/4925.eca85085.async.js +1 -0
- package/static/dist/5008.c612bbdb.async.js +11 -0
- package/static/dist/5035.2489750b.async.js +67 -0
- package/static/dist/5310.6c4eff46.async.js +1 -0
- package/static/dist/5484.826c5ee3.async.js +1 -0
- package/static/dist/5969.87aeb075.async.js +1 -0
- package/static/dist/6304.51c52839.async.js +1 -0
- package/static/dist/6433.69941426.async.js +22 -0
- package/static/dist/6661.5cda5ce0.async.js +1 -0
- package/static/dist/6805.798ec30a.async.js +1 -0
- package/static/dist/{412.7e4d2d42.async.js → 7382.305c10b2.async.js} +2 -2
- package/static/dist/{7393.b7603b10.async.js → 7393.d9ed4b3a.async.js} +1 -1
- package/static/dist/7567.a224d0a6.async.js +5 -0
- package/static/dist/{7742.eec663d7.async.js → 7742.dd8a0112.async.js} +2 -2
- package/static/dist/8037.386b415d.async.js +1 -0
- package/static/dist/8297.e6ac1ce9.async.js +1 -0
- package/static/dist/8432.5bbc2cdd.async.js +1 -0
- package/static/dist/858.d51fc4e2.async.js +1 -0
- package/static/dist/8612.84caf0a5.async.js +1 -0
- package/static/dist/{8966.d92806db.async.js → 8657.805a96f7.async.js} +2 -2
- package/static/dist/8844.8525fd2e.async.js +81 -0
- package/static/dist/9065.6684b5d0.async.js +1 -0
- package/static/dist/921.198cefa6.async.js +6 -0
- package/static/dist/{9504.06cb7ea5.async.js → 9504.6d4e29e7.async.js} +1 -1
- package/static/dist/9673.18a70227.async.js +3 -0
- package/static/dist/986.ab6a48a4.async.js +1 -0
- package/static/dist/index.html +1 -1
- package/static/dist/layouts__index.285d8505.chunk.css +1 -0
- package/static/dist/layouts__index.3db43e0b.async.js +1 -0
- package/static/dist/src__pages__404.8794c158.async.js +1 -0
- package/static/dist/{src__pages__config__index.b5bde963.async.js → src__pages__config__index.7fb61af5.async.js} +3 -3
- package/static/dist/{src__pages__crontab__index.be4295e5.async.js → src__pages__crontab__index.5cfa7d5b.async.js} +2 -2
- package/static/dist/src__pages__crontab__logModal.44ad577c.async.js +2 -0
- package/static/dist/src__pages__crontab__modal.6d17fdcf.async.js +5 -0
- package/static/dist/src__pages__crontab__viewCreateModal.3db14204.async.js +4 -0
- package/static/dist/src__pages__crontab__viewManageModal.9f899650.async.js +4 -0
- package/static/dist/src__pages__dependence__index.3b140a79.async.js +2 -0
- package/static/dist/src__pages__dependence__logModal.e49658d5.async.js +4 -0
- package/static/dist/src__pages__dependence__modal.94ff002a.async.js +5 -0
- package/static/dist/{src__pages__diff__index.200be0dc.async.js → src__pages__diff__index.240e4991.async.js} +3 -3
- package/static/dist/{src__pages__env__editNameModal.9898b16a.async.js → src__pages__env__editNameModal.047bb3ba.async.js} +2 -2
- package/static/dist/src__pages__env__index.48602d18.async.js +2 -0
- package/static/dist/src__pages__env__modal.8b48ffa4.async.js +5 -0
- package/static/dist/src__pages__error__index.c0477141.async.js +4 -0
- package/static/dist/{src__pages__initialization__index.bcf87634.chunk.css → src__pages__initialization__index.66819338.chunk.css} +1 -1
- package/static/dist/src__pages__initialization__index.978a7f09.async.js +21 -0
- package/static/dist/src__pages__log__index.ae245070.async.js +1 -0
- package/static/dist/src__pages__login__index.8eb4df8e.async.js +2 -0
- package/static/dist/{src__pages__script__editModal.9a8934a1.async.js → src__pages__script__editModal.02b12902.async.js} +2 -2
- package/static/dist/{src__pages__script__editNameModal.42003a2f.async.js → src__pages__script__editNameModal.2773cb7b.async.js} +2 -2
- package/static/dist/{src__pages__script__index.670d9577.async.js → src__pages__script__index.679510cd.async.js} +3 -3
- package/static/dist/{src__pages__script__renameModal.3b9285b0.async.js → src__pages__script__renameModal.ea3b6689.async.js} +2 -2
- package/static/dist/{src__pages__script__saveModal.475c369d.async.js → src__pages__script__saveModal.312a0beb.async.js} +2 -2
- package/static/dist/{src__pages__script__setting.d41d33ae.async.js → src__pages__script__setting.11abc6ae.async.js} +2 -2
- package/static/dist/src__pages__setting__about.1460b7fa.async.js +1 -0
- package/static/dist/{src__pages__setting__appModal.4edca962.async.js → src__pages__setting__appModal.74267529.async.js} +2 -2
- package/static/dist/src__pages__setting__checkUpdate.ce2e30bb.async.js +4 -0
- package/static/dist/src__pages__setting__index.9fcd6dc2.async.js +2 -0
- package/static/dist/src__pages__setting__loginLog.0708083b.async.js +18 -0
- package/static/dist/src__pages__setting__notification.15a286d0.async.js +21 -0
- package/static/dist/src__pages__setting__other.00a69cf4.async.js +1 -0
- package/static/dist/src__pages__setting__security.62b6b562.async.js +4 -0
- package/static/dist/src__pages__subscription__index.708b6c8f.async.js +2 -0
- package/static/dist/src__pages__subscription__logModal.3a1a8e58.async.js +2 -0
- package/static/dist/src__pages__subscription__modal.c034f25a.async.js +4 -0
- package/static/dist/umi.cb44a99a.js +11 -0
- package/version.yaml +10 -5
- package/static/dist/1655.37556417.async.js +0 -4
- package/static/dist/1766.e0c12c07.async.js +0 -27
- package/static/dist/2260.04ae2823.async.js +0 -1
- package/static/dist/2715.30714799.async.js +0 -1
- package/static/dist/3639.62e1ddf6.async.js +0 -5
- package/static/dist/3820.ad340d47.async.js +0 -1
- package/static/dist/4011.3a02258a.async.js +0 -22
- package/static/dist/4124.6a5a1531.async.js +0 -1
- package/static/dist/4163.5180a456.async.js +0 -1
- package/static/dist/4180.e830b6e6.async.js +0 -2
- package/static/dist/4925.4425d963.async.js +0 -1
- package/static/dist/5008.8fcc2d24.async.js +0 -11
- package/static/dist/5310.9c3e0c09.async.js +0 -1
- package/static/dist/5319.dd84246e.async.js +0 -1
- package/static/dist/5484.ac83d6b4.async.js +0 -1
- package/static/dist/5544.6baaab99.async.js +0 -81
- package/static/dist/6304.613145ef.async.js +0 -1
- package/static/dist/6661.f5843bf4.async.js +0 -1
- package/static/dist/6794.4c503d6d.async.js +0 -5
- package/static/dist/6805.f5be6007.async.js +0 -1
- package/static/dist/7461.ed40fa5f.async.js +0 -1
- package/static/dist/7466.15597d4f.async.js +0 -1
- package/static/dist/7938.4e3377e7.async.js +0 -67
- package/static/dist/8037.61d0095e.async.js +0 -1
- package/static/dist/8297.3d6c376d.async.js +0 -1
- package/static/dist/8352.e0fbb494.async.js +0 -1
- package/static/dist/8432.30267db1.async.js +0 -1
- package/static/dist/8447.d0f63993.async.js +0 -1
- package/static/dist/9065.0806f3e5.async.js +0 -1
- package/static/dist/9280.aacaa172.async.js +0 -6
- package/static/dist/9673.a1545ea3.async.js +0 -3
- package/static/dist/986.c108246f.async.js +0 -1
- package/static/dist/layouts__index.3de47467.chunk.css +0 -1
- package/static/dist/layouts__index.a6451a2c.async.js +0 -1
- package/static/dist/src__pages__404.b5140a4b.async.js +0 -1
- package/static/dist/src__pages__crontab__logModal.0f6a4945.async.js +0 -2
- package/static/dist/src__pages__crontab__modal.cb176c70.async.js +0 -5
- package/static/dist/src__pages__crontab__viewCreateModal.f2b8a69a.async.js +0 -4
- package/static/dist/src__pages__crontab__viewManageModal.b86bbb79.async.js +0 -4
- package/static/dist/src__pages__dependence__index.c17201d7.async.js +0 -2
- package/static/dist/src__pages__dependence__logModal.42c56e18.async.js +0 -4
- package/static/dist/src__pages__dependence__modal.58620a62.async.js +0 -5
- package/static/dist/src__pages__env__index.c79218f4.async.js +0 -2
- package/static/dist/src__pages__env__modal.07f411f1.async.js +0 -5
- package/static/dist/src__pages__error__index.2f9d7c50.async.js +0 -4
- package/static/dist/src__pages__initialization__index.af82f7e1.async.js +0 -21
- package/static/dist/src__pages__log__index.5e63a6b7.async.js +0 -1
- package/static/dist/src__pages__login__index.44d624a7.async.js +0 -2
- package/static/dist/src__pages__setting__about.7ca2707b.async.js +0 -1
- package/static/dist/src__pages__setting__checkUpdate.dd497877.async.js +0 -4
- package/static/dist/src__pages__setting__index.4a85066e.async.js +0 -2
- package/static/dist/src__pages__setting__loginLog.c8ddd712.async.js +0 -18
- package/static/dist/src__pages__setting__notification.e124b7ae.async.js +0 -21
- package/static/dist/src__pages__setting__other.a58b5fae.async.js +0 -1
- package/static/dist/src__pages__setting__security.aabc2d21.async.js +0 -4
- package/static/dist/src__pages__subscription__index.04531731.async.js +0 -2
- package/static/dist/src__pages__subscription__logModal.b86a5c9b.async.js +0 -2
- package/static/dist/src__pages__subscription__modal.ea198f81.async.js +0 -4
- package/static/dist/umi.29bfaff2.js +0 -11
- /package/static/dist/{8352.d2d0a2c7.chunk.css → 8612.d2d0a2c7.chunk.css} +0 -0
- /package/static/dist/{7394.59dcf306.chunk.css → 9439.59dcf306.chunk.css} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_whyour_qinglong=self.webpackChunk_whyour_qinglong||[]).push([[2715],{43209:function(a,l,e){"use strict";e.d(l,{Z:function(){return ze}});var t=e(15343),r=e(87807),o=e(18790),s=e(60795),c=e(14797),n=e(63313),h=e.n(n),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M300 276.5a56 56 0 1056-97 56 56 0 00-56 97zm0 284a56 56 0 1056-97 56 56 0 00-56 97zM640 228a56 56 0 10112 0 56 56 0 00-112 0zm0 284a56 56 0 10112 0 56 56 0 00-112 0zM300 844.5a56 56 0 1056-97 56 56 0 00-56 97zM640 796a56 56 0 10112 0 56 56 0 00-112 0z"}}]},name:"holder",theme:"outlined"},m=v,C=e(46420),M=function(f,u){return n.createElement(C.Z,(0,c.Z)((0,c.Z)({},f),{},{ref:u,icon:m}))};M.displayName="HolderOutlined";var W=n.forwardRef(M),Z=e(84875),$=e.n(Z),oe=e(82259),ye=e(16082),se=4;function ge(i){var f,u=i.dropPosition,p=i.dropLevelOffset,x=i.prefixCls,y=i.indent,d=i.direction,b=d===void 0?"ltr":d,g=b==="ltr"?"left":"right",D=b==="ltr"?"right":"left",E=(f={},(0,r.Z)(f,g,-p*y+se),(0,r.Z)(f,D,0),f);switch(u){case-1:E.top=-3;break;case 1:E.bottom=-3;break;default:E.bottom=-3,E[g]=y+se;break}return h().createElement("div",{style:E,className:"".concat(x,"-drop-indicator")})}var me=e(96062),Ce=n.forwardRef(function(i,f){var u,p=n.useContext(oe.E_),x=p.getPrefixCls,y=p.direction,d=p.virtual,b=i.prefixCls,g=i.className,D=i.showIcon,E=D===void 0?!1:D,F=i.showLine,te=i.switcherIcon,A=i.blockNode,R=A===void 0?!1:A,L=i.children,T=i.checkable,I=T===void 0?!1:T,k=i.selectable,j=k===void 0?!0:k,P=i.draggable,G=i.motion,ne=G===void 0?(0,s.Z)((0,s.Z)({},ye.ZP),{motionAppear:!1}):G,w=x("tree",b),ae=(0,s.Z)((0,s.Z)({},i),{checkable:I,selectable:j,showIcon:E,motion:ne,blockNode:R,showLine:!!F,dropIndicatorRender:ge}),V=n.useMemo(function(){if(!P)return!1;var S={};switch((0,o.Z)(P)){case"function":S.nodeDraggable=P;break;case"object":S=(0,s.Z)({},P);break;default:break}return S.icon!==!1&&(S.icon=S.icon||n.createElement(W,null)),S},[P]);return n.createElement(t.Z,(0,s.Z)({itemHeight:20,ref:f,virtual:d},ae,{prefixCls:w,className:$()((u={},(0,r.Z)(u,"".concat(w,"-icon-hide"),!E),(0,r.Z)(u,"".concat(w,"-block-node"),R),(0,r.Z)(u,"".concat(w,"-unselectable"),!j),(0,r.Z)(u,"".concat(w,"-rtl"),y==="rtl"),u),g),direction:y,checkable:I&&n.createElement("span",{className:"".concat(w,"-checkbox-inner")}),selectable:j,switcherIcon:function(U){return(0,me.Z)(w,te,F,U)},draggable:V}),L)}),ie=Ce,X=e(14402),ce=e(17079),Oe=e(25265),be={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 444H820V330.4c0-17.7-14.3-32-32-32H473L355.7 186.2a8.15 8.15 0 00-5.5-2.2H96c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h698c13 0 24.8-7.9 29.7-20l134-332c1.5-3.8 2.3-7.9 2.3-12 0-17.7-14.3-32-32-32zM136 256h188.5l119.6 114.4H748V444H238c-13 0-24.8 7.9-29.7 20L136 643.2V256zm635.3 512H159l103.3-256h612.4L771.3 768z"}}]},name:"folder-open",theme:"outlined"},Ee=be,le=function(f,u){return n.createElement(C.Z,(0,c.Z)((0,c.Z)({},f),{},{ref:u,icon:Ee}))};le.displayName="FolderOpenOutlined";var Ke=n.forwardRef(le),_e={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M880 298.4H521L403.7 186.2a8.15 8.15 0 00-5.5-2.2H144c-17.7 0-32 14.3-32 32v592c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V330.4c0-17.7-14.3-32-32-32zM840 768H184V256h188.5l119.6 114.4H840V768z"}}]},name:"folder",theme:"outlined"},we=_e,de=function(f,u){return n.createElement(C.Z,(0,c.Z)((0,c.Z)({},f),{},{ref:u,icon:we}))};de.displayName="FolderOutlined";var Se=n.forwardRef(de),Ne=e(62857),ue=e(54419),_;(function(i){i[i.None=0]="None",i[i.Start=1]="Start",i[i.End=2]="End"})(_||(_={}));function Y(i,f){function u(p){var x=p.key,y=p.children;f(x,p)!==!1&&Y(y||[],f)}i.forEach(u)}function Pe(i){var f=i.treeData,u=i.expandedKeys,p=i.startKey,x=i.endKey,y=[],d=_.None;if(p&&p===x)return[p];if(!p||!x)return[];function b(g){return g===p||g===x}return Y(f,function(g){if(d===_.End)return!1;if(b(g)){if(y.push(g),d===_.None)d=_.Start;else if(d===_.Start)return d=_.End,!1}else d===_.Start&&y.push(g);return u.includes(g)}),y}function q(i,f){var u=(0,X.Z)(f),p=[];return Y(i,function(x,y){var d=u.indexOf(x);return d!==-1&&(p.push(y),u.splice(d,1)),!!u.length}),p}var fe=function(i,f){var u={};for(var p in i)Object.prototype.hasOwnProperty.call(i,p)&&f.indexOf(p)<0&&(u[p]=i[p]);if(i!=null&&typeof Object.getOwnPropertySymbols=="function")for(var x=0,p=Object.getOwnPropertySymbols(i);x<p.length;x++)f.indexOf(p[x])<0&&Object.prototype.propertyIsEnumerable.call(i,p[x])&&(u[p[x]]=i[p[x]]);return u};function He(i){var f=i.isLeaf,u=i.expanded;return f?n.createElement(Oe.Z,null):u?n.createElement(Ke,null):n.createElement(Se,null)}function pe(i){var f=i.treeData,u=i.children;return f||(0,ue.zn)(u)}var Ze=function(f,u){var p=f.defaultExpandAll,x=f.defaultExpandParent,y=f.defaultExpandedKeys,d=fe(f,["defaultExpandAll","defaultExpandParent","defaultExpandedKeys"]),b=n.useRef(),g=n.useRef(),D=function(){var z=(0,ue.I8)(pe(d)),H=z.keyEntities,O;return p?O=Object.keys(H):x?O=(0,Ne.r7)(d.expandedKeys||y||[],H):O=d.expandedKeys||y,O},E=n.useState(d.selectedKeys||d.defaultSelectedKeys||[]),F=(0,ce.Z)(E,2),te=F[0],A=F[1],R=n.useState(function(){return D()}),L=(0,ce.Z)(R,2),T=L[0],I=L[1];n.useEffect(function(){"selectedKeys"in d&&A(d.selectedKeys)},[d.selectedKeys]),n.useEffect(function(){"expandedKeys"in d&&I(d.expandedKeys)},[d.expandedKeys]);var k=function(z,H){var O;return"expandedKeys"in d||I(z),(O=d.onExpand)===null||O===void 0?void 0:O.call(d,z,H)},j=function(z,H){var O,ve=d.multiple,je=H.node,N=H.nativeEvent,xe=je.key,B=xe===void 0?"":xe,J=pe(d),Q=(0,s.Z)((0,s.Z)({},H),{selected:!0}),Me=(N==null?void 0:N.ctrlKey)||(N==null?void 0:N.metaKey),$e=N==null?void 0:N.shiftKey,K;ve&&Me?(K=z,b.current=B,g.current=K,Q.selectedNodes=q(J,K)):ve&&$e?(K=Array.from(new Set([].concat((0,X.Z)(g.current||[]),(0,X.Z)(Pe({treeData:J,expandedKeys:T,startKey:B,endKey:b.current}))))),Q.selectedNodes=q(J,K)):(K=[B],b.current=B,g.current=K,Q.selectedNodes=q(J,K)),(O=d.onSelect)===null||O===void 0||O.call(d,K,Q),"selectedKeys"in d||A(K)},P=n.useContext(oe.E_),G=P.getPrefixCls,ne=P.direction,w=d.prefixCls,ae=d.className,V=d.showIcon,S=V===void 0?!0:V,U=d.expandAction,Fe=U===void 0?"click":U,Ae=fe(d,["prefixCls","className","showIcon","expandAction"]),re=G("tree",w),Te=$()("".concat(re,"-directory"),(0,r.Z)({},"".concat(re,"-directory-rtl"),ne==="rtl"),ae);return n.createElement(ie,(0,s.Z)({icon:He,ref:u,blockNode:!0},Ae,{showIcon:S,expandAction:Fe,prefixCls:re,className:Te,expandedKeys:T,selectedKeys:te,onSelect:j,onExpand:k}))},De=n.forwardRef(Ze),Ie=De,ee=ie;ee.DirectoryTree=Ie,ee.TreeNode=t.O;var ze=ee},88987:function(a,l,e){var t=e(71519),r=e(82999),o=e(76111),s=e(50506),c=e(80845);function n(h){var v=-1,m=h==null?0:h.length;for(this.clear();++v<m;){var C=h[v];this.set(C[0],C[1])}}n.prototype.clear=t,n.prototype.delete=r,n.prototype.get=o,n.prototype.has=s,n.prototype.set=c,a.exports=n},175:function(a,l,e){var t=e(2173),r=e(33752),o=e(10548),s=e(63410),c=e(3564);function n(h){var v=-1,m=h==null?0:h.length;for(this.clear();++v<m;){var C=h[v];this.set(C[0],C[1])}}n.prototype.clear=t,n.prototype.delete=r,n.prototype.get=o,n.prototype.has=s,n.prototype.set=c,a.exports=n},35922:function(a,l,e){var t=e(47758),r=e(29165),o=t(r,"Map");a.exports=o},9440:function(a,l,e){var t=e(7140),r=e(56504),o=e(88833),s=e(80953),c=e(70724);function n(h){var v=-1,m=h==null?0:h.length;for(this.clear();++v<m;){var C=h[v];this.set(C[0],C[1])}}n.prototype.clear=t,n.prototype.delete=r,n.prototype.get=o,n.prototype.has=s,n.prototype.set=c,a.exports=n},81956:function(a,l,e){var t=e(47758),r=e(29165),o=t(r,"Set");a.exports=o},78188:function(a,l,e){var t=e(9440),r=e(96659),o=e(97230);function s(c){var n=-1,h=c==null?0:c.length;for(this.__data__=new t;++n<h;)this.add(c[n])}s.prototype.add=s.prototype.push=r,s.prototype.has=o,a.exports=s},62718:function(a,l,e){var t=e(42448);function r(o,s){for(var c=o.length;c--;)if(t(o[c][0],s))return c;return-1}a.exports=r},58939:function(a,l,e){var t=e(92042),r=e(90654),o=e(36838),s=e(51059),c=/[\\^$.*+?()[\]{}|]/g,n=/^\[object .+?Constructor\]$/,h=Function.prototype,v=Object.prototype,m=h.toString,C=v.hasOwnProperty,M=RegExp("^"+m.call(C).replace(c,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function W(Z){if(!o(Z)||r(Z))return!1;var $=t(Z)?M:n;return $.test(s(Z))}a.exports=W},29880:function(a){function l(e,t){return e.has(t)}a.exports=l},36633:function(a,l,e){var t=e(29165),r=t["__core-js_shared__"];a.exports=r},67707:function(a,l,e){var t=e(3880);function r(o,s){var c=o.__data__;return t(s)?c[typeof s=="string"?"string":"hash"]:c.map}a.exports=r},47758:function(a,l,e){var t=e(58939),r=e(9149);function o(s,c){var n=r(s,c);return t(n)?n:void 0}a.exports=o},9149:function(a){function l(e,t){return e==null?void 0:e[t]}a.exports=l},71519:function(a,l,e){var t=e(37722);function r(){this.__data__=t?t(null):{},this.size=0}a.exports=r},82999:function(a){function l(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}a.exports=l},76111:function(a,l,e){var t=e(37722),r="__lodash_hash_undefined__",o=Object.prototype,s=o.hasOwnProperty;function c(n){var h=this.__data__;if(t){var v=h[n];return v===r?void 0:v}return s.call(h,n)?h[n]:void 0}a.exports=c},50506:function(a,l,e){var t=e(37722),r=Object.prototype,o=r.hasOwnProperty;function s(c){var n=this.__data__;return t?n[c]!==void 0:o.call(n,c)}a.exports=s},80845:function(a,l,e){var t=e(37722),r="__lodash_hash_undefined__";function o(s,c){var n=this.__data__;return this.size+=this.has(s)?0:1,n[s]=t&&c===void 0?r:c,this}a.exports=o},3880:function(a){function l(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}a.exports=l},90654:function(a,l,e){var t=e(36633),r=function(){var s=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||"");return s?"Symbol(src)_1."+s:""}();function o(s){return!!r&&r in s}a.exports=o},2173:function(a){function l(){this.__data__=[],this.size=0}a.exports=l},33752:function(a,l,e){var t=e(62718),r=Array.prototype,o=r.splice;function s(c){var n=this.__data__,h=t(n,c);if(h<0)return!1;var v=n.length-1;return h==v?n.pop():o.call(n,h,1),--this.size,!0}a.exports=s},10548:function(a,l,e){var t=e(62718);function r(o){var s=this.__data__,c=t(s,o);return c<0?void 0:s[c][1]}a.exports=r},63410:function(a,l,e){var t=e(62718);function r(o){return t(this.__data__,o)>-1}a.exports=r},3564:function(a,l,e){var t=e(62718);function r(o,s){var c=this.__data__,n=t(c,o);return n<0?(++this.size,c.push([o,s])):c[n][1]=s,this}a.exports=r},7140:function(a,l,e){var t=e(88987),r=e(175),o=e(35922);function s(){this.size=0,this.__data__={hash:new t,map:new(o||r),string:new t}}a.exports=s},56504:function(a,l,e){var t=e(67707);function r(o){var s=t(this,o).delete(o);return this.size-=s?1:0,s}a.exports=r},88833:function(a,l,e){var t=e(67707);function r(o){return t(this,o).get(o)}a.exports=r},80953:function(a,l,e){var t=e(67707);function r(o){return t(this,o).has(o)}a.exports=r},70724:function(a,l,e){var t=e(67707);function r(o,s){var c=t(this,o),n=c.size;return c.set(o,s),this.size+=c.size==n?0:1,this}a.exports=r},37722:function(a,l,e){var t=e(47758),r=t(Object,"create");a.exports=r},96659:function(a){var l="__lodash_hash_undefined__";function e(t){return this.__data__.set(t,l),this}a.exports=e},97230:function(a){function l(e){return this.__data__.has(e)}a.exports=l},79967:function(a){function l(e){var t=-1,r=Array(e.size);return e.forEach(function(o){r[++t]=o}),r}a.exports=l},51059:function(a){var l=Function.prototype,e=l.toString;function t(r){if(r!=null){try{return e.call(r)}catch(o){}try{return r+""}catch(o){}}return""}a.exports=t},42448:function(a){function l(e,t){return e===t||e!==e&&t!==t}a.exports=l},92042:function(a,l,e){var t=e(80732),r=e(36838),o="[object AsyncFunction]",s="[object Function]",c="[object GeneratorFunction]",n="[object Proxy]";function h(v){if(!r(v))return!1;var m=t(v);return m==s||m==c||m==o||m==n}a.exports=h}}]);
|
|
@@ -7,7 +7,7 @@ b`.split(/\n/).length!=3?function(e){for(var t=0,i=[],r=e.length;t<=r;){var n=e.
|
|
|
7
7
|
height: `+(S-C)+"px"))}function h(b,C,L){var S=w(n,b),N=S.text.length,P,J;function B(K,fe){return Xr(e,g(b,K),"div",S,fe)}function de(K,fe,V){var X=Tl(e,S,null,K),_=fe=="ltr"==(V=="after")?"left":"right",R=V=="after"?X.begin:X.end-(/\s/.test(S.text.charAt(X.end-1))?2:1);return B(R,_)[_]}var ue=Fe(S,n.direction);return jo(ue,C||0,L==null?N:L,function(K,fe,V,X){var _=V=="ltr",R=B(K,_?"left":"right"),he=B(fe-1,_?"right":"left"),zt=C==null&&K==0,$e=L==null&&fe==N,te=X==0,We=!ue||X==ue.length-1;if(he.top-R.top<=3){var j=(u?zt:$e)&&te,Tn=(u?$e:zt)&&We,ze=j?a:(_?R:he).left,gt=Tn?s:(_?he:R).right;f(ze,R.top,gt-ze,R.bottom)}else{var yt,le,Gt,Mn;_?(yt=u&&zt&&te?a:R.left,le=u?s:de(K,V,"before"),Gt=u?a:de(fe,V,"after"),Mn=u&&$e&&We?s:he.right):(yt=u?de(K,V,"before"):a,le=!u&&zt&&te?s:R.right,Gt=!u&&$e&&We?a:he.left,Mn=u?de(fe,V,"after"):s),f(yt,R.top,le-yt,R.bottom),R.bottom<he.top&&f(a,R.bottom,null,he.top),f(Gt,he.top,Mn-Gt,he.bottom)}(!P||qr(R,P)<0)&&(P=R),qr(he,P)<0&&(P=he),(!J||qr(R,J)<0)&&(J=R),qr(he,J)<0&&(J=he)}),{start:P,end:J}}var d=t.from(),c=t.to();if(d.line==c.line)h(d.line,d.ch,c.ch);else{var p=w(n,d.line),v=w(n,c.line),y=Se(p)==Se(v),m=h(d.line,d.ch,y?p.text.length+1:null).end,x=h(c.line,y?0:null,c.ch).start;y&&(m.top<x.top-2?(f(m.right,m.top,null,m.bottom),f(a,x.top,x.left,x.bottom)):f(m.right,m.top,x.left-m.right,m.bottom)),m.bottom<x.top&&f(a,m.bottom,null,x.top)}i.appendChild(l)}function $i(e){if(e.state.focused){var t=e.display;clearInterval(t.blinker);var i=!0;t.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?t.blinker=setInterval(function(){e.hasFocus()||Dt(e),t.cursorDiv.style.visibility=(i=!i)?"":"hidden"},e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function Al(e){e.hasFocus()||(e.display.input.focus(),e.state.focused||tn(e))}function en(e){e.state.delayingBlurEvent=!0,setTimeout(function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,e.state.focused&&Dt(e))},100)}function tn(e,t){e.state.delayingBlurEvent&&!e.state.draggingText&&(e.state.delayingBlurEvent=!1),e.options.readOnly!="nocursor"&&(e.state.focused||(G(e,"focus",e,t),e.state.focused=!0,it(e.display.wrapper,"CodeMirror-focused"),!e.curOp&&e.display.selForContextMenu!=e.doc.sel&&(e.display.input.reset(),ie&&setTimeout(function(){return e.display.input.reset(!0)},20)),e.display.input.receivedFocus()),$i(e))}function Dt(e,t){e.state.delayingBlurEvent||(e.state.focused&&(G(e,"blur",e,t),e.state.focused=!1,tt(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout(function(){e.state.focused||(e.display.shift=!1)},150))}function Zr(e){for(var t=e.display,i=t.lineDiv.offsetTop,r=Math.max(0,t.scroller.getBoundingClientRect().top),n=t.lineDiv.getBoundingClientRect().top,l=0,o=0;o<t.view.length;o++){var a=t.view[o],s=e.options.lineWrapping,u=void 0,f=0;if(!a.hidden){if(n+=a.line.height,A&&E<8){var h=a.node.offsetTop+a.node.offsetHeight;u=h-i,i=h}else{var d=a.node.getBoundingClientRect();u=d.bottom-d.top,!s&&a.text.firstChild&&(f=a.text.firstChild.getBoundingClientRect().right-d.left-1)}var c=a.line.height-u;if((c>.005||c<-.005)&&(n<r&&(l-=c),De(a.line,u),Ol(a.line),a.rest))for(var p=0;p<a.rest.length;p++)Ol(a.rest[p]);if(f>e.display.sizerWidth){var v=Math.ceil(f/Mt(e.display));v>e.display.maxLineLength&&(e.display.maxLineLength=v,e.display.maxLine=a.line,e.display.maxLineChanged=!0)}}}Math.abs(l)>2&&(t.scroller.scrollTop+=l)}function Ol(e){if(e.widgets)for(var t=0;t<e.widgets.length;++t){var i=e.widgets[t],r=i.node.parentNode;r&&(i.height=r.offsetHeight)}}function Qr(e,t,i){var r=i&&i.top!=null?Math.max(0,i.top):e.scroller.scrollTop;r=Math.floor(r-Kr(e));var n=i&&i.bottom!=null?i.bottom:r+e.wrapper.clientHeight,l=at(t,r),o=at(t,n);if(i&&i.ensure){var a=i.ensure.from.line,s=i.ensure.to.line;a<l?(l=a,o=at(t,Ee(w(t,a))+e.wrapper.clientHeight)):Math.min(s,t.lastLine())>=o&&(l=at(t,Ee(w(t,s))-e.wrapper.clientHeight),o=s)}return{from:l,to:Math.max(o,l+1)}}function Qa(e,t){if(!Y(e,"scrollCursorIntoView")){var i=e.display,r=i.sizer.getBoundingClientRect(),n=null,l=i.wrapper.ownerDocument;if(t.top+r.top<0?n=!0:t.bottom+r.top>(l.defaultView.innerHeight||l.documentElement.clientHeight)&&(n=!1),n!=null&&!Xo){var o=k("div","\u200B",null,`position: absolute;
|
|
8
8
|
top: `+(t.top-i.viewOffset-Kr(e.display))+`px;
|
|
9
9
|
height: `+(t.bottom-t.top+Ae(e)+i.barHeight)+`px;
|
|
10
|
-
left: `+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(o),o.scrollIntoView(n),e.display.lineSpace.removeChild(o)}}}function Ja(e,t,i,r){r==null&&(r=0);var n;!e.options.lineWrapping&&t==i&&(i=t.sticky=="before"?g(t.line,t.ch+1,"before"):t,t=t.ch?g(t.line,t.sticky=="before"?t.ch-1:t.ch,"after"):t);for(var l=0;l<5;l++){var o=!1,a=Le(e,t),s=!i||i==t?a:Le(e,i);n={left:Math.min(a.left,s.left),top:Math.min(a.top,s.top)-r,right:Math.max(a.left,s.left),bottom:Math.max(a.bottom,s.bottom)+r};var u=rn(e,n),f=e.doc.scrollTop,h=e.doc.scrollLeft;if(u.scrollTop!=null&&(lr(e,u.scrollTop),Math.abs(e.doc.scrollTop-f)>1&&(o=!0)),u.scrollLeft!=null&&(ct(e,u.scrollLeft),Math.abs(e.doc.scrollLeft-h)>1&&(o=!0)),!o)break}return n}function ja(e,t){var i=rn(e,t);i.scrollTop!=null&&lr(e,i.scrollTop),i.scrollLeft!=null&&ct(e,i.scrollLeft)}function rn(e,t){var i=e.display,r=Tt(e.display);t.top<0&&(t.top=0);var n=e.curOp&&e.curOp.scrollTop!=null?e.curOp.scrollTop:i.scroller.scrollTop,l=Ki(e),o={};t.bottom-t.top>l&&(t.bottom=t.top+l);var a=e.doc.height+Ui(i),s=t.top<r,u=t.bottom>a-r;if(t.top<n)o.scrollTop=s?0:t.top;else if(t.bottom>n+l){var f=Math.min(t.top,(u?a:t.bottom)-l);f!=n&&(o.scrollTop=f)}var h=e.options.fixedGutter?0:i.gutters.offsetWidth,d=e.curOp&&e.curOp.scrollLeft!=null?e.curOp.scrollLeft:i.scroller.scrollLeft-h,c=st(e)-i.gutters.offsetWidth,p=t.right-t.left>c;return p&&(t.right=t.left+c),t.left<10?o.scrollLeft=0:t.left<d?o.scrollLeft=Math.max(0,t.left+h-(p?0:10)):t.right>c+d-3&&(o.scrollLeft=t.right+(p?0:10)-c),o}function nn(e,t){t!=null&&(Jr(e),e.curOp.scrollTop=(e.curOp.scrollTop==null?e.doc.scrollTop:e.curOp.scrollTop)+t)}function Nt(e){Jr(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function nr(e,t,i){(t!=null||i!=null)&&Jr(e),t!=null&&(e.curOp.scrollLeft=t),i!=null&&(e.curOp.scrollTop=i)}function Va(e,t){Jr(e),e.curOp.scrollToPos=t}function Jr(e){var t=e.curOp.scrollToPos;if(t){e.curOp.scrollToPos=null;var i=Ll(e,t.from),r=Ll(e,t.to);Wl(e,i,r,t.margin)}}function Wl(e,t,i,r){var n=rn(e,{left:Math.min(t.left,i.left),top:Math.min(t.top,i.top)-r,right:Math.max(t.right,i.right),bottom:Math.max(t.bottom,i.bottom)+r});nr(e,n.scrollLeft,n.scrollTop)}function lr(e,t){Math.abs(e.doc.scrollTop-t)<2||(He||on(e,{top:t}),Hl(e,t,!0),He&&on(e),sr(e,100))}function Hl(e,t,i){t=Math.max(0,Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t)),!(e.display.scroller.scrollTop==t&&!i)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function ct(e,t,i,r){t=Math.max(0,Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth)),!((i?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!r)&&(e.doc.scrollLeft=t,Bl(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function or(e){var t=e.display,i=t.gutters.offsetWidth,r=Math.round(e.doc.height+Ui(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?i:0,docHeight:r,scrollHeight:r+Ae(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:i}}var dt=function(e,t,i){this.cm=i;var r=this.vert=k("div",[k("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),n=this.horiz=k("div",[k("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");r.tabIndex=n.tabIndex=-1,e(r),e(n),T(r,"scroll",function(){r.clientHeight&&t(r.scrollTop,"vertical")}),T(n,"scroll",function(){n.clientWidth&&t(n.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,A&&E<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};dt.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,i=e.scrollHeight>e.clientHeight+1,r=e.nativeBarWidth;if(i){this.vert.style.display="block",this.vert.style.bottom=t?r+"px":"0";var n=e.viewHeight-(t?r:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+n)+"px"}else this.vert.scrollTop=0,this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=i?r+"px":"0",this.horiz.style.left=e.barLeft+"px";var l=e.viewWidth-e.barLeft-(i?r:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+l)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(r==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:i?r:0,bottom:t?r:0}},dt.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},dt.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},dt.prototype.zeroWidthHack=function(){var e=ye&&!_o?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.visibility=this.vert.style.visibility="hidden",this.disableHoriz=new _e,this.disableVert=new _e},dt.prototype.enableZeroWidthBar=function(e,t,i){e.style.visibility="";function r(){var n=e.getBoundingClientRect(),l=i=="vert"?document.elementFromPoint(n.right-1,(n.top+n.bottom)/2):document.elementFromPoint((n.right+n.left)/2,n.bottom-1);l!=e?e.style.visibility="hidden":t.set(1e3,r)}t.set(1e3,r)},dt.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var ar=function(){};ar.prototype.update=function(){return{bottom:0,right:0}},ar.prototype.setScrollLeft=function(){},ar.prototype.setScrollTop=function(){},ar.prototype.clear=function(){};function At(e,t){t||(t=or(e));var i=e.display.barWidth,r=e.display.barHeight;Fl(e,t);for(var n=0;n<4&&i!=e.display.barWidth||r!=e.display.barHeight;n++)i!=e.display.barWidth&&e.options.lineWrapping&&Zr(e),Fl(e,or(e)),i=e.display.barWidth,r=e.display.barHeight}function Fl(e,t){var i=e.display,r=i.scrollbars.update(t);i.sizer.style.paddingRight=(i.barWidth=r.right)+"px",i.sizer.style.paddingBottom=(i.barHeight=r.bottom)+"px",i.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(i.scrollbarFiller.style.display="block",i.scrollbarFiller.style.height=r.bottom+"px",i.scrollbarFiller.style.width=r.right+"px"):i.scrollbarFiller.style.display="",r.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(i.gutterFiller.style.display="block",i.gutterFiller.style.height=r.bottom+"px",i.gutterFiller.style.width=t.gutterWidth+"px"):i.gutterFiller.style.display=""}var Pl={native:dt,null:ar};function El(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&tt(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new Pl[e.options.scrollbarStyle](function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),T(t,"mousedown",function(){e.state.focused&&setTimeout(function(){return e.display.input.focus()},0)}),t.setAttribute("cm-not-content","true")},function(t,i){i=="horizontal"?ct(e,t):lr(e,t)},e),e.display.scrollbars.addClass&&it(e.display.wrapper,e.display.scrollbars.addClass)}var $a=0;function pt(e){e.curOp={cm:e,viewChanged:!1,startHeight:e.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:++$a,markArrays:null},Aa(e.curOp)}function vt(e){var t=e.curOp;t&&Wa(t,function(i){for(var r=0;r<i.ops.length;r++)i.ops[r].cm.curOp=null;es(i)})}function es(e){for(var t=e.ops,i=0;i<t.length;i++)ts(t[i]);for(var r=0;r<t.length;r++)rs(t[r]);for(var n=0;n<t.length;n++)is(t[n]);for(var l=0;l<t.length;l++)ns(t[l]);for(var o=0;o<t.length;o++)ls(t[o])}function ts(e){var t=e.cm,i=t.display;as(t),e.updateMaxLine&&zi(t),e.mustUpdate=e.viewChanged||e.forceUpdate||e.scrollTop!=null||e.scrollToPos&&(e.scrollToPos.from.line<i.viewFrom||e.scrollToPos.to.line>=i.viewTo)||i.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new jr(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function rs(e){e.updatedDisplay=e.mustUpdate&&ln(e.cm,e.update)}function is(e){var t=e.cm,i=t.display;e.updatedDisplay&&Zr(t),e.barMeasure=or(t),i.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=gl(t,i.maxLine,i.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(i.scroller.clientWidth,i.sizer.offsetLeft+e.adjustWidthTo+Ae(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,i.sizer.offsetLeft+e.adjustWidthTo-st(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=i.input.prepareSelection())}function ns(e){var t=e.cm;e.adjustWidthTo!=null&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&ct(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1);var i=e.focus&&e.focus==me(we(t));e.preparedSelection&&t.display.input.showSelection(e.preparedSelection,i),(e.updatedDisplay||e.startHeight!=t.doc.height)&&At(t,e.barMeasure),e.updatedDisplay&&sn(t,e.barMeasure),e.selectionChanged&&$i(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),i&&Al(e.cm)}function ls(e){var t=e.cm,i=t.display,r=t.doc;if(e.updatedDisplay&&Il(t,e.update),i.wheelStartX!=null&&(e.scrollTop!=null||e.scrollLeft!=null||e.scrollToPos)&&(i.wheelStartX=i.wheelStartY=null),e.scrollTop!=null&&Hl(t,e.scrollTop,e.forceScroll),e.scrollLeft!=null&&ct(t,e.scrollLeft,!0,!0),e.scrollToPos){var n=Ja(t,D(r,e.scrollToPos.from),D(r,e.scrollToPos.to),e.scrollToPos.margin);Qa(t,n)}var l=e.maybeHiddenMarkers,o=e.maybeUnhiddenMarkers;if(l)for(var a=0;a<l.length;++a)l[a].lines.length||G(l[a],"hide");if(o)for(var s=0;s<o.length;++s)o[s].lines.length&&G(o[s],"unhide");i.wrapper.offsetHeight&&(r.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&G(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function ce(e,t){if(e.curOp)return t();pt(e);try{return t()}finally{vt(e)}}function Z(e,t){return function(){if(e.curOp)return t.apply(e,arguments);pt(e);try{return t.apply(e,arguments)}finally{vt(e)}}}function ne(e){return function(){if(this.curOp)return e.apply(this,arguments);pt(this);try{return e.apply(this,arguments)}finally{vt(this)}}}function Q(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);pt(t);try{return e.apply(this,arguments)}finally{vt(t)}}}function sr(e,t){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(t,pi(os,e))}function os(e){var t=e.doc;if(!(t.highlightFrontier>=e.display.viewTo)){var i=+new Date+e.options.workTime,r=jt(e,t.highlightFrontier),n=[];t.iter(r.line,Math.min(t.first+t.size,e.display.viewTo+500),function(l){if(r.line>=e.display.viewFrom){var o=l.styles,a=l.text.length>e.options.maxHighlightLength?lt(t.mode,r.state):null,s=_n(e,l,r,!0);a&&(r.state=a),l.styles=s.styles;var u=l.styleClasses,f=s.classes;f?l.styleClasses=f:u&&(l.styleClasses=null);for(var h=!o||o.length!=l.styles.length||u!=f&&(!u||!f||u.bgClass!=f.bgClass||u.textClass!=f.textClass),d=0;!h&&d<o.length;++d)h=o[d]!=l.styles[d];h&&n.push(r.line),l.stateAfter=r.save(),r.nextLine()}else l.text.length<=e.options.maxHighlightLength&&Fi(e,l.text,r),l.stateAfter=r.line%5==0?r.save():null,r.nextLine();if(+new Date>i)return sr(e,e.options.workDelay),!0}),t.highlightFrontier=r.line,t.modeFrontier=Math.max(t.modeFrontier,r.line),n.length&&ce(e,function(){for(var l=0;l<n.length;l++)Ye(e,n[l],"text")})}}var jr=function(e,t,i){var r=e.display;this.viewport=t,this.visible=Qr(r,e.doc,t),this.editorIsHidden=!r.wrapper.offsetWidth,this.wrapperHeight=r.wrapper.clientHeight,this.wrapperWidth=r.wrapper.clientWidth,this.oldDisplayWidth=st(e),this.force=i,this.dims=Qi(e),this.events=[]};jr.prototype.signal=function(e,t){xe(e,t)&&this.events.push(arguments)},jr.prototype.finish=function(){for(var e=0;e<this.events.length;e++)G.apply(null,this.events[e])};function as(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=Ae(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=Ae(e)+"px",t.scrollbarsClipped=!0)}function ss(e){if(e.hasFocus())return null;var t=me(we(e));if(!t||!Ke(e.display.lineDiv,t))return null;var i={activeElt:t};if(window.getSelection){var r=Dr(e).getSelection();r.anchorNode&&r.extend&&Ke(e.display.lineDiv,r.anchorNode)&&(i.anchorNode=r.anchorNode,i.anchorOffset=r.anchorOffset,i.focusNode=r.focusNode,i.focusOffset=r.focusOffset)}return i}function us(e){if(!(!e||!e.activeElt||e.activeElt==me(e.activeElt.ownerDocument))&&(e.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName)&&e.anchorNode&&Ke(document.body,e.anchorNode)&&Ke(document.body,e.focusNode))){var t=e.activeElt.ownerDocument,i=t.defaultView.getSelection(),r=t.createRange();r.setEnd(e.anchorNode,e.anchorOffset),r.collapse(!1),i.removeAllRanges(),i.addRange(r),i.extend(e.focusNode,e.focusOffset)}}function ln(e,t){var i=e.display,r=e.doc;if(t.editorIsHidden)return qe(e),!1;if(!t.force&&t.visible.from>=i.viewFrom&&t.visible.to<=i.viewTo&&(i.updateLineNumbers==null||i.updateLineNumbers>=i.viewTo)&&i.renderedView==i.view&&Dl(e)==0)return!1;Rl(e)&&(qe(e),t.dims=Qi(e));var n=r.first+r.size,l=Math.max(t.visible.from-e.options.viewportMargin,r.first),o=Math.min(n,t.visible.to+e.options.viewportMargin);i.viewFrom<l&&l-i.viewFrom<20&&(l=Math.max(r.first,i.viewFrom)),i.viewTo>o&&i.viewTo-o<20&&(o=Math.min(n,i.viewTo)),Pe&&(l=Bi(e.doc,l),o=nl(e.doc,o));var a=l!=i.viewFrom||o!=i.viewTo||i.lastWrapHeight!=t.wrapperHeight||i.lastWrapWidth!=t.wrapperWidth;qa(e,l,o),i.viewOffset=Ee(w(e.doc,i.viewFrom)),e.display.mover.style.top=i.viewOffset+"px";var s=Dl(e);if(!a&&s==0&&!t.force&&i.renderedView==i.view&&(i.updateLineNumbers==null||i.updateLineNumbers>=i.viewTo))return!1;var u=ss(e);return s>4&&(i.lineDiv.style.display="none"),fs(e,i.updateLineNumbers,t.dims),s>4&&(i.lineDiv.style.display=""),i.renderedView=i.view,us(u),Ue(i.cursorDiv),Ue(i.selectionDiv),i.gutters.style.height=i.sizer.style.minHeight=0,a&&(i.lastWrapHeight=t.wrapperHeight,i.lastWrapWidth=t.wrapperWidth,sr(e,400)),i.updateLineNumbers=null,!0}function Il(e,t){for(var i=t.viewport,r=!0;;r=!1){if(!r||!e.options.lineWrapping||t.oldDisplayWidth==st(e)){if(i&&i.top!=null&&(i={top:Math.min(e.doc.height+Ui(e.display)-Ki(e),i.top)}),t.visible=Qr(e.display,e.doc,i),t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)break}else r&&(t.visible=Qr(e.display,e.doc,i));if(!ln(e,t))break;Zr(e);var n=or(e);ir(e),At(e,n),sn(e,n),t.force=!1}t.signal(e,"update",e),(e.display.viewFrom!=e.display.reportedViewFrom||e.display.viewTo!=e.display.reportedViewTo)&&(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function on(e,t){var i=new jr(e,t);if(ln(e,i)){Zr(e),Il(e,i);var r=or(e);ir(e),At(e,r),sn(e,r),i.finish()}}function fs(e,t,i){var r=e.display,n=e.options.lineNumbers,l=r.lineDiv,o=l.firstChild;function a(p){var v=p.nextSibling;return ie&&ye&&e.display.currentWheelTarget==p?p.style.display="none":p.parentNode.removeChild(p),v}for(var s=r.view,u=r.viewFrom,f=0;f<s.length;f++){var h=s[f];if(!h.hidden)if(!h.node||h.node.parentNode!=l){var d=Ia(e,h,u,i);l.insertBefore(d,o)}else{for(;o!=h.node;)o=a(o);var c=n&&t!=null&&t<=u&&h.lineNumber;h.changes&&($(h.changes,"gutter")>-1&&(c=!1),ul(e,h,u,i)),c&&(Ue(h.lineNumber),h.lineNumber.appendChild(document.createTextNode(Oi(e.options,u)))),o=h.node.nextSibling}u+=h.size}for(;o;)o=a(o)}function an(e){var t=e.gutters.offsetWidth;e.sizer.style.marginLeft=t+"px",q(e,"gutterChanged",e)}function sn(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Ae(e)+"px"}function Bl(e){var t=e.display,i=t.view;if(!(!t.alignWidgets&&(!t.gutters.firstChild||!e.options.fixedGutter))){for(var r=Ji(t)-t.scroller.scrollLeft+e.doc.scrollLeft,n=t.gutters.offsetWidth,l=r+"px",o=0;o<i.length;o++)if(!i[o].hidden){e.options.fixedGutter&&(i[o].gutter&&(i[o].gutter.style.left=l),i[o].gutterBackground&&(i[o].gutterBackground.style.left=l));var a=i[o].alignable;if(a)for(var s=0;s<a.length;s++)a[s].style.left=l}e.options.fixedGutter&&(t.gutters.style.left=r+n+"px")}}function Rl(e){if(!e.options.lineNumbers)return!1;var t=e.doc,i=Oi(e.options,t.first+t.size-1),r=e.display;if(i.length!=r.lineNumChars){var n=r.measure.appendChild(k("div",[k("div",i)],"CodeMirror-linenumber CodeMirror-gutter-elt")),l=n.firstChild.offsetWidth,o=n.offsetWidth-l;return r.lineGutter.style.width="",r.lineNumInnerWidth=Math.max(l,r.lineGutter.offsetWidth-o)+1,r.lineNumWidth=r.lineNumInnerWidth+o,r.lineNumChars=r.lineNumInnerWidth?i.length:-1,r.lineGutter.style.width=r.lineNumWidth+"px",an(e.display),!0}return!1}function un(e,t){for(var i=[],r=!1,n=0;n<e.length;n++){var l=e[n],o=null;if(typeof l!="string"&&(o=l.style,l=l.className),l=="CodeMirror-linenumbers")if(t)r=!0;else continue;i.push({className:l,style:o})}return t&&!r&&i.push({className:"CodeMirror-linenumbers",style:null}),i}function zl(e){var t=e.gutters,i=e.gutterSpecs;Ue(t),e.lineGutter=null;for(var r=0;r<i.length;++r){var n=i[r],l=n.className,o=n.style,a=t.appendChild(k("div",null,"CodeMirror-gutter "+l));o&&(a.style.cssText=o),l=="CodeMirror-linenumbers"&&(e.lineGutter=a,a.style.width=(e.lineNumWidth||1)+"px")}t.style.display=i.length?"":"none",an(e)}function ur(e){zl(e.display),ae(e),Bl(e)}function hs(e,t,i,r){var n=this;this.input=i,n.scrollbarFiller=k("div",null,"CodeMirror-scrollbar-filler"),n.scrollbarFiller.setAttribute("cm-not-content","true"),n.gutterFiller=k("div",null,"CodeMirror-gutter-filler"),n.gutterFiller.setAttribute("cm-not-content","true"),n.lineDiv=bt("div",null,"CodeMirror-code"),n.selectionDiv=k("div",null,null,"position: relative; z-index: 1"),n.cursorDiv=k("div",null,"CodeMirror-cursors"),n.measure=k("div",null,"CodeMirror-measure"),n.lineMeasure=k("div",null,"CodeMirror-measure"),n.lineSpace=bt("div",[n.measure,n.lineMeasure,n.selectionDiv,n.cursorDiv,n.lineDiv],null,"position: relative; outline: none");var l=bt("div",[n.lineSpace],"CodeMirror-lines");n.mover=k("div",[l],null,"position: relative"),n.sizer=k("div",[n.mover],"CodeMirror-sizer"),n.sizerWidth=null,n.heightForcer=k("div",null,null,"position: absolute; height: "+Wn+"px; width: 1px;"),n.gutters=k("div",null,"CodeMirror-gutters"),n.lineGutter=null,n.scroller=k("div",[n.sizer,n.heightForcer,n.gutters],"CodeMirror-scroll"),n.scroller.setAttribute("tabIndex","-1"),n.wrapper=k("div",[n.scrollbarFiller,n.gutterFiller,n.scroller],"CodeMirror"),Ge&&An>=105&&(n.wrapper.style.clipPath="inset(0px)"),n.wrapper.setAttribute("translate","no"),A&&E<8&&(n.gutters.style.zIndex=-1,n.scroller.style.paddingRight=0),!ie&&!(He&&Kt)&&(n.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(n.wrapper):e(n.wrapper)),n.viewFrom=n.viewTo=t.first,n.reportedViewFrom=n.reportedViewTo=t.first,n.view=[],n.renderedView=null,n.externalMeasured=null,n.viewOffset=0,n.lastWrapHeight=n.lastWrapWidth=0,n.updateLineNumbers=null,n.nativeBarWidth=n.barHeight=n.barWidth=0,n.scrollbarsClipped=!1,n.lineNumWidth=n.lineNumInnerWidth=n.lineNumChars=null,n.alignWidgets=!1,n.cachedCharWidth=n.cachedTextHeight=n.cachedPaddingH=null,n.maxLine=null,n.maxLineLength=0,n.maxLineChanged=!1,n.wheelDX=n.wheelDY=n.wheelStartX=n.wheelStartY=null,n.shift=!1,n.selForContextMenu=null,n.activeTouch=null,n.gutterSpecs=un(r.gutters,r.lineNumbers),zl(n),i.init(n)}var Vr=0,Be=null;A?Be=-.53:He?Be=15:Ge?Be=-.7:Tr&&(Be=-1/3);function Gl(e){var t=e.wheelDeltaX,i=e.wheelDeltaY;return t==null&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),i==null&&e.detail&&e.axis==e.VERTICAL_AXIS?i=e.detail:i==null&&(i=e.wheelDelta),{x:t,y:i}}function cs(e){var t=Gl(e);return t.x*=Be,t.y*=Be,t}function Ul(e,t){Ge&&An==102&&(e.display.chromeScrollHack==null?e.display.sizer.style.pointerEvents="none":clearTimeout(e.display.chromeScrollHack),e.display.chromeScrollHack=setTimeout(function(){e.display.chromeScrollHack=null,e.display.sizer.style.pointerEvents=""},100));var i=Gl(t),r=i.x,n=i.y,l=Be;t.deltaMode===0&&(r=t.deltaX,n=t.deltaY,l=1);var o=e.display,a=o.scroller,s=a.scrollWidth>a.clientWidth,u=a.scrollHeight>a.clientHeight;if(r&&s||n&&u){if(n&&ye&&ie){e:for(var f=t.target,h=o.view;f!=a;f=f.parentNode)for(var d=0;d<h.length;d++)if(h[d].node==f){e.display.currentWheelTarget=f;break e}}if(r&&!He&&!Ce&&l!=null){n&&u&&lr(e,Math.max(0,a.scrollTop+n*l)),ct(e,Math.max(0,a.scrollLeft+r*l)),(!n||n&&u)&&oe(t),o.wheelStartX=null;return}if(n&&l!=null){var c=n*l,p=e.doc.scrollTop,v=p+o.wrapper.clientHeight;c<0?p=Math.max(0,p+c-50):v=Math.min(e.doc.height,v+c+50),on(e,{top:p,bottom:v})}Vr<20&&t.deltaMode!==0&&(o.wheelStartX==null?(o.wheelStartX=a.scrollLeft,o.wheelStartY=a.scrollTop,o.wheelDX=r,o.wheelDY=n,setTimeout(function(){if(o.wheelStartX!=null){var y=a.scrollLeft-o.wheelStartX,m=a.scrollTop-o.wheelStartY,x=m&&o.wheelDY&&m/o.wheelDY||y&&o.wheelDX&&y/o.wheelDX;o.wheelStartX=o.wheelStartY=null,x&&(Be=(Be*Vr+x)/(Vr+1),++Vr)}},200)):(o.wheelDX+=r,o.wheelDY+=n))}}var ge=function(e,t){this.ranges=e,this.primIndex=t};ge.prototype.primary=function(){return this.ranges[this.primIndex]},ge.prototype.equals=function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var t=0;t<this.ranges.length;t++){var i=this.ranges[t],r=e.ranges[t];if(!Wi(i.anchor,r.anchor)||!Wi(i.head,r.head))return!1}return!0},ge.prototype.deepCopy=function(){for(var e=[],t=0;t<this.ranges.length;t++)e[t]=new O(Hi(this.ranges[t].anchor),Hi(this.ranges[t].head));return new ge(e,this.primIndex)},ge.prototype.somethingSelected=function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},ge.prototype.contains=function(e,t){t||(t=e);for(var i=0;i<this.ranges.length;i++){var r=this.ranges[i];if(M(t,r.from())>=0&&M(e,r.to())<=0)return i}return-1};var O=function(e,t){this.anchor=e,this.head=t};O.prototype.from=function(){return Pr(this.anchor,this.head)},O.prototype.to=function(){return Fr(this.anchor,this.head)},O.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function ke(e,t,i){var r=e&&e.options.selectionsMayTouch,n=t[i];t.sort(function(d,c){return M(d.from(),c.from())}),i=$(t,n);for(var l=1;l<t.length;l++){var o=t[l],a=t[l-1],s=M(a.to(),o.from());if(r&&!o.empty()?s>0:s>=0){var u=Pr(a.from(),o.from()),f=Fr(a.to(),o.to()),h=a.empty()?o.from()==o.head:a.from()==a.head;l<=i&&--i,t.splice(--l,2,new O(h?f:u,h?u:f))}}return new ge(t,i)}function Ze(e,t){return new ge([new O(e,t||e)],0)}function Qe(e){return e.text?g(e.from.line+e.text.length-1,W(e.text).length+(e.text.length==1?e.from.ch:0)):e.to}function Kl(e,t){if(M(e,t.from)<0)return e;if(M(e,t.to)<=0)return Qe(t);var i=e.line+t.text.length-(t.to.line-t.from.line)-1,r=e.ch;return e.line==t.to.line&&(r+=Qe(t).ch-t.to.ch),g(i,r)}function fn(e,t){for(var i=[],r=0;r<e.sel.ranges.length;r++){var n=e.sel.ranges[r];i.push(new O(Kl(n.anchor,t),Kl(n.head,t)))}return ke(e.cm,i,e.sel.primIndex)}function _l(e,t,i){return e.line==t.line?g(i.line,e.ch-t.ch+i.ch):g(i.line+(e.line-t.line),e.ch)}function ds(e,t,i){for(var r=[],n=g(e.first,0),l=n,o=0;o<t.length;o++){var a=t[o],s=_l(a.from,n,l),u=_l(Qe(a),n,l);if(n=a.to,l=u,i=="around"){var f=e.sel.ranges[o],h=M(f.head,f.anchor)<0;r[o]=new O(h?u:s,h?s:u)}else r[o]=new O(s,s)}return new ge(r,e.sel.primIndex)}function hn(e){e.doc.mode=Di(e.options,e.doc.modeOption),fr(e)}function fr(e){e.doc.iter(function(t){t.stateAfter&&(t.stateAfter=null),t.styles&&(t.styles=null)}),e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,sr(e,100),e.state.modeGen++,e.curOp&&ae(e)}function Xl(e,t){return t.from.ch==0&&t.to.ch==0&&W(t.text)==""&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function cn(e,t,i,r){function n(x){return i?i[x]:null}function l(x,b,C){Ca(x,b,C,r),q(x,"change",x,t)}function o(x,b){for(var C=[],L=x;L<b;++L)C.push(new St(u[L],n(L),r));return C}var a=t.from,s=t.to,u=t.text,f=w(e,a.line),h=w(e,s.line),d=W(u),c=n(u.length-1),p=s.line-a.line;if(t.full)e.insert(0,o(0,u.length)),e.remove(u.length,e.size-u.length);else if(Xl(e,t)){var v=o(0,u.length-1);l(h,h.text,c),p&&e.remove(a.line,p),v.length&&e.insert(a.line,v)}else if(f==h)if(u.length==1)l(f,f.text.slice(0,a.ch)+d+f.text.slice(s.ch),c);else{var y=o(1,u.length-1);y.push(new St(d+f.text.slice(s.ch),c,r)),l(f,f.text.slice(0,a.ch)+u[0],n(0)),e.insert(a.line+1,y)}else if(u.length==1)l(f,f.text.slice(0,a.ch)+u[0]+h.text.slice(s.ch),n(0)),e.remove(a.line+1,p);else{l(f,f.text.slice(0,a.ch)+u[0],n(0)),l(h,d+h.text.slice(s.ch),c);var m=o(1,u.length-1);p>1&&e.remove(a.line+1,p-1),e.insert(a.line+1,m)}q(e,"change",e,t)}function Je(e,t,i){function r(n,l,o){if(n.linked)for(var a=0;a<n.linked.length;++a){var s=n.linked[a];if(s.doc!=l){var u=o&&s.sharedHist;i&&!u||(t(s.doc,u),r(s.doc,n,u))}}}r(e,null,!0)}function Yl(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,ji(e),hn(e),ql(e),e.options.direction=t.direction,e.options.lineWrapping||zi(e),e.options.mode=t.modeOption,ae(e)}function ql(e){(e.doc.direction=="rtl"?it:tt)(e.display.lineDiv,"CodeMirror-rtl")}function ps(e){ce(e,function(){ql(e),ae(e)})}function $r(e){this.done=[],this.undone=[],this.undoDepth=e?e.undoDepth:1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e?e.maxGeneration:1}function dn(e,t){var i={from:Hi(t.from),to:Qe(t),text:ot(e,t.from,t.to)};return Jl(e,i,t.from.line,t.to.line+1),Je(e,function(r){return Jl(r,i,t.from.line,t.to.line+1)},!0),i}function Zl(e){for(;e.length;){var t=W(e);if(t.ranges)e.pop();else break}}function vs(e,t){if(t)return Zl(e.done),W(e.done);if(e.done.length&&!W(e.done).ranges)return W(e.done);if(e.done.length>1&&!e.done[e.done.length-2].ranges)return e.done.pop(),W(e.done)}function Ql(e,t,i,r){var n=e.history;n.undone.length=0;var l=+new Date,o,a;if((n.lastOp==r||n.lastOrigin==t.origin&&t.origin&&(t.origin.charAt(0)=="+"&&n.lastModTime>l-(e.cm?e.cm.options.historyEventDelay:500)||t.origin.charAt(0)=="*"))&&(o=vs(n,n.lastOp==r)))a=W(o.changes),M(t.from,t.to)==0&&M(t.from,a.to)==0?a.to=Qe(t):o.changes.push(dn(e,t));else{var s=W(n.done);for((!s||!s.ranges)&&ei(e.sel,n.done),o={changes:[dn(e,t)],generation:n.generation},n.done.push(o);n.done.length>n.undoDepth;)n.done.shift(),n.done[0].ranges||n.done.shift()}n.done.push(i),n.generation=++n.maxGeneration,n.lastModTime=n.lastSelTime=l,n.lastOp=n.lastSelOp=r,n.lastOrigin=n.lastSelOrigin=t.origin,a||G(e,"historyAdded")}function gs(e,t,i,r){var n=t.charAt(0);return n=="*"||n=="+"&&i.ranges.length==r.ranges.length&&i.somethingSelected()==r.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}function ys(e,t,i,r){var n=e.history,l=r&&r.origin;i==n.lastSelOp||l&&n.lastSelOrigin==l&&(n.lastModTime==n.lastSelTime&&n.lastOrigin==l||gs(e,l,W(n.done),t))?n.done[n.done.length-1]=t:ei(t,n.done),n.lastSelTime=+new Date,n.lastSelOrigin=l,n.lastSelOp=i,r&&r.clearRedo!==!1&&Zl(n.undone)}function ei(e,t){var i=W(t);i&&i.ranges&&i.equals(e)||t.push(e)}function Jl(e,t,i,r){var n=t["spans_"+e.id],l=0;e.iter(Math.max(e.first,i),Math.min(e.first+e.size,r),function(o){o.markedSpans&&((n||(n=t["spans_"+e.id]={}))[l]=o.markedSpans),++l})}function ms(e){if(!e)return null;for(var t,i=0;i<e.length;++i)e[i].marker.explicitlyCleared?t||(t=e.slice(0,i)):t&&t.push(e[i]);return t?t.length?t:null:e}function bs(e,t){var i=t["spans_"+e.id];if(!i)return null;for(var r=[],n=0;n<t.text.length;++n)r.push(ms(i[n]));return r}function jl(e,t){var i=bs(e,t),r=Ei(e,t);if(!i)return r;if(!r)return i;for(var n=0;n<i.length;++n){var l=i[n],o=r[n];if(l&&o){e:for(var a=0;a<o.length;++a){for(var s=o[a],u=0;u<l.length;++u)if(l[u].marker==s.marker)continue e;l.push(s)}}else o&&(i[n]=o)}return i}function Ot(e,t,i){for(var r=[],n=0;n<e.length;++n){var l=e[n];if(l.ranges){r.push(i?ge.prototype.deepCopy.call(l):l);continue}var o=l.changes,a=[];r.push({changes:a});for(var s=0;s<o.length;++s){var u=o[s],f=void 0;if(a.push({from:u.from,to:u.to,text:u.text}),t)for(var h in u)(f=h.match(/^spans_(\d+)$/))&&$(t,Number(f[1]))>-1&&(W(a)[h]=u[h],delete u[h])}}return r}function pn(e,t,i,r){if(r){var n=e.anchor;if(i){var l=M(t,n)<0;l!=M(i,n)<0?(n=t,t=i):l!=M(t,i)<0&&(t=i)}return new O(n,t)}else return new O(i||t,t)}function ti(e,t,i,r,n){n==null&&(n=e.cm&&(e.cm.display.shift||e.extend)),ee(e,new ge([pn(e.sel.primary(),t,i,n)],0),r)}function Vl(e,t,i){for(var r=[],n=e.cm&&(e.cm.display.shift||e.extend),l=0;l<e.sel.ranges.length;l++)r[l]=pn(e.sel.ranges[l],t[l],null,n);var o=ke(e.cm,r,e.sel.primIndex);ee(e,o,i)}function vn(e,t,i,r){var n=e.sel.ranges.slice(0);n[t]=i,ee(e,ke(e.cm,n,e.sel.primIndex),r)}function $l(e,t,i,r){ee(e,Ze(t,i),r)}function xs(e,t,i){var r={ranges:t.ranges,update:function(n){this.ranges=[];for(var l=0;l<n.length;l++)this.ranges[l]=new O(D(e,n[l].anchor),D(e,n[l].head))},origin:i&&i.origin};return G(e,"beforeSelectionChange",e,r),e.cm&&G(e.cm,"beforeSelectionChange",e.cm,r),r.ranges!=t.ranges?ke(e.cm,r.ranges,r.ranges.length-1):t}function eo(e,t,i){var r=e.history.done,n=W(r);n&&n.ranges?(r[r.length-1]=t,ri(e,t,i)):ee(e,t,i)}function ee(e,t,i){ri(e,t,i),ys(e,e.sel,e.cm?e.cm.curOp.id:NaN,i)}function ri(e,t,i){(xe(e,"beforeSelectionChange")||e.cm&&xe(e.cm,"beforeSelectionChange"))&&(t=xs(e,t,i));var r=i&&i.bias||(M(t.primary().head,e.sel.primary().head)<0?-1:1);to(e,io(e,t,r,!0)),!(i&&i.scroll===!1)&&e.cm&&e.cm.getOption("readOnly")!="nocursor"&&Nt(e.cm)}function to(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=1,e.cm.curOp.selectionChanged=!0,Bn(e.cm)),q(e,"cursorActivity",e))}function ro(e){to(e,io(e,e.sel,null,!1))}function io(e,t,i,r){for(var n,l=0;l<t.ranges.length;l++){var o=t.ranges[l],a=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[l],s=ii(e,o.anchor,a&&a.anchor,i,r),u=o.head==o.anchor?s:ii(e,o.head,a&&a.head,i,r);(n||s!=o.anchor||u!=o.head)&&(n||(n=t.ranges.slice(0,l)),n[l]=new O(s,u))}return n?ke(e.cm,n,t.primIndex):t}function Wt(e,t,i,r,n){var l=w(e,t.line);if(l.markedSpans)for(var o=0;o<l.markedSpans.length;++o){var a=l.markedSpans[o],s=a.marker,u="selectLeft"in s?!s.selectLeft:s.inclusiveLeft,f="selectRight"in s?!s.selectRight:s.inclusiveRight;if((a.from==null||(u?a.from<=t.ch:a.from<t.ch))&&(a.to==null||(f?a.to>=t.ch:a.to>t.ch))){if(n&&(G(s,"beforeCursorEnter"),s.explicitlyCleared))if(l.markedSpans){--o;continue}else break;if(!s.atomic)continue;if(i){var h=s.find(r<0?1:-1),d=void 0;if((r<0?f:u)&&(h=no(e,h,-r,h&&h.line==t.line?l:null)),h&&h.line==t.line&&(d=M(h,i))&&(r<0?d<0:d>0))return Wt(e,h,t,r,n)}var c=s.find(r<0?-1:1);return(r<0?u:f)&&(c=no(e,c,r,c.line==t.line?l:null)),c?Wt(e,c,t,r,n):null}}return t}function ii(e,t,i,r,n){var l=r||1,o=Wt(e,t,i,l,n)||!n&&Wt(e,t,i,l,!0)||Wt(e,t,i,-l,n)||!n&&Wt(e,t,i,-l,!0);return o||(e.cantEdit=!0,g(e.first,0))}function no(e,t,i,r){return i<0&&t.ch==0?t.line>e.first?D(e,g(t.line-1)):null:i>0&&t.ch==(r||w(e,t.line)).text.length?t.line<e.first+e.size-1?g(t.line+1,0):null:new g(t.line,t.ch+i)}function lo(e){e.setSelection(g(e.firstLine(),0),g(e.lastLine()),Me)}function oo(e,t,i){var r={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){return r.canceled=!0}};return i&&(r.update=function(n,l,o,a){n&&(r.from=D(e,n)),l&&(r.to=D(e,l)),o&&(r.text=o),a!==void 0&&(r.origin=a)}),G(e,"beforeChange",e,r),e.cm&&G(e.cm,"beforeChange",e.cm,r),r.canceled?(e.cm&&(e.cm.curOp.updateInput=2),null):{from:r.from,to:r.to,text:r.text,origin:r.origin}}function Ht(e,t,i){if(e.cm){if(!e.cm.curOp)return Z(e.cm,Ht)(e,t,i);if(e.cm.state.suppressEdits)return}if(!((xe(e,"beforeChange")||e.cm&&xe(e.cm,"beforeChange"))&&(t=oo(e,t,!0),!t))){var r=jn&&!i&&ya(e,t.from,t.to);if(r)for(var n=r.length-1;n>=0;--n)ao(e,{from:r[n].from,to:r[n].to,text:n?[""]:t.text,origin:t.origin});else ao(e,t)}}function ao(e,t){if(!(t.text.length==1&&t.text[0]==""&&M(t.from,t.to)==0)){var i=fn(e,t);Ql(e,t,i,e.cm?e.cm.curOp.id:NaN),hr(e,t,i,Ei(e,t));var r=[];Je(e,function(n,l){!l&&$(r,n.history)==-1&&(ho(n.history,t),r.push(n.history)),hr(n,t,null,Ei(n,t))})}}function ni(e,t,i){var r=e.cm&&e.cm.state.suppressEdits;if(!(r&&!i)){for(var n=e.history,l,o=e.sel,a=t=="undo"?n.done:n.undone,s=t=="undo"?n.undone:n.done,u=0;u<a.length&&(l=a[u],!(i?l.ranges&&!l.equals(e.sel):!l.ranges));u++);if(u!=a.length){for(n.lastOrigin=n.lastSelOrigin=null;;)if(l=a.pop(),l.ranges){if(ei(l,s),i&&!l.equals(e.sel)){ee(e,l,{clearRedo:!1});return}o=l}else if(r){a.push(l);return}else break;var f=[];ei(o,s),s.push({changes:f,generation:n.generation}),n.generation=l.generation||++n.maxGeneration;for(var h=xe(e,"beforeChange")||e.cm&&xe(e.cm,"beforeChange"),d=function(v){var y=l.changes[v];if(y.origin=t,h&&!oo(e,y,!1))return a.length=0,{};f.push(dn(e,y));var m=v?fn(e,y):W(a);hr(e,y,m,jl(e,y)),!v&&e.cm&&e.cm.scrollIntoView({from:y.from,to:Qe(y)});var x=[];Je(e,function(b,C){!C&&$(x,b.history)==-1&&(ho(b.history,y),x.push(b.history)),hr(b,y,null,jl(b,y))})},c=l.changes.length-1;c>=0;--c){var p=d(c);if(p)return p.v}}}}function so(e,t){if(t!=0&&(e.first+=t,e.sel=new ge(Or(e.sel.ranges,function(n){return new O(g(n.anchor.line+t,n.anchor.ch),g(n.head.line+t,n.head.ch))}),e.sel.primIndex),e.cm)){ae(e.cm,e.first,e.first-t,t);for(var i=e.cm.display,r=i.viewFrom;r<i.viewTo;r++)Ye(e.cm,r,"gutter")}}function hr(e,t,i,r){if(e.cm&&!e.cm.curOp)return Z(e.cm,hr)(e,t,i,r);if(t.to.line<e.first){so(e,t.text.length-1-(t.to.line-t.from.line));return}if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var n=t.text.length-1-(e.first-t.from.line);so(e,n),t={from:g(e.first,0),to:g(t.to.line+n,t.to.ch),text:[W(t.text)],origin:t.origin}}var l=e.lastLine();t.to.line>l&&(t={from:t.from,to:g(l,w(e,l).text.length),text:[t.text[0]],origin:t.origin}),t.removed=ot(e,t.from,t.to),i||(i=fn(e,t)),e.cm?Cs(e.cm,t,r):cn(e,t,r),ri(e,i,Me),e.cantEdit&&ii(e,g(e.firstLine(),0))&&(e.cantEdit=!1)}}function Cs(e,t,i){var r=e.doc,n=e.display,l=t.from,o=t.to,a=!1,s=l.line;e.options.lineWrapping||(s=H(Se(w(r,l.line))),r.iter(s,o.line+1,function(c){if(c==n.maxLine)return a=!0,!0})),r.sel.contains(t.from,t.to)>-1&&Bn(e),cn(r,t,i,Ml(e)),e.options.lineWrapping||(r.iter(s,l.line+t.text.length,function(c){var p=Gr(c);p>n.maxLineLength&&(n.maxLine=c,n.maxLineLength=p,n.maxLineChanged=!0,a=!1)}),a&&(e.curOp.updateMaxLine=!0)),fa(r,l.line),sr(e,400);var u=t.text.length-(o.line-l.line)-1;t.full?ae(e):l.line==o.line&&t.text.length==1&&!Xl(e.doc,t)?Ye(e,l.line,"text"):ae(e,l.line,o.line+1,u);var f=xe(e,"changes"),h=xe(e,"change");if(h||f){var d={from:l,to:o,text:t.text,removed:t.removed,origin:t.origin};h&&q(e,"change",e,d),f&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(d)}e.display.selForContextMenu=null}function Ft(e,t,i,r,n){var l;r||(r=i),M(r,i)<0&&(l=[r,i],i=l[0],r=l[1]),typeof t=="string"&&(t=e.splitLines(t)),Ht(e,{from:i,to:r,text:t,origin:n})}function uo(e,t,i,r){i<e.line?e.line+=r:t<e.line&&(e.line=t,e.ch=0)}function fo(e,t,i,r){for(var n=0;n<e.length;++n){var l=e[n],o=!0;if(l.ranges){l.copied||(l=e[n]=l.deepCopy(),l.copied=!0);for(var a=0;a<l.ranges.length;a++)uo(l.ranges[a].anchor,t,i,r),uo(l.ranges[a].head,t,i,r);continue}for(var s=0;s<l.changes.length;++s){var u=l.changes[s];if(i<u.from.line)u.from=g(u.from.line+r,u.from.ch),u.to=g(u.to.line+r,u.to.ch);else if(t<=u.to.line){o=!1;break}}o||(e.splice(0,n+1),n=0)}}function ho(e,t){var i=t.from.line,r=t.to.line,n=t.text.length-(r-i)-1;fo(e.done,i,r,n),fo(e.undone,i,r,n)}function cr(e,t,i,r){var n=t,l=t;return typeof t=="number"?l=w(e,Un(e,t)):n=H(t),n==null?null:(r(l,n)&&e.cm&&Ye(e.cm,n,i),l)}function dr(e){this.lines=e,this.parent=null;for(var t=0,i=0;i<e.length;++i)e[i].parent=this,t+=e[i].height;this.height=t}dr.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var i=e,r=e+t;i<r;++i){var n=this.lines[i];this.height-=n.height,wa(n),q(n,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,i){this.height+=i,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var r=0;r<t.length;++r)t[r].parent=this},iterN:function(e,t,i){for(var r=e+t;e<r;++e)if(i(this.lines[e]))return!0}};function pr(e){this.children=e;for(var t=0,i=0,r=0;r<e.length;++r){var n=e[r];t+=n.chunkSize(),i+=n.height,n.parent=this}this.size=t,this.height=i,this.parent=null}pr.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){this.size-=t;for(var i=0;i<this.children.length;++i){var r=this.children[i],n=r.chunkSize();if(e<n){var l=Math.min(t,n-e),o=r.height;if(r.removeInner(e,l),this.height-=o-r.height,n==l&&(this.children.splice(i--,1),r.parent=null),(t-=l)==0)break;e=0}else e-=n}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof dr))){var a=[];this.collapse(a),this.children=[new dr(a)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t<this.children.length;++t)this.children[t].collapse(e)},insertInner:function(e,t,i){this.size+=t.length,this.height+=i;for(var r=0;r<this.children.length;++r){var n=this.children[r],l=n.chunkSize();if(e<=l){if(n.insertInner(e,t,i),n.lines&&n.lines.length>50){for(var o=n.lines.length%25+25,a=o;a<n.lines.length;){var s=new dr(n.lines.slice(a,a+=25));n.height-=s.height,this.children.splice(++r,0,s),s.parent=this}n.lines=n.lines.slice(0,o),this.maybeSpill()}break}e-=l}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=e.children.splice(e.children.length-5,5),i=new pr(t);if(e.parent){e.size-=i.size,e.height-=i.height;var n=$(e.parent.children,e);e.parent.children.splice(n+1,0,i)}else{var r=new pr(e.children);r.parent=e,e.children=[r,i],e=r}i.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,i){for(var r=0;r<this.children.length;++r){var n=this.children[r],l=n.chunkSize();if(e<l){var o=Math.min(t,l-e);if(n.iterN(e,o,i))return!0;if((t-=o)==0)break;e=0}else e-=l}}};var vr=function(e,t,i){if(i)for(var r in i)i.hasOwnProperty(r)&&(this[r]=i[r]);this.doc=e,this.node=t};vr.prototype.clear=function(){var e=this.doc.cm,t=this.line.widgets,i=this.line,r=H(i);if(!(r==null||!t)){for(var n=0;n<t.length;++n)t[n]==this&&t.splice(n--,1);t.length||(i.widgets=null);var l=tr(this);De(i,Math.max(0,i.height-l)),e&&(ce(e,function(){co(e,i,-l),Ye(e,r,"widget")}),q(e,"lineWidgetCleared",e,this,r))}},vr.prototype.changed=function(){var e=this,t=this.height,i=this.doc.cm,r=this.line;this.height=null;var n=tr(this)-t;n&&(Xe(this.doc,r)||De(r,r.height+n),i&&ce(i,function(){i.curOp.forceUpdate=!0,co(i,r,n),q(i,"lineWidgetChanged",i,e,H(r))}))},xt(vr);function co(e,t,i){Ee(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&nn(e,i)}function ws(e,t,i,r){var n=new vr(e,i,r),l=e.cm;return l&&n.noHScroll&&(l.display.alignWidgets=!0),cr(e,t,"widget",function(o){var a=o.widgets||(o.widgets=[]);if(n.insertAt==null?a.push(n):a.splice(Math.min(a.length,Math.max(0,n.insertAt)),0,n),n.line=o,l&&!Xe(e,o)){var s=Ee(o)<e.scrollTop;De(o,o.height+tr(n)),s&&nn(l,n.height),l.curOp.forceUpdate=!0}return!0}),l&&q(l,"lineWidgetAdded",l,n,typeof t=="number"?t:H(t)),n}var po=0,je=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++po};je.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&pt(e),xe(this,"clear")){var i=this.find();i&&q(this,"clear",i.from,i.to)}for(var r=null,n=null,l=0;l<this.lines.length;++l){var o=this.lines[l],a=Vt(o.markedSpans,this);e&&!this.collapsed?Ye(e,H(o),"text"):e&&(a.to!=null&&(n=H(o)),a.from!=null&&(r=H(o))),o.markedSpans=da(o.markedSpans,a),a.from==null&&this.collapsed&&!Xe(this.doc,o)&&e&&De(o,Tt(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var s=0;s<this.lines.length;++s){var u=Se(this.lines[s]),f=Gr(u);f>e.display.maxLineLength&&(e.display.maxLine=u,e.display.maxLineLength=f,e.display.maxLineChanged=!0)}r!=null&&e&&this.collapsed&&ae(e,r,n+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&ro(e.doc)),e&&q(e,"markerCleared",e,this,r,n),t&&vt(e),this.parent&&this.parent.clear()}},je.prototype.find=function(e,t){e==null&&this.type=="bookmark"&&(e=1);for(var i,r,n=0;n<this.lines.length;++n){var l=this.lines[n],o=Vt(l.markedSpans,this);if(o.from!=null&&(i=g(t?l:H(l),o.from),e==-1))return i;if(o.to!=null&&(r=g(t?l:H(l),o.to),e==1))return r}return i&&{from:i,to:r}},je.prototype.changed=function(){var e=this,t=this.find(-1,!0),i=this,r=this.doc.cm;!t||!r||ce(r,function(){var n=t.line,l=H(t.line),o=_i(r,l);if(o&&(bl(o),r.curOp.selectionChanged=r.curOp.forceUpdate=!0),r.curOp.updateMaxLine=!0,!Xe(i.doc,n)&&i.height!=null){var a=i.height;i.height=null;var s=tr(i)-a;s&&De(n,n.height+s)}q(r,"markerChanged",r,e)})},je.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(!t.maybeHiddenMarkers||$(t.maybeHiddenMarkers,this)==-1)&&(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},je.prototype.detachLine=function(e){if(this.lines.splice($(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}},xt(je);function Pt(e,t,i,r,n){if(r&&r.shared)return Ss(e,t,i,r,n);if(e.cm&&!e.cm.curOp)return Z(e.cm,Pt)(e,t,i,r,n);var l=new je(e,n),o=M(t,i);if(r&&nt(r,l,!1),o>0||o==0&&l.clearWhenEmpty!==!1)return l;if(l.replacedWith&&(l.collapsed=!0,l.widgetNode=bt("span",[l.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||l.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(l.widgetNode.insertLeft=!0)),l.collapsed){if(il(e,t.line,t,i,l)||t.line!=i.line&&il(e,i.line,t,i,l))throw new Error("Inserting collapsed marker partially overlapping an existing one");ca()}l.addToHistory&&Ql(e,{from:t,to:i,origin:"markText"},e.sel,NaN);var a=t.line,s=e.cm,u;if(e.iter(a,i.line+1,function(h){s&&l.collapsed&&!s.options.lineWrapping&&Se(h)==s.display.maxLine&&(u=!0),l.collapsed&&a!=t.line&&De(h,0),pa(h,new Ir(l,a==t.line?t.ch:null,a==i.line?i.ch:null),e.cm&&e.cm.curOp),++a}),l.collapsed&&e.iter(t.line,i.line+1,function(h){Xe(e,h)&&De(h,0)}),l.clearOnEnter&&T(l,"beforeCursorEnter",function(){return l.clear()}),l.readOnly&&(ha(),(e.history.done.length||e.history.undone.length)&&e.clearHistory()),l.collapsed&&(l.id=++po,l.atomic=!0),s){if(u&&(s.curOp.updateMaxLine=!0),l.collapsed)ae(s,t.line,i.line+1);else if(l.className||l.startStyle||l.endStyle||l.css||l.attributes||l.title)for(var f=t.line;f<=i.line;f++)Ye(s,f,"text");l.atomic&&ro(s.doc),q(s,"markerAdded",s,l)}return l}var gr=function(e,t){this.markers=e,this.primary=t;for(var i=0;i<e.length;++i)e[i].parent=this};gr.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();q(this,"clear")}},gr.prototype.find=function(e,t){return this.primary.find(e,t)},xt(gr);function Ss(e,t,i,r,n){r=nt(r),r.shared=!1;var l=[Pt(e,t,i,r,n)],o=l[0],a=r.widgetNode;return Je(e,function(s){a&&(r.widgetNode=a.cloneNode(!0)),l.push(Pt(s,D(s,t),D(s,i),r,n));for(var u=0;u<s.linked.length;++u)if(s.linked[u].isParent)return;o=W(l)}),new gr(l,o)}function vo(e){return e.findMarks(g(e.first,0),e.clipPos(g(e.lastLine())),function(t){return t.parent})}function Ls(e,t){for(var i=0;i<t.length;i++){var r=t[i],n=r.find(),l=e.clipPos(n.from),o=e.clipPos(n.to);if(M(l,o)){var a=Pt(e,l,o,r.primary,r.primary.type);r.markers.push(a),a.parent=r}}}function ks(e){for(var t=function(r){var n=e[r],l=[n.primary.doc];Je(n.primary.doc,function(s){return l.push(s)});for(var o=0;o<n.markers.length;o++){var a=n.markers[o];$(l,a.doc)==-1&&(a.parent=null,n.markers.splice(o--,1))}},i=0;i<e.length;i++)t(i)}var Ts=0,se=function(e,t,i,r,n){if(!(this instanceof se))return new se(e,t,i,r,n);i==null&&(i=0),pr.call(this,[new dr([new St("",null)])]),this.first=i,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=i;var l=g(i,0);this.sel=Ze(l),this.history=new $r(null),this.id=++Ts,this.modeOption=t,this.lineSep=r,this.direction=n=="rtl"?"rtl":"ltr",this.extend=!1,typeof e=="string"&&(e=this.splitLines(e)),cn(this,{from:l,to:l,text:e}),ee(this,Ze(l),Me)};se.prototype=Fn(pr.prototype,{constructor:se,iter:function(e,t,i){i?this.iterN(e-this.first,t-e,i):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var i=0,r=0;r<t.length;++r)i+=t[r].height;this.insertInner(e-this.first,t,i)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=Ai(this,this.first,this.first+this.size);return e===!1?t:t.join(e||this.lineSeparator())},setValue:Q(function(e){var t=g(this.first,0),i=this.first+this.size-1;Ht(this,{from:t,to:g(i,w(this,i).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&nr(this.cm,0,0),ee(this,Ze(t),Me)}),replaceRange:function(e,t,i,r){t=D(this,t),i=i?D(this,i):t,Ft(this,e,t,i,r)},getRange:function(e,t,i){var r=ot(this,D(this,e),D(this,t));return i===!1?r:i===""?r.join(""):r.join(i||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){if(Jt(this,e))return w(this,e)},getLineNumber:function(e){return H(e)},getLineHandleVisualStart:function(e){return typeof e=="number"&&(e=w(this,e)),Se(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return D(this,e)},getCursor:function(e){var t=this.sel.primary(),i;return e==null||e=="head"?i=t.head:e=="anchor"?i=t.anchor:e=="end"||e=="to"||e===!1?i=t.to():i=t.from(),i},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:Q(function(e,t,i){$l(this,D(this,typeof e=="number"?g(e,t||0):e),null,i)}),setSelection:Q(function(e,t,i){$l(this,D(this,e),D(this,t||e),i)}),extendSelection:Q(function(e,t,i){ti(this,D(this,e),t&&D(this,t),i)}),extendSelections:Q(function(e,t){Vl(this,Kn(this,e),t)}),extendSelectionsBy:Q(function(e,t){var i=Or(this.sel.ranges,e);Vl(this,Kn(this,i),t)}),setSelections:Q(function(e,t,i){if(e.length){for(var r=[],n=0;n<e.length;n++)r[n]=new O(D(this,e[n].anchor),D(this,e[n].head||e[n].anchor));t==null&&(t=Math.min(e.length-1,this.sel.primIndex)),ee(this,ke(this.cm,r,t),i)}}),addSelection:Q(function(e,t,i){var r=this.sel.ranges.slice(0);r.push(new O(D(this,e),D(this,t||e))),ee(this,ke(this.cm,r,r.length-1),i)}),getSelection:function(e){for(var t=this.sel.ranges,i,r=0;r<t.length;r++){var n=ot(this,t[r].from(),t[r].to());i=i?i.concat(n):n}return e===!1?i:i.join(e||this.lineSeparator())},getSelections:function(e){for(var t=[],i=this.sel.ranges,r=0;r<i.length;r++){var n=ot(this,i[r].from(),i[r].to());e!==!1&&(n=n.join(e||this.lineSeparator())),t[r]=n}return t},replaceSelection:function(e,t,i){for(var r=[],n=0;n<this.sel.ranges.length;n++)r[n]=e;this.replaceSelections(r,t,i||"+input")},replaceSelections:Q(function(e,t,i){for(var r=[],n=this.sel,l=0;l<n.ranges.length;l++){var o=n.ranges[l];r[l]={from:o.from(),to:o.to(),text:this.splitLines(e[l]),origin:i}}for(var a=t&&t!="end"&&ds(this,r,t),s=r.length-1;s>=0;s--)Ht(this,r[s]);a?eo(this,a):this.cm&&Nt(this.cm)}),undo:Q(function(){ni(this,"undo")}),redo:Q(function(){ni(this,"redo")}),undoSelection:Q(function(){ni(this,"undo",!0)}),redoSelection:Q(function(){ni(this,"redo",!0)}),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,i=0,r=0;r<e.done.length;r++)e.done[r].ranges||++t;for(var n=0;n<e.undone.length;n++)e.undone[n].ranges||++i;return{undo:t,redo:i}},clearHistory:function(){var e=this;this.history=new $r(this.history),Je(this,function(t){return t.history=e.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:Ot(this.history.done),undone:Ot(this.history.undone)}},setHistory:function(e){var t=this.history=new $r(this.history);t.done=Ot(e.done.slice(0),null,!0),t.undone=Ot(e.undone.slice(0),null,!0)},setGutterMarker:Q(function(e,t,i){return cr(this,e,"gutter",function(r){var n=r.gutterMarkers||(r.gutterMarkers={});return n[t]=i,!i&&Pn(n)&&(r.gutterMarkers=null),!0})}),clearGutter:Q(function(e){var t=this;this.iter(function(i){i.gutterMarkers&&i.gutterMarkers[e]&&cr(t,i,"gutter",function(){return i.gutterMarkers[e]=null,Pn(i.gutterMarkers)&&(i.gutterMarkers=null),!0})})}),lineInfo:function(e){var t;if(typeof e=="number"){if(!Jt(this,e)||(t=e,e=w(this,e),!e))return null}else if(t=H(e),t==null)return null;return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:Q(function(e,t,i){return cr(this,e,t=="gutter"?"gutter":"class",function(r){var n=t=="text"?"textClass":t=="background"?"bgClass":t=="gutter"?"gutterClass":"wrapClass";if(!r[n])r[n]=i;else{if(mt(i).test(r[n]))return!1;r[n]+=" "+i}return!0})}),removeLineClass:Q(function(e,t,i){return cr(this,e,t=="gutter"?"gutter":"class",function(r){var n=t=="text"?"textClass":t=="background"?"bgClass":t=="gutter"?"gutterClass":"wrapClass",l=r[n];if(l)if(i==null)r[n]=null;else{var o=l.match(mt(i));if(!o)return!1;var a=o.index+o[0].length;r[n]=l.slice(0,o.index)+(!o.index||a==l.length?"":" ")+l.slice(a)||null}else return!1;return!0})}),addLineWidget:Q(function(e,t,i){return ws(this,e,t,i)}),removeLineWidget:function(e){e.clear()},markText:function(e,t,i){return Pt(this,D(this,e),D(this,t),i,i&&i.type||"range")},setBookmark:function(e,t){var i={replacedWith:t&&(t.nodeType==null?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return e=D(this,e),Pt(this,e,e,i,"bookmark")},findMarksAt:function(e){e=D(this,e);var t=[],i=w(this,e.line).markedSpans;if(i)for(var r=0;r<i.length;++r){var n=i[r];(n.from==null||n.from<=e.ch)&&(n.to==null||n.to>=e.ch)&&t.push(n.marker.parent||n.marker)}return t},findMarks:function(e,t,i){e=D(this,e),t=D(this,t);var r=[],n=e.line;return this.iter(e.line,t.line+1,function(l){var o=l.markedSpans;if(o)for(var a=0;a<o.length;a++){var s=o[a];!(s.to!=null&&n==e.line&&e.ch>=s.to||s.from==null&&n!=e.line||s.from!=null&&n==t.line&&s.from>=t.ch)&&(!i||i(s.marker))&&r.push(s.marker.parent||s.marker)}++n}),r},getAllMarks:function(){var e=[];return this.iter(function(t){var i=t.markedSpans;if(i)for(var r=0;r<i.length;++r)i[r].from!=null&&e.push(i[r].marker)}),e},posFromIndex:function(e){var t,i=this.first,r=this.lineSeparator().length;return this.iter(function(n){var l=n.text.length+r;if(l>e)return t=e,!0;e-=l,++i}),D(this,g(i,t))},indexFromPos:function(e){e=D(this,e);var t=e.ch;if(e.line<this.first||e.ch<0)return 0;var i=this.lineSeparator().length;return this.iter(this.first,e.line,function(r){t+=r.text.length+i}),t},copy:function(e){var t=new se(Ai(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,i=this.first+this.size;e.from!=null&&e.from>t&&(t=e.from),e.to!=null&&e.to<i&&(i=e.to);var r=new se(Ai(this,t,i),e.mode||this.modeOption,t,this.lineSep,this.direction);return e.sharedHist&&(r.history=this.history),(this.linked||(this.linked=[])).push({doc:r,sharedHist:e.sharedHist}),r.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],Ls(r,vo(this)),r},unlinkDoc:function(e){if(e instanceof I&&(e=e.doc),this.linked)for(var t=0;t<this.linked.length;++t){var i=this.linked[t];if(i.doc==e){this.linked.splice(t,1),e.unlinkDoc(this),ks(vo(this));break}}if(e.history==this.history){var r=[e.id];Je(e,function(n){return r.push(n.id)},!0),e.history=new $r(null),e.history.done=Ot(this.history.done,r),e.history.undone=Ot(this.history.undone,r)}},iterLinkedDocs:function(e){Je(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):ki(e)},lineSeparator:function(){return this.lineSep||`
|
|
10
|
+
left: `+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(o),o.scrollIntoView(n),e.display.lineSpace.removeChild(o)}}}function Ja(e,t,i,r){r==null&&(r=0);var n;!e.options.lineWrapping&&t==i&&(i=t.sticky=="before"?g(t.line,t.ch+1,"before"):t,t=t.ch?g(t.line,t.sticky=="before"?t.ch-1:t.ch,"after"):t);for(var l=0;l<5;l++){var o=!1,a=Le(e,t),s=!i||i==t?a:Le(e,i);n={left:Math.min(a.left,s.left),top:Math.min(a.top,s.top)-r,right:Math.max(a.left,s.left),bottom:Math.max(a.bottom,s.bottom)+r};var u=rn(e,n),f=e.doc.scrollTop,h=e.doc.scrollLeft;if(u.scrollTop!=null&&(lr(e,u.scrollTop),Math.abs(e.doc.scrollTop-f)>1&&(o=!0)),u.scrollLeft!=null&&(ct(e,u.scrollLeft),Math.abs(e.doc.scrollLeft-h)>1&&(o=!0)),!o)break}return n}function ja(e,t){var i=rn(e,t);i.scrollTop!=null&&lr(e,i.scrollTop),i.scrollLeft!=null&&ct(e,i.scrollLeft)}function rn(e,t){var i=e.display,r=Tt(e.display);t.top<0&&(t.top=0);var n=e.curOp&&e.curOp.scrollTop!=null?e.curOp.scrollTop:i.scroller.scrollTop,l=Ki(e),o={};t.bottom-t.top>l&&(t.bottom=t.top+l);var a=e.doc.height+Ui(i),s=t.top<r,u=t.bottom>a-r;if(t.top<n)o.scrollTop=s?0:t.top;else if(t.bottom>n+l){var f=Math.min(t.top,(u?a:t.bottom)-l);f!=n&&(o.scrollTop=f)}var h=e.options.fixedGutter?0:i.gutters.offsetWidth,d=e.curOp&&e.curOp.scrollLeft!=null?e.curOp.scrollLeft:i.scroller.scrollLeft-h,c=st(e)-i.gutters.offsetWidth,p=t.right-t.left>c;return p&&(t.right=t.left+c),t.left<10?o.scrollLeft=0:t.left<d?o.scrollLeft=Math.max(0,t.left+h-(p?0:10)):t.right>c+d-3&&(o.scrollLeft=t.right+(p?0:10)-c),o}function nn(e,t){t!=null&&(Jr(e),e.curOp.scrollTop=(e.curOp.scrollTop==null?e.doc.scrollTop:e.curOp.scrollTop)+t)}function Nt(e){Jr(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function nr(e,t,i){(t!=null||i!=null)&&Jr(e),t!=null&&(e.curOp.scrollLeft=t),i!=null&&(e.curOp.scrollTop=i)}function Va(e,t){Jr(e),e.curOp.scrollToPos=t}function Jr(e){var t=e.curOp.scrollToPos;if(t){e.curOp.scrollToPos=null;var i=Ll(e,t.from),r=Ll(e,t.to);Wl(e,i,r,t.margin)}}function Wl(e,t,i,r){var n=rn(e,{left:Math.min(t.left,i.left),top:Math.min(t.top,i.top)-r,right:Math.max(t.right,i.right),bottom:Math.max(t.bottom,i.bottom)+r});nr(e,n.scrollLeft,n.scrollTop)}function lr(e,t){Math.abs(e.doc.scrollTop-t)<2||(He||on(e,{top:t}),Hl(e,t,!0),He&&on(e),sr(e,100))}function Hl(e,t,i){t=Math.max(0,Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t)),!(e.display.scroller.scrollTop==t&&!i)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function ct(e,t,i,r){t=Math.max(0,Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth)),!((i?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!r)&&(e.doc.scrollLeft=t,Bl(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function or(e){var t=e.display,i=t.gutters.offsetWidth,r=Math.round(e.doc.height+Ui(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?i:0,docHeight:r,scrollHeight:r+Ae(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:i}}var dt=function(e,t,i){this.cm=i;var r=this.vert=k("div",[k("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),n=this.horiz=k("div",[k("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");r.tabIndex=n.tabIndex=-1,e(r),e(n),T(r,"scroll",function(){r.clientHeight&&t(r.scrollTop,"vertical")}),T(n,"scroll",function(){n.clientWidth&&t(n.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,A&&E<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};dt.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,i=e.scrollHeight>e.clientHeight+1,r=e.nativeBarWidth;if(i){this.vert.style.display="block",this.vert.style.bottom=t?r+"px":"0";var n=e.viewHeight-(t?r:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+n)+"px"}else this.vert.scrollTop=0,this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=i?r+"px":"0",this.horiz.style.left=e.barLeft+"px";var l=e.viewWidth-e.barLeft-(i?r:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+l)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(r==0&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:i?r:0,bottom:t?r:0}},dt.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},dt.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},dt.prototype.zeroWidthHack=function(){var e=ye&&!_o?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.visibility=this.vert.style.visibility="hidden",this.disableHoriz=new _e,this.disableVert=new _e},dt.prototype.enableZeroWidthBar=function(e,t,i){e.style.visibility="";function r(){var n=e.getBoundingClientRect(),l=i=="vert"?document.elementFromPoint(n.right-1,(n.top+n.bottom)/2):document.elementFromPoint((n.right+n.left)/2,n.bottom-1);l!=e?e.style.visibility="hidden":t.set(1e3,r)}t.set(1e3,r)},dt.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var ar=function(){};ar.prototype.update=function(){return{bottom:0,right:0}},ar.prototype.setScrollLeft=function(){},ar.prototype.setScrollTop=function(){},ar.prototype.clear=function(){};function At(e,t){t||(t=or(e));var i=e.display.barWidth,r=e.display.barHeight;Fl(e,t);for(var n=0;n<4&&i!=e.display.barWidth||r!=e.display.barHeight;n++)i!=e.display.barWidth&&e.options.lineWrapping&&Zr(e),Fl(e,or(e)),i=e.display.barWidth,r=e.display.barHeight}function Fl(e,t){var i=e.display,r=i.scrollbars.update(t);i.sizer.style.paddingRight=(i.barWidth=r.right)+"px",i.sizer.style.paddingBottom=(i.barHeight=r.bottom)+"px",i.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(i.scrollbarFiller.style.display="block",i.scrollbarFiller.style.height=r.bottom+"px",i.scrollbarFiller.style.width=r.right+"px"):i.scrollbarFiller.style.display="",r.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(i.gutterFiller.style.display="block",i.gutterFiller.style.height=r.bottom+"px",i.gutterFiller.style.width=t.gutterWidth+"px"):i.gutterFiller.style.display=""}var Pl={native:dt,null:ar};function El(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&tt(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new Pl[e.options.scrollbarStyle](function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),T(t,"mousedown",function(){e.state.focused&&setTimeout(function(){return e.display.input.focus()},0)}),t.setAttribute("cm-not-content","true")},function(t,i){i=="horizontal"?ct(e,t):lr(e,t)},e),e.display.scrollbars.addClass&&it(e.display.wrapper,e.display.scrollbars.addClass)}var $a=0;function pt(e){e.curOp={cm:e,viewChanged:!1,startHeight:e.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:++$a,markArrays:null},Aa(e.curOp)}function vt(e){var t=e.curOp;t&&Wa(t,function(i){for(var r=0;r<i.ops.length;r++)i.ops[r].cm.curOp=null;es(i)})}function es(e){for(var t=e.ops,i=0;i<t.length;i++)ts(t[i]);for(var r=0;r<t.length;r++)rs(t[r]);for(var n=0;n<t.length;n++)is(t[n]);for(var l=0;l<t.length;l++)ns(t[l]);for(var o=0;o<t.length;o++)ls(t[o])}function ts(e){var t=e.cm,i=t.display;as(t),e.updateMaxLine&&zi(t),e.mustUpdate=e.viewChanged||e.forceUpdate||e.scrollTop!=null||e.scrollToPos&&(e.scrollToPos.from.line<i.viewFrom||e.scrollToPos.to.line>=i.viewTo)||i.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new jr(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function rs(e){e.updatedDisplay=e.mustUpdate&&ln(e.cm,e.update)}function is(e){var t=e.cm,i=t.display;e.updatedDisplay&&Zr(t),e.barMeasure=or(t),i.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=gl(t,i.maxLine,i.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(i.scroller.clientWidth,i.sizer.offsetLeft+e.adjustWidthTo+Ae(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,i.sizer.offsetLeft+e.adjustWidthTo-st(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=i.input.prepareSelection())}function ns(e){var t=e.cm;e.adjustWidthTo!=null&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&ct(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1);var i=e.focus&&e.focus==me(we(t));e.preparedSelection&&t.display.input.showSelection(e.preparedSelection,i),(e.updatedDisplay||e.startHeight!=t.doc.height)&&At(t,e.barMeasure),e.updatedDisplay&&sn(t,e.barMeasure),e.selectionChanged&&$i(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),i&&Al(e.cm)}function ls(e){var t=e.cm,i=t.display,r=t.doc;if(e.updatedDisplay&&Il(t,e.update),i.wheelStartX!=null&&(e.scrollTop!=null||e.scrollLeft!=null||e.scrollToPos)&&(i.wheelStartX=i.wheelStartY=null),e.scrollTop!=null&&Hl(t,e.scrollTop,e.forceScroll),e.scrollLeft!=null&&ct(t,e.scrollLeft,!0,!0),e.scrollToPos){var n=Ja(t,D(r,e.scrollToPos.from),D(r,e.scrollToPos.to),e.scrollToPos.margin);Qa(t,n)}var l=e.maybeHiddenMarkers,o=e.maybeUnhiddenMarkers;if(l)for(var a=0;a<l.length;++a)l[a].lines.length||G(l[a],"hide");if(o)for(var s=0;s<o.length;++s)o[s].lines.length&&G(o[s],"unhide");i.wrapper.offsetHeight&&(r.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&G(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function ce(e,t){if(e.curOp)return t();pt(e);try{return t()}finally{vt(e)}}function Z(e,t){return function(){if(e.curOp)return t.apply(e,arguments);pt(e);try{return t.apply(e,arguments)}finally{vt(e)}}}function ne(e){return function(){if(this.curOp)return e.apply(this,arguments);pt(this);try{return e.apply(this,arguments)}finally{vt(this)}}}function Q(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);pt(t);try{return e.apply(this,arguments)}finally{vt(t)}}}function sr(e,t){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(t,pi(os,e))}function os(e){var t=e.doc;if(!(t.highlightFrontier>=e.display.viewTo)){var i=+new Date+e.options.workTime,r=jt(e,t.highlightFrontier),n=[];t.iter(r.line,Math.min(t.first+t.size,e.display.viewTo+500),function(l){if(r.line>=e.display.viewFrom){var o=l.styles,a=l.text.length>e.options.maxHighlightLength?lt(t.mode,r.state):null,s=_n(e,l,r,!0);a&&(r.state=a),l.styles=s.styles;var u=l.styleClasses,f=s.classes;f?l.styleClasses=f:u&&(l.styleClasses=null);for(var h=!o||o.length!=l.styles.length||u!=f&&(!u||!f||u.bgClass!=f.bgClass||u.textClass!=f.textClass),d=0;!h&&d<o.length;++d)h=o[d]!=l.styles[d];h&&n.push(r.line),l.stateAfter=r.save(),r.nextLine()}else l.text.length<=e.options.maxHighlightLength&&Fi(e,l.text,r),l.stateAfter=r.line%5==0?r.save():null,r.nextLine();if(+new Date>i)return sr(e,e.options.workDelay),!0}),t.highlightFrontier=r.line,t.modeFrontier=Math.max(t.modeFrontier,r.line),n.length&&ce(e,function(){for(var l=0;l<n.length;l++)Ye(e,n[l],"text")})}}var jr=function(e,t,i){var r=e.display;this.viewport=t,this.visible=Qr(r,e.doc,t),this.editorIsHidden=!r.wrapper.offsetWidth,this.wrapperHeight=r.wrapper.clientHeight,this.wrapperWidth=r.wrapper.clientWidth,this.oldDisplayWidth=st(e),this.force=i,this.dims=Qi(e),this.events=[]};jr.prototype.signal=function(e,t){xe(e,t)&&this.events.push(arguments)},jr.prototype.finish=function(){for(var e=0;e<this.events.length;e++)G.apply(null,this.events[e])};function as(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=Ae(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=Ae(e)+"px",t.scrollbarsClipped=!0)}function ss(e){if(e.hasFocus())return null;var t=me(we(e));if(!t||!Ke(e.display.lineDiv,t))return null;var i={activeElt:t};if(window.getSelection){var r=Dr(e).getSelection();r.anchorNode&&r.extend&&Ke(e.display.lineDiv,r.anchorNode)&&(i.anchorNode=r.anchorNode,i.anchorOffset=r.anchorOffset,i.focusNode=r.focusNode,i.focusOffset=r.focusOffset)}return i}function us(e){if(!(!e||!e.activeElt||e.activeElt==me(e.activeElt.ownerDocument))&&(e.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName)&&e.anchorNode&&Ke(document.body,e.anchorNode)&&Ke(document.body,e.focusNode))){var t=e.activeElt.ownerDocument,i=t.defaultView.getSelection(),r=t.createRange();r.setEnd(e.anchorNode,e.anchorOffset),r.collapse(!1),i.removeAllRanges(),i.addRange(r),i.extend(e.focusNode,e.focusOffset)}}function ln(e,t){var i=e.display,r=e.doc;if(t.editorIsHidden)return qe(e),!1;if(!t.force&&t.visible.from>=i.viewFrom&&t.visible.to<=i.viewTo&&(i.updateLineNumbers==null||i.updateLineNumbers>=i.viewTo)&&i.renderedView==i.view&&Dl(e)==0)return!1;Rl(e)&&(qe(e),t.dims=Qi(e));var n=r.first+r.size,l=Math.max(t.visible.from-e.options.viewportMargin,r.first),o=Math.min(n,t.visible.to+e.options.viewportMargin);i.viewFrom<l&&l-i.viewFrom<20&&(l=Math.max(r.first,i.viewFrom)),i.viewTo>o&&i.viewTo-o<20&&(o=Math.min(n,i.viewTo)),Pe&&(l=Bi(e.doc,l),o=nl(e.doc,o));var a=l!=i.viewFrom||o!=i.viewTo||i.lastWrapHeight!=t.wrapperHeight||i.lastWrapWidth!=t.wrapperWidth;qa(e,l,o),i.viewOffset=Ee(w(e.doc,i.viewFrom)),e.display.mover.style.top=i.viewOffset+"px";var s=Dl(e);if(!a&&s==0&&!t.force&&i.renderedView==i.view&&(i.updateLineNumbers==null||i.updateLineNumbers>=i.viewTo))return!1;var u=ss(e);return s>4&&(i.lineDiv.style.display="none"),fs(e,i.updateLineNumbers,t.dims),s>4&&(i.lineDiv.style.display=""),i.renderedView=i.view,us(u),Ue(i.cursorDiv),Ue(i.selectionDiv),i.gutters.style.height=i.sizer.style.minHeight=0,a&&(i.lastWrapHeight=t.wrapperHeight,i.lastWrapWidth=t.wrapperWidth,sr(e,400)),i.updateLineNumbers=null,!0}function Il(e,t){for(var i=t.viewport,r=!0;;r=!1){if(!r||!e.options.lineWrapping||t.oldDisplayWidth==st(e)){if(i&&i.top!=null&&(i={top:Math.min(e.doc.height+Ui(e.display)-Ki(e),i.top)}),t.visible=Qr(e.display,e.doc,i),t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)break}else r&&(t.visible=Qr(e.display,e.doc,i));if(!ln(e,t))break;Zr(e);var n=or(e);ir(e),At(e,n),sn(e,n),t.force=!1}t.signal(e,"update",e),(e.display.viewFrom!=e.display.reportedViewFrom||e.display.viewTo!=e.display.reportedViewTo)&&(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function on(e,t){var i=new jr(e,t);if(ln(e,i)){Zr(e),Il(e,i);var r=or(e);ir(e),At(e,r),sn(e,r),i.finish()}}function fs(e,t,i){var r=e.display,n=e.options.lineNumbers,l=r.lineDiv,o=l.firstChild;function a(p){var v=p.nextSibling;return ie&&ye&&e.display.currentWheelTarget==p?p.style.display="none":p.parentNode.removeChild(p),v}for(var s=r.view,u=r.viewFrom,f=0;f<s.length;f++){var h=s[f];if(!h.hidden)if(!h.node||h.node.parentNode!=l){var d=Ia(e,h,u,i);l.insertBefore(d,o)}else{for(;o!=h.node;)o=a(o);var c=n&&t!=null&&t<=u&&h.lineNumber;h.changes&&($(h.changes,"gutter")>-1&&(c=!1),ul(e,h,u,i)),c&&(Ue(h.lineNumber),h.lineNumber.appendChild(document.createTextNode(Oi(e.options,u)))),o=h.node.nextSibling}u+=h.size}for(;o;)o=a(o)}function an(e){var t=e.gutters.offsetWidth;e.sizer.style.marginLeft=t+"px",q(e,"gutterChanged",e)}function sn(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Ae(e)+"px"}function Bl(e){var t=e.display,i=t.view;if(!(!t.alignWidgets&&(!t.gutters.firstChild||!e.options.fixedGutter))){for(var r=Ji(t)-t.scroller.scrollLeft+e.doc.scrollLeft,n=t.gutters.offsetWidth,l=r+"px",o=0;o<i.length;o++)if(!i[o].hidden){e.options.fixedGutter&&(i[o].gutter&&(i[o].gutter.style.left=l),i[o].gutterBackground&&(i[o].gutterBackground.style.left=l));var a=i[o].alignable;if(a)for(var s=0;s<a.length;s++)a[s].style.left=l}e.options.fixedGutter&&(t.gutters.style.left=r+n+"px")}}function Rl(e){if(!e.options.lineNumbers)return!1;var t=e.doc,i=Oi(e.options,t.first+t.size-1),r=e.display;if(i.length!=r.lineNumChars){var n=r.measure.appendChild(k("div",[k("div",i)],"CodeMirror-linenumber CodeMirror-gutter-elt")),l=n.firstChild.offsetWidth,o=n.offsetWidth-l;return r.lineGutter.style.width="",r.lineNumInnerWidth=Math.max(l,r.lineGutter.offsetWidth-o)+1,r.lineNumWidth=r.lineNumInnerWidth+o,r.lineNumChars=r.lineNumInnerWidth?i.length:-1,r.lineGutter.style.width=r.lineNumWidth+"px",an(e.display),!0}return!1}function un(e,t){for(var i=[],r=!1,n=0;n<e.length;n++){var l=e[n],o=null;if(typeof l!="string"&&(o=l.style,l=l.className),l=="CodeMirror-linenumbers")if(t)r=!0;else continue;i.push({className:l,style:o})}return t&&!r&&i.push({className:"CodeMirror-linenumbers",style:null}),i}function zl(e){var t=e.gutters,i=e.gutterSpecs;Ue(t),e.lineGutter=null;for(var r=0;r<i.length;++r){var n=i[r],l=n.className,o=n.style,a=t.appendChild(k("div",null,"CodeMirror-gutter "+l));o&&(a.style.cssText=o),l=="CodeMirror-linenumbers"&&(e.lineGutter=a,a.style.width=(e.lineNumWidth||1)+"px")}t.style.display=i.length?"":"none",an(e)}function ur(e){zl(e.display),ae(e),Bl(e)}function hs(e,t,i,r){var n=this;this.input=i,n.scrollbarFiller=k("div",null,"CodeMirror-scrollbar-filler"),n.scrollbarFiller.setAttribute("cm-not-content","true"),n.gutterFiller=k("div",null,"CodeMirror-gutter-filler"),n.gutterFiller.setAttribute("cm-not-content","true"),n.lineDiv=bt("div",null,"CodeMirror-code"),n.selectionDiv=k("div",null,null,"position: relative; z-index: 1"),n.cursorDiv=k("div",null,"CodeMirror-cursors"),n.measure=k("div",null,"CodeMirror-measure"),n.lineMeasure=k("div",null,"CodeMirror-measure"),n.lineSpace=bt("div",[n.measure,n.lineMeasure,n.selectionDiv,n.cursorDiv,n.lineDiv],null,"position: relative; outline: none");var l=bt("div",[n.lineSpace],"CodeMirror-lines");n.mover=k("div",[l],null,"position: relative"),n.sizer=k("div",[n.mover],"CodeMirror-sizer"),n.sizerWidth=null,n.heightForcer=k("div",null,null,"position: absolute; height: "+Wn+"px; width: 1px;"),n.gutters=k("div",null,"CodeMirror-gutters"),n.lineGutter=null,n.scroller=k("div",[n.sizer,n.heightForcer,n.gutters],"CodeMirror-scroll"),n.scroller.setAttribute("tabIndex","-1"),n.wrapper=k("div",[n.scrollbarFiller,n.gutterFiller,n.scroller],"CodeMirror"),Ge&&An>=105&&(n.wrapper.style.clipPath="inset(0px)"),n.wrapper.setAttribute("translate","no"),A&&E<8&&(n.gutters.style.zIndex=-1,n.scroller.style.paddingRight=0),!ie&&!(He&&Kt)&&(n.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(n.wrapper):e(n.wrapper)),n.viewFrom=n.viewTo=t.first,n.reportedViewFrom=n.reportedViewTo=t.first,n.view=[],n.renderedView=null,n.externalMeasured=null,n.viewOffset=0,n.lastWrapHeight=n.lastWrapWidth=0,n.updateLineNumbers=null,n.nativeBarWidth=n.barHeight=n.barWidth=0,n.scrollbarsClipped=!1,n.lineNumWidth=n.lineNumInnerWidth=n.lineNumChars=null,n.alignWidgets=!1,n.cachedCharWidth=n.cachedTextHeight=n.cachedPaddingH=null,n.maxLine=null,n.maxLineLength=0,n.maxLineChanged=!1,n.wheelDX=n.wheelDY=n.wheelStartX=n.wheelStartY=null,n.shift=!1,n.selForContextMenu=null,n.activeTouch=null,n.gutterSpecs=un(r.gutters,r.lineNumbers),zl(n),i.init(n)}var Vr=0,Be=null;A?Be=-.53:He?Be=15:Ge?Be=-.7:Tr&&(Be=-1/3);function Gl(e){var t=e.wheelDeltaX,i=e.wheelDeltaY;return t==null&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),i==null&&e.detail&&e.axis==e.VERTICAL_AXIS?i=e.detail:i==null&&(i=e.wheelDelta),{x:t,y:i}}function cs(e){var t=Gl(e);return t.x*=Be,t.y*=Be,t}function Ul(e,t){Ge&&An==102&&(e.display.chromeScrollHack==null?e.display.sizer.style.pointerEvents="none":clearTimeout(e.display.chromeScrollHack),e.display.chromeScrollHack=setTimeout(function(){e.display.chromeScrollHack=null,e.display.sizer.style.pointerEvents=""},100));var i=Gl(t),r=i.x,n=i.y,l=Be;t.deltaMode===0&&(r=t.deltaX,n=t.deltaY,l=1);var o=e.display,a=o.scroller,s=a.scrollWidth>a.clientWidth,u=a.scrollHeight>a.clientHeight;if(r&&s||n&&u){if(n&&ye&&ie){e:for(var f=t.target,h=o.view;f!=a;f=f.parentNode)for(var d=0;d<h.length;d++)if(h[d].node==f){e.display.currentWheelTarget=f;break e}}if(r&&!He&&!Ce&&l!=null){n&&u&&lr(e,Math.max(0,a.scrollTop+n*l)),ct(e,Math.max(0,a.scrollLeft+r*l)),(!n||n&&u)&&oe(t),o.wheelStartX=null;return}if(n&&l!=null){var c=n*l,p=e.doc.scrollTop,v=p+o.wrapper.clientHeight;c<0?p=Math.max(0,p+c-50):v=Math.min(e.doc.height,v+c+50),on(e,{top:p,bottom:v})}Vr<20&&t.deltaMode!==0&&(o.wheelStartX==null?(o.wheelStartX=a.scrollLeft,o.wheelStartY=a.scrollTop,o.wheelDX=r,o.wheelDY=n,setTimeout(function(){if(o.wheelStartX!=null){var y=a.scrollLeft-o.wheelStartX,m=a.scrollTop-o.wheelStartY,x=m&&o.wheelDY&&m/o.wheelDY||y&&o.wheelDX&&y/o.wheelDX;o.wheelStartX=o.wheelStartY=null,x&&(Be=(Be*Vr+x)/(Vr+1),++Vr)}},200)):(o.wheelDX+=r,o.wheelDY+=n))}}var ge=function(e,t){this.ranges=e,this.primIndex=t};ge.prototype.primary=function(){return this.ranges[this.primIndex]},ge.prototype.equals=function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var t=0;t<this.ranges.length;t++){var i=this.ranges[t],r=e.ranges[t];if(!Wi(i.anchor,r.anchor)||!Wi(i.head,r.head))return!1}return!0},ge.prototype.deepCopy=function(){for(var e=[],t=0;t<this.ranges.length;t++)e[t]=new O(Hi(this.ranges[t].anchor),Hi(this.ranges[t].head));return new ge(e,this.primIndex)},ge.prototype.somethingSelected=function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},ge.prototype.contains=function(e,t){t||(t=e);for(var i=0;i<this.ranges.length;i++){var r=this.ranges[i];if(M(t,r.from())>=0&&M(e,r.to())<=0)return i}return-1};var O=function(e,t){this.anchor=e,this.head=t};O.prototype.from=function(){return Pr(this.anchor,this.head)},O.prototype.to=function(){return Fr(this.anchor,this.head)},O.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch};function ke(e,t,i){var r=e&&e.options.selectionsMayTouch,n=t[i];t.sort(function(d,c){return M(d.from(),c.from())}),i=$(t,n);for(var l=1;l<t.length;l++){var o=t[l],a=t[l-1],s=M(a.to(),o.from());if(r&&!o.empty()?s>0:s>=0){var u=Pr(a.from(),o.from()),f=Fr(a.to(),o.to()),h=a.empty()?o.from()==o.head:a.from()==a.head;l<=i&&--i,t.splice(--l,2,new O(h?f:u,h?u:f))}}return new ge(t,i)}function Ze(e,t){return new ge([new O(e,t||e)],0)}function Qe(e){return e.text?g(e.from.line+e.text.length-1,W(e.text).length+(e.text.length==1?e.from.ch:0)):e.to}function Kl(e,t){if(M(e,t.from)<0)return e;if(M(e,t.to)<=0)return Qe(t);var i=e.line+t.text.length-(t.to.line-t.from.line)-1,r=e.ch;return e.line==t.to.line&&(r+=Qe(t).ch-t.to.ch),g(i,r)}function fn(e,t){for(var i=[],r=0;r<e.sel.ranges.length;r++){var n=e.sel.ranges[r];i.push(new O(Kl(n.anchor,t),Kl(n.head,t)))}return ke(e.cm,i,e.sel.primIndex)}function _l(e,t,i){return e.line==t.line?g(i.line,e.ch-t.ch+i.ch):g(i.line+(e.line-t.line),e.ch)}function ds(e,t,i){for(var r=[],n=g(e.first,0),l=n,o=0;o<t.length;o++){var a=t[o],s=_l(a.from,n,l),u=_l(Qe(a),n,l);if(n=a.to,l=u,i=="around"){var f=e.sel.ranges[o],h=M(f.head,f.anchor)<0;r[o]=new O(h?u:s,h?s:u)}else r[o]=new O(s,s)}return new ge(r,e.sel.primIndex)}function hn(e){e.doc.mode=Di(e.options,e.doc.modeOption),fr(e)}function fr(e){e.doc.iter(function(t){t.stateAfter&&(t.stateAfter=null),t.styles&&(t.styles=null)}),e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,sr(e,100),e.state.modeGen++,e.curOp&&ae(e)}function Xl(e,t){return t.from.ch==0&&t.to.ch==0&&W(t.text)==""&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function cn(e,t,i,r){function n(x){return i?i[x]:null}function l(x,b,C){Ca(x,b,C,r),q(x,"change",x,t)}function o(x,b){for(var C=[],L=x;L<b;++L)C.push(new St(u[L],n(L),r));return C}var a=t.from,s=t.to,u=t.text,f=w(e,a.line),h=w(e,s.line),d=W(u),c=n(u.length-1),p=s.line-a.line;if(t.full)e.insert(0,o(0,u.length)),e.remove(u.length,e.size-u.length);else if(Xl(e,t)){var v=o(0,u.length-1);l(h,h.text,c),p&&e.remove(a.line,p),v.length&&e.insert(a.line,v)}else if(f==h)if(u.length==1)l(f,f.text.slice(0,a.ch)+d+f.text.slice(s.ch),c);else{var y=o(1,u.length-1);y.push(new St(d+f.text.slice(s.ch),c,r)),l(f,f.text.slice(0,a.ch)+u[0],n(0)),e.insert(a.line+1,y)}else if(u.length==1)l(f,f.text.slice(0,a.ch)+u[0]+h.text.slice(s.ch),n(0)),e.remove(a.line+1,p);else{l(f,f.text.slice(0,a.ch)+u[0],n(0)),l(h,d+h.text.slice(s.ch),c);var m=o(1,u.length-1);p>1&&e.remove(a.line+1,p-1),e.insert(a.line+1,m)}q(e,"change",e,t)}function Je(e,t,i){function r(n,l,o){if(n.linked)for(var a=0;a<n.linked.length;++a){var s=n.linked[a];if(s.doc!=l){var u=o&&s.sharedHist;i&&!u||(t(s.doc,u),r(s.doc,n,u))}}}r(e,null,!0)}function Yl(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,ji(e),hn(e),ql(e),e.options.direction=t.direction,e.options.lineWrapping||zi(e),e.options.mode=t.modeOption,ae(e)}function ql(e){(e.doc.direction=="rtl"?it:tt)(e.display.lineDiv,"CodeMirror-rtl")}function ps(e){ce(e,function(){ql(e),ae(e)})}function $r(e){this.done=[],this.undone=[],this.undoDepth=e?e.undoDepth:1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e?e.maxGeneration:1}function dn(e,t){var i={from:Hi(t.from),to:Qe(t),text:ot(e,t.from,t.to)};return Jl(e,i,t.from.line,t.to.line+1),Je(e,function(r){return Jl(r,i,t.from.line,t.to.line+1)},!0),i}function Zl(e){for(;e.length;){var t=W(e);if(t.ranges)e.pop();else break}}function vs(e,t){if(t)return Zl(e.done),W(e.done);if(e.done.length&&!W(e.done).ranges)return W(e.done);if(e.done.length>1&&!e.done[e.done.length-2].ranges)return e.done.pop(),W(e.done)}function Ql(e,t,i,r){var n=e.history;n.undone.length=0;var l=+new Date,o,a;if((n.lastOp==r||n.lastOrigin==t.origin&&t.origin&&(t.origin.charAt(0)=="+"&&n.lastModTime>l-(e.cm?e.cm.options.historyEventDelay:500)||t.origin.charAt(0)=="*"))&&(o=vs(n,n.lastOp==r)))a=W(o.changes),M(t.from,t.to)==0&&M(t.from,a.to)==0?a.to=Qe(t):o.changes.push(dn(e,t));else{var s=W(n.done);for((!s||!s.ranges)&&ei(e.sel,n.done),o={changes:[dn(e,t)],generation:n.generation},n.done.push(o);n.done.length>n.undoDepth;)n.done.shift(),n.done[0].ranges||n.done.shift()}n.done.push(i),n.generation=++n.maxGeneration,n.lastModTime=n.lastSelTime=l,n.lastOp=n.lastSelOp=r,n.lastOrigin=n.lastSelOrigin=t.origin,a||G(e,"historyAdded")}function gs(e,t,i,r){var n=t.charAt(0);return n=="*"||n=="+"&&i.ranges.length==r.ranges.length&&i.somethingSelected()==r.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}function ys(e,t,i,r){var n=e.history,l=r&&r.origin;i==n.lastSelOp||l&&n.lastSelOrigin==l&&(n.lastModTime==n.lastSelTime&&n.lastOrigin==l||gs(e,l,W(n.done),t))?n.done[n.done.length-1]=t:ei(t,n.done),n.lastSelTime=+new Date,n.lastSelOrigin=l,n.lastSelOp=i,r&&r.clearRedo!==!1&&Zl(n.undone)}function ei(e,t){var i=W(t);i&&i.ranges&&i.equals(e)||t.push(e)}function Jl(e,t,i,r){var n=t["spans_"+e.id],l=0;e.iter(Math.max(e.first,i),Math.min(e.first+e.size,r),function(o){o.markedSpans&&((n||(n=t["spans_"+e.id]={}))[l]=o.markedSpans),++l})}function ms(e){if(!e)return null;for(var t,i=0;i<e.length;++i)e[i].marker.explicitlyCleared?t||(t=e.slice(0,i)):t&&t.push(e[i]);return t?t.length?t:null:e}function bs(e,t){var i=t["spans_"+e.id];if(!i)return null;for(var r=[],n=0;n<t.text.length;++n)r.push(ms(i[n]));return r}function jl(e,t){var i=bs(e,t),r=Ei(e,t);if(!i)return r;if(!r)return i;for(var n=0;n<i.length;++n){var l=i[n],o=r[n];if(l&&o)e:for(var a=0;a<o.length;++a){for(var s=o[a],u=0;u<l.length;++u)if(l[u].marker==s.marker)continue e;l.push(s)}else o&&(i[n]=o)}return i}function Ot(e,t,i){for(var r=[],n=0;n<e.length;++n){var l=e[n];if(l.ranges){r.push(i?ge.prototype.deepCopy.call(l):l);continue}var o=l.changes,a=[];r.push({changes:a});for(var s=0;s<o.length;++s){var u=o[s],f=void 0;if(a.push({from:u.from,to:u.to,text:u.text}),t)for(var h in u)(f=h.match(/^spans_(\d+)$/))&&$(t,Number(f[1]))>-1&&(W(a)[h]=u[h],delete u[h])}}return r}function pn(e,t,i,r){if(r){var n=e.anchor;if(i){var l=M(t,n)<0;l!=M(i,n)<0?(n=t,t=i):l!=M(t,i)<0&&(t=i)}return new O(n,t)}else return new O(i||t,t)}function ti(e,t,i,r,n){n==null&&(n=e.cm&&(e.cm.display.shift||e.extend)),ee(e,new ge([pn(e.sel.primary(),t,i,n)],0),r)}function Vl(e,t,i){for(var r=[],n=e.cm&&(e.cm.display.shift||e.extend),l=0;l<e.sel.ranges.length;l++)r[l]=pn(e.sel.ranges[l],t[l],null,n);var o=ke(e.cm,r,e.sel.primIndex);ee(e,o,i)}function vn(e,t,i,r){var n=e.sel.ranges.slice(0);n[t]=i,ee(e,ke(e.cm,n,e.sel.primIndex),r)}function $l(e,t,i,r){ee(e,Ze(t,i),r)}function xs(e,t,i){var r={ranges:t.ranges,update:function(n){this.ranges=[];for(var l=0;l<n.length;l++)this.ranges[l]=new O(D(e,n[l].anchor),D(e,n[l].head))},origin:i&&i.origin};return G(e,"beforeSelectionChange",e,r),e.cm&&G(e.cm,"beforeSelectionChange",e.cm,r),r.ranges!=t.ranges?ke(e.cm,r.ranges,r.ranges.length-1):t}function eo(e,t,i){var r=e.history.done,n=W(r);n&&n.ranges?(r[r.length-1]=t,ri(e,t,i)):ee(e,t,i)}function ee(e,t,i){ri(e,t,i),ys(e,e.sel,e.cm?e.cm.curOp.id:NaN,i)}function ri(e,t,i){(xe(e,"beforeSelectionChange")||e.cm&&xe(e.cm,"beforeSelectionChange"))&&(t=xs(e,t,i));var r=i&&i.bias||(M(t.primary().head,e.sel.primary().head)<0?-1:1);to(e,io(e,t,r,!0)),!(i&&i.scroll===!1)&&e.cm&&e.cm.getOption("readOnly")!="nocursor"&&Nt(e.cm)}function to(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=1,e.cm.curOp.selectionChanged=!0,Bn(e.cm)),q(e,"cursorActivity",e))}function ro(e){to(e,io(e,e.sel,null,!1))}function io(e,t,i,r){for(var n,l=0;l<t.ranges.length;l++){var o=t.ranges[l],a=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[l],s=ii(e,o.anchor,a&&a.anchor,i,r),u=o.head==o.anchor?s:ii(e,o.head,a&&a.head,i,r);(n||s!=o.anchor||u!=o.head)&&(n||(n=t.ranges.slice(0,l)),n[l]=new O(s,u))}return n?ke(e.cm,n,t.primIndex):t}function Wt(e,t,i,r,n){var l=w(e,t.line);if(l.markedSpans)for(var o=0;o<l.markedSpans.length;++o){var a=l.markedSpans[o],s=a.marker,u="selectLeft"in s?!s.selectLeft:s.inclusiveLeft,f="selectRight"in s?!s.selectRight:s.inclusiveRight;if((a.from==null||(u?a.from<=t.ch:a.from<t.ch))&&(a.to==null||(f?a.to>=t.ch:a.to>t.ch))){if(n&&(G(s,"beforeCursorEnter"),s.explicitlyCleared))if(l.markedSpans){--o;continue}else break;if(!s.atomic)continue;if(i){var h=s.find(r<0?1:-1),d=void 0;if((r<0?f:u)&&(h=no(e,h,-r,h&&h.line==t.line?l:null)),h&&h.line==t.line&&(d=M(h,i))&&(r<0?d<0:d>0))return Wt(e,h,t,r,n)}var c=s.find(r<0?-1:1);return(r<0?u:f)&&(c=no(e,c,r,c.line==t.line?l:null)),c?Wt(e,c,t,r,n):null}}return t}function ii(e,t,i,r,n){var l=r||1,o=Wt(e,t,i,l,n)||!n&&Wt(e,t,i,l,!0)||Wt(e,t,i,-l,n)||!n&&Wt(e,t,i,-l,!0);return o||(e.cantEdit=!0,g(e.first,0))}function no(e,t,i,r){return i<0&&t.ch==0?t.line>e.first?D(e,g(t.line-1)):null:i>0&&t.ch==(r||w(e,t.line)).text.length?t.line<e.first+e.size-1?g(t.line+1,0):null:new g(t.line,t.ch+i)}function lo(e){e.setSelection(g(e.firstLine(),0),g(e.lastLine()),Me)}function oo(e,t,i){var r={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){return r.canceled=!0}};return i&&(r.update=function(n,l,o,a){n&&(r.from=D(e,n)),l&&(r.to=D(e,l)),o&&(r.text=o),a!==void 0&&(r.origin=a)}),G(e,"beforeChange",e,r),e.cm&&G(e.cm,"beforeChange",e.cm,r),r.canceled?(e.cm&&(e.cm.curOp.updateInput=2),null):{from:r.from,to:r.to,text:r.text,origin:r.origin}}function Ht(e,t,i){if(e.cm){if(!e.cm.curOp)return Z(e.cm,Ht)(e,t,i);if(e.cm.state.suppressEdits)return}if(!((xe(e,"beforeChange")||e.cm&&xe(e.cm,"beforeChange"))&&(t=oo(e,t,!0),!t))){var r=jn&&!i&&ya(e,t.from,t.to);if(r)for(var n=r.length-1;n>=0;--n)ao(e,{from:r[n].from,to:r[n].to,text:n?[""]:t.text,origin:t.origin});else ao(e,t)}}function ao(e,t){if(!(t.text.length==1&&t.text[0]==""&&M(t.from,t.to)==0)){var i=fn(e,t);Ql(e,t,i,e.cm?e.cm.curOp.id:NaN),hr(e,t,i,Ei(e,t));var r=[];Je(e,function(n,l){!l&&$(r,n.history)==-1&&(ho(n.history,t),r.push(n.history)),hr(n,t,null,Ei(n,t))})}}function ni(e,t,i){var r=e.cm&&e.cm.state.suppressEdits;if(!(r&&!i)){for(var n=e.history,l,o=e.sel,a=t=="undo"?n.done:n.undone,s=t=="undo"?n.undone:n.done,u=0;u<a.length&&(l=a[u],!(i?l.ranges&&!l.equals(e.sel):!l.ranges));u++);if(u!=a.length){for(n.lastOrigin=n.lastSelOrigin=null;;)if(l=a.pop(),l.ranges){if(ei(l,s),i&&!l.equals(e.sel)){ee(e,l,{clearRedo:!1});return}o=l}else if(r){a.push(l);return}else break;var f=[];ei(o,s),s.push({changes:f,generation:n.generation}),n.generation=l.generation||++n.maxGeneration;for(var h=xe(e,"beforeChange")||e.cm&&xe(e.cm,"beforeChange"),d=function(v){var y=l.changes[v];if(y.origin=t,h&&!oo(e,y,!1))return a.length=0,{};f.push(dn(e,y));var m=v?fn(e,y):W(a);hr(e,y,m,jl(e,y)),!v&&e.cm&&e.cm.scrollIntoView({from:y.from,to:Qe(y)});var x=[];Je(e,function(b,C){!C&&$(x,b.history)==-1&&(ho(b.history,y),x.push(b.history)),hr(b,y,null,jl(b,y))})},c=l.changes.length-1;c>=0;--c){var p=d(c);if(p)return p.v}}}}function so(e,t){if(t!=0&&(e.first+=t,e.sel=new ge(Or(e.sel.ranges,function(n){return new O(g(n.anchor.line+t,n.anchor.ch),g(n.head.line+t,n.head.ch))}),e.sel.primIndex),e.cm)){ae(e.cm,e.first,e.first-t,t);for(var i=e.cm.display,r=i.viewFrom;r<i.viewTo;r++)Ye(e.cm,r,"gutter")}}function hr(e,t,i,r){if(e.cm&&!e.cm.curOp)return Z(e.cm,hr)(e,t,i,r);if(t.to.line<e.first){so(e,t.text.length-1-(t.to.line-t.from.line));return}if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var n=t.text.length-1-(e.first-t.from.line);so(e,n),t={from:g(e.first,0),to:g(t.to.line+n,t.to.ch),text:[W(t.text)],origin:t.origin}}var l=e.lastLine();t.to.line>l&&(t={from:t.from,to:g(l,w(e,l).text.length),text:[t.text[0]],origin:t.origin}),t.removed=ot(e,t.from,t.to),i||(i=fn(e,t)),e.cm?Cs(e.cm,t,r):cn(e,t,r),ri(e,i,Me),e.cantEdit&&ii(e,g(e.firstLine(),0))&&(e.cantEdit=!1)}}function Cs(e,t,i){var r=e.doc,n=e.display,l=t.from,o=t.to,a=!1,s=l.line;e.options.lineWrapping||(s=H(Se(w(r,l.line))),r.iter(s,o.line+1,function(c){if(c==n.maxLine)return a=!0,!0})),r.sel.contains(t.from,t.to)>-1&&Bn(e),cn(r,t,i,Ml(e)),e.options.lineWrapping||(r.iter(s,l.line+t.text.length,function(c){var p=Gr(c);p>n.maxLineLength&&(n.maxLine=c,n.maxLineLength=p,n.maxLineChanged=!0,a=!1)}),a&&(e.curOp.updateMaxLine=!0)),fa(r,l.line),sr(e,400);var u=t.text.length-(o.line-l.line)-1;t.full?ae(e):l.line==o.line&&t.text.length==1&&!Xl(e.doc,t)?Ye(e,l.line,"text"):ae(e,l.line,o.line+1,u);var f=xe(e,"changes"),h=xe(e,"change");if(h||f){var d={from:l,to:o,text:t.text,removed:t.removed,origin:t.origin};h&&q(e,"change",e,d),f&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(d)}e.display.selForContextMenu=null}function Ft(e,t,i,r,n){var l;r||(r=i),M(r,i)<0&&(l=[r,i],i=l[0],r=l[1]),typeof t=="string"&&(t=e.splitLines(t)),Ht(e,{from:i,to:r,text:t,origin:n})}function uo(e,t,i,r){i<e.line?e.line+=r:t<e.line&&(e.line=t,e.ch=0)}function fo(e,t,i,r){for(var n=0;n<e.length;++n){var l=e[n],o=!0;if(l.ranges){l.copied||(l=e[n]=l.deepCopy(),l.copied=!0);for(var a=0;a<l.ranges.length;a++)uo(l.ranges[a].anchor,t,i,r),uo(l.ranges[a].head,t,i,r);continue}for(var s=0;s<l.changes.length;++s){var u=l.changes[s];if(i<u.from.line)u.from=g(u.from.line+r,u.from.ch),u.to=g(u.to.line+r,u.to.ch);else if(t<=u.to.line){o=!1;break}}o||(e.splice(0,n+1),n=0)}}function ho(e,t){var i=t.from.line,r=t.to.line,n=t.text.length-(r-i)-1;fo(e.done,i,r,n),fo(e.undone,i,r,n)}function cr(e,t,i,r){var n=t,l=t;return typeof t=="number"?l=w(e,Un(e,t)):n=H(t),n==null?null:(r(l,n)&&e.cm&&Ye(e.cm,n,i),l)}function dr(e){this.lines=e,this.parent=null;for(var t=0,i=0;i<e.length;++i)e[i].parent=this,t+=e[i].height;this.height=t}dr.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var i=e,r=e+t;i<r;++i){var n=this.lines[i];this.height-=n.height,wa(n),q(n,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,i){this.height+=i,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var r=0;r<t.length;++r)t[r].parent=this},iterN:function(e,t,i){for(var r=e+t;e<r;++e)if(i(this.lines[e]))return!0}};function pr(e){this.children=e;for(var t=0,i=0,r=0;r<e.length;++r){var n=e[r];t+=n.chunkSize(),i+=n.height,n.parent=this}this.size=t,this.height=i,this.parent=null}pr.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){this.size-=t;for(var i=0;i<this.children.length;++i){var r=this.children[i],n=r.chunkSize();if(e<n){var l=Math.min(t,n-e),o=r.height;if(r.removeInner(e,l),this.height-=o-r.height,n==l&&(this.children.splice(i--,1),r.parent=null),(t-=l)==0)break;e=0}else e-=n}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof dr))){var a=[];this.collapse(a),this.children=[new dr(a)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t<this.children.length;++t)this.children[t].collapse(e)},insertInner:function(e,t,i){this.size+=t.length,this.height+=i;for(var r=0;r<this.children.length;++r){var n=this.children[r],l=n.chunkSize();if(e<=l){if(n.insertInner(e,t,i),n.lines&&n.lines.length>50){for(var o=n.lines.length%25+25,a=o;a<n.lines.length;){var s=new dr(n.lines.slice(a,a+=25));n.height-=s.height,this.children.splice(++r,0,s),s.parent=this}n.lines=n.lines.slice(0,o),this.maybeSpill()}break}e-=l}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=e.children.splice(e.children.length-5,5),i=new pr(t);if(e.parent){e.size-=i.size,e.height-=i.height;var n=$(e.parent.children,e);e.parent.children.splice(n+1,0,i)}else{var r=new pr(e.children);r.parent=e,e.children=[r,i],e=r}i.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,i){for(var r=0;r<this.children.length;++r){var n=this.children[r],l=n.chunkSize();if(e<l){var o=Math.min(t,l-e);if(n.iterN(e,o,i))return!0;if((t-=o)==0)break;e=0}else e-=l}}};var vr=function(e,t,i){if(i)for(var r in i)i.hasOwnProperty(r)&&(this[r]=i[r]);this.doc=e,this.node=t};vr.prototype.clear=function(){var e=this.doc.cm,t=this.line.widgets,i=this.line,r=H(i);if(!(r==null||!t)){for(var n=0;n<t.length;++n)t[n]==this&&t.splice(n--,1);t.length||(i.widgets=null);var l=tr(this);De(i,Math.max(0,i.height-l)),e&&(ce(e,function(){co(e,i,-l),Ye(e,r,"widget")}),q(e,"lineWidgetCleared",e,this,r))}},vr.prototype.changed=function(){var e=this,t=this.height,i=this.doc.cm,r=this.line;this.height=null;var n=tr(this)-t;n&&(Xe(this.doc,r)||De(r,r.height+n),i&&ce(i,function(){i.curOp.forceUpdate=!0,co(i,r,n),q(i,"lineWidgetChanged",i,e,H(r))}))},xt(vr);function co(e,t,i){Ee(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&nn(e,i)}function ws(e,t,i,r){var n=new vr(e,i,r),l=e.cm;return l&&n.noHScroll&&(l.display.alignWidgets=!0),cr(e,t,"widget",function(o){var a=o.widgets||(o.widgets=[]);if(n.insertAt==null?a.push(n):a.splice(Math.min(a.length,Math.max(0,n.insertAt)),0,n),n.line=o,l&&!Xe(e,o)){var s=Ee(o)<e.scrollTop;De(o,o.height+tr(n)),s&&nn(l,n.height),l.curOp.forceUpdate=!0}return!0}),l&&q(l,"lineWidgetAdded",l,n,typeof t=="number"?t:H(t)),n}var po=0,je=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++po};je.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&pt(e),xe(this,"clear")){var i=this.find();i&&q(this,"clear",i.from,i.to)}for(var r=null,n=null,l=0;l<this.lines.length;++l){var o=this.lines[l],a=Vt(o.markedSpans,this);e&&!this.collapsed?Ye(e,H(o),"text"):e&&(a.to!=null&&(n=H(o)),a.from!=null&&(r=H(o))),o.markedSpans=da(o.markedSpans,a),a.from==null&&this.collapsed&&!Xe(this.doc,o)&&e&&De(o,Tt(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var s=0;s<this.lines.length;++s){var u=Se(this.lines[s]),f=Gr(u);f>e.display.maxLineLength&&(e.display.maxLine=u,e.display.maxLineLength=f,e.display.maxLineChanged=!0)}r!=null&&e&&this.collapsed&&ae(e,r,n+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&ro(e.doc)),e&&q(e,"markerCleared",e,this,r,n),t&&vt(e),this.parent&&this.parent.clear()}},je.prototype.find=function(e,t){e==null&&this.type=="bookmark"&&(e=1);for(var i,r,n=0;n<this.lines.length;++n){var l=this.lines[n],o=Vt(l.markedSpans,this);if(o.from!=null&&(i=g(t?l:H(l),o.from),e==-1))return i;if(o.to!=null&&(r=g(t?l:H(l),o.to),e==1))return r}return i&&{from:i,to:r}},je.prototype.changed=function(){var e=this,t=this.find(-1,!0),i=this,r=this.doc.cm;!t||!r||ce(r,function(){var n=t.line,l=H(t.line),o=_i(r,l);if(o&&(bl(o),r.curOp.selectionChanged=r.curOp.forceUpdate=!0),r.curOp.updateMaxLine=!0,!Xe(i.doc,n)&&i.height!=null){var a=i.height;i.height=null;var s=tr(i)-a;s&&De(n,n.height+s)}q(r,"markerChanged",r,e)})},je.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(!t.maybeHiddenMarkers||$(t.maybeHiddenMarkers,this)==-1)&&(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},je.prototype.detachLine=function(e){if(this.lines.splice($(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}},xt(je);function Pt(e,t,i,r,n){if(r&&r.shared)return Ss(e,t,i,r,n);if(e.cm&&!e.cm.curOp)return Z(e.cm,Pt)(e,t,i,r,n);var l=new je(e,n),o=M(t,i);if(r&&nt(r,l,!1),o>0||o==0&&l.clearWhenEmpty!==!1)return l;if(l.replacedWith&&(l.collapsed=!0,l.widgetNode=bt("span",[l.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||l.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(l.widgetNode.insertLeft=!0)),l.collapsed){if(il(e,t.line,t,i,l)||t.line!=i.line&&il(e,i.line,t,i,l))throw new Error("Inserting collapsed marker partially overlapping an existing one");ca()}l.addToHistory&&Ql(e,{from:t,to:i,origin:"markText"},e.sel,NaN);var a=t.line,s=e.cm,u;if(e.iter(a,i.line+1,function(h){s&&l.collapsed&&!s.options.lineWrapping&&Se(h)==s.display.maxLine&&(u=!0),l.collapsed&&a!=t.line&&De(h,0),pa(h,new Ir(l,a==t.line?t.ch:null,a==i.line?i.ch:null),e.cm&&e.cm.curOp),++a}),l.collapsed&&e.iter(t.line,i.line+1,function(h){Xe(e,h)&&De(h,0)}),l.clearOnEnter&&T(l,"beforeCursorEnter",function(){return l.clear()}),l.readOnly&&(ha(),(e.history.done.length||e.history.undone.length)&&e.clearHistory()),l.collapsed&&(l.id=++po,l.atomic=!0),s){if(u&&(s.curOp.updateMaxLine=!0),l.collapsed)ae(s,t.line,i.line+1);else if(l.className||l.startStyle||l.endStyle||l.css||l.attributes||l.title)for(var f=t.line;f<=i.line;f++)Ye(s,f,"text");l.atomic&&ro(s.doc),q(s,"markerAdded",s,l)}return l}var gr=function(e,t){this.markers=e,this.primary=t;for(var i=0;i<e.length;++i)e[i].parent=this};gr.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();q(this,"clear")}},gr.prototype.find=function(e,t){return this.primary.find(e,t)},xt(gr);function Ss(e,t,i,r,n){r=nt(r),r.shared=!1;var l=[Pt(e,t,i,r,n)],o=l[0],a=r.widgetNode;return Je(e,function(s){a&&(r.widgetNode=a.cloneNode(!0)),l.push(Pt(s,D(s,t),D(s,i),r,n));for(var u=0;u<s.linked.length;++u)if(s.linked[u].isParent)return;o=W(l)}),new gr(l,o)}function vo(e){return e.findMarks(g(e.first,0),e.clipPos(g(e.lastLine())),function(t){return t.parent})}function Ls(e,t){for(var i=0;i<t.length;i++){var r=t[i],n=r.find(),l=e.clipPos(n.from),o=e.clipPos(n.to);if(M(l,o)){var a=Pt(e,l,o,r.primary,r.primary.type);r.markers.push(a),a.parent=r}}}function ks(e){for(var t=function(r){var n=e[r],l=[n.primary.doc];Je(n.primary.doc,function(s){return l.push(s)});for(var o=0;o<n.markers.length;o++){var a=n.markers[o];$(l,a.doc)==-1&&(a.parent=null,n.markers.splice(o--,1))}},i=0;i<e.length;i++)t(i)}var Ts=0,se=function(e,t,i,r,n){if(!(this instanceof se))return new se(e,t,i,r,n);i==null&&(i=0),pr.call(this,[new dr([new St("",null)])]),this.first=i,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=i;var l=g(i,0);this.sel=Ze(l),this.history=new $r(null),this.id=++Ts,this.modeOption=t,this.lineSep=r,this.direction=n=="rtl"?"rtl":"ltr",this.extend=!1,typeof e=="string"&&(e=this.splitLines(e)),cn(this,{from:l,to:l,text:e}),ee(this,Ze(l),Me)};se.prototype=Fn(pr.prototype,{constructor:se,iter:function(e,t,i){i?this.iterN(e-this.first,t-e,i):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var i=0,r=0;r<t.length;++r)i+=t[r].height;this.insertInner(e-this.first,t,i)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=Ai(this,this.first,this.first+this.size);return e===!1?t:t.join(e||this.lineSeparator())},setValue:Q(function(e){var t=g(this.first,0),i=this.first+this.size-1;Ht(this,{from:t,to:g(i,w(this,i).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&nr(this.cm,0,0),ee(this,Ze(t),Me)}),replaceRange:function(e,t,i,r){t=D(this,t),i=i?D(this,i):t,Ft(this,e,t,i,r)},getRange:function(e,t,i){var r=ot(this,D(this,e),D(this,t));return i===!1?r:i===""?r.join(""):r.join(i||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){if(Jt(this,e))return w(this,e)},getLineNumber:function(e){return H(e)},getLineHandleVisualStart:function(e){return typeof e=="number"&&(e=w(this,e)),Se(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return D(this,e)},getCursor:function(e){var t=this.sel.primary(),i;return e==null||e=="head"?i=t.head:e=="anchor"?i=t.anchor:e=="end"||e=="to"||e===!1?i=t.to():i=t.from(),i},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:Q(function(e,t,i){$l(this,D(this,typeof e=="number"?g(e,t||0):e),null,i)}),setSelection:Q(function(e,t,i){$l(this,D(this,e),D(this,t||e),i)}),extendSelection:Q(function(e,t,i){ti(this,D(this,e),t&&D(this,t),i)}),extendSelections:Q(function(e,t){Vl(this,Kn(this,e),t)}),extendSelectionsBy:Q(function(e,t){var i=Or(this.sel.ranges,e);Vl(this,Kn(this,i),t)}),setSelections:Q(function(e,t,i){if(e.length){for(var r=[],n=0;n<e.length;n++)r[n]=new O(D(this,e[n].anchor),D(this,e[n].head||e[n].anchor));t==null&&(t=Math.min(e.length-1,this.sel.primIndex)),ee(this,ke(this.cm,r,t),i)}}),addSelection:Q(function(e,t,i){var r=this.sel.ranges.slice(0);r.push(new O(D(this,e),D(this,t||e))),ee(this,ke(this.cm,r,r.length-1),i)}),getSelection:function(e){for(var t=this.sel.ranges,i,r=0;r<t.length;r++){var n=ot(this,t[r].from(),t[r].to());i=i?i.concat(n):n}return e===!1?i:i.join(e||this.lineSeparator())},getSelections:function(e){for(var t=[],i=this.sel.ranges,r=0;r<i.length;r++){var n=ot(this,i[r].from(),i[r].to());e!==!1&&(n=n.join(e||this.lineSeparator())),t[r]=n}return t},replaceSelection:function(e,t,i){for(var r=[],n=0;n<this.sel.ranges.length;n++)r[n]=e;this.replaceSelections(r,t,i||"+input")},replaceSelections:Q(function(e,t,i){for(var r=[],n=this.sel,l=0;l<n.ranges.length;l++){var o=n.ranges[l];r[l]={from:o.from(),to:o.to(),text:this.splitLines(e[l]),origin:i}}for(var a=t&&t!="end"&&ds(this,r,t),s=r.length-1;s>=0;s--)Ht(this,r[s]);a?eo(this,a):this.cm&&Nt(this.cm)}),undo:Q(function(){ni(this,"undo")}),redo:Q(function(){ni(this,"redo")}),undoSelection:Q(function(){ni(this,"undo",!0)}),redoSelection:Q(function(){ni(this,"redo",!0)}),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,i=0,r=0;r<e.done.length;r++)e.done[r].ranges||++t;for(var n=0;n<e.undone.length;n++)e.undone[n].ranges||++i;return{undo:t,redo:i}},clearHistory:function(){var e=this;this.history=new $r(this.history),Je(this,function(t){return t.history=e.history},!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:Ot(this.history.done),undone:Ot(this.history.undone)}},setHistory:function(e){var t=this.history=new $r(this.history);t.done=Ot(e.done.slice(0),null,!0),t.undone=Ot(e.undone.slice(0),null,!0)},setGutterMarker:Q(function(e,t,i){return cr(this,e,"gutter",function(r){var n=r.gutterMarkers||(r.gutterMarkers={});return n[t]=i,!i&&Pn(n)&&(r.gutterMarkers=null),!0})}),clearGutter:Q(function(e){var t=this;this.iter(function(i){i.gutterMarkers&&i.gutterMarkers[e]&&cr(t,i,"gutter",function(){return i.gutterMarkers[e]=null,Pn(i.gutterMarkers)&&(i.gutterMarkers=null),!0})})}),lineInfo:function(e){var t;if(typeof e=="number"){if(!Jt(this,e)||(t=e,e=w(this,e),!e))return null}else if(t=H(e),t==null)return null;return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:Q(function(e,t,i){return cr(this,e,t=="gutter"?"gutter":"class",function(r){var n=t=="text"?"textClass":t=="background"?"bgClass":t=="gutter"?"gutterClass":"wrapClass";if(!r[n])r[n]=i;else{if(mt(i).test(r[n]))return!1;r[n]+=" "+i}return!0})}),removeLineClass:Q(function(e,t,i){return cr(this,e,t=="gutter"?"gutter":"class",function(r){var n=t=="text"?"textClass":t=="background"?"bgClass":t=="gutter"?"gutterClass":"wrapClass",l=r[n];if(l)if(i==null)r[n]=null;else{var o=l.match(mt(i));if(!o)return!1;var a=o.index+o[0].length;r[n]=l.slice(0,o.index)+(!o.index||a==l.length?"":" ")+l.slice(a)||null}else return!1;return!0})}),addLineWidget:Q(function(e,t,i){return ws(this,e,t,i)}),removeLineWidget:function(e){e.clear()},markText:function(e,t,i){return Pt(this,D(this,e),D(this,t),i,i&&i.type||"range")},setBookmark:function(e,t){var i={replacedWith:t&&(t.nodeType==null?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return e=D(this,e),Pt(this,e,e,i,"bookmark")},findMarksAt:function(e){e=D(this,e);var t=[],i=w(this,e.line).markedSpans;if(i)for(var r=0;r<i.length;++r){var n=i[r];(n.from==null||n.from<=e.ch)&&(n.to==null||n.to>=e.ch)&&t.push(n.marker.parent||n.marker)}return t},findMarks:function(e,t,i){e=D(this,e),t=D(this,t);var r=[],n=e.line;return this.iter(e.line,t.line+1,function(l){var o=l.markedSpans;if(o)for(var a=0;a<o.length;a++){var s=o[a];!(s.to!=null&&n==e.line&&e.ch>=s.to||s.from==null&&n!=e.line||s.from!=null&&n==t.line&&s.from>=t.ch)&&(!i||i(s.marker))&&r.push(s.marker.parent||s.marker)}++n}),r},getAllMarks:function(){var e=[];return this.iter(function(t){var i=t.markedSpans;if(i)for(var r=0;r<i.length;++r)i[r].from!=null&&e.push(i[r].marker)}),e},posFromIndex:function(e){var t,i=this.first,r=this.lineSeparator().length;return this.iter(function(n){var l=n.text.length+r;if(l>e)return t=e,!0;e-=l,++i}),D(this,g(i,t))},indexFromPos:function(e){e=D(this,e);var t=e.ch;if(e.line<this.first||e.ch<0)return 0;var i=this.lineSeparator().length;return this.iter(this.first,e.line,function(r){t+=r.text.length+i}),t},copy:function(e){var t=new se(Ai(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,i=this.first+this.size;e.from!=null&&e.from>t&&(t=e.from),e.to!=null&&e.to<i&&(i=e.to);var r=new se(Ai(this,t,i),e.mode||this.modeOption,t,this.lineSep,this.direction);return e.sharedHist&&(r.history=this.history),(this.linked||(this.linked=[])).push({doc:r,sharedHist:e.sharedHist}),r.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],Ls(r,vo(this)),r},unlinkDoc:function(e){if(e instanceof I&&(e=e.doc),this.linked)for(var t=0;t<this.linked.length;++t){var i=this.linked[t];if(i.doc==e){this.linked.splice(t,1),e.unlinkDoc(this),ks(vo(this));break}}if(e.history==this.history){var r=[e.id];Je(e,function(n){return r.push(n.id)},!0),e.history=new $r(null),e.history.done=Ot(this.history.done,r),e.history.undone=Ot(this.history.undone,r)}},iterLinkedDocs:function(e){Je(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):ki(e)},lineSeparator:function(){return this.lineSep||`
|
|
11
11
|
`},setDirection:Q(function(e){e!="rtl"&&(e="ltr"),e!=this.direction&&(this.direction=e,this.iter(function(t){return t.order=null}),this.cm&&ps(this.cm))})}),se.prototype.eachLine=se.prototype.iter;var go=0;function Ms(e){var t=this;if(yo(t),!(Y(t,e)||Ie(t.display,e))){oe(e),A&&(go=+new Date);var i=ft(t,e,!0),r=e.dataTransfer.files;if(!(!i||t.isReadOnly()))if(r&&r.length&&window.FileReader&&window.File)for(var n=r.length,l=Array(n),o=0,a=function(){++o==n&&Z(t,function(){i=D(t.doc,i);var c={from:i,to:i,text:t.doc.splitLines(l.filter(function(p){return p!=null}).join(t.doc.lineSeparator())),origin:"paste"};Ht(t.doc,c),eo(t.doc,Ze(D(t.doc,i),D(t.doc,Qe(c))))})()},s=function(c,p){if(t.options.allowDropFileTypes&&$(t.options.allowDropFileTypes,c.type)==-1){a();return}var v=new FileReader;v.onerror=function(){return a()},v.onload=function(){var y=v.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(y)){a();return}l[p]=y,a()},v.readAsText(c)},u=0;u<r.length;u++)s(r[u],u);else{if(t.state.draggingText&&t.doc.sel.contains(i)>-1){t.state.draggingText(e),setTimeout(function(){return t.display.input.focus()},20);return}try{var f=e.dataTransfer.getData("Text");if(f){var h;if(t.state.draggingText&&!t.state.draggingText.copy&&(h=t.listSelections()),ri(t.doc,Ze(i,i)),h)for(var d=0;d<h.length;++d)Ft(t.doc,"",h[d].anchor,h[d].head,"drag");t.replaceSelection(f,"around","paste"),t.display.input.focus()}}catch(c){}}}}function Ds(e,t){if(A&&(!e.state.draggingText||+new Date-go<100)){Qt(t);return}if(!(Y(e,t)||Ie(e.display,t))&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!Tr)){var i=k("img",null,null,"position: fixed; left: 0; top: 0;");i.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",Ce&&(i.width=i.height=1,e.display.wrapper.appendChild(i),i._top=i.offsetTop),t.dataTransfer.setDragImage(i,0,0),Ce&&i.parentNode.removeChild(i)}}function Ns(e,t){var i=ft(e,t);if(i){var r=document.createDocumentFragment();Vi(e,i,r),e.display.dragCursor||(e.display.dragCursor=k("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),pe(e.display.dragCursor,r)}}function yo(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function mo(e){if(document.getElementsByClassName){for(var t=document.getElementsByClassName("CodeMirror"),i=[],r=0;r<t.length;r++){var n=t[r].CodeMirror;n&&i.push(n)}i.length&&i[0].operation(function(){for(var l=0;l<i.length;l++)e(i[l])})}}var bo=!1;function As(){bo||(Os(),bo=!0)}function Os(){var e;T(window,"resize",function(){e==null&&(e=setTimeout(function(){e=null,mo(Ws)},100))}),T(window,"blur",function(){return mo(Dt)})}function Ws(e){var t=e.display;t.cachedCharWidth=t.cachedTextHeight=t.cachedPaddingH=null,t.scrollbarsClipped=!1,e.setSize()}for(var Ve={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},yr=0;yr<10;yr++)Ve[yr+48]=Ve[yr+96]=String(yr);for(var li=65;li<=90;li++)Ve[li]=String.fromCharCode(li);for(var mr=1;mr<=12;mr++)Ve[mr+111]=Ve[mr+63235]="F"+mr;var Re={};Re.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"},Re.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"},Re.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Re.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"]},Re.default=ye?Re.macDefault:Re.pcDefault;function Hs(e){var t=e.split(/-(?!$)/);e=t[t.length-1];for(var i,r,n,l,o=0;o<t.length-1;o++){var a=t[o];if(/^(cmd|meta|m)$/i.test(a))l=!0;else if(/^a(lt)?$/i.test(a))i=!0;else if(/^(c|ctrl|control)$/i.test(a))r=!0;else if(/^s(hift)?$/i.test(a))n=!0;else throw new Error("Unrecognized modifier name: "+a)}return i&&(e="Alt-"+e),r&&(e="Ctrl-"+e),l&&(e="Cmd-"+e),n&&(e="Shift-"+e),e}function Fs(e){var t={};for(var i in e)if(e.hasOwnProperty(i)){var r=e[i];if(/^(name|fallthrough|(de|at)tach)$/.test(i))continue;if(r=="..."){delete e[i];continue}for(var n=Or(i.split(" "),Hs),l=0;l<n.length;l++){var o=void 0,a=void 0;l==n.length-1?(a=n.join(" "),o=r):(a=n.slice(0,l+1).join(" "),o="...");var s=t[a];if(!s)t[a]=o;else if(s!=o)throw new Error("Inconsistent bindings for "+a)}delete e[i]}for(var u in t)e[u]=t[u];return e}function Et(e,t,i,r){t=oi(t);var n=t.call?t.call(e,r):t[e];if(n===!1)return"nothing";if(n==="...")return"multi";if(n!=null&&i(n))return"handled";if(t.fallthrough){if(Object.prototype.toString.call(t.fallthrough)!="[object Array]")return Et(e,t.fallthrough,i,r);for(var l=0;l<t.fallthrough.length;l++){var o=Et(e,t.fallthrough[l],i,r);if(o)return o}}}function xo(e){var t=typeof e=="string"?e:Ve[e.keyCode];return t=="Ctrl"||t=="Alt"||t=="Shift"||t=="Mod"}function Co(e,t,i){var r=e;return t.altKey&&r!="Alt"&&(e="Alt-"+e),(On?t.metaKey:t.ctrlKey)&&r!="Ctrl"&&(e="Ctrl-"+e),(On?t.ctrlKey:t.metaKey)&&r!="Mod"&&(e="Cmd-"+e),!i&&t.shiftKey&&r!="Shift"&&(e="Shift-"+e),e}function wo(e,t){if(Ce&&e.keyCode==34&&e.char)return!1;var i=Ve[e.keyCode];return i==null||e.altGraphKey?!1:(e.keyCode==3&&e.code&&(i=e.code),Co(i,e,t))}function oi(e){return typeof e=="string"?Re[e]:e}function It(e,t){for(var i=e.doc.sel.ranges,r=[],n=0;n<i.length;n++){for(var l=t(i[n]);r.length&&M(l.from,W(r).to)<=0;){var o=r.pop();if(M(o.from,l.from)<0){l.from=o.from;break}}r.push(l)}ce(e,function(){for(var a=r.length-1;a>=0;a--)Ft(e.doc,"",r[a].from,r[a].to,"+delete");Nt(e)})}function gn(e,t,i){var r=En(e.text,t+i,i);return r<0||r>e.text.length?null:r}function yn(e,t,i){var r=gn(e,t.ch,i);return r==null?null:new g(t.line,r,i<0?"after":"before")}function mn(e,t,i,r,n){if(e){t.doc.direction=="rtl"&&(n=-n);var l=Fe(i,t.doc.direction);if(l){var o=n<0?W(l):l[0],a=n<0==(o.level==1),s=a?"after":"before",u;if(o.level>0||t.doc.direction=="rtl"){var f=kt(t,i);u=n<0?i.text.length-1:0;var h=Oe(t,f,u).top;u=Yt(function(d){return Oe(t,f,d).top==h},n<0==(o.level==1)?o.from:o.to-1,u),s=="before"&&(u=gn(i,u,1))}else u=n<0?o.to:o.from;return new g(r,u,s)}}return new g(r,n<0?i.text.length:0,n<0?"before":"after")}function Ps(e,t,i,r){var n=Fe(t,e.doc.direction);if(!n)return yn(t,i,r);i.ch>=t.text.length?(i.ch=t.text.length,i.sticky="before"):i.ch<=0&&(i.ch=0,i.sticky="after");var l=Zt(n,i.ch,i.sticky),o=n[l];if(e.doc.direction=="ltr"&&o.level%2==0&&(r>0?o.to>i.ch:o.from<i.ch))return yn(t,i,r);var a=function(m,x){return gn(t,m instanceof g?m.ch:m,x)},s,u=function(m){return e.options.lineWrapping?(s=s||kt(e,t),Tl(e,t,s,m)):{begin:0,end:t.text.length}},f=u(i.sticky=="before"?a(i,-1):i.ch);if(e.doc.direction=="rtl"||o.level==1){var h=o.level==1==r<0,d=a(i,h?1:-1);if(d!=null&&(h?d<=o.to&&d<=f.end:d>=o.from&&d>=f.begin)){var c=h?"before":"after";return new g(i.line,d,c)}}var p=function(m,x,b){for(var C=function(P,J){return J?new g(i.line,a(P,1),"before"):new g(i.line,P,"after")};m>=0&&m<n.length;m+=x){var L=n[m],S=x>0==(L.level!=1),N=S?b.begin:a(b.end,-1);if(L.from<=N&&N<L.to||(N=S?L.from:a(L.to,-1),b.begin<=N&&N<b.end))return C(N,S)}},v=p(l+r,r,f);if(v)return v;var y=r>0?f.end:a(f.begin,-1);return y!=null&&!(r>0&&y==t.text.length)&&(v=p(r>0?0:n.length-1,r,u(y)),v)?v:null}var br={selectAll:lo,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),Me)},killLine:function(e){return It(e,function(t){if(t.empty()){var i=w(e.doc,t.head.line).text.length;return t.head.ch==i&&t.head.line<e.lastLine()?{from:t.head,to:g(t.head.line+1,0)}:{from:t.head,to:g(t.head.line,i)}}else return{from:t.from(),to:t.to()}})},deleteLine:function(e){return It(e,function(t){return{from:g(t.from().line,0),to:D(e.doc,g(t.to().line+1,0))}})},delLineLeft:function(e){return It(e,function(t){return{from:g(t.from().line,0),to:t.from()}})},delWrappedLineLeft:function(e){return It(e,function(t){var i=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:0,top:i},"div");return{from:r,to:t.from()}})},delWrappedLineRight:function(e){return It(e,function(t){var i=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:i},"div");return{from:t.from(),to:r}})},undo:function(e){return e.undo()},redo:function(e){return e.redo()},undoSelection:function(e){return e.undoSelection()},redoSelection:function(e){return e.redoSelection()},goDocStart:function(e){return e.extendSelection(g(e.firstLine(),0))},goDocEnd:function(e){return e.extendSelection(g(e.lastLine()))},goLineStart:function(e){return e.extendSelectionsBy(function(t){return So(e,t.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(e){return e.extendSelectionsBy(function(t){return Lo(e,t.head)},{origin:"+move",bias:1})},goLineEnd:function(e){return e.extendSelectionsBy(function(t){return Es(e,t.head.line)},{origin:"+move",bias:-1})},goLineRight:function(e){return e.extendSelectionsBy(function(t){var i=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:i},"div")},Xt)},goLineLeft:function(e){return e.extendSelectionsBy(function(t){var i=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:0,top:i},"div")},Xt)},goLineLeftSmart:function(e){return e.extendSelectionsBy(function(t){var i=e.cursorCoords(t.head,"div").top+5,r=e.coordsChar({left:0,top:i},"div");return r.ch<e.getLine(r.line).search(/\S/)?Lo(e,t.head):r},Xt)},goLineUp:function(e){return e.moveV(-1,"line")},goLineDown:function(e){return e.moveV(1,"line")},goPageUp:function(e){return e.moveV(-1,"page")},goPageDown:function(e){return e.moveV(1,"page")},goCharLeft:function(e){return e.moveH(-1,"char")},goCharRight:function(e){return e.moveH(1,"char")},goColumnLeft:function(e){return e.moveH(-1,"column")},goColumnRight:function(e){return e.moveH(1,"column")},goWordLeft:function(e){return e.moveH(-1,"word")},goGroupRight:function(e){return e.moveH(1,"group")},goGroupLeft:function(e){return e.moveH(-1,"group")},goWordRight:function(e){return e.moveH(1,"word")},delCharBefore:function(e){return e.deleteH(-1,"codepoint")},delCharAfter:function(e){return e.deleteH(1,"char")},delWordBefore:function(e){return e.deleteH(-1,"word")},delWordAfter:function(e){return e.deleteH(1,"word")},delGroupBefore:function(e){return e.deleteH(-1,"group")},delGroupAfter:function(e){return e.deleteH(1,"group")},indentAuto:function(e){return e.indentSelection("smart")},indentMore:function(e){return e.indentSelection("add")},indentLess:function(e){return e.indentSelection("subtract")},insertTab:function(e){return e.replaceSelection(" ")},insertSoftTab:function(e){for(var t=[],i=e.listSelections(),r=e.options.tabSize,n=0;n<i.length;n++){var l=i[n].from(),o=be(e.getLine(l.line),l.ch,r);t.push(yi(r-o%r))}e.replaceSelections(t)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){return ce(e,function(){for(var t=e.listSelections(),i=[],r=0;r<t.length;r++)if(t[r].empty()){var n=t[r].head,l=w(e.doc,n.line).text;if(l){if(n.ch==l.length&&(n=new g(n.line,n.ch-1)),n.ch>0)n=new g(n.line,n.ch+1),e.replaceRange(l.charAt(n.ch-1)+l.charAt(n.ch-2),g(n.line,n.ch-2),n,"+transpose");else if(n.line>e.doc.first){var o=w(e.doc,n.line-1).text;o&&(n=new g(n.line,1),e.replaceRange(l.charAt(0)+e.doc.lineSeparator()+o.charAt(o.length-1),g(n.line-1,o.length-1),n,"+transpose"))}}i.push(new O(n,n))}e.setSelections(i)})},newlineAndIndent:function(e){return ce(e,function(){for(var t=e.listSelections(),i=t.length-1;i>=0;i--)e.replaceRange(e.doc.lineSeparator(),t[i].anchor,t[i].head,"+input");t=e.listSelections();for(var r=0;r<t.length;r++)e.indentLine(t[r].from().line,null,!0);Nt(e)})},openLine:function(e){return e.replaceSelection(`
|
|
12
12
|
`,"start")},toggleOverwrite:function(e){return e.toggleOverwrite()}};function So(e,t){var i=w(e.doc,t),r=Se(i);return r!=i&&(t=H(r)),mn(!0,e,r,t,1)}function Es(e,t){var i=w(e.doc,t),r=ba(i);return r!=i&&(t=H(r)),mn(!0,e,i,t,-1)}function Lo(e,t){var i=So(e,t.line),r=w(e.doc,i.line),n=Fe(r,e.doc.direction);if(!n||n[0].level==0){var l=Math.max(i.ch,r.text.search(/\S/)),o=t.line==i.line&&t.ch<=l&&t.ch;return g(i.line,o?0:l,i.sticky)}return i}function ai(e,t,i){if(typeof t=="string"&&(t=br[t],!t))return!1;e.display.input.ensurePolled();var r=e.display.shift,n=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),i&&(e.display.shift=!1),n=t(e)!=Nr}finally{e.display.shift=r,e.state.suppressEdits=!1}return n}function Is(e,t,i){for(var r=0;r<e.state.keyMaps.length;r++){var n=Et(t,e.state.keyMaps[r],i,e);if(n)return n}return e.options.extraKeys&&Et(t,e.options.extraKeys,i,e)||Et(t,e.options.keyMap,i,e)}var Bs=new _e;function xr(e,t,i,r){var n=e.state.keySeq;if(n){if(xo(t))return"handled";if(/\'$/.test(t)?e.state.keySeq=null:Bs.set(50,function(){e.state.keySeq==n&&(e.state.keySeq=null,e.display.input.reset())}),ko(e,n+" "+t,i,r))return!0}return ko(e,t,i,r)}function ko(e,t,i,r){var n=Is(e,t,r);return n=="multi"&&(e.state.keySeq=t),n=="handled"&&q(e,"keyHandled",e,t,i),(n=="handled"||n=="multi")&&(oe(i),$i(e)),!!n}function To(e,t){var i=wo(t,!0);return i?t.shiftKey&&!e.state.keySeq?xr(e,"Shift-"+i,t,function(r){return ai(e,r,!0)})||xr(e,i,t,function(r){if(typeof r=="string"?/^go[A-Z]/.test(r):r.motion)return ai(e,r)}):xr(e,i,t,function(r){return ai(e,r)}):!1}function Rs(e,t,i){return xr(e,"'"+i+"'",t,function(r){return ai(e,r,!0)})}var bn=null;function Mo(e){var t=this;if(!(e.target&&e.target!=t.display.input.getField())&&(t.curOp.focus=me(we(t)),!Y(t,e))){A&&E<11&&e.keyCode==27&&(e.returnValue=!1);var i=e.keyCode;t.display.shift=i==16||e.shiftKey;var r=To(t,e);Ce&&(bn=r?i:null,!r&&i==88&&!ia&&(ye?e.metaKey:e.ctrlKey)&&t.replaceSelection("",null,"cut")),He&&!ye&&!r&&i==46&&e.shiftKey&&!e.ctrlKey&&document.execCommand&&document.execCommand("cut"),i==18&&!/\bCodeMirror-crosshair\b/.test(t.display.lineDiv.className)&&zs(t)}}function zs(e){var t=e.display.lineDiv;it(t,"CodeMirror-crosshair");function i(r){(r.keyCode==18||!r.altKey)&&(tt(t,"CodeMirror-crosshair"),ve(document,"keyup",i),ve(document,"mouseover",i))}T(document,"keyup",i),T(document,"mouseover",i)}function Do(e){e.keyCode==16&&(this.doc.sel.shift=!1),Y(this,e)}function No(e){var t=this;if(!(e.target&&e.target!=t.display.input.getField())&&!(Ie(t.display,e)||Y(t,e)||e.ctrlKey&&!e.altKey||ye&&e.metaKey)){var i=e.keyCode,r=e.charCode;if(Ce&&i==bn){bn=null,oe(e);return}if(!(Ce&&(!e.which||e.which<10)&&To(t,e))){var n=String.fromCharCode(r==null?i:r);n!="\b"&&(Rs(t,e,n)||t.display.input.onKeyPress(e))}}}var Gs=400,xn=function(e,t,i){this.time=e,this.pos=t,this.button=i};xn.prototype.compare=function(e,t,i){return this.time+Gs>e&&M(t,this.pos)==0&&i==this.button};var Cr,wr;function Us(e,t){var i=+new Date;return wr&&wr.compare(i,e,t)?(Cr=wr=null,"triple"):Cr&&Cr.compare(i,e,t)?(wr=new xn(i,e,t),Cr=null,"double"):(Cr=new xn(i,e,t),wr=null,"single")}function Ao(e){var t=this,i=t.display;if(!(Y(t,e)||i.activeTouch&&i.input.supportsTouch())){if(i.input.ensurePolled(),i.shift=e.shiftKey,Ie(i,e)){ie||(i.scroller.draggable=!1,setTimeout(function(){return i.scroller.draggable=!0},100));return}if(!Cn(t,e)){var r=ft(t,e),n=zn(e),l=r?Us(r,n):"single";Dr(t).focus(),n==1&&t.state.selectingText&&t.state.selectingText(e),!(r&&Ks(t,n,r,l,e))&&(n==1?r?Xs(t,r,l,e):wi(e)==i.scroller&&oe(e):n==2?(r&&ti(t.doc,r),setTimeout(function(){return i.input.focus()},20)):n==3&&(ci?t.display.input.onContextMenu(e):en(t)))}}}function Ks(e,t,i,r,n){var l="Click";return r=="double"?l="Double"+l:r=="triple"&&(l="Triple"+l),l=(t==1?"Left":t==2?"Middle":"Right")+l,xr(e,Co(l,n),n,function(o){if(typeof o=="string"&&(o=br[o]),!o)return!1;var a=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),a=o(e,i)!=Nr}finally{e.state.suppressEdits=!1}return a})}function _s(e,t,i){var r=e.getOption("configureMouse"),n=r?r(e,t,i):{};if(n.unit==null){var l=Yo?i.shiftKey&&i.metaKey:i.altKey;n.unit=l?"rectangle":t=="single"?"char":t=="double"?"word":"line"}return(n.extend==null||e.doc.extend)&&(n.extend=e.doc.extend||i.shiftKey),n.addNew==null&&(n.addNew=ye?i.metaKey:i.ctrlKey),n.moveOnDrag==null&&(n.moveOnDrag=!(ye?i.altKey:i.ctrlKey)),n}function Xs(e,t,i,r){A?setTimeout(pi(Al,e),0):e.curOp.focus=me(we(e));var n=_s(e,i,r),l=e.doc.sel,o;e.options.dragDrop&&$o&&!e.isReadOnly()&&i=="single"&&(o=l.contains(t))>-1&&(M((o=l.ranges[o]).from(),t)<0||t.xRel>0)&&(M(o.to(),t)>0||t.xRel<0)?Ys(e,r,t,n):qs(e,r,t,n)}function Ys(e,t,i,r){var n=e.display,l=!1,o=Z(e,function(u){ie&&(n.scroller.draggable=!1),e.state.draggingText=!1,e.state.delayingBlurEvent&&(e.hasFocus()?e.state.delayingBlurEvent=!1:en(e)),ve(n.wrapper.ownerDocument,"mouseup",o),ve(n.wrapper.ownerDocument,"mousemove",a),ve(n.scroller,"dragstart",s),ve(n.scroller,"drop",o),l||(oe(u),r.addNew||ti(e.doc,i,null,null,r.extend),ie&&!Tr||A&&E==9?setTimeout(function(){n.wrapper.ownerDocument.body.focus({preventScroll:!0}),n.input.focus()},20):n.input.focus())}),a=function(u){l=l||Math.abs(t.clientX-u.clientX)+Math.abs(t.clientY-u.clientY)>=10},s=function(){return l=!0};ie&&(n.scroller.draggable=!0),e.state.draggingText=o,o.copy=!r.moveOnDrag,T(n.wrapper.ownerDocument,"mouseup",o),T(n.wrapper.ownerDocument,"mousemove",a),T(n.scroller,"dragstart",s),T(n.scroller,"drop",o),e.state.delayingBlurEvent=!0,setTimeout(function(){return n.input.focus()},20),n.scroller.dragDrop&&n.scroller.dragDrop()}function Oo(e,t,i){if(i=="char")return new O(t,t);if(i=="word")return e.findWordAt(t);if(i=="line")return new O(g(t.line,0),D(e.doc,g(t.line+1,0)));var r=i(e,t);return new O(r.from,r.to)}function qs(e,t,i,r){A&&en(e);var n=e.display,l=e.doc;oe(t);var o,a,s=l.sel,u=s.ranges;if(r.addNew&&!r.extend?(a=l.sel.contains(i),a>-1?o=u[a]:o=new O(i,i)):(o=l.sel.primary(),a=l.sel.primIndex),r.unit=="rectangle")r.addNew||(o=new O(i,i)),i=ft(e,t,!0,!0),a=-1;else{var f=Oo(e,i,r.unit);r.extend?o=pn(o,f.anchor,f.head,r.extend):o=f}r.addNew?a==-1?(a=u.length,ee(l,ke(e,u.concat([o]),a),{scroll:!1,origin:"*mouse"})):u.length>1&&u[a].empty()&&r.unit=="char"&&!r.extend?(ee(l,ke(e,u.slice(0,a).concat(u.slice(a+1)),0),{scroll:!1,origin:"*mouse"}),s=l.sel):vn(l,a,o,vi):(a=0,ee(l,new ge([o],0),vi),s=l.sel);var h=i;function d(b){if(M(h,b)!=0)if(h=b,r.unit=="rectangle"){for(var C=[],L=e.options.tabSize,S=be(w(l,i.line).text,i.ch,L),N=be(w(l,b.line).text,b.ch,L),P=Math.min(S,N),J=Math.max(S,N),B=Math.min(i.line,b.line),de=Math.min(e.lastLine(),Math.max(i.line,b.line));B<=de;B++){var ue=w(l,B).text,K=gi(ue,P,L);P==J?C.push(new O(g(B,K),g(B,K))):ue.length>K&&C.push(new O(g(B,K),g(B,gi(ue,J,L))))}C.length||C.push(new O(i,i)),ee(l,ke(e,s.ranges.slice(0,a).concat(C),a),{origin:"*mouse",scroll:!1}),e.scrollIntoView(b)}else{var fe=o,V=Oo(e,b,r.unit),X=fe.anchor,_;M(V.anchor,X)>0?(_=V.head,X=Pr(fe.from(),V.anchor)):(_=V.anchor,X=Fr(fe.to(),V.head));var R=s.ranges.slice(0);R[a]=Zs(e,new O(D(l,X),_)),ee(l,ke(e,R,a),vi)}}var c=n.wrapper.getBoundingClientRect(),p=0;function v(b){var C=++p,L=ft(e,b,!0,r.unit=="rectangle");if(L)if(M(L,h)!=0){e.curOp.focus=me(we(e)),d(L);var S=Qr(n,l);(L.line>=S.to||L.line<S.from)&&setTimeout(Z(e,function(){p==C&&v(b)}),150)}else{var N=b.clientY<c.top?-20:b.clientY>c.bottom?20:0;N&&setTimeout(Z(e,function(){p==C&&(n.scroller.scrollTop+=N,v(b))}),50)}}function y(b){e.state.selectingText=!1,p=1/0,b&&(oe(b),n.input.focus()),ve(n.wrapper.ownerDocument,"mousemove",m),ve(n.wrapper.ownerDocument,"mouseup",x),l.history.lastSelOrigin=null}var m=Z(e,function(b){b.buttons===0||!zn(b)?y(b):v(b)}),x=Z(e,y);e.state.selectingText=x,T(n.wrapper.ownerDocument,"mousemove",m),T(n.wrapper.ownerDocument,"mouseup",x)}function Zs(e,t){var i=t.anchor,r=t.head,n=w(e.doc,i.line);if(M(i,r)==0&&i.sticky==r.sticky)return t;var l=Fe(n);if(!l)return t;var o=Zt(l,i.ch,i.sticky),a=l[o];if(a.from!=i.ch&&a.to!=i.ch)return t;var s=o+(a.from==i.ch==(a.level!=1)?0:1);if(s==0||s==l.length)return t;var u;if(r.line!=i.line)u=(r.line-i.line)*(e.doc.direction=="ltr"?1:-1)>0;else{var f=Zt(l,r.ch,r.sticky),h=f-o||(r.ch-i.ch)*(a.level==1?-1:1);f==s-1||f==s?u=h<0:u=h>0}var d=l[s+(u?-1:0)],c=u==(d.level==1),p=c?d.from:d.to,v=c?"after":"before";return i.ch==p&&i.sticky==v?t:new O(new g(i.line,p,v),r)}function Wo(e,t,i,r){var n,l;if(t.touches)n=t.touches[0].clientX,l=t.touches[0].clientY;else try{n=t.clientX,l=t.clientY}catch(d){return!1}if(n>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;r&&oe(t);var o=e.display,a=o.lineDiv.getBoundingClientRect();if(l>a.bottom||!xe(e,i))return Ci(t);l-=a.top-o.viewOffset;for(var s=0;s<e.display.gutterSpecs.length;++s){var u=o.gutters.childNodes[s];if(u&&u.getBoundingClientRect().right>=n){var f=at(e.doc,l),h=e.display.gutterSpecs[s];return G(e,i,e,f,h.className,t),Ci(t)}}}function Cn(e,t){return Wo(e,t,"gutterClick",!0)}function Ho(e,t){Ie(e.display,t)||Qs(e,t)||Y(e,t,"contextmenu")||ci||e.display.input.onContextMenu(t)}function Qs(e,t){return xe(e,"gutterContextMenu")?Wo(e,t,"gutterContextMenu",!1):!1}function Fo(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),rr(e)}var Bt={toString:function(){return"CodeMirror.Init"}},Po={},si={};function Js(e){var t=e.optionHandlers;function i(r,n,l,o){e.defaults[r]=n,l&&(t[r]=o?function(a,s,u){u!=Bt&&l(a,s,u)}:l)}e.defineOption=i,e.Init=Bt,i("value","",function(r,n){return r.setValue(n)},!0),i("mode",null,function(r,n){r.doc.modeOption=n,hn(r)},!0),i("indentUnit",2,hn,!0),i("indentWithTabs",!1),i("smartIndent",!0),i("tabSize",4,function(r){fr(r),rr(r),ae(r)},!0),i("lineSeparator",null,function(r,n){if(r.doc.lineSep=n,!!n){var l=[],o=r.doc.first;r.doc.iter(function(s){for(var u=0;;){var f=s.text.indexOf(n,u);if(f==-1)break;u=f+n.length,l.push(g(o,f))}o++});for(var a=l.length-1;a>=0;a--)Ft(r.doc,n,l[a],g(l[a].line,l[a].ch+n.length))}}),i("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\u202d\u202e\u2066\u2067\u2069\ufeff\ufff9-\ufffc]/g,function(r,n,l){r.state.specialChars=new RegExp(n.source+(n.test(" ")?"":"| "),"g"),l!=Bt&&r.refresh()}),i("specialCharPlaceholder",ka,function(r){return r.refresh()},!0),i("electricChars",!0),i("inputStyle",Kt?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),i("spellcheck",!1,function(r,n){return r.getInputField().spellcheck=n},!0),i("autocorrect",!1,function(r,n){return r.getInputField().autocorrect=n},!0),i("autocapitalize",!1,function(r,n){return r.getInputField().autocapitalize=n},!0),i("rtlMoveVisually",!qo),i("wholeLineUpdateBefore",!0),i("theme","default",function(r){Fo(r),ur(r)},!0),i("keyMap","default",function(r,n,l){var o=oi(n),a=l!=Bt&&oi(l);a&&a.detach&&a.detach(r,o),o.attach&&o.attach(r,a||null)}),i("extraKeys",null),i("configureMouse",null),i("lineWrapping",!1,Vs,!0),i("gutters",[],function(r,n){r.display.gutterSpecs=un(n,r.options.lineNumbers),ur(r)},!0),i("fixedGutter",!0,function(r,n){r.display.gutters.style.left=n?Ji(r.display)+"px":"0",r.refresh()},!0),i("coverGutterNextToScrollbar",!1,function(r){return At(r)},!0),i("scrollbarStyle","native",function(r){El(r),At(r),r.display.scrollbars.setScrollTop(r.doc.scrollTop),r.display.scrollbars.setScrollLeft(r.doc.scrollLeft)},!0),i("lineNumbers",!1,function(r,n){r.display.gutterSpecs=un(r.options.gutters,n),ur(r)},!0),i("firstLineNumber",1,ur,!0),i("lineNumberFormatter",function(r){return r},ur,!0),i("showCursorWhenSelecting",!1,ir,!0),i("resetSelectionOnContextMenu",!0),i("lineWiseCopyCut",!0),i("pasteLinesPerSelection",!0),i("selectionsMayTouch",!1),i("readOnly",!1,function(r,n){n=="nocursor"&&(Dt(r),r.display.input.blur()),r.display.input.readOnlyChanged(n)}),i("screenReaderLabel",null,function(r,n){n=n===""?null:n,r.display.input.screenReaderLabelChanged(n)}),i("disableInput",!1,function(r,n){n||r.display.input.reset()},!0),i("dragDrop",!0,js),i("allowDropFileTypes",null),i("cursorBlinkRate",530),i("cursorScrollMargin",0),i("cursorHeight",1,ir,!0),i("singleCursorHeightPerLine",!0,ir,!0),i("workTime",100),i("workDelay",100),i("flattenSpans",!0,fr,!0),i("addModeClass",!1,fr,!0),i("pollInterval",100),i("undoDepth",200,function(r,n){return r.doc.history.undoDepth=n}),i("historyEventDelay",1250),i("viewportMargin",10,function(r){return r.refresh()},!0),i("maxHighlightLength",1e4,fr,!0),i("moveInputWithCursor",!0,function(r,n){n||r.display.input.resetPosition()}),i("tabindex",null,function(r,n){return r.display.input.getField().tabIndex=n||""}),i("autofocus",null),i("direction","ltr",function(r,n){return r.doc.setDirection(n)},!0),i("phrases",null)}function js(e,t,i){var r=i&&i!=Bt;if(!t!=!r){var n=e.display.dragFunctions,l=t?T:ve;l(e.display.scroller,"dragstart",n.start),l(e.display.scroller,"dragenter",n.enter),l(e.display.scroller,"dragover",n.over),l(e.display.scroller,"dragleave",n.leave),l(e.display.scroller,"drop",n.drop)}}function Vs(e){e.options.lineWrapping?(it(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(tt(e.display.wrapper,"CodeMirror-wrap"),zi(e)),ji(e),ae(e),rr(e),setTimeout(function(){return At(e)},100)}function I(e,t){var i=this;if(!(this instanceof I))return new I(e,t);this.options=t=t?nt(t):{},nt(Po,t,!1);var r=t.value;typeof r=="string"?r=new se(r,t.mode,null,t.lineSeparator,t.direction):t.mode&&(r.modeOption=t.mode),this.doc=r;var n=new I.inputStyles[t.inputStyle](this),l=this.display=new hs(e,r,n,t);l.wrapper.CodeMirror=this,Fo(this),t.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),El(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 _e,keySeq:null,specialChars:null},t.autofocus&&!Kt&&l.input.focus(),A&&E<11&&setTimeout(function(){return i.display.input.reset(!0)},20),$s(this),As(),pt(this),this.curOp.forceUpdate=!0,Yl(this,r),t.autofocus&&!Kt||this.hasFocus()?setTimeout(function(){i.hasFocus()&&!i.state.focused&&tn(i)},20):Dt(this);for(var o in si)si.hasOwnProperty(o)&&si[o](this,t[o],Bt);Rl(this),t.finishInit&&t.finishInit(this);for(var a=0;a<wn.length;++a)wn[a](this);vt(this),ie&&t.lineWrapping&&getComputedStyle(l.lineDiv).textRendering=="optimizelegibility"&&(l.lineDiv.style.textRendering="auto")}I.defaults=Po,I.optionHandlers=si;function $s(e){var t=e.display;T(t.scroller,"mousedown",Z(e,Ao)),A&&E<11?T(t.scroller,"dblclick",Z(e,function(s){if(!Y(e,s)){var u=ft(e,s);if(!(!u||Cn(e,s)||Ie(e.display,s))){oe(s);var f=e.findWordAt(u);ti(e.doc,f.anchor,f.head)}}})):T(t.scroller,"dblclick",function(s){return Y(e,s)||oe(s)}),T(t.scroller,"contextmenu",function(s){return Ho(e,s)}),T(t.input.getField(),"contextmenu",function(s){t.scroller.contains(s.target)||Ho(e,s)});var i,r={end:0};function n(){t.activeTouch&&(i=setTimeout(function(){return t.activeTouch=null},1e3),r=t.activeTouch,r.end=+new Date)}function l(s){if(s.touches.length!=1)return!1;var u=s.touches[0];return u.radiusX<=1&&u.radiusY<=1}function o(s,u){if(u.left==null)return!0;var f=u.left-s.left,h=u.top-s.top;return f*f+h*h>20*20}T(t.scroller,"touchstart",function(s){if(!Y(e,s)&&!l(s)&&!Cn(e,s)){t.input.ensurePolled(),clearTimeout(i);var u=+new Date;t.activeTouch={start:u,moved:!1,prev:u-r.end<=300?r:null},s.touches.length==1&&(t.activeTouch.left=s.touches[0].pageX,t.activeTouch.top=s.touches[0].pageY)}}),T(t.scroller,"touchmove",function(){t.activeTouch&&(t.activeTouch.moved=!0)}),T(t.scroller,"touchend",function(s){var u=t.activeTouch;if(u&&!Ie(t,s)&&u.left!=null&&!u.moved&&new Date-u.start<300){var f=e.coordsChar(t.activeTouch,"page"),h;!u.prev||o(u,u.prev)?h=new O(f,f):!u.prev.prev||o(u,u.prev.prev)?h=e.findWordAt(f):h=new O(g(f.line,0),D(e.doc,g(f.line+1,0))),e.setSelection(h.anchor,h.head),e.focus(),oe(s)}n()}),T(t.scroller,"touchcancel",n),T(t.scroller,"scroll",function(){t.scroller.clientHeight&&(lr(e,t.scroller.scrollTop),ct(e,t.scroller.scrollLeft,!0),G(e,"scroll",e))}),T(t.scroller,"mousewheel",function(s){return Ul(e,s)}),T(t.scroller,"DOMMouseScroll",function(s){return Ul(e,s)}),T(t.wrapper,"scroll",function(){return t.wrapper.scrollTop=t.wrapper.scrollLeft=0}),t.dragFunctions={enter:function(s){Y(e,s)||Qt(s)},over:function(s){Y(e,s)||(Ns(e,s),Qt(s))},start:function(s){return Ds(e,s)},drop:Z(e,Ms),leave:function(s){Y(e,s)||yo(e)}};var a=t.input.getField();T(a,"keyup",function(s){return Do.call(e,s)}),T(a,"keydown",Z(e,Mo)),T(a,"keypress",Z(e,No)),T(a,"focus",function(s){return tn(e,s)}),T(a,"blur",function(s){return Dt(e,s)})}var wn=[];I.defineInitHook=function(e){return wn.push(e)};function Sr(e,t,i,r){var n=e.doc,l;i==null&&(i="add"),i=="smart"&&(n.mode.indent?l=jt(e,t).state:i="prev");var o=e.options.tabSize,a=w(n,t),s=be(a.text,null,o);a.stateAfter&&(a.stateAfter=null);var u=a.text.match(/^\s*/)[0],f;if(!r&&!/\S/.test(a.text))f=0,i="not";else if(i=="smart"&&(f=n.mode.indent(l,a.text.slice(u.length),a.text),f==Nr||f>150)){if(!r)return;i="prev"}i=="prev"?t>n.first?f=be(w(n,t-1).text,null,o):f=0:i=="add"?f=s+e.options.indentUnit:i=="subtract"?f=s-e.options.indentUnit:typeof i=="number"&&(f=s+i),f=Math.max(0,f);var h="",d=0;if(e.options.indentWithTabs)for(var c=Math.floor(f/o);c;--c)d+=o,h+=" ";if(d<f&&(h+=yi(f-d)),h!=u)return Ft(n,h,g(t,0),g(t,u.length),"+input"),a.stateAfter=null,!0;for(var p=0;p<n.sel.ranges.length;p++){var v=n.sel.ranges[p];if(v.head.line==t&&v.head.ch<u.length){var y=g(t,u.length);vn(n,p,new O(y,y));break}}}var Te=null;function ui(e){Te=e}function Sn(e,t,i,r,n){var l=e.doc;e.display.shift=!1,r||(r=l.sel);var o=+new Date-200,a=n=="paste"||e.state.pasteIncoming>o,s=ki(t),u=null;if(a&&r.ranges.length>1)if(Te&&Te.text.join(`
|
|
13
13
|
`)==t){if(r.ranges.length%Te.text.length==0){u=[];for(var f=0;f<Te.text.length;f++)u.push(l.splitLines(Te.text[f]))}}else s.length==r.ranges.length&&e.options.pasteLinesPerSelection&&(u=Or(s,function(m){return[m]}));for(var h=e.curOp.updateInput,d=r.ranges.length-1;d>=0;d--){var c=r.ranges[d],p=c.from(),v=c.to();c.empty()&&(i&&i>0?p=g(p.line,p.ch-i):e.state.overwrite&&!a?v=g(v.line,Math.min(w(l,v.line).text.length,v.ch+W(s).length)):a&&Te&&Te.lineWise&&Te.text.join(`
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
(self.webpackChunk_whyour_qinglong=self.webpackChunk_whyour_qinglong||[]).push([[3639],{65601:function(C,k,p){"use strict";p.d(k,{Z:function(){return c}});var h=p(14797),_=p(63313),i={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 1024c-69.1 0-136.2-13.5-199.3-40.2C251.7 958 197 921 150 874c-47-47-84-101.7-109.8-162.7C13.5 648.2 0 581.1 0 512c0-19.9 16.1-36 36-36s36 16.1 36 36c0 59.4 11.6 117 34.6 171.3 22.2 52.4 53.9 99.5 94.3 139.9 40.4 40.4 87.5 72.2 139.9 94.3C395 940.4 452.6 952 512 952c59.4 0 117-11.6 171.3-34.6 52.4-22.2 99.5-53.9 139.9-94.3 40.4-40.4 72.2-87.5 94.3-139.9C940.4 629 952 571.4 952 512c0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.2C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3s-13.5 136.2-40.2 199.3C958 772.3 921 827 874 874c-47 47-101.8 83.9-162.7 109.7-63.1 26.8-130.2 40.3-199.3 40.3z"}}]},name:"loading-3-quarters",theme:"outlined"},l=i,s=p(46420),r=function(y,a){return _.createElement(s.Z,(0,h.Z)((0,h.Z)({},y),{},{ref:a,icon:l}))};r.displayName="Loading3QuartersOutlined";var c=_.forwardRef(r)},84658:function(C){"use strict";var k=function(){function i(l,s){for(var r=0;r<s.length;r++){var c=s[r];c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(l,c.key,c)}}return function(l,s,r){return s&&i(l.prototype,s),r&&i(l,r),l}}();function p(i,l){if(!(i instanceof l))throw new TypeError("Cannot call a class as a function")}var h=[[{color:"0, 0, 0",class:"ansi-black"},{color:"187, 0, 0",class:"ansi-red"},{color:"0, 187, 0",class:"ansi-green"},{color:"187, 187, 0",class:"ansi-yellow"},{color:"0, 0, 187",class:"ansi-blue"},{color:"187, 0, 187",class:"ansi-magenta"},{color:"0, 187, 187",class:"ansi-cyan"},{color:"255,255,255",class:"ansi-white"}],[{color:"85, 85, 85",class:"ansi-bright-black"},{color:"255, 85, 85",class:"ansi-bright-red"},{color:"0, 255, 0",class:"ansi-bright-green"},{color:"255, 255, 85",class:"ansi-bright-yellow"},{color:"85, 85, 255",class:"ansi-bright-blue"},{color:"255, 85, 255",class:"ansi-bright-magenta"},{color:"85, 255, 255",class:"ansi-bright-cyan"},{color:"255, 255, 255",class:"ansi-bright-white"}]],_=function(){k(i,null,[{key:"escapeForHtml",value:function(s){return new i().escapeForHtml(s)}},{key:"linkify",value:function(s){return new i().linkify(s)}},{key:"ansiToHtml",value:function(s,r){return new i().ansiToHtml(s,r)}},{key:"ansiToJson",value:function(s,r){return new i().ansiToJson(s,r)}},{key:"ansiToText",value:function(s){return new i().ansiToText(s)}}]);function i(){p(this,i),this.fg=this.bg=this.fg_truecolor=this.bg_truecolor=null,this.bright=0}return k(i,[{key:"setupPalette",value:function(){this.PALETTE_COLORS=[];for(var s=0;s<2;++s)for(var r=0;r<8;++r)this.PALETTE_COLORS.push(h[s][r].color);for(var c=[0,95,135,175,215,255],v=function(d,u,w){return c[d]+", "+c[u]+", "+c[w]},y=void 0,a=void 0,f=void 0,n=0;n<6;++n)for(var t=0;t<6;++t)for(var e=0;e<6;++e)this.PALETTE_COLORS.push(v(n,t,e));for(var g=8,o=0;o<24;++o,g+=10)this.PALETTE_COLORS.push(v(g,g,g))}},{key:"escapeForHtml",value:function(s){return s.replace(/[&<>]/gm,function(r){return r=="&"?"&":r=="<"?"<":r==">"?">":""})}},{key:"linkify",value:function(s){return s.replace(/(https?:\/\/[^\s]+)/gm,function(r){return'<a href="'+r+'">'+r+"</a>"})}},{key:"ansiToHtml",value:function(s,r){return this.process(s,r,!0)}},{key:"ansiToJson",value:function(s,r){return r=r||{},r.json=!0,r.clearLine=!1,this.process(s,r,!0)}},{key:"ansiToText",value:function(s){return this.process(s,{},!1)}},{key:"process",value:function(s,r,c){var v=this,y=this,a=s.split(/\033\[/),f=a.shift();r==null&&(r={}),r.clearLine=/\r/.test(s);var n=a.map(function(e){return v.processChunk(e,r,c)});if(r&&r.json){var t=y.processChunkJson("");return t.content=f,t.clearLine=r.clearLine,n.unshift(t),r.remove_empty&&(n=n.filter(function(e){return!e.isEmpty()})),n}else n.unshift(f);return n.join("")}},{key:"processChunkJson",value:function(s,r,c){r=typeof r=="undefined"?{}:r;var v=r.use_classes=typeof r.use_classes!="undefined"&&r.use_classes,y=r.key=v?"class":"color",a={content:s,fg:null,bg:null,fg_truecolor:null,bg_truecolor:null,clearLine:r.clearLine,decoration:null,was_processed:!1,isEmpty:function(){return!a.content}},f=s.match(/^([!\x3c-\x3f]*)([\d;]*)([\x20-\x2c]*[\x40-\x7e])([\s\S]*)/m);if(!f)return a;var n=a.content=f[4],t=f[2].split(";");if(f[1]!==""||f[3]!=="m"||!c)return a;var e=this;for(e.decoration=null;t.length>0;){var g=t.shift(),o=parseInt(g);if(isNaN(o)||o===0)e.fg=e.bg=e.decoration=null;else if(o===1)e.decoration="bold";else if(o===2)e.decoration="dim";else if(o==3)e.decoration="italic";else if(o==4)e.decoration="underline";else if(o==5)e.decoration="blink";else if(o===7)e.decoration="reverse";else if(o===8)e.decoration="hidden";else if(o===9)e.decoration="strikethrough";else if(o==39)e.fg=null;else if(o==49)e.bg=null;else if(o>=30&&o<38)e.fg=h[0][o%10][y];else if(o>=90&&o<98)e.fg=h[1][o%10][y];else if(o>=40&&o<48)e.bg=h[0][o%10][y];else if(o>=100&&o<108)e.bg=h[1][o%10][y];else if(o===38||o===48){var b=o===38;if(t.length>=1){var d=t.shift();if(d==="5"&&t.length>=1){var u=parseInt(t.shift());if(u>=0&&u<=255)if(!v)this.PALETTE_COLORS||e.setupPalette(),b?e.fg=this.PALETTE_COLORS[u]:e.bg=this.PALETTE_COLORS[u];else{var w=u>=16?"ansi-palette-"+u:h[u>7?1:0][u%8].class;b?e.fg=w:e.bg=w}}else if(d==="2"&&t.length>=3){var L=parseInt(t.shift()),E=parseInt(t.shift()),T=parseInt(t.shift());if(L>=0&&L<=255&&E>=0&&E<=255&&T>=0&&T<=255){var O=L+", "+E+", "+T;v?b?(e.fg="ansi-truecolor",e.fg_truecolor=O):(e.bg="ansi-truecolor",e.bg_truecolor=O):b?e.fg=O:e.bg=O}}}}}if(e.fg===null&&e.bg===null&&e.decoration===null)return a;var m=[],S=[],R={};return a.fg=e.fg,a.bg=e.bg,a.fg_truecolor=e.fg_truecolor,a.bg_truecolor=e.bg_truecolor,a.decoration=e.decoration,a.was_processed=!0,a}},{key:"processChunk",value:function(s,r,c){var v=this,y=this;r=r||{};var a=this.processChunkJson(s,r,c);if(r.json)return a;if(a.isEmpty())return"";if(!a.was_processed)return a.content;var f=r.use_classes,n=[],t=[],e={},g=function(b){var d=[],u=void 0;for(u in b)b.hasOwnProperty(u)&&d.push("data-"+u+'="'+v.escapeForHtml(b[u])+'"');return d.length>0?" "+d.join(" "):""};return a.fg&&(f?(t.push(a.fg+"-fg"),a.fg_truecolor!==null&&(e["ansi-truecolor-fg"]=a.fg_truecolor,a.fg_truecolor=null)):n.push("color:rgb("+a.fg+")")),a.bg&&(f?(t.push(a.bg+"-bg"),a.bg_truecolor!==null&&(e["ansi-truecolor-bg"]=a.bg_truecolor,a.bg_truecolor=null)):n.push("background-color:rgb("+a.bg+")")),a.decoration&&(f?t.push("ansi-"+a.decoration):a.decoration==="bold"?n.push("font-weight:bold"):a.decoration==="dim"?n.push("opacity:0.5"):a.decoration==="italic"?n.push("font-style:italic"):a.decoration==="reverse"?n.push("filter:invert(100%)"):a.decoration==="hidden"?n.push("visibility:hidden"):a.decoration==="strikethrough"?n.push("text-decoration:line-through"):n.push("text-decoration:"+a.decoration)),f?'<span class="'+t.join(" ")+'"'+g(e)+">"+a.content+"</span>":'<span style="'+n.join(";")+'"'+g(e)+">"+a.content+"</span>"}}]),i}();C.exports=_},99120:function(C,k,p){"use strict";var h=this&&this.__importDefault||function(n){return n&&n.__esModule?n:{default:n}},_=this&&this.__importStar||function(n){if(n&&n.__esModule)return n;var t={};if(n!=null)for(var e in n)Object.hasOwnProperty.call(n,e)&&(t[e]=n[e]);return t.default=n,t};Object.defineProperty(k,"__esModule",{value:!0});const i=h(p(84658)),l=p(40526),s=_(p(63313));function r(n,t=!1){return n=l.escapeCarriageReturn(f(n)),i.default.ansiToJson(n,{json:!0,remove_empty:!0,use_classes:t})}function c(n){let t="";return n.bg&&(t+=`${n.bg}-bg `),n.fg&&(t+=`${n.fg}-fg `),n.decoration&&(t+=`ansi-${n.decoration} `),t===""?null:(t=t.substring(0,t.length-1),t)}function v(n){const t={};return n.bg&&(t.backgroundColor=`rgb(${n.bg})`),n.fg&&(t.color=`rgb(${n.fg})`),t}function y(n,t,e,g){const o=t?null:v(e),b=t?c(e):null;if(!n)return s.createElement("span",{style:o,key:g,className:b},e.content);const d=[],u=/(\s|^)(https?:\/\/(?:www\.|(?!www))[^\s.]+\.[^\s]{2,}|www\.[^\s]+\.[^\s]{2,})/g;let w=0,L;for(;(L=u.exec(e.content))!==null;){const[,E,T]=L,O=L.index+E.length;O>w&&d.push(e.content.substring(w,O));const m=T.startsWith("www.")?`http://${T}`:T;d.push(s.createElement("a",{key:w,href:m,target:"_blank"},`${T}`)),w=u.lastIndex}return w<e.content.length&&d.push(e.content.substring(w)),s.createElement("span",{style:o,key:g,className:b},d)}function a(n){const{className:t,useClasses:e,children:g,linkify:o}=n;return s.createElement("code",{className:t},r(g!=null?g:"",e!=null?e:!1).map(y.bind(null,o!=null?o:!1,e!=null?e:!1)))}k.default=a;function f(n){let t=n;do n=t,t=n.replace(/[^\n]\x08/gm,"");while(t.length<n.length);return n}},40526:function(C){function k(i){if(!i)return"";if(!/\r/.test(i))return i;for(i=i.replace(/\r+\n/gm,`
|
|
2
|
+
`);/\r./.test(i);)i=i.replace(/^([^\r\n]*)\r+([^\r\n]+)/gm,function(l,s,r){return r+s.slice(r.length)});return i}function p(i){for(var l=0,s=0;s<i.length;s++)i[l].length<=i[s].length&&(l=s);return l}function h(i){if(!/\r/.test(i))return i;for(var l=i.split("\r"),s=[];l.length>0;){var r=p(l);s.push(l[r]),l=l.slice(r+1)}return s.join("\r")}function _(i){if(!i)return"";if(!/\r/.test(i))return i;if(!/\n/.test(i))return h(i);i=i.replace(/\r+\n/gm,`
|
|
3
|
+
`);var l=i.lastIndexOf(`
|
|
4
|
+
`);return k(i.slice(0,l))+`
|
|
5
|
+
`+h(i.slice(l+1))}C.exports=k,C.exports.escapeCarriageReturn=k,C.exports.escapeCarriageReturnSafe=_}}]);
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_whyour_qinglong=self.webpackChunk_whyour_qinglong||[]).push([[3800],{13800:function(Ue,le,p){p.d(le,{Z:function(){return Be}});var $=p(87807),j=p(60795),ue=p(65905),de=p(59673),fe=p(40227),ve=p(5132),pe=p(84875),G=p.n(pe),ge=p(92976),o=p(63313),he=p(82259),ee=p(20341),Y=p(56088),K=p(14797),te=p(16803),re={percent:0,prefixCls:"rc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,trailColor:"#D9D9D9",trailWidth:1,gapPosition:"bottom"},ae=function(){var e=(0,o.useRef)([]),t=(0,o.useRef)(null);return(0,o.useEffect)(function(){var r=Date.now(),a=!1;e.current.forEach(function(c){if(c){a=!0;var n=c.style;n.transitionDuration=".3s, .3s, .3s, .06s",t.current&&r-t.current<100&&(n.transitionDuration="0s, 0s")}}),a&&(t.current=Date.now())}),e.current},ke=["className","percent","prefixCls","strokeColor","strokeLinecap","strokeWidth","style","trailColor","trailWidth","transition"],ye=function(e){var t=(0,K.Z)((0,K.Z)({},re),e),r=t.className,a=t.percent,c=t.prefixCls,n=t.strokeColor,l=t.strokeLinecap,i=t.strokeWidth,u=t.style,f=t.trailColor,v=t.trailWidth,y=t.transition,g=(0,te.Z)(t,ke);delete g.gapPosition;var d=Array.isArray(a)?a:[a],m=Array.isArray(n)?n:[n],h=ae(),C=i/2,O=100-i/2,P="M ".concat(l==="round"?C:0,",").concat(C,`
|
|
2
|
+
L `).concat(l==="round"?O:100,",").concat(C),b="0 0 100 ".concat(i),E=0;return o.createElement("svg",(0,j.Z)({className:G()("".concat(c,"-line"),r),viewBox:b,preserveAspectRatio:"none",style:u},g),o.createElement("path",{className:"".concat(c,"-line-trail"),d:P,strokeLinecap:l,stroke:f,strokeWidth:v||i,fillOpacity:"0"}),d.map(function(k,S){var L=1;switch(l){case"round":L=1-i/100;break;case"square":L=1-i/2/100;break;default:L=1;break}var W={strokeDasharray:"".concat(k*L,"px, 100px"),strokeDashoffset:"-".concat(E,"px"),transition:y||"stroke-dashoffset 0.3s ease 0s, stroke-dasharray .3s ease 0s, stroke 0.3s linear"},z=m[S]||m[m.length-1];return E+=k,o.createElement("path",{key:S,className:"".concat(c,"-line-path"),d:P,strokeLinecap:l,stroke:z,strokeWidth:i,fillOpacity:"0",ref:function(T){h[S]=T},style:W})}))},me=ye,X=p(18790),Ce=p(17079),Pe=p(65021),se=0,Se=(0,Pe.Z)();function xe(){var s;return Se?(s=se,se+=1):s="TEST_OR_SSR",s}var be=function(s){var e=o.useState(),t=(0,Ce.Z)(e,2),r=t[0],a=t[1];return o.useEffect(function(){a("rc_progress_".concat(xe()))},[]),s||r},Ee=["id","prefixCls","steps","strokeWidth","trailWidth","gapDegree","gapPosition","trailColor","strokeLinecap","style","className","strokeColor","percent"];function oe(s){return+s.replace("%","")}function ne(s){var e=s!=null?s:[];return Array.isArray(e)?e:[e]}var B=100,q=function(e,t,r,a,c,n,l,i,u,f){var v=arguments.length>10&&arguments[10]!==void 0?arguments[10]:0,y=r/100*360*((360-n)/360),g=n===0?0:{bottom:0,top:180,left:90,right:-90}[l],d=(100-a)/100*t;return u==="round"&&a!==100&&(d+=f/2,d>=t&&(d=t-.01)),{stroke:typeof i=="string"?i:void 0,strokeDasharray:"".concat(t,"px ").concat(e),strokeDashoffset:d+v,transform:"rotate(".concat(c+y+g,"deg)"),transformOrigin:"0 0",transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s, opacity .3s ease 0s",fillOpacity:0}},Le=function(e){var t=(0,K.Z)((0,K.Z)({},re),e),r=t.id,a=t.prefixCls,c=t.steps,n=t.strokeWidth,l=t.trailWidth,i=t.gapDegree,u=i===void 0?0:i,f=t.gapPosition,v=t.trailColor,y=t.strokeLinecap,g=t.style,d=t.className,m=t.strokeColor,h=t.percent,C=(0,te.Z)(t,Ee),O=be(r),P="".concat(O,"-gradient"),b=B/2-n/2,E=Math.PI*2*b,k=u>0?90+u/2:-90,S=E*((360-u)/360),L=(0,X.Z)(c)==="object"?c:{count:c,space:2},W=L.count,z=L.space,R=q(E,S,0,100,k,u,f,v,y,n),T=ne(h),x=ne(m),D=x.find(function(N){return N&&(0,X.Z)(N)==="object"}),M=ae(),_=function(){var Z=0;return T.map(function(A,F){var J=x[F]||x[x.length-1],U=J&&(0,X.Z)(J)==="object"?"url(#".concat(P,")"):void 0,V=q(E,S,Z,A,k,u,f,J,y,n);return Z+=A,o.createElement("circle",{key:F,className:"".concat(a,"-circle-path"),r:b,cx:0,cy:0,stroke:U,strokeLinecap:y,strokeWidth:n,opacity:A===0?0:1,style:V,ref:function(Q){M[F]=Q}})}).reverse()},I=function(){var Z=Math.round(W*(T[0]/100)),A=100/W,F=0;return new Array(W).fill(null).map(function(J,U){var V=U<=Z-1?x[0]:v,ie=V&&(0,X.Z)(V)==="object"?"url(#".concat(P,")"):void 0,Q=q(E,S,F,A,k,u,f,V,"butt",n,z);return F+=(S-Q.strokeDashoffset+z)*100/S,o.createElement("circle",{key:U,className:"".concat(a,"-circle-path"),r:b,cx:0,cy:0,stroke:ie,strokeWidth:n,opacity:1,style:Q,ref:function(Me){M[U]=Me}})})};return o.createElement("svg",(0,j.Z)({className:G()("".concat(a,"-circle"),d),viewBox:"".concat(-B/2," ").concat(-B/2," ").concat(B," ").concat(B),style:g,id:r,role:"presentation"},C),D&&o.createElement("defs",null,o.createElement("linearGradient",{id:P,x1:"100%",y1:"0%",x2:"0%",y2:"0%"},Object.keys(D).sort(function(N,Z){return oe(N)-oe(Z)}).map(function(N,Z){return o.createElement("stop",{key:Z,offset:N,stopColor:D[N]})}))),!W&&o.createElement("circle",{className:"".concat(a,"-circle-trail"),r:b,cx:0,cy:0,stroke:v,strokeLinecap:y,strokeWidth:l||n,style:R}),W?I():_())},ce=Le,Ve={Line:me,Circle:ce};function w(s){return!s||s<0?0:s>100?100:s}function H(s){var e=s.success,t=s.successPercent,r=t;return e&&"progress"in e&&(r=e.progress),e&&"percent"in e&&(r=e.percent),r}function Ne(s){var e=s.percent,t=s.success,r=s.successPercent,a=w(H({success:t,successPercent:r}));return[a,w(w(e)-a)]}function Ze(s){var e=s.success,t=e===void 0?{}:e,r=s.strokeColor,a=t.strokeColor;return[a||Y.ez.green,r||null]}var Oe=function(e){var t=e.prefixCls,r=e.width,a=e.strokeWidth,c=e.trailColor,n=c===void 0?null:c,l=e.strokeLinecap,i=l===void 0?"round":l,u=e.gapPosition,f=e.gapDegree,v=e.type,y=e.children,g=e.success,d=r||120,m={width:d,height:d,fontSize:d*.15+6},h=a||6,C=u||v==="dashboard"&&"bottom"||void 0,O=function(){if(f||f===0)return f;if(v==="dashboard")return 75},P=Object.prototype.toString.call(e.strokeColor)==="[object Object]",b=Ze({success:g,strokeColor:e.strokeColor}),E=G()("".concat(t,"-inner"),(0,$.Z)({},"".concat(t,"-circle-gradient"),P));return o.createElement("div",{className:E,style:m},o.createElement(ce,{percent:Ne(e),strokeWidth:h,trailWidth:h,strokeColor:b,strokeLinecap:i,trailColor:n,prefixCls:t,gapDegree:O(),gapPosition:C}),y)},We=Oe,De=function(s,e){var t={};for(var r in s)Object.prototype.hasOwnProperty.call(s,r)&&e.indexOf(r)<0&&(t[r]=s[r]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,r=Object.getOwnPropertySymbols(s);a<r.length;a++)e.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(s,r[a])&&(t[r[a]]=s[r[a]]);return t},Ie=function(e){var t=[];return Object.keys(e).forEach(function(r){var a=parseFloat(r.replace(/%/g,""));isNaN(a)||t.push({key:a,value:e[r]})}),t=t.sort(function(r,a){return r.key-a.key}),t.map(function(r){var a=r.key,c=r.value;return"".concat(c," ").concat(a,"%")}).join(", ")},$e=function(e,t){var r=e.from,a=r===void 0?Y.ez.blue:r,c=e.to,n=c===void 0?Y.ez.blue:c,l=e.direction,i=l===void 0?t==="rtl"?"to left":"to right":l,u=De(e,["from","to","direction"]);if(Object.keys(u).length!==0){var f=Ie(u);return{backgroundImage:"linear-gradient(".concat(i,", ").concat(f,")")}}return{backgroundImage:"linear-gradient(".concat(i,", ").concat(a,", ").concat(n,")")}},je=function(e){var t=e.prefixCls,r=e.direction,a=e.percent,c=e.strokeWidth,n=e.size,l=e.strokeColor,i=e.strokeLinecap,u=i===void 0?"round":i,f=e.children,v=e.trailColor,y=v===void 0?null:v,g=e.success,d=l&&typeof l!="string"?$e(l,r):{background:l},m=u==="square"||u==="butt"?0:void 0,h={backgroundColor:y||void 0,borderRadius:m},C=(0,j.Z)({width:"".concat(w(a),"%"),height:c||(n==="small"?6:8),borderRadius:m},d),O=H(e),P={width:"".concat(w(O),"%"),height:c||(n==="small"?6:8),borderRadius:m,backgroundColor:g==null?void 0:g.strokeColor},b=O!==void 0?o.createElement("div",{className:"".concat(t,"-success-bg"),style:P}):null;return o.createElement(o.Fragment,null,o.createElement("div",{className:"".concat(t,"-outer")},o.createElement("div",{className:"".concat(t,"-inner"),style:h},o.createElement("div",{className:"".concat(t,"-bg"),style:C}),b)),f)},we=je,Ae=function(e){for(var t=e.size,r=e.steps,a=e.percent,c=a===void 0?0:a,n=e.strokeWidth,l=n===void 0?8:n,i=e.strokeColor,u=e.trailColor,f=u===void 0?null:u,v=e.prefixCls,y=e.children,g=Math.round(r*(c/100)),d=t==="small"?2:14,m=new Array(r),h=0;h<r;h++){var C=Array.isArray(i)?i[h]:i;m[h]=o.createElement("div",{key:h,className:G()("".concat(v,"-steps-item"),(0,$.Z)({},"".concat(v,"-steps-item-active"),h<=g-1)),style:{backgroundColor:h<=g-1?C:f,width:d,height:l}})}return o.createElement("div",{className:"".concat(v,"-steps-outer")},m,y)},ze=Ae,Re=function(s,e){var t={};for(var r in s)Object.prototype.hasOwnProperty.call(s,r)&&e.indexOf(r)<0&&(t[r]=s[r]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,r=Object.getOwnPropertySymbols(s);a<r.length;a++)e.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(s,r[a])&&(t[r[a]]=s[r[a]]);return t},Ke=(0,ee.b)("line","circle","dashboard"),Te=(0,ee.b)("normal","exception","active","success"),Fe=function(e){var t,r=e.prefixCls,a=e.className,c=e.steps,n=e.strokeColor,l=e.percent,i=l===void 0?0:l,u=e.size,f=u===void 0?"default":u,v=e.showInfo,y=v===void 0?!0:v,g=e.type,d=g===void 0?"line":g,m=Re(e,["prefixCls","className","steps","strokeColor","percent","size","showInfo","type"]);function h(){var x=H(e);return parseInt(x!==void 0?x.toString():i.toString(),10)}function C(){var x=e.status;return!Te.includes(x)&&h()>=100?"success":x||"normal"}function O(x,D){var M=e.format,_=H(e);if(!y)return null;var I,N=M||function(A){return"".concat(A,"%")},Z=d==="line";return M||D!=="exception"&&D!=="success"?I=N(w(i),w(_)):D==="exception"?I=Z?o.createElement(fe.Z,null):o.createElement(ve.Z,null):D==="success"&&(I=Z?o.createElement(ue.Z,null):o.createElement(de.Z,null)),o.createElement("span",{className:"".concat(x,"-text"),title:typeof I=="string"?I:void 0},I)}var P=o.useContext(he.E_),b=P.getPrefixCls,E=P.direction,k=b("progress",r),S=C(),L=O(k,S),W=Array.isArray(n)?n[0]:n,z=typeof n=="string"||Array.isArray(n)?n:void 0,R;d==="line"?R=c?o.createElement(ze,(0,j.Z)({},e,{strokeColor:z,prefixCls:k,steps:c}),L):o.createElement(we,(0,j.Z)({},e,{strokeColor:W,prefixCls:k,direction:E}),L):(d==="circle"||d==="dashboard")&&(R=o.createElement(We,(0,j.Z)({},e,{strokeColor:W,prefixCls:k,progressStatus:S}),L));var T=G()(k,(t={},(0,$.Z)(t,"".concat(k,"-").concat(d==="dashboard"&&"circle"||c&&"steps"||d),!0),(0,$.Z)(t,"".concat(k,"-status-").concat(S),!0),(0,$.Z)(t,"".concat(k,"-show-info"),y),(0,$.Z)(t,"".concat(k,"-").concat(f),f),(0,$.Z)(t,"".concat(k,"-rtl"),E==="rtl"),t),a);return o.createElement("div",(0,j.Z)({},(0,ge.Z)(m,["status","format","trailColor","strokeWidth","width","gapDegree","gapPosition","strokeLinecap","success","successPercent"]),{className:T,role:"progressbar"}),R)},Ge=Fe,Be=Ge}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_whyour_qinglong=self.webpackChunk_whyour_qinglong||[]).push([[3820],{75909:function(K,P,e){var r=e(14797),n=e(87807),v=e(16803),f=e(63313),x=e.n(f),a=e(84875),y=e.n(a),l=e(12888),o=e(57439),m=["className","component","viewBox","spin","rotate","tabIndex","onClick","children"],Z=f.forwardRef(function(O,S){var M=O.className,V=O.component,B=O.viewBox,X=O.spin,W=O.rotate,G=O.tabIndex,g=O.onClick,b=O.children,N=(0,v.Z)(O,m);(0,o.Kp)(!!(V||b),"Should have `component` prop or `children`."),(0,o.C3)();var t=f.useContext(l.Z),h=t.prefixCls,E=h===void 0?"anticon":h,i=t.rootClassName,u=y()(i,E,M),U=y()((0,n.Z)({},"".concat(E,"-spin"),!!X)),s=W?{msTransform:"rotate(".concat(W,"deg)"),transform:"rotate(".concat(W,"deg)")}:void 0,d=(0,r.Z)((0,r.Z)({},o.vD),{},{className:U,style:s,viewBox:B});B||delete d.viewBox;var p=function(){return V?f.createElement(V,(0,r.Z)({},d),b):b?((0,o.Kp)(!!B||f.Children.count(b)===1&&f.isValidElement(b)&&f.Children.only(b).type==="use","Make sure that you provide correct `viewBox` prop (default `0 0 1024 1024`) to the icon."),f.createElement("svg",(0,r.Z)((0,r.Z)({},d),{},{viewBox:B}),b)):null},c=G;return c===void 0&&g&&(c=-1),f.createElement("span",(0,r.Z)((0,r.Z)({role:"img"},N),{},{ref:S,tabIndex:c,onClick:g,className:u}),p())});Z.displayName="AntdIcon",P.Z=Z},55258:function(K,P,e){e.d(P,{Z:function(){return m}});var r=e(14797),n=e(16803),v=e(63313),f=e.n(v),x=e(75909),a=["type","children"],y=new Set;function l(Z){return!!(typeof Z=="string"&&Z.length&&!y.has(Z))}function o(Z){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,S=Z[O];if(l(S)){var M=document.createElement("script");M.setAttribute("src",S),M.setAttribute("data-namespace",S),Z.length>O+1&&(M.onload=function(){o(Z,O+1)},M.onerror=function(){o(Z,O+1)}),y.add(S),document.body.appendChild(M)}}function m(){var Z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},O=Z.scriptUrl,S=Z.extraCommonProps,M=S===void 0?{}:S;O&&typeof document!="undefined"&&typeof window!="undefined"&&typeof document.createElement=="function"&&(Array.isArray(O)?o(O.reverse()):o([O]));var V=v.forwardRef(function(B,X){var W=B.type,G=B.children,g=(0,n.Z)(B,a),b=null;return B.type&&(b=v.createElement("use",{xlinkHref:"#".concat(W)})),G&&(b=G),v.createElement(x.Z,(0,r.Z)((0,r.Z)((0,r.Z)({},M),g),{},{ref:X}),b)});return V.displayName="Iconfont",V}},20209:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M686.7 638.6L544.1 535.5V288c0-4.4-3.6-8-8-8H488c-4.4 0-8 3.6-8 8v275.4c0 2.6 1.2 5 3.3 6.5l165.4 120.6c3.6 2.6 8.6 1.8 11.2-1.7l28.6-39c2.6-3.7 1.8-8.7-1.8-11.2z"}}]},name:"clock-circle",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="ClockCircleOutlined";var y=n.forwardRef(a)},13740:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="DeleteOutlined";var y=n.forwardRef(a)},7688:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M945 412H689c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h256c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zM811 548H689c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h122c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zM477.3 322.5H434c-6.2 0-11.2 5-11.2 11.2v248c0 3.6 1.7 6.9 4.6 9l148.9 108.6c5 3.6 12 2.6 15.6-2.4l25.7-35.1v-.1c3.6-5 2.5-12-2.5-15.6l-126.7-91.6V333.7c.1-6.2-5-11.2-11.1-11.2z"}},{tag:"path",attrs:{d:"M804.8 673.9H747c-5.6 0-10.9 2.9-13.9 7.7a321 321 0 01-44.5 55.7 317.17 317.17 0 01-101.3 68.3c-39.3 16.6-81 25-124 25-43.1 0-84.8-8.4-124-25-37.9-16-72-39-101.3-68.3s-52.3-63.4-68.3-101.3c-16.6-39.2-25-80.9-25-124 0-43.1 8.4-84.7 25-124 16-37.9 39-72 68.3-101.3 29.3-29.3 63.4-52.3 101.3-68.3 39.2-16.6 81-25 124-25 43.1 0 84.8 8.4 124 25 37.9 16 72 39 101.3 68.3a321 321 0 0144.5 55.7c3 4.8 8.3 7.7 13.9 7.7h57.8c6.9 0 11.3-7.2 8.2-13.3-65.2-129.7-197.4-214-345-215.7-216.1-2.7-395.6 174.2-396 390.1C71.6 727.5 246.9 903 463.2 903c149.5 0 283.9-84.6 349.8-215.8a9.18 9.18 0 00-8.2-13.3z"}}]},name:"field-time",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="FieldTimeOutlined";var y=n.forwardRef(a)},97674:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494zM504 618H320c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zM312 490v48c0 4.4 3.6 8 8 8h384c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H320c-4.4 0-8 3.6-8 8z"}}]},name:"file-text",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="FileTextOutlined";var y=n.forwardRef(a)},3563:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M290 236.4l43.9-43.9a8.01 8.01 0 00-4.7-13.6L169 160c-5.1-.6-9.5 3.7-8.9 8.9L179 329.1c.8 6.6 8.9 9.4 13.6 4.7l43.7-43.7L370 423.7c3.1 3.1 8.2 3.1 11.3 0l42.4-42.3c3.1-3.1 3.1-8.2 0-11.3L290 236.4zm352.7 187.3c3.1 3.1 8.2 3.1 11.3 0l133.7-133.6 43.7 43.7a8.01 8.01 0 0013.6-4.7L863.9 169c.6-5.1-3.7-9.5-8.9-8.9L694.8 179c-6.6.8-9.4 8.9-4.7 13.6l43.9 43.9L600.3 370a8.03 8.03 0 000 11.3l42.4 42.4zM845 694.9c-.8-6.6-8.9-9.4-13.6-4.7l-43.7 43.7L654 600.3a8.03 8.03 0 00-11.3 0l-42.4 42.3a8.03 8.03 0 000 11.3L734 787.6l-43.9 43.9a8.01 8.01 0 004.7 13.6L855 864c5.1.6 9.5-3.7 8.9-8.9L845 694.9zm-463.7-94.6a8.03 8.03 0 00-11.3 0L236.3 733.9l-43.7-43.7a8.01 8.01 0 00-13.6 4.7L160.1 855c-.6 5.1 3.7 9.5 8.9 8.9L329.2 845c6.6-.8 9.4-8.9 4.7-13.6L290 787.6 423.7 654c3.1-3.1 3.1-8.2 0-11.3l-42.4-42.4z"}}]},name:"fullscreen",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="FullscreenOutlined";var y=n.forwardRef(a)},65601:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 1024c-69.1 0-136.2-13.5-199.3-40.2C251.7 958 197 921 150 874c-47-47-84-101.7-109.8-162.7C13.5 648.2 0 581.1 0 512c0-19.9 16.1-36 36-36s36 16.1 36 36c0 59.4 11.6 117 34.6 171.3 22.2 52.4 53.9 99.5 94.3 139.9 40.4 40.4 87.5 72.2 139.9 94.3C395 940.4 452.6 952 512 952c59.4 0 117-11.6 171.3-34.6 52.4-22.2 99.5-53.9 139.9-94.3 40.4-40.4 72.2-87.5 94.3-139.9C940.4 629 952 571.4 952 512c0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.2C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3s-13.5 136.2-40.2 199.3C958 772.3 921 827 874 874c-47 47-101.8 83.9-162.7 109.7-63.1 26.8-130.2 40.3-199.3 40.3z"}}]},name:"loading-3-quarters",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="Loading3QuartersOutlined";var y=n.forwardRef(a)},32320:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M696 480H328c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"minus-circle",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="MinusCircleOutlined";var y=n.forwardRef(a)},69685:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372zm-88-532h-48c-4.4 0-8 3.6-8 8v304c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8zm224 0h-48c-4.4 0-8 3.6-8 8v304c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8z"}}]},name:"pause-circle",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="PauseCircleOutlined";var y=n.forwardRef(a)},44968:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M719.4 499.1l-296.1-215A15.9 15.9 0 00398 297v430c0 13.1 14.8 20.5 25.3 12.9l296.1-215a15.9 15.9 0 000-25.8zm-257.6 134V390.9L628.5 512 461.8 633.1z"}}]},name:"play-circle",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="PlayCircleOutlined";var y=n.forwardRef(a)},43114:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M878.3 392.1L631.9 145.7c-6.5-6.5-15-9.7-23.5-9.7s-17 3.2-23.5 9.7L423.8 306.9c-12.2-1.4-24.5-2-36.8-2-73.2 0-146.4 24.1-206.5 72.3a33.23 33.23 0 00-2.7 49.4l181.7 181.7-215.4 215.2a15.8 15.8 0 00-4.6 9.8l-3.4 37.2c-.9 9.4 6.6 17.4 15.9 17.4.5 0 1 0 1.5-.1l37.2-3.4c3.7-.3 7.2-2 9.8-4.6l215.4-215.4 181.7 181.7c6.5 6.5 15 9.7 23.5 9.7 9.7 0 19.3-4.2 25.9-12.4 56.3-70.3 79.7-158.3 70.2-243.4l161.1-161.1c12.9-12.8 12.9-33.8 0-46.8zM666.2 549.3l-24.5 24.5 3.8 34.4a259.92 259.92 0 01-30.4 153.9L262 408.8c12.9-7.1 26.3-13.1 40.3-17.9 27.2-9.4 55.7-14.1 84.7-14.1 9.6 0 19.3.5 28.9 1.6l34.4 3.8 24.5-24.5L608.5 224 800 415.5 666.2 549.3z"}}]},name:"pushpin",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="PushpinOutlined";var y=n.forwardRef(a)},68834:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M924.8 625.7l-65.5-56c3.1-19 4.7-38.4 4.7-57.8s-1.6-38.8-4.7-57.8l65.5-56a32.03 32.03 0 009.3-35.2l-.9-2.6a443.74 443.74 0 00-79.7-137.9l-1.8-2.1a32.12 32.12 0 00-35.1-9.5l-81.3 28.9c-30-24.6-63.5-44-99.7-57.6l-15.7-85a32.05 32.05 0 00-25.8-25.7l-2.7-.5c-52.1-9.4-106.9-9.4-159 0l-2.7.5a32.05 32.05 0 00-25.8 25.7l-15.8 85.4a351.86 351.86 0 00-99 57.4l-81.9-29.1a32 32 0 00-35.1 9.5l-1.8 2.1a446.02 446.02 0 00-79.7 137.9l-.9 2.6c-4.5 12.5-.8 26.5 9.3 35.2l66.3 56.6c-3.1 18.8-4.6 38-4.6 57.1 0 19.2 1.5 38.4 4.6 57.1L99 625.5a32.03 32.03 0 00-9.3 35.2l.9 2.6c18.1 50.4 44.9 96.9 79.7 137.9l1.8 2.1a32.12 32.12 0 0035.1 9.5l81.9-29.1c29.8 24.5 63.1 43.9 99 57.4l15.8 85.4a32.05 32.05 0 0025.8 25.7l2.7.5a449.4 449.4 0 00159 0l2.7-.5a32.05 32.05 0 0025.8-25.7l15.7-85a350 350 0 0099.7-57.6l81.3 28.9a32 32 0 0035.1-9.5l1.8-2.1c34.8-41.1 61.6-87.5 79.7-137.9l.9-2.6c4.5-12.3.8-26.3-9.3-35zM788.3 465.9c2.5 15.1 3.8 30.6 3.8 46.1s-1.3 31-3.8 46.1l-6.6 40.1 74.7 63.9a370.03 370.03 0 01-42.6 73.6L721 702.8l-31.4 25.8c-23.9 19.6-50.5 35-79.3 45.8l-38.1 14.3-17.9 97a377.5 377.5 0 01-85 0l-17.9-97.2-37.8-14.5c-28.5-10.8-55-26.2-78.7-45.7l-31.4-25.9-93.4 33.2c-17-22.9-31.2-47.6-42.6-73.6l75.5-64.5-6.5-40c-2.4-14.9-3.7-30.3-3.7-45.5 0-15.3 1.2-30.6 3.7-45.5l6.5-40-75.5-64.5c11.3-26.1 25.6-50.7 42.6-73.6l93.4 33.2 31.4-25.9c23.7-19.5 50.2-34.9 78.7-45.7l37.9-14.3 17.9-97.2c28.1-3.2 56.8-3.2 85 0l17.9 97 38.1 14.3c28.7 10.8 55.4 26.2 79.3 45.8l31.4 25.8 92.8-32.9c17 22.9 31.2 47.6 42.6 73.6L781.8 426l6.5 39.9zM512 326c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 614c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 502c0-29.9 11.7-58 32.8-79.2C454 401.6 482.1 390 512 390c29.9 0 58 11.6 79.2 32.8A111.6 111.6 0 01624 502c0 29.9-11.7 58-32.8 79.2z"}}]},name:"setting",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="SettingOutlined";var y=n.forwardRef(a)},61327:function(K,P,e){e.d(P,{Z:function(){return y}});var r=e(14797),n=e(63313),v={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 192H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM104 228a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"unordered-list",theme:"outlined"},f=v,x=e(46420),a=function(o,m){return n.createElement(x.Z,(0,r.Z)((0,r.Z)({},o),{},{ref:m,icon:f}))};a.displayName="UnorderedListOutlined";var y=n.forwardRef(a)},1953:function(K,P,e){e.d(P,{Z:function(){return N}});var r=e(87807),n=e(60795),v=e(84875),f=e.n(v),x=e(92976),a=e(63313),y=e(82259),l=e(65189),o=e(13700),m=e(86986),Z=function(t,h){var E={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&h.indexOf(i)<0&&(E[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var u=0,i=Object.getOwnPropertySymbols(t);u<i.length;u++)h.indexOf(i[u])<0&&Object.prototype.propertyIsEnumerable.call(t,i[u])&&(E[i[u]]=t[i[u]]);return E},O=function(h){var E=h.prefixCls,i=h.className,u=h.hoverable,U=u===void 0?!0:u,s=Z(h,["prefixCls","className","hoverable"]);return a.createElement(y.C,null,function(d){var p=d.getPrefixCls,c=p("card",E),C=f()("".concat(c,"-grid"),i,(0,r.Z)({},"".concat(c,"-grid-hoverable"),U));return a.createElement("div",(0,n.Z)({},s,{className:C}))})},S=O,M=function(t,h){var E={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&h.indexOf(i)<0&&(E[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var u=0,i=Object.getOwnPropertySymbols(t);u<i.length;u++)h.indexOf(i[u])<0&&Object.prototype.propertyIsEnumerable.call(t,i[u])&&(E[i[u]]=t[i[u]]);return E};function V(t){var h=t.map(function(E,i){return a.createElement("li",{style:{width:"".concat(100/t.length,"%")},key:"action-".concat(i)},a.createElement("span",null,E))});return h}var B=a.forwardRef(function(t,h){var E,i,u=a.useContext(y.E_),U=u.getPrefixCls,s=u.direction,d=a.useContext(l.Z),p=function(ae){var re;(re=t.onTabChange)===null||re===void 0||re.call(t,ae)},c=function(){var ae;return a.Children.forEach(t.children,function(re){re&&re.type&&re.type===S&&(ae=!0)}),ae},C=t.prefixCls,L=t.className,z=t.extra,I=t.headStyle,$=I===void 0?{}:I,j=t.bodyStyle,H=j===void 0?{}:j,F=t.title,Y=t.loading,R=t.bordered,ie=R===void 0?!0:R,T=t.size,q=t.type,w=t.cover,ee=t.actions,te=t.tabList,ce=t.children,k=t.activeTabKey,ne=t.defaultActiveTabKey,de=t.tabBarExtraContent,pe=t.hoverable,ve=t.tabProps,Se=ve===void 0?{}:ve,me=M(t,["prefixCls","className","extra","headStyle","bodyStyle","title","loading","bordered","size","type","cover","actions","tabList","children","activeTabKey","defaultActiveTabKey","tabBarExtraContent","hoverable","tabProps"]),A=U("card",C),be=a.createElement(o.Z,{loading:!0,active:!0,paragraph:{rows:4},title:!1},ce),he=k!==void 0,ge=(0,n.Z)((0,n.Z)({},Se),(E={},(0,r.Z)(E,he?"activeKey":"defaultActiveKey",he?k:ne),(0,r.Z)(E,"tabBarExtraContent",de),E)),Ce,ye=te&&te.length?a.createElement(m.Z,(0,n.Z)({size:"large"},ge,{className:"".concat(A,"-head-tabs"),onChange:p,items:te.map(function(oe){var ae;return{label:oe.tab,key:oe.key,disabled:(ae=oe.disabled)!==null&&ae!==void 0?ae:!1}})})):null;(F||z||ye)&&(Ce=a.createElement("div",{className:"".concat(A,"-head"),style:$},a.createElement("div",{className:"".concat(A,"-head-wrapper")},F&&a.createElement("div",{className:"".concat(A,"-head-title")},F),z&&a.createElement("div",{className:"".concat(A,"-extra")},z)),ye));var fe=w?a.createElement("div",{className:"".concat(A,"-cover")},w):null,Me=a.createElement("div",{className:"".concat(A,"-body"),style:H},Y?be:ce),Ne=ee&&ee.length?a.createElement("ul",{className:"".concat(A,"-actions")},V(ee)):null,Le=(0,x.Z)(me,["onTabChange"]),Oe=T||d,xe=f()(A,(i={},(0,r.Z)(i,"".concat(A,"-loading"),Y),(0,r.Z)(i,"".concat(A,"-bordered"),ie),(0,r.Z)(i,"".concat(A,"-hoverable"),pe),(0,r.Z)(i,"".concat(A,"-contain-grid"),c()),(0,r.Z)(i,"".concat(A,"-contain-tabs"),te&&te.length),(0,r.Z)(i,"".concat(A,"-").concat(Oe),Oe),(0,r.Z)(i,"".concat(A,"-type-").concat(q),!!q),(0,r.Z)(i,"".concat(A,"-rtl"),s==="rtl"),i),L);return a.createElement("div",(0,n.Z)({ref:h},Le,{className:xe}),Ce,fe,Me,Ne)}),X=B,W=function(t,h){var E={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&h.indexOf(i)<0&&(E[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var u=0,i=Object.getOwnPropertySymbols(t);u<i.length;u++)h.indexOf(i[u])<0&&Object.prototype.propertyIsEnumerable.call(t,i[u])&&(E[i[u]]=t[i[u]]);return E},G=function(h){return a.createElement(y.C,null,function(E){var i=E.getPrefixCls,u=h.prefixCls,U=h.className,s=h.avatar,d=h.title,p=h.description,c=W(h,["prefixCls","className","avatar","title","description"]),C=i("card",u),L=f()("".concat(C,"-meta"),U),z=s?a.createElement("div",{className:"".concat(C,"-meta-avatar")},s):null,I=d?a.createElement("div",{className:"".concat(C,"-meta-title")},d):null,$=p?a.createElement("div",{className:"".concat(C,"-meta-description")},p):null,j=I||$?a.createElement("div",{className:"".concat(C,"-meta-detail")},I,$):null;return a.createElement("div",(0,n.Z)({},c,{className:L}),z,j)})},g=G,b=X;b.Grid=S,b.Meta=g;var N=b},394:function(K,P,e){var r=e(60795),n=e(87807),v=e(84875),f=e.n(v),x=e(63313),a=e.n(x),y=e(82259),l=function(m,Z){var O={};for(var S in m)Object.prototype.hasOwnProperty.call(m,S)&&Z.indexOf(S)<0&&(O[S]=m[S]);if(m!=null&&typeof Object.getOwnPropertySymbols=="function")for(var M=0,S=Object.getOwnPropertySymbols(m);M<S.length;M++)Z.indexOf(S[M])<0&&Object.prototype.propertyIsEnumerable.call(m,S[M])&&(O[S[M]]=m[S[M]]);return O},o=function(Z){var O,S=x.useContext(y.E_),M=S.getPrefixCls,V=S.direction,B=Z.prefixCls,X=Z.type,W=X===void 0?"horizontal":X,G=Z.orientation,g=G===void 0?"center":G,b=Z.orientationMargin,N=Z.className,t=Z.children,h=Z.dashed,E=Z.plain,i=l(Z,["prefixCls","type","orientation","orientationMargin","className","children","dashed","plain"]),u=M("divider",B),U=g.length>0?"-".concat(g):g,s=!!t,d=g==="left"&&b!=null,p=g==="right"&&b!=null,c=f()(u,"".concat(u,"-").concat(W),(O={},(0,n.Z)(O,"".concat(u,"-with-text"),s),(0,n.Z)(O,"".concat(u,"-with-text").concat(U),s),(0,n.Z)(O,"".concat(u,"-dashed"),!!h),(0,n.Z)(O,"".concat(u,"-plain"),!!E),(0,n.Z)(O,"".concat(u,"-rtl"),V==="rtl"),(0,n.Z)(O,"".concat(u,"-no-default-orientation-margin-left"),d),(0,n.Z)(O,"".concat(u,"-no-default-orientation-margin-right"),p),O),N),C=(0,r.Z)((0,r.Z)({},d&&{marginLeft:b}),p&&{marginRight:b});return x.createElement("div",(0,r.Z)({className:c},i,{role:"separator"}),t&&W!=="vertical"&&x.createElement("span",{className:"".concat(u,"-inner-text"),style:C},t))};P.Z=o},64865:function(K,P,e){e.d(P,{ZM:function(){return E},ZP:function(){return U}});var r=e(14402),n=e(60795),v=e(87807),f=e(17079),x=e(18790),a=e(84875),y=e.n(a),l=e(63313),o=e.n(l),m=e(82259),Z=e(23474),O=e(19698),S=e(99043),M=e(79470),V=e(27705),B=e(11847),X=e(40630),W=e(25515),G=function(s,d){var p={};for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&d.indexOf(c)<0&&(p[c]=s[c]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var C=0,c=Object.getOwnPropertySymbols(s);C<c.length;C++)d.indexOf(c[C])<0&&Object.prototype.propertyIsEnumerable.call(s,c[C])&&(p[c[C]]=s[c[C]]);return p},g=function(d){var p=d.prefixCls,c=d.className,C=d.avatar,L=d.title,z=d.description,I=G(d,["prefixCls","className","avatar","title","description"]),$=(0,l.useContext)(m.E_),j=$.getPrefixCls,H=j("list",p),F=y()("".concat(H,"-item-meta"),c),Y=o().createElement("div",{className:"".concat(H,"-item-meta-content")},L&&o().createElement("h4",{className:"".concat(H,"-item-meta-title")},L),z&&o().createElement("div",{className:"".concat(H,"-item-meta-description")},z));return o().createElement("div",(0,n.Z)({},I,{className:F}),C&&o().createElement("div",{className:"".concat(H,"-item-meta-avatar")},C),(L||z)&&Y)},b=function(d,p){var c=d.prefixCls,C=d.children,L=d.actions,z=d.extra,I=d.className,$=d.colStyle,j=G(d,["prefixCls","children","actions","extra","className","colStyle"]),H=(0,l.useContext)(E),F=H.grid,Y=H.itemLayout,R=(0,l.useContext)(m.E_),ie=R.getPrefixCls,T=function(){var ne;return l.Children.forEach(C,function(de){typeof de=="string"&&(ne=!0)}),ne&&l.Children.count(C)>1},q=function(){return Y==="vertical"?!!z:!T()},w=ie("list",c),ee=L&&L.length>0&&o().createElement("ul",{className:"".concat(w,"-item-action"),key:"actions"},L.map(function(k,ne){return o().createElement("li",{key:"".concat(w,"-item-action-").concat(ne)},k,ne!==L.length-1&&o().createElement("em",{className:"".concat(w,"-item-action-split")}))})),te=F?"div":"li",ce=o().createElement(te,(0,n.Z)({},j,F?{}:{ref:p},{className:y()("".concat(w,"-item"),(0,v.Z)({},"".concat(w,"-item-no-flex"),!q()),I)}),Y==="vertical"&&z?[o().createElement("div",{className:"".concat(w,"-item-main"),key:"content"},C,ee),o().createElement("div",{className:"".concat(w,"-item-extra"),key:"extra"},z)]:[C,ee,(0,W.Tm)(z,{key:"extra"})]);return F?o().createElement(X.Z,{ref:p,flex:1,style:$},ce):ce},N=(0,l.forwardRef)(b);N.Meta=g;var t=N,h=function(s,d){var p={};for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&d.indexOf(c)<0&&(p[c]=s[c]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var C=0,c=Object.getOwnPropertySymbols(s);C<c.length;C++)d.indexOf(c[C])<0&&Object.prototype.propertyIsEnumerable.call(s,c[C])&&(p[c[C]]=s[c[C]]);return p},E=l.createContext({}),i=E.Consumer;function u(s){var d,p=s.pagination,c=p===void 0?!1:p,C=s.prefixCls,L=s.bordered,z=L===void 0?!1:L,I=s.split,$=I===void 0?!0:I,j=s.className,H=s.children,F=s.itemLayout,Y=s.loadMore,R=s.grid,ie=s.dataSource,T=ie===void 0?[]:ie,q=s.size,w=s.header,ee=s.footer,te=s.loading,ce=te===void 0?!1:te,k=s.rowKey,ne=s.renderItem,de=s.locale,pe=h(s,["pagination","prefixCls","bordered","split","className","children","itemLayout","loadMore","grid","dataSource","size","header","footer","loading","rowKey","renderItem","locale"]),ve=c&&(0,x.Z)(c)==="object"?c:{},Se=l.useState(ve.defaultCurrent||1),me=(0,f.Z)(Se,2),A=me[0],be=me[1],he=l.useState(ve.defaultPageSize||10),ge=(0,f.Z)(he,2),Ce=ge[0],ye=ge[1],fe=l.useContext(m.E_),Me=fe.getPrefixCls,Ne=fe.renderEmpty,Le=fe.direction,Oe={current:1,total:0},xe=function(J){return function(se,le){be(se),ye(le),c&&c[J]&&c[J](se,le)}},oe=xe("onChange"),ae=xe("onShowSizeChange"),re=function(J,se){if(!ne)return null;var le;return typeof k=="function"?le=k(J):k?le=J[k]:le=J.key,le||(le="list-item-".concat(se)),l.createElement(l.Fragment,{key:le},ne(J,se))},je=function(){return!!(Y||c||ee)},we=function(J,se){return l.createElement("div",{className:"".concat(J,"-empty-text")},de&&de.emptyText||se("List"))},Q=Me("list",C),ue=ce;typeof ue=="boolean"&&(ue={spinning:ue});var Ie=ue&&ue.spinning,Ee="";switch(q){case"large":Ee="lg";break;case"small":Ee="sm";break;default:break}var Ke=y()(Q,(d={},(0,v.Z)(d,"".concat(Q,"-vertical"),F==="vertical"),(0,v.Z)(d,"".concat(Q,"-").concat(Ee),Ee),(0,v.Z)(d,"".concat(Q,"-split"),$),(0,v.Z)(d,"".concat(Q,"-bordered"),z),(0,v.Z)(d,"".concat(Q,"-loading"),Ie),(0,v.Z)(d,"".concat(Q,"-grid"),!!R),(0,v.Z)(d,"".concat(Q,"-something-after-last-item"),je()),(0,v.Z)(d,"".concat(Q,"-rtl"),Le==="rtl"),d),j),_=(0,n.Z)((0,n.Z)((0,n.Z)({},Oe),{total:T.length,current:A,pageSize:Ce}),c||{}),De=Math.ceil(_.total/_.pageSize);_.current>De&&(_.current=De);var Te=c?l.createElement("div",{className:"".concat(Q,"-pagination")},l.createElement(M.Z,(0,n.Z)({},_,{onChange:oe,onShowSizeChange:ae}))):null,ze=(0,r.Z)(T);c&&T.length>(_.current-1)*_.pageSize&&(ze=(0,r.Z)(T).splice((_.current-1)*_.pageSize,_.pageSize));var Ue=Object.keys(R||{}).some(function(D){return["xs","sm","md","lg","xl","xxl"].includes(D)}),Ae=(0,S.Z)(Ue),Pe=l.useMemo(function(){for(var D=0;D<B.c4.length;D+=1){var J=B.c4[D];if(Ae[J])return J}},[Ae]),Fe=l.useMemo(function(){if(R){var D=Pe&&R[Pe]?R[Pe]:R.column;if(D)return{width:"".concat(100/D,"%"),maxWidth:"".concat(100/D,"%")}}},[R==null?void 0:R.column,Pe]),Re=Ie&&l.createElement("div",{style:{minHeight:53}});if(ze.length>0){var Be=ze.map(function(D,J){return re(D,J)});Re=R?l.createElement(O.Z,{gutter:R.gutter},l.Children.map(Be,function(D){return l.createElement("div",{key:D==null?void 0:D.key,style:Fe},D)})):l.createElement("ul",{className:"".concat(Q,"-items")},Be)}else!H&&!Ie&&(Re=we(Q,Ne||Z.Z));var Ze=_.position||"bottom",We=l.useMemo(function(){return{grid:R,itemLayout:F}},[JSON.stringify(R),F]);return l.createElement(E.Provider,{value:We},l.createElement("div",(0,n.Z)({className:Ke},pe),(Ze==="top"||Ze==="both")&&Te,w&&l.createElement("div",{className:"".concat(Q,"-header")},w),l.createElement(V.Z,(0,n.Z)({},ue),Re,H),ee&&l.createElement("div",{className:"".concat(Q,"-footer")},ee),Y||(Ze==="bottom"||Ze==="both")&&Te))}u.Item=t;var U=u},16861:function(K,P,e){e.d(P,{Z:function(){return G}});var r=e(60795),n=e(87807),v=e(24090),f=e(84875),x=e.n(f),a=e(17079),y=e(16803),l=e(63313),o=e(26230),m=e(25641),Z=l.forwardRef(function(g,b){var N,t=g.prefixCls,h=t===void 0?"rc-switch":t,E=g.className,i=g.checked,u=g.defaultChecked,U=g.disabled,s=g.loadingIcon,d=g.checkedChildren,p=g.unCheckedChildren,c=g.onClick,C=g.onChange,L=g.onKeyDown,z=(0,y.Z)(g,["prefixCls","className","checked","defaultChecked","disabled","loadingIcon","checkedChildren","unCheckedChildren","onClick","onChange","onKeyDown"]),I=(0,o.Z)(!1,{value:i,defaultValue:u}),$=(0,a.Z)(I,2),j=$[0],H=$[1];function F(T,q){var w=j;return U||(w=T,H(w),C==null||C(w,q)),w}function Y(T){T.which===m.Z.LEFT?F(!1,T):T.which===m.Z.RIGHT&&F(!0,T),L==null||L(T)}function R(T){var q=F(!j,T);c==null||c(q,T)}var ie=x()(h,E,(N={},(0,n.Z)(N,"".concat(h,"-checked"),j),(0,n.Z)(N,"".concat(h,"-disabled"),U),N));return l.createElement("button",Object.assign({},z,{type:"button",role:"switch","aria-checked":j,disabled:U,className:ie,ref:b,onKeyDown:Y,onClick:R}),s,l.createElement("span",{className:"".concat(h,"-inner")},j?d:p))});Z.displayName="Switch";var O=Z,S=e(82259),M=e(7893),V=e(65189),B=e(1570),X=function(g,b){var N={};for(var t in g)Object.prototype.hasOwnProperty.call(g,t)&&b.indexOf(t)<0&&(N[t]=g[t]);if(g!=null&&typeof Object.getOwnPropertySymbols=="function")for(var h=0,t=Object.getOwnPropertySymbols(g);h<t.length;h++)b.indexOf(t[h])<0&&Object.prototype.propertyIsEnumerable.call(g,t[h])&&(N[t[h]]=g[t[h]]);return N},W=l.forwardRef(function(g,b){var N,t=g.prefixCls,h=g.size,E=g.disabled,i=g.loading,u=g.className,U=u===void 0?"":u,s=X(g,["prefixCls","size","disabled","loading","className"]),d=l.useContext(S.E_),p=d.getPrefixCls,c=d.direction,C=l.useContext(V.Z),L=l.useContext(M.Z),z=(E!=null?E:L)||i,I=p("switch",t),$=l.createElement("div",{className:"".concat(I,"-handle")},i&&l.createElement(v.Z,{className:"".concat(I,"-loading-icon")})),j=x()((N={},(0,n.Z)(N,"".concat(I,"-small"),(h||C)==="small"),(0,n.Z)(N,"".concat(I,"-loading"),i),(0,n.Z)(N,"".concat(I,"-rtl"),c==="rtl"),N),U);return l.createElement(B.Z,{insertExtraNode:!0},l.createElement(O,(0,r.Z)({},s,{prefixCls:I,className:j,disabled:z,ref:b,loadingIcon:$})))});W.__ANT_SWITCH=!0;var G=W}}]);
|